summaryrefslogtreecommitdiffhomepage
path: root/packages/ui/src/components
diff options
context:
space:
mode:
authorAdam <[email protected]>2026-01-06 08:18:17 -0600
committerAdam <[email protected]>2026-01-06 08:19:17 -0600
commitb88bcd49fdea0955f2efc8f09a3614c188d22107 (patch)
tree8ab04d7a9d2b892cd884eab5ab3bb5da9187191a /packages/ui/src/components
parent3f463bc9168abd907be9ae582e161ff89c3a27c9 (diff)
downloadopencode-b88bcd49fdea0955f2efc8f09a3614c188d22107.tar.gz
opencode-b88bcd49fdea0955f2efc8f09a3614c188d22107.zip
fix(app): code splitting for web load perf gains
Diffstat (limited to 'packages/ui/src/components')
-rw-r--r--packages/ui/src/components/list.tsx5
-rw-r--r--packages/ui/src/components/markdown.tsx3
2 files changed, 5 insertions, 3 deletions
diff --git a/packages/ui/src/components/list.tsx b/packages/ui/src/components/list.tsx
index b94405c81..60161f6dc 100644
--- a/packages/ui/src/components/list.tsx
+++ b/packages/ui/src/components/list.tsx
@@ -175,12 +175,13 @@ export function List<T>(props: ListProps<T> & { ref?: (ref: ListRef) => void })
fallback={
<div data-slot="list-empty-state">
<div data-slot="list-message">
- {props.emptyMessage ?? "No results"} for <span data-slot="list-filter">&quot;{filter()}&quot;</span>
+ {props.emptyMessage ?? (grouped.loading ? "Loading" : "No results")} for{" "}
+ <span data-slot="list-filter">&quot;{filter()}&quot;</span>
</div>
</div>
}
>
- <For each={grouped()}>
+ <For each={grouped.latest}>
{(group) => (
<div data-slot="list-group">
<Show when={group.category}>
diff --git a/packages/ui/src/components/markdown.tsx b/packages/ui/src/components/markdown.tsx
index 7615d1737..6e40b700a 100644
--- a/packages/ui/src/components/markdown.tsx
+++ b/packages/ui/src/components/markdown.tsx
@@ -15,6 +15,7 @@ export function Markdown(
async (markdown) => {
return marked.parse(markdown)
},
+ { initialValue: "" },
)
return (
<div
@@ -23,7 +24,7 @@ export function Markdown(
...(local.classList ?? {}),
[local.class ?? ""]: !!local.class,
}}
- innerHTML={html()}
+ innerHTML={html.latest}
{...others}
/>
)