@crisp-ui-kit/crisp 0.5.0 → 0.7.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 +14 -0
- package/dist/accordion.css +9 -1
- package/dist/appshell.css +12 -4
- package/dist/authshell.css +57 -0
- package/dist/authshell.d.ts +7 -0
- package/dist/avatargroup.css +2 -2
- package/dist/badge.css +4 -4
- package/dist/barchart.css +13 -5
- package/dist/board.css +9 -1
- package/dist/bulkbar.css +11 -3
- package/dist/button.css +15 -1
- package/dist/button.d.ts +2 -1
- package/dist/card.css +8 -0
- package/dist/checkbox.css +17 -1
- package/dist/cjs/components/accordion/accordion.js +69 -0
- package/dist/cjs/components/accordion/accordion.recipe.js +26 -0
- package/dist/cjs/components/accordion/index.js +7 -0
- package/dist/cjs/components/avatar/avatar.js +44 -0
- package/dist/cjs/components/avatar/avatar.recipe.js +42 -0
- package/dist/cjs/components/avatar/index.js +7 -0
- package/dist/cjs/components/avatargroup/avatargroup.js +52 -0
- package/dist/cjs/components/avatargroup/avatargroup.recipe.js +18 -0
- package/dist/cjs/components/avatargroup/index.js +7 -0
- package/dist/cjs/components/badge/badge.js +44 -0
- package/dist/cjs/components/badge/badge.recipe.js +68 -0
- package/dist/cjs/components/badge/index.js +7 -0
- package/dist/cjs/components/barchart/barchart.js +45 -0
- package/dist/cjs/components/barchart/barchart.recipe.js +34 -0
- package/dist/cjs/components/barchart/index.js +7 -0
- package/dist/cjs/components/breadcrumb/breadcrumb.js +53 -0
- package/dist/cjs/components/breadcrumb/breadcrumb.recipe.js +21 -0
- package/dist/cjs/components/breadcrumb/index.js +7 -0
- package/dist/cjs/components/bulkbar/bulkbar.js +53 -0
- package/dist/cjs/components/bulkbar/bulkbar.recipe.js +31 -0
- package/dist/cjs/components/bulkbar/index.js +8 -0
- package/dist/cjs/components/button/button.js +62 -0
- package/dist/cjs/components/button/button.recipe.js +58 -0
- package/dist/cjs/components/button/index.js +7 -0
- package/dist/cjs/components/callout/callout.js +25 -0
- package/dist/cjs/components/callout/callout.recipe.js +29 -0
- package/dist/cjs/components/callout/index.js +7 -0
- package/dist/cjs/components/card/card.js +54 -0
- package/dist/cjs/components/card/card.recipe.js +31 -0
- package/dist/cjs/components/card/index.js +10 -0
- package/dist/cjs/components/checkbox/checkbox.js +56 -0
- package/dist/cjs/components/checkbox/checkbox.recipe.js +34 -0
- package/dist/cjs/components/checkbox/index.js +7 -0
- package/dist/cjs/components/columncalc/columncalc.js +139 -0
- package/dist/cjs/components/columncalc/columncalc.recipe.js +33 -0
- package/dist/cjs/components/columncalc/index.js +10 -0
- package/dist/cjs/components/contextmenu/contextmenu.js +78 -0
- package/dist/cjs/components/contextmenu/contextmenu.recipe.js +24 -0
- package/dist/cjs/components/contextmenu/index.js +7 -0
- package/dist/cjs/components/datatable/datatable.js +508 -0
- package/dist/cjs/components/datatable/datatable.recipe.js +113 -0
- package/dist/cjs/components/datatable/index.js +7 -0
- package/dist/cjs/components/datepicker/datepicker.js +153 -0
- package/dist/cjs/components/datepicker/datepicker.recipe.js +180 -0
- package/dist/cjs/components/datepicker/index.js +19 -0
- package/dist/cjs/components/datepickerfield/datepickerfield.js +85 -0
- package/dist/cjs/components/datepickerfield/datepickerfield.recipe.js +44 -0
- package/dist/cjs/components/datepickerfield/index.js +7 -0
- package/dist/cjs/components/dialog/dialog.js +86 -0
- package/dist/cjs/components/dialog/dialog.recipe.js +35 -0
- package/dist/cjs/components/dialog/index.js +9 -0
- package/dist/cjs/components/divider/divider.js +10 -0
- package/dist/cjs/components/divider/divider.recipe.js +17 -0
- package/dist/cjs/components/divider/index.js +7 -0
- package/dist/cjs/components/donutchart/donutchart.js +41 -0
- package/dist/cjs/components/donutchart/donutchart.recipe.js +30 -0
- package/dist/cjs/components/donutchart/index.js +7 -0
- package/dist/cjs/components/drawer/drawer.js +80 -0
- package/dist/cjs/components/drawer/drawer.recipe.js +30 -0
- package/dist/cjs/components/drawer/index.js +9 -0
- package/dist/cjs/components/emptystate/emptystate.js +10 -0
- package/dist/cjs/components/emptystate/emptystate.recipe.js +34 -0
- package/dist/cjs/components/emptystate/index.js +7 -0
- package/dist/cjs/components/formfield/formfield.js +50 -0
- package/dist/cjs/components/formfield/formfield.recipe.js +22 -0
- package/dist/cjs/components/formfield/index.js +7 -0
- package/dist/cjs/components/input/index.js +7 -0
- package/dist/cjs/components/input/input.js +47 -0
- package/dist/cjs/components/input/input.recipe.js +59 -0
- package/dist/cjs/components/kbd/index.js +7 -0
- package/dist/cjs/components/kbd/kbd.js +44 -0
- package/dist/cjs/components/kbd/kbd.recipe.js +23 -0
- package/dist/cjs/components/linechart/index.js +7 -0
- package/dist/cjs/components/linechart/linechart.js +57 -0
- package/dist/cjs/components/linechart/linechart.recipe.js +35 -0
- package/dist/cjs/components/menu/index.js +14 -0
- package/dist/cjs/components/menu/menu-keyboard.js +117 -0
- package/dist/cjs/components/menu/menu.js +144 -0
- package/dist/cjs/components/menu/menu.recipe.js +54 -0
- package/dist/cjs/components/multiselect/index.js +7 -0
- package/dist/cjs/components/multiselect/multiselect.js +161 -0
- package/dist/cjs/components/multiselect/multiselect.recipe.js +71 -0
- package/dist/cjs/components/popover/index.js +7 -0
- package/dist/cjs/components/popover/popover.js +106 -0
- package/dist/cjs/components/popover/popover.recipe.js +21 -0
- package/dist/cjs/components/progress/index.js +7 -0
- package/dist/cjs/components/progress/progress.js +26 -0
- package/dist/cjs/components/progress/progress.recipe.js +20 -0
- package/dist/cjs/components/radiogroup/index.js +8 -0
- package/dist/cjs/components/radiogroup/radiogroup.js +83 -0
- package/dist/cjs/components/radiogroup/radiogroup.recipe.js +40 -0
- package/dist/cjs/components/resizablepanel/index.js +12 -0
- package/dist/cjs/components/resizablepanel/resizablepanel.js +176 -0
- package/dist/cjs/components/resizablepanel/resizablepanel.recipe.js +69 -0
- package/dist/cjs/components/segmented/index.js +7 -0
- package/dist/cjs/components/segmented/segmented.js +95 -0
- package/dist/cjs/components/segmented/segmented.recipe.js +23 -0
- package/dist/cjs/components/select/index.js +7 -0
- package/dist/cjs/components/select/select.js +180 -0
- package/dist/cjs/components/select/select.recipe.js +79 -0
- package/dist/cjs/components/skeleton/index.js +7 -0
- package/dist/cjs/components/skeleton/skeleton.js +13 -0
- package/dist/cjs/components/skeleton/skeleton.recipe.js +17 -0
- package/dist/cjs/components/spinner/index.js +7 -0
- package/dist/cjs/components/spinner/spinner.js +15 -0
- package/dist/cjs/components/spinner/spinner.recipe.js +16 -0
- package/dist/cjs/components/stagebar/index.js +7 -0
- package/dist/cjs/components/stagebar/stagebar.js +26 -0
- package/dist/cjs/components/stagebar/stagebar.recipe.js +17 -0
- package/dist/cjs/components/statcard/index.js +7 -0
- package/dist/cjs/components/statcard/statcard.js +15 -0
- package/dist/cjs/components/statcard/statcard.recipe.js +37 -0
- package/dist/cjs/components/switch/index.js +7 -0
- package/dist/cjs/components/switch/switch.js +58 -0
- package/dist/cjs/components/switch/switch.recipe.js +29 -0
- package/dist/cjs/components/table/index.js +14 -0
- package/dist/cjs/components/table/table.js +66 -0
- package/dist/cjs/components/table/table.recipe.js +43 -0
- package/dist/cjs/components/tabletoolbar/index.js +20 -0
- package/dist/cjs/components/tabletoolbar/tabletoolbar.chrome.js +84 -0
- package/dist/cjs/components/tabletoolbar/tabletoolbar.js +237 -0
- package/dist/cjs/components/tabletoolbar/tabletoolbar.recipe.js +26 -0
- package/dist/cjs/components/tabs/index.js +7 -0
- package/dist/cjs/components/tabs/tabs.js +106 -0
- package/dist/cjs/components/tabs/tabs.recipe.js +36 -0
- package/dist/cjs/components/textarea/index.js +7 -0
- package/dist/cjs/components/textarea/textarea.js +56 -0
- package/dist/cjs/components/textarea/textarea.recipe.js +46 -0
- package/dist/cjs/components/toast/index.js +8 -0
- package/dist/cjs/components/toast/toast.js +95 -0
- package/dist/cjs/components/toast/toast.recipe.js +31 -0
- package/dist/cjs/components/tooltip/index.js +7 -0
- package/dist/cjs/components/tooltip/tooltip.js +95 -0
- package/dist/cjs/components/tooltip/tooltip.recipe.js +16 -0
- package/dist/cjs/components/wheelpicker/index.js +7 -0
- package/dist/cjs/components/wheelpicker/wheelpicker.js +134 -0
- package/dist/cjs/components/wheelpicker/wheelpicker.recipe.js +95 -0
- package/dist/cjs/core/cx.js +8 -0
- package/dist/cjs/core/define.js +6 -0
- package/dist/cjs/core/index.js +11 -0
- package/dist/cjs/core/primitive.js +49 -0
- package/dist/cjs/core/resolve.js +44 -0
- package/dist/cjs/core/types.js +2 -0
- package/dist/cjs/index.js +92 -0
- package/dist/cjs/package.json +3 -0
- package/dist/cjs/product/appshell/appshell.js +104 -0
- package/dist/cjs/product/appshell/appshell.recipe.js +30 -0
- package/dist/cjs/product/appshell/index.js +7 -0
- package/dist/cjs/product/authshell/authshell.js +21 -0
- package/dist/cjs/product/authshell/authshell.recipe.js +67 -0
- package/dist/cjs/product/authshell/index.js +7 -0
- package/dist/cjs/product/board/board.js +78 -0
- package/dist/cjs/product/board/board.recipe.js +31 -0
- package/dist/cjs/product/board/index.js +7 -0
- package/dist/cjs/product/command/command.js +238 -0
- package/dist/cjs/product/command/command.recipe.js +47 -0
- package/dist/cjs/product/command/index.js +8 -0
- package/dist/cjs/product/entitycard/entitycard.js +14 -0
- package/dist/cjs/product/entitycard/entitycard.recipe.js +32 -0
- package/dist/cjs/product/entitycard/index.js +7 -0
- package/dist/cjs/product/flowcanvas/flowcanvas.js +121 -0
- package/dist/cjs/product/flowcanvas/flowcanvas.recipe.js +28 -0
- package/dist/cjs/product/flowcanvas/index.js +7 -0
- package/dist/cjs/product/inbox/inbox.js +16 -0
- package/dist/cjs/product/inbox/inbox.recipe.js +46 -0
- package/dist/cjs/product/inbox/index.js +7 -0
- package/dist/cjs/product/listpage/index.js +8 -0
- package/dist/cjs/product/listpage/listpage.js +25 -0
- package/dist/cjs/product/listpage/listpage.recipe.js +46 -0
- package/dist/cjs/product/navitem/index.js +5 -0
- package/dist/cjs/product/navitem/navitem.js +44 -0
- package/dist/cjs/product/navitem/navitem.recipe.js +36 -0
- package/dist/cjs/product/onboarding/index.js +7 -0
- package/dist/cjs/product/onboarding/onboarding.js +17 -0
- package/dist/cjs/product/onboarding/onboarding.recipe.js +44 -0
- package/dist/cjs/product/recordpage/index.js +7 -0
- package/dist/cjs/product/recordpage/recordpage.js +409 -0
- package/dist/cjs/product/recordpage/recordpage.recipe.js +162 -0
- package/dist/cjs/product/recordpanel/index.js +7 -0
- package/dist/cjs/product/recordpanel/recordpanel.js +83 -0
- package/dist/cjs/product/recordpanel/recordpanel.recipe.js +51 -0
- package/dist/cjs/product/recordstable/company-logos.js +29 -0
- package/dist/cjs/product/recordstable/index.js +10 -0
- package/dist/cjs/product/recordstable/recordstable.js +1092 -0
- package/dist/cjs/product/recordstable/recordstable.recipe.js +152 -0
- package/dist/cjs/product/recordstable/recordstable.tag.js +21 -0
- package/dist/cjs/product/richtext/index.js +7 -0
- package/dist/cjs/product/richtext/richtext.js +147 -0
- package/dist/cjs/product/richtext/richtext.recipe.js +43 -0
- package/dist/cjs/product/settingssection/index.js +7 -0
- package/dist/cjs/product/settingssection/settingssection.js +14 -0
- package/dist/cjs/product/settingssection/settingssection.recipe.js +23 -0
- package/dist/cjs/product/settingsshell/index.js +7 -0
- package/dist/cjs/product/settingsshell/settingsshell.js +59 -0
- package/dist/cjs/product/settingsshell/settingsshell.recipe.js +46 -0
- package/dist/cjs/product/sidebar/index.js +13 -0
- package/dist/cjs/product/sidebar/sidebar.js +148 -0
- package/dist/cjs/product/sidebar/sidebar.recipe.js +46 -0
- package/dist/cjs/product/tasklist/index.js +7 -0
- package/dist/cjs/product/tasklist/tasklist.js +19 -0
- package/dist/cjs/product/tasklist/tasklist.recipe.js +38 -0
- package/dist/cjs/product/trialbanner/index.js +7 -0
- package/dist/cjs/product/trialbanner/trialbanner.js +13 -0
- package/dist/cjs/product/trialbanner/trialbanner.recipe.js +32 -0
- package/dist/cjs/product/viewtoggle/index.js +7 -0
- package/dist/cjs/product/viewtoggle/viewtoggle.js +55 -0
- package/dist/cjs/product/viewtoggle/viewtoggle.recipe.js +27 -0
- package/dist/cjs/tokens/contract.js +21 -0
- package/dist/cjs/tokens/elevation.js +47 -0
- package/dist/cjs/tokens/index.js +18 -0
- package/dist/cjs/tokens/palette.js +63 -0
- package/dist/cjs/tokens/scale.js +70 -0
- package/dist/cjs/tokens/semantic.js +57 -0
- package/dist/columncalc.css +26 -0
- package/dist/columncalc.d.ts +7 -0
- package/dist/command.css +34 -1
- package/dist/contextmenu.css +10 -2
- package/dist/datatable.css +60 -14
- package/dist/datepicker.css +165 -19
- package/dist/datepicker.d.ts +2 -2
- package/dist/datepickerfield.css +27 -0
- package/dist/datepickerfield.d.ts +7 -0
- package/dist/dialog.css +10 -2
- package/dist/donutchart.css +8 -0
- package/dist/drawer.css +13 -5
- package/dist/entitycard.css +10 -2
- package/dist/esm/components/accordion/accordion.js +17 -16
- package/dist/esm/components/accordion/accordion.recipe.js +1 -1
- package/dist/esm/components/avatargroup/avatargroup.js +2 -2
- package/dist/esm/components/avatargroup/avatargroup.recipe.js +2 -2
- package/dist/esm/components/badge/badge.recipe.js +4 -4
- package/dist/esm/components/barchart/barchart.js +15 -2
- package/dist/esm/components/barchart/barchart.recipe.js +10 -5
- package/dist/esm/components/breadcrumb/breadcrumb.js +2 -2
- package/dist/esm/components/bulkbar/bulkbar.js +2 -2
- package/dist/esm/components/bulkbar/bulkbar.recipe.js +4 -4
- package/dist/esm/components/button/button.js +13 -2
- package/dist/esm/components/button/button.recipe.js +20 -4
- package/dist/esm/components/callout/callout.js +2 -2
- package/dist/esm/components/checkbox/checkbox.recipe.js +9 -1
- package/dist/esm/components/columncalc/columncalc.js +100 -0
- package/dist/esm/components/columncalc/columncalc.recipe.js +30 -0
- package/dist/esm/components/columncalc/index.js +1 -0
- package/dist/esm/components/contextmenu/contextmenu.recipe.js +4 -4
- package/dist/esm/components/datatable/datatable.js +276 -49
- package/dist/esm/components/datatable/datatable.recipe.js +54 -16
- package/dist/esm/components/datepicker/datepicker.js +104 -53
- package/dist/esm/components/datepicker/datepicker.recipe.js +170 -25
- package/dist/esm/components/datepicker/index.js +1 -1
- package/dist/esm/components/datepickerfield/datepickerfield.js +49 -0
- package/dist/esm/components/datepickerfield/datepickerfield.recipe.js +41 -0
- package/dist/esm/components/datepickerfield/index.js +2 -0
- package/dist/esm/components/dialog/dialog.js +2 -2
- package/dist/esm/components/dialog/dialog.recipe.js +4 -4
- package/dist/esm/components/divider/divider.js +2 -2
- package/dist/esm/components/donutchart/donutchart.js +2 -2
- package/dist/esm/components/drawer/drawer.js +2 -2
- package/dist/esm/components/drawer/drawer.recipe.js +6 -6
- package/dist/esm/components/emptystate/emptystate.js +2 -2
- package/dist/esm/components/formfield/formfield.js +2 -2
- package/dist/esm/components/input/input.js +6 -3
- package/dist/esm/components/input/input.recipe.js +38 -5
- package/dist/esm/components/linechart/linechart.js +15 -2
- package/dist/esm/components/linechart/linechart.recipe.js +10 -5
- package/dist/esm/components/menu/index.js +1 -0
- package/dist/esm/components/menu/menu-keyboard.js +80 -0
- package/dist/esm/components/menu/menu.js +27 -60
- package/dist/esm/components/menu/menu.recipe.js +5 -5
- package/dist/esm/components/multiselect/multiselect.js +10 -3
- package/dist/esm/components/multiselect/multiselect.recipe.js +8 -8
- package/dist/esm/components/popover/popover.js +2 -2
- package/dist/esm/components/popover/popover.recipe.js +2 -2
- package/dist/esm/components/progress/progress.js +3 -3
- package/dist/esm/components/radiogroup/radiogroup.js +2 -2
- package/dist/esm/components/radiogroup/radiogroup.recipe.js +1 -1
- package/dist/esm/components/resizablepanel/index.js +2 -0
- package/dist/esm/components/resizablepanel/resizablepanel.js +135 -0
- package/dist/esm/components/resizablepanel/resizablepanel.recipe.js +66 -0
- package/dist/esm/components/segmented/segmented.js +2 -2
- package/dist/esm/components/select/select.js +2 -2
- package/dist/esm/components/select/select.recipe.js +6 -6
- package/dist/esm/components/skeleton/skeleton.js +5 -2
- package/dist/esm/components/spinner/spinner.js +3 -2
- package/dist/esm/components/stagebar/stagebar.js +2 -2
- package/dist/esm/components/statcard/statcard.js +2 -2
- package/dist/esm/components/table/table.recipe.js +6 -6
- package/dist/esm/components/tabletoolbar/tabletoolbar.chrome.js +3 -3
- package/dist/esm/components/tabletoolbar/tabletoolbar.js +21 -13
- package/dist/esm/components/tabs/tabs.js +2 -2
- package/dist/esm/components/tabs/tabs.recipe.js +4 -4
- package/dist/esm/components/textarea/textarea.js +5 -5
- package/dist/esm/components/textarea/textarea.recipe.js +16 -4
- package/dist/esm/components/toast/toast.js +4 -4
- package/dist/esm/components/toast/toast.recipe.js +2 -2
- package/dist/esm/components/tooltip/tooltip.js +21 -7
- package/dist/esm/components/wheelpicker/index.js +2 -0
- package/dist/esm/components/wheelpicker/wheelpicker.js +98 -0
- package/dist/esm/components/wheelpicker/wheelpicker.recipe.js +92 -0
- package/dist/esm/index.js +5 -0
- package/dist/esm/product/appshell/appshell.js +33 -9
- package/dist/esm/product/appshell/appshell.recipe.js +4 -4
- package/dist/esm/product/authshell/authshell.js +18 -0
- package/dist/esm/product/authshell/authshell.recipe.js +64 -0
- package/dist/esm/product/authshell/index.js +2 -0
- package/dist/esm/product/board/board.js +2 -2
- package/dist/esm/product/board/board.recipe.js +1 -1
- package/dist/esm/product/command/command.js +19 -6
- package/dist/esm/product/command/command.recipe.js +27 -2
- package/dist/esm/product/entitycard/entitycard.js +2 -2
- package/dist/esm/product/entitycard/entitycard.recipe.js +2 -2
- package/dist/esm/product/flowcanvas/flowcanvas.js +4 -4
- package/dist/esm/product/inbox/inbox.recipe.js +1 -1
- package/dist/esm/product/listpage/listpage.recipe.js +3 -3
- package/dist/esm/product/navitem/navitem.recipe.js +13 -1
- package/dist/esm/product/onboarding/onboarding.js +2 -2
- package/dist/esm/product/onboarding/onboarding.recipe.js +2 -2
- package/dist/esm/product/recordpage/recordpage.js +133 -47
- package/dist/esm/product/recordpage/recordpage.recipe.js +19 -17
- package/dist/esm/product/recordpanel/recordpanel.js +4 -4
- package/dist/esm/product/recordpanel/recordpanel.recipe.js +12 -16
- package/dist/esm/product/recordstable/recordstable.js +157 -66
- package/dist/esm/product/recordstable/recordstable.recipe.js +23 -23
- package/dist/esm/product/recordstable/recordstable.tag.js +18 -0
- package/dist/esm/product/richtext/richtext.js +3 -3
- package/dist/esm/product/richtext/richtext.recipe.js +3 -3
- package/dist/esm/product/settingssection/settingssection.js +2 -2
- package/dist/esm/product/settingsshell/settingsshell.js +2 -2
- package/dist/esm/product/settingsshell/settingsshell.recipe.js +7 -2
- package/dist/esm/product/sidebar/sidebar.js +2 -2
- package/dist/esm/product/sidebar/sidebar.recipe.js +27 -2
- package/dist/esm/product/tasklist/tasklist.js +4 -4
- package/dist/esm/product/trialbanner/trialbanner.js +2 -2
- package/dist/esm/product/trialbanner/trialbanner.recipe.js +2 -2
- package/dist/esm/product/viewtoggle/viewtoggle.js +10 -2
- package/dist/esm/product/viewtoggle/viewtoggle.recipe.js +1 -1
- package/dist/esm/tokens/elevation.js +44 -0
- package/dist/esm/tokens/index.js +1 -0
- package/dist/esm/tokens/palette.js +30 -0
- package/dist/esm/tokens/scale.js +7 -0
- package/dist/esm/tokens/semantic.js +24 -0
- package/dist/inbox.css +9 -1
- package/dist/input.css +32 -4
- package/dist/linechart.css +5 -5
- package/dist/listpage.css +11 -3
- package/dist/menu.css +11 -3
- package/dist/multiselect.css +14 -6
- package/dist/native/tokens.d.ts +16 -0
- package/dist/native/tokens.js +221 -0
- package/dist/navitem.css +21 -1
- package/dist/onboarding.css +10 -2
- package/dist/popover.css +8 -0
- package/dist/progress.css +8 -0
- package/dist/radiogroup.css +9 -1
- package/dist/recordpage.css +22 -12
- package/dist/recordpanel.css +25 -15
- package/dist/recordstable.css +37 -23
- package/dist/resizablepanel.css +53 -0
- package/dist/resizablepanel.d.ts +7 -0
- package/dist/richtext.css +11 -3
- package/dist/segmented.css +8 -0
- package/dist/select.css +12 -4
- package/dist/settingsshell.css +15 -2
- package/dist/sidebar.css +34 -1
- package/dist/skeleton.css +8 -0
- package/dist/spinner.css +8 -0
- package/dist/stagebar.css +8 -0
- package/dist/styles.css +2051 -1111
- package/dist/switch.css +8 -0
- package/dist/table.css +14 -6
- package/dist/tabletoolbar.css +8 -0
- package/dist/tabs.css +12 -4
- package/dist/tasklist.css +8 -0
- package/dist/textarea.css +23 -3
- package/dist/toast.css +10 -2
- package/dist/tokens.css +29 -0
- package/dist/tokens.json +217 -0
- package/dist/tooltip.css +8 -0
- package/dist/trialbanner.css +8 -0
- package/dist/types/components/accordion/accordion.d.ts +10 -8
- package/dist/types/components/avatargroup/avatargroup.d.ts +2 -2
- package/dist/types/components/barchart/barchart.d.ts +4 -2
- package/dist/types/components/breadcrumb/breadcrumb.d.ts +2 -2
- package/dist/types/components/bulkbar/bulkbar.d.ts +4 -2
- package/dist/types/components/button/button.d.ts +8 -0
- package/dist/types/components/button/button.recipe.d.ts +12 -0
- package/dist/types/components/callout/callout.d.ts +2 -2
- package/dist/types/components/columncalc/columncalc.d.ts +49 -0
- package/dist/types/components/columncalc/columncalc.recipe.d.ts +3 -0
- package/dist/types/components/columncalc/index.d.ts +1 -0
- package/dist/types/components/datatable/datatable.d.ts +58 -3
- package/dist/types/components/datepicker/datepicker.d.ts +41 -18
- package/dist/types/components/datepicker/datepicker.recipe.d.ts +25 -2
- package/dist/types/components/datepicker/index.d.ts +1 -1
- package/dist/types/components/datepickerfield/datepickerfield.d.ts +35 -0
- package/dist/types/components/datepickerfield/datepickerfield.recipe.d.ts +5 -0
- package/dist/types/components/datepickerfield/index.d.ts +2 -0
- package/dist/types/components/dialog/dialog.d.ts +3 -1
- package/dist/types/components/divider/divider.d.ts +2 -2
- package/dist/types/components/donutchart/donutchart.d.ts +2 -2
- package/dist/types/components/drawer/drawer.d.ts +3 -1
- package/dist/types/components/emptystate/emptystate.d.ts +2 -2
- package/dist/types/components/formfield/formfield.d.ts +7 -4
- package/dist/types/components/input/input.d.ts +8 -2
- package/dist/types/components/linechart/linechart.d.ts +4 -2
- package/dist/types/components/menu/index.d.ts +1 -0
- package/dist/types/components/menu/menu-keyboard.d.ts +33 -0
- package/dist/types/components/menu/menu.d.ts +7 -1
- package/dist/types/components/multiselect/multiselect.d.ts +8 -4
- package/dist/types/components/popover/popover.d.ts +4 -1
- package/dist/types/components/progress/progress.d.ts +2 -2
- package/dist/types/components/radiogroup/radiogroup.d.ts +2 -2
- package/dist/types/components/resizablepanel/index.d.ts +2 -0
- package/dist/types/components/resizablepanel/resizablepanel.d.ts +75 -0
- package/dist/types/components/resizablepanel/resizablepanel.recipe.d.ts +3 -0
- package/dist/types/components/segmented/segmented.d.ts +2 -2
- package/dist/types/components/select/select.d.ts +2 -2
- package/dist/types/components/skeleton/skeleton.d.ts +2 -2
- package/dist/types/components/spinner/spinner.d.ts +2 -2
- package/dist/types/components/stagebar/stagebar.d.ts +2 -2
- package/dist/types/components/statcard/statcard.d.ts +2 -2
- package/dist/types/components/tabletoolbar/tabletoolbar.d.ts +28 -2
- package/dist/types/components/tabs/tabs.d.ts +2 -2
- package/dist/types/components/toast/toast.d.ts +7 -1
- package/dist/types/components/tooltip/tooltip.d.ts +8 -1
- package/dist/types/components/wheelpicker/index.d.ts +2 -0
- package/dist/types/components/wheelpicker/wheelpicker.d.ts +37 -0
- package/dist/types/components/wheelpicker/wheelpicker.recipe.d.ts +26 -0
- package/dist/types/index.d.ts +5 -0
- package/dist/types/product/appshell/appshell.d.ts +16 -2
- package/dist/types/product/authshell/authshell.d.ts +28 -0
- package/dist/types/product/authshell/authshell.recipe.d.ts +3 -0
- package/dist/types/product/authshell/index.d.ts +2 -0
- package/dist/types/product/board/board.d.ts +2 -2
- package/dist/types/product/command/command.d.ts +25 -1
- package/dist/types/product/entitycard/entitycard.d.ts +2 -2
- package/dist/types/product/flowcanvas/flowcanvas.d.ts +9 -1
- package/dist/types/product/onboarding/onboarding.d.ts +7 -1
- package/dist/types/product/recordpage/recordpage.d.ts +65 -1
- package/dist/types/product/recordpanel/recordpanel.d.ts +8 -2
- package/dist/types/product/recordstable/recordstable.d.ts +90 -1
- package/dist/types/product/recordstable/recordstable.tag.d.ts +10 -0
- package/dist/types/product/richtext/richtext.d.ts +5 -1
- package/dist/types/product/settingssection/settingssection.d.ts +2 -2
- package/dist/types/product/settingsshell/settingsshell.d.ts +6 -2
- package/dist/types/product/sidebar/sidebar.d.ts +8 -0
- package/dist/types/product/tasklist/tasklist.d.ts +5 -1
- package/dist/types/product/trialbanner/trialbanner.d.ts +2 -2
- package/dist/types/product/viewtoggle/viewtoggle.d.ts +11 -5
- package/dist/types/tokens/contract.d.ts +14 -3
- package/dist/types/tokens/elevation.d.ts +44 -0
- package/dist/types/tokens/index.d.ts +1 -0
- package/dist/types/tokens/palette.d.ts +40 -0
- package/dist/types/tokens/scale.d.ts +7 -0
- package/dist/types/tokens/semantic.d.ts +19 -0
- package/dist/viewtoggle.css +9 -1
- package/dist/wheelpicker.css +68 -0
- package/dist/wheelpicker.d.ts +7 -0
- package/package.json +160 -68
package/README.md
CHANGED
|
@@ -24,6 +24,15 @@ React 18+ is a peer dependency:
|
|
|
24
24
|
npm install react react-dom
|
|
25
25
|
```
|
|
26
26
|
|
|
27
|
+
crisp ships **ESM and CommonJS**, so both `import` and `require` work. Every
|
|
28
|
+
component also has its own subpath, which is what keeps a one-component import
|
|
29
|
+
small (a lone `Badge` bundles to ~8 KB):
|
|
30
|
+
|
|
31
|
+
```tsx
|
|
32
|
+
import { Badge } from "@crisp-ui-kit/crisp"; // barrel — tree-shakes
|
|
33
|
+
import { Menu } from "@crisp-ui-kit/crisp/menu"; // or import it directly
|
|
34
|
+
```
|
|
35
|
+
|
|
27
36
|
## Usage
|
|
28
37
|
|
|
29
38
|
Import the stylesheet **once** at your app root, then use components anywhere:
|
|
@@ -39,6 +48,11 @@ crisp's own tokens (plus box-sizing and `color-scheme`), so a fresh app doesn't
|
|
|
39
48
|
render Times New Roman on a transparent background. Import it first, before
|
|
40
49
|
`styles.css`.
|
|
41
50
|
|
|
51
|
+
`styles.css` already contains the design tokens, so that one import is enough.
|
|
52
|
+
`@crisp-ui-kit/crisp/tokens.css` is available separately for the rare case of
|
|
53
|
+
wanting the tokens **without** the component styles — theming another library
|
|
54
|
+
from crisp's palette, for instance.
|
|
55
|
+
|
|
42
56
|
```tsx
|
|
43
57
|
import { Button, Badge, EmptyState } from "@crisp-ui-kit/crisp";
|
|
44
58
|
|
package/dist/accordion.css
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
.accordion {
|
|
2
2
|
display: flex; flex-direction: column; font-family: var(--font-sans);
|
|
3
3
|
& .accordion-item { border-bottom: 1px solid var(--border-subtle); }
|
|
4
|
-
& .accordion-trigger { display: flex; align-items: center; gap: var(--space-2); width: 100%; height: 44px; padding: 0 var(--space-1); margin: 0; border: none; background: none; color: var(--fg-primary); font-family: inherit; font-size: var(--text-lg); font-weight: var(--weight-medium); text-align:
|
|
4
|
+
& .accordion-trigger { display: flex; align-items: center; gap: var(--space-2); width: 100%; height: 44px; padding: 0 var(--space-1); margin: 0; border: none; background: none; color: var(--fg-primary); font-family: inherit; font-size: var(--text-lg); font-weight: var(--weight-medium); text-align: start; cursor: pointer; }
|
|
5
5
|
& .accordion-trigger:hover { color: var(--fg-primary); }
|
|
6
6
|
& .accordion-title { flex: 1; min-width: 0; }
|
|
7
7
|
& .accordion-chevron { flex-shrink: 0; color: var(--fg-muted); transition: transform .2s ease; }
|
|
@@ -11,3 +11,11 @@
|
|
|
11
11
|
& .accordion-panel-inner { overflow: hidden; }
|
|
12
12
|
& .accordion-content { padding: 0 var(--space-1) var(--space-3); font-size: var(--text-md); color: var(--fg-muted); }
|
|
13
13
|
}
|
|
14
|
+
|
|
15
|
+
@media (prefers-reduced-motion: reduce) {
|
|
16
|
+
.accordion, .accordion * {
|
|
17
|
+
animation-duration: 0.01ms !important;
|
|
18
|
+
animation-iteration-count: 1 !important;
|
|
19
|
+
transition-duration: 0.01ms !important;
|
|
20
|
+
}
|
|
21
|
+
}
|
package/dist/appshell.css
CHANGED
|
@@ -3,11 +3,19 @@
|
|
|
3
3
|
display: flex; height: 100%; width: 100%; overflow: hidden; background: var(--bg-surface); font-family: var(--font-sans); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
|
|
4
4
|
& .appshell-side { position: relative; flex-shrink: 0; overflow: hidden; }
|
|
5
5
|
& .appshell-side-inner { height: 100%; }
|
|
6
|
-
& .appshell-resize { position: absolute; top: 0; right: 0; width:
|
|
7
|
-
& .appshell-resize::after { content: ""; position: absolute; top: 0; right: 0; width:
|
|
8
|
-
& .appshell-resize:hover::after, & .appshell-resize[data-dragging]::after { background: var(--bg-brand-solid); }
|
|
6
|
+
& .appshell-resize { position: absolute; top: 0; right: 0; width: 10px; height: 100%; cursor: col-resize; z-index: 5; touch-action: none; }
|
|
7
|
+
& .appshell-resize::after { content: ""; position: absolute; top: 0; right: 0; width: 1px; height: 100%; background: var(--border-subtle); transition: background-color .16s, height .16s; }
|
|
8
|
+
& .appshell-resize:hover::after, & .appshell-resize[data-dragging]::after { width: 2px; background: var(--bg-brand-solid); }
|
|
9
9
|
& .appshell-main { position: relative; flex: 1; min-width: 0; display: flex; flex-direction: column; overflow: hidden; }
|
|
10
|
-
& .appshell-expand { position: absolute; top: var(--space-2);
|
|
10
|
+
& .appshell-expand { position: absolute; top: var(--space-2); inset-inline-start: var(--space-2); z-index: 6; display: inline-flex; align-items: center; justify-content: center; width: var(--size-row); height: var(--size-row); padding: 0; border: none; border-radius: var(--radius-md); box-shadow: inset 0 0 0 1px var(--border-subtle); background: var(--bg-surface); color: var(--fg-muted); font-family: inherit; cursor: pointer; transition: background-color .12s; }
|
|
11
11
|
& .appshell-expand:hover { background: var(--bg-raised); color: var(--fg-primary); }
|
|
12
12
|
|
|
13
13
|
}
|
|
14
|
+
|
|
15
|
+
@media (prefers-reduced-motion: reduce) {
|
|
16
|
+
.appshell, .appshell * {
|
|
17
|
+
animation-duration: 0.01ms !important;
|
|
18
|
+
animation-iteration-count: 1 !important;
|
|
19
|
+
transition-duration: 0.01ms !important;
|
|
20
|
+
}
|
|
21
|
+
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
.authshell {
|
|
2
|
+
min-height: 100%; box-sizing: border-box; display: flex; flex-direction: column; align-items: center; position: relative;
|
|
3
|
+
background: var(--bg-surface); font-family: var(--font-sans); font-size: var(--text-lg); line-height: 20px; color: var(--fg-primary);
|
|
4
|
+
-webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
|
|
5
|
+
|
|
6
|
+
& .authshell-progress { position: absolute; top: 0; left: 0; width: 100%; height: 2px; background: var(--border-default); }
|
|
7
|
+
& .authshell-progress-fill { height: 2px; background: var(--fg-primary); border-radius: 4px; transition: width .2s; }
|
|
8
|
+
|
|
9
|
+
& .authshell-logo { margin-top: var(--space-8); height: 24px; display: flex; align-items: center; }
|
|
10
|
+
|
|
11
|
+
& .authshell-card { margin-top: var(--space-6); display: flex; height: 692px; border-radius: 20px; border: 1px solid var(--border-subtle); overflow: hidden; }
|
|
12
|
+
|
|
13
|
+
& .authshell-pane { flex: 0 0 564px; padding: 72px; display: flex; flex-direction: column; box-sizing: border-box; }
|
|
14
|
+
|
|
15
|
+
& .authshell-preview { flex: 0 0 564px; padding: 96px 64px; background: var(--bg-subtle); border-inline-start: 1px solid color-mix(in srgb, var(--fg-primary) 5%, transparent); position: relative; overflow: hidden; box-sizing: border-box; }
|
|
16
|
+
& .authshell-preview::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 120px; background: linear-gradient(color-mix(in srgb, var(--bg-subtle) 0%, transparent) 0%, var(--bg-subtle) 100%); pointer-events: none; }
|
|
17
|
+
|
|
18
|
+
& .authshell-body { width: 420px; margin: 0 auto; display: flex; flex-direction: column; gap: var(--space-8); align-items: center; }
|
|
19
|
+
|
|
20
|
+
& .authshell-title { font-size: 20px; line-height: 24px; font-weight: var(--weight-semibold); letter-spacing: -0.4px; color: var(--fg-primary); align-self: stretch; }
|
|
21
|
+
|
|
22
|
+
& .authshell-form { align-self: stretch; display: flex; flex-direction: column; gap: 28px; }
|
|
23
|
+
|
|
24
|
+
& .authshell-footer { margin-top: var(--space-6); display: flex; align-items: center; gap: var(--space-1); font-size: var(--text-sm); line-height: 16px; color: color-mix(in srgb, var(--fg-primary) 63%, transparent); }
|
|
25
|
+
& .authshell-footer a { color: inherit; font-weight: var(--weight-medium); text-decoration: underline; }
|
|
26
|
+
|
|
27
|
+
/* Auth-surface control treatment: flatter than the in-app chrome — a plain
|
|
28
|
+
hairline ring instead of elevation.field's soft glow, and a 36px (not
|
|
29
|
+
40px) submit. Scoped to .authshell-body so a consumer keeps using
|
|
30
|
+
crisp's Input / FormField / Button and gets the auth treatment for free. */
|
|
31
|
+
& .authshell-body .formfield-label { font-size: var(--text-sm); line-height: 16px; font-weight: var(--weight-medium); letter-spacing: -0.12px; color: color-mix(in srgb, var(--fg-primary) 50%, transparent); padding-inline-start: var(--space-1); }
|
|
32
|
+
& .authshell-body .formfield { gap: var(--space-1); }
|
|
33
|
+
& .authshell-body .input { height: 34px; padding-inline: var(--space-2-5); border-radius: 10px; background: transparent; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--fg-primary) 6%, transparent); font-size: var(--text-lg); font-weight: var(--weight-medium); letter-spacing: -0.14px; transition: box-shadow .14s, background-color .14s; }
|
|
34
|
+
& .authshell-body .input:focus { box-shadow: inset 0 0 0 1px var(--bg-brand-solid); }
|
|
35
|
+
/* Same three-layer brand shadow as Button's primary intent, but the auth
|
|
36
|
+
button's inset ring is measured at rgba(0,0,0,0.06) — a hairline, not
|
|
37
|
+
the in-app button's rgba(255,255,255,0.07) highlight. */
|
|
38
|
+
& .authshell-body .button { height: 36px; padding-inline: var(--space-3); border-radius: 10px; }
|
|
39
|
+
& .authshell-body .button--intent_primary { box-shadow: inset 0 0 0 1px rgba(0,0,0,0.06), 0 2px 4px -2px rgba(38,109,240,0.12), 0 3px 6px -2px rgba(38,109,240,0.08); }
|
|
40
|
+
|
|
41
|
+
/* Attio drops the preview pane in JS on narrow viewports (measured: two
|
|
42
|
+
panes at 1393px, one at 954px), so 1200px is a chosen threshold inside
|
|
43
|
+
that bracket, not a measured value. A CONTAINER query, not a media
|
|
44
|
+
query: the shell is embedded in the docs inside an ~800px column, where
|
|
45
|
+
a viewport query would keep the 1130px card and overflow it. Asking the
|
|
46
|
+
shell's own width is what "there isn't room for the preview" means. */
|
|
47
|
+
container-type: inline-size;
|
|
48
|
+
@container (max-width: 1200px) { & .authshell-preview { display: none; } }
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
@media (prefers-reduced-motion: reduce) {
|
|
52
|
+
.authshell, .authshell * {
|
|
53
|
+
animation-duration: 0.01ms !important;
|
|
54
|
+
animation-iteration-count: 1 !important;
|
|
55
|
+
transition-duration: 0.01ms !important;
|
|
56
|
+
}
|
|
57
|
+
}
|
package/dist/avatargroup.css
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
.avatargroup {
|
|
2
2
|
display: inline-flex; align-items: center;
|
|
3
|
-
& > * { margin-
|
|
4
|
-
& > *:first-child { margin-
|
|
3
|
+
& > * { margin-inline-start: -var(--space-2); box-shadow: 0 0 0 2px var(--bg-surface); position: relative; }
|
|
4
|
+
& > *:first-child { margin-inline-start: 0; }
|
|
5
5
|
}
|
package/dist/badge.css
CHANGED
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
height: 20px; padding-inline: var(--space-2); font-size: var(--text-sm); border-radius: var(--radius-sm);
|
|
25
25
|
}
|
|
26
26
|
.badge--size_large {
|
|
27
|
-
height:
|
|
27
|
+
height: var(--size-chip); padding-inline: 9px; font-size: var(--text-lg); border-radius: var(--radius-chip);
|
|
28
28
|
}
|
|
29
29
|
.badge--variant_soft {
|
|
30
30
|
|
|
@@ -36,13 +36,13 @@
|
|
|
36
36
|
background: var(--bg-brand-solid); color: var(--fg-on-brand); box-shadow: none;
|
|
37
37
|
}
|
|
38
38
|
.badge--compound_1 {
|
|
39
|
-
background: var(--bg-success); color: var(--fg-on-
|
|
39
|
+
background: var(--bg-success); color: var(--fg-on-tone); box-shadow: none;
|
|
40
40
|
}
|
|
41
41
|
.badge--compound_2 {
|
|
42
|
-
background: var(--bg-warning); color: var(--fg-on-
|
|
42
|
+
background: var(--bg-warning); color: var(--fg-on-tone); box-shadow: none;
|
|
43
43
|
}
|
|
44
44
|
.badge--compound_3 {
|
|
45
|
-
background: var(--bg-danger); color: var(--fg-on-
|
|
45
|
+
background: var(--bg-danger); color: var(--fg-on-tone); box-shadow: none;
|
|
46
46
|
}
|
|
47
47
|
.badge--compound_4 {
|
|
48
48
|
background: var(--fg-muted); color: var(--bg-surface); box-shadow: none;
|
package/dist/barchart.css
CHANGED
|
@@ -1,15 +1,23 @@
|
|
|
1
1
|
.barchart {
|
|
2
|
-
display: flex; flex-direction: column; box-sizing: border-box; font-family: var(--font-sans);
|
|
2
|
+
display: flex; flex-direction: column; box-sizing: border-box; font-family: var(--font-sans); --barchart-yaxis-width: 34px;
|
|
3
3
|
& .barchart-body { display: flex; flex: 1; min-height: 0; }
|
|
4
|
-
& .barchart-yaxis { position: relative; flex-shrink: 0; width:
|
|
5
|
-
& .barchart-ytick { position: absolute;
|
|
4
|
+
& .barchart-yaxis { position: relative; flex-shrink: 0; width: var(--barchart-yaxis-width); }
|
|
5
|
+
& .barchart-ytick { position: absolute; inset-inline-end: var(--space-2); transform: translateY(50%); font-size: var(--text-xs); color: var(--fg-muted); white-space: nowrap; }
|
|
6
6
|
& .barchart-plot { position: relative; flex: 1; min-width: 0; display: flex; align-items: flex-end; gap: var(--space-3); border-bottom: 1px solid var(--border-default); }
|
|
7
7
|
& .barchart-grid { position: absolute; left: 0; right: 0; border-top: 1px dashed var(--border-subtle); pointer-events: none; }
|
|
8
8
|
& .barchart-col { position: relative; flex: 1; min-width: 0; height: 100%; display: flex; align-items: flex-end; justify-content: center; }
|
|
9
9
|
& .barchart-bar { width: 100%; max-width: 96px; border-radius: var(--radius-sm) var(--radius-sm) 0 0; background: var(--bg-brand-solid); transition: height 0.3s ease; }
|
|
10
10
|
& .barchart-bar[data-empty] { min-height: 2px; opacity: 0.35; }
|
|
11
11
|
& .barchart-xaxis { display: flex; gap: var(--space-3); margin-top: var(--space-1-5); }
|
|
12
|
-
& .barchart-xaxis[data-inset] { padding-
|
|
12
|
+
& .barchart-xaxis[data-inset] { padding-inline-start: var(--barchart-yaxis-width); }
|
|
13
13
|
& .barchart-xlabel { flex: 1; min-width: 0; text-align: center; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: var(--text-sm); color: var(--fg-muted); }
|
|
14
|
-
& .barchart-axis-title { margin-top: var(--space-1); padding-
|
|
14
|
+
& .barchart-axis-title { margin-top: var(--space-1); padding-inline-start: var(--barchart-yaxis-width); text-align: center; font-size: var(--text-sm); color: var(--fg-muted); }
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
@media (prefers-reduced-motion: reduce) {
|
|
18
|
+
.barchart, .barchart * {
|
|
19
|
+
animation-duration: 0.01ms !important;
|
|
20
|
+
animation-iteration-count: 1 !important;
|
|
21
|
+
transition-duration: 0.01ms !important;
|
|
22
|
+
}
|
|
15
23
|
}
|
package/dist/board.css
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
& .board-col-dot { width: 9px; height: 9px; border-radius: var(--radius-full); flex-shrink: 0; }
|
|
6
6
|
& .board-col-title { font-size: var(--text-lg); font-weight: var(--weight-semibold); color: var(--fg-primary); }
|
|
7
7
|
& .board-col-count { font-size: var(--text-md); color: var(--fg-muted); }
|
|
8
|
-
& .board-col-add { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; margin-
|
|
8
|
+
& .board-col-add { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; margin-inline-start: auto; padding: 0; border: none; border-radius: var(--radius-md); background: none; color: var(--fg-muted); font-family: inherit; cursor: pointer; }
|
|
9
9
|
& .board-col-add:hover { background: color-mix(in srgb, var(--fg-primary) 6%, transparent); color: var(--fg-primary); }
|
|
10
10
|
& .board-col-body { display: flex; flex-direction: column; gap: var(--space-2); flex: 1; min-height: 48px; padding: var(--space-1); border-radius: var(--radius-lg); overflow-y: auto; transition: background 0.12s; }
|
|
11
11
|
& .board-col[data-over] .board-col-body { background: color-mix(in srgb, var(--bg-brand-solid) 7%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--bg-brand-solid) 30%, transparent); }
|
|
@@ -15,3 +15,11 @@
|
|
|
15
15
|
& .board-card:active { cursor: grabbing; }
|
|
16
16
|
& .board-card[data-dragging] { opacity: 0.4; }
|
|
17
17
|
}
|
|
18
|
+
|
|
19
|
+
@media (prefers-reduced-motion: reduce) {
|
|
20
|
+
.board, .board * {
|
|
21
|
+
animation-duration: 0.01ms !important;
|
|
22
|
+
animation-iteration-count: 1 !important;
|
|
23
|
+
transition-duration: 0.01ms !important;
|
|
24
|
+
}
|
|
25
|
+
}
|
package/dist/bulkbar.css
CHANGED
|
@@ -1,13 +1,21 @@
|
|
|
1
1
|
.bulkbar {
|
|
2
2
|
position: absolute; left: 0; right: 0; bottom: var(--space-4); display: flex; justify-content: center; pointer-events: none; z-index: 10;
|
|
3
|
-
& .bulkbar-bar { pointer-events: auto; display: flex; align-items: center; gap: var(--space-0-5); height:
|
|
3
|
+
& .bulkbar-bar { pointer-events: auto; display: flex; align-items: center; gap: var(--space-0-5); height: 48px; padding: 0 var(--space-1) 0 var(--space-1-5); border-radius: 14px; background: var(--bg-surface); box-shadow: inset 0 0 0 1px var(--ring-popover), 0 0 0 1px var(--shadow-popover1), 0 4px 8px -4px var(--shadow-popover2), 0 4px 12px -2px var(--shadow-popover3); color: var(--fg-primary); transition: opacity .16s ease, transform .16s ease; }
|
|
4
4
|
& .bulkbar-bar { @starting-style { opacity: 0; transform: translateY(10px); } }
|
|
5
|
-
& .bulkbar-count { display: inline-flex; align-items: center; gap: var(--space-1); height:
|
|
5
|
+
& .bulkbar-count { display: inline-flex; align-items: center; gap: var(--space-1); height: var(--size-menuRow); margin: 0; padding: 0 var(--space-2); border: none; border-radius: var(--radius-md); background: color-mix(in srgb, var(--fg-primary) 4%, transparent); font-family: inherit; font-size: var(--text-md); font-weight: var(--weight-medium); color: var(--fg-muted); white-space: nowrap; cursor: pointer; transition: background-color .12s; }
|
|
6
6
|
& .bulkbar-count:hover { background: color-mix(in srgb, var(--fg-primary) 8%, transparent); color: var(--fg-primary); }
|
|
7
7
|
& .bulkbar-count svg { flex-shrink: 0; }
|
|
8
|
-
& .bulkbar-btn { display: inline-flex; align-items: center; gap: var(--space-1); height:
|
|
8
|
+
& .bulkbar-btn { display: inline-flex; align-items: center; gap: var(--space-1); height: var(--size-menuRow); padding: 0 var(--space-2); border: none; border-radius: var(--radius-md); background: transparent; color: var(--fg-primary); font-family: inherit; font-size: var(--text-md); font-weight: var(--weight-medium); white-space: nowrap; cursor: pointer; transition: background-color .12s; }
|
|
9
9
|
& .bulkbar-btn:hover { background: var(--bg-raised); }
|
|
10
10
|
& .bulkbar-btn--danger { color: var(--bg-danger); }
|
|
11
11
|
& .bulkbar-btn--danger:hover { background: color-mix(in srgb, var(--bg-danger) 10%, transparent); }
|
|
12
12
|
& .bulkbar-btn svg { flex-shrink: 0; }
|
|
13
13
|
}
|
|
14
|
+
|
|
15
|
+
@media (prefers-reduced-motion: reduce) {
|
|
16
|
+
.bulkbar, .bulkbar * {
|
|
17
|
+
animation-duration: 0.01ms !important;
|
|
18
|
+
animation-iteration-count: 1 !important;
|
|
19
|
+
transition-duration: 0.01ms !important;
|
|
20
|
+
}
|
|
21
|
+
}
|
package/dist/button.css
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
background: var(--bg-surface); color: var(--fg-primary); box-shadow: inset 0 0 0 1px var(--ring-neutral), 0 0 2px rgba(28,40,64,0.18), 0 1px 3px rgba(0,0,0,0.04); &:hover { background: var(--bg-raised); }
|
|
9
9
|
}
|
|
10
10
|
.button--intent_danger {
|
|
11
|
-
background: var(--bg-danger); color: var(--fg-on-brand); box-shadow: inset 0 0 0 1px rgba(255,255,255,0.07), 0 2px 4px -2px rgba(
|
|
11
|
+
background: var(--bg-danger-solid); color: var(--fg-on-brand); box-shadow: inset 0 0 0 1px rgba(255,255,255,0.07), 0 2px 4px -2px rgba(186,37,37,0.20), 0 3px 6px -2px rgba(186,37,37,0.12); &:hover { filter: brightness(0.96); } &:active { filter: brightness(0.92); }
|
|
12
12
|
}
|
|
13
13
|
.button--intent_ghost {
|
|
14
14
|
background: transparent; color: var(--fg-muted); box-shadow: none; &:hover { background: var(--bg-raised); color: var(--fg-primary); }
|
|
@@ -28,3 +28,17 @@
|
|
|
28
28
|
.button--shape_icon {
|
|
29
29
|
padding-inline: 0; aspect-ratio: 1 / 1;
|
|
30
30
|
}
|
|
31
|
+
.button--touchTarget_true {
|
|
32
|
+
position: relative; &::after { content: ""; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 100%; height: 100%; min-width: 44px; min-height: 44px; }
|
|
33
|
+
}
|
|
34
|
+
.button--touchTarget_false {
|
|
35
|
+
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
@media (prefers-reduced-motion: reduce) {
|
|
39
|
+
.button, .button * {
|
|
40
|
+
animation-duration: 0.01ms !important;
|
|
41
|
+
animation-iteration-count: 1 !important;
|
|
42
|
+
transition-duration: 0.01ms !important;
|
|
43
|
+
}
|
|
44
|
+
}
|
package/dist/button.d.ts
CHANGED
|
@@ -4,6 +4,7 @@ export interface ButtonVariants {
|
|
|
4
4
|
intent?: "primary" | "neutral" | "danger" | "ghost";
|
|
5
5
|
size?: "sm" | "md" | "lg";
|
|
6
6
|
shape?: "text" | "icon";
|
|
7
|
+
touchTarget?: boolean;
|
|
7
8
|
}
|
|
8
9
|
|
|
9
|
-
export declare const buttonRecipe: RecipeFn<{ intent: { primary: string; neutral: string; danger: string; ghost: string }; size: { sm: string; md: string; lg: string }; shape: { text: string; icon: string } }>;
|
|
10
|
+
export declare const buttonRecipe: RecipeFn<{ intent: { primary: string; neutral: string; danger: string; ghost: string }; size: { sm: string; md: string; lg: string }; shape: { text: string; icon: string }; touchTarget: { true: string; false: string } }>;
|
package/dist/card.css
CHANGED
package/dist/checkbox.css
CHANGED
|
@@ -1,3 +1,19 @@
|
|
|
1
1
|
.checkbox {
|
|
2
|
-
appearance: none; -webkit-appearance: none; box-sizing: border-box; flex-shrink: 0; margin: 0; width: 16px; height: 16px; border: none; border-radius: var(--radius-sm)
|
|
2
|
+
appearance: none; -webkit-appearance: none; box-sizing: border-box; flex-shrink: 0; margin: 0; width: 16px; height: 16px; border: none; border-radius: var(--radius-sm)
|
|
3
|
+
; background: var(--bg-surface)
|
|
4
|
+
; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--fg-primary)
|
|
5
|
+
9%, transparent); cursor: pointer; transition: background-color .12s, box-shadow .12s; &:hover { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--fg-primary) 30%, transparent); }
|
|
6
|
+
&:checked, &:indeterminate { background: var(--bg-brand-solid) center / 10px no-repeat; box-shadow: none; }
|
|
7
|
+
&:checked { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 12 12' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2.5 6.5 5 9l4.5-5'/%3E%3C/svg%3E"); }
|
|
8
|
+
&:indeterminate { background-image: linear-gradient(var(--fg-on-brand), var(--fg-on-brand)); background-size: 8px 2px; }
|
|
9
|
+
&:focus-visible { outline: 2px solid var(--bg-brand-solid); outline-offset: 1px; }
|
|
10
|
+
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
@media (prefers-reduced-motion: reduce) {
|
|
14
|
+
.checkbox, .checkbox * {
|
|
15
|
+
animation-duration: 0.01ms !important;
|
|
16
|
+
animation-iteration-count: 1 !important;
|
|
17
|
+
transition-duration: 0.01ms !important;
|
|
18
|
+
}
|
|
3
19
|
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
35
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
+
exports.Accordion = Accordion;
|
|
37
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
38
|
+
const lucide_react_1 = require("lucide-react");
|
|
39
|
+
const React = __importStar(require("react"));
|
|
40
|
+
const accordion_recipe_1 = require("./accordion.recipe");
|
|
41
|
+
/**
|
|
42
|
+
* A collapsible section list — measured from Attio's sidebar groups. Single or
|
|
43
|
+
* multiple open; panels animate their height (grid-rows 0fr->1fr). Headers are
|
|
44
|
+
* buttons with `aria-expanded` / `aria-controls`.
|
|
45
|
+
*/
|
|
46
|
+
const toSet = (v) => new Set(v == null ? [] : Array.isArray(v) ? v : [v]);
|
|
47
|
+
function Accordion({ items, multiple, value, defaultValue, onValueChange, className, ...rest }) {
|
|
48
|
+
const [internal, setInternal] = React.useState(() => toSet(defaultValue));
|
|
49
|
+
// `value` present means the caller owns the open set; our own state is then
|
|
50
|
+
// never read, so a click can only change what is shown by going through
|
|
51
|
+
// onValueChange and coming back as a new `value`.
|
|
52
|
+
const open = value !== undefined ? toSet(value) : internal;
|
|
53
|
+
const toggle = (itemValue) => {
|
|
54
|
+
const next = new Set(multiple ? open : []);
|
|
55
|
+
if (open.has(itemValue))
|
|
56
|
+
next.delete(itemValue);
|
|
57
|
+
else
|
|
58
|
+
next.add(itemValue);
|
|
59
|
+
onValueChange?.(multiple ? [...next] : ([...next][0] ?? ""));
|
|
60
|
+
if (value === undefined)
|
|
61
|
+
setInternal(next);
|
|
62
|
+
};
|
|
63
|
+
return ((0, jsx_runtime_1.jsx)("div", { className: (0, accordion_recipe_1.accordionRecipe)({ className }), ...rest, children: items.map((item) => {
|
|
64
|
+
const isOpen = open.has(item.value);
|
|
65
|
+
const panelId = `accordion-panel-${item.value}`;
|
|
66
|
+
return ((0, jsx_runtime_1.jsxs)("div", { className: "accordion-item", children: [(0, jsx_runtime_1.jsxs)("button", { type: "button", className: "accordion-trigger", "aria-expanded": isOpen, "aria-controls": panelId, onClick: () => toggle(item.value), children: [(0, jsx_runtime_1.jsx)("span", { className: "accordion-title", children: item.title }), (0, jsx_runtime_1.jsx)(lucide_react_1.ChevronDown, { className: "accordion-chevron", size: 16, strokeWidth: 1.75, "aria-hidden": "true" })] }), (0, jsx_runtime_1.jsx)("div", { id: panelId, className: "accordion-panel", role: "region", "data-open": isOpen ? "" : undefined, hidden: !isOpen, children: (0, jsx_runtime_1.jsx)("div", { className: "accordion-panel-inner", children: (0, jsx_runtime_1.jsx)("div", { className: "accordion-content", children: item.content }) }) })] }, item.value));
|
|
67
|
+
}) }));
|
|
68
|
+
}
|
|
69
|
+
Accordion.displayName = "Accordion";
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.accordionRecipe = void 0;
|
|
4
|
+
const core_1 = require("../../core");
|
|
5
|
+
const tokens_1 = require("../../tokens");
|
|
6
|
+
// A stack of collapsible sections — Attio's sidebar sections / "view all".
|
|
7
|
+
// The panel animates height via the grid-template-rows 0fr->1fr technique.
|
|
8
|
+
const config = (0, core_1.defineRecipe)({
|
|
9
|
+
name: "accordion",
|
|
10
|
+
base: `display: flex; flex-direction: column; font-family: ${tokens_1.contract.font.sans};
|
|
11
|
+
& .accordion-item { border-bottom: 1px solid ${tokens_1.contract.borderSubtle}; }
|
|
12
|
+
& .accordion-trigger { display: flex; align-items: center; gap: ${tokens_1.contract.space["2"]}; width: 100%; height: 44px; padding: 0 ${tokens_1.contract.space["1"]}; margin: 0; border: none; background: none; color: ${tokens_1.contract.fgPrimary}; font-family: inherit; font-size: ${tokens_1.contract.text.lg}; font-weight: ${tokens_1.contract.weight.medium}; text-align: start; cursor: pointer; }
|
|
13
|
+
& .accordion-trigger:hover { color: ${tokens_1.contract.fgPrimary}; }
|
|
14
|
+
& .accordion-title { flex: 1; min-width: 0; }
|
|
15
|
+
& .accordion-chevron { flex-shrink: 0; color: ${tokens_1.contract.fgMuted}; transition: transform .2s ease; }
|
|
16
|
+
& .accordion-trigger[aria-expanded="true"] .accordion-chevron { transform: rotate(180deg); }
|
|
17
|
+
& .accordion-panel { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .2s ease; }
|
|
18
|
+
& .accordion-panel[data-open] { grid-template-rows: 1fr; }
|
|
19
|
+
& .accordion-panel-inner { overflow: hidden; }
|
|
20
|
+
& .accordion-content { padding: 0 ${tokens_1.contract.space["1"]} ${tokens_1.contract.space["3"]}; font-size: ${tokens_1.contract.text.md}; color: ${tokens_1.contract.fgMuted}; }`,
|
|
21
|
+
variants: {},
|
|
22
|
+
defaultVariants: {},
|
|
23
|
+
compoundVariants: [],
|
|
24
|
+
});
|
|
25
|
+
exports.accordionRecipe = (0, core_1.resolveRecipe)(config);
|
|
26
|
+
exports.default = config;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.accordionRecipe = exports.Accordion = void 0;
|
|
4
|
+
var accordion_1 = require("./accordion");
|
|
5
|
+
Object.defineProperty(exports, "Accordion", { enumerable: true, get: function () { return accordion_1.Accordion; } });
|
|
6
|
+
var accordion_recipe_1 = require("./accordion.recipe");
|
|
7
|
+
Object.defineProperty(exports, "accordionRecipe", { enumerable: true, get: function () { return accordion_recipe_1.accordionRecipe; } });
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
35
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
+
exports.Avatar = void 0;
|
|
37
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
38
|
+
const React = __importStar(require("react"));
|
|
39
|
+
const core_1 = require("../../core");
|
|
40
|
+
const avatar_recipe_1 = require("./avatar.recipe");
|
|
41
|
+
exports.Avatar = React.forwardRef(({ size, shape, tone, className, asChild, ...props }, ref) => {
|
|
42
|
+
return ((0, jsx_runtime_1.jsx)(core_1.Primitive.span, { ref: ref, asChild: asChild, className: (0, avatar_recipe_1.avatarRecipe)({ size, shape, tone, className }), ...props }));
|
|
43
|
+
});
|
|
44
|
+
exports.Avatar.displayName = "Avatar";
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.avatarRecipe = void 0;
|
|
4
|
+
const core_1 = require("../../core");
|
|
5
|
+
const tokens_1 = require("../../tokens");
|
|
6
|
+
const config = (0, core_1.defineRecipe)({
|
|
7
|
+
name: "avatar",
|
|
8
|
+
base: `display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; font-family: ${tokens_1.contract.font.sans}; font-weight: ${tokens_1.contract.weight.semibold}; overflow: hidden; user-select: none; & img { width: 100%; height: 100%; object-fit: cover; }`,
|
|
9
|
+
variants: {
|
|
10
|
+
size: {
|
|
11
|
+
sm: `height: 16px; width: 16px; font-size: 9px;`,
|
|
12
|
+
md: `height: 20px; width: 20px; font-size: 10px;`,
|
|
13
|
+
lg: `height: 24px; width: 24px; font-size: ${tokens_1.contract.text.sm};`,
|
|
14
|
+
xl: `height: 32px; width: 32px; font-size: ${tokens_1.contract.text.lg};`,
|
|
15
|
+
},
|
|
16
|
+
shape: {
|
|
17
|
+
circle: `border-radius: ${tokens_1.contract.radius.full};`,
|
|
18
|
+
rounded: `border-radius: 30%;`,
|
|
19
|
+
},
|
|
20
|
+
tone: {
|
|
21
|
+
neutral: `background: ${tokens_1.contract.bgRaised}; color: ${tokens_1.contract.fgMuted}; box-shadow: inset 0 0 0 1px ${tokens_1.contract.borderDefault};`,
|
|
22
|
+
brand: `background: ${tokens_1.contract.bgBrandSolid}; color: #fff;`,
|
|
23
|
+
orange: `background: ${tokens_1.contract.bgOrange}; color: #fff;`,
|
|
24
|
+
cyan: `background: ${tokens_1.contract.bgCyan}; color: #fff;`,
|
|
25
|
+
purple: `background: ${tokens_1.contract.bgPurple}; color: #fff;`,
|
|
26
|
+
green: `background: ${tokens_1.contract.bgSuccess}; color: #fff;`,
|
|
27
|
+
},
|
|
28
|
+
},
|
|
29
|
+
defaultVariants: { size: "md", shape: "circle", tone: "neutral" },
|
|
30
|
+
compoundVariants: [],
|
|
31
|
+
});
|
|
32
|
+
exports.avatarRecipe = Object.assign((0, core_1.resolveRecipe)(config), {
|
|
33
|
+
config,
|
|
34
|
+
meta: {
|
|
35
|
+
lg: {
|
|
36
|
+
height: "24px",
|
|
37
|
+
fontSize: "12px",
|
|
38
|
+
fontWeight: "600",
|
|
39
|
+
},
|
|
40
|
+
},
|
|
41
|
+
});
|
|
42
|
+
exports.default = config;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.avatarRecipe = exports.Avatar = void 0;
|
|
4
|
+
var avatar_1 = require("./avatar");
|
|
5
|
+
Object.defineProperty(exports, "Avatar", { enumerable: true, get: function () { return avatar_1.Avatar; } });
|
|
6
|
+
var avatar_recipe_1 = require("./avatar.recipe");
|
|
7
|
+
Object.defineProperty(exports, "avatarRecipe", { enumerable: true, get: function () { return avatar_recipe_1.avatarRecipe; } });
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
35
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
+
exports.AvatarGroup = AvatarGroup;
|
|
37
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
38
|
+
const React = __importStar(require("react"));
|
|
39
|
+
const avatar_1 = require("../avatar/avatar");
|
|
40
|
+
const avatargroup_recipe_1 = require("./avatargroup.recipe");
|
|
41
|
+
/**
|
|
42
|
+
* A stack of overlapping avatars with an optional "+N" overflow chip — measured
|
|
43
|
+
* from Attio's team / member rows. Pass `<Avatar>` children; each is ringed in
|
|
44
|
+
* the surface colour so it reads against its neighbour.
|
|
45
|
+
*/
|
|
46
|
+
function AvatarGroup({ children, max, size = "md", className, "aria-label": ariaLabel, ...rest }) {
|
|
47
|
+
const items = React.Children.toArray(children);
|
|
48
|
+
const shown = max != null ? items.slice(0, max) : items;
|
|
49
|
+
const overflow = items.length - shown.length;
|
|
50
|
+
return ((0, jsx_runtime_1.jsxs)("div", { className: (0, avatargroup_recipe_1.avatargroupRecipe)({ className }), ...rest, role: "group", "aria-label": ariaLabel, children: [shown, overflow > 0 && ((0, jsx_runtime_1.jsxs)(avatar_1.Avatar, { size: size, shape: "circle", tone: "neutral", children: ["+", overflow] }))] }));
|
|
51
|
+
}
|
|
52
|
+
AvatarGroup.displayName = "AvatarGroup";
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.avatargroupRecipe = void 0;
|
|
4
|
+
const core_1 = require("../../core");
|
|
5
|
+
const tokens_1 = require("../../tokens");
|
|
6
|
+
// A row of overlapping avatars — each ringed in the surface colour so it reads
|
|
7
|
+
// against its neighbour, with a "+N" overflow chip.
|
|
8
|
+
const config = (0, core_1.defineRecipe)({
|
|
9
|
+
name: "avatargroup",
|
|
10
|
+
base: `display: inline-flex; align-items: center;
|
|
11
|
+
& > * { margin-inline-start: -${tokens_1.contract.space["2"]}; box-shadow: 0 0 0 2px ${tokens_1.contract.bgSurface}; position: relative; }
|
|
12
|
+
& > *:first-child { margin-inline-start: 0; }`,
|
|
13
|
+
variants: {},
|
|
14
|
+
defaultVariants: {},
|
|
15
|
+
compoundVariants: [],
|
|
16
|
+
});
|
|
17
|
+
exports.avatargroupRecipe = (0, core_1.resolveRecipe)(config);
|
|
18
|
+
exports.default = config;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.avatargroupRecipe = exports.AvatarGroup = void 0;
|
|
4
|
+
var avatargroup_1 = require("./avatargroup");
|
|
5
|
+
Object.defineProperty(exports, "AvatarGroup", { enumerable: true, get: function () { return avatargroup_1.AvatarGroup; } });
|
|
6
|
+
var avatargroup_recipe_1 = require("./avatargroup.recipe");
|
|
7
|
+
Object.defineProperty(exports, "avatargroupRecipe", { enumerable: true, get: function () { return avatargroup_recipe_1.avatargroupRecipe; } });
|