@povio/ui 5.0.0-rc.1 → 5.0.0-rc.3
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/.rulesync/rules/ui-buttons-and-content.md +56 -0
- package/.rulesync/rules/ui-inputs-and-forms.md +62 -0
- package/.rulesync/rules/ui-overlays-navigation-and-styling.md +49 -0
- package/.rulesync/rules/ui-overview.md +33 -0
- package/README.md +49 -16
- package/dist/{Accordion-CzFKi8Bp.js → Accordion-BzwO4_ml.js} +20 -136
- package/dist/{Alert-T25LY8ZL.js → Alert-CnvEb1D_.js} +16 -12
- package/dist/{Alert-f1dG-4Uy.d.ts → Alert-DfiJbKH0.d.ts} +2 -1
- package/dist/{AlertDialog-B6R2MbNg.d.ts → AlertDialog-OWTbR4km.d.ts} +3 -3
- package/dist/{Autocomplete-CQ63Cynd.d.ts → Autocomplete-BwNHp8fy.d.ts} +1 -1
- package/dist/{Badge-YKlKz-Jy.d.ts → Badge-CBNpj823.d.ts} +8 -5
- package/dist/BadgeButton-Ccgt3oGO.d.ts +15 -0
- package/dist/{BottomSheet-DvqBvth_.js → BottomSheet-BXLE3161.js} +7 -6
- package/dist/{BottomSheet-xaymO7aQ.d.ts → BottomSheet-DbQuzfAB.d.ts} +1 -1
- package/dist/{BottomSheet.lazy-CGBRPve_.d.ts → BottomSheet.lazy-D9LCEo7s.d.ts} +1 -1
- package/dist/{Breadcrumbs-DyriI-Bi.d.ts → Breadcrumbs-CUV6CU8Q.d.ts} +1 -1
- package/dist/{Breadcrumbs-DiIYJAWf.js → Breadcrumbs-CbKzAq1v.js} +24 -38
- package/dist/Button-C5rv4Cr2.js +506 -0
- package/dist/{Button-BZ3is6IU.d.ts → Button-D-4qb0IR.d.ts} +3 -3
- package/dist/{ButtonContent-B2_dZ6vA.js → ButtonContent-c7lJayVQ.js} +10 -8
- package/dist/{Calendar-DzQApBCy.js → Calendar-CVSQH-rC.js} +22 -15
- package/dist/{CheckContent-DZ7Gk8GS.js → CheckContent-D7sZPmzx.js} +2 -2
- package/dist/{Checkbox-BepzfVfK.js → Checkbox-BU0d702K.js} +6 -6
- package/dist/{Checkbox-CHpgW3fI.d.ts → Checkbox-DVTWaMKa.d.ts} +1 -1
- package/dist/{CheckboxCheckmark-B3lnOjsU.js → CheckboxCheckmark-usHsolNj.js} +10 -10
- package/dist/{CheckboxGroup-CXrR3A-c.d.ts → CheckboxGroup-DGF12cmB.d.ts} +3 -3
- package/dist/ComponentGallery-DIFeJqGx.js +2528 -0
- package/dist/{DatePicker-B3l9TEjW.d.ts → DatePicker-8xSs_jNd.d.ts} +3 -3
- package/dist/{DatePicker-CI87jC4_.js → DatePicker-D95gDPhg.js} +12 -11
- package/dist/{DatePickerInput-UBZcTmdv.js → DatePickerInput-CX6NYim4.js} +12 -23
- package/dist/{DatePickerInput-CZTEsrS0.d.ts → DatePickerInput-D81ZJ3fT.d.ts} +3 -3
- package/dist/{DateRangePicker-DKkc2B3n.d.ts → DateRangePicker-Bfq-yDm7.d.ts} +3 -3
- package/dist/{DateRangePicker-BX2O5zA8.js → DateRangePicker-_uTQk_ae.js} +16 -15
- package/dist/{DateTimePicker-CVfkp45w.js → DateTimePicker-BB058Z34.js} +11 -10
- package/dist/{DateTimePicker-IHr-wPq8.d.ts → DateTimePicker-D4lHyf6P.d.ts} +3 -3
- package/dist/{Dialog-DdRP4YFC.js → Dialog-9manOgMA.js} +4 -4
- package/dist/{Dialog-CXoVeIkU.js → Dialog-CKLkS00H.js} +10 -2
- package/dist/{Dialog-DEbI_9S-.d.ts → Dialog-CW93T9X1.d.ts} +3 -2
- package/dist/{DropdownMenu-zrodtd44.js → DropdownMenu-5jmtgLXd.js} +8 -6
- package/dist/{DropdownMenu-CWDhk3XA.d.ts → DropdownMenu-JNpYT4-3.d.ts} +3 -2
- package/dist/{DropdownMenuDesktop-CGYxsavQ.js → DropdownMenuDesktop-Cl9gZVq0.js} +9 -38
- package/dist/{FileInput-Dz1eESr_.js → FileInput-C0-6bw4w.js} +8 -8
- package/dist/{FileInput-BQbn77bE.d.ts → FileInput-C4CE5kuP.d.ts} +5 -4
- package/dist/{FileUpload-qySCMcLn.d.ts → FileUpload-CR7bZxV1.d.ts} +1 -1
- package/dist/{FileUpload-D3Io7Is5.js → FileUpload-DDpYMn8f.js} +51 -139
- package/dist/{FileUploadContainer-qOyGvb5J.d.ts → FileUploadContainer-042ztsaL.d.ts} +1 -1
- package/dist/{Form-u_N_6mwo.d.ts → Form-BJ12MjE-.d.ts} +1 -1
- package/dist/{FormField-B0miX3gu.d.ts → FormField-Byiehm9y.d.ts} +1 -1
- package/dist/{FormField-CHD4OJOt.js → FormField-U_-d4V_g.js} +9 -9
- package/dist/{FormFieldError-QRAFHUTt.js → FormFieldError-DeOHHLo2.js} +1 -1
- package/dist/FormFieldHeaderTooltip-DXbuu88v.js +17 -0
- package/dist/{IconButton-KXecZgYX.d.ts → IconButton-D4thBurp.d.ts} +2 -2
- package/dist/IconSlot-DSK7qNxc.js +79 -0
- package/dist/{InlineIconButton-CbKZ2U_a.d.ts → InlineIconButton-BeJCjl-q.d.ts} +2 -2
- package/dist/{InlineTooltipWrapper-g5yoeH1B.js → InlineTooltipWrapper-Bpmd--e7.js} +3 -3
- package/dist/{Input-efmPwk8f.d.ts → Input-DOanwj3l.d.ts} +3 -3
- package/dist/{InputContent-DuBa9FuI.d.ts → InputContent-CXuP1ghQ.d.ts} +3 -3
- package/dist/{InputItem-2zf6QI5L.js → InputItem-D-KuiNSc.js} +11 -11
- package/dist/{Inputs-C-w03Q_F.d.ts → Inputs-DA73LmLc.d.ts} +1 -1
- package/dist/{Inputs-BceDTmdT.js → Inputs-j3JmcLWR.js} +1 -1
- package/dist/{Link-QYpprkN1.d.ts → Link-Ow9H7kNv.d.ts} +3 -2
- package/dist/{ListBox-B7DW1S7n.js → ListBox-CL8Ar4Q_.js} +5 -4
- package/dist/{MenuItem--Mjd_yK8.d.ts → MenuItem-DHyqOqln.d.ts} +1 -1
- package/dist/{Modal-CoFt5PGP.js → Modal-w60dVQcb.js} +1 -1
- package/dist/{NumberField-z2JatYK0.d.ts → NumberField-Cb9Gf6QJ.d.ts} +3 -3
- package/dist/{NumberRangeInput-Chai3iEi.d.ts → NumberRangeInput-BfbJQqzn.d.ts} +2 -2
- package/dist/{NumberRangeInput-BxVrHq8R.js → NumberRangeInput-C-8U05wF.js} +6 -6
- package/dist/{Pagination-CXtIDclf.d.ts → Pagination-CwQu5Py8.d.ts} +1 -1
- package/dist/{PaginationList-CXG4jWFD.d.ts → PaginationList-DMRUGtf8.d.ts} +1 -1
- package/dist/{PaginationList-0bAmvXC0.js → PaginationList-DtvuP63b.js} +2 -2
- package/dist/{PasswordInput-ub2TQxef.d.ts → PasswordInput-CLwFUgl0.d.ts} +1 -1
- package/dist/{Popover-DUKH0q9u.d.ts → Popover-BTHPteIh.d.ts} +2 -2
- package/dist/{Progress-DQWiFP0L.js → Progress-B3mY9rIP.js} +2 -2
- package/dist/{Progress-Dho39FDs.d.ts → Progress-CjWOR38H.d.ts} +2 -1
- package/dist/{QuerySelect-Bo1K6gi_.d.ts → QuerySelect-BGxb6Y0K.d.ts} +2 -2
- package/dist/{RadioGroup-SSZYch-J.js → RadioGroup-B7_pNwn9.js} +13 -13
- package/dist/{RadioGroup-B_zJdn4y.d.ts → RadioGroup-CZg2kIMk.d.ts} +3 -3
- package/dist/{RichTextEditor-D6RewmRj.js → RichTextEditor-D9-B1Cze.js} +52 -133
- package/dist/{RichTextEditor-B_JX3nor.d.ts → RichTextEditor-YxuRUlI7.d.ts} +1 -1
- package/dist/{Select-CuZDkeQs.js → Select-CkujlTjm.js} +5 -4
- package/dist/{Select-DeapZMYx.d.ts → Select-pHbyJdZJ.d.ts} +1 -1
- package/dist/{SelectBase-7SE9Za2r.d.ts → SelectBase-Omiq2D3M.d.ts} +3 -3
- package/dist/{Slider-DJ9K_a-x.js → Slider-BHPl0OPy.js} +11 -11
- package/dist/{Slider-BFViQmM3.d.ts → Slider-EYlGCLWe.d.ts} +1 -1
- package/dist/{Spinner-BEYBu85B.js → Spinner-BeVTUzzx.js} +1 -1
- package/dist/{Spinner-BbcI6IOb.d.ts → Spinner-DbXeDOa2.d.ts} +2 -1
- package/dist/{SplitButton-lL87EcBL.d.ts → SplitButton-D9ngY1rJ.d.ts} +3 -3
- package/dist/{Stepper-C1YPgTBG.js → Stepper-Cp5vbL5g.js} +4 -117
- package/dist/{Stepper-hlhViuaK.d.ts → Stepper-TATlHZhQ.d.ts} +9 -8
- package/dist/{Switch-JxRmH1dX.js → Switch-CqnGEdeD.js} +11 -11
- package/dist/{Switch-DPftmB1b.d.ts → Switch-s_EPn0Jz.d.ts} +1 -1
- package/dist/Table-BDNSuEWc.js +689 -0
- package/dist/Tag-AHfV_XSf.d.ts +44 -0
- package/dist/{Tag-HiDH438e.js → Tag-DPg5sL1Z.js} +22 -21
- package/dist/{TextArea-gikUKKDl.js → TextArea-DqHDiRGJ.js} +6 -6
- package/dist/{TextArea-BhrCBGbq.d.ts → TextArea-l_keyLK7.d.ts} +2 -2
- package/dist/{TextButton-DnXRykhF.d.ts → TextButton-XUhV_1s0.d.ts} +4 -4
- package/dist/{TimePicker-CmT89X7v.d.ts → TimePicker-B1POvGWs.d.ts} +2 -2
- package/dist/{TimePicker-DtNTOOGr.js → TimePicker-DQ6JCkGB.js} +10 -10
- package/dist/Toast-DtG3pA61.js +53 -0
- package/dist/{Toast-B4cXs2rj.d.ts → Toast-ruXqONDA.d.ts} +1 -1
- package/dist/{ToastContainer-BbsMIwtC.js → ToastContainer-qgpzMFD4.js} +4 -3
- package/dist/{ToggleButton-BGuzPJDO.d.ts → ToggleButton-7aP8Jb11.d.ts} +2 -2
- package/dist/{ToggleGroup-D9CFdM5-.d.ts → ToggleGroup-CRFDIPGZ.d.ts} +1 -1
- package/dist/{ToggleGroup-Cl0NS3fe.js → ToggleGroup-DX0VYXwP.js} +25 -58
- package/dist/{Tooltip-aE1Vswxz.js → Tooltip-B9DKcYvr.js} +6 -47
- package/dist/{Tooltip-D7dNwGy9.d.ts → Tooltip-DHv6vAqW.d.ts} +6 -5
- package/dist/{TooltipWrapper-CRf-JFeo.js → TooltipWrapper-DznDgVJB.js} +4 -4
- package/dist/{Typography-B0Gp1lpc.js → Typography-LU4z2pR1.js} +2 -2
- package/dist/{Typography-BiuidzDC.d.ts → Typography-XljT9s02.d.ts} +1 -1
- package/dist/accordion.cva-CL1bVscW.js +129 -0
- package/dist/{autocomplete-BJ7rqWa4.d.ts → autocomplete-DeERHN8W.d.ts} +2 -2
- package/dist/badgeButton.cva-B2bgCQP6.d.ts +41 -0
- package/dist/badgeButton.cva-CvN4CTx5.js +300 -0
- package/dist/breadcrumbs.cva-7zzdDhVR.js +27 -0
- package/dist/{button.cva-BvRI-3Gn.d.ts → button.cva-C7kEhgoA.d.ts} +7 -6
- package/dist/{buttonContent.cva-BDT_CReI.d.ts → buttonContent.cva-DPIlROA9.d.ts} +2 -2
- package/dist/{checkbox-BfcE8J5P.d.ts → checkbox-DxIPDTK5.d.ts} +1 -1
- package/dist/{checkbox-group-CHs2wFHS.d.ts → checkbox-group-B3BOVshI.d.ts} +1 -1
- package/dist/{checkbox.cva-gv87kr1W.d.ts → checkbox.cva-t1Ox50hy.d.ts} +4 -3
- package/dist/components/accordion.js +1 -1
- package/dist/components/alert-dialog.d.ts +1 -1
- package/dist/components/alert-dialog.js +4 -4
- package/dist/components/alert.d.ts +1 -1
- package/dist/components/alert.js +1 -1
- package/dist/components/autocomplete.d.ts +1 -1
- package/dist/components/autocomplete.js +5 -4
- package/dist/components/badge-button.d.ts +2 -0
- package/dist/components/{pill-button.js → badge-button.js} +13 -12
- package/dist/components/badge.d.ts +1 -1
- package/dist/components/badge.js +56 -37
- package/dist/components/bottom-sheet.d.ts +2 -2
- package/dist/components/bottom-sheet.js +2 -2
- package/dist/components/breadcrumbs.d.ts +1 -1
- package/dist/components/breadcrumbs.js +1 -1
- package/dist/components/button.d.ts +2 -2
- package/dist/components/button.js +1 -1
- package/dist/components/checkbox-group.d.ts +1 -1
- package/dist/components/checkbox-group.js +6 -6
- package/dist/components/checkbox.d.ts +1 -1
- package/dist/components/checkbox.js +1 -1
- package/dist/components/date-picker.d.ts +1 -1
- package/dist/components/date-picker.js +1 -1
- package/dist/components/date-range-picker.d.ts +1 -1
- package/dist/components/date-range-picker.js +1 -1
- package/dist/components/date-time-picker.d.ts +1 -1
- package/dist/components/date-time-picker.js +1 -1
- package/dist/components/dialog.d.ts +1 -1
- package/dist/components/dialog.js +1 -1
- package/dist/components/drawer.js +3 -3
- package/dist/components/dropdown-menu.d.ts +2 -2
- package/dist/components/dropdown-menu.js +2 -2
- package/dist/components/file-input.d.ts +1 -1
- package/dist/components/file-input.js +1 -1
- package/dist/components/file-upload-container.d.ts +2 -2
- package/dist/components/file-upload-container.js +1 -1
- package/dist/components/file-upload.d.ts +2 -2
- package/dist/components/file-upload.js +1 -1
- package/dist/components/form-field.d.ts +1 -1
- package/dist/components/form-field.js +1 -1
- package/dist/components/icon-button.d.ts +1 -1
- package/dist/components/icon-button.js +2 -2
- package/dist/components/icon-slot.d.ts +2 -0
- package/dist/components/icon-slot.js +2 -0
- package/dist/components/inline-icon-button.d.ts +1 -1
- package/dist/components/inline-icon-button.js +1 -1
- package/dist/components/input.d.ts +1 -1
- package/dist/components/input.js +7 -7
- package/dist/components/link.d.ts +1 -1
- package/dist/components/link.js +32 -1
- package/dist/components/number-field.d.ts +1 -1
- package/dist/components/number-field.js +7 -7
- package/dist/components/number-range-input.d.ts +1 -1
- package/dist/components/number-range-input.js +1 -1
- package/dist/components/pagination-list.d.ts +1 -1
- package/dist/components/pagination-list.js +1 -1
- package/dist/components/pagination.d.ts +1 -1
- package/dist/components/pagination.js +2 -2
- package/dist/components/password-input.d.ts +1 -1
- package/dist/components/popover.d.ts +1 -1
- package/dist/components/popover.js +6 -5
- package/dist/components/progress.d.ts +1 -1
- package/dist/components/progress.js +1 -1
- package/dist/components/query-autocomplete.d.ts +2 -2
- package/dist/components/query-autocomplete.js +2 -2
- package/dist/components/query-select.d.ts +1 -1
- package/dist/components/query-select.js +3 -3
- package/dist/components/radio-group.d.ts +1 -1
- package/dist/components/radio-group.js +1 -1
- package/dist/components/select.d.ts +2 -2
- package/dist/components/select.js +1 -1
- package/dist/components/slider.d.ts +1 -1
- package/dist/components/slider.js +1 -1
- package/dist/components/spinner.d.ts +1 -1
- package/dist/components/spinner.js +1 -1
- package/dist/components/split-button.d.ts +1 -1
- package/dist/components/split-button.js +3 -3
- package/dist/components/stepper.d.ts +1 -1
- package/dist/components/stepper.js +1 -1
- package/dist/components/switch.d.ts +1 -1
- package/dist/components/switch.js +1 -1
- package/dist/components/tag.d.ts +1 -1
- package/dist/components/tag.js +1 -1
- package/dist/components/text-area.d.ts +1 -1
- package/dist/components/text-area.js +1 -1
- package/dist/components/text-button.d.ts +1 -1
- package/dist/components/text-button.js +1 -1
- package/dist/components/time-picker.d.ts +1 -1
- package/dist/components/time-picker.js +1 -1
- package/dist/components/toast.d.ts +2 -2
- package/dist/components/toast.js +2 -2
- package/dist/components/toggle-button.d.ts +1 -1
- package/dist/components/toggle-button.js +1 -1
- package/dist/components/toggle-group.d.ts +2 -2
- package/dist/components/toggle-group.js +1 -1
- package/dist/components/tooltip-ellipsis.js +1 -1
- package/dist/components/tooltip.d.ts +1 -1
- package/dist/components/tooltip.js +1 -1
- package/dist/components/typography.d.ts +2 -2
- package/dist/components/typography.js +1 -1
- package/dist/components/use-toast.d.ts +1 -1
- package/dist/components/use-toast.js +2 -2
- package/dist/config/confirmation.d.ts +1 -1
- package/dist/config/link-context.d.ts +2 -2
- package/dist/config/ui-config.d.ts +2 -2
- package/dist/config/ui-config.js +1 -1
- package/dist/config/ui-configurator-theme.d.ts +2 -0
- package/dist/config/ui-configurator-theme.js +2 -0
- package/dist/config/ui-configurator-vite.d.ts +10 -0
- package/dist/config/ui-configurator-vite.js +174 -0
- package/dist/config/ui-configurator.d.ts +934 -0
- package/dist/config/ui-configurator.js +3731 -0
- package/dist/config/ui-overrides.d.ts +1 -1
- package/dist/config/ui-overrides.js +1 -1
- package/dist/{confirmation.context-DPAKsLYl.d.ts → confirmation.context-BOeEVczb.d.ts} +1 -1
- package/dist/{date-picker-BYFWSbN8.d.ts → date-picker-DnxDmlOW.d.ts} +1 -1
- package/dist/{date-range-picker-BaaXOObm.d.ts → date-range-picker-DHDOSvHN.d.ts} +1 -1
- package/dist/{date-time-picker-D42cTCgx.d.ts → date-time-picker-UkTa0OJ8.d.ts} +1 -1
- package/dist/datePickerInput.cva-Cd7UUN61.js +14 -0
- package/dist/{datePickerValue.utils-CFCY-fRJ.js → datePickerValue.utils-CUzkWie8.js} +5 -5
- package/dist/{dialog.cva---xiOXMQ.js → dialog.cva-COhDZaVl.js} +4 -4
- package/dist/{dist-B8h0VT0E.js → dist-CAdwxJbe.js} +1 -208
- package/dist/{dom.utils-DjuRTR6U.js → dom.utils-D1AopHx9.js} +1 -1
- package/dist/dropdownMenu.cva-DvEmX0bs.js +34 -0
- package/dist/{dynamicInputs-wEEikYeg.d.ts → dynamicInputs-iP39lVKf.d.ts} +102 -100
- package/dist/{fieldAdapter-C0lCFmf0.js → fieldAdapter-DjYls12j.js} +1 -1
- package/dist/{file-input-C56GXRwz.d.ts → file-input-DkbkdI7l.d.ts} +1 -1
- package/dist/{file-upload-Bx0X534g.d.ts → file-upload-CTsPhxJk.d.ts} +2 -2
- package/dist/fileUpload.cva-ujmStxB1.js +42 -0
- package/dist/{fileUpload.types-DWuQKA2l.d.ts → fileUpload.types-n5FxK_F-.d.ts} +2 -2
- package/dist/iconSlot.cva-CnpFzAOR.d.ts +21 -0
- package/dist/icons.d.ts +2 -1
- package/dist/icons.js +2 -1
- package/dist/index.d.ts +87 -86
- package/dist/index.js +55 -44
- package/dist/info-iUmX3uDk.js +32 -0
- package/dist/{input-D2kGX0hW.d.ts → input-CdQNCPgH.d.ts} +1 -1
- package/dist/{input.cva-BhDJxc7r.d.ts → input.cva-BsHgYa-L.d.ts} +3 -2
- package/dist/{input.cva-BcXyC1vZ.js → input.cva-DJA8ovm_.js} +9 -9
- package/dist/{link.context-CDZn6oL2.d.ts → link.context-D5qyz9Rf.d.ts} +1 -1
- package/dist/link.cva-DMTHZiJG.js +12 -0
- package/dist/{number-field-Bw2GKr0s.d.ts → number-field-CUDbenNV.d.ts} +1 -1
- package/dist/{number-range-input-Dqe6x2dR.d.ts → number-range-input-DZGrcvjL.d.ts} +1 -1
- package/dist/{password-input-DepKyhh3.d.ts → password-input-fYN20cQO.d.ts} +1 -1
- package/dist/{popover.cva-BJSkLndY.js → popover.cva-Bhud1wnp.js} +1 -1
- package/dist/popoverAnimation-DEZSvKP8.js +4 -0
- package/dist/{query-autocomplete-BSpHin_R.d.ts → query-autocomplete-CfuQeiYG.d.ts} +2 -2
- package/dist/{query-select-m1DCp4UF.d.ts → query-select-CuT_sE6a.d.ts} +2 -2
- package/dist/{queryAutocomplete.types-CrbVUmvl.d.ts → queryAutocomplete.types-tl3r6iaY.d.ts} +2 -2
- package/dist/{radio-group-Civ3Fb70.d.ts → radio-group-B3ccPf0p.d.ts} +1 -1
- package/dist/{radio.cva-BlOrmxzf.d.ts → radio.cva-DN9VQ3Kb.d.ts} +4 -3
- package/dist/rhf/autocomplete.d.ts +2 -2
- package/dist/rhf/autocomplete.js +1 -1
- package/dist/rhf/checkbox-group.d.ts +2 -2
- package/dist/rhf/checkbox-group.js +1 -1
- package/dist/rhf/checkbox.d.ts +2 -2
- package/dist/rhf/checkbox.js +2 -2
- package/dist/rhf/date-picker.d.ts +2 -2
- package/dist/rhf/date-picker.js +2 -2
- package/dist/rhf/date-range-picker.d.ts +2 -2
- package/dist/rhf/date-range-picker.js +2 -2
- package/dist/rhf/date-time-picker.d.ts +2 -2
- package/dist/rhf/date-time-picker.js +2 -2
- package/dist/rhf/file-input.d.ts +2 -2
- package/dist/rhf/file-input.js +2 -2
- package/dist/rhf/file-upload.d.ts +2 -2
- package/dist/rhf/file-upload.js +2 -2
- package/dist/rhf/input.d.ts +2 -2
- package/dist/rhf/input.js +1 -1
- package/dist/rhf/inputs.d.ts +2 -2
- package/dist/rhf/number-field.d.ts +2 -2
- package/dist/rhf/number-field.js +1 -1
- package/dist/rhf/number-range-input.d.ts +2 -2
- package/dist/rhf/number-range-input.js +2 -2
- package/dist/rhf/password-input.d.ts +2 -2
- package/dist/rhf/password-input.js +1 -1
- package/dist/rhf/query-autocomplete.d.ts +1 -1
- package/dist/rhf/query-autocomplete.js +1 -1
- package/dist/rhf/query-select.d.ts +1 -1
- package/dist/rhf/query-select.js +1 -1
- package/dist/rhf/radio-group.d.ts +2 -2
- package/dist/rhf/radio-group.js +2 -2
- package/dist/rhf/rich-text-editor.d.ts +2 -2
- package/dist/rhf/rich-text-editor.js +2 -2
- package/dist/rhf/select.d.ts +2 -2
- package/dist/rhf/select.js +2 -2
- package/dist/rhf/slider.d.ts +2 -2
- package/dist/rhf/slider.js +2 -2
- package/dist/rhf/switch.d.ts +2 -2
- package/dist/rhf/switch.js +2 -2
- package/dist/rhf/text-area.d.ts +2 -2
- package/dist/rhf/text-area.js +2 -2
- package/dist/rhf/time-picker.d.ts +2 -2
- package/dist/rhf/time-picker.js +2 -2
- package/dist/rhf/toggle-group.d.ts +2 -2
- package/dist/rhf/toggle-group.js +2 -2
- package/dist/{rhf-D8B7mLO1.js → rhf-t348TCCL.js} +1 -1
- package/dist/rhf.d.ts +87 -86
- package/dist/rhf.js +55 -44
- package/dist/{rich-text-editor-DvNEOIux.d.ts → rich-text-editor-B-Onl7T8.d.ts} +1 -1
- package/dist/rich-text-editor.d.ts +1 -1
- package/dist/rich-text-editor.js +1 -1
- package/dist/{select-DY5QtwqI.d.ts → select-B4a52eWW.d.ts} +2 -2
- package/dist/selectDesktop.cva-CHAMxhfO.js +69 -0
- package/dist/{slider-CrB-Gkcv.d.ts → slider-dNj9jruO.d.ts} +1 -1
- package/dist/{staticDateTimeSegments-DR8bJw-F.js → staticDateTimeSegments-CsCE9Buo.js} +26 -27
- package/dist/{staticSelect.utils-Cm7MoDVG.js → staticSelect.utils-BemUyaaA.js} +31 -90
- package/dist/stepper.cva-CZ0Kj-s7.js +116 -0
- package/dist/style-merge.util-zLimKwt6.d.ts +40 -0
- package/dist/styles/color-utilities.css +13 -25
- package/dist/styles/configurator.css +1852 -0
- package/dist/styles/input.d.ts +1 -1
- package/dist/{switch-8WzXfTS8.d.ts → switch-C--iWnY8.d.ts} +1 -1
- package/dist/switch.cva-CWNzmdRc.d.ts +16 -0
- package/dist/table.cva-BikE8qJH.js +49 -0
- package/dist/tanstack/autocomplete.d.ts +1 -1
- package/dist/tanstack/checkbox-group.d.ts +1 -1
- package/dist/tanstack/checkbox.d.ts +1 -1
- package/dist/tanstack/checkbox.js +1 -1
- package/dist/tanstack/date-picker.d.ts +1 -1
- package/dist/tanstack/date-picker.js +1 -1
- package/dist/tanstack/date-range-picker.d.ts +1 -1
- package/dist/tanstack/date-range-picker.js +1 -1
- package/dist/tanstack/date-time-picker.d.ts +1 -1
- package/dist/tanstack/date-time-picker.js +1 -1
- package/dist/tanstack/file-input.d.ts +1 -1
- package/dist/tanstack/file-input.js +1 -1
- package/dist/tanstack/file-upload.d.ts +2 -2
- package/dist/tanstack/file-upload.js +1 -1
- package/dist/tanstack/form.d.ts +1 -1
- package/dist/tanstack/form.js +1 -1
- package/dist/tanstack/input.d.ts +1 -1
- package/dist/tanstack/inputs.d.ts +3 -3
- package/dist/tanstack/inputs.js +1 -1
- package/dist/tanstack/number-field.d.ts +1 -1
- package/dist/tanstack/number-range-input.d.ts +1 -1
- package/dist/tanstack/number-range-input.js +1 -1
- package/dist/tanstack/password-input.d.ts +1 -1
- package/dist/tanstack/query-select.d.ts +1 -1
- package/dist/tanstack/radio-group.d.ts +1 -1
- package/dist/tanstack/radio-group.js +1 -1
- package/dist/tanstack/rich-text-editor.d.ts +1 -1
- package/dist/tanstack/rich-text-editor.js +1 -1
- package/dist/tanstack/select.d.ts +1 -1
- package/dist/tanstack/select.js +1 -1
- package/dist/tanstack/slider.d.ts +1 -1
- package/dist/tanstack/slider.js +1 -1
- package/dist/tanstack/switch.d.ts +1 -1
- package/dist/tanstack/switch.js +1 -1
- package/dist/tanstack/table.d.ts +1 -1
- package/dist/tanstack/table.js +2 -1
- package/dist/tanstack/text-area.d.ts +1 -1
- package/dist/tanstack/text-area.js +1 -1
- package/dist/tanstack/time-picker.d.ts +1 -1
- package/dist/tanstack/time-picker.js +1 -1
- package/dist/tanstack/toggle-group.d.ts +2 -2
- package/dist/tanstack/toggle-group.js +1 -1
- package/dist/tanstack.d.ts +71 -70
- package/dist/tanstack.js +66 -53
- package/dist/{text-area-CqnKRWKq.d.ts → text-area-DQAtpOQp.d.ts} +1 -1
- package/dist/theme-model-C-QMCksE.js +136 -0
- package/dist/theme-model-T1zIdBg8.d.ts +12 -0
- package/dist/{time-picker-Cz1GIzpF.d.ts → time-picker-DoGfbil6.d.ts} +1 -1
- package/dist/{toast.cva-Cj6o2Rmu.d.ts → toast.cva-By5lvAfr.d.ts} +3 -2
- package/dist/toast.cva-C_L_RffH.js +163 -0
- package/dist/{toast.runtime-CIKvmkjo.js → toast.runtime-cxex9e4E.js} +2 -1
- package/dist/{toggle-group-CPkKHm1t.d.ts → toggle-group-C1nMDOwz.d.ts} +1 -1
- package/dist/toggleGroup.cva-MbpaEBg1.js +35 -0
- package/dist/{toggleGroup.types-DD6uRI5G.d.ts → toggleGroup.types-Bp43zbSQ.d.ts} +2 -1
- package/dist/tooltip.cva-BIzlOXHH.js +48 -0
- package/dist/{tooltipWrapper.cva-CUu8pI-a.js → tooltipWrapper.cva-BBQ4ic3D.js} +1 -1
- package/dist/{typography.cva-jtp6WWUH.d.ts → typography.cva-D1JOEYl-.d.ts} +2 -1
- package/dist/{typography.cva-CJZZSGXW.js → typography.cva-iD15k56p.js} +1 -1
- package/dist/{uiConfig.context-D2eUIPHn.js → uiConfig.context-BS3r_kTS.js} +1 -1
- package/dist/{uiConfig.context-aoarCLYX.d.ts → uiConfig.context-DeBX2beU.d.ts} +8 -8
- package/dist/{uiOverrides.context-Bfm2n-n8.js → uiOverrides.context-BTCH9y5a.js} +2 -2
- package/dist/{uiOverrides.context-C3xb4Ttq.d.ts → uiOverrides.context-DEp139He.d.ts} +11 -44
- package/dist/underline-66hmELxa.js +81 -0
- package/dist/{useBreakpoint-BOA-MyoT.js → useBreakpoint-DQoMN-BG.js} +1 -1
- package/dist/{useFieldAccessibility-D2_Qm26-.js → useFieldAccessibility-B4MVL6fz.js} +15 -8
- package/dist/{useFormAutosave-BYFn3LH8.js → useFormAutosave-Mg-tdwMh.js} +2 -2
- package/dist/{useStaticInputHandoff-DB9PgioW.js → useStaticInputHandoff-CvSBPUB3.js} +13 -10
- package/dist/useTableColumnConfig-gfVame8v.js +892 -0
- package/dist/{useTableNav-D9mICzNW.d.ts → useTableNav-Ckj5PBRk.d.ts} +3 -2
- package/dist/{useToast-DMSm59Y6.d.ts → useToast-yreVCUer.d.ts} +1 -1
- package/package.json +38 -6
- package/rulesync.jsonc +11 -0
- package/scripts/generate-rules.mjs +34 -0
- package/src/configurator/README.md +71 -0
- package/dist/Button-sn52l1Yv.js +0 -506
- package/dist/FormFieldHeaderTooltip-Dl24v4_j.js +0 -45
- package/dist/Link-Btxj2gzg.js +0 -42
- package/dist/PillButton-DASBXLFB.d.ts +0 -15
- package/dist/Tag-Cch_68QO.d.ts +0 -43
- package/dist/components/pill-button.d.ts +0 -2
- package/dist/pillButton.cva-BEWuu0qm.d.ts +0 -34
- package/dist/pillButton.cva-DlP5tOT5.js +0 -197
- package/dist/switch.cva-8T0fw31t.d.ts +0 -15
- package/dist/useTableColumnConfig-CcJxu14U.js +0 -1625
|
@@ -0,0 +1,2528 @@
|
|
|
1
|
+
import { t as createLucideIcon } from "./createLucideIcon-LcezOE4z.js";
|
|
2
|
+
import { n as ArrowLeft } from "./DropdownMenu-5jmtgLXd.js";
|
|
3
|
+
import { i as ArrowRight } from "./DropdownMenuDesktop-Cl9gZVq0.js";
|
|
4
|
+
import { n as Italic, r as Bold, t as Underline } from "./underline-66hmELxa.js";
|
|
5
|
+
import { s as Calendar, t as UIConfig } from "./uiConfig.context-BS3r_kTS.js";
|
|
6
|
+
import { t as Check } from "./check-DYMBkp_Z.js";
|
|
7
|
+
import { t as ChevronDown } from "./chevron-down-B4Pr8bD3.js";
|
|
8
|
+
import { t as ChevronUp } from "./chevron-up-D_Gqpb5M.js";
|
|
9
|
+
import { t as FileUpload } from "./FileUpload-DDpYMn8f.js";
|
|
10
|
+
import { t as PasswordInput } from "./PasswordInput-DYwUZ4-k.js";
|
|
11
|
+
import { t as Table } from "./Table-BDNSuEWc.js";
|
|
12
|
+
import { t as Info } from "./info-iUmX3uDk.js";
|
|
13
|
+
import { t as UIOverrides } from "./uiOverrides.context-BTCH9y5a.js";
|
|
14
|
+
import { t as Breadcrumbs } from "./Breadcrumbs-CbKzAq1v.js";
|
|
15
|
+
import { t as Checkbox } from "./Checkbox-BU0d702K.js";
|
|
16
|
+
import { t as Slider } from "./Slider-BHPl0OPy.js";
|
|
17
|
+
import { t as Accordion } from "./Accordion-BzwO4_ml.js";
|
|
18
|
+
import { t as RadioGroup } from "./RadioGroup-B7_pNwn9.js";
|
|
19
|
+
import { t as Switch } from "./Switch-CqnGEdeD.js";
|
|
20
|
+
import { t as TextArea } from "./TextArea-DqHDiRGJ.js";
|
|
21
|
+
import { i as menuPopoverWrapperDefinition, n as menuItemDefinition, r as menuPopoverDefinition, t as dropdownMenuDefinition } from "./dropdownMenu.cva-DvEmX0bs.js";
|
|
22
|
+
import { t as ToggleGroup } from "./ToggleGroup-DX0VYXwP.js";
|
|
23
|
+
import { i as tooltipTextDefinition, n as tooltipPointerHorizontalDefinition, t as tooltipDefinition } from "./tooltip.cva-BIzlOXHH.js";
|
|
24
|
+
import { t as Typography } from "./Typography-LU4z2pR1.js";
|
|
25
|
+
import { t as Spinner } from "./Spinner-BeVTUzzx.js";
|
|
26
|
+
import { t as Button } from "./Button-C5rv4Cr2.js";
|
|
27
|
+
import { IconButton } from "./components/icon-button.js";
|
|
28
|
+
import { BadgeButton } from "./components/badge-button.js";
|
|
29
|
+
import { SplitButton } from "./components/split-button.js";
|
|
30
|
+
import { TextButton } from "./components/text-button.js";
|
|
31
|
+
import { ToggleButton } from "./components/toggle-button.js";
|
|
32
|
+
import { t as Tag } from "./Tag-DPg5sL1Z.js";
|
|
33
|
+
import { t as popoverDefinition } from "./popover.cva-Bhud1wnp.js";
|
|
34
|
+
import { Input } from "./components/input.js";
|
|
35
|
+
import { Autocomplete } from "./components/autocomplete.js";
|
|
36
|
+
import { CheckboxGroup } from "./components/checkbox-group.js";
|
|
37
|
+
import { t as TimePicker } from "./TimePicker-DQ6JCkGB.js";
|
|
38
|
+
import { t as DatePicker } from "./DatePicker-D95gDPhg.js";
|
|
39
|
+
import { t as Select } from "./Select-CkujlTjm.js";
|
|
40
|
+
import { t as Progress } from "./Progress-B3mY9rIP.js";
|
|
41
|
+
import { NumberField } from "./components/number-field.js";
|
|
42
|
+
import { t as Stepper } from "./Stepper-Cp5vbL5g.js";
|
|
43
|
+
import { n as dialogMainDefinition, t as dialogContentDefinition } from "./dialog.cva-COhDZaVl.js";
|
|
44
|
+
import { Pagination } from "./components/pagination.js";
|
|
45
|
+
import { t as Alert } from "./Alert-CnvEb1D_.js";
|
|
46
|
+
import { t as Toast } from "./Toast-DtG3pA61.js";
|
|
47
|
+
import { Link } from "./components/link.js";
|
|
48
|
+
import { Badge } from "./components/badge.js";
|
|
49
|
+
import $ahdqC$react, { createContext, useCallback, useContext, useEffect, useLayoutEffect, useRef, useState } from "react";
|
|
50
|
+
import { c } from "react/compiler-runtime";
|
|
51
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
52
|
+
//#region ../../node_modules/.bun/lucide-react@1.43.0+83d5fd7b249dbeef/node_modules/lucide-react/dist/esm/icons/house.mjs
|
|
53
|
+
/**
|
|
54
|
+
* @license lucide-react v1.43.0 - ISC
|
|
55
|
+
*
|
|
56
|
+
* This source code is licensed under the ISC license.
|
|
57
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
58
|
+
*/
|
|
59
|
+
const __iconData$2 = {
|
|
60
|
+
name: "house",
|
|
61
|
+
size: 24,
|
|
62
|
+
node: [["path", {
|
|
63
|
+
d: "M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8",
|
|
64
|
+
key: "5wwlr5"
|
|
65
|
+
}], ["path", {
|
|
66
|
+
d: "M3 10a2 2 0 0 1 .709-1.528l7-6a2 2 0 0 1 2.582 0l7 6A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z",
|
|
67
|
+
key: "r6nss1"
|
|
68
|
+
}]],
|
|
69
|
+
aliases: ["home"]
|
|
70
|
+
};
|
|
71
|
+
__iconData$2.node;
|
|
72
|
+
const House = createLucideIcon(__iconData$2);
|
|
73
|
+
//#endregion
|
|
74
|
+
//#region ../../node_modules/.bun/lucide-react@1.43.0+83d5fd7b249dbeef/node_modules/lucide-react/dist/esm/icons/send.mjs
|
|
75
|
+
/**
|
|
76
|
+
* @license lucide-react v1.43.0 - ISC
|
|
77
|
+
*
|
|
78
|
+
* This source code is licensed under the ISC license.
|
|
79
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
80
|
+
*/
|
|
81
|
+
const __iconData$1 = {
|
|
82
|
+
name: "send",
|
|
83
|
+
size: 24,
|
|
84
|
+
node: [["path", {
|
|
85
|
+
d: "M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",
|
|
86
|
+
key: "1ffxy3"
|
|
87
|
+
}], ["path", {
|
|
88
|
+
d: "m21.854 2.147-10.94 10.939",
|
|
89
|
+
key: "12cjpa"
|
|
90
|
+
}]]
|
|
91
|
+
};
|
|
92
|
+
__iconData$1.node;
|
|
93
|
+
const Send = createLucideIcon(__iconData$1);
|
|
94
|
+
//#endregion
|
|
95
|
+
//#region ../../node_modules/.bun/lucide-react@1.43.0+83d5fd7b249dbeef/node_modules/lucide-react/dist/esm/icons/settings.mjs
|
|
96
|
+
/**
|
|
97
|
+
* @license lucide-react v1.43.0 - ISC
|
|
98
|
+
*
|
|
99
|
+
* This source code is licensed under the ISC license.
|
|
100
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
101
|
+
*/
|
|
102
|
+
const __iconData = {
|
|
103
|
+
name: "settings",
|
|
104
|
+
size: 24,
|
|
105
|
+
node: [["path", {
|
|
106
|
+
d: "M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915",
|
|
107
|
+
key: "1i5ecw"
|
|
108
|
+
}], ["circle", {
|
|
109
|
+
cx: "12",
|
|
110
|
+
cy: "12",
|
|
111
|
+
r: "3",
|
|
112
|
+
key: "1v7zrd"
|
|
113
|
+
}]]
|
|
114
|
+
};
|
|
115
|
+
__iconData.node;
|
|
116
|
+
const Settings = createLucideIcon(__iconData);
|
|
117
|
+
//#endregion
|
|
118
|
+
//#region ../../node_modules/.bun/react-aria@3.52.1+67f6792bdf102c28/node_modules/react-aria/dist/private/overlays/PortalProvider.mjs
|
|
119
|
+
const $72abaeab4d80592f$export$60d741e20e0aa309 = /*#__PURE__*/ createContext({});
|
|
120
|
+
function $72abaeab4d80592f$export$78efe591171d7d45(props) {
|
|
121
|
+
let { getContainer } = props;
|
|
122
|
+
let { getContainer: ctxGetContainer } = $72abaeab4d80592f$export$9fc1347d4195ccb3();
|
|
123
|
+
return /*#__PURE__*/ $ahdqC$react.createElement($72abaeab4d80592f$export$60d741e20e0aa309.Provider, { value: { getContainer: getContainer === null ? void 0 : getContainer ?? ctxGetContainer } }, props.children);
|
|
124
|
+
}
|
|
125
|
+
function $72abaeab4d80592f$export$9fc1347d4195ccb3() {
|
|
126
|
+
return useContext($72abaeab4d80592f$export$60d741e20e0aa309) ?? {};
|
|
127
|
+
}
|
|
128
|
+
//#endregion
|
|
129
|
+
//#region src/configurator/inspector/token-classes.ts
|
|
130
|
+
/** Tailwind breakpoints from the Atlas base theme, in rem. */
|
|
131
|
+
const breakpoints = {
|
|
132
|
+
sm: 23.75,
|
|
133
|
+
md: 37.5,
|
|
134
|
+
lg: 80,
|
|
135
|
+
xl: 105
|
|
136
|
+
};
|
|
137
|
+
/** Utility prefix → the slots it sets, its specificity, and the theme namespace its value lives in. */
|
|
138
|
+
const utilities = [
|
|
139
|
+
[
|
|
140
|
+
"p",
|
|
141
|
+
[
|
|
142
|
+
"padding.top",
|
|
143
|
+
"padding.right",
|
|
144
|
+
"padding.bottom",
|
|
145
|
+
"padding.left"
|
|
146
|
+
],
|
|
147
|
+
0,
|
|
148
|
+
"spacing"
|
|
149
|
+
],
|
|
150
|
+
[
|
|
151
|
+
"px",
|
|
152
|
+
["padding.left", "padding.right"],
|
|
153
|
+
1,
|
|
154
|
+
"spacing"
|
|
155
|
+
],
|
|
156
|
+
[
|
|
157
|
+
"py",
|
|
158
|
+
["padding.top", "padding.bottom"],
|
|
159
|
+
1,
|
|
160
|
+
"spacing"
|
|
161
|
+
],
|
|
162
|
+
[
|
|
163
|
+
"pt",
|
|
164
|
+
["padding.top"],
|
|
165
|
+
2,
|
|
166
|
+
"spacing"
|
|
167
|
+
],
|
|
168
|
+
[
|
|
169
|
+
"pr",
|
|
170
|
+
["padding.right"],
|
|
171
|
+
2,
|
|
172
|
+
"spacing"
|
|
173
|
+
],
|
|
174
|
+
[
|
|
175
|
+
"pe",
|
|
176
|
+
["padding.right"],
|
|
177
|
+
2,
|
|
178
|
+
"spacing"
|
|
179
|
+
],
|
|
180
|
+
[
|
|
181
|
+
"pb",
|
|
182
|
+
["padding.bottom"],
|
|
183
|
+
2,
|
|
184
|
+
"spacing"
|
|
185
|
+
],
|
|
186
|
+
[
|
|
187
|
+
"pl",
|
|
188
|
+
["padding.left"],
|
|
189
|
+
2,
|
|
190
|
+
"spacing"
|
|
191
|
+
],
|
|
192
|
+
[
|
|
193
|
+
"ps",
|
|
194
|
+
["padding.left"],
|
|
195
|
+
2,
|
|
196
|
+
"spacing"
|
|
197
|
+
],
|
|
198
|
+
[
|
|
199
|
+
"gap",
|
|
200
|
+
["gap.row", "gap.column"],
|
|
201
|
+
0,
|
|
202
|
+
"spacing"
|
|
203
|
+
],
|
|
204
|
+
[
|
|
205
|
+
"gap-x",
|
|
206
|
+
["gap.column"],
|
|
207
|
+
1,
|
|
208
|
+
"spacing"
|
|
209
|
+
],
|
|
210
|
+
[
|
|
211
|
+
"gap-y",
|
|
212
|
+
["gap.row"],
|
|
213
|
+
1,
|
|
214
|
+
"spacing"
|
|
215
|
+
],
|
|
216
|
+
[
|
|
217
|
+
"rounded",
|
|
218
|
+
["radius"],
|
|
219
|
+
0,
|
|
220
|
+
"radius"
|
|
221
|
+
]
|
|
222
|
+
];
|
|
223
|
+
/** Splits `md:hover:px-4` into its variants and utility, ignoring colons inside `[...]` / `(...)`. */
|
|
224
|
+
function splitVariants(className) {
|
|
225
|
+
const parts = [];
|
|
226
|
+
let depth = 0;
|
|
227
|
+
let current = "";
|
|
228
|
+
for (const char of className) {
|
|
229
|
+
if (char === "[" || char === "(") depth++;
|
|
230
|
+
if (char === "]" || char === ")") depth--;
|
|
231
|
+
if (char === ":" && depth === 0) {
|
|
232
|
+
parts.push(current);
|
|
233
|
+
current = "";
|
|
234
|
+
} else current += char;
|
|
235
|
+
}
|
|
236
|
+
return {
|
|
237
|
+
variants: parts,
|
|
238
|
+
utility: current
|
|
239
|
+
};
|
|
240
|
+
}
|
|
241
|
+
/** Breakpoint weight when every variant is an active breakpoint; `undefined` for state variants or inactive breakpoints. */
|
|
242
|
+
function variantWeight(variants, viewportWidth, rootFontSize) {
|
|
243
|
+
let weight = 0;
|
|
244
|
+
for (const variant of variants) {
|
|
245
|
+
const max = variant.startsWith("max-");
|
|
246
|
+
const size = breakpoints[max ? variant.slice(4) : variant];
|
|
247
|
+
if (size === void 0) return void 0;
|
|
248
|
+
if (!(max ? viewportWidth < size * rootFontSize : viewportWidth >= size * rootFontSize)) return void 0;
|
|
249
|
+
weight = Math.max(weight, size);
|
|
250
|
+
}
|
|
251
|
+
return weight;
|
|
252
|
+
}
|
|
253
|
+
function tokenFor(value, namespace, isKnown) {
|
|
254
|
+
const referenced = value.match(/^\[.*?var\((--[\w-]+)/)?.[1] ?? value.match(/^\((--[\w-]+)\)$/)?.[1];
|
|
255
|
+
if (referenced) return isKnown(referenced) ? referenced : void 0;
|
|
256
|
+
const name = `--${namespace}-${value}`;
|
|
257
|
+
return isKnown(name) ? name : void 0;
|
|
258
|
+
}
|
|
259
|
+
/**
|
|
260
|
+
* Resolves which theme tokens drive an element's padding, gap and radius from its rendered Tailwind classes.
|
|
261
|
+
* Only tokens accepted by `isKnown` are returned, so every result can be opened in the editor.
|
|
262
|
+
*/
|
|
263
|
+
function inspectTokens(className, isKnown, viewportWidth = Infinity, rootFontSize = 16) {
|
|
264
|
+
const winners = /* @__PURE__ */ new Map();
|
|
265
|
+
for (const raw of className.split(/\s+/).filter(Boolean)) {
|
|
266
|
+
const { variants, utility } = splitVariants(raw);
|
|
267
|
+
const weight = variantWeight(variants, viewportWidth, rootFontSize);
|
|
268
|
+
if (weight === void 0) continue;
|
|
269
|
+
const clean = utility.replace(/^!|!$/g, "");
|
|
270
|
+
for (const [prefix, slots, specificity, namespace] of utilities) {
|
|
271
|
+
if (!clean.startsWith(`${prefix}-`)) continue;
|
|
272
|
+
const token = tokenFor(clean.slice(prefix.length + 1), namespace, isKnown);
|
|
273
|
+
if (!token) continue;
|
|
274
|
+
const rank = weight * 10 + specificity;
|
|
275
|
+
for (const slot of slots) if ((winners.get(slot)?.rank ?? -1) <= rank) winners.set(slot, {
|
|
276
|
+
token,
|
|
277
|
+
rank
|
|
278
|
+
});
|
|
279
|
+
}
|
|
280
|
+
}
|
|
281
|
+
const result = {
|
|
282
|
+
padding: {},
|
|
283
|
+
gap: {}
|
|
284
|
+
};
|
|
285
|
+
for (const [slot, { token }] of winners) if (slot === "radius") result.radius = token;
|
|
286
|
+
else if (slot.startsWith("gap.")) result.gap[slot.slice(4)] = token;
|
|
287
|
+
else result.padding[slot.slice(8)] = token;
|
|
288
|
+
return result;
|
|
289
|
+
}
|
|
290
|
+
//#endregion
|
|
291
|
+
//#region src/configurator/inspector/Inspector.tsx
|
|
292
|
+
const px = (value) => parseFloat(value) || 0;
|
|
293
|
+
const hasTokens = (tokens) => !!(tokens.radius || tokens.gap.row || tokens.gap.column || Object.keys(tokens.padding).length);
|
|
294
|
+
/** Devtools-style overlay: hover an element to see its token-driven padding, gaps and radius, click one to edit it. */
|
|
295
|
+
function Inspector({ isKnown, describe, onSelect, revision, children }) {
|
|
296
|
+
const stageRef = useRef(null);
|
|
297
|
+
const contentRef = useRef(null);
|
|
298
|
+
const [target, setTarget] = useState(null);
|
|
299
|
+
const [regions, setRegions] = useState([]);
|
|
300
|
+
const [outline, setOutline] = useState(null);
|
|
301
|
+
const [active, setActive] = useState(null);
|
|
302
|
+
const tokensOf = useCallback((element) => inspectTokens(typeof element.className === "string" ? element.className : "", isKnown, window.innerWidth, px(getComputedStyle(document.documentElement).fontSize) || 16), [isKnown]);
|
|
303
|
+
const measure = useCallback(() => {
|
|
304
|
+
const stage = stageRef.current;
|
|
305
|
+
if (!stage || !target || !target.isConnected) {
|
|
306
|
+
setRegions([]);
|
|
307
|
+
setOutline(null);
|
|
308
|
+
return;
|
|
309
|
+
}
|
|
310
|
+
const origin = stage.getBoundingClientRect();
|
|
311
|
+
const box = target.getBoundingClientRect();
|
|
312
|
+
const scale = target.offsetWidth ? box.width / target.offsetWidth : 1;
|
|
313
|
+
const style = getComputedStyle(target);
|
|
314
|
+
const tokens = tokensOf(target);
|
|
315
|
+
const left = box.left - origin.left;
|
|
316
|
+
const top = box.top - origin.top;
|
|
317
|
+
const border = {
|
|
318
|
+
top: px(style.borderTopWidth) * scale,
|
|
319
|
+
right: px(style.borderRightWidth) * scale,
|
|
320
|
+
bottom: px(style.borderBottomWidth) * scale,
|
|
321
|
+
left: px(style.borderLeftWidth) * scale
|
|
322
|
+
};
|
|
323
|
+
const pad = {
|
|
324
|
+
top: px(style.paddingTop) * scale,
|
|
325
|
+
right: px(style.paddingRight) * scale,
|
|
326
|
+
bottom: px(style.paddingBottom) * scale,
|
|
327
|
+
left: px(style.paddingLeft) * scale
|
|
328
|
+
};
|
|
329
|
+
const inner = {
|
|
330
|
+
x: left + border.left,
|
|
331
|
+
y: top + border.top,
|
|
332
|
+
width: box.width - border.left - border.right,
|
|
333
|
+
height: box.height - border.top - border.bottom
|
|
334
|
+
};
|
|
335
|
+
const next = [];
|
|
336
|
+
const add = (kind, token, key, x, y, width, height) => {
|
|
337
|
+
if (token && width > .5 && height > .5) next.push({
|
|
338
|
+
key,
|
|
339
|
+
kind,
|
|
340
|
+
token,
|
|
341
|
+
label: describe(token),
|
|
342
|
+
x,
|
|
343
|
+
y,
|
|
344
|
+
width,
|
|
345
|
+
height
|
|
346
|
+
});
|
|
347
|
+
};
|
|
348
|
+
add("padding", tokens.padding.top, "pt", inner.x, inner.y, inner.width, pad.top);
|
|
349
|
+
add("padding", tokens.padding.bottom, "pb", inner.x, inner.y + inner.height - pad.bottom, inner.width, pad.bottom);
|
|
350
|
+
add("padding", tokens.padding.left, "pl", inner.x, inner.y + pad.top, pad.left, inner.height - pad.top - pad.bottom);
|
|
351
|
+
add("padding", tokens.padding.right, "pr", inner.x + inner.width - pad.right, inner.y + pad.top, pad.right, inner.height - pad.top - pad.bottom);
|
|
352
|
+
if (tokens.gap.row || tokens.gap.column) {
|
|
353
|
+
const children_0 = [...target.children].map((child) => child.getBoundingClientRect()).filter((rect) => rect.width > 0 && rect.height > 0);
|
|
354
|
+
const contentTop = inner.y + pad.top;
|
|
355
|
+
const contentHeight = inner.height - pad.top - pad.bottom;
|
|
356
|
+
const contentLeft = inner.x + pad.left;
|
|
357
|
+
const contentWidth = inner.width - pad.left - pad.right;
|
|
358
|
+
children_0.slice(1).forEach((rect_0, index) => {
|
|
359
|
+
const previous = children_0[index];
|
|
360
|
+
if (rect_0.left >= previous.right - .5) add("gap", tokens.gap.column, `gx${index}`, previous.right - origin.left, contentTop, rect_0.left - previous.right, contentHeight);
|
|
361
|
+
else if (rect_0.top >= previous.bottom - .5) add("gap", tokens.gap.row, `gy${index}`, contentLeft, previous.bottom - origin.top, contentWidth, rect_0.top - previous.bottom);
|
|
362
|
+
});
|
|
363
|
+
}
|
|
364
|
+
if (tokens.radius && px(style.borderTopLeftRadius) > 0) {
|
|
365
|
+
const size = Math.min(12, box.width / 3, box.height / 3);
|
|
366
|
+
add("radius", tokens.radius, "r-tl", left, top, size, size);
|
|
367
|
+
add("radius", tokens.radius, "r-tr", left + box.width - size, top, size, size);
|
|
368
|
+
add("radius", tokens.radius, "r-bl", left, top + box.height - size, size, size);
|
|
369
|
+
add("radius", tokens.radius, "r-br", left + box.width - size, top + box.height - size, size, size);
|
|
370
|
+
}
|
|
371
|
+
setRegions(next);
|
|
372
|
+
setOutline({
|
|
373
|
+
x: left,
|
|
374
|
+
y: top,
|
|
375
|
+
width: box.width,
|
|
376
|
+
height: box.height
|
|
377
|
+
});
|
|
378
|
+
}, [
|
|
379
|
+
target,
|
|
380
|
+
tokensOf,
|
|
381
|
+
describe
|
|
382
|
+
]);
|
|
383
|
+
useLayoutEffect(measure, [measure, revision]);
|
|
384
|
+
useEffect(() => {
|
|
385
|
+
const stage_0 = stageRef.current;
|
|
386
|
+
if (!stage_0) return;
|
|
387
|
+
let frame = 0;
|
|
388
|
+
const schedule = () => {
|
|
389
|
+
cancelAnimationFrame(frame);
|
|
390
|
+
frame = requestAnimationFrame(measure);
|
|
391
|
+
};
|
|
392
|
+
const observer = new ResizeObserver(schedule);
|
|
393
|
+
observer.observe(stage_0);
|
|
394
|
+
if (target) observer.observe(target);
|
|
395
|
+
window.addEventListener("scroll", schedule, true);
|
|
396
|
+
return () => {
|
|
397
|
+
cancelAnimationFrame(frame);
|
|
398
|
+
observer.disconnect();
|
|
399
|
+
window.removeEventListener("scroll", schedule, true);
|
|
400
|
+
};
|
|
401
|
+
}, [measure, target]);
|
|
402
|
+
const onPointerMove = (event) => {
|
|
403
|
+
if (event.target.closest(".studio-inspect-region")) return;
|
|
404
|
+
const content = contentRef.current;
|
|
405
|
+
if (!content) return;
|
|
406
|
+
const hit = document.elementsFromPoint(event.clientX, event.clientY).find((element_0) => content.contains(element_0) && hasTokens(tokensOf(element_0)));
|
|
407
|
+
if (hit && hit !== target) setTarget(hit);
|
|
408
|
+
};
|
|
409
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
410
|
+
ref: stageRef,
|
|
411
|
+
className: "studio-inspect-stage",
|
|
412
|
+
onPointerMove,
|
|
413
|
+
children: [
|
|
414
|
+
/* @__PURE__ */ jsx("div", {
|
|
415
|
+
ref: contentRef,
|
|
416
|
+
className: "studio-inspect-content",
|
|
417
|
+
children
|
|
418
|
+
}),
|
|
419
|
+
/* @__PURE__ */ jsxs("div", {
|
|
420
|
+
className: "studio-inspect-layer",
|
|
421
|
+
"aria-label": "Token inspector",
|
|
422
|
+
children: [
|
|
423
|
+
outline && /* @__PURE__ */ jsx("div", {
|
|
424
|
+
className: "studio-inspect-outline",
|
|
425
|
+
style: {
|
|
426
|
+
left: outline.x,
|
|
427
|
+
top: outline.y,
|
|
428
|
+
width: outline.width,
|
|
429
|
+
height: outline.height
|
|
430
|
+
}
|
|
431
|
+
}),
|
|
432
|
+
regions.map((region) => /* @__PURE__ */ jsx("button", {
|
|
433
|
+
type: "button",
|
|
434
|
+
className: `studio-inspect-region is-${region.kind} ${active === region.token ? "is-active" : ""}`,
|
|
435
|
+
style: {
|
|
436
|
+
left: region.x,
|
|
437
|
+
top: region.y,
|
|
438
|
+
width: region.width,
|
|
439
|
+
height: region.height
|
|
440
|
+
},
|
|
441
|
+
"aria-label": `Edit ${region.kind} ${region.label}`,
|
|
442
|
+
title: region.label,
|
|
443
|
+
onPointerEnter: () => setActive(region.token),
|
|
444
|
+
onPointerLeave: () => setActive(null),
|
|
445
|
+
onClick: (event_0) => {
|
|
446
|
+
event_0.stopPropagation();
|
|
447
|
+
onSelect(region.token);
|
|
448
|
+
}
|
|
449
|
+
}, region.key)),
|
|
450
|
+
active && regions.some((region_1) => region_1.token === active) && /* @__PURE__ */ jsx(InspectLabel, {
|
|
451
|
+
region: regions.find((region_0) => region_0.token === active),
|
|
452
|
+
stageWidth: stageRef.current?.clientWidth ?? 0
|
|
453
|
+
})
|
|
454
|
+
]
|
|
455
|
+
}),
|
|
456
|
+
!target && /* @__PURE__ */ jsx("p", {
|
|
457
|
+
className: "studio-inspect-hint",
|
|
458
|
+
children: "Hover the component to see its paddings, gaps and radius."
|
|
459
|
+
})
|
|
460
|
+
]
|
|
461
|
+
});
|
|
462
|
+
}
|
|
463
|
+
function InspectLabel(t0) {
|
|
464
|
+
const $ = c(10);
|
|
465
|
+
const { region, stageWidth } = t0;
|
|
466
|
+
const left = Math.max(4, Math.min(region.x, stageWidth - 220));
|
|
467
|
+
const t1 = `studio-inspect-label is-${region.kind}`;
|
|
468
|
+
const t2 = Math.max(0, region.y - 24);
|
|
469
|
+
let t3;
|
|
470
|
+
if ($[0] !== left || $[1] !== t2) {
|
|
471
|
+
t3 = {
|
|
472
|
+
left,
|
|
473
|
+
top: t2
|
|
474
|
+
};
|
|
475
|
+
$[0] = left;
|
|
476
|
+
$[1] = t2;
|
|
477
|
+
$[2] = t3;
|
|
478
|
+
} else t3 = $[2];
|
|
479
|
+
let t4;
|
|
480
|
+
if ($[3] !== region.kind) {
|
|
481
|
+
t4 = /* @__PURE__ */ jsx("strong", { children: region.kind });
|
|
482
|
+
$[3] = region.kind;
|
|
483
|
+
$[4] = t4;
|
|
484
|
+
} else t4 = $[4];
|
|
485
|
+
let t5;
|
|
486
|
+
if ($[5] !== region.label || $[6] !== t1 || $[7] !== t3 || $[8] !== t4) {
|
|
487
|
+
t5 = /* @__PURE__ */ jsxs("div", {
|
|
488
|
+
className: t1,
|
|
489
|
+
style: t3,
|
|
490
|
+
children: [
|
|
491
|
+
t4,
|
|
492
|
+
" ",
|
|
493
|
+
region.label
|
|
494
|
+
]
|
|
495
|
+
});
|
|
496
|
+
$[5] = region.label;
|
|
497
|
+
$[6] = t1;
|
|
498
|
+
$[7] = t3;
|
|
499
|
+
$[8] = t4;
|
|
500
|
+
$[9] = t5;
|
|
501
|
+
} else t5 = $[9];
|
|
502
|
+
return t5;
|
|
503
|
+
}
|
|
504
|
+
//#endregion
|
|
505
|
+
//#region src/configurator/gallery/demos.tsx
|
|
506
|
+
const galleryGroups = [
|
|
507
|
+
"Buttons",
|
|
508
|
+
"Inputs",
|
|
509
|
+
"Selection",
|
|
510
|
+
"Files",
|
|
511
|
+
"Feedback",
|
|
512
|
+
"Text",
|
|
513
|
+
"Navigation",
|
|
514
|
+
"Overlays",
|
|
515
|
+
"Data"
|
|
516
|
+
];
|
|
517
|
+
const noop = () => {};
|
|
518
|
+
const menuItems = [
|
|
519
|
+
{
|
|
520
|
+
label: "Edit",
|
|
521
|
+
onAction: noop
|
|
522
|
+
},
|
|
523
|
+
{
|
|
524
|
+
label: "Duplicate",
|
|
525
|
+
onAction: noop
|
|
526
|
+
},
|
|
527
|
+
{
|
|
528
|
+
label: "Archive",
|
|
529
|
+
isDisabled: true,
|
|
530
|
+
onAction: noop
|
|
531
|
+
}
|
|
532
|
+
];
|
|
533
|
+
const eventItems = [
|
|
534
|
+
{
|
|
535
|
+
id: "1",
|
|
536
|
+
label: "Roundtable"
|
|
537
|
+
},
|
|
538
|
+
{
|
|
539
|
+
id: "2",
|
|
540
|
+
label: "Conference"
|
|
541
|
+
},
|
|
542
|
+
{
|
|
543
|
+
id: "3",
|
|
544
|
+
label: "Meeting"
|
|
545
|
+
},
|
|
546
|
+
{
|
|
547
|
+
id: "4",
|
|
548
|
+
label: "Party"
|
|
549
|
+
},
|
|
550
|
+
{
|
|
551
|
+
id: "5",
|
|
552
|
+
label: "Disabled item",
|
|
553
|
+
isDisabled: true
|
|
554
|
+
}
|
|
555
|
+
];
|
|
556
|
+
const airportItems = Array.from({ length: 12 }, (_, index) => ({
|
|
557
|
+
id: `airport-${index + 1}`,
|
|
558
|
+
label: `Airport ${String(index + 1).padStart(3, "0")}`
|
|
559
|
+
}));
|
|
560
|
+
const groupOptions = [
|
|
561
|
+
{
|
|
562
|
+
label: "Option 1",
|
|
563
|
+
value: "option-1"
|
|
564
|
+
},
|
|
565
|
+
{
|
|
566
|
+
label: "Option 2",
|
|
567
|
+
value: "option-2"
|
|
568
|
+
},
|
|
569
|
+
{
|
|
570
|
+
label: "Option 3",
|
|
571
|
+
value: "option-3"
|
|
572
|
+
}
|
|
573
|
+
];
|
|
574
|
+
const accordionContent = /* @__PURE__ */ jsx("p", {
|
|
575
|
+
className: "text-text-default-2",
|
|
576
|
+
children: "This is the content of the accordion item. It can contain any React elements."
|
|
577
|
+
});
|
|
578
|
+
const accordionItems = [
|
|
579
|
+
{
|
|
580
|
+
id: "item1",
|
|
581
|
+
heading: "What is your refund policy?",
|
|
582
|
+
subheading: "Returns & exchanges",
|
|
583
|
+
icon: Info,
|
|
584
|
+
children: accordionContent
|
|
585
|
+
},
|
|
586
|
+
{
|
|
587
|
+
id: "item2",
|
|
588
|
+
heading: "How do I track my order?",
|
|
589
|
+
subheading: "Shipping info",
|
|
590
|
+
icon: Info,
|
|
591
|
+
children: accordionContent
|
|
592
|
+
},
|
|
593
|
+
{
|
|
594
|
+
id: "item3",
|
|
595
|
+
heading: "Do you offer international shipping?",
|
|
596
|
+
subheading: "Global delivery",
|
|
597
|
+
icon: Info,
|
|
598
|
+
children: accordionContent
|
|
599
|
+
}
|
|
600
|
+
];
|
|
601
|
+
const steps = [
|
|
602
|
+
{
|
|
603
|
+
id: "1",
|
|
604
|
+
title: "Account",
|
|
605
|
+
subtext: "Create your account"
|
|
606
|
+
},
|
|
607
|
+
{
|
|
608
|
+
id: "2",
|
|
609
|
+
title: "Profile",
|
|
610
|
+
subtext: "Tell us about yourself"
|
|
611
|
+
},
|
|
612
|
+
{
|
|
613
|
+
id: "3",
|
|
614
|
+
title: "Review",
|
|
615
|
+
subtext: "Review your details"
|
|
616
|
+
}
|
|
617
|
+
];
|
|
618
|
+
const tableRows = [
|
|
619
|
+
{
|
|
620
|
+
name: "Ada Lovelace",
|
|
621
|
+
email: "ada@example.com",
|
|
622
|
+
role: "Admin"
|
|
623
|
+
},
|
|
624
|
+
{
|
|
625
|
+
name: "Alan Turing",
|
|
626
|
+
email: "alan@example.com",
|
|
627
|
+
role: "Editor"
|
|
628
|
+
},
|
|
629
|
+
{
|
|
630
|
+
name: "Grace Hopper",
|
|
631
|
+
email: "grace@example.com",
|
|
632
|
+
role: "Viewer"
|
|
633
|
+
},
|
|
634
|
+
{
|
|
635
|
+
name: "Linus Torvalds",
|
|
636
|
+
email: "linus@example.com",
|
|
637
|
+
role: "Editor"
|
|
638
|
+
}
|
|
639
|
+
];
|
|
640
|
+
const tableColumns = [
|
|
641
|
+
{
|
|
642
|
+
accessorKey: "name",
|
|
643
|
+
header: "Name",
|
|
644
|
+
enableSorting: false
|
|
645
|
+
},
|
|
646
|
+
{
|
|
647
|
+
accessorKey: "email",
|
|
648
|
+
header: "Email",
|
|
649
|
+
enableSorting: false
|
|
650
|
+
},
|
|
651
|
+
{
|
|
652
|
+
accessorKey: "role",
|
|
653
|
+
header: "Role",
|
|
654
|
+
enableSorting: false
|
|
655
|
+
}
|
|
656
|
+
];
|
|
657
|
+
function ToggleGroupDemo() {
|
|
658
|
+
const $ = c(11);
|
|
659
|
+
const [value, setValue] = useState("option1");
|
|
660
|
+
let t0;
|
|
661
|
+
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
662
|
+
t0 = ["bold"];
|
|
663
|
+
$[0] = t0;
|
|
664
|
+
} else t0 = $[0];
|
|
665
|
+
const [format, setFormat] = useState(t0);
|
|
666
|
+
let t1;
|
|
667
|
+
if ($[1] === Symbol.for("react.memo_cache_sentinel")) {
|
|
668
|
+
t1 = [
|
|
669
|
+
{
|
|
670
|
+
id: "option1",
|
|
671
|
+
label: "Option 1"
|
|
672
|
+
},
|
|
673
|
+
{
|
|
674
|
+
id: "option2",
|
|
675
|
+
label: "Option 2"
|
|
676
|
+
},
|
|
677
|
+
{
|
|
678
|
+
id: "option3",
|
|
679
|
+
label: "Option 3"
|
|
680
|
+
}
|
|
681
|
+
];
|
|
682
|
+
$[1] = t1;
|
|
683
|
+
} else t1 = $[1];
|
|
684
|
+
let t2;
|
|
685
|
+
if ($[2] !== value) {
|
|
686
|
+
t2 = /* @__PURE__ */ jsx(ToggleGroup, {
|
|
687
|
+
"aria-label": "View",
|
|
688
|
+
items: t1,
|
|
689
|
+
value,
|
|
690
|
+
onChange: setValue
|
|
691
|
+
});
|
|
692
|
+
$[2] = value;
|
|
693
|
+
$[3] = t2;
|
|
694
|
+
} else t2 = $[3];
|
|
695
|
+
let t3;
|
|
696
|
+
if ($[4] === Symbol.for("react.memo_cache_sentinel")) {
|
|
697
|
+
t3 = /* @__PURE__ */ jsx(ToggleGroup, {
|
|
698
|
+
"aria-label": "Send options",
|
|
699
|
+
items: [{
|
|
700
|
+
id: "calendar",
|
|
701
|
+
label: "Calendar",
|
|
702
|
+
icon: Calendar
|
|
703
|
+
}, {
|
|
704
|
+
id: "send",
|
|
705
|
+
label: "Send",
|
|
706
|
+
icon: Send
|
|
707
|
+
}],
|
|
708
|
+
defaultValue: "calendar"
|
|
709
|
+
});
|
|
710
|
+
$[4] = t3;
|
|
711
|
+
} else t3 = $[4];
|
|
712
|
+
let t4;
|
|
713
|
+
if ($[5] === Symbol.for("react.memo_cache_sentinel")) {
|
|
714
|
+
t4 = [
|
|
715
|
+
{
|
|
716
|
+
id: "bold",
|
|
717
|
+
label: "Bold",
|
|
718
|
+
icon: Bold,
|
|
719
|
+
iconOnly: true
|
|
720
|
+
},
|
|
721
|
+
{
|
|
722
|
+
id: "italic",
|
|
723
|
+
label: "Italic",
|
|
724
|
+
icon: Italic,
|
|
725
|
+
iconOnly: true
|
|
726
|
+
},
|
|
727
|
+
{
|
|
728
|
+
id: "underline",
|
|
729
|
+
label: "Underline",
|
|
730
|
+
icon: Underline,
|
|
731
|
+
iconOnly: true
|
|
732
|
+
}
|
|
733
|
+
];
|
|
734
|
+
$[5] = t4;
|
|
735
|
+
} else t4 = $[5];
|
|
736
|
+
let t5;
|
|
737
|
+
if ($[6] !== format) {
|
|
738
|
+
t5 = /* @__PURE__ */ jsx(ToggleGroup, {
|
|
739
|
+
"aria-label": "Formatting",
|
|
740
|
+
selectionMode: "multiple",
|
|
741
|
+
items: t4,
|
|
742
|
+
value: format,
|
|
743
|
+
onChange: setFormat
|
|
744
|
+
});
|
|
745
|
+
$[6] = format;
|
|
746
|
+
$[7] = t5;
|
|
747
|
+
} else t5 = $[7];
|
|
748
|
+
let t6;
|
|
749
|
+
if ($[8] !== t2 || $[9] !== t5) {
|
|
750
|
+
t6 = /* @__PURE__ */ jsxs("div", {
|
|
751
|
+
className: "flex flex-col items-start gap-3",
|
|
752
|
+
children: [
|
|
753
|
+
t2,
|
|
754
|
+
t3,
|
|
755
|
+
t5
|
|
756
|
+
]
|
|
757
|
+
});
|
|
758
|
+
$[8] = t2;
|
|
759
|
+
$[9] = t5;
|
|
760
|
+
$[10] = t6;
|
|
761
|
+
} else t6 = $[10];
|
|
762
|
+
return t6;
|
|
763
|
+
}
|
|
764
|
+
function CheckboxGroupDemo() {
|
|
765
|
+
const $ = c(3);
|
|
766
|
+
let t0;
|
|
767
|
+
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
768
|
+
t0 = ["option-2"];
|
|
769
|
+
$[0] = t0;
|
|
770
|
+
} else t0 = $[0];
|
|
771
|
+
const [value, setValue] = useState(t0);
|
|
772
|
+
let t1;
|
|
773
|
+
if ($[1] !== value) {
|
|
774
|
+
t1 = /* @__PURE__ */ jsx(CheckboxGroup, {
|
|
775
|
+
label: "Checkbox group",
|
|
776
|
+
options: groupOptions,
|
|
777
|
+
value,
|
|
778
|
+
onChange: setValue
|
|
779
|
+
});
|
|
780
|
+
$[1] = value;
|
|
781
|
+
$[2] = t1;
|
|
782
|
+
} else t1 = $[2];
|
|
783
|
+
return t1;
|
|
784
|
+
}
|
|
785
|
+
function RadioGroupDemo() {
|
|
786
|
+
const $ = c(2);
|
|
787
|
+
const [value, setValue] = useState("option-1");
|
|
788
|
+
let t0;
|
|
789
|
+
if ($[0] !== value) {
|
|
790
|
+
t0 = /* @__PURE__ */ jsx(RadioGroup, {
|
|
791
|
+
label: "Radio group",
|
|
792
|
+
options: groupOptions,
|
|
793
|
+
value,
|
|
794
|
+
onChange: setValue
|
|
795
|
+
});
|
|
796
|
+
$[0] = value;
|
|
797
|
+
$[1] = t0;
|
|
798
|
+
} else t0 = $[1];
|
|
799
|
+
return t0;
|
|
800
|
+
}
|
|
801
|
+
function SelectDemo() {
|
|
802
|
+
const $ = c(8);
|
|
803
|
+
const [value, setValue] = useState("2");
|
|
804
|
+
let t0;
|
|
805
|
+
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
806
|
+
t0 = ["1", "3"];
|
|
807
|
+
$[0] = t0;
|
|
808
|
+
} else t0 = $[0];
|
|
809
|
+
const [multi, setMulti] = useState(t0);
|
|
810
|
+
let t1;
|
|
811
|
+
if ($[1] !== value) {
|
|
812
|
+
t1 = /* @__PURE__ */ jsx(Select, {
|
|
813
|
+
label: "Event type",
|
|
814
|
+
placeholder: "Ex.: Roundtable",
|
|
815
|
+
items: eventItems,
|
|
816
|
+
value,
|
|
817
|
+
onChange: setValue
|
|
818
|
+
});
|
|
819
|
+
$[1] = value;
|
|
820
|
+
$[2] = t1;
|
|
821
|
+
} else t1 = $[2];
|
|
822
|
+
let t2;
|
|
823
|
+
if ($[3] !== multi) {
|
|
824
|
+
t2 = /* @__PURE__ */ jsx(Select, {
|
|
825
|
+
label: "Event types",
|
|
826
|
+
placeholder: "Select several",
|
|
827
|
+
selectionMode: "multiple",
|
|
828
|
+
items: eventItems,
|
|
829
|
+
value: multi,
|
|
830
|
+
onChange: setMulti
|
|
831
|
+
});
|
|
832
|
+
$[3] = multi;
|
|
833
|
+
$[4] = t2;
|
|
834
|
+
} else t2 = $[4];
|
|
835
|
+
let t3;
|
|
836
|
+
if ($[5] !== t1 || $[6] !== t2) {
|
|
837
|
+
t3 = /* @__PURE__ */ jsxs("div", {
|
|
838
|
+
className: "flex flex-col gap-4",
|
|
839
|
+
children: [t1, t2]
|
|
840
|
+
});
|
|
841
|
+
$[5] = t1;
|
|
842
|
+
$[6] = t2;
|
|
843
|
+
$[7] = t3;
|
|
844
|
+
} else t3 = $[7];
|
|
845
|
+
return t3;
|
|
846
|
+
}
|
|
847
|
+
function AutocompleteDemo() {
|
|
848
|
+
const $ = c(2);
|
|
849
|
+
const [value, setValue] = useState(null);
|
|
850
|
+
let t0;
|
|
851
|
+
if ($[0] !== value) {
|
|
852
|
+
t0 = /* @__PURE__ */ jsx(Autocomplete, {
|
|
853
|
+
label: "Airport",
|
|
854
|
+
placeholder: "Choose an airport",
|
|
855
|
+
items: airportItems,
|
|
856
|
+
value,
|
|
857
|
+
onChange: setValue
|
|
858
|
+
});
|
|
859
|
+
$[0] = value;
|
|
860
|
+
$[1] = t0;
|
|
861
|
+
} else t0 = $[1];
|
|
862
|
+
return t0;
|
|
863
|
+
}
|
|
864
|
+
function DatePickerDemo() {
|
|
865
|
+
const $ = c(2);
|
|
866
|
+
const [value, setValue] = useState(null);
|
|
867
|
+
let t0;
|
|
868
|
+
if ($[0] !== value) {
|
|
869
|
+
t0 = /* @__PURE__ */ jsx(DatePicker, {
|
|
870
|
+
label: "Date",
|
|
871
|
+
value,
|
|
872
|
+
onChange: setValue
|
|
873
|
+
});
|
|
874
|
+
$[0] = value;
|
|
875
|
+
$[1] = t0;
|
|
876
|
+
} else t0 = $[1];
|
|
877
|
+
return t0;
|
|
878
|
+
}
|
|
879
|
+
function TimePickerDemo() {
|
|
880
|
+
const $ = c(2);
|
|
881
|
+
const [value, setValue] = useState(null);
|
|
882
|
+
let t0;
|
|
883
|
+
if ($[0] !== value) {
|
|
884
|
+
t0 = /* @__PURE__ */ jsx(TimePicker, {
|
|
885
|
+
label: "Time",
|
|
886
|
+
value,
|
|
887
|
+
onChange: setValue
|
|
888
|
+
});
|
|
889
|
+
$[0] = value;
|
|
890
|
+
$[1] = t0;
|
|
891
|
+
} else t0 = $[1];
|
|
892
|
+
return t0;
|
|
893
|
+
}
|
|
894
|
+
function PaginationDemo() {
|
|
895
|
+
const $ = c(4);
|
|
896
|
+
const [page, setPage] = useState(1);
|
|
897
|
+
const [pageSize, setPageSize] = useState(10);
|
|
898
|
+
let t0;
|
|
899
|
+
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
900
|
+
t0 = (size) => {
|
|
901
|
+
setPageSize(size);
|
|
902
|
+
setPage(1);
|
|
903
|
+
};
|
|
904
|
+
$[0] = t0;
|
|
905
|
+
} else t0 = $[0];
|
|
906
|
+
let t1;
|
|
907
|
+
if ($[1] !== page || $[2] !== pageSize) {
|
|
908
|
+
t1 = /* @__PURE__ */ jsx(Pagination, {
|
|
909
|
+
page,
|
|
910
|
+
pageSize,
|
|
911
|
+
totalItems: 100,
|
|
912
|
+
hideFirstLast: true,
|
|
913
|
+
onPageChange: setPage,
|
|
914
|
+
onPageSizeChange: t0
|
|
915
|
+
});
|
|
916
|
+
$[1] = page;
|
|
917
|
+
$[2] = pageSize;
|
|
918
|
+
$[3] = t1;
|
|
919
|
+
} else t1 = $[3];
|
|
920
|
+
return t1;
|
|
921
|
+
}
|
|
922
|
+
function DialogDemo() {
|
|
923
|
+
const $ = c(19);
|
|
924
|
+
const ui = UIConfig.useConfig();
|
|
925
|
+
const dialogMainCva = UIOverrides.useCva("dialog.mainCva", dialogMainDefinition);
|
|
926
|
+
const dialogContentCva = UIOverrides.useCva("dialog.contentCva", dialogContentDefinition);
|
|
927
|
+
let t0;
|
|
928
|
+
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
929
|
+
t0 = /* @__PURE__ */ jsx(Button, { children: "Open dialog" });
|
|
930
|
+
$[0] = t0;
|
|
931
|
+
} else t0 = $[0];
|
|
932
|
+
let t1;
|
|
933
|
+
if ($[1] !== dialogMainCva) {
|
|
934
|
+
t1 = dialogMainCva({});
|
|
935
|
+
$[1] = dialogMainCva;
|
|
936
|
+
$[2] = t1;
|
|
937
|
+
} else t1 = $[2];
|
|
938
|
+
let t2;
|
|
939
|
+
if ($[3] !== dialogContentCva) {
|
|
940
|
+
t2 = dialogContentCva({});
|
|
941
|
+
$[3] = dialogContentCva;
|
|
942
|
+
$[4] = t2;
|
|
943
|
+
} else t2 = $[4];
|
|
944
|
+
let t3;
|
|
945
|
+
if ($[5] !== ui.alertDialog.titleTypography) {
|
|
946
|
+
t3 = /* @__PURE__ */ jsx(Typography, {
|
|
947
|
+
...ui.alertDialog.titleTypography,
|
|
948
|
+
as: "h2",
|
|
949
|
+
className: "text-surface-default-card-foreground",
|
|
950
|
+
children: "Delete project?"
|
|
951
|
+
});
|
|
952
|
+
$[5] = ui.alertDialog.titleTypography;
|
|
953
|
+
$[6] = t3;
|
|
954
|
+
} else t3 = $[6];
|
|
955
|
+
let t4;
|
|
956
|
+
if ($[7] !== ui.alertDialog.descriptionTypography) {
|
|
957
|
+
t4 = /* @__PURE__ */ jsx(Typography, {
|
|
958
|
+
...ui.alertDialog.descriptionTypography,
|
|
959
|
+
className: "text-surface-default-card-foreground",
|
|
960
|
+
children: "This will permanently remove the project and all of its files. This action cannot be undone."
|
|
961
|
+
});
|
|
962
|
+
$[7] = ui.alertDialog.descriptionTypography;
|
|
963
|
+
$[8] = t4;
|
|
964
|
+
} else t4 = $[8];
|
|
965
|
+
let t5;
|
|
966
|
+
if ($[9] !== t3 || $[10] !== t4) {
|
|
967
|
+
t5 = /* @__PURE__ */ jsxs("div", {
|
|
968
|
+
className: "flex flex-col gap-modal-gap-text",
|
|
969
|
+
children: [t3, t4]
|
|
970
|
+
});
|
|
971
|
+
$[9] = t3;
|
|
972
|
+
$[10] = t4;
|
|
973
|
+
$[11] = t5;
|
|
974
|
+
} else t5 = $[11];
|
|
975
|
+
let t6;
|
|
976
|
+
if ($[12] === Symbol.for("react.memo_cache_sentinel")) {
|
|
977
|
+
t6 = /* @__PURE__ */ jsxs("div", {
|
|
978
|
+
className: "flex w-full flex-wrap gap-modal-gap-buttons pt-1",
|
|
979
|
+
children: [/* @__PURE__ */ jsx(Button, {
|
|
980
|
+
color: "secondary",
|
|
981
|
+
width: "fill",
|
|
982
|
+
className: "min-w-40 flex-1 shrink-0",
|
|
983
|
+
children: "Cancel"
|
|
984
|
+
}), /* @__PURE__ */ jsx(Button, {
|
|
985
|
+
width: "fill",
|
|
986
|
+
className: "min-w-40 flex-1 shrink-0",
|
|
987
|
+
children: "Delete"
|
|
988
|
+
})]
|
|
989
|
+
});
|
|
990
|
+
$[12] = t6;
|
|
991
|
+
} else t6 = $[12];
|
|
992
|
+
let t7;
|
|
993
|
+
if ($[13] !== t2 || $[14] !== t5) {
|
|
994
|
+
t7 = /* @__PURE__ */ jsxs("div", {
|
|
995
|
+
"aria-label": "Delete project",
|
|
996
|
+
className: t2,
|
|
997
|
+
children: [t5, t6]
|
|
998
|
+
});
|
|
999
|
+
$[13] = t2;
|
|
1000
|
+
$[14] = t5;
|
|
1001
|
+
$[15] = t7;
|
|
1002
|
+
} else t7 = $[15];
|
|
1003
|
+
let t8;
|
|
1004
|
+
if ($[16] !== t1 || $[17] !== t7) {
|
|
1005
|
+
t8 = /* @__PURE__ */ jsxs("div", {
|
|
1006
|
+
className: "flex flex-col items-start gap-3",
|
|
1007
|
+
children: [t0, /* @__PURE__ */ jsx("div", {
|
|
1008
|
+
className: t1,
|
|
1009
|
+
children: t7
|
|
1010
|
+
})]
|
|
1011
|
+
});
|
|
1012
|
+
$[16] = t1;
|
|
1013
|
+
$[17] = t7;
|
|
1014
|
+
$[18] = t8;
|
|
1015
|
+
} else t8 = $[18];
|
|
1016
|
+
return t8;
|
|
1017
|
+
}
|
|
1018
|
+
function PopoverDemo() {
|
|
1019
|
+
const $ = c(6);
|
|
1020
|
+
const popoverCva = UIOverrides.useCva("popover.cva", popoverDefinition);
|
|
1021
|
+
let t0;
|
|
1022
|
+
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
1023
|
+
t0 = /* @__PURE__ */ jsx(Button, {
|
|
1024
|
+
endIcon: ChevronDown,
|
|
1025
|
+
children: "Open popover"
|
|
1026
|
+
});
|
|
1027
|
+
$[0] = t0;
|
|
1028
|
+
} else t0 = $[0];
|
|
1029
|
+
let t1;
|
|
1030
|
+
if ($[1] !== popoverCva) {
|
|
1031
|
+
t1 = popoverCva({});
|
|
1032
|
+
$[1] = popoverCva;
|
|
1033
|
+
$[2] = t1;
|
|
1034
|
+
} else t1 = $[2];
|
|
1035
|
+
const t2 = `${t1} overflow-hidden p-2`;
|
|
1036
|
+
let t3;
|
|
1037
|
+
if ($[3] === Symbol.for("react.memo_cache_sentinel")) {
|
|
1038
|
+
t3 = /* @__PURE__ */ jsxs("div", {
|
|
1039
|
+
className: "flex flex-col gap-2",
|
|
1040
|
+
children: [
|
|
1041
|
+
/* @__PURE__ */ jsx(Typography, {
|
|
1042
|
+
size: "body",
|
|
1043
|
+
className: "font-bold",
|
|
1044
|
+
children: "Popover title"
|
|
1045
|
+
}),
|
|
1046
|
+
/* @__PURE__ */ jsx(Typography, {
|
|
1047
|
+
size: "small",
|
|
1048
|
+
children: "Popovers show rich content anchored to a trigger element."
|
|
1049
|
+
}),
|
|
1050
|
+
/* @__PURE__ */ jsx(TextButton, {
|
|
1051
|
+
size: "sm",
|
|
1052
|
+
children: "Learn more"
|
|
1053
|
+
})
|
|
1054
|
+
]
|
|
1055
|
+
});
|
|
1056
|
+
$[3] = t3;
|
|
1057
|
+
} else t3 = $[3];
|
|
1058
|
+
let t4;
|
|
1059
|
+
if ($[4] !== t2) {
|
|
1060
|
+
t4 = /* @__PURE__ */ jsxs("div", {
|
|
1061
|
+
className: "flex flex-col items-start",
|
|
1062
|
+
children: [t0, /* @__PURE__ */ jsx("div", {
|
|
1063
|
+
className: "my-4 w-72 outline-none",
|
|
1064
|
+
children: /* @__PURE__ */ jsx("div", {
|
|
1065
|
+
"aria-label": "Popover",
|
|
1066
|
+
className: "outline-none",
|
|
1067
|
+
children: /* @__PURE__ */ jsx("div", {
|
|
1068
|
+
className: t2,
|
|
1069
|
+
children: t3
|
|
1070
|
+
})
|
|
1071
|
+
})
|
|
1072
|
+
})]
|
|
1073
|
+
});
|
|
1074
|
+
$[4] = t2;
|
|
1075
|
+
$[5] = t4;
|
|
1076
|
+
} else t4 = $[5];
|
|
1077
|
+
return t4;
|
|
1078
|
+
}
|
|
1079
|
+
function DropdownMenuDemo() {
|
|
1080
|
+
const $ = c(19);
|
|
1081
|
+
const menuPopoverCva = UIOverrides.useCva("dropdownMenu.popoverCva", menuPopoverDefinition);
|
|
1082
|
+
const menuPopoverWrapperCva = UIOverrides.useCva("dropdownMenu.popoverWrapperCva", menuPopoverWrapperDefinition);
|
|
1083
|
+
const menuCva = UIOverrides.useCva("dropdownMenu.cva", dropdownMenuDefinition);
|
|
1084
|
+
const menuItemCva = UIOverrides.useCva("dropdownMenu.itemCva", menuItemDefinition);
|
|
1085
|
+
let t0;
|
|
1086
|
+
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
1087
|
+
t0 = [
|
|
1088
|
+
{ label: "Profile" },
|
|
1089
|
+
{ label: "Settings" },
|
|
1090
|
+
{
|
|
1091
|
+
label: "More options",
|
|
1092
|
+
submenu: true
|
|
1093
|
+
},
|
|
1094
|
+
{
|
|
1095
|
+
label: "Disabled item",
|
|
1096
|
+
disabled: true
|
|
1097
|
+
}
|
|
1098
|
+
];
|
|
1099
|
+
$[0] = t0;
|
|
1100
|
+
} else t0 = $[0];
|
|
1101
|
+
const items = t0;
|
|
1102
|
+
let t1;
|
|
1103
|
+
if ($[1] === Symbol.for("react.memo_cache_sentinel")) {
|
|
1104
|
+
t1 = /* @__PURE__ */ jsx(BadgeButton, {
|
|
1105
|
+
icon: Settings,
|
|
1106
|
+
children: "Open menu"
|
|
1107
|
+
});
|
|
1108
|
+
$[1] = t1;
|
|
1109
|
+
} else t1 = $[1];
|
|
1110
|
+
let t2;
|
|
1111
|
+
if ($[2] !== menuPopoverCva) {
|
|
1112
|
+
t2 = menuPopoverCva({});
|
|
1113
|
+
$[2] = menuPopoverCva;
|
|
1114
|
+
$[3] = t2;
|
|
1115
|
+
} else t2 = $[3];
|
|
1116
|
+
const t3 = `${t2} w-56`;
|
|
1117
|
+
let t4;
|
|
1118
|
+
if ($[4] !== menuPopoverWrapperCva) {
|
|
1119
|
+
t4 = menuPopoverWrapperCva({});
|
|
1120
|
+
$[4] = menuPopoverWrapperCva;
|
|
1121
|
+
$[5] = t4;
|
|
1122
|
+
} else t4 = $[5];
|
|
1123
|
+
let t5;
|
|
1124
|
+
if ($[6] !== menuCva) {
|
|
1125
|
+
t5 = menuCva({ isMobile: false });
|
|
1126
|
+
$[6] = menuCva;
|
|
1127
|
+
$[7] = t5;
|
|
1128
|
+
} else t5 = $[7];
|
|
1129
|
+
let t6;
|
|
1130
|
+
if ($[8] !== menuItemCva) {
|
|
1131
|
+
t6 = items.map((item) => /* @__PURE__ */ jsxs("div", {
|
|
1132
|
+
"aria-disabled": item.disabled || void 0,
|
|
1133
|
+
"data-disabled": item.disabled || void 0,
|
|
1134
|
+
"data-has-submenu": item.submenu || void 0,
|
|
1135
|
+
className: menuItemCva({ isMobile: false }),
|
|
1136
|
+
children: [item.label, item.submenu && /* @__PURE__ */ jsx(ArrowRight, { className: "size-6" })]
|
|
1137
|
+
}, item.label));
|
|
1138
|
+
$[8] = menuItemCva;
|
|
1139
|
+
$[9] = t6;
|
|
1140
|
+
} else t6 = $[9];
|
|
1141
|
+
let t7;
|
|
1142
|
+
if ($[10] !== t5 || $[11] !== t6) {
|
|
1143
|
+
t7 = /* @__PURE__ */ jsx("div", {
|
|
1144
|
+
className: t5,
|
|
1145
|
+
children: t6
|
|
1146
|
+
});
|
|
1147
|
+
$[10] = t5;
|
|
1148
|
+
$[11] = t6;
|
|
1149
|
+
$[12] = t7;
|
|
1150
|
+
} else t7 = $[12];
|
|
1151
|
+
let t8;
|
|
1152
|
+
if ($[13] !== t4 || $[14] !== t7) {
|
|
1153
|
+
t8 = /* @__PURE__ */ jsx("div", {
|
|
1154
|
+
className: t4,
|
|
1155
|
+
children: t7
|
|
1156
|
+
});
|
|
1157
|
+
$[13] = t4;
|
|
1158
|
+
$[14] = t7;
|
|
1159
|
+
$[15] = t8;
|
|
1160
|
+
} else t8 = $[15];
|
|
1161
|
+
let t9;
|
|
1162
|
+
if ($[16] !== t3 || $[17] !== t8) {
|
|
1163
|
+
t9 = /* @__PURE__ */ jsxs("div", {
|
|
1164
|
+
className: "flex flex-col items-start",
|
|
1165
|
+
children: [t1, /* @__PURE__ */ jsx("div", {
|
|
1166
|
+
className: t3,
|
|
1167
|
+
children: t8
|
|
1168
|
+
})]
|
|
1169
|
+
});
|
|
1170
|
+
$[16] = t3;
|
|
1171
|
+
$[17] = t8;
|
|
1172
|
+
$[18] = t9;
|
|
1173
|
+
} else t9 = $[18];
|
|
1174
|
+
return t9;
|
|
1175
|
+
}
|
|
1176
|
+
function TooltipDemo() {
|
|
1177
|
+
const $ = c(19);
|
|
1178
|
+
const tooltipCva = UIOverrides.useCva("tooltip.cva", tooltipDefinition);
|
|
1179
|
+
const tooltipPointerCva = UIOverrides.useCva("tooltip.pointerHorizontalCva", tooltipPointerHorizontalDefinition);
|
|
1180
|
+
const tooltipTextCva = UIOverrides.useCva("tooltip.textCva", tooltipTextDefinition);
|
|
1181
|
+
let t0;
|
|
1182
|
+
if ($[0] !== tooltipCva) {
|
|
1183
|
+
t0 = tooltipCva({});
|
|
1184
|
+
$[0] = tooltipCva;
|
|
1185
|
+
$[1] = t0;
|
|
1186
|
+
} else t0 = $[1];
|
|
1187
|
+
let t1;
|
|
1188
|
+
if ($[2] !== tooltipTextCva) {
|
|
1189
|
+
t1 = tooltipTextCva({});
|
|
1190
|
+
$[2] = tooltipTextCva;
|
|
1191
|
+
$[3] = t1;
|
|
1192
|
+
} else t1 = $[3];
|
|
1193
|
+
const t2 = `${t1} font-bold`;
|
|
1194
|
+
let t3;
|
|
1195
|
+
if ($[4] !== t2) {
|
|
1196
|
+
t3 = /* @__PURE__ */ jsx(Typography, {
|
|
1197
|
+
size: "small",
|
|
1198
|
+
className: t2,
|
|
1199
|
+
children: "Tooltip text"
|
|
1200
|
+
});
|
|
1201
|
+
$[4] = t2;
|
|
1202
|
+
$[5] = t3;
|
|
1203
|
+
} else t3 = $[5];
|
|
1204
|
+
let t4;
|
|
1205
|
+
if ($[6] !== t0 || $[7] !== t3) {
|
|
1206
|
+
t4 = /* @__PURE__ */ jsx("div", {
|
|
1207
|
+
className: t0,
|
|
1208
|
+
children: t3
|
|
1209
|
+
});
|
|
1210
|
+
$[6] = t0;
|
|
1211
|
+
$[7] = t3;
|
|
1212
|
+
$[8] = t4;
|
|
1213
|
+
} else t4 = $[8];
|
|
1214
|
+
let t5;
|
|
1215
|
+
if ($[9] !== tooltipPointerCva) {
|
|
1216
|
+
t5 = tooltipPointerCva({});
|
|
1217
|
+
$[9] = tooltipPointerCva;
|
|
1218
|
+
$[10] = t5;
|
|
1219
|
+
} else t5 = $[10];
|
|
1220
|
+
let t6;
|
|
1221
|
+
if ($[11] !== t5) {
|
|
1222
|
+
t6 = /* @__PURE__ */ jsx(ChevronUp, {
|
|
1223
|
+
className: t5,
|
|
1224
|
+
fill: "currentColor",
|
|
1225
|
+
strokeWidth: 0,
|
|
1226
|
+
"aria-hidden": "true"
|
|
1227
|
+
});
|
|
1228
|
+
$[11] = t5;
|
|
1229
|
+
$[12] = t6;
|
|
1230
|
+
} else t6 = $[12];
|
|
1231
|
+
let t7;
|
|
1232
|
+
if ($[13] !== t4 || $[14] !== t6) {
|
|
1233
|
+
t7 = /* @__PURE__ */ jsxs("div", {
|
|
1234
|
+
className: "group flex flex-col items-center",
|
|
1235
|
+
"data-placement": "top",
|
|
1236
|
+
children: [t4, t6]
|
|
1237
|
+
});
|
|
1238
|
+
$[13] = t4;
|
|
1239
|
+
$[14] = t6;
|
|
1240
|
+
$[15] = t7;
|
|
1241
|
+
} else t7 = $[15];
|
|
1242
|
+
let t8;
|
|
1243
|
+
if ($[16] === Symbol.for("react.memo_cache_sentinel")) {
|
|
1244
|
+
t8 = /* @__PURE__ */ jsx(Button, {
|
|
1245
|
+
variant: "outlined",
|
|
1246
|
+
children: "Hover me"
|
|
1247
|
+
});
|
|
1248
|
+
$[16] = t8;
|
|
1249
|
+
} else t8 = $[16];
|
|
1250
|
+
let t9;
|
|
1251
|
+
if ($[17] !== t7) {
|
|
1252
|
+
t9 = /* @__PURE__ */ jsxs("div", {
|
|
1253
|
+
className: "flex flex-col items-center",
|
|
1254
|
+
children: [t7, t8]
|
|
1255
|
+
});
|
|
1256
|
+
$[17] = t7;
|
|
1257
|
+
$[18] = t9;
|
|
1258
|
+
} else t9 = $[18];
|
|
1259
|
+
return t9;
|
|
1260
|
+
}
|
|
1261
|
+
const demos = [
|
|
1262
|
+
{
|
|
1263
|
+
id: "button",
|
|
1264
|
+
title: "Button",
|
|
1265
|
+
group: "Buttons",
|
|
1266
|
+
render: () => /* @__PURE__ */ jsxs("div", {
|
|
1267
|
+
className: "flex flex-col gap-3",
|
|
1268
|
+
children: [
|
|
1269
|
+
/* @__PURE__ */ jsxs("div", {
|
|
1270
|
+
className: "flex flex-wrap items-center gap-2",
|
|
1271
|
+
children: [
|
|
1272
|
+
/* @__PURE__ */ jsx(Button, { children: "Contained" }),
|
|
1273
|
+
/* @__PURE__ */ jsx(Button, {
|
|
1274
|
+
variant: "outlined",
|
|
1275
|
+
children: "Outlined"
|
|
1276
|
+
}),
|
|
1277
|
+
/* @__PURE__ */ jsx(Button, {
|
|
1278
|
+
variant: "subtle",
|
|
1279
|
+
children: "Subtle"
|
|
1280
|
+
}),
|
|
1281
|
+
/* @__PURE__ */ jsx(Button, {
|
|
1282
|
+
variant: "ghost",
|
|
1283
|
+
children: "Ghost"
|
|
1284
|
+
}),
|
|
1285
|
+
/* @__PURE__ */ jsx(Button, {
|
|
1286
|
+
variant: "text",
|
|
1287
|
+
children: "Text"
|
|
1288
|
+
})
|
|
1289
|
+
]
|
|
1290
|
+
}),
|
|
1291
|
+
/* @__PURE__ */ jsxs("div", {
|
|
1292
|
+
className: "flex flex-wrap items-center gap-2",
|
|
1293
|
+
children: [
|
|
1294
|
+
/* @__PURE__ */ jsx(Button, {
|
|
1295
|
+
color: "secondary",
|
|
1296
|
+
children: "Secondary"
|
|
1297
|
+
}),
|
|
1298
|
+
/* @__PURE__ */ jsx(Button, {
|
|
1299
|
+
color: "error",
|
|
1300
|
+
children: "Error"
|
|
1301
|
+
}),
|
|
1302
|
+
/* @__PURE__ */ jsx(Button, {
|
|
1303
|
+
startIcon: Calendar,
|
|
1304
|
+
children: "With icon"
|
|
1305
|
+
}),
|
|
1306
|
+
/* @__PURE__ */ jsx(Button, {
|
|
1307
|
+
isLoading: true,
|
|
1308
|
+
children: "Loading"
|
|
1309
|
+
})
|
|
1310
|
+
]
|
|
1311
|
+
}),
|
|
1312
|
+
/* @__PURE__ */ jsxs("div", {
|
|
1313
|
+
className: "flex flex-wrap items-center gap-2",
|
|
1314
|
+
children: [
|
|
1315
|
+
/* @__PURE__ */ jsx(Button, {
|
|
1316
|
+
size: "sm",
|
|
1317
|
+
children: "Small"
|
|
1318
|
+
}),
|
|
1319
|
+
/* @__PURE__ */ jsx(Button, {
|
|
1320
|
+
size: "default",
|
|
1321
|
+
children: "Default"
|
|
1322
|
+
}),
|
|
1323
|
+
/* @__PURE__ */ jsx(Button, {
|
|
1324
|
+
isDisabled: true,
|
|
1325
|
+
children: "Disabled"
|
|
1326
|
+
}),
|
|
1327
|
+
/* @__PURE__ */ jsx(Button, {
|
|
1328
|
+
variant: "outlined",
|
|
1329
|
+
isDisabled: true,
|
|
1330
|
+
children: "Disabled"
|
|
1331
|
+
})
|
|
1332
|
+
]
|
|
1333
|
+
})
|
|
1334
|
+
]
|
|
1335
|
+
})
|
|
1336
|
+
},
|
|
1337
|
+
{
|
|
1338
|
+
id: "icon-button",
|
|
1339
|
+
title: "IconButton",
|
|
1340
|
+
group: "Buttons",
|
|
1341
|
+
render: () => /* @__PURE__ */ jsxs("div", {
|
|
1342
|
+
className: "flex flex-wrap items-center gap-2",
|
|
1343
|
+
children: [
|
|
1344
|
+
/* @__PURE__ */ jsx(IconButton, {
|
|
1345
|
+
icon: Calendar,
|
|
1346
|
+
label: "Calendar"
|
|
1347
|
+
}),
|
|
1348
|
+
/* @__PURE__ */ jsx(IconButton, {
|
|
1349
|
+
icon: Calendar,
|
|
1350
|
+
label: "Calendar",
|
|
1351
|
+
variant: "outlined"
|
|
1352
|
+
}),
|
|
1353
|
+
/* @__PURE__ */ jsx(IconButton, {
|
|
1354
|
+
icon: Calendar,
|
|
1355
|
+
label: "Calendar",
|
|
1356
|
+
variant: "subtle"
|
|
1357
|
+
}),
|
|
1358
|
+
/* @__PURE__ */ jsx(IconButton, {
|
|
1359
|
+
icon: Calendar,
|
|
1360
|
+
label: "Calendar",
|
|
1361
|
+
color: "secondary"
|
|
1362
|
+
}),
|
|
1363
|
+
/* @__PURE__ */ jsx(IconButton, {
|
|
1364
|
+
icon: Calendar,
|
|
1365
|
+
label: "Calendar",
|
|
1366
|
+
size: "sm"
|
|
1367
|
+
}),
|
|
1368
|
+
/* @__PURE__ */ jsx(IconButton, {
|
|
1369
|
+
icon: Calendar,
|
|
1370
|
+
label: "Calendar",
|
|
1371
|
+
isDisabled: true
|
|
1372
|
+
})
|
|
1373
|
+
]
|
|
1374
|
+
})
|
|
1375
|
+
},
|
|
1376
|
+
{
|
|
1377
|
+
id: "text-button",
|
|
1378
|
+
title: "TextButton",
|
|
1379
|
+
group: "Buttons",
|
|
1380
|
+
render: () => /* @__PURE__ */ jsxs("div", {
|
|
1381
|
+
className: "flex flex-wrap items-center gap-4",
|
|
1382
|
+
children: [
|
|
1383
|
+
/* @__PURE__ */ jsx(TextButton, { children: "Log in" }),
|
|
1384
|
+
/* @__PURE__ */ jsx(TextButton, {
|
|
1385
|
+
icon: Calendar,
|
|
1386
|
+
children: "With icon"
|
|
1387
|
+
}),
|
|
1388
|
+
/* @__PURE__ */ jsx(TextButton, {
|
|
1389
|
+
color: "secondary",
|
|
1390
|
+
children: "Secondary"
|
|
1391
|
+
}),
|
|
1392
|
+
/* @__PURE__ */ jsx(TextButton, {
|
|
1393
|
+
color: "error",
|
|
1394
|
+
children: "Error"
|
|
1395
|
+
}),
|
|
1396
|
+
/* @__PURE__ */ jsx(TextButton, {
|
|
1397
|
+
isDisabled: true,
|
|
1398
|
+
children: "Disabled"
|
|
1399
|
+
})
|
|
1400
|
+
]
|
|
1401
|
+
})
|
|
1402
|
+
},
|
|
1403
|
+
{
|
|
1404
|
+
id: "toggle-button",
|
|
1405
|
+
title: "ToggleButton",
|
|
1406
|
+
group: "Buttons",
|
|
1407
|
+
render: () => /* @__PURE__ */ jsxs("div", {
|
|
1408
|
+
className: "flex flex-wrap items-center gap-2",
|
|
1409
|
+
children: [
|
|
1410
|
+
/* @__PURE__ */ jsx(ToggleButton, { children: "Toggle me" }),
|
|
1411
|
+
/* @__PURE__ */ jsx(ToggleButton, {
|
|
1412
|
+
defaultSelected: true,
|
|
1413
|
+
children: "Selected"
|
|
1414
|
+
}),
|
|
1415
|
+
/* @__PURE__ */ jsx(ToggleButton, {
|
|
1416
|
+
isDisabled: true,
|
|
1417
|
+
children: "Disabled"
|
|
1418
|
+
})
|
|
1419
|
+
]
|
|
1420
|
+
})
|
|
1421
|
+
},
|
|
1422
|
+
{
|
|
1423
|
+
id: "split-button",
|
|
1424
|
+
title: "SplitButton",
|
|
1425
|
+
group: "Buttons",
|
|
1426
|
+
render: () => /* @__PURE__ */ jsxs("div", {
|
|
1427
|
+
className: "flex flex-wrap items-center gap-3",
|
|
1428
|
+
children: [/* @__PURE__ */ jsx(SplitButton, {
|
|
1429
|
+
label: "Save",
|
|
1430
|
+
labelRight: "More",
|
|
1431
|
+
items: menuItems
|
|
1432
|
+
}), /* @__PURE__ */ jsx(SplitButton, {
|
|
1433
|
+
label: "Save",
|
|
1434
|
+
labelRight: "More",
|
|
1435
|
+
variant: "outlined",
|
|
1436
|
+
items: menuItems
|
|
1437
|
+
})]
|
|
1438
|
+
})
|
|
1439
|
+
},
|
|
1440
|
+
{
|
|
1441
|
+
id: "badge-button",
|
|
1442
|
+
title: "BadgeButton",
|
|
1443
|
+
group: "Buttons",
|
|
1444
|
+
render: () => /* @__PURE__ */ jsxs("div", {
|
|
1445
|
+
className: "flex flex-wrap items-center gap-2",
|
|
1446
|
+
children: [
|
|
1447
|
+
/* @__PURE__ */ jsx(BadgeButton, { children: "Badge" }),
|
|
1448
|
+
/* @__PURE__ */ jsx(BadgeButton, {
|
|
1449
|
+
icon: Calendar,
|
|
1450
|
+
children: "With icon"
|
|
1451
|
+
}),
|
|
1452
|
+
/* @__PURE__ */ jsx(BadgeButton, {
|
|
1453
|
+
dismissable: true,
|
|
1454
|
+
children: "Dismissable"
|
|
1455
|
+
}),
|
|
1456
|
+
/* @__PURE__ */ jsx(BadgeButton, {
|
|
1457
|
+
toggle: true,
|
|
1458
|
+
defaultSelected: true,
|
|
1459
|
+
children: "Selected"
|
|
1460
|
+
}),
|
|
1461
|
+
/* @__PURE__ */ jsx(BadgeButton, {
|
|
1462
|
+
isDisabled: true,
|
|
1463
|
+
children: "Disabled"
|
|
1464
|
+
})
|
|
1465
|
+
]
|
|
1466
|
+
})
|
|
1467
|
+
},
|
|
1468
|
+
{
|
|
1469
|
+
id: "toggle-group",
|
|
1470
|
+
title: "ToggleGroup",
|
|
1471
|
+
group: "Buttons",
|
|
1472
|
+
render: () => /* @__PURE__ */ jsx(ToggleGroupDemo, {})
|
|
1473
|
+
},
|
|
1474
|
+
{
|
|
1475
|
+
id: "input",
|
|
1476
|
+
title: "Input",
|
|
1477
|
+
group: "Inputs",
|
|
1478
|
+
render: () => /* @__PURE__ */ jsxs("div", {
|
|
1479
|
+
className: "flex flex-col gap-4",
|
|
1480
|
+
children: [
|
|
1481
|
+
/* @__PURE__ */ jsx(Input, {
|
|
1482
|
+
label: "First name",
|
|
1483
|
+
placeholder: "Enter your name"
|
|
1484
|
+
}),
|
|
1485
|
+
/* @__PURE__ */ jsx(Input, {
|
|
1486
|
+
label: "Email",
|
|
1487
|
+
placeholder: "name@example.com",
|
|
1488
|
+
helperText: "We will never share your email.",
|
|
1489
|
+
isRequired: true
|
|
1490
|
+
}),
|
|
1491
|
+
/* @__PURE__ */ jsx(Input, {
|
|
1492
|
+
label: "Username",
|
|
1493
|
+
defaultValue: "admin",
|
|
1494
|
+
error: "This username is already taken."
|
|
1495
|
+
}),
|
|
1496
|
+
/* @__PURE__ */ jsx(Input, {
|
|
1497
|
+
label: "Disabled",
|
|
1498
|
+
defaultValue: "Read only value",
|
|
1499
|
+
isDisabled: true
|
|
1500
|
+
})
|
|
1501
|
+
]
|
|
1502
|
+
})
|
|
1503
|
+
},
|
|
1504
|
+
{
|
|
1505
|
+
id: "text-area",
|
|
1506
|
+
title: "TextArea",
|
|
1507
|
+
group: "Inputs",
|
|
1508
|
+
render: () => /* @__PURE__ */ jsx(TextArea, {
|
|
1509
|
+
label: "Description",
|
|
1510
|
+
placeholder: "Tell us more",
|
|
1511
|
+
helperText: "Maximum 500 characters"
|
|
1512
|
+
})
|
|
1513
|
+
},
|
|
1514
|
+
{
|
|
1515
|
+
id: "password-input",
|
|
1516
|
+
title: "PasswordInput",
|
|
1517
|
+
group: "Inputs",
|
|
1518
|
+
render: () => /* @__PURE__ */ jsx(PasswordInput, {
|
|
1519
|
+
label: "Password",
|
|
1520
|
+
defaultValue: "supersecret",
|
|
1521
|
+
isRequired: true
|
|
1522
|
+
})
|
|
1523
|
+
},
|
|
1524
|
+
{
|
|
1525
|
+
id: "number-field",
|
|
1526
|
+
title: "NumberField",
|
|
1527
|
+
group: "Inputs",
|
|
1528
|
+
render: () => /* @__PURE__ */ jsx(NumberField, {
|
|
1529
|
+
label: "Quantity",
|
|
1530
|
+
defaultValue: 3
|
|
1531
|
+
})
|
|
1532
|
+
},
|
|
1533
|
+
{
|
|
1534
|
+
id: "checkbox",
|
|
1535
|
+
title: "Checkbox",
|
|
1536
|
+
group: "Inputs",
|
|
1537
|
+
render: () => /* @__PURE__ */ jsxs("div", {
|
|
1538
|
+
className: "flex flex-col gap-2",
|
|
1539
|
+
children: [
|
|
1540
|
+
/* @__PURE__ */ jsx(Checkbox, { children: "Unchecked" }),
|
|
1541
|
+
/* @__PURE__ */ jsx(Checkbox, {
|
|
1542
|
+
defaultSelected: true,
|
|
1543
|
+
children: "Checked"
|
|
1544
|
+
}),
|
|
1545
|
+
/* @__PURE__ */ jsx(Checkbox, {
|
|
1546
|
+
isIndeterminate: true,
|
|
1547
|
+
children: "Indeterminate"
|
|
1548
|
+
}),
|
|
1549
|
+
/* @__PURE__ */ jsx(Checkbox, {
|
|
1550
|
+
isDisabled: true,
|
|
1551
|
+
children: "Disabled"
|
|
1552
|
+
}),
|
|
1553
|
+
/* @__PURE__ */ jsx(Checkbox, {
|
|
1554
|
+
error: "This is an error message",
|
|
1555
|
+
children: "With error"
|
|
1556
|
+
})
|
|
1557
|
+
]
|
|
1558
|
+
})
|
|
1559
|
+
},
|
|
1560
|
+
{
|
|
1561
|
+
id: "checkbox-group",
|
|
1562
|
+
title: "CheckboxGroup",
|
|
1563
|
+
group: "Inputs",
|
|
1564
|
+
render: () => /* @__PURE__ */ jsx(CheckboxGroupDemo, {})
|
|
1565
|
+
},
|
|
1566
|
+
{
|
|
1567
|
+
id: "radio-group",
|
|
1568
|
+
title: "RadioGroup",
|
|
1569
|
+
group: "Inputs",
|
|
1570
|
+
render: () => /* @__PURE__ */ jsx(RadioGroupDemo, {})
|
|
1571
|
+
},
|
|
1572
|
+
{
|
|
1573
|
+
id: "switch",
|
|
1574
|
+
title: "Switch",
|
|
1575
|
+
group: "Inputs",
|
|
1576
|
+
render: () => /* @__PURE__ */ jsxs("div", {
|
|
1577
|
+
className: "flex flex-col gap-2",
|
|
1578
|
+
children: [
|
|
1579
|
+
/* @__PURE__ */ jsx(Switch, { children: "Off" }),
|
|
1580
|
+
/* @__PURE__ */ jsx(Switch, {
|
|
1581
|
+
defaultSelected: true,
|
|
1582
|
+
children: "On"
|
|
1583
|
+
}),
|
|
1584
|
+
/* @__PURE__ */ jsx(Switch, {
|
|
1585
|
+
isDisabled: true,
|
|
1586
|
+
children: "Disabled"
|
|
1587
|
+
}),
|
|
1588
|
+
/* @__PURE__ */ jsx(Switch, {
|
|
1589
|
+
defaultSelected: true,
|
|
1590
|
+
isDisabled: true,
|
|
1591
|
+
children: "Selected disabled"
|
|
1592
|
+
})
|
|
1593
|
+
]
|
|
1594
|
+
})
|
|
1595
|
+
},
|
|
1596
|
+
{
|
|
1597
|
+
id: "slider",
|
|
1598
|
+
title: "Slider",
|
|
1599
|
+
group: "Inputs",
|
|
1600
|
+
render: () => /* @__PURE__ */ jsxs("div", {
|
|
1601
|
+
className: "flex flex-col gap-4",
|
|
1602
|
+
children: [/* @__PURE__ */ jsx(Slider, {
|
|
1603
|
+
label: "Percentage",
|
|
1604
|
+
defaultValue: 40,
|
|
1605
|
+
unit: "%"
|
|
1606
|
+
}), /* @__PURE__ */ jsx(Slider, {
|
|
1607
|
+
label: "Range",
|
|
1608
|
+
isRange: true,
|
|
1609
|
+
defaultValue: [25, 75]
|
|
1610
|
+
})]
|
|
1611
|
+
})
|
|
1612
|
+
},
|
|
1613
|
+
{
|
|
1614
|
+
id: "select",
|
|
1615
|
+
title: "Select",
|
|
1616
|
+
group: "Selection",
|
|
1617
|
+
render: () => /* @__PURE__ */ jsx(SelectDemo, {})
|
|
1618
|
+
},
|
|
1619
|
+
{
|
|
1620
|
+
id: "autocomplete",
|
|
1621
|
+
title: "Autocomplete",
|
|
1622
|
+
group: "Selection",
|
|
1623
|
+
render: () => /* @__PURE__ */ jsx(AutocompleteDemo, {})
|
|
1624
|
+
},
|
|
1625
|
+
{
|
|
1626
|
+
id: "date-picker",
|
|
1627
|
+
title: "DatePicker",
|
|
1628
|
+
group: "Selection",
|
|
1629
|
+
render: () => /* @__PURE__ */ jsx(DatePickerDemo, {})
|
|
1630
|
+
},
|
|
1631
|
+
{
|
|
1632
|
+
id: "time-picker",
|
|
1633
|
+
title: "TimePicker",
|
|
1634
|
+
group: "Selection",
|
|
1635
|
+
render: () => /* @__PURE__ */ jsx(TimePickerDemo, {})
|
|
1636
|
+
},
|
|
1637
|
+
{
|
|
1638
|
+
id: "file-upload",
|
|
1639
|
+
title: "FileUpload",
|
|
1640
|
+
group: "Files",
|
|
1641
|
+
render: () => /* @__PURE__ */ jsx(FileUpload, {
|
|
1642
|
+
label: "Upload file",
|
|
1643
|
+
helperText: "Upload images (JPEG, PNG, WEBP)",
|
|
1644
|
+
acceptedFileTypes: [
|
|
1645
|
+
"image/jpeg",
|
|
1646
|
+
"image/png",
|
|
1647
|
+
"image/webp"
|
|
1648
|
+
]
|
|
1649
|
+
})
|
|
1650
|
+
},
|
|
1651
|
+
{
|
|
1652
|
+
id: "alert",
|
|
1653
|
+
title: "Alert",
|
|
1654
|
+
group: "Feedback",
|
|
1655
|
+
render: () => /* @__PURE__ */ jsxs("div", {
|
|
1656
|
+
className: "flex flex-col gap-3",
|
|
1657
|
+
children: [
|
|
1658
|
+
/* @__PURE__ */ jsx(Alert, {
|
|
1659
|
+
text: "This is a neutral alert with some helpful information.",
|
|
1660
|
+
icon: Info
|
|
1661
|
+
}),
|
|
1662
|
+
/* @__PURE__ */ jsx(Alert, {
|
|
1663
|
+
color: "success",
|
|
1664
|
+
text: "Your changes have been saved.",
|
|
1665
|
+
icon: Check
|
|
1666
|
+
}),
|
|
1667
|
+
/* @__PURE__ */ jsx(Alert, {
|
|
1668
|
+
color: "warning",
|
|
1669
|
+
text: "Your trial ends in 3 days.",
|
|
1670
|
+
icon: Info
|
|
1671
|
+
}),
|
|
1672
|
+
/* @__PURE__ */ jsx(Alert, {
|
|
1673
|
+
variant: "contained",
|
|
1674
|
+
color: "error",
|
|
1675
|
+
text: "Something went wrong. Please try again.",
|
|
1676
|
+
icon: Info
|
|
1677
|
+
})
|
|
1678
|
+
]
|
|
1679
|
+
})
|
|
1680
|
+
},
|
|
1681
|
+
{
|
|
1682
|
+
id: "toast",
|
|
1683
|
+
title: "Toast",
|
|
1684
|
+
group: "Feedback",
|
|
1685
|
+
render: () => /* @__PURE__ */ jsxs("div", {
|
|
1686
|
+
className: "flex flex-col gap-3",
|
|
1687
|
+
children: [/* @__PURE__ */ jsx(Toast, {
|
|
1688
|
+
variant: "outlined",
|
|
1689
|
+
color: "neutral",
|
|
1690
|
+
text: "This is a toast notification.",
|
|
1691
|
+
icon: Check,
|
|
1692
|
+
actions: [{
|
|
1693
|
+
text: "Undo",
|
|
1694
|
+
onPress: noop
|
|
1695
|
+
}, {
|
|
1696
|
+
text: "Dismiss",
|
|
1697
|
+
onPress: noop
|
|
1698
|
+
}]
|
|
1699
|
+
}), /* @__PURE__ */ jsx(Toast, {
|
|
1700
|
+
variant: "contained",
|
|
1701
|
+
color: "success",
|
|
1702
|
+
text: "File uploaded successfully.",
|
|
1703
|
+
icon: Check
|
|
1704
|
+
})]
|
|
1705
|
+
})
|
|
1706
|
+
},
|
|
1707
|
+
{
|
|
1708
|
+
id: "progress",
|
|
1709
|
+
title: "Progress",
|
|
1710
|
+
group: "Feedback",
|
|
1711
|
+
render: () => /* @__PURE__ */ jsxs("div", {
|
|
1712
|
+
className: "flex flex-col gap-4",
|
|
1713
|
+
children: [
|
|
1714
|
+
/* @__PURE__ */ jsx(Progress, {
|
|
1715
|
+
progress: 50,
|
|
1716
|
+
valueLabel: "trailing"
|
|
1717
|
+
}),
|
|
1718
|
+
/* @__PURE__ */ jsx(Progress, {
|
|
1719
|
+
progress: 30,
|
|
1720
|
+
valueLabel: "leading"
|
|
1721
|
+
}),
|
|
1722
|
+
/* @__PURE__ */ jsx(Progress, {
|
|
1723
|
+
progress: 75,
|
|
1724
|
+
valueLabel: "none"
|
|
1725
|
+
})
|
|
1726
|
+
]
|
|
1727
|
+
})
|
|
1728
|
+
},
|
|
1729
|
+
{
|
|
1730
|
+
id: "spinner",
|
|
1731
|
+
title: "Spinner",
|
|
1732
|
+
group: "Feedback",
|
|
1733
|
+
render: () => /* @__PURE__ */ jsxs("div", {
|
|
1734
|
+
className: "flex items-center gap-6",
|
|
1735
|
+
children: [/* @__PURE__ */ jsx(Spinner, { size: "default" }), /* @__PURE__ */ jsx(Spinner, { size: "l" })]
|
|
1736
|
+
})
|
|
1737
|
+
},
|
|
1738
|
+
{
|
|
1739
|
+
id: "badge",
|
|
1740
|
+
title: "Badge",
|
|
1741
|
+
group: "Text",
|
|
1742
|
+
render: () => /* @__PURE__ */ jsxs("div", {
|
|
1743
|
+
className: "flex flex-wrap items-center gap-2",
|
|
1744
|
+
children: [
|
|
1745
|
+
/* @__PURE__ */ jsx(Badge, {
|
|
1746
|
+
color: "primary",
|
|
1747
|
+
children: "Primary"
|
|
1748
|
+
}),
|
|
1749
|
+
/* @__PURE__ */ jsx(Badge, {
|
|
1750
|
+
color: "secondary",
|
|
1751
|
+
children: "Secondary"
|
|
1752
|
+
}),
|
|
1753
|
+
/* @__PURE__ */ jsx(Badge, {
|
|
1754
|
+
color: "error",
|
|
1755
|
+
children: "Error"
|
|
1756
|
+
}),
|
|
1757
|
+
/* @__PURE__ */ jsx(Badge, {
|
|
1758
|
+
variant: "outlined",
|
|
1759
|
+
color: "primary",
|
|
1760
|
+
children: "Outlined"
|
|
1761
|
+
}),
|
|
1762
|
+
/* @__PURE__ */ jsx(Badge, {
|
|
1763
|
+
color: "primary",
|
|
1764
|
+
dismissable: true,
|
|
1765
|
+
onDismiss: noop,
|
|
1766
|
+
children: "Dismissable"
|
|
1767
|
+
})
|
|
1768
|
+
]
|
|
1769
|
+
})
|
|
1770
|
+
},
|
|
1771
|
+
{
|
|
1772
|
+
id: "tag",
|
|
1773
|
+
title: "Tag",
|
|
1774
|
+
group: "Text",
|
|
1775
|
+
render: () => /* @__PURE__ */ jsxs("div", {
|
|
1776
|
+
className: "flex flex-wrap items-center gap-2",
|
|
1777
|
+
children: [
|
|
1778
|
+
/* @__PURE__ */ jsx(Tag, {
|
|
1779
|
+
color: "primary",
|
|
1780
|
+
children: "Primary"
|
|
1781
|
+
}),
|
|
1782
|
+
/* @__PURE__ */ jsx(Tag, {
|
|
1783
|
+
color: "secondary",
|
|
1784
|
+
children: "Secondary"
|
|
1785
|
+
}),
|
|
1786
|
+
/* @__PURE__ */ jsx(Tag, {
|
|
1787
|
+
color: "success",
|
|
1788
|
+
children: "Success"
|
|
1789
|
+
}),
|
|
1790
|
+
/* @__PURE__ */ jsx(Tag, {
|
|
1791
|
+
color: "warning",
|
|
1792
|
+
children: "Warning"
|
|
1793
|
+
}),
|
|
1794
|
+
/* @__PURE__ */ jsx(Tag, {
|
|
1795
|
+
color: "error",
|
|
1796
|
+
children: "Error"
|
|
1797
|
+
}),
|
|
1798
|
+
/* @__PURE__ */ jsx(Tag, {
|
|
1799
|
+
color: "primary",
|
|
1800
|
+
dismissable: true,
|
|
1801
|
+
onDismiss: noop,
|
|
1802
|
+
children: "Dismissable"
|
|
1803
|
+
})
|
|
1804
|
+
]
|
|
1805
|
+
})
|
|
1806
|
+
},
|
|
1807
|
+
{
|
|
1808
|
+
id: "link",
|
|
1809
|
+
title: "Link",
|
|
1810
|
+
group: "Text",
|
|
1811
|
+
render: () => /* @__PURE__ */ jsxs(Typography, {
|
|
1812
|
+
size: "body",
|
|
1813
|
+
children: [
|
|
1814
|
+
"Read the ",
|
|
1815
|
+
/* @__PURE__ */ jsx(Link, {
|
|
1816
|
+
href: "#",
|
|
1817
|
+
children: "documentation"
|
|
1818
|
+
}),
|
|
1819
|
+
" or visit the ",
|
|
1820
|
+
/* @__PURE__ */ jsx(Link, {
|
|
1821
|
+
href: "#",
|
|
1822
|
+
children: "help center"
|
|
1823
|
+
}),
|
|
1824
|
+
"."
|
|
1825
|
+
]
|
|
1826
|
+
})
|
|
1827
|
+
},
|
|
1828
|
+
{
|
|
1829
|
+
id: "typography",
|
|
1830
|
+
title: "Typography",
|
|
1831
|
+
group: "Text",
|
|
1832
|
+
render: () => /* @__PURE__ */ jsxs("div", {
|
|
1833
|
+
className: "flex flex-col gap-2",
|
|
1834
|
+
children: [
|
|
1835
|
+
/* @__PURE__ */ jsx(Typography, {
|
|
1836
|
+
size: "h1",
|
|
1837
|
+
as: "h1",
|
|
1838
|
+
children: "Heading 1"
|
|
1839
|
+
}),
|
|
1840
|
+
/* @__PURE__ */ jsx(Typography, {
|
|
1841
|
+
size: "h2",
|
|
1842
|
+
as: "h2",
|
|
1843
|
+
children: "Heading 2"
|
|
1844
|
+
}),
|
|
1845
|
+
/* @__PURE__ */ jsx(Typography, {
|
|
1846
|
+
size: "h3",
|
|
1847
|
+
as: "h3",
|
|
1848
|
+
children: "Heading 3"
|
|
1849
|
+
}),
|
|
1850
|
+
/* @__PURE__ */ jsx(Typography, {
|
|
1851
|
+
size: "lead",
|
|
1852
|
+
children: "Lead paragraph text."
|
|
1853
|
+
}),
|
|
1854
|
+
/* @__PURE__ */ jsx(Typography, {
|
|
1855
|
+
size: "body",
|
|
1856
|
+
children: "Body text for general content and descriptions."
|
|
1857
|
+
}),
|
|
1858
|
+
/* @__PURE__ */ jsx(Typography, {
|
|
1859
|
+
size: "small",
|
|
1860
|
+
children: "Small text for captions and metadata."
|
|
1861
|
+
})
|
|
1862
|
+
]
|
|
1863
|
+
})
|
|
1864
|
+
},
|
|
1865
|
+
{
|
|
1866
|
+
id: "accordion",
|
|
1867
|
+
title: "Accordion",
|
|
1868
|
+
group: "Navigation",
|
|
1869
|
+
render: () => /* @__PURE__ */ jsx(Accordion, {
|
|
1870
|
+
items: accordionItems,
|
|
1871
|
+
defaultExpandedKeys: ["item1"]
|
|
1872
|
+
})
|
|
1873
|
+
},
|
|
1874
|
+
{
|
|
1875
|
+
id: "stepper",
|
|
1876
|
+
wide: true,
|
|
1877
|
+
title: "Stepper",
|
|
1878
|
+
group: "Navigation",
|
|
1879
|
+
render: () => /* @__PURE__ */ jsx(Stepper, {
|
|
1880
|
+
steps,
|
|
1881
|
+
currentStep: 1
|
|
1882
|
+
})
|
|
1883
|
+
},
|
|
1884
|
+
{
|
|
1885
|
+
id: "breadcrumbs",
|
|
1886
|
+
title: "Breadcrumbs",
|
|
1887
|
+
group: "Navigation",
|
|
1888
|
+
render: () => /* @__PURE__ */ jsx(Breadcrumbs, { items: [
|
|
1889
|
+
{
|
|
1890
|
+
id: "home",
|
|
1891
|
+
label: "Home",
|
|
1892
|
+
link: { href: "#" },
|
|
1893
|
+
icon: House
|
|
1894
|
+
},
|
|
1895
|
+
{
|
|
1896
|
+
id: "products",
|
|
1897
|
+
label: "Products",
|
|
1898
|
+
link: { href: "#" }
|
|
1899
|
+
},
|
|
1900
|
+
{
|
|
1901
|
+
id: "current",
|
|
1902
|
+
label: "Product details"
|
|
1903
|
+
}
|
|
1904
|
+
] })
|
|
1905
|
+
},
|
|
1906
|
+
{
|
|
1907
|
+
id: "pagination",
|
|
1908
|
+
wide: true,
|
|
1909
|
+
title: "Pagination",
|
|
1910
|
+
group: "Navigation",
|
|
1911
|
+
render: () => /* @__PURE__ */ jsx(PaginationDemo, {})
|
|
1912
|
+
},
|
|
1913
|
+
{
|
|
1914
|
+
id: "dialog",
|
|
1915
|
+
title: "Dialog",
|
|
1916
|
+
group: "Overlays",
|
|
1917
|
+
overlay: true,
|
|
1918
|
+
render: () => /* @__PURE__ */ jsx(DialogDemo, {})
|
|
1919
|
+
},
|
|
1920
|
+
{
|
|
1921
|
+
id: "popover",
|
|
1922
|
+
title: "Popover",
|
|
1923
|
+
group: "Overlays",
|
|
1924
|
+
overlay: true,
|
|
1925
|
+
render: () => /* @__PURE__ */ jsx(PopoverDemo, {})
|
|
1926
|
+
},
|
|
1927
|
+
{
|
|
1928
|
+
id: "tooltip",
|
|
1929
|
+
title: "Tooltip",
|
|
1930
|
+
group: "Overlays",
|
|
1931
|
+
overlay: true,
|
|
1932
|
+
render: () => /* @__PURE__ */ jsx(TooltipDemo, {})
|
|
1933
|
+
},
|
|
1934
|
+
{
|
|
1935
|
+
id: "dropdown-menu",
|
|
1936
|
+
title: "DropdownMenu",
|
|
1937
|
+
group: "Overlays",
|
|
1938
|
+
overlay: true,
|
|
1939
|
+
render: () => /* @__PURE__ */ jsx(DropdownMenuDemo, {})
|
|
1940
|
+
},
|
|
1941
|
+
{
|
|
1942
|
+
id: "table",
|
|
1943
|
+
wide: true,
|
|
1944
|
+
title: "Table",
|
|
1945
|
+
group: "Data",
|
|
1946
|
+
render: () => /* @__PURE__ */ jsx(Table, {
|
|
1947
|
+
items: tableRows,
|
|
1948
|
+
columns: tableColumns
|
|
1949
|
+
})
|
|
1950
|
+
}
|
|
1951
|
+
];
|
|
1952
|
+
//#endregion
|
|
1953
|
+
//#region src/configurator/gallery/LayoutPreview.tsx
|
|
1954
|
+
/** Daily active users for the stats card; the last day is highlighted as today. */
|
|
1955
|
+
const week = [
|
|
1956
|
+
{
|
|
1957
|
+
day: "M",
|
|
1958
|
+
value: 58
|
|
1959
|
+
},
|
|
1960
|
+
{
|
|
1961
|
+
day: "T",
|
|
1962
|
+
value: 72
|
|
1963
|
+
},
|
|
1964
|
+
{
|
|
1965
|
+
day: "W",
|
|
1966
|
+
value: 64
|
|
1967
|
+
},
|
|
1968
|
+
{
|
|
1969
|
+
day: "T",
|
|
1970
|
+
value: 80
|
|
1971
|
+
},
|
|
1972
|
+
{
|
|
1973
|
+
day: "F",
|
|
1974
|
+
value: 70
|
|
1975
|
+
},
|
|
1976
|
+
{
|
|
1977
|
+
day: "S",
|
|
1978
|
+
value: 44
|
|
1979
|
+
},
|
|
1980
|
+
{
|
|
1981
|
+
day: "S",
|
|
1982
|
+
value: 90
|
|
1983
|
+
}
|
|
1984
|
+
];
|
|
1985
|
+
const team = [
|
|
1986
|
+
"AK",
|
|
1987
|
+
"MS",
|
|
1988
|
+
"LP"
|
|
1989
|
+
];
|
|
1990
|
+
const features = [
|
|
1991
|
+
"Unlimited projects",
|
|
1992
|
+
"Shared design tokens",
|
|
1993
|
+
"Priority support"
|
|
1994
|
+
];
|
|
1995
|
+
const teamSizes = [
|
|
1996
|
+
{
|
|
1997
|
+
id: "small",
|
|
1998
|
+
label: "1–10 people"
|
|
1999
|
+
},
|
|
2000
|
+
{
|
|
2001
|
+
id: "medium",
|
|
2002
|
+
label: "11–50 people"
|
|
2003
|
+
},
|
|
2004
|
+
{
|
|
2005
|
+
id: "large",
|
|
2006
|
+
label: "51+ people"
|
|
2007
|
+
}
|
|
2008
|
+
];
|
|
2009
|
+
/** A basic form, so input, label, helper text and focus styles can be judged in context. */
|
|
2010
|
+
function DemoRequestForm() {
|
|
2011
|
+
const $ = c(10);
|
|
2012
|
+
const [teamSize, setTeamSize] = useState("medium");
|
|
2013
|
+
let t0;
|
|
2014
|
+
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2015
|
+
t0 = /* @__PURE__ */ jsxs("div", { children: [/* @__PURE__ */ jsx("h4", { children: "Request a demo" }), /* @__PURE__ */ jsx("p", {
|
|
2016
|
+
className: "studio-layout-muted",
|
|
2017
|
+
children: "We will get back to you within one business day."
|
|
2018
|
+
})] });
|
|
2019
|
+
$[0] = t0;
|
|
2020
|
+
} else t0 = $[0];
|
|
2021
|
+
let t1;
|
|
2022
|
+
let t2;
|
|
2023
|
+
if ($[1] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2024
|
+
t1 = /* @__PURE__ */ jsx(Input, {
|
|
2025
|
+
label: "Full name",
|
|
2026
|
+
placeholder: "Jane Doe"
|
|
2027
|
+
});
|
|
2028
|
+
t2 = /* @__PURE__ */ jsx(Input, {
|
|
2029
|
+
label: "Work email",
|
|
2030
|
+
placeholder: "jane@company.com",
|
|
2031
|
+
isRequired: true
|
|
2032
|
+
});
|
|
2033
|
+
$[1] = t1;
|
|
2034
|
+
$[2] = t2;
|
|
2035
|
+
} else {
|
|
2036
|
+
t1 = $[1];
|
|
2037
|
+
t2 = $[2];
|
|
2038
|
+
}
|
|
2039
|
+
let t3;
|
|
2040
|
+
if ($[3] !== teamSize) {
|
|
2041
|
+
t3 = /* @__PURE__ */ jsx(Select, {
|
|
2042
|
+
label: "Team size",
|
|
2043
|
+
placeholder: "Select team size",
|
|
2044
|
+
items: teamSizes,
|
|
2045
|
+
value: teamSize,
|
|
2046
|
+
onChange: setTeamSize
|
|
2047
|
+
});
|
|
2048
|
+
$[3] = teamSize;
|
|
2049
|
+
$[4] = t3;
|
|
2050
|
+
} else t3 = $[4];
|
|
2051
|
+
let t4;
|
|
2052
|
+
if ($[5] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2053
|
+
t4 = /* @__PURE__ */ jsx("div", {
|
|
2054
|
+
className: "studio-layout-form-wide",
|
|
2055
|
+
children: /* @__PURE__ */ jsx(TextArea, {
|
|
2056
|
+
label: "Message",
|
|
2057
|
+
placeholder: "What would you like to see?",
|
|
2058
|
+
helperText: "Optional, up to 500 characters."
|
|
2059
|
+
})
|
|
2060
|
+
});
|
|
2061
|
+
$[5] = t4;
|
|
2062
|
+
} else t4 = $[5];
|
|
2063
|
+
let t5;
|
|
2064
|
+
if ($[6] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2065
|
+
t5 = /* @__PURE__ */ jsx(Checkbox, {
|
|
2066
|
+
defaultSelected: true,
|
|
2067
|
+
children: "Send me product updates"
|
|
2068
|
+
});
|
|
2069
|
+
$[6] = t5;
|
|
2070
|
+
} else t5 = $[6];
|
|
2071
|
+
let t6;
|
|
2072
|
+
if ($[7] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2073
|
+
t6 = /* @__PURE__ */ jsxs("div", {
|
|
2074
|
+
className: "studio-layout-form-footer",
|
|
2075
|
+
children: [t5, /* @__PURE__ */ jsxs("div", {
|
|
2076
|
+
className: "studio-layout-form-actions",
|
|
2077
|
+
children: [/* @__PURE__ */ jsx(Button, {
|
|
2078
|
+
size: "s",
|
|
2079
|
+
variant: "ghost",
|
|
2080
|
+
children: "Cancel"
|
|
2081
|
+
}), /* @__PURE__ */ jsx(Button, {
|
|
2082
|
+
size: "s",
|
|
2083
|
+
type: "submit",
|
|
2084
|
+
children: "Request demo"
|
|
2085
|
+
})]
|
|
2086
|
+
})]
|
|
2087
|
+
});
|
|
2088
|
+
$[7] = t6;
|
|
2089
|
+
} else t6 = $[7];
|
|
2090
|
+
let t7;
|
|
2091
|
+
if ($[8] !== t3) {
|
|
2092
|
+
t7 = /* @__PURE__ */ jsxs("article", {
|
|
2093
|
+
className: "studio-layout-card is-form",
|
|
2094
|
+
children: [t0, /* @__PURE__ */ jsxs("form", {
|
|
2095
|
+
className: "studio-layout-form",
|
|
2096
|
+
onSubmit: _temp,
|
|
2097
|
+
children: [
|
|
2098
|
+
t1,
|
|
2099
|
+
t2,
|
|
2100
|
+
t3,
|
|
2101
|
+
t4,
|
|
2102
|
+
t6
|
|
2103
|
+
]
|
|
2104
|
+
})]
|
|
2105
|
+
});
|
|
2106
|
+
$[8] = t3;
|
|
2107
|
+
$[9] = t7;
|
|
2108
|
+
} else t7 = $[9];
|
|
2109
|
+
return t7;
|
|
2110
|
+
}
|
|
2111
|
+
/**
|
|
2112
|
+
* Small product cards built only from theme tokens and Povio UI components, so palette, typography, radius and
|
|
2113
|
+
* component changes can be judged in a realistic composition rather than component by component.
|
|
2114
|
+
*/
|
|
2115
|
+
function _temp(event) {
|
|
2116
|
+
return event.preventDefault();
|
|
2117
|
+
}
|
|
2118
|
+
function LayoutPreview() {
|
|
2119
|
+
const $ = c(13);
|
|
2120
|
+
let t0;
|
|
2121
|
+
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2122
|
+
t0 = /* @__PURE__ */ jsx("h3", { children: "Layouts" });
|
|
2123
|
+
$[0] = t0;
|
|
2124
|
+
} else t0 = $[0];
|
|
2125
|
+
let t1;
|
|
2126
|
+
let t2;
|
|
2127
|
+
if ($[1] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2128
|
+
t1 = /* @__PURE__ */ jsx("p", {
|
|
2129
|
+
className: "studio-layout-label",
|
|
2130
|
+
children: "Sprint 24"
|
|
2131
|
+
});
|
|
2132
|
+
t2 = /* @__PURE__ */ jsx("h4", { children: "Redesign onboarding flow" });
|
|
2133
|
+
$[1] = t1;
|
|
2134
|
+
$[2] = t2;
|
|
2135
|
+
} else {
|
|
2136
|
+
t1 = $[1];
|
|
2137
|
+
t2 = $[2];
|
|
2138
|
+
}
|
|
2139
|
+
let t3;
|
|
2140
|
+
if ($[3] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2141
|
+
t3 = /* @__PURE__ */ jsxs("div", {
|
|
2142
|
+
className: "studio-layout-tags",
|
|
2143
|
+
children: [/* @__PURE__ */ jsx(Tag, { children: "Design" }), /* @__PURE__ */ jsx(Tag, { children: "Research" })]
|
|
2144
|
+
});
|
|
2145
|
+
$[3] = t3;
|
|
2146
|
+
} else t3 = $[3];
|
|
2147
|
+
let t4;
|
|
2148
|
+
if ($[4] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2149
|
+
t4 = /* @__PURE__ */ jsxs("div", {
|
|
2150
|
+
className: "studio-layout-progress",
|
|
2151
|
+
children: [/* @__PURE__ */ jsx("span", { children: "12 of 18 tasks" }), /* @__PURE__ */ jsx(Progress, { progress: 65 })]
|
|
2152
|
+
});
|
|
2153
|
+
$[4] = t4;
|
|
2154
|
+
} else t4 = $[4];
|
|
2155
|
+
let t5;
|
|
2156
|
+
if ($[5] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2157
|
+
t5 = /* @__PURE__ */ jsxs("article", {
|
|
2158
|
+
className: "studio-layout-card is-soft",
|
|
2159
|
+
children: [
|
|
2160
|
+
t1,
|
|
2161
|
+
t2,
|
|
2162
|
+
t3,
|
|
2163
|
+
t4,
|
|
2164
|
+
/* @__PURE__ */ jsxs("div", {
|
|
2165
|
+
className: "studio-layout-footer",
|
|
2166
|
+
children: [/* @__PURE__ */ jsx("div", {
|
|
2167
|
+
className: "studio-layout-avatars",
|
|
2168
|
+
"aria-label": `${team.length} team members`,
|
|
2169
|
+
children: team.map(_temp2)
|
|
2170
|
+
}), /* @__PURE__ */ jsx(Button, {
|
|
2171
|
+
size: "s",
|
|
2172
|
+
children: "Open board"
|
|
2173
|
+
})]
|
|
2174
|
+
})
|
|
2175
|
+
]
|
|
2176
|
+
});
|
|
2177
|
+
$[5] = t5;
|
|
2178
|
+
} else t5 = $[5];
|
|
2179
|
+
let t6;
|
|
2180
|
+
let t7;
|
|
2181
|
+
let t8;
|
|
2182
|
+
if ($[6] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2183
|
+
t6 = /* @__PURE__ */ jsx("p", {
|
|
2184
|
+
className: "studio-layout-label",
|
|
2185
|
+
children: "Weekly active users"
|
|
2186
|
+
});
|
|
2187
|
+
t7 = /* @__PURE__ */ jsx("p", {
|
|
2188
|
+
className: "studio-layout-amount",
|
|
2189
|
+
children: "8,420"
|
|
2190
|
+
});
|
|
2191
|
+
t8 = /* @__PURE__ */ jsx("p", {
|
|
2192
|
+
className: "studio-layout-trend",
|
|
2193
|
+
children: "+12% vs last week"
|
|
2194
|
+
});
|
|
2195
|
+
$[6] = t6;
|
|
2196
|
+
$[7] = t7;
|
|
2197
|
+
$[8] = t8;
|
|
2198
|
+
} else {
|
|
2199
|
+
t6 = $[6];
|
|
2200
|
+
t7 = $[7];
|
|
2201
|
+
t8 = $[8];
|
|
2202
|
+
}
|
|
2203
|
+
let t9;
|
|
2204
|
+
if ($[9] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2205
|
+
t9 = /* @__PURE__ */ jsxs("article", {
|
|
2206
|
+
className: "studio-layout-card is-stats",
|
|
2207
|
+
children: [
|
|
2208
|
+
t6,
|
|
2209
|
+
t7,
|
|
2210
|
+
t8,
|
|
2211
|
+
/* @__PURE__ */ jsx("div", {
|
|
2212
|
+
className: "studio-layout-chart",
|
|
2213
|
+
role: "img",
|
|
2214
|
+
"aria-label": "Daily active users for the last seven days",
|
|
2215
|
+
children: week.map(_temp3)
|
|
2216
|
+
})
|
|
2217
|
+
]
|
|
2218
|
+
});
|
|
2219
|
+
$[9] = t9;
|
|
2220
|
+
} else t9 = $[9];
|
|
2221
|
+
let t10;
|
|
2222
|
+
if ($[10] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2223
|
+
t10 = /* @__PURE__ */ jsx("p", {
|
|
2224
|
+
className: "studio-layout-label",
|
|
2225
|
+
children: "Pro plan"
|
|
2226
|
+
});
|
|
2227
|
+
$[10] = t10;
|
|
2228
|
+
} else t10 = $[10];
|
|
2229
|
+
let t11;
|
|
2230
|
+
if ($[11] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2231
|
+
t11 = /* @__PURE__ */ jsxs("p", {
|
|
2232
|
+
className: "studio-layout-price",
|
|
2233
|
+
children: ["€24", /* @__PURE__ */ jsx("span", { children: "/month" })]
|
|
2234
|
+
});
|
|
2235
|
+
$[11] = t11;
|
|
2236
|
+
} else t11 = $[11];
|
|
2237
|
+
let t12;
|
|
2238
|
+
if ($[12] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2239
|
+
t12 = /* @__PURE__ */ jsxs("section", {
|
|
2240
|
+
className: "studio-gallery-group",
|
|
2241
|
+
"aria-label": "Layouts",
|
|
2242
|
+
children: [t0, /* @__PURE__ */ jsxs("div", {
|
|
2243
|
+
className: "studio-layout-grid",
|
|
2244
|
+
children: [
|
|
2245
|
+
t5,
|
|
2246
|
+
t9,
|
|
2247
|
+
/* @__PURE__ */ jsxs("article", {
|
|
2248
|
+
className: "studio-layout-card is-bold",
|
|
2249
|
+
children: [
|
|
2250
|
+
t10,
|
|
2251
|
+
t11,
|
|
2252
|
+
/* @__PURE__ */ jsx("ul", {
|
|
2253
|
+
className: "studio-layout-features",
|
|
2254
|
+
children: features.map(_temp4)
|
|
2255
|
+
}),
|
|
2256
|
+
/* @__PURE__ */ jsx(Button, {
|
|
2257
|
+
size: "s",
|
|
2258
|
+
className: "studio-layout-cta",
|
|
2259
|
+
children: "Upgrade"
|
|
2260
|
+
})
|
|
2261
|
+
]
|
|
2262
|
+
}),
|
|
2263
|
+
/* @__PURE__ */ jsx(DemoRequestForm, {})
|
|
2264
|
+
]
|
|
2265
|
+
})]
|
|
2266
|
+
});
|
|
2267
|
+
$[12] = t12;
|
|
2268
|
+
} else t12 = $[12];
|
|
2269
|
+
return t12;
|
|
2270
|
+
}
|
|
2271
|
+
function _temp4(feature) {
|
|
2272
|
+
return /* @__PURE__ */ jsxs("li", { children: [/* @__PURE__ */ jsx(Check, {
|
|
2273
|
+
size: 13,
|
|
2274
|
+
"aria-hidden": "true"
|
|
2275
|
+
}), feature] }, feature);
|
|
2276
|
+
}
|
|
2277
|
+
function _temp3(t0, index) {
|
|
2278
|
+
const { day, value } = t0;
|
|
2279
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
2280
|
+
className: `studio-layout-bar ${index === week.length - 1 ? "is-today" : ""}`,
|
|
2281
|
+
children: [/* @__PURE__ */ jsx("span", { style: { height: `${value}%` } }), /* @__PURE__ */ jsx("span", {
|
|
2282
|
+
className: "studio-layout-day",
|
|
2283
|
+
children: day
|
|
2284
|
+
})]
|
|
2285
|
+
}, `${day}-${value}`);
|
|
2286
|
+
}
|
|
2287
|
+
function _temp2(initials) {
|
|
2288
|
+
return /* @__PURE__ */ jsx("span", { children: initials }, initials);
|
|
2289
|
+
}
|
|
2290
|
+
//#endregion
|
|
2291
|
+
//#region src/configurator/gallery/ComponentGallery.tsx
|
|
2292
|
+
/** Keeps portaled overlays (tooltips, popovers) inside the card so they inherit preview tokens and stay in place. */
|
|
2293
|
+
function PortalHere(t0) {
|
|
2294
|
+
const $ = c(7);
|
|
2295
|
+
const { children } = t0;
|
|
2296
|
+
const [container, setContainer] = useState(null);
|
|
2297
|
+
let t1;
|
|
2298
|
+
if ($[0] !== container) {
|
|
2299
|
+
t1 = () => container ?? document.body;
|
|
2300
|
+
$[0] = container;
|
|
2301
|
+
$[1] = t1;
|
|
2302
|
+
} else t1 = $[1];
|
|
2303
|
+
let t2;
|
|
2304
|
+
if ($[2] !== children) {
|
|
2305
|
+
t2 = children(setContainer);
|
|
2306
|
+
$[2] = children;
|
|
2307
|
+
$[3] = t2;
|
|
2308
|
+
} else t2 = $[3];
|
|
2309
|
+
let t3;
|
|
2310
|
+
if ($[4] !== t1 || $[5] !== t2) {
|
|
2311
|
+
t3 = /* @__PURE__ */ jsx($72abaeab4d80592f$export$78efe591171d7d45, {
|
|
2312
|
+
getContainer: t1,
|
|
2313
|
+
children: t2
|
|
2314
|
+
});
|
|
2315
|
+
$[4] = t1;
|
|
2316
|
+
$[5] = t2;
|
|
2317
|
+
$[6] = t3;
|
|
2318
|
+
} else t3 = $[6];
|
|
2319
|
+
return t3;
|
|
2320
|
+
}
|
|
2321
|
+
function ZoomedDemo(t0) {
|
|
2322
|
+
const $ = c(22);
|
|
2323
|
+
const { demo, width, onBack, inspector } = t0;
|
|
2324
|
+
const backRef = useRef(null);
|
|
2325
|
+
let t1;
|
|
2326
|
+
let t2;
|
|
2327
|
+
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2328
|
+
t1 = () => backRef.current?.focus();
|
|
2329
|
+
t2 = [];
|
|
2330
|
+
$[0] = t1;
|
|
2331
|
+
$[1] = t2;
|
|
2332
|
+
} else {
|
|
2333
|
+
t1 = $[0];
|
|
2334
|
+
t2 = $[1];
|
|
2335
|
+
}
|
|
2336
|
+
useEffect(t1, t2);
|
|
2337
|
+
let t3;
|
|
2338
|
+
if ($[2] !== onBack) {
|
|
2339
|
+
t3 = (event) => {
|
|
2340
|
+
if (event.key !== "Escape") return;
|
|
2341
|
+
event.stopPropagation();
|
|
2342
|
+
onBack();
|
|
2343
|
+
};
|
|
2344
|
+
$[2] = onBack;
|
|
2345
|
+
$[3] = t3;
|
|
2346
|
+
} else t3 = $[3];
|
|
2347
|
+
let t4;
|
|
2348
|
+
if ($[4] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2349
|
+
t4 = /* @__PURE__ */ jsx(ArrowLeft, {
|
|
2350
|
+
size: 13,
|
|
2351
|
+
"aria-hidden": "true"
|
|
2352
|
+
});
|
|
2353
|
+
$[4] = t4;
|
|
2354
|
+
} else t4 = $[4];
|
|
2355
|
+
let t5;
|
|
2356
|
+
if ($[5] !== onBack) {
|
|
2357
|
+
t5 = /* @__PURE__ */ jsxs("button", {
|
|
2358
|
+
ref: backRef,
|
|
2359
|
+
type: "button",
|
|
2360
|
+
className: "studio-gallery-back",
|
|
2361
|
+
onClick: onBack,
|
|
2362
|
+
children: [t4, "All components"]
|
|
2363
|
+
});
|
|
2364
|
+
$[5] = onBack;
|
|
2365
|
+
$[6] = t5;
|
|
2366
|
+
} else t5 = $[6];
|
|
2367
|
+
let t6;
|
|
2368
|
+
if ($[7] !== demo.title) {
|
|
2369
|
+
t6 = /* @__PURE__ */ jsx("span", { children: demo.title });
|
|
2370
|
+
$[7] = demo.title;
|
|
2371
|
+
$[8] = t6;
|
|
2372
|
+
} else t6 = $[8];
|
|
2373
|
+
let t7;
|
|
2374
|
+
if ($[9] !== t5 || $[10] !== t6) {
|
|
2375
|
+
t7 = /* @__PURE__ */ jsxs("div", {
|
|
2376
|
+
className: "studio-gallery-zoom-bar",
|
|
2377
|
+
children: [t5, t6]
|
|
2378
|
+
});
|
|
2379
|
+
$[9] = t5;
|
|
2380
|
+
$[10] = t6;
|
|
2381
|
+
$[11] = t7;
|
|
2382
|
+
} else t7 = $[11];
|
|
2383
|
+
let t8;
|
|
2384
|
+
if ($[12] !== demo || $[13] !== width) {
|
|
2385
|
+
t8 = /* @__PURE__ */ jsx(PortalHere, { children: (portalRef) => /* @__PURE__ */ jsx("div", {
|
|
2386
|
+
ref: portalRef,
|
|
2387
|
+
className: "studio-gallery-demo",
|
|
2388
|
+
style: {
|
|
2389
|
+
width,
|
|
2390
|
+
maxWidth: "100%"
|
|
2391
|
+
},
|
|
2392
|
+
children: demo.render()
|
|
2393
|
+
}) });
|
|
2394
|
+
$[12] = demo;
|
|
2395
|
+
$[13] = width;
|
|
2396
|
+
$[14] = t8;
|
|
2397
|
+
} else t8 = $[14];
|
|
2398
|
+
let t9;
|
|
2399
|
+
if ($[15] !== inspector || $[16] !== t8) {
|
|
2400
|
+
t9 = /* @__PURE__ */ jsx("div", {
|
|
2401
|
+
className: "studio-gallery-zoom-stage",
|
|
2402
|
+
children: /* @__PURE__ */ jsx(Inspector, {
|
|
2403
|
+
...inspector,
|
|
2404
|
+
children: t8
|
|
2405
|
+
})
|
|
2406
|
+
});
|
|
2407
|
+
$[15] = inspector;
|
|
2408
|
+
$[16] = t8;
|
|
2409
|
+
$[17] = t9;
|
|
2410
|
+
} else t9 = $[17];
|
|
2411
|
+
let t10;
|
|
2412
|
+
if ($[18] !== t3 || $[19] !== t7 || $[20] !== t9) {
|
|
2413
|
+
t10 = /* @__PURE__ */ jsxs("div", {
|
|
2414
|
+
className: "studio-gallery-zoom",
|
|
2415
|
+
onKeyDown: t3,
|
|
2416
|
+
children: [t7, t9]
|
|
2417
|
+
});
|
|
2418
|
+
$[18] = t3;
|
|
2419
|
+
$[19] = t7;
|
|
2420
|
+
$[20] = t9;
|
|
2421
|
+
$[21] = t10;
|
|
2422
|
+
} else t10 = $[21];
|
|
2423
|
+
return t10;
|
|
2424
|
+
}
|
|
2425
|
+
/** Every Povio UI component in one scrollable list; clicking a card zooms it into the token inspector. */
|
|
2426
|
+
function ComponentGallery(t0) {
|
|
2427
|
+
const $ = c(12);
|
|
2428
|
+
const { inspector } = t0;
|
|
2429
|
+
const [zoomed, setZoomed] = useState(null);
|
|
2430
|
+
const [zoomedWidth, setZoomedWidth] = useState();
|
|
2431
|
+
let t1;
|
|
2432
|
+
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2433
|
+
t1 = (id) => {
|
|
2434
|
+
setZoomedWidth(document.querySelector(`#gallery-card-${id} .studio-gallery-demo`)?.offsetWidth);
|
|
2435
|
+
setZoomed(id);
|
|
2436
|
+
};
|
|
2437
|
+
$[0] = t1;
|
|
2438
|
+
} else t1 = $[0];
|
|
2439
|
+
const open = t1;
|
|
2440
|
+
let t2;
|
|
2441
|
+
if ($[1] !== zoomed) {
|
|
2442
|
+
t2 = demos.find((demo) => demo.id === zoomed);
|
|
2443
|
+
$[1] = zoomed;
|
|
2444
|
+
$[2] = t2;
|
|
2445
|
+
} else t2 = $[2];
|
|
2446
|
+
const zoomedDemo = t2;
|
|
2447
|
+
const lastZoomed = useRef(null);
|
|
2448
|
+
let t3;
|
|
2449
|
+
let t4;
|
|
2450
|
+
if ($[3] !== zoomed) {
|
|
2451
|
+
t3 = () => {
|
|
2452
|
+
if (zoomed) lastZoomed.current = zoomed;
|
|
2453
|
+
else if (lastZoomed.current) document.querySelector(`#gallery-card-${lastZoomed.current} .studio-gallery-card-hit`)?.focus();
|
|
2454
|
+
};
|
|
2455
|
+
t4 = [zoomed];
|
|
2456
|
+
$[3] = zoomed;
|
|
2457
|
+
$[4] = t3;
|
|
2458
|
+
$[5] = t4;
|
|
2459
|
+
} else {
|
|
2460
|
+
t3 = $[4];
|
|
2461
|
+
t4 = $[5];
|
|
2462
|
+
}
|
|
2463
|
+
useEffect(t3, t4);
|
|
2464
|
+
if (zoomedDemo) {
|
|
2465
|
+
let t5;
|
|
2466
|
+
if ($[6] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2467
|
+
t5 = () => setZoomed(null);
|
|
2468
|
+
$[6] = t5;
|
|
2469
|
+
} else t5 = $[6];
|
|
2470
|
+
let t6;
|
|
2471
|
+
if ($[7] !== inspector || $[8] !== zoomedDemo || $[9] !== zoomedWidth) {
|
|
2472
|
+
t6 = /* @__PURE__ */ jsx(ZoomedDemo, {
|
|
2473
|
+
demo: zoomedDemo,
|
|
2474
|
+
width: zoomedWidth,
|
|
2475
|
+
inspector,
|
|
2476
|
+
onBack: t5
|
|
2477
|
+
}, zoomedDemo.id);
|
|
2478
|
+
$[7] = inspector;
|
|
2479
|
+
$[8] = zoomedDemo;
|
|
2480
|
+
$[9] = zoomedWidth;
|
|
2481
|
+
$[10] = t6;
|
|
2482
|
+
} else t6 = $[10];
|
|
2483
|
+
return t6;
|
|
2484
|
+
}
|
|
2485
|
+
let t5;
|
|
2486
|
+
if ($[11] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2487
|
+
t5 = /* @__PURE__ */ jsxs("div", {
|
|
2488
|
+
className: "studio-gallery",
|
|
2489
|
+
children: [/* @__PURE__ */ jsx(LayoutPreview, {}), galleryGroups.map((group) => {
|
|
2490
|
+
const items = demos.filter((demo_0) => demo_0.group === group);
|
|
2491
|
+
if (!items.length) return null;
|
|
2492
|
+
return /* @__PURE__ */ jsxs("section", {
|
|
2493
|
+
className: "studio-gallery-group",
|
|
2494
|
+
"aria-label": group,
|
|
2495
|
+
children: [/* @__PURE__ */ jsx("h3", { children: group }), /* @__PURE__ */ jsx("div", {
|
|
2496
|
+
className: "studio-gallery-grid",
|
|
2497
|
+
children: items.map((demo_1) => /* @__PURE__ */ jsxs("div", {
|
|
2498
|
+
id: `gallery-card-${demo_1.id}`,
|
|
2499
|
+
className: `studio-gallery-card ${demo_1.wide ? "is-wide" : ""}`,
|
|
2500
|
+
children: [
|
|
2501
|
+
/* @__PURE__ */ jsx("button", {
|
|
2502
|
+
type: "button",
|
|
2503
|
+
className: "studio-gallery-card-hit",
|
|
2504
|
+
"aria-label": `Inspect ${demo_1.title}`,
|
|
2505
|
+
onClick: () => open(demo_1.id)
|
|
2506
|
+
}),
|
|
2507
|
+
/* @__PURE__ */ jsx("span", {
|
|
2508
|
+
className: "studio-gallery-card-title",
|
|
2509
|
+
children: demo_1.title
|
|
2510
|
+
}),
|
|
2511
|
+
/* @__PURE__ */ jsx(PortalHere, { children: (portalRef) => /* @__PURE__ */ jsx("div", {
|
|
2512
|
+
ref: portalRef,
|
|
2513
|
+
className: "studio-gallery-demo",
|
|
2514
|
+
inert: true,
|
|
2515
|
+
children: demo_1.render()
|
|
2516
|
+
}) })
|
|
2517
|
+
]
|
|
2518
|
+
}, demo_1.id))
|
|
2519
|
+
})]
|
|
2520
|
+
}, group);
|
|
2521
|
+
})]
|
|
2522
|
+
});
|
|
2523
|
+
$[11] = t5;
|
|
2524
|
+
} else t5 = $[11];
|
|
2525
|
+
return t5;
|
|
2526
|
+
}
|
|
2527
|
+
//#endregion
|
|
2528
|
+
export { ComponentGallery as default };
|