@ifhover/leaf-ui 0.23.0 → 0.24.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/badge/badge.cjs +5 -4
- package/dist/cjs/badge/badge.cjs.map +1 -1
- package/dist/cjs/badge/badge.d.cts +2 -2
- package/dist/cjs/badge/badge.d.cts.map +1 -1
- package/dist/cjs/browser/modules/badge/badge.cjs +5 -4
- package/dist/cjs/browser/modules/badge/badge.cjs.map +1 -1
- package/dist/cjs/browser/modules/card/card.cjs +7 -10
- package/dist/cjs/browser/modules/card/card.cjs.map +1 -1
- package/dist/cjs/browser/modules/checkbox/group.cjs +10 -1
- package/dist/cjs/browser/modules/checkbox/group.cjs.map +1 -1
- package/dist/cjs/browser/modules/checkbox/index.cjs.map +1 -1
- package/dist/cjs/browser/modules/config-provider/helpers.cjs +4 -1
- package/dist/cjs/browser/modules/config-provider/helpers.cjs.map +1 -1
- package/dist/cjs/browser/modules/confirm/confirm.cjs +1 -1
- package/dist/cjs/browser/modules/confirm/confirm.cjs.map +1 -1
- package/dist/cjs/browser/modules/drawer/drawer.cjs +2 -2
- package/dist/cjs/browser/modules/drawer/drawer.cjs.map +1 -1
- package/dist/cjs/browser/modules/index.cjs.map +1 -1
- package/dist/cjs/browser/modules/layout/layout.cjs +9 -1
- package/dist/cjs/browser/modules/layout/layout.cjs.map +1 -1
- package/dist/cjs/browser/modules/menu/menu.cjs +11 -3
- package/dist/cjs/browser/modules/menu/menu.cjs.map +1 -1
- package/dist/cjs/browser/modules/modal/base.cjs +5 -4
- package/dist/cjs/browser/modules/modal/base.cjs.map +1 -1
- package/dist/cjs/browser/modules/modal/modal.cjs +1 -2
- package/dist/cjs/browser/modules/modal/modal.cjs.map +1 -1
- package/dist/cjs/browser/modules/popover/popover.cjs +1 -0
- package/dist/cjs/browser/modules/popover/popover.cjs.map +1 -1
- package/dist/cjs/browser/modules/radio/index.cjs.map +1 -1
- package/dist/cjs/browser/modules/radio/radio.cjs +10 -1
- package/dist/cjs/browser/modules/radio/radio.cjs.map +1 -1
- package/dist/cjs/browser/modules/select/index.cjs.map +1 -1
- package/dist/cjs/browser/modules/select/select.cjs +136 -5
- package/dist/cjs/browser/modules/select/select.cjs.map +1 -1
- package/dist/cjs/browser/modules/select/virtual-list.cjs +1 -0
- package/dist/cjs/browser/modules/select/virtual-list.cjs.map +1 -1
- package/dist/cjs/browser/modules/shared/choice-columns.cjs +101 -0
- package/dist/cjs/browser/modules/shared/choice-columns.cjs.map +1 -0
- package/dist/cjs/browser/modules/shared/date-input.cjs +8 -20
- package/dist/cjs/browser/modules/shared/date-input.cjs.map +1 -1
- package/dist/cjs/browser/modules/shared/floating.cjs +9 -7
- package/dist/cjs/browser/modules/shared/floating.cjs.map +1 -1
- package/dist/cjs/browser/modules/shared/scoped-portal.cjs +3 -1
- package/dist/cjs/browser/modules/shared/scoped-portal.cjs.map +1 -1
- package/dist/cjs/browser/modules/shared/theme-variables.cjs +103 -4
- package/dist/cjs/browser/modules/shared/theme-variables.cjs.map +1 -1
- package/dist/cjs/browser/modules/table/index.cjs.map +1 -1
- package/dist/cjs/browser/modules/table/table-frame.cjs +19 -8
- package/dist/cjs/browser/modules/table/table-frame.cjs.map +1 -1
- package/dist/cjs/browser/modules/table/table.cjs +133 -18
- package/dist/cjs/browser/modules/table/table.cjs.map +1 -1
- package/dist/cjs/browser/modules/table/types.cjs.map +1 -1
- package/dist/cjs/browser/modules/tabs/tabs.cjs +6 -2
- package/dist/cjs/browser/modules/tabs/tabs.cjs.map +1 -1
- package/dist/cjs/browser/modules/theme.cjs +4 -0
- package/dist/cjs/browser/modules/theme.cjs.map +1 -1
- package/dist/cjs/browser/modules/tooltip/tooltip.cjs +1 -0
- package/dist/cjs/browser/modules/tooltip/tooltip.cjs.map +1 -1
- package/dist/cjs/browser/modules/tour/tour.cjs +1 -0
- package/dist/cjs/browser/modules/tour/tour.cjs.map +1 -1
- package/dist/cjs/card/card.cjs +7 -10
- package/dist/cjs/card/card.cjs.map +1 -1
- package/dist/cjs/card/card.d.cts +3 -5
- package/dist/cjs/card/card.d.cts.map +1 -1
- package/dist/cjs/checkbox/group.cjs +10 -1
- package/dist/cjs/checkbox/group.cjs.map +1 -1
- package/dist/cjs/checkbox/group.d.cts +3 -0
- package/dist/cjs/checkbox/group.d.cts.map +1 -1
- package/dist/cjs/checkbox/index.cjs.map +1 -1
- package/dist/cjs/checkbox/index.d.cts +1 -0
- package/dist/cjs/checkbox/index.d.cts.map +1 -1
- package/dist/cjs/config-provider/helpers.cjs +4 -1
- package/dist/cjs/config-provider/helpers.cjs.map +1 -1
- package/dist/cjs/config-provider/helpers.d.cts +1 -1
- package/dist/cjs/config-provider/helpers.d.cts.map +1 -1
- package/dist/cjs/confirm/confirm.cjs +1 -1
- package/dist/cjs/confirm/confirm.cjs.map +1 -1
- package/dist/cjs/drawer/drawer.cjs +2 -2
- package/dist/cjs/drawer/drawer.cjs.map +1 -1
- package/dist/cjs/drawer/drawer.d.cts +0 -2
- package/dist/cjs/drawer/drawer.d.cts.map +1 -1
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/cjs/index.d.cts +3 -2
- package/dist/cjs/index.d.cts.map +1 -1
- package/dist/cjs/layout/layout.cjs +9 -1
- package/dist/cjs/layout/layout.cjs.map +1 -1
- package/dist/cjs/layout/layout.d.cts +2 -0
- package/dist/cjs/layout/layout.d.cts.map +1 -1
- package/dist/cjs/menu/menu.cjs +11 -3
- package/dist/cjs/menu/menu.cjs.map +1 -1
- package/dist/cjs/menu/menu.d.cts +2 -0
- package/dist/cjs/menu/menu.d.cts.map +1 -1
- package/dist/cjs/modal/base.cjs +5 -4
- package/dist/cjs/modal/base.cjs.map +1 -1
- package/dist/cjs/modal/base.d.cts +2 -0
- package/dist/cjs/modal/base.d.cts.map +1 -1
- package/dist/cjs/modal/modal.cjs +1 -2
- package/dist/cjs/modal/modal.cjs.map +1 -1
- package/dist/cjs/modal/modal.d.cts +0 -2
- package/dist/cjs/modal/modal.d.cts.map +1 -1
- package/dist/cjs/popover/popover.cjs +1 -0
- package/dist/cjs/popover/popover.cjs.map +1 -1
- package/dist/cjs/popover/popover.d.cts.map +1 -1
- package/dist/cjs/radio/index.cjs.map +1 -1
- package/dist/cjs/radio/index.d.cts +1 -0
- package/dist/cjs/radio/index.d.cts.map +1 -1
- package/dist/cjs/radio/radio.cjs +10 -1
- package/dist/cjs/radio/radio.cjs.map +1 -1
- package/dist/cjs/radio/radio.d.cts +3 -0
- package/dist/cjs/radio/radio.d.cts.map +1 -1
- package/dist/cjs/select/index.cjs.map +1 -1
- package/dist/cjs/select/index.d.cts +1 -1
- package/dist/cjs/select/index.d.cts.map +1 -1
- package/dist/cjs/select/select.cjs +136 -5
- package/dist/cjs/select/select.cjs.map +1 -1
- package/dist/cjs/select/select.d.cts +5 -1
- package/dist/cjs/select/select.d.cts.map +1 -1
- package/dist/cjs/select/virtual-list.cjs +1 -0
- package/dist/cjs/select/virtual-list.cjs.map +1 -1
- package/dist/cjs/select/virtual-list.d.cts.map +1 -1
- package/dist/cjs/shared/choice-columns.cjs +101 -0
- package/dist/cjs/shared/choice-columns.cjs.map +1 -0
- package/dist/cjs/shared/choice-columns.d.cts +9 -0
- package/dist/cjs/shared/choice-columns.d.cts.map +1 -0
- package/dist/cjs/shared/date-input.cjs +8 -20
- package/dist/cjs/shared/date-input.cjs.map +1 -1
- package/dist/cjs/shared/date-input.d.cts.map +1 -1
- package/dist/cjs/shared/floating.cjs +9 -7
- package/dist/cjs/shared/floating.cjs.map +1 -1
- package/dist/cjs/shared/floating.d.cts.map +1 -1
- package/dist/cjs/shared/scoped-portal.cjs +3 -1
- package/dist/cjs/shared/scoped-portal.cjs.map +1 -1
- package/dist/cjs/shared/theme-variables.cjs +103 -4
- package/dist/cjs/shared/theme-variables.cjs.map +1 -1
- package/dist/cjs/shared/theme-variables.d.cts +6 -1
- package/dist/cjs/shared/theme-variables.d.cts.map +1 -1
- package/dist/cjs/table/index.cjs.map +1 -1
- package/dist/cjs/table/index.d.cts +1 -1
- package/dist/cjs/table/index.d.cts.map +1 -1
- package/dist/cjs/table/table-frame.cjs +19 -8
- package/dist/cjs/table/table-frame.cjs.map +1 -1
- package/dist/cjs/table/table-frame.d.cts +2 -0
- package/dist/cjs/table/table-frame.d.cts.map +1 -1
- package/dist/cjs/table/table.cjs +133 -18
- package/dist/cjs/table/table.cjs.map +1 -1
- package/dist/cjs/table/table.d.cts +4 -2
- package/dist/cjs/table/table.d.cts.map +1 -1
- package/dist/cjs/table/types.cjs.map +1 -1
- package/dist/cjs/table/types.d.cts +16 -0
- package/dist/cjs/table/types.d.cts.map +1 -1
- package/dist/cjs/tabs/tabs.cjs +6 -2
- package/dist/cjs/tabs/tabs.cjs.map +1 -1
- package/dist/cjs/tabs/tabs.d.cts +5 -2
- package/dist/cjs/tabs/tabs.d.cts.map +1 -1
- package/dist/cjs/theme.cjs +4 -0
- package/dist/cjs/theme.cjs.map +1 -1
- package/dist/cjs/theme.d.cts +4 -0
- package/dist/cjs/theme.d.cts.map +1 -1
- package/dist/cjs/tooltip/tooltip.cjs +1 -0
- package/dist/cjs/tooltip/tooltip.cjs.map +1 -1
- package/dist/cjs/tooltip/tooltip.d.cts.map +1 -1
- package/dist/cjs/tour/tour.cjs +1 -0
- package/dist/cjs/tour/tour.cjs.map +1 -1
- package/dist/cjs/tour/tour.d.cts.map +1 -1
- package/dist/esm/badge/badge.d.ts +2 -2
- package/dist/esm/badge/badge.d.ts.map +1 -1
- package/dist/esm/badge/badge.js +5 -4
- package/dist/esm/badge/badge.js.map +1 -1
- package/dist/esm/browser/modules/badge/badge.js +5 -4
- package/dist/esm/browser/modules/badge/badge.js.map +1 -1
- package/dist/esm/browser/modules/card/card.js +7 -10
- package/dist/esm/browser/modules/card/card.js.map +1 -1
- package/dist/esm/browser/modules/checkbox/group.js +10 -1
- package/dist/esm/browser/modules/checkbox/group.js.map +1 -1
- package/dist/esm/browser/modules/checkbox/index.js.map +1 -1
- package/dist/esm/browser/modules/config-provider/helpers.js +4 -1
- package/dist/esm/browser/modules/config-provider/helpers.js.map +1 -1
- package/dist/esm/browser/modules/confirm/confirm.js +1 -1
- package/dist/esm/browser/modules/confirm/confirm.js.map +1 -1
- package/dist/esm/browser/modules/drawer/drawer.js +2 -2
- package/dist/esm/browser/modules/drawer/drawer.js.map +1 -1
- package/dist/esm/browser/modules/index.js.map +1 -1
- package/dist/esm/browser/modules/layout/layout.js +9 -1
- package/dist/esm/browser/modules/layout/layout.js.map +1 -1
- package/dist/esm/browser/modules/menu/menu.js +11 -3
- package/dist/esm/browser/modules/menu/menu.js.map +1 -1
- package/dist/esm/browser/modules/modal/base.js +5 -4
- package/dist/esm/browser/modules/modal/base.js.map +1 -1
- package/dist/esm/browser/modules/modal/modal.js +1 -2
- package/dist/esm/browser/modules/modal/modal.js.map +1 -1
- package/dist/esm/browser/modules/popover/popover.js +1 -0
- package/dist/esm/browser/modules/popover/popover.js.map +1 -1
- package/dist/esm/browser/modules/radio/index.js.map +1 -1
- package/dist/esm/browser/modules/radio/radio.js +10 -1
- package/dist/esm/browser/modules/radio/radio.js.map +1 -1
- package/dist/esm/browser/modules/select/index.js.map +1 -1
- package/dist/esm/browser/modules/select/select.js +137 -6
- package/dist/esm/browser/modules/select/select.js.map +1 -1
- package/dist/esm/browser/modules/select/virtual-list.js +1 -0
- package/dist/esm/browser/modules/select/virtual-list.js.map +1 -1
- package/dist/esm/browser/modules/shared/choice-columns.js +47 -0
- package/dist/esm/browser/modules/shared/choice-columns.js.map +1 -0
- package/dist/esm/browser/modules/shared/date-input.js +8 -20
- package/dist/esm/browser/modules/shared/date-input.js.map +1 -1
- package/dist/esm/browser/modules/shared/floating.js +10 -8
- package/dist/esm/browser/modules/shared/floating.js.map +1 -1
- package/dist/esm/browser/modules/shared/scoped-portal.js +3 -1
- package/dist/esm/browser/modules/shared/scoped-portal.js.map +1 -1
- package/dist/esm/browser/modules/shared/theme-variables.js +101 -4
- package/dist/esm/browser/modules/shared/theme-variables.js.map +1 -1
- package/dist/esm/browser/modules/table/index.js.map +1 -1
- package/dist/esm/browser/modules/table/table-frame.js +20 -9
- package/dist/esm/browser/modules/table/table-frame.js.map +1 -1
- package/dist/esm/browser/modules/table/table.js +133 -18
- package/dist/esm/browser/modules/table/table.js.map +1 -1
- package/dist/esm/browser/modules/table/types.js.map +1 -1
- package/dist/esm/browser/modules/tabs/tabs.js +6 -2
- package/dist/esm/browser/modules/tabs/tabs.js.map +1 -1
- package/dist/esm/browser/modules/theme.js +4 -0
- package/dist/esm/browser/modules/theme.js.map +1 -1
- package/dist/esm/browser/modules/tooltip/tooltip.js +1 -0
- package/dist/esm/browser/modules/tooltip/tooltip.js.map +1 -1
- package/dist/esm/browser/modules/tour/tour.js +1 -0
- package/dist/esm/browser/modules/tour/tour.js.map +1 -1
- package/dist/esm/card/card.d.ts +3 -5
- package/dist/esm/card/card.d.ts.map +1 -1
- package/dist/esm/card/card.js +7 -10
- package/dist/esm/card/card.js.map +1 -1
- package/dist/esm/checkbox/group.d.ts +3 -0
- package/dist/esm/checkbox/group.d.ts.map +1 -1
- package/dist/esm/checkbox/group.js +10 -1
- package/dist/esm/checkbox/group.js.map +1 -1
- package/dist/esm/checkbox/index.d.ts +1 -0
- package/dist/esm/checkbox/index.d.ts.map +1 -1
- package/dist/esm/checkbox/index.js.map +1 -1
- package/dist/esm/config-provider/helpers.d.ts +1 -1
- package/dist/esm/config-provider/helpers.d.ts.map +1 -1
- package/dist/esm/config-provider/helpers.js +4 -1
- package/dist/esm/config-provider/helpers.js.map +1 -1
- package/dist/esm/confirm/confirm.js +1 -1
- package/dist/esm/confirm/confirm.js.map +1 -1
- package/dist/esm/drawer/drawer.d.ts +0 -2
- package/dist/esm/drawer/drawer.d.ts.map +1 -1
- package/dist/esm/drawer/drawer.js +2 -2
- package/dist/esm/drawer/drawer.js.map +1 -1
- package/dist/esm/index.d.ts +3 -2
- package/dist/esm/index.d.ts.map +1 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/layout/layout.d.ts +2 -0
- package/dist/esm/layout/layout.d.ts.map +1 -1
- package/dist/esm/layout/layout.js +9 -1
- package/dist/esm/layout/layout.js.map +1 -1
- package/dist/esm/menu/menu.d.ts +2 -0
- package/dist/esm/menu/menu.d.ts.map +1 -1
- package/dist/esm/menu/menu.js +11 -3
- package/dist/esm/menu/menu.js.map +1 -1
- package/dist/esm/modal/base.d.ts +2 -0
- package/dist/esm/modal/base.d.ts.map +1 -1
- package/dist/esm/modal/base.js +5 -4
- package/dist/esm/modal/base.js.map +1 -1
- package/dist/esm/modal/modal.d.ts +0 -2
- package/dist/esm/modal/modal.d.ts.map +1 -1
- package/dist/esm/modal/modal.js +1 -2
- package/dist/esm/modal/modal.js.map +1 -1
- package/dist/esm/popover/popover.d.ts.map +1 -1
- package/dist/esm/popover/popover.js +1 -0
- package/dist/esm/popover/popover.js.map +1 -1
- package/dist/esm/radio/index.d.ts +1 -0
- package/dist/esm/radio/index.d.ts.map +1 -1
- package/dist/esm/radio/index.js.map +1 -1
- package/dist/esm/radio/radio.d.ts +3 -0
- package/dist/esm/radio/radio.d.ts.map +1 -1
- package/dist/esm/radio/radio.js +10 -1
- package/dist/esm/radio/radio.js.map +1 -1
- package/dist/esm/select/index.d.ts +1 -1
- package/dist/esm/select/index.d.ts.map +1 -1
- package/dist/esm/select/index.js.map +1 -1
- package/dist/esm/select/select.d.ts +5 -1
- package/dist/esm/select/select.d.ts.map +1 -1
- package/dist/esm/select/select.js +137 -6
- package/dist/esm/select/select.js.map +1 -1
- package/dist/esm/select/virtual-list.d.ts.map +1 -1
- package/dist/esm/select/virtual-list.js +1 -0
- package/dist/esm/select/virtual-list.js.map +1 -1
- package/dist/esm/shared/choice-columns.d.ts +9 -0
- package/dist/esm/shared/choice-columns.d.ts.map +1 -0
- package/dist/esm/shared/choice-columns.js +47 -0
- package/dist/esm/shared/choice-columns.js.map +1 -0
- package/dist/esm/shared/date-input.d.ts.map +1 -1
- package/dist/esm/shared/date-input.js +8 -20
- package/dist/esm/shared/date-input.js.map +1 -1
- package/dist/esm/shared/floating.d.ts.map +1 -1
- package/dist/esm/shared/floating.js +10 -8
- package/dist/esm/shared/floating.js.map +1 -1
- package/dist/esm/shared/scoped-portal.js +3 -1
- package/dist/esm/shared/scoped-portal.js.map +1 -1
- package/dist/esm/shared/theme-variables.d.ts +6 -1
- package/dist/esm/shared/theme-variables.d.ts.map +1 -1
- package/dist/esm/shared/theme-variables.js +101 -4
- package/dist/esm/shared/theme-variables.js.map +1 -1
- package/dist/esm/styles/alert.css +1 -1
- package/dist/esm/styles/anchor.css +1 -1
- package/dist/esm/styles/autocomplete.css +1 -1
- package/dist/esm/styles/avatar.css +1 -1
- package/dist/esm/styles/backtop.css +1 -1
- package/dist/esm/styles/badge.css +1 -1
- package/dist/esm/styles/breadcrumb.css +1 -1
- package/dist/esm/styles/button.css +1 -1
- package/dist/esm/styles/calendar.css +1 -1
- package/dist/esm/styles/card.css +1 -1
- package/dist/esm/styles/carousel.css +1 -1
- package/dist/esm/styles/cascader.css +1 -1
- package/dist/esm/styles/checkbox.css +1 -1
- package/dist/esm/styles/collapse.css +1 -1
- package/dist/esm/styles/colorpicker.css +1 -1
- package/dist/esm/styles/components/alert.css +1 -1
- package/dist/esm/styles/components/autocomplete.css +1 -1
- package/dist/esm/styles/components/badge.css +1 -1
- package/dist/esm/styles/components/button.css +1 -1
- package/dist/esm/styles/components/card.css +1 -1
- package/dist/esm/styles/components/checkbox.css +1 -1
- package/dist/esm/styles/components/datepicker.css +1 -1
- package/dist/esm/styles/components/drawer.css +1 -1
- package/dist/esm/styles/components/dropdown.css +1 -1
- package/dist/esm/styles/components/layout.css +1 -1
- package/dist/esm/styles/components/mentions.css +1 -1
- package/dist/esm/styles/components/menu.css +1 -1
- package/dist/esm/styles/components/modal.css +1 -1
- package/dist/esm/styles/components/radio.css +1 -1
- package/dist/esm/styles/components/select.css +1 -1
- package/dist/esm/styles/components/shared-calendar.css +1 -1
- package/dist/esm/styles/components/table.css +1 -1
- package/dist/esm/styles/components/tabs.css +1 -1
- package/dist/esm/styles/components/treeselect.css +1 -1
- package/dist/esm/styles/config-provider.css +1 -1
- package/dist/esm/styles/confirm.css +1 -1
- package/dist/esm/styles/datepicker.css +1 -1
- package/dist/esm/styles/daterangepicker.css +1 -1
- package/dist/esm/styles/descriptions.css +1 -1
- package/dist/esm/styles/divider.css +1 -1
- package/dist/esm/styles/drawer.css +1 -1
- package/dist/esm/styles/dropdown.css +1 -1
- package/dist/esm/styles/empty.css +1 -1
- package/dist/esm/styles/errorboundary.css +1 -1
- package/dist/esm/styles/filelist.css +1 -1
- package/dist/esm/styles/flex.css +1 -1
- package/dist/esm/styles/floatbutton.css +1 -1
- package/dist/esm/styles/form.css +1 -1
- package/dist/esm/styles/grid.css +1 -1
- package/dist/esm/styles/image.css +1 -1
- package/dist/esm/styles/index.css +1 -1
- package/dist/esm/styles/index.css.map +1 -1
- package/dist/esm/styles/infinitescroll.css +1 -1
- package/dist/esm/styles/input.css +1 -1
- package/dist/esm/styles/inputmask.css +1 -1
- package/dist/esm/styles/inputnumber.css +1 -1
- package/dist/esm/styles/inputotp.css +1 -1
- package/dist/esm/styles/layout.css +1 -1
- package/dist/esm/styles/loading.css +1 -1
- package/dist/esm/styles/loadingbar.css +1 -1
- package/dist/esm/styles/masonry.css +1 -1
- package/dist/esm/styles/mentions.css +1 -1
- package/dist/esm/styles/menu.css +1 -1
- package/dist/esm/styles/message.css +1 -1
- package/dist/esm/styles/modal.css +1 -1
- package/dist/esm/styles/notification.css +1 -1
- package/dist/esm/styles/pagination.css +1 -1
- package/dist/esm/styles/popconfirm.css +1 -1
- package/dist/esm/styles/popover.css +1 -1
- package/dist/esm/styles/progress.css +1 -1
- package/dist/esm/styles/qrcode.css +1 -1
- package/dist/esm/styles/radio.css +1 -1
- package/dist/esm/styles/rate.css +1 -1
- package/dist/esm/styles/result.css +1 -1
- package/dist/esm/styles/scrollarea.css +1 -1
- package/dist/esm/styles/scrollbar.css +1 -1
- package/dist/esm/styles/select.css +1 -1
- package/dist/esm/styles/skeleton.css +1 -1
- package/dist/esm/styles/slider.css +1 -1
- package/dist/esm/styles/space.css +1 -1
- package/dist/esm/styles/splitter.css +1 -1
- package/dist/esm/styles/statistic.css +1 -1
- package/dist/esm/styles/steps.css +1 -1
- package/dist/esm/styles/switch.css +1 -1
- package/dist/esm/styles/table.css +1 -1
- package/dist/esm/styles/tabs.css +1 -1
- package/dist/esm/styles/tag.css +1 -1
- package/dist/esm/styles/textarea.css +1 -1
- package/dist/esm/styles/timeline.css +1 -1
- package/dist/esm/styles/tooltip.css +1 -1
- package/dist/esm/styles/tour.css +1 -1
- package/dist/esm/styles/transfer.css +1 -1
- package/dist/esm/styles/tree.css +1 -1
- package/dist/esm/styles/treeselect.css +1 -1
- package/dist/esm/styles/typography.css +1 -1
- package/dist/esm/styles/upload.css +1 -1
- package/dist/esm/styles/virtuallist.css +1 -1
- package/dist/esm/table/index.d.ts +1 -1
- package/dist/esm/table/index.d.ts.map +1 -1
- package/dist/esm/table/index.js.map +1 -1
- package/dist/esm/table/table-frame.d.ts +2 -0
- package/dist/esm/table/table-frame.d.ts.map +1 -1
- package/dist/esm/table/table-frame.js +20 -9
- package/dist/esm/table/table-frame.js.map +1 -1
- package/dist/esm/table/table.d.ts +4 -2
- package/dist/esm/table/table.d.ts.map +1 -1
- package/dist/esm/table/table.js +133 -18
- package/dist/esm/table/table.js.map +1 -1
- package/dist/esm/table/types.d.ts +16 -0
- package/dist/esm/table/types.d.ts.map +1 -1
- package/dist/esm/table/types.js.map +1 -1
- package/dist/esm/tabs/tabs.d.ts +5 -2
- package/dist/esm/tabs/tabs.d.ts.map +1 -1
- package/dist/esm/tabs/tabs.js +6 -2
- package/dist/esm/tabs/tabs.js.map +1 -1
- package/dist/esm/theme.d.ts +4 -0
- package/dist/esm/theme.d.ts.map +1 -1
- package/dist/esm/theme.js +4 -0
- package/dist/esm/theme.js.map +1 -1
- package/dist/esm/tooltip/tooltip.d.ts.map +1 -1
- package/dist/esm/tooltip/tooltip.js +1 -0
- package/dist/esm/tooltip/tooltip.js.map +1 -1
- package/dist/esm/tour/tour.d.ts.map +1 -1
- package/dist/esm/tour/tour.js +1 -0
- package/dist/esm/tour/tour.js.map +1 -1
- package/package.json +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"drawer/drawer.cjs","sources":["webpack://webpack/runtime/define_property_getters","webpack://webpack/runtime/has_own_property","webpack://webpack/runtime/make_namespace_object","../../../../../src/drawer/drawer.tsx"],"sourcesContent":["__webpack_require__.d = (exports, getters, values) => {\n\tvar define = (defs, kind) => {\n\t\tfor(var key in defs) {\n\t\t\tif(__webpack_require__.o(defs, key) && !__webpack_require__.o(exports, key)) {\n\t\t\t\tObject.defineProperty(exports, key, { enumerable: true, [kind]: defs[key] });\n\t\t\t}\n\t\t}\n\t};\n\tdefine(getters, \"get\");\n\tdefine(values, \"value\");\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","import { X } from 'lucide-react';\nimport {\n type HTMLAttributes,\n type ReactNode,\n type Ref,\n useContext,\n useEffect,\n useId,\n useRef,\n useState,\n} from 'react';\nimport { useComponentProps } from '../config-provider/component-defaults';\nimport { useLeafConfig } from '../config-provider/context';\nimport { ScrollbarControl } from '../scrollbar/scrollbar';\nimport { classes } from '../shared/classes';\nimport { type DialogFocusOptions, useDialog, useOverlayLayer } from '../shared/dialog';\nimport { inertProps } from '../shared/inert';\nimport { OverlayOwner } from '../shared/overlay-owner';\nimport { resolveDialogPaddingFlags, resolvePaddingVars } from '../shared/padding';\nimport { useContentTransition, usePresence } from '../shared/presence';\nimport { ScopedPortal } from '../shared/scoped-portal';\nimport type { ContainerPadding } from '../shared/types';\nimport { type TabsProps, useTabsParts } from '../tabs/tabs';\n\n/** Tabs controls integrated with the drawer; Drawer fixes the line type and top placement. */\nexport interface DrawerTabsProps extends Omit<TabsProps, 'type' | 'placement' | 'children'> {}\n\nexport interface DrawerProps\n extends Omit<HTMLAttributes<HTMLDivElement>, 'title' | 'onResize'>,\n DialogFocusOptions {\n open: boolean;\n title?: ReactNode;\n description?: ReactNode;\n /** Embedded tabs placed below the heading, or replacing it when no title is supplied. */\n tabs?: DrawerTabsProps;\n icon?: ReactNode;\n /** Separate the header and footer with subtle borders. */\n divided?: boolean;\n /** Customize inner padding for the drawer or individual header/body/footer regions. */\n padding?: ContainerPadding;\n footer?: ReactNode;\n extra?: ReactNode;\n placement?: 'left' | 'right' | 'top' | 'bottom';\n width?: number | string;\n height?: number | string;\n closable?: boolean;\n maskClosable?: boolean;\n keyboard?: boolean;\n onClose?: () => void;\n afterClose?: () => void;\n forceRender?: boolean;\n destroyOnClose?: boolean;\n preserve?: boolean;\n container?: Element | DocumentFragment | (() => Element | DocumentFragment);\n push?: boolean | number;\n /** Show a swipe handle bar along the leading edge and allow pointer dragging to close. Defaults to `true` when `placement=\"bottom\"`. */\n showSwipeHandle?: boolean;\n resizable?: boolean;\n minSize?: number;\n maxSize?: number;\n onResize?: (size: number) => void;\n}\n\ninterface DrawerInnerProps {\n id: string;\n open: boolean;\n title?: ReactNode;\n description?: ReactNode;\n tabs?: DrawerTabsProps;\n icon?: ReactNode;\n extra?: ReactNode;\n footer?: ReactNode;\n closable: boolean;\n onClose?: () => void;\n contentRef: Ref<HTMLDivElement>;\n ariaLabel?: string;\n ariaLabelledBy?: string;\n children?: ReactNode;\n}\n\ninterface DrawerTabsLayoutProps {\n open: boolean;\n tabs: DrawerTabsProps;\n id: string;\n title?: ReactNode;\n hasHeading: boolean;\n extraNode: ReactNode;\n contentRef: Ref<HTMLDivElement>;\n ariaLabel?: string;\n ariaLabelledBy?: string;\n children?: ReactNode;\n}\n\nfunction hasRenderableNode(value: ReactNode): boolean {\n return value != null && typeof value !== 'boolean';\n}\n\nfunction DrawerBody({\n id,\n title,\n ariaLabel,\n contentRef,\n children,\n}: {\n id: string;\n title?: ReactNode;\n ariaLabel?: string;\n contentRef: Ref<HTMLDivElement>;\n children?: ReactNode;\n}) {\n return (\n <ScrollbarControl\n className=\"leaf-drawer__body\"\n viewportClassName=\"leaf-drawer__viewport\"\n orientation=\"vertical\"\n role={title != null || ariaLabel ? 'region' : 'presentation'}\n aria-labelledby={title != null ? `${id}-title` : undefined}\n aria-label={title == null ? ariaLabel : undefined}\n >\n <div ref={contentRef} className=\"leaf-drawer__content\">\n {children}\n </div>\n </ScrollbarControl>\n );\n}\n\nfunction DrawerTabsLayout({\n open,\n tabs,\n id,\n title,\n hasHeading,\n extraNode,\n contentRef,\n ariaLabel,\n ariaLabelledBy,\n children,\n}: DrawerTabsLayoutProps) {\n const tabExtra =\n !hasHeading && extraNode != null ? (\n <div className=\"leaf-dialog-tab-extra leaf-drawer__tab-extra\">\n {tabs.extra}\n {extraNode}\n </div>\n ) : (\n tabs.extra\n );\n const tabLabel = tabs['aria-label'] ?? (typeof title === 'string' ? title : ariaLabel);\n const tabLabelledBy =\n tabs['aria-labelledby'] ??\n (tabs['aria-label'] == null && title != null\n ? `${id}-title`\n : tabs['aria-label'] == null\n ? ariaLabelledBy\n : undefined);\n const parts = useTabsParts({\n ...tabs,\n type: 'line',\n placement: 'top',\n size: tabs.size ?? 'md',\n 'aria-label': tabLabel,\n 'aria-labelledby': tabLabelledBy,\n extra: tabExtra,\n className: classes(\n 'leaf-dialog-tabs',\n hasHeading && 'leaf-dialog-tabs--headed',\n 'leaf-drawer__tabs',\n tabs.className,\n ),\n panelsClassName: 'leaf-dialog-panels',\n visibilityKey: open,\n });\n const hasContent = Boolean(parts?.hasPanels) || hasRenderableNode(children);\n\n return (\n <>\n {parts && <div {...parts.rootProps}>{parts.header}</div>}\n {hasContent && (\n <DrawerBody id={id} title={title} ariaLabel={ariaLabel} contentRef={contentRef}>\n {parts?.panels}\n {children}\n </DrawerBody>\n )}\n </>\n );\n}\n\nfunction DrawerInner({\n id,\n open,\n title,\n description,\n tabs,\n icon,\n extra,\n footer,\n closable,\n onClose,\n contentRef,\n ariaLabel,\n ariaLabelledBy,\n children,\n}: DrawerInnerProps) {\n const { messages } = useLeafConfig();\n const hasTabs = Boolean(tabs?.items?.length);\n const hasHeading = title != null || description != null || icon != null;\n const closeButton = closable ? (\n <button\n type=\"button\"\n className=\"leaf-drawer__close\"\n aria-label={messages.common.close}\n onClick={onClose}\n >\n <X size={16} aria-hidden=\"true\" />\n </button>\n ) : null;\n const extraNode = extra != null ? <div className=\"leaf-drawer__extra\">{extra}</div> : null;\n\n return (\n <>\n {(hasHeading || (!hasTabs && extra != null)) && (\n <div\n className={classes('leaf-drawer__header', !hasHeading && 'leaf-drawer__header--compact')}\n >\n {icon != null && (\n <span className=\"leaf-drawer__icon\" aria-hidden=\"true\">\n {icon}\n </span>\n )}\n {(title != null || description != null) && (\n <div className=\"leaf-drawer__heading\">\n {title != null && <h2 id={`${id}-title`}>{title}</h2>}\n {description != null && (\n <div id={`${id}-description`} className=\"leaf-drawer__description\">\n {description}\n </div>\n )}\n </div>\n )}\n {extraNode}\n </div>\n )}\n {closeButton}\n {hasTabs && tabs ? (\n <DrawerTabsLayout\n open={open}\n tabs={tabs}\n id={id}\n title={title}\n hasHeading={hasHeading}\n extraNode={extraNode}\n contentRef={contentRef}\n ariaLabel={ariaLabel}\n ariaLabelledBy={ariaLabelledBy}\n >\n {children}\n </DrawerTabsLayout>\n ) : (\n <DrawerBody id={id} title={title} ariaLabel={ariaLabel} contentRef={contentRef}>\n {children}\n </DrawerBody>\n )}\n {footer != null && <div className=\"leaf-drawer__footer\">{footer}</div>}\n </>\n );\n}\n\nfunction DrawerSurface({\n open,\n title,\n description,\n tabs,\n icon,\n divided = false,\n padding,\n footer,\n extra,\n placement = 'right',\n width = 380,\n height = 300,\n closable = true,\n maskClosable = true,\n keyboard = true,\n onClose,\n afterClose,\n forceRender = false,\n destroyOnClose = false,\n preserve,\n initialFocus,\n returnFocus,\n container: _container,\n push = false,\n showSwipeHandle,\n resizable = false,\n minSize = 240,\n maxSize = 900,\n onResize,\n children,\n className,\n style,\n ...props\n}: DrawerProps) {\n const { messages, maskBlur, theme } = useLeafConfig();\n const id = useId();\n const panel = useRef<HTMLDivElement>(null);\n const backdrop = useRef<HTMLButtonElement>(null);\n const content = useRef<HTMLDivElement>(null);\n const present = usePresence(open, backdrop);\n const layer = useOverlayLayer(present, open);\n const hasHeading = title != null || description != null || icon != null;\n const hasTabs = Boolean(tabs?.items?.length);\n const tabsSize = hasTabs ? (tabs?.size ?? 'md') : undefined;\n const swipeHandleVisible = showSwipeHandle ?? placement === 'bottom';\n const paddingStyle = resolvePaddingVars('drawer', padding);\n const paddingFlags = resolveDialogPaddingFlags(padding);\n const drawerTheme = theme.components?.Drawer;\n const surfaceFlags = {\n ...(drawerTheme?.headerBackground !== undefined ? { 'data-header-surface': '' } : {}),\n ...(drawerTheme?.footerBackground !== undefined ? { 'data-footer-surface': '' } : {}),\n };\n const contentRevision = useRef({ children, revision: 0 });\n if (children !== contentRevision.current.children)\n contentRevision.current = { children, revision: contentRevision.current.revision + 1 };\n useContentTransition(content, `${open}:${contentRevision.current.revision}`, 0, true);\n const owner = useContext(OverlayOwner);\n const [resized, setResized] = useState<number>();\n const stopDragging = useRef<(() => void) | undefined>(undefined);\n const stopSwiping = useRef<(() => void) | undefined>(undefined);\n useEffect(\n () => () => {\n stopDragging.current?.();\n stopSwiping.current?.();\n },\n [],\n );\n useEffect(() => {\n if (!open) stopSwiping.current?.();\n else {\n panel.current?.removeAttribute('data-swiping');\n panel.current?.style.removeProperty('--leaf-drawer-swipe-transform');\n }\n }, [open]);\n const horizontal = placement === 'left' || placement === 'right';\n // biome-ignore lint/correctness/useExhaustiveDependencies: Resizing resets when the configured dimensions change.\n useEffect(() => {\n setResized(undefined);\n }, [width, height]);\n useEffect(() => {\n if (!open || !push || !owner) return;\n const parent = document.getElementById(owner);\n if (!parent) return;\n const previous = parent.style.transform;\n const distance = typeof push === 'number' ? push : 40;\n parent.style.transform = `translate${horizontal ? 'X' : 'Y'}(${placement === 'right' || placement === 'bottom' ? -distance : distance}px)`;\n return () => {\n parent.style.transform = previous;\n };\n }, [open, push, owner, placement, horizontal]);\n const previous = useRef(false);\n useEffect(() => {\n if (previous.current && !present) afterClose?.();\n previous.current = present;\n }, [present, afterClose]);\n useDialog(open, panel, id, () => onClose?.(), keyboard, { initialFocus, returnFocus });\n const visited = useRef(false);\n if (open) visited.current = true;\n if (\n !present &&\n !forceRender &&\n ((preserve === undefined ? destroyOnClose : !preserve) || !visited.current)\n )\n return null;\n return (\n <div\n hidden={!present}\n className={classes('leaf-drawer-mask', `leaf-drawer-mask--${placement}`)}\n style={layer.maskStyle}\n data-blur={maskBlur ? undefined : 'off'}\n data-state={open ? 'open' : 'closing'}\n aria-hidden={!open || undefined}\n {...inertProps(!open)}\n >\n <button\n ref={backdrop}\n type=\"button\"\n tabIndex={-1}\n className=\"leaf-drawer-backdrop\"\n aria-label={messages.common.close}\n onClick={() => {\n if (maskClosable) onClose?.();\n }}\n />\n <div\n {...props}\n ref={panel}\n id={props.id ?? id}\n role=\"dialog\"\n aria-modal=\"true\"\n aria-labelledby={title != null ? `${id}-title` : props['aria-labelledby']}\n aria-describedby={\n [props['aria-describedby'], description != null && `${id}-description`]\n .filter(Boolean)\n .join(' ') || undefined\n }\n tabIndex={-1}\n className={classes(\n 'leaf-drawer',\n `leaf-drawer--placement-${placement}`,\n swipeHandleVisible && 'leaf-drawer--swipeable',\n divided && 'leaf-drawer--divided',\n hasHeading && 'leaf-drawer--headed',\n hasTabs && 'leaf-drawer--tabbed',\n closable && 'leaf-drawer--closable',\n className,\n )}\n data-tabs-size={tabsSize}\n {...paddingFlags}\n {...surfaceFlags}\n style={{\n ...(horizontal\n ? { width: resized ?? width, height: '100%' }\n : { height: resized ?? height, width: '100%' }),\n ...layer.popupStyle,\n ...paddingStyle,\n ...style,\n }}\n >\n {resizable && (\n // biome-ignore lint/a11y/useSemanticElements: This is the adjustable ARIA window-splitter handle, not a decorative separator.\n <div\n role=\"separator\"\n tabIndex={0}\n aria-label={messages.drawer.resize}\n aria-orientation={horizontal ? 'vertical' : 'horizontal'}\n aria-valuemin={minSize}\n aria-valuemax={maxSize}\n aria-valuenow={\n resized ??\n (typeof (horizontal ? width : height) === 'number'\n ? Number(horizontal ? width : height)\n : undefined)\n }\n className=\"leaf-drawer__resize\"\n onPointerDown={(event) => {\n if (!panel.current) return;\n stopDragging.current?.();\n event.preventDefault();\n event.currentTarget.setPointerCapture?.(event.pointerId);\n const start = horizontal ? event.clientX : event.clientY;\n const bounds = panel.current.getBoundingClientRect();\n const size = horizontal ? bounds.width : bounds.height;\n const update = (event: PointerEvent) => {\n const next = Math.min(\n maxSize,\n Math.max(\n minSize,\n size +\n ((horizontal ? event.clientX : event.clientY) - start) *\n (placement === 'right' || placement === 'bottom' ? -1 : 1),\n ),\n );\n setResized(next);\n onResize?.(next);\n };\n const end = () => {\n window.removeEventListener('pointermove', update);\n window.removeEventListener('pointerup', end);\n window.removeEventListener('pointercancel', end);\n stopDragging.current = undefined;\n };\n stopDragging.current = end;\n window.addEventListener('pointermove', update);\n window.addEventListener('pointerup', end, { once: true });\n window.addEventListener('pointercancel', end, { once: true });\n }}\n onKeyDown={(event) => {\n if (!panel.current) return;\n if (!['ArrowLeft', 'ArrowRight', 'ArrowUp', 'ArrowDown'].includes(event.key)) return;\n event.preventDefault();\n const bounds = panel.current.getBoundingClientRect();\n const size = horizontal ? bounds.width : bounds.height;\n const next = Math.min(\n maxSize,\n Math.max(\n minSize,\n size +\n (['ArrowRight', 'ArrowDown'].includes(event.key) ? 10 : -10) *\n (placement === 'right' || placement === 'bottom' ? -1 : 1),\n ),\n );\n setResized(next);\n onResize?.(next);\n }}\n />\n )}\n {swipeHandleVisible && (\n <div\n className={classes(\n 'leaf-drawer__swipe-handle',\n `leaf-drawer__swipe-handle--${placement}`,\n )}\n data-swipe-handle=\"\"\n aria-hidden=\"true\"\n onPointerDown={(event) => {\n if (!panel.current || (event.button !== 0 && event.pointerType === 'mouse')) return;\n stopSwiping.current?.();\n event.preventDefault();\n event.currentTarget.setPointerCapture?.(event.pointerId);\n const node = panel.current;\n const startX = event.clientX;\n const startY = event.clientY;\n const startTime = Date.now();\n const bounds = node.getBoundingClientRect();\n const panelSize = horizontal ? bounds.width : bounds.height;\n let latestOffset = 0;\n const getOffset = (pointerEvent: PointerEvent) => {\n const raw =\n placement === 'bottom'\n ? pointerEvent.clientY - startY\n : placement === 'top'\n ? startY - pointerEvent.clientY\n : placement === 'right'\n ? pointerEvent.clientX - startX\n : startX - pointerEvent.clientX;\n return Math.max(0, raw);\n };\n const formatTransform = (offset: number) =>\n placement === 'bottom'\n ? `translateY(${offset}px)`\n : placement === 'top'\n ? `translateY(${-offset}px)`\n : placement === 'right'\n ? `translateX(${offset}px)`\n : `translateX(${-offset}px)`;\n node.setAttribute('data-swiping', 'true');\n const update = (moveEvent: PointerEvent) => {\n latestOffset = getOffset(moveEvent);\n node.style.setProperty(\n '--leaf-drawer-swipe-transform',\n formatTransform(latestOffset),\n );\n };\n const cleanup = () => {\n window.removeEventListener('pointermove', update);\n window.removeEventListener('pointerup', finish);\n window.removeEventListener('pointercancel', finish);\n stopSwiping.current = undefined;\n };\n const finish = (endEvent?: PointerEvent) => {\n cleanup();\n const finalOffset = endEvent ? getOffset(endEvent) : latestOffset;\n const elapsed = Math.max(1, Date.now() - startTime);\n const threshold = Math.min(120, Math.max(48, panelSize * 0.3));\n const velocity = finalOffset / elapsed;\n const shouldClose =\n endEvent?.type === 'pointerup' &&\n (finalOffset >= threshold || (finalOffset > 24 && velocity > 0.4));\n node.removeAttribute('data-swiping');\n if (shouldClose) {\n onClose?.();\n if (typeof requestAnimationFrame === 'function') {\n requestAnimationFrame(() =>\n node.style.removeProperty('--leaf-drawer-swipe-transform'),\n );\n } else {\n node.style.removeProperty('--leaf-drawer-swipe-transform');\n }\n return;\n }\n node.style.removeProperty('--leaf-drawer-swipe-transform');\n };\n stopSwiping.current = () => {\n cleanup();\n node.removeAttribute('data-swiping');\n node.style.removeProperty('--leaf-drawer-swipe-transform');\n };\n window.addEventListener('pointermove', update);\n window.addEventListener('pointerup', finish, { once: true });\n window.addEventListener('pointercancel', finish, { once: true });\n }}\n >\n <span className=\"leaf-drawer__swipe-bar\" />\n </div>\n )}\n <OverlayOwner.Provider value={id}>\n <DrawerInner\n id={id}\n open={open}\n title={title}\n description={description}\n tabs={tabs}\n icon={icon}\n extra={extra}\n footer={footer}\n closable={closable}\n onClose={onClose}\n contentRef={content}\n ariaLabel={props['aria-label']}\n ariaLabelledBy={props['aria-labelledby']}\n >\n {children}\n </DrawerInner>\n </OverlayOwner.Provider>\n </div>\n </div>\n );\n}\nexport function Drawer(rawProps: DrawerProps) {\n const props = useComponentProps('Drawer', rawProps);\n const visited = useRef(false);\n // 首次打开或显式 forceRender 前保留行内锚点并延迟挂载 ScopedPortal,避免提前在 body 占位。\n if (props.open || props.forceRender) visited.current = true;\n if (!visited.current) return <span hidden />;\n return (\n <ScopedPortal container={props.container}>\n <DrawerSurface {...props} />\n </ScopedPortal>\n );\n}\n"],"names":["X","useContext","useEffect","useId","useRef","useState","useComponentProps","useLeafConfig","ScrollbarControl","classes","useDialog","useOverlayLayer","inertProps","OverlayOwner","resolveDialogPaddingFlags","resolvePaddingVars","useContentTransition","usePresence","ScopedPortal","useTabsParts","hasRenderableNode","value","DrawerBody","id","title","ariaLabel","contentRef","children","undefined","DrawerTabsLayout","open","tabs","hasHeading","extraNode","ariaLabelledBy","tabExtra","tabLabel","tabLabelledBy","parts","hasContent","Boolean","DrawerInner","description","icon","extra","footer","closable","onClose","messages","hasTabs","closeButton","DrawerSurface","divided","padding","placement","width","height","maskClosable","keyboard","afterClose","forceRender","destroyOnClose","preserve","initialFocus","returnFocus","_container","push","showSwipeHandle","resizable","minSize","maxSize","onResize","className","style","props","maskBlur","theme","panel","backdrop","content","present","layer","tabsSize","swipeHandleVisible","paddingStyle","paddingFlags","drawerTheme","surfaceFlags","contentRevision","owner","resized","setResized","stopDragging","stopSwiping","horizontal","parent","document","previous","distance","visited","Number","event","start","bounds","size","update","next","Math","end","window","node","startX","startY","startTime","Date","panelSize","latestOffset","getOffset","pointerEvent","raw","formatTransform","offset","moveEvent","cleanup","finish","endEvent","finalOffset","elapsed","threshold","velocity","shouldClose","requestAnimationFrame","Drawer","rawProps"],"mappings":";;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA,0CAA0C,qCAAqC;AAC/E;AACA;AACA;AACA;AACA;AACA;;;;ACVA;;;;ACAA;AACA;AACA;AACA,uDAAuD,iBAAiB;AACxE;AACA,gDAAgD,aAAa;AAC7D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACNiC;AAUlB;AAC2D;AACf;AACD;AACd;AAC2C;AAC1C;AACU;AAC2B;AACX;AAChB;AAEK;AAuE5D,SAASoB,kBAAkBC,KAAgB;IACzC,OAAOA,SAAS,QAAQ,OAAOA,UAAU;AAC3C;AAEA,SAASC,WAAW,EAClBC,EAAE,EACFC,KAAK,EACLC,SAAS,EACTC,UAAU,EACVC,QAAQ,EAOT;IACC,qBACE,oCAACnB,8CAAgBA;QACf,WAAU;QACV,mBAAkB;QAClB,aAAY;QACZ,MAAMgB,SAAS,QAAQC,YAAY,WAAW;QAC9C,mBAAiBD,SAAS,OAAO,GAAGD,GAAG,MAAM,CAAC,GAAGK;QACjD,cAAYJ,SAAS,OAAOC,YAAYG;kBAExC,kDAAC;YAAI,KAAKF;YAAY,WAAU;sBAC7BC;;;AAIT;AAEA,SAASE,iBAAiB,EACxBC,IAAI,EACJC,IAAI,EACJR,EAAE,EACFC,KAAK,EACLQ,UAAU,EACVC,SAAS,EACTP,UAAU,EACVD,SAAS,EACTS,cAAc,EACdP,QAAQ,EACc;IACtB,MAAMQ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D,IAAI,CAACA,QAAQ,OAAO,EAAE,qBAAO,oCAAC;QAAK,MAAM;;IACzC,qBACE,oCAACjF,8CAAYA;QAAC,WAAWwD,MAAM,SAAS;kBACtC,kDAACvB;YAAe,GAAGuB,KAAK;;;AAG9B"}
|
|
1
|
+
{"version":3,"file":"drawer/drawer.cjs","sources":["webpack://webpack/runtime/define_property_getters","webpack://webpack/runtime/has_own_property","webpack://webpack/runtime/make_namespace_object","../../../../../src/drawer/drawer.tsx"],"sourcesContent":["__webpack_require__.d = (exports, getters, values) => {\n\tvar define = (defs, kind) => {\n\t\tfor(var key in defs) {\n\t\t\tif(__webpack_require__.o(defs, key) && !__webpack_require__.o(exports, key)) {\n\t\t\t\tObject.defineProperty(exports, key, { enumerable: true, [kind]: defs[key] });\n\t\t\t}\n\t\t}\n\t};\n\tdefine(getters, \"get\");\n\tdefine(values, \"value\");\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","import { X } from 'lucide-react';\nimport {\n type HTMLAttributes,\n type ReactNode,\n type Ref,\n useContext,\n useEffect,\n useId,\n useRef,\n useState,\n} from 'react';\nimport { useComponentProps } from '../config-provider/component-defaults';\nimport { useLeafConfig } from '../config-provider/context';\nimport { ScrollbarControl } from '../scrollbar/scrollbar';\nimport { classes } from '../shared/classes';\nimport { type DialogFocusOptions, useDialog, useOverlayLayer } from '../shared/dialog';\nimport { inertProps } from '../shared/inert';\nimport { OverlayOwner } from '../shared/overlay-owner';\nimport { resolveDialogPaddingFlags, resolvePaddingVars } from '../shared/padding';\nimport { useContentTransition, usePresence } from '../shared/presence';\nimport { ScopedPortal } from '../shared/scoped-portal';\nimport type { ContainerPadding } from '../shared/types';\nimport { type TabsProps, useTabsParts } from '../tabs/tabs';\n\n/** Tabs controls integrated with the drawer; Drawer fixes the line type and top placement. */\nexport interface DrawerTabsProps extends Omit<TabsProps, 'type' | 'placement' | 'children'> {}\n\nexport interface DrawerProps\n extends Omit<HTMLAttributes<HTMLDivElement>, 'title' | 'onResize'>,\n DialogFocusOptions {\n open: boolean;\n title?: ReactNode;\n description?: ReactNode;\n /** Embedded tabs placed below the heading, or replacing it when no title is supplied. */\n tabs?: DrawerTabsProps;\n icon?: ReactNode;\n /** Customize inner padding for the drawer or individual header/body/footer regions. */\n padding?: ContainerPadding;\n footer?: ReactNode;\n extra?: ReactNode;\n placement?: 'left' | 'right' | 'top' | 'bottom';\n width?: number | string;\n height?: number | string;\n closable?: boolean;\n maskClosable?: boolean;\n keyboard?: boolean;\n onClose?: () => void;\n afterClose?: () => void;\n forceRender?: boolean;\n destroyOnClose?: boolean;\n preserve?: boolean;\n container?: Element | DocumentFragment | (() => Element | DocumentFragment);\n push?: boolean | number;\n /** Show a swipe handle bar along the leading edge and allow pointer dragging to close. Defaults to `true` when `placement=\"bottom\"`. */\n showSwipeHandle?: boolean;\n resizable?: boolean;\n minSize?: number;\n maxSize?: number;\n onResize?: (size: number) => void;\n}\n\ninterface DrawerInnerProps {\n id: string;\n open: boolean;\n title?: ReactNode;\n description?: ReactNode;\n tabs?: DrawerTabsProps;\n icon?: ReactNode;\n extra?: ReactNode;\n footer?: ReactNode;\n closable: boolean;\n onClose?: () => void;\n contentRef: Ref<HTMLDivElement>;\n ariaLabel?: string;\n ariaLabelledBy?: string;\n children?: ReactNode;\n}\n\ninterface DrawerTabsLayoutProps {\n open: boolean;\n tabs: DrawerTabsProps;\n id: string;\n title?: ReactNode;\n hasHeading: boolean;\n extraNode: ReactNode;\n contentRef: Ref<HTMLDivElement>;\n ariaLabel?: string;\n ariaLabelledBy?: string;\n children?: ReactNode;\n}\n\nfunction hasRenderableNode(value: ReactNode): boolean {\n return value != null && typeof value !== 'boolean';\n}\n\nfunction DrawerBody({\n id,\n title,\n ariaLabel,\n contentRef,\n children,\n}: {\n id: string;\n title?: ReactNode;\n ariaLabel?: string;\n contentRef: Ref<HTMLDivElement>;\n children?: ReactNode;\n}) {\n return (\n <ScrollbarControl\n className=\"leaf-drawer__body\"\n viewportClassName=\"leaf-drawer__viewport\"\n orientation=\"vertical\"\n role={title != null || ariaLabel ? 'region' : 'presentation'}\n aria-labelledby={title != null ? `${id}-title` : undefined}\n aria-label={title == null ? ariaLabel : undefined}\n >\n <div ref={contentRef} className=\"leaf-drawer__content\">\n {children}\n </div>\n </ScrollbarControl>\n );\n}\n\nfunction DrawerTabsLayout({\n open,\n tabs,\n id,\n title,\n hasHeading,\n extraNode,\n contentRef,\n ariaLabel,\n ariaLabelledBy,\n children,\n}: DrawerTabsLayoutProps) {\n const tabExtra =\n !hasHeading && extraNode != null ? (\n <div className=\"leaf-dialog-tab-extra leaf-drawer__tab-extra\">\n {tabs.extra}\n {extraNode}\n </div>\n ) : (\n tabs.extra\n );\n const tabLabel = tabs['aria-label'] ?? (typeof title === 'string' ? title : ariaLabel);\n const tabLabelledBy =\n tabs['aria-labelledby'] ??\n (tabs['aria-label'] == null && title != null\n ? `${id}-title`\n : tabs['aria-label'] == null\n ? ariaLabelledBy\n : undefined);\n const parts = useTabsParts({\n ...tabs,\n type: 'line',\n placement: 'top',\n size: tabs.size ?? 'md',\n 'aria-label': tabLabel,\n 'aria-labelledby': tabLabelledBy,\n extra: tabExtra,\n className: classes(\n 'leaf-dialog-tabs',\n hasHeading && 'leaf-dialog-tabs--headed',\n 'leaf-drawer__tabs',\n tabs.className,\n ),\n panelsClassName: 'leaf-dialog-panels',\n visibilityKey: open,\n });\n const hasContent = Boolean(parts?.hasPanels) || hasRenderableNode(children);\n\n return (\n <>\n {parts && <div {...parts.rootProps}>{parts.header}</div>}\n {hasContent && (\n <DrawerBody id={id} title={title} ariaLabel={ariaLabel} contentRef={contentRef}>\n {parts?.panels}\n {children}\n </DrawerBody>\n )}\n </>\n );\n}\n\nfunction DrawerInner({\n id,\n open,\n title,\n description,\n tabs,\n icon,\n extra,\n footer,\n closable,\n onClose,\n contentRef,\n ariaLabel,\n ariaLabelledBy,\n children,\n}: DrawerInnerProps) {\n const { messages } = useLeafConfig();\n const hasTabs = Boolean(tabs?.items?.length);\n const hasHeading = title != null || description != null || icon != null;\n const closeButton = closable ? (\n <button\n type=\"button\"\n className=\"leaf-drawer__close\"\n aria-label={messages.common.close}\n onClick={onClose}\n >\n <X size={16} aria-hidden=\"true\" />\n </button>\n ) : null;\n const extraNode = extra != null ? <div className=\"leaf-drawer__extra\">{extra}</div> : null;\n\n return (\n <>\n {(hasHeading || (!hasTabs && extra != null)) && (\n <div\n className={classes('leaf-drawer__header', !hasHeading && 'leaf-drawer__header--compact')}\n >\n {icon != null && (\n <span className=\"leaf-drawer__icon\" aria-hidden=\"true\">\n {icon}\n </span>\n )}\n {(title != null || description != null) && (\n <div className=\"leaf-drawer__heading\">\n {title != null && <h2 id={`${id}-title`}>{title}</h2>}\n {description != null && (\n <div id={`${id}-description`} className=\"leaf-drawer__description\">\n {description}\n </div>\n )}\n </div>\n )}\n {extraNode}\n </div>\n )}\n {closeButton}\n {hasTabs && tabs ? (\n <DrawerTabsLayout\n open={open}\n tabs={tabs}\n id={id}\n title={title}\n hasHeading={hasHeading}\n extraNode={extraNode}\n contentRef={contentRef}\n ariaLabel={ariaLabel}\n ariaLabelledBy={ariaLabelledBy}\n >\n {children}\n </DrawerTabsLayout>\n ) : (\n <DrawerBody id={id} title={title} ariaLabel={ariaLabel} contentRef={contentRef}>\n {children}\n </DrawerBody>\n )}\n {footer != null && <div className=\"leaf-drawer__footer\">{footer}</div>}\n </>\n );\n}\n\nfunction DrawerSurface({\n open,\n title,\n description,\n tabs,\n icon,\n padding,\n footer,\n extra,\n placement = 'right',\n width = 380,\n height = 300,\n closable = true,\n maskClosable = true,\n keyboard = true,\n onClose,\n afterClose,\n forceRender = false,\n destroyOnClose = false,\n preserve,\n initialFocus,\n returnFocus,\n container: _container,\n push = false,\n showSwipeHandle,\n resizable = false,\n minSize = 240,\n maxSize = 900,\n onResize,\n children,\n className,\n style,\n ...props\n}: DrawerProps) {\n const { messages, maskBlur, theme } = useLeafConfig();\n const id = useId();\n const panel = useRef<HTMLDivElement>(null);\n const backdrop = useRef<HTMLButtonElement>(null);\n const content = useRef<HTMLDivElement>(null);\n const present = usePresence(open, backdrop);\n const layer = useOverlayLayer(present, open);\n const hasHeading = title != null || description != null || icon != null;\n const hasTabs = Boolean(tabs?.items?.length);\n const tabsSize = hasTabs ? (tabs?.size ?? 'md') : undefined;\n const swipeHandleVisible = showSwipeHandle ?? placement === 'bottom';\n const paddingStyle = resolvePaddingVars('drawer', padding);\n const paddingFlags = resolveDialogPaddingFlags(padding);\n const drawerTheme = theme.components?.Drawer;\n const surfaceFlags = {\n ...(drawerTheme?.headerBackground !== undefined ? { 'data-header-surface': '' } : {}),\n ...(drawerTheme?.footerBackground !== undefined ? { 'data-footer-surface': '' } : {}),\n };\n const contentRevision = useRef({ children, revision: 0 });\n if (children !== contentRevision.current.children)\n contentRevision.current = { children, revision: contentRevision.current.revision + 1 };\n useContentTransition(content, `${open}:${contentRevision.current.revision}`, 0, true);\n const owner = useContext(OverlayOwner);\n const [resized, setResized] = useState<number>();\n const stopDragging = useRef<(() => void) | undefined>(undefined);\n const stopSwiping = useRef<(() => void) | undefined>(undefined);\n useEffect(\n () => () => {\n stopDragging.current?.();\n stopSwiping.current?.();\n },\n [],\n );\n useEffect(() => {\n if (!open) stopSwiping.current?.();\n else {\n panel.current?.removeAttribute('data-swiping');\n panel.current?.style.removeProperty('--leaf-drawer-swipe-transform');\n }\n }, [open]);\n const horizontal = placement === 'left' || placement === 'right';\n // biome-ignore lint/correctness/useExhaustiveDependencies: Resizing resets when the configured dimensions change.\n useEffect(() => {\n setResized(undefined);\n }, [width, height]);\n useEffect(() => {\n if (!open || !push || !owner) return;\n const parent = document.getElementById(owner);\n if (!parent) return;\n const previous = parent.style.transform;\n const distance = typeof push === 'number' ? push : 40;\n parent.style.transform = `translate${horizontal ? 'X' : 'Y'}(${placement === 'right' || placement === 'bottom' ? -distance : distance}px)`;\n return () => {\n parent.style.transform = previous;\n };\n }, [open, push, owner, placement, horizontal]);\n const previous = useRef(false);\n useEffect(() => {\n if (previous.current && !present) afterClose?.();\n previous.current = present;\n }, [present, afterClose]);\n useDialog(open, panel, id, () => onClose?.(), keyboard, { initialFocus, returnFocus });\n const visited = useRef(false);\n if (open) visited.current = true;\n if (\n !present &&\n !forceRender &&\n ((preserve === undefined ? destroyOnClose : !preserve) || !visited.current)\n )\n return null;\n return (\n <div\n hidden={!present}\n className={classes('leaf-drawer-mask', `leaf-drawer-mask--${placement}`)}\n style={layer.maskStyle}\n data-blur={maskBlur ? undefined : 'off'}\n data-state={open ? 'open' : 'closing'}\n aria-hidden={!open || undefined}\n {...inertProps(!open)}\n >\n <button\n ref={backdrop}\n type=\"button\"\n tabIndex={-1}\n className=\"leaf-drawer-backdrop\"\n aria-label={messages.common.close}\n onClick={() => {\n if (maskClosable) onClose?.();\n }}\n />\n <div\n {...props}\n ref={panel}\n id={props.id ?? id}\n role=\"dialog\"\n aria-modal=\"true\"\n aria-labelledby={title != null ? `${id}-title` : props['aria-labelledby']}\n aria-describedby={\n [props['aria-describedby'], description != null && `${id}-description`]\n .filter(Boolean)\n .join(' ') || undefined\n }\n tabIndex={-1}\n className={classes(\n 'leaf-drawer',\n `leaf-drawer--placement-${placement}`,\n swipeHandleVisible && 'leaf-drawer--swipeable',\n hasHeading && 'leaf-drawer--headed',\n hasTabs && 'leaf-drawer--tabbed',\n closable && 'leaf-drawer--closable',\n className,\n )}\n data-tabs-size={tabsSize}\n {...paddingFlags}\n {...surfaceFlags}\n style={{\n ...(horizontal\n ? { width: resized ?? width, height: '100%' }\n : { height: resized ?? height, width: '100%' }),\n ...layer.popupStyle,\n ...paddingStyle,\n ...style,\n }}\n >\n {resizable && (\n // biome-ignore lint/a11y/useSemanticElements: This is the adjustable ARIA window-splitter handle, not a decorative separator.\n <div\n role=\"separator\"\n tabIndex={0}\n aria-label={messages.drawer.resize}\n aria-orientation={horizontal ? 'vertical' : 'horizontal'}\n aria-valuemin={minSize}\n aria-valuemax={maxSize}\n aria-valuenow={\n resized ??\n (typeof (horizontal ? width : height) === 'number'\n ? Number(horizontal ? width : height)\n : undefined)\n }\n className=\"leaf-drawer__resize\"\n onPointerDown={(event) => {\n if (!panel.current) return;\n stopDragging.current?.();\n event.preventDefault();\n event.currentTarget.setPointerCapture?.(event.pointerId);\n const start = horizontal ? event.clientX : event.clientY;\n const bounds = panel.current.getBoundingClientRect();\n const size = horizontal ? bounds.width : bounds.height;\n const update = (event: PointerEvent) => {\n const next = Math.min(\n maxSize,\n Math.max(\n minSize,\n size +\n ((horizontal ? event.clientX : event.clientY) - start) *\n (placement === 'right' || placement === 'bottom' ? -1 : 1),\n ),\n );\n setResized(next);\n onResize?.(next);\n };\n const end = () => {\n window.removeEventListener('pointermove', update);\n window.removeEventListener('pointerup', end);\n window.removeEventListener('pointercancel', end);\n stopDragging.current = undefined;\n };\n stopDragging.current = end;\n window.addEventListener('pointermove', update);\n window.addEventListener('pointerup', end, { once: true });\n window.addEventListener('pointercancel', end, { once: true });\n }}\n onKeyDown={(event) => {\n if (!panel.current) return;\n if (!['ArrowLeft', 'ArrowRight', 'ArrowUp', 'ArrowDown'].includes(event.key)) return;\n event.preventDefault();\n const bounds = panel.current.getBoundingClientRect();\n const size = horizontal ? bounds.width : bounds.height;\n const next = Math.min(\n maxSize,\n Math.max(\n minSize,\n size +\n (['ArrowRight', 'ArrowDown'].includes(event.key) ? 10 : -10) *\n (placement === 'right' || placement === 'bottom' ? -1 : 1),\n ),\n );\n setResized(next);\n onResize?.(next);\n }}\n />\n )}\n {swipeHandleVisible && (\n <div\n className={classes(\n 'leaf-drawer__swipe-handle',\n `leaf-drawer__swipe-handle--${placement}`,\n )}\n data-swipe-handle=\"\"\n aria-hidden=\"true\"\n onPointerDown={(event) => {\n if (!panel.current || (event.button !== 0 && event.pointerType === 'mouse')) return;\n stopSwiping.current?.();\n event.preventDefault();\n event.currentTarget.setPointerCapture?.(event.pointerId);\n const node = panel.current;\n const startX = event.clientX;\n const startY = event.clientY;\n const startTime = Date.now();\n const bounds = node.getBoundingClientRect();\n const panelSize = horizontal ? bounds.width : bounds.height;\n let latestOffset = 0;\n const getOffset = (pointerEvent: PointerEvent) => {\n const raw =\n placement === 'bottom'\n ? pointerEvent.clientY - startY\n : placement === 'top'\n ? startY - pointerEvent.clientY\n : placement === 'right'\n ? pointerEvent.clientX - startX\n : startX - pointerEvent.clientX;\n return Math.max(0, raw);\n };\n const formatTransform = (offset: number) =>\n placement === 'bottom'\n ? `translateY(${offset}px)`\n : placement === 'top'\n ? `translateY(${-offset}px)`\n : placement === 'right'\n ? `translateX(${offset}px)`\n : `translateX(${-offset}px)`;\n node.setAttribute('data-swiping', 'true');\n const update = (moveEvent: PointerEvent) => {\n latestOffset = getOffset(moveEvent);\n node.style.setProperty(\n '--leaf-drawer-swipe-transform',\n formatTransform(latestOffset),\n );\n };\n const cleanup = () => {\n window.removeEventListener('pointermove', update);\n window.removeEventListener('pointerup', finish);\n window.removeEventListener('pointercancel', finish);\n stopSwiping.current = undefined;\n };\n const finish = (endEvent?: PointerEvent) => {\n cleanup();\n const finalOffset = endEvent ? getOffset(endEvent) : latestOffset;\n const elapsed = Math.max(1, Date.now() - startTime);\n const threshold = Math.min(120, Math.max(48, panelSize * 0.3));\n const velocity = finalOffset / elapsed;\n const shouldClose =\n endEvent?.type === 'pointerup' &&\n (finalOffset >= threshold || (finalOffset > 24 && velocity > 0.4));\n node.removeAttribute('data-swiping');\n if (shouldClose) {\n onClose?.();\n if (typeof requestAnimationFrame === 'function') {\n requestAnimationFrame(() =>\n node.style.removeProperty('--leaf-drawer-swipe-transform'),\n );\n } else {\n node.style.removeProperty('--leaf-drawer-swipe-transform');\n }\n return;\n }\n node.style.removeProperty('--leaf-drawer-swipe-transform');\n };\n stopSwiping.current = () => {\n cleanup();\n node.removeAttribute('data-swiping');\n node.style.removeProperty('--leaf-drawer-swipe-transform');\n };\n window.addEventListener('pointermove', update);\n window.addEventListener('pointerup', finish, { once: true });\n window.addEventListener('pointercancel', finish, { once: true });\n }}\n >\n <span className=\"leaf-drawer__swipe-bar\" />\n </div>\n )}\n <OverlayOwner.Provider value={id}>\n <DrawerInner\n id={id}\n open={open}\n title={title}\n description={description}\n tabs={tabs}\n icon={icon}\n extra={extra}\n footer={footer}\n closable={closable}\n onClose={onClose}\n contentRef={content}\n ariaLabel={props['aria-label']}\n ariaLabelledBy={props['aria-labelledby']}\n >\n {children}\n </DrawerInner>\n </OverlayOwner.Provider>\n </div>\n </div>\n );\n}\nexport function Drawer(rawProps: DrawerProps) {\n const props = useComponentProps('Drawer', rawProps);\n const visited = useRef(false);\n // 首次打开或显式 forceRender 前保留行内锚点并延迟挂载 ScopedPortal,避免提前在 body 占位。\n if (props.open || props.forceRender) visited.current = true;\n if (!visited.current) return <span hidden />;\n return (\n <ScopedPortal container={props.container}>\n <DrawerSurface {...props} />\n </ScopedPortal>\n );\n}\n"],"names":["X","useContext","useEffect","useId","useRef","useState","useComponentProps","useLeafConfig","ScrollbarControl","classes","useDialog","useOverlayLayer","inertProps","OverlayOwner","resolveDialogPaddingFlags","resolvePaddingVars","useContentTransition","usePresence","ScopedPortal","useTabsParts","hasRenderableNode","value","DrawerBody","id","title","ariaLabel","contentRef","children","undefined","DrawerTabsLayout","open","tabs","hasHeading","extraNode","ariaLabelledBy","tabExtra","tabLabel","tabLabelledBy","parts","hasContent","Boolean","DrawerInner","description","icon","extra","footer","closable","onClose","messages","hasTabs","closeButton","DrawerSurface","padding","placement","width","height","maskClosable","keyboard","afterClose","forceRender","destroyOnClose","preserve","initialFocus","returnFocus","_container","push","showSwipeHandle","resizable","minSize","maxSize","onResize","className","style","props","maskBlur","theme","panel","backdrop","content","present","layer","tabsSize","swipeHandleVisible","paddingStyle","paddingFlags","drawerTheme","surfaceFlags","contentRevision","owner","resized","setResized","stopDragging","stopSwiping","horizontal","parent","document","previous","distance","visited","Number","event","start","bounds","size","update","next","Math","end","window","node","startX","startY","startTime","Date","panelSize","latestOffset","getOffset","pointerEvent","raw","formatTransform","offset","moveEvent","cleanup","finish","endEvent","finalOffset","elapsed","threshold","velocity","shouldClose","requestAnimationFrame","Drawer","rawProps"],"mappings":";;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA,0CAA0C,qCAAqC;AAC/E;AACA;AACA;AACA;AACA;AACA;;;;ACVA;;;;ACAA;AACA;AACA;AACA,uDAAuD,iBAAiB;AACxE;AACA,gDAAgD,aAAa;AAC7D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACNiC;AAUlB;AAC2D;AACf;AACD;AACd;AAC2C;AAC1C;AACU;AAC2B;AACX;AAChB;AAEK;AAqE5D,SAASoB,kBAAkBC,KAAgB;IACzC,OAAOA,SAAS,QAAQ,OAAOA,UAAU;AAC3C;AAEA,SAASC,WAAW,EAClBC,EAAE,EACFC,KAAK,EACLC,SAAS,EACTC,UAAU,EACVC,QAAQ,EAOT;IACC,qBACE,oCAACnB,8CAAgBA;QACf,WAAU;QACV,mBAAkB;QAClB,aAAY;QACZ,MAAMgB,SAAS,QAAQC,YAAY,WAAW;QAC9C,mBAAiBD,SAAS,OAAO,GAAGD,GAAG,MAAM,CAAC,GAAGK;QACjD,cAAYJ,SAAS,OAAOC,YAAYG;kBAExC,kDAAC;YAAI,KAAKF;YAAY,WAAU;sBAC7BC;;;AAIT;AAEA,SAASE,iBAAiB,EACxBC,IAAI,EACJC,IAAI,EACJR,EAAE,EACFC,KAAK,EACLQ,UAAU,EACVC,SAAS,EACTP,UAAU,EACVD,SAAS,EACTS,cAAc,EACdP,QAAQ,EACc;IACtB,MAAMQ,WACJ,CAACH,cAAcC,aAAa,qBAC1B,qCAAC;QAAI,WAAU;;YACZF,KAAK,KAAK;YACVE;;SAGHF,KAAK,KAAK;IAEd,MA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AGsB,KAAK;;;AAG9B"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","sources":["webpack://webpack/runtime/define_property_getters","webpack://webpack/runtime/has_own_property","webpack://webpack/runtime/make_namespace_object","../../../../src/index.ts"],"sourcesContent":["__webpack_require__.d = (exports, getters, values) => {\n\tvar define = (defs, kind) => {\n\t\tfor(var key in defs) {\n\t\t\tif(__webpack_require__.o(defs, key) && !__webpack_require__.o(exports, key)) {\n\t\t\t\tObject.defineProperty(exports, key, { enumerable: true, [kind]: defs[key] });\n\t\t\t}\n\t\t}\n\t};\n\tdefine(getters, \"get\");\n\tdefine(values, \"value\");\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","export type {\n AlertProps,\n AlertType,\n AlertTypeInput,\n FeedbackType,\n FeedbackTypeInput,\n} from './alert';\nexport { Alert } from './alert';\nexport type { AffixProps, AnchorItem, AnchorProps } from './anchor';\nexport { Affix, Anchor } from './anchor';\nexport type {\n AutoCompleteOption,\n AutoCompleteOptionGroup,\n AutoCompleteProps,\n} from './autocomplete';\nexport { AutoComplete } from './autocomplete';\nexport type { AvatarGroupProps, AvatarProps } from './avatar';\nexport { Avatar, AvatarGroup } from './avatar';\nexport type { BackTopProps } from './backtop';\nexport { BackTop } from './backtop';\nexport type { BadgeProps } from './badge';\nexport { Badge } from './badge';\nexport type { BreadcrumbItem, BreadcrumbProps } from './breadcrumb';\nexport { Breadcrumb } from './breadcrumb';\nexport type {\n ButtonGroupProps,\n ButtonProps,\n ButtonSize,\n ButtonVariant,\n} from './button';\nexport { Button, ButtonGroup } from './button';\nexport type { CalendarProps } from './calendar';\nexport { Calendar } from './calendar';\nexport type { CardProps, CardTabsProps, CardTitleProps } from './card';\nexport { Card, CardTitle } from './card';\nexport type { CarouselHandle, CarouselProps } from './carousel';\nexport { Carousel } from './carousel';\nexport type { CascaderFieldNames, CascaderOption, CascaderProps } from './cascader';\nexport { Cascader, mapCascaderOptions } from './cascader';\nexport type { CheckboxGroupProps, CheckboxOption, CheckboxProps } from './checkbox';\nexport { Checkbox, CheckboxGroup } from './checkbox';\nexport type { CollapseItem, CollapseProps } from './collapse';\nexport { Collapse } from './collapse';\nexport type {\n ColorGradient,\n ColorGradientStop,\n ColorPickerProps,\n ColorPreset,\n} from './colorpicker';\nexport { ColorPicker, gradientString, parseGradient } from './colorpicker';\nexport type {\n ConfigProviderProps,\n LeafComponentDefaults,\n LeafDensity,\n LeafLocale,\n LeafTheme,\n LeafThemeTokens,\n LeafTranslation,\n LeafTranslations,\n} from './config-provider';\nexport { ConfigProvider } from './config-provider';\nexport type { LeafDirection } from './config-provider/context';\nexport { colorContrast, useBreakpoint, useSystemAppearance } from './config-provider/helpers';\nexport type { ConfirmApi, ConfirmOptions, ConfirmProviderProps } from './confirm';\nexport { ConfirmProvider, useConfirm } from './confirm';\nexport type {\n DatePickerProps,\n SingleDatePickerProps,\n TimePickerModeProps,\n} from './datepicker';\nexport { DatePicker } from './datepicker';\nexport type {\n DateRange,\n DateRangePickerProps,\n TimeRange,\n TimeRangePickerModeProps,\n} from './daterangepicker';\nexport { DateRangePicker } from './daterangepicker';\nexport type { OpenDateRange } from './daterangepicker/daterangepicker';\nexport type { DescriptionItem, DescriptionsProps } from './descriptions';\nexport { Descriptions } from './descriptions';\nexport type { DividerProps } from './divider';\nexport { Divider } from './divider';\nexport type { DrawerProps, DrawerTabsProps } from './drawer';\nexport { Drawer } from './drawer';\nexport type { DropdownItem, DropdownProps } from './dropdown';\nexport { Dropdown } from './dropdown';\nexport type { EmptyProps } from './empty';\nexport { Empty } from './empty';\nexport type { ErrorBoundaryFallbackProps, ErrorBoundaryProps } from './errorboundary';\nexport { ErrorBoundary } from './errorboundary';\nexport type { FileItem, FileListProps } from './filelist';\nexport { FileList } from './filelist';\nexport type { FlexGap, FlexProps } from './flex';\nexport { Flex } from './flex';\nexport type {\n FloatButtonAction,\n FloatButtonGroupProps,\n FloatButtonPlacement,\n FloatButtonProps,\n} from './floatbutton';\nexport { FAB, FloatButton, FloatButtonGroup } from './floatbutton';\nexport type {\n FormError,\n FormErrorSummaryProps,\n FormFieldProps,\n FormGroupProps,\n FormListField,\n FormListOperations,\n FormListProps,\n FormProps,\n} from './form';\nexport { Form, FormErrorSummary, FormField, FormGroup, FormList } from './form';\nexport type { FormValidationApi, FormValidationOptions } from './form/validation';\nexport { useFormValidation } from './form/validation';\nexport type { ColProps, GridBreakpoint, GridProps, RowProps } from './grid';\nexport { Col, Grid, Row } from './grid';\nexport type {\n ImagePreviewApi,\n ImagePreviewItem,\n ImagePreviewOptions,\n ImagePreviewProviderProps,\n} from './image';\nexport { ImagePreviewProvider, useImagePreview } from './image';\nexport type { InfiniteScrollProps } from './infinitescroll';\nexport { InfiniteScroll } from './infinitescroll';\nexport type { InputGroupProps, InputProps, InputSearchProps } from './input';\nexport { Input, InputGroup, InputSearch } from './input';\nexport type { InputMaskProps } from './inputmask';\nexport { InputMask } from './inputmask';\nexport type {\n InputNumberProps,\n InputNumberVariant,\n NumericInputNumberProps,\n StringInputNumberProps,\n} from './inputnumber';\nexport { InputNumber } from './inputnumber';\nexport type { InputOTPProps } from './inputotp';\nexport { InputOTP } from './inputotp';\nexport type { LayoutProps, LayoutSiderProps } from './layout';\nexport { Layout, LayoutContent, LayoutFooter, LayoutHeader, LayoutSider } from './layout';\nexport type { LoadingProps, LoadingVariant } from './loading';\nexport { Loading } from './loading';\nexport type { LoadingBarApi, LoadingBarProps, LoadingBarProviderProps } from './loadingbar';\nexport { LoadingBar, LoadingBarProvider, useLoadingBar } from './loadingbar';\nexport type { MasonryProps } from './masonry';\nexport { Masonry } from './masonry';\nexport type { MentionOption, MentionsProps } from './mentions';\nexport { Mentions } from './mentions';\nexport type { MenuGroupProps, MenuItem, MenuProps } from './menu';\nexport { Menu, MenuGroup } from './menu';\nexport type { MessageApi, MessageOptions, MessageProps, MessageProviderProps } from './message';\nexport { Message, MessageProvider, useMessage } from './message';\nexport type { ModalFooterActions, ModalProps, ModalTabsProps } from './modal';\nexport { Modal } from './modal';\nexport type {\n NotificationApi,\n NotificationOptions,\n NotificationProps,\n NotificationProviderProps,\n} from './notification';\nexport { Notification, NotificationProvider, useNotification } from './notification';\nexport type { PaginationProps } from './pagination';\nexport { Pagination } from './pagination';\nexport type { PopconfirmProps } from './popconfirm';\nexport { Popconfirm } from './popconfirm';\nexport type { PopoverProps } from './popover';\nexport { Popover } from './popover';\nexport type { ProgressProps, ProgressSegment } from './progress';\nexport { Progress } from './progress';\nexport type { QRCodeProps } from './qrcode';\nexport { QRCode } from './qrcode';\nexport type { RadioGroupProps, RadioOption, RadioProps } from './radio';\nexport { Radio, RadioGroup } from './radio';\nexport type { RateProps } from './rate';\nexport { Rate } from './rate';\nexport type { ResultProps } from './result';\nexport { Result } from './result';\nexport type { ScrollAreaProps } from './scrollarea';\nexport { ScrollArea } from './scrollarea';\nexport type { ScrollbarProps } from './scrollbar';\nexport { Scrollbar } from './scrollbar';\nexport type { SelectOption, SelectOptionGroup, SelectProps } from './select';\nexport { Select } from './select';\nexport type { DateFormat, DatePreset } from './shared/date-format';\nexport type { DialogFocusOptions, FocusTarget } from './shared/dialog';\nexport type { PopupOptions } from './shared/floating';\nexport type { TimeParts } from './shared/time';\nexport type {\n ContainerPadding,\n ControlSize,\n ControlStatus,\n PaddingValue,\n SectionPadding,\n} from './shared/types';\nexport type {\n SkeletonAvatarProps,\n SkeletonButtonProps,\n SkeletonImageProps,\n SkeletonInputProps,\n SkeletonProps,\n} from './skeleton';\nexport {\n Skeleton,\n SkeletonAvatar,\n SkeletonButton,\n SkeletonImage,\n SkeletonInput,\n} from './skeleton';\nexport type { SliderMark, SliderProps } from './slider';\nexport { Slider } from './slider';\nexport type { SpaceProps } from './space';\nexport { Space } from './space';\nexport type { SplitterPanel, SplitterProps } from './splitter';\nexport { ResizablePanels, Splitter } from './splitter';\nexport type { CountdownProps, StatisticProps } from './statistic';\nexport { Countdown, Statistic } from './statistic';\nexport type { StepItem, StepsProps } from './steps';\nexport { Steps } from './steps';\nexport type { SwitchProps } from './switch';\nexport { Switch } from './switch';\nexport type {\n TableCellProps,\n TableColumn,\n TableExpandable,\n TableHeaderCellProps,\n TableKey,\n TablePaginationProps,\n TablePresentationProps,\n TableProps,\n TableRowKey,\n TableRowProps,\n TableRowSelection,\n TableSorterState,\n TableSortOrder,\n TableVirtualOptions,\n} from './table';\nexport { Table } from './table';\nexport type { TabItem, TabsProps } from './tabs';\nexport { Tabs } from './tabs';\nexport type { CheckableTagProps, TagGroupProps, TagOption, TagProps } from './tag';\nexport { CheckableTag, Tag, TagGroup } from './tag';\nexport type { TextareaProps } from './textarea';\nexport { Textarea } from './textarea';\nexport type { TextareaAutoSize } from './textarea/textarea';\nexport type { LeafComponentStateTokens, LeafComponentTokens, LeafThemeStyle } from './theme';\nexport type { TimelineItem, TimelineProps } from './timeline';\nexport { Timeline } from './timeline';\nexport type { TooltipProps } from './tooltip';\nexport { Tooltip } from './tooltip';\nexport type { TourProps, TourStep } from './tour';\nexport { Tour } from './tour';\nexport type { TransferChangeInfo, TransferItem, TransferProps } from './transfer';\nexport { Transfer } from './transfer';\nexport type {\n TreeCheckInfo,\n TreeDropInfo,\n TreeExpandInfo,\n TreeNode,\n TreeProps,\n TreeSelectInfo,\n} from './tree';\nexport { moveTreeNode, Tree } from './tree';\nexport type { TreeSelectOption, TreeSelectProps, TreeSelectValue } from './treeselect';\nexport { TreeSelect } from './treeselect';\nexport type {\n LinkProps,\n ParagraphProps,\n TextProps,\n TitleProps,\n TypographyProps,\n} from './typography';\nexport { Link, Paragraph, Text, Title, Typography } from './typography';\nexport type {\n AvatarUploadProps,\n UploadChangeInfo,\n UploadFile,\n UploadProps,\n UploadRejection,\n UploadRequest,\n UploadResult,\n} from './upload';\nexport { AvatarUpload, Upload } from './upload';\nexport type { UploadHandle } from './upload/upload';\nexport type { VirtualListHandle, VirtualListProps } from './virtuallist';\nexport { VirtualList } from './virtuallist';\n"],"names":["Alert","Affix","Anchor","AutoComplete","Avatar","AvatarGroup","BackTop","Badge","Breadcrumb","Button","ButtonGroup","Calendar","Card","CardTitle","Carousel","Cascader","mapCascaderOptions","Checkbox","CheckboxGroup","Collapse","ColorPicker","gradientString","parseGradient","ConfigProvider","colorContrast","useBreakpoint","useSystemAppearance","ConfirmProvider","useConfirm","DatePicker","DateRangePicker","Descriptions","Divider","Drawer","Dropdown","Empty","ErrorBoundary","FileList","Flex","FAB","FloatButton","FloatButtonGroup","Form","FormErrorSummary","FormField","FormGroup","FormList","useFormValidation","Col","Grid","Row","ImagePreviewProvider","useImagePreview","InfiniteScroll","Input","InputGroup","InputSearch","InputMask","InputNumber","InputOTP","Layout","LayoutContent","LayoutFooter","LayoutHeader","LayoutSider","Loading","LoadingBar","LoadingBarProvider","useLoadingBar","Masonry","Mentions","Menu","MenuGroup","Message","MessageProvider","useMessage","Modal","Notification","NotificationProvider","useNotification","Pagination","Popconfirm","Popover","Progress","QRCode","Radio","RadioGroup","Rate","Result","ScrollArea","Scrollbar","Select","Skeleton","SkeletonAvatar","SkeletonButton","SkeletonImage","SkeletonInput","Slider","Space","ResizablePanels","Splitter","Countdown","Statistic","Steps","Switch","Table","Tabs","CheckableTag","Tag","TagGroup","Textarea","Timeline","Tooltip","Tour","Transfer","moveTreeNode","Tree","TreeSelect","Link","Paragraph","Text","Title","Typography","AvatarUpload","Upload","VirtualList"],"mappings":";;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA,0CAA0C,qCAAqC;AAC/E;AACA;AACA;AACA;AACA;AACA;;;;ACVA;;;;ACAA;AACA;AACA;AACA,uDAAuD,iBAAiB;AACxE;AACA,gDAAgD,aAAa;AAC7D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACCgC;AAES;AAMK;AAEC;AAEX;AAEJ;AAEU;AAOK;AAET;AAEG;AAEH;AAEoB;AAEL;AAEf;AAOqC;AAWxB;AAE2C;AAEtC;AAMd;AAOU;AAGN;AAEV;AAEF;AAEI;AAEN;AAEgB;AAEV;AAER;AAOqC;AAWa;AAE1B;AAEd;AAOwB;AAEd;AAEO;AAEjB;AAOI;AAEN;AAEoD;AAEtD;AAEyC;AAEzC;AAEE;AAEG;AAEwB;AAEjC;AAOqD;AAE3C;AAEA;AAEN;AAEE;AAEJ;AAEU;AAEd;AAEI;AAEQ;AAEF;AAEN;AAyBd;AAEc;AAEF;AAEuB;AAEJ;AAEnB;AAEE;AAiBF;AAEF;AAEsB;AAEd;AAIA;AAEF;AAEN;AAEQ;AASM;AAEF;AAQ8B;AAUxB;AAGJ"}
|
|
1
|
+
{"version":3,"file":"index.cjs","sources":["webpack://webpack/runtime/define_property_getters","webpack://webpack/runtime/has_own_property","webpack://webpack/runtime/make_namespace_object","../../../../src/index.ts"],"sourcesContent":["__webpack_require__.d = (exports, getters, values) => {\n\tvar define = (defs, kind) => {\n\t\tfor(var key in defs) {\n\t\t\tif(__webpack_require__.o(defs, key) && !__webpack_require__.o(exports, key)) {\n\t\t\t\tObject.defineProperty(exports, key, { enumerable: true, [kind]: defs[key] });\n\t\t\t}\n\t\t}\n\t};\n\tdefine(getters, \"get\");\n\tdefine(values, \"value\");\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","export type {\n AlertProps,\n AlertType,\n AlertTypeInput,\n FeedbackType,\n FeedbackTypeInput,\n} from './alert';\nexport { Alert } from './alert';\nexport type { AffixProps, AnchorItem, AnchorProps } from './anchor';\nexport { Affix, Anchor } from './anchor';\nexport type {\n AutoCompleteOption,\n AutoCompleteOptionGroup,\n AutoCompleteProps,\n} from './autocomplete';\nexport { AutoComplete } from './autocomplete';\nexport type { AvatarGroupProps, AvatarProps } from './avatar';\nexport { Avatar, AvatarGroup } from './avatar';\nexport type { BackTopProps } from './backtop';\nexport { BackTop } from './backtop';\nexport type { BadgeProps } from './badge';\nexport { Badge } from './badge';\nexport type { BreadcrumbItem, BreadcrumbProps } from './breadcrumb';\nexport { Breadcrumb } from './breadcrumb';\nexport type {\n ButtonGroupProps,\n ButtonProps,\n ButtonSize,\n ButtonVariant,\n} from './button';\nexport { Button, ButtonGroup } from './button';\nexport type { CalendarProps } from './calendar';\nexport { Calendar } from './calendar';\nexport type { CardProps, CardTabsProps, CardTitleProps } from './card';\nexport { Card, CardTitle } from './card';\nexport type { CarouselHandle, CarouselProps } from './carousel';\nexport { Carousel } from './carousel';\nexport type { CascaderFieldNames, CascaderOption, CascaderProps } from './cascader';\nexport { Cascader, mapCascaderOptions } from './cascader';\nexport type { CheckboxGroupProps, CheckboxOption, CheckboxProps } from './checkbox';\nexport { Checkbox, CheckboxGroup } from './checkbox';\nexport type { CollapseItem, CollapseProps } from './collapse';\nexport { Collapse } from './collapse';\nexport type {\n ColorGradient,\n ColorGradientStop,\n ColorPickerProps,\n ColorPreset,\n} from './colorpicker';\nexport { ColorPicker, gradientString, parseGradient } from './colorpicker';\nexport type {\n ConfigProviderProps,\n LeafComponentDefaults,\n LeafDensity,\n LeafLocale,\n LeafTheme,\n LeafThemeTokens,\n LeafTranslation,\n LeafTranslations,\n} from './config-provider';\nexport { ConfigProvider } from './config-provider';\nexport type { LeafDirection } from './config-provider/context';\nexport { colorContrast, useBreakpoint, useSystemAppearance } from './config-provider/helpers';\nexport type { ConfirmApi, ConfirmOptions, ConfirmProviderProps } from './confirm';\nexport { ConfirmProvider, useConfirm } from './confirm';\nexport type {\n DatePickerProps,\n SingleDatePickerProps,\n TimePickerModeProps,\n} from './datepicker';\nexport { DatePicker } from './datepicker';\nexport type {\n DateRange,\n DateRangePickerProps,\n TimeRange,\n TimeRangePickerModeProps,\n} from './daterangepicker';\nexport { DateRangePicker } from './daterangepicker';\nexport type { OpenDateRange } from './daterangepicker/daterangepicker';\nexport type { DescriptionItem, DescriptionsProps } from './descriptions';\nexport { Descriptions } from './descriptions';\nexport type { DividerProps } from './divider';\nexport { Divider } from './divider';\nexport type { DrawerProps, DrawerTabsProps } from './drawer';\nexport { Drawer } from './drawer';\nexport type { DropdownItem, DropdownProps } from './dropdown';\nexport { Dropdown } from './dropdown';\nexport type { EmptyProps } from './empty';\nexport { Empty } from './empty';\nexport type { ErrorBoundaryFallbackProps, ErrorBoundaryProps } from './errorboundary';\nexport { ErrorBoundary } from './errorboundary';\nexport type { FileItem, FileListProps } from './filelist';\nexport { FileList } from './filelist';\nexport type { FlexGap, FlexProps } from './flex';\nexport { Flex } from './flex';\nexport type {\n FloatButtonAction,\n FloatButtonGroupProps,\n FloatButtonPlacement,\n FloatButtonProps,\n} from './floatbutton';\nexport { FAB, FloatButton, FloatButtonGroup } from './floatbutton';\nexport type {\n FormError,\n FormErrorSummaryProps,\n FormFieldProps,\n FormGroupProps,\n FormListField,\n FormListOperations,\n FormListProps,\n FormProps,\n} from './form';\nexport { Form, FormErrorSummary, FormField, FormGroup, FormList } from './form';\nexport type { FormValidationApi, FormValidationOptions } from './form/validation';\nexport { useFormValidation } from './form/validation';\nexport type { ColProps, GridBreakpoint, GridProps, RowProps } from './grid';\nexport { Col, Grid, Row } from './grid';\nexport type {\n ImagePreviewApi,\n ImagePreviewItem,\n ImagePreviewOptions,\n ImagePreviewProviderProps,\n} from './image';\nexport { ImagePreviewProvider, useImagePreview } from './image';\nexport type { InfiniteScrollProps } from './infinitescroll';\nexport { InfiniteScroll } from './infinitescroll';\nexport type { InputGroupProps, InputProps, InputSearchProps } from './input';\nexport { Input, InputGroup, InputSearch } from './input';\nexport type { InputMaskProps } from './inputmask';\nexport { InputMask } from './inputmask';\nexport type {\n InputNumberProps,\n InputNumberVariant,\n NumericInputNumberProps,\n StringInputNumberProps,\n} from './inputnumber';\nexport { InputNumber } from './inputnumber';\nexport type { InputOTPProps } from './inputotp';\nexport { InputOTP } from './inputotp';\nexport type { LayoutProps, LayoutSiderProps } from './layout';\nexport { Layout, LayoutContent, LayoutFooter, LayoutHeader, LayoutSider } from './layout';\nexport type { LoadingProps, LoadingVariant } from './loading';\nexport { Loading } from './loading';\nexport type { LoadingBarApi, LoadingBarProps, LoadingBarProviderProps } from './loadingbar';\nexport { LoadingBar, LoadingBarProvider, useLoadingBar } from './loadingbar';\nexport type { MasonryProps } from './masonry';\nexport { Masonry } from './masonry';\nexport type { MentionOption, MentionsProps } from './mentions';\nexport { Mentions } from './mentions';\nexport type { MenuGroupProps, MenuItem, MenuProps } from './menu';\nexport { Menu, MenuGroup } from './menu';\nexport type { MessageApi, MessageOptions, MessageProps, MessageProviderProps } from './message';\nexport { Message, MessageProvider, useMessage } from './message';\nexport type { ModalFooterActions, ModalProps, ModalTabsProps } from './modal';\nexport { Modal } from './modal';\nexport type {\n NotificationApi,\n NotificationOptions,\n NotificationProps,\n NotificationProviderProps,\n} from './notification';\nexport { Notification, NotificationProvider, useNotification } from './notification';\nexport type { PaginationProps } from './pagination';\nexport { Pagination } from './pagination';\nexport type { PopconfirmProps } from './popconfirm';\nexport { Popconfirm } from './popconfirm';\nexport type { PopoverProps } from './popover';\nexport { Popover } from './popover';\nexport type { ProgressProps, ProgressSegment } from './progress';\nexport { Progress } from './progress';\nexport type { QRCodeProps } from './qrcode';\nexport { QRCode } from './qrcode';\nexport type { RadioGroupProps, RadioOption, RadioProps } from './radio';\nexport { Radio, RadioGroup } from './radio';\nexport type { RateProps } from './rate';\nexport { Rate } from './rate';\nexport type { ResultProps } from './result';\nexport { Result } from './result';\nexport type { ScrollAreaProps } from './scrollarea';\nexport { ScrollArea } from './scrollarea';\nexport type { ScrollbarProps } from './scrollbar';\nexport { Scrollbar } from './scrollbar';\nexport type {\n SelectOption,\n SelectOptionGroup,\n SelectOptionRenderContext,\n SelectProps,\n} from './select';\nexport { Select } from './select';\nexport type { ChoiceBreakpoint, ChoiceColumns } from './shared/choice-columns';\nexport type { DateFormat, DatePreset } from './shared/date-format';\nexport type { DialogFocusOptions, FocusTarget } from './shared/dialog';\nexport type { PopupOptions } from './shared/floating';\nexport type { TimeParts } from './shared/time';\nexport type {\n ContainerPadding,\n ControlSize,\n ControlStatus,\n PaddingValue,\n SectionPadding,\n} from './shared/types';\nexport type {\n SkeletonAvatarProps,\n SkeletonButtonProps,\n SkeletonImageProps,\n SkeletonInputProps,\n SkeletonProps,\n} from './skeleton';\nexport {\n Skeleton,\n SkeletonAvatar,\n SkeletonButton,\n SkeletonImage,\n SkeletonInput,\n} from './skeleton';\nexport type { SliderMark, SliderProps } from './slider';\nexport { Slider } from './slider';\nexport type { SpaceProps } from './space';\nexport { Space } from './space';\nexport type { SplitterPanel, SplitterProps } from './splitter';\nexport { ResizablePanels, Splitter } from './splitter';\nexport type { CountdownProps, StatisticProps } from './statistic';\nexport { Countdown, Statistic } from './statistic';\nexport type { StepItem, StepsProps } from './steps';\nexport { Steps } from './steps';\nexport type { SwitchProps } from './switch';\nexport { Switch } from './switch';\nexport type {\n TableCellProps,\n TableColumn,\n TableExpandable,\n TableHeaderCellProps,\n TableKey,\n TablePaginationProps,\n TablePresentationProps,\n TableProps,\n TableRowGroup,\n TableRowGroupInfo,\n TableRowKey,\n TableRowProps,\n TableRowSelection,\n TableSorterState,\n TableSortOrder,\n TableVirtualOptions,\n} from './table';\nexport { Table } from './table';\nexport type { TabItem, TabsProps } from './tabs';\nexport { Tabs } from './tabs';\nexport type { CheckableTagProps, TagGroupProps, TagOption, TagProps } from './tag';\nexport { CheckableTag, Tag, TagGroup } from './tag';\nexport type { TextareaProps } from './textarea';\nexport { Textarea } from './textarea';\nexport type { TextareaAutoSize } from './textarea/textarea';\nexport type { LeafComponentStateTokens, LeafComponentTokens, LeafThemeStyle } from './theme';\nexport type { TimelineItem, TimelineProps } from './timeline';\nexport { Timeline } from './timeline';\nexport type { TooltipProps } from './tooltip';\nexport { Tooltip } from './tooltip';\nexport type { TourProps, TourStep } from './tour';\nexport { Tour } from './tour';\nexport type { TransferChangeInfo, TransferItem, TransferProps } from './transfer';\nexport { Transfer } from './transfer';\nexport type {\n TreeCheckInfo,\n TreeDropInfo,\n TreeExpandInfo,\n TreeNode,\n TreeProps,\n TreeSelectInfo,\n} from './tree';\nexport { moveTreeNode, Tree } from './tree';\nexport type { TreeSelectOption, TreeSelectProps, TreeSelectValue } from './treeselect';\nexport { TreeSelect } from './treeselect';\nexport type {\n LinkProps,\n ParagraphProps,\n TextProps,\n TitleProps,\n TypographyProps,\n} from './typography';\nexport { Link, Paragraph, Text, Title, Typography } from './typography';\nexport type {\n AvatarUploadProps,\n UploadChangeInfo,\n UploadFile,\n UploadProps,\n UploadRejection,\n UploadRequest,\n UploadResult,\n} from './upload';\nexport { AvatarUpload, Upload } from './upload';\nexport type { UploadHandle } from './upload/upload';\nexport type { VirtualListHandle, VirtualListProps } from './virtuallist';\nexport { VirtualList } from './virtuallist';\n"],"names":["Alert","Affix","Anchor","AutoComplete","Avatar","AvatarGroup","BackTop","Badge","Breadcrumb","Button","ButtonGroup","Calendar","Card","CardTitle","Carousel","Cascader","mapCascaderOptions","Checkbox","CheckboxGroup","Collapse","ColorPicker","gradientString","parseGradient","ConfigProvider","colorContrast","useBreakpoint","useSystemAppearance","ConfirmProvider","useConfirm","DatePicker","DateRangePicker","Descriptions","Divider","Drawer","Dropdown","Empty","ErrorBoundary","FileList","Flex","FAB","FloatButton","FloatButtonGroup","Form","FormErrorSummary","FormField","FormGroup","FormList","useFormValidation","Col","Grid","Row","ImagePreviewProvider","useImagePreview","InfiniteScroll","Input","InputGroup","InputSearch","InputMask","InputNumber","InputOTP","Layout","LayoutContent","LayoutFooter","LayoutHeader","LayoutSider","Loading","LoadingBar","LoadingBarProvider","useLoadingBar","Masonry","Mentions","Menu","MenuGroup","Message","MessageProvider","useMessage","Modal","Notification","NotificationProvider","useNotification","Pagination","Popconfirm","Popover","Progress","QRCode","Radio","RadioGroup","Rate","Result","ScrollArea","Scrollbar","Select","Skeleton","SkeletonAvatar","SkeletonButton","SkeletonImage","SkeletonInput","Slider","Space","ResizablePanels","Splitter","Countdown","Statistic","Steps","Switch","Table","Tabs","CheckableTag","Tag","TagGroup","Textarea","Timeline","Tooltip","Tour","Transfer","moveTreeNode","Tree","TreeSelect","Link","Paragraph","Text","Title","Typography","AvatarUpload","Upload","VirtualList"],"mappings":";;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA,0CAA0C,qCAAqC;AAC/E;AACA;AACA;AACA;AACA;AACA;;;;ACVA;;;;ACAA;AACA;AACA;AACA,uDAAuD,iBAAiB;AACxE;AACA,gDAAgD,aAAa;AAC7D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACCgC;AAES;AAMK;AAEC;AAEX;AAEJ;AAEU;AAOK;AAET;AAEG;AAEH;AAEoB;AAEL;AAEf;AAOqC;AAWxB;AAE2C;AAEtC;AAMd;AAOU;AAGN;AAEV;AAEF;AAEI;AAEN;AAEgB;AAEV;AAER;AAOqC;AAWa;AAE1B;AAEd;AAOwB;AAEd;AAEO;AAEjB;AAOI;AAEN;AAEoD;AAEtD;AAEyC;AAEzC;AAEE;AAEG;AAEwB;AAEjC;AAOqD;AAE3C;AAEA;AAEN;AAEE;AAEJ;AAEU;AAEd;AAEI;AAEQ;AAEF;AAON;AA0Bd;AAEc;AAEF;AAEuB;AAEJ;AAEnB;AAEE;AAmBF;AAEF;AAEsB;AAEd;AAIA;AAEF;AAEN;AAEQ;AASM;AAEF;AAQ8B;AAUxB;AAGJ"}
|
|
@@ -93,7 +93,7 @@ const LayoutRoot = /*#__PURE__*/ (0,external_react_namespaceObject.forwardRef)(f
|
|
|
93
93
|
});
|
|
94
94
|
});
|
|
95
95
|
const layout_LayoutSider = /*#__PURE__*/ (0,external_react_namespaceObject.forwardRef)(function LayoutSider(rawProps, ref) {
|
|
96
|
-
const { width = 220, collapsedWidth = 64, collapsed, defaultCollapsed = false, collapsible = false, breakpoint, onCollapse, trigger, className, children, style, ...props } = (0,component_defaults_cjs_namespaceObject.useComponentProps)('LayoutSider', rawProps);
|
|
96
|
+
const { width = 220, collapsedWidth = 64, collapsed, defaultCollapsed = false, collapsible = false, breakpoint, onCollapse, trigger, header, footer, className, children, style, ...props } = (0,component_defaults_cjs_namespaceObject.useComponentProps)('LayoutSider', rawProps);
|
|
97
97
|
const t = (0,use_text_cjs_namespaceObject.useText)();
|
|
98
98
|
const { direction } = (0,context_cjs_namespaceObject.useLeafConfig)();
|
|
99
99
|
const [compact, setCompact] = (0,use_controllable_cjs_namespaceObject.useControllable)(collapsed, defaultCollapsed, onCollapse);
|
|
@@ -121,12 +121,20 @@ const layout_LayoutSider = /*#__PURE__*/ (0,external_react_namespaceObject.forwa
|
|
|
121
121
|
...style
|
|
122
122
|
},
|
|
123
123
|
children: [
|
|
124
|
+
header != null && /*#__PURE__*/ (0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
125
|
+
className: "leaf-layout__sider-header",
|
|
126
|
+
children: header
|
|
127
|
+
}),
|
|
124
128
|
/*#__PURE__*/ (0,jsx_runtime_namespaceObject.jsx)(scrollbar_cjs_namespaceObject.ScrollbarControl, {
|
|
125
129
|
className: "leaf-layout__sider-content",
|
|
126
130
|
role: "presentation",
|
|
127
131
|
tabIndex: -1,
|
|
128
132
|
children: children
|
|
129
133
|
}),
|
|
134
|
+
footer != null && /*#__PURE__*/ (0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
135
|
+
className: "leaf-layout__sider-footer",
|
|
136
|
+
children: footer
|
|
137
|
+
}),
|
|
130
138
|
collapsible && !narrow && /*#__PURE__*/ (0,jsx_runtime_namespaceObject.jsx)(button_cjs_namespaceObject.ButtonControl, {
|
|
131
139
|
variant: "text",
|
|
132
140
|
size: "sm",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"layout/layout.cjs","sources":["webpack://webpack/runtime/define_property_getters","webpack://webpack/runtime/has_own_property","webpack://webpack/runtime/make_namespace_object","../../../../../src/layout/layout.tsx"],"sourcesContent":["__webpack_require__.d = (exports, getters, values) => {\n\tvar define = (defs, kind) => {\n\t\tfor(var key in defs) {\n\t\t\tif(__webpack_require__.o(defs, key) && !__webpack_require__.o(exports, key)) {\n\t\t\t\tObject.defineProperty(exports, key, { enumerable: true, [kind]: defs[key] });\n\t\t\t}\n\t\t}\n\t};\n\tdefine(getters, \"get\");\n\tdefine(values, \"value\");\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","import { ChevronLeft, ChevronRight } from 'lucide-react';\nimport { forwardRef, type HTMLAttributes, type ReactNode, useEffect, useState } from 'react';\nimport { ButtonControl } from '../button/button';\nimport { useComponentProps } from '../config-provider/component-defaults';\nimport { useLeafConfig } from '../config-provider/context';\nimport { ScrollbarControl } from '../scrollbar/scrollbar';\nimport { classes } from '../shared/classes';\nimport { useControllable } from '../shared/use-controllable';\nimport { useText } from '../shared/use-text';\n\nexport interface LayoutProps extends HTMLAttributes<HTMLDivElement> {\n direction?: 'horizontal' | 'vertical';\n}\nconst LayoutRoot = forwardRef<HTMLDivElement, LayoutProps>(function Layout(rawProps, ref) {\n const { direction = 'vertical', className, ...props } = useComponentProps('Layout', rawProps);\n return (\n <div\n {...props}\n ref={ref}\n className={classes('leaf-layout', `leaf-layout--${direction}`, className)}\n />\n );\n});\nexport interface LayoutSiderProps extends HTMLAttributes<HTMLElement> {\n width?: number | string;\n collapsedWidth?: number | string;\n collapsed?: boolean;\n defaultCollapsed?: boolean;\n collapsible?: boolean;\n breakpoint?: number;\n onCollapse?: (collapsed: boolean) => void;\n trigger?: ReactNode;\n}\nexport const LayoutSider = forwardRef<HTMLElement, LayoutSiderProps>(function LayoutSider(\n rawProps: LayoutSiderProps,\n ref,\n) {\n const {\n width = 220,\n collapsedWidth = 64,\n collapsed,\n defaultCollapsed = false,\n collapsible = false,\n breakpoint,\n onCollapse,\n trigger,\n className,\n children,\n style,\n ...props\n } = useComponentProps('LayoutSider', rawProps);\n const t = useText();\n const { direction } = useLeafConfig();\n const [compact, setCompact] = useControllable(collapsed, defaultCollapsed, onCollapse);\n const [narrow, setNarrow] = useState(false);\n useEffect(() => {\n if (breakpoint === undefined) return;\n const query = matchMedia(`(max-width: ${breakpoint}px)`);\n const update = () => setNarrow(query.matches);\n update();\n query.addEventListener('change', update);\n return () => query.removeEventListener('change', update);\n }, [breakpoint]);\n const folded = compact || narrow;\n const zeroCollapsed =\n folded &&\n (collapsedWidth === 0 ||\n (typeof collapsedWidth === 'string' && Number.parseFloat(collapsedWidth) === 0));\n const showExpandChevron = direction === 'rtl' ? !folded : folded;\n return (\n <aside\n {...props}\n ref={ref}\n className={classes(\n 'leaf-layout__sider',\n zeroCollapsed && 'leaf-layout__sider--zero',\n className,\n )}\n data-collapsed={folded || undefined}\n style={{ width: folded ? collapsedWidth : width, ...style }}\n >\n <ScrollbarControl className=\"leaf-layout__sider-content\" role=\"presentation\" tabIndex={-1}>\n {children}\n </ScrollbarControl>\n {collapsible && !narrow && (\n <ButtonControl\n variant=\"text\"\n size=\"sm\"\n onClick={() => setCompact(!compact)}\n aria-expanded={!folded}\n aria-label={folded ? t('layout.expandSidebar') : t('layout.collapseSidebar')}\n >\n {trigger !== undefined ? (\n trigger\n ) : showExpandChevron ? (\n <ChevronRight size={16} aria-hidden=\"true\" />\n ) : (\n <ChevronLeft size={16} aria-hidden=\"true\" />\n )}\n </ButtonControl>\n )}\n </aside>\n );\n});\nexport const LayoutHeader = forwardRef<HTMLElement, HTMLAttributes<HTMLElement>>(\n function LayoutHeader(rawProps: HTMLAttributes<HTMLElement>, ref) {\n const { className, ...props } = useComponentProps('LayoutHeader', rawProps);\n return <header {...props} ref={ref} className={classes('leaf-layout__header', className)} />;\n },\n);\nexport const LayoutContent = forwardRef<HTMLElement, HTMLAttributes<HTMLElement>>(\n function LayoutContent(rawProps: HTMLAttributes<HTMLElement>, ref) {\n const { className, ...props } = useComponentProps('LayoutContent', rawProps);\n return <main {...props} ref={ref} className={classes('leaf-layout__content', className)} />;\n },\n);\nexport const LayoutFooter = forwardRef<HTMLElement, HTMLAttributes<HTMLElement>>(\n function LayoutFooter(rawProps: HTMLAttributes<HTMLElement>, ref) {\n const { className, ...props } = useComponentProps('LayoutFooter', rawProps);\n return <footer {...props} ref={ref} className={classes('leaf-layout__footer', className)} />;\n },\n);\nexport const Layout = Object.assign(LayoutRoot, {\n Header: LayoutHeader,\n Sider: LayoutSider,\n Content: LayoutContent,\n Footer: LayoutFooter,\n});\n"],"names":["ChevronLeft","ChevronRight","forwardRef","useEffect","useState","ButtonControl","useComponentProps","useLeafConfig","ScrollbarControl","classes","useControllable","useText","LayoutRoot","Layout","rawProps","ref","direction","className","props","LayoutSider","width","collapsedWidth","collapsed","defaultCollapsed","collapsible","breakpoint","onCollapse","trigger","children","style","t","compact","setCompact","narrow","setNarrow","undefined","query","matchMedia","update","folded","zeroCollapsed","Number","showExpandChevron","LayoutHeader","LayoutContent","LayoutFooter","Object"],"mappings":";;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA,0CAA0C,qCAAqC;AAC/E;AACA;AACA;AACA;AACA;AACA;;;;ACVA;;;;ACAA;AACA;AACA;AACA,uDAAuD,iBAAiB;AACxE;AACA,gDAAgD,aAAa;AAC7D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACNyD;AACoC;AAC5C;AACyB;AACf;AACD;AACd;AACiB;AAChB;AAK7C,MAAMY,2BAAaV,6CAAUA,CAA8B,SAASW,OAAOC,QAAQ,EAAEC,GAAG;IACtF,MAAM,EAAEC,YAAY,UAAU,EAAEC,SAAS,EAAE,GAAGC,OAAO,GAAGZ,4DAAiBA,CAAC,UAAUQ;IACpF,qBACE,oCAAC;QACE,GAAGI,KAAK;QACT,KAAKH;QACL,WAAWN,uCAAOA,CAAC,eAAe,CAAC,aAAa,EAAEO,WAAW,EAAEC;;AAGrE;
|
|
1
|
+
{"version":3,"file":"layout/layout.cjs","sources":["webpack://webpack/runtime/define_property_getters","webpack://webpack/runtime/has_own_property","webpack://webpack/runtime/make_namespace_object","../../../../../src/layout/layout.tsx"],"sourcesContent":["__webpack_require__.d = (exports, getters, values) => {\n\tvar define = (defs, kind) => {\n\t\tfor(var key in defs) {\n\t\t\tif(__webpack_require__.o(defs, key) && !__webpack_require__.o(exports, key)) {\n\t\t\t\tObject.defineProperty(exports, key, { enumerable: true, [kind]: defs[key] });\n\t\t\t}\n\t\t}\n\t};\n\tdefine(getters, \"get\");\n\tdefine(values, \"value\");\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","import { ChevronLeft, ChevronRight } from 'lucide-react';\nimport { forwardRef, type HTMLAttributes, type ReactNode, useEffect, useState } from 'react';\nimport { ButtonControl } from '../button/button';\nimport { useComponentProps } from '../config-provider/component-defaults';\nimport { useLeafConfig } from '../config-provider/context';\nimport { ScrollbarControl } from '../scrollbar/scrollbar';\nimport { classes } from '../shared/classes';\nimport { useControllable } from '../shared/use-controllable';\nimport { useText } from '../shared/use-text';\n\nexport interface LayoutProps extends HTMLAttributes<HTMLDivElement> {\n direction?: 'horizontal' | 'vertical';\n}\nconst LayoutRoot = forwardRef<HTMLDivElement, LayoutProps>(function Layout(rawProps, ref) {\n const { direction = 'vertical', className, ...props } = useComponentProps('Layout', rawProps);\n return (\n <div\n {...props}\n ref={ref}\n className={classes('leaf-layout', `leaf-layout--${direction}`, className)}\n />\n );\n});\nexport interface LayoutSiderProps extends HTMLAttributes<HTMLElement> {\n width?: number | string;\n collapsedWidth?: number | string;\n collapsed?: boolean;\n defaultCollapsed?: boolean;\n collapsible?: boolean;\n breakpoint?: number;\n onCollapse?: (collapsed: boolean) => void;\n trigger?: ReactNode;\n header?: ReactNode;\n footer?: ReactNode;\n}\nexport const LayoutSider = forwardRef<HTMLElement, LayoutSiderProps>(function LayoutSider(\n rawProps: LayoutSiderProps,\n ref,\n) {\n const {\n width = 220,\n collapsedWidth = 64,\n collapsed,\n defaultCollapsed = false,\n collapsible = false,\n breakpoint,\n onCollapse,\n trigger,\n header,\n footer,\n className,\n children,\n style,\n ...props\n } = useComponentProps('LayoutSider', rawProps);\n const t = useText();\n const { direction } = useLeafConfig();\n const [compact, setCompact] = useControllable(collapsed, defaultCollapsed, onCollapse);\n const [narrow, setNarrow] = useState(false);\n useEffect(() => {\n if (breakpoint === undefined) return;\n const query = matchMedia(`(max-width: ${breakpoint}px)`);\n const update = () => setNarrow(query.matches);\n update();\n query.addEventListener('change', update);\n return () => query.removeEventListener('change', update);\n }, [breakpoint]);\n const folded = compact || narrow;\n const zeroCollapsed =\n folded &&\n (collapsedWidth === 0 ||\n (typeof collapsedWidth === 'string' && Number.parseFloat(collapsedWidth) === 0));\n const showExpandChevron = direction === 'rtl' ? !folded : folded;\n return (\n <aside\n {...props}\n ref={ref}\n className={classes(\n 'leaf-layout__sider',\n zeroCollapsed && 'leaf-layout__sider--zero',\n className,\n )}\n data-collapsed={folded || undefined}\n style={{ width: folded ? collapsedWidth : width, ...style }}\n >\n {header != null && <div className=\"leaf-layout__sider-header\">{header}</div>}\n <ScrollbarControl className=\"leaf-layout__sider-content\" role=\"presentation\" tabIndex={-1}>\n {children}\n </ScrollbarControl>\n {footer != null && <div className=\"leaf-layout__sider-footer\">{footer}</div>}\n {collapsible && !narrow && (\n <ButtonControl\n variant=\"text\"\n size=\"sm\"\n onClick={() => setCompact(!compact)}\n aria-expanded={!folded}\n aria-label={folded ? t('layout.expandSidebar') : t('layout.collapseSidebar')}\n >\n {trigger !== undefined ? (\n trigger\n ) : showExpandChevron ? (\n <ChevronRight size={16} aria-hidden=\"true\" />\n ) : (\n <ChevronLeft size={16} aria-hidden=\"true\" />\n )}\n </ButtonControl>\n )}\n </aside>\n );\n});\nexport const LayoutHeader = forwardRef<HTMLElement, HTMLAttributes<HTMLElement>>(\n function LayoutHeader(rawProps: HTMLAttributes<HTMLElement>, ref) {\n const { className, ...props } = useComponentProps('LayoutHeader', rawProps);\n return <header {...props} ref={ref} className={classes('leaf-layout__header', className)} />;\n },\n);\nexport const LayoutContent = forwardRef<HTMLElement, HTMLAttributes<HTMLElement>>(\n function LayoutContent(rawProps: HTMLAttributes<HTMLElement>, ref) {\n const { className, ...props } = useComponentProps('LayoutContent', rawProps);\n return <main {...props} ref={ref} className={classes('leaf-layout__content', className)} />;\n },\n);\nexport const LayoutFooter = forwardRef<HTMLElement, HTMLAttributes<HTMLElement>>(\n function LayoutFooter(rawProps: HTMLAttributes<HTMLElement>, ref) {\n const { className, ...props } = useComponentProps('LayoutFooter', rawProps);\n return <footer {...props} ref={ref} className={classes('leaf-layout__footer', className)} />;\n },\n);\nexport const Layout = Object.assign(LayoutRoot, {\n Header: LayoutHeader,\n Sider: LayoutSider,\n Content: LayoutContent,\n Footer: LayoutFooter,\n});\n"],"names":["ChevronLeft","ChevronRight","forwardRef","useEffect","useState","ButtonControl","useComponentProps","useLeafConfig","ScrollbarControl","classes","useControllable","useText","LayoutRoot","Layout","rawProps","ref","direction","className","props","LayoutSider","width","collapsedWidth","collapsed","defaultCollapsed","collapsible","breakpoint","onCollapse","trigger","header","footer","children","style","t","compact","setCompact","narrow","setNarrow","undefined","query","matchMedia","update","folded","zeroCollapsed","Number","showExpandChevron","LayoutHeader","LayoutContent","LayoutFooter","Object"],"mappings":";;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA,0CAA0C,qCAAqC;AAC/E;AACA;AACA;AACA;AACA;AACA;;;;ACVA;;;;ACAA;AACA;AACA;AACA,uDAAuD,iBAAiB;AACxE;AACA,gDAAgD,aAAa;AAC7D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACNyD;AACoC;AAC5C;AACyB;AACf;AACD;AACd;AACiB;AAChB;AAK7C,MAAMY,2BAAaV,6CAAUA,CAA8B,SAASW,OAAOC,QAAQ,EAAEC,GAAG;IACtF,MAAM,EAAEC,YAAY,UAAU,EAAEC,SAAS,EAAE,GAAGC,OAAO,GAAGZ,4DAAiBA,CAAC,UAAUQ;IACpF,qBACE,oCAAC;QACE,GAAGI,KAAK;QACT,KAAKH;QACL,WAAWN,uCAAOA,CAAC,eAAe,CAAC,aAAa,EAAEO,WAAW,EAAEC;;AAGrE;AAaO,MAAME,kBAAWA,iBAAGjB,6CAAUA,CAAgC,SAASiB,YAC5E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,aAAMA,GAAGmC,OAAO,MAAM,CAACpC,YAAY;IAC9C,QAAQiC,mBAAYA;IACpB,OAAO1B,kBAAWA;IAClB,SAAS2B,oBAAaA;IACtB,QAAQC,mBAAYA;AACtB,GAAG"}
|
|
@@ -145,9 +145,15 @@ function MenuSubmenu({ open, id, label, children }) {
|
|
|
145
145
|
});
|
|
146
146
|
}
|
|
147
147
|
function Menu(rawProps) {
|
|
148
|
-
const { items, selectedKey, defaultSelectedKey = '', onSelect, openKeys, defaultOpenKeys = [], onOpenChange, collapsed = false, variant = 'neutral', itemRender, linkRender, itemClassName, className, ...props } = (0,component_defaults_cjs_namespaceObject.useComponentProps)('Menu', rawProps);
|
|
148
|
+
const { items, selectedKey, defaultSelectedKey = '', onSelect, openKeys, defaultOpenKeys = [], onOpenChange, collapsed = false, embedded = false, variant = 'neutral', itemRender, linkRender, itemClassName, className, ...props } = (0,component_defaults_cjs_namespaceObject.useComponentProps)('Menu', rawProps);
|
|
149
|
+
const { direction, theme } = (0,context_cjs_namespaceObject.useLeafConfig)();
|
|
149
150
|
const t = (0,use_text_cjs_namespaceObject.useText)();
|
|
150
|
-
const
|
|
151
|
+
const customMenuBackground = props.style?.['--leaf-component-menu-background'] ?? props.style?.background ?? props.style?.backgroundColor ?? theme?.components?.Menu?.background;
|
|
152
|
+
const hasCustomBackground = typeof customMenuBackground === 'string' && customMenuBackground.trim().length > 0;
|
|
153
|
+
const explicitTransparentBg = typeof customMenuBackground === 'string' && customMenuBackground.trim() === 'transparent';
|
|
154
|
+
const collapsedPopupStyle = explicitTransparentBg ? {
|
|
155
|
+
'--leaf-component-menu-background': 'var(--leaf-color-surface-raised)'
|
|
156
|
+
} : undefined;
|
|
151
157
|
const id = (0,external_react_namespaceObject.useId)();
|
|
152
158
|
const root = (0,external_react_namespaceObject.useRef)(null);
|
|
153
159
|
const [selected, setSelected] = (0,use_controllable_cjs_namespaceObject.useControllable)(selectedKey, defaultSelectedKey);
|
|
@@ -280,6 +286,7 @@ function Menu(rawProps) {
|
|
|
280
286
|
getItemClassName: itemClassName ? (entry)=>typeof itemClassName === 'function' ? itemClassName(getOriginal(entry)) : itemClassName : undefined
|
|
281
287
|
},
|
|
282
288
|
popupWidth: 208,
|
|
289
|
+
popupStyle: collapsedPopupStyle,
|
|
283
290
|
popupPlacement: direction === 'rtl' ? 'left-start' : 'right-start',
|
|
284
291
|
open: expanded,
|
|
285
292
|
disabled: item.disabled,
|
|
@@ -333,7 +340,8 @@ function Menu(rawProps) {
|
|
|
333
340
|
return /*#__PURE__*/ (0,jsx_runtime_namespaceObject.jsx)("nav", {
|
|
334
341
|
...props,
|
|
335
342
|
ref: root,
|
|
336
|
-
className: (0,classes_cjs_namespaceObject.classes)('leaf-menu', `leaf-menu--${variant}`, collapsed && 'leaf-menu--collapsed', className),
|
|
343
|
+
className: (0,classes_cjs_namespaceObject.classes)('leaf-menu', `leaf-menu--${variant}`, collapsed && 'leaf-menu--collapsed', embedded && 'leaf-menu--embedded', className),
|
|
344
|
+
"data-custom-background": hasCustomBackground || undefined,
|
|
337
345
|
"aria-label": props['aria-label'] ?? t('menu.navigationMenu'),
|
|
338
346
|
children: /*#__PURE__*/ (0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
339
347
|
role: "menu",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"menu/menu.cjs","sources":["webpack://webpack/runtime/define_property_getters","webpack://webpack/runtime/has_own_property","webpack://webpack/runtime/make_namespace_object","../../../../../src/menu/menu.tsx"],"sourcesContent":["__webpack_require__.d = (exports, getters, values) => {\n\tvar define = (defs, kind) => {\n\t\tfor(var key in defs) {\n\t\t\tif(__webpack_require__.o(defs, key) && !__webpack_require__.o(exports, key)) {\n\t\t\t\tObject.defineProperty(exports, key, { enumerable: true, [kind]: defs[key] });\n\t\t\t}\n\t\t}\n\t};\n\tdefine(getters, \"get\");\n\tdefine(values, \"value\");\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","import { ChevronDown } from 'lucide-react';\nimport {\n type CSSProperties,\n forwardRef,\n type HTMLAttributes,\n isValidElement,\n type ReactNode,\n type Ref,\n useEffect,\n useId,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\nimport { useComponentProps } from '../config-provider/component-defaults';\nimport { useLeafConfig } from '../config-provider/context';\nimport type { DropdownItem } from '../dropdown';\nimport { DropdownControl as Dropdown } from '../dropdown/dropdown';\nimport { classes } from '../shared/classes';\nimport { inertProps } from '../shared/inert';\nimport { useControllable } from '../shared/use-controllable';\nimport { useText } from '../shared/use-text';\nimport { TooltipControl } from '../tooltip/tooltip';\n\nconst useBrowserLayoutEffect = typeof window === 'undefined' ? useEffect : useLayoutEffect;\n\nexport interface MenuGroupProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title'> {\n title: ReactNode;\n}\n\nconst MenuGroupControl = forwardRef<HTMLDivElement, MenuGroupProps>(function MenuGroupControl(\n { title, children, className, ...props },\n ref,\n) {\n const titleId = useId();\n return (\n // biome-ignore lint/a11y/useSemanticElements: Menu groups and arbitrary sidebar content are not form fieldsets.\n <div\n role=\"group\"\n aria-labelledby={props['aria-label'] !== undefined ? undefined : titleId}\n {...props}\n ref={ref}\n className={classes('leaf-menu__group', className)}\n >\n <div id={titleId} className=\"leaf-menu__group-label\">\n {title}\n </div>\n {children}\n </div>\n );\n});\n\nexport const MenuGroup = forwardRef<HTMLDivElement, MenuGroupProps>(\n function MenuGroup(rawProps, ref) {\n const props = useComponentProps('MenuGroup', rawProps);\n return (\n <MenuGroupControl\n {...props}\n ref={ref}\n className={classes('leaf-menu-group', props.className)}\n />\n );\n },\n);\n\nexport interface MenuItem {\n key: string;\n label: ReactNode;\n icon?: ReactNode;\n extra?: ReactNode;\n href?: string;\n disabled?: boolean;\n danger?: boolean;\n children?: readonly MenuItem[];\n type?: 'item' | 'group' | 'divider';\n}\nexport interface MenuProps extends Omit<HTMLAttributes<HTMLElement>, 'onSelect'> {\n items: readonly MenuItem[];\n variant?: 'neutral' | 'raised' | 'primary';\n selectedKey?: string;\n defaultSelectedKey?: string;\n onSelect?: (key: string, item: MenuItem) => void;\n openKeys?: readonly string[];\n defaultOpenKeys?: readonly string[];\n onOpenChange?: (keys: string[]) => void;\n collapsed?: boolean;\n itemRender?: (item: MenuItem, content: ReactNode) => ReactNode;\n linkRender?: (item: MenuItem, link: ReactNode) => ReactNode;\n itemClassName?: string | ((item: MenuItem) => string);\n}\nfunction MenuSubmenu({\n open,\n id,\n label,\n children,\n}: {\n open: boolean;\n id: string;\n label?: string;\n children: () => ReactNode;\n}) {\n const panel = useRef<HTMLDivElement>(null);\n const [expanded, setExpanded] = useState(open);\n const [visited, setVisited] = useState(open);\n if (open && !visited) setVisited(true);\n useBrowserLayoutEffect(() => {\n if (expanded === open) return;\n // Establish layout with lazy content mounted before changing the transition target.\n panel.current?.getBoundingClientRect();\n setExpanded(open);\n }, [expanded, open]);\n return (\n <div\n ref={panel}\n id={id}\n role=\"menu\"\n className=\"leaf-menu__submenu\"\n aria-label={label}\n aria-hidden={!open || undefined}\n {...inertProps(!open)}\n data-open={expanded || undefined}\n >\n <div className=\"leaf-menu__submenu-inner\">\n <div className=\"leaf-menu__submenu-content\">{visited && children()}</div>\n </div>\n </div>\n );\n}\nexport function Menu(rawProps: MenuProps) {\n const {\n items,\n selectedKey,\n defaultSelectedKey = '',\n onSelect,\n openKeys,\n defaultOpenKeys = [],\n onOpenChange,\n collapsed = false,\n variant = 'neutral',\n itemRender,\n linkRender,\n itemClassName,\n className,\n ...props\n } = useComponentProps('Menu', rawProps);\n const t = useText();\n const { direction } = useLeafConfig();\n const id = useId();\n const root = useRef<HTMLElement>(null);\n const [selected, setSelected] = useControllable(selectedKey, defaultSelectedKey);\n const [active, setActive] = useState<string | undefined>(undefined);\n const [opened, setOpened] = useControllable<readonly string[]>(\n openKeys,\n defaultOpenKeys,\n (keys) => onOpenChange?.([...keys]),\n );\n const [collapsedPopupKey, setCollapsedPopupKey] = useState<string | null>(null);\n useEffect(() => {\n if (!collapsed) setCollapsedPopupKey(null);\n }, [collapsed]);\n const toggle = (key: string) =>\n setOpened(opened.includes(key) ? opened.filter((value) => value !== key) : [...opened, key]);\n const visibleItems: MenuItem[] = [];\n const itemByKey = new Map<string, MenuItem>();\n const collect = (entries: readonly MenuItem[], insideVisible = true) => {\n for (const item of entries) {\n itemByKey.set(item.key, item);\n if (item.type === 'group') collect(item.children ?? [], insideVisible);\n else if (item.type !== 'divider') {\n if (insideVisible && !item.disabled) visibleItems.push(item);\n collect(item.children ?? [], insideVisible && opened.includes(item.key) && !collapsed);\n }\n }\n };\n collect(items);\n const focusKey = visibleItems.some((item) => item.key === active)\n ? active\n : (visibleItems.find((item) => item.key === selected)?.key ?? visibleItems[0]?.key);\n const getOriginal = (entry: DropdownItem): MenuItem =>\n itemByKey.get(entry.key) ?? (entry as MenuItem);\n const parentOf = (\n entries: readonly MenuItem[],\n targetKey: string,\n parentItem?: MenuItem,\n ): MenuItem | undefined => {\n for (const entry of entries) {\n if (entry.key === targetKey) return parentItem;\n const parent = parentOf(\n entry.children ?? [],\n targetKey,\n entry.type === 'group' ? parentItem : entry,\n );\n if (parent) return parent;\n }\n return undefined;\n };\n const convert = (entries: readonly MenuItem[]): DropdownItem[] =>\n entries.map((item) => ({\n ...item,\n children: item.children ? convert(item.children) : undefined,\n onClick: () => {\n if (!item.children?.length) {\n setSelected(item.key);\n onSelect?.(item.key, item);\n }\n },\n }));\n const renderItems = (entries: readonly MenuItem[], depth: number): ReactNode =>\n entries.map((item) => {\n if (item.type === 'divider') return <hr className=\"leaf-menu__divider\" key={item.key} />;\n if (item.type === 'group')\n return (\n <MenuGroupControl key={item.key} title={item.label}>\n {renderItems(item.children ?? [], depth)}\n </MenuGroupControl>\n );\n const hasChildren = Boolean(item.children?.length);\n const expanded =\n collapsed && hasChildren ? collapsedPopupKey === item.key : opened.includes(item.key);\n const originalContent = (\n <>\n {item.icon && (\n <span className=\"leaf-menu__icon\" aria-hidden=\"true\">\n {item.icon}\n </span>\n )}\n {!item.icon && collapsed && (\n <span className=\"leaf-menu__icon\" aria-hidden=\"true\">\n {typeof item.label === 'string' ? item.label.slice(0, 1) : '·'}\n </span>\n )}\n <span className=\"leaf-menu__label\">{item.label}</span>\n {!collapsed && item.extra != null && (\n <>\n {' '}\n <span className=\"leaf-menu__extra\">{item.extra}</span>\n </>\n )}\n {hasChildren && <ChevronDown className=\"leaf-menu__arrow\" size={14} aria-hidden=\"true\" />}\n </>\n );\n const content = itemRender?.(item, originalContent) ?? originalContent;\n const common = {\n role: 'menuitem',\n 'aria-current': !hasChildren && selected === item.key ? ('page' as const) : undefined,\n 'aria-disabled': item.disabled || undefined,\n 'aria-expanded': hasChildren ? expanded : undefined,\n 'aria-controls': hasChildren ? `${id}-${item.key}` : undefined,\n 'data-selected': (!hasChildren && selected === item.key) || undefined,\n 'data-selectable': !hasChildren || undefined,\n 'data-danger': item.danger || undefined,\n className: classes(\n 'leaf-menu__item',\n typeof itemClassName === 'function' ? itemClassName(item) : itemClassName,\n ),\n tabIndex: !item.disabled && focusKey === item.key ? 0 : -1,\n 'data-menu-key': item.key,\n 'aria-label': collapsed && typeof item.label === 'string' ? item.label : undefined,\n onFocus: () => setActive(item.key),\n style: {\n '--leaf-menu-depth': depth,\n } as CSSProperties,\n };\n const activate = () => {\n if (item.disabled) return;\n if (hasChildren) toggle(item.key);\n else {\n setSelected(item.key);\n onSelect?.(item.key, item);\n }\n };\n if (hasChildren && collapsed)\n return (\n <div key={item.key} className=\"leaf-menu__entry\">\n <Dropdown\n items={convert(item.children ?? [])}\n navigation={{\n selectedKey: selected,\n title: collapsed ? item.label : undefined,\n variant,\n renderLink: linkRender\n ? (entry, link) => linkRender(getOriginal(entry), link)\n : undefined,\n renderItem: itemRender\n ? (entry, node) => itemRender(getOriginal(entry), node)\n : undefined,\n getItemClassName: itemClassName\n ? (entry) =>\n typeof itemClassName === 'function'\n ? itemClassName(getOriginal(entry))\n : itemClassName\n : undefined,\n }}\n popupWidth={208}\n popupPlacement={direction === 'rtl' ? 'left-start' : 'right-start'}\n open={expanded}\n disabled={item.disabled}\n onOpenChange={(next) => setCollapsedPopupKey(next ? item.key : null)}\n >\n <button\n {...common}\n type=\"button\"\n onKeyDown={(event) => {\n if (\n collapsed &&\n event.key === (direction === 'rtl' ? 'ArrowLeft' : 'ArrowRight')\n ) {\n event.preventDefault();\n if (!item.disabled) setCollapsedPopupKey(item.key);\n }\n }}\n >\n {content}\n </button>\n </Dropdown>\n </div>\n );\n const triggerNode =\n item.href && !hasChildren ? (\n ((link: ReactNode) => linkRender?.(item, link) ?? link)(\n <a\n {...common}\n href={item.disabled ? undefined : item.href}\n onClick={(event) => {\n if (item.disabled) event.preventDefault();\n else activate();\n }}\n >\n {content}\n </a>,\n )\n ) : (\n <button {...common} type=\"button\" disabled={item.disabled} onClick={activate}>\n {content}\n </button>\n );\n return (\n <div key={item.key} className=\"leaf-menu__entry\">\n {collapsed &&\n !hasChildren &&\n isValidElement<\n HTMLAttributes<HTMLElement> & { ref?: Ref<HTMLElement>; disabled?: boolean }\n >(triggerNode) ? (\n <TooltipControl\n content={item.label}\n placement={direction === 'rtl' ? 'left' : 'right'}\n disabled={item.disabled || item.label == null || item.label === ''}\n >\n {triggerNode}\n </TooltipControl>\n ) : (\n triggerNode\n )}\n {hasChildren && (\n <MenuSubmenu\n id={`${id}-${item.key}`}\n open={expanded}\n label={typeof item.label === 'string' ? item.label : undefined}\n >\n {() => renderItems(item.children ?? [], depth + 1)}\n </MenuSubmenu>\n )}\n </div>\n );\n });\n return (\n <nav\n {...props}\n ref={root}\n className={classes(\n 'leaf-menu',\n `leaf-menu--${variant}`,\n collapsed && 'leaf-menu--collapsed',\n className,\n )}\n aria-label={props['aria-label'] ?? t('menu.navigationMenu')}\n >\n <div\n role=\"menu\"\n onKeyDown={(event) => {\n if (event.defaultPrevented) return;\n if (\n !['ArrowDown', 'ArrowUp', 'ArrowRight', 'ArrowLeft', 'Home', 'End', 'Escape'].includes(\n event.key,\n )\n )\n return;\n const target = event.target as HTMLElement;\n const choices = [\n ...(root.current?.querySelectorAll<HTMLElement>(\n '[role=\"menuitem\"]:not([aria-disabled=\"true\"])',\n ) ?? []),\n ].filter((node) => visibleItems.some((item) => item.key === node.dataset.menuKey));\n const position = choices.indexOf(target.closest('[role=\"menuitem\"]') as HTMLElement);\n const key = choices[position]?.dataset.menuKey;\n const item = visibleItems.find((entry) => entry.key === key);\n const focusItem = (nextKey: string) => {\n setActive(nextKey);\n queueMicrotask(() => {\n const node = [\n ...(root.current?.querySelectorAll<HTMLElement>('[data-menu-key]') ?? []),\n ].find((entry) => entry.dataset.menuKey === nextKey);\n node?.focus();\n });\n };\n if (event.key === 'Escape') {\n if (!collapsed && item) {\n const parent = parentOf(items, item.key);\n if (parent && opened.includes(parent.key)) {\n event.preventDefault();\n setOpened(opened.filter((value) => value !== parent.key));\n focusItem(parent.key);\n } else if (opened.includes(item.key)) {\n event.preventDefault();\n setOpened(opened.filter((value) => value !== item.key));\n }\n }\n return;\n }\n if (!collapsed && item) {\n if (event.key === (direction === 'rtl' ? 'ArrowLeft' : 'ArrowRight')) {\n event.preventDefault();\n if (item.children?.length) {\n if (!opened.includes(item.key)) setOpened([...opened, item.key]);\n else {\n const firstEnabled = (entries: readonly MenuItem[]): MenuItem | undefined => {\n for (const entry of entries) {\n if (entry.type === 'group') {\n const child = firstEnabled(entry.children ?? []);\n if (child) return child;\n } else if (!entry.disabled && entry.type !== 'divider') return entry;\n }\n return undefined;\n };\n const child = firstEnabled(item.children);\n if (child) focusItem(child.key);\n }\n }\n return;\n }\n if (event.key === (direction === 'rtl' ? 'ArrowRight' : 'ArrowLeft')) {\n event.preventDefault();\n if (opened.includes(item.key)) toggle(item.key);\n else {\n const parent = parentOf(items, item.key);\n if (parent) focusItem(parent.key);\n }\n return;\n }\n }\n const next =\n event.key === 'Home'\n ? 0\n : event.key === 'End'\n ? choices.length - 1\n : (position +\n (event.key === 'ArrowUp' ||\n event.key === (direction === 'rtl' ? 'ArrowRight' : 'ArrowLeft')\n ? -1\n : 1) +\n choices.length) %\n choices.length;\n event.preventDefault();\n const nextKey = choices[next]?.dataset.menuKey;\n if (nextKey) setActive(nextKey);\n choices[next]?.focus();\n }}\n >\n {renderItems(items, 0)}\n </div>\n </nav>\n );\n}\n"],"names":["ChevronDown","forwardRef","isValidElement","useEffect","useId","useLayoutEffect","useRef","useState","useComponentProps","useLeafConfig","DropdownControl","Dropdown","classes","inertProps","useControllable","useText","TooltipControl","useBrowserLayoutEffect","window","MenuGroupControl","title","children","className","props","ref","titleId","undefined","MenuGroup","rawProps","MenuSubmenu","open","id","label","panel","expanded","setExpanded","visited","setVisited","Menu","items","selectedKey","defaultSelectedKey","onSelect","openKeys","defaultOpenKeys","onOpenChange","collapsed","variant","itemRender","linkRender","itemClassName","t","direction","root","selected","setSelected","active","setActive","opened","setOpened","keys","collapsedPopupKey","setCollapsedPopupKey","toggle","key","value","visibleItems","itemByKey","Map","collect","entries","insideVisible","item","focusKey","getOriginal","entry","parentOf","targetKey","parentItem","parent","convert","renderItems","depth","hasChildren","Boolean","originalContent","content","common","activate","link","node","next","event","triggerNode","target","choices","position","focusItem","nextKey","queueMicrotask","firstEnabled","child"],"mappings":";;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA,0CAA0C,qCAAqC;AAC/E;AACA;AACA;AACA;AACA;AACA;;;;ACVA;;;;ACAA;AACA;AACA;AACA,uDAAuD,iBAAiB;AACxE;AACA,gDAAgD,aAAa;AAC7D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACN2C;AAa5B;AAC2D;AACf;AAEQ;AACvB;AACC;AACgB;AAChB;AACO;AAEpD,MAAMiB,yBAAyB,OAAOC,WAA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MxC,CAAAA,cAAc,QAAQ,eAAe,WAAU,IAC1D,CAAC,IACD,KACJ2C,QAAQ,MAAK,IACfA,QAAQ,MAAM;gBACtBH,MAAM,cAAc;gBACpB,MAAMM,UAAUH,OAAO,CAACJ,KAAK,EAAE,QAAQ;gBACvC,IAAIO,SAASzC,UAAUyC;gBACvBH,OAAO,CAACJ,KAAK,EAAE;YACjB;sBAECV,YAAY1C,OAAO;;;AAI5B"}
|
|
1
|
+
{"version":3,"file":"menu/menu.cjs","sources":["webpack://webpack/runtime/define_property_getters","webpack://webpack/runtime/has_own_property","webpack://webpack/runtime/make_namespace_object","../../../../../src/menu/menu.tsx"],"sourcesContent":["__webpack_require__.d = (exports, getters, values) => {\n\tvar define = (defs, kind) => {\n\t\tfor(var key in defs) {\n\t\t\tif(__webpack_require__.o(defs, key) && !__webpack_require__.o(exports, key)) {\n\t\t\t\tObject.defineProperty(exports, key, { enumerable: true, [kind]: defs[key] });\n\t\t\t}\n\t\t}\n\t};\n\tdefine(getters, \"get\");\n\tdefine(values, \"value\");\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","import { ChevronDown } from 'lucide-react';\nimport {\n type CSSProperties,\n forwardRef,\n type HTMLAttributes,\n isValidElement,\n type ReactNode,\n type Ref,\n useEffect,\n useId,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\nimport { useComponentProps } from '../config-provider/component-defaults';\nimport { useLeafConfig } from '../config-provider/context';\nimport type { DropdownItem } from '../dropdown';\nimport { DropdownControl as Dropdown } from '../dropdown/dropdown';\nimport { classes } from '../shared/classes';\nimport { inertProps } from '../shared/inert';\nimport { useControllable } from '../shared/use-controllable';\nimport { useText } from '../shared/use-text';\nimport { TooltipControl } from '../tooltip/tooltip';\n\nconst useBrowserLayoutEffect = typeof window === 'undefined' ? useEffect : useLayoutEffect;\n\nexport interface MenuGroupProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title'> {\n title: ReactNode;\n}\n\nconst MenuGroupControl = forwardRef<HTMLDivElement, MenuGroupProps>(function MenuGroupControl(\n { title, children, className, ...props },\n ref,\n) {\n const titleId = useId();\n return (\n // biome-ignore lint/a11y/useSemanticElements: Menu groups and arbitrary sidebar content are not form fieldsets.\n <div\n role=\"group\"\n aria-labelledby={props['aria-label'] !== undefined ? undefined : titleId}\n {...props}\n ref={ref}\n className={classes('leaf-menu__group', className)}\n >\n <div id={titleId} className=\"leaf-menu__group-label\">\n {title}\n </div>\n {children}\n </div>\n );\n});\n\nexport const MenuGroup = forwardRef<HTMLDivElement, MenuGroupProps>(\n function MenuGroup(rawProps, ref) {\n const props = useComponentProps('MenuGroup', rawProps);\n return (\n <MenuGroupControl\n {...props}\n ref={ref}\n className={classes('leaf-menu-group', props.className)}\n />\n );\n },\n);\n\nexport interface MenuItem {\n key: string;\n label: ReactNode;\n icon?: ReactNode;\n extra?: ReactNode;\n href?: string;\n disabled?: boolean;\n danger?: boolean;\n children?: readonly MenuItem[];\n type?: 'item' | 'group' | 'divider';\n}\nexport interface MenuProps extends Omit<HTMLAttributes<HTMLElement>, 'onSelect'> {\n items: readonly MenuItem[];\n variant?: 'neutral' | 'raised' | 'primary';\n selectedKey?: string;\n defaultSelectedKey?: string;\n onSelect?: (key: string, item: MenuItem) => void;\n openKeys?: readonly string[];\n defaultOpenKeys?: readonly string[];\n onOpenChange?: (keys: string[]) => void;\n collapsed?: boolean;\n /** 嵌入侧栏等外层容器时移除独立背景、外内边距并撑满容器宽度。 */\n embedded?: boolean;\n itemRender?: (item: MenuItem, content: ReactNode) => ReactNode;\n linkRender?: (item: MenuItem, link: ReactNode) => ReactNode;\n itemClassName?: string | ((item: MenuItem) => string);\n}\nfunction MenuSubmenu({\n open,\n id,\n label,\n children,\n}: {\n open: boolean;\n id: string;\n label?: string;\n children: () => ReactNode;\n}) {\n const panel = useRef<HTMLDivElement>(null);\n const [expanded, setExpanded] = useState(open);\n const [visited, setVisited] = useState(open);\n if (open && !visited) setVisited(true);\n useBrowserLayoutEffect(() => {\n if (expanded === open) return;\n // Establish layout with lazy content mounted before changing the transition target.\n panel.current?.getBoundingClientRect();\n setExpanded(open);\n }, [expanded, open]);\n return (\n <div\n ref={panel}\n id={id}\n role=\"menu\"\n className=\"leaf-menu__submenu\"\n aria-label={label}\n aria-hidden={!open || undefined}\n {...inertProps(!open)}\n data-open={expanded || undefined}\n >\n <div className=\"leaf-menu__submenu-inner\">\n <div className=\"leaf-menu__submenu-content\">{visited && children()}</div>\n </div>\n </div>\n );\n}\nexport function Menu(rawProps: MenuProps) {\n const {\n items,\n selectedKey,\n defaultSelectedKey = '',\n onSelect,\n openKeys,\n defaultOpenKeys = [],\n onOpenChange,\n collapsed = false,\n embedded = false,\n variant = 'neutral',\n itemRender,\n linkRender,\n itemClassName,\n className,\n ...props\n } = useComponentProps('Menu', rawProps);\n const { direction, theme } = useLeafConfig();\n const t = useText();\n const customMenuBackground =\n (props.style as Record<string, unknown> | undefined)?.['--leaf-component-menu-background'] ??\n props.style?.background ??\n props.style?.backgroundColor ??\n theme?.components?.Menu?.background;\n const hasCustomBackground =\n typeof customMenuBackground === 'string' && customMenuBackground.trim().length > 0;\n const explicitTransparentBg =\n typeof customMenuBackground === 'string' && customMenuBackground.trim() === 'transparent';\n const collapsedPopupStyle = explicitTransparentBg\n ? ({ '--leaf-component-menu-background': 'var(--leaf-color-surface-raised)' } as CSSProperties)\n : undefined;\n const id = useId();\n const root = useRef<HTMLElement>(null);\n const [selected, setSelected] = useControllable(selectedKey, defaultSelectedKey);\n const [active, setActive] = useState<string | undefined>(undefined);\n const [opened, setOpened] = useControllable<readonly string[]>(\n openKeys,\n defaultOpenKeys,\n (keys) => onOpenChange?.([...keys]),\n );\n const [collapsedPopupKey, setCollapsedPopupKey] = useState<string | null>(null);\n useEffect(() => {\n if (!collapsed) setCollapsedPopupKey(null);\n }, [collapsed]);\n const toggle = (key: string) =>\n setOpened(opened.includes(key) ? opened.filter((value) => value !== key) : [...opened, key]);\n const visibleItems: MenuItem[] = [];\n const itemByKey = new Map<string, MenuItem>();\n const collect = (entries: readonly MenuItem[], insideVisible = true) => {\n for (const item of entries) {\n itemByKey.set(item.key, item);\n if (item.type === 'group') collect(item.children ?? [], insideVisible);\n else if (item.type !== 'divider') {\n if (insideVisible && !item.disabled) visibleItems.push(item);\n collect(item.children ?? [], insideVisible && opened.includes(item.key) && !collapsed);\n }\n }\n };\n collect(items);\n const focusKey = visibleItems.some((item) => item.key === active)\n ? active\n : (visibleItems.find((item) => item.key === selected)?.key ?? visibleItems[0]?.key);\n const getOriginal = (entry: DropdownItem): MenuItem =>\n itemByKey.get(entry.key) ?? (entry as MenuItem);\n const parentOf = (\n entries: readonly MenuItem[],\n targetKey: string,\n parentItem?: MenuItem,\n ): MenuItem | undefined => {\n for (const entry of entries) {\n if (entry.key === targetKey) return parentItem;\n const parent = parentOf(\n entry.children ?? [],\n targetKey,\n entry.type === 'group' ? parentItem : entry,\n );\n if (parent) return parent;\n }\n return undefined;\n };\n const convert = (entries: readonly MenuItem[]): DropdownItem[] =>\n entries.map((item) => ({\n ...item,\n children: item.children ? convert(item.children) : undefined,\n onClick: () => {\n if (!item.children?.length) {\n setSelected(item.key);\n onSelect?.(item.key, item);\n }\n },\n }));\n const renderItems = (entries: readonly MenuItem[], depth: number): ReactNode =>\n entries.map((item) => {\n if (item.type === 'divider') return <hr className=\"leaf-menu__divider\" key={item.key} />;\n if (item.type === 'group')\n return (\n <MenuGroupControl key={item.key} title={item.label}>\n {renderItems(item.children ?? [], depth)}\n </MenuGroupControl>\n );\n const hasChildren = Boolean(item.children?.length);\n const expanded =\n collapsed && hasChildren ? collapsedPopupKey === item.key : opened.includes(item.key);\n const originalContent = (\n <>\n {item.icon && (\n <span className=\"leaf-menu__icon\" aria-hidden=\"true\">\n {item.icon}\n </span>\n )}\n {!item.icon && collapsed && (\n <span className=\"leaf-menu__icon\" aria-hidden=\"true\">\n {typeof item.label === 'string' ? item.label.slice(0, 1) : '·'}\n </span>\n )}\n <span className=\"leaf-menu__label\">{item.label}</span>\n {!collapsed && item.extra != null && (\n <>\n {' '}\n <span className=\"leaf-menu__extra\">{item.extra}</span>\n </>\n )}\n {hasChildren && <ChevronDown className=\"leaf-menu__arrow\" size={14} aria-hidden=\"true\" />}\n </>\n );\n const content = itemRender?.(item, originalContent) ?? originalContent;\n const common = {\n role: 'menuitem',\n 'aria-current': !hasChildren && selected === item.key ? ('page' as const) : undefined,\n 'aria-disabled': item.disabled || undefined,\n 'aria-expanded': hasChildren ? expanded : undefined,\n 'aria-controls': hasChildren ? `${id}-${item.key}` : undefined,\n 'data-selected': (!hasChildren && selected === item.key) || undefined,\n 'data-selectable': !hasChildren || undefined,\n 'data-danger': item.danger || undefined,\n className: classes(\n 'leaf-menu__item',\n typeof itemClassName === 'function' ? itemClassName(item) : itemClassName,\n ),\n tabIndex: !item.disabled && focusKey === item.key ? 0 : -1,\n 'data-menu-key': item.key,\n 'aria-label': collapsed && typeof item.label === 'string' ? item.label : undefined,\n onFocus: () => setActive(item.key),\n style: {\n '--leaf-menu-depth': depth,\n } as CSSProperties,\n };\n const activate = () => {\n if (item.disabled) return;\n if (hasChildren) toggle(item.key);\n else {\n setSelected(item.key);\n onSelect?.(item.key, item);\n }\n };\n if (hasChildren && collapsed)\n return (\n <div key={item.key} className=\"leaf-menu__entry\">\n <Dropdown\n items={convert(item.children ?? [])}\n navigation={{\n selectedKey: selected,\n title: collapsed ? item.label : undefined,\n variant,\n renderLink: linkRender\n ? (entry, link) => linkRender(getOriginal(entry), link)\n : undefined,\n renderItem: itemRender\n ? (entry, node) => itemRender(getOriginal(entry), node)\n : undefined,\n getItemClassName: itemClassName\n ? (entry) =>\n typeof itemClassName === 'function'\n ? itemClassName(getOriginal(entry))\n : itemClassName\n : undefined,\n }}\n popupWidth={208}\n popupStyle={collapsedPopupStyle}\n popupPlacement={direction === 'rtl' ? 'left-start' : 'right-start'}\n open={expanded}\n disabled={item.disabled}\n onOpenChange={(next) => setCollapsedPopupKey(next ? item.key : null)}\n >\n <button\n {...common}\n type=\"button\"\n onKeyDown={(event) => {\n if (\n collapsed &&\n event.key === (direction === 'rtl' ? 'ArrowLeft' : 'ArrowRight')\n ) {\n event.preventDefault();\n if (!item.disabled) setCollapsedPopupKey(item.key);\n }\n }}\n >\n {content}\n </button>\n </Dropdown>\n </div>\n );\n const triggerNode =\n item.href && !hasChildren ? (\n ((link: ReactNode) => linkRender?.(item, link) ?? link)(\n <a\n {...common}\n href={item.disabled ? undefined : item.href}\n onClick={(event) => {\n if (item.disabled) event.preventDefault();\n else activate();\n }}\n >\n {content}\n </a>,\n )\n ) : (\n <button {...common} type=\"button\" disabled={item.disabled} onClick={activate}>\n {content}\n </button>\n );\n return (\n <div key={item.key} className=\"leaf-menu__entry\">\n {collapsed &&\n !hasChildren &&\n isValidElement<\n HTMLAttributes<HTMLElement> & { ref?: Ref<HTMLElement>; disabled?: boolean }\n >(triggerNode) ? (\n <TooltipControl\n content={item.label}\n placement={direction === 'rtl' ? 'left' : 'right'}\n disabled={item.disabled || item.label == null || item.label === ''}\n >\n {triggerNode}\n </TooltipControl>\n ) : (\n triggerNode\n )}\n {hasChildren && (\n <MenuSubmenu\n id={`${id}-${item.key}`}\n open={expanded}\n label={typeof item.label === 'string' ? item.label : undefined}\n >\n {() => renderItems(item.children ?? [], depth + 1)}\n </MenuSubmenu>\n )}\n </div>\n );\n });\n return (\n <nav\n {...props}\n ref={root}\n className={classes(\n 'leaf-menu',\n `leaf-menu--${variant}`,\n collapsed && 'leaf-menu--collapsed',\n embedded && 'leaf-menu--embedded',\n className,\n )}\n data-custom-background={hasCustomBackground || undefined}\n aria-label={props['aria-label'] ?? t('menu.navigationMenu')}\n >\n <div\n role=\"menu\"\n onKeyDown={(event) => {\n if (event.defaultPrevented) return;\n if (\n !['ArrowDown', 'ArrowUp', 'ArrowRight', 'ArrowLeft', 'Home', 'End', 'Escape'].includes(\n event.key,\n )\n )\n return;\n const target = event.target as HTMLElement;\n const choices = [\n ...(root.current?.querySelectorAll<HTMLElement>(\n '[role=\"menuitem\"]:not([aria-disabled=\"true\"])',\n ) ?? []),\n ].filter((node) => visibleItems.some((item) => item.key === node.dataset.menuKey));\n const position = choices.indexOf(target.closest('[role=\"menuitem\"]') as HTMLElement);\n const key = choices[position]?.dataset.menuKey;\n const item = visibleItems.find((entry) => entry.key === key);\n const focusItem = (nextKey: string) => {\n setActive(nextKey);\n queueMicrotask(() => {\n const node = [\n ...(root.current?.querySelectorAll<HTMLElement>('[data-menu-key]') ?? []),\n ].find((entry) => entry.dataset.menuKey === nextKey);\n node?.focus();\n });\n };\n if (event.key === 'Escape') {\n if (!collapsed && item) {\n const parent = parentOf(items, item.key);\n if (parent && opened.includes(parent.key)) {\n event.preventDefault();\n setOpened(opened.filter((value) => value !== parent.key));\n focusItem(parent.key);\n } else if (opened.includes(item.key)) {\n event.preventDefault();\n setOpened(opened.filter((value) => value !== item.key));\n }\n }\n return;\n }\n if (!collapsed && item) {\n if (event.key === (direction === 'rtl' ? 'ArrowLeft' : 'ArrowRight')) {\n event.preventDefault();\n if (item.children?.length) {\n if (!opened.includes(item.key)) setOpened([...opened, item.key]);\n else {\n const firstEnabled = (entries: readonly MenuItem[]): MenuItem | undefined => {\n for (const entry of entries) {\n if (entry.type === 'group') {\n const child = firstEnabled(entry.children ?? []);\n if (child) return child;\n } else if (!entry.disabled && entry.type !== 'divider') return entry;\n }\n return undefined;\n };\n const child = firstEnabled(item.children);\n if (child) focusItem(child.key);\n }\n }\n return;\n }\n if (event.key === (direction === 'rtl' ? 'ArrowRight' : 'ArrowLeft')) {\n event.preventDefault();\n if (opened.includes(item.key)) toggle(item.key);\n else {\n const parent = parentOf(items, item.key);\n if (parent) focusItem(parent.key);\n }\n return;\n }\n }\n const next =\n event.key === 'Home'\n ? 0\n : event.key === 'End'\n ? choices.length - 1\n : (position +\n (event.key === 'ArrowUp' ||\n event.key === (direction === 'rtl' ? 'ArrowRight' : 'ArrowLeft')\n ? -1\n : 1) +\n choices.length) %\n choices.length;\n event.preventDefault();\n const nextKey = choices[next]?.dataset.menuKey;\n if (nextKey) setActive(nextKey);\n choices[next]?.focus();\n }}\n >\n {renderItems(items, 0)}\n </div>\n </nav>\n );\n}\n"],"names":["ChevronDown","forwardRef","isValidElement","useEffect","useId","useLayoutEffect","useRef","useState","useComponentProps","useLeafConfig","DropdownControl","Dropdown","classes","inertProps","useControllable","useText","TooltipControl","useBrowserLayoutEffect","window","MenuGroupControl","title","children","className","props","ref","titleId","undefined","MenuGroup","rawProps","MenuSubmenu","open","id","label","panel","expanded","setExpanded","visited","setVisited","Menu","items","selectedKey","defaultSelectedKey","onSelect","openKeys","defaultOpenKeys","onOpenChange","collapsed","embedded","variant","itemRender","linkRender","itemClassName","direction","theme","t","customMenuBackground","hasCustomBackground","explicitTransparentBg","collapsedPopupStyle","root","selected","setSelected","active","setActive","opened","setOpened","keys","collapsedPopupKey","setCollapsedPopupKey","toggle","key","value","visibleItems","itemByKey","Map","collect","entries","insideVisible","item","focusKey","getOriginal","entry","parentOf","targetKey","parentItem","parent","convert","renderItems","depth","hasChildren","Boolean","originalContent","content","common","activate","link","node","next","event","triggerNode","target","choices","position","focusItem","nextKey","queueMicrotask","firstEnabled","child"],"mappings":";;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA,0CAA0C,qCAAqC;AAC/E;AACA;AACA;AACA;AACA;AACA;;;;ACVA;;;;ACAA;AACA;AACA;AACA,uDAAuD,iBAAiB;AACxE;AACA,gDAAgD,aAAa;AAC7D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACN2C;AAa5B;AAC2D;AACf;AAEQ;AACvB;AACC;AACgB;AAChB;AACO;AAEpD,MAAMiB,yBAAyB,OAAOC,WAAW,cAA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G,KAAM9C,CAAAA,cAAc,QAAQ,eAAe,WAAU,GAAI;wBACpE8C,MAAM,cAAc;wBACpB,IAAIlC,OAAO,QAAQ,CAACc,KAAK,GAAG,GAAGT,OAAOS,KAAK,GAAG;6BACzC;4BACH,MAAMO,SAASH,SAAS3C,OAAOuC,KAAK,GAAG;4BACvC,IAAIO,QAAQkB,UAAUlB,OAAO,GAAG;wBAClC;wBACA;oBACF;gBACF;gBACA,MAAMY,OACJC,MAAM,GAAG,KAAK,SACV,IACAA,MAAM,GAAG,KAAK,QACZG,QAAQ,MAAM,GAAG,IAChBC,CAAAA,WACEJ,CAAAA,MAAM,GAAG,KAAK,aACfA,MAAM,GAAG,KAAM9C,CAAAA,cAAc,QAAQ,eAAe,WAAU,IAC1D,CAAC,IACD,KACJiD,QAAQ,MAAK,IACfA,QAAQ,MAAM;gBACtBH,MAAM,cAAc;gBACpB,MAAMM,UAAUH,OAAO,CAACJ,KAAK,EAAE,QAAQ;gBACvC,IAAIO,SAASzC,UAAUyC;gBACvBH,OAAO,CAACJ,KAAK,EAAE;YACjB;sBAECV,YAAYhD,OAAO;;;AAI5B"}
|
|
@@ -108,7 +108,7 @@ const scoped_portal_cjs_namespaceObject = require("../shared/scoped-portal.cjs")
|
|
|
108
108
|
})
|
|
109
109
|
});
|
|
110
110
|
}
|
|
111
|
-
function ModalSurface({ open, title, description, tabs, icon, size = 'md', danger = false,
|
|
111
|
+
function ModalSurface({ open, title, description, tabs, icon, size = 'md', danger = false, padding, footer, confirmText, cancelText, confirmLoading = false, confirmButtonProps, cancelButtonProps, onConfirm, onCancel, width, closable = true, maskClosable = true, keyboard = true, onClose, afterClose, forceRender = false, destroyOnClose = false, preserve, initialFocus, returnFocus, container: _container, closeOnConfirm = false, onConfirmError, themeKey = 'Modal', renderTabsLayout: RenderTabsLayout, children, className, style, ...props }) {
|
|
112
112
|
const { messages, maskBlur, theme } = (0,context_cjs_namespaceObject.useLeafConfig)();
|
|
113
113
|
const [pending, setPending] = (0,external_react_namespaceObject.useState)(false);
|
|
114
114
|
const mounted = (0,external_react_namespaceObject.useRef)(true);
|
|
@@ -219,11 +219,12 @@ function ModalSurface({ open, title, description, tabs, icon, size = 'md', dange
|
|
|
219
219
|
const paddingStyle = (0,padding_cjs_namespaceObject.resolvePaddingVars)('modal', padding);
|
|
220
220
|
const paddingFlags = (0,padding_cjs_namespaceObject.resolveDialogPaddingFlags)(padding);
|
|
221
221
|
const modalTheme = theme.components?.Modal;
|
|
222
|
+
const confirmTheme = themeKey === 'Confirm' ? theme.components?.Confirm : undefined;
|
|
222
223
|
const surfaceFlags = {
|
|
223
|
-
...modalTheme?.headerBackground !== undefined ? {
|
|
224
|
+
...(confirmTheme?.headerBackground ?? modalTheme?.headerBackground) !== undefined ? {
|
|
224
225
|
'data-header-surface': ''
|
|
225
226
|
} : {},
|
|
226
|
-
...modalTheme?.footerBackground !== undefined ? {
|
|
227
|
+
...(confirmTheme?.footerBackground ?? modalTheme?.footerBackground) !== undefined ? {
|
|
227
228
|
'data-footer-surface': ''
|
|
228
229
|
} : {}
|
|
229
230
|
};
|
|
@@ -271,7 +272,7 @@ function ModalSurface({ open, title, description, tabs, icon, size = 'md', dange
|
|
|
271
272
|
hasDescription && descriptionId
|
|
272
273
|
].filter(Boolean).join(' ') || undefined,
|
|
273
274
|
tabIndex: -1,
|
|
274
|
-
className: (0,classes_cjs_namespaceObject.classes)('leaf-modal', size === 'mini' && 'leaf-modal--mini', danger && 'leaf-modal--danger',
|
|
275
|
+
className: (0,classes_cjs_namespaceObject.classes)('leaf-modal', size === 'mini' && 'leaf-modal--mini', danger && 'leaf-modal--danger', hasHeading && 'leaf-modal--headed', hasTabs && 'leaf-modal--tabbed', closable && 'leaf-modal--closable', className),
|
|
275
276
|
"data-tabs-size": tabsSize,
|
|
276
277
|
...paddingFlags,
|
|
277
278
|
...surfaceFlags,
|