Browse Source

chore: generate

opencode-agent[bot] 3 weeks ago
parent
commit
e84d441b82

+ 1 - 1
packages/app/src/components/dialog-select-model.tsx

@@ -92,7 +92,7 @@ export function ModelSelectorPopover<T extends ValidComponent = "div">(props: {
   provider?: string
   provider?: string
   children?: JSX.Element | ((open: boolean) => JSX.Element)
   children?: JSX.Element | ((open: boolean) => JSX.Element)
   triggerAs?: T
   triggerAs?: T
-  triggerProps?: ComponentProps<T>,
+  triggerProps?: ComponentProps<T>
   gutter?: number
   gutter?: number
 }) {
 }) {
   const [store, setStore] = createStore<{
   const [store, setStore] = createStore<{

+ 16 - 14
packages/app/src/components/prompt-input.tsx

@@ -925,7 +925,7 @@ export const PromptInput: Component<PromptInputProps> = (props) => {
       .abort({
       .abort({
         sessionID,
         sessionID,
       })
       })
-      .catch(() => { })
+      .catch(() => {})
   }
   }
 
 
   const addToHistory = (prompt: Prompt, mode: "normal" | "shell") => {
   const addToHistory = (prompt: Prompt, mode: "normal" | "shell") => {
@@ -1351,18 +1351,18 @@ export const PromptInput: Component<PromptInputProps> = (props) => {
 
 
     const contextParts: Array<
     const contextParts: Array<
       | {
       | {
-        id: string
-        type: "text"
-        text: string
-        synthetic?: boolean
-      }
+          id: string
+          type: "text"
+          text: string
+          synthetic?: boolean
+        }
       | {
       | {
-        id: string
-        type: "file"
-        mime: string
-        url: string
-        filename?: string
-      }
+          id: string
+          type: "file"
+          mime: string
+          url: string
+          filename?: string
+        }
     > = []
     > = []
 
 
     const commentNote = (path: string, selection: FileSelection | undefined, comment: string) => {
     const commentNote = (path: string, selection: FileSelection | undefined, comment: string) => {
@@ -1958,7 +1958,9 @@ export const PromptInput: Component<PromptInputProps> = (props) => {
                           <ProviderIcon id={local.model.current()!.provider.id as IconName} class="size-4 shrink-0" />
                           <ProviderIcon id={local.model.current()!.provider.id as IconName} class="size-4 shrink-0" />
                         </Show>
                         </Show>
                         {local.model.current()?.name ?? language.t("dialog.model.select.title")}
                         {local.model.current()?.name ?? language.t("dialog.model.select.title")}
-                        <MorphChevron expanded={!!dialog.active?.id && dialog.active.id.startsWith("select-model-unpaid")} />
+                        <MorphChevron
+                          expanded={!!dialog.active?.id && dialog.active.id.startsWith("select-model-unpaid")}
+                        />
                       </Button>
                       </Button>
                     </TooltipKeybind>
                     </TooltipKeybind>
                   }
                   }
@@ -2201,4 +2203,4 @@ function setCursorPosition(parent: HTMLElement, position: number) {
   fallbackRange.collapse(false)
   fallbackRange.collapse(false)
   fallbackSelection?.removeAllRanges()
   fallbackSelection?.removeAllRanges()
   fallbackSelection?.addRange(fallbackRange)
   fallbackSelection?.addRange(fallbackRange)
-}
+}

+ 16 - 16
packages/app/src/components/settings-general.tsx

@@ -60,24 +60,24 @@ export const SettingsGeneral: Component = () => {
         const actions =
         const actions =
           platform.update && platform.restart
           platform.update && platform.restart
             ? [
             ? [
-              {
-                label: language.t("toast.update.action.installRestart"),
-                onClick: async () => {
-                  await platform.update!()
-                  await platform.restart!()
+                {
+                  label: language.t("toast.update.action.installRestart"),
+                  onClick: async () => {
+                    await platform.update!()
+                    await platform.restart!()
+                  },
                 },
                 },
-              },
-              {
-                label: language.t("toast.update.action.notYet"),
-                onClick: "dismiss" as const,
-              },
-            ]
+                {
+                  label: language.t("toast.update.action.notYet"),
+                  onClick: "dismiss" as const,
+                },
+              ]
             : [
             : [
-              {
-                label: language.t("toast.update.action.notYet"),
-                onClick: "dismiss" as const,
-              },
-            ]
+                {
+                  label: language.t("toast.update.action.notYet"),
+                  onClick: "dismiss" as const,
+                },
+              ]
 
 
         showToast({
         showToast({
           persistent: true,
           persistent: true,

+ 1 - 1
packages/ui/src/components/button.tsx

@@ -4,7 +4,7 @@ import { Icon, IconProps } from "./icon"
 
 
 export interface ButtonProps
 export interface ButtonProps
   extends ComponentProps<typeof Kobalte>,
   extends ComponentProps<typeof Kobalte>,
-  Pick<ComponentProps<"button">, "class" | "classList" | "children" | "style"> {
+    Pick<ComponentProps<"button">, "class" | "classList" | "children" | "style"> {
   size?: "small" | "normal" | "large"
   size?: "small" | "normal" | "large"
   variant?: "primary" | "secondary" | "ghost"
   variant?: "primary" | "secondary" | "ghost"
   icon?: IconProps["name"]
   icon?: IconProps["name"]

+ 5 - 2
packages/ui/src/components/cycle-label.tsx

@@ -23,7 +23,10 @@ const wait = (ms: number) => new Promise((resolve) => setTimeout(resolve, ms))
 
 
 export function CycleLabel(props: CycleLabelProps) {
 export function CycleLabel(props: CycleLabelProps) {
   const getDuration = (text: string) => {
   const getDuration = (text: string) => {
-    const d = props.duration ?? Number(getComputedStyle(document.documentElement).getPropertyValue("--transition-duration")) ?? 200
+    const d =
+      props.duration ??
+      Number(getComputedStyle(document.documentElement).getPropertyValue("--transition-duration")) ??
+      200
     return typeof d === "function" ? d(text) : d
     return typeof d === "function" ? d(text) : d
   }
   }
   const stagger = () => props?.stagger ?? 30
   const stagger = () => props?.stagger ?? 30
@@ -129,4 +132,4 @@ export function CycleLabel(props: CycleLabelProps) {
       }}
       }}
     />
     />
   )
   )
-}
+}

+ 4 - 1
packages/ui/src/components/icon.tsx

@@ -86,7 +86,10 @@ export interface IconProps extends ComponentProps<"svg"> {
 export function Icon(props: IconProps) {
 export function Icon(props: IconProps) {
   const [local, others] = splitProps(props, ["name", "size", "class", "classList"])
   const [local, others] = splitProps(props, ["name", "size", "class", "classList"])
   return (
   return (
-    <div data-component="icon" data-size={typeof local.size !== 'number' ? local.size || "normal" : `size-[${local.size}px]`}>
+    <div
+      data-component="icon"
+      data-size={typeof local.size !== "number" ? local.size || "normal" : `size-[${local.size}px]`}
+    >
       <svg
       <svg
         data-slot="icon-svg"
         data-slot="icon-svg"
         classList={{
         classList={{

+ 1 - 1
packages/ui/src/components/morph-chevron.tsx

@@ -70,4 +70,4 @@ export function MorphChevron(props: MorphChevronProps) {
       </path>
       </path>
     </svg>
     </svg>
   )
   )
-}
+}

+ 17 - 3
packages/ui/src/components/reasoning-icon.tsx

@@ -25,8 +25,22 @@ export function ReasoningIcon(props: ReasoningIconProps) {
         [split.class ?? ""]: !!split.class,
         [split.class ?? ""]: !!split.class,
       }}
       }}
     >
     >
-      <path d="M5.83196 10.3225V11.1666C5.83196 11.7189 6.27967 12.1666 6.83196 12.1666H9.16687C9.71915 12.1666 10.1669 11.7189 10.1669 11.1666V10.3225M5.83196 10.3225C5.55695 10.1843 5.29695 10.0206 5.05505 9.83459C3.90601 8.95086 3.16549 7.56219 3.16549 6.00055C3.16549 3.33085 5.32971 1.16663 7.99941 1.16663C10.6691 1.16663 12.8333 3.33085 12.8333 6.00055C12.8333 7.56219 12.0928 8.95086 10.9438 9.83459C10.7019 10.0206 10.4419 10.1843 10.1669 10.3225M5.83196 10.3225H10.1669M6.5 14.1666H9.5" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" />
-      <circle cx="8" cy="5.83325" r="2.86364" fill="currentColor" stroke="currentColor" stroke-width={strokeWidth()} style={{ '--reasoning-icon-percentage': split.percentage / 100 }} data-slot="reasoning-icon-percentage" />
+      <path
+        d="M5.83196 10.3225V11.1666C5.83196 11.7189 6.27967 12.1666 6.83196 12.1666H9.16687C9.71915 12.1666 10.1669 11.7189 10.1669 11.1666V10.3225M5.83196 10.3225C5.55695 10.1843 5.29695 10.0206 5.05505 9.83459C3.90601 8.95086 3.16549 7.56219 3.16549 6.00055C3.16549 3.33085 5.32971 1.16663 7.99941 1.16663C10.6691 1.16663 12.8333 3.33085 12.8333 6.00055C12.8333 7.56219 12.0928 8.95086 10.9438 9.83459C10.7019 10.0206 10.4419 10.1843 10.1669 10.3225M5.83196 10.3225H10.1669M6.5 14.1666H9.5"
+        stroke="currentColor"
+        stroke-linecap="round"
+        stroke-linejoin="round"
+      />
+      <circle
+        cx="8"
+        cy="5.83325"
+        r="2.86364"
+        fill="currentColor"
+        stroke="currentColor"
+        stroke-width={strokeWidth()}
+        style={{ "--reasoning-icon-percentage": split.percentage / 100 }}
+        data-slot="reasoning-icon-percentage"
+      />
     </svg>
     </svg>
   )
   )
-}
+}

+ 1 - 1
packages/ui/src/components/select.tsx

@@ -176,4 +176,4 @@ export function Select<T>(props: SelectProps<T> & Omit<ButtonProps, "children">)
       </Kobalte.Portal>
       </Kobalte.Portal>
     </Kobalte>
     </Kobalte>
   )
   )
-}
+}