@slotted/react 0.1.0-beta.10 → 0.1.0-beta.12
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/dist/action-bar-z2DPc1Wy.js +285 -0
- package/dist/action-bar.js +1 -1
- package/dist/action-sheet-BnedGewu.js +360 -0
- package/dist/action-sheet.js +1 -1
- package/dist/{alert-BTcqbG8w.js → alert-BTAXJ69M.js} +5 -5
- package/dist/alert.js +1 -1
- package/dist/{app-shell-BlkqQrOx.js → app-shell-Cb_kDBeV.js} +232 -173
- package/dist/app-shell.js +1 -1
- package/dist/{attachment-zlOPJvIm.js → attachment-D1O4qS8H.js} +28 -28
- package/dist/attachment.js +1 -1
- package/dist/{breadcrumb-DCGynpkb.js → breadcrumb-CnFjxxI2.js} +10 -10
- package/dist/breadcrumb.js +1 -1
- package/dist/{button-BCVjdzkn.js → button-D31perSu.js} +2 -2
- package/dist/button.js +2 -2
- package/dist/{calendar-qGUJ-kAy.js → calendar-DZyC1gAT.js} +8 -8
- package/dist/calendar.js +1 -1
- package/dist/{carousel-CjRTu8m7.js → carousel-Dso3gcYd.js} +14 -14
- package/dist/carousel.js +1 -1
- package/dist/cascader-BbajBwsX.js +1157 -0
- package/dist/cascader.js +1 -1
- package/dist/{chart-CPFq3jIE.js → chart-Bb6ctahn.js} +9 -9
- package/dist/chart.js +1 -1
- package/dist/{checkbox-CMY2KIih.js → checkbox-C_8GVtjD.js} +3 -3
- package/dist/{checkbox-group-DzMtLF7f.js → checkbox-group-DXCcusol.js} +2 -2
- package/dist/checkbox-group.js +1 -1
- package/dist/checkbox.js +1 -1
- package/dist/{code-block-Bh_2Eg3M.js → code-block-C4mtsROE.js} +8 -8
- package/dist/code-block.js +1 -1
- package/dist/{color-picker-DlepH5co.js → color-picker-JZPnPb7s.js} +49 -49
- package/dist/color-picker.js +1 -1
- package/dist/{column-manager-CV9tCnKa.js → column-manager-BDUj-WIs.js} +31 -31
- package/dist/column-manager.js +1 -1
- package/dist/combobox-Dn69QwGX.js +904 -0
- package/dist/combobox.js +1 -1
- package/dist/command-palette-Dh1HKz_F.js +744 -0
- package/dist/command-palette.js +1 -1
- package/dist/{context-menu-Dbc0KkFp.js → context-menu-uJjEmAN3.js} +1 -1
- package/dist/context-menu.js +1 -1
- package/dist/{currency-field--wIfgVAx.js → currency-field-lHcrNJ7X.js} +13 -13
- package/dist/currency-field.js +1 -1
- package/dist/{dashboard-grid-D_LbWfdZ.js → dashboard-grid-z-SOm9H0.js} +65 -65
- package/dist/dashboard-grid.js +1 -1
- package/dist/{data-grid-XH5fGoGj.js → data-grid-Kj1b9RD-.js} +1316 -1272
- package/dist/data-grid.js +1 -1
- package/dist/data-list-BgdkA3bD.js +587 -0
- package/dist/data-list.js +1 -1
- package/dist/{date-field-BrNyJBiJ.js → date-field-B2lQzE3p.js} +5 -5
- package/dist/date-field.js +1 -1
- package/dist/{date-picker-Nl55so0C.js → date-picker-DpTRb-Y1.js} +16 -16
- package/dist/date-picker.js +1 -1
- package/dist/{date-range-picker-DLkvfUJD.js → date-range-picker-CBUPJep5.js} +17 -17
- package/dist/date-range-picker.js +1 -1
- package/dist/{datetime-field-CZRhRDPb.js → datetime-field-BZ44uJ_B.js} +7 -7
- package/dist/datetime-field.js +1 -1
- package/dist/{datetime-picker-_GHra2WL.js → datetime-picker-BK_bV3Yr.js} +21 -21
- package/dist/datetime-picker.js +1 -1
- package/dist/{datetime-range-picker-Dy1A0Wqy.js → datetime-range-picker-ChdbRgzQ.js} +21 -21
- package/dist/datetime-range-picker.js +1 -1
- package/dist/{description-list-Cc4JYZ-3.js → description-list-CYlfHDwx.js} +11 -11
- package/dist/description-list.js +1 -1
- package/dist/{detail-panel-BI_wHSoz.js → detail-panel-DimjnPI8.js} +91 -91
- package/dist/detail-panel.js +1 -1
- package/dist/{dialog-B6MP7GYI.js → dialog-BB5MdJex.js} +108 -108
- package/dist/dialog.js +1 -1
- package/dist/docs/action-bar.json +4 -4
- package/dist/docs/action-bar.md +3 -3
- package/dist/docs/calendar.md +2 -2
- package/dist/docs/command-palette.json +1 -0
- package/dist/docs/command-palette.md +1 -1
- package/dist/docs/data-grid.examples.md +8 -2
- package/dist/docs/data-grid.json +12 -2
- package/dist/docs/data-grid.md +3 -1
- package/dist/docs/detail-panel.json +4 -2
- package/dist/docs/detail-panel.md +15 -5
- package/dist/docs/dialog.json +1 -0
- package/dist/docs/dialog.md +1 -1
- package/dist/docs/drawer.json +6 -4
- package/dist/docs/drawer.md +3 -3
- package/dist/docs/event-calendar.md +2 -2
- package/dist/docs/guidelines/index.md +4 -3
- package/dist/docs/guidelines/layout-alignment.md +17 -7
- package/dist/docs/guidelines/list-pages.md +3 -3
- package/dist/docs/page-header.json +18 -2
- package/dist/docs/page-header.md +5 -3
- package/dist/docs/page.json +1 -0
- package/dist/docs/page.md +1 -1
- package/dist/docs/rating.md +1 -1
- package/dist/docs/section.json +1 -1
- package/dist/docs/section.md +1 -1
- package/dist/docs/skills/compose-screen/SKILL.md +12 -4
- package/dist/docs/skills/review-screen/SKILL.md +20 -18
- package/dist/docs/skills/theme-app/SKILL.md +12 -1
- package/dist/docs/toast.json +1 -0
- package/dist/docs/toast.md +1 -1
- package/dist/docs/tokens.md +1 -1
- package/dist/docs/toolbar.json +1 -1
- package/dist/docs/toolbar.md +1 -1
- package/dist/docs/typography.md +1 -1
- package/dist/{drawer-CkpFlKYa.js → drawer-fyPyxnYQ.js} +216 -206
- package/dist/drawer.js +1 -1
- package/dist/entity-picker-ClyhBTyK.js +1283 -0
- package/dist/entity-picker.js +1 -1
- package/dist/{event-calendar-BDjI5T44.js → event-calendar-COgC24UG.js} +23 -23
- package/dist/event-calendar.js +1 -1
- package/dist/{field-group-CCM2vPKL.js → field-group-Bj-EbPIU.js} +2 -2
- package/dist/field-group.js +1 -1
- package/dist/{field-CzSGs7wo.js → field-tnEZiRLg.js} +19 -19
- package/dist/field.js +1 -1
- package/dist/filter-bar-BRuCz79-.js +1342 -0
- package/dist/filter-bar.js +1 -1
- package/dist/{form-CDq04WDY.js → form-DEcJ7tHf.js} +1 -1
- package/dist/form.js +1 -1
- package/dist/{fullscreen-6GW4naDP.js → fullscreen-BwweNj3-.js} +13 -13
- package/dist/fullscreen.js +1 -1
- package/dist/{hover-card-aadyPXzF.js → hover-card-BWcU37Yp.js} +1 -1
- package/dist/hover-card.js +1 -1
- package/dist/{i18n-DpW8lqJ1.js → i18n-D7xXDd8-.js} +11 -4
- package/dist/i18n.js +1 -1
- package/dist/{icon-button-CRB218_z.js → icon-button-DbSZKGT4.js} +73 -71
- package/dist/{import-export-center-DUrNwRKP.js → import-export-center-CYf0Qxl_.js} +291 -289
- package/dist/import-export-center.js +1 -1
- package/dist/index.js +100 -100
- package/dist/{kbd-Z4YmSPRy.js → kbd-dNz8QHfL.js} +1 -1
- package/dist/kbd.js +1 -1
- package/dist/{link-BsSlZ1ts.js → link-DLPyg54C.js} +5 -5
- package/dist/link.js +1 -1
- package/dist/{listbox-VFcfZT70.js → listbox-BSqx_ARf.js} +1 -1
- package/dist/listbox.js +1 -1
- package/dist/{loading-overlay-BZPBDK4w.js → loading-overlay-BLIrcaoj.js} +9 -9
- package/dist/loading-overlay.js +1 -1
- package/dist/{markdown-BmCU_sOv.js → markdown-DccRb1xf.js} +17 -17
- package/dist/markdown.js +1 -1
- package/dist/{menu-parts-DS9JEUCt.js → menu-parts-CNNHRduK.js} +42 -42
- package/dist/menu.js +1 -1
- package/dist/{menubar-BV43BKep.js → menubar-Bdr6zigi.js} +1 -1
- package/dist/menubar.js +1 -1
- package/dist/message-BkTiWsUp.js +436 -0
- package/dist/message-scroller-akQEtQLn.js +218 -0
- package/dist/message-scroller.js +1 -1
- package/dist/message.js +1 -1
- package/dist/{multi-select-YaxhhH9y.js → multi-select-BvlJIEtz.js} +445 -443
- package/dist/multi-select.js +1 -1
- package/dist/{navigation-menu-parts-B64gKl8B.js → navigation-menu-parts-CEW4fgCo.js} +12 -12
- package/dist/navigation-menu.js +1 -1
- package/dist/{notification-center-Ci-OLWTO.js → notification-center-BQO0Ey3h.js} +40 -40
- package/dist/notification-center.js +1 -1
- package/dist/{number-field-BYQmPyM-.js → number-field-D1MqT8_A.js} +13 -13
- package/dist/number-field.js +1 -1
- package/dist/{otp-input-BKO0WPZc.js → otp-input-Cub9H9Di.js} +1 -1
- package/dist/otp-input.js +1 -1
- package/dist/{page-CfjGviUA.js → page-CwYmBoZQ.js} +1 -1
- package/dist/{page-header-w_PFLnLG.js → page-header-CMxCQqu_.js} +117 -114
- package/dist/page-header.js +1 -1
- package/dist/page.js +1 -1
- package/dist/{pagination-Cm9665gb.js → pagination-IEuos7H1.js} +12 -12
- package/dist/pagination.js +1 -1
- package/dist/{popover-D1krYeP-.js → popover-C7NpEzq6.js} +22 -22
- package/dist/popover.js +1 -1
- package/dist/prompt-composer-Cu8bj1Vb.js +276 -0
- package/dist/prompt-composer.js +1 -1
- package/dist/{prose-Bl5OjXTb.js → prose-CQN4Bqqh.js} +1 -1
- package/dist/prose.js +1 -1
- package/dist/{radio-group-D9VTBLUB.js → radio-group-BHlDgCLk.js} +2 -2
- package/dist/radio-group.js +1 -1
- package/dist/{rating-BRqsV5OF.js → rating-Cr0lXaAV.js} +15 -15
- package/dist/rating.js +1 -1
- package/dist/{saved-views-C_76obIv.js → saved-views-CyLSn8a2.js} +151 -151
- package/dist/saved-views.js +1 -1
- package/dist/{scroll-area-vrm2bbtZ.js → scroll-area-Fr0PmnRS.js} +1 -1
- package/dist/scroll-area.js +1 -1
- package/dist/{segmented-control-5DTOKO3g.js → segmented-control-uPnQYklX.js} +2 -2
- package/dist/segmented-control.js +1 -1
- package/dist/select-C0JYHwBy.js +1020 -0
- package/dist/select.js +1 -1
- package/dist/{side-navigation-MNMSkj9b.js → side-navigation-D8lRpHwj.js} +64 -64
- package/dist/side-navigation.js +1 -1
- package/dist/{skeleton-DyOwgYmF.js → skeleton-DeEOmm1y.js} +1 -1
- package/dist/skeleton.js +1 -1
- package/dist/{slider-OMe1DAC-.js → slider-BSI1xvjw.js} +2 -2
- package/dist/slider.js +1 -1
- package/dist/{sparkline-ChkaLVdY.js → sparkline-CYU4_lCD.js} +1 -1
- package/dist/sparkline.js +1 -1
- package/dist/spinner-ring-DyfaYloA.js +19 -0
- package/dist/{split-button-DbmRwfMC.js → split-button-CkbylOMN.js} +2 -2
- package/dist/split-button.js +1 -1
- package/dist/{stat-card-BSnsTmsq.js → stat-card-CAh4SdeY.js} +16 -16
- package/dist/stat-card.js +1 -1
- package/dist/{status-indicator-CyKhBdvN.js → status-indicator-BVMnpcm8.js} +4 -4
- package/dist/status-indicator.js +1 -1
- package/dist/{stepper-Cw1Auv3n.js → stepper-BLfvMz04.js} +16 -16
- package/dist/stepper.js +1 -1
- package/dist/styles/action-bar.css +1 -1
- package/dist/styles/action-sheet.css +2 -2
- package/dist/styles/button.css +2 -2
- package/dist/styles/cascader.css +2 -2
- package/dist/styles/chart.css +1 -1
- package/dist/styles/column-manager.css +3 -3
- package/dist/styles/command-palette.css +3 -3
- package/dist/styles/dashboard-grid.css +2 -2
- package/dist/styles/data-grid.css +3 -3
- package/dist/styles/data-list.css +2 -2
- package/dist/styles/detail-panel.css +4 -4
- package/dist/styles/dialog.css +1 -1
- package/dist/styles/drawer.css +1 -1
- package/dist/styles/entity-picker.css +1 -1
- package/dist/styles/event-calendar.css +1 -1
- package/dist/styles/filter-bar.css +3 -3
- package/dist/styles/import-export-center.css +4 -4
- package/dist/styles/index.css +12 -12
- package/dist/styles/markdown.css +2 -2
- package/dist/styles/multi-select.css +1 -1
- package/dist/styles/notification-center.css +3 -3
- package/dist/styles/page-header.css +2 -2
- package/dist/styles/page.css +1 -1
- package/dist/styles/prompt-composer.css +1 -1
- package/dist/styles/saved-views.css +2 -2
- package/dist/styles/split-button.css +2 -2
- package/dist/styles/table.css +2 -2
- package/dist/styles/tabs.css +1 -1
- package/dist/styles/timeline.css +1 -1
- package/dist/styles/toast.css +1 -1
- package/dist/styles/tour.css +2 -2
- package/dist/styles/transfer.css +2 -2
- package/dist/styles/upload.css +1 -1
- package/dist/styles/wizard.css +2 -2
- package/dist/styles.css +1 -1
- package/dist/{switch-CQ1rpuKa.js → switch-BHyKHqeI.js} +5 -5
- package/dist/switch.js +1 -1
- package/dist/{table-DpGTPtnb.js → table-C8zOHDcY.js} +30 -30
- package/dist/{table-of-contents-BFVERMZy.js → table-of-contents-BAIuPCdy.js} +8 -8
- package/dist/table-of-contents.js +1 -1
- package/dist/table.js +1 -1
- package/dist/{tag-aX7uyAN0.js → tag-XYGEPUHR.js} +14 -14
- package/dist/tag.js +1 -1
- package/dist/{tags-input-BgpS22sf.js → tags-input-ClYSd-No.js} +40 -40
- package/dist/tags-input.js +1 -1
- package/dist/text-field-Cguj75tn.js +205 -0
- package/dist/text-field.js +1 -1
- package/dist/{textarea-DNCjsQYd.js → textarea-BKsh_jAo.js} +1 -1
- package/dist/textarea.js +1 -1
- package/dist/{time-field-Cm6iBjwH.js → time-field-BIE4WMpS.js} +7 -7
- package/dist/time-field.js +1 -1
- package/dist/{time-picker-Ce18FSO2.js → time-picker-CNfafRDF.js} +18 -18
- package/dist/time-picker.js +1 -1
- package/dist/{time-range-picker-kDnw4PQ3.js → time-range-picker-D7gM_Wno.js} +20 -20
- package/dist/time-range-picker.js +1 -1
- package/dist/timeline-BLadNUkS.js +449 -0
- package/dist/timeline.js +1 -1
- package/dist/{toast-58ex8PDK.js → toast-CjbiXiza.js} +16 -16
- package/dist/toast.js +1 -1
- package/dist/{toggle-group-YxVJlCnI.js → toggle-group-BZmghKac.js} +1 -1
- package/dist/toggle-group.js +1 -1
- package/dist/toolbar-BI4ZepBs.js +243 -0
- package/dist/toolbar.js +1 -1
- package/dist/{top-navigation-DorkYBnR.js → top-navigation-BTZpx5VA.js} +13 -13
- package/dist/top-navigation.js +1 -1
- package/dist/{tour-CwK_m_Jp.js → tour-_CQ1kYov.js} +23 -23
- package/dist/tour.js +1 -1
- package/dist/{transfer-DxGDWIEt.js → transfer-BVhBdIGp.js} +59 -59
- package/dist/transfer.js +1 -1
- package/dist/tree-DfI9UWLA.js +794 -0
- package/dist/tree.js +1 -1
- package/dist/types/action-bar/action-bar-overflow.d.ts.map +1 -1
- package/dist/types/action-bar/action-bar.types.d.ts +2 -2
- package/dist/types/action-sheet/action-sheet-parts.d.ts.map +1 -1
- package/dist/types/app-shell/app-shell-parts.d.ts.map +1 -1
- package/dist/types/app-shell/app-shell.d.ts.map +1 -1
- package/dist/types/app-shell/app-shell.types.d.ts +21 -14
- package/dist/types/app-shell/app-shell.types.d.ts.map +1 -1
- package/dist/types/app-shell/index.d.ts +1 -1
- package/dist/types/app-shell/index.d.ts.map +1 -1
- package/dist/types/button/button-indicator.d.ts.map +1 -1
- package/dist/types/button/spinner-ring.d.ts +8 -0
- package/dist/types/button/spinner-ring.d.ts.map +1 -0
- package/dist/types/cascader/cascader-surface.d.ts.map +1 -1
- package/dist/types/cascader/cascader.d.ts.map +1 -1
- package/dist/types/combobox/combobox-parts.d.ts.map +1 -1
- package/dist/types/command-palette/command-palette.d.ts.map +1 -1
- package/dist/types/data-grid/data-grid-body.d.ts +7 -2
- package/dist/types/data-grid/data-grid-body.d.ts.map +1 -1
- package/dist/types/data-grid/data-grid-header.d.ts.map +1 -1
- package/dist/types/data-grid/data-grid.d.ts +1 -1
- package/dist/types/data-grid/data-grid.d.ts.map +1 -1
- package/dist/types/detail-panel/detail-panel-parts.d.ts +2 -1
- package/dist/types/detail-panel/detail-panel-parts.d.ts.map +1 -1
- package/dist/types/drawer/drawer-parts.d.ts.map +1 -1
- package/dist/types/entity-picker/entity-picker-control.d.ts.map +1 -1
- package/dist/types/filter-bar/filter-bar.d.ts.map +1 -1
- package/dist/types/i18n/slotted-provider.d.ts +6 -0
- package/dist/types/i18n/slotted-provider.d.ts.map +1 -1
- package/dist/types/import-export-center/import-export-center.d.ts.map +1 -1
- package/dist/types/message/message-parts.d.ts.map +1 -1
- package/dist/types/message-scroller/message-scroller.d.ts.map +1 -1
- package/dist/types/multi-select/multi-select-parts.d.ts.map +1 -1
- package/dist/types/page-header/page-header-defaults.d.ts +1 -1
- package/dist/types/page-header/page-header-defaults.d.ts.map +1 -1
- package/dist/types/page-header/page-header.d.ts +1 -1
- package/dist/types/page-header/page-header.d.ts.map +1 -1
- package/dist/types/page-header/page-header.types.d.ts +9 -0
- package/dist/types/page-header/page-header.types.d.ts.map +1 -1
- package/dist/types/prompt-composer/prompt-composer.d.ts.map +1 -1
- package/dist/types/select/select-parts.d.ts.map +1 -1
- package/dist/types/text-field/text-field.d.ts.map +1 -1
- package/dist/types/timeline/timeline-parts.d.ts.map +1 -1
- package/dist/types/timeline/timeline.d.ts.map +1 -1
- package/dist/types/toolbar/toolbar-overflow.d.ts.map +1 -1
- package/dist/types/toolbar/toolbar.types.d.ts +2 -2
- package/dist/types/tree/tree-parts.d.ts.map +1 -1
- package/dist/{upload-CEDsfMWz.js → upload-N2-nyO8x.js} +65 -65
- package/dist/upload.js +1 -1
- package/dist/{wizard-B3p7zCSj.js → wizard-CK1x2fs3.js} +16 -16
- package/dist/wizard.js +1 -1
- package/package.json +6 -6
- package/dist/action-bar-CJgBierN.js +0 -283
- package/dist/action-sheet-tRrjm7WQ.js +0 -358
- package/dist/cascader-DqlC1z5b.js +0 -1154
- package/dist/combobox-YWFkxaQ3.js +0 -902
- package/dist/command-palette-DXNq-zKN.js +0 -741
- package/dist/data-list-DZCN_uW1.js +0 -587
- package/dist/entity-picker-CFwLGQeU.js +0 -1281
- package/dist/filter-bar-G50WdRac.js +0 -1340
- package/dist/message-Dtck9RJy.js +0 -434
- package/dist/message-scroller-niUJ8RoL.js +0 -216
- package/dist/prompt-composer-sh_TXKYZ.js +0 -273
- package/dist/select-BFx5EgAa.js +0 -1018
- package/dist/text-field-DL_uhNXV.js +0 -203
- package/dist/timeline-pEL30Jp8.js +0 -446
- package/dist/toolbar-BtIyVbs4.js +0 -241
- package/dist/tree-DbLRyItM.js +0 -792
|
@@ -0,0 +1,276 @@
|
|
|
1
|
+
import { r as e } from "./i18n-D7xXDd8-.js";
|
|
2
|
+
import { n as t, t as n } from "./icon-DjqSEQ-o.js";
|
|
3
|
+
/* empty css */
|
|
4
|
+
import { t as r } from "./spinner-ring-DyfaYloA.js";
|
|
5
|
+
import { b as i } from "./field-tnEZiRLg.js";
|
|
6
|
+
import { keyedProps as a, withSelectorKey as o } from "@slotted/core/selector-key";
|
|
7
|
+
import { createControllable as s } from "@slotted/core/state";
|
|
8
|
+
import { createContext as c, useContext as l, useEffect as u, useRef as d, useState as f } from "react";
|
|
9
|
+
import { Fragment as p, jsx as m, jsxs as h } from "react/jsx-runtime";
|
|
10
|
+
import { promptComposerMessages as g } from "@slotted/core/i18n";
|
|
11
|
+
import { selectFiles as _ } from "@slotted/core/upload";
|
|
12
|
+
import { getLiveAnnouncer as v } from "@slotted/core/live-announcer";
|
|
13
|
+
//#region src/prompt-composer/prompt-composer-defaults.tsx
|
|
14
|
+
var y = c({
|
|
15
|
+
emphasis: "none",
|
|
16
|
+
size: "md",
|
|
17
|
+
submitOn: "enter",
|
|
18
|
+
variant: "raised"
|
|
19
|
+
});
|
|
20
|
+
function b() {
|
|
21
|
+
return l(y);
|
|
22
|
+
}
|
|
23
|
+
function x({ children: e, ...t }) {
|
|
24
|
+
let n = { ...b() };
|
|
25
|
+
for (let [e, r] of Object.entries(t)) r !== void 0 && (n[e] = r);
|
|
26
|
+
return /* @__PURE__ */ m(y.Provider, {
|
|
27
|
+
value: n,
|
|
28
|
+
children: e
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
//#endregion
|
|
32
|
+
//#region src/prompt-composer/prompt-composer.tsx
|
|
33
|
+
var S = c(null);
|
|
34
|
+
function C(e) {
|
|
35
|
+
let t = l(S);
|
|
36
|
+
if (t === null) throw Error(`PromptComposer${e} must sit inside a PromptComposer`);
|
|
37
|
+
return t;
|
|
38
|
+
}
|
|
39
|
+
function w(e) {
|
|
40
|
+
return e.detail === 0 ? "keyboard" : "pointer";
|
|
41
|
+
}
|
|
42
|
+
function T(e) {
|
|
43
|
+
return Array.from(e.dataTransfer?.types ?? []).includes("Files");
|
|
44
|
+
}
|
|
45
|
+
function E({ accept: t, canSubmit: n, children: r, className: o, defaultValue: c, disabled: l, invalid: y, maxFiles: x, maxSize: C, messages: w, multiple: E = !0, onAttach: D, onDragLeave: O, onDragOver: k, onDrop: A, onMouseDown: j, onStop: M, onSubmit: ee, onValueChange: te, onValueSubmit: ne, readOnly: re, render: N, size: ie, status: P = "ready", style: ae, submitOn: oe, value: F, emphasis: se, variant: ce, ...le }) {
|
|
46
|
+
let I = i(), L = b(), R = e(g, w), z = d(null), [ue, de] = f(c ?? ""), [B, V] = f(!1), H = F ?? ue, U = l ?? I?.disabled, W = re ?? I?.readOnly, G = y ?? I?.invalid, fe = ie ?? I?.size ?? L.size, K = P === "submitted" || P === "streaming", q = U !== !0 && W !== !0 && !K && (n ?? H.trim() !== ""), J = I?.registerControl;
|
|
47
|
+
u(() => J?.(), [J]);
|
|
48
|
+
let Y = () => v(z.current?.ownerDocument), X = d(P);
|
|
49
|
+
u(() => {
|
|
50
|
+
P === "submitted" && X.current !== "submitted" && Y().announce(R("sending")), X.current = P;
|
|
51
|
+
});
|
|
52
|
+
let Z = (e, t, n) => {
|
|
53
|
+
s({
|
|
54
|
+
controlled: F,
|
|
55
|
+
initial: H,
|
|
56
|
+
onRequest: (e) => te?.(e.value, e)
|
|
57
|
+
}).request(e, t, n) && de(e);
|
|
58
|
+
}, Q = (e, t) => {
|
|
59
|
+
if (!q) return;
|
|
60
|
+
let n = !1, r = H;
|
|
61
|
+
s({
|
|
62
|
+
controlled: void 0,
|
|
63
|
+
initial: "",
|
|
64
|
+
onRequest: (e) => {
|
|
65
|
+
ne?.(e.value, e), n = e.cancelled;
|
|
66
|
+
},
|
|
67
|
+
equals: () => !1
|
|
68
|
+
}).request(r, e, t), !n && (Z("", "submit", t), z.current?.focus());
|
|
69
|
+
}, pe = (e, t) => {
|
|
70
|
+
M?.({
|
|
71
|
+
reason: e,
|
|
72
|
+
source: t
|
|
73
|
+
}), Y().announce(R("stopped")), z.current?.focus();
|
|
74
|
+
}, me = (e, n, r) => {
|
|
75
|
+
if (e.length === 0 || U === !0 || W === !0) return;
|
|
76
|
+
let i = _(e, [], {
|
|
77
|
+
accept: t,
|
|
78
|
+
maxFiles: x,
|
|
79
|
+
maxSize: C,
|
|
80
|
+
multiple: E
|
|
81
|
+
}), a = i.files.filter((e) => e.status !== "rejected" && e.file !== void 0).map((e) => e.file);
|
|
82
|
+
D?.(a, {
|
|
83
|
+
reason: n,
|
|
84
|
+
rejected: i.rejected,
|
|
85
|
+
source: r
|
|
86
|
+
});
|
|
87
|
+
}, he = {
|
|
88
|
+
accept: t,
|
|
89
|
+
attach: me,
|
|
90
|
+
canSubmit: q,
|
|
91
|
+
describedBy: I?.describedBy,
|
|
92
|
+
disabled: U,
|
|
93
|
+
id: I?.ids.control,
|
|
94
|
+
inputRef: z,
|
|
95
|
+
invalid: G,
|
|
96
|
+
multiple: E,
|
|
97
|
+
readOnly: W,
|
|
98
|
+
required: I?.required,
|
|
99
|
+
setValue: (e, t) => Z(e, "keyboard", t),
|
|
100
|
+
status: P,
|
|
101
|
+
stop: pe,
|
|
102
|
+
submit: Q,
|
|
103
|
+
submitOn: oe ?? L.submitOn,
|
|
104
|
+
t: R,
|
|
105
|
+
value: H
|
|
106
|
+
}, ge = (se ?? L.emphasis) === "ring", $ = a({
|
|
107
|
+
...le,
|
|
108
|
+
children: ge ? /* @__PURE__ */ h(p, { children: [
|
|
109
|
+
r,
|
|
110
|
+
/* @__PURE__ */ m("span", {
|
|
111
|
+
"aria-hidden": "true",
|
|
112
|
+
"data-part": "glow",
|
|
113
|
+
"data-part-glow": ""
|
|
114
|
+
}),
|
|
115
|
+
/* @__PURE__ */ m("span", {
|
|
116
|
+
"aria-hidden": "true",
|
|
117
|
+
"data-part": "ring",
|
|
118
|
+
"data-part-ring": ""
|
|
119
|
+
})
|
|
120
|
+
] }) : r,
|
|
121
|
+
className: o,
|
|
122
|
+
style: ae,
|
|
123
|
+
...U === !0 ? { "data-disabled": "" } : {},
|
|
124
|
+
...B ? { "data-drop-target": "" } : {},
|
|
125
|
+
...ge ? { "data-emphasis": "ring" } : {},
|
|
126
|
+
...G === !0 ? { "data-invalid": "" } : {},
|
|
127
|
+
...K ? { "data-loading": "" } : {},
|
|
128
|
+
...W === !0 ? { "data-readonly": "" } : {},
|
|
129
|
+
"data-part": "root",
|
|
130
|
+
"data-size": fe,
|
|
131
|
+
"data-status": P,
|
|
132
|
+
"data-ui": "prompt-composer",
|
|
133
|
+
"data-variant": ce ?? L.variant,
|
|
134
|
+
onMouseDown: (e) => {
|
|
135
|
+
j?.(e);
|
|
136
|
+
let t = e.target.getAttribute("data-part");
|
|
137
|
+
e.defaultPrevented || t !== "root" && t !== "header" && t !== "footer" || (e.preventDefault(), z.current?.focus());
|
|
138
|
+
},
|
|
139
|
+
onSubmit: (e) => {
|
|
140
|
+
ee?.(e), !e.defaultPrevented && (e.preventDefault(), Q("keyboard", e.nativeEvent));
|
|
141
|
+
},
|
|
142
|
+
onDragOver: (e) => {
|
|
143
|
+
k?.(e), T(e) && U !== !0 && W !== !0 && (e.preventDefault(), B || V(!0));
|
|
144
|
+
},
|
|
145
|
+
onDragLeave: (e) => {
|
|
146
|
+
O?.(e);
|
|
147
|
+
let t = e.relatedTarget;
|
|
148
|
+
(t === null || !e.currentTarget.contains(t)) && V(!1);
|
|
149
|
+
},
|
|
150
|
+
onDrop: (e) => {
|
|
151
|
+
A?.(e), V(!1), T(e) && (e.preventDefault(), me(Array.from(e.dataTransfer.files), "drop", e.nativeEvent));
|
|
152
|
+
}
|
|
153
|
+
});
|
|
154
|
+
return /* @__PURE__ */ m(S.Provider, {
|
|
155
|
+
value: he,
|
|
156
|
+
children: N === void 0 ? /* @__PURE__ */ m("form", { ...$ }) : N($)
|
|
157
|
+
});
|
|
158
|
+
}
|
|
159
|
+
function D({ render: e, ...t }) {
|
|
160
|
+
let n = a({
|
|
161
|
+
...t,
|
|
162
|
+
"data-part": "header"
|
|
163
|
+
});
|
|
164
|
+
return e === void 0 ? /* @__PURE__ */ m("div", { ...n }) : e(n);
|
|
165
|
+
}
|
|
166
|
+
function O({ render: e, ...t }) {
|
|
167
|
+
let n = a({
|
|
168
|
+
...t,
|
|
169
|
+
"data-part": "footer"
|
|
170
|
+
});
|
|
171
|
+
return e === void 0 ? /* @__PURE__ */ m("div", { ...n }) : e(n);
|
|
172
|
+
}
|
|
173
|
+
function k({ "aria-describedby": e, "aria-invalid": t, "aria-required": n, id: r, maxLength: a, maxRows: s, onChange: c, onKeyDown: l, onPaste: d, rows: f, showCount: p = !1, style: h, ...g }) {
|
|
174
|
+
let _ = C("Input"), v = i()?.setCount;
|
|
175
|
+
return u(() => {
|
|
176
|
+
if (p && v !== void 0) return v({
|
|
177
|
+
length: _.value.length,
|
|
178
|
+
max: a ?? void 0
|
|
179
|
+
}), () => v(void 0);
|
|
180
|
+
}, [
|
|
181
|
+
_.value,
|
|
182
|
+
a,
|
|
183
|
+
v,
|
|
184
|
+
p
|
|
185
|
+
]), /* @__PURE__ */ m("textarea", {
|
|
186
|
+
...o(g, "part", "input"),
|
|
187
|
+
"aria-describedby": [e, _.describedBy].filter(Boolean).join(" ") || void 0,
|
|
188
|
+
"aria-invalid": t ?? (_.invalid === !0 || void 0),
|
|
189
|
+
"aria-required": n ?? (_.required === !0 || void 0),
|
|
190
|
+
dir: g.dir ?? "auto",
|
|
191
|
+
disabled: _.disabled,
|
|
192
|
+
id: r ?? _.id,
|
|
193
|
+
maxLength: a,
|
|
194
|
+
onChange: (e) => {
|
|
195
|
+
c?.(e), _.setValue(e.currentTarget.value, e);
|
|
196
|
+
},
|
|
197
|
+
onKeyDown: (e) => {
|
|
198
|
+
l?.(e), !(e.defaultPrevented || e.key !== "Enter" || e.shiftKey) && (e.nativeEvent.isComposing || e.keyCode === 229 || (e.metaKey || e.ctrlKey || _.submitOn === "enter") && (e.preventDefault(), _.submit("keyboard", e.nativeEvent)));
|
|
199
|
+
},
|
|
200
|
+
onPaste: (e) => {
|
|
201
|
+
d?.(e);
|
|
202
|
+
let t = Array.from(e.clipboardData?.files ?? []);
|
|
203
|
+
t.length !== 0 && (e.clipboardData.getData("text/plain") === "" && e.preventDefault(), _.attach(t, "paste", e.nativeEvent));
|
|
204
|
+
},
|
|
205
|
+
readOnly: _.readOnly,
|
|
206
|
+
ref: (e) => {
|
|
207
|
+
_.inputRef.current = e;
|
|
208
|
+
let { ref: t } = g;
|
|
209
|
+
typeof t == "function" ? t(e) : t != null && (t.current = e);
|
|
210
|
+
},
|
|
211
|
+
rows: f ?? 1,
|
|
212
|
+
style: {
|
|
213
|
+
...f === void 0 ? {} : { "--slotted-prompt-composer-rows": f },
|
|
214
|
+
...s === void 0 ? {} : { "--slotted-prompt-composer-max-rows": s },
|
|
215
|
+
...h
|
|
216
|
+
},
|
|
217
|
+
value: _.value
|
|
218
|
+
});
|
|
219
|
+
}
|
|
220
|
+
function A({ render: e, type: t = "button", ...n }) {
|
|
221
|
+
let r = a({
|
|
222
|
+
...n,
|
|
223
|
+
"data-part": "action",
|
|
224
|
+
type: t
|
|
225
|
+
});
|
|
226
|
+
return e === void 0 ? /* @__PURE__ */ m("button", { ...r }) : e(r);
|
|
227
|
+
}
|
|
228
|
+
function j({ "aria-label": e, children: r, disabled: i, onClick: a, ...s }) {
|
|
229
|
+
let c = C("Attach"), l = d(null), u = i ?? (c.disabled === !0 || c.readOnly === !0);
|
|
230
|
+
return /* @__PURE__ */ h(p, { children: [/* @__PURE__ */ m("button", {
|
|
231
|
+
...o(s, "part", "attach"),
|
|
232
|
+
"aria-label": e ?? c.t("attach"),
|
|
233
|
+
disabled: u,
|
|
234
|
+
onClick: (e) => {
|
|
235
|
+
a?.(e), e.defaultPrevented || l.current?.click();
|
|
236
|
+
},
|
|
237
|
+
type: "button",
|
|
238
|
+
children: r ?? /* @__PURE__ */ m(n, { children: /* @__PURE__ */ m(t, { name: "paperclip" }) })
|
|
239
|
+
}), /* @__PURE__ */ m("input", {
|
|
240
|
+
accept: c.accept,
|
|
241
|
+
hidden: !0,
|
|
242
|
+
multiple: c.multiple,
|
|
243
|
+
onChange: (e) => {
|
|
244
|
+
c.attach(Array.from(e.currentTarget.files ?? []), "pointer", e.nativeEvent), e.currentTarget.value = "";
|
|
245
|
+
},
|
|
246
|
+
ref: l,
|
|
247
|
+
tabIndex: -1,
|
|
248
|
+
type: "file"
|
|
249
|
+
})] });
|
|
250
|
+
}
|
|
251
|
+
function M({ "aria-label": e, children: i, disabled: a, onClick: s, ...c }) {
|
|
252
|
+
let l = C("Submit"), { status: u, t: d } = l, f = u === "streaming", g = u === "submitted", _ = d(f ? "stop" : g ? "sending" : u === "error" ? "retry" : "send"), v = u === "error" ? "rotate-ccw" : "arrow-up";
|
|
253
|
+
return /* @__PURE__ */ m("button", {
|
|
254
|
+
...o(c, "part", "submit"),
|
|
255
|
+
"aria-disabled": g ? !0 : void 0,
|
|
256
|
+
"aria-label": i === void 0 ? e ?? _ : e,
|
|
257
|
+
disabled: f ? !1 : a ?? (!g && !l.canSubmit),
|
|
258
|
+
onClick: (e) => {
|
|
259
|
+
s?.(e), !e.defaultPrevented && (e.preventDefault(), f ? l.stop(w(e), e.nativeEvent) : g || l.submit(w(e), e.nativeEvent));
|
|
260
|
+
},
|
|
261
|
+
type: f || g ? "button" : "submit",
|
|
262
|
+
children: i ?? (g ? /* @__PURE__ */ m("span", {
|
|
263
|
+
"aria-hidden": "true",
|
|
264
|
+
"data-ui": "spinner",
|
|
265
|
+
"data-ui-spinner": "",
|
|
266
|
+
children: r
|
|
267
|
+
}, "busy") : f ? /* @__PURE__ */ h(p, { children: [/* @__PURE__ */ m("span", {
|
|
268
|
+
"aria-hidden": "true",
|
|
269
|
+
"data-ui": "spinner",
|
|
270
|
+
"data-ui-spinner": "",
|
|
271
|
+
children: r
|
|
272
|
+
}, "ring"), /* @__PURE__ */ m(n, { children: /* @__PURE__ */ m(t, { name: "stop" }) }, "stop")] }) : /* @__PURE__ */ m(n, { children: /* @__PURE__ */ m(t, { name: v }) }, v))
|
|
273
|
+
});
|
|
274
|
+
}
|
|
275
|
+
//#endregion
|
|
276
|
+
export { D as a, x as c, O as i, b as l, A as n, k as o, j as r, M as s, E as t };
|
package/dist/prompt-composer.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as e, c as t, i as n, l as r, n as i, o as a, r as o, s, t as c } from "./prompt-composer-
|
|
1
|
+
import { a as e, c as t, i as n, l as r, n as i, o as a, r as o, s, t as c } from "./prompt-composer-Cu8bj1Vb.js";
|
|
2
2
|
export { c as PromptComposer, i as PromptComposerAction, o as PromptComposerAttach, t as PromptComposerDefaultsProvider, n as PromptComposerFooter, e as PromptComposerHeader, a as PromptComposerInput, s as PromptComposerSubmit, r as usePromptComposerDefaults };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as e } from "./i18n-
|
|
1
|
+
import { r as e } from "./i18n-D7xXDd8-.js";
|
|
2
2
|
import { keyedProps as t } from "@slotted/core/selector-key";
|
|
3
3
|
import { createContext as n, useCallback as r, useContext as i, useEffect as a, useImperativeHandle as o, useRef as s, useState as c } from "react";
|
|
4
4
|
import { Fragment as l, jsx as u, jsxs as d } from "react/jsx-runtime";
|
package/dist/prose.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as e, c as t, i as n, n as r, o as i, r as a, s as o, t as s } from "./prose-
|
|
1
|
+
import { a as e, c as t, i as n, n as r, o as i, r as a, s as o, t as s } from "./prose-CQN4Bqqh.js";
|
|
2
2
|
export { i as Prose, r as ProseAnchor, o as ProseDefaultsProvider, a as ProseExclude, n as ProseFootnotes, e as ProseLead, s as ProseScroll, t as useProseDefaults };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as e, t } from "./icon-DjqSEQ-o.js";
|
|
2
|
-
import { b as n, f as r } from "./field-
|
|
3
|
-
import { r as i } from "./field-group-
|
|
2
|
+
import { b as n, f as r } from "./field-tnEZiRLg.js";
|
|
3
|
+
import { r as i } from "./field-group-Bj-EbPIU.js";
|
|
4
4
|
import { keyedProps as a, withSelectorKey as o } from "@slotted/core/selector-key";
|
|
5
5
|
import { createControllable as s } from "@slotted/core/state";
|
|
6
6
|
import { createContext as c, useContext as l, useEffect as u, useId as d, useState as f } from "react";
|
package/dist/radio-group.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as e, i as t, n, r, t as i } from "./radio-group-
|
|
1
|
+
import { a as e, i as t, n, r, t as i } from "./radio-group-BHlDgCLk.js";
|
|
2
2
|
export { i as Radio, n as RadioGroup, t as RadioGroupDefaultsProvider, r as useRadioGroup, e as useRadioGroupDefaults };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { n as e, t } from "./
|
|
2
|
-
import { n, r } from "./
|
|
3
|
-
import { b as i, f as a } from "./field-
|
|
1
|
+
import { n as e, r as t } from "./i18n-D7xXDd8-.js";
|
|
2
|
+
import { n, t as r } from "./icon-DjqSEQ-o.js";
|
|
3
|
+
import { b as i, f as a } from "./field-tnEZiRLg.js";
|
|
4
4
|
import { keyedProps as o, selectorKeyProps as s } from "@slotted/core/selector-key";
|
|
5
5
|
import { createControllable as ee } from "@slotted/core/state";
|
|
6
6
|
import { createContext as c, createElement as l, useContext as u, useEffect as te, useId as d, useImperativeHandle as ne, useRef as f, useState as p } from "react";
|
|
@@ -40,7 +40,7 @@ function O(e) {
|
|
|
40
40
|
return String(Math.round(e * 1e4) / 1e4);
|
|
41
41
|
}
|
|
42
42
|
function k() {
|
|
43
|
-
return /* @__PURE__ */ h(
|
|
43
|
+
return /* @__PURE__ */ h(r, { children: /* @__PURE__ */ h(n, { name: "star" }) });
|
|
44
44
|
}
|
|
45
45
|
function A({ fill: e, index: t, renderSymbol: n }) {
|
|
46
46
|
let r = n === void 0 ? /* @__PURE__ */ h(k, {}) : n({
|
|
@@ -57,10 +57,10 @@ function A({ fill: e, index: t, renderSymbol: n }) {
|
|
|
57
57
|
children: r
|
|
58
58
|
})] });
|
|
59
59
|
}
|
|
60
|
-
function j({ "aria-label":
|
|
61
|
-
let C = E(), w =
|
|
60
|
+
function j({ "aria-label": n, className: r, count: i, distribution: a, locale: s, max: ee, messages: c, ref: l, render: u, renderSymbol: te, role: d, showValue: ne, size: f, style: p, tone: _, value: b, variant: x, ...ie }) {
|
|
61
|
+
let C = E(), w = t(re, c), T = e(), D = Math.max(1, Math.floor(ee ?? C.max)), k = x ?? "full", j = s ?? T, M = Number.isFinite(b) ? Math.min(Math.max(b, 0), D) : 0, N = k === "full" ? S(M, D) : [+(M > 0)], P = new Intl.NumberFormat(j), ae = Math.max(0, ...a ?? []), F = o({
|
|
62
62
|
...ie,
|
|
63
|
-
"aria-label":
|
|
63
|
+
"aria-label": n ?? (i === void 0 ? w("displayLabel", {
|
|
64
64
|
value: y(M, j),
|
|
65
65
|
max: D
|
|
66
66
|
}) : w("displayLabelWithCount", {
|
|
@@ -106,7 +106,7 @@ function j({ "aria-label": e, className: t, count: i, distribution: a, locale: s
|
|
|
106
106
|
children: k === "histogram" ? P.format(i) : `(${P.format(i)})`
|
|
107
107
|
})
|
|
108
108
|
] }),
|
|
109
|
-
className:
|
|
109
|
+
className: r,
|
|
110
110
|
"data-part": "root",
|
|
111
111
|
"data-size": f ?? C.size,
|
|
112
112
|
"data-tone": _ ?? C.tone,
|
|
@@ -128,8 +128,8 @@ function M(e) {
|
|
|
128
128
|
function N(e) {
|
|
129
129
|
return getComputedStyle(e).direction === "rtl" || e.closest("[dir]")?.getAttribute("dir")?.toLowerCase() === "rtl";
|
|
130
130
|
}
|
|
131
|
-
function P({ "aria-describedby":
|
|
132
|
-
let H = i(), ve = a(), U = E(), ye =
|
|
131
|
+
function P({ "aria-describedby": n, "aria-invalid": r, "aria-label": s, "aria-labelledby": c, "aria-readonly": l, "aria-required": u, caption: _, className: v, clearable: b, defaultValue: w, disabled: T, form: D, handle: O, invalid: k, locale: j, max: P, messages: ae, name: F, onKeyDown: oe, onPointerDown: se, onPointerLeave: I, onPointerOver: ce, onPreviewChange: L, onValueChange: le, readOnly: ue, ref: R, render: z, renderSymbol: de, required: fe, role: pe, size: me, step: B, style: he, tone: ge, value: V, ..._e }) {
|
|
132
|
+
let H = i(), ve = a(), U = E(), ye = t(re, ae), be = e(), xe = d(), W = Math.max(1, Math.floor(P ?? U.max)), G = B ?? 1, K = {
|
|
133
133
|
max: W,
|
|
134
134
|
step: G
|
|
135
135
|
}, Se = me ?? H?.size ?? U.size, Ce = ge ?? U.tone, we = b ?? U.clearable, Te = j ?? be, q = T ?? H?.disabled ?? ve.disabled, J = ue ?? H?.readOnly ?? ve.readOnly, Ee = k ?? H?.invalid, De = fe ?? H?.required, Y = q === !0 || J === !0, [Oe, ke] = p(() => x(w, K)), X = x(V === void 0 ? Oe : V, K), [Ae, je] = p(null), [Me, Ne] = p(!1), Pe = f(null), Fe = f(null), Z = f(/* @__PURE__ */ new Map()), Q = f(void 0), Ie = f(!1), Le = H?.registerControl;
|
|
@@ -187,8 +187,8 @@ function P({ "aria-describedby": e, "aria-invalid": t, "aria-label": s, "aria-la
|
|
|
187
187
|
Q.current?.pointerId === e.pointerId && (Q.current = void 0, Ne(!1));
|
|
188
188
|
}, We = S(X, W), Ge = o({
|
|
189
189
|
..._e,
|
|
190
|
-
"aria-describedby": [
|
|
191
|
-
"aria-invalid":
|
|
190
|
+
"aria-describedby": [n, H?.describedBy].filter(Boolean).join(" ") || void 0,
|
|
191
|
+
"aria-invalid": r ?? (Ee === !0 || void 0),
|
|
192
192
|
"aria-label": s,
|
|
193
193
|
"aria-labelledby": c ?? (s === void 0 && H !== void 0 ? H.ids.label : void 0),
|
|
194
194
|
"aria-readonly": l ?? (J === !0 || void 0),
|
|
@@ -290,8 +290,8 @@ function oe(e, t) {
|
|
|
290
290
|
] });
|
|
291
291
|
}
|
|
292
292
|
var se = (e, t) => e.length === t.length && e.every((e, n) => e === t[n]);
|
|
293
|
-
function I({ className:
|
|
294
|
-
let A = E(), M = Math.max(1, Math.floor(te ?? A.max)), N = T ?? "bars", P = C ?? A.tone, I =
|
|
293
|
+
function I({ className: n, counts: r, defaultSelectedLevels: i, filterable: a, insightThresholds: c, locale: u, max: te, messages: d, onSelectedLevelsChange: ne, ref: f, render: _, selectedLevels: y, showInsight: x, size: ie, style: S, tone: C, variant: T, ...D }) {
|
|
294
|
+
let A = E(), M = Math.max(1, Math.floor(te ?? A.max)), N = T ?? "bars", P = C ?? A.tone, I = t(re, d), ce = e(), L = u ?? ce, le = Array.from({ length: M }, (e, t) => r[t] ?? 0), ue = {
|
|
295
295
|
...A.insightThresholds,
|
|
296
296
|
...c
|
|
297
297
|
}, R = w(le, ue), z = R.total > 0, de = new Intl.NumberFormat(L), fe = new Intl.NumberFormat(L, {
|
|
@@ -481,7 +481,7 @@ function I({ className: e, counts: t, defaultSelectedLevels: i, filterable: a, i
|
|
|
481
481
|
} : void 0, G = o({
|
|
482
482
|
...D,
|
|
483
483
|
children: N === "spectrum" ? xe : ve,
|
|
484
|
-
className:
|
|
484
|
+
className: n,
|
|
485
485
|
"data-part": "root",
|
|
486
486
|
"data-size": ie ?? A.size,
|
|
487
487
|
"data-tone": P,
|
package/dist/rating.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as e, i as t, n, r, t as i } from "./rating-
|
|
1
|
+
import { a as e, i as t, n, r, t as i } from "./rating-Cr0lXaAV.js";
|
|
2
2
|
export { n as Rating, r as RatingDisplay, t as RatingProvider, i as RatingSummary, e as useRatingDefaults };
|