@asanchez-sa/abby 0.1.2 → 0.2.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.
Files changed (120) hide show
  1. package/README.md +1 -1
  2. package/dist/agents/approvals.d.ts +4 -4
  3. package/dist/agents/changes.d.ts +4 -4
  4. package/dist/agents/hooks.d.ts +3 -3
  5. package/dist/agents/index.d.ts +2 -7
  6. package/dist/agents/index.js +2 -5
  7. package/dist/agents/run-tool.d.ts +2 -2
  8. package/dist/agents/ui-sdk.d.ts +3 -5
  9. package/dist/agents/ui-sdk.js +3 -3
  10. package/dist/behaviors/lists/index.d.ts +2 -3
  11. package/dist/behaviors/lists/index.js +1 -3
  12. package/dist/behaviors/lists/ui-sdk.d.ts +2 -2
  13. package/dist/behaviors/lists/ui-sdk.js +3 -3
  14. package/dist/behaviors/popups/index.d.ts +2 -3
  15. package/dist/behaviors/popups/index.js +1 -3
  16. package/dist/behaviors/popups/ui-sdk.d.ts +2 -2
  17. package/dist/behaviors/popups/ui-sdk.js +3 -3
  18. package/dist/behaviors/preferences/index.d.ts +2 -3
  19. package/dist/behaviors/preferences/index.js +1 -3
  20. package/dist/behaviors/preferences/ui-sdk.d.ts +2 -2
  21. package/dist/behaviors/preferences/ui-sdk.js +3 -3
  22. package/dist/behaviors/transitions/index.d.ts +2 -3
  23. package/dist/behaviors/transitions/index.js +1 -3
  24. package/dist/behaviors/transitions/ui-sdk.d.ts +2 -2
  25. package/dist/behaviors/transitions/ui-sdk.js +3 -3
  26. package/dist/components/alert/alert.d.ts +3 -2
  27. package/dist/components/alert/alert.js +3 -2
  28. package/dist/components/attachment/attachment.d.ts +3 -2
  29. package/dist/components/attachment/attachment.js +3 -2
  30. package/dist/components/badge/badge.d.ts +3 -2
  31. package/dist/components/badge/badge.js +3 -2
  32. package/dist/components/bubble/bubble.d.ts +3 -2
  33. package/dist/components/bubble/bubble.js +3 -2
  34. package/dist/components/button-group/button-group.d.ts +4 -3
  35. package/dist/components/button-group/button-group.js +4 -3
  36. package/dist/components/card/card.d.ts +3 -2
  37. package/dist/components/card/card.js +3 -2
  38. package/dist/components/choice-cards/choice-cards.d.ts +4 -3
  39. package/dist/components/choice-cards/choice-cards.js +4 -3
  40. package/dist/components/command-dock/command-dock.d.ts +4 -4
  41. package/dist/components/command-dock/command-dock.js +9 -9
  42. package/dist/components/empty/empty.d.ts +3 -2
  43. package/dist/components/empty/empty.js +3 -2
  44. package/dist/components/input/input.d.ts +5 -2
  45. package/dist/components/input/input.js +32 -17
  46. package/dist/components/input-group/input-group.d.ts +5 -4
  47. package/dist/components/input-group/input-group.js +5 -4
  48. package/dist/components/item/item.d.ts +3 -2
  49. package/dist/components/item/item.js +3 -2
  50. package/dist/components/link/link.d.ts +3 -2
  51. package/dist/components/link/link.js +4 -4
  52. package/dist/components/marker/marker.d.ts +3 -2
  53. package/dist/components/marker/marker.js +3 -2
  54. package/dist/components/message-scroller/message-scroller.d.ts +7 -6
  55. package/dist/components/message-scroller/message-scroller.js +8 -8
  56. package/dist/components/model-selector/model-selector.js +9 -9
  57. package/dist/components/native-select/native-select.js +4 -4
  58. package/dist/components/note-editor/note-editor.js +5 -5
  59. package/dist/components/otp-input/otp-input.d.ts +8 -2
  60. package/dist/components/otp-input/otp-input.js +35 -20
  61. package/dist/components/questionnaire/questionnaire.d.ts +11 -11
  62. package/dist/components/questionnaire/questionnaire.js +13 -13
  63. package/dist/components/sidebar/sidebar.d.ts +4 -4
  64. package/dist/components/sidebar/sidebar.js +10 -9
  65. package/dist/components/table-of-contents/table-of-contents.d.ts +4 -4
  66. package/dist/components/table-of-contents/table-of-contents.js +5 -5
  67. package/dist/components/team-mark/team-mark.d.ts +26 -0
  68. package/dist/components/team-mark/team-mark.js +101 -0
  69. package/dist/components/toolbar/toolbar.d.ts +3 -2
  70. package/dist/components/toolbar/toolbar.js +7 -5
  71. package/dist/components/week-strip/week-strip.d.ts +7 -7
  72. package/dist/components/week-strip/week-strip.js +32 -31
  73. package/dist/core/index.d.ts +2 -6
  74. package/dist/core/index.js +2 -26
  75. package/dist/core/ui-sdk.d.ts +2 -2
  76. package/dist/core/ui-sdk.js +3 -3
  77. package/dist/tools/observe/index.d.ts +2 -2
  78. package/dist/tools/observe/index.js +1 -3
  79. package/dist/tools/observe/ui-sdk.d.ts +2 -1
  80. package/dist/tools/observe/ui-sdk.js +1 -2
  81. package/dist/tools/testing/check-agent.d.ts +4 -3
  82. package/dist/tools/testing/index.d.ts +2 -3
  83. package/dist/tools/testing/index.js +3 -4
  84. package/dist/tools/testing/ui-sdk.d.ts +2 -1
  85. package/dist/tools/testing/ui-sdk.js +1 -2
  86. package/dist/utilities/color/index.d.ts +2 -2
  87. package/dist/utilities/color/index.js +1 -3
  88. package/dist/utilities/color/ui-sdk.d.ts +2 -1
  89. package/dist/utilities/color/ui-sdk.js +1 -2
  90. package/dist/utilities/date/index.d.ts +2 -2
  91. package/dist/utilities/date/index.js +1 -6
  92. package/dist/utilities/date/ui-sdk.d.ts +2 -1
  93. package/dist/utilities/date/ui-sdk.js +1 -2
  94. package/dist/utilities/image/index.d.ts +2 -2
  95. package/dist/utilities/image/index.js +1 -3
  96. package/dist/utilities/image/ui-sdk.d.ts +2 -1
  97. package/dist/utilities/image/ui-sdk.js +1 -2
  98. package/dist/utilities/number/index.d.ts +2 -2
  99. package/dist/utilities/number/index.js +1 -3
  100. package/dist/utilities/number/ui-sdk.d.ts +2 -1
  101. package/dist/utilities/number/ui-sdk.js +1 -2
  102. package/dist/utilities/platform/index.d.ts +2 -3
  103. package/dist/utilities/platform/index.js +1 -14
  104. package/dist/utilities/platform/ui-sdk.d.ts +2 -2
  105. package/dist/utilities/platform/ui-sdk.js +3 -3
  106. package/dist/utilities/text/index.d.ts +2 -3
  107. package/dist/utilities/text/index.js +1 -3
  108. package/dist/utilities/text/ui-sdk.d.ts +2 -2
  109. package/dist/utilities/text/ui-sdk.js +3 -3
  110. package/package.json +2 -1
  111. package/skills/agent-ready-ui/SKILL.md +1 -1
  112. package/skills/blocks/SKILL.md +1 -1
  113. package/skills/compose-screens/SKILL.md +40 -1
  114. package/skills/note-editor/SKILL.md +1 -1
  115. package/skills/note-status/SKILL.md +1 -1
  116. package/skills/setup/SKILL.md +1 -1
  117. package/skills/theming/SKILL.md +1 -1
  118. package/src/blocks/shell/parts/marks.tsx +18 -4
  119. package/src/blocks/shell/parts/rail.tsx +7 -7
  120. package/dist/_virtual/_rolldown/runtime.js +0 -26
@@ -11,7 +11,7 @@ metadata:
11
11
  agent reads.
12
12
  type: lifecycle
13
13
  library: abby
14
- library_version: 0.1.2
14
+ library_version: 0.2.0
15
15
  sources:
16
16
  - src/blocks/notes/notes-block.tsx
17
17
  - src/blocks/notes/adapters.ts
@@ -11,7 +11,7 @@ metadata:
11
11
  accessible and usable by agents.
12
12
  type: core
13
13
  library: abby
14
- library_version: 0.1.2
14
+ library_version: 0.2.0
15
15
  requires:
16
16
  - setup
17
17
  sources:
@@ -102,6 +102,44 @@ import { Button } from "abby/button";
102
102
  export const Small = () => <Button size="xs">Undo archive</Button>;
103
103
  ```
104
104
 
105
+ A screen that asks for one thing (a sign-in, a code) uses the touch size. An `Input` with `size="lg"` measures what a `Button` with `size="lg"` does, so a field and its button stack as one column. An `OTPInputSlot` with `size="lg"` is a 48px cell with the digit at 20px, and the groups and the separator space out with it. The default size of either doesn't change.
106
+
107
+ ```tsx
108
+ import { Button } from "abby/button";
109
+ import { Field, FieldLabel } from "abby/field";
110
+ import { Input } from "abby/input";
111
+ import { OTPInput, OTPInputGroup, OTPInputSlot } from "abby/otp-input";
112
+
113
+ export function SignIn() {
114
+ return (
115
+ <form className="flex w-90 flex-col gap-3">
116
+ <Field>
117
+ <FieldLabel>Email</FieldLabel>
118
+ <Input size="lg" type="email" />
119
+ </Field>
120
+ <Button size="lg" type="submit">
121
+ Send code
122
+ </Button>
123
+ </form>
124
+ );
125
+ }
126
+
127
+ export function Code() {
128
+ return (
129
+ <Field>
130
+ <FieldLabel>Code</FieldLabel>
131
+ <OTPInput maxLength={6}>
132
+ <OTPInputGroup>
133
+ {[0, 1, 2, 3, 4, 5].map((index) => (
134
+ <OTPInputSlot key={index} index={index} size="lg" />
135
+ ))}
136
+ </OTPInputGroup>
137
+ </OTPInput>
138
+ </Field>
139
+ );
140
+ }
141
+ ```
142
+
105
143
  ### Draw icons with `Icon`
106
144
 
107
145
  Icons come from `@hugeicons/core-free-icons` through `Icon`, which sets abby's size and stroke and hides the icon from screen readers. Pass `label` only when the icon says something no text around it says.
@@ -305,6 +343,7 @@ export function Shell() {
305
343
  }
306
344
  ```
307
345
 
346
+ - A team's tile (its initials on its color, 36px with 10px corners) is `TeamMark` from `abby/team-mark`: `<TeamMark name="Casa Norte" color="#8b6a3e" />`. Without `color` it's Alma's neutral tile with ink letters, for a team whose color the app doesn't know, such as an invitation. It repeats the name beside it, so it's hidden from screen readers and agents. On the sidebar's paper set `--team-mark-surface` to `var(--sidebar)`, and inside a rail's button add `className="size-full"`.
308
347
  - A rail's button is `size="icon"`: a 36px circle whose name shows only in its tooltip. Its badge is `variant="dot"`: a dot while the column is open, the count once collapsed. Put what the badge says in the button's `aria-describedby`.
309
348
  - A two-line row (a name and a line under it) is `size="lg"`, 48px. A row that's a link takes `render={<a href="…" />}`: the button turns it into a link an agent follows, so don't pass `LinkPart` there.
310
349
  - `SidebarInsetHeader` is the page's top bar, lined up with the window's controls; while the sidebar is collapsed, put a `SidebarTrigger` first in it.
@@ -13,7 +13,7 @@ metadata:
13
13
  blocks a person does.
14
14
  type: core
15
15
  library: abby
16
- library_version: 0.1.2
16
+ library_version: 0.2.0
17
17
  requires:
18
18
  - compose-screens
19
19
  - agent-ready-ui
@@ -12,7 +12,7 @@ metadata:
12
12
  and keep both usable by an agent without loading the editor.
13
13
  type: core
14
14
  library: abby
15
- library_version: 0.1.2
15
+ library_version: 0.2.0
16
16
  sources:
17
17
  - src/components/note-status/note-status.tsx
18
18
  - src/components/note-place/note-place.tsx
@@ -9,7 +9,7 @@ metadata:
9
9
  imports, CSS order and server rendering rules the package expects.
10
10
  type: lifecycle
11
11
  library: abby
12
- library_version: 0.1.2
12
+ library_version: 0.2.0
13
13
  sources:
14
14
  - README.md
15
15
  - src/styles/index.css
@@ -9,7 +9,7 @@ metadata:
9
9
  contrast keep working, and shows how to switch schemes and themes.
10
10
  type: core
11
11
  library: abby
12
- library_version: 0.1.2
12
+ library_version: 0.2.0
13
13
  requires:
14
14
  - setup
15
15
  sources:
@@ -20,13 +20,27 @@ export function tint(color: string, surface = "var(--background)"): CSSPropertie
20
20
  };
21
21
  }
22
22
 
23
- /** The assistant's logo: an ink tile with its violet core. */
23
+ /**
24
+ * The assistant's logo: an ink tile with its violet core and white dots. It
25
+ * is a logo, so its colors are fixed and don't turn over in dark, as Alma's
26
+ * "Dark ink" asks: the tile stays #1D1D1F, and in dark a 1px white line at
27
+ * 14% sets it apart from the dark paper. The line is 1px at every size
28
+ * (`non-scaling-stroke`), and half of it, inside the edge, shows.
29
+ */
24
30
  export function AssistantMark({ className }: { className?: string }) {
25
31
  return (
26
32
  <svg viewBox="0 0 24 24" aria-hidden="true" className={className}>
27
- <rect width="24" height="24" rx="7" className="fill-foreground" />
28
- <circle cx="12" cy="12" r="2.6" className="fill-chart-2" />
29
- <g className="fill-background">
33
+ <rect
34
+ width="24"
35
+ height="24"
36
+ rx="7"
37
+ fill="#1d1d1f"
38
+ strokeWidth="1"
39
+ vectorEffect="non-scaling-stroke"
40
+ className="stroke-transparent dark:stroke-[#ffffff24]"
41
+ />
42
+ <circle cx="12" cy="12" r="2.6" fill="#8e5be0" />
43
+ <g fill="#ffffff">
30
44
  <circle cx="16.2" cy="10.4" r="1" />
31
45
  <circle cx="9.4" cy="15.8" r="1" />
32
46
  <circle cx="8.6" cy="8.9" r="0.9" opacity="0.8" />
@@ -19,6 +19,7 @@ import {
19
19
  SidebarMenuButton,
20
20
  SidebarMenuItem,
21
21
  } from "abby/sidebar";
22
+ import { TeamMark } from "abby/team-mark";
22
23
  import type { ShellWorkspace } from "../data.ts";
23
24
  import type { ShellTexts } from "../texts.ts";
24
25
  import { initialsOf, tint } from "./marks.tsx";
@@ -122,13 +123,12 @@ export function Rail({ workspace, texts, page, href }: RailProps) {
122
123
  render={<a href={href("home")} />}
123
124
  data-team=""
124
125
  >
125
- <span
126
- aria-hidden="true"
127
- className="grid size-full place-items-center rounded-lg text-xs font-semibold"
128
- style={tint(team.color, "var(--sidebar)")}
129
- >
130
- {team.initials}
131
- </span>
126
+ <TeamMark
127
+ name={team.name}
128
+ initials={team.initials}
129
+ color={team.color}
130
+ className="size-full [--team-mark-surface:var(--sidebar)]"
131
+ />
132
132
  <span>{team.name}</span>
133
133
  </SidebarMenuButton>
134
134
  </SidebarMenuItem>
@@ -1,26 +0,0 @@
1
- // \0rolldown/runtime.js
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __exportAll = (all, no_symbols) => {
7
- let target = {};
8
- for (var name in all) __defProp(target, name, {
9
- get: all[name],
10
- enumerable: true
11
- });
12
- if (!no_symbols) __defProp(target, Symbol.toStringTag, { value: "Module" });
13
- return target;
14
- };
15
- var __copyProps = (to, from, except, desc) => {
16
- if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
17
- key = keys[i];
18
- if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
19
- get: ((k) => from[k]).bind(null, key),
20
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
21
- });
22
- }
23
- return to;
24
- };
25
- var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
26
- export { __exportAll, __reExport };