@crewlethq/ui 0.32.0 → 0.34.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/README.md +149 -5
- package/dist/AccessDeniedCard/AccessDeniedCard.d.ts +5 -0
- package/dist/AccessDeniedCard/index.js +1 -5
- package/dist/AccessDeniedCard-QVNDMT46.css +8 -0
- package/dist/AppShell/index.js +4 -4
- package/dist/{AppShell-GCM4TDVY.css → AppShell-JTSEOA57.css} +3 -1
- package/dist/ArrangeGroup/ArrangeGroup.d.ts +16 -1
- package/dist/ArrangeGroup/index.d.ts +1 -1
- package/dist/ArrangeGroup/index.js +1 -1
- package/dist/{ArrangeGroup-GY5YMP6E.css → ArrangeGroup-KRWWOJKR.css} +43 -0
- package/dist/ArrangeList/index.js +2 -2
- package/dist/ArtifactBar/index.js +14 -12
- package/dist/{ArtifactBar-MLMJHWY6.css → ArtifactBar-C462VD4C.css} +8 -3
- package/dist/ArtifactCard/ArtifactCard.d.ts +64 -6
- package/dist/ArtifactCard/index.d.ts +2 -2
- package/dist/ArtifactCard/index.js +6 -4
- package/dist/ArtifactCard-XHRLAL7C.css +289 -0
- package/dist/ArtifactCover/index.js +8 -6
- package/dist/ArtifactIcon/index.js +7 -5
- package/dist/ArtifactKindIllustration/ArtifactKindIllustration.d.ts +53 -0
- package/dist/ArtifactKindIllustration/index.d.ts +3 -0
- package/dist/ArtifactKindIllustration/index.js +3 -0
- package/dist/ArtifactKindIllustration-4NG6IE3C.css +211 -0
- package/dist/ArtifactPanel/ArtifactPanel.d.ts +6 -2
- package/dist/ArtifactPanel/index.js +1 -1
- package/dist/{ArtifactPanel-YFXT5O77.css → ArtifactPanel-HW3SU7CP.css} +25 -7
- package/dist/Avatar/Avatar.d.ts +6 -4
- package/dist/Avatar/index.js +2 -2
- package/dist/AvatarPicker/index.js +8 -8
- package/dist/Callout/index.js +1 -1
- package/dist/{Callout-SXXK4B5R.css → Callout-ZAVG3P66.css} +46 -6
- package/dist/Canvas/Canvas.d.ts +33 -2
- package/dist/Canvas/index.d.ts +1 -1
- package/dist/Canvas/index.js +4 -4
- package/dist/{Canvas-LRVNW7XN.css → Canvas-VUG2HLZK.css} +23 -0
- package/dist/CanvasBoard/CanvasBoard.d.ts +38 -3
- package/dist/CanvasBoard/budget.d.ts +9 -3
- package/dist/CanvasBoard/index.d.ts +2 -2
- package/dist/CanvasBoard/index.js +7 -7
- package/dist/{CanvasBoard-MBZVBWDO.css → CanvasBoard-5NNSKY6A.css} +127 -6
- package/dist/CanvasToolbar/index.js +5 -5
- package/dist/{CanvasToolbar-AE5MXH7T.css → CanvasToolbar-EM5EVZED.css} +4 -2
- package/dist/ChangeMark/index.js +4 -4
- package/dist/CharacterPicker/index.js +2 -2
- package/dist/Charts/ActivityStrip.d.ts +16 -1
- package/dist/Charts/BarList.d.ts +6 -0
- package/dist/Charts/ChartEmpty.d.ts +33 -0
- package/dist/Charts/Legend.d.ts +6 -0
- package/dist/Charts/StackedBar.d.ts +4 -1
- package/dist/Charts/StackedColumns.d.ts +14 -3
- package/dist/Charts/TimeSeries.d.ts +11 -1
- package/dist/Charts/index.d.ts +2 -0
- package/dist/Charts/index.js +1 -1
- package/dist/{Charts-RY4JN5FC.css → Charts-MBJG72BS.css} +140 -16
- package/dist/Checkbox/index.js +1 -1
- package/dist/{Checkbox-5UORUG3F.css → Checkbox-ALWG3WV2.css} +11 -0
- package/dist/CommandPalette/index.js +3 -3
- package/dist/{CommandPalette-HBTNKHZQ.css → CommandPalette-7CFGVBND.css} +4 -0
- package/dist/CommentThread/index.js +5 -5
- package/dist/Container/index.js +1 -1
- package/dist/{Container-3TSKMGNI.css → Container-34BAKG7B.css} +3 -1
- package/dist/{DashboardCover-RMINBODB.css → DashboardCover-KYGYMRKW.css} +42 -9
- package/dist/DataTable/index.js +5 -5
- package/dist/{DataTable-WZK3V62B.css → DataTable-NL2YWAIA.css} +4 -1
- package/dist/DataView/index.js +8 -8
- package/dist/DateTimePicker/index.js +3 -3
- package/dist/DocTabsEditor/DocTabsEditor.d.ts +34 -21
- package/dist/DocTabsEditor/index.js +4 -1
- package/dist/DocTabsEditor-4M452LNS.css +189 -0
- package/dist/Document/Document.d.ts +18 -1
- package/dist/Document/index.d.ts +2 -2
- package/dist/Document/index.js +1 -1
- package/dist/{Document-G3YTZIUL.css → Document-JUGCSQ4L.css} +78 -5
- package/dist/EditingStatus/index.js +1 -1
- package/dist/{EditingStatus-L6THUAN7.css → EditingStatus-NNA2CKIL.css} +17 -4
- package/dist/{Editor-YWBUJAQU.js → Editor-UUZ7XKCU.js} +5 -5
- package/dist/EntityChip/index.js +3 -3
- package/dist/FactList/index.js +3 -3
- package/dist/FollowBanner/index.js +3 -3
- package/dist/Fullscreen/index.d.ts +1 -0
- package/dist/Fullscreen/index.js +1 -1
- package/dist/Fullscreen/useIdle.d.ts +16 -0
- package/dist/HuePicker/index.js +3 -3
- package/dist/ImageUpload/index.js +3 -3
- package/dist/Layer/index.d.ts +1 -1
- package/dist/Layer/index.js +1 -1
- package/dist/Layer/place.d.ts +18 -0
- package/dist/LayersList/LayersList.d.ts +57 -0
- package/dist/LayersList/index.d.ts +3 -0
- package/dist/LayersList/index.js +3 -0
- package/dist/LayersList-NQZEIPZB.css +82 -0
- package/dist/LinkInterstitial/index.js +4 -4
- package/dist/ListInput/index.js +1 -1
- package/dist/LivePreview/LivePreview.d.ts +83 -0
- package/dist/LivePreview/budget.d.ts +50 -0
- package/dist/LivePreview/index.d.ts +5 -0
- package/dist/LivePreview/index.js +2 -0
- package/dist/LivePreview-SRO7KHO4.css +65 -0
- package/dist/Markdown/index.js +1 -1
- package/dist/MarkdownEditor/index.js +5 -5
- package/dist/MediaMatch/index.d.ts +1 -0
- package/dist/MediaMatch/index.js +1 -0
- package/dist/MediaMatch/useMediaMatch.d.ts +19 -0
- package/dist/Menu/index.js +2 -2
- package/dist/MergeConflicts/index.js +4 -4
- package/dist/Modal/index.js +2 -2
- package/dist/{Modal-XOSV6FAH.css → Modal-7MWRCWAI.css} +30 -0
- package/dist/Note/index.js +1 -1
- package/dist/{Note-ONSKKTOA.css → Note-WI5MLZOO.css} +13 -0
- package/dist/OrgLabel/index.js +3 -3
- package/dist/OrgNode/index.js +4 -4
- package/dist/OrgTable/index.js +7 -7
- package/dist/PeopleRail/index.js +3 -3
- package/dist/Popover/index.js +2 -2
- package/dist/PresenceStack/index.js +3 -3
- package/dist/{PresenceStack-QSXQJND5.css → PresenceStack-FJJQVH74.css} +11 -3
- package/dist/PresenterView/PresenterView.d.ts +3 -0
- package/dist/PresenterView/index.js +5 -3
- package/dist/PresenterView-T3EXIQ5S.css +147 -0
- package/dist/Principal/index.js +3 -3
- package/dist/PrincipalPicker/index.js +4 -4
- package/dist/RichEditor/index.js +5 -5
- package/dist/RichEditor/schema.d.ts +1 -1
- package/dist/RichEditorMarkdown/index.js +3 -3
- package/dist/SandboxedFrame/SandboxedFrame.d.ts +44 -2
- package/dist/SandboxedFrame/index.d.ts +2 -2
- package/dist/SandboxedFrame/index.js +3 -3
- package/dist/SandboxedFrame-P5NASXB7.css +72 -0
- package/dist/Section/index.js +1 -1
- package/dist/{Section-QR3ILQVK.css → Section-O5AHGSOG.css} +28 -5
- package/dist/SegmentedControl/index.js +3 -3
- package/dist/Select/Select.d.ts +10 -0
- package/dist/Select/index.d.ts +1 -1
- package/dist/Select/index.js +2 -2
- package/dist/{Select-2P7AWUE4.css → Select-A54YS5EP.css} +29 -0
- package/dist/ShareDialog/ShareDialog.d.ts +10 -0
- package/dist/ShareDialog/index.js +9 -9
- package/dist/{ShareDialog-YZ4F37MW.css → ShareDialog-4QDCBWMH.css} +12 -0
- package/dist/SheetGrid/SheetGrid.d.ts +7 -3
- package/dist/SheetGrid/index.js +8 -8
- package/dist/{SheetGrid-J3TKKXZL.css → SheetGrid-GDPCCZ4V.css} +154 -14
- package/dist/SheetModel/fit.d.ts +34 -0
- package/dist/SheetModel/index.d.ts +1 -0
- package/dist/SheetModel/index.js +1 -1
- package/dist/SheetModel/labels.d.ts +1 -1
- package/dist/Shortcut/index.js +1 -1
- package/dist/Skeleton/Skeleton.d.ts +2 -1
- package/dist/Skeleton/index.js +1 -1
- package/dist/SlideCompare/SlideCompare.d.ts +6 -1
- package/dist/SlideCompare/index.js +3 -3
- package/dist/{SlideCompare-MGM3U2ME.css → SlideCompare-HTCMPQFY.css} +36 -3
- package/dist/SlideFilmstrip/SlideFilmstrip.d.ts +14 -3
- package/dist/SlideFilmstrip/index.js +3 -3
- package/dist/{SlideFilmstrip-BCLNAHFX.css → SlideFilmstrip-5U6Z55GS.css} +63 -2
- package/dist/SlideGrid/index.js +3 -3
- package/dist/{SlideGrid-RT6QEQEE.css → SlideGrid-S4LTJ4UU.css} +9 -5
- package/dist/SlideNav/SlideNav.d.ts +49 -0
- package/dist/SlideNav/index.d.ts +3 -0
- package/dist/SlideNav/index.js +4 -0
- package/dist/SlideNav-BLFJF6AH.css +53 -0
- package/dist/SlideStage/SlideStage.d.ts +9 -1
- package/dist/SlideStage/index.js +2 -2
- package/dist/{SlideStage-KGRRALXR.css → SlideStage-S2FISF4C.css} +23 -0
- package/dist/StatCard/StatCard.d.ts +16 -1
- package/dist/StatCard/index.js +1 -1
- package/dist/{StatCard-KPAFD4E2.css → StatCard-4T7TMWMN.css} +40 -13
- package/dist/Switcher/index.js +6 -6
- package/dist/TableCells/index.js +3 -3
- package/dist/Tabs/Tabs.d.ts +21 -4
- package/dist/Tabs/index.js +1 -1
- package/dist/{Tabs-CJGO35BH.css → Tabs-MMZXV5EF.css} +9 -8
- package/dist/TagsInput/index.js +1 -1
- package/dist/ThemeSwitcher/index.js +4 -4
- package/dist/TimeWindowPicker/index.js +4 -4
- package/dist/Toaster/index.js +2 -2
- package/dist/{Toaster-EOOOTSJT.css → Toaster-C6BQ7L6I.css} +10 -1
- package/dist/Toolbar/index.js +1 -1
- package/dist/Tooltip/Tooltip.d.ts +12 -1
- package/dist/Tooltip/index.d.ts +1 -1
- package/dist/Tooltip/index.js +2 -2
- package/dist/TreeCanvas/index.js +5 -5
- package/dist/TreeGrid/index.js +3 -3
- package/dist/VersionCompare/index.js +4 -4
- package/dist/VersionTimeline/index.js +4 -4
- package/dist/WidgetFrame/WidgetFrame.d.ts +8 -1
- package/dist/WidgetFrame/index.js +2 -2
- package/dist/{WidgetFrame-LRZIL62O.css → WidgetFrame-BTFW3CRK.css} +49 -5
- package/dist/{chunk-WJDQ7XQA.js → chunk-2QEDJSJC.js} +1 -1
- package/dist/{chunk-VYDFB6PJ.js → chunk-356JNSER.js} +50 -17
- package/dist/{chunk-2HIOJ4YZ.js → chunk-3EB2AV3H.js} +2 -3
- package/dist/{chunk-ODT5H4MN.js → chunk-3LYWD3BO.js} +2 -2
- package/dist/{chunk-OTN35CI4.js → chunk-3P4Y5RX6.js} +18 -6
- package/dist/{chunk-FAQGGX2Z.js → chunk-3TFDQLW3.js} +1 -1
- package/dist/{chunk-E6EWK5YY.js → chunk-3Y56GQPM.js} +3 -3
- package/dist/{chunk-A4E5YLXO.js → chunk-4B6LSFDS.js} +1 -1
- package/dist/{chunk-UAN5NE7M.js → chunk-5AQBPHZD.js} +1 -1
- package/dist/{chunk-CJKMURZO.js → chunk-5SZGKSGL.js} +1 -1
- package/dist/chunk-6VOS2GMB.js +54 -0
- package/dist/{chunk-QWOPX2MN.js → chunk-6ZJ3N7QI.js} +7 -5
- package/dist/{chunk-3ZAFJ4GK.js → chunk-7Q7WDXHG.js} +4 -4
- package/dist/{chunk-QH3AKP2N.js → chunk-AC22RZKC.js} +2 -2
- package/dist/{chunk-UZ6MA2V6.js → chunk-AORVEG5V.js} +2 -2
- package/dist/{chunk-ZITJKF6Z.js → chunk-AYB6AYNH.js} +1 -1
- package/dist/{chunk-FC4YTTFJ.js → chunk-BQ7AKL2N.js} +5 -5
- package/dist/{chunk-Y5NQ2LMS.js → chunk-BY4N65PM.js} +1 -1
- package/dist/{chunk-YFW4MTK4.js → chunk-C7DKX453.js} +1 -1
- package/dist/{chunk-RCQXUT5K.js → chunk-CCAXYHQS.js} +1 -1
- package/dist/{chunk-JQLTG4KH.js → chunk-CCLNGVCM.js} +62 -51
- package/dist/{chunk-6AH2XJ3Q.js → chunk-CFAJP777.js} +3 -3
- package/dist/{chunk-4KP4RC3O.js → chunk-CI3VPIJN.js} +1 -1
- package/dist/{chunk-7T42VQQT.js → chunk-CPEPST4S.js} +1 -1
- package/dist/{chunk-AAOH2P6Y.js → chunk-DFK5EQTU.js} +5 -3
- package/dist/{chunk-V5IGUXMZ.js → chunk-E4NNGC6X.js} +4 -4
- package/dist/{chunk-TGYDROIB.js → chunk-EBCHVFCS.js} +4 -4
- package/dist/{chunk-LWXRD6L6.js → chunk-EWAFN2IU.js} +118 -27
- package/dist/{chunk-YDBC4DNW.js → chunk-FWYHRU7M.js} +1 -1
- package/dist/{chunk-HVNTQ36V.js → chunk-GMU6SQ6B.js} +4 -4
- package/dist/{chunk-LIXSV5YI.js → chunk-GPHWCK7M.js} +1 -1
- package/dist/{chunk-UQHKFF2N.js → chunk-GPWJCP3U.js} +1 -1
- package/dist/{chunk-77DRMDXR.js → chunk-HG5VF3TZ.js} +192 -67
- package/dist/{chunk-QVE4GJAT.js → chunk-HJO4WCH6.js} +1 -1
- package/dist/{chunk-JI5AVQLA.js → chunk-HOIZ6MIS.js} +1 -1
- package/dist/{chunk-I3BSQUKN.js → chunk-HUVG2FFT.js} +1 -1
- package/dist/{chunk-VS3KOOOL.js → chunk-ILAEBSLJ.js} +3 -3
- package/dist/{chunk-P4BOXB6E.js → chunk-IUD5VA2Z.js} +6 -7
- package/dist/{chunk-GR55WT4R.js → chunk-IYO2N5ZH.js} +2 -2
- package/dist/{chunk-RWA4H2TV.js → chunk-J6ON5SYE.js} +1 -1
- package/dist/{chunk-AMNN4WDX.js → chunk-JBUMD6DS.js} +2 -2
- package/dist/{chunk-BWRGFKJP.js → chunk-K3IJQNB7.js} +2 -3
- package/dist/{chunk-LFNUH4GY.js → chunk-K4VP6ZKE.js} +1 -1
- package/dist/{chunk-ZR5VN5IV.js → chunk-KD2IRYCT.js} +2 -2
- package/dist/chunk-KF6YGL4B.js +160 -0
- package/dist/{chunk-SKOYC2CF.js → chunk-KK5OYNAF.js} +2 -1
- package/dist/{chunk-UB7TJEKZ.js → chunk-KV3ODJXH.js} +6 -7
- package/dist/chunk-LL5AFXU7.js +96 -0
- package/dist/{chunk-VYOKRN2I.js → chunk-LM3ISVJA.js} +1 -1
- package/dist/{chunk-E6CR5PEV.js → chunk-LV4APO72.js} +8 -2
- package/dist/{chunk-B4EBHPK3.js → chunk-M5KZX5JE.js} +9 -2
- package/dist/{chunk-HMPFGIWM.js → chunk-OMV5W53A.js} +10 -1
- package/dist/chunk-ONL54WMH.js +55 -0
- package/dist/{chunk-AKEZ3G5V.js → chunk-ONQKKHON.js} +1 -1
- package/dist/{chunk-LZHLSQYK.js → chunk-OOWPSBIS.js} +2 -2
- package/dist/{chunk-4KWOKX2B.js → chunk-OSKJZNBT.js} +1 -1
- package/dist/{chunk-4JUKWWUD.js → chunk-PLDUNXAO.js} +1 -1
- package/dist/{chunk-EHQTPVV4.js → chunk-PLTCDSTU.js} +1 -1
- package/dist/{chunk-5OM447RW.js → chunk-PZKHBB7D.js} +1 -1
- package/dist/{chunk-VEB5ERRE.js → chunk-QWNVSR6G.js} +2 -2
- package/dist/{chunk-IG75YMUN.js → chunk-RTPQDNW3.js} +1 -1
- package/dist/{chunk-YEKYVJQR.js → chunk-SGHIAGPR.js} +2 -2
- package/dist/{chunk-SVSCLHHI.js → chunk-SZZRIHGT.js} +1 -1
- package/dist/{chunk-EBNI36UQ.js → chunk-T46NR3WP.js} +3 -3
- package/dist/{chunk-FPS3JIPQ.js → chunk-TC7DJTXI.js} +1 -1
- package/dist/{chunk-W5J7R5EB.js → chunk-TEUQWOWZ.js} +1 -1
- package/dist/chunk-THROPJZC.js +115 -0
- package/dist/{chunk-IDBHX5SR.js → chunk-TRQCHF2F.js} +1 -1
- package/dist/{chunk-M3LUNN7F.js → chunk-TYKQ33CL.js} +13 -2
- package/dist/chunk-UDQW6UK7.js +129 -0
- package/dist/{chunk-WTNUVQVI.js → chunk-UHJQDFKQ.js} +1 -1
- package/dist/{chunk-VVRL27HM.js → chunk-ULPL26BU.js} +2 -2
- package/dist/{chunk-EBJREOKS.js → chunk-UXXJDIYE.js} +4 -4
- package/dist/{chunk-5LUI3WQP.js → chunk-V43UVX4H.js} +1 -1
- package/dist/{chunk-W4XYY73O.js → chunk-VHZ3AXJD.js} +1 -1
- package/dist/{chunk-NHBP2XS5.js → chunk-VI5FWDZW.js} +51 -3
- package/dist/{chunk-HJEVSQN6.js → chunk-VL6CUNSX.js} +11 -5
- package/dist/{chunk-XDTYBF2F.js → chunk-W5XCNEZC.js} +39 -1
- package/dist/{chunk-LDJ3J4TQ.js → chunk-WGD2HX2A.js} +1 -1
- package/dist/{chunk-FQCLKD7U.js → chunk-WKEPORNM.js} +1 -1
- package/dist/{chunk-PJD2KFHX.js → chunk-WPX6A5BV.js} +38 -13
- package/dist/{chunk-I3KKZ2O3.js → chunk-XEGZHHRH.js} +45 -36
- package/dist/{chunk-IKB6HFGK.js → chunk-XO7PUL4F.js} +6 -4
- package/dist/chunk-XTOVADJU.js +170 -0
- package/dist/chunk-XV32RKQZ.js +142 -0
- package/dist/{chunk-TBMDMXEX.js → chunk-YA3AWELW.js} +1 -1
- package/dist/{chunk-HVIX5ECM.js → chunk-YEVG2X5R.js} +1 -1
- package/dist/chunk-YZFLH463.js +215 -0
- package/dist/generated/index.d.ts +5 -0
- package/dist/generated/index.js +112 -108
- package/dist/index.js +112 -108
- package/dist/styles.css +1982 -228
- package/package.json +3 -3
- package/dist/AccessDeniedCard-WXM5DBDZ.css +0 -8
- package/dist/ArtifactCard-EXVAEBV6.css +0 -109
- package/dist/DocTabsEditor-RCOWHX5J.css +0 -78
- package/dist/PresenterView-T2C6ZZ3N.css +0 -103
- package/dist/SandboxedFrame-L6HBQZCD.css +0 -50
- package/dist/chunk-CRKFL423.js +0 -74
- package/dist/chunk-GOSQXEZU.js +0 -102
- package/dist/chunk-MBNFJSZS.js +0 -107
- package/dist/chunk-RV7SZAHR.js +0 -105
- package/dist/chunk-UZ7ZUSLH.js +0 -179
- package/dist/utils/useMediaMatch.d.ts +0 -12
- /package/dist/{chunk-TF2P3OPS.js → chunk-YCARLYI6.js} +0 -0
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { Select } from './chunk-
|
|
1
|
+
import { Select } from './chunk-BQ7AKL2N.js';
|
|
2
2
|
import { CopyButton } from './chunk-W46LPU4R.js';
|
|
3
|
-
import { Modal } from './chunk-
|
|
4
|
-
import { Callout } from './chunk-
|
|
5
|
-
import { PrincipalAvatar } from './chunk-
|
|
3
|
+
import { Modal } from './chunk-XEGZHHRH.js';
|
|
4
|
+
import { Callout } from './chunk-SZZRIHGT.js';
|
|
5
|
+
import { PrincipalAvatar } from './chunk-CI3VPIJN.js';
|
|
6
6
|
import { useHeadingLevel, headingTag } from './chunk-PQADV6P6.js';
|
|
7
|
-
import { useMediaMatch } from './chunk-
|
|
7
|
+
import { useMediaMatch } from './chunk-RTPQDNW3.js';
|
|
8
8
|
import { Button } from './chunk-OG6CL3EB.js';
|
|
9
9
|
import { IconButton } from './chunk-4FQT6ZAY.js';
|
|
10
10
|
import { cx } from './chunk-ODEQTPFM.js';
|
|
11
|
-
import './ShareDialog-
|
|
11
|
+
import './ShareDialog-4QDCBWMH.css';
|
|
12
12
|
import { useState, useId } from 'react';
|
|
13
13
|
import { breakpoint } from '@crewlethq/tokens';
|
|
14
14
|
import { XGlyph } from '@crewlethq/icons/glyphs';
|
|
@@ -43,6 +43,7 @@ var LABELS = {
|
|
|
43
43
|
},
|
|
44
44
|
roleFor: (name) => `Role for ${name}`,
|
|
45
45
|
remove: (name) => `Remove ${name}`,
|
|
46
|
+
noAccess: "No access",
|
|
46
47
|
saving: "Saving",
|
|
47
48
|
busy: "Wait for the change to finish.",
|
|
48
49
|
agentNote: (name, role) => `${name} can ${AGENT_CAN[role]}.`,
|
|
@@ -143,52 +144,62 @@ function ShareDialog({
|
|
|
143
144
|
/* @__PURE__ */ jsx(Heading, { id: audienceId, className: "crewlet-share-dialog__heading", children: text.audience }),
|
|
144
145
|
/* @__PURE__ */ jsx("ul", { className: "crewlet-share-dialog__audience", children: audience.map((row) => {
|
|
145
146
|
const direct = row.via === void 0 && row.role !== "owner";
|
|
146
|
-
const
|
|
147
|
-
const
|
|
148
|
-
const
|
|
147
|
+
const invalid = row.invalid !== void 0 && row.invalid !== "";
|
|
148
|
+
const editable = !invalid && !readOnly && onRoleChange !== void 0 && (row.editable ?? direct);
|
|
149
|
+
const removable = !readOnly && onRemove !== void 0 && (invalid ? row.removable ?? true : row.removable ?? (row.editable ?? direct));
|
|
150
|
+
const rowNote = invalid ? void 0 : row.note ?? (row.principal.kind === "agent" ? text.agentNote(row.principal.name, row.role) : void 0);
|
|
149
151
|
const detail = row.via ?? row.principal.detail;
|
|
150
|
-
return /* @__PURE__ */ jsxs(
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
152
|
+
return /* @__PURE__ */ jsxs(
|
|
153
|
+
"li",
|
|
154
|
+
{
|
|
155
|
+
className: cx("crewlet-share-dialog__row", row.pending && "is-pending", invalid && "is-invalid"),
|
|
156
|
+
"aria-busy": row.pending || void 0,
|
|
157
|
+
children: [
|
|
158
|
+
/* @__PURE__ */ jsx(PrincipalAvatar, { principal: row.principal, size: "md" }),
|
|
159
|
+
/* @__PURE__ */ jsxs("span", { className: "crewlet-share-dialog__who", children: [
|
|
160
|
+
/* @__PURE__ */ jsxs("span", { className: "crewlet-share-dialog__name", children: [
|
|
161
|
+
row.principal.name,
|
|
162
|
+
row.self ? /* @__PURE__ */ jsxs("span", { className: "crewlet-share-dialog__you", children: [
|
|
163
|
+
" ",
|
|
164
|
+
text.you
|
|
165
|
+
] }) : null
|
|
166
|
+
] }),
|
|
167
|
+
detail ? /* @__PURE__ */ jsx("span", { className: "crewlet-share-dialog__detail", children: detail }) : null
|
|
168
|
+
] }),
|
|
169
|
+
/* @__PURE__ */ jsxs("span", { className: "crewlet-share-dialog__controls", children: [
|
|
170
|
+
row.pending ? /* @__PURE__ */ jsx("span", { className: "crewlet-share-dialog__saving", children: text.saving }) : null,
|
|
171
|
+
editable && row.role !== "owner" ? /* @__PURE__ */ jsx(
|
|
172
|
+
Select,
|
|
173
|
+
{
|
|
174
|
+
value: row.role,
|
|
175
|
+
options: roleOptions,
|
|
176
|
+
onChange: (value) => onRoleChange(row, value),
|
|
177
|
+
ariaLabel: text.roleFor(row.principal.name),
|
|
178
|
+
disabled: row.pending ?? false,
|
|
179
|
+
size: "sm",
|
|
180
|
+
width: "auto",
|
|
181
|
+
align: "right"
|
|
182
|
+
}
|
|
183
|
+
) : /* @__PURE__ */ jsx("span", { className: "crewlet-share-dialog__role", children: invalid ? text.noAccess : text.roles[row.role] }),
|
|
184
|
+
removable ? /* @__PURE__ */ jsx(
|
|
185
|
+
IconButton,
|
|
186
|
+
{
|
|
187
|
+
label: text.remove(row.principal.name),
|
|
188
|
+
icon: /* @__PURE__ */ jsx(XGlyph, {}),
|
|
189
|
+
size: "sm",
|
|
190
|
+
variant: "ghost",
|
|
191
|
+
disabledReason: row.pending ? text.busy : void 0,
|
|
192
|
+
onClick: () => onRemove(row)
|
|
193
|
+
}
|
|
194
|
+
) : null
|
|
195
|
+
] }),
|
|
196
|
+
rowNote ? /* @__PURE__ */ jsx("span", { className: "crewlet-share-dialog__note", children: rowNote }) : null,
|
|
197
|
+
invalid ? /* @__PURE__ */ jsx("span", { className: "crewlet-share-dialog__invalid", children: row.invalid }) : null,
|
|
198
|
+
/* @__PURE__ */ jsx("span", { className: "crewlet-share-dialog__refusal", "aria-live": "polite", children: row.refusal ?? "" })
|
|
199
|
+
]
|
|
200
|
+
},
|
|
201
|
+
row.id
|
|
202
|
+
);
|
|
192
203
|
}) })
|
|
193
204
|
] }),
|
|
194
205
|
/* @__PURE__ */ jsxs("section", { className: "crewlet-share-dialog__section", "aria-labelledby": companyId, "aria-busy": companyPending || void 0, children: [
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { Document } from './chunk-
|
|
2
|
-
import { ArtifactKindGlyph } from './chunk-
|
|
1
|
+
import { Document } from './chunk-TYKQ33CL.js';
|
|
2
|
+
import { ArtifactKindGlyph } from './chunk-XTOVADJU.js';
|
|
3
3
|
import { cx } from './chunk-ODEQTPFM.js';
|
|
4
4
|
import './ArtifactCover-D4MBEJ5H.css';
|
|
5
|
-
import './DashboardCover-
|
|
5
|
+
import './DashboardCover-KYGYMRKW.css';
|
|
6
6
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
7
7
|
|
|
8
8
|
function DocCover({ children, className }) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { FormField } from './chunk-6QFAK2WV.js';
|
|
2
2
|
import { cx } from './chunk-ODEQTPFM.js';
|
|
3
|
-
import './Checkbox-
|
|
3
|
+
import './Checkbox-ALWG3WV2.css';
|
|
4
4
|
import { forwardRef, useId, useRef, useCallback, useEffect } from 'react';
|
|
5
5
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
6
6
|
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { Skeleton } from './chunk-
|
|
1
|
+
import { Skeleton } from './chunk-TEUQWOWZ.js';
|
|
2
2
|
import { RelativeTime } from './chunk-3CZ7XAVY.js';
|
|
3
3
|
import { VisuallyHidden } from './chunk-BZFWDIV6.js';
|
|
4
4
|
import { cx } from './chunk-ODEQTPFM.js';
|
|
5
|
-
import './WidgetFrame-
|
|
5
|
+
import './WidgetFrame-BTFW3CRK.css';
|
|
6
6
|
import { useId } from 'react';
|
|
7
7
|
import { ClockGlyph, LockGlyph, CircleAlertGlyph } from '@crewlethq/icons/glyphs';
|
|
8
8
|
import { jsxs, Fragment, jsx } from 'react/jsx-runtime';
|
|
@@ -22,6 +22,7 @@ function WidgetFrame({
|
|
|
22
22
|
onCite,
|
|
23
23
|
actions,
|
|
24
24
|
flush = false,
|
|
25
|
+
holdTitle = false,
|
|
25
26
|
headingLevel = 3,
|
|
26
27
|
now,
|
|
27
28
|
labels,
|
|
@@ -36,7 +37,7 @@ function WidgetFrame({
|
|
|
36
37
|
const citation = /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
37
38
|
/* @__PURE__ */ jsx(VisuallyHidden, { children: text.cite }),
|
|
38
39
|
" ",
|
|
39
|
-
/* @__PURE__ */ jsx("span", { className: "crewlet-widget-frame__source", children: source.label }),
|
|
40
|
+
/* @__PURE__ */ jsx("span", { className: "crewlet-widget-frame__source", title: source.label, children: source.label }),
|
|
40
41
|
source.status === "live" ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
41
42
|
" ",
|
|
42
43
|
/* @__PURE__ */ jsx("span", { className: "crewlet-widget-frame__when", children: text.live })
|
|
@@ -64,6 +65,7 @@ function WidgetFrame({
|
|
|
64
65
|
"crewlet-widget-frame",
|
|
65
66
|
`crewlet-widget-frame--${source.status}`,
|
|
66
67
|
flush && "crewlet-widget-frame--flush",
|
|
68
|
+
holdTitle && "crewlet-widget-frame--hold-title",
|
|
67
69
|
className
|
|
68
70
|
),
|
|
69
71
|
"aria-labelledby": titleId,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { richEditorLabels } from './chunk-
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { richEditorLabels } from './chunk-4B6LSFDS.js';
|
|
2
|
+
import { Callout } from './chunk-SZZRIHGT.js';
|
|
3
|
+
import { Skeleton } from './chunk-TEUQWOWZ.js';
|
|
4
4
|
import { Button } from './chunk-OG6CL3EB.js';
|
|
5
5
|
import './RichEditor-NPD2KAPS.css';
|
|
6
6
|
import { forwardRef, useState, useEffect } from 'react';
|
|
@@ -9,7 +9,7 @@ import { jsx } from 'react/jsx-runtime';
|
|
|
9
9
|
var engine = null;
|
|
10
10
|
var loading = null;
|
|
11
11
|
function loadEngine() {
|
|
12
|
-
loading ??= import('./Editor-
|
|
12
|
+
loading ??= import('./Editor-UUZ7XKCU.js').then(
|
|
13
13
|
(module) => {
|
|
14
14
|
engine = module.Editor;
|
|
15
15
|
return engine;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { HuePicker } from './chunk-
|
|
2
|
-
import { Popover } from './chunk-
|
|
1
|
+
import { HuePicker } from './chunk-GPHWCK7M.js';
|
|
2
|
+
import { Popover } from './chunk-K3IJQNB7.js';
|
|
3
3
|
import { NODE_HUE_NAMES } from './chunk-AYKXMIOR.js';
|
|
4
|
-
import { CharacterPicker } from './chunk-
|
|
5
|
-
import { Avatar } from './chunk-
|
|
4
|
+
import { CharacterPicker } from './chunk-YEVG2X5R.js';
|
|
5
|
+
import { Avatar } from './chunk-PZKHBB7D.js';
|
|
6
6
|
import { cx } from './chunk-ODEQTPFM.js';
|
|
7
7
|
import './AvatarPicker-PREY36MG.css';
|
|
8
8
|
import { CREWLET_CHARACTER_GEOMETRY, CREWLET_CHARACTERS } from '@crewlethq/icons/characters';
|
|
@@ -3,16 +3,18 @@ import { Tag } from './chunk-GFV4LJHH.js';
|
|
|
3
3
|
import { StatusDot } from './chunk-WIATRXEJ.js';
|
|
4
4
|
import { CursorFlag } from './chunk-3BYIWOTV.js';
|
|
5
5
|
import { presenceHueClass } from './chunk-I6POAB4V.js';
|
|
6
|
-
import { ChangeMark } from './chunk-
|
|
7
|
-
import { isEmptyValue, displayText, ratingMax, findPerson, findOption, statusTone, editText, textMax, sheetLabels, normalizeValue, sameValue, spokenText, drawnColumns, sortRows, SHEET_ROW_HEIGHT, cellKey, columnOffsets, SHEET_ROW_NUMBER_WIDTH,
|
|
6
|
+
import { ChangeMark } from './chunk-SGHIAGPR.js';
|
|
7
|
+
import { isEmptyValue, displayText, ratingMax, findPerson, findOption, statusTone, editText, textMax, sheetLabels, normalizeValue, sameValue, spokenText, drawnColumns, fitSamples, fittedWidth, columnWidth, SHEET_COLUMN_BOUNDS, sortRows, SHEET_ROW_HEIGHT, cellKey, columnOffsets, SHEET_ROW_NUMBER_WIDTH, rangeOf, presenceByCell, presenceByRow, presenceByColumn, scrollToRow, planClear, visibleRows, cellDescription, nextSort, rowName, inRange, hasPrevious, flagText, toTSV, planPaste, parseTSV, isMod, moveFrom, isTypingKey, editorSide, optionHue, parseText, liveOptions, checkValue } from './chunk-VI5FWDZW.js';
|
|
8
8
|
import { presenceLabels } from './chunk-Z7JYG5TF.js';
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
9
|
+
import { Tooltip } from './chunk-6ZJ3N7QI.js';
|
|
10
|
+
import { Avatar } from './chunk-PZKHBB7D.js';
|
|
11
|
+
import { Menu } from './chunk-3EB2AV3H.js';
|
|
11
12
|
import { isComposing } from './chunk-R25RGPUB.js';
|
|
12
13
|
import { Button } from './chunk-OG6CL3EB.js';
|
|
14
|
+
import { IconButton } from './chunk-4FQT6ZAY.js';
|
|
13
15
|
import { VisuallyHidden } from './chunk-BZFWDIV6.js';
|
|
14
16
|
import { cx } from './chunk-ODEQTPFM.js';
|
|
15
|
-
import './SheetGrid-
|
|
17
|
+
import './SheetGrid-GDPCCZ4V.css';
|
|
16
18
|
import { useId, useRef, useMemo, useState, useLayoutEffect, useEffect, useCallback } from 'react';
|
|
17
19
|
import { CheckGlyph, StarGlyph, CircleAlertGlyph, ArrowUpGlyph, ArrowDownGlyph, TrashGlyph, EllipsisGlyph, RotateCcwClockGlyph, PlusGlyph } from '@crewlethq/icons/glyphs';
|
|
18
20
|
import { isCrewletCharacter } from '@crewlethq/icons/characters';
|
|
@@ -615,6 +617,7 @@ var DateCell = (props) => /* @__PURE__ */ jsx(SheetCell, { ...props, type: "date
|
|
|
615
617
|
var UrlCell = (props) => /* @__PURE__ */ jsx(SheetCell, { ...props, type: "url" });
|
|
616
618
|
var RatingCell = (props) => /* @__PURE__ */ jsx(SheetCell, { ...props, type: "rating" });
|
|
617
619
|
var HEADER = -1;
|
|
620
|
+
var FROZEN_SHARE = 0.6;
|
|
618
621
|
function SheetGrid({
|
|
619
622
|
label,
|
|
620
623
|
columns: declared,
|
|
@@ -647,7 +650,59 @@ function SheetGrid({
|
|
|
647
650
|
const labels = useMemo(() => sheetLabels(labelOverrides), [labelOverrides]);
|
|
648
651
|
const said = useMemo(() => presenceLabels(presenceOverrides), [presenceOverrides]);
|
|
649
652
|
const context = useMemo(() => ({ people, locale, labels }), [people, locale, labels]);
|
|
650
|
-
const
|
|
653
|
+
const ordered = useMemo(() => drawnColumns(declared), [declared]);
|
|
654
|
+
const [viewportWidth, setViewportWidth] = useState(0);
|
|
655
|
+
const latestRows = useRef(given);
|
|
656
|
+
useLayoutEffect(() => {
|
|
657
|
+
latestRows.current = given;
|
|
658
|
+
});
|
|
659
|
+
const hasRows = given.length > 0;
|
|
660
|
+
const [samples, setSamples] = useState(null);
|
|
661
|
+
useLayoutEffect(() => {
|
|
662
|
+
const from = hasRows ? latestRows.current : [];
|
|
663
|
+
setSamples(new Map(ordered.filter((column) => !(column.width && column.width > 0)).map((column) => [column.field, fitSamples(column, from, context)])));
|
|
664
|
+
}, [ordered, hasRows, context]);
|
|
665
|
+
const [fontsLoaded, setFontsLoaded] = useState(0);
|
|
666
|
+
useEffect(() => {
|
|
667
|
+
const fonts = typeof document === "undefined" ? void 0 : document.fonts;
|
|
668
|
+
if (!fonts) return void 0;
|
|
669
|
+
let live = true;
|
|
670
|
+
const loaded = () => {
|
|
671
|
+
if (live) setFontsLoaded((n) => n + 1);
|
|
672
|
+
};
|
|
673
|
+
void fonts.ready.then(loaded);
|
|
674
|
+
fonts.addEventListener("loadingdone", loaded);
|
|
675
|
+
return () => {
|
|
676
|
+
live = false;
|
|
677
|
+
fonts.removeEventListener("loadingdone", loaded);
|
|
678
|
+
};
|
|
679
|
+
}, []);
|
|
680
|
+
const measurer = useRef(null);
|
|
681
|
+
const [measured, setMeasured] = useState(/* @__PURE__ */ new Map());
|
|
682
|
+
useLayoutEffect(() => {
|
|
683
|
+
const box = measurer.current;
|
|
684
|
+
if (!box) return;
|
|
685
|
+
const next = /* @__PURE__ */ new Map();
|
|
686
|
+
for (const group of box.querySelectorAll("[data-measure]")) {
|
|
687
|
+
let widest = 0;
|
|
688
|
+
for (const part of group.children) widest = Math.max(widest, part.getBoundingClientRect().width);
|
|
689
|
+
next.set(group.dataset["measure"] ?? "", widest);
|
|
690
|
+
}
|
|
691
|
+
setMeasured(next);
|
|
692
|
+
}, [samples, fontsLoaded]);
|
|
693
|
+
const columns = useMemo(() => {
|
|
694
|
+
const declares = (column) => column.width !== void 0 && column.width > 0;
|
|
695
|
+
const fitted = ordered.map((column) => declares(column) ? column : { ...column, width: fittedWidth(column.type, measured.get(column.field) ?? 0) });
|
|
696
|
+
if (viewportWidth <= 0) return fitted;
|
|
697
|
+
const room = Math.floor(viewportWidth * FROZEN_SHARE) - SHEET_ROW_NUMBER_WIDTH;
|
|
698
|
+
const over = fitted.filter((column) => column.frozen).reduce((sum, column) => sum + columnWidth(column), 0) - room;
|
|
699
|
+
const yielding = ordered.filter((column) => column.frozen && !declares(column)).length;
|
|
700
|
+
if (over <= 0 || yielding === 0) return fitted;
|
|
701
|
+
const each = Math.ceil(over / yielding);
|
|
702
|
+
return fitted.map(
|
|
703
|
+
(column, index) => column.frozen && !declares(ordered[index]) ? { ...column, width: Math.max(SHEET_COLUMN_BOUNDS[column.type][0], columnWidth(column) - each) } : column
|
|
704
|
+
);
|
|
705
|
+
}, [ordered, measured, viewportWidth]);
|
|
651
706
|
const rows = useMemo(() => sortRows(columns, given, sort, context), [columns, given, sort, context]);
|
|
652
707
|
const editable = mode === "edit" && onEdit !== void 0;
|
|
653
708
|
const rowActions = mode === "edit" && onDeleteRow !== void 0;
|
|
@@ -660,13 +715,13 @@ function SheetGrid({
|
|
|
660
715
|
const [headerHeight, setHeaderHeight] = useState(SHEET_ROW_HEIGHT);
|
|
661
716
|
const [viewport, setViewport] = useState(0);
|
|
662
717
|
const [scrollTop, setScrollTop] = useState(0);
|
|
718
|
+
const [scrolledAcross, setScrolledAcross] = useState(false);
|
|
663
719
|
const [active, setActive] = useState(null);
|
|
664
720
|
const [anchor, setAnchor] = useState(null);
|
|
665
721
|
const [editing, setEditing] = useState(null);
|
|
666
722
|
const [local, setLocal] = useState(/* @__PURE__ */ new Map());
|
|
667
723
|
const [announcement, setAnnouncement] = useState({ text: "", n: 0 });
|
|
668
724
|
const dragging = useRef(false);
|
|
669
|
-
const [hoveredRow, setHoveredRow] = useState(null);
|
|
670
725
|
const [rowMenu, setRowMenu] = useState(null);
|
|
671
726
|
const say = useCallback((text) => setAnnouncement((current2) => ({ text, n: current2.n + 1 })), []);
|
|
672
727
|
const heardRefusals = useRef(/* @__PURE__ */ new Map());
|
|
@@ -690,6 +745,7 @@ function SheetGrid({
|
|
|
690
745
|
const head = grid.current?.querySelector(".crewlet-sheet-grid__row--head")?.offsetHeight ?? 0;
|
|
691
746
|
if (head > 0) setHeaderHeight(head);
|
|
692
747
|
setViewport(scroller.current?.clientHeight ?? 0);
|
|
748
|
+
setViewportWidth(scroller.current?.clientWidth ?? 0);
|
|
693
749
|
};
|
|
694
750
|
measure();
|
|
695
751
|
if (typeof ResizeObserver !== "function") return void 0;
|
|
@@ -707,6 +763,7 @@ function SheetGrid({
|
|
|
707
763
|
[columns]
|
|
708
764
|
);
|
|
709
765
|
const totalWidth = useMemo(() => columns.reduce((sum, column) => sum + columnWidth(column), SHEET_ROW_NUMBER_WIDTH), [columns]);
|
|
766
|
+
const lastFrozen = useMemo(() => columns.reduce((edge, column, index) => column.frozen ? index : edge, -1), [columns]);
|
|
710
767
|
const frozenEdge = useMemo(() => {
|
|
711
768
|
let edge = SHEET_ROW_NUMBER_WIDTH;
|
|
712
769
|
columns.forEach((column, index) => {
|
|
@@ -947,6 +1004,7 @@ function SheetGrid({
|
|
|
947
1004
|
const page = Math.max(1, Math.floor(Math.max(viewport - headerHeight, rowHeight) / rowHeight) - 1);
|
|
948
1005
|
const onKeyDown = (event) => {
|
|
949
1006
|
if (editing || isComposing(event) || !current || !currentCell) return;
|
|
1007
|
+
if (event.target.closest(".crewlet-sheet-grid__row-actions")) return;
|
|
950
1008
|
const column = columns[current.col];
|
|
951
1009
|
const mod = isMod(event);
|
|
952
1010
|
if (mod && event.altKey && event.key.toLowerCase() === "h") {
|
|
@@ -1099,7 +1157,10 @@ function SheetGrid({
|
|
|
1099
1157
|
width: `${totalWidth}px`
|
|
1100
1158
|
};
|
|
1101
1159
|
const contentHeight = headerHeight + rows.length * rowHeight + 2;
|
|
1102
|
-
const scrollerStyle = fit === "content" ? {
|
|
1160
|
+
const scrollerStyle = fit === "content" ? {
|
|
1161
|
+
height: `${height !== void 0 ? Math.min(contentHeight, height) : contentHeight}px`,
|
|
1162
|
+
"--crewlet-sheet-content-height": `${contentHeight}px`
|
|
1163
|
+
} : height !== void 0 ? { height: `${height}px` } : void 0;
|
|
1103
1164
|
const side = (rowAt) => {
|
|
1104
1165
|
const top = headerHeight + rowAt * rowHeight - scrollTop;
|
|
1105
1166
|
const view = viewport > 0 ? viewport : rowHeight * 12;
|
|
@@ -1111,9 +1172,12 @@ function SheetGrid({
|
|
|
1111
1172
|
"div",
|
|
1112
1173
|
{
|
|
1113
1174
|
ref: scroller,
|
|
1114
|
-
className: "crewlet-sheet-grid__scroller",
|
|
1175
|
+
className: cx("crewlet-sheet-grid__scroller", scrolledAcross && "crewlet-sheet-grid__scroller--across"),
|
|
1115
1176
|
style: scrollerStyle,
|
|
1116
|
-
onScroll: (event) =>
|
|
1177
|
+
onScroll: (event) => {
|
|
1178
|
+
setScrollTop(event.currentTarget.scrollTop);
|
|
1179
|
+
setScrolledAcross(event.currentTarget.scrollLeft > 0);
|
|
1180
|
+
},
|
|
1117
1181
|
children: /* @__PURE__ */ jsxs(
|
|
1118
1182
|
"div",
|
|
1119
1183
|
{
|
|
@@ -1126,20 +1190,15 @@ function SheetGrid({
|
|
|
1126
1190
|
"aria-multiselectable": "true",
|
|
1127
1191
|
"aria-describedby": helpId,
|
|
1128
1192
|
tabIndex: -1,
|
|
1129
|
-
className: "crewlet-sheet-grid__grid",
|
|
1193
|
+
className: cx("crewlet-sheet-grid__grid", range && (range.top !== range.bottom || range.left !== range.right) && "crewlet-sheet-grid__grid--range"),
|
|
1130
1194
|
style,
|
|
1131
1195
|
onKeyDown,
|
|
1132
|
-
onMouseMove: rowActions ? (event) => {
|
|
1133
|
-
const over = event.target.closest("[data-row-id]")?.dataset["rowId"] ?? null;
|
|
1134
|
-
setHoveredRow((was) => was === over ? was : over);
|
|
1135
|
-
} : void 0,
|
|
1136
|
-
onMouseLeave: rowActions ? () => setHoveredRow(null) : void 0,
|
|
1137
1196
|
onCopy,
|
|
1138
1197
|
onCut,
|
|
1139
1198
|
onPaste,
|
|
1140
1199
|
children: [
|
|
1141
1200
|
/* @__PURE__ */ jsx("div", { role: "rowgroup", className: "crewlet-sheet-grid__head", children: /* @__PURE__ */ jsxs("div", { role: "row", "aria-rowindex": 1, className: "crewlet-sheet-grid__row crewlet-sheet-grid__row--head", children: [
|
|
1142
|
-
/* @__PURE__ */ jsx("div", { role: "columnheader", "aria-colindex": 1, className: "crewlet-sheet-grid__corner", children: /* @__PURE__ */ jsx(VisuallyHidden, { children: labels.rowHeader }) }),
|
|
1201
|
+
/* @__PURE__ */ jsx("div", { role: "columnheader", "aria-colindex": 1, className: cx("crewlet-sheet-grid__corner", lastFrozen < 0 && "crewlet-sheet-grid__frozen-edge"), children: /* @__PURE__ */ jsx(VisuallyHidden, { children: labels.rowHeader }) }),
|
|
1143
1202
|
columns.map((column, col) => {
|
|
1144
1203
|
const position = { row: HEADER, col };
|
|
1145
1204
|
const isActive = current?.row === HEADER && current.col === col;
|
|
@@ -1155,7 +1214,13 @@ function SheetGrid({
|
|
|
1155
1214
|
"aria-colindex": col + 2,
|
|
1156
1215
|
"aria-sort": sorted ?? (onSortChange ? "none" : void 0),
|
|
1157
1216
|
tabIndex: isActive ? 0 : -1,
|
|
1158
|
-
className: cx(
|
|
1217
|
+
className: cx(
|
|
1218
|
+
"crewlet-sheet-grid__header",
|
|
1219
|
+
`crewlet-sheet-grid__header--${column.type}`,
|
|
1220
|
+
column.frozen && "crewlet-sheet-grid__cell--frozen",
|
|
1221
|
+
col === lastFrozen && "crewlet-sheet-grid__frozen-edge",
|
|
1222
|
+
isActive && "crewlet-sheet-grid__header--active"
|
|
1223
|
+
),
|
|
1159
1224
|
style: column.frozen ? { insetInlineStart: `${offsets[col]}px` } : void 0,
|
|
1160
1225
|
onMouseDown: (event) => onCellMouseDown(event, { rowId: null, field: column.field }),
|
|
1161
1226
|
onFocus: (event) => {
|
|
@@ -1164,7 +1229,7 @@ function SheetGrid({
|
|
|
1164
1229
|
onClick: () => {
|
|
1165
1230
|
if (onSortChange) onSortChange(nextSort(sort, column.field));
|
|
1166
1231
|
},
|
|
1167
|
-
title: onSortChange ? labels.sortBy(column.label) :
|
|
1232
|
+
title: onSortChange ? labels.sortBy(column.label) : column.label,
|
|
1168
1233
|
children: [
|
|
1169
1234
|
/* @__PURE__ */ jsx("span", { className: "crewlet-sheet-grid__header-label", children: column.label }),
|
|
1170
1235
|
/* @__PURE__ */ jsx(VisuallyHidden, { children: `, ${labels.types[column.type]}` }),
|
|
@@ -1180,6 +1245,9 @@ function SheetGrid({
|
|
|
1180
1245
|
/* @__PURE__ */ jsx("div", { role: "rowgroup", className: "crewlet-sheet-grid__body", style: { height: `${rows.length * rowHeight}px` }, children: drawn.map((index) => {
|
|
1181
1246
|
const row = rows[index];
|
|
1182
1247
|
const rowPresence = onRows.get(row.id);
|
|
1248
|
+
const rowNameId = `${id}-r${index}-name`;
|
|
1249
|
+
const rowSelected = range !== null && index >= range.top && index <= range.bottom;
|
|
1250
|
+
const actionsLabel = labels.rowActions(index + 1);
|
|
1183
1251
|
return /* @__PURE__ */ jsxs(
|
|
1184
1252
|
"div",
|
|
1185
1253
|
{
|
|
@@ -1194,18 +1262,31 @@ function SheetGrid({
|
|
|
1194
1262
|
{
|
|
1195
1263
|
role: "rowheader",
|
|
1196
1264
|
"aria-colindex": 1,
|
|
1197
|
-
|
|
1265
|
+
"aria-labelledby": rowNameId,
|
|
1266
|
+
className: cx(
|
|
1267
|
+
"crewlet-sheet-grid__rownum",
|
|
1268
|
+
lastFrozen < 0 && "crewlet-sheet-grid__frozen-edge",
|
|
1269
|
+
rowActions && "crewlet-sheet-grid__rownum--actions",
|
|
1270
|
+
rowSelected && "crewlet-sheet-grid__rownum--selected",
|
|
1271
|
+
rowMenu === row.id && "crewlet-sheet-grid__rownum--open",
|
|
1272
|
+
rowPresence && "crewlet-sheet-grid__rownum--present",
|
|
1273
|
+
rowPresence && presenceHueClass(rowPresence.hue)
|
|
1274
|
+
),
|
|
1198
1275
|
children: [
|
|
1199
|
-
/* @__PURE__ */ jsx("span", { "aria-hidden": "true", children: index + 1 }),
|
|
1200
|
-
/* @__PURE__ */ jsx(VisuallyHidden, { children: rowName(columns, row, index, context) }),
|
|
1201
|
-
rowActions
|
|
1276
|
+
/* @__PURE__ */ jsx("span", { className: "crewlet-sheet-grid__rownum-number", "aria-hidden": "true", children: index + 1 }),
|
|
1277
|
+
/* @__PURE__ */ jsx(VisuallyHidden, { id: rowNameId, children: rowName(columns, row, index, context) }),
|
|
1278
|
+
rowActions ? /* @__PURE__ */ jsx("span", { className: "crewlet-sheet-grid__row-actions", children: /* @__PURE__ */ jsx(
|
|
1202
1279
|
Menu,
|
|
1203
1280
|
{
|
|
1204
|
-
label:
|
|
1205
|
-
icon: /* @__PURE__ */ jsx(EllipsisGlyph, { size: "xs" }),
|
|
1281
|
+
label: actionsLabel,
|
|
1206
1282
|
triggerTabIndex: -1,
|
|
1207
1283
|
open: rowMenu === row.id,
|
|
1208
1284
|
onOpenChange: (open) => setRowMenu(open ? row.id : null),
|
|
1285
|
+
renderTrigger: (trigger) => (
|
|
1286
|
+
// Lined up with the button's leading edge: the gutter is the
|
|
1287
|
+
// grid's first column, and a centred tip hung past the grid.
|
|
1288
|
+
/* @__PURE__ */ jsx(Tooltip, { content: actionsLabel, align: "start", children: /* @__PURE__ */ jsx(IconButton, { ...trigger, label: actionsLabel, icon: /* @__PURE__ */ jsx(EllipsisGlyph, {}), size: "sm", title: "" }) })
|
|
1289
|
+
),
|
|
1209
1290
|
items: [
|
|
1210
1291
|
{
|
|
1211
1292
|
key: "delete",
|
|
@@ -1232,6 +1313,7 @@ function SheetGrid({
|
|
|
1232
1313
|
const people2 = onCells.get(key);
|
|
1233
1314
|
const lead = people2?.[0];
|
|
1234
1315
|
const isEditing = editing?.rowId === row.id && editing.field === column.field;
|
|
1316
|
+
const history = isActive && onShowHistory !== void 0 && !isEditing;
|
|
1235
1317
|
return (
|
|
1236
1318
|
// eslint-disable-next-line jsx-a11y/click-events-have-key-events -- keys reach the grid's own handler, which toggles on Space and Enter
|
|
1237
1319
|
/* @__PURE__ */ jsxs(
|
|
@@ -1248,11 +1330,13 @@ function SheetGrid({
|
|
|
1248
1330
|
"crewlet-sheet-grid__cell",
|
|
1249
1331
|
`crewlet-sheet-grid__cell--${column.type}`,
|
|
1250
1332
|
column.frozen && "crewlet-sheet-grid__cell--frozen",
|
|
1333
|
+
col === lastFrozen && "crewlet-sheet-grid__frozen-edge",
|
|
1251
1334
|
selected && "crewlet-sheet-grid__cell--selected",
|
|
1252
1335
|
isActive && "crewlet-sheet-grid__cell--active",
|
|
1253
1336
|
pending && "crewlet-sheet-grid__cell--pending",
|
|
1254
1337
|
refused !== void 0 && "crewlet-sheet-grid__cell--refused",
|
|
1255
1338
|
isEditing && "crewlet-sheet-grid__cell--editing",
|
|
1339
|
+
history && "crewlet-sheet-grid__cell--history",
|
|
1256
1340
|
lead && "crewlet-presence-ring",
|
|
1257
1341
|
lead && presenceHueClass(lead.hue),
|
|
1258
1342
|
lead && (lead.idle ? "crewlet-presence-ring--idle" : null)
|
|
@@ -1286,7 +1370,7 @@ function SheetGrid({
|
|
|
1286
1370
|
) : null,
|
|
1287
1371
|
people2 && lead ? /* @__PURE__ */ jsx(CursorFlag, { name: flagText(people2), hue: lead.hue, kind: lead.kind, editing: people2.some((entry) => entry.editing) }) : null,
|
|
1288
1372
|
isActive && refused !== void 0 && !isEditing ? /* @__PURE__ */ jsx("span", { className: "crewlet-sheet-grid__message", "aria-hidden": "true", children: refused }) : null,
|
|
1289
|
-
|
|
1373
|
+
history ? /* @__PURE__ */ jsx(
|
|
1290
1374
|
"button",
|
|
1291
1375
|
{
|
|
1292
1376
|
type: "button",
|
|
@@ -1295,7 +1379,7 @@ function SheetGrid({
|
|
|
1295
1379
|
className: "crewlet-sheet-grid__history",
|
|
1296
1380
|
title: labels.history,
|
|
1297
1381
|
onMouseDown: (event) => event.stopPropagation(),
|
|
1298
|
-
onClick: () => onShowHistory({ rowId: row.id, field: column.field }),
|
|
1382
|
+
onClick: () => onShowHistory?.({ rowId: row.id, field: column.field }),
|
|
1299
1383
|
children: /* @__PURE__ */ jsx(RotateCcwClockGlyph, { size: "xs" })
|
|
1300
1384
|
}
|
|
1301
1385
|
) : null,
|
|
@@ -1329,6 +1413,13 @@ function SheetGrid({
|
|
|
1329
1413
|
)
|
|
1330
1414
|
}
|
|
1331
1415
|
),
|
|
1416
|
+
samples ? /* @__PURE__ */ jsx("div", { ref: measurer, className: "crewlet-sheet-grid__measure", "aria-hidden": "true", inert: true, children: ordered.filter((column) => samples.has(column.field)).map((column) => /* @__PURE__ */ jsxs("div", { "data-measure": column.field, children: [
|
|
1417
|
+
/* @__PURE__ */ jsxs("div", { className: cx("crewlet-sheet-grid__header", `crewlet-sheet-grid__header--${column.type}`), children: [
|
|
1418
|
+
/* @__PURE__ */ jsx("span", { className: "crewlet-sheet-grid__header-label", children: column.label }),
|
|
1419
|
+
onSortChange ? /* @__PURE__ */ jsx("span", { className: "crewlet-sheet-grid__sort", children: /* @__PURE__ */ jsx(ArrowDownGlyph, { size: "xs" }) }) : null
|
|
1420
|
+
] }),
|
|
1421
|
+
(samples.get(column.field) ?? []).map((value, index) => /* @__PURE__ */ jsx("div", { className: cx("crewlet-sheet-grid__cell", `crewlet-sheet-grid__cell--${column.type}`), children: /* @__PURE__ */ jsx("span", { className: "crewlet-sheet-grid__value", children: /* @__PURE__ */ jsx(CellDisplay, { column, value, context }) }) }, index))
|
|
1422
|
+
] }, column.field)) }) : null,
|
|
1332
1423
|
/* @__PURE__ */ jsx(VisuallyHidden, { id: describedId, children: description }),
|
|
1333
1424
|
/* @__PURE__ */ jsx(VisuallyHidden, { id: helpId, children: rowActions ? `${labels.keyboardHelp} ${labels.rowActionsHelp}` : labels.keyboardHelp }),
|
|
1334
1425
|
/* @__PURE__ */ jsx(VisuallyHidden, { children: /* @__PURE__ */ jsx("span", { role: "status", "aria-live": "polite", children: /* @__PURE__ */ jsx("span", { children: announcement.text }, announcement.n) }) }),
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { Modal } from './chunk-I3KKZ2O3.js';
|
|
1
|
+
import { Modal } from './chunk-XEGZHHRH.js';
|
|
3
2
|
import { useListbox, useOptionKeys } from './chunk-F73MC7EZ.js';
|
|
4
|
-
import { Popover } from './chunk-
|
|
3
|
+
import { Popover } from './chunk-K3IJQNB7.js';
|
|
5
4
|
import { KeyChip, highlightMatch } from './chunk-FYTIJM2T.js';
|
|
6
5
|
import { Input } from './chunk-6QFAK2WV.js';
|
|
7
|
-
import {
|
|
6
|
+
import { Skeleton } from './chunk-TEUQWOWZ.js';
|
|
7
|
+
import { useMediaMatch } from './chunk-RTPQDNW3.js';
|
|
8
8
|
import { focusables, isComposing } from './chunk-R25RGPUB.js';
|
|
9
9
|
import { announce } from './chunk-RSAQOKH3.js';
|
|
10
10
|
import { VisuallyHidden } from './chunk-BZFWDIV6.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { PRESENCE_LABELS, presenceOrder, collapseSessions } from './chunk-Z7JYG5TF.js';
|
|
2
|
-
import { Avatar } from './chunk-
|
|
2
|
+
import { Avatar } from './chunk-PZKHBB7D.js';
|
|
3
3
|
import { headingTag, useHeadingLevel } from './chunk-PQADV6P6.js';
|
|
4
4
|
import { Button } from './chunk-OG6CL3EB.js';
|
|
5
5
|
import { IconButton } from './chunk-4FQT6ZAY.js';
|