@designa8/vibedesign-linear-internal-v1-b737 0.13.3 → 0.13.5

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/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # @designa8/vibedesign-linear-internal-v1-b737
2
2
 
3
- Complete design system generated by Atoms Design, version **0.13.3**.
3
+ Complete design system generated by Atoms Design, version **0.13.5**.
4
4
  Tokens, atoms, molecules, organisms, and templates — import from the package root;
5
5
  never hardcode visual values in consumer code.
6
6
 
package/dist/index.cjs CHANGED
@@ -423,7 +423,7 @@ var variants = {
423
423
  soft: "border-transparent bg-surface-soft text-ink ring-1 ring-hairline ring-inset shadow-none enabled:hover:bg-surface-strong enabled:hover:ring-hairline-strong enabled:active:bg-surface-strong aria-pressed:bg-surface-strong disabled:ring-hairline-soft",
424
424
  tint: "border-hairline bg-surface-soft text-muted shadow-none enabled:hover:bg-surface-strong enabled:hover:text-ink enabled:active:bg-surface-strong aria-checked:border-primary aria-checked:bg-primary-soft aria-checked:text-primary aria-checked:enabled:hover:bg-primary-soft aria-checked:enabled:hover:text-primary",
425
425
  inverse: "border-transparent bg-inverse-canvas text-inverse-ink shadow-sm enabled:hover:opacity-90 enabled:active:opacity-80",
426
- neutral: "border-transparent bg-muted text-on-primary shadow-sm enabled:hover:bg-muted enabled:active:bg-muted",
426
+ neutral: "border-transparent bg-muted text-on-primary shadow-sm enabled:hover:bg-body enabled:active:bg-ink",
427
427
  media: "border-transparent bg-transparent p-0 focus-visible:ring-inset enabled:hover:bg-surface-soft enabled:active:bg-surface-strong"
428
428
  };
429
429
  var sizes = {
@@ -11029,7 +11029,6 @@ var PromptInputBar = React90.forwardRef(
11029
11029
  const [internalImages, setInternalImages] = React90.useState(
11030
11030
  []
11031
11031
  );
11032
- const [internalModelId, setInternalModelId] = React90.useState(void 0);
11033
11032
  const [menuOpen, setMenuOpen] = React90.useState(false);
11034
11033
  const [menuPos, setMenuPos] = React90.useState(null);
11035
11034
  const [mounted, setMounted] = React90.useState(false);
@@ -11058,8 +11057,7 @@ var PromptInputBar = React90.forwardRef(
11058
11057
  React90.useEffect(() => {
11059
11058
  if (selectedModelId !== void 0) setPickedModelId(selectedModelId);
11060
11059
  }, [selectedModelId]);
11061
- const activeModelId = pickedModelId ?? internalModelId;
11062
- const currentModel = models?.find((m) => m.id === activeModelId) ?? models?.[0];
11060
+ const currentModel = models?.find((m) => m.id === pickedModelId) ?? models?.[0];
11063
11061
  const prefersReducedMotion = React90.useCallback(
11064
11062
  () => typeof window !== "undefined" && typeof window.matchMedia === "function" && window.matchMedia("(prefers-reduced-motion: reduce)").matches,
11065
11063
  []
@@ -11274,11 +11272,8 @@ var PromptInputBar = React90.forwardRef(
11274
11272
  return;
11275
11273
  }
11276
11274
  setPickedModelId(model.id);
11277
- if (selectedModelId === void 0) setInternalModelId(model.id);
11278
11275
  onModelChange?.(model.id);
11279
- window.requestAnimationFrame(() => {
11280
- menuPanelRef.current?.querySelector('[data-menu-item][aria-checked="true"]')?.focus({ preventScroll: true });
11281
- });
11276
+ closeMenu();
11282
11277
  };
11283
11278
  const handleMenuKeyDown = (e) => {
11284
11279
  if (e.key === "Escape") {
@@ -11317,7 +11312,7 @@ var PromptInputBar = React90.forwardRef(
11317
11312
  ref: menuPanelRef,
11318
11313
  id: `${uid}-menu`,
11319
11314
  role: "menu",
11320
- "aria-label": `Prompt options. Current model: ${currentModel?.name ?? "none"}`,
11315
+ "aria-label": "Prompt options",
11321
11316
  "aria-hidden": menuOpen ? void 0 : true,
11322
11317
  "data-state": menuOpen ? "open" : "closed",
11323
11318
  inert: !menuOpen,
@@ -11459,13 +11454,13 @@ var PromptInputBar = React90.forwardRef(
11459
11454
  inert: isRecording,
11460
11455
  className: ROW_LAYER,
11461
11456
  children: [
11462
- /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
11463
- IconButton,
11457
+ /* @__PURE__ */ (0, import_jsx_runtime90.jsxs)(
11458
+ Button,
11464
11459
  {
11465
11460
  ref: plusRef,
11466
- icon: "plus",
11467
- size: "lg",
11461
+ iconOnly: true,
11468
11462
  variant: "soft",
11463
+ size: "lg",
11469
11464
  "aria-label": triggerLabel,
11470
11465
  "aria-haspopup": "menu",
11471
11466
  "aria-expanded": menuOpen,
@@ -11477,7 +11472,11 @@ var PromptInputBar = React90.forwardRef(
11477
11472
  ROUND,
11478
11473
  "shrink-0 transition-transform duration-200 ease-out",
11479
11474
  menuOpen && "rotate-45"
11480
- )
11475
+ ),
11476
+ children: [
11477
+ /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(Icon, { name: "plus", size: 18 }),
11478
+ /* @__PURE__ */ (0, import_jsx_runtime90.jsx)("span", { className: "sr-only", children: currentModel?.name ?? "" })
11479
+ ]
11481
11480
  }
11482
11481
  ),
11483
11482
  /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(
package/dist/index.js CHANGED
@@ -277,7 +277,7 @@ var variants = {
277
277
  soft: "border-transparent bg-surface-soft text-ink ring-1 ring-hairline ring-inset shadow-none enabled:hover:bg-surface-strong enabled:hover:ring-hairline-strong enabled:active:bg-surface-strong aria-pressed:bg-surface-strong disabled:ring-hairline-soft",
278
278
  tint: "border-hairline bg-surface-soft text-muted shadow-none enabled:hover:bg-surface-strong enabled:hover:text-ink enabled:active:bg-surface-strong aria-checked:border-primary aria-checked:bg-primary-soft aria-checked:text-primary aria-checked:enabled:hover:bg-primary-soft aria-checked:enabled:hover:text-primary",
279
279
  inverse: "border-transparent bg-inverse-canvas text-inverse-ink shadow-sm enabled:hover:opacity-90 enabled:active:opacity-80",
280
- neutral: "border-transparent bg-muted text-on-primary shadow-sm enabled:hover:bg-muted enabled:active:bg-muted",
280
+ neutral: "border-transparent bg-muted text-on-primary shadow-sm enabled:hover:bg-body enabled:active:bg-ink",
281
281
  media: "border-transparent bg-transparent p-0 focus-visible:ring-inset enabled:hover:bg-surface-soft enabled:active:bg-surface-strong"
282
282
  };
283
283
  var sizes = {
@@ -10883,7 +10883,6 @@ var PromptInputBar = React90.forwardRef(
10883
10883
  const [internalImages, setInternalImages] = React90.useState(
10884
10884
  []
10885
10885
  );
10886
- const [internalModelId, setInternalModelId] = React90.useState(void 0);
10887
10886
  const [menuOpen, setMenuOpen] = React90.useState(false);
10888
10887
  const [menuPos, setMenuPos] = React90.useState(null);
10889
10888
  const [mounted, setMounted] = React90.useState(false);
@@ -10912,8 +10911,7 @@ var PromptInputBar = React90.forwardRef(
10912
10911
  React90.useEffect(() => {
10913
10912
  if (selectedModelId !== void 0) setPickedModelId(selectedModelId);
10914
10913
  }, [selectedModelId]);
10915
- const activeModelId = pickedModelId ?? internalModelId;
10916
- const currentModel = models?.find((m) => m.id === activeModelId) ?? models?.[0];
10914
+ const currentModel = models?.find((m) => m.id === pickedModelId) ?? models?.[0];
10917
10915
  const prefersReducedMotion = React90.useCallback(
10918
10916
  () => typeof window !== "undefined" && typeof window.matchMedia === "function" && window.matchMedia("(prefers-reduced-motion: reduce)").matches,
10919
10917
  []
@@ -11128,11 +11126,8 @@ var PromptInputBar = React90.forwardRef(
11128
11126
  return;
11129
11127
  }
11130
11128
  setPickedModelId(model.id);
11131
- if (selectedModelId === void 0) setInternalModelId(model.id);
11132
11129
  onModelChange?.(model.id);
11133
- window.requestAnimationFrame(() => {
11134
- menuPanelRef.current?.querySelector('[data-menu-item][aria-checked="true"]')?.focus({ preventScroll: true });
11135
- });
11130
+ closeMenu();
11136
11131
  };
11137
11132
  const handleMenuKeyDown = (e) => {
11138
11133
  if (e.key === "Escape") {
@@ -11171,7 +11166,7 @@ var PromptInputBar = React90.forwardRef(
11171
11166
  ref: menuPanelRef,
11172
11167
  id: `${uid}-menu`,
11173
11168
  role: "menu",
11174
- "aria-label": `Prompt options. Current model: ${currentModel?.name ?? "none"}`,
11169
+ "aria-label": "Prompt options",
11175
11170
  "aria-hidden": menuOpen ? void 0 : true,
11176
11171
  "data-state": menuOpen ? "open" : "closed",
11177
11172
  inert: !menuOpen,
@@ -11313,13 +11308,13 @@ var PromptInputBar = React90.forwardRef(
11313
11308
  inert: isRecording,
11314
11309
  className: ROW_LAYER,
11315
11310
  children: [
11316
- /* @__PURE__ */ jsx90(
11317
- IconButton,
11311
+ /* @__PURE__ */ jsxs82(
11312
+ Button,
11318
11313
  {
11319
11314
  ref: plusRef,
11320
- icon: "plus",
11321
- size: "lg",
11315
+ iconOnly: true,
11322
11316
  variant: "soft",
11317
+ size: "lg",
11323
11318
  "aria-label": triggerLabel,
11324
11319
  "aria-haspopup": "menu",
11325
11320
  "aria-expanded": menuOpen,
@@ -11331,7 +11326,11 @@ var PromptInputBar = React90.forwardRef(
11331
11326
  ROUND,
11332
11327
  "shrink-0 transition-transform duration-200 ease-out",
11333
11328
  menuOpen && "rotate-45"
11334
- )
11329
+ ),
11330
+ children: [
11331
+ /* @__PURE__ */ jsx90(Icon, { name: "plus", size: 18 }),
11332
+ /* @__PURE__ */ jsx90("span", { className: "sr-only", children: currentModel?.name ?? "" })
11333
+ ]
11335
11334
  }
11336
11335
  ),
11337
11336
  /* @__PURE__ */ jsx90(
package/dist/styles.css CHANGED
@@ -2570,23 +2570,23 @@
2570
2570
  }
2571
2571
  }
2572
2572
  }
2573
- .enabled\:hover\:bg-inverse-ink\/10 {
2573
+ .enabled\:hover\:bg-body {
2574
2574
  &:enabled {
2575
2575
  &:hover {
2576
2576
  @media (hover: hover) {
2577
- background-color: color-mix(in srgb, #F7F8F8 10%, transparent);
2578
- @supports (color: color-mix(in lab, red, red)) {
2579
- background-color: color-mix(in oklab, var(--color-inverse-ink) 10%, transparent);
2580
- }
2577
+ background-color: var(--color-body);
2581
2578
  }
2582
2579
  }
2583
2580
  }
2584
2581
  }
2585
- .enabled\:hover\:bg-muted {
2582
+ .enabled\:hover\:bg-inverse-ink\/10 {
2586
2583
  &:enabled {
2587
2584
  &:hover {
2588
2585
  @media (hover: hover) {
2589
- background-color: var(--color-muted);
2586
+ background-color: color-mix(in srgb, #F7F8F8 10%, transparent);
2587
+ @supports (color: color-mix(in lab, red, red)) {
2588
+ background-color: color-mix(in oklab, var(--color-inverse-ink) 10%, transparent);
2589
+ }
2590
2590
  }
2591
2591
  }
2592
2592
  }
@@ -2685,10 +2685,10 @@
2685
2685
  }
2686
2686
  }
2687
2687
  }
2688
- .enabled\:active\:bg-muted {
2688
+ .enabled\:active\:bg-ink {
2689
2689
  &:enabled {
2690
2690
  &:active {
2691
- background-color: var(--color-muted);
2691
+ background-color: var(--color-ink);
2692
2692
  }
2693
2693
  }
2694
2694
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@designa8/vibedesign-linear-internal-v1-b737",
3
- "version": "0.13.3",
3
+ "version": "0.13.5",
4
4
  "description": "Complete design system \"My Project linear-internal-v1\" generated by Atoms Design.",
5
5
  "main": "dist/index.cjs",
6
6
  "module": "dist/index.js",
@@ -18,8 +18,9 @@ import { Icon } from "../Icon";
18
18
  * darkens on hover, and a brand-tinted `aria-checked` state — a pill-shaped
19
19
  * toggle (a switch-styled toolbar chip).
20
20
  * `inverse` is a filled ink surface with inverse text, for a solid neutral
21
- * action that must not read as brand primary. `neutral` is a muted grey fill
22
- * with an on-primary glyph, for a control that is inert until it has content.
21
+ * action that must not read as brand primary. `neutral` is a solid muted fill
22
+ * with an inverse glyph that deepens one step on hover and one more on press —
23
+ * a control that looks inert until it has content.
23
24
  * `media` is a borderless, full-width block trigger that wraps a thumbnail or
24
25
  * other media (no fixed height, no padding); clicking it opens a larger view.
25
26
  */
@@ -93,7 +94,7 @@ const variants: Record<ButtonVariant, string> = {
93
94
  inverse:
94
95
  "border-transparent bg-inverse-canvas text-inverse-ink shadow-sm enabled:hover:opacity-90 enabled:active:opacity-80",
95
96
  neutral:
96
- "border-transparent bg-muted text-on-primary shadow-sm enabled:hover:bg-muted enabled:active:bg-muted",
97
+ "border-transparent bg-muted text-on-primary shadow-sm enabled:hover:bg-body enabled:active:bg-ink",
97
98
  media:
98
99
  "border-transparent bg-transparent p-0 focus-visible:ring-inset enabled:hover:bg-surface-soft enabled:active:bg-surface-strong",
99
100
  };
@@ -4,10 +4,16 @@ import type { ButtonProps } from "../Button";
4
4
  import { Icon } from "../Icon";
5
5
  import type { IconName } from "../Icon";
6
6
 
7
+ /**
8
+ * `neutral` is a solid muted-grey fill with an inverse glyph — quiet and
9
+ * inactive-looking, so a send / submit control can sit greyed out until there
10
+ * is something to send and flip to `primary` when there is.
11
+ */
7
12
  export type IconButtonVariant =
8
13
  | "secondary"
9
14
  | "ghost"
10
15
  | "primary"
16
+ | "neutral"
11
17
  | "soft"
12
18
  | "inverse";
13
19
  export type IconButtonSize = "sm" | "md" | "lg";
@@ -1,9 +1,11 @@
1
1
  import * as React from "react";
2
+ import { Button } from "../Button";
2
3
  import { IconButton } from "./IconButton";
3
4
 
4
5
  export default function IconButtonPreview() {
5
6
  const [count, setCount] = React.useState(0);
6
7
  const [starred, setStarred] = React.useState(false);
8
+ const [hasText, setHasText] = React.useState(false);
7
9
 
8
10
  return (
9
11
  <div className="w-full max-w-3xl mx-auto p-lg space-y-lg text-ink">
@@ -25,11 +27,49 @@ export default function IconButtonPreview() {
25
27
  <IconButton icon="plus" disabled aria-label="Create issue (disabled)" />
26
28
  <span className="text-body-sm text-muted">Created {count}</span>
27
29
  </div>
30
+
28
31
  <div className="flex flex-wrap items-center gap-lg">
29
32
  <IconButton icon="plus" size="sm" aria-label="Small" />
30
33
  <IconButton icon="plus" size="md" aria-label="Medium" />
31
34
  <IconButton icon="plus" size="lg" aria-label="Large" />
32
35
  </div>
36
+
37
+ <div className="space-y-sm">
38
+ <p className="text-body-sm text-muted">
39
+ Neutral reads as inert until there is something to send.
40
+ </p>
41
+ <div className="flex flex-wrap items-center gap-lg">
42
+ <IconButton
43
+ icon="arrow-up"
44
+ variant={hasText ? "primary" : "neutral"}
45
+ aria-label={
46
+ hasText ? "Send message" : "Send message (nothing to send)"
47
+ }
48
+ onClick={() => setHasText((v) => !v)}
49
+ />
50
+ <IconButton
51
+ icon="arrow-up"
52
+ variant="neutral"
53
+ size="sm"
54
+ aria-label="Neutral small"
55
+ />
56
+ <IconButton
57
+ icon="arrow-up"
58
+ variant="neutral"
59
+ size="lg"
60
+ aria-label="Neutral large"
61
+ />
62
+ <IconButton
63
+ icon="arrow-up"
64
+ variant="neutral"
65
+ disabled
66
+ aria-label="Neutral disabled"
67
+ />
68
+ <Button variant="secondary" size="sm" onClick={() => setHasText((v) => !v)}>
69
+ {hasText ? "Clear draft" : "Type a draft"}
70
+ </Button>
71
+ </div>
72
+ </div>
33
73
  </div>
34
74
  );
35
75
  }
@@ -216,9 +216,6 @@ export const PromptInputBar = React.forwardRef<
216
216
  const [internalImages, setInternalImages] = React.useState<PastedImage[]>(
217
217
  [],
218
218
  );
219
- const [internalModelId, setInternalModelId] = React.useState<
220
- string | undefined
221
- >(undefined);
222
219
  const [menuOpen, setMenuOpen] = React.useState(false);
223
220
  const [menuPos, setMenuPos] = React.useState<{
224
221
  top: number;
@@ -255,8 +252,8 @@ export const PromptInputBar = React.forwardRef<
255
252
  suggestDesigns !== undefined ? suggestDesigns : internalSuggest;
256
253
  const hasModels = Boolean(models && models.length > 0);
257
254
 
258
- /* The tick has to move the instant a row is picked, even before a controlled
259
- parent echoes the id back, so the picked id is mirrored locally. */
255
+ /* The pick has to read back on the trigger the instant a row is chosen, even
256
+ before a controlled parent echoes the id, so it is mirrored locally. */
260
257
  const [pickedModelId, setPickedModelId] = React.useState<
261
258
  string | undefined
262
259
  >(selectedModelId);
@@ -265,9 +262,8 @@ export const PromptInputBar = React.forwardRef<
265
262
  if (selectedModelId !== undefined) setPickedModelId(selectedModelId);
266
263
  }, [selectedModelId]);
267
264
 
268
- const activeModelId = pickedModelId ?? internalModelId;
269
265
  const currentModel =
270
- models?.find((m) => m.id === activeModelId) ?? models?.[0];
266
+ models?.find((m) => m.id === pickedModelId) ?? models?.[0];
271
267
 
272
268
  const prefersReducedMotion = React.useCallback(
273
269
  () =>
@@ -522,21 +518,14 @@ export const PromptInputBar = React.forwardRef<
522
518
  onSuggestDesignsChange?.(next);
523
519
  };
524
520
 
525
- /* A model picker is a radio list: the tick has to be seen to move, so the
526
- panel stays open on a pick and focus follows the chosen row. */
527
521
  const handleModelSelect = (model: PromptInputBarModel) => {
528
522
  if (model.available === false) {
529
523
  onUnavailableModelClick?.(model.id);
530
524
  return;
531
525
  }
532
526
  setPickedModelId(model.id);
533
- if (selectedModelId === undefined) setInternalModelId(model.id);
534
527
  onModelChange?.(model.id);
535
- window.requestAnimationFrame(() => {
536
- menuPanelRef.current
537
- ?.querySelector<HTMLElement>('[data-menu-item][aria-checked="true"]')
538
- ?.focus({ preventScroll: true });
539
- });
528
+ closeMenu();
540
529
  };
541
530
 
542
531
  /* Arrow keys walk the rows of the open menu, Escape closes it. */
@@ -585,9 +574,7 @@ export const PromptInputBar = React.forwardRef<
585
574
  ref={menuPanelRef}
586
575
  id={`${uid}-menu`}
587
576
  role="menu"
588
- aria-label={`Prompt options. Current model: ${
589
- currentModel?.name ?? "none"
590
- }`}
577
+ aria-label="Prompt options"
591
578
  aria-hidden={menuOpen ? undefined : true}
592
579
  data-state={menuOpen ? "open" : "closed"}
593
580
  inert={!menuOpen}
@@ -746,11 +733,14 @@ export const PromptInputBar = React.forwardRef<
746
733
  inert={isRecording}
747
734
  className={ROW_LAYER}
748
735
  >
749
- <IconButton
736
+ {/* One 36px circle: soft fill, inset hairline ring, ink glyph. The
737
+ model name lives in its label and its hidden text, so a pick
738
+ reads back on the trigger itself. */}
739
+ <Button
750
740
  ref={plusRef}
751
- icon="plus"
752
- size="lg"
741
+ iconOnly
753
742
  variant="soft"
743
+ size="lg"
754
744
  aria-label={triggerLabel}
755
745
  aria-haspopup="menu"
756
746
  aria-expanded={menuOpen}
@@ -763,7 +753,10 @@ export const PromptInputBar = React.forwardRef<
763
753
  "shrink-0 transition-transform duration-200 ease-out",
764
754
  menuOpen && "rotate-45",
765
755
  )}
766
- />
756
+ >
757
+ <Icon name="plus" size={18} />
758
+ <span className="sr-only">{currentModel?.name ?? ""}</span>
759
+ </Button>
767
760
 
768
761
  <Button
769
762
  variant="tint"