@softure-ai/theme-notion 0.4.0 → 0.5.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/CHANGELOG.md CHANGED
@@ -4,6 +4,26 @@ Newest first. Each version lists what changed for an app that uses the theme. Wh
4
4
  production, the version gets a line `verified in: <app>@<commit>` ([docs/05](../../docs/05-adoption-playbook.md),
5
5
  "Definition of done").
6
6
 
7
+ ## 0.5.0
8
+
9
+ - Needs `@softure-ai/theme-kit` `^0.1.4` (was `^0.1.3`): the version whose `softure-theme-css` writes `preflight.css`
10
+ and the stylesheet re-exports (#795).
11
+ - `Command` (#809): `CommandDialog` passes its `title` to cmdk's `label`, so the palette's combobox is named by the
12
+ dialog's title (it had an empty name: cmdk's `aria-labelledby` points at its hidden label and wins over an
13
+ `aria-label` on `CommandInput`). A bare `Command` needs `label` from the app. `CommandInput` takes `children`,
14
+ rendered after the input inside the input row (a `Kbd` "Esc" sits at its right end with no positioning), and
15
+ `wrapperClassName`, merged into the row's classes (`h-12` for the 48 px row). An app drops its absolutely
16
+ positioned `Kbd` beside `CommandInput` and its parent selector on `data-slot=command-input-wrapper`; a `label` it
17
+ set on `Command` keeps working. Without the new props the classes are unchanged.
18
+ - `StatCards` (#813): a card takes an optional `icon` (a Lucide icon component, e.g. `icon: Wallet`), drawn before the
19
+ label at 16 px with `ICON_STROKE_WIDTH` in the label's muted colour, 6 px apart, `aria-hidden`. An app that rebuilt
20
+ the card from `Card` to show the icon goes back to `StatCards`. A card without `icon` renders as before.
21
+ - `base.css`, `preflight.css`, `maplibre.css` (#795): the kit's page stylesheets, exported by the theme as
22
+ `@softure-ai/theme-notion/<name>.css`. Each is one `@import` of the kit's file, resolved from the theme's own dependency,
23
+ so the app gets the kit version the theme was built against and needs no `@softure-ai/theme-kit` of its own. An app
24
+ replaces `@softure-ai/theme-kit/` with `@softure-ai/theme-notion/` in its `globals.css` and drops a direct
25
+ `@softure-ai/theme-kit` dependency it kept only for the CSS. The old imports keep working while the kit is hoisted.
26
+
7
27
  ## 0.4.0
8
28
 
9
29
  - Server Components (#770): the package root imports from a React Server Component again. 0.3.0's `ui/item.tsx`
package/README.md CHANGED
@@ -16,11 +16,16 @@ npm i @softure-ai/theme-notion tailwindcss @tailwindcss/postcss
16
16
  @import "tailwindcss";
17
17
  @import "@softure-ai/theme-notion/theme.css"; /* tokens, utilities, dark:, animations, the components' classes */
18
18
  @import "@softure-ai/theme-notion/sft-bridge.css"; /* optional: pages of the SOFTURE packages in a PageFrame */
19
- @import "@softure-ai/theme-kit/base.css"; /* body on the theme's background, text colour and font */
19
+ @import "@softure-ai/theme-notion/base.css"; /* body on the theme's background, text colour and font */
20
20
  @import "@softure-ai/theme-notion/page.css"; /* body text 14 px, blue text selection, font smoothing */
21
- @import "@softure-ai/theme-kit/maplibre.css"; /* only if the app shows MapLibre maps */
21
+ @import "@softure-ai/theme-notion/maplibre.css"; /* only if the app shows MapLibre maps */
22
22
  ```
23
23
 
24
+ Every stylesheet comes from the theme. `base.css`, `maplibre.css` and `preflight.css` are the kit's
25
+ ([`@softure-ai/theme-kit`](../theme-kit/README.md)), re-exported by the theme: they resolve the kit from the theme's own
26
+ dependency, so the app declares only the theme and gets the kit version the theme was built against, in any package
27
+ manager layout.
28
+
24
29
  `theme.css` names the package's components as Tailwind sources, so their classes are generated without the app
25
30
  listing `node_modules`. It clears Tailwind's default palette: only the theme's colours exist as utilities.
26
31
 
@@ -31,13 +36,13 @@ taking the scoped preflight instead of Tailwind's:
31
36
  @import "@softure-ai/ui/styles.css"; /* first: it declares the layer order */
32
37
  @layer theme, base, components, utilities;
33
38
  @import "tailwindcss/theme.css" layer(theme);
34
- @import "@softure-ai/theme-kit/preflight.css"; /* Tailwind's preflight, only inside [data-slot] elements */
39
+ @import "@softure-ai/theme-notion/preflight.css"; /* Tailwind's preflight, only inside [data-slot] elements */
35
40
  @import "tailwindcss/utilities.css" layer(utilities);
36
41
  @import "@softure-ai/theme-notion/theme.css";
37
42
  @import "@softure-ai/theme-notion/sft-bridge.css";
38
- @import "@softure-ai/theme-kit/base.css"; /* nothing else styles body under the scoped preflight */
43
+ @import "@softure-ai/theme-notion/base.css"; /* nothing else styles body under the scoped preflight */
39
44
  @import "@softure-ai/theme-notion/page.css";
40
- @import "@softure-ai/theme-kit/maplibre.css"; /* only if the app shows MapLibre maps */
45
+ @import "@softure-ai/theme-notion/maplibre.css"; /* only if the app shows MapLibre maps */
41
46
  ```
42
47
 
43
48
  `base.css` gives `body` the theme's background, text colour and sans font without the browser's 8 px margin, so a
@@ -71,7 +76,8 @@ import { CircleCheck } from "lucide-react";
71
76
  wording by props: `Breadcrumb aria-label`, `BreadcrumbEllipsis label`, `PageHeader crumbsLabel`,
72
77
  `DialogContent closeLabel`, `SheetContent closeLabel`, `SidePanel closeLabel`, `Steps stateLabels`,
73
78
  `Sidebar mobileTitle mobileDescription`, `SidebarTrigger label`, `SidebarRail label`, `Spinner aria-label`,
74
- `CommandDialog title description`, `SortableList instructions announcements`, `SortableHandle label`.
79
+ `CommandDialog title description` (`title` also names its search field), `Command label` (the search field's
80
+ name outside a `CommandDialog`; without it the field has none), `SortableList instructions announcements`, `SortableHandle label`.
75
81
 
76
82
  ## Rules, in short
77
83
 
@@ -161,14 +167,15 @@ A screen's summary figures: `StatsFold` (figures folded under a heading, closed
161
167
  optional `hint`, optional `aside` tag; `isFullWidth` and `isOneRow` change the grid) and `StatPills` ("label **value**" tags in one row). Each figure takes a
162
168
  `tone`; the app keeps only its own table of which meaning takes which tone. A card's `progress` (0–100, clamped) draws
163
169
  the package's 6 px `Progress` under the figure, filled in the card's tone (primary without one) and named by
164
- `progressLabel` (default: the card's `label`).
170
+ `progressLabel` (default: the card's `label`). A card's `icon` (a Lucide icon component) is drawn before the label: 16 px,
171
+ `ICON_STROKE_WIDTH`, the label's muted colour, 6 px apart, `aria-hidden` (the label stays the card's text).
165
172
 
166
173
  ```tsx
167
174
  <StatsFold title="Summary">
168
175
  <StatCards
169
176
  label="Totals"
170
177
  cards={[
171
- { key: "paid", label: "Paid", value: "1,200", tone: "success" },
178
+ { key: "paid", label: "Paid", value: "1,200", tone: "success", icon: Wallet },
172
179
  { key: "owed", label: "Owed", value: "300", tone: "danger", hint: "2 invoices", aside: { text: "+5%" } },
173
180
  { key: "hours", label: "Hours", value: "21.5 / 23.4 h", progress: 92, progressLabel: "Hours used" },
174
181
  ]}
@@ -291,6 +298,19 @@ Deltas from stock shadcn:
291
298
  Notion callout).
292
299
  - `input`, `textarea`, `select`, `input-group`: 28 px high, grey `field` background, thin `input` border.
293
300
  - `dropdown-menu`, `select`, `popover`, `command`: radius 10, `shadow-menu` without a border, 28 px items.
301
+ - `command`: `CommandDialog` passes its `title` to cmdk's `label`, the search field's accessible name (cmdk's
302
+ `aria-labelledby` wins over an `aria-label` on `CommandInput`). `CommandInput` renders its `children` at the end of
303
+ the input row and merges `wrapperClassName` into the row:
304
+
305
+ ```tsx
306
+ <CommandDialog open={open} onOpenChange={setOpen} title="Search pages">
307
+ <CommandInput placeholder="Search…" wrapperClassName="h-12">
308
+ <Kbd>Esc</Kbd>
309
+ </CommandInput>
310
+ <CommandList>…</CommandList>
311
+ </CommandDialog>
312
+ ```
313
+
294
314
  - `dialog`, `alert-dialog`: radius 10, `shadow-dialog`, no border. `card`: `shadow-card` instead of a border.
295
315
  - `checkbox` 16 px with a 1.5 px border, `radio-group` drawn the same (round, a `primary` dot), `switch` 26 × 16
296
316
  (thumb shadow in `SWITCH_THUMB_SHADOW_CLASS`, for a native switch drawn the same), `tooltip` dark without an arrow,
package/dist/base.css ADDED
@@ -0,0 +1,2 @@
1
+ /* The kit's base.css, resolved from this theme's own dependency on @softure-ai/theme-kit. */
2
+ @import "@softure-ai/theme-kit/base.css";
@@ -0,0 +1,2 @@
1
+ /* The kit's maplibre.css, resolved from this theme's own dependency on @softure-ai/theme-kit. */
2
+ @import "@softure-ai/theme-kit/maplibre.css";
@@ -1,3 +1,4 @@
1
+ import { type LucideIcon } from "lucide-react";
1
2
  import type { ReactNode } from "react";
2
3
  import { type Tone } from "./tones.js";
3
4
  export interface StatsFoldProps {
@@ -15,6 +16,8 @@ export interface StatCard {
15
16
  /** Unique within the row; kept as `data-stat`. */
16
17
  readonly key: string;
17
18
  readonly label: string;
19
+ /** A decorative icon before the label: 16 px, the design system's stroke, the label's muted colour. */
20
+ readonly icon?: LucideIcon;
18
21
  readonly value: string;
19
22
  readonly hint?: string;
20
23
  readonly tone?: Tone;
@@ -1 +1 @@
1
- {"version":3,"file":"Stats.d.ts","sourceRoot":"","sources":["../../src/notion/Stats.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAOvC,OAAO,EAAqC,KAAK,IAAI,EAAE,MAAM,YAAY,CAAC;AAE1E,MAAM,WAAW,cAAc;IAC7B,6BAA6B;IAC7B,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,QAAQ,EAAE,SAAS,CAAC;IAC7B,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;CAC7B;AAID,wBAAgB,SAAS,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAE,EAAE,cAAc,+BAmBvE;AAED,MAAM,WAAW,aAAa;IAC5B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,IAAI,CAAC,EAAE,IAAI,CAAC;CACtB;AAED,MAAM,WAAW,QAAQ;IACvB,kDAAkD;IAClD,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,IAAI,CAAC,EAAE,IAAI,CAAC;IACrB,QAAQ,CAAC,KAAK,CAAC,EAAE,aAAa,CAAC;IAC/B,wGAAwG;IACxG,Q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+BAsDhG;AAED,MAAM,WAAW,QAAQ;IACvB,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,IAAI,CAAC,EAAE,IAAI,CAAC;CACtB;AAED,MAAM,WAAW,cAAc;IAC7B,kCAAkC;IAClC,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,KAAK,EAAE,SAAS,QAAQ,EAAE,CAAC;CACrC;AAGD,wBAAgB,SAAS,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,EAAE,cAAc,+BAYzD"}
@@ -20,15 +20,20 @@ function getStatCardsLayout(isFullWidth, isOneRow) {
20
20
  return "row";
21
21
  return isFullWidth ? "full" : "grid";
22
22
  }
23
- // Summary figures as a row of cards wrapping on a narrow screen: the label, the figure in its tone's colour (never
24
- // broken, tabular numbers), an optional bar under it, an optional note and an optional short figure on its right as a
25
- // tag.
23
+ function StatCardLabel({ label, icon: Icon }) {
24
+ if (Icon === undefined)
25
+ return _jsx("div", { className: "text-section-label text-muted-foreground", children: label });
26
+ return (_jsxs("div", { className: "flex items-center gap-1.5 text-section-label text-muted-foreground", children: [_jsx(Icon, { "aria-hidden": "true", strokeWidth: ICON_STROKE_WIDTH, className: "size-4 shrink-0" }), label] }));
27
+ }
28
+ // Summary figures as a row of cards wrapping on a narrow screen: the label (after an optional icon), the figure in its
29
+ // tone's colour (never broken, tabular numbers), an optional bar under it, an optional note and an optional short
30
+ // figure on its right as a tag.
26
31
  export function StatCards({ label, cards, isFullWidth = false, isOneRow = false }) {
27
32
  return (_jsx("ul", { "aria-label": label, "data-slot": "stat-cards", "data-layout": getStatCardsLayout(isFullWidth, isOneRow), className: cn("grid gap-2", isFullWidth
28
33
  ? "grid-cols-[repeat(auto-fit,minmax(min(14rem,100%),1fr))]"
29
34
  : "grid-cols-[repeat(auto-fill,minmax(min(10rem,100%),1fr))]", isOneRow && "sm:auto-cols-fr sm:grid-flow-col sm:grid-cols-none"), children: cards.map((card) => {
30
35
  const tone = card.tone ?? "default";
31
- return (_jsxs("li", { "data-stat": card.key, className: "flex min-w-0 items-start justify-between gap-2 rounded-lg bg-card p-3 text-card-foreground shadow-card", children: [_jsxs("div", { className: cn("min-w-0", card.progress !== undefined && "flex-1"), children: [_jsx("div", { className: "text-section-label text-muted-foreground", children: card.label }), _jsx("div", { "data-tone": tone, className: cn("mt-1 text-heading-3 whitespace-nowrap tabular-nums", TONE_TEXT[tone]), children: card.value }), card.progress === undefined ? null : (_jsx(Progress, { value: clampProgress(card.progress), "aria-label": card.progressLabel ?? card.label, "data-slot": "stat-card-progress", className: "mt-2", indicatorClassName: card.tone === undefined ? undefined : TONE_FILL[card.tone] })), card.hint === undefined ? null : _jsx("div", { className: "mt-1 text-small text-muted-foreground", children: card.hint })] }), card.aside === undefined ? null : (_jsx(Badge, { variant: "tag", color: TONE_COLORS[card.aside.tone ?? "default"] ?? "default", "data-slot": "stat-card-aside", "data-tone": card.aside.tone ?? "default", className: "text-small", children: card.aside.text }))] }, card.key));
36
+ return (_jsxs("li", { "data-stat": card.key, className: "flex min-w-0 items-start justify-between gap-2 rounded-lg bg-card p-3 text-card-foreground shadow-card", children: [_jsxs("div", { className: cn("min-w-0", card.progress !== undefined && "flex-1"), children: [_jsx(StatCardLabel, { label: card.label, icon: card.icon }), _jsx("div", { "data-tone": tone, className: cn("mt-1 text-heading-3 whitespace-nowrap tabular-nums", TONE_TEXT[tone]), children: card.value }), card.progress === undefined ? null : (_jsx(Progress, { value: clampProgress(card.progress), "aria-label": card.progressLabel ?? card.label, "data-slot": "stat-card-progress", className: "mt-2", indicatorClassName: card.tone === undefined ? undefined : TONE_FILL[card.tone] })), card.hint === undefined ? null : _jsx("div", { className: "mt-1 text-small text-muted-foreground", children: card.hint })] }), card.aside === undefined ? null : (_jsx(Badge, { variant: "tag", color: TONE_COLORS[card.aside.tone ?? "default"] ?? "default", "data-slot": "stat-card-aside", "data-tone": card.aside.tone ?? "default", className: "text-small", children: card.aside.text }))] }, card.key));
32
37
  }) }));
33
38
  }
34
39
  // Small counts as "label **value**" tags in one row, wrapping only on a phone, each in its tone's colour.
@@ -1 +1 @@
1
- {"version":3,"file":"Stats.js","sourceRoot":"","sources":["../../src/notion/Stats.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAG5C,OAAO,EAAE,KAAK,EAAE,MAAM,gBAAgB,CAAC;AACvC,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC7C,OAAO,EAAE,EAAE,EAAE,MAAM,iBAAiB,CAAC;AAErC,OAAO,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AACrD,OAAO,EAAE,WAAW,EAAE,SAAS,EAAE,SAAS,EAAa,MAAM,YAAY,CAAC;AAS1E,qHAAqH;AACrH,oHAAoH;AACpH,MAAM,UAAU,SAAS,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAkB;IACtE,OAAO,CACL,gCAAmB,YAAY,EAAC,SAAS,EAAE,EAAE,CAAC,kBAAkB,EAAE,SAAS,CAAC,aAC1E,gCACY,oBAAoB,EAC9B,SAAS,EAAC,yPAAyP,aAEnQ,KAAC,YAAY,mBACC,MAAM,EAClB,WAAW,EAAE,iBAAiB,EAC9B,SAAS,EAAC,yGAAyG,GACnH,EACF,aAAI,SAAS,EAAC,gBAAgB,YAAE,KAAK,GAAM,IACnC,EACV,2BAAe,oBAAoB,EAAC,SAAS,EAAC,oCAAoC,YAC/E,QAAQ,GACL,IACE,CACX,CAAC;AACJ,CAAC;AA+BD,SAAS,aAAa,CAAC,QAAgB;IACrC,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,QAAQ,CAAC;QAAE,OAAO,CAAC,CAAC;IACzC,OAAO,IAAI,CAAC,GAAG,CAAC,GAAG,EAAE,IAAI,CAAC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Y,YAAY,EAAC,SAAS,EAAC,0DAA0D,YAC/G,KAAK,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,CACnB,0BAA8B,IAAI,CAAC,GAAG,eAAa,IAAI,CAAC,IAAI,IAAI,SAAS,YACvE,MAAC,KAAK,IAAC,OAAO,EAAC,KAAK,EAAC,KAAK,EAAE,WAAW,CAAC,IAAI,CAAC,IAAI,IAAI,SAAS,CAAC,IAAI,SAAS,aACzE,IAAI,CAAC,KAAK,OAAE,iBAAQ,SAAS,EAAC,0BAA0B,YAAE,IAAI,CAAC,KAAK,GAAU,IACzE,IAHD,IAAI,CAAC,GAAG,CAIZ,CACN,CAAC,GACC,CACN,CAAC;AACJ,CAAC"}
@@ -0,0 +1,2 @@
1
+ /* The kit's preflight.css, resolved from this theme's own dependency on @softure-ai/theme-kit. */
2
+ @import "@softure-ai/theme-kit/preflight.css";
@@ -8,7 +8,12 @@ declare function CommandDialog({ title, description, children, className, showCl
8
8
  className?: string;
9
9
  showCloseButton?: boolean;
10
10
  }): React.JSX.Element;
11
- declare function CommandInput({ className, ...props }: React.ComponentProps<typeof CommandPrimitive.Input>): React.JSX.Element;
11
+ declare function CommandInput({ className, wrapperClassName, children, ...props }: React.ComponentProps<typeof CommandPrimitive.Input> & {
12
+ /** Classes for the input row (e.g. its height), merged after the row's own. */
13
+ wrapperClassName?: string;
14
+ /** Content at the end of the input row, after the input (e.g. a `Kbd`). */
15
+ children?: React.ReactNode;
16
+ }): React.JSX.Element;
12
17
  declare function CommandList({ className, ...props }: React.ComponentProps<typeof CommandPrimitive.List>): React.JSX.Element;
13
18
  declare function CommandEmpty({ ...props }: React.ComponentProps<typeof CommandPrimitive.Empty>): React.JSX.Element;
14
19
  declare function CommandGroup({ className, ...props }: React.ComponentProps<typeof CommandPrimitive.Group>): React.JSX.Element;
@@ -1 +1 @@
1
- {"version":3,"file":"command.d.ts","sourceRoot":"","sources":["../../src/ui/command.tsx"],"names":[],"mappings":"AAEA,OAAO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ACzB,2EAA2E;IAC3E,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;CAC3B,qBAkBA;AAED,iBAAS,WAAW,CAAC,EACnB,SAAS,EACT,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,gBAAgB,CAAC,IAAI,CAAC,qBAWpD;AAED,iBAAS,YAAY,CAAC,EACpB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,gBAAgB,CAAC,KAAK,CAAC,qBAQrD;AAED,iBAAS,YAAY,CAAC,EACpB,SAAS,EACT,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,gBAAgB,CAAC,KAAK,CAAC,qBAWrD;AAED,iBAAS,gBAAgB,CAAC,EACxB,SAAS,EACT,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,gBAAgB,CAAC,SAAS,CAAC,qBAQzD;AAED,iBAAS,WAAW,CAAC,EACnB,SAAS,EACT,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,gBAAgB,CAAC,IAAI,CAAC,qBAWpD;AAED,iBAAS,eAAe,CAAC,EACvB,SAAS,EACT,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,MAAM,CAAC,qBAW9B;AAED,OAAO,EACL,OAAO,EACP,aAAa,EACb,YAAY,EACZ,WAAW,EACX,YAAY,EACZ,YAAY,EACZ,WAAW,EACX,eAAe,EACf,gBAAgB,GACjB,CAAA"}
@@ -10,10 +10,10 @@ function Command({ className, ...props }) {
10
10
  return (_jsx(CommandPrimitive, { "data-slot": "command", className: cn("flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground", className), ...props }));
11
11
  }
12
12
  function CommandDialog({ title = messages.command.title, description = messages.command.description, children, className, showCloseButton = true, ...props }) {
13
- return (_jsxs(Dialog, { ...props, children: [_jsxs(DialogHeader, { className: "sr-only", children: [_jsx(DialogTitle, { children: title }), _jsx(DialogDescription, { children: description })] }), _jsx(DialogContent, { className: cn("overflow-hidden p-0", className), showCloseButton: showCloseButton, children: _jsx(Command, { className: "**:data-[slot=command-input-wrapper]:h-12 [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]]:px-2 [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-input-wrapper]_svg]:h-5 [&_[cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5", children: children }) })] }));
13
+ return (_jsxs(Dialog, { ...props, children: [_jsxs(DialogHeader, { className: "sr-only", children: [_jsx(DialogTitle, { children: title }), _jsx(DialogDescription, { children: description })] }), _jsx(DialogContent, { className: cn("overflow-hidden p-0", className), showCloseButton: showCloseButton, children: _jsx(Command, { label: title, className: "**:data-[slot=command-input-wrapper]:h-12 [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]]:px-2 [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-input-wrapper]_svg]:h-5 [&_[cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5", children: children }) })] }));
14
14
  }
15
- function CommandInput({ className, ...props }) {
16
- return (_jsxs("div", { "data-slot": "command-input-wrapper", className: "flex h-9 items-center gap-2 border-b px-3", children: [_jsx(SearchIcon, { className: "size-4 shrink-0 opacity-50" }), _jsx(CommandPrimitive.Input, { "data-slot": "command-input", className: cn("flex h-10 w-full rounded-md bg-transparent py-3 text-sm outline-hidden placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50", className), ...props })] }));
15
+ function CommandInput({ className, wrapperClassName, children, ...props }) {
16
+ return (_jsxs("div", { "data-slot": "command-input-wrapper", className: cn("flex h-9 items-center gap-2 border-b px-3", wrapperClassName), children: [_jsx(SearchIcon, { className: "size-4 shrink-0 opacity-50" }), _jsx(CommandPrimitive.Input, { "data-slot": "command-input", className: cn("flex h-10 w-full rounded-md bg-transparent py-3 text-sm outline-hidden placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50", className), ...props }), children] }));
17
17
  }
18
18
  function CommandList({ className, ...props }) {
19
19
  return (_jsx(CommandPrimitive.List, { "data-slot": "command-list", className: cn("max-h-[300px] scroll-py-1 overflow-x-hidden overflow-y-auto", className), ...props }));
@@ -1 +1 @@
1
- {"version":3,"file":"command.js","sourceRoot":"","sources":["../../src/ui/command.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAA;;AAEZ,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,MAAM,CAAA;AAClD,OAAO,EAAE,EAAE,IAAI,QAAQ,EAAE,MAAM,mBAAmB,CAAA;AAClD,OAAO,EAAE,EAAE,EAAE,MAAM,iBAAiB,CAAA;AACpC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AAEzC,OAAO,EACL,MAAM,EACN,aAAa,EACb,iBAAiB,EACjB,YAAY,EACZ,WAAW,GACZ,MAAM,aAAa,CAAA;AAEpB,SAAS,OAAO,CAAC,EACf,SAAS,EACT,GAAG,KAAK,EACsC;IAC9C,OAAO,CACL,KAAC,gBAAgB,iBACL,SAAS,EACnB,SAAS,EAAE,EAAE,CACX,2FAA2F,EAC3F,SAAS,CACV,KACG,KAAK,GACT,CACH,CAAA;AACH,CAAC;AAED,SAAS,aAAa,CAAC,EACrB,KAAK,GAAG,QAAQ,CAAC,OAAO,CAAC,KAAK,EAC9B,WAAW,GAAG,QAAQ,CAAC,OAAO,CAAC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Ae,EACzB,SAAS,EAAE,EAAE,CACX,wNAAwN,EACxN,SAAS,CACV,KACG,KAAK,GACT,CACH,CAAA;AACH,CAAC;AAED,SAAS,gBAAgB,CAAC,EACxB,SAAS,EACT,GAAG,KAAK,EACgD;IACxD,OAAO,CACL,KAAC,gBAAgB,CAAC,SAAS,iBACf,mBAAmB,EAC7B,SAAS,EAAE,EAAE,CAAC,sBAAsB,EAAE,SAAS,CAAC,KAC5C,KAAK,GACT,CACH,CAAA;AACH,CAAC;AAED,SAAS,WAAW,CAAC,EACnB,SAAS,EACT,GAAG,KAAK,EAC2C;IACnD,OAAO,CACL,KAAC,gBAAgB,CAAC,IAAI,iBACV,cAAc,EACxB,SAAS,EAAE,EAAE,CACX,2YAA2Y,EAC3Y,SAAS,CACV,KACG,KAAK,GACT,CACH,CAAA;AACH,CAAC;AAED,SAAS,eAAe,CAAC,EACvB,SAAS,EACT,GAAG,KAAK,EACqB;IAC7B,OAAO,CACL,4BACY,kBAAkB,EAC5B,SAAS,EAAE,EAAE,CACX,uDAAuD,EACvD,SAAS,CACV,KACG,KAAK,GACT,CACH,CAAA;AACH,CAAC;AAED,OAAO,EACL,OAAO,EACP,aAAa,EACb,YAAY,EACZ,WAAW,EACX,YAAY,EACZ,YAAY,EACZ,WAAW,EACX,eAAe,EACf,gBAAgB,GACjB,CAAA"}
1
+ {"version":3,"file":"command.js","sourceRoot":"","sources":["../../src/ui/command.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAA;;AAEZ,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,MAAM,CAAA;AAClD,OAAO,EAAE,EAAE,IAAI,QAAQ,EAAE,MAAM,mBAAmB,CAAA;AAClD,OAAO,EAAE,EAAE,EAAE,MAAM,iBAAiB,CAAA;AACpC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AAEzC,OAAO,EACL,MAAM,EACN,aAAa,EACb,iBAA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,YAAY,EACZ,WAAW,EACX,eAAe,EACf,gBAAgB,GACjB,CAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@softure-ai/theme-notion",
3
- "version": "0.4.0",
3
+ "version": "0.5.0",
4
4
  "description": "SOFTURE AI Notion theme: shadcn/ui components (new-york v4, Radix, Tailwind CSS v4, lucide) with the Notion design system's tokens and deltas, ready to import.",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -34,7 +34,10 @@
34
34
  },
35
35
  "./theme.css": "./dist/theme.css",
36
36
  "./sft-bridge.css": "./dist/sft-bridge.css",
37
- "./page.css": "./dist/page.css"
37
+ "./page.css": "./dist/page.css",
38
+ "./preflight.css": "./dist/preflight.css",
39
+ "./base.css": "./dist/base.css",
40
+ "./maplibre.css": "./dist/maplibre.css"
38
41
  },
39
42
  "softureTheme": {
40
43
  "sources": [
@@ -58,7 +61,7 @@
58
61
  "@dnd-kit/core": "^6.3.1",
59
62
  "@dnd-kit/sortable": "^10.0.0",
60
63
  "@dnd-kit/utilities": "^3.2.2",
61
- "@softure-ai/theme-kit": "^0.1.3",
64
+ "@softure-ai/theme-kit": "^0.1.4",
62
65
  "class-variance-authority": "^0.7.1",
63
66
  "cmdk": "^1.1.1",
64
67
  "lucide-react": "^1.61.0",
@@ -1,4 +1,4 @@
1
- import { ChevronRight } from "lucide-react";
1
+ import { ChevronRight, type LucideIcon } from "lucide-react";
2
2
  import type { ReactNode } from "react";
3
3
 
4
4
  import { Badge } from "../ui/badge.js";
@@ -47,6 +47,8 @@ export interface StatCard {
47
47
  /** Unique within the row; kept as `data-stat`. */
48
48
  readonly key: string;
49
49
  readonly label: string;
50
+ /** A decorative icon before the label: 16 px, the design system's stroke, the label's muted colour. */
51
+ readonly icon?: LucideIcon;
50
52
  readonly value: string;
51
53
  readonly hint?: string;
52
54
  readonly tone?: Tone;
@@ -77,9 +79,19 @@ function getStatCardsLayout(isFullWidth: boolean, isOneRow: boolean): "row" | "f
77
79
  return isFullWidth ? "full" : "grid";
78
80
  }
79
81
 
80
- // Summary figures as a row of cards wrapping on a narrow screen: the label, the figure in its tone's colour (never
81
- // broken, tabular numbers), an optional bar under it, an optional note and an optional short figure on its right as a
82
- // tag.
82
+ function StatCardLabel({ label, icon: Icon }: { readonly label: string; readonly icon: LucideIcon | undefined }) {
83
+ if (Icon === undefined) return <div className="text-section-label text-muted-foreground">{label}</div>;
84
+ return (
85
+ <div className="flex items-center gap-1.5 text-section-label text-muted-foreground">
86
+ <Icon aria-hidden="true" strokeWidth={ICON_STROKE_WIDTH} className="size-4 shrink-0" />
87
+ {label}
88
+ </div>
89
+ );
90
+ }
91
+
92
+ // Summary figures as a row of cards wrapping on a narrow screen: the label (after an optional icon), the figure in its
93
+ // tone's colour (never broken, tabular numbers), an optional bar under it, an optional note and an optional short
94
+ // figure on its right as a tag.
83
95
  export function StatCards({ label, cards, isFullWidth = false, isOneRow = false }: StatCardsProps) {
84
96
  return (
85
97
  <ul
@@ -103,7 +115,7 @@ export function StatCards({ label, cards, isFullWidth = false, isOneRow = false
103
115
  className="flex min-w-0 items-start justify-between gap-2 rounded-lg bg-card p-3 text-card-foreground shadow-card"
104
116
  >
105
117
  <div className={cn("min-w-0", card.progress !== undefined && "flex-1")}>
106
- <div className="text-section-label text-muted-foreground">{card.label}</div>
118
+ <StatCardLabel label={card.label} icon={card.icon} />
107
119
  <div data-tone={tone} className={cn("mt-1 text-heading-3 whitespace-nowrap tabular-nums", TONE_TEXT[tone])}>
108
120
  {card.value}
109
121
  </div>
@@ -53,7 +53,7 @@ function CommandDialog({
53
53
  className={cn("overflow-hidden p-0", className)}
54
54
  showCloseButton={showCloseButton}
55
55
  >
56
- <Command className="**:data-[slot=command-input-wrapper]:h-12 [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]]:px-2 [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-input-wrapper]_svg]:h-5 [&_[cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5">
56
+ <Command label={title} className="**:data-[slot=command-input-wrapper]:h-12 [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]]:px-2 [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-input-wrapper]_svg]:h-5 [&_[cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5">
57
57
  {children}
58
58
  </Command>
59
59
  </DialogContent>
@@ -63,12 +63,19 @@ function CommandDialog({
63
63
 
64
64
  function CommandInput({
65
65
  className,
66
+ wrapperClassName,
67
+ children,
66
68
  ...props
67
- }: React.ComponentProps<typeof CommandPrimitive.Input>) {
69
+ }: React.ComponentProps<typeof CommandPrimitive.Input> & {
70
+ /** Classes for the input row (e.g. its height), merged after the row's own. */
71
+ wrapperClassName?: string
72
+ /** Content at the end of the input row, after the input (e.g. a `Kbd`). */
73
+ children?: React.ReactNode
74
+ }) {
68
75
  return (
69
76
  <div
70
77
  data-slot="command-input-wrapper"
71
- className="flex h-9 items-center gap-2 border-b px-3"
78
+ className={cn("flex h-9 items-center gap-2 border-b px-3", wrapperClassName)}
72
79
  >
73
80
  <SearchIcon className="size-4 shrink-0 opacity-50" />
74
81
  <CommandPrimitive.Input
@@ -79,6 +86,7 @@ function CommandInput({
79
86
  )}
80
87
  {...props}
81
88
  />
89
+ {children}
82
90
  </div>
83
91
  )
84
92
  }