mirror of
https://github.com/anomalyco/opencode.git
synced 2026-05-04 23:40:48 +00:00
wip: desktop work
This commit is contained in:
parent
eff12cb484
commit
89b703c387
38 changed files with 1353 additions and 638 deletions
|
|
@ -29,6 +29,7 @@ export function List<T>(props: ListProps<T>) {
|
|||
// }
|
||||
const handleSelect = (item: T) => {
|
||||
props.onSelect?.(item)
|
||||
list.setActive(props.key(item))
|
||||
}
|
||||
|
||||
const handleKey = (e: KeyboardEvent) => {
|
||||
|
|
@ -64,10 +65,10 @@ export function List<T>(props: ListProps<T>) {
|
|||
data-key={props.key(item)}
|
||||
data-active={props.key(item) === list.active()}
|
||||
onClick={() => handleSelect(item)}
|
||||
onMouseMove={(e) => {
|
||||
e.currentTarget.focus()
|
||||
onMouseMove={() => {
|
||||
// e.currentTarget.focus()
|
||||
setStore("mouseActive", true)
|
||||
list.setActive(props.key(item))
|
||||
// list.setActive(props.key(item))
|
||||
}}
|
||||
>
|
||||
{props.children(item)}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue