@crewlethq/ui 0.28.0 → 0.30.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 (95) hide show
  1. package/README.md +45 -4
  2. package/dist/AccessDeniedCard/index.js +3 -3
  3. package/dist/Accordion/index.js +3 -3
  4. package/dist/AppShell/index.js +1 -1
  5. package/dist/{AppShell-APHZKJYH.css → AppShell-GCM4TDVY.css} +4 -1
  6. package/dist/ArtifactBar/ArtifactBar.d.ts +143 -0
  7. package/dist/ArtifactBar/index.d.ts +3 -0
  8. package/dist/ArtifactBar/index.js +25 -0
  9. package/dist/ArtifactBar-IBWB5POL.css +358 -0
  10. package/dist/ArtifactCard/index.js +3 -3
  11. package/dist/ArtifactCover/index.js +5 -5
  12. package/dist/ArtifactIcon/index.js +4 -4
  13. package/dist/ArtifactPanel/ArtifactPanel.d.ts +81 -0
  14. package/dist/ArtifactPanel/index.d.ts +3 -0
  15. package/dist/ArtifactPanel/index.js +5 -0
  16. package/dist/ArtifactPanel-YFXT5O77.css +132 -0
  17. package/dist/AuthLayout/index.js +3 -3
  18. package/dist/AvatarPicker/index.js +4 -4
  19. package/dist/Card/index.js +2 -2
  20. package/dist/ChangeMark/index.js +1 -1
  21. package/dist/CommandPalette/index.js +3 -3
  22. package/dist/CommentThread/index.js +5 -5
  23. package/dist/Composer/index.js +2 -2
  24. package/dist/DataView/index.js +4 -4
  25. package/dist/Disclosure/index.js +3 -3
  26. package/dist/Document/Document.d.ts +8 -1
  27. package/dist/Document/index.js +1 -1
  28. package/dist/{Document-PQGXJHB7.css → Document-G3YTZIUL.css} +71 -0
  29. package/dist/EditingStatus/EditingStatus.d.ts +25 -0
  30. package/dist/EditingStatus/index.d.ts +3 -0
  31. package/dist/EditingStatus/index.js +2 -0
  32. package/dist/EditingStatus-NFADEPSX.css +53 -0
  33. package/dist/Editor-YZ7KG2RD.js +2099 -0
  34. package/dist/HuePicker/index.js +2 -2
  35. package/dist/ListInput/index.js +2 -2
  36. package/dist/Markdown/grammar.d.ts +170 -0
  37. package/dist/Markdown/index.d.ts +2 -0
  38. package/dist/Markdown/index.js +1 -0
  39. package/dist/MarkdownEditor/index.js +1 -1
  40. package/dist/PeopleRail/PeopleRail.d.ts +8 -1
  41. package/dist/PeopleRail/index.js +1 -1
  42. package/dist/{PeopleRail-R64WVOSH.css → PeopleRail-SZGHZXVT.css} +8 -0
  43. package/dist/RichEditor/Editor.d.ts +17 -0
  44. package/dist/RichEditor/RichEditor.d.ts +26 -0
  45. package/dist/RichEditor/codec.d.ts +78 -0
  46. package/dist/RichEditor/commands.d.ts +89 -0
  47. package/dist/RichEditor/index.d.ts +4 -0
  48. package/dist/RichEditor/index.js +8 -0
  49. package/dist/RichEditor/keys.d.ts +16 -0
  50. package/dist/RichEditor/nodeviews.d.ts +60 -0
  51. package/dist/RichEditor/paste.d.ts +47 -0
  52. package/dist/RichEditor/plugins.d.ts +49 -0
  53. package/dist/RichEditor/roundtrip.d.ts +14 -0
  54. package/dist/RichEditor/schema.d.ts +23 -0
  55. package/dist/RichEditor/types.d.ts +140 -0
  56. package/dist/RichEditor-NPD2KAPS.css +419 -0
  57. package/dist/RichEditorMarkdown/index.d.ts +1 -0
  58. package/dist/RichEditorMarkdown/index.js +3 -0
  59. package/dist/SheetGrid/index.js +1 -1
  60. package/dist/ThemeSwitcher/index.js +1 -1
  61. package/dist/VersionCompare/index.js +2 -2
  62. package/dist/chunk-3DPIU2Q7.js +28 -0
  63. package/dist/{chunk-V2Z24W2Z.js → chunk-4JUKWWUD.js} +1 -1
  64. package/dist/{chunk-MQEEQVG6.js → chunk-6AH2XJ3Q.js} +2 -2
  65. package/dist/chunk-A4E5YLXO.js +85 -0
  66. package/dist/{chunk-WENCSQ47.js → chunk-EBNI36UQ.js} +1 -1
  67. package/dist/{chunk-6J35F334.js → chunk-GOSQXEZU.js} +1 -1
  68. package/dist/{chunk-M2VJGNCD.js → chunk-GR55WT4R.js} +3 -3
  69. package/dist/chunk-I3BSQUKN.js +121 -0
  70. package/dist/chunk-IDBHX5SR.js +12 -0
  71. package/dist/{chunk-WI6K5M5X.js → chunk-M3LUNN7F.js} +1 -1
  72. package/dist/{chunk-S4RCG44T.js → chunk-MICH6QSJ.js} +1 -1
  73. package/dist/chunk-QMBP23BL.js +347 -0
  74. package/dist/{chunk-G2AVKPSL.js → chunk-RIAZM6L3.js} +1 -1
  75. package/dist/chunk-SKOYC2CF.js +288 -0
  76. package/dist/{chunk-PRNX5AFE.js → chunk-TGYDROIB.js} +1 -1
  77. package/dist/{chunk-G3EEUNZQ.js → chunk-UB7TJEKZ.js} +1 -1
  78. package/dist/chunk-UQHKFF2N.js +106 -0
  79. package/dist/{chunk-WHZFDS62.js → chunk-VDPJGP4Q.js} +1 -1
  80. package/dist/chunk-VOX3YRFO.js +76 -0
  81. package/dist/chunk-YFW4MTK4.js +749 -0
  82. package/dist/generated/index.d.ts +6 -0
  83. package/dist/generated/index.js +83 -75
  84. package/dist/index.js +83 -75
  85. package/dist/styles.css +8849 -7793
  86. package/package.json +13 -3
  87. package/dist/chunk-FVLCTCMV.js +0 -96
  88. package/dist/{chunk-RIEDQSA4.js → chunk-7DZDSSJS.js} +1 -1
  89. package/dist/{chunk-YZCJ63JF.js → chunk-ACA27MZH.js} +1 -1
  90. package/dist/{chunk-ENJUPIND.js → chunk-FZVJDJFN.js} +1 -1
  91. package/dist/{chunk-SGIQCI6Y.js → chunk-LIXSV5YI.js} +1 -1
  92. package/dist/{chunk-NWW4IQJU.js → chunk-OC46246T.js} +0 -0
  93. package/dist/{chunk-VOMYRJV5.js → chunk-RODMM35O.js} +2 -2
  94. package/dist/{chunk-HCKJGBQH.js → chunk-VVRL27HM.js} +1 -1
  95. package/dist/{chunk-D5JZN3ML.js → chunk-Z6VW6CXX.js} +1 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@crewlethq/ui",
3
- "version": "0.28.0",
3
+ "version": "0.30.0",
4
4
  "description": "Crewlet shared React components built on @crewlethq/tokens and @crewlethq/icons.",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -42,8 +42,18 @@
42
42
  "clean": "rm -rf dist src/generated"
43
43
  },
44
44
  "dependencies": {
45
- "@crewlethq/icons": "0.28.0",
46
- "@crewlethq/tokens": "0.28.0",
45
+ "@crewlethq/icons": "0.30.0",
46
+ "@crewlethq/tokens": "0.30.0",
47
+ "prosemirror-commands": "1.7.2",
48
+ "prosemirror-gapcursor": "1.4.1",
49
+ "prosemirror-history": "1.5.1",
50
+ "prosemirror-inputrules": "1.5.1",
51
+ "prosemirror-keymap": "1.2.3",
52
+ "prosemirror-model": "1.25.12",
53
+ "prosemirror-schema-list": "1.5.1",
54
+ "prosemirror-state": "1.4.4",
55
+ "prosemirror-transform": "1.12.2",
56
+ "prosemirror-view": "1.42.6",
47
57
  "uqr": "0.1.3"
48
58
  },
49
59
  "peerDependencies": {
@@ -1,96 +0,0 @@
1
- import { PRESENCE_LABELS, presenceOrder, collapseSessions } from './chunk-Z7JYG5TF.js';
2
- import { Avatar } from './chunk-5OM447RW.js';
3
- import { headingTag, useHeadingLevel } from './chunk-PQADV6P6.js';
4
- import { Button } from './chunk-OG6CL3EB.js';
5
- import { IconButton } from './chunk-4FQT6ZAY.js';
6
- import { cx } from './chunk-ODEQTPFM.js';
7
- import './PeopleRail-R64WVOSH.css';
8
- import { useId } from 'react';
9
- import { isCrewletCharacter } from '@crewlethq/icons/characters';
10
- import { XGlyph } from '@crewlethq/icons/glyphs';
11
- import { jsxs, jsx } from 'react/jsx-runtime';
12
-
13
- var PEOPLE_RAIL_LABELS = {
14
- title: "People here",
15
- close: "Close people",
16
- you: "You",
17
- nobody: "Nobody else is here right now.",
18
- follow: "Follow",
19
- following: "Following",
20
- followName: (name) => `Follow ${name}`,
21
- stopFollowingName: (name) => `Stop following ${name}`,
22
- activity: PRESENCE_LABELS.activity
23
- };
24
- function peopleRailKey(member) {
25
- return member.seat ?? member.id;
26
- }
27
- function PeopleRail({
28
- members,
29
- self,
30
- following,
31
- onFollow,
32
- onClose,
33
- actions,
34
- labels: overrides,
35
- className
36
- }) {
37
- const labels = overrides ? { ...PEOPLE_RAIL_LABELS, ...overrides } : PEOPLE_RAIL_LABELS;
38
- const headingID = useId();
39
- const Heading = headingTag(useHeadingLevel());
40
- const others = presenceOrder(collapseSessions(members));
41
- return /* @__PURE__ */ jsxs("aside", { className: cx("crewlet-people-rail", className), "aria-labelledby": headingID, children: [
42
- /* @__PURE__ */ jsxs("div", { className: "crewlet-people-rail__head", children: [
43
- /* @__PURE__ */ jsx(Heading, { className: "crewlet-people-rail__title", id: headingID, children: labels.title }),
44
- onClose && /* @__PURE__ */ jsx(IconButton, { size: "sm", variant: "ghost", label: labels.close, icon: /* @__PURE__ */ jsx(XGlyph, { size: "sm" }), onClick: onClose })
45
- ] }),
46
- /* @__PURE__ */ jsxs("ul", { role: "list", className: "crewlet-people-rail__list", children: [
47
- self && /* @__PURE__ */ jsxs("li", { className: "crewlet-people-rail__person", children: [
48
- /* @__PURE__ */ jsx(PresenceBadge, { member: self }),
49
- /* @__PURE__ */ jsx("span", { className: "crewlet-people-rail__text", children: /* @__PURE__ */ jsx("span", { className: "crewlet-people-rail__name", children: labels.you }) })
50
- ] }),
51
- others.map((member) => {
52
- const key = peopleRailKey(member);
53
- const followed = following !== void 0 && following === key;
54
- const extra = actions?.(member);
55
- return /* @__PURE__ */ jsxs("li", { className: "crewlet-people-rail__person", children: [
56
- /* @__PURE__ */ jsx(PresenceBadge, { member }),
57
- /* @__PURE__ */ jsxs("span", { className: "crewlet-people-rail__text", children: [
58
- /* @__PURE__ */ jsx("span", { className: "crewlet-people-rail__name", children: member.name }),
59
- /* @__PURE__ */ jsx("span", { className: "crewlet-people-rail__where", children: member.location ?? labels.activity(member.activity, member.kind) })
60
- ] }),
61
- extra !== void 0 && extra !== null || onFollow ? /* @__PURE__ */ jsxs("span", { className: "crewlet-people-rail__actions", children: [
62
- extra,
63
- onFollow && /* @__PURE__ */ jsx(
64
- Button,
65
- {
66
- size: "small",
67
- variant: followed ? "primary" : "secondary",
68
- pressed: followed,
69
- "aria-label": followed ? labels.stopFollowingName(member.name) : labels.followName(member.name),
70
- onClick: () => onFollow(followed ? null : member),
71
- children: followed ? labels.following : labels.follow
72
- }
73
- )
74
- ] }) : null
75
- ] }, key);
76
- })
77
- ] }),
78
- others.length === 0 && /* @__PURE__ */ jsx("p", { className: "crewlet-people-rail__note", children: labels.nobody })
79
- ] });
80
- }
81
- function PresenceBadge({ member }) {
82
- return /* @__PURE__ */ jsx(
83
- Avatar,
84
- {
85
- name: member.name,
86
- kind: member.kind,
87
- src: member.src,
88
- character: member.character !== void 0 && isCrewletCharacter(member.character) ? member.character : void 0,
89
- hue: member.kind === "agent" ? member.hue : void 0,
90
- size: "sm",
91
- decorative: true
92
- }
93
- );
94
- }
95
-
96
- export { PEOPLE_RAIL_LABELS, PeopleRail, peopleRailKey };
@@ -1,5 +1,5 @@
1
- import { Kbd } from './chunk-SMBKXWML.js';
2
1
  import { Textarea } from './chunk-6QFAK2WV.js';
2
+ import { Kbd } from './chunk-SMBKXWML.js';
3
3
  import { cx } from './chunk-ODEQTPFM.js';
4
4
  import './Composer-ABGJIAIR.css';
5
5
  import { forwardRef } from 'react';
@@ -1,6 +1,6 @@
1
1
  import { CardHeaderSlotContext } from './chunk-AV2DXAEL.js';
2
- import { useHeadingLevel, HeadingLevelProvider, nextHeadingLevel, headingTag } from './chunk-PQADV6P6.js';
3
2
  import { Count } from './chunk-BHHIIK3M.js';
3
+ import { useHeadingLevel, HeadingLevelProvider, nextHeadingLevel, headingTag } from './chunk-PQADV6P6.js';
4
4
  import { cx } from './chunk-ODEQTPFM.js';
5
5
  import './Card-KJOYHDTJ.css';
6
6
  import { createContext, useId, useState, isValidElement, useRef, useCallback, useMemo, Children, cloneElement, useContext, useEffect, Fragment } from 'react';
@@ -1,5 +1,5 @@
1
- import { headingTag } from './chunk-PQADV6P6.js';
2
1
  import { Count } from './chunk-BHHIIK3M.js';
2
+ import { headingTag } from './chunk-PQADV6P6.js';
3
3
  import { cx } from './chunk-ODEQTPFM.js';
4
4
  import { ChevronDownGlyph } from '@crewlethq/icons/glyphs';
5
5
  import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
@@ -1,5 +1,5 @@
1
- import { SegmentedControl } from './chunk-RCQXUT5K.js';
2
1
  import { NODE_HUES, NODE_HUE_NAMES } from './chunk-AYKXMIOR.js';
2
+ import { SegmentedControl } from './chunk-RCQXUT5K.js';
3
3
  import { cx } from './chunk-ODEQTPFM.js';
4
4
  import { jsx } from 'react/jsx-runtime';
5
5
 
File without changes
@@ -1,11 +1,11 @@
1
1
  import { PageHeader } from './chunk-HOXGBLEY.js';
2
2
  import { Toolbar } from './chunk-PGRPNDWM.js';
3
- import { DataTable } from './chunk-EBJREOKS.js';
4
3
  import { DateTimePicker } from './chunk-Y5NQ2LMS.js';
4
+ import { DataTable } from './chunk-EBJREOKS.js';
5
5
  import { useListbox, useOptionKeys } from './chunk-F73MC7EZ.js';
6
- import { Kbd } from './chunk-SMBKXWML.js';
7
6
  import { Popover } from './chunk-BWRGFKJP.js';
8
7
  import { Input } from './chunk-6QFAK2WV.js';
8
+ import { Kbd } from './chunk-SMBKXWML.js';
9
9
  import { RelativeTime } from './chunk-3CZ7XAVY.js';
10
10
  import { Count } from './chunk-BHHIIK3M.js';
11
11
  import { Menu } from './chunk-2HIOJ4YZ.js';
@@ -1,7 +1,7 @@
1
1
  import { Modal } from './chunk-I3KKZ2O3.js';
2
2
  import { useListbox, useHighlightRest } from './chunk-F73MC7EZ.js';
3
- import { Kbd } from './chunk-SMBKXWML.js';
4
3
  import { Input } from './chunk-6QFAK2WV.js';
4
+ import { Kbd } from './chunk-SMBKXWML.js';
5
5
  import { Count } from './chunk-BHHIIK3M.js';
6
6
  import { isComposing } from './chunk-R25RGPUB.js';
7
7
  import { VisuallyHidden } from './chunk-BZFWDIV6.js';
@@ -1,5 +1,5 @@
1
- import { Kbd } from './chunk-SMBKXWML.js';
2
1
  import { FormField, Textarea, Input } from './chunk-6QFAK2WV.js';
2
+ import { Kbd } from './chunk-SMBKXWML.js';
3
3
  import { isComposing } from './chunk-R25RGPUB.js';
4
4
  import { announce } from './chunk-RSAQOKH3.js';
5
5
  import { IconButton } from './chunk-4FQT6ZAY.js';