@glasshome/ui 1.30.0 → 1.31.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/SPEC.md CHANGED
@@ -191,6 +191,7 @@ role clears 4.5:1 against `--background`/`--card`/`--popover`/`--muted` (3:1 for
191
191
  | rows that belong to the row above them | `<FieldSubGroup>` | a bare `<Separator>` and a left pad |
192
192
  | picking one of a few described choices | `<OptionCardGroup>` + `<OptionCard>` | a hand-rolled `role="radio"` card list |
193
193
  | picking one of a few results you can see (pictures, shapes, previews) | `<PreviewTileGroup>` + `<PreviewTile>` | a grid of `aria-pressed` buttons by hand |
194
+ | where a catalog item comes from (official, community, built in) | `<SourceMarks official builtIn>`, in a tile through `<PreviewTile marks>` | a `badge-check` icon or a "Built in" byline by hand |
194
195
  | one colour out of a few | `<SwatchPicker>` (+ a picker as its child) | round buttons by hand |
195
196
  | an editor that leaves the page live behind it | `<DockedPanel>` + its Header, Body, Footer | a `<Sheet>` with its scrim hidden |
196
197
  | tabs above a stack of toggle groups | `<TabsTrigger icon>` | an `<Icon>` placed inside the trigger by hand |
@@ -98,4 +98,5 @@ export { ToggleGroup, ToggleGroupItem } from "./toggle-group.js";
98
98
  export { Tooltip, TooltipContent, TooltipTrigger } from "./tooltip.js";
99
99
  export { WidgetCard } from "./widget-card.js";
100
100
  export { formatWidgetCount, WidgetIdentity, WidgetMeta, type WidgetSummary, widgetHref, } from "./widget-identity.js";
101
+ export { SourceMarks } from "./source-marks.js";
101
102
  export { WidgetTrustBadge } from "./widget-trust-badge.js";
@@ -18333,14 +18333,14 @@ var _O = /*#__PURE__*/ K("<span data-slot=password-input-leading aria-hidden=tru
18333
18333
  Ft(["click"]);
18334
18334
  //#endregion
18335
18335
  //#region src/solid/preview-tile.tsx
18336
- var CO = /*#__PURE__*/ K("<div data-slot=preview-tile-face>"), wO = /*#__PURE__*/ K("<span data-slot=preview-tile-caption class=\"text-foreground flex min-w-0 items-center gap-1 text-xs font-medium\"><span class=truncate>"), TO = /*#__PURE__*/ K("<span data-slot=preview-tile-meta class=\"text-muted-foreground -mt-1 truncate text-[11px] leading-tight\">"), EO = /*#__PURE__*/ K("<span class=sr-only>"), DO = {
18336
+ var CO = /*#__PURE__*/ K("<div data-slot=preview-tile-face>"), wO = /*#__PURE__*/ K("<span data-slot=preview-tile-caption class=\"text-foreground @container/source-marks flex min-w-0 items-center gap-1 text-xs font-medium\"><span class=truncate>"), TO = /*#__PURE__*/ K("<span data-slot=preview-tile-meta class=\"text-muted-foreground -mt-1 truncate text-[11px] leading-tight\">"), EO = /*#__PURE__*/ K("<span class=sr-only>"), DO = {
18337
18337
  2: "grid-cols-2",
18338
18338
  3: "grid-cols-3",
18339
18339
  4: "grid-cols-4"
18340
18340
  }, OO = {
18341
18341
  wide: "aspect-[16/10]",
18342
18342
  tile: "aspect-[5/4]"
18343
- }, kO = "relative w-full overflow-hidden rounded-lg border border-border/60 transition-glass duration-200 group-active/preview-tile:scale-[0.97] group-data-[checked]/preview-tile:border-transparent group-data-[checked]/preview-tile:ring-2 group-data-[checked]/preview-tile:ring-primary group-data-[checked]/preview-tile:ring-offset-2 group-data-[checked]/preview-tile:ring-offset-transparent group-has-[:focus-visible]/preview-tile:ring-[3px] group-has-[:focus-visible]/preview-tile:ring-ring/50";
18343
+ }, kO = "relative w-full overflow-hidden rounded-lg border border-border/60 transition-glass duration-200 group-active/preview-tile:scale-[0.97] group-data-[checked]/preview-tile:border-transparent after:pointer-events-none after:absolute after:inset-0 after:z-10 after:rounded-[inherit] after:ring-inset after:transition-glass group-data-[checked]/preview-tile:after:ring-2 group-data-[checked]/preview-tile:after:ring-primary group-has-[:focus-visible]/preview-tile:after:ring-[3px] group-has-[:focus-visible]/preview-tile:after:ring-ring/50";
18344
18344
  function AO(e) {
18345
18345
  return z(XD, {
18346
18346
  "data-slot": "preview-tile-group",
@@ -18373,7 +18373,7 @@ function jO(e) {
18373
18373
  showControl: !1,
18374
18374
  onClick: () => !e.disabled && e.onPick?.(),
18375
18375
  get class() {
18376
- return O("group/preview-tile min-w-0 [&_[data-slot=radio-group-item-content]]:flex [&_[data-slot=radio-group-item-content]]:flex-col [&_[data-slot=radio-group-item-content]]:gap-1.5", e.class);
18376
+ return O("group/preview-tile min-w-0 [&_[data-slot=radio-group-item-content]]:flex [&_[data-slot=radio-group-item-content]]:flex-col [&_[data-slot=radio-group-item-content]]:gap-1.5 [&_[data-slot=radio-group-item-label]]:min-w-0", e.class);
18377
18377
  },
18378
18378
  get children() {
18379
18379
  return [(() => {
@@ -18405,7 +18405,7 @@ function jO(e) {
18405
18405
  "aria-hidden": "true",
18406
18406
  class: "shrink-0"
18407
18407
  })
18408
- }), n), V(n, () => e.label), t;
18408
+ }), n), V(n, () => e.label), V(t, () => e.marks, null), t;
18409
18409
  })(), z(k, {
18410
18410
  get when() {
18411
18411
  return e.meta;
@@ -21091,4 +21091,26 @@ function Hj(e) {
21091
21091
  });
21092
21092
  }
21093
21093
  //#endregion
21094
- export { za as Accordion, Ha as AccordionContent, Ba as AccordionItem, Va as AccordionTrigger, Xa as Alert, Qa as AlertDescription, zs as AlertDialog, Xs as AlertDialogAction, Ws as AlertDialogBody, Zs as AlertDialogCancel, Hs as AlertDialogContent, qs as AlertDialogDescription, Gs as AlertDialogFooter, Us as AlertDialogHeader, Ks as AlertDialogTitle, Bs as AlertDialogTrigger, Za as AlertTitle, Ih as AreaChart, Ld as AreaPicker, zd as AspectRatio, Kd as Avatar, Jd as AvatarFallback, qd as AvatarImage, $d as Badge, Lh as BarList, Ef as BottomSheet, Nf as BottomSheetBody, Lf as BottomSheetClose, Af as BottomSheetContent, If as BottomSheetDescription, Pf as BottomSheetFooter, jf as BottomSheetHandle, Mf as BottomSheetHeader, kf as BottomSheetOverlay, Of as BottomSheetPortal, Ff as BottomSheetTitle, Df as BottomSheetTrigger, Wf as Breadcrumb, Xf as BreadcrumbEllipsis, Kf as BreadcrumbItem, qf as BreadcrumbLink, Gf as BreadcrumbList, Jf as BreadcrumbPage, Yf as BreadcrumbSeparator, Qf as Button, ip as ButtonGroup, op as ButtonGroupSeparator, ap as ButtonGroupText, $f as ButtonWell, gp as Card, bp as CardAction, xp as CardContent, yp as CardDescription, Sp as CardFooter, _p as CardHeader, vp as CardTitle, Lm as Carousel, Rm as CarouselContent, Bm as CarouselDots, zm as CarouselItem, Hm as CarouselNext, Vm as CarouselPrevious, kc as Checkbox, Uh as Collapsible, Gh as CollapsibleContent, Wh as CollapsibleTrigger, Qh as ColorDisc, Dg as ColorSlider, Kg as ColorWheel, sv as ContextMenu, gv as ContextMenuCheckboxItem, mv as ContextMenuContent, cv as ContextMenuGroup, hv as ContextMenuItem, vv as ContextMenuLabel, uv as ContextMenuRadioGroup, _v as ContextMenuRadioItem, yv as ContextMenuSeparator, bv as ContextMenuShortcut, lv as ContextMenuSub, pv as ContextMenuSubContent, fv as ContextMenuSubTrigger, dv as ContextMenuTrigger, zy as CopyButton, By as CountPill, Yy as DashboardPreview, Vx as DataTableHead, Bx as DataTableRow, eS as Dialog, sS as DialogBody, rS as DialogClose, aS as DialogContent, uS as DialogDescription, cS as DialogFooter, oS as DialogHeader, lS as DialogTitle, tS as DialogTrigger, RS as Dock, HS as DockedPanel, WS as DockedPanelBody, GS as DockedPanelFooter, US as DockedPanelHeader, qS as DropdownMenu, nC as DropdownMenuCheckboxItem, QS as DropdownMenuContent, JS as DropdownMenuGroup, $S as DropdownMenuItem, aC as DropdownMenuLabel, XS as DropdownMenuRadioGroup, rC as DropdownMenuRadioItem, iC as DropdownMenuSeparator, oC as DropdownMenuShortcut, YS as DropdownMenuSub, tC as DropdownMenuSubContent, eC as DropdownMenuSubTrigger, ZS as DropdownMenuTrigger, ib as Empty, ub as EmptyContent, lb as EmptyDescription, ab as EmptyHeader, sb as EmptyMedia, cb as EmptyTitle, Qs as EntityDataContext, MC as EntitySelector, rE as FactRow, QC as Field, $C as FieldContent, nw as FieldDescription, aw as FieldError, XC as FieldGroup, ew as FieldLabel, YC as FieldLegend, iw as FieldSeparator, JC as FieldSet, rw as FieldSubGroup, tw as FieldTitle, dw as Form, vw as FormControl, yw as FormDescription, pw as FormField, mw as FormItem, hw as FormLabel, bw as FormMessage, jy as GlassToast, T as HOLD_GRACE_MS, Le as HOLD_MS, Dw as HeroAction, dO as HeroOption, Rw as HoverCard, Bw as HoverCardContent, zw as HoverCardTrigger, $ as Icon, Xw as IconPicker, TE as ImagePicker, fb as Input, NE as InputGroup, FE as InputGroupAddon, zE as InputGroupButton, VE as InputGroupInput, BE as InputGroupText, HE as InputGroupTextarea, YE as InputOTP, XE as InputOTPGroup, QE as InputOTPSeparator, ZE as InputOTPSlot, uD as Item, gD as ItemActions, pD as ItemContent, hD as ItemDescription, vD as ItemFooter, sD as ItemGroup, _D as ItemHeader, fD as ItemMedia, cD as ItemSeparator, mD as ItemTitle, xD as Kbd, SD as KbdGroup, PC as Label, NA as LabeledField, PA as LabeledIconPicker, FA as LabeledInput, iE as ListRow, AD as Logo, nT as MEDIA_PAGE_SIZE, Qw as MediaStoreContext, Zw as MediaStoreError, vT as MediaTile, eE as NOOP_GLASS, PD as NumberField, ie as OVERLAY_SURFACE, lO as OptionCard, cO as OptionCardGroup, sO as OptionChoice, Wm as Overlay, Ic as PICKER_ROW_HEIGHT, gO as PageHeader, ET as Pagination, DT as PaginationContent, MT as PaginationEllipsis, OT as PaginationItem, kT as PaginationLink, jT as PaginationNext, AT as PaginationPrevious, SO as PasswordInput, Lc as PickerRow, Vc as PickerSearch, Gc as PickerTrigger, vd as Popover, xd as PopoverAnchor, bd as PopoverContent, yd as PopoverTrigger, jO as PreviewTile, AO as PreviewTileGroup, JO as Progress, re as RISE_MOTION, XD as RadioGroup, ZD as RadioGroupItem, zh as RangeToggle, nk as ResizableHandle, tk as ResizablePanel, ek as ResizablePanelGroup, ak as ResponsiveDialog, lk as ResponsiveDialogBody, pk as ResponsiveDialogClose, sk as ResponsiveDialogContent, fk as ResponsiveDialogDescription, uk as ResponsiveDialogFooter, ck as ResponsiveDialogHeader, dk as ResponsiveDialogTitle, ok as ResponsiveDialogTrigger, MA as RowActions, qk as SCHEMA_FORM_FORM_TYPES, rt as SECTION_INNER_RADIUS, we as SECTION_OUTER_RADIUS, Oe as SECTION_PADDING, Je as SECTION_ROW_CLASS, Re as SECTION_ROW_SURFACE, a as SETTLE_MOTION, dA as SchemaForm, CA as ScopeIndicator, TA as ScrollArea, EA as ScrollBar, AA as SectionAddButton, tE as SectionCard, jA as SectionEmpty, dE as SectionGroup, sE as SectionIcon, fE as SectionLabel, pE as SectionMeta, nE as SectionRow, mE as SectionRowSkeleton, hE as SectionRowSkeletons, uE as SectionSubtitle, cE as SectionTitle, Kb as Select, Yb as SelectContent, Qb as SelectGroup, Zb as SelectItem, Xb as SelectLabel, $b as SelectSeparator, Jb as SelectTrigger, qb as SelectValue, tp as Separator, RA as Sheet, YA as SheetBody, VA as SheetClose, qA as SheetContent, QA as SheetDescription, XA as SheetFooter, JA as SheetHeader, ZA as SheetTitle, zA as SheetTrigger, tx as Skeleton, ej as Slider, kd as SlidingIndicator, by as Spinner, gj as Spotlight, Hh as StackedBar, yj as StepIndicator, Sj as SwatchPicker, gk as Switch, IA as SwitchRow, Mx as TABLE_BLEED, ux as TABLE_CELL_INSET, Nx as TABLE_CELL_X, fx as TABLE_HEAD_CELL_CLASS, Fx as TABLE_HEAD_CLASS, dx as TABLE_HEAD_LABEL_CLASS, Lx as TABLE_NUM_CELL_CLASS, Px as TABLE_ROW_CLASS, Ix as TABLE_SCROLL_CLASS, h as TRAVEL_MOTION, px as Table, hx as TableBody, Xx as TableBulkBar, bx as TableCaption, yx as TableCell, Ux as TableEmpty, Wx as TableError, Rx as TableFilterSelect, gx as TableFooter, vx as TableHead, mx as TableHeader, Gx as TableLoadMore, _x as TableRow, zx as TableSearchInput, Yx as TableSkeleton, Hx as TableSortHeader, sh as Tabs, uh as TabsContent, ch as TabsList, lh as TabsTrigger, eg as TemperatureBar, wj as Textarea, ef as TierBadge, Iy as Toaster, Ok as Toggle, Ak as ToggleGroup, jk as ToggleGroupItem, kS as Tooltip, jS as TooltipContent, AS as TooltipTrigger, Bj as WidgetCard, Ij as WidgetIdentity, Lj as WidgetMeta, Dj as WidgetTrustBadge, rp as buttonGroupVariants, Xe as buttonVariants, He as copyImage, Ne as copyText, aT as createBrokenMedia, ED as createListReorder, Kx as createTableWindow, TD as dragTargetIndex, Mh as formatBytes, Ah as formatCompact, Fj as formatWidgetCount, cT as imagePreset, uT as imageUrl, rT as isMediaImage, $h as kelvinToCss, mT as mediaIndexErrorCopy, pT as mediaStoreErrorCopy, lT as mediaUrl, Mr as parseColor, sT as presetValue, ec as provideEntityData, Aa as provideIcons, eT as provideMediaStore, iT as sortMediaForClearing, n as spendLongPress, fT as toMediaStoreError, Fy as toast, Ek as toggleVariants, Ly as useCopyText, tc as useEntityData, fw as useFormField, tT as useMediaStore, Pj as widgetHref };
21094
+ //#region src/solid/source-marks.tsx
21095
+ var Uj = /*#__PURE__*/ K("<span data-slot=source-marks>");
21096
+ function Wj(e) {
21097
+ return (() => {
21098
+ var t = Uj();
21099
+ return V(t, z(Dj, { get isOfficial() {
21100
+ return e.official;
21101
+ } }), null), V(t, z(k, {
21102
+ get when() {
21103
+ return e.builtIn;
21104
+ },
21105
+ get children() {
21106
+ return z($d, {
21107
+ tone: "var(--muted-foreground)",
21108
+ class: "@max-[12rem]/source-marks:hidden",
21109
+ children: "Built in"
21110
+ });
21111
+ }
21112
+ }), null), B(() => R(t, O("inline-flex shrink-0 items-center gap-1.5", e.class))), t;
21113
+ })();
21114
+ }
21115
+ //#endregion
21116
+ export { za as Accordion, Ha as AccordionContent, Ba as AccordionItem, Va as AccordionTrigger, Xa as Alert, Qa as AlertDescription, zs as AlertDialog, Xs as AlertDialogAction, Ws as AlertDialogBody, Zs as AlertDialogCancel, Hs as AlertDialogContent, qs as AlertDialogDescription, Gs as AlertDialogFooter, Us as AlertDialogHeader, Ks as AlertDialogTitle, Bs as AlertDialogTrigger, Za as AlertTitle, Ih as AreaChart, Ld as AreaPicker, zd as AspectRatio, Kd as Avatar, Jd as AvatarFallback, qd as AvatarImage, $d as Badge, Lh as BarList, Ef as BottomSheet, Nf as BottomSheetBody, Lf as BottomSheetClose, Af as BottomSheetContent, If as BottomSheetDescription, Pf as BottomSheetFooter, jf as BottomSheetHandle, Mf as BottomSheetHeader, kf as BottomSheetOverlay, Of as BottomSheetPortal, Ff as BottomSheetTitle, Df as BottomSheetTrigger, Wf as Breadcrumb, Xf as BreadcrumbEllipsis, Kf as BreadcrumbItem, qf as BreadcrumbLink, Gf as BreadcrumbList, Jf as BreadcrumbPage, Yf as BreadcrumbSeparator, Qf as Button, ip as ButtonGroup, op as ButtonGroupSeparator, ap as ButtonGroupText, $f as ButtonWell, gp as Card, bp as CardAction, xp as CardContent, yp as CardDescription, Sp as CardFooter, _p as CardHeader, vp as CardTitle, Lm as Carousel, Rm as CarouselContent, Bm as CarouselDots, zm as CarouselItem, Hm as CarouselNext, Vm as CarouselPrevious, kc as Checkbox, Uh as Collapsible, Gh as CollapsibleContent, Wh as CollapsibleTrigger, Qh as ColorDisc, Dg as ColorSlider, Kg as ColorWheel, sv as ContextMenu, gv as ContextMenuCheckboxItem, mv as ContextMenuContent, cv as ContextMenuGroup, hv as ContextMenuItem, vv as ContextMenuLabel, uv as ContextMenuRadioGroup, _v as ContextMenuRadioItem, yv as ContextMenuSeparator, bv as ContextMenuShortcut, lv as ContextMenuSub, pv as ContextMenuSubContent, fv as ContextMenuSubTrigger, dv as ContextMenuTrigger, zy as CopyButton, By as CountPill, Yy as DashboardPreview, Vx as DataTableHead, Bx as DataTableRow, eS as Dialog, sS as DialogBody, rS as DialogClose, aS as DialogContent, uS as DialogDescription, cS as DialogFooter, oS as DialogHeader, lS as DialogTitle, tS as DialogTrigger, RS as Dock, HS as DockedPanel, WS as DockedPanelBody, GS as DockedPanelFooter, US as DockedPanelHeader, qS as DropdownMenu, nC as DropdownMenuCheckboxItem, QS as DropdownMenuContent, JS as DropdownMenuGroup, $S as DropdownMenuItem, aC as DropdownMenuLabel, XS as DropdownMenuRadioGroup, rC as DropdownMenuRadioItem, iC as DropdownMenuSeparator, oC as DropdownMenuShortcut, YS as DropdownMenuSub, tC as DropdownMenuSubContent, eC as DropdownMenuSubTrigger, ZS as DropdownMenuTrigger, ib as Empty, ub as EmptyContent, lb as EmptyDescription, ab as EmptyHeader, sb as EmptyMedia, cb as EmptyTitle, Qs as EntityDataContext, MC as EntitySelector, rE as FactRow, QC as Field, $C as FieldContent, nw as FieldDescription, aw as FieldError, XC as FieldGroup, ew as FieldLabel, YC as FieldLegend, iw as FieldSeparator, JC as FieldSet, rw as FieldSubGroup, tw as FieldTitle, dw as Form, vw as FormControl, yw as FormDescription, pw as FormField, mw as FormItem, hw as FormLabel, bw as FormMessage, jy as GlassToast, T as HOLD_GRACE_MS, Le as HOLD_MS, Dw as HeroAction, dO as HeroOption, Rw as HoverCard, Bw as HoverCardContent, zw as HoverCardTrigger, $ as Icon, Xw as IconPicker, TE as ImagePicker, fb as Input, NE as InputGroup, FE as InputGroupAddon, zE as InputGroupButton, VE as InputGroupInput, BE as InputGroupText, HE as InputGroupTextarea, YE as InputOTP, XE as InputOTPGroup, QE as InputOTPSeparator, ZE as InputOTPSlot, uD as Item, gD as ItemActions, pD as ItemContent, hD as ItemDescription, vD as ItemFooter, sD as ItemGroup, _D as ItemHeader, fD as ItemMedia, cD as ItemSeparator, mD as ItemTitle, xD as Kbd, SD as KbdGroup, PC as Label, NA as LabeledField, PA as LabeledIconPicker, FA as LabeledInput, iE as ListRow, AD as Logo, nT as MEDIA_PAGE_SIZE, Qw as MediaStoreContext, Zw as MediaStoreError, vT as MediaTile, eE as NOOP_GLASS, PD as NumberField, ie as OVERLAY_SURFACE, lO as OptionCard, cO as OptionCardGroup, sO as OptionChoice, Wm as Overlay, Ic as PICKER_ROW_HEIGHT, gO as PageHeader, ET as Pagination, DT as PaginationContent, MT as PaginationEllipsis, OT as PaginationItem, kT as PaginationLink, jT as PaginationNext, AT as PaginationPrevious, SO as PasswordInput, Lc as PickerRow, Vc as PickerSearch, Gc as PickerTrigger, vd as Popover, xd as PopoverAnchor, bd as PopoverContent, yd as PopoverTrigger, jO as PreviewTile, AO as PreviewTileGroup, JO as Progress, re as RISE_MOTION, XD as RadioGroup, ZD as RadioGroupItem, zh as RangeToggle, nk as ResizableHandle, tk as ResizablePanel, ek as ResizablePanelGroup, ak as ResponsiveDialog, lk as ResponsiveDialogBody, pk as ResponsiveDialogClose, sk as ResponsiveDialogContent, fk as ResponsiveDialogDescription, uk as ResponsiveDialogFooter, ck as ResponsiveDialogHeader, dk as ResponsiveDialogTitle, ok as ResponsiveDialogTrigger, MA as RowActions, qk as SCHEMA_FORM_FORM_TYPES, rt as SECTION_INNER_RADIUS, we as SECTION_OUTER_RADIUS, Oe as SECTION_PADDING, Je as SECTION_ROW_CLASS, Re as SECTION_ROW_SURFACE, a as SETTLE_MOTION, dA as SchemaForm, CA as ScopeIndicator, TA as ScrollArea, EA as ScrollBar, AA as SectionAddButton, tE as SectionCard, jA as SectionEmpty, dE as SectionGroup, sE as SectionIcon, fE as SectionLabel, pE as SectionMeta, nE as SectionRow, mE as SectionRowSkeleton, hE as SectionRowSkeletons, uE as SectionSubtitle, cE as SectionTitle, Kb as Select, Yb as SelectContent, Qb as SelectGroup, Zb as SelectItem, Xb as SelectLabel, $b as SelectSeparator, Jb as SelectTrigger, qb as SelectValue, tp as Separator, RA as Sheet, YA as SheetBody, VA as SheetClose, qA as SheetContent, QA as SheetDescription, XA as SheetFooter, JA as SheetHeader, ZA as SheetTitle, zA as SheetTrigger, tx as Skeleton, ej as Slider, kd as SlidingIndicator, Wj as SourceMarks, by as Spinner, gj as Spotlight, Hh as StackedBar, yj as StepIndicator, Sj as SwatchPicker, gk as Switch, IA as SwitchRow, Mx as TABLE_BLEED, ux as TABLE_CELL_INSET, Nx as TABLE_CELL_X, fx as TABLE_HEAD_CELL_CLASS, Fx as TABLE_HEAD_CLASS, dx as TABLE_HEAD_LABEL_CLASS, Lx as TABLE_NUM_CELL_CLASS, Px as TABLE_ROW_CLASS, Ix as TABLE_SCROLL_CLASS, h as TRAVEL_MOTION, px as Table, hx as TableBody, Xx as TableBulkBar, bx as TableCaption, yx as TableCell, Ux as TableEmpty, Wx as TableError, Rx as TableFilterSelect, gx as TableFooter, vx as TableHead, mx as TableHeader, Gx as TableLoadMore, _x as TableRow, zx as TableSearchInput, Yx as TableSkeleton, Hx as TableSortHeader, sh as Tabs, uh as TabsContent, ch as TabsList, lh as TabsTrigger, eg as TemperatureBar, wj as Textarea, ef as TierBadge, Iy as Toaster, Ok as Toggle, Ak as ToggleGroup, jk as ToggleGroupItem, kS as Tooltip, jS as TooltipContent, AS as TooltipTrigger, Bj as WidgetCard, Ij as WidgetIdentity, Lj as WidgetMeta, Dj as WidgetTrustBadge, rp as buttonGroupVariants, Xe as buttonVariants, He as copyImage, Ne as copyText, aT as createBrokenMedia, ED as createListReorder, Kx as createTableWindow, TD as dragTargetIndex, Mh as formatBytes, Ah as formatCompact, Fj as formatWidgetCount, cT as imagePreset, uT as imageUrl, rT as isMediaImage, $h as kelvinToCss, mT as mediaIndexErrorCopy, pT as mediaStoreErrorCopy, lT as mediaUrl, Mr as parseColor, sT as presetValue, ec as provideEntityData, Aa as provideIcons, eT as provideMediaStore, iT as sortMediaForClearing, n as spendLongPress, fT as toMediaStoreError, Fy as toast, Ek as toggleVariants, Ly as useCopyText, tc as useEntityData, fw as useFormField, tT as useMediaStore, Pj as widgetHref };
@@ -25,6 +25,8 @@ export declare function PreviewTile(props: {
25
25
  /** Off for pictures that name themselves; the label still reaches assistive tech. */
26
26
  caption?: boolean;
27
27
  icon?: string;
28
+ /** Beside the caption, after the label: provenance like `SourceMarks`. */
29
+ marks?: JSX.Element;
28
30
  shape?: keyof typeof SHAPE;
29
31
  disabled?: boolean;
30
32
  class?: string;
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Where a catalog item comes from: the official or community mark, plus Built in when it ships with GlassHome.
3
+ * Inside an `@container/source-marks` narrower than 12rem, Built in steps aside so the name keeps its room.
4
+ */
5
+ export declare function SourceMarks(props: {
6
+ official: boolean;
7
+ builtIn?: boolean;
8
+ class?: string;
9
+ }): import("solid-js").JSX.Element;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@glasshome/ui",
3
- "version": "1.30.0",
3
+ "version": "1.31.0",
4
4
  "description": "SolidJS component library for GlassHome, built on Kobalte",
5
5
  "keywords": [
6
6
  "components",
@@ -399,4 +399,5 @@ export {
399
399
  type WidgetSummary,
400
400
  widgetHref,
401
401
  } from "./widget-identity.js";
402
+ export { SourceMarks } from "./source-marks.js";
402
403
  export { WidgetTrustBadge } from "./widget-trust-badge.js";
@@ -9,9 +9,10 @@ const COLUMNS = { 2: "grid-cols-2", 3: "grid-cols-3", 4: "grid-cols-4" } as cons
9
9
  const SHAPE = { wide: "aspect-[16/10]", tile: "aspect-[5/4]" } as const;
10
10
 
11
11
  /* The face is the affordance: the radio control is suppressed and a ring on
12
- * the face carries the picked state, the focus ring rides the same edge. */
12
+ * the face carries the picked state, the focus ring rides the same edge.
13
+ * Rings are drawn inside the face, above the picture: an outer ring is cut off where a scroll area clips the grid. */
13
14
  const TILE_FACE =
14
- "relative w-full overflow-hidden rounded-lg border border-border/60 transition-glass duration-200 group-active/preview-tile:scale-[0.97] group-data-[checked]/preview-tile:border-transparent group-data-[checked]/preview-tile:ring-2 group-data-[checked]/preview-tile:ring-primary group-data-[checked]/preview-tile:ring-offset-2 group-data-[checked]/preview-tile:ring-offset-transparent group-has-[:focus-visible]/preview-tile:ring-[3px] group-has-[:focus-visible]/preview-tile:ring-ring/50";
15
+ "relative w-full overflow-hidden rounded-lg border border-border/60 transition-glass duration-200 group-active/preview-tile:scale-[0.97] group-data-[checked]/preview-tile:border-transparent after:pointer-events-none after:absolute after:inset-0 after:z-10 after:rounded-[inherit] after:ring-inset after:transition-glass group-data-[checked]/preview-tile:after:ring-2 group-data-[checked]/preview-tile:after:ring-primary group-has-[:focus-visible]/preview-tile:after:ring-[3px] group-has-[:focus-visible]/preview-tile:after:ring-ring/50";
15
16
 
16
17
  export function PreviewTileGroup(props: {
17
18
  value: string | null;
@@ -43,6 +44,8 @@ export function PreviewTile(props: {
43
44
  /** Off for pictures that name themselves; the label still reaches assistive tech. */
44
45
  caption?: boolean;
45
46
  icon?: string;
47
+ /** Beside the caption, after the label: provenance like `SourceMarks`. */
48
+ marks?: JSX.Element;
46
49
  shape?: keyof typeof SHAPE;
47
50
  disabled?: boolean;
48
51
  class?: string;
@@ -58,7 +61,7 @@ export function PreviewTile(props: {
58
61
  showControl={false}
59
62
  onClick={() => !props.disabled && props.onPick?.()}
60
63
  class={cn(
61
- "group/preview-tile min-w-0 [&_[data-slot=radio-group-item-content]]:flex [&_[data-slot=radio-group-item-content]]:flex-col [&_[data-slot=radio-group-item-content]]:gap-1.5",
64
+ "group/preview-tile min-w-0 [&_[data-slot=radio-group-item-content]]:flex [&_[data-slot=radio-group-item-content]]:flex-col [&_[data-slot=radio-group-item-content]]:gap-1.5 [&_[data-slot=radio-group-item-label]]:min-w-0",
62
65
  props.class,
63
66
  )}
64
67
  >
@@ -68,7 +71,7 @@ export function PreviewTile(props: {
68
71
  <Show when={props.caption ?? true} fallback={<span class="sr-only">{props.label}</span>}>
69
72
  <span
70
73
  data-slot="preview-tile-caption"
71
- class="text-foreground flex min-w-0 items-center gap-1 text-xs font-medium"
74
+ class="text-foreground @container/source-marks flex min-w-0 items-center gap-1 text-xs font-medium"
72
75
  >
73
76
  <Show when={props.icon}>
74
77
  {(icon) => (
@@ -76,6 +79,7 @@ export function PreviewTile(props: {
76
79
  )}
77
80
  </Show>
78
81
  <span class="truncate">{props.label}</span>
82
+ {props.marks}
79
83
  </span>
80
84
  <Show when={props.meta}>
81
85
  <span
@@ -0,0 +1,24 @@
1
+ import { Show } from "solid-js";
2
+ import { cn } from "../lib/utils.js";
3
+ import { Badge } from "./badge.js";
4
+ import { WidgetTrustBadge } from "./widget-trust-badge.js";
5
+
6
+ /**
7
+ * Where a catalog item comes from: the official or community mark, plus Built in when it ships with GlassHome.
8
+ * Inside an `@container/source-marks` narrower than 12rem, Built in steps aside so the name keeps its room.
9
+ */
10
+ export function SourceMarks(props: { official: boolean; builtIn?: boolean; class?: string }) {
11
+ return (
12
+ <span
13
+ data-slot="source-marks"
14
+ class={cn("inline-flex shrink-0 items-center gap-1.5", props.class)}
15
+ >
16
+ <WidgetTrustBadge isOfficial={props.official} />
17
+ <Show when={props.builtIn}>
18
+ <Badge tone="var(--muted-foreground)" class="@max-[12rem]/source-marks:hidden">
19
+ Built in
20
+ </Badge>
21
+ </Show>
22
+ </span>
23
+ );
24
+ }