@nova-design-system/nova-webcomponents 3.23.0 → 3.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/app-globals-V2Kpy_OQ.js.map +1 -1
- package/dist/cjs/events.utils-BE6R5q9C.js +33 -0
- package/dist/cjs/events.utils-BE6R5q9C.js.map +1 -0
- package/dist/cjs/{grow.animation-BrWzyoUA.js → grow.animation-ynu_HmA_.js} +2 -30
- package/dist/cjs/grow.animation-ynu_HmA_.js.map +1 -0
- package/dist/cjs/{i18n.utils-BizoXo6c.js → i18n.utils-ku0bScip.js} +16 -20
- package/dist/cjs/{i18n.utils-BizoXo6c.js.map → i18n.utils-ku0bScip.js.map} +1 -1
- package/dist/cjs/index-B1na8x6M.js +12 -4
- package/dist/cjs/index.cjs.js +5 -2
- package/dist/cjs/index.cjs.js.map +1 -1
- package/dist/cjs/index.esm-CG1TVKfu.js +540 -0
- package/dist/cjs/index.esm-CG1TVKfu.js.map +1 -0
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/native.cjs.js +1 -1
- package/dist/cjs/nv-accordion.cjs.entry.js +2 -7
- package/dist/cjs/nv-accordion.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-alert.cjs.entry.js +1 -2
- package/dist/cjs/nv-alert.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-badge_2.cjs.entry.js +1 -1
- package/dist/cjs/nv-button.cjs.entry.js +3 -5
- package/dist/cjs/nv-button.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-calendar.cjs.entry.js +14 -24
- package/dist/cjs/nv-calendar.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-datagrid.cjs.entry.js +67 -72
- package/dist/cjs/nv-datagrid.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-dialog.cjs.entry.js +6 -538
- package/dist/cjs/nv-dialog.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-drawer.cjs.entry.js +443 -0
- package/dist/cjs/nv-drawer.entry.cjs.js.map +1 -0
- package/dist/cjs/nv-drawerfooter.nv-drawerheader.entry.cjs.js.map +1 -0
- package/dist/cjs/nv-drawerfooter_2.cjs.entry.js +144 -0
- package/dist/cjs/nv-fieldcheckbox.cjs.entry.js +6 -6
- package/dist/cjs/nv-fieldcheckbox.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-fielddate.cjs.entry.js +12 -15
- package/dist/cjs/nv-fielddate.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-fielddaterange.cjs.entry.js +12 -13
- package/dist/cjs/nv-fielddaterange.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-fielddropdown.cjs.entry.js +24 -33
- package/dist/cjs/nv-fielddropdown.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-fielddropdownitem.cjs.entry.js +2 -3
- package/dist/cjs/nv-fielddropdownitem.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-fieldmultiselect.cjs.entry.js +19 -27
- package/dist/cjs/nv-fieldmultiselect.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-fieldnumber.cjs.entry.js +6 -6
- package/dist/cjs/nv-fieldnumber.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-fieldpassword.cjs.entry.js +6 -6
- package/dist/cjs/nv-fieldpassword.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-fieldradio.cjs.entry.js +4 -4
- package/dist/cjs/nv-fieldradio.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-fieldselect.cjs.entry.js +8 -8
- package/dist/cjs/nv-fieldselect.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-fieldslider.cjs.entry.js +5 -5
- package/dist/cjs/nv-fieldslider.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-fieldtext.cjs.entry.js +6 -6
- package/dist/cjs/nv-fieldtext.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-fieldtextarea.cjs.entry.js +6 -7
- package/dist/cjs/nv-fieldtextarea.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-fieldtime.cjs.entry.js +27 -35
- package/dist/cjs/nv-fieldtime.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-icon.cjs.entry.js +2 -2
- package/dist/cjs/nv-icon.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-iconbutton.nv-loader.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-iconbutton_2.cjs.entry.js +5 -6
- package/dist/cjs/nv-menu.cjs.entry.js +3 -4
- package/dist/cjs/nv-menu.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-menuitem.cjs.entry.js +1 -1
- package/dist/cjs/nv-notification-bullet.cjs.entry.js +1 -2
- package/dist/cjs/nv-notification-bullet.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-notification.cjs.entry.js +6 -9
- package/dist/cjs/nv-notification.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-notificationcontainer.cjs.entry.js +1 -1
- package/dist/cjs/nv-popover.cjs.entry.js +12 -12
- package/dist/cjs/nv-popover.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-row.cjs.entry.js +1 -1
- package/dist/cjs/nv-sidebar.cjs.entry.js +3 -3
- package/dist/cjs/nv-sidebar.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-sidebarcontent.cjs.entry.js +1 -1
- package/dist/cjs/nv-sidebardivider.cjs.entry.js +1 -1
- package/dist/cjs/nv-sidebarfooter.cjs.entry.js +1 -1
- package/dist/cjs/nv-sidebargroup.cjs.entry.js +1 -1
- package/dist/cjs/nv-sidebarheader.cjs.entry.js +1 -1
- package/dist/cjs/nv-sidebarlogo.cjs.entry.js +1 -1
- package/dist/cjs/nv-sidebarnavitem.cjs.entry.js +4 -5
- package/dist/cjs/nv-sidebarnavitem.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-sidebarnavsubitem.cjs.entry.js +1 -1
- package/dist/cjs/nv-split.cjs.entry.js +43 -41
- package/dist/cjs/nv-split.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-stack.cjs.entry.js +1 -1
- package/dist/cjs/nv-table.cjs.entry.js +6 -8
- package/dist/cjs/nv-table.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-tableheader.cjs.entry.js +2 -2
- package/dist/cjs/nv-tableheader.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-toggle.cjs.entry.js +2 -2
- package/dist/cjs/nv-togglebutton.cjs.entry.js +2 -2
- package/dist/cjs/nv-togglebutton.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-togglebuttongroup.cjs.entry.js +3 -4
- package/dist/cjs/nv-togglebuttongroup.entry.cjs.js.map +1 -1
- package/dist/cjs/nv-tooltip.cjs.entry.js +1 -1
- package/dist/collection/collection-manifest.json +3 -0
- package/dist/collection/components/nv-accordion/nv-accordion.docs.js +66 -40
- package/dist/collection/components/nv-accordion/nv-accordion.docs.js.map +1 -1
- package/dist/collection/components/nv-accordion/nv-accordion.js +2 -7
- package/dist/collection/components/nv-accordion/nv-accordion.js.map +1 -1
- package/dist/collection/components/nv-alert/nv-alert.docs.js +18 -1
- package/dist/collection/components/nv-alert/nv-alert.docs.js.map +1 -1
- package/dist/collection/components/nv-alert/nv-alert.js +1 -2
- package/dist/collection/components/nv-alert/nv-alert.js.map +1 -1
- package/dist/collection/components/nv-avatar/nv-avatar.docs.js +56 -0
- package/dist/collection/components/nv-avatar/nv-avatar.docs.js.map +1 -1
- package/dist/collection/components/nv-badge/nv-badge.docs.js +64 -15
- package/dist/collection/components/nv-badge/nv-badge.docs.js.map +1 -1
- package/dist/collection/components/nv-breadcrumbs/nv-breadcrumbs.docs.js +10 -1
- package/dist/collection/components/nv-breadcrumbs/nv-breadcrumbs.docs.js.map +1 -1
- package/dist/collection/components/nv-button/nv-button.docs.js +38 -4
- package/dist/collection/components/nv-button/nv-button.docs.js.map +1 -1
- package/dist/collection/components/nv-button/nv-button.js +3 -5
- package/dist/collection/components/nv-button/nv-button.js.map +1 -1
- package/dist/collection/components/nv-buttongroup/nv-buttongroup.docs.js +22 -0
- package/dist/collection/components/nv-buttongroup/nv-buttongroup.docs.js.map +1 -1
- package/dist/collection/components/nv-calendar/nv-calendar.docs.js +269 -14
- package/dist/collection/components/nv-calendar/nv-calendar.docs.js.map +1 -1
- package/dist/collection/components/nv-calendar/nv-calendar.js +13 -22
- package/dist/collection/components/nv-calendar/nv-calendar.js.map +1 -1
- package/dist/collection/components/nv-calendar/partials/week-numbers.js +1 -2
- package/dist/collection/components/nv-calendar/partials/week-numbers.js.map +1 -1
- package/dist/collection/components/nv-calendar/test/nv-calendar.utils.test.js +11 -11
- package/dist/collection/components/nv-calendar/test/nv-calendar.utils.test.js.map +1 -1
- package/dist/collection/components/nv-calendar/test/partials/calendar-grid.logic.test.js +2 -2
- package/dist/collection/components/nv-calendar/test/partials/calendar-grid.logic.test.js.map +1 -1
- package/dist/collection/components/nv-calendar/test/partials/calendar-shortcuts.logic.test.js +6 -5
- package/dist/collection/components/nv-calendar/test/partials/calendar-shortcuts.logic.test.js.map +1 -1
- package/dist/collection/components/nv-calendar/test/partials/day-cell.logic.test.js +10 -1
- package/dist/collection/components/nv-calendar/test/partials/day-cell.logic.test.js.map +1 -1
- package/dist/collection/components/nv-col/nv-col.docs.js +8 -0
- package/dist/collection/components/nv-col/nv-col.docs.js.map +1 -1
- package/dist/collection/components/nv-datagrid/nv-datagrid.docs.js +290 -286
- package/dist/collection/components/nv-datagrid/nv-datagrid.docs.js.map +1 -1
- package/dist/collection/components/nv-datagrid/nv-datagrid.js +67 -72
- package/dist/collection/components/nv-datagrid/nv-datagrid.js.map +1 -1
- package/dist/collection/components/nv-dialog/nv-dialog.docs.js +64 -13
- package/dist/collection/components/nv-dialog/nv-dialog.docs.js.map +1 -1
- package/dist/collection/components/nv-drawer/nv-drawer.css +114 -0
- package/dist/collection/components/nv-drawer/nv-drawer.docs.js +145 -0
- package/dist/collection/components/nv-drawer/nv-drawer.docs.js.map +1 -0
- package/dist/collection/components/nv-drawer/nv-drawer.js +719 -0
- package/dist/collection/components/nv-drawer/nv-drawer.js.map +1 -0
- package/dist/collection/components/nv-drawerfooter/nv-drawerfooter.css +8 -0
- package/dist/collection/components/nv-drawerfooter/nv-drawerfooter.docs.js +6 -0
- package/dist/collection/components/nv-drawerfooter/nv-drawerfooter.docs.js.map +1 -0
- package/dist/collection/components/nv-drawerfooter/nv-drawerfooter.js +325 -0
- package/dist/collection/components/nv-drawerfooter/nv-drawerfooter.js.map +1 -0
- package/dist/collection/components/nv-drawerheader/nv-drawerheader.css +32 -0
- package/dist/collection/components/nv-drawerheader/nv-drawerheader.docs.js +6 -0
- package/dist/collection/components/nv-drawerheader/nv-drawerheader.docs.js.map +1 -0
- package/dist/collection/components/nv-drawerheader/nv-drawerheader.js +92 -0
- package/dist/collection/components/nv-drawerheader/nv-drawerheader.js.map +1 -0
- package/dist/collection/components/nv-fieldcheckbox/nv-fieldcheckbox.docs.js +186 -136
- package/dist/collection/components/nv-fieldcheckbox/nv-fieldcheckbox.docs.js.map +1 -1
- package/dist/collection/components/nv-fieldcheckbox/nv-fieldcheckbox.js +6 -6
- package/dist/collection/components/nv-fieldcheckbox/nv-fieldcheckbox.js.map +1 -1
- package/dist/collection/components/nv-fielddate/nv-fielddate.docs.js +300 -109
- package/dist/collection/components/nv-fielddate/nv-fielddate.docs.js.map +1 -1
- package/dist/collection/components/nv-fielddate/nv-fielddate.js +11 -14
- package/dist/collection/components/nv-fielddate/nv-fielddate.js.map +1 -1
- package/dist/collection/components/nv-fielddate/styles/nv-fielddate.css +1 -1
- package/dist/collection/components/nv-fielddaterange/nv-fielddaterange.docs.js +406 -1
- package/dist/collection/components/nv-fielddaterange/nv-fielddaterange.docs.js.map +1 -1
- package/dist/collection/components/nv-fielddaterange/nv-fielddaterange.js +11 -12
- package/dist/collection/components/nv-fielddaterange/nv-fielddaterange.js.map +1 -1
- package/dist/collection/components/nv-fielddaterange/styles/nv-fielddaterange.css +1 -1
- package/dist/collection/components/nv-fielddropdown/nv-fielddropdown.docs.js +210 -118
- package/dist/collection/components/nv-fielddropdown/nv-fielddropdown.docs.js.map +1 -1
- package/dist/collection/components/nv-fielddropdown/nv-fielddropdown.js +22 -31
- package/dist/collection/components/nv-fielddropdown/nv-fielddropdown.js.map +1 -1
- package/dist/collection/components/nv-fielddropdown/styles/nv-fielddropdown.css +1 -1
- package/dist/collection/components/nv-fielddropdownitem/nv-fielddropdownitem.js +2 -3
- package/dist/collection/components/nv-fielddropdownitem/nv-fielddropdownitem.js.map +1 -1
- package/dist/collection/components/nv-fielddropdownitemcheck/nv-fielddropdownitemcheck.js +1 -1
- package/dist/collection/components/nv-fieldmultiselect/nv-fieldmultiselect.docs.js +462 -322
- package/dist/collection/components/nv-fieldmultiselect/nv-fieldmultiselect.docs.js.map +1 -1
- package/dist/collection/components/nv-fieldmultiselect/nv-fieldmultiselect.js +17 -25
- package/dist/collection/components/nv-fieldmultiselect/nv-fieldmultiselect.js.map +1 -1
- package/dist/collection/components/nv-fieldmultiselect/styles/nv-fieldmultiselect.css +1 -1
- package/dist/collection/components/nv-fieldnumber/nv-fieldnumber.css +1 -1
- package/dist/collection/components/nv-fieldnumber/nv-fieldnumber.docs.js +70 -7
- package/dist/collection/components/nv-fieldnumber/nv-fieldnumber.docs.js.map +1 -1
- package/dist/collection/components/nv-fieldnumber/nv-fieldnumber.js +5 -5
- package/dist/collection/components/nv-fieldnumber/nv-fieldnumber.js.map +1 -1
- package/dist/collection/components/nv-fieldpassword/nv-fieldpassword.css +1 -1
- package/dist/collection/components/nv-fieldpassword/nv-fieldpassword.docs.js +79 -6
- package/dist/collection/components/nv-fieldpassword/nv-fieldpassword.docs.js.map +1 -1
- package/dist/collection/components/nv-fieldpassword/nv-fieldpassword.js +5 -5
- package/dist/collection/components/nv-fieldpassword/nv-fieldpassword.js.map +1 -1
- package/dist/collection/components/nv-fieldradio/nv-fieldradio.docs.js +58 -6
- package/dist/collection/components/nv-fieldradio/nv-fieldradio.docs.js.map +1 -1
- package/dist/collection/components/nv-fieldradio/nv-fieldradio.js +4 -4
- package/dist/collection/components/nv-fieldradio/nv-fieldradio.js.map +1 -1
- package/dist/collection/components/nv-fieldselect/nv-fieldselect.docs.js +138 -30
- package/dist/collection/components/nv-fieldselect/nv-fieldselect.docs.js.map +1 -1
- package/dist/collection/components/nv-fieldselect/nv-fieldselect.js +7 -7
- package/dist/collection/components/nv-fieldselect/nv-fieldselect.js.map +1 -1
- package/dist/collection/components/nv-fieldselect/styles/nv-fieldselect.css +1 -1
- package/dist/collection/components/nv-fieldslider/nv-fieldslider.docs.js +138 -30
- package/dist/collection/components/nv-fieldslider/nv-fieldslider.docs.js.map +1 -1
- package/dist/collection/components/nv-fieldslider/nv-fieldslider.js +3 -3
- package/dist/collection/components/nv-fieldslider/partials/field-input.js +1 -1
- package/dist/collection/components/nv-fieldslider/partials/field-input.js.map +1 -1
- package/dist/collection/components/nv-fieldslider/styles/nv-fieldslider.css +1 -1
- package/dist/collection/components/nv-fieldtext/nv-fieldtext.css +1 -1
- package/dist/collection/components/nv-fieldtext/nv-fieldtext.docs.js +92 -16
- package/dist/collection/components/nv-fieldtext/nv-fieldtext.docs.js.map +1 -1
- package/dist/collection/components/nv-fieldtext/nv-fieldtext.js +5 -5
- package/dist/collection/components/nv-fieldtext/nv-fieldtext.js.map +1 -1
- package/dist/collection/components/nv-fieldtextarea/nv-fieldtextarea.docs.js +64 -3
- package/dist/collection/components/nv-fieldtextarea/nv-fieldtextarea.docs.js.map +1 -1
- package/dist/collection/components/nv-fieldtextarea/nv-fieldtextarea.js +6 -7
- package/dist/collection/components/nv-fieldtextarea/nv-fieldtextarea.js.map +1 -1
- package/dist/collection/components/nv-fieldtime/nv-fieldtime.docs.js +41 -22
- package/dist/collection/components/nv-fieldtime/nv-fieldtime.docs.js.map +1 -1
- package/dist/collection/components/nv-fieldtime/nv-fieldtime.js +25 -33
- package/dist/collection/components/nv-fieldtime/nv-fieldtime.js.map +1 -1
- package/dist/collection/components/nv-fieldtime/styles/nv-fieldtime.css +1 -1
- package/dist/collection/components/nv-fieldtime/utils/format-utils.js +1 -1
- package/dist/collection/components/nv-fieldtime/utils/format-utils.js.map +1 -1
- package/dist/collection/components/nv-icon/nv-icon.docs.js +46 -0
- package/dist/collection/components/nv-icon/nv-icon.docs.js.map +1 -1
- package/dist/collection/components/nv-icon/nv-icon.js +1 -1
- package/dist/collection/components/nv-icon/nv-icons.js +2 -0
- package/dist/collection/components/nv-icon/nv-icons.js.map +1 -1
- package/dist/collection/components/nv-iconbutton/nv-iconbutton.css +4 -4
- package/dist/collection/components/nv-iconbutton/nv-iconbutton.docs.js +18 -1
- package/dist/collection/components/nv-iconbutton/nv-iconbutton.docs.js.map +1 -1
- package/dist/collection/components/nv-iconbutton/nv-iconbutton.js +3 -4
- package/dist/collection/components/nv-iconbutton/nv-iconbutton.js.map +1 -1
- package/dist/collection/components/nv-loader/nv-loader.docs.js +8 -4
- package/dist/collection/components/nv-loader/nv-loader.docs.js.map +1 -1
- package/dist/collection/components/nv-loader/nv-loader.js +1 -1
- package/dist/collection/components/nv-menu/nv-menu.docs.js +17 -5
- package/dist/collection/components/nv-menu/nv-menu.docs.js.map +1 -1
- package/dist/collection/components/nv-menu/nv-menu.js +3 -4
- package/dist/collection/components/nv-menu/nv-menu.js.map +1 -1
- package/dist/collection/components/nv-menuitem/nv-menuitem.js +2 -2
- package/dist/collection/components/nv-notification/nv-notification.docs.js +34 -3
- package/dist/collection/components/nv-notification/nv-notification.docs.js.map +1 -1
- package/dist/collection/components/nv-notification/nv-notification.js +6 -9
- package/dist/collection/components/nv-notification/nv-notification.js.map +1 -1
- package/dist/collection/components/nv-notification-bullet/nv-notification-bullet.docs.js +60 -0
- package/dist/collection/components/nv-notification-bullet/nv-notification-bullet.docs.js.map +1 -1
- package/dist/collection/components/nv-notification-bullet/nv-notification-bullet.js +1 -2
- package/dist/collection/components/nv-notification-bullet/nv-notification-bullet.js.map +1 -1
- package/dist/collection/components/nv-notificationcontainer/nv-notificationcontainer.js +1 -1
- package/dist/collection/components/nv-popover/nv-popover.docs.js +35 -10
- package/dist/collection/components/nv-popover/nv-popover.docs.js.map +1 -1
- package/dist/collection/components/nv-popover/nv-popover.js +2 -3
- package/dist/collection/components/nv-popover/nv-popover.js.map +1 -1
- package/dist/collection/components/nv-row/nv-row.docs.js +7 -0
- package/dist/collection/components/nv-row/nv-row.docs.js.map +1 -1
- package/dist/collection/components/nv-row/nv-row.js +1 -1
- package/dist/collection/components/nv-sidebar/nv-sidebar.docs.js +39 -0
- package/dist/collection/components/nv-sidebar/nv-sidebar.docs.js.map +1 -1
- package/dist/collection/components/nv-sidebar/nv-sidebar.js +3 -3
- package/dist/collection/components/nv-sidebar/nv-sidebar.js.map +1 -1
- package/dist/collection/components/nv-sidebarcontent/nv-sidebarcontent.js +1 -1
- package/dist/collection/components/nv-sidebardivider/nv-sidebardivider.js +1 -1
- package/dist/collection/components/nv-sidebarfooter/nv-sidebarfooter.js +1 -1
- package/dist/collection/components/nv-sidebargroup/nv-sidebargroup.js +1 -1
- package/dist/collection/components/nv-sidebarheader/nv-sidebarheader.js +1 -1
- package/dist/collection/components/nv-sidebarlogo/nv-sidebarlogo.js +1 -1
- package/dist/collection/components/nv-sidebarnavitem/nv-sidebarnavitem.js +5 -6
- package/dist/collection/components/nv-sidebarnavitem/nv-sidebarnavitem.js.map +1 -1
- package/dist/collection/components/nv-sidebarnavsubitem/nv-sidebarnavsubitem.js +1 -1
- package/dist/collection/components/nv-split/nv-split.docs.js +38 -2
- package/dist/collection/components/nv-split/nv-split.docs.js.map +1 -1
- package/dist/collection/components/nv-split/nv-split.js +44 -42
- package/dist/collection/components/nv-split/nv-split.js.map +1 -1
- package/dist/collection/components/nv-split/styles/nv-split.css +2 -0
- package/dist/collection/components/nv-stack/nv-stack.docs.js +13 -0
- package/dist/collection/components/nv-stack/nv-stack.docs.js.map +1 -1
- package/dist/collection/components/nv-stack/nv-stack.js +1 -1
- package/dist/collection/components/nv-table/nv-table.docs.js +12 -0
- package/dist/collection/components/nv-table/nv-table.docs.js.map +1 -1
- package/dist/collection/components/nv-table/nv-table.js +1 -1
- package/dist/collection/components/nv-table/nv-table.utils.js +5 -7
- package/dist/collection/components/nv-table/nv-table.utils.js.map +1 -1
- package/dist/collection/components/nv-table/test/nv-table.utils.test.js +4 -5
- package/dist/collection/components/nv-table/test/nv-table.utils.test.js.map +1 -1
- package/dist/collection/components/nv-tableheader/nv-tableheader.docs.js +29 -1
- package/dist/collection/components/nv-tableheader/nv-tableheader.docs.js.map +1 -1
- package/dist/collection/components/nv-tableheader/nv-tableheader.js +2 -2
- package/dist/collection/components/nv-tableheader/nv-tableheader.js.map +1 -1
- package/dist/collection/components/nv-toggle/nv-toggle.docs.js +31 -0
- package/dist/collection/components/nv-toggle/nv-toggle.docs.js.map +1 -1
- package/dist/collection/components/nv-toggle/nv-toggle.js +2 -2
- package/dist/collection/components/nv-togglebutton/nv-togglebutton.js +1 -1
- package/dist/collection/components/nv-togglebutton/styles/nv-togglebutton.css +16 -12
- package/dist/collection/components/nv-togglebuttongroup/nv-togglebuttongroup.docs.js +20 -7
- package/dist/collection/components/nv-togglebuttongroup/nv-togglebuttongroup.docs.js.map +1 -1
- package/dist/collection/components/nv-togglebuttongroup/nv-togglebuttongroup.js +2 -3
- package/dist/collection/components/nv-togglebuttongroup/nv-togglebuttongroup.js.map +1 -1
- package/dist/collection/components/nv-togglebuttongroup/styles/nv-togglebuttongroup.css +4 -12
- package/dist/collection/components/nv-tooltip/nv-tooltip.docs.js +33 -6
- package/dist/collection/components/nv-tooltip/nv-tooltip.docs.js.map +1 -1
- package/dist/collection/components/nv-tooltip/nv-tooltip.js +1 -1
- package/dist/collection/templates/navigation.docs.js +1 -1
- package/dist/collection/templates/navigation.docs.js.map +1 -1
- package/dist/collection/utils/i18n.utils.js +1 -2
- package/dist/collection/utils/i18n.utils.js.map +1 -1
- package/dist/collection/utils/search-engine/strategies/fuzzy.js +2 -2
- package/dist/collection/utils/search-engine/strategies/fuzzy.js.map +1 -1
- package/dist/collection/utils/search-engine/strategies/smart.js +2 -2
- package/dist/collection/utils/search-engine/strategies/smart.js.map +1 -1
- package/dist/collection/utils/search-engine/strategies/strict.js +2 -2
- package/dist/collection/utils/search-engine/strategies/strict.js.map +1 -1
- package/dist/collection/utils/search-engine/worker/worker-client.js +7 -10
- package/dist/collection/utils/search-engine/worker/worker-client.js.map +1 -1
- package/dist/components/index.js +4 -2
- package/dist/components/index.js.map +1 -1
- package/dist/components/nv-accordion-item.js +1 -1
- package/dist/components/nv-accordion.js +6 -11
- package/dist/components/nv-accordion.js.map +1 -1
- package/dist/components/nv-alert.js +2 -3
- package/dist/components/nv-alert.js.map +1 -1
- package/dist/components/nv-avatar.js +1 -1
- package/dist/components/nv-badge.js +1 -1
- package/dist/components/nv-breadcrumb.js +2 -2
- package/dist/components/nv-button.js +1 -1
- package/dist/components/nv-calendar.js +1 -1
- package/dist/components/nv-datagrid.js +69 -74
- package/dist/components/nv-datagrid.js.map +1 -1
- package/dist/components/nv-dialog.js +7 -539
- package/dist/components/nv-dialog.js.map +1 -1
- package/dist/components/nv-dialogfooter.js +1 -1
- package/dist/components/nv-drawer.d.ts +11 -0
- package/dist/components/nv-drawer.js +507 -0
- package/dist/components/nv-drawer.js.map +1 -0
- package/dist/components/nv-drawerfooter.d.ts +11 -0
- package/dist/components/nv-drawerfooter.js +9 -0
- package/dist/components/nv-drawerfooter.js.map +1 -0
- package/dist/components/nv-drawerheader.d.ts +11 -0
- package/dist/components/nv-drawerheader.js +9 -0
- package/dist/components/nv-drawerheader.js.map +1 -0
- package/dist/components/nv-fieldcheckbox.js +1 -1
- package/dist/components/nv-fielddate.js +18 -21
- package/dist/components/nv-fielddate.js.map +1 -1
- package/dist/components/nv-fielddaterange.js +18 -19
- package/dist/components/nv-fielddaterange.js.map +1 -1
- package/dist/components/nv-fielddropdown.js +29 -38
- package/dist/components/nv-fielddropdown.js.map +1 -1
- package/dist/components/nv-fielddropdownitem.js +1 -1
- package/dist/components/nv-fielddropdownitemcheck.js +1 -1
- package/dist/components/nv-fieldmultiselect.js +26 -34
- package/dist/components/nv-fieldmultiselect.js.map +1 -1
- package/dist/components/nv-fieldnumber.js +1 -1
- package/dist/components/nv-fieldpassword.js +9 -9
- package/dist/components/nv-fieldpassword.js.map +1 -1
- package/dist/components/nv-fieldradio.js +4 -4
- package/dist/components/nv-fieldradio.js.map +1 -1
- package/dist/components/nv-fieldselect.js +11 -11
- package/dist/components/nv-fieldselect.js.map +1 -1
- package/dist/components/nv-fieldslider.js +9 -9
- package/dist/components/nv-fieldslider.js.map +1 -1
- package/dist/components/nv-fieldtext.js +1 -1
- package/dist/components/nv-fieldtextarea.js +6 -7
- package/dist/components/nv-fieldtextarea.js.map +1 -1
- package/dist/components/nv-fieldtime.js +31 -39
- package/dist/components/nv-fieldtime.js.map +1 -1
- package/dist/components/nv-icon.js +1 -1
- package/dist/components/nv-iconbutton.js +1 -1
- package/dist/components/nv-loader.js +1 -1
- package/dist/components/nv-menu.js +6 -7
- package/dist/components/nv-menu.js.map +1 -1
- package/dist/components/nv-menuitem.js +1 -1
- package/dist/components/nv-notification-bullet.js +1 -1
- package/dist/components/nv-notification.js +7 -10
- package/dist/components/nv-notification.js.map +1 -1
- package/dist/components/nv-notificationcontainer.js +1 -1
- package/dist/components/nv-popover.js +1 -1
- package/dist/components/nv-row.js +1 -1
- package/dist/components/nv-sidebar.js +4 -4
- package/dist/components/nv-sidebar.js.map +1 -1
- package/dist/components/nv-sidebarcontent.js +1 -1
- package/dist/components/nv-sidebardivider.js +1 -1
- package/dist/components/nv-sidebarfooter.js +1 -1
- package/dist/components/nv-sidebargroup.js +1 -1
- package/dist/components/nv-sidebarheader.js +1 -1
- package/dist/components/nv-sidebarlogo.js +1 -1
- package/dist/components/nv-sidebarnavitem.js +6 -7
- package/dist/components/nv-sidebarnavitem.js.map +1 -1
- package/dist/components/nv-sidebarnavsubitem.js +1 -1
- package/dist/components/nv-split.js +43 -41
- package/dist/components/nv-split.js.map +1 -1
- package/dist/components/nv-stack.js +1 -1
- package/dist/components/nv-table.js +6 -8
- package/dist/components/nv-table.js.map +1 -1
- package/dist/components/nv-tableheader.js +5 -5
- package/dist/components/nv-tableheader.js.map +1 -1
- package/dist/components/nv-toggle.js +2 -2
- package/dist/components/nv-togglebutton.js +2 -2
- package/dist/components/nv-togglebutton.js.map +1 -1
- package/dist/components/nv-togglebuttongroup.js +3 -4
- package/dist/components/nv-togglebuttongroup.js.map +1 -1
- package/dist/components/nv-tooltip.js +1 -1
- package/dist/components/{p-D1i2OAGe.js → p-B45HbBWe.js} +6 -8
- package/dist/components/p-B45HbBWe.js.map +1 -0
- package/dist/components/p-B6GgGra-.js +29 -0
- package/dist/components/p-B6GgGra-.js.map +1 -0
- package/dist/components/{p-Dk8ekxr_.js → p-B7VlEQVW.js} +16 -26
- package/dist/components/p-B7VlEQVW.js.map +1 -0
- package/dist/components/{p-B-3kAnun.js → p-B9i3m6rk.js} +6 -6
- package/dist/components/p-B9i3m6rk.js.map +1 -0
- package/dist/components/{p-BQo7AMPX.js → p-BILd3Ta-.js} +9 -9
- package/dist/components/p-BILd3Ta-.js.map +1 -0
- package/dist/components/{p-Dc_0pr83.js → p-BISctfud.js} +8 -8
- package/dist/components/p-BISctfud.js.map +1 -0
- package/dist/components/{p-CIyQBhTX.js → p-BVOv1zgq.js} +4 -4
- package/dist/components/{p-CIyQBhTX.js.map → p-BVOv1zgq.js.map} +1 -1
- package/dist/components/{p-B6EYOx_n.js → p-Bg_l3jn1.js} +3 -3
- package/dist/components/{p-B6EYOx_n.js.map → p-Bg_l3jn1.js.map} +1 -1
- package/dist/components/{p-CBvZjfqs.js → p-C2QAWGhf.js} +4 -4
- package/dist/components/{p-CBvZjfqs.js.map → p-C2QAWGhf.js.map} +1 -1
- package/dist/components/{p-DzUXTCUy.js → p-COnt5ux_.js} +3 -3
- package/dist/components/{p-DzUXTCUy.js.map → p-COnt5ux_.js.map} +1 -1
- package/dist/components/{p-KUIQrV3D.js → p-Cc7XnqPp.js} +5 -5
- package/dist/components/{p-KUIQrV3D.js.map → p-Cc7XnqPp.js.map} +1 -1
- package/dist/components/{p-CmwaW0q4.js → p-D02w_Ru6.js} +3 -28
- package/dist/components/p-D02w_Ru6.js.map +1 -0
- package/dist/components/p-D3eWMME9.js +538 -0
- package/dist/components/p-D3eWMME9.js.map +1 -0
- package/dist/components/{p--iYGZN4R.js → p-D6APFL6N.js} +11 -11
- package/dist/components/p-D6APFL6N.js.map +1 -0
- package/dist/components/{p-DstpaOhw.js → p-DZJHk4fr.js} +3 -3
- package/dist/components/{p-DstpaOhw.js.map → p-DZJHk4fr.js.map} +1 -1
- package/dist/components/{p-Da9WgE5U.js → p-DiUP3TzF.js} +5 -5
- package/dist/components/{p-Da9WgE5U.js.map → p-DiUP3TzF.js.map} +1 -1
- package/dist/components/{p-DWG6az-u.js → p-DpDooigg.js} +5 -6
- package/dist/components/p-DpDooigg.js.map +1 -0
- package/dist/components/{p-BKfPh2in.js → p-Dr-67WvG.js} +4 -4
- package/dist/components/{p-BKfPh2in.js.map → p-Dr-67WvG.js.map} +1 -1
- package/dist/components/{p-DaiLIZ8f.js → p-DvapDVBj.js} +8 -9
- package/dist/components/p-DvapDVBj.js.map +1 -0
- package/dist/components/{p-DOZbXX2L.js → p-IlwlcG9l.js} +16 -20
- package/dist/components/p-IlwlcG9l.js.map +1 -0
- package/dist/components/p-W6vOfMC9.js +63 -0
- package/dist/components/p-W6vOfMC9.js.map +1 -0
- package/dist/components/{p-CBOuqJTb.js → p-nfYynlVq.js} +4 -4
- package/dist/components/{p-CBOuqJTb.js.map → p-nfYynlVq.js.map} +1 -1
- package/dist/components/{p-CBF8V1L7.js → p-tyaJ-nGV.js} +3 -4
- package/dist/components/p-tyaJ-nGV.js.map +1 -0
- package/dist/components/p-u-maNLLs.js +145 -0
- package/dist/components/p-u-maNLLs.js.map +1 -0
- package/dist/esm/app-globals-DQuL1Twl.js.map +1 -1
- package/dist/esm/events.utils-B6GgGra-.js +29 -0
- package/dist/esm/events.utils-B6GgGra-.js.map +1 -0
- package/dist/esm/{grow.animation-CvHGHBL4.js → grow.animation-D7ep_aVl.js} +3 -28
- package/dist/esm/grow.animation-D7ep_aVl.js.map +1 -0
- package/dist/esm/{i18n.utils-DOZbXX2L.js → i18n.utils-IlwlcG9l.js} +16 -20
- package/dist/esm/{i18n.utils-DOZbXX2L.js.map → i18n.utils-IlwlcG9l.js.map} +1 -1
- package/dist/esm/index-CasQushP.js +12 -4
- package/dist/esm/index.esm-D3eWMME9.js +538 -0
- package/dist/esm/index.esm-D3eWMME9.js.map +1 -0
- package/dist/esm/index.js +4 -2
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/native.js +1 -1
- package/dist/esm/nv-accordion.entry.js +2 -7
- package/dist/esm/nv-accordion.entry.js.map +1 -1
- package/dist/esm/nv-alert.entry.js +1 -2
- package/dist/esm/nv-alert.entry.js.map +1 -1
- package/dist/esm/nv-badge_2.entry.js +1 -1
- package/dist/esm/nv-button.entry.js +3 -5
- package/dist/esm/nv-button.entry.js.map +1 -1
- package/dist/esm/nv-calendar.entry.js +14 -24
- package/dist/esm/nv-calendar.entry.js.map +1 -1
- package/dist/esm/nv-datagrid.entry.js +67 -72
- package/dist/esm/nv-datagrid.entry.js.map +1 -1
- package/dist/esm/nv-dialog.entry.js +3 -535
- package/dist/esm/nv-dialog.entry.js.map +1 -1
- package/dist/esm/nv-drawer.entry.js +441 -0
- package/dist/esm/nv-drawer.entry.js.map +1 -0
- package/dist/esm/nv-drawerfooter.nv-drawerheader.entry.js.map +1 -0
- package/dist/esm/nv-drawerfooter_2.entry.js +141 -0
- package/dist/esm/nv-fieldcheckbox.entry.js +6 -6
- package/dist/esm/nv-fieldcheckbox.entry.js.map +1 -1
- package/dist/esm/nv-fielddate.entry.js +12 -15
- package/dist/esm/nv-fielddate.entry.js.map +1 -1
- package/dist/esm/nv-fielddaterange.entry.js +12 -13
- package/dist/esm/nv-fielddaterange.entry.js.map +1 -1
- package/dist/esm/nv-fielddropdown.entry.js +24 -33
- package/dist/esm/nv-fielddropdown.entry.js.map +1 -1
- package/dist/esm/nv-fielddropdownitem.entry.js +2 -3
- package/dist/esm/nv-fielddropdownitem.entry.js.map +1 -1
- package/dist/esm/nv-fieldmultiselect.entry.js +19 -27
- package/dist/esm/nv-fieldmultiselect.entry.js.map +1 -1
- package/dist/esm/nv-fieldnumber.entry.js +6 -6
- package/dist/esm/nv-fieldnumber.entry.js.map +1 -1
- package/dist/esm/nv-fieldpassword.entry.js +6 -6
- package/dist/esm/nv-fieldpassword.entry.js.map +1 -1
- package/dist/esm/nv-fieldradio.entry.js +4 -4
- package/dist/esm/nv-fieldradio.entry.js.map +1 -1
- package/dist/esm/nv-fieldselect.entry.js +8 -8
- package/dist/esm/nv-fieldselect.entry.js.map +1 -1
- package/dist/esm/nv-fieldslider.entry.js +5 -5
- package/dist/esm/nv-fieldslider.entry.js.map +1 -1
- package/dist/esm/nv-fieldtext.entry.js +6 -6
- package/dist/esm/nv-fieldtext.entry.js.map +1 -1
- package/dist/esm/nv-fieldtextarea.entry.js +6 -7
- package/dist/esm/nv-fieldtextarea.entry.js.map +1 -1
- package/dist/esm/nv-fieldtime.entry.js +27 -35
- package/dist/esm/nv-fieldtime.entry.js.map +1 -1
- package/dist/esm/nv-icon.entry.js +2 -2
- package/dist/esm/nv-icon.entry.js.map +1 -1
- package/dist/esm/nv-iconbutton.nv-loader.entry.js.map +1 -1
- package/dist/esm/nv-iconbutton_2.entry.js +5 -6
- package/dist/esm/nv-menu.entry.js +3 -4
- package/dist/esm/nv-menu.entry.js.map +1 -1
- package/dist/esm/nv-menuitem.entry.js +1 -1
- package/dist/esm/nv-notification-bullet.entry.js +1 -2
- package/dist/esm/nv-notification-bullet.entry.js.map +1 -1
- package/dist/esm/nv-notification.entry.js +6 -9
- package/dist/esm/nv-notification.entry.js.map +1 -1
- package/dist/esm/nv-notificationcontainer.entry.js +1 -1
- package/dist/esm/nv-popover.entry.js +4 -4
- package/dist/esm/nv-popover.entry.js.map +1 -1
- package/dist/esm/nv-row.entry.js +1 -1
- package/dist/esm/nv-sidebar.entry.js +3 -3
- package/dist/esm/nv-sidebar.entry.js.map +1 -1
- package/dist/esm/nv-sidebarcontent.entry.js +1 -1
- package/dist/esm/nv-sidebardivider.entry.js +1 -1
- package/dist/esm/nv-sidebarfooter.entry.js +1 -1
- package/dist/esm/nv-sidebargroup.entry.js +1 -1
- package/dist/esm/nv-sidebarheader.entry.js +1 -1
- package/dist/esm/nv-sidebarlogo.entry.js +1 -1
- package/dist/esm/nv-sidebarnavitem.entry.js +4 -5
- package/dist/esm/nv-sidebarnavitem.entry.js.map +1 -1
- package/dist/esm/nv-sidebarnavsubitem.entry.js +1 -1
- package/dist/esm/nv-split.entry.js +43 -41
- package/dist/esm/nv-split.entry.js.map +1 -1
- package/dist/esm/nv-stack.entry.js +1 -1
- package/dist/esm/nv-table.entry.js +6 -8
- package/dist/esm/nv-table.entry.js.map +1 -1
- package/dist/esm/nv-tableheader.entry.js +2 -2
- package/dist/esm/nv-tableheader.entry.js.map +1 -1
- package/dist/esm/nv-toggle.entry.js +2 -2
- package/dist/esm/nv-togglebutton.entry.js +2 -2
- package/dist/esm/nv-togglebutton.entry.js.map +1 -1
- package/dist/esm/nv-togglebuttongroup.entry.js +3 -4
- package/dist/esm/nv-togglebuttongroup.entry.js.map +1 -1
- package/dist/esm/nv-tooltip.entry.js +1 -1
- package/dist/lib/generators/angular-output.js +9 -7
- package/dist/lib/generators/angular-output.js.map +1 -1
- package/dist/lib/generators/docs-blazor.js +32 -14
- package/dist/lib/generators/docs-blazor.js.map +1 -1
- package/dist/lib/generators/vue-output.js +10 -11
- package/dist/lib/generators/vue-output.js.map +1 -1
- package/dist/lib/utils/componentBinding.js +9 -10
- package/dist/lib/utils/componentBinding.js.map +1 -1
- package/dist/lib/utils/parseToCSharpTypes.js +3 -16
- package/dist/lib/utils/parseToCSharpTypes.js.map +1 -1
- package/dist/lib/utils/spread.js +3 -4
- package/dist/lib/utils/spread.js.map +1 -1
- package/dist/native/index.esm.js +1 -1
- package/dist/native/index.esm.js.map +1 -1
- package/dist/native/native.css +1 -1
- package/dist/native/native.esm.js +1 -1
- package/dist/native/nv-accordion.entry.esm.js.map +1 -1
- package/dist/native/nv-alert.entry.esm.js.map +1 -1
- package/dist/native/nv-button.entry.esm.js.map +1 -1
- package/dist/native/nv-calendar.entry.esm.js.map +1 -1
- package/dist/native/nv-datagrid.entry.esm.js.map +1 -1
- package/dist/native/nv-dialog.entry.esm.js.map +1 -1
- package/dist/native/nv-drawer.entry.esm.js.map +1 -0
- package/dist/native/nv-drawerfooter.nv-drawerheader.entry.esm.js.map +1 -0
- package/dist/native/nv-fieldcheckbox.entry.esm.js.map +1 -1
- package/dist/native/nv-fielddate.entry.esm.js.map +1 -1
- package/dist/native/nv-fielddaterange.entry.esm.js.map +1 -1
- package/dist/native/nv-fielddropdown.entry.esm.js.map +1 -1
- package/dist/native/nv-fielddropdownitem.entry.esm.js.map +1 -1
- package/dist/native/nv-fieldmultiselect.entry.esm.js.map +1 -1
- package/dist/native/nv-fieldnumber.entry.esm.js.map +1 -1
- package/dist/native/nv-fieldpassword.entry.esm.js.map +1 -1
- package/dist/native/nv-fieldradio.entry.esm.js.map +1 -1
- package/dist/native/nv-fieldselect.entry.esm.js.map +1 -1
- package/dist/native/nv-fieldslider.entry.esm.js.map +1 -1
- package/dist/native/nv-fieldtext.entry.esm.js.map +1 -1
- package/dist/native/nv-fieldtextarea.entry.esm.js.map +1 -1
- package/dist/native/nv-fieldtime.entry.esm.js.map +1 -1
- package/dist/native/nv-icon.entry.esm.js.map +1 -1
- package/dist/native/nv-iconbutton.nv-loader.entry.esm.js.map +1 -1
- package/dist/native/nv-menu.entry.esm.js.map +1 -1
- package/dist/native/nv-notification-bullet.entry.esm.js.map +1 -1
- package/dist/native/nv-notification.entry.esm.js.map +1 -1
- package/dist/native/nv-popover.entry.esm.js.map +1 -1
- package/dist/native/nv-sidebar.entry.esm.js.map +1 -1
- package/dist/native/nv-sidebarnavitem.entry.esm.js.map +1 -1
- package/dist/native/nv-split.entry.esm.js.map +1 -1
- package/dist/native/nv-table.entry.esm.js.map +1 -1
- package/dist/native/nv-tableheader.entry.esm.js.map +1 -1
- package/dist/native/nv-togglebutton.entry.esm.js.map +1 -1
- package/dist/native/nv-togglebuttongroup.entry.esm.js.map +1 -1
- package/dist/native/{p-b21e38a3.entry.js → p-04a2fe7f.entry.js} +2 -2
- package/dist/native/p-08204da4.entry.js +2 -0
- package/dist/native/{p-bd6ae5f3.entry.js.map → p-08204da4.entry.js.map} +1 -1
- package/dist/native/{p-e0adb05d.entry.js → p-0e07b91b.entry.js} +2 -2
- package/dist/native/p-0e07b91b.entry.js.map +1 -0
- package/dist/native/p-136dfb3e.entry.js +2 -0
- package/dist/native/p-136dfb3e.entry.js.map +1 -0
- package/dist/native/p-1f2dd37f.entry.js +2 -0
- package/dist/native/p-1f2dd37f.entry.js.map +1 -0
- package/dist/native/p-255a0482.entry.js +2 -0
- package/dist/native/p-255a0482.entry.js.map +1 -0
- package/dist/native/{p-f73e9752.entry.js → p-3305a7e6.entry.js} +2 -2
- package/dist/native/p-3305a7e6.entry.js.map +1 -0
- package/dist/native/p-36b0a6f0.entry.js +2 -0
- package/dist/native/p-36b0a6f0.entry.js.map +1 -0
- package/dist/native/p-434bc910.entry.js +2 -0
- package/dist/native/p-434bc910.entry.js.map +1 -0
- package/dist/native/{p-ea98ba7a.entry.js → p-436029a5.entry.js} +2 -2
- package/dist/native/p-460fdf02.entry.js +2 -0
- package/dist/native/p-460fdf02.entry.js.map +1 -0
- package/dist/native/p-477e02cf.entry.js +2 -0
- package/dist/native/p-477e02cf.entry.js.map +1 -0
- package/dist/native/{p-28afb852.entry.js → p-4efb582b.entry.js} +2 -2
- package/dist/native/p-4efb582b.entry.js.map +1 -0
- package/dist/native/p-4f1dfa32.entry.js +2 -0
- package/dist/native/p-4f1dfa32.entry.js.map +1 -0
- package/dist/native/p-51b7de55.entry.js +13 -0
- package/dist/native/p-51b7de55.entry.js.map +1 -0
- package/dist/native/{p-37c6d559.entry.js → p-5dd120dc.entry.js} +2 -2
- package/dist/native/p-5dd120dc.entry.js.map +1 -0
- package/dist/native/{p-5acf105e.entry.js → p-67181258.entry.js} +2 -2
- package/dist/native/p-6a81884b.entry.js +2 -0
- package/dist/native/p-6a81884b.entry.js.map +1 -0
- package/dist/native/p-6aa483de.entry.js +2 -0
- package/dist/native/{p-b1a917c7.entry.js → p-6fc79712.entry.js} +2 -2
- package/dist/native/{p-ee04ea09.entry.js → p-729589cb.entry.js} +2 -2
- package/dist/native/p-729589cb.entry.js.map +1 -0
- package/dist/native/p-78bf7650.entry.js +2 -0
- package/dist/native/p-7e6e9ea2.entry.js +2 -0
- package/dist/native/p-8f1cd9e2.entry.js +2 -0
- package/dist/native/p-8f1cd9e2.entry.js.map +1 -0
- package/dist/native/{p-4cf47e1a.entry.js → p-910cd685.entry.js} +2 -2
- package/dist/native/p-91eaf02e.entry.js +2 -0
- package/dist/native/p-91eaf02e.entry.js.map +1 -0
- package/dist/native/p-93e35975.entry.js +2 -0
- package/dist/native/p-93e35975.entry.js.map +1 -0
- package/dist/native/{p-9d8257dc.entry.js → p-96c45604.entry.js} +2 -2
- package/dist/native/{p-6f456ae4.entry.js → p-9b6ad782.entry.js} +2 -2
- package/dist/native/{p-6f456ae4.entry.js.map → p-9b6ad782.entry.js.map} +1 -1
- package/dist/native/{p-fd872d54.entry.js → p-9f32c3ea.entry.js} +2 -2
- package/dist/native/p-B6GgGra-.js +2 -0
- package/dist/native/p-B6GgGra-.js.map +1 -0
- package/dist/native/p-Blc6XEY7.js +2 -0
- package/dist/native/p-Blc6XEY7.js.map +1 -0
- package/dist/native/p-D3eWMME9.js +6 -0
- package/dist/native/p-D3eWMME9.js.map +1 -0
- package/dist/native/p-DQuL1Twl.js.map +1 -1
- package/dist/native/p-IlwlcG9l.js +2 -0
- package/dist/native/{p-DOZbXX2L.js.map → p-IlwlcG9l.js.map} +1 -1
- package/dist/native/{p-b0935c49.entry.js → p-a6fea322.entry.js} +2 -2
- package/dist/native/p-ae279ae9.entry.js +2 -0
- package/dist/native/p-ae279ae9.entry.js.map +1 -0
- package/dist/native/p-ba1286aa.entry.js +2 -0
- package/dist/native/p-ba1286aa.entry.js.map +1 -0
- package/dist/native/p-bb52a5a9.entry.js +2 -0
- package/dist/native/p-bb52a5a9.entry.js.map +1 -0
- package/dist/native/p-bc90247e.entry.js +2 -0
- package/dist/native/p-bc90247e.entry.js.map +1 -0
- package/dist/native/{p-0493fb6d.entry.js → p-c2a73a5a.entry.js} +2 -2
- package/dist/native/p-c4c11549.entry.js +2 -0
- package/dist/native/{p-3c54e422.entry.js → p-c5ecdc49.entry.js} +2 -2
- package/dist/native/p-c5ecdc49.entry.js.map +1 -0
- package/dist/native/{p-527e9b56.entry.js → p-cb1b9edb.entry.js} +2 -2
- package/dist/native/p-cb1b9edb.entry.js.map +1 -0
- package/dist/native/p-cdaf54b0.entry.js +2 -0
- package/dist/native/p-cdaf54b0.entry.js.map +1 -0
- package/dist/native/{p-e7dc36d9.entry.js → p-ceb8fe8a.entry.js} +2 -2
- package/dist/native/p-daf7541b.entry.js +2 -0
- package/dist/native/p-daf7541b.entry.js.map +1 -0
- package/dist/native/{p-da893df2.entry.js → p-ded4be77.entry.js} +2 -2
- package/dist/native/p-ded4be77.entry.js.map +1 -0
- package/dist/native/p-e1fc5f8c.entry.js +2 -0
- package/dist/native/p-e1fc5f8c.entry.js.map +1 -0
- package/dist/native/{p-d4f95c86.entry.js → p-e6c69f7d.entry.js} +2 -2
- package/dist/native/p-e6c69f7d.entry.js.map +1 -0
- package/dist/native/p-e83603f1.entry.js +2 -0
- package/dist/native/p-e83603f1.entry.js.map +1 -0
- package/dist/native/p-ec217581.entry.js +2 -0
- package/dist/native/p-ec217581.entry.js.map +1 -0
- package/dist/native/p-ee694832.entry.js +2 -0
- package/dist/native/p-ee694832.entry.js.map +1 -0
- package/dist/native/{p-b1ef2f25.entry.js → p-f7e0146e.entry.js} +2 -2
- package/dist/native/p-f7e0146e.entry.js.map +1 -0
- package/dist/types/components/nv-drawer/nv-drawer.d.ts +161 -0
- package/dist/types/components/nv-drawer/nv-drawer.docs.d.ts +4 -0
- package/dist/types/components/nv-drawerfooter/nv-drawerfooter.d.ts +76 -0
- package/dist/types/components/nv-drawerfooter/nv-drawerfooter.docs.d.ts +4 -0
- package/dist/types/components/nv-drawerheader/nv-drawerheader.d.ts +20 -0
- package/dist/types/components/nv-drawerheader/nv-drawerheader.docs.d.ts +4 -0
- package/dist/types/components/nv-icon/nv-icons.d.ts +1 -1
- package/dist/types/components/nv-split/nv-split.d.ts +4 -4
- package/dist/types/components.d.ts +292 -5
- package/dist/vscode-data.json +153 -1
- package/hydrate/index.js +969 -408
- package/hydrate/index.mjs +969 -408
- package/package.json +13 -1
- package/dist/cjs/grow.animation-BrWzyoUA.js.map +0 -1
- package/dist/components/p--iYGZN4R.js.map +0 -1
- package/dist/components/p-B-3kAnun.js.map +0 -1
- package/dist/components/p-BQo7AMPX.js.map +0 -1
- package/dist/components/p-CBF8V1L7.js.map +0 -1
- package/dist/components/p-CmwaW0q4.js.map +0 -1
- package/dist/components/p-D1i2OAGe.js.map +0 -1
- package/dist/components/p-DOZbXX2L.js.map +0 -1
- package/dist/components/p-DWG6az-u.js.map +0 -1
- package/dist/components/p-DaiLIZ8f.js.map +0 -1
- package/dist/components/p-Dc_0pr83.js.map +0 -1
- package/dist/components/p-Dk8ekxr_.js.map +0 -1
- package/dist/esm/grow.animation-CvHGHBL4.js.map +0 -1
- package/dist/native/p-02df60a5.entry.js +0 -2
- package/dist/native/p-02df60a5.entry.js.map +0 -1
- package/dist/native/p-0b8d6777.entry.js +0 -13
- package/dist/native/p-0b8d6777.entry.js.map +0 -1
- package/dist/native/p-0e7e693f.entry.js +0 -2
- package/dist/native/p-0e7e693f.entry.js.map +0 -1
- package/dist/native/p-0fe60a9d.entry.js +0 -2
- package/dist/native/p-0fe60a9d.entry.js.map +0 -1
- package/dist/native/p-14b0bf14.entry.js +0 -2
- package/dist/native/p-14b0bf14.entry.js.map +0 -1
- package/dist/native/p-28afb852.entry.js.map +0 -1
- package/dist/native/p-2cf77850.entry.js +0 -2
- package/dist/native/p-2cf77850.entry.js.map +0 -1
- package/dist/native/p-31a12d8a.entry.js +0 -2
- package/dist/native/p-31a12d8a.entry.js.map +0 -1
- package/dist/native/p-37c6d559.entry.js.map +0 -1
- package/dist/native/p-3c54e422.entry.js.map +0 -1
- package/dist/native/p-3c9b22ff.entry.js +0 -2
- package/dist/native/p-3c9b22ff.entry.js.map +0 -1
- package/dist/native/p-4a71f223.entry.js +0 -2
- package/dist/native/p-4a71f223.entry.js.map +0 -1
- package/dist/native/p-527e9b56.entry.js.map +0 -1
- package/dist/native/p-5bce524d.entry.js +0 -2
- package/dist/native/p-5bce524d.entry.js.map +0 -1
- package/dist/native/p-63bc0a05.entry.js +0 -2
- package/dist/native/p-63bc0a05.entry.js.map +0 -1
- package/dist/native/p-63bf86de.entry.js +0 -2
- package/dist/native/p-6a3c1413.entry.js +0 -2
- package/dist/native/p-7e274db7.entry.js +0 -7
- package/dist/native/p-7e274db7.entry.js.map +0 -1
- package/dist/native/p-86b2b071.entry.js +0 -2
- package/dist/native/p-86b2b071.entry.js.map +0 -1
- package/dist/native/p-8b278fce.entry.js +0 -2
- package/dist/native/p-8b278fce.entry.js.map +0 -1
- package/dist/native/p-9c543ab2.entry.js +0 -2
- package/dist/native/p-9c543ab2.entry.js.map +0 -1
- package/dist/native/p-DOZbXX2L.js +0 -2
- package/dist/native/p-DS5GOtQ3.js +0 -2
- package/dist/native/p-DS5GOtQ3.js.map +0 -1
- package/dist/native/p-a2aa6872.entry.js +0 -2
- package/dist/native/p-b1ef2f25.entry.js.map +0 -1
- package/dist/native/p-b2ed6d34.entry.js +0 -2
- package/dist/native/p-b2ed6d34.entry.js.map +0 -1
- package/dist/native/p-bd6ae5f3.entry.js +0 -2
- package/dist/native/p-c98b9ce4.entry.js +0 -2
- package/dist/native/p-c98b9ce4.entry.js.map +0 -1
- package/dist/native/p-cc305619.entry.js +0 -2
- package/dist/native/p-cc305619.entry.js.map +0 -1
- package/dist/native/p-d1cfdc3e.entry.js +0 -2
- package/dist/native/p-d1cfdc3e.entry.js.map +0 -1
- package/dist/native/p-d3b1bd81.entry.js +0 -2
- package/dist/native/p-d424b9aa.entry.js +0 -2
- package/dist/native/p-d424b9aa.entry.js.map +0 -1
- package/dist/native/p-d4f95c86.entry.js.map +0 -1
- package/dist/native/p-da893df2.entry.js.map +0 -1
- package/dist/native/p-e0adb05d.entry.js.map +0 -1
- package/dist/native/p-e6a37207.entry.js +0 -2
- package/dist/native/p-e6a37207.entry.js.map +0 -1
- package/dist/native/p-ee04ea09.entry.js.map +0 -1
- package/dist/native/p-f73e9752.entry.js.map +0 -1
- /package/dist/native/{p-b21e38a3.entry.js.map → p-04a2fe7f.entry.js.map} +0 -0
- /package/dist/native/{p-ea98ba7a.entry.js.map → p-436029a5.entry.js.map} +0 -0
- /package/dist/native/{p-5acf105e.entry.js.map → p-67181258.entry.js.map} +0 -0
- /package/dist/native/{p-63bf86de.entry.js.map → p-6aa483de.entry.js.map} +0 -0
- /package/dist/native/{p-b1a917c7.entry.js.map → p-6fc79712.entry.js.map} +0 -0
- /package/dist/native/{p-d3b1bd81.entry.js.map → p-78bf7650.entry.js.map} +0 -0
- /package/dist/native/{p-a2aa6872.entry.js.map → p-7e6e9ea2.entry.js.map} +0 -0
- /package/dist/native/{p-4cf47e1a.entry.js.map → p-910cd685.entry.js.map} +0 -0
- /package/dist/native/{p-9d8257dc.entry.js.map → p-96c45604.entry.js.map} +0 -0
- /package/dist/native/{p-fd872d54.entry.js.map → p-9f32c3ea.entry.js.map} +0 -0
- /package/dist/native/{p-b0935c49.entry.js.map → p-a6fea322.entry.js.map} +0 -0
- /package/dist/native/{p-0493fb6d.entry.js.map → p-c2a73a5a.entry.js.map} +0 -0
- /package/dist/native/{p-6a3c1413.entry.js.map → p-c4c11549.entry.js.map} +0 -0
- /package/dist/native/{p-e7dc36d9.entry.js.map → p-ceb8fe8a.entry.js.map} +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { p as proxyCustomElement, H, c as createEvent, h, d as Host } from './p-C63Xpg9a.js';
|
|
2
|
-
import { d as defineCustomElement$4 } from './p-
|
|
3
|
-
import { d as defineCustomElement$3 } from './p-
|
|
4
|
-
import { d as defineCustomElement$2 } from './p-
|
|
2
|
+
import { d as defineCustomElement$4 } from './p-nfYynlVq.js';
|
|
3
|
+
import { d as defineCustomElement$3 } from './p-DvapDVBj.js';
|
|
4
|
+
import { d as defineCustomElement$2 } from './p-COnt5ux_.js';
|
|
5
5
|
|
|
6
6
|
const nvTableheaderCss = "nv-tableheader{display:inline-flex;width:100%;align-items:center;gap:var(--spacing-2)}nv-tableheader:focus-visible:focus,nv-tableheader:focus-visible:focus-within{outline:none}nv-tableheader:focus-visible:focus-visible,nv-tableheader:focus-visible:has(:focus-visible){outline:calc(var(--focus-outline-stroke) * 1) solid var(--color-focus-brand);outline-offset:calc(var(--focus-outline-offset) * 1)}nv-tableheader:focus-visible{border-radius:var(--radius-rounded-sm)}nv-tableheader nv-iconbutton{transition:transform 120ms ease, opacity 120ms ease}nv-tableheader nv-iconbutton svg{transition:transform 240ms ease}nv-tableheader nv-iconbutton.is-none{opacity:0.5}nv-tableheader nv-iconbutton.is-desc svg{transform:rotate(180deg)}";
|
|
7
7
|
|
|
@@ -32,7 +32,7 @@ const NvTableheader$1 = /*@__PURE__*/ proxyCustomElement(class NvTableheader ext
|
|
|
32
32
|
cycleSortDirection(e) {
|
|
33
33
|
if (!this.sortable)
|
|
34
34
|
return;
|
|
35
|
-
e
|
|
35
|
+
e?.preventDefault();
|
|
36
36
|
const next = {
|
|
37
37
|
none: 'asc',
|
|
38
38
|
asc: 'desc',
|
|
@@ -63,7 +63,7 @@ const NvTableheader$1 = /*@__PURE__*/ proxyCustomElement(class NvTableheader ext
|
|
|
63
63
|
/****************************************************************************/
|
|
64
64
|
//#region RENDER
|
|
65
65
|
render() {
|
|
66
|
-
return (h(Host, { key: '
|
|
66
|
+
return (h(Host, { key: 'ae56ba389e554b3b555a1f29dba6a2c434e4a0ea', role: "columnheader", "aria-sort": this.ariaSort, tabindex: this.sortable ? 0 : undefined, onKeyDown: this.handleKeyDown.bind(this), onClick: this.cycleSortDirection.bind(this) }, h("slot", { key: '55efe6331ebcbde6b9b37f7d8dec610e444dc4b1' }), this.sortable && (h("span", { key: 'ecde17447218e6d462504cb10bdc8b95266ce402', class: "sort-icon-wrap", "aria-hidden": "true" }, h("nv-iconbutton", { key: 'c6e18e4149d2805cb16d5a79ec29db85a656b42c', disableTabindex: true, name: "arrow-up", size: "xs", emphasis: this.sortDirection === 'none' ? 'lower' : 'low',
|
|
67
67
|
// prevent mousedown from selecting text
|
|
68
68
|
onMouseDown: (e) => e.preventDefault(), class: {
|
|
69
69
|
'is-none': this.sortDirection === 'none',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"nv-tableheader.js","mappings":";;;;;AAAA,MAAM,gBAAgB,GAAG,ytBAAytB;;MCUruBA,eAAa,iBAAAC,kBAAA,CAAA,MAAA,aAAA,SAAAC,CAAA,CAAA;AAL1B,IAAA,WAAA,CAAA,YAAA,EAAA;;;;;;;;AASE;;;;AAIG;AAEM,QAAA,IAAQ,CAAA,QAAA,GAAY,KAAK;AAElC;;;AAGG;AAEH,QAAA,IAAa,CAAA,aAAA,GAA4B,MAAM;AA2FhD;;;;AArFS,IAAA,kBAAkB,CAAC,CAAS,EAAA;QAClC,IAAI,CAAC,IAAI,CAAC,QAAQ;YAAE;
|
|
1
|
+
{"file":"nv-tableheader.js","mappings":";;;;;AAAA,MAAM,gBAAgB,GAAG,ytBAAytB;;MCUruBA,eAAa,iBAAAC,kBAAA,CAAA,MAAA,aAAA,SAAAC,CAAA,CAAA;AAL1B,IAAA,WAAA,CAAA,YAAA,EAAA;;;;;;;;AASE;;;;AAIG;AAEM,QAAA,IAAQ,CAAA,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AAC,EACxC,OAAO,EAAE,IAAI,CAAC,kBAAkB,CAAC,IAAI,CAAC,IAAI,CAAC,EAAA,EAE3C,CAAa,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAA,EAEZ,IAAI,CAAC,QAAQ,KACZ,6DAAM,KAAK,EAAC,gBAAgB,EAAA,aAAA,EAAa,MAAM,EAAA,EAC7C,CACE,CAAA,eAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,eAAe,EACf,IAAA,EAAA,IAAI,EAAC,UAAU,EACf,IAAI,EAAC,IAAI,EACT,QAAQ,EAAE,IAAI,CAAC,aAAa,KAAK,MAAM,GAAG,OAAO,GAAG,KAAK;;AAEzD,YAAA,WAAW,EAAE,CAAC,CAAa,KAAK,CAAC,CAAC,cAAc,EAAE,EAClD,KAAK,EAAE;AACL,gBAAA,SAAS,EAAE,IAAI,CAAC,aAAa,KAAK,MAAM;AACxC,gBAAA,SAAS,EAAE,IAAI,CAAC,aAAa,KAAK,MAAM;AACzC,aAAA,EAAA,CACD,CACG,CACR,CACI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["NvTableheader","__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/nv-tableheader/nv-tableheader.scss?tag=nv-tableheader","src/components/nv-tableheader/nv-tableheader.tsx"],"sourcesContent":["// include focus ring\n@use \"../../styles/focus-ring\" as focus;\n\n@mixin root-styles() {\n display: inline-flex;\n width: 100%;\n align-items: center;\n gap: var(--spacing-2);\n}\n\n@mixin focus-styles() {\n @include focus.focus-ring();\n border-radius: var(--radius-rounded-sm);\n}\n\n@mixin nv-icon-styles() {\n transition: transform 120ms ease, opacity 120ms ease;\n svg {\n transition: transform 240ms ease;\n }\n &.is-none { opacity: .5; }\n &.is-desc {\n svg {\n transform: rotate(180deg);\n }\n }\n}\n\nnv-tableheader {\n @include root-styles();\n\n &:focus-visible {\n @include focus-styles();\n }\n\n nv-iconbutton {\n @include nv-icon-styles();\n }\n}","import { Component, Host, h, Prop, Event, EventEmitter } from '@stencil/core';\n\n/**\n * @slot default - Child content of the component.\n */\n@Component({\n tag: 'nv-tableheader',\n styleUrl: 'nv-tableheader.scss',\n shadow: false,\n})\nexport class NvTableheader {\n /****************************************************************************/\n //#region PROPERTIES\n\n /**\n * Will render the header as sortable with the corresponding icon button.\n * Allows the header to be tabbed, and trigger sorting via click or keyboard\n * navigation\n */\n @Prop({ reflect: true })\n readonly sortable: boolean = false;\n\n /**\n * The current sort direction of the header. Will be 'none' if the header is\n * not sortable or if the sort direction is not set.\n */\n @Prop({ reflect: true, mutable: true })\n sortDirection: 'none' | 'asc' | 'desc' = 'none';\n\n //#endregion PROPERTIES\n /****************************************************************************/\n //#region METHODS\n\n private cycleSortDirection(e?: Event) {\n if (!this.sortable) return;\n e?.preventDefault();\n\n const next = {\n none: 'asc',\n asc: 'desc',\n desc: 'none',\n } as const;\n\n this.sortDirection = next[this.sortDirection];\n this.sortDirectionChanged.emit(this.sortDirection);\n }\n\n private handleKeyDown(event: KeyboardEvent) {\n if (!this.sortable) return;\n if (event.key === 'Enter' || event.key === ' ') {\n event.preventDefault();\n this.cycleSortDirection();\n }\n }\n\n get ariaSort() {\n const sortMap = {\n none: 'none',\n asc: 'ascending',\n desc: 'descending',\n } as const;\n\n if (!this.sortable) return sortMap.none;\n return sortMap[this.sortDirection];\n }\n\n //#endregion METHODS\n /****************************************************************************/\n //#region WATCHERS\n //#endregion WATCHERS\n /****************************************************************************/\n //#region LIFECYCLE\n //#endregion LIFECYCLE\n /****************************************************************************/\n //#region EVENTS\n\n /**\n * Event emitted when the sort direction changes. Payload is the new sort\n * direction.\n */\n @Event({ bubbles: false })\n sortDirectionChanged: EventEmitter<string>;\n\n //#endregion EVENTS\n /****************************************************************************/\n //#region RENDER\n\n render() {\n return (\n <Host\n role=\"columnheader\"\n aria-sort={this.ariaSort}\n tabindex={this.sortable ? 0 : undefined}\n onKeyDown={this.handleKeyDown.bind(this)}\n onClick={this.cycleSortDirection.bind(this)}\n >\n <slot></slot>\n\n {this.sortable && (\n <span class=\"sort-icon-wrap\" aria-hidden=\"true\">\n <nv-iconbutton\n disableTabindex\n name=\"arrow-up\"\n size=\"xs\"\n emphasis={this.sortDirection === 'none' ? 'lower' : 'low'}\n // prevent mousedown from selecting text\n onMouseDown={(e: MouseEvent) => e.preventDefault()}\n class={{\n 'is-none': this.sortDirection === 'none',\n 'is-desc': this.sortDirection === 'desc',\n }}\n />\n </span>\n )}\n </Host>\n );\n }\n // #endregion RENDER\n}\n"],"version":3}
|
|
@@ -64,8 +64,8 @@ const NvToggle$1 = /*@__PURE__*/ proxyCustomElement(class NvToggle extends H {
|
|
|
64
64
|
/****************************************************************************/
|
|
65
65
|
//#region RENDER
|
|
66
66
|
render() {
|
|
67
|
-
return (h(Host, { key: '
|
|
68
|
-
this.el.querySelector('[slot="description"]')) && (h("div", { key: '
|
|
67
|
+
return (h(Host, { key: 'bf104d1513a3cf741c6b42ab48554c40d19263d1', class: clsx(this.labelPlacement === 'before' && 'label-placement-before') }, h("div", { key: '8c7e9684887e0d454a69101fb83f290d26236841', class: "input-container" }, h("input", { key: '5771d8999e03247600a2b98d0eae985ff0345e28', type: "checkbox", id: this.inputId, name: this.name, autocomplete: "off", value: this.value, checked: Boolean(this.checked), disabled: this.disabled || this.readonly, readonly: this.readonly })), h("div", { key: '8c95821037235c2eab053bce5bb7a0dc15173ea4', class: "text-container" }, (this.label || this.el.querySelector('[slot="label"]')) && (h("label", { key: '36c1d110f4c9151e1d05c665546f01f323999b15', htmlFor: this.inputId, class: clsx(this.hideLabel && 'visually-hidden') }, h("slot", { key: '4fe3f5fab8c1a20480c9eba085221afc36caae73', name: "label" }, this.label))), (this.description ||
|
|
68
|
+
this.el.querySelector('[slot="description"]')) && (h("div", { key: '63dc983d3b09327f57bd62feb7a25865f90390a7', class: "description" }, h("slot", { key: 'e85b616e8bf1301e53f62a2c4e1ea87675b1dcff', name: "description" }, this.description))))));
|
|
69
69
|
}
|
|
70
70
|
static get formAssociated() { return true; }
|
|
71
71
|
get el() { return this; }
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { p as proxyCustomElement, H, c as createEvent, h, d as Host } from './p-C63Xpg9a.js';
|
|
2
2
|
|
|
3
|
-
const nvTogglebuttonCss = "nv-togglebutton{display:inline-flex;justify-content:center;align-items:center}nv-togglebutton:focus-visible,nv-togglebutton:has(:focus-visible){z-index:1}nv-togglebutton[size=xs]{padding:var(--button-xs-padding-y) var(--button-xs-padding-x);gap:var(--button-xs-gap);border-radius:var(--button-xs-border-radius);line-height:var(--button-xs-line-height);height:var(--button-xs-height);font-size:var(--button-xs-font-size)}nv-togglebutton[size=xs] nv-icon>svg{width:var(--spacing-3);height:var(--spacing-3);stroke-width:1.2px}nv-togglebutton[size=xs]{padding-top:calc(var(--togglegroup-xs-button-padding-y) -
|
|
3
|
+
const nvTogglebuttonCss = "nv-togglebutton{display:inline-flex;justify-content:center;align-items:center}nv-togglebutton:focus-visible,nv-togglebutton:has(:focus-visible){z-index:1}nv-togglebutton[size=xs]{padding:var(--button-xs-padding-y) var(--button-xs-padding-x);gap:var(--button-xs-gap);border-radius:var(--button-xs-border-radius);line-height:var(--button-xs-line-height);height:var(--button-xs-height);font-size:var(--button-xs-font-size)}nv-togglebutton[size=xs] nv-icon>svg{width:var(--spacing-3);height:var(--spacing-3);stroke-width:1.2px}nv-togglebutton[size=xs]{padding-top:calc(var(--togglegroup-xs-button-padding-y) - var(--togglegroup-stroke));padding-bottom:calc(var(--togglegroup-xs-button-padding-y) - var(--togglegroup-stroke));border-radius:var(--togglegroup-xs-button-radius);height:calc((var(--togglegroup-xs-height)) - var(--togglegroup-inner-space));border-width:0}nv-togglebutton[size=sm]{padding:var(--button-sm-padding-y) var(--button-sm-padding-x);gap:var(--button-sm-gap);border-radius:var(--button-sm-border-radius);line-height:var(--button-sm-line-height);height:var(--button-sm-height);font-size:var(--button-sm-font-size)}nv-togglebutton[size=sm] nv-icon>svg{width:var(--spacing-4);height:var(--spacing-4);stroke-width:1.5px}nv-togglebutton[size=sm]{padding-top:calc(var(--togglegroup-sm-button-padding-y) - var(--togglegroup-stroke));padding-bottom:calc(var(--togglegroup-sm-button-padding-y) - var(--togglegroup-stroke));border-radius:calc(var(--togglegroup-sm-button-radius) + 1px);height:calc((var(--togglegroup-sm-height)) - var(--togglegroup-inner-space));border-width:0}nv-togglebutton[size=md]{padding:var(--button-md-padding-y) var(--button-md-padding-x);gap:var(--button-md-gap);border-radius:var(--button-md-border-radius);line-height:var(--button-md-line-height);height:var(--button-md-height);font-size:var(--button-md-font-size)}nv-togglebutton[size=md] nv-icon>svg{width:var(--spacing-5);height:var(--spacing-5);stroke-width:1.6px}nv-togglebutton[size=md]{padding-top:calc(var(--togglegroup-md-button-padding-y) - var(--togglegroup-stroke));padding-bottom:calc(var(--togglegroup-md-button-padding-y) - var(--togglegroup-stroke));border-radius:calc(var(--togglegroup-md-button-radius) + 1px);height:calc((var(--togglegroup-md-height)) - var(--togglegroup-inner-space));border-width:0}nv-togglebutton[size=lg]{padding:var(--button-lg-padding-y) var(--button-lg-padding-x);gap:var(--button-lg-gap);border-radius:var(--button-lg-border-radius);line-height:var(--button-lg-line-height);height:var(--button-lg-height);font-size:var(--button-lg-font-size)}nv-togglebutton[size=lg] nv-icon>svg{width:var(--spacing-6);height:var(--spacing-6);stroke-width:1.8px}nv-togglebutton[size=lg]{padding-top:calc(var(--togglegroup-lg-button-padding-y) - var(--togglegroup-stroke));padding-bottom:calc(var(--togglegroup-lg-button-padding-y) - var(--togglegroup-stroke));border-radius:calc(var(--togglegroup-lg-button-radius) + 1px);height:calc((var(--togglegroup-lg-height)) - var(--togglegroup-inner-space));border-width:0}nv-togglebutton[emphasis=high]{background:var(--components-button-low-background);border:1px solid var(--components-button-low-border);color:var(--components-button-low-text)}nv-togglebutton[emphasis=high]:hover{background:var(--components-button-low-background-hover);border:1px solid var(--components-button-low-border);color:var(--components-button-low-text-hover)}nv-togglebutton[emphasis=high]:active{background:var(--components-button-low-background-active);border:1px solid var(--components-button-low-border-active);color:var(--components-button-low-text-active)}nv-togglebutton[emphasis=high]:focus,nv-togglebutton[emphasis=high]:focus-within{outline:none}nv-togglebutton[emphasis=high]:focus-visible,nv-togglebutton[emphasis=high]:has(:focus-visible){outline:calc(var(--focus-outline-stroke) * 1) solid var(--color-focus-brand);outline-offset:calc(var(--focus-outline-offset) * 1)}nv-togglebutton[emphasis=high]:disabled:not([disabled=false]){opacity:0.5;cursor:not-allowed;box-shadow:none}nv-togglebutton[emphasis=high][active]:not([active=false]){background:var(--components-button-low-background-active);border:1px solid var(--components-button-low-border-active);color:var(--components-button-low-text-active)}nv-togglebutton[emphasis=low]{background:var(--components-button-lower-background);border:1px solid var(--components-button-lower-border);color:var(--components-button-lower-text)}nv-togglebutton[emphasis=low]:hover{background:var(--components-button-lower-background-hover);border:1px solid var(--components-button-lower-border);color:var(--components-button-lower-text-hover)}nv-togglebutton[emphasis=low]:active{background:var(--components-button-lower-background-active);border:1px solid var(--components-button-lower-border-active);color:var(--components-button-lower-text-active)}nv-togglebutton[emphasis=low]:focus,nv-togglebutton[emphasis=low]:focus-within{outline:none}nv-togglebutton[emphasis=low]:focus-visible,nv-togglebutton[emphasis=low]:has(:focus-visible){outline:calc(var(--focus-outline-stroke) * 1) solid var(--color-focus-brand);outline-offset:calc(var(--focus-outline-offset) * 1)}nv-togglebutton[emphasis=low]:disabled:not([disabled=false]){opacity:0.5;cursor:not-allowed;box-shadow:none}nv-togglebutton[emphasis=low][active]:not([active=false]),nv-togglebutton[emphasis=low]:active{background:var(--components-button-lower-background-hover);border:1px solid var(--components-button-lower-border);color:var(--components-button-lower-text-hover)}";
|
|
4
4
|
|
|
5
5
|
const NvTogglebutton$1 = /*@__PURE__*/ proxyCustomElement(class NvTogglebutton extends H {
|
|
6
6
|
constructor(registerHost) {
|
|
@@ -56,7 +56,7 @@ const NvTogglebutton$1 = /*@__PURE__*/ proxyCustomElement(class NvTogglebutton e
|
|
|
56
56
|
/****************************************************************************/
|
|
57
57
|
//#region RENDER
|
|
58
58
|
render() {
|
|
59
|
-
return (h(Host, { key: '
|
|
59
|
+
return (h(Host, { key: 'af68f5f4887be35f48bb74f15f597e7fe575b3fd', role: "button", tabindex: "0", "aria-pressed": String(this.active), onClick: this.handleClick }, h("slot", { key: '624ab0edc86bf9b5686f3f99097adf82ea972764' })));
|
|
60
60
|
}
|
|
61
61
|
get el() { return this; }
|
|
62
62
|
static get style() { return nvTogglebuttonCss; }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"nv-togglebutton.js","mappings":";;AAAA,MAAM,iBAAiB,GAAG,+
|
|
1
|
+
{"file":"nv-togglebutton.js","mappings":";;AAAA,MAAM,iBAAiB,GAAG,+4KAA+4K;;MCoB55KA,gBAAc,iBAAAC,kBAAA,CAAA,MAAA,cAAA,SAAAC,CAAA,CAAA;AAL3B,IAAA,WAAA,CAAA,YAAA,EAAA;;;;;;;;AAWE;;;;AAIG;AAEM,QAAA,IAAI,CAAA,IAAA,GAA0B,IAAI;AAS3C;;AAEG;AAEM,QAAA,IAAQ,CAAA,QAAA,GAAY,KAAK;AAElC;;;AAGG;AAEM,QAAA,IAAM,CAAA,MAAA,GAAY,KAAK;AAEhC;;AAEG;AAEM,QAAA,IAAQ,CAAA,QAAA,GAA8B,MAAM;;;;AAM7C,QAAA,IAAW,CAAA,WAAA,GAAG,MAAK;YACzB,IAAI,IAAI,CAAC,QAAQ;gBAAE;AAEnB,YAAA,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC;gBAChB,KAAK,EAAE,IAAI,CAAC,KAAK;gBACjB,MAAM,EAAE,IAAI,CAAC,MAAM;AACpB,aAAA,CAAC;AACJ,SAAC;AAgDF;;;;AAzCC,IAAA,aAAa,CAAC,KAAoB,EAAA;AAChC,QAAA,IAAI,KAAK,CAAC,GAAG,KAAK,OAAO,IAAI,KAAK,CAAC,GAAG,KAAK,GAAG,EAAE;YAC9C,KAAK,CAAC,cAAc,EAAE;AACtB,YAAA,IAAI,CAAC,EAAE,CAAC,KAAK,EAAE;;;;;;;IAyBnB,MAAM,GAAA;QACJ,QACE,EAAC,IAAI,EAAA,EAAA,GAAA,EAAA,0CAAA,EACH,IAAI,EAAC,QAAQ,EACb,QAAQ,EAAC,GAAG,kBACE,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,EACjC,OAAO,EAAE,IAAI,CAAC,WAAW,EAAA,EAEzB,CAAa,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAA,CACR;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["NvTogglebutton","__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/nv-togglebutton/styles/nv-togglebutton.scss?tag=nv-togglebutton","src/components/nv-togglebutton/nv-togglebutton.tsx"],"sourcesContent":["@use \"./mixins\" as *;\n\nnv-togglebutton {\n @include root-styles();\n\n @each $size in $sizes {\n &[size=\"#{$size}\"] {\n @include button-size-styles($size);\n @include togglegroup-button-size-styles($size);\n }\n }\n\n &[emphasis=\"high\"] {\n @include button-emphasis-styles('low');\n &[active]:not([active=\"false\"]) {\n @include button-active-styles('low');\n }\n }\n &[emphasis=\"low\"] {\n @include button-emphasis-styles('lower');\n &[active]:not([active=\"false\"]), &:active {\n @include button-hover-styles('lower');\n }\n }\n}\n","import {\n Component,\n Host,\n h,\n Prop,\n Event,\n Element,\n Listen,\n EventEmitter,\n} from '@stencil/core';\nimport { ToggleButtonEmphasis, ToggleButtonSize } from '../../utils/constants';\n\n/**\n * @slot default - Child content of the toggle button.\n */\n@Component({\n tag: 'nv-togglebutton',\n styleUrl: 'styles/nv-togglebutton.scss',\n shadow: false,\n})\nexport class NvTogglebutton {\n @Element() el: HTMLNvTogglebuttonElement;\n\n /****************************************************************************/\n //#region PROPERTIES\n\n /**\n * Determines how large or small the togglebutton appears, allowing for\n * customization of the togglebutton's dimensions to fit different design\n * specifications and user needs.\n */\n @Prop({ reflect: true })\n readonly size: `${ToggleButtonSize}` = 'md';\n\n /**\n * The value to associated with the button when selected in a\n * Togglebuttongroup.\n */\n @Prop({ reflect: true })\n readonly value: string;\n\n /**\n * Prevents all interaction, rendering the toggle in a non-interactive state.\n */\n @Prop({ reflect: true })\n readonly disabled: boolean = false;\n\n /**\n * Whether the button is active or not. Will not toggle automatically but\n * needs to be controlled externally.\n */\n @Prop({ reflect: true })\n readonly active: boolean = false;\n\n /**\n * Make it more or less visually prominent to users.\n */\n @Prop({ reflect: true })\n readonly emphasis: `${ToggleButtonEmphasis}` = 'high';\n\n //#endregion PROPERTIES\n /****************************************************************************/\n //#region METHODS\n\n private handleClick = () => {\n if (this.disabled) return;\n\n this.toggled.emit({\n value: this.value,\n active: this.active,\n });\n };\n\n //#endregion METHODS\n /****************************************************************************/\n //#region LISTENERS\n\n @Listen('keydown', { passive: false })\n handleKeyDown(event: KeyboardEvent) {\n if (event.key === 'Enter' || event.key === ' ') {\n event.preventDefault();\n this.el.click();\n }\n }\n\n //#endregion LISTENERS\n /****************************************************************************/\n //#region EVENTS\n\n /* eslint-disable nova/event-bubbling */\n /**\n * Emitted when the button is toggled. Will bubble up so that the\n * nv-togglebuttongroup can update the state.\n */\n @Event({ eventName: 'toggled', bubbles: true })\n toggled: EventEmitter<{\n /** The value associated with the button. */\n value: string;\n /** If the button is active when clicked. */\n active: boolean;\n }>;\n /* eslint-enable nova/event-bubbling */\n\n //#endregion EVENTS\n /****************************************************************************/\n //#region RENDER\n render() {\n return (\n <Host\n role=\"button\"\n tabindex=\"0\"\n aria-pressed={String(this.active)}\n onClick={this.handleClick}\n >\n <slot></slot>\n </Host>\n );\n }\n // #endregion RENDER\n}\n"],"version":3}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { p as proxyCustomElement, H, c as createEvent, h, d as Host } from './p-C63Xpg9a.js';
|
|
2
2
|
|
|
3
|
-
const nvTogglebuttongroupCss = "nv-togglebuttongroup{display:flex;gap:var(--togglegroup-lg-gap);border-radius:var(--togglegroup-lg-radius);width:fit-content;padding:var(--togglegroup-lg-gap)}nv-togglebuttongroup[emphasis=high]{border:1px solid var(--components-togglegroup-high-border)}nv-togglebuttongroup[emphasis=low]{border:1px solid var(--components-togglegroup-low-border)}nv-togglebuttongroup[size=xs]{padding:calc(var(--togglegroup-xs-padding) - 1px);gap:var(--togglegroup-xs-gap);border-radius:var(--togglegroup-xs-radius)}nv-togglebuttongroup[size=sm]{padding:calc(var(--togglegroup-sm-padding) - 1px);gap:var(--togglegroup-sm-gap);border-radius:var(--togglegroup-sm-radius)}nv-togglebuttongroup[size=md]{padding:calc(var(--togglegroup-md-padding) - 1px);gap:var(--togglegroup-md-gap);border-radius:var(--togglegroup-md-radius)}nv-togglebuttongroup[size=lg]{padding:calc(var(--togglegroup-lg-padding) - 1px);gap:var(--togglegroup-lg-gap);border-radius:var(--togglegroup-lg-radius)}";
|
|
3
|
+
const nvTogglebuttongroupCss = "nv-togglebuttongroup{display:flex;gap:var(--togglegroup-lg-gap);border-radius:var(--togglegroup-lg-radius);width:fit-content;padding:var(--togglegroup-lg-gap)}nv-togglebuttongroup[emphasis=high]{border:1px solid var(--components-togglegroup-high-border)}nv-togglebuttongroup[emphasis=low]{border:1px solid var(--components-togglegroup-low-border)}nv-togglebuttongroup[size=xs]{padding:calc(var(--togglegroup-xs-padding) - 1px);gap:var(--togglegroup-xs-gap);border-radius:var(--togglegroup-xs-radius);height:var(--togglegroup-xs-height)}nv-togglebuttongroup[size=sm]{padding:calc(var(--togglegroup-sm-padding) - 1px);gap:var(--togglegroup-sm-gap);border-radius:var(--togglegroup-sm-radius);height:var(--togglegroup-sm-height)}nv-togglebuttongroup[size=md]{padding:calc(var(--togglegroup-md-padding) - 1px);gap:var(--togglegroup-md-gap);border-radius:var(--togglegroup-md-radius);height:var(--togglegroup-md-height)}nv-togglebuttongroup[size=lg]{padding:calc(var(--togglegroup-lg-padding) - 1px);gap:var(--togglegroup-lg-gap);border-radius:var(--togglegroup-lg-radius);height:var(--togglegroup-lg-height)}";
|
|
4
4
|
|
|
5
5
|
const NvTogglebuttongroup$1 = /*@__PURE__*/ proxyCustomElement(class NvTogglebuttongroup extends H {
|
|
6
6
|
constructor(registerHost) {
|
|
@@ -36,11 +36,10 @@ const NvTogglebuttongroup$1 = /*@__PURE__*/ proxyCustomElement(class NvTogglebut
|
|
|
36
36
|
*/
|
|
37
37
|
this.setActiveToggleButtons = () => {
|
|
38
38
|
this.el.querySelectorAll('nv-togglebutton').forEach(toggleButtonEl => {
|
|
39
|
-
var _a;
|
|
40
39
|
const btn = NvTogglebuttongroup.asToggleButton(toggleButtonEl);
|
|
41
40
|
if (!btn)
|
|
42
41
|
return;
|
|
43
|
-
btn.active = (
|
|
42
|
+
btn.active = (this.value ?? []).includes(btn.value);
|
|
44
43
|
});
|
|
45
44
|
};
|
|
46
45
|
/**
|
|
@@ -157,7 +156,7 @@ const NvTogglebuttongroup$1 = /*@__PURE__*/ proxyCustomElement(class NvTogglebut
|
|
|
157
156
|
/****************************************************************************/
|
|
158
157
|
//#region RENDER
|
|
159
158
|
render() {
|
|
160
|
-
return (h(Host, { key: '
|
|
159
|
+
return (h(Host, { key: '2d4f46a06045c84018b0a5c296b2eb19c2803d7a' }, h("slot", { key: '4f387071fe030057df13c6b3ff5e6f480fcd339b' })));
|
|
161
160
|
}
|
|
162
161
|
get el() { return this; }
|
|
163
162
|
static get watchers() { return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"nv-togglebuttongroup.js","mappings":";;AAAA,MAAM,sBAAsB,GAAG,i8BAAi8B;;MCqBn9BA,qBAAmB,iBAAAC,kBAAA,CAAA,MAAA,mBAAA,SAAAC,CAAA,CAAA;AALhC,IAAA,WAAA,CAAA,YAAA,EAAA;;;;;;AAmBE;;AAEG;AAEM,QAAA,IAAS,CAAA,SAAA,GAAY,KAAK;AAEnC;;AAEG;AAEM,QAAA,IAAY,CAAA,YAAA,GAAY,KAAK;AAEtC;;AAEG;AAEM,QAAA,IAAQ,CAAA,QA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IAAI,QAAQ,CAAC,GAAG,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE;AACpC,gBAAA,IAAI,CAAC,KAAK,GAAG,EAAE;;iBACV;gBACL,IAAI,CAAC,KAAK,GAAG,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC;;YAEnC;;QAGF,MAAM,EAAE,IAAI,KAAK,CAAC,MAAM,CAAC,MAAM,EAAE;YAC/B,IAAI,IAAI,CAAC,YAAY,IAAI,QAAQ,CAAC,IAAI,KAAK,CAAC;AAAE,gBAAA,MAAM,MAAM;YAC1D,QAAQ,CAAC,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC;;aAC9B;YACL,QAAQ,CAAC,GAAG,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC;;AAElC,QAAA,IAAI,CAAC,KAAK,GAAG,CAAC,GAAG,QAAQ,CAAC;;;;;;IAQ5B,iBAAiB,GAAA;QACf,IAAI,CAAC,sBAAsB,EAAE;QAC7B,IAAI,CAAC,wBAAwB,EAAE;QAC/B,IAAI,CAAC,oBAAoB,EAAE;QAC3B,IAAI,CAAC,qBAAqB,EAAE;;IAG9B,oBAAoB,GAAA;AAClB,QAAA,IAAI,IAAI,CAAC,gBAAgB,EAAE;AACzB,YAAA,IAAI,CAAC,gBAAgB,CAAC,UAAU,EAAE;;;;;;IAmBtC,MAAM,GAAA;QACJ,QACE,EAAC,IAAI,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,EACH,CAAa,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAA,CACR;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["NvTogglebuttongroup","__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/nv-togglebuttongroup/styles/nv-togglebuttongroup.scss?tag=nv-togglebuttongroup","src/components/nv-togglebuttongroup/nv-togglebuttongroup.tsx"],"sourcesContent":["@use \"./mixins\" as *;\n\nnv-togglebuttongroup {\n @include root-styles();\n\n &[emphasis=\"high\"] {\n @include high-emphasis-styles();\n }\n &[emphasis=\"low\"] {\n @include low-emphasis-styles();\n }\n @each $size in $sizes {\n &[size=\"#{$size}\"] {\n @include size-styles($size);\n \n }\n }\n}\n","import {\n Component,\n Host,\n h,\n Prop,\n Listen,\n Watch,\n Element,\n Event,\n EventEmitter,\n} from '@stencil/core';\nimport { ToggleButtonEmphasis, ToggleButtonSize } from '../../utils/constants';\n\n/**\n * @slot default - Child content of the component, pass the nv-togglebutton components here.\n */\n@Component({\n tag: 'nv-togglebuttongroup',\n styleUrl: 'styles/nv-togglebuttongroup.scss',\n shadow: false,\n})\nexport class NvTogglebuttongroup {\n @Element() el!: HTMLNvTogglebuttongroupElement;\n private mutationObserver: MutationObserver;\n\n /****************************************************************************/\n //#region PROPERTIES\n\n /**\n * The active toggle buttons in the group. Is an array of one string when in\n * exclusive mode, and an array of strings when in non-exclusive mode.\n */\n @Prop({ reflect: false, mutable: true })\n value: string[];\n\n /**\n * Activates single-selection mode so only one button can be active at a time.\n */\n @Prop({ reflect: true })\n readonly exclusive: boolean = false;\n\n /**\n * Ensures at least one toggle stays selected at all times.\n */\n @Prop({ reflect: true })\n readonly enforceValue: boolean = false;\n\n /**\n * Make it more or less visually prominent to users.\n */\n @Prop({ reflect: true })\n readonly emphasis: `${ToggleButtonEmphasis}` = 'high';\n\n /**\n * Determines how large or small the togglebutton appears, allowing for\n * customization of the togglebutton's dimensions to fit different design\n * specifications and user needs.\n */\n @Prop({ reflect: true })\n readonly size: `${ToggleButtonSize}` = 'md';\n\n //#endregion PROPERTIES\n /****************************************************************************/\n //#region METHODS\n\n /**\n * Sets the active state of all toggle buttons depending on the value of the\n * group.\n */\n private setActiveToggleButtons = () => {\n this.el.querySelectorAll('nv-togglebutton').forEach(toggleButtonEl => {\n const btn = NvTogglebuttongroup.asToggleButton(toggleButtonEl);\n if (!btn) return;\n btn.active = (this.value ?? []).includes(btn.value);\n });\n };\n\n /**\n * Sets the emphasis of all toggle buttons to the same value.\n */\n private setEmphasisToggleButtons = () => {\n this.el.querySelectorAll('nv-togglebutton').forEach(toggleButtonEl => {\n const btn = NvTogglebuttongroup.asToggleButton(toggleButtonEl);\n if (!btn) return;\n btn.emphasis = this.emphasis;\n });\n };\n\n /**\n * Sets the size of all toggle buttons to the same value.\n */\n private setSizeToggleButtons = () => {\n this.el.querySelectorAll('nv-togglebutton').forEach(toggleButtonEl => {\n const btn = NvTogglebuttongroup.asToggleButton(toggleButtonEl);\n if (!btn) return;\n btn.size = this.size;\n });\n };\n\n /**\n * Sets up the MutationObserver to watch for changes in child elements\n */\n private setupMutationObserver = (): void => {\n this.mutationObserver = new MutationObserver(mutations => {\n mutations.forEach(mutation => {\n if (mutation.type === 'childList' && mutation.addedNodes.length > 0) {\n this.setEmphasisToggleButtons();\n this.setSizeToggleButtons();\n }\n });\n });\n\n this.mutationObserver.observe(this.el, {\n childList: true,\n subtree: true,\n });\n };\n\n /**\n * Narrow Type used locally to interact with nv-togglebutton child elements.\n * @param {Element} element - The element to check.\n * @returns {(HTMLElement & {\n * active: boolean;\n * value: string;\n * emphasis: `${ToggleButtonEmphasis}`;\n * size: `${ToggleButtonSize}`;\n * }) | null} The element as a toggle button, or null if it is not a toggle button.\n */\n private static asToggleButton(element: Element):\n | (HTMLElement & {\n /**\n * Whether the button is active or not. Will not toggle automatically but\n * needs to be controlled externally.\n */\n active: boolean;\n /**\n * The value to associated with the button when selected in a\n * Togglebuttongroup.\n */\n value: string;\n /**\n * Make it more or less visually prominent to users.\n */\n emphasis: `${ToggleButtonEmphasis}`;\n /**\n * Determines how large or small the togglebutton appears, allowing for\n * customization of the togglebutton's dimensions to fit different design\n * specifications and user needs.\n */\n size: `${ToggleButtonSize}`;\n })\n | null {\n return element instanceof HTMLElement\n ? (element as unknown as HTMLElement & {\n /**\n * Whether the button is active or not. Will not toggle automatically but\n * needs to be controlled externally.\n */\n active: boolean;\n /**\n * The value to associated with the button when selected in a\n * Togglebuttongroup.\n */\n value: string;\n /**\n * Make it more or less visually prominent to users.\n */\n emphasis: `${ToggleButtonEmphasis}`;\n /**\n * Determines how large or small the togglebutton appears, allowing for\n * customization of the togglebutton's dimensions to fit different design\n * specifications and user needs.\n */\n size: `${ToggleButtonSize}`;\n })\n : null;\n }\n //#endregion METHODS\n /****************************************************************************/\n //#region WATCHERS\n\n @Watch('value')\n onValueChanged(newValue: typeof this.value) {\n this.setActiveToggleButtons();\n this.valueChanged.emit(newValue);\n }\n\n @Watch('emphasis')\n onEmphasisChanged() {\n this.setEmphasisToggleButtons();\n }\n\n @Watch('size')\n onSizeChanged() {\n this.setSizeToggleButtons();\n }\n\n /* eslint-disable nova/native-event-listener */\n @Listen('toggled')\n onToggled(event: CustomEvent<HTMLNvTogglebuttonElementEventMap['toggled']>) {\n event.stopPropagation();\n\n const valueSet = new Set(this.value);\n\n if (this.exclusive && this.enforceValue) {\n this.value = [event.detail.value];\n return;\n }\n\n if (this.exclusive) {\n if (valueSet.has(event.detail.value)) {\n this.value = [];\n } else {\n this.value = [event.detail.value];\n }\n return;\n }\n\n toggle: if (event.detail.active) {\n if (this.enforceValue && valueSet.size === 1) break toggle;\n valueSet.delete(event.detail.value);\n } else {\n valueSet.add(event.detail.value);\n }\n this.value = [...valueSet];\n }\n /* eslint-enable nova/native-event-listener */\n\n //#endregion WATCHERS\n /****************************************************************************/\n //#region LIFECYCLE\n\n componentWillLoad() {\n this.setActiveToggleButtons();\n this.setEmphasisToggleButtons();\n this.setSizeToggleButtons();\n this.setupMutationObserver();\n }\n\n disconnectedCallback() {\n if (this.mutationObserver) {\n this.mutationObserver.disconnect();\n }\n }\n\n //#endregion LIFECYCLE\n /****************************************************************************/\n //#region EVENTS\n\n /**\n * Emitted when the selected toggle buttons change.\n * @bind value\n */\n @Event({ bubbles: false })\n valueChanged: EventEmitter<string[]>;\n\n //#endregion EVENTS\n /****************************************************************************/\n //#region RENDER\n\n render() {\n return (\n <Host>\n <slot></slot>\n </Host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A,EAAA,0CAAA,EAAA,EACH,CAAa,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAA,CACR;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["NvTogglebuttongroup","__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/nv-togglebuttongroup/styles/nv-togglebuttongroup.scss?tag=nv-togglebuttongroup","src/components/nv-togglebuttongroup/nv-togglebuttongroup.tsx"],"sourcesContent":["@use \"./mixins\" as *;\n\nnv-togglebuttongroup {\n @include root-styles();\n\n &[emphasis=\"high\"] {\n @include high-emphasis-styles();\n }\n &[emphasis=\"low\"] {\n @include low-emphasis-styles();\n }\n @each $size in $sizes {\n &[size=\"#{$size}\"] {\n @include size-styles($size);\n \n }\n }\n}\n","import {\n Component,\n Host,\n h,\n Prop,\n Listen,\n Watch,\n Element,\n Event,\n EventEmitter,\n} from '@stencil/core';\nimport { ToggleButtonEmphasis, ToggleButtonSize } from '../../utils/constants';\n\n/**\n * @slot default - Child content of the component, pass the nv-togglebutton components here.\n */\n@Component({\n tag: 'nv-togglebuttongroup',\n styleUrl: 'styles/nv-togglebuttongroup.scss',\n shadow: false,\n})\nexport class NvTogglebuttongroup {\n @Element() el!: HTMLNvTogglebuttongroupElement;\n private mutationObserver: MutationObserver;\n\n /****************************************************************************/\n //#region PROPERTIES\n\n /**\n * The active toggle buttons in the group. Is an array of one string when in\n * exclusive mode, and an array of strings when in non-exclusive mode.\n */\n @Prop({ reflect: false, mutable: true })\n value: string[];\n\n /**\n * Activates single-selection mode so only one button can be active at a time.\n */\n @Prop({ reflect: true })\n readonly exclusive: boolean = false;\n\n /**\n * Ensures at least one toggle stays selected at all times.\n */\n @Prop({ reflect: true })\n readonly enforceValue: boolean = false;\n\n /**\n * Make it more or less visually prominent to users.\n */\n @Prop({ reflect: true })\n readonly emphasis: `${ToggleButtonEmphasis}` = 'high';\n\n /**\n * Determines how large or small the togglebutton appears, allowing for\n * customization of the togglebutton's dimensions to fit different design\n * specifications and user needs.\n */\n @Prop({ reflect: true })\n readonly size: `${ToggleButtonSize}` = 'md';\n\n //#endregion PROPERTIES\n /****************************************************************************/\n //#region METHODS\n\n /**\n * Sets the active state of all toggle buttons depending on the value of the\n * group.\n */\n private setActiveToggleButtons = () => {\n this.el.querySelectorAll('nv-togglebutton').forEach(toggleButtonEl => {\n const btn = NvTogglebuttongroup.asToggleButton(toggleButtonEl);\n if (!btn) return;\n btn.active = (this.value ?? []).includes(btn.value);\n });\n };\n\n /**\n * Sets the emphasis of all toggle buttons to the same value.\n */\n private setEmphasisToggleButtons = () => {\n this.el.querySelectorAll('nv-togglebutton').forEach(toggleButtonEl => {\n const btn = NvTogglebuttongroup.asToggleButton(toggleButtonEl);\n if (!btn) return;\n btn.emphasis = this.emphasis;\n });\n };\n\n /**\n * Sets the size of all toggle buttons to the same value.\n */\n private setSizeToggleButtons = () => {\n this.el.querySelectorAll('nv-togglebutton').forEach(toggleButtonEl => {\n const btn = NvTogglebuttongroup.asToggleButton(toggleButtonEl);\n if (!btn) return;\n btn.size = this.size;\n });\n };\n\n /**\n * Sets up the MutationObserver to watch for changes in child elements\n */\n private setupMutationObserver = (): void => {\n this.mutationObserver = new MutationObserver(mutations => {\n mutations.forEach(mutation => {\n if (mutation.type === 'childList' && mutation.addedNodes.length > 0) {\n this.setEmphasisToggleButtons();\n this.setSizeToggleButtons();\n }\n });\n });\n\n this.mutationObserver.observe(this.el, {\n childList: true,\n subtree: true,\n });\n };\n\n /**\n * Narrow Type used locally to interact with nv-togglebutton child elements.\n * @param {Element} element - The element to check.\n * @returns {(HTMLElement & {\n * active: boolean;\n * value: string;\n * emphasis: `${ToggleButtonEmphasis}`;\n * size: `${ToggleButtonSize}`;\n * }) | null} The element as a toggle button, or null if it is not a toggle button.\n */\n private static asToggleButton(element: Element):\n | (HTMLElement & {\n /**\n * Whether the button is active or not. Will not toggle automatically but\n * needs to be controlled externally.\n */\n active: boolean;\n /**\n * The value to associated with the button when selected in a\n * Togglebuttongroup.\n */\n value: string;\n /**\n * Make it more or less visually prominent to users.\n */\n emphasis: `${ToggleButtonEmphasis}`;\n /**\n * Determines how large or small the togglebutton appears, allowing for\n * customization of the togglebutton's dimensions to fit different design\n * specifications and user needs.\n */\n size: `${ToggleButtonSize}`;\n })\n | null {\n return element instanceof HTMLElement\n ? (element as unknown as HTMLElement & {\n /**\n * Whether the button is active or not. Will not toggle automatically but\n * needs to be controlled externally.\n */\n active: boolean;\n /**\n * The value to associated with the button when selected in a\n * Togglebuttongroup.\n */\n value: string;\n /**\n * Make it more or less visually prominent to users.\n */\n emphasis: `${ToggleButtonEmphasis}`;\n /**\n * Determines how large or small the togglebutton appears, allowing for\n * customization of the togglebutton's dimensions to fit different design\n * specifications and user needs.\n */\n size: `${ToggleButtonSize}`;\n })\n : null;\n }\n //#endregion METHODS\n /****************************************************************************/\n //#region WATCHERS\n\n @Watch('value')\n onValueChanged(newValue: typeof this.value) {\n this.setActiveToggleButtons();\n this.valueChanged.emit(newValue);\n }\n\n @Watch('emphasis')\n onEmphasisChanged() {\n this.setEmphasisToggleButtons();\n }\n\n @Watch('size')\n onSizeChanged() {\n this.setSizeToggleButtons();\n }\n\n /* eslint-disable nova/native-event-listener */\n @Listen('toggled')\n onToggled(event: CustomEvent<HTMLNvTogglebuttonElementEventMap['toggled']>) {\n event.stopPropagation();\n\n const valueSet = new Set(this.value);\n\n if (this.exclusive && this.enforceValue) {\n this.value = [event.detail.value];\n return;\n }\n\n if (this.exclusive) {\n if (valueSet.has(event.detail.value)) {\n this.value = [];\n } else {\n this.value = [event.detail.value];\n }\n return;\n }\n\n toggle: if (event.detail.active) {\n if (this.enforceValue && valueSet.size === 1) break toggle;\n valueSet.delete(event.detail.value);\n } else {\n valueSet.add(event.detail.value);\n }\n this.value = [...valueSet];\n }\n /* eslint-enable nova/native-event-listener */\n\n //#endregion WATCHERS\n /****************************************************************************/\n //#region LIFECYCLE\n\n componentWillLoad() {\n this.setActiveToggleButtons();\n this.setEmphasisToggleButtons();\n this.setSizeToggleButtons();\n this.setupMutationObserver();\n }\n\n disconnectedCallback() {\n if (this.mutationObserver) {\n this.mutationObserver.disconnect();\n }\n }\n\n //#endregion LIFECYCLE\n /****************************************************************************/\n //#region EVENTS\n\n /**\n * Emitted when the selected toggle buttons change.\n * @bind value\n */\n @Event({ bubbles: false })\n valueChanged: EventEmitter<string[]>;\n\n //#endregion EVENTS\n /****************************************************************************/\n //#region RENDER\n\n render() {\n return (\n <Host>\n <slot></slot>\n </Host>\n );\n }\n\n // #endregion RENDER\n}\n"],"version":3}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { p as proxyCustomElement, H, h, d as Host } from './p-C63Xpg9a.js';
|
|
2
2
|
import { b as ButtonType, B as ButtonSize } from './p-BReL3Lsa.js';
|
|
3
|
-
import { d as defineCustomElement$1 } from './p-
|
|
3
|
+
import { d as defineCustomElement$1 } from './p-COnt5ux_.js';
|
|
4
4
|
|
|
5
5
|
const nvButtonCss = "nv-button{text-decoration:none;display:inline-flex;justify-content:center;align-items:center;font-style:normal;font-weight:var(--font-weight-medium-emphasis);font-family:var(--font-family-default), var(--font-family-fallback), sans-serif;transition:background-color 150ms ease-out;user-select:none;cursor:pointer;height:fit-content;width:fit-content}nv-button[size=xs]{padding:var(--button-xs-padding-y) var(--button-xs-padding-x);gap:var(--button-xs-gap);border-radius:var(--button-xs-border-radius);line-height:var(--button-xs-line-height);height:var(--button-xs-height);font-size:var(--button-xs-font-size)}nv-button[size=xs] nv-icon>svg{width:var(--spacing-3);height:var(--spacing-3);stroke-width:1.2px}nv-button[size=sm]{padding:var(--button-sm-padding-y) var(--button-sm-padding-x);gap:var(--button-sm-gap);border-radius:var(--button-sm-border-radius);line-height:var(--button-sm-line-height);height:var(--button-sm-height);font-size:var(--button-sm-font-size)}nv-button[size=sm] nv-icon>svg{width:var(--spacing-4);height:var(--spacing-4);stroke-width:1.5px}nv-button[size=md]{padding:var(--button-md-padding-y) var(--button-md-padding-x);gap:var(--button-md-gap);border-radius:var(--button-md-border-radius);line-height:var(--button-md-line-height);height:var(--button-md-height);font-size:var(--button-md-font-size)}nv-button[size=md] nv-icon>svg{width:var(--spacing-5);height:var(--spacing-5);stroke-width:1.6px}nv-button[size=lg]{padding:var(--button-lg-padding-y) var(--button-lg-padding-x);gap:var(--button-lg-gap);border-radius:var(--button-lg-border-radius);line-height:var(--button-lg-line-height);height:var(--button-lg-height);font-size:var(--button-lg-font-size)}nv-button[size=lg] nv-icon>svg{width:var(--spacing-6);height:var(--spacing-6);stroke-width:1.8px}nv-button[emphasis=high]{background:var(--components-button-high-background);border:1px solid var(--components-button-high-border);color:var(--components-button-high-text)}nv-button[emphasis=high]:hover{background:var(--components-button-high-background-hover);border:1px solid var(--components-button-high-border);color:var(--components-button-high-text-hover)}nv-button[emphasis=high]:active{background:var(--components-button-high-background-active);border:1px solid var(--components-button-high-border-active);color:var(--components-button-high-text-active)}nv-button[emphasis=high]:focus,nv-button[emphasis=high]:focus-within{outline:none}nv-button[emphasis=high]:focus-visible,nv-button[emphasis=high]:has(:focus-visible){outline:calc(var(--focus-outline-stroke) * 1) solid var(--color-focus-brand);outline-offset:calc(var(--focus-outline-offset) * 1)}nv-button[emphasis=high]:disabled:not([disabled=false]){opacity:0.5;cursor:not-allowed;box-shadow:none}nv-button[emphasis=high][active]:not([active=false]){background:var(--components-button-high-background-active);border:1px solid var(--components-button-high-border-active);color:var(--components-button-high-text-active)}nv-button[emphasis=high][danger]:not([danger=false]){background:var(--components-button-destructive-high-background);border:1px solid transparent;color:var(--components-button-destructive-high-text)}nv-button[emphasis=high][danger]:not([danger=false]):hover{background:var(--components-button-destructive-high-background-hover);border:1px solid transparent;color:var(--components-button-destructive-high-text-hover)}nv-button[emphasis=high][danger]:not([danger=false]):focus,nv-button[emphasis=high][danger]:not([danger=false]):focus-within{outline:none}nv-button[emphasis=high][danger]:not([danger=false]):focus-visible,nv-button[emphasis=high][danger]:not([danger=false]):has(:focus-visible){outline:calc(var(--focus-outline-stroke) * 1) solid var(--color-focus-destructive);outline-offset:calc(var(--focus-outline-offset) * 1)}nv-button[emphasis=medium]{background:var(--components-button-medium-background);border:1px solid var(--components-button-medium-border);color:var(--components-button-medium-text)}nv-button[emphasis=medium]:hover{background:var(--components-button-medium-background-hover);border:1px solid var(--components-button-medium-border);color:var(--components-button-medium-text-hover)}nv-button[emphasis=medium]:active{background:var(--components-button-medium-background-active);border:1px solid var(--components-button-medium-border-active);color:var(--components-button-medium-text-active)}nv-button[emphasis=medium]:focus,nv-button[emphasis=medium]:focus-within{outline:none}nv-button[emphasis=medium]:focus-visible,nv-button[emphasis=medium]:has(:focus-visible){outline:calc(var(--focus-outline-stroke) * 1) solid var(--color-focus-brand);outline-offset:calc(var(--focus-outline-offset) * 1)}nv-button[emphasis=medium]:disabled:not([disabled=false]){opacity:0.5;cursor:not-allowed;box-shadow:none}nv-button[emphasis=medium][active]:not([active=false]){background:var(--components-button-medium-background-active);border:1px solid var(--components-button-medium-border-active);color:var(--components-button-medium-text-active)}nv-button[emphasis=medium][danger]:not([danger=false]){background:var(--components-button-destructive-medium-background);border:1px solid var(--components-button-destructive-medium-border);color:var(--components-button-destructive-medium-text)}nv-button[emphasis=medium][danger]:not([danger=false]):hover{background:var(--components-button-destructive-medium-background-hover);border:1px solid var(--components-button-destructive-medium-border);color:var(--components-button-destructive-medium-text-hover)}nv-button[emphasis=medium][danger]:not([danger=false]):focus,nv-button[emphasis=medium][danger]:not([danger=false]):focus-within{outline:none}nv-button[emphasis=medium][danger]:not([danger=false]):focus-visible,nv-button[emphasis=medium][danger]:not([danger=false]):has(:focus-visible){outline:calc(var(--focus-outline-stroke) * 1) solid var(--color-focus-destructive);outline-offset:calc(var(--focus-outline-offset) * 1)}nv-button[emphasis=low]{background:var(--components-button-low-background);border:1px solid var(--components-button-low-border);color:var(--components-button-low-text)}nv-button[emphasis=low]:hover{background:var(--components-button-low-background-hover);border:1px solid var(--components-button-low-border);color:var(--components-button-low-text-hover)}nv-button[emphasis=low]:active{background:var(--components-button-low-background-active);border:1px solid var(--components-button-low-border-active);color:var(--components-button-low-text-active)}nv-button[emphasis=low]:focus,nv-button[emphasis=low]:focus-within{outline:none}nv-button[emphasis=low]:focus-visible,nv-button[emphasis=low]:has(:focus-visible){outline:calc(var(--focus-outline-stroke) * 1) solid var(--color-focus-brand);outline-offset:calc(var(--focus-outline-offset) * 1)}nv-button[emphasis=low]:disabled:not([disabled=false]){opacity:0.5;cursor:not-allowed;box-shadow:none}nv-button[emphasis=low][active]:not([active=false]){background:var(--components-button-low-background-active);border:1px solid var(--components-button-low-border-active);color:var(--components-button-low-text-active)}nv-button[emphasis=low][danger]:not([danger=false]){background:var(--components-button-destructive-low-background);border:1px solid var(--components-button-destructive-low-border);color:var(--components-button-destructive-low-text)}nv-button[emphasis=low][danger]:not([danger=false]):hover{background:var(--components-button-destructive-low-background-hover);border:1px solid var(--components-button-destructive-low-border);color:var(--components-button-destructive-low-text-hover)}nv-button[emphasis=low][danger]:not([danger=false]):focus,nv-button[emphasis=low][danger]:not([danger=false]):focus-within{outline:none}nv-button[emphasis=low][danger]:not([danger=false]):focus-visible,nv-button[emphasis=low][danger]:not([danger=false]):has(:focus-visible){outline:calc(var(--focus-outline-stroke) * 1) solid var(--color-focus-destructive);outline-offset:calc(var(--focus-outline-offset) * 1)}nv-button[emphasis=lower]{background:var(--components-button-lower-background);border:1px solid var(--components-button-lower-border);color:var(--components-button-lower-text)}nv-button[emphasis=lower]:hover{background:var(--components-button-lower-background-hover);border:1px solid var(--components-button-lower-border);color:var(--components-button-lower-text-hover)}nv-button[emphasis=lower]:active{background:var(--components-button-lower-background-active);border:1px solid var(--components-button-lower-border-active);color:var(--components-button-lower-text-active)}nv-button[emphasis=lower]:focus,nv-button[emphasis=lower]:focus-within{outline:none}nv-button[emphasis=lower]:focus-visible,nv-button[emphasis=lower]:has(:focus-visible){outline:calc(var(--focus-outline-stroke) * 1) solid var(--color-focus-brand);outline-offset:calc(var(--focus-outline-offset) * 1)}nv-button[emphasis=lower]:disabled:not([disabled=false]){opacity:0.5;cursor:not-allowed;box-shadow:none}nv-button[emphasis=lower][active]:not([active=false]){background:var(--components-button-lower-background-active);border:1px solid var(--components-button-lower-border-active);color:var(--components-button-lower-text-active)}nv-button[emphasis=lower][danger]:not([danger=false]){background:var(--components-button-destructive-lower-background);border:1px solid var(--components-button-destructive-lower-border);color:var(--components-button-destructive-lower-text)}nv-button[emphasis=lower][danger]:not([danger=false]):hover{background:var(--components-button-destructive-lower-background-hover);border:1px solid var(--components-button-destructive-lower-border);color:var(--components-button-destructive-lower-text-hover)}nv-button[emphasis=lower][danger]:not([danger=false]):focus,nv-button[emphasis=lower][danger]:not([danger=false]):focus-within{outline:none}nv-button[emphasis=lower][danger]:not([danger=false]):focus-visible,nv-button[emphasis=lower][danger]:not([danger=false]):has(:focus-visible){outline:calc(var(--focus-outline-stroke) * 1) solid var(--color-focus-destructive);outline-offset:calc(var(--focus-outline-offset) * 1)}nv-button[fluid]:not([fluid=false]){width:100%}nv-button[loading]:not([loading=false]) [slot=leading-icon]{display:none}";
|
|
6
6
|
|
|
@@ -70,13 +70,12 @@ const NvButton = /*@__PURE__*/ proxyCustomElement(class NvButton extends H {
|
|
|
70
70
|
* @param {Event} event - The click event.
|
|
71
71
|
*/
|
|
72
72
|
this.handleButtonClick = (event) => {
|
|
73
|
-
var _a;
|
|
74
73
|
if (this.loading || this.disabled) {
|
|
75
74
|
event.preventDefault();
|
|
76
75
|
return;
|
|
77
76
|
}
|
|
78
77
|
if (this.type !== ButtonType.Button &&
|
|
79
|
-
(this.form ||
|
|
78
|
+
(this.form || this.internals?.form)) {
|
|
80
79
|
this.processFormAction();
|
|
81
80
|
}
|
|
82
81
|
else if (this.form && this.type === ButtonType.Button) {
|
|
@@ -89,12 +88,11 @@ const NvButton = /*@__PURE__*/ proxyCustomElement(class NvButton extends H {
|
|
|
89
88
|
* Falls back to ElementInternals form if no explicit form ID is provided.
|
|
90
89
|
*/
|
|
91
90
|
this.processFormAction = () => {
|
|
92
|
-
var _a, _b;
|
|
93
91
|
const formElement = this.form
|
|
94
92
|
? document.getElementById(this.form)
|
|
95
|
-
:
|
|
93
|
+
: this.internals?.form;
|
|
96
94
|
if (!formElement) {
|
|
97
|
-
console.warn('No form element found.', `Form ID: ${this.form || 'Not provided'}`, `Internals form:`,
|
|
95
|
+
console.warn('No form element found.', `Form ID: ${this.form || 'Not provided'}`, `Internals form:`, this.internals?.form);
|
|
98
96
|
return;
|
|
99
97
|
}
|
|
100
98
|
switch (this.type) {
|
|
@@ -188,6 +186,6 @@ function defineCustomElement() {
|
|
|
188
186
|
defineCustomElement();
|
|
189
187
|
|
|
190
188
|
export { NvButton as N, defineCustomElement as d };
|
|
191
|
-
//# sourceMappingURL=p-
|
|
189
|
+
//# sourceMappingURL=p-B45HbBWe.js.map
|
|
192
190
|
|
|
193
|
-
//# sourceMappingURL=p-
|
|
191
|
+
//# sourceMappingURL=p-B45HbBWe.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"file":"p-B45HbBWe.js","mappings":";;;;AAAA,MAAM,WAAW,GAAG,4/TAA4/T;;MCwBngU,QAAQ,iBAAAA,kBAAA,CAAA,MAAA,QAAA,SAAAC,CAAA,CAAA;AANrB,IAAA,WAAA,CAAA,YAAA,EAAA;;;;;;;;AAaE;;;;AAIG;AAEM,QAAA,IAAI,CAAA,IAAA,GAAoB,IAAI;AAErC;;;;AAIG;AAEM,QAAA,IAAQ,CAAA,QAAA,GAAwB,MAAM;AAE/C;;;AAGG;AAEM,QAAA,IAAM,CAAA,MAAA,GAAY,KAAK;AAEhC;;;AAGG;AAEM,QAAA,IAAM,CAAA,MAAA,GAAY,KAAK;AAEhC;;;;AAIG;AAEH,QAAA,IAAO,CAAA,OAAA,GAAY,KAAK;AAExB;;AAEG;AAEH,QAAA,IAAQ,CAAA,QAAA,GAAY,KAAK;AAEzB;;AAEG;AAEM,QAAA,IAAK,CAAA,KAAA,GAAY,KAAK;AA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AM,IAAI,EAAC,eAAe,EAAQ,CAAA,CAC7B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/nv-button/styles/nv-button.scss?tag=nv-button","src/components/nv-button/nv-button.tsx"],"sourcesContent":["@use \"./mixins\" as *;\n\n// Make sure to update nv-button class in the tailwind-components.scss file when\n// you add new styles or change the structure here.\nnv-button {\n @include root-styles();\n\n @each $size in $sizes {\n &[size=\"#{$size}\"] {\n @include size-styles($size);\n }\n }\n\n @each $emphasis in $emphases {\n &[emphasis=\"#{$emphasis}\"] {\n @include emphasis-styles($emphasis);\n\n &[active]:not([active=\"false\"]) {\n @include active-styles($emphasis);\n }\n\n &[danger]:not([danger=\"false\"]) {\n @include danger-styles($emphasis);\n }\n }\n }\n\n &[fluid]:not([fluid=\"false\"]) {\n @include fluid-styles();\n }\n\n &[loading]:not([loading=\"false\"]) {\n [slot=\"leading-icon\"] {\n display: none;\n }\n }\n}\n","import {\n Component,\n Listen,\n Host,\n h,\n Prop,\n AttachInternals,\n Element,\n Watch,\n} from '@stencil/core';\n\nimport { ButtonSize, ButtonEmphasis, ButtonType } from '../../utils/constants';\n\n/**\n * @slot default - Content of the button.\n * @slot leading-icon - Icon before the label.\n * @slot trailing-icon - Icon after the label.\n */\n@Component({\n tag: 'nv-button',\n shadow: false,\n formAssociated: true,\n styleUrl: 'styles/nv-button.scss',\n})\nexport class NvButton {\n @AttachInternals() internals: ElementInternals;\n @Element() el: HTMLNvButtonElement;\n\n /****************************************************************************/\n //#region PROPERTIES\n\n /**\n * Determines how large or small the button appears, allowing for\n * customization of the button's dimensions to fit different design\n * specifications and user needs.\n */\n @Prop({ reflect: true })\n readonly size: `${ButtonSize}` = 'md';\n\n /**\n * Adjusts the button's emphasis to make it more or less visually prominent\n * to users. Use this to draw attention to important actions or reduce focus\n * on less critical ones\n */\n @Prop({ reflect: true })\n readonly emphasis: `${ButtonEmphasis}` = 'high';\n\n /**\n * Use this prop to highlight the button when it represents the current page\n * or active selection. This helps users understand their navigation context.\n */\n @Prop({ reflect: true })\n readonly active: boolean = false;\n\n /**\n * Applies styling that visually indicates the button represents a dangerous\n * action.\n */\n @Prop({ reflect: true })\n readonly danger: boolean = false;\n\n /**\n * Set this to true to show a spinner on the button, letting users know that\n * their action is being processed. It helps improve user experience by\n * indicating ongoing activities.\n */\n @Prop({ reflect: true, mutable: true })\n loading: boolean = false;\n\n /**\n * Disables the button, preventing user interaction.\n */\n @Prop({ reflect: true, mutable: true })\n disabled: boolean = false;\n\n /**\n * Allows the button to stretch and fill the entire width of its container.\n */\n @Prop({ reflect: true })\n readonly fluid: boolean = false;\n\n /**\n * Sets the button type to control its function in forms. Use 'submit' to send\n * form data, 'reset' to clear the form, or 'button' for a standard button\n * that doesn't interact with form submission by default.\n */\n @Prop({ reflect: true })\n readonly type: `${ButtonType}` = 'button';\n\n /**\n * Sets the form associated with the button in case the (submit) button is not a child of a form.\n * Matches the native HTML button 'form' attribute behavior.\n */\n @Prop({ reflect: true })\n readonly form: string;\n\n /**\n * Use this to make the button skip-able when users navigate with the keyboard.\n * The button remains clickable but won’t be reached via the Tab key.\n */\n @Prop({ reflect: true })\n readonly disableTabindex: boolean = false;\n\n //#endregion PROPERTIES\n /****************************************************************************/\n //#region METHODS\n\n /**\n * Handles button click events, managing form actions and disabled states.\n * Prevents default behavior when button is disabled or loading, and\n * processes form submissions/resets when appropriate.\n * @param {Event} event - The click event.\n */\n private handleButtonClick = (event: Event): void => {\n if (this.loading || this.disabled) {\n event.preventDefault();\n return;\n }\n\n if (\n this.type !== ButtonType.Button &&\n (this.form || this.internals?.form)\n ) {\n this.processFormAction();\n } else if (this.form && this.type === ButtonType.Button) {\n console.warn(\n 'Button has a form id but is not of type submit or reset so no form action will be processed.',\n `Button:`,\n this.el,\n );\n }\n };\n\n /**\n * Processes form-related actions by finding the associated form element\n * and triggering the appropriate action (submit/reset) based on button type.\n * Falls back to ElementInternals form if no explicit form ID is provided.\n */\n private processFormAction = (): void => {\n const formElement = this.form\n ? (document.getElementById(this.form) as HTMLFormElement)\n : this.internals?.form;\n\n if (!formElement) {\n console.warn(\n 'No form element found.',\n `Form ID: ${this.form || 'Not provided'}`,\n `Internals form:`,\n this.internals?.form,\n );\n return;\n }\n\n switch (this.type) {\n case ButtonType.Submit:\n formElement.requestSubmit();\n break;\n case ButtonType.Reset:\n formElement.reset();\n break;\n }\n };\n\n //#endregion METHODS\n /****************************************************************************/\n //#region EVENTS\n\n @Listen('keydown', { passive: false })\n handleKeyDown(event: KeyboardEvent) {\n if (event.key === 'Enter' || event.key === ' ') {\n event.preventDefault();\n this.el.click();\n }\n }\n\n //#endregion EVENTS\n /****************************************************************************/\n //#region WATCHERS\n\n @Watch('loading')\n handleLoadingChange(loading: boolean) {\n this.loading = loading;\n this.disabled = loading;\n }\n\n @Watch('disabled')\n handleDisabledChange(disabled: boolean) {\n if (this.loading) {\n this.disabled = this.loading;\n } else {\n this.disabled = disabled;\n }\n }\n\n //#endregion WATCHERS\n /****************************************************************************/\n //#region LIFECYCLE\n\n componentWillLoad() {\n if (this.loading) {\n this.disabled = this.loading;\n }\n }\n\n //#endregion LIFECYCLE\n /****************************************************************************/\n //#region RENDER\n\n render() {\n return (\n <Host\n role=\"button\"\n tabindex={this.disableTabindex ? -1 : 0}\n onClick={this.handleButtonClick}\n >\n {this.loading && (\n <nv-loader\n size={this.size === ButtonSize.Large ? 'sm' : 'xs'}\n ></nv-loader>\n )}\n\n <slot name=\"leading-icon\"></slot>\n <slot></slot>\n <slot name=\"trailing-icon\"></slot>\n </Host>\n );\n }\n\n //#endregion RENDER\n}\n"],"version":3}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Adds a set of event listeners to the given target.
|
|
3
|
+
* @param {EventsAndListeners} events - The events and listeners to add.
|
|
4
|
+
* @param {Element | Window | Document} target - The target element or window to add the event listeners to.
|
|
5
|
+
* @param {T} context - The class context to bind the event listeners to.
|
|
6
|
+
*/
|
|
7
|
+
function addEventListeners(events, target, context) {
|
|
8
|
+
events.forEach(([event, listener]) => target.addEventListener(event, listener.bind(context)));
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Removes a set of event listeners from the given target.
|
|
12
|
+
* @param {EventsAndListeners} events - The events and listeners to remove.
|
|
13
|
+
* @param {Element | Window | Document} target - The target element or window to remove the event listeners from.
|
|
14
|
+
* @param {T} context - The class context to bind the event listeners to.
|
|
15
|
+
*/
|
|
16
|
+
function removeEventListeners(events, target, context) {
|
|
17
|
+
events.forEach(([event, listener]) => target.removeEventListener(event, listener.bind(context)));
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
var events_utils = /*#__PURE__*/Object.freeze({
|
|
21
|
+
__proto__: null,
|
|
22
|
+
addEventListeners: addEventListeners,
|
|
23
|
+
removeEventListeners: removeEventListeners
|
|
24
|
+
});
|
|
25
|
+
|
|
26
|
+
export { addEventListeners as a, events_utils as e, removeEventListeners as r };
|
|
27
|
+
//# sourceMappingURL=p-B6GgGra-.js.map
|
|
28
|
+
|
|
29
|
+
//# sourceMappingURL=p-B6GgGra-.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"file":"p-B6GgGra-.js","mappings":"AAEA;;;;;AAKG;SACa,iBAAiB,CAC/B,MAA0B,EAC1B,MAAmC,EACnC,OAAU,EAAA;IAEV,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,KAAK,EAAE,QAAQ,CAAC,KAC/B,MAAM,CAAC,gBAAgB,CAAC,KAAK,EAAE,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CACvD;AACH;AAEA;;;;;AAKG;SACa,oBAAoB,CAClC,MAA0B,EAC1B,MAAmC,EACnC,OAAU,EAAA;IAEV,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,KAAK,EAAE,QAAQ,CAAC,KAC/B,MAAM,CAAC,mBAAmB,CAAC,KAAK,EAAE,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAC1D;AACH;;;;;;;;;;","names":[],"sources":["src/utils/events.utils.ts"],"sourcesContent":["export type EventsAndListeners = [string, EventListener][];\n\n/**\n * Adds a set of event listeners to the given target.\n * @param {EventsAndListeners} events - The events and listeners to add.\n * @param {Element | Window | Document} target - The target element or window to add the event listeners to.\n * @param {T} context - The class context to bind the event listeners to.\n */\nexport function addEventListeners<T>(\n events: EventsAndListeners,\n target: Element | Window | Document,\n context: T,\n) {\n events.forEach(([event, listener]) =>\n target.addEventListener(event, listener.bind(context)),\n );\n}\n\n/**\n * Removes a set of event listeners from the given target.\n * @param {EventsAndListeners} events - The events and listeners to remove.\n * @param {Element | Window | Document} target - The target element or window to remove the event listeners from.\n * @param {T} context - The class context to bind the event listeners to.\n */\nexport function removeEventListeners<T>(\n events: EventsAndListeners,\n target: Element | Window | Document,\n context: T,\n) {\n events.forEach(([event, listener]) =>\n target.removeEventListener(event, listener.bind(context)),\n );\n}\n"],"version":3}
|
|
@@ -409,8 +409,7 @@ const WeekNumbers = props => {
|
|
|
409
409
|
return () => handleWeekClick(week);
|
|
410
410
|
};
|
|
411
411
|
return (h("div", { class: "week-numbers" }, h("div", { class: "week-header" }, localizedWeekText), weeks.map((week, weekIndex) => {
|
|
412
|
-
|
|
413
|
-
const firstDayWithDate = ((_a = week.find(d => d.date)) === null || _a === void 0 ? void 0 : _a.date) || new Date();
|
|
412
|
+
const firstDayWithDate = week.find(d => d.date)?.date || new Date();
|
|
414
413
|
const weekNumber = getWeekNumber(firstDayWithDate);
|
|
415
414
|
const isClickable = selectionType === 'range';
|
|
416
415
|
return (h("div", { class: `week-number ${isClickable ? 'clickable' : ''}`, onClick: createWeekHandler(week), key: `week-${weekIndex}`, role: isClickable ? 'button' : undefined, tabindex: isClickable ? 0 : undefined }, weekNumber));
|
|
@@ -644,7 +643,7 @@ const NvCalendar = /*@__PURE__*/ proxyCustomElement(class NvCalendar extends H {
|
|
|
644
643
|
}
|
|
645
644
|
else {
|
|
646
645
|
// Handle malformed dates gracefully - reset state
|
|
647
|
-
console.warn(`Invalid date range format: ${values
|
|
646
|
+
console.warn(`Invalid date range format: ${values?.[0]}, ${values?.[1]}`);
|
|
648
647
|
this.startDate = null;
|
|
649
648
|
this.endDate = null;
|
|
650
649
|
if (!this.showActions) {
|
|
@@ -922,26 +921,17 @@ const NvCalendar = /*@__PURE__*/ proxyCustomElement(class NvCalendar extends H {
|
|
|
922
921
|
this.handleMonthChange = (event, calendarOffset = 0) => {
|
|
923
922
|
const select = event.target;
|
|
924
923
|
const selectedMonth = parseInt(select.value, 10);
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
924
|
+
// Calculate the current displayed year for this specific calendar
|
|
925
|
+
const targetCalendarDate = new Date(this.currentDate);
|
|
926
|
+
targetCalendarDate.setUTCDate(1);
|
|
928
927
|
targetCalendarDate.setUTCMonth(targetCalendarDate.getUTCMonth() + calendarOffset);
|
|
929
|
-
const
|
|
930
|
-
|
|
931
|
-
//
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
if (monthDiff < -6) {
|
|
937
|
-
// e.g. from Dec to Jan, go forward 1 month
|
|
938
|
-
monthDiff += 12;
|
|
939
|
-
}
|
|
940
|
-
// Apply the diff to the original `currentDate`
|
|
941
|
-
const finalDate = new Date(this.currentDate);
|
|
942
|
-
// Avoid day-of-month rollover when moving to shorter months.
|
|
943
|
-
finalDate.setUTCDate(1);
|
|
944
|
-
finalDate.setUTCMonth(finalDate.getUTCMonth() + monthDiff);
|
|
928
|
+
const currentYear = targetCalendarDate.getUTCFullYear();
|
|
929
|
+
// Create a new date with the selected month, keeping the SAME year
|
|
930
|
+
// This ensures the year never changes when selecting a month
|
|
931
|
+
const newTargetDate = new Date(Date.UTC(currentYear, selectedMonth, 1));
|
|
932
|
+
// Calculate what currentDate should be by subtracting the offset
|
|
933
|
+
const finalDate = new Date(newTargetDate);
|
|
934
|
+
finalDate.setUTCMonth(finalDate.getUTCMonth() - calendarOffset);
|
|
945
935
|
this.currentDate = finalDate;
|
|
946
936
|
};
|
|
947
937
|
/**
|
|
@@ -1420,8 +1410,8 @@ const NvCalendar = /*@__PURE__*/ proxyCustomElement(class NvCalendar extends H {
|
|
|
1420
1410
|
* @slot default - Child content of the component.
|
|
1421
1411
|
*/
|
|
1422
1412
|
render() {
|
|
1423
|
-
return (h(Host, { key: '
|
|
1424
|
-
this.hasActions) && (h("div", { key: '
|
|
1413
|
+
return (h(Host, { key: '18793334c6b01685f8c42acb0709bb3b35a1d466' }, h("div", { key: '2fa622b5027d4fc94732e0826fac044056e8bca1', class: "datepicker-root" }, h("div", { key: '4c88d823b5a720d3529bc199014b5e498ba1a701', class: `datepicker-container ${this.numberOfCalendars === 1 ? 'datepicker-container-single' : ''}` }, h("div", { key: 'e6be82fb79db589171e4db2beb640fb005dd603f', class: `datepicker-wrapper ${this.numberOfCalendars === 1 ? 'single' : ''}` }, this.shortcutsPlacement === 'left' && this.renderShortcuts(), Array.from({ length: this.numberOfCalendars }, (_, index) => this.renderCalendar(index, index)), this.shortcutsPlacement === 'right' && this.renderShortcuts()), ((this.hasShortcuts && this.shortcutsPlacement === 'bottom') ||
|
|
1414
|
+
this.hasActions) && (h("div", { key: '5991593c0ae9128c3dfea099db2864a37105c9a4', class: "datepicker-controls" }, this.shortcutsPlacement === 'bottom' && this.renderShortcuts(), this.hasActions && this.renderActions())))), h("slot", { key: '5e92296fdc3732ea7f241a5ce381e0234330e7a3' })));
|
|
1425
1415
|
}
|
|
1426
1416
|
get el() { return this; }
|
|
1427
1417
|
static get watchers() { return {
|
|
@@ -1480,6 +1470,6 @@ function defineCustomElement() {
|
|
|
1480
1470
|
defineCustomElement();
|
|
1481
1471
|
|
|
1482
1472
|
export { NvCalendar as N, defineCustomElement as d, getDefaultExportFromCjs as g };
|
|
1483
|
-
//# sourceMappingURL=p-
|
|
1473
|
+
//# sourceMappingURL=p-B7VlEQVW.js.map
|
|
1484
1474
|
|
|
1485
|
-
//# sourceMappingURL=p-
|
|
1475
|
+
//# sourceMappingURL=p-B7VlEQVW.js.map
|