@nextcloud/vue 8.24.0 → 8.25.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/CHANGELOG.md +43 -0
- package/README.md +2 -2
- package/dist/Components/NcActionButton.cjs +1 -1
- package/dist/Components/NcActionButton.mjs +1 -1
- package/dist/Components/NcActionButtonGroup.cjs +1 -1
- package/dist/Components/NcActionButtonGroup.mjs +1 -1
- package/dist/Components/NcActionInput.cjs +1 -1
- package/dist/Components/NcActionInput.mjs +1 -1
- package/dist/Components/NcActions.cjs +1 -1
- package/dist/Components/NcActions.mjs +1 -1
- package/dist/Components/NcAppContent.cjs +1 -1
- package/dist/Components/NcAppContent.mjs +1 -1
- package/dist/Components/NcAppNavigation.cjs +1 -1
- package/dist/Components/NcAppNavigation.mjs +1 -1
- package/dist/Components/NcAppNavigationCaption.cjs +1 -1
- package/dist/Components/NcAppNavigationCaption.mjs +1 -1
- package/dist/Components/NcAppNavigationItem.cjs +1 -1
- package/dist/Components/NcAppNavigationItem.mjs +1 -1
- package/dist/Components/NcAppNavigationNewItem.cjs +1 -1
- package/dist/Components/NcAppNavigationNewItem.mjs +1 -1
- package/dist/Components/NcAppNavigationSearch.cjs +1 -1
- package/dist/Components/NcAppNavigationSearch.mjs +1 -1
- package/dist/Components/NcAppNavigationSettings.cjs +1 -1
- package/dist/Components/NcAppNavigationSettings.mjs +1 -1
- package/dist/Components/NcAppNavigationToggle.cjs +1 -1
- package/dist/Components/NcAppNavigationToggle.mjs +1 -1
- package/dist/Components/NcAppSettingsDialog.cjs +1 -1
- package/dist/Components/NcAppSettingsDialog.mjs +1 -1
- package/dist/Components/NcAppSidebar.cjs +1 -1
- package/dist/Components/NcAppSidebar.mjs +1 -1
- package/dist/Components/NcAvatar.cjs +1 -1
- package/dist/Components/NcAvatar.mjs +1 -1
- package/dist/Components/NcBreadcrumb.cjs +1 -1
- package/dist/Components/NcBreadcrumb.mjs +1 -1
- package/dist/Components/NcBreadcrumbs.cjs +1 -1
- package/dist/Components/NcBreadcrumbs.mjs +1 -1
- package/dist/Components/NcCheckboxRadioSwitch.cjs +1 -1
- package/dist/Components/NcCheckboxRadioSwitch.mjs +1 -1
- package/dist/Components/NcChip.cjs +6 -6
- package/dist/Components/NcChip.cjs.map +1 -1
- package/dist/Components/NcChip.mjs +5 -5
- package/dist/Components/NcChip.mjs.map +1 -1
- package/dist/Components/NcCollectionList.cjs +1 -1
- package/dist/Components/NcCollectionList.mjs +1 -1
- package/dist/Components/NcColorPicker.cjs +1 -1
- package/dist/Components/NcColorPicker.mjs +1 -1
- package/dist/Components/NcContent.cjs +1 -1
- package/dist/Components/NcContent.mjs +1 -1
- package/dist/Components/NcDashboardWidget.cjs +1 -1
- package/dist/Components/NcDashboardWidget.mjs +1 -1
- package/dist/Components/NcDashboardWidgetItem.cjs +1 -1
- package/dist/Components/NcDashboardWidgetItem.mjs +1 -1
- package/dist/Components/NcDateTime.cjs +1 -1
- package/dist/Components/NcDateTime.mjs +1 -1
- package/dist/Components/NcDateTimePicker.cjs +47 -21
- package/dist/Components/NcDateTimePicker.cjs.map +1 -1
- package/dist/Components/NcDateTimePicker.mjs +47 -21
- package/dist/Components/NcDateTimePicker.mjs.map +1 -1
- package/dist/Components/NcDateTimePickerNative.cjs +1 -1
- package/dist/Components/NcDateTimePickerNative.mjs +1 -1
- package/dist/Components/NcDialog.cjs +1 -1
- package/dist/Components/NcDialog.mjs +1 -1
- package/dist/Components/NcDialogButton.cjs +1 -1
- package/dist/Components/NcDialogButton.mjs +1 -1
- package/dist/Components/NcEmojiPicker.cjs +1 -1
- package/dist/Components/NcEmojiPicker.mjs +1 -1
- package/dist/Components/NcIconSvgWrapper.cjs +1 -1
- package/dist/Components/NcIconSvgWrapper.mjs +1 -1
- package/dist/Components/NcListItem.cjs +1 -1
- package/dist/Components/NcListItem.mjs +1 -1
- package/dist/Components/NcListItemIcon.cjs +1 -1
- package/dist/Components/NcListItemIcon.mjs +1 -1
- package/dist/Components/NcModal.cjs +21 -21
- package/dist/Components/NcModal.cjs.map +1 -1
- package/dist/Components/NcModal.mjs +21 -21
- package/dist/Components/NcModal.mjs.map +1 -1
- package/dist/Components/NcPasswordField.cjs +1 -1
- package/dist/Components/NcPasswordField.mjs +1 -1
- package/dist/Components/NcPopover.cjs +1 -1
- package/dist/Components/NcPopover.mjs +1 -1
- package/dist/Components/NcRelatedResourcesPanel.cjs +1 -1
- package/dist/Components/NcRelatedResourcesPanel.mjs +1 -1
- package/dist/Components/NcRichContenteditable.cjs +1 -1
- package/dist/Components/NcRichContenteditable.mjs +1 -1
- package/dist/Components/NcRichText.cjs +2 -2
- package/dist/Components/NcRichText.mjs +3 -3
- package/dist/Components/NcSelect.cjs +1 -1
- package/dist/Components/NcSelect.mjs +1 -1
- package/dist/Components/NcSelectTags.cjs +1 -1
- package/dist/Components/NcSelectTags.mjs +1 -1
- package/dist/Components/NcSelectUsers.cjs +4 -0
- package/dist/Components/NcSelectUsers.cjs.map +1 -0
- package/dist/Components/NcSelectUsers.mjs +5 -0
- package/dist/Components/NcSelectUsers.mjs.map +1 -0
- package/dist/Components/NcSettingsInputText.cjs +1 -1
- package/dist/Components/NcSettingsInputText.mjs +1 -1
- package/dist/Components/NcSettingsSection.cjs +1 -1
- package/dist/Components/NcSettingsSection.mjs +1 -1
- package/dist/Components/NcSettingsSelectGroup.cjs +1 -1
- package/dist/Components/NcSettingsSelectGroup.mjs +1 -1
- package/dist/Components/NcTextField.cjs +1 -1
- package/dist/Components/NcTextField.mjs +1 -1
- package/dist/Components/NcTimezonePicker.cjs +1 -1
- package/dist/Components/NcTimezonePicker.mjs +1 -1
- package/dist/Components/NcUserBubble.cjs +1 -1
- package/dist/Components/NcUserBubble.mjs +1 -1
- package/dist/Components/NcUserStatusIcon.cjs +1 -1
- package/dist/Components/NcUserStatusIcon.mjs +1 -1
- package/dist/Directives/Tooltip.cjs +1 -1
- package/dist/Directives/Tooltip.cjs.map +1 -1
- package/dist/Directives/Tooltip.mjs +4 -4
- package/dist/Directives/Tooltip.mjs.map +1 -1
- package/dist/Functions/reference.cjs +1 -1
- package/dist/Functions/reference.mjs +1 -1
- package/dist/Functions/usernameToColor.cjs +1 -1
- package/dist/Functions/usernameToColor.mjs +1 -1
- package/dist/assets/{NcAppContent-JfRwJlWK.css → NcAppContent-DswTJB9n.css} +4 -4
- package/dist/assets/{NcAvatar-Cc-2PM1F.css → NcAvatar-BvPk6o_F.css} +24 -24
- package/dist/assets/{NcDateTimePicker-D07hGMOZ.css → NcDateTimePicker-BY1UnUZM.css} +12 -12
- package/dist/assets/{NcIconSvgWrapper-BxyhLaB5.css → NcIconSvgWrapper-BiNW6Guv.css} +8 -4
- package/dist/assets/{NcModal-DXN1C02T.css → NcModal-BS5vtogq.css} +68 -69
- package/dist/assets/{NcPopover-DpakVVxI.css → NcPopover-CWwUNpmE.css} +9 -9
- package/dist/assets/{NcRichContenteditable-BV6g3dmd.css → NcRichContenteditable-CtPZudY6.css} +13 -10
- package/dist/assets/NcSelectUsers-BoxBQpbA.css +4 -0
- package/dist/assets/{Tooltip-DQ4Plm4r.css → Tooltip-C-QZMStp.css} +7 -9
- package/dist/chunks/{GenColors-CV4Niqso.cjs → GenColors-7bkY5Nwl.cjs} +2 -2
- package/dist/chunks/{GenColors-CV4Niqso.cjs.map → GenColors-7bkY5Nwl.cjs.map} +1 -1
- package/dist/chunks/{GenColors-NALDypHH.mjs → GenColors-S7frO84b.mjs} +2 -2
- package/dist/chunks/{GenColors-NALDypHH.mjs.map → GenColors-S7frO84b.mjs.map} +1 -1
- package/dist/chunks/{NcActionButton-ChQFsL4S.cjs → NcActionButton-CXeEXQLT.cjs} +37 -5
- package/dist/chunks/NcActionButton-CXeEXQLT.cjs.map +1 -0
- package/dist/chunks/{NcActionButton-BFxArTsE.mjs → NcActionButton-Gpv56vuS.mjs} +37 -5
- package/dist/chunks/NcActionButton-Gpv56vuS.mjs.map +1 -0
- package/dist/chunks/{NcActionButtonGroup-BSFS4BYN.cjs → NcActionButtonGroup-BMy3W9fG.cjs} +2 -2
- package/dist/chunks/{NcActionButtonGroup-BSFS4BYN.cjs.map → NcActionButtonGroup-BMy3W9fG.cjs.map} +1 -1
- package/dist/chunks/{NcActionButtonGroup-B5OcRwWQ.mjs → NcActionButtonGroup-BteTNhIn.mjs} +2 -2
- package/dist/chunks/{NcActionButtonGroup-B5OcRwWQ.mjs.map → NcActionButtonGroup-BteTNhIn.mjs.map} +1 -1
- package/dist/chunks/{NcActionInput-DghifYMn.cjs → NcActionInput-B-7FoLVy.cjs} +6 -6
- package/dist/chunks/{NcActionInput-DghifYMn.cjs.map → NcActionInput-B-7FoLVy.cjs.map} +1 -1
- package/dist/chunks/{NcActionInput-DXiL7Phe.mjs → NcActionInput-D-zf_ZR9.mjs} +6 -6
- package/dist/chunks/{NcActionInput-DXiL7Phe.mjs.map → NcActionInput-D-zf_ZR9.mjs.map} +1 -1
- package/dist/chunks/{NcActions-C_H0APKA.mjs → NcActions-Bkh3UMs3.mjs} +3 -3
- package/dist/chunks/{NcActions-C_H0APKA.mjs.map → NcActions-Bkh3UMs3.mjs.map} +1 -1
- package/dist/chunks/{NcActions-C_gPnk6X.cjs → NcActions-DFHXBqKC.cjs} +3 -3
- package/dist/chunks/{NcActions-C_gPnk6X.cjs.map → NcActions-DFHXBqKC.cjs.map} +1 -1
- package/dist/chunks/{NcAppContent-PC4RbdhU.cjs → NcAppContent-D__4-2XM.cjs} +8 -13
- package/dist/chunks/NcAppContent-D__4-2XM.cjs.map +1 -0
- package/dist/chunks/{NcAppContent-DiOscHZ8.mjs → NcAppContent-_x1Bvwg-.mjs} +8 -13
- package/dist/chunks/NcAppContent-_x1Bvwg-.mjs.map +1 -0
- package/dist/chunks/{NcAppNavigation-B9Dd0YBs.cjs → NcAppNavigation-DBfTz6qV.cjs} +2 -2
- package/dist/chunks/{NcAppNavigation-B9Dd0YBs.cjs.map → NcAppNavigation-DBfTz6qV.cjs.map} +1 -1
- package/dist/chunks/{NcAppNavigation-DD1CfV7A.mjs → NcAppNavigation-H8Gvbq5E.mjs} +2 -2
- package/dist/chunks/{NcAppNavigation-DD1CfV7A.mjs.map → NcAppNavigation-H8Gvbq5E.mjs.map} +1 -1
- package/dist/chunks/{NcAppNavigationCaption-8NN7iPkz.mjs → NcAppNavigationCaption-Dz7wVRDM.mjs} +2 -2
- package/dist/chunks/{NcAppNavigationCaption-8NN7iPkz.mjs.map → NcAppNavigationCaption-Dz7wVRDM.mjs.map} +1 -1
- package/dist/chunks/{NcAppNavigationCaption-CuKecXh9.cjs → NcAppNavigationCaption-Kjwx7t2O.cjs} +2 -2
- package/dist/chunks/{NcAppNavigationCaption-CuKecXh9.cjs.map → NcAppNavigationCaption-Kjwx7t2O.cjs.map} +1 -1
- package/dist/chunks/{NcAppNavigationItem-B2LzgJUC.cjs → NcAppNavigationItem-CHa42b-x.cjs} +6 -6
- package/dist/chunks/{NcAppNavigationItem-B2LzgJUC.cjs.map → NcAppNavigationItem-CHa42b-x.cjs.map} +1 -1
- package/dist/chunks/{NcAppNavigationItem-B50v2lmS.mjs → NcAppNavigationItem-Dpm3T1dA.mjs} +6 -6
- package/dist/chunks/{NcAppNavigationItem-B50v2lmS.mjs.map → NcAppNavigationItem-Dpm3T1dA.mjs.map} +1 -1
- package/dist/chunks/{NcAppNavigationNewItem-bRz_V5Y1.cjs → NcAppNavigationNewItem-BLek0JRU.cjs} +2 -2
- package/dist/chunks/{NcAppNavigationNewItem-bRz_V5Y1.cjs.map → NcAppNavigationNewItem-BLek0JRU.cjs.map} +1 -1
- package/dist/chunks/{NcAppNavigationNewItem-B7_0fFTF.mjs → NcAppNavigationNewItem-DGjgp78o.mjs} +2 -2
- package/dist/chunks/{NcAppNavigationNewItem-B7_0fFTF.mjs.map → NcAppNavigationNewItem-DGjgp78o.mjs.map} +1 -1
- package/dist/chunks/{NcAppNavigationSearch-B-HqHu3j.cjs → NcAppNavigationSearch-BblolNaS.cjs} +3 -3
- package/dist/chunks/{NcAppNavigationSearch-B-HqHu3j.cjs.map → NcAppNavigationSearch-BblolNaS.cjs.map} +1 -1
- package/dist/chunks/{NcAppNavigationSearch-ChGonQL8.mjs → NcAppNavigationSearch-DTW6CtnU.mjs} +3 -3
- package/dist/chunks/{NcAppNavigationSearch-ChGonQL8.mjs.map → NcAppNavigationSearch-DTW6CtnU.mjs.map} +1 -1
- package/dist/chunks/{NcAppNavigationSettings-9nG2gY_9.mjs → NcAppNavigationSettings-C0QuEMmn.mjs} +3 -3
- package/dist/chunks/{NcAppNavigationSettings-9nG2gY_9.mjs.map → NcAppNavigationSettings-C0QuEMmn.mjs.map} +1 -1
- package/dist/chunks/{NcAppNavigationSettings-C--IJ1A2.cjs → NcAppNavigationSettings-lfJvt3vG.cjs} +3 -3
- package/dist/chunks/{NcAppNavigationSettings-C--IJ1A2.cjs.map → NcAppNavigationSettings-lfJvt3vG.cjs.map} +1 -1
- package/dist/chunks/{NcAppNavigationToggle-FxOt_DlD.cjs → NcAppNavigationToggle-CUGOWggc.cjs} +2 -2
- package/dist/chunks/{NcAppNavigationToggle-FxOt_DlD.cjs.map → NcAppNavigationToggle-CUGOWggc.cjs.map} +1 -1
- package/dist/chunks/{NcAppNavigationToggle-CJ5N3NI4.mjs → NcAppNavigationToggle-CjPJB2s3.mjs} +2 -2
- package/dist/chunks/{NcAppNavigationToggle-CJ5N3NI4.mjs.map → NcAppNavigationToggle-CjPJB2s3.mjs.map} +1 -1
- package/dist/chunks/{NcAppSettingsDialog-C2rBRxUv.mjs → NcAppSettingsDialog-Dl-kMSpe.mjs} +4 -4
- package/dist/chunks/{NcAppSettingsDialog-C2rBRxUv.mjs.map → NcAppSettingsDialog-Dl-kMSpe.mjs.map} +1 -1
- package/dist/chunks/{NcAppSettingsDialog-CSLft-a9.cjs → NcAppSettingsDialog-K3yVenLs.cjs} +4 -4
- package/dist/chunks/{NcAppSettingsDialog-CSLft-a9.cjs.map → NcAppSettingsDialog-K3yVenLs.cjs.map} +1 -1
- package/dist/chunks/{NcAppSidebar-DVvZYd17.cjs → NcAppSidebar-Bmlid_Pa.cjs} +4 -4
- package/dist/chunks/{NcAppSidebar-DVvZYd17.cjs.map → NcAppSidebar-Bmlid_Pa.cjs.map} +1 -1
- package/dist/chunks/{NcAppSidebar-19hVcGhv.mjs → NcAppSidebar-DOJNq1iG.mjs} +4 -4
- package/dist/chunks/{NcAppSidebar-19hVcGhv.mjs.map → NcAppSidebar-DOJNq1iG.mjs.map} +1 -1
- package/dist/chunks/{NcAvatar--JVA_B6Y.cjs → NcAvatar-Bp1wPu2I.cjs} +12 -14
- package/dist/chunks/{NcAvatar--JVA_B6Y.cjs.map → NcAvatar-Bp1wPu2I.cjs.map} +1 -1
- package/dist/chunks/{NcAvatar-DwORvUjC.mjs → NcAvatar-DOvpF1gr.mjs} +12 -14
- package/dist/chunks/{NcAvatar-DwORvUjC.mjs.map → NcAvatar-DOvpF1gr.mjs.map} +1 -1
- package/dist/chunks/{NcBreadcrumb-DPF3ELzz.mjs → NcBreadcrumb-1Gv4FRrG.mjs} +2 -2
- package/dist/chunks/{NcBreadcrumb-DPF3ELzz.mjs.map → NcBreadcrumb-1Gv4FRrG.mjs.map} +1 -1
- package/dist/chunks/{NcBreadcrumb-B0ve-OJl.cjs → NcBreadcrumb-9pV_jqex.cjs} +2 -2
- package/dist/chunks/{NcBreadcrumb-B0ve-OJl.cjs.map → NcBreadcrumb-9pV_jqex.cjs.map} +1 -1
- package/dist/chunks/{NcBreadcrumbs-CL_IHuT9.mjs → NcBreadcrumbs-CwuR-hUE.mjs} +4 -4
- package/dist/chunks/{NcBreadcrumbs-CL_IHuT9.mjs.map → NcBreadcrumbs-CwuR-hUE.mjs.map} +1 -1
- package/dist/chunks/{NcBreadcrumbs-C_XQLT-h.cjs → NcBreadcrumbs-D4RrS0HT.cjs} +4 -4
- package/dist/chunks/{NcBreadcrumbs-C_XQLT-h.cjs.map → NcBreadcrumbs-D4RrS0HT.cjs.map} +1 -1
- package/dist/chunks/{NcCheckboxRadioSwitch-DOxX6fqr.cjs → NcCheckboxRadioSwitch-DbK49DI7.cjs} +2 -2
- package/dist/chunks/{NcCheckboxRadioSwitch-DOxX6fqr.cjs.map → NcCheckboxRadioSwitch-DbK49DI7.cjs.map} +1 -1
- package/dist/chunks/{NcCheckboxRadioSwitch-BaMf0PDd.mjs → NcCheckboxRadioSwitch-Di9rSADK.mjs} +2 -2
- package/dist/chunks/{NcCheckboxRadioSwitch-BaMf0PDd.mjs.map → NcCheckboxRadioSwitch-Di9rSADK.mjs.map} +1 -1
- package/dist/chunks/{NcCollectionList-DyZNTQFW.cjs → NcCollectionList-C3QKgLIe.cjs} +6 -6
- package/dist/chunks/{NcCollectionList-DyZNTQFW.cjs.map → NcCollectionList-C3QKgLIe.cjs.map} +1 -1
- package/dist/chunks/{NcCollectionList-iHUm6owG.mjs → NcCollectionList-D51FpJCr.mjs} +6 -6
- package/dist/chunks/{NcCollectionList-iHUm6owG.mjs.map → NcCollectionList-D51FpJCr.mjs.map} +1 -1
- package/dist/chunks/{NcColorPicker-CKIoVhox.cjs → NcColorPicker-9BNg5lJ0.cjs} +4 -4
- package/dist/chunks/{NcColorPicker-CKIoVhox.cjs.map → NcColorPicker-9BNg5lJ0.cjs.map} +1 -1
- package/dist/chunks/{NcColorPicker-av-NHSU7.mjs → NcColorPicker-sJKL33GV.mjs} +4 -4
- package/dist/chunks/{NcColorPicker-av-NHSU7.mjs.map → NcColorPicker-sJKL33GV.mjs.map} +1 -1
- package/dist/chunks/{NcContent-EFEXh_OO.cjs → NcContent-4X_oNYtW.cjs} +3 -3
- package/dist/chunks/{NcContent-EFEXh_OO.cjs.map → NcContent-4X_oNYtW.cjs.map} +1 -1
- package/dist/chunks/{NcContent-uiwRXAwA.mjs → NcContent-BHl5YDYI.mjs} +3 -3
- package/dist/chunks/{NcContent-uiwRXAwA.mjs.map → NcContent-BHl5YDYI.mjs.map} +1 -1
- package/dist/chunks/{NcDashboardWidget-3kbcJvFx.cjs → NcDashboardWidget-B1och7uR.cjs} +4 -4
- package/dist/chunks/{NcDashboardWidget-3kbcJvFx.cjs.map → NcDashboardWidget-B1och7uR.cjs.map} +1 -1
- package/dist/chunks/{NcDashboardWidget-DDaM0QjK.mjs → NcDashboardWidget-CioEwUfN.mjs} +4 -4
- package/dist/chunks/{NcDashboardWidget-DDaM0QjK.mjs.map → NcDashboardWidget-CioEwUfN.mjs.map} +1 -1
- package/dist/chunks/{NcDashboardWidgetItem-DOzM3reO.cjs → NcDashboardWidgetItem-BZPoOCWQ.cjs} +4 -4
- package/dist/chunks/{NcDashboardWidgetItem-DOzM3reO.cjs.map → NcDashboardWidgetItem-BZPoOCWQ.cjs.map} +1 -1
- package/dist/chunks/{NcDashboardWidgetItem-C44gZwCP.mjs → NcDashboardWidgetItem-D4EefvnL.mjs} +4 -4
- package/dist/chunks/{NcDashboardWidgetItem-C44gZwCP.mjs.map → NcDashboardWidgetItem-D4EefvnL.mjs.map} +1 -1
- package/dist/chunks/{NcDateTime-BfJVNppR.mjs → NcDateTime-BR6BBvML.mjs} +2 -2
- package/dist/chunks/{NcDateTime-BfJVNppR.mjs.map → NcDateTime-BR6BBvML.mjs.map} +1 -1
- package/dist/chunks/{NcDateTime-DNnBHGEQ.cjs → NcDateTime-C-kLQayi.cjs} +2 -2
- package/dist/chunks/{NcDateTime-DNnBHGEQ.cjs.map → NcDateTime-C-kLQayi.cjs.map} +1 -1
- package/dist/chunks/{NcDialog-DbCdhtw7.cjs → NcDialog-BjLJB7fW.cjs} +2 -2
- package/dist/chunks/{NcDialog-DbCdhtw7.cjs.map → NcDialog-BjLJB7fW.cjs.map} +1 -1
- package/dist/chunks/{NcDialog-D3Z5tp_6.mjs → NcDialog-D2lwwZL-.mjs} +2 -2
- package/dist/chunks/{NcDialog-D3Z5tp_6.mjs.map → NcDialog-D2lwwZL-.mjs.map} +1 -1
- package/dist/chunks/{NcDialogButton-BhPydgMe.mjs → NcDialogButton-BB56HcBl.mjs} +3 -3
- package/dist/chunks/{NcDialogButton-BhPydgMe.mjs.map → NcDialogButton-BB56HcBl.mjs.map} +1 -1
- package/dist/chunks/{NcDialogButton-CYsTKE2g.cjs → NcDialogButton-ByvLH63s.cjs} +3 -3
- package/dist/chunks/{NcDialogButton-CYsTKE2g.cjs.map → NcDialogButton-ByvLH63s.cjs.map} +1 -1
- package/dist/chunks/{NcEmojiPicker-C5HYxVqp.mjs → NcEmojiPicker-B49sJeMw.mjs} +7 -7
- package/dist/chunks/{NcEmojiPicker-C5HYxVqp.mjs.map → NcEmojiPicker-B49sJeMw.mjs.map} +1 -1
- package/dist/chunks/{NcEmojiPicker-DPHhky3J.cjs → NcEmojiPicker-DcTSImTm.cjs} +7 -7
- package/dist/chunks/{NcEmojiPicker-DPHhky3J.cjs.map → NcEmojiPicker-DcTSImTm.cjs.map} +1 -1
- package/dist/chunks/{NcIconSvgWrapper-B_eOG2sZ.cjs → NcIconSvgWrapper-BlucK1g3.cjs} +27 -16
- package/dist/chunks/NcIconSvgWrapper-BlucK1g3.cjs.map +1 -0
- package/dist/chunks/{NcIconSvgWrapper-CHmdAuhg.mjs → NcIconSvgWrapper-RKuZn260.mjs} +28 -17
- package/dist/chunks/NcIconSvgWrapper-RKuZn260.mjs.map +1 -0
- package/dist/chunks/{NcInputConfirmCancel-CvV0tE6s.mjs → NcInputConfirmCancel-CacBXLGS.mjs} +2 -2
- package/dist/chunks/{NcInputConfirmCancel-CvV0tE6s.mjs.map → NcInputConfirmCancel-CacBXLGS.mjs.map} +1 -1
- package/dist/chunks/{NcInputConfirmCancel-DRhv_CTt.cjs → NcInputConfirmCancel-lVLFwBA4.cjs} +2 -2
- package/dist/chunks/{NcInputConfirmCancel-DRhv_CTt.cjs.map → NcInputConfirmCancel-lVLFwBA4.cjs.map} +1 -1
- package/dist/chunks/{NcListItem-CA4CzIW8.mjs → NcListItem-BBTd7BLc.mjs} +2 -2
- package/dist/chunks/{NcListItem-CA4CzIW8.mjs.map → NcListItem-BBTd7BLc.mjs.map} +1 -1
- package/dist/chunks/{NcListItem-D5XlkLgC.cjs → NcListItem-D_mvsnph.cjs} +2 -2
- package/dist/chunks/{NcListItem-D5XlkLgC.cjs.map → NcListItem-D_mvsnph.cjs.map} +1 -1
- package/dist/chunks/{NcListItemIcon-DhENqcJ-.mjs → NcListItemIcon-B16M-aHV.mjs} +3 -3
- package/dist/chunks/{NcListItemIcon-DhENqcJ-.mjs.map → NcListItemIcon-B16M-aHV.mjs.map} +1 -1
- package/dist/chunks/{NcListItemIcon-DIJ0vvYv.cjs → NcListItemIcon-COUzDQI5.cjs} +3 -3
- package/dist/chunks/{NcListItemIcon-DIJ0vvYv.cjs.map → NcListItemIcon-COUzDQI5.cjs.map} +1 -1
- package/dist/chunks/{NcPasswordField-DXJ93Wpz.cjs → NcPasswordField-BCzIotoB.cjs} +2 -2
- package/dist/chunks/{NcPasswordField-DXJ93Wpz.cjs.map → NcPasswordField-BCzIotoB.cjs.map} +1 -1
- package/dist/chunks/{NcPasswordField-zMKko5oa.mjs → NcPasswordField-CTKHRVC4.mjs} +2 -2
- package/dist/chunks/{NcPasswordField-zMKko5oa.mjs.map → NcPasswordField-CTKHRVC4.mjs.map} +1 -1
- package/dist/chunks/{NcPopover-CA2Dalxs.cjs → NcPopover-BxLo6SFb.cjs} +2 -2
- package/dist/chunks/{NcPopover-CA2Dalxs.cjs.map → NcPopover-BxLo6SFb.cjs.map} +1 -1
- package/dist/chunks/{NcPopover-C9KlPo4Z.mjs → NcPopover-w98cBbbF.mjs} +2 -2
- package/dist/chunks/{NcPopover-C9KlPo4Z.mjs.map → NcPopover-w98cBbbF.mjs.map} +1 -1
- package/dist/chunks/{NcRelatedResourcesPanel-X4vhm8hy.cjs → NcRelatedResourcesPanel-B-y_Wan4.cjs} +5 -5
- package/dist/chunks/{NcRelatedResourcesPanel-X4vhm8hy.cjs.map → NcRelatedResourcesPanel-B-y_Wan4.cjs.map} +1 -1
- package/dist/chunks/{NcRelatedResourcesPanel-BxBE_1N3.mjs → NcRelatedResourcesPanel-CmiW_ds0.mjs} +5 -5
- package/dist/chunks/{NcRelatedResourcesPanel-BxBE_1N3.mjs.map → NcRelatedResourcesPanel-CmiW_ds0.mjs.map} +1 -1
- package/dist/chunks/{NcRichContenteditable-CC4jGcJn.cjs → NcRichContenteditable-ClHXIiXL.cjs} +12 -21
- package/dist/chunks/NcRichContenteditable-ClHXIiXL.cjs.map +1 -0
- package/dist/chunks/{NcRichContenteditable-Ct8cG0U6.mjs → NcRichContenteditable-zZQChT9M.mjs} +12 -21
- package/dist/chunks/NcRichContenteditable-zZQChT9M.mjs.map +1 -0
- package/dist/chunks/{NcRichText-h1RHm2bK.mjs → NcRichText-C43cKGcR.mjs} +3 -3
- package/dist/chunks/{NcRichText-h1RHm2bK.mjs.map → NcRichText-C43cKGcR.mjs.map} +1 -1
- package/dist/chunks/{NcRichText-Ck9Sk6wk.cjs → NcRichText-CMbtZkLP.cjs} +3 -3
- package/dist/chunks/{NcRichText-Ck9Sk6wk.cjs.map → NcRichText-CMbtZkLP.cjs.map} +1 -1
- package/dist/chunks/{NcSelect-vJq9dZPb.cjs → NcSelect-C9cGa-5v.cjs} +25 -8
- package/dist/chunks/NcSelect-C9cGa-5v.cjs.map +1 -0
- package/dist/chunks/{NcSelect-DrtYueu1.mjs → NcSelect-XLdUgokz.mjs} +25 -8
- package/dist/chunks/NcSelect-XLdUgokz.mjs.map +1 -0
- package/dist/chunks/{NcSelectTags-DvVm-C1N.cjs → NcSelectTags-B0rsXdxP.cjs} +3 -3
- package/dist/chunks/{NcSelectTags-DvVm-C1N.cjs.map → NcSelectTags-B0rsXdxP.cjs.map} +1 -1
- package/dist/chunks/{NcSelectTags--4zU4C41.mjs → NcSelectTags-DT2Y3Kms.mjs} +3 -3
- package/dist/chunks/{NcSelectTags--4zU4C41.mjs.map → NcSelectTags-DT2Y3Kms.mjs.map} +1 -1
- package/dist/chunks/NcSelectUsers-C-bbm2cW.cjs +187 -0
- package/dist/chunks/NcSelectUsers-C-bbm2cW.cjs.map +1 -0
- package/dist/chunks/NcSelectUsers-DFlj_h9t.mjs +188 -0
- package/dist/chunks/NcSelectUsers-DFlj_h9t.mjs.map +1 -0
- package/dist/chunks/{NcSettingsInputText-8EcoOEIo.cjs → NcSettingsInputText-BU1_SHOq.cjs} +3 -3
- package/dist/chunks/{NcSettingsInputText-8EcoOEIo.cjs.map → NcSettingsInputText-BU1_SHOq.cjs.map} +1 -1
- package/dist/chunks/{NcSettingsInputText-DKscbkn_.mjs → NcSettingsInputText-t1FMnLKA.mjs} +3 -3
- package/dist/chunks/{NcSettingsInputText-DKscbkn_.mjs.map → NcSettingsInputText-t1FMnLKA.mjs.map} +1 -1
- package/dist/chunks/{NcSettingsSection-DW5u2qWg.cjs → NcSettingsSection-Dcdxs1IN.cjs} +2 -2
- package/dist/chunks/{NcSettingsSection-DW5u2qWg.cjs.map → NcSettingsSection-Dcdxs1IN.cjs.map} +1 -1
- package/dist/chunks/{NcSettingsSection-DP3xDXrA.mjs → NcSettingsSection-EC3SmiDX.mjs} +2 -2
- package/dist/chunks/{NcSettingsSection-DP3xDXrA.mjs.map → NcSettingsSection-EC3SmiDX.mjs.map} +1 -1
- package/dist/chunks/{NcSettingsSelectGroup-DHuru8HO.mjs → NcSettingsSelectGroup-B4isXyUU.mjs} +4 -4
- package/dist/chunks/{NcSettingsSelectGroup-DHuru8HO.mjs.map → NcSettingsSelectGroup-B4isXyUU.mjs.map} +1 -1
- package/dist/chunks/{NcSettingsSelectGroup-DmnTgIg5.cjs → NcSettingsSelectGroup-CE71MIQo.cjs} +4 -4
- package/dist/chunks/{NcSettingsSelectGroup-DmnTgIg5.cjs.map → NcSettingsSelectGroup-CE71MIQo.cjs.map} +1 -1
- package/dist/chunks/{NcTextField-DpLIIKYI.mjs → NcTextField-DRANdaIf.mjs} +3 -3
- package/dist/chunks/{NcTextField-DpLIIKYI.mjs.map → NcTextField-DRANdaIf.mjs.map} +1 -1
- package/dist/chunks/{NcTextField-rilWP68p.cjs → NcTextField-Uk5iD8o2.cjs} +3 -3
- package/dist/chunks/{NcTextField-rilWP68p.cjs.map → NcTextField-Uk5iD8o2.cjs.map} +1 -1
- package/dist/chunks/{NcTimezonePicker-CQkZVQOW.cjs → NcTimezonePicker-BTyhPxMT.cjs} +4 -4
- package/dist/chunks/{NcTimezonePicker-CQkZVQOW.cjs.map → NcTimezonePicker-BTyhPxMT.cjs.map} +1 -1
- package/dist/chunks/{NcTimezonePicker-CGuLj6Bs.mjs → NcTimezonePicker-sAG8kn1b.mjs} +4 -4
- package/dist/chunks/{NcTimezonePicker-CGuLj6Bs.mjs.map → NcTimezonePicker-sAG8kn1b.mjs.map} +1 -1
- package/dist/chunks/{NcUserBubble-X7NIiLjg.mjs → NcUserBubble-DmZZOMRr.mjs} +3 -3
- package/dist/chunks/{NcUserBubble-X7NIiLjg.mjs.map → NcUserBubble-DmZZOMRr.mjs.map} +1 -1
- package/dist/chunks/{NcUserBubble-Du4ecEXq.cjs → NcUserBubble-cX4wyq1_.cjs} +3 -3
- package/dist/chunks/{NcUserBubble-Du4ecEXq.cjs.map → NcUserBubble-cX4wyq1_.cjs.map} +1 -1
- package/dist/chunks/{NcUserStatusIcon-D1Mw6nKB.mjs → NcUserStatusIcon-WEKmuaoU.mjs} +3 -3
- package/dist/chunks/{NcUserStatusIcon-D1Mw6nKB.mjs.map → NcUserStatusIcon-WEKmuaoU.mjs.map} +1 -1
- package/dist/chunks/{NcUserStatusIcon-Cy942iqr.cjs → NcUserStatusIcon-cs42Lzdd.cjs} +3 -3
- package/dist/chunks/{NcUserStatusIcon-Cy942iqr.cjs.map → NcUserStatusIcon-cs42Lzdd.cjs.map} +1 -1
- package/dist/chunks/{ScopeComponent-Dw8Duyxn.mjs → ScopeComponent-BaHwjQGQ.mjs} +2 -2
- package/dist/chunks/{ScopeComponent-Dw8Duyxn.mjs.map → ScopeComponent-BaHwjQGQ.mjs.map} +1 -1
- package/dist/chunks/{ScopeComponent-Uz_pNcsJ.cjs → ScopeComponent-CqVh6vwk.cjs} +2 -2
- package/dist/chunks/{ScopeComponent-Uz_pNcsJ.cjs.map → ScopeComponent-CqVh6vwk.cjs.map} +1 -1
- package/dist/chunks/{_l10n-DINju8Lo.cjs → _l10n-BiiXtYiP.cjs} +22 -18
- package/dist/chunks/{_l10n-DINju8Lo.cjs.map → _l10n-BiiXtYiP.cjs.map} +1 -1
- package/dist/chunks/{_l10n-DKne-gFg.mjs → _l10n-Dt0m9Fxw.mjs} +70 -66
- package/dist/chunks/_l10n-Dt0m9Fxw.mjs.map +1 -0
- package/dist/chunks/mdi-CZJxQPz6.mjs +9 -0
- package/dist/chunks/mdi-CZJxQPz6.mjs.map +1 -0
- package/dist/chunks/mdi-Da9VuUVq.cjs +8 -0
- package/dist/chunks/mdi-Da9VuUVq.cjs.map +1 -0
- package/dist/chunks/{referencePickerModal-CIO6RuJz.cjs → referencePickerModal-BdK-_zC6.cjs} +6 -6
- package/dist/chunks/{referencePickerModal-CIO6RuJz.cjs.map → referencePickerModal-BdK-_zC6.cjs.map} +1 -1
- package/dist/chunks/{referencePickerModal-DTLuXI-A.mjs → referencePickerModal-Bxp4FMcs.mjs} +6 -6
- package/dist/chunks/{referencePickerModal-DTLuXI-A.mjs.map → referencePickerModal-Bxp4FMcs.mjs.map} +1 -1
- package/dist/chunks/{usernameToColor-DLOoqQAF.mjs → usernameToColor-DJfepfog.mjs} +2 -2
- package/dist/chunks/{usernameToColor-DLOoqQAF.mjs.map → usernameToColor-DJfepfog.mjs.map} +1 -1
- package/dist/chunks/{usernameToColor-BiO_8cQo.cjs → usernameToColor-mqInDrGv.cjs} +2 -2
- package/dist/chunks/{usernameToColor-BiO_8cQo.cjs.map → usernameToColor-mqInDrGv.cjs.map} +1 -1
- package/dist/index.cjs +48 -45
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +50 -47
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/dist/chunks/ChevronLeft-BK4j9oVH.mjs +0 -38
- package/dist/chunks/ChevronLeft-BK4j9oVH.mjs.map +0 -1
- package/dist/chunks/ChevronLeft-CAiEPWc5.cjs +0 -37
- package/dist/chunks/ChevronLeft-CAiEPWc5.cjs.map +0 -1
- package/dist/chunks/NcActionButton-BFxArTsE.mjs.map +0 -1
- package/dist/chunks/NcActionButton-ChQFsL4S.cjs.map +0 -1
- package/dist/chunks/NcAppContent-DiOscHZ8.mjs.map +0 -1
- package/dist/chunks/NcAppContent-PC4RbdhU.cjs.map +0 -1
- package/dist/chunks/NcIconSvgWrapper-B_eOG2sZ.cjs.map +0 -1
- package/dist/chunks/NcIconSvgWrapper-CHmdAuhg.mjs.map +0 -1
- package/dist/chunks/NcRichContenteditable-CC4jGcJn.cjs.map +0 -1
- package/dist/chunks/NcRichContenteditable-Ct8cG0U6.mjs.map +0 -1
- package/dist/chunks/NcSelect-DrtYueu1.mjs.map +0 -1
- package/dist/chunks/NcSelect-vJq9dZPb.cjs.map +0 -1
- package/dist/chunks/_l10n-DKne-gFg.mjs.map +0 -1
package/dist/index.mjs
CHANGED
|
@@ -1,96 +1,97 @@
|
|
|
1
|
-
import { N as NcActionButton } from "./chunks/NcActionButton-
|
|
2
|
-
import { N as NcActionButtonGroup } from "./chunks/NcActionButtonGroup-
|
|
1
|
+
import { N as NcActionButton } from "./chunks/NcActionButton-Gpv56vuS.mjs";
|
|
2
|
+
import { N as NcActionButtonGroup } from "./chunks/NcActionButtonGroup-BteTNhIn.mjs";
|
|
3
3
|
import NcActionCaption from "./Components/NcActionCaption.mjs";
|
|
4
4
|
import { N as NcActionCheckbox } from "./chunks/NcActionCheckbox-DSMKeccY.mjs";
|
|
5
|
-
import { N as NcActionInput } from "./chunks/NcActionInput-
|
|
5
|
+
import { N as NcActionInput } from "./chunks/NcActionInput-D-zf_ZR9.mjs";
|
|
6
6
|
import NcActionLink from "./Components/NcActionLink.mjs";
|
|
7
7
|
import { N as NcActionRadio } from "./chunks/NcActionRadio-yAm71xxU.mjs";
|
|
8
8
|
import NcActionRouter from "./Components/NcActionRouter.mjs";
|
|
9
|
-
import { N as NcActions } from "./chunks/NcActions-
|
|
9
|
+
import { N as NcActions } from "./chunks/NcActions-Bkh3UMs3.mjs";
|
|
10
10
|
import NcActionSeparator from "./Components/NcActionSeparator.mjs";
|
|
11
11
|
import NcActionText from "./Components/NcActionText.mjs";
|
|
12
12
|
import { N as NcActionTextEditable } from "./chunks/NcActionTextEditable-BYqqHPj2.mjs";
|
|
13
|
-
import { N as NcAppContent } from "./chunks/NcAppContent-
|
|
13
|
+
import { N as NcAppContent } from "./chunks/NcAppContent-_x1Bvwg-.mjs";
|
|
14
14
|
import NcAppContentDetails from "./Components/NcAppContentDetails.mjs";
|
|
15
15
|
import NcAppContentList from "./Components/NcAppContentList.mjs";
|
|
16
|
-
import { N as NcAppNavigation } from "./chunks/NcAppNavigation-
|
|
17
|
-
import { N as NcAppNavigationCaption } from "./chunks/NcAppNavigationCaption-
|
|
16
|
+
import { N as NcAppNavigation } from "./chunks/NcAppNavigation-H8Gvbq5E.mjs";
|
|
17
|
+
import { N as NcAppNavigationCaption } from "./chunks/NcAppNavigationCaption-Dz7wVRDM.mjs";
|
|
18
18
|
import NcAppNavigationIconBullet from "./Components/NcAppNavigationIconBullet.mjs";
|
|
19
|
-
import { N as NcAppNavigationItem } from "./chunks/NcAppNavigationItem-
|
|
19
|
+
import { N as NcAppNavigationItem } from "./chunks/NcAppNavigationItem-Dpm3T1dA.mjs";
|
|
20
20
|
import NcAppNavigationList from "./Components/NcAppNavigationList.mjs";
|
|
21
21
|
import NcAppNavigationNew from "./Components/NcAppNavigationNew.mjs";
|
|
22
|
-
import { N as NcAppNavigationNewItem } from "./chunks/NcAppNavigationNewItem-
|
|
23
|
-
import { N as NcAppNavigationSearch } from "./chunks/NcAppNavigationSearch-
|
|
24
|
-
import { N as NcAppNavigationSettings } from "./chunks/NcAppNavigationSettings-
|
|
22
|
+
import { N as NcAppNavigationNewItem } from "./chunks/NcAppNavigationNewItem-DGjgp78o.mjs";
|
|
23
|
+
import { N as NcAppNavigationSearch } from "./chunks/NcAppNavigationSearch-DTW6CtnU.mjs";
|
|
24
|
+
import { N as NcAppNavigationSettings } from "./chunks/NcAppNavigationSettings-C0QuEMmn.mjs";
|
|
25
25
|
import NcAppNavigationSpacer from "./Components/NcAppNavigationSpacer.mjs";
|
|
26
|
-
import { N as NcAppSettingsDialog } from "./chunks/NcAppSettingsDialog-
|
|
26
|
+
import { N as NcAppSettingsDialog } from "./chunks/NcAppSettingsDialog-Dl-kMSpe.mjs";
|
|
27
27
|
import NcAppSettingsSection from "./Components/NcAppSettingsSection.mjs";
|
|
28
|
-
import { N as NcAppSidebar } from "./chunks/NcAppSidebar-
|
|
28
|
+
import { N as NcAppSidebar } from "./chunks/NcAppSidebar-DOJNq1iG.mjs";
|
|
29
29
|
import NcAppSidebarTab from "./Components/NcAppSidebarTab.mjs";
|
|
30
|
-
import { N as NcAvatar } from "./chunks/NcAvatar-
|
|
31
|
-
import { u } from "./chunks/NcAvatar-
|
|
30
|
+
import { N as NcAvatar } from "./chunks/NcAvatar-DOvpF1gr.mjs";
|
|
31
|
+
import { u } from "./chunks/NcAvatar-DOvpF1gr.mjs";
|
|
32
32
|
import { N as NcBlurHash } from "./chunks/NcBlurHash-do2wxY-0.mjs";
|
|
33
|
-
import { N as NcBreadcrumb } from "./chunks/NcBreadcrumb-
|
|
34
|
-
import { N as NcBreadcrumbs } from "./chunks/NcBreadcrumbs-
|
|
33
|
+
import { N as NcBreadcrumb } from "./chunks/NcBreadcrumb-1Gv4FRrG.mjs";
|
|
34
|
+
import { N as NcBreadcrumbs } from "./chunks/NcBreadcrumbs-CwuR-hUE.mjs";
|
|
35
35
|
import NcButton from "./Components/NcButton.mjs";
|
|
36
|
-
import { N as NcCheckboxRadioSwitch } from "./chunks/NcCheckboxRadioSwitch-
|
|
37
|
-
import { N as NcCollectionList } from "./chunks/NcCollectionList-
|
|
38
|
-
import { N as NcColorPicker } from "./chunks/NcColorPicker-
|
|
39
|
-
import { N as NcContent } from "./chunks/NcContent-
|
|
36
|
+
import { N as NcCheckboxRadioSwitch } from "./chunks/NcCheckboxRadioSwitch-Di9rSADK.mjs";
|
|
37
|
+
import { N as NcCollectionList } from "./chunks/NcCollectionList-D51FpJCr.mjs";
|
|
38
|
+
import { N as NcColorPicker } from "./chunks/NcColorPicker-sJKL33GV.mjs";
|
|
39
|
+
import { N as NcContent } from "./chunks/NcContent-BHl5YDYI.mjs";
|
|
40
40
|
import { N as NcCounterBubble } from "./chunks/NcCounterBubble-CDfRYl8B.mjs";
|
|
41
|
-
import { N as NcDashboardWidget } from "./chunks/NcDashboardWidget-
|
|
42
|
-
import { N as NcDashboardWidgetItem } from "./chunks/NcDashboardWidgetItem-
|
|
43
|
-
import { N as NcDateTime } from "./chunks/NcDateTime-
|
|
44
|
-
import { u as u2 } from "./chunks/NcDateTime-
|
|
41
|
+
import { N as NcDashboardWidget } from "./chunks/NcDashboardWidget-CioEwUfN.mjs";
|
|
42
|
+
import { N as NcDashboardWidgetItem } from "./chunks/NcDashboardWidgetItem-D4EefvnL.mjs";
|
|
43
|
+
import { N as NcDateTime } from "./chunks/NcDateTime-BR6BBvML.mjs";
|
|
44
|
+
import { u as u2 } from "./chunks/NcDateTime-BR6BBvML.mjs";
|
|
45
45
|
import NcDateTimePicker from "./Components/NcDateTimePicker.mjs";
|
|
46
46
|
import NcDateTimePickerNative from "./Components/NcDateTimePickerNative.mjs";
|
|
47
|
-
import { N as NcDialog } from "./chunks/NcDialog-
|
|
48
|
-
import { N as NcDialogButton } from "./chunks/NcDialogButton-
|
|
47
|
+
import { N as NcDialog } from "./chunks/NcDialog-D2lwwZL-.mjs";
|
|
48
|
+
import { N as NcDialogButton } from "./chunks/NcDialogButton-BB56HcBl.mjs";
|
|
49
49
|
import NcEllipsisedOption from "./Components/NcEllipsisedOption.mjs";
|
|
50
|
-
import { N as NcEmojiPicker } from "./chunks/NcEmojiPicker-
|
|
50
|
+
import { N as NcEmojiPicker } from "./chunks/NcEmojiPicker-B49sJeMw.mjs";
|
|
51
51
|
import NcEmptyContent from "./Components/NcEmptyContent.mjs";
|
|
52
52
|
import NcGuestContent from "./Components/NcGuestContent.mjs";
|
|
53
53
|
import NcHeaderButton from "./Components/NcHeaderButton.mjs";
|
|
54
54
|
import { N as NcHeaderMenu } from "./chunks/NcHeaderMenu-Bc1ucNsv.mjs";
|
|
55
55
|
import { N as NcHighlight } from "./chunks/index-Bz6q9mZw.mjs";
|
|
56
|
-
import { N as NcIconSvgWrapper } from "./chunks/NcIconSvgWrapper-
|
|
56
|
+
import { N as NcIconSvgWrapper } from "./chunks/NcIconSvgWrapper-RKuZn260.mjs";
|
|
57
57
|
import { N as NcInputField } from "./chunks/NcInputField-DTtUueUZ.mjs";
|
|
58
|
-
import { N as NcListItem } from "./chunks/NcListItem-
|
|
59
|
-
import { N as NcListItemIcon } from "./chunks/NcListItemIcon-
|
|
58
|
+
import { N as NcListItem } from "./chunks/NcListItem-BBTd7BLc.mjs";
|
|
59
|
+
import { N as NcListItemIcon } from "./chunks/NcListItemIcon-B16M-aHV.mjs";
|
|
60
60
|
import NcLoadingIcon from "./Components/NcLoadingIcon.mjs";
|
|
61
61
|
import NcModal from "./Components/NcModal.mjs";
|
|
62
62
|
import NcNoteCard from "./Components/NcNoteCard.mjs";
|
|
63
|
-
import { N as NcPasswordField } from "./chunks/NcPasswordField-
|
|
64
|
-
import { N as NcPopover } from "./chunks/NcPopover-
|
|
63
|
+
import { N as NcPasswordField } from "./chunks/NcPasswordField-CTKHRVC4.mjs";
|
|
64
|
+
import { N as NcPopover } from "./chunks/NcPopover-w98cBbbF.mjs";
|
|
65
65
|
import { N as NcProgressBar } from "./chunks/NcProgressBar-DegJ2JjE.mjs";
|
|
66
|
-
import { N as NcRelatedResourcesPanel } from "./chunks/NcRelatedResourcesPanel-
|
|
66
|
+
import { N as NcRelatedResourcesPanel } from "./chunks/NcRelatedResourcesPanel-CmiW_ds0.mjs";
|
|
67
67
|
import { N as NcMentionBubble } from "./chunks/index-G8WQDZ8G.mjs";
|
|
68
68
|
import { r } from "./chunks/index-G8WQDZ8G.mjs";
|
|
69
|
-
import { N as NcAutoCompleteResult, a as NcRichContenteditable } from "./chunks/NcRichContenteditable-
|
|
70
|
-
import { N as NcRichText } from "./chunks/NcRichText-
|
|
69
|
+
import { N as NcAutoCompleteResult, a as NcRichContenteditable } from "./chunks/NcRichContenteditable-zZQChT9M.mjs";
|
|
70
|
+
import { N as NcRichText } from "./chunks/NcRichText-C43cKGcR.mjs";
|
|
71
71
|
import { N, h, d, i, b, r as r2, c, a } from "./chunks/index-56SXuvlv.mjs";
|
|
72
72
|
import "@vueuse/core";
|
|
73
73
|
import "vue";
|
|
74
74
|
import "vue-router";
|
|
75
|
-
import { a as a2, g, b as b2, c as c2, d as d2, s } from "./chunks/referencePickerModal-
|
|
75
|
+
import { a as a2, g, b as b2, c as c2, d as d2, s } from "./chunks/referencePickerModal-Bxp4FMcs.mjs";
|
|
76
76
|
import "unist-util-visit";
|
|
77
77
|
import "unist-builder";
|
|
78
78
|
import "@nextcloud/router";
|
|
79
79
|
import "@nextcloud/axios";
|
|
80
80
|
import "@nextcloud/sharing/public";
|
|
81
81
|
import "@nextcloud/auth";
|
|
82
|
-
import { N as NcSelect } from "./chunks/NcSelect-
|
|
83
|
-
import { N as NcTextField } from "./chunks/NcTextField-
|
|
82
|
+
import { N as NcSelect } from "./chunks/NcSelect-XLdUgokz.mjs";
|
|
83
|
+
import { N as NcTextField } from "./chunks/NcTextField-DRANdaIf.mjs";
|
|
84
84
|
import "@nextcloud/event-bus";
|
|
85
85
|
import { N as NcSavingIndicatorIcon } from "./chunks/NcSavingIndicatorIcon-nv1147dk.mjs";
|
|
86
|
-
import { N as NcSelectTags } from "./chunks/NcSelectTags
|
|
87
|
-
import { N as
|
|
88
|
-
import { N as
|
|
89
|
-
import { N as
|
|
86
|
+
import { N as NcSelectTags } from "./chunks/NcSelectTags-DT2Y3Kms.mjs";
|
|
87
|
+
import { N as NcSelectUsers } from "./chunks/NcSelectUsers-DFlj_h9t.mjs";
|
|
88
|
+
import { N as NcSettingsInputText } from "./chunks/NcSettingsInputText-t1FMnLKA.mjs";
|
|
89
|
+
import { N as NcSettingsSection } from "./chunks/NcSettingsSection-EC3SmiDX.mjs";
|
|
90
|
+
import { N as NcSettingsSelectGroup } from "./chunks/NcSettingsSelectGroup-B4isXyUU.mjs";
|
|
90
91
|
import { N as NcTextArea } from "./chunks/NcTextArea-BHERsE_g.mjs";
|
|
91
|
-
import { N as NcTimezonePicker } from "./chunks/NcTimezonePicker-
|
|
92
|
-
import { N as NcUserBubble } from "./chunks/NcUserBubble-
|
|
93
|
-
import { N as NcUserStatusIcon } from "./chunks/NcUserStatusIcon-
|
|
92
|
+
import { N as NcTimezonePicker } from "./chunks/NcTimezonePicker-sAG8kn1b.mjs";
|
|
93
|
+
import { N as NcUserBubble } from "./chunks/NcUserBubble-DmZZOMRr.mjs";
|
|
94
|
+
import { N as NcUserStatusIcon } from "./chunks/NcUserStatusIcon-WEKmuaoU.mjs";
|
|
94
95
|
import NcVNodes from "./Components/NcVNodes.mjs";
|
|
95
96
|
import { isFullscreenState, useIsFullscreen } from "./Composables/useIsFullscreen.mjs";
|
|
96
97
|
import { MOBILE_BREAKPOINT, MOBILE_SMALL_BREAKPOINT, isMobileState, useIsMobile, useIsSmallMobile } from "./Composables/useIsMobile.mjs";
|
|
@@ -102,7 +103,7 @@ import { spawnDialog } from "./Functions/dialog.mjs";
|
|
|
102
103
|
import { E, a as a3, e, g as g2, s as s2 } from "./chunks/emoji-BY_D0V5K.mjs";
|
|
103
104
|
import { checkIfDarkTheme, isDarkTheme } from "./Functions/isDarkTheme.mjs";
|
|
104
105
|
import { preloadImage } from "./Functions/preloadImage.mjs";
|
|
105
|
-
import { u as u3 } from "./chunks/usernameToColor-
|
|
106
|
+
import { u as u3 } from "./chunks/usernameToColor-DJfepfog.mjs";
|
|
106
107
|
import { directive } from "./Directives/Focus.mjs";
|
|
107
108
|
import { directive as directive$1 } from "./Directives/Linkify.mjs";
|
|
108
109
|
import "./Directives/Tooltip.mjs";
|
|
@@ -184,6 +185,7 @@ const NcComponents = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.define
|
|
|
184
185
|
NcSavingIndicatorIcon,
|
|
185
186
|
NcSelect,
|
|
186
187
|
NcSelectTags,
|
|
188
|
+
NcSelectUsers,
|
|
187
189
|
NcSettingsInputText,
|
|
188
190
|
NcSettingsSection,
|
|
189
191
|
NcSettingsSelectGroup,
|
|
@@ -288,6 +290,7 @@ export {
|
|
|
288
290
|
NcSavingIndicatorIcon,
|
|
289
291
|
NcSelect,
|
|
290
292
|
NcSelectTags,
|
|
293
|
+
NcSelectUsers,
|
|
291
294
|
NcSettingsInputText,
|
|
292
295
|
NcSettingsSection,
|
|
293
296
|
NcSettingsSelectGroup,
|
package/dist/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../src/plugin.ts"],"sourcesContent":["/**\n * SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport type { DefineComponent, Directive, PluginObject } from 'vue'\n\nimport * as NcComponents from './components/index.js'\nimport * as NcDirectives from './directives/index.js'\n\n/**\n * Install all Nextcloud Vue components and directives globally\n * @example\n * ```js\n * import { NextcloudVuePlugin } from '@nextcloud/vue'\n * import Vue from 'vue'\n *\n * // ...\n *\n * Vue.use(NextcloudVuePlugin)\n * new Vue({\n * // options\n * })\n * ```\n */\nexport const NextcloudVuePlugin: PluginObject<never> = {\n\tinstall(Vue) {\n\t\t// Install components\n\t\tObject.entries(NcComponents as { [key: string]: DefineComponent }).forEach(([name, component]) => {\n\t\t\tVue.component(component.name || name, component)\n\t\t})\n\n\t\t// Install directives\n\t\tObject.entries(NcDirectives as { [key: string]: Directive }).forEach(([name, directive]) => {\n\t\t\tVue.directive(name, directive)\n\t\t})\n\t},\n}\n"],"names":["directive"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../src/plugin.ts"],"sourcesContent":["/**\n * SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport type { DefineComponent, Directive, PluginObject } from 'vue'\n\nimport * as NcComponents from './components/index.js'\nimport * as NcDirectives from './directives/index.js'\n\n/**\n * Install all Nextcloud Vue components and directives globally\n * @example\n * ```js\n * import { NextcloudVuePlugin } from '@nextcloud/vue'\n * import Vue from 'vue'\n *\n * // ...\n *\n * Vue.use(NextcloudVuePlugin)\n * new Vue({\n * // options\n * })\n * ```\n */\nexport const NextcloudVuePlugin: PluginObject<never> = {\n\tinstall(Vue) {\n\t\t// Install components\n\t\tObject.entries(NcComponents as { [key: string]: DefineComponent }).forEach(([name, component]) => {\n\t\t\tVue.component(component.name || name, component)\n\t\t})\n\n\t\t// Install directives\n\t\tObject.entries(NcDirectives as { [key: string]: Directive }).forEach(([name, directive]) => {\n\t\t\tVue.directive(name, directive)\n\t\t})\n\t},\n}\n"],"names":["directive"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAyBO,MAAM,qBAA0C;AAAA,EACtD,QAAQ,KAAK;AAEL,WAAA,QAAQ,YAAkD,EAAE,QAAQ,CAAC,CAAC,MAAM,SAAS,MAAM;AACjG,UAAI,UAAU,UAAU,QAAQ,MAAM,SAAS;AAAA,IAAA,CAC/C;AAGM,WAAA,QAAQ,YAA4C,EAAE,QAAQ,CAAC,CAAC,MAAMA,UAAS,MAAM;AACvF,UAAA,UAAU,MAAMA,UAAS;AAAA,IAAA,CAC7B;AAAA,EAAA;AAEH;"}
|
package/package.json
CHANGED
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import { n as normalizeComponent } from "./_plugin-vue2_normalizer-DU4iP6Vu.mjs";
|
|
2
|
-
const _sfc_main = {
|
|
3
|
-
name: "ChevronLeftIcon",
|
|
4
|
-
emits: ["click"],
|
|
5
|
-
props: {
|
|
6
|
-
title: {
|
|
7
|
-
type: String
|
|
8
|
-
},
|
|
9
|
-
fillColor: {
|
|
10
|
-
type: String,
|
|
11
|
-
default: "currentColor"
|
|
12
|
-
},
|
|
13
|
-
size: {
|
|
14
|
-
type: Number,
|
|
15
|
-
default: 24
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
};
|
|
19
|
-
var _sfc_render = function render() {
|
|
20
|
-
var _vm = this, _c = _vm._self._c;
|
|
21
|
-
return _c("span", _vm._b({ staticClass: "material-design-icon chevron-left-icon", attrs: { "aria-hidden": _vm.title ? null : "true", "aria-label": _vm.title, "role": "img" }, on: { "click": function($event) {
|
|
22
|
-
return _vm.$emit("click", $event);
|
|
23
|
-
} } }, "span", _vm.$attrs, false), [_c("svg", { staticClass: "material-design-icon__svg", attrs: { "fill": _vm.fillColor, "width": _vm.size, "height": _vm.size, "viewBox": "0 0 24 24" } }, [_c("path", { attrs: { "d": "M15.41,16.58L10.83,12L15.41,7.41L14,6L8,12L14,18L15.41,16.58Z" } }, [_vm.title ? _c("title", [_vm._v(_vm._s(_vm.title))]) : _vm._e()])])]);
|
|
24
|
-
};
|
|
25
|
-
var _sfc_staticRenderFns = [];
|
|
26
|
-
var __component__ = /* @__PURE__ */ normalizeComponent(
|
|
27
|
-
_sfc_main,
|
|
28
|
-
_sfc_render,
|
|
29
|
-
_sfc_staticRenderFns,
|
|
30
|
-
false,
|
|
31
|
-
null,
|
|
32
|
-
null
|
|
33
|
-
);
|
|
34
|
-
const ChevronLeft = __component__.exports;
|
|
35
|
-
export {
|
|
36
|
-
ChevronLeft as C
|
|
37
|
-
};
|
|
38
|
-
//# sourceMappingURL=ChevronLeft-BK4j9oVH.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ChevronLeft-BK4j9oVH.mjs","sources":["../../node_modules/vue-material-design-icons/ChevronLeft.vue"],"sourcesContent":["<template>\n <span v-bind=\"$attrs\"\n :aria-hidden=\"title ? null : 'true'\"\n :aria-label=\"title\"\n class=\"material-design-icon chevron-left-icon\"\n role=\"img\"\n @click=\"$emit('click', $event)\">\n <svg :fill=\"fillColor\"\n class=\"material-design-icon__svg\"\n :width=\"size\"\n :height=\"size\"\n viewBox=\"0 0 24 24\">\n <path d=\"M15.41,16.58L10.83,12L15.41,7.41L14,6L8,12L14,18L15.41,16.58Z\">\n <title v-if=\"title\">{{ title }}</title>\n </path>\n </svg>\n </span>\n</template>\n\n<script>\nexport default {\n name: \"ChevronLeftIcon\",\n emits: ['click'],\n props: {\n title: {\n type: String,\n },\n fillColor: {\n type: String,\n default: \"currentColor\"\n },\n size: {\n type: Number,\n default: 24\n }\n }\n}\n</script>"],"names":[],"mappings":";AAoBA,MAAA,YAAA;AAAA,EACA,MAAA;AAAA,EACA,OAAA,CAAA,OAAA;AAAA,EACA,OAAA;AAAA,IACA,OAAA;AAAA,MACA,MAAA;AAAA,IACA;AAAA,IACA,WAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA,IACA,MAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA,EACA;AACA;;;;;;;;;;;;;;;;;","x_google_ignoreList":[0]}
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
const _pluginVue2_normalizer = require("./_plugin-vue2_normalizer-V0q-tHlQ.cjs");
|
|
3
|
-
const _sfc_main = {
|
|
4
|
-
name: "ChevronLeftIcon",
|
|
5
|
-
emits: ["click"],
|
|
6
|
-
props: {
|
|
7
|
-
title: {
|
|
8
|
-
type: String
|
|
9
|
-
},
|
|
10
|
-
fillColor: {
|
|
11
|
-
type: String,
|
|
12
|
-
default: "currentColor"
|
|
13
|
-
},
|
|
14
|
-
size: {
|
|
15
|
-
type: Number,
|
|
16
|
-
default: 24
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
};
|
|
20
|
-
var _sfc_render = function render() {
|
|
21
|
-
var _vm = this, _c = _vm._self._c;
|
|
22
|
-
return _c("span", _vm._b({ staticClass: "material-design-icon chevron-left-icon", attrs: { "aria-hidden": _vm.title ? null : "true", "aria-label": _vm.title, "role": "img" }, on: { "click": function($event) {
|
|
23
|
-
return _vm.$emit("click", $event);
|
|
24
|
-
} } }, "span", _vm.$attrs, false), [_c("svg", { staticClass: "material-design-icon__svg", attrs: { "fill": _vm.fillColor, "width": _vm.size, "height": _vm.size, "viewBox": "0 0 24 24" } }, [_c("path", { attrs: { "d": "M15.41,16.58L10.83,12L15.41,7.41L14,6L8,12L14,18L15.41,16.58Z" } }, [_vm.title ? _c("title", [_vm._v(_vm._s(_vm.title))]) : _vm._e()])])]);
|
|
25
|
-
};
|
|
26
|
-
var _sfc_staticRenderFns = [];
|
|
27
|
-
var __component__ = /* @__PURE__ */ _pluginVue2_normalizer.normalizeComponent(
|
|
28
|
-
_sfc_main,
|
|
29
|
-
_sfc_render,
|
|
30
|
-
_sfc_staticRenderFns,
|
|
31
|
-
false,
|
|
32
|
-
null,
|
|
33
|
-
null
|
|
34
|
-
);
|
|
35
|
-
const ChevronLeft = __component__.exports;
|
|
36
|
-
exports.ChevronLeft = ChevronLeft;
|
|
37
|
-
//# sourceMappingURL=ChevronLeft-CAiEPWc5.cjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ChevronLeft-CAiEPWc5.cjs","sources":["../../node_modules/vue-material-design-icons/ChevronLeft.vue"],"sourcesContent":["<template>\n <span v-bind=\"$attrs\"\n :aria-hidden=\"title ? null : 'true'\"\n :aria-label=\"title\"\n class=\"material-design-icon chevron-left-icon\"\n role=\"img\"\n @click=\"$emit('click', $event)\">\n <svg :fill=\"fillColor\"\n class=\"material-design-icon__svg\"\n :width=\"size\"\n :height=\"size\"\n viewBox=\"0 0 24 24\">\n <path d=\"M15.41,16.58L10.83,12L15.41,7.41L14,6L8,12L14,18L15.41,16.58Z\">\n <title v-if=\"title\">{{ title }}</title>\n </path>\n </svg>\n </span>\n</template>\n\n<script>\nexport default {\n name: \"ChevronLeftIcon\",\n emits: ['click'],\n props: {\n title: {\n type: String,\n },\n fillColor: {\n type: String,\n default: \"currentColor\"\n },\n size: {\n type: Number,\n default: 24\n }\n }\n}\n</script>"],"names":[],"mappings":";;AAoBA,MAAA,YAAA;AAAA,EACA,MAAA;AAAA,EACA,OAAA,CAAA,OAAA;AAAA,EACA,OAAA;AAAA,IACA,OAAA;AAAA,MACA,MAAA;AAAA,IACA;AAAA,IACA,WAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA,IACA,MAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA,EACA;AACA;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[0]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"NcActionButton-BFxArTsE.mjs","sources":["../../src/components/NcActionButton/NcActionButton.vue"],"sourcesContent":["<!--\n - SPDX-FileCopyrightText: 2019 Nextcloud GmbH and Nextcloud contributors\n - SPDX-License-Identifier: AGPL-3.0-or-later\n-->\n\n<docs>\nThis component is made to be used inside of the [NcActions](#NcActions) component slots.\n\n```vue\n\t<template>\n\t\t<NcActions>\n\t\t\t<NcActionButton @click=\"showMessage('Delete')\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<Delete :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tDelete\n\t\t\t</NcActionButton>\n\t\t\t<NcActionButton :close-after-click=\"true\" @click=\"showMessage('Delete and close menu')\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<Delete :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tDelete and close\n\t\t\t</NcActionButton>\n\t\t\t<NcActionButton :is-menu=\"true\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<Plus :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tCreate\n\t\t\t</NcActionButton>\n\t\t\t<NcActionButton :disabled=\"true\" @click=\"showMessage('Disabled')\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<Delete :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tDisabled button\n\t\t\t</NcActionButton>\n\t\t</NcActions>\n\t</template>\n\t<script>\n\timport Delete from 'vue-material-design-icons/Delete.vue'\n\timport Plus from 'vue-material-design-icons/Plus.vue'\n\n\texport default {\n\t\tcomponents: {\n\t\t\tDelete,\n\t\t\tPlus,\n\t\t},\n\t\tmethods: {\n\t\t\tshowMessage(msg) {\n\t\t\t\talert(msg)\n\t\t\t},\n\t\t},\n\t}\n\t</script>\n```\n\nIf you're using a long text you can specify a name\n\n```vue\n\t<template>\n\t\t<NcActions>\n\t\t\t<NcActionButton @click=\"showMessage('Add')\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<Plus :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tAdd new\n\t\t\t</NcActionButton>\n\t\t\t<NcActionButton name=\"Long button\" @click=\"showMessage('Delete')\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<Delete :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tThis button is associated with a very long text.\\nAnd with new lines too.\n\t\t\t</NcActionButton>\n\t\t</NcActions>\n\t</template>\n\t<script>\n\timport Delete from 'vue-material-design-icons/Delete.vue'\n\timport Plus from 'vue-material-design-icons/Plus.vue'\n\n\texport default {\n\t\tcomponents: {\n\t\t\tDelete,\n\t\t\tPlus,\n\t\t},\n\t\tmethods: {\n\t\t\tshowMessage(msg) {\n\t\t\t\talert(msg)\n\t\t\t},\n\t\t},\n\t}\n\t</script>\n\n```\n\nAction icon attribute with a single action\n\n```vue\n\t<template>\n\t\t<NcActions>\n\t\t\t<NcActionButton @click=\"showMessage('Add')\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<Plus :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tAdd new\n\t\t\t</NcActionButton>\n\t\t</NcActions>\n\t</template>\n\t<script>\n\timport Plus from 'vue-material-design-icons/Plus.vue'\n\n\texport default {\n\t\tcomponents: {\n\t\t\tPlus,\n\t\t},\n\t\tmethods: {\n\t\t\tshowMessage(msg) {\n\t\t\t\talert(msg)\n\t\t\t},\n\t\t},\n\t}\n\t</script>\n\n```\n\nYou can also use a custom icon, for example from the vue-material-design-icons library:\n\n```vue\n<template>\n\t<NcActions>\n\t\t<NcActionButton>\n\t\t\t<template #icon>\n\t\t\t\t<HandBackLeft :size=\"20\" />\n\t\t\t</template>\n\t\t\tRaise left hand\n\t\t</NcActionButton>\n\t\t<NcActionButton>\n\t\t\t<template #icon>\n\t\t\t\t<HandBackRight :size=\"20\" />\n\t\t\t</template>\n\t\t\tRaise right hand\n\t\t</NcActionButton>\n\t</NcActions>\n</template>\n<script>\nimport HandBackLeft from 'vue-material-design-icons/HandBackLeft.vue'\nimport HandBackRight from 'vue-material-design-icons/HandBackRight.vue'\n\nexport default {\n\tcomponents: {\n\t\tHandBackLeft,\n\t\tHandBackRight,\n\t},\n}\n</script>\n```\n\n### With different model behavior\nBy default the button will act like a normal button, but it is also possible to change the behavior to a toggle button, checkbox button or radio button.\n\nFor example to have the button act like a toggle button just set the `modelValue` property to the toggle state:\n\n```vue\n<template>\n\t<NcActions>\n\t\t<NcActionButton :model-value.sync=\"fullscreen\">\n\t\t\t<template #icon>\n\t\t\t\t<Fullscreen :size=\"20\" />\n\t\t\t</template>\n\t\t\tFullscreen\n\t\t</NcActionButton>\n\t</NcActions>\n</template>\n<script>\nimport Fullscreen from 'vue-material-design-icons/Fullscreen.vue'\n\nexport default {\n\tcomponents: {\n\t\tFullscreen,\n\t},\n\tdata() {\n\t\treturn {\n\t\t\tfullscreen: true,\n\t\t}\n\t},\n}\n</script>\n```\n\nAnother example would be using it with checkbox semantics, to enable or disable features.\nThis also allows tri-state behavior (`true`, `false`, `null`) in which case `aria-checked` will be either `true`, `false` or `mixed`.\n\n```vue\n<template>\n\t<NcActions>\n\t\t<NcActionButton :model-value.sync=\"handRaised\" type=\"checkbox\">\n\t\t\t<template #icon>\n\t\t\t\t<HandBackLeft :size=\"20\" />\n\t\t\t</template>\n\t\t\tRaise hand\n\t\t</NcActionButton>\n\t\t<NcActionButton :model-value.sync=\"fullscreen\" type=\"checkbox\">\n\t\t\t<template #icon>\n\t\t\t\t<Fullscreen :size=\"20\" />\n\t\t\t</template>\n\t\t\tFullscreen\n\t\t</NcActionButton>\n\t</NcActions>\n</template>\n<script>\nimport HandBackLeft from 'vue-material-design-icons/HandBackLeft.vue'\nimport Fullscreen from 'vue-material-design-icons/Fullscreen.vue'\n\nexport default {\n\tcomponents: {\n\t\tHandBackLeft,\n\t\tFullscreen,\n\t},\n\tdata() {\n\t\treturn {\n\t\t\tfullscreen: true,\n\t\t\thandRaised: false,\n\t\t}\n\t},\n}\n</script>\n```\n\nIt is also possible to use the button with radio semantics, this is only possible in menus and not for inline actions!\n\nWith a string `modelValue`, checked state is determined by the `value` property and updates `modelValue` with the new `value` string.\n\nWith a boolean `modelValue`, checked state is determined by `modelValue` and updates to `true` on check.\n\nNote: unlike native radio buttons, `NcActionButton` are not grouped by name, so you need to connect them by bind correct `modelValue``.\n\n```vue\n<template>\n\t<div>\n\t\t<NcActions>\n\t\t\t<NcActionButton :model-value.sync=\"payment\" type=\"radio\" value=\"cash\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<Cash :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tPay with cash\n\t\t\t</NcActionButton>\n\t\t\t<NcActionButton :model-value.sync=\"payment\" type=\"radio\" value=\"card\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<CreditCard :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tPay by card\n\t\t\t</NcActionButton>\n\t\t\t<NcActionSeparator />\n\t\t\t<NcActionButton type=\"radio\" :model-value=\"align.isLeft\" @update:modelValue=\"setAlign('Left', $event)\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<FormatAlignLeft :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tLeft\n\t\t\t</NcActionButton>\n\t\t\t<NcActionButton type=\"radio\" :model-value=\"align.isCenter\" @update:modelValue=\"setAlign('Center', $event)\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<FormatAlignCenter :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tCenter\n\t\t\t</NcActionButton>\n\t\t\t<NcActionButton type=\"radio\" :model-value=\"align.isRight\" @update:modelValue=\"setAlign('Right', $event)\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<FormatAlignRight :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tRight\n\t\t\t</NcActionButton>\n\t\t</NcActions>\n\t\t<p>payment = \"{{ payment }}\"</p>\n\t\t<p>align.isLeft = {{ align.isLeft }}</p>\n\t\t<p>align.isCenter = {{ align.isCenter }}</p>\n\t\t<p>align.isRight = {{ align.isRight }}</p>\n\t</div>\n</template>\n<script>\nimport Cash from 'vue-material-design-icons/Cash.vue'\nimport CreditCard from 'vue-material-design-icons/CreditCard.vue'\nimport FormatAlignLeft from 'vue-material-design-icons/FormatAlignLeft.vue'\nimport FormatAlignCenter from 'vue-material-design-icons/FormatAlignCenter.vue'\nimport FormatAlignRight from 'vue-material-design-icons/FormatAlignRight.vue'\n\nexport default {\n\tcomponents: {\n\t\tCash,\n\t\tCreditCard,\n\t\tFormatAlignLeft,\n\t\tFormatAlignCenter,\n\t\tFormatAlignRight,\n\t},\n\tdata() {\n\t\treturn {\n\t\t\tpayment: 'card',\n\t\t\talign: {\n\t\t\t\tisLeft: false,\n\t\t\t\tisCenter: true,\n\t\t\t\tisRight: false,\n\t\t\t},\n\t\t}\n\t},\n\tmethods: {\n\t\tsetAlign(direction, value) {\n\t\t\tthis.align.isLeft = false\n\t\t\tthis.align.isCenter = false\n\t\t\tthis.align.isRight = false\n\t\t\tthis.align[`is${direction}`] = value\n\t\t},\n\t}\n}\n</script>\n```\n</docs>\n\n<template>\n\t<li class=\"action\" :class=\"{ 'action--disabled': disabled }\" :role=\"isInSemanticMenu && 'presentation'\">\n\t\t<button :aria-label=\"ariaLabel\"\n\t\t\t:class=\"['action-button button-vue', {\n\t\t\t\t'action-button--active': isChecked,\n\t\t\t\tfocusable: isFocusable,\n\t\t\t}]\"\n\t\t\t:disabled=\"disabled\"\n\t\t\t:title=\"title\"\n\t\t\t:type=\"nativeType\"\n\t\t\tv-bind=\"buttonAttributes\"\n\t\t\t@click=\"handleClick\">\n\t\t\t<!-- @slot Manually provide icon -->\n\t\t\t<slot name=\"icon\">\n\t\t\t\t<span :class=\"[isIconUrl ? 'action-button__icon--url' : icon]\"\n\t\t\t\t\t:style=\"{ backgroundImage: isIconUrl ? `url(${icon})` : null }\"\n\t\t\t\t\taria-hidden=\"true\"\n\t\t\t\t\tclass=\"action-button__icon\" />\n\t\t\t</slot>\n\n\t\t\t<!-- long text with name -->\n\t\t\t<span v-if=\"name\"\n\t\t\t\tclass=\"action-button__longtext-wrapper\">\n\t\t\t\t<strong class=\"action-button__name\">\n\t\t\t\t\t{{ name }}\n\t\t\t\t</strong>\n\t\t\t\t<br>\n\t\t\t\t<!-- white space is shown on longtext, so we can't\n\t\t\t\t\tput {{ text }} on a new line for code readability -->\n\t\t\t\t<span class=\"action-button__longtext\" v-text=\"text\" />\n\t\t\t</span>\n\n\t\t\t<!-- long text only -->\n\t\t\t<!-- white space is shown on longtext, so we can't\n\t\t\t\tput {{ text }} on a new line for code readability -->\n\t\t\t<span v-else-if=\"isLongText\"\n\t\t\t\tclass=\"action-button__longtext\"\n\t\t\t\tv-text=\"text\" />\n\n\t\t\t<!-- default text display -->\n\t\t\t<span v-else class=\"action-button__text\">{{ text }}</span>\n\n\t\t\t<!-- right(in LTR) or left(in RTL) arrow icon when there is a sub-menu -->\n\t\t\t<ChevronRightIcon v-if=\"isMenu && !isRtl\" :size=\"20\" class=\"action-button__menu-icon\" />\n\t\t\t<ChevronLeftIcon v-else-if=\"isMenu && isRtl\" :size=\"20\" class=\"action-button__menu-icon\" />\n\t\t\t<CheckIcon v-else-if=\"isChecked === true\" :size=\"20\" class=\"action-button__pressed-icon\" />\n\t\t\t<span v-else-if=\"isChecked === false\" class=\"action-button__pressed-icon material-design-icon\" />\n\n\t\t\t<!-- fake slot to gather inner text -->\n\t\t\t<slot v-if=\"false\" />\n\t\t</button>\n\t</li>\n</template>\n\n<script>\nimport CheckIcon from 'vue-material-design-icons/Check.vue'\nimport ChevronRightIcon from 'vue-material-design-icons/ChevronRight.vue'\nimport ChevronLeftIcon from 'vue-material-design-icons/ChevronLeft.vue'\nimport ActionTextMixin from '../../mixins/actionText.js'\nimport { isRtl } from '../../utils/rtl.ts'\n\n/**\n * Button component to be used in Actions\n */\nexport default {\n\tname: 'NcActionButton',\n\n\tcomponents: {\n\t\tCheckIcon,\n\t\tChevronRightIcon,\n\t\tChevronLeftIcon,\n\t},\n\tmixins: [ActionTextMixin],\n\n\tinject: {\n\t\tisInSemanticMenu: {\n\t\t\tfrom: 'NcActions:isSemanticMenu',\n\t\t\tdefault: false,\n\t\t},\n\t},\n\n\tprops: {\n\t\t/**\n\t\t * @deprecated To be removed in @nextcloud/vue 9. Migration guide: remove ariaHidden prop from NcAction* components.\n\t\t * @todo Add a check in @nextcloud/vue 9 that this prop is not provided,\n\t\t * otherwise root element will inherit incorrect aria-hidden.\n\t\t */\n\t\tariaHidden: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: null,\n\t\t},\n\n\t\t/**\n\t\t * disabled state of the action button\n\t\t */\n\t\tdisabled: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: false,\n\t\t},\n\n\t\t/**\n\t\t * If this is a menu, a chevron icon will\n\t\t * be added at the end of the line\n\t\t */\n\t\tisMenu: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: false,\n\t\t},\n\n\t\t/**\n\t\t * The button's behavior, by default the button acts like a normal button with optional toggle button behavior if `modelValue` is `true` or `false`.\n\t\t * But you can also set to checkbox button behavior with tri-state or radio button like behavior.\n\t\t * This extends the native HTML button type attribute.\n\t\t */\n\t\ttype: {\n\t\t\ttype: String,\n\t\t\tdefault: 'button',\n\t\t\tvalidator: (behavior) => ['button', 'checkbox', 'radio', 'reset', 'submit'].includes(behavior),\n\t\t},\n\n\t\t/**\n\t\t * The buttons state if `type` is 'checkbox' or 'radio' (meaning if it is pressed / selected).\n\t\t * For checkbox and toggle button behavior - boolean value.\n\t\t * For radio button behavior - could be a boolean checked or a string with the value of the button.\n\t\t * Note: Unlike native radio buttons, NcActionButton are not grouped by name, so you need to connect them by bind correct modelValue.\n\t\t *\n\t\t * **This is not availabe for `type='submit'` or `type='reset'`**\n\t\t *\n\t\t * If using `type='checkbox'` a `model-value` of `true` means checked, `false` means unchecked and `null` means indeterminate (tri-state)\n\t\t * For `type='radio'` `null` is equal to `false`\n\t\t */\n\t\tmodelValue: {\n\t\t\ttype: [Boolean, String],\n\t\t\tdefault: null,\n\t\t},\n\n\t\t/**\n\t\t * The value used for the `modelValue` when this component is used with radio behavior\n\t\t * Similar to the `value` attribute of `<input type=\"radio\">`\n\t\t */\n\t\tvalue: {\n\t\t\ttype: String,\n\t\t\tdefault: null,\n\t\t},\n\t},\n\tsetup() {\n\t\treturn {\n\t\t\tisRtl,\n\t\t}\n\t},\n\n\tcomputed: {\n\t\t/**\n\t\t * determines if the action is focusable\n\t\t *\n\t\t * @return {boolean} is the action focusable ?\n\t\t */\n\t\tisFocusable() {\n\t\t\treturn !this.disabled\n\t\t},\n\n\t\t/**\n\t\t * The current \"checked\" or \"pressed\" state for the model behavior\n\t\t */\n\t\tisChecked() {\n\t\t\tif (this.type === 'radio' && typeof this.modelValue !== 'boolean') {\n\t\t\t\treturn this.modelValue === this.value\n\t\t\t}\n\t\t\treturn this.modelValue\n\t\t},\n\n\t\t/**\n\t\t * The native HTML type to set on the button\n\t\t */\n\t\tnativeType() {\n\t\t\tif (this.type === 'submit' || this.type === 'reset') {\n\t\t\t\treturn this.type\n\t\t\t}\n\t\t\treturn 'button'\n\t\t},\n\n\t\t/**\n\t\t * HTML attributes to bind to the <button>\n\t\t */\n\t\tbuttonAttributes() {\n\t\t\tconst attributes = {}\n\n\t\t\tif (this.isInSemanticMenu) {\n\t\t\t\t// By default it needs to be a menu item in semantic menus\n\t\t\t\tattributes.role = 'menuitem'\n\n\t\t\t\tif (this.type === 'radio') {\n\t\t\t\t\tattributes.role = 'menuitemradio'\n\t\t\t\t\tattributes['aria-checked'] = this.isChecked ? 'true' : 'false'\n\t\t\t\t} else if (this.type === 'checkbox' || (this.nativeType === 'button' && this.modelValue !== null)) {\n\t\t\t\t\t// either if checkbox behavior was set or the model value is not unset\n\t\t\t\t\tattributes.role = 'menuitemcheckbox'\n\t\t\t\t\tattributes['aria-checked'] = this.modelValue === null ? 'mixed' : (this.modelValue ? 'true' : 'false')\n\t\t\t\t}\n\t\t\t} else if (this.modelValue !== null && this.nativeType === 'button') {\n\t\t\t\t// In case this has a modelValue it is considered a toggle button, so we need to set the aria-pressed\n\t\t\t\tattributes['aria-pressed'] = this.modelValue ? 'true' : 'false'\n\t\t\t}\n\n\t\t\treturn attributes\n\t\t},\n\t},\n\n\tmethods: {\n\t\t/**\n\t\t * Forward click event, let mixin handle the close-after-click and emit new modelValue if needed\n\t\t * @param {MouseEvent} event The click event\n\t\t */\n\t\thandleClick(event) {\n\t\t\tthis.onClick(event)\n\t\t\t// If modelValue or type is set (so modelValue might be null for tri-state) we need to update it\n\t\t\tif (this.modelValue !== null || this.type !== 'button') {\n\t\t\t\tif (this.type === 'radio') {\n\t\t\t\t\tif (typeof this.modelValue !== 'boolean') {\n\t\t\t\t\t\t// String-value radios behavior is similar to native - click on checked radio does nothing\n\t\t\t\t\t\tif (!this.isChecked) {\n\t\t\t\t\t\t\tthis.$emit('update:modelValue', this.value)\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\t// Boolean radio allows to uncheck\n\t\t\t\t\t\tthis.$emit('update:modelValue', !this.isChecked)\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\t// Checkbox toggles value\n\t\t\t\t\tthis.$emit('update:modelValue', !this.isChecked)\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\t},\n}\n</script>\n\n<style lang=\"scss\" scoped>\n@import '../../assets/action';\n@include action-active;\n@include action--disabled;\n@include action-item('button');\n\n.action-button__pressed-icon {\n\tmargin-inline: auto calc($icon-margin * -1);\n}\n</style>\n"],"names":["CheckIcon","ChevronRightIcon","ChevronLeftIcon"],"mappings":";;;;;;AA0XA,MAAA,YAAA;AAAA,EACA,MAAA;AAAA,EAEA,YAAA;AAAA,IACA,WAAAA;AAAAA,IACA,kBAAAC;AAAAA,IACA,iBAAAC;AAAAA,EACA;AAAA,EACA,QAAA,CAAA,eAAA;AAAA,EAEA,QAAA;AAAA,IACA,kBAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA,EACA;AAAA,EAEA,OAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAMA,YAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA,IAKA,UAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA,IAMA,QAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAOA,MAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,MACA,WAAA,CAAA,aAAA,CAAA,UAAA,YAAA,SAAA,SAAA,QAAA,EAAA,SAAA,QAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAaA,YAAA;AAAA,MACA,MAAA,CA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A,YAAA,KAAA,SAAA,SAAA;AACA,cAAA,OAAA,KAAA,eAAA,WAAA;AAEA,gBAAA,CAAA,KAAA,WAAA;AACA,mBAAA,MAAA,qBAAA,KAAA,KAAA;AAAA,YACA;AAAA,UACA,OAAA;AAEA,iBAAA,MAAA,qBAAA,CAAA,KAAA,SAAA;AAAA,UACA;AAAA,QACA,OAAA;AAEA,eAAA,MAAA,qBAAA,CAAA,KAAA,SAAA;AAAA,QACA;AAAA,MACA;AAAA,IACA;AAAA,EACA;AACA;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"NcActionButton-ChQFsL4S.cjs","sources":["../../src/components/NcActionButton/NcActionButton.vue"],"sourcesContent":["<!--\n - SPDX-FileCopyrightText: 2019 Nextcloud GmbH and Nextcloud contributors\n - SPDX-License-Identifier: AGPL-3.0-or-later\n-->\n\n<docs>\nThis component is made to be used inside of the [NcActions](#NcActions) component slots.\n\n```vue\n\t<template>\n\t\t<NcActions>\n\t\t\t<NcActionButton @click=\"showMessage('Delete')\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<Delete :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tDelete\n\t\t\t</NcActionButton>\n\t\t\t<NcActionButton :close-after-click=\"true\" @click=\"showMessage('Delete and close menu')\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<Delete :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tDelete and close\n\t\t\t</NcActionButton>\n\t\t\t<NcActionButton :is-menu=\"true\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<Plus :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tCreate\n\t\t\t</NcActionButton>\n\t\t\t<NcActionButton :disabled=\"true\" @click=\"showMessage('Disabled')\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<Delete :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tDisabled button\n\t\t\t</NcActionButton>\n\t\t</NcActions>\n\t</template>\n\t<script>\n\timport Delete from 'vue-material-design-icons/Delete.vue'\n\timport Plus from 'vue-material-design-icons/Plus.vue'\n\n\texport default {\n\t\tcomponents: {\n\t\t\tDelete,\n\t\t\tPlus,\n\t\t},\n\t\tmethods: {\n\t\t\tshowMessage(msg) {\n\t\t\t\talert(msg)\n\t\t\t},\n\t\t},\n\t}\n\t</script>\n```\n\nIf you're using a long text you can specify a name\n\n```vue\n\t<template>\n\t\t<NcActions>\n\t\t\t<NcActionButton @click=\"showMessage('Add')\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<Plus :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tAdd new\n\t\t\t</NcActionButton>\n\t\t\t<NcActionButton name=\"Long button\" @click=\"showMessage('Delete')\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<Delete :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tThis button is associated with a very long text.\\nAnd with new lines too.\n\t\t\t</NcActionButton>\n\t\t</NcActions>\n\t</template>\n\t<script>\n\timport Delete from 'vue-material-design-icons/Delete.vue'\n\timport Plus from 'vue-material-design-icons/Plus.vue'\n\n\texport default {\n\t\tcomponents: {\n\t\t\tDelete,\n\t\t\tPlus,\n\t\t},\n\t\tmethods: {\n\t\t\tshowMessage(msg) {\n\t\t\t\talert(msg)\n\t\t\t},\n\t\t},\n\t}\n\t</script>\n\n```\n\nAction icon attribute with a single action\n\n```vue\n\t<template>\n\t\t<NcActions>\n\t\t\t<NcActionButton @click=\"showMessage('Add')\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<Plus :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tAdd new\n\t\t\t</NcActionButton>\n\t\t</NcActions>\n\t</template>\n\t<script>\n\timport Plus from 'vue-material-design-icons/Plus.vue'\n\n\texport default {\n\t\tcomponents: {\n\t\t\tPlus,\n\t\t},\n\t\tmethods: {\n\t\t\tshowMessage(msg) {\n\t\t\t\talert(msg)\n\t\t\t},\n\t\t},\n\t}\n\t</script>\n\n```\n\nYou can also use a custom icon, for example from the vue-material-design-icons library:\n\n```vue\n<template>\n\t<NcActions>\n\t\t<NcActionButton>\n\t\t\t<template #icon>\n\t\t\t\t<HandBackLeft :size=\"20\" />\n\t\t\t</template>\n\t\t\tRaise left hand\n\t\t</NcActionButton>\n\t\t<NcActionButton>\n\t\t\t<template #icon>\n\t\t\t\t<HandBackRight :size=\"20\" />\n\t\t\t</template>\n\t\t\tRaise right hand\n\t\t</NcActionButton>\n\t</NcActions>\n</template>\n<script>\nimport HandBackLeft from 'vue-material-design-icons/HandBackLeft.vue'\nimport HandBackRight from 'vue-material-design-icons/HandBackRight.vue'\n\nexport default {\n\tcomponents: {\n\t\tHandBackLeft,\n\t\tHandBackRight,\n\t},\n}\n</script>\n```\n\n### With different model behavior\nBy default the button will act like a normal button, but it is also possible to change the behavior to a toggle button, checkbox button or radio button.\n\nFor example to have the button act like a toggle button just set the `modelValue` property to the toggle state:\n\n```vue\n<template>\n\t<NcActions>\n\t\t<NcActionButton :model-value.sync=\"fullscreen\">\n\t\t\t<template #icon>\n\t\t\t\t<Fullscreen :size=\"20\" />\n\t\t\t</template>\n\t\t\tFullscreen\n\t\t</NcActionButton>\n\t</NcActions>\n</template>\n<script>\nimport Fullscreen from 'vue-material-design-icons/Fullscreen.vue'\n\nexport default {\n\tcomponents: {\n\t\tFullscreen,\n\t},\n\tdata() {\n\t\treturn {\n\t\t\tfullscreen: true,\n\t\t}\n\t},\n}\n</script>\n```\n\nAnother example would be using it with checkbox semantics, to enable or disable features.\nThis also allows tri-state behavior (`true`, `false`, `null`) in which case `aria-checked` will be either `true`, `false` or `mixed`.\n\n```vue\n<template>\n\t<NcActions>\n\t\t<NcActionButton :model-value.sync=\"handRaised\" type=\"checkbox\">\n\t\t\t<template #icon>\n\t\t\t\t<HandBackLeft :size=\"20\" />\n\t\t\t</template>\n\t\t\tRaise hand\n\t\t</NcActionButton>\n\t\t<NcActionButton :model-value.sync=\"fullscreen\" type=\"checkbox\">\n\t\t\t<template #icon>\n\t\t\t\t<Fullscreen :size=\"20\" />\n\t\t\t</template>\n\t\t\tFullscreen\n\t\t</NcActionButton>\n\t</NcActions>\n</template>\n<script>\nimport HandBackLeft from 'vue-material-design-icons/HandBackLeft.vue'\nimport Fullscreen from 'vue-material-design-icons/Fullscreen.vue'\n\nexport default {\n\tcomponents: {\n\t\tHandBackLeft,\n\t\tFullscreen,\n\t},\n\tdata() {\n\t\treturn {\n\t\t\tfullscreen: true,\n\t\t\thandRaised: false,\n\t\t}\n\t},\n}\n</script>\n```\n\nIt is also possible to use the button with radio semantics, this is only possible in menus and not for inline actions!\n\nWith a string `modelValue`, checked state is determined by the `value` property and updates `modelValue` with the new `value` string.\n\nWith a boolean `modelValue`, checked state is determined by `modelValue` and updates to `true` on check.\n\nNote: unlike native radio buttons, `NcActionButton` are not grouped by name, so you need to connect them by bind correct `modelValue``.\n\n```vue\n<template>\n\t<div>\n\t\t<NcActions>\n\t\t\t<NcActionButton :model-value.sync=\"payment\" type=\"radio\" value=\"cash\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<Cash :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tPay with cash\n\t\t\t</NcActionButton>\n\t\t\t<NcActionButton :model-value.sync=\"payment\" type=\"radio\" value=\"card\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<CreditCard :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tPay by card\n\t\t\t</NcActionButton>\n\t\t\t<NcActionSeparator />\n\t\t\t<NcActionButton type=\"radio\" :model-value=\"align.isLeft\" @update:modelValue=\"setAlign('Left', $event)\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<FormatAlignLeft :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tLeft\n\t\t\t</NcActionButton>\n\t\t\t<NcActionButton type=\"radio\" :model-value=\"align.isCenter\" @update:modelValue=\"setAlign('Center', $event)\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<FormatAlignCenter :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tCenter\n\t\t\t</NcActionButton>\n\t\t\t<NcActionButton type=\"radio\" :model-value=\"align.isRight\" @update:modelValue=\"setAlign('Right', $event)\">\n\t\t\t\t<template #icon>\n\t\t\t\t\t<FormatAlignRight :size=\"20\" />\n\t\t\t\t</template>\n\t\t\t\tRight\n\t\t\t</NcActionButton>\n\t\t</NcActions>\n\t\t<p>payment = \"{{ payment }}\"</p>\n\t\t<p>align.isLeft = {{ align.isLeft }}</p>\n\t\t<p>align.isCenter = {{ align.isCenter }}</p>\n\t\t<p>align.isRight = {{ align.isRight }}</p>\n\t</div>\n</template>\n<script>\nimport Cash from 'vue-material-design-icons/Cash.vue'\nimport CreditCard from 'vue-material-design-icons/CreditCard.vue'\nimport FormatAlignLeft from 'vue-material-design-icons/FormatAlignLeft.vue'\nimport FormatAlignCenter from 'vue-material-design-icons/FormatAlignCenter.vue'\nimport FormatAlignRight from 'vue-material-design-icons/FormatAlignRight.vue'\n\nexport default {\n\tcomponents: {\n\t\tCash,\n\t\tCreditCard,\n\t\tFormatAlignLeft,\n\t\tFormatAlignCenter,\n\t\tFormatAlignRight,\n\t},\n\tdata() {\n\t\treturn {\n\t\t\tpayment: 'card',\n\t\t\talign: {\n\t\t\t\tisLeft: false,\n\t\t\t\tisCenter: true,\n\t\t\t\tisRight: false,\n\t\t\t},\n\t\t}\n\t},\n\tmethods: {\n\t\tsetAlign(direction, value) {\n\t\t\tthis.align.isLeft = false\n\t\t\tthis.align.isCenter = false\n\t\t\tthis.align.isRight = false\n\t\t\tthis.align[`is${direction}`] = value\n\t\t},\n\t}\n}\n</script>\n```\n</docs>\n\n<template>\n\t<li class=\"action\" :class=\"{ 'action--disabled': disabled }\" :role=\"isInSemanticMenu && 'presentation'\">\n\t\t<button :aria-label=\"ariaLabel\"\n\t\t\t:class=\"['action-button button-vue', {\n\t\t\t\t'action-button--active': isChecked,\n\t\t\t\tfocusable: isFocusable,\n\t\t\t}]\"\n\t\t\t:disabled=\"disabled\"\n\t\t\t:title=\"title\"\n\t\t\t:type=\"nativeType\"\n\t\t\tv-bind=\"buttonAttributes\"\n\t\t\t@click=\"handleClick\">\n\t\t\t<!-- @slot Manually provide icon -->\n\t\t\t<slot name=\"icon\">\n\t\t\t\t<span :class=\"[isIconUrl ? 'action-button__icon--url' : icon]\"\n\t\t\t\t\t:style=\"{ backgroundImage: isIconUrl ? `url(${icon})` : null }\"\n\t\t\t\t\taria-hidden=\"true\"\n\t\t\t\t\tclass=\"action-button__icon\" />\n\t\t\t</slot>\n\n\t\t\t<!-- long text with name -->\n\t\t\t<span v-if=\"name\"\n\t\t\t\tclass=\"action-button__longtext-wrapper\">\n\t\t\t\t<strong class=\"action-button__name\">\n\t\t\t\t\t{{ name }}\n\t\t\t\t</strong>\n\t\t\t\t<br>\n\t\t\t\t<!-- white space is shown on longtext, so we can't\n\t\t\t\t\tput {{ text }} on a new line for code readability -->\n\t\t\t\t<span class=\"action-button__longtext\" v-text=\"text\" />\n\t\t\t</span>\n\n\t\t\t<!-- long text only -->\n\t\t\t<!-- white space is shown on longtext, so we can't\n\t\t\t\tput {{ text }} on a new line for code readability -->\n\t\t\t<span v-else-if=\"isLongText\"\n\t\t\t\tclass=\"action-button__longtext\"\n\t\t\t\tv-text=\"text\" />\n\n\t\t\t<!-- default text display -->\n\t\t\t<span v-else class=\"action-button__text\">{{ text }}</span>\n\n\t\t\t<!-- right(in LTR) or left(in RTL) arrow icon when there is a sub-menu -->\n\t\t\t<ChevronRightIcon v-if=\"isMenu && !isRtl\" :size=\"20\" class=\"action-button__menu-icon\" />\n\t\t\t<ChevronLeftIcon v-else-if=\"isMenu && isRtl\" :size=\"20\" class=\"action-button__menu-icon\" />\n\t\t\t<CheckIcon v-else-if=\"isChecked === true\" :size=\"20\" class=\"action-button__pressed-icon\" />\n\t\t\t<span v-else-if=\"isChecked === false\" class=\"action-button__pressed-icon material-design-icon\" />\n\n\t\t\t<!-- fake slot to gather inner text -->\n\t\t\t<slot v-if=\"false\" />\n\t\t</button>\n\t</li>\n</template>\n\n<script>\nimport CheckIcon from 'vue-material-design-icons/Check.vue'\nimport ChevronRightIcon from 'vue-material-design-icons/ChevronRight.vue'\nimport ChevronLeftIcon from 'vue-material-design-icons/ChevronLeft.vue'\nimport ActionTextMixin from '../../mixins/actionText.js'\nimport { isRtl } from '../../utils/rtl.ts'\n\n/**\n * Button component to be used in Actions\n */\nexport default {\n\tname: 'NcActionButton',\n\n\tcomponents: {\n\t\tCheckIcon,\n\t\tChevronRightIcon,\n\t\tChevronLeftIcon,\n\t},\n\tmixins: [ActionTextMixin],\n\n\tinject: {\n\t\tisInSemanticMenu: {\n\t\t\tfrom: 'NcActions:isSemanticMenu',\n\t\t\tdefault: false,\n\t\t},\n\t},\n\n\tprops: {\n\t\t/**\n\t\t * @deprecated To be removed in @nextcloud/vue 9. Migration guide: remove ariaHidden prop from NcAction* components.\n\t\t * @todo Add a check in @nextcloud/vue 9 that this prop is not provided,\n\t\t * otherwise root element will inherit incorrect aria-hidden.\n\t\t */\n\t\tariaHidden: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: null,\n\t\t},\n\n\t\t/**\n\t\t * disabled state of the action button\n\t\t */\n\t\tdisabled: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: false,\n\t\t},\n\n\t\t/**\n\t\t * If this is a menu, a chevron icon will\n\t\t * be added at the end of the line\n\t\t */\n\t\tisMenu: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: false,\n\t\t},\n\n\t\t/**\n\t\t * The button's behavior, by default the button acts like a normal button with optional toggle button behavior if `modelValue` is `true` or `false`.\n\t\t * But you can also set to checkbox button behavior with tri-state or radio button like behavior.\n\t\t * This extends the native HTML button type attribute.\n\t\t */\n\t\ttype: {\n\t\t\ttype: String,\n\t\t\tdefault: 'button',\n\t\t\tvalidator: (behavior) => ['button', 'checkbox', 'radio', 'reset', 'submit'].includes(behavior),\n\t\t},\n\n\t\t/**\n\t\t * The buttons state if `type` is 'checkbox' or 'radio' (meaning if it is pressed / selected).\n\t\t * For checkbox and toggle button behavior - boolean value.\n\t\t * For radio button behavior - could be a boolean checked or a string with the value of the button.\n\t\t * Note: Unlike native radio buttons, NcActionButton are not grouped by name, so you need to connect them by bind correct modelValue.\n\t\t *\n\t\t * **This is not availabe for `type='submit'` or `type='reset'`**\n\t\t *\n\t\t * If using `type='checkbox'` a `model-value` of `true` means checked, `false` means unchecked and `null` means indeterminate (tri-state)\n\t\t * For `type='radio'` `null` is equal to `false`\n\t\t */\n\t\tmodelValue: {\n\t\t\ttype: [Boolean, String],\n\t\t\tdefault: null,\n\t\t},\n\n\t\t/**\n\t\t * The value used for the `modelValue` when this component is used with radio behavior\n\t\t * Similar to the `value` attribute of `<input type=\"radio\">`\n\t\t */\n\t\tvalue: {\n\t\t\ttype: String,\n\t\t\tdefault: null,\n\t\t},\n\t},\n\tsetup() {\n\t\treturn {\n\t\t\tisRtl,\n\t\t}\n\t},\n\n\tcomputed: {\n\t\t/**\n\t\t * determines if the action is focusable\n\t\t *\n\t\t * @return {boolean} is the action focusable ?\n\t\t */\n\t\tisFocusable() {\n\t\t\treturn !this.disabled\n\t\t},\n\n\t\t/**\n\t\t * The current \"checked\" or \"pressed\" state for the model behavior\n\t\t */\n\t\tisChecked() {\n\t\t\tif (this.type === 'radio' && typeof this.modelValue !== 'boolean') {\n\t\t\t\treturn this.modelValue === this.value\n\t\t\t}\n\t\t\treturn this.modelValue\n\t\t},\n\n\t\t/**\n\t\t * The native HTML type to set on the button\n\t\t */\n\t\tnativeType() {\n\t\t\tif (this.type === 'submit' || this.type === 'reset') {\n\t\t\t\treturn this.type\n\t\t\t}\n\t\t\treturn 'button'\n\t\t},\n\n\t\t/**\n\t\t * HTML attributes to bind to the <button>\n\t\t */\n\t\tbuttonAttributes() {\n\t\t\tconst attributes = {}\n\n\t\t\tif (this.isInSemanticMenu) {\n\t\t\t\t// By default it needs to be a menu item in semantic menus\n\t\t\t\tattributes.role = 'menuitem'\n\n\t\t\t\tif (this.type === 'radio') {\n\t\t\t\t\tattributes.role = 'menuitemradio'\n\t\t\t\t\tattributes['aria-checked'] = this.isChecked ? 'true' : 'false'\n\t\t\t\t} else if (this.type === 'checkbox' || (this.nativeType === 'button' && this.modelValue !== null)) {\n\t\t\t\t\t// either if checkbox behavior was set or the model value is not unset\n\t\t\t\t\tattributes.role = 'menuitemcheckbox'\n\t\t\t\t\tattributes['aria-checked'] = this.modelValue === null ? 'mixed' : (this.modelValue ? 'true' : 'false')\n\t\t\t\t}\n\t\t\t} else if (this.modelValue !== null && this.nativeType === 'button') {\n\t\t\t\t// In case this has a modelValue it is considered a toggle button, so we need to set the aria-pressed\n\t\t\t\tattributes['aria-pressed'] = this.modelValue ? 'true' : 'false'\n\t\t\t}\n\n\t\t\treturn attributes\n\t\t},\n\t},\n\n\tmethods: {\n\t\t/**\n\t\t * Forward click event, let mixin handle the close-after-click and emit new modelValue if needed\n\t\t * @param {MouseEvent} event The click event\n\t\t */\n\t\thandleClick(event) {\n\t\t\tthis.onClick(event)\n\t\t\t// If modelValue or type is set (so modelValue might be null for tri-state) we need to update it\n\t\t\tif (this.modelValue !== null || this.type !== 'button') {\n\t\t\t\tif (this.type === 'radio') {\n\t\t\t\t\tif (typeof this.modelValue !== 'boolean') {\n\t\t\t\t\t\t// String-value radios behavior is similar to native - click on checked radio does nothing\n\t\t\t\t\t\tif (!this.isChecked) {\n\t\t\t\t\t\t\tthis.$emit('update:modelValue', this.value)\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\t// Boolean radio allows to uncheck\n\t\t\t\t\t\tthis.$emit('update:modelValue', !this.isChecked)\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\t// Checkbox toggles value\n\t\t\t\t\tthis.$emit('update:modelValue', !this.isChecked)\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\t},\n}\n</script>\n\n<style lang=\"scss\" scoped>\n@import '../../assets/action';\n@include action-active;\n@include action--disabled;\n@include action-item('button');\n\n.action-button__pressed-icon {\n\tmargin-inline: auto calc($icon-margin * -1);\n}\n</style>\n"],"names":["CheckIcon","ChevronRightIcon","ChevronLeftIcon","ActionTextMixin","isRtl"],"mappings":";;;;;;;AA0XA,MAAA,YAAA;AAAA,EACA,MAAA;AAAA,EAEA,YAAA;AAAA,IACA,WAAAA,MAAA;AAAA,IACA,kBAAAC,aAAA;AAAA,IACA,iBAAAC,YAAA;AAAA,EACA;AAAA,EACA,QAAA,CAAAC,WAAAA,eAAA;AAAA,EAEA,QAAA;AAAA,IACA,kBAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA,EACA;AAAA,EAEA,OAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAMA,YAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA,IAKA,UAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA,IAMA,QAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAOA,MAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,MACA,WAAA,CAAA,aAAA,CAAA,UAAA,YAAA,SAAA,SAAA,QAAA,EAAA,SAAA,QAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAaA,YAAA;AAAA,MACA,MAAA,CAAA,SAAA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA,IAMA,OAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA,EACA;AAAA,EACA,QAAA;AACA,WAAA;AAAA,MACA,OAAAC,IAAA;AAAA,IACA;AAAA,EACA;AAAA,EAEA,UAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IA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AA,KAAA,SAAA;AAAA,QACA;AAAA,MACA;AAAA,IACA;AAAA,EACA;AACA;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"NcAppContent-DiOscHZ8.mjs","sources":["../../src/components/NcAppContent/NcAppDetailsToggle.vue","../../src/components/NcAppContent/NcAppContent.vue"],"sourcesContent":["<!--\n - SPDX-FileCopyrightText: 2019 Nextcloud GmbH and Nextcloud contributors\n - SPDX-License-Identifier: AGPL-3.0-or-later\n-->\n\n<template>\n\t<NcButton v-tooltip=\"title\"\n\t\tclass=\"app-details-toggle\"\n\t\t:class=\"{ 'app-details-toggle--mobile': isMobile }\"\n\t\t:aria-label=\"title\"\n\t\tvariant=\"tertiary\">\n\t\t<template #icon>\n\t\t\t<ArrowLeft v-if=\"isRtl\" :size=\"20\" />\n\t\t\t<ArrowRight v-else :size=\"20\" />\n\t\t</template>\n\t</NcButton>\n</template>\n\n<script>\nimport NcButton from '../NcButton/index.js'\nimport { t } from '../../l10n.js'\nimport Tooltip from '../../directives/Tooltip/index.js'\n\nimport { emit } from '@nextcloud/event-bus'\n\nimport ArrowRight from 'vue-material-design-icons/ArrowRight.vue'\nimport ArrowLeft from 'vue-material-design-icons/ArrowLeft.vue'\n\nimport { useIsMobile } from '../../composables/useIsMobile/index.js'\nimport { isRtl } from '../../utils/rtl.ts'\n\nexport default {\n\tname: 'NcAppDetailsToggle',\n\n\tdirectives: {\n\t\ttooltip: Tooltip,\n\t},\n\n\tcomponents: {\n\t\tNcButton,\n\t\tArrowRight,\n\t\tArrowLeft,\n\t},\n\tsetup() {\n\t\treturn {\n\t\t\tisRtl,\n\t\t\tisMobile: useIsMobile(),\n\t\t}\n\t},\n\n\tcomputed: {\n\t\ttitle() {\n\t\t\treturn t('Go back to the list')\n\t\t},\n\t},\n\twatch: {\n\t\tisMobile: {\n\t\t\timmediate: true,\n\t\t\thandler() {\n\t\t\t\tthis.toggleAppNavigationButton(this.isMobile)\n\t\t\t},\n\t\t},\n\t},\n\n\tbeforeDestroy() {\n\t\tif (this.isMobile) {\n\t\t\tthis.toggleAppNavigationButton(false)\n\t\t}\n\t},\n\n\tmethods: {\n\t\ttoggleAppNavigationButton(hide = true) {\n\t\t\tconst appNavigationToggle = document.querySelector('.app-navigation .app-navigation-toggle')\n\t\t\tif (appNavigationToggle) {\n\t\t\t\tappNavigationToggle.style.display = hide ? 'none' : null\n\n\t\t\t\t// If we hide the NavigationToggle, we need to make sure the Navigation is also closed\n\t\t\t\tif (hide === true) {\n\t\t\t\t\temit('toggle-navigation', { open: false })\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\t},\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.app-details-toggle {\n\tposition: sticky;\n\twidth: var(--default-clickable-area);\n\theight: var(--default-clickable-area);\n\tpadding: $icon-margin;\n\tcursor: pointer;\n\topacity: .6;\n\ttransform: rotate(180deg);\n\tbackground-color: var(--color-main-background);\n\tz-index: 2000;\n\n\ttop: var(--app-navigation-padding);\n\t// Navigation Toggle button width + 2 paddings around\n\tinset-inline-start: calc(var(--default-clickable-area) + var(--app-navigation-padding) * 2);\n\t&--mobile {\n\t\t// There is no NavigationToggle button\n\t\tinset-inline-start: var(--app-navigation-padding);\n\t}\n\n\t&:active,\n\t&:hover,\n\t&:focus {\n\t\topacity: 1;\n\t}\n}\n\n</style>\n","<!--\n - SPDX-FileCopyrightText: 2019 Nextcloud GmbH and Nextcloud contributors\n - SPDX-License-Identifier: AGPL-3.0-or-later\n-->\n\n<docs>\n### General description\n\nThis components provides a wrapper around the main app's content.\n\nSingle-column layouts can just use the default slot. A resizable column\ncan be added by providing content to the named slot `list`.\n\n### CSS variables\nIn the css section some css variables are declared and will be available for\nall the children of the NcAppContent component\n\n### Examples\n\n#### Usage: Single-column content\n```vue\n<template>\n\t<NcAppContent>\n\t\t<h2>Single-column main content</h2>\n\t</NcAppContent>\n</template>\n```\n\n#### Usage: Two resizable columns\n```vue\n<template>\n\t<NcAppContent>\n\t\t<template #list>\n\t\t\t<div>Resizable list content</div>\n\t\t</template>\n\n\t\t<div>Main content</div>\n\t</NcAppContent>\n</template>\n```\n\n#### Overriding Defaults\nThe default, min and max sizes (in percent) of the resizable list column can be overridden.\nThe list size must be between the min and the max width value.\n\n```\n<NcAppContent\n\t:list-size=\"35\"\n\t:list-min-width=\"20\"\n\t:list-max-width=\"45\"\n>...</NcAppContent>\n```\n\n#### Usage: Custom document title\nFor accessibility reasons every document should have a `h1` heading,\nthis is visually hidden, but required for a semantically correct document.\nYou can use your app name or current view for the heading.\n\nAdditionally you can set a custom document title, e.g. to show the current status.\n\n```vue\n<template>\n\t<NcAppContent :pageHeading=\"heading ? 'Heading' : undefined\" :pageTitle=\"title ? 'Title' : undefined\" >\n\t\t<NcCheckboxRadioSwitch type=\"switch\" :checked.sync=\"title\">\n\t\t\tToggle title\n\t\t</NcCheckboxRadioSwitch>\n\t\t<NcCheckboxRadioSwitch type=\"switch\" :checked.sync=\"heading\">\n\t\t\tToggle Heading\n\t\t</NcCheckboxRadioSwitch>\n\t\t<NcButton @click=\"reset\">Reset</NcButton>\n\t</NcAppContent>\n</template>\n\n<script>\nexport default {\n\tdata() {\n\t\treturn {\n\t\t\theading: false,\n\t\t\ttitle: false,\n\t\t}\n\t},\n\tmethods: {\n\t\treset() {\n\t\t\tthis.heading = false\n\t\t\tthis.title = false\n\t\t\tdocument.title = ''\n\t\t},\n\t},\n}\n</script>\n```\n</docs>\n\n<template>\n\t<main id=\"app-content-vue\" class=\"app-content no-snapper\" :class=\"{ 'app-content--has-list': hasList }\">\n\t\t<h1 v-if=\"pageHeading\" class=\"hidden-visually\">\n\t\t\t{{ pageHeading }}\n\t\t</h1>\n\n\t\t<template v-if=\"hasList\">\n\t\t\t<!-- Mobile view does not allow resizeable panes -->\n\t\t\t<div v-if=\"isMobile || layout === 'no-split'\"\n\t\t\t\tclass=\"app-content-wrapper app-content-wrapper--no-split\"\n\t\t\t\t:class=\"{\n\t\t\t\t\t'app-content-wrapper--show-details': showDetails,\n\t\t\t\t\t'app-content-wrapper--show-list': !showDetails,\n\t\t\t\t\t'app-content-wrapper--mobile': isMobile,}\">\n\t\t\t\t<NcAppDetailsToggle v-if=\"showDetails\" @click.native.stop.prevent=\"hideDetails\" />\n\n\t\t\t\t<slot v-if=\"!showDetails\" name=\"list\" />\n\t\t\t\t<slot v-else />\n\t\t\t</div>\n\t\t\t<div v-else-if=\"layout === 'vertical-split' || layout === 'horizontal-split'\" class=\"app-content-wrapper\">\n\t\t\t\t<Splitpanes :horizontal=\"layout === 'horizontal-split'\"\n\t\t\t\t\tclass=\"default-theme\"\n\t\t\t\t\t:class=\"{ 'splitpanes--horizontal': layout === 'horizontal-split',\n\t\t\t\t\t\t'splitpanes--vertical': layout === 'vertical-split'\n\t\t\t\t\t}\"\n\t\t\t\t\t:rtl=\"isRtl\"\n\t\t\t\t\t@resized=\"handlePaneResize\">\n\t\t\t\t\t<Pane class=\"splitpanes__pane-list\"\n\t\t\t\t\t\t:size=\"listPaneSize || paneDefaults.list.size\"\n\t\t\t\t\t\t:min-size=\"paneDefaults.list.min\"\n\t\t\t\t\t\t:max-size=\"paneDefaults.list.max\">\n\t\t\t\t\t\t<!-- @slot Provide a list to the app content -->\n\t\t\t\t\t\t<slot name=\"list\" />\n\t\t\t\t\t</Pane>\n\n\t\t\t\t\t<Pane class=\"splitpanes__pane-details\"\n\t\t\t\t\t\t:size=\"detailsPaneSize\"\n\t\t\t\t\t\t:min-size=\"paneDefaults.details.min\"\n\t\t\t\t\t\t:max-size=\"paneDefaults.details.max\">\n\t\t\t\t\t\t<!-- @slot Provide the main content to the app content -->\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</Pane>\n\t\t\t\t</Splitpanes>\n\t\t\t</div>\n\t\t</template>\n\t\t<!-- @slot Provide the main content to the app content -->\n\t\t<slot v-if=\"!hasList\" />\n\t</main>\n</template>\n\n<script>\nimport { getBuilder } from '@nextcloud/browser-storage'\nimport { emit } from '@nextcloud/event-bus'\nimport { loadState } from '@nextcloud/initial-state'\nimport { useSwipe } from '@vueuse/core'\nimport { Splitpanes, Pane } from 'splitpanes'\nimport { useIsMobile } from '../../composables/useIsMobile/index.js'\nimport { isRtl } from '../../utils/rtl.ts'\n\nimport NcAppDetailsToggle from './NcAppDetailsToggle.vue'\n\nimport 'splitpanes/dist/splitpanes.css'\n\nconst browserStorage = getBuilder('nextcloud').persist().build()\nconst { name: productName } = loadState('theming', 'data', { name: 'Nextcloud' })\nconst activeApp = loadState('core', 'active-app', appName)\nconst localizedAppName = loadState('core', 'apps', {})[activeApp]?.name ?? appName\n\n/**\n * App content container to be used for the main content of your app\n *\n */\nexport default {\n\tname: 'NcAppContent',\n\n\tcomponents: {\n\t\tNcAppDetailsToggle,\n\t\tPane,\n\t\tSplitpanes,\n\t},\n\tprops: {\n\t\t/**\n\t\t * Allows to disable the control by swipe of the app navigation open state\n\t\t * @deprecated will be removed with the next version - use `disableSwipe` instead\n\t\t */\n\t\tallowSwipeNavigation: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: true,\n\t\t},\n\n\t\t/**\n\t\t * Allows to disable the control by swipe of the app navigation open state.\n\t\t */\n\t\tdisableSwipe: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: false,\n\t\t},\n\n\t\t/**\n\t\t * Allows you to set the default width of the resizable list in % on vertical-split\n\t\t * Allows you to set the default height of the resizable list in % on horizontal-split\n\t\t * Must be between listMinWidth and listMaxWidth\n\t\t */\n\t\tlistSize: {\n\t\t\ttype: Number,\n\t\t\tdefault: 20,\n\t\t},\n\n\t\t/**\n\t\t * Allows you to set the minimum width of the list column in % on vertical-split\n\t\t * Allows you to set the minimum height of the list column in % on horizontal-split\n\t\t */\n\t\tlistMinWidth: {\n\t\t\ttype: Number,\n\t\t\tdefault: 15,\n\t\t},\n\n\t\t/**\n\t\t * Allows you to set the maximum width of the list column in % on vertical-split\n\t\t * Allows you to set the maximum height of the list column in % on horizontal-split\n\t\t */\n\t\tlistMaxWidth: {\n\t\t\ttype: Number,\n\t\t\tdefault: 40,\n\t\t},\n\n\t\t/**\n\t\t * Specify the config key for the pane config sizes\n\t\t * Default is the global var appName if you use the webpack-vue-config\n\t\t */\n\t\tpaneConfigKey: {\n\t\t\ttype: String,\n\t\t\tdefault: '',\n\t\t},\n\n\t\t/**\n\t\t * When in mobile view, only the list or the details are shown.\n\t\t *\n\t\t * If you provide a list, you need to provide a variable\n\t\t * that will be set to true by the user when an element of\n\t\t * the list gets selected. The details will then show a back\n\t\t * arrow to return to the list that will update this prop to false.\n\t\t */\n\t\tshowDetails: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: true,\n\t\t},\n\n\t\t/**\n\t\t * Specify the `<h1>` page heading\n\t\t */\n\t\tpageHeading: {\n\t\t\ttype: String,\n\t\t\tdefault: null,\n\t\t},\n\t\t/**\n\t\t * Content layout used when there is a list together with content:\n\t\t * - `vertical-split` - a 2-column layout with list and default content separated vertically\n\t\t * - `no-split` - a single column layout; List is shown when `showDetails` is `false`, otherwise the default slot content is shown with a back button to return to the list.\n\t\t * - 'horizontal-split' - a 2-column layout with list and default content separated horizontally\n\t\t * On mobile screen `no-split` layout is forced.\n\t\t */\n\t\tlayout: {\n\t\t\ttype: String,\n\t\t\tdefault: 'vertical-split',\n\t\t\tvalidator(value) {\n\t\t\t\treturn ['no-split', 'vertical-split', 'horizontal-split'].includes(value)\n\t\t\t},\n\t\t},\n\n\t\t/**\n\t\t * Allow setting the page's `<title>`\n\t\t *\n\t\t * If a page heading is set it defaults to `{pageHeading} - {appName} - {productName}` e.g. `Favorites - Files - Nextcloud`.\n\t\t * When the page heading and the app name is the same only one is used, e.g. `Files - Files - Nextcloud` is shown as `Files - Nextcloud`.\n\t\t * When setting the prop then the following format will be used: `{pageTitle} - {pageHeading || appName} - {productName}`\n\t\t */\n\t\tpageTitle: {\n\t\t\ttype: String,\n\t\t\tdefault: null,\n\t\t},\n\t},\n\n\temits: [\n\t\t'update:showDetails',\n\t\t'resize:list',\n\t],\n\n\tsetup() {\n\t\treturn {\n\t\t\tisMobile: useIsMobile(),\n\t\t\tisRtl,\n\t\t}\n\t},\n\n\tdata() {\n\t\treturn {\n\t\t\tcontentHeight: 0,\n\t\t\thasList: false,\n\t\t\thasContent: false,\n\t\t\tswiping: {},\n\t\t\tlistPaneSize: this.restorePaneConfig(),\n\t\t}\n\t},\n\n\tcomputed: {\n\t\tpaneConfigID() {\n\t\t\t// If provided, let's use it\n\t\t\tif (this.paneConfigKey !== '') {\n\t\t\t\treturn `pane-list-size-${this.paneConfigKey}`\n\t\t\t}\n\n\t\t\ttry {\n\t\t\t\t// Using the webpack-vue-config, appName is a global variable\n\t\t\t\t// This will throw a ReferenceError when the global variable is missing\n\t\t\t\t// In that case either you provide paneConfigKey or else it fallback\n\t\t\t\t// to a global storage key\n\t\t\t\treturn `pane-list-size-${appName}`\n\t\t\t} catch (e) {\n\t\t\t\tconsole.info('[INFO] AppContent:', 'falling back to global nextcloud pane config')\n\t\t\t\treturn 'pane-list-size-nextcloud'\n\t\t\t}\n\t\t},\n\n\t\tdetailsPaneSize() {\n\t\t\tif (this.listPaneSize) {\n\t\t\t\treturn 100 - this.listPaneSize\n\t\t\t}\n\t\t\treturn this.paneDefaults.details.size\n\t\t},\n\n\t\tpaneDefaults() {\n\t\t\treturn {\n\t\t\t\tlist: {\n\t\t\t\t\tsize: this.listSize,\n\t\t\t\t\tmin: this.listMinWidth,\n\t\t\t\t\tmax: this.listMaxWidth,\n\t\t\t\t},\n\n\t\t\t\t// set the inverse values of the details column\n\t\t\t\t// based on the provided (or default) values of the list column\n\t\t\t\tdetails: {\n\t\t\t\t\tsize: 100 - this.listSize,\n\t\t\t\t\tmin: 100 - this.listMaxWidth,\n\t\t\t\t\tmax: 100 - this.listMinWidth,\n\t\t\t\t},\n\t\t\t}\n\t\t},\n\n\t\trealPageTitle() {\n\t\t\tconst entries = new Set()\n\t\t\tif (this.pageTitle) {\n\t\t\t\tentries.add(this.pageTitle)\n\t\t\t}\n\t\t\tif (this.pageHeading) {\n\t\t\t\tentries.add(this.pageHeading)\n\t\t\t}\n\t\t\tif (entries.size === 0) {\n\t\t\t\treturn null\n\t\t\t}\n\n\t\t\tif (entries.size < 2) {\n\t\t\t\t// Only add if not already pageHeading and pageTitle are included\n\t\t\t\tentries.add(localizedAppName)\n\t\t\t}\n\t\t\tentries.add(productName)\n\t\t\treturn [...entries.values()].join(' - ')\n\t\t},\n\t},\n\n\twatch: {\n\t\trealPageTitle: {\n\t\t\timmediate: true,\n\t\t\thandler() {\n\t\t\t\tif (this.realPageTitle !== null) {\n\t\t\t\t\tdocument.title = this.realPageTitle\n\t\t\t\t}\n\t\t\t},\n\t\t},\n\t},\n\n\tupdated() {\n\t\tthis.checkSlots()\n\t},\n\n\tmounted() {\n\t\tif (this.allowSwipeNavigation && !this.disableSwipe) {\n\t\t\tthis.swiping = useSwipe(this.$el, {\n\t\t\t\tonSwipeEnd: this.handleSwipe,\n\t\t\t})\n\t\t}\n\n\t\tthis.checkSlots()\n\t\tthis.restorePaneConfig()\n\t},\n\n\tmethods: {\n\t\t/**\n\t\t * handle the swipe event\n\t\t *\n\t\t * @param {TouchEvent} e The touch event\n\t\t * @param {import('@vueuse/core').SwipeDirection} direction The swipe direction of the event\n\t\t */\n\t\thandleSwipe(e, direction) {\n\t\t\tconst minSwipeX = 70\n\t\t\tconst touchZone = 300\n\t\t\tif (Math.abs(this.swiping.lengthX) > minSwipeX) {\n\t\t\t\tif (this.swiping.coordsStart.x < (touchZone / 2) && direction === 'right') {\n\t\t\t\t\temit('toggle-navigation', {\n\t\t\t\t\t\topen: true,\n\t\t\t\t\t})\n\t\t\t\t} else if (this.swiping.coordsStart.x < touchZone * 1.5 && direction === 'left') {\n\t\t\t\t\temit('toggle-navigation', {\n\t\t\t\t\t\topen: false,\n\t\t\t\t\t})\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\n\t\thandlePaneResize(event) {\n\t\t\tconst listPaneSize = parseInt(event[0].size, 10)\n\t\t\tbrowserStorage.setItem(this.paneConfigID, JSON.stringify(listPaneSize))\n\t\t\tthis.listPaneSize = listPaneSize\n\t\t\t/**\n\t\t\t * Emitted when the list pane is resized by the user\n\t\t\t */\n\t\t\tthis.$emit('resize:list', { size: listPaneSize })\n\t\t\tconsole.debug('AppContent pane config', listPaneSize)\n\t\t},\n\n\t\t// $slots is not reactive, we need to update this manually\n\t\tcheckSlots() {\n\t\t\tthis.hasList = !!this.$scopedSlots.list\n\t\t\tthis.hasContent = !!this.$scopedSlots.default\n\t\t},\n\n\t\t// browserStorage is not reactive, we need to update this manually\n\t\trestorePaneConfig() {\n\t\t\tconst listPaneSize = parseInt(browserStorage.getItem(this.paneConfigID), 10)\n\t\t\tif (!isNaN(listPaneSize) && listPaneSize !== this.listPaneSize) {\n\t\t\t\tconsole.debug('AppContent pane config', listPaneSize)\n\t\t\t\tthis.listPaneSize = listPaneSize\n\t\t\t\treturn listPaneSize\n\t\t\t}\n\t\t},\n\n\t\t/**\n\t\t * The user clicked the back arrow from the details view\n\t\t */\n\t\thideDetails() {\n\t\t\tthis.$emit('update:showDetails', false)\n\t\t},\n\t},\n}\n</script>\n<style lang=\"scss\" scoped>\n\n.app-content {\n\tposition: initial;\n\tz-index: 1000;\n\tflex-basis: 100vw;\n\theight: 100%;\n\t// Overriding server styles TODO: cleanup!\n\tmargin: 0 !important;\n\tbackground-color: var(--color-main-background);\n\tmin-width: 0;\n\n\t&:not(.app-content--has-list) {\n\t\toverflow: auto;\n\t}\n}\n\n.app-content-wrapper {\n\tposition: relative;\n\twidth: 100%;\n\theight: 100%;\n}\n\n// Mobile list/details handling\n.app-content-wrapper--no-split {\n\t&.app-content-wrapper--show-list :deep() {\n\t\t.app-content-list {\n\t\t\tdisplay: flex;\n\t\t}\n\t\t.app-content-details {\n\t\t\tdisplay: none;\n\t\t}\n\t}\n\t&.app-content-wrapper--show-details :deep() {\n\t\t.app-content-list {\n\t\t\tdisplay: none;\n\t\t}\n\t\t.app-content-details {\n\t\t\tdisplay: block;\n\t\t}\n\t}\n}\n\n:deep(.splitpanes.default-theme) {\n\t.app-content-list {\n\t\tmax-width: none;\n\t\t/* Thin scrollbar is hard to catch on resizable columns */\n\t\tscrollbar-width: auto;\n\t}\n\n\t.splitpanes__pane {\n\t\tbackground-color: transparent;\n\t\ttransition: none;\n\n\t\t&-list {\n\t\t\tmin-width: 300px;\n\t\t\tposition: sticky;\n\n\t\t\t@media only screen and (width < $breakpoint-mobile) {\n\t\t\t\tdisplay: none;\n\t\t\t}\n\t\t}\n\n\t\t&-details {\n\t\t\toverflow-y: auto;\n\n\t\t\t@media only screen and (width < $breakpoint-mobile) {\n\t\t\t\tmin-width: 100%;\n\t\t\t}\n\t\t}\n\t}\n\n\t.splitpanes__splitter {\n\t\tbackground-color: var(--color-main-background);\n\t\t&::before, &::after {\n\t\t\tbackground-color: var(--color-border);\n\t\t}\n\t}\n\n\t&.splitpanes--vertical .splitpanes__splitter {\n\t\tborder-left: 1px solid var(--color-border);\n\t}\n\n\t&.splitpanes--horizontal .splitpanes__splitter {\n\t\tborder-top: 1px solid var(--color-border);\n\t}\n}\n\n.app-content-wrapper--show-list {\n\t:deep(.app-content-list) {\n\t\tmax-width: none;\n\t}\n}\n</style>\n"],"names":["_sfc_main","Tooltip"],"mappings":";;;;;;;;;;;;;;;;AA+BA,MAAAA,cAAA;AAAA,EACA,MAAA;AAAA,EAEA,YAAA;AAAA,IACA,SAAAC;AAAAA,EACA;AAAA,EAEA,YAAA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACA;AAAA,EACA,QAAA;AACA,WAAA;AAAA,MACA;AAAA,MACA,UAAA,YAAA;AAAA,IACA;AAAA,EACA;AAAA,EAEA,UAAA;AAAA,IACA,QAAA;AACA,aAAA,EAAA,qBAAA;AAAA,IACA;AAAA,EACA;AAAA,EACA,OAAA;AAAA,IACA,UAAA;AAAA,MACA,WAAA;AAAA,MACA,UAAA;AACA,aAAA,0BAAA,KAAA,QAAA;AAA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AAA,cAAA,SAAA;AACA,eAAA,qBAAA;AAAA,YACA,MAAA;AAAA,UACA,CAAA;AAAA,QACA,WAAA,KAAA,QAAA,YAAA,IAAA,YAAA,OAAA,cAAA,QAAA;AACA,eAAA,qBAAA;AAAA,YACA,MAAA;AAAA,UACA,CAAA;AAAA,QACA;AAAA,MACA;AAAA,IACA;AAAA,IAEA,iBAAA,OAAA;AACA,YAAA,eAAA,SAAA,MAAA,CAAA,EAAA,MAAA,EAAA;AACA,qBAAA,QAAA,KAAA,cAAA,KAAA,UAAA,YAAA,CAAA;AACA,WAAA,eAAA;AAIA,WAAA,MAAA,eAAA,EAAA,MAAA,aAAA,CAAA;AACA,cAAA,MAAA,0BAAA,YAAA;AAAA,IACA;AAAA;AAAA,IAGA,aAAA;AACA,WAAA,UAAA,CAAA,CAAA,KAAA,aAAA;AACA,WAAA,aAAA,CAAA,CAAA,KAAA,aAAA;AAAA,IACA;AAAA;AAAA,IAGA,oBAAA;AACA,YAAA,eAAA,SAAA,eAAA,QAAA,KAAA,YAAA,GAAA,EAAA;AACA,UAAA,CAAA,MAAA,YAAA,KAAA,iBAAA,KAAA,cAAA;AACA,gBAAA,MAAA,0BAAA,YAAA;AACA,aAAA,eAAA;AACA,eAAA;AAAA,MACA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA,IAKA,cAAA;AACA,WAAA,MAAA,sBAAA,KAAA;AAAA,IACA;AAAA,EACA;AACA;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"NcAppContent-PC4RbdhU.cjs","sources":["../../src/components/NcAppContent/NcAppDetailsToggle.vue","../../src/components/NcAppContent/NcAppContent.vue"],"sourcesContent":["<!--\n - SPDX-FileCopyrightText: 2019 Nextcloud GmbH and Nextcloud contributors\n - SPDX-License-Identifier: AGPL-3.0-or-later\n-->\n\n<template>\n\t<NcButton v-tooltip=\"title\"\n\t\tclass=\"app-details-toggle\"\n\t\t:class=\"{ 'app-details-toggle--mobile': isMobile }\"\n\t\t:aria-label=\"title\"\n\t\tvariant=\"tertiary\">\n\t\t<template #icon>\n\t\t\t<ArrowLeft v-if=\"isRtl\" :size=\"20\" />\n\t\t\t<ArrowRight v-else :size=\"20\" />\n\t\t</template>\n\t</NcButton>\n</template>\n\n<script>\nimport NcButton from '../NcButton/index.js'\nimport { t } from '../../l10n.js'\nimport Tooltip from '../../directives/Tooltip/index.js'\n\nimport { emit } from '@nextcloud/event-bus'\n\nimport ArrowRight from 'vue-material-design-icons/ArrowRight.vue'\nimport ArrowLeft from 'vue-material-design-icons/ArrowLeft.vue'\n\nimport { useIsMobile } from '../../composables/useIsMobile/index.js'\nimport { isRtl } from '../../utils/rtl.ts'\n\nexport default {\n\tname: 'NcAppDetailsToggle',\n\n\tdirectives: {\n\t\ttooltip: Tooltip,\n\t},\n\n\tcomponents: {\n\t\tNcButton,\n\t\tArrowRight,\n\t\tArrowLeft,\n\t},\n\tsetup() {\n\t\treturn {\n\t\t\tisRtl,\n\t\t\tisMobile: useIsMobile(),\n\t\t}\n\t},\n\n\tcomputed: {\n\t\ttitle() {\n\t\t\treturn t('Go back to the list')\n\t\t},\n\t},\n\twatch: {\n\t\tisMobile: {\n\t\t\timmediate: true,\n\t\t\thandler() {\n\t\t\t\tthis.toggleAppNavigationButton(this.isMobile)\n\t\t\t},\n\t\t},\n\t},\n\n\tbeforeDestroy() {\n\t\tif (this.isMobile) {\n\t\t\tthis.toggleAppNavigationButton(false)\n\t\t}\n\t},\n\n\tmethods: {\n\t\ttoggleAppNavigationButton(hide = true) {\n\t\t\tconst appNavigationToggle = document.querySelector('.app-navigation .app-navigation-toggle')\n\t\t\tif (appNavigationToggle) {\n\t\t\t\tappNavigationToggle.style.display = hide ? 'none' : null\n\n\t\t\t\t// If we hide the NavigationToggle, we need to make sure the Navigation is also closed\n\t\t\t\tif (hide === true) {\n\t\t\t\t\temit('toggle-navigation', { open: false })\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\t},\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.app-details-toggle {\n\tposition: sticky;\n\twidth: var(--default-clickable-area);\n\theight: var(--default-clickable-area);\n\tpadding: $icon-margin;\n\tcursor: pointer;\n\topacity: .6;\n\ttransform: rotate(180deg);\n\tbackground-color: var(--color-main-background);\n\tz-index: 2000;\n\n\ttop: var(--app-navigation-padding);\n\t// Navigation Toggle button width + 2 paddings around\n\tinset-inline-start: calc(var(--default-clickable-area) + var(--app-navigation-padding) * 2);\n\t&--mobile {\n\t\t// There is no NavigationToggle button\n\t\tinset-inline-start: var(--app-navigation-padding);\n\t}\n\n\t&:active,\n\t&:hover,\n\t&:focus {\n\t\topacity: 1;\n\t}\n}\n\n</style>\n","<!--\n - SPDX-FileCopyrightText: 2019 Nextcloud GmbH and Nextcloud contributors\n - SPDX-License-Identifier: AGPL-3.0-or-later\n-->\n\n<docs>\n### General description\n\nThis components provides a wrapper around the main app's content.\n\nSingle-column layouts can just use the default slot. A resizable column\ncan be added by providing content to the named slot `list`.\n\n### CSS variables\nIn the css section some css variables are declared and will be available for\nall the children of the NcAppContent component\n\n### Examples\n\n#### Usage: Single-column content\n```vue\n<template>\n\t<NcAppContent>\n\t\t<h2>Single-column main content</h2>\n\t</NcAppContent>\n</template>\n```\n\n#### Usage: Two resizable columns\n```vue\n<template>\n\t<NcAppContent>\n\t\t<template #list>\n\t\t\t<div>Resizable list content</div>\n\t\t</template>\n\n\t\t<div>Main content</div>\n\t</NcAppContent>\n</template>\n```\n\n#### Overriding Defaults\nThe default, min and max sizes (in percent) of the resizable list column can be overridden.\nThe list size must be between the min and the max width value.\n\n```\n<NcAppContent\n\t:list-size=\"35\"\n\t:list-min-width=\"20\"\n\t:list-max-width=\"45\"\n>...</NcAppContent>\n```\n\n#### Usage: Custom document title\nFor accessibility reasons every document should have a `h1` heading,\nthis is visually hidden, but required for a semantically correct document.\nYou can use your app name or current view for the heading.\n\nAdditionally you can set a custom document title, e.g. to show the current status.\n\n```vue\n<template>\n\t<NcAppContent :pageHeading=\"heading ? 'Heading' : undefined\" :pageTitle=\"title ? 'Title' : undefined\" >\n\t\t<NcCheckboxRadioSwitch type=\"switch\" :checked.sync=\"title\">\n\t\t\tToggle title\n\t\t</NcCheckboxRadioSwitch>\n\t\t<NcCheckboxRadioSwitch type=\"switch\" :checked.sync=\"heading\">\n\t\t\tToggle Heading\n\t\t</NcCheckboxRadioSwitch>\n\t\t<NcButton @click=\"reset\">Reset</NcButton>\n\t</NcAppContent>\n</template>\n\n<script>\nexport default {\n\tdata() {\n\t\treturn {\n\t\t\theading: false,\n\t\t\ttitle: false,\n\t\t}\n\t},\n\tmethods: {\n\t\treset() {\n\t\t\tthis.heading = false\n\t\t\tthis.title = false\n\t\t\tdocument.title = ''\n\t\t},\n\t},\n}\n</script>\n```\n</docs>\n\n<template>\n\t<main id=\"app-content-vue\" class=\"app-content no-snapper\" :class=\"{ 'app-content--has-list': hasList }\">\n\t\t<h1 v-if=\"pageHeading\" class=\"hidden-visually\">\n\t\t\t{{ pageHeading }}\n\t\t</h1>\n\n\t\t<template v-if=\"hasList\">\n\t\t\t<!-- Mobile view does not allow resizeable panes -->\n\t\t\t<div v-if=\"isMobile || layout === 'no-split'\"\n\t\t\t\tclass=\"app-content-wrapper app-content-wrapper--no-split\"\n\t\t\t\t:class=\"{\n\t\t\t\t\t'app-content-wrapper--show-details': showDetails,\n\t\t\t\t\t'app-content-wrapper--show-list': !showDetails,\n\t\t\t\t\t'app-content-wrapper--mobile': isMobile,}\">\n\t\t\t\t<NcAppDetailsToggle v-if=\"showDetails\" @click.native.stop.prevent=\"hideDetails\" />\n\n\t\t\t\t<slot v-if=\"!showDetails\" name=\"list\" />\n\t\t\t\t<slot v-else />\n\t\t\t</div>\n\t\t\t<div v-else-if=\"layout === 'vertical-split' || layout === 'horizontal-split'\" class=\"app-content-wrapper\">\n\t\t\t\t<Splitpanes :horizontal=\"layout === 'horizontal-split'\"\n\t\t\t\t\tclass=\"default-theme\"\n\t\t\t\t\t:class=\"{ 'splitpanes--horizontal': layout === 'horizontal-split',\n\t\t\t\t\t\t'splitpanes--vertical': layout === 'vertical-split'\n\t\t\t\t\t}\"\n\t\t\t\t\t:rtl=\"isRtl\"\n\t\t\t\t\t@resized=\"handlePaneResize\">\n\t\t\t\t\t<Pane class=\"splitpanes__pane-list\"\n\t\t\t\t\t\t:size=\"listPaneSize || paneDefaults.list.size\"\n\t\t\t\t\t\t:min-size=\"paneDefaults.list.min\"\n\t\t\t\t\t\t:max-size=\"paneDefaults.list.max\">\n\t\t\t\t\t\t<!-- @slot Provide a list to the app content -->\n\t\t\t\t\t\t<slot name=\"list\" />\n\t\t\t\t\t</Pane>\n\n\t\t\t\t\t<Pane class=\"splitpanes__pane-details\"\n\t\t\t\t\t\t:size=\"detailsPaneSize\"\n\t\t\t\t\t\t:min-size=\"paneDefaults.details.min\"\n\t\t\t\t\t\t:max-size=\"paneDefaults.details.max\">\n\t\t\t\t\t\t<!-- @slot Provide the main content to the app content -->\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</Pane>\n\t\t\t\t</Splitpanes>\n\t\t\t</div>\n\t\t</template>\n\t\t<!-- @slot Provide the main content to the app content -->\n\t\t<slot v-if=\"!hasList\" />\n\t</main>\n</template>\n\n<script>\nimport { getBuilder } from '@nextcloud/browser-storage'\nimport { emit } from '@nextcloud/event-bus'\nimport { loadState } from '@nextcloud/initial-state'\nimport { useSwipe } from '@vueuse/core'\nimport { Splitpanes, Pane } from 'splitpanes'\nimport { useIsMobile } from '../../composables/useIsMobile/index.js'\nimport { isRtl } from '../../utils/rtl.ts'\n\nimport NcAppDetailsToggle from './NcAppDetailsToggle.vue'\n\nimport 'splitpanes/dist/splitpanes.css'\n\nconst browserStorage = getBuilder('nextcloud').persist().build()\nconst { name: productName } = loadState('theming', 'data', { name: 'Nextcloud' })\nconst activeApp = loadState('core', 'active-app', appName)\nconst localizedAppName = loadState('core', 'apps', {})[activeApp]?.name ?? appName\n\n/**\n * App content container to be used for the main content of your app\n *\n */\nexport default {\n\tname: 'NcAppContent',\n\n\tcomponents: {\n\t\tNcAppDetailsToggle,\n\t\tPane,\n\t\tSplitpanes,\n\t},\n\tprops: {\n\t\t/**\n\t\t * Allows to disable the control by swipe of the app navigation open state\n\t\t * @deprecated will be removed with the next version - use `disableSwipe` instead\n\t\t */\n\t\tallowSwipeNavigation: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: true,\n\t\t},\n\n\t\t/**\n\t\t * Allows to disable the control by swipe of the app navigation open state.\n\t\t */\n\t\tdisableSwipe: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: false,\n\t\t},\n\n\t\t/**\n\t\t * Allows you to set the default width of the resizable list in % on vertical-split\n\t\t * Allows you to set the default height of the resizable list in % on horizontal-split\n\t\t * Must be between listMinWidth and listMaxWidth\n\t\t */\n\t\tlistSize: {\n\t\t\ttype: Number,\n\t\t\tdefault: 20,\n\t\t},\n\n\t\t/**\n\t\t * Allows you to set the minimum width of the list column in % on vertical-split\n\t\t * Allows you to set the minimum height of the list column in % on horizontal-split\n\t\t */\n\t\tlistMinWidth: {\n\t\t\ttype: Number,\n\t\t\tdefault: 15,\n\t\t},\n\n\t\t/**\n\t\t * Allows you to set the maximum width of the list column in % on vertical-split\n\t\t * Allows you to set the maximum height of the list column in % on horizontal-split\n\t\t */\n\t\tlistMaxWidth: {\n\t\t\ttype: Number,\n\t\t\tdefault: 40,\n\t\t},\n\n\t\t/**\n\t\t * Specify the config key for the pane config sizes\n\t\t * Default is the global var appName if you use the webpack-vue-config\n\t\t */\n\t\tpaneConfigKey: {\n\t\t\ttype: String,\n\t\t\tdefault: '',\n\t\t},\n\n\t\t/**\n\t\t * When in mobile view, only the list or the details are shown.\n\t\t *\n\t\t * If you provide a list, you need to provide a variable\n\t\t * that will be set to true by the user when an element of\n\t\t * the list gets selected. The details will then show a back\n\t\t * arrow to return to the list that will update this prop to false.\n\t\t */\n\t\tshowDetails: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: true,\n\t\t},\n\n\t\t/**\n\t\t * Specify the `<h1>` page heading\n\t\t */\n\t\tpageHeading: {\n\t\t\ttype: String,\n\t\t\tdefault: null,\n\t\t},\n\t\t/**\n\t\t * Content layout used when there is a list together with content:\n\t\t * - `vertical-split` - a 2-column layout with list and default content separated vertically\n\t\t * - `no-split` - a single column layout; List is shown when `showDetails` is `false`, otherwise the default slot content is shown with a back button to return to the list.\n\t\t * - 'horizontal-split' - a 2-column layout with list and default content separated horizontally\n\t\t * On mobile screen `no-split` layout is forced.\n\t\t */\n\t\tlayout: {\n\t\t\ttype: String,\n\t\t\tdefault: 'vertical-split',\n\t\t\tvalidator(value) {\n\t\t\t\treturn ['no-split', 'vertical-split', 'horizontal-split'].includes(value)\n\t\t\t},\n\t\t},\n\n\t\t/**\n\t\t * Allow setting the page's `<title>`\n\t\t *\n\t\t * If a page heading is set it defaults to `{pageHeading} - {appName} - {productName}` e.g. `Favorites - Files - Nextcloud`.\n\t\t * When the page heading and the app name is the same only one is used, e.g. `Files - Files - Nextcloud` is shown as `Files - Nextcloud`.\n\t\t * When setting the prop then the following format will be used: `{pageTitle} - {pageHeading || appName} - {productName}`\n\t\t */\n\t\tpageTitle: {\n\t\t\ttype: String,\n\t\t\tdefault: null,\n\t\t},\n\t},\n\n\temits: [\n\t\t'update:showDetails',\n\t\t'resize:list',\n\t],\n\n\tsetup() {\n\t\treturn {\n\t\t\tisMobile: useIsMobile(),\n\t\t\tisRtl,\n\t\t}\n\t},\n\n\tdata() {\n\t\treturn {\n\t\t\tcontentHeight: 0,\n\t\t\thasList: false,\n\t\t\thasContent: false,\n\t\t\tswiping: {},\n\t\t\tlistPaneSize: this.restorePaneConfig(),\n\t\t}\n\t},\n\n\tcomputed: {\n\t\tpaneConfigID() {\n\t\t\t// If provided, let's use it\n\t\t\tif (this.paneConfigKey !== '') {\n\t\t\t\treturn `pane-list-size-${this.paneConfigKey}`\n\t\t\t}\n\n\t\t\ttry {\n\t\t\t\t// Using the webpack-vue-config, appName is a global variable\n\t\t\t\t// This will throw a ReferenceError when the global variable is missing\n\t\t\t\t// In that case either you provide paneConfigKey or else it fallback\n\t\t\t\t// to a global storage key\n\t\t\t\treturn `pane-list-size-${appName}`\n\t\t\t} catch (e) {\n\t\t\t\tconsole.info('[INFO] AppContent:', 'falling back to global nextcloud pane config')\n\t\t\t\treturn 'pane-list-size-nextcloud'\n\t\t\t}\n\t\t},\n\n\t\tdetailsPaneSize() {\n\t\t\tif (this.listPaneSize) {\n\t\t\t\treturn 100 - this.listPaneSize\n\t\t\t}\n\t\t\treturn this.paneDefaults.details.size\n\t\t},\n\n\t\tpaneDefaults() {\n\t\t\treturn {\n\t\t\t\tlist: {\n\t\t\t\t\tsize: this.listSize,\n\t\t\t\t\tmin: this.listMinWidth,\n\t\t\t\t\tmax: this.listMaxWidth,\n\t\t\t\t},\n\n\t\t\t\t// set the inverse values of the details column\n\t\t\t\t// based on the provided (or default) values of the list column\n\t\t\t\tdetails: {\n\t\t\t\t\tsize: 100 - this.listSize,\n\t\t\t\t\tmin: 100 - this.listMaxWidth,\n\t\t\t\t\tmax: 100 - this.listMinWidth,\n\t\t\t\t},\n\t\t\t}\n\t\t},\n\n\t\trealPageTitle() {\n\t\t\tconst entries = new Set()\n\t\t\tif (this.pageTitle) {\n\t\t\t\tentries.add(this.pageTitle)\n\t\t\t}\n\t\t\tif (this.pageHeading) {\n\t\t\t\tentries.add(this.pageHeading)\n\t\t\t}\n\t\t\tif (entries.size === 0) {\n\t\t\t\treturn null\n\t\t\t}\n\n\t\t\tif (entries.size < 2) {\n\t\t\t\t// Only add if not already pageHeading and pageTitle are included\n\t\t\t\tentries.add(localizedAppName)\n\t\t\t}\n\t\t\tentries.add(productName)\n\t\t\treturn [...entries.values()].join(' - ')\n\t\t},\n\t},\n\n\twatch: {\n\t\trealPageTitle: {\n\t\t\timmediate: true,\n\t\t\thandler() {\n\t\t\t\tif (this.realPageTitle !== null) {\n\t\t\t\t\tdocument.title = this.realPageTitle\n\t\t\t\t}\n\t\t\t},\n\t\t},\n\t},\n\n\tupdated() {\n\t\tthis.checkSlots()\n\t},\n\n\tmounted() {\n\t\tif (this.allowSwipeNavigation && !this.disableSwipe) {\n\t\t\tthis.swiping = useSwipe(this.$el, {\n\t\t\t\tonSwipeEnd: this.handleSwipe,\n\t\t\t})\n\t\t}\n\n\t\tthis.checkSlots()\n\t\tthis.restorePaneConfig()\n\t},\n\n\tmethods: {\n\t\t/**\n\t\t * handle the swipe event\n\t\t *\n\t\t * @param {TouchEvent} e The touch event\n\t\t * @param {import('@vueuse/core').SwipeDirection} direction The swipe direction of the event\n\t\t */\n\t\thandleSwipe(e, direction) {\n\t\t\tconst minSwipeX = 70\n\t\t\tconst touchZone = 300\n\t\t\tif (Math.abs(this.swiping.lengthX) > minSwipeX) {\n\t\t\t\tif (this.swiping.coordsStart.x < (touchZone / 2) && direction === 'right') {\n\t\t\t\t\temit('toggle-navigation', {\n\t\t\t\t\t\topen: true,\n\t\t\t\t\t})\n\t\t\t\t} else if (this.swiping.coordsStart.x < touchZone * 1.5 && direction === 'left') {\n\t\t\t\t\temit('toggle-navigation', {\n\t\t\t\t\t\topen: false,\n\t\t\t\t\t})\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\n\t\thandlePaneResize(event) {\n\t\t\tconst listPaneSize = parseInt(event[0].size, 10)\n\t\t\tbrowserStorage.setItem(this.paneConfigID, JSON.stringify(listPaneSize))\n\t\t\tthis.listPaneSize = listPaneSize\n\t\t\t/**\n\t\t\t * Emitted when the list pane is resized by the user\n\t\t\t */\n\t\t\tthis.$emit('resize:list', { size: listPaneSize })\n\t\t\tconsole.debug('AppContent pane config', listPaneSize)\n\t\t},\n\n\t\t// $slots is not reactive, we need to update this manually\n\t\tcheckSlots() {\n\t\t\tthis.hasList = !!this.$scopedSlots.list\n\t\t\tthis.hasContent = !!this.$scopedSlots.default\n\t\t},\n\n\t\t// browserStorage is not reactive, we need to update this manually\n\t\trestorePaneConfig() {\n\t\t\tconst listPaneSize = parseInt(browserStorage.getItem(this.paneConfigID), 10)\n\t\t\tif (!isNaN(listPaneSize) && listPaneSize !== this.listPaneSize) {\n\t\t\t\tconsole.debug('AppContent pane config', listPaneSize)\n\t\t\t\tthis.listPaneSize = listPaneSize\n\t\t\t\treturn listPaneSize\n\t\t\t}\n\t\t},\n\n\t\t/**\n\t\t * The user clicked the back arrow from the details view\n\t\t */\n\t\thideDetails() {\n\t\t\tthis.$emit('update:showDetails', false)\n\t\t},\n\t},\n}\n</script>\n<style lang=\"scss\" scoped>\n\n.app-content {\n\tposition: initial;\n\tz-index: 1000;\n\tflex-basis: 100vw;\n\theight: 100%;\n\t// Overriding server styles TODO: cleanup!\n\tmargin: 0 !important;\n\tbackground-color: var(--color-main-background);\n\tmin-width: 0;\n\n\t&:not(.app-content--has-list) {\n\t\toverflow: auto;\n\t}\n}\n\n.app-content-wrapper {\n\tposition: relative;\n\twidth: 100%;\n\theight: 100%;\n}\n\n// Mobile list/details handling\n.app-content-wrapper--no-split {\n\t&.app-content-wrapper--show-list :deep() {\n\t\t.app-content-list {\n\t\t\tdisplay: flex;\n\t\t}\n\t\t.app-content-details {\n\t\t\tdisplay: none;\n\t\t}\n\t}\n\t&.app-content-wrapper--show-details :deep() {\n\t\t.app-content-list {\n\t\t\tdisplay: none;\n\t\t}\n\t\t.app-content-details {\n\t\t\tdisplay: block;\n\t\t}\n\t}\n}\n\n:deep(.splitpanes.default-theme) {\n\t.app-content-list {\n\t\tmax-width: none;\n\t\t/* Thin scrollbar is hard to catch on resizable columns */\n\t\tscrollbar-width: auto;\n\t}\n\n\t.splitpanes__pane {\n\t\tbackground-color: transparent;\n\t\ttransition: none;\n\n\t\t&-list {\n\t\t\tmin-width: 300px;\n\t\t\tposition: sticky;\n\n\t\t\t@media only screen and (width < $breakpoint-mobile) {\n\t\t\t\tdisplay: none;\n\t\t\t}\n\t\t}\n\n\t\t&-details {\n\t\t\toverflow-y: auto;\n\n\t\t\t@media only screen and (width < $breakpoint-mobile) {\n\t\t\t\tmin-width: 100%;\n\t\t\t}\n\t\t}\n\t}\n\n\t.splitpanes__splitter {\n\t\tbackground-color: var(--color-main-background);\n\t\t&::before, &::after {\n\t\t\tbackground-color: var(--color-border);\n\t\t}\n\t}\n\n\t&.splitpanes--vertical .splitpanes__splitter {\n\t\tborder-left: 1px solid var(--color-border);\n\t}\n\n\t&.splitpanes--horizontal .splitpanes__splitter {\n\t\tborder-top: 1px solid var(--color-border);\n\t}\n}\n\n.app-content-wrapper--show-list {\n\t:deep(.app-content-list) {\n\t\tmax-width: none;\n\t}\n}\n</style>\n"],"names":["_sfc_main","Tooltip","NcButton","ArrowRight","ArrowLeft","isRtl","useIsMobile","t","emit","getBuilder","loadState","Pane","Splitpanes","useSwipe"],"mappings":";;;;;;;;;;;;;;;;;AA+BA,MAAAA,cAAA;AAAA,EACA,MAAA;AAAA,EAEA,YAAA;AAAA,IACA,SAAAC,YAAA;AAAA,EACA;AAAA,EAEA,YAAA;AAAA,IACA,UAAAC;AAAAA,IACA,YAAAC,WAAA;AAAA,IACA,WAAAC,UAAA;AAAA,EACA;AAAA,EACA,QAAA;AACA,WAAA;AAAA,MACA,OAAAC,IAAA;AAAA,MACA,UAAAC,wBAAAA,YAAA;AAAA,IACA;AAAA,EACA;AAAA,EAEA,UAAA;AAAA,IACA,QAAA;AACA,aAAAC,MAAA,EAAA,qBAAA;AAAA,IACA;AAAA,EACA;AAAA,EACA,OAAA;AAAA,IACA,UAAA;AAAA,MACA,WAAA;AAAA,MACA,UAAA;AACA,aAAA,0BAAA,KAAA,QAAA;AAAA,MACA;AAAA,IACA;AAAA,EACA;AAAA,EAEA,gBAAA;AACA,QAAA,KAAA,UAAA;AACA,WAAA,0BAAA,KAAA;AAAA,IACA;AAAA,EACA;AAAA,EAEA,SAAA;AAAA,IACA,0BAAA,OAAA,MAAA;AACA,YAAA,sBAAA,SAAA,cAAA,wCAAA;AACA,UAAA,qBAAA;AACA,4BAAA,MAAA,UAAA,OAAA,SAAA;A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BAAA;AAAA,YACA,MAAA;AAAA,UACA,CAAA;AAAA,QACA;AAAA,MACA;AAAA,IACA;AAAA,IAEA,iBAAA,OAAA;AACA,YAAA,eAAA,SAAA,MAAA,CAAA,EAAA,MAAA,EAAA;AACA,qBAAA,QAAA,KAAA,cAAA,KAAA,UAAA,YAAA,CAAA;AACA,WAAA,eAAA;AAIA,WAAA,MAAA,eAAA,EAAA,MAAA,aAAA,CAAA;AACA,cAAA,MAAA,0BAAA,YAAA;AAAA,IACA;AAAA;AAAA,IAGA,aAAA;AACA,WAAA,UAAA,CAAA,CAAA,KAAA,aAAA;AACA,WAAA,aAAA,CAAA,CAAA,KAAA,aAAA;AAAA,IACA;AAAA;AAAA,IAGA,oBAAA;AACA,YAAA,eAAA,SAAA,eAAA,QAAA,KAAA,YAAA,GAAA,EAAA;AACA,UAAA,CAAA,MAAA,YAAA,KAAA,iBAAA,KAAA,cAAA;AACA,gBAAA,MAAA,0BAAA,YAAA;AACA,aAAA,eAAA;AACA,eAAA;AAAA,MACA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA,IAKA,cAAA;AACA,WAAA,MAAA,sBAAA,KAAA;AAAA,IACA;AAAA,EACA;AACA;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"NcIconSvgWrapper-B_eOG2sZ.cjs","sources":["../../src/components/NcIconSvgWrapper/NcIconSvgWrapper.vue"],"sourcesContent":["<!--\n - SPDX-FileCopyrightText: 2022 Nextcloud GmbH and Nextcloud contributors\n - SPDX-License-Identifier: AGPL-3.0-or-later\n-->\n\n<docs>\n### Description\n\nRender raw SVG string icons.\n\n### Usage within `icon`-slot\n\n```vue\n<template>\n\t<div class=\"grid\">\n\t\t<NcButton aria-label=\"Close\">\n\t\t\t<template #icon>\n\t\t\t\t<NcIconSvgWrapper :svg=\"closeSvg\" name=\"Close\" />\n\t\t\t</template>\n\t\t</NcButton>\n\t\t<NcButton aria-label=\"Settings\">\n\t\t\t<template #icon>\n\t\t\t\t<NcIconSvgWrapper :svg=\"cogSvg\" name=\"Cog\" />\n\t\t\t</template>\n\t\t</NcButton>\n\t\t<NcButton aria-label=\"Add\">\n\t\t\t<template #icon>\n\t\t\t\t<NcIconSvgWrapper :svg=\"plusSvg\" name=\"Plus\" />\n\t\t\t</template>\n\t\t</NcButton>\n\t\t<NcButton aria-label=\"Send\">\n\t\t\t<template #icon>\n\t\t\t\t<NcIconSvgWrapper :path=\"mdiSend\" name=\"Send\" />\n\t\t\t</template>\n\t\t</NcButton>\n\t\t<NcButton aria-label=\"Star\">\n\t\t\t<template #icon>\n\t\t\t\t<NcIconSvgWrapper :path=\"mdiStar\" name=\"Star\" />\n\t\t\t</template>\n\t\t</NcButton>\n\t</div>\n</template>\n\n<script>\nimport closeSvg from '@mdi/svg/svg/close.svg?raw'\nimport cogSvg from '@mdi/svg/svg/cog.svg?raw'\nimport plusSvg from '@mdi/svg/svg/plus.svg?raw'\nimport { mdiSend } from '@mdi/js'\nimport { mdiStar } from '@mdi/js'\n\nexport default {\n\tsetup() {\n\t\t// This icons are static data, so you do not need to put them into `data` which will make them reactive\n\t\treturn {\n\t\t\tcloseSvg,\n\t\t\tcogSvg,\n\t\t\tplusSvg,\n\t\t\tmdiSend,\n\t\t\tmdiStar,\n\t\t}\n\t},\n}\n</script>\n\n<style>\n.grid {\n\tdisplay: grid;\n\tgrid-template-columns: repeat(5, max-content);\n\tgap: 10px;\n}\n</style>\n```\n\n### Inline usage inside text\n\n```vue\n<template>\n\t<p>\n\t\tThis is my <NcIconSvgWrapper inline :path=\"mdiStar\" /> Favorite\n\t</p>\n</template>\n<script>\nimport { mdiStar } from '@mdi/js'\n\nexport default {\n\tsetup() {\n\t\treturn {\n\t\t\tmdiStar,\n\t\t}\n\t},\n}\n</script>\n```\n</docs>\n\n<template>\n\t<span v-if=\"!cleanSvg\"\n\t\tv-bind=\"attributes\">\n\t\t<svg viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\">\n\t\t\t<path :d=\"path\" />\n\t\t</svg>\n\t</span>\n\t<span v-else\n\t\tv-bind=\"attributes\"\n\t\tv-html=\"cleanSvg\" /> <!-- eslint-disable-line vue/no-v-html -->\n</template>\n\n<script>\nimport Vue from 'vue'\nimport DOMPurify from 'dompurify'\n\nexport default {\n\tname: 'NcIconSvgWrapper',\n\n\tprops: {\n\t\t/**\n\t\t * Set if the icon should be used as inline content e.g. within text.\n\t\t * By default the icon is made a block element for use inside `icon`-slots.\n\t\t */\n\t\tinline: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: false,\n\t\t},\n\n\t\t/**\n\t\t * Raw SVG string to render\n\t\t */\n\t\tsvg: {\n\t\t\ttype: String,\n\t\t\tdefault: '',\n\t\t},\n\n\t\t/**\n\t\t * Label of the icon, used in aria-label\n\t\t */\n\t\tname: {\n\t\t\ttype: String,\n\t\t\tdefault: '',\n\t\t},\n\n\t\t/**\n\t\t * Raw SVG path to render. Takes precedence over the SVG string in the `svg` prop.\n\t\t */\n\t\tpath: {\n\t\t\ttype: String,\n\t\t\tdefault: '',\n\t\t},\n\n\t\t/**\n\t\t * Size of the icon to show. Only use if not using within an icon slot.\n\t\t * Defaults to 20px which is the Nextcloud icon size for all icon slots.\n\t\t * @default 20\n\t\t */\n\t\tsize: {\n\t\t\ttype: [Number, String],\n\t\t\tdefault: 20,\n\t\t\tvalidator: (value) => typeof value === 'number' || value === 'auto',\n\t\t},\n\t},\n\n\tcomputed: {\n\t\t/**\n\t\t * Icon size used in CSS\n\t\t */\n\t\ticonSize() {\n\t\t\treturn typeof this.size === 'number' ? `${this.size}px` : this.size\n\t\t},\n\n\t\tcleanSvg() {\n\t\t\tif (!this.svg || this.path) {\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\tconst svg = DOMPurify.sanitize(this.svg)\n\n\t\t\tconst svgDocument = new DOMParser().parseFromString(svg, 'image/svg+xml')\n\n\t\t\tif (svgDocument.querySelector('parsererror')) {\n\t\t\t\tVue.util.warn('SVG is not valid')\n\t\t\t\treturn ''\n\t\t\t}\n\n\t\t\tif (svgDocument.documentElement.id) {\n\t\t\t\tsvgDocument.documentElement.removeAttribute('id')\n\t\t\t}\n\n\t\t\treturn svgDocument.documentElement.outerHTML\n\t\t},\n\t\tattributes() {\n\t\t\treturn {\n\t\t\t\tclass: ['icon-vue', { 'icon-vue--inline': this.inline }],\n\t\t\t\tstyle: {\n\t\t\t\t\t'--icon-size': this.iconSize,\n\t\t\t\t},\n\t\t\t\trole: 'img',\n\t\t\t\t'aria-hidden': !this.name ? true : undefined,\n\t\t\t\t'aria-label': this.name || undefined,\n\t\t\t}\n\t\t},\n\t},\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.icon-vue {\n\tdisplay: flex;\n\tjustify-content: center;\n\talign-items: center;\n\tmin-width: var(--default-clickable-area);\n\tmin-height: var(--default-clickable-area);\n\topacity: 1;\n\n\t&--inline {\n\t\tdisplay: inline-flex;\n\t\tmin-width: fit-content;\n\t\tmin-height: fit-content;\n\t\tvertical-align: text-bottom;\n\t}\n\n\t&:deep(svg) {\n\t\tfill: currentColor;\n\t\twidth: var(--icon-size, 20px);\n\t\theight: var(--icon-size, 20px);\n\t\tmax-width: var(--icon-size, 20px);\n\t\tmax-height: var(--icon-size, 20px);\n\t}\n}\n</style>\n"],"names":["DOMPurify","Vue"],"mappings":";;;;;;;AA+GA,MAAA,YAAA;AAAA,EACA,MAAA;AAAA,EAEA,OAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAKA,QAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA,IAKA,KAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA,IAKA,MAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA,IAKA,MAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAOA,MAAA;AAAA,MACA,MAAA,CAAA,QAAA,MAAA;AAAA,MACA,SAAA;AAAA,MACA,WAAA,CAAA,UAAA,OAAA,UAAA,YAAA,UAAA;AAAA,IACA;AAAA,EACA;AAAA,EAEA,UAAA;AAAA;AAAA;AAAA;AAAA,IAIA,WAAA;AACA,aAAA,OAAA,KAAA,SAAA,WAAA,GAAA,KAAA,IAAA,OAAA,KAAA;AAAA,IACA;AAAA,IAEA,WAAA;AACA,UAAA,CAAA,KAAA,OAAA,KAAA,MAAA;AACA;AAAA,MACA;AAEA,YAAA,MAAAA,mBAAAA,QAAA,SAAA,KAAA,GAAA;AAEA,YAAA,cAAA,IAAA,UAAA,EAAA,gBAAA,KAAA,eAAA;AAEA,UAAA,YAAA,cAAA,aAAA,GAAA;AACAC,6BAAA,KAAA,KAAA,kBAAA;AACA,eAAA;AAAA,MACA;AAEA,UAAA,YAAA,gBAAA,IAAA;AACA,oBAAA,gBAAA,gBAAA,IAAA;AAAA,MACA;AAEA,aAAA,YAAA,gBAAA;AAAA,IACA;AAAA,IACA,aAAA;AACA,aAAA;AAAA,QACA,OAAA,CAAA,YAAA,EAAA,oBAAA,KAAA,OAAA,CAAA;AAAA,QACA,OAAA;AAAA,UACA,eAAA,KAAA;AAAA,QACA;AAAA,QACA,MAAA;AAAA,QACA,eAAA,CAAA,KAAA,OAAA,OAAA;AAAA,QACA,cAAA,KAAA,QAAA;AAAA,MACA;AAAA,IACA;AAAA,EACA;AACA;;;;;;;;;;;;;;;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"NcIconSvgWrapper-CHmdAuhg.mjs","sources":["../../src/components/NcIconSvgWrapper/NcIconSvgWrapper.vue"],"sourcesContent":["<!--\n - SPDX-FileCopyrightText: 2022 Nextcloud GmbH and Nextcloud contributors\n - SPDX-License-Identifier: AGPL-3.0-or-later\n-->\n\n<docs>\n### Description\n\nRender raw SVG string icons.\n\n### Usage within `icon`-slot\n\n```vue\n<template>\n\t<div class=\"grid\">\n\t\t<NcButton aria-label=\"Close\">\n\t\t\t<template #icon>\n\t\t\t\t<NcIconSvgWrapper :svg=\"closeSvg\" name=\"Close\" />\n\t\t\t</template>\n\t\t</NcButton>\n\t\t<NcButton aria-label=\"Settings\">\n\t\t\t<template #icon>\n\t\t\t\t<NcIconSvgWrapper :svg=\"cogSvg\" name=\"Cog\" />\n\t\t\t</template>\n\t\t</NcButton>\n\t\t<NcButton aria-label=\"Add\">\n\t\t\t<template #icon>\n\t\t\t\t<NcIconSvgWrapper :svg=\"plusSvg\" name=\"Plus\" />\n\t\t\t</template>\n\t\t</NcButton>\n\t\t<NcButton aria-label=\"Send\">\n\t\t\t<template #icon>\n\t\t\t\t<NcIconSvgWrapper :path=\"mdiSend\" name=\"Send\" />\n\t\t\t</template>\n\t\t</NcButton>\n\t\t<NcButton aria-label=\"Star\">\n\t\t\t<template #icon>\n\t\t\t\t<NcIconSvgWrapper :path=\"mdiStar\" name=\"Star\" />\n\t\t\t</template>\n\t\t</NcButton>\n\t</div>\n</template>\n\n<script>\nimport closeSvg from '@mdi/svg/svg/close.svg?raw'\nimport cogSvg from '@mdi/svg/svg/cog.svg?raw'\nimport plusSvg from '@mdi/svg/svg/plus.svg?raw'\nimport { mdiSend } from '@mdi/js'\nimport { mdiStar } from '@mdi/js'\n\nexport default {\n\tsetup() {\n\t\t// This icons are static data, so you do not need to put them into `data` which will make them reactive\n\t\treturn {\n\t\t\tcloseSvg,\n\t\t\tcogSvg,\n\t\t\tplusSvg,\n\t\t\tmdiSend,\n\t\t\tmdiStar,\n\t\t}\n\t},\n}\n</script>\n\n<style>\n.grid {\n\tdisplay: grid;\n\tgrid-template-columns: repeat(5, max-content);\n\tgap: 10px;\n}\n</style>\n```\n\n### Inline usage inside text\n\n```vue\n<template>\n\t<p>\n\t\tThis is my <NcIconSvgWrapper inline :path=\"mdiStar\" /> Favorite\n\t</p>\n</template>\n<script>\nimport { mdiStar } from '@mdi/js'\n\nexport default {\n\tsetup() {\n\t\treturn {\n\t\t\tmdiStar,\n\t\t}\n\t},\n}\n</script>\n```\n</docs>\n\n<template>\n\t<span v-if=\"!cleanSvg\"\n\t\tv-bind=\"attributes\">\n\t\t<svg viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\">\n\t\t\t<path :d=\"path\" />\n\t\t</svg>\n\t</span>\n\t<span v-else\n\t\tv-bind=\"attributes\"\n\t\tv-html=\"cleanSvg\" /> <!-- eslint-disable-line vue/no-v-html -->\n</template>\n\n<script>\nimport Vue from 'vue'\nimport DOMPurify from 'dompurify'\n\nexport default {\n\tname: 'NcIconSvgWrapper',\n\n\tprops: {\n\t\t/**\n\t\t * Set if the icon should be used as inline content e.g. within text.\n\t\t * By default the icon is made a block element for use inside `icon`-slots.\n\t\t */\n\t\tinline: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: false,\n\t\t},\n\n\t\t/**\n\t\t * Raw SVG string to render\n\t\t */\n\t\tsvg: {\n\t\t\ttype: String,\n\t\t\tdefault: '',\n\t\t},\n\n\t\t/**\n\t\t * Label of the icon, used in aria-label\n\t\t */\n\t\tname: {\n\t\t\ttype: String,\n\t\t\tdefault: '',\n\t\t},\n\n\t\t/**\n\t\t * Raw SVG path to render. Takes precedence over the SVG string in the `svg` prop.\n\t\t */\n\t\tpath: {\n\t\t\ttype: String,\n\t\t\tdefault: '',\n\t\t},\n\n\t\t/**\n\t\t * Size of the icon to show. Only use if not using within an icon slot.\n\t\t * Defaults to 20px which is the Nextcloud icon size for all icon slots.\n\t\t * @default 20\n\t\t */\n\t\tsize: {\n\t\t\ttype: [Number, String],\n\t\t\tdefault: 20,\n\t\t\tvalidator: (value) => typeof value === 'number' || value === 'auto',\n\t\t},\n\t},\n\n\tcomputed: {\n\t\t/**\n\t\t * Icon size used in CSS\n\t\t */\n\t\ticonSize() {\n\t\t\treturn typeof this.size === 'number' ? `${this.size}px` : this.size\n\t\t},\n\n\t\tcleanSvg() {\n\t\t\tif (!this.svg || this.path) {\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\tconst svg = DOMPurify.sanitize(this.svg)\n\n\t\t\tconst svgDocument = new DOMParser().parseFromString(svg, 'image/svg+xml')\n\n\t\t\tif (svgDocument.querySelector('parsererror')) {\n\t\t\t\tVue.util.warn('SVG is not valid')\n\t\t\t\treturn ''\n\t\t\t}\n\n\t\t\tif (svgDocument.documentElement.id) {\n\t\t\t\tsvgDocument.documentElement.removeAttribute('id')\n\t\t\t}\n\n\t\t\treturn svgDocument.documentElement.outerHTML\n\t\t},\n\t\tattributes() {\n\t\t\treturn {\n\t\t\t\tclass: ['icon-vue', { 'icon-vue--inline': this.inline }],\n\t\t\t\tstyle: {\n\t\t\t\t\t'--icon-size': this.iconSize,\n\t\t\t\t},\n\t\t\t\trole: 'img',\n\t\t\t\t'aria-hidden': !this.name ? true : undefined,\n\t\t\t\t'aria-label': this.name || undefined,\n\t\t\t}\n\t\t},\n\t},\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.icon-vue {\n\tdisplay: flex;\n\tjustify-content: center;\n\talign-items: center;\n\tmin-width: var(--default-clickable-area);\n\tmin-height: var(--default-clickable-area);\n\topacity: 1;\n\n\t&--inline {\n\t\tdisplay: inline-flex;\n\t\tmin-width: fit-content;\n\t\tmin-height: fit-content;\n\t\tvertical-align: text-bottom;\n\t}\n\n\t&:deep(svg) {\n\t\tfill: currentColor;\n\t\twidth: var(--icon-size, 20px);\n\t\theight: var(--icon-size, 20px);\n\t\tmax-width: var(--icon-size, 20px);\n\t\tmax-height: var(--icon-size, 20px);\n\t}\n}\n</style>\n"],"names":[],"mappings":";;;AA+GA,MAAA,YAAA;AAAA,EACA,MAAA;AAAA,EAEA,OAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAKA,QAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA,IAKA,KAAA;AAAA,MACA,MAAA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