@nextcloud/vue 8.0.1 → 8.1.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 +15 -0
- 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 +9 -5
- package/dist/Components/NcAppContent.cjs.map +1 -1
- package/dist/Components/NcAppContent.mjs +13 -9
- package/dist/Components/NcAppContent.mjs.map +1 -1
- package/dist/Components/NcAppNavigation.cjs +11 -7
- package/dist/Components/NcAppNavigation.cjs.map +1 -1
- package/dist/Components/NcAppNavigation.mjs +9 -5
- package/dist/Components/NcAppNavigation.mjs.map +1 -1
- package/dist/Components/NcAppNavigationItem.cjs +16 -12
- package/dist/Components/NcAppNavigationItem.cjs.map +1 -1
- package/dist/Components/NcAppNavigationItem.mjs +14 -10
- package/dist/Components/NcAppNavigationItem.mjs.map +1 -1
- package/dist/Components/NcAppNavigationNewItem.cjs +1 -1
- package/dist/Components/NcAppNavigationNewItem.mjs +1 -1
- package/dist/Components/NcAppNavigationSettings.cjs +4 -2
- package/dist/Components/NcAppNavigationSettings.cjs.map +1 -1
- package/dist/Components/NcAppNavigationSettings.mjs +6 -4
- package/dist/Components/NcAppNavigationSettings.mjs.map +1 -1
- package/dist/Components/NcAppNavigationToggle.cjs +1 -1
- package/dist/Components/NcAppNavigationToggle.mjs +1 -1
- package/dist/Components/NcAppSettingsDialog.cjs +10 -6
- package/dist/Components/NcAppSettingsDialog.cjs.map +1 -1
- package/dist/Components/NcAppSettingsDialog.mjs +14 -10
- package/dist/Components/NcAppSettingsDialog.mjs.map +1 -1
- package/dist/Components/NcAppSidebar.cjs +3 -3
- package/dist/Components/NcAppSidebar.cjs.map +1 -1
- package/dist/Components/NcAppSidebar.mjs +3 -3
- package/dist/Components/NcAppSidebar.mjs.map +1 -1
- package/dist/Components/NcAvatar.cjs +1 -1
- package/dist/Components/NcAvatar.mjs +1 -1
- package/dist/Components/NcCheckboxRadioSwitch.cjs +1 -1
- package/dist/Components/NcCheckboxRadioSwitch.mjs +1 -1
- package/dist/Components/NcColorPicker.cjs +1 -1
- package/dist/Components/NcColorPicker.mjs +1 -1
- package/dist/Components/NcDashboardWidget.cjs +1 -1
- package/dist/Components/NcDashboardWidget.mjs +2 -2
- 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 +2 -2
- package/dist/Components/NcDateTimePicker.mjs +4 -4
- package/dist/Components/NcDateTimePickerNative.cjs +1 -1
- package/dist/Components/NcDateTimePickerNative.mjs +1 -1
- package/dist/Components/NcEmojiPicker.cjs +1 -1
- package/dist/Components/NcEmojiPicker.mjs +1 -1
- package/dist/Components/NcHeaderMenu.cjs +11 -9
- package/dist/Components/NcHeaderMenu.cjs.map +1 -1
- package/dist/Components/NcHeaderMenu.mjs +16 -14
- package/dist/Components/NcHeaderMenu.mjs.map +1 -1
- package/dist/Components/NcListItem.cjs +1 -1
- package/dist/Components/NcListItem.mjs +1 -1
- package/dist/Components/NcListItemIcon.cjs +4 -2
- package/dist/Components/NcListItemIcon.cjs.map +1 -1
- package/dist/Components/NcListItemIcon.mjs +9 -7
- package/dist/Components/NcListItemIcon.mjs.map +1 -1
- package/dist/Components/NcModal.cjs +1 -1
- package/dist/Components/NcModal.mjs +3 -3
- package/dist/Components/NcPasswordField.cjs +1 -1
- package/dist/Components/NcPasswordField.mjs +1 -1
- package/dist/Components/NcRelatedResourcesPanel.cjs +1 -1
- package/dist/Components/NcRelatedResourcesPanel.mjs +1 -1
- package/dist/Components/NcRichContenteditable.cjs +2 -2
- package/dist/Components/NcRichContenteditable.mjs +2 -2
- package/dist/Components/NcRichText.cjs +1 -1
- package/dist/Components/NcRichText.mjs +3 -3
- package/dist/Components/NcSelect.cjs +2 -2
- package/dist/Components/NcSelect.cjs.map +1 -1
- package/dist/Components/NcSelect.mjs +3 -3
- package/dist/Components/NcSelect.mjs.map +1 -1
- package/dist/Components/NcSelectTags.cjs +1 -1
- package/dist/Components/NcSelectTags.mjs +1 -1
- 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 +25 -17
- package/dist/Components/NcTextField.cjs.map +1 -1
- package/dist/Components/NcTextField.mjs +27 -19
- package/dist/Components/NcTextField.mjs.map +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/Composables/useIsFullscreen.cjs +35 -0
- package/dist/Composables/useIsFullscreen.cjs.map +1 -0
- package/dist/Composables/useIsFullscreen.mjs +35 -0
- package/dist/Composables/useIsFullscreen.mjs.map +1 -0
- package/dist/Composables/useIsMobile.cjs +35 -0
- package/dist/Composables/useIsMobile.cjs.map +1 -0
- package/dist/Composables/useIsMobile.mjs +35 -0
- package/dist/Composables/useIsMobile.mjs.map +1 -0
- package/dist/Mixins/isFullscreen.cjs +10 -19
- package/dist/Mixins/isFullscreen.cjs.map +1 -1
- package/dist/Mixins/isFullscreen.mjs +10 -19
- package/dist/Mixins/isFullscreen.mjs.map +1 -1
- package/dist/Mixins/isMobile.cjs +10 -62
- package/dist/Mixins/isMobile.cjs.map +1 -1
- package/dist/Mixins/isMobile.mjs +10 -62
- package/dist/Mixins/isMobile.mjs.map +1 -1
- package/dist/assets/{index-7d211db9.css → index-2e31f707.css} +29 -14
- package/dist/assets/{index-ebbb7829.css → index-4437e6bf.css} +8 -8
- package/dist/assets/{index-4271da53.css → index-4596132f.css} +17 -17
- package/dist/assets/{index-db5a8b1c.css → index-9ca89b81.css} +11 -11
- package/dist/assets/{index-dea0aef3.css → index-dce4b705.css} +10 -10
- package/dist/assets/{index-9176105d.css → index-f8d6daf3.css} +41 -41
- package/dist/assets/{index-750c02cc.css → index-f9bfa317.css} +3 -0
- package/dist/chunks/{NcAppNavigationToggle-82764816.mjs → NcAppNavigationToggle-a031dce0.mjs} +1 -1
- package/dist/chunks/{NcAppNavigationToggle-82764816.mjs.map → NcAppNavigationToggle-a031dce0.mjs.map} +1 -1
- package/dist/chunks/{NcAppNavigationToggle-60664a28.cjs → NcAppNavigationToggle-d248cb09.cjs} +1 -1
- package/dist/chunks/{NcAppNavigationToggle-60664a28.cjs.map → NcAppNavigationToggle-d248cb09.cjs.map} +1 -1
- package/dist/chunks/{NcInputConfirmCancel-262d455f.cjs → NcInputConfirmCancel-00bdeac7.cjs} +1 -1
- package/dist/chunks/{NcInputConfirmCancel-262d455f.cjs.map → NcInputConfirmCancel-00bdeac7.cjs.map} +1 -1
- package/dist/chunks/{NcInputConfirmCancel-906c7816.mjs → NcInputConfirmCancel-40ea7cd1.mjs} +1 -1
- package/dist/chunks/{NcInputConfirmCancel-906c7816.mjs.map → NcInputConfirmCancel-40ea7cd1.mjs.map} +1 -1
- package/dist/chunks/{NcRichText-ae95c854.cjs → NcRichText-89373b11.cjs} +1 -1
- package/dist/chunks/{NcRichText-ae95c854.cjs.map → NcRichText-89373b11.cjs.map} +1 -1
- package/dist/chunks/{NcRichText-1e8fd02d.mjs → NcRichText-e2026b55.mjs} +1 -1
- package/dist/chunks/{NcRichText-1e8fd02d.mjs.map → NcRichText-e2026b55.mjs.map} +1 -1
- package/dist/chunks/{NcSettingsSelectGroup-ae323579.mjs → NcSettingsSelectGroup-b49652df.mjs} +2 -2
- package/dist/chunks/{NcSettingsSelectGroup-ae323579.mjs.map → NcSettingsSelectGroup-b49652df.mjs.map} +1 -1
- package/dist/chunks/{NcSettingsSelectGroup-e8f9f9fe.cjs → NcSettingsSelectGroup-fad68876.cjs} +1 -1
- package/dist/chunks/{NcSettingsSelectGroup-e8f9f9fe.cjs.map → NcSettingsSelectGroup-fad68876.cjs.map} +1 -1
- package/dist/chunks/{ScopeComponent-1ab1ebb9.mjs → ScopeComponent-a06864ef.mjs} +1 -1
- package/dist/chunks/{ScopeComponent-1ab1ebb9.mjs.map → ScopeComponent-a06864ef.mjs.map} +1 -1
- package/dist/chunks/{ScopeComponent-50287dad.cjs → ScopeComponent-a24eb082.cjs} +1 -1
- package/dist/chunks/{ScopeComponent-50287dad.cjs.map → ScopeComponent-a24eb082.cjs.map} +1 -1
- package/dist/chunks/{index-fbf943b3.mjs → index-831524a1.mjs} +6 -4
- package/dist/chunks/{index-fbf943b3.mjs.map → index-831524a1.mjs.map} +1 -1
- package/dist/chunks/{index-e06b96d3.cjs → index-ac31691c.cjs} +7 -5
- package/dist/chunks/{index-e06b96d3.cjs.map → index-ac31691c.cjs.map} +1 -1
- package/dist/chunks/{l10n-ec2d3010.cjs → l10n-098e6a54.cjs} +1 -1
- package/dist/chunks/{l10n-ec2d3010.cjs.map → l10n-098e6a54.cjs.map} +1 -1
- package/dist/chunks/{l10n-9fc9974f.mjs → l10n-a929cdef.mjs} +1 -1
- package/dist/chunks/{l10n-9fc9974f.mjs.map → l10n-a929cdef.mjs.map} +1 -1
- package/dist/chunks/l10n-c3dbf018.cjs +29 -0
- package/dist/chunks/l10n-c3dbf018.cjs.map +1 -0
- package/dist/chunks/l10n-f51d3415.mjs +31 -0
- package/dist/chunks/l10n-f51d3415.mjs.map +1 -0
- package/dist/chunks/{referencePickerModal-e033bf2c.cjs → referencePickerModal-b79b7b92.cjs} +1 -1
- package/dist/chunks/{referencePickerModal-e033bf2c.cjs.map → referencePickerModal-b79b7b92.cjs.map} +1 -1
- package/dist/chunks/{referencePickerModal-6bc8f6b9.mjs → referencePickerModal-c87eab17.mjs} +1 -1
- package/dist/chunks/{referencePickerModal-6bc8f6b9.mjs.map → referencePickerModal-c87eab17.mjs.map} +1 -1
- package/dist/index.cjs +4 -4
- package/dist/index.mjs +6 -6
- package/package.json +1 -1
- package/dist/chunks/l10n-f491109d.cjs +0 -29
- package/dist/chunks/l10n-f491109d.cjs.map +0 -1
- package/dist/chunks/l10n-f692947e.mjs +0 -31
- package/dist/chunks/l10n-f692947e.mjs.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NcTextField.cjs","sources":["../../node_modules/vue-material-design-icons/UndoVariant.vue","../../src/components/NcTextField/NcTextField.vue"],"sourcesContent":["<template>\n <span v-bind=\"$attrs\"\n :aria-hidden=\"!title\"\n :aria-label=\"title\"\n class=\"material-design-icon undo-variant-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=\"M13.5,7A6.5,6.5 0 0,1 20,13.5A6.5,6.5 0 0,1 13.5,20H10V18H13.5C16,18 18,16 18,13.5C18,11 16,9 13.5,9H7.83L10.91,12.09L9.5,13.5L4,8L9.5,2.5L10.92,3.91L7.83,7H13.5M6,18H8V20H6V18Z\">\n <title v-if=\"title\">{{ title }}</title>\n </path>\n </svg>\n </span>\n</template>\n\n<script>\nexport default {\n name: \"UndoVariantIcon\",\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>","<!--\n - @copyright Copyright (c) 2022 Marco Ambrosini <marcoambrosini@pm.me>\n -\n - @author Marco Ambrosini <marcoambrosini@pm.me>\n -\n - @license GNU AGPL version 3 or any later version\n -\n - This program is free software: you can redistribute it and/or modify\n - it under the terms of the GNU Affero General Public License as\n - published by the Free Software Foundation, either version 3 of the\n - License, or (at your option) any later version.\n -\n - This program is distributed in the hope that it will be useful,\n - but WITHOUT ANY WARRANTY; without even the implied warranty of\n - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n - GNU Affero General Public License for more details.\n -\n - You should have received a copy of the GNU Affero General Public License\n - along with this program. If not, see <http://www.gnu.org/licenses/>.\n-->\n\n<docs>\n### Description\nSee [NcInputField](#/Components/NcFields?id=ncinputfield) for a list of all available props.\n\nGeneral purpose text field component.\nIt is recommended to not only provide a placeholder, but also a label.\nThe label should describe what input is expected and the placehold what format the input should have.\n\nNote: the inner html `input` element inherits all the attributes from the\nNcTextField component so you can add things like `autocomplete`, `maxlength`\nand `minlength`.\n\n```\n<template>\n\t<div class=\"wrapper\">\n\t\t<NcTextField :value.sync=\"text1\"\n\t\t\tlabel=\"Leading icon and clear trailing button\"\n\t\t\ttrailing-button-icon=\"close\"\n\t\t\t:show-trailing-button=\"text1 !== ''\"\n\t\t\t@trailing-button-click=\"clearText\">\n\t\t\t<Magnify :size=\"20\" />\n\t\t</NcTextField>\n\t\t<NcTextField :value.sync=\"text4\"\n\t\t\tlabel=\"Internal label\"\n\t\t\tplaceholder=\"That can be used together with placeholder\"\n\t\t\ttrailing-button-icon=\"close\"\n\t\t\t:show-trailing-button=\"text4 !== ''\"\n\t\t\t@trailing-button-click=\"clearText\">\n\t\t\t<Lock :size=\"20\" />\n\t\t</NcTextField>\n\t\t<NcTextField :value.sync=\"text2\"\n\t\t\tlabel=\"Success state\"\n\t\t\tplaceholder=\"Placeholders are possible\"\n\t\t\t:success=\"true\"\n\t\t\t@trailing-button-click=\"clearText\">\n\t\t</NcTextField>\n\t\t<NcTextField :value.sync=\"text3\"\n\t\t\tlabel=\"Error state\"\n\t\t\tplaceholder=\"Enter something valid\"\n\t\t\t:error=\"true\"\n\t\t\t@trailing-button-click=\"clearText\">\n\t\t</NcTextField>\n\t\t<NcTextField label=\"Disabled\"\n\t\t\t:disabled=\"true\" />\n\t\t<NcTextField label=\"Disabled + Success\"\n\t\t\t:success=\"true\"\n\t\t\t:disabled=\"true\" />\n\t\t<div class=\"external-label\">\n\t\t\t<label for=\"textField\">External label</label>\n\t\t\t<NcTextField :value.sync=\"text5\"\n\t\t\t\tid=\"textField\"\n\t\t\t\t:label-outside=\"true\"\n\t\t\t\tplaceholder=\"Input with external label\"\n\t\t\t\t@trailing-button-click=\"clearText\" />\n\t\t</div>\n\t</div>\n</template>\n<script>\nimport Magnify from 'vue-material-design-icons/Magnify'\nimport Lock from 'vue-material-design-icons/Lock'\nimport Close from 'vue-material-design-icons/Close'\n\nexport default {\n\tdata() {\n\t\treturn {\n\t\t\ttext1: '',\n\t\t\ttext2: '',\n\t\t\ttext3: '',\n\t\t\ttext4: '',\n\t\t\ttext5: '',\n\t\t}\n\t},\n\n\tcomponents: {\n\t\tMagnify,\n\t\tLock,\n\t\tClose,\n\t},\n\n\tmethods: {\n\t\tclearText() {\n\t\t\tthis.text1 = ''\n\t\t\tthis.text3 = ''\n\t\t}\n\t}\n}\n</script>\n<style lang=\"scss\" scoped>\n.wrapper {\n\tdisplay: flex;\n\tgap: 4px;\n\talign-items: flex-end;\n\tflex-wrap: wrap;\n}\n\n.external-label {\n\tdisplay: flex;\n\twidth: 100%;\n\tmargin-top: 1rem;\n}\n\n.external-label label {\n\tpadding-top: 7px;\n\tpadding-right: 14px;\n\twhite-space: nowrap;\n}\n</style>\n```\n</docs>\n\n<template>\n\t<NcInputField v-bind=\"propsAndAttrsToForward\"\n\t\tref=\"inputField\"\n\t\tv-on=\"$listeners\"\n\t\t@input=\"handleInput\">\n\t\t<!-- Default slot for the leading icon -->\n\t\t<slot />\n\n\t\t<!-- Trailing icon slot, except for search type input as the browser already adds a trailing close icon -->\n\t\t<template v-if=\"type !== 'search'\" #trailing-button-icon>\n\t\t\t<Close v-if=\"trailingButtonIcon === 'close'\" :size=\"20\" />\n\t\t\t<ArrowRight v-else-if=\"trailingButtonIcon === 'arrowRight'\" :size=\"20\" />\n\t\t\t<Undo v-else-if=\"trailingButtonIcon === 'undo'\" :size=\"20\" />\n\t\t</template>\n\t</NcInputField>\n</template>\n\n<script>\n\nimport NcInputField from '../NcInputField/NcInputField.vue'\n\nimport Close from 'vue-material-design-icons/Close.vue'\nimport ArrowRight from 'vue-material-design-icons/ArrowRight.vue'\nimport Undo from 'vue-material-design-icons/UndoVariant.vue'\n\nimport { t } from '../../l10n.js'\n\nconst NcInputFieldProps = new Set(Object.keys(NcInputField.props))\n\nexport default {\n\tname: 'NcTextField',\n\n\tcomponents: {\n\t\tNcInputField,\n\t\tClose,\n\t\tArrowRight,\n\t\tUndo,\n\t},\n\n\t// Allow forwarding all attributes\n\tinheritAttrs: false,\n\n\tprops: {\n\t\t/**\n\t\t * Any [NcInputField](#/Components/NcFields?id=ncinputfield) props\n\t\t */\n\t\t// Not an actual prop but needed to show in vue-styleguidist docs\n\t\t// eslint-disable-next-line\n\t\t' ': {},\n\n\t\t// Reuse all the props from NcInputField for better typing and documentation\n\t\t...NcInputField.props,\n\n\t\t
|
|
1
|
+
{"version":3,"file":"NcTextField.cjs","sources":["../../node_modules/vue-material-design-icons/UndoVariant.vue","../../src/components/NcTextField/NcTextField.vue"],"sourcesContent":["<template>\n <span v-bind=\"$attrs\"\n :aria-hidden=\"!title\"\n :aria-label=\"title\"\n class=\"material-design-icon undo-variant-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=\"M13.5,7A6.5,6.5 0 0,1 20,13.5A6.5,6.5 0 0,1 13.5,20H10V18H13.5C16,18 18,16 18,13.5C18,11 16,9 13.5,9H7.83L10.91,12.09L9.5,13.5L4,8L9.5,2.5L10.92,3.91L7.83,7H13.5M6,18H8V20H6V18Z\">\n <title v-if=\"title\">{{ title }}</title>\n </path>\n </svg>\n </span>\n</template>\n\n<script>\nexport default {\n name: \"UndoVariantIcon\",\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>","<!--\n - @copyright Copyright (c) 2022 Marco Ambrosini <marcoambrosini@pm.me>\n -\n - @author Marco Ambrosini <marcoambrosini@pm.me>\n -\n - @license GNU AGPL version 3 or any later version\n -\n - This program is free software: you can redistribute it and/or modify\n - it under the terms of the GNU Affero General Public License as\n - published by the Free Software Foundation, either version 3 of the\n - License, or (at your option) any later version.\n -\n - This program is distributed in the hope that it will be useful,\n - but WITHOUT ANY WARRANTY; without even the implied warranty of\n - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n - GNU Affero General Public License for more details.\n -\n - You should have received a copy of the GNU Affero General Public License\n - along with this program. If not, see <http://www.gnu.org/licenses/>.\n-->\n\n<docs>\n### Description\nSee [NcInputField](#/Components/NcFields?id=ncinputfield) for a list of all available props.\n\nGeneral purpose text field component.\nIt is recommended to not only provide a placeholder, but also a label.\nThe label should describe what input is expected and the placehold what format the input should have.\n\nNote: the inner html `input` element inherits all the attributes from the\nNcTextField component so you can add things like `autocomplete`, `maxlength`\nand `minlength`.\n\n```\n<template>\n\t<div class=\"wrapper\">\n\t\t<NcTextField :value.sync=\"text1\"\n\t\t\tlabel=\"Leading icon and clear trailing button\"\n\t\t\ttrailing-button-icon=\"close\"\n\t\t\t:show-trailing-button=\"text1 !== ''\"\n\t\t\t@trailing-button-click=\"clearText\">\n\t\t\t<Magnify :size=\"20\" />\n\t\t</NcTextField>\n\t\t<NcTextField :value.sync=\"text4\"\n\t\t\tlabel=\"Internal label\"\n\t\t\tplaceholder=\"That can be used together with placeholder\"\n\t\t\ttrailing-button-icon=\"close\"\n\t\t\t:show-trailing-button=\"text4 !== ''\"\n\t\t\t@trailing-button-click=\"clearText\">\n\t\t\t<Lock :size=\"20\" />\n\t\t</NcTextField>\n\t\t<NcTextField :value.sync=\"text2\"\n\t\t\tlabel=\"Success state\"\n\t\t\tplaceholder=\"Placeholders are possible\"\n\t\t\t:success=\"true\"\n\t\t\t@trailing-button-click=\"clearText\">\n\t\t</NcTextField>\n\t\t<NcTextField :value.sync=\"text3\"\n\t\t\tlabel=\"Error state\"\n\t\t\tplaceholder=\"Enter something valid\"\n\t\t\t:error=\"true\"\n\t\t\t@trailing-button-click=\"clearText\">\n\t\t</NcTextField>\n\t\t<NcTextField label=\"Disabled\"\n\t\t\t:disabled=\"true\" />\n\t\t<NcTextField label=\"Disabled + Success\"\n\t\t\t:success=\"true\"\n\t\t\t:disabled=\"true\" />\n\t\t<div class=\"external-label\">\n\t\t\t<label for=\"textField\">External label</label>\n\t\t\t<NcTextField :value.sync=\"text5\"\n\t\t\t\tid=\"textField\"\n\t\t\t\t:label-outside=\"true\"\n\t\t\t\tplaceholder=\"Input with external label\"\n\t\t\t\t@trailing-button-click=\"clearText\" />\n\t\t</div>\n\t</div>\n</template>\n<script>\nimport Magnify from 'vue-material-design-icons/Magnify'\nimport Lock from 'vue-material-design-icons/Lock'\nimport Close from 'vue-material-design-icons/Close'\n\nexport default {\n\tdata() {\n\t\treturn {\n\t\t\ttext1: '',\n\t\t\ttext2: '',\n\t\t\ttext3: '',\n\t\t\ttext4: '',\n\t\t\ttext5: '',\n\t\t}\n\t},\n\n\tcomponents: {\n\t\tMagnify,\n\t\tLock,\n\t\tClose,\n\t},\n\n\tmethods: {\n\t\tclearText() {\n\t\t\tthis.text1 = ''\n\t\t\tthis.text3 = ''\n\t\t}\n\t}\n}\n</script>\n<style lang=\"scss\" scoped>\n.wrapper {\n\tdisplay: flex;\n\tgap: 4px;\n\talign-items: flex-end;\n\tflex-wrap: wrap;\n}\n\n.external-label {\n\tdisplay: flex;\n\twidth: 100%;\n\tmargin-top: 1rem;\n}\n\n.external-label label {\n\tpadding-top: 7px;\n\tpadding-right: 14px;\n\twhite-space: nowrap;\n}\n</style>\n```\n</docs>\n\n<template>\n\t<NcInputField v-bind=\"propsAndAttrsToForward\"\n\t\tref=\"inputField\"\n\t\tv-on=\"$listeners\"\n\t\t@input=\"handleInput\">\n\t\t<!-- Default slot for the leading icon -->\n\t\t<slot />\n\n\t\t<!-- Trailing icon slot, except for search type input as the browser already adds a trailing close icon -->\n\t\t<template v-if=\"type !== 'search'\" #trailing-button-icon>\n\t\t\t<Close v-if=\"trailingButtonIcon === 'close'\" :size=\"20\" />\n\t\t\t<ArrowRight v-else-if=\"trailingButtonIcon === 'arrowRight'\" :size=\"20\" />\n\t\t\t<Undo v-else-if=\"trailingButtonIcon === 'undo'\" :size=\"20\" />\n\t\t</template>\n\t</NcInputField>\n</template>\n\n<script>\n\nimport NcInputField from '../NcInputField/NcInputField.vue'\n\nimport Close from 'vue-material-design-icons/Close.vue'\nimport ArrowRight from 'vue-material-design-icons/ArrowRight.vue'\nimport Undo from 'vue-material-design-icons/UndoVariant.vue'\n\nimport { t } from '../../l10n.js'\n\nconst NcInputFieldProps = new Set(Object.keys(NcInputField.props))\n\nexport default {\n\tname: 'NcTextField',\n\n\tcomponents: {\n\t\tNcInputField,\n\t\tClose,\n\t\tArrowRight,\n\t\tUndo,\n\t},\n\n\t// Allow forwarding all attributes\n\tinheritAttrs: false,\n\n\tprops: {\n\t\t/**\n\t\t * Any [NcInputField](#/Components/NcFields?id=ncinputfield) props\n\t\t */\n\t\t// Not an actual prop but needed to show in vue-styleguidist docs\n\t\t// eslint-disable-next-line\n\t\t' ': {},\n\n\t\t// Reuse all the props from NcInputField for better typing and documentation\n\t\t...NcInputField.props,\n\n\t\t/**\n\t\t * The `aria-label` to set on the trailing button\n\t\t * If no explicit value is set it will default to the one matching the `trailingButtonIcon`:\n\t\t * @default 'Clear text'|'Save changes'|'Undo changes'\n\t\t */\n\t\ttrailingButtonLabel: {\n\t\t\ttype: String,\n\t\t\tdefault: '',\n\t\t},\n\n\t\t// Custom props\n\n\t\t/**\n\t\t * Specifies which material design icon should be used for the trailing\n\t\t * button.\n\t\t * @type {'close'|'arrowRight'|'undo'}\n\t\t */\n\t\ttrailingButtonIcon: {\n\t\t\ttype: String,\n\t\t\tdefault: 'close',\n\t\t\tvalidator: (value) => [\n\t\t\t\t'close',\n\t\t\t\t'arrowRight',\n\t\t\t\t'undo',\n\t\t\t].includes(value),\n\t\t},\n\t},\n\n\temits: [\n\t\t'update:value',\n\t],\n\n\tcomputed: {\n\t\tpropsAndAttrsToForward() {\n\t\t\tconst predefinedLabels = {\n\t\t\t\tundo: t('Undo changes'),\n\t\t\t\tclose: t('Clear text'),\n\t\t\t\tarrowRight: t('Save changes'),\n\t\t\t}\n\n\t\t\treturn {\n\t\t\t\t// Proxy all the HTML attributes\n\t\t\t\t...this.$attrs,\n\t\t\t\t// Proxy original NcInputField's props\n\t\t\t\t...Object.fromEntries(\n\t\t\t\t\tObject.entries(this.$props).filter(([key]) => NcInputFieldProps.has(key)),\n\t\t\t\t),\n\t\t\t\t// Adjust aria-label for predefined trailing buttons\n\t\t\t\ttrailingButtonLabel: this.trailingButtonLabel || predefinedLabels[this.trailingButtonIcon],\n\t\t\t}\n\t\t},\n\t},\n\n\tmethods: {\n\t\t/**\n\t\t * Focus the input element\n\t\t *\n\t\t * @public\n\t\t */\n\t\tfocus() {\n\t\t\tthis.$refs.inputField.focus()\n\t\t},\n\n\t\t/**\n\t\t * Select all the text in the input\n\t\t *\n\t\t * @public\n\t\t */\n\t\tselect() {\n\t\t\tthis.$refs.inputField.select()\n\t\t},\n\n\t\thandleInput(event) {\n\t\t\tthis.$emit('update:value', event.target.value)\n\t\t},\n\t},\n}\n</script>\n"],"names":["_sfc_main","NcInputFieldProps","NcInputField","Close","ArrowRight","Undo","value","predefinedLabels","t","key","event"],"mappings":";mPAoBAA,IAAA;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;;;;;;;;;;;;;;;;qBC0HAC,IAAA,IAAA,IAAA,OAAA,KAAAC,EAAA,KAAA,CAAA,GAEAF,IAAA;AAAA,EACA,MAAA;AAAA,EAEA,YAAA;AAAA,IACA,cAAAE;AAAAA,IACA,OAAAC,EAAA;AAAA,IACA,YAAAC,EAAA;AAAA,IACA,MAAAC;AAAA,EACA;AAAA;AAAA,EAGA,cAAA;AAAA,EAEA,OAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAMA,KAAA,CAAA;AAAA;AAAA,IAGA,GAAAH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAOA,qBAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IASA,oBAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,MACA,WAAA,CAAAI,MAAA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,MACA,EAAA,SAAAA,CAAA;AAAA,IACA;AAAA,EACA;AAAA,EAEA,OAAA;AAAA,IACA;AAAA,EACA;AAAA,EAEA,UAAA;AAAA,IACA,yBAAA;AACA,YAAAC,IAAA;AAAA,QACA,MAAAC,EAAA,EAAA,cAAA;AAAA,QACA,OAAAA,EAAA,EAAA,YAAA;AAAA,QACA,YAAAA,EAAA,EAAA,cAAA;AAAA,MACA;AAEA,aAAA;AAAA;AAAA,QAEA,GAAA,KAAA;AAAA;AAAA,QAEA,GAAA,OAAA;AAAA,UACA,OAAA,QAAA,KAAA,MAAA,EAAA,OAAA,CAAA,CAAAC,CAAA,MAAAR,EAAA,IAAAQ,CAAA,CAAA;AAAA,QACA;AAAA;AAAA,QAEA,qBAAA,KAAA,uBAAAF,EAAA,KAAA,kBAAA;AAAA,MACA;AAAA,IACA;AAAA,EACA;AAAA,EAEA,SAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAMA,QAAA;AACA,WAAA,MAAA,WAAA,MAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAOA,SAAA;AACA,WAAA,MAAA,WAAA,OAAA;AAAA,IACA;AAAA,IAEA,YAAAG,GAAA;AACA,WAAA,MAAA,gBAAAA,EAAA,OAAA,KAAA;AAAA,IACA;AAAA,EACA;AACA;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[0]}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import
|
|
1
|
+
import i from "./NcInputField.mjs";
|
|
2
2
|
import { C as l } from "../chunks/Close-271f72e2.mjs";
|
|
3
|
-
import { A as
|
|
4
|
-
import { n as
|
|
5
|
-
import { t as
|
|
3
|
+
import { A as a } from "../chunks/ArrowRight-74a9fcb2.mjs";
|
|
4
|
+
import { n as s } from "../chunks/_plugin-vue2_normalizer-71e2aa87.mjs";
|
|
5
|
+
import { t as r } from "../chunks/l10n-f51d3415.mjs";
|
|
6
6
|
const c = {
|
|
7
7
|
name: "UndoVariantIcon",
|
|
8
8
|
emits: ["click"],
|
|
@@ -22,10 +22,10 @@ const c = {
|
|
|
22
22
|
};
|
|
23
23
|
var u = function() {
|
|
24
24
|
var t = this, e = t._self._c;
|
|
25
|
-
return e("span", t._b({ staticClass: "material-design-icon undo-variant-icon", attrs: { "aria-hidden": !t.title, "aria-label": t.title, role: "img" }, on: { click: function(
|
|
26
|
-
return t.$emit("click",
|
|
25
|
+
return e("span", t._b({ staticClass: "material-design-icon undo-variant-icon", attrs: { "aria-hidden": !t.title, "aria-label": t.title, role: "img" }, on: { click: function(o) {
|
|
26
|
+
return t.$emit("click", o);
|
|
27
27
|
} } }, "span", t.$attrs, !1), [e("svg", { staticClass: "material-design-icon__svg", attrs: { fill: t.fillColor, width: t.size, height: t.size, viewBox: "0 0 24 24" } }, [e("path", { attrs: { d: "M13.5,7A6.5,6.5 0 0,1 20,13.5A6.5,6.5 0 0,1 13.5,20H10V18H13.5C16,18 18,16 18,13.5C18,11 16,9 13.5,9H7.83L10.91,12.09L9.5,13.5L4,8L9.5,2.5L10.92,3.91L7.83,7H13.5M6,18H8V20H6V18Z" } }, [t.title ? e("title", [t._v(t._s(t.title))]) : t._e()])])]);
|
|
28
|
-
}, p = [], d = /* @__PURE__ */
|
|
28
|
+
}, p = [], d = /* @__PURE__ */ s(
|
|
29
29
|
c,
|
|
30
30
|
u,
|
|
31
31
|
p,
|
|
@@ -35,12 +35,12 @@ var u = function() {
|
|
|
35
35
|
null,
|
|
36
36
|
null
|
|
37
37
|
);
|
|
38
|
-
const f = d.exports, _ = new Set(Object.keys(
|
|
38
|
+
const f = d.exports, _ = new Set(Object.keys(i.props)), m = {
|
|
39
39
|
name: "NcTextField",
|
|
40
40
|
components: {
|
|
41
|
-
NcInputField:
|
|
41
|
+
NcInputField: i,
|
|
42
42
|
Close: l,
|
|
43
|
-
ArrowRight:
|
|
43
|
+
ArrowRight: a,
|
|
44
44
|
Undo: f
|
|
45
45
|
},
|
|
46
46
|
// Allow forwarding all attributes
|
|
@@ -53,14 +53,15 @@ const f = d.exports, _ = new Set(Object.keys(r.props)), m = {
|
|
|
53
53
|
// eslint-disable-next-line
|
|
54
54
|
" ": {},
|
|
55
55
|
// Reuse all the props from NcInputField for better typing and documentation
|
|
56
|
-
...
|
|
57
|
-
// Redefined props
|
|
56
|
+
...i.props,
|
|
58
57
|
/**
|
|
59
|
-
*
|
|
58
|
+
* The `aria-label` to set on the trailing button
|
|
59
|
+
* If no explicit value is set it will default to the one matching the `trailingButtonIcon`:
|
|
60
|
+
* @default 'Clear text'|'Save changes'|'Undo changes'
|
|
60
61
|
*/
|
|
61
62
|
trailingButtonLabel: {
|
|
62
63
|
type: String,
|
|
63
|
-
default:
|
|
64
|
+
default: ""
|
|
64
65
|
},
|
|
65
66
|
// Custom props
|
|
66
67
|
/**
|
|
@@ -83,13 +84,20 @@ const f = d.exports, _ = new Set(Object.keys(r.props)), m = {
|
|
|
83
84
|
],
|
|
84
85
|
computed: {
|
|
85
86
|
propsAndAttrsToForward() {
|
|
87
|
+
const n = {
|
|
88
|
+
undo: r("Undo changes"),
|
|
89
|
+
close: r("Clear text"),
|
|
90
|
+
arrowRight: r("Save changes")
|
|
91
|
+
};
|
|
86
92
|
return {
|
|
87
93
|
// Proxy all the HTML attributes
|
|
88
94
|
...this.$attrs,
|
|
89
95
|
// Proxy original NcInputField's props
|
|
90
96
|
...Object.fromEntries(
|
|
91
|
-
Object.entries(this.$props).filter(([
|
|
92
|
-
)
|
|
97
|
+
Object.entries(this.$props).filter(([t]) => _.has(t))
|
|
98
|
+
),
|
|
99
|
+
// Adjust aria-label for predefined trailing buttons
|
|
100
|
+
trailingButtonLabel: this.trailingButtonLabel || n[this.trailingButtonIcon]
|
|
93
101
|
};
|
|
94
102
|
}
|
|
95
103
|
},
|
|
@@ -120,7 +128,7 @@ var g = function() {
|
|
|
120
128
|
return e("NcInputField", t._g(t._b({ ref: "inputField", on: { input: t.handleInput }, scopedSlots: t._u([t.type !== "search" ? { key: "trailing-button-icon", fn: function() {
|
|
121
129
|
return [t.trailingButtonIcon === "close" ? e("Close", { attrs: { size: 20 } }) : t.trailingButtonIcon === "arrowRight" ? e("ArrowRight", { attrs: { size: 20 } }) : t.trailingButtonIcon === "undo" ? e("Undo", { attrs: { size: 20 } }) : t._e()];
|
|
122
130
|
}, proxy: !0 } : null], null, !0) }, "NcInputField", t.propsAndAttrsToForward, !1), t.$listeners), [t._t("default")], 2);
|
|
123
|
-
}, h = [], v = /* @__PURE__ */
|
|
131
|
+
}, h = [], v = /* @__PURE__ */ s(
|
|
124
132
|
m,
|
|
125
133
|
g,
|
|
126
134
|
h,
|
|
@@ -130,7 +138,7 @@ var g = function() {
|
|
|
130
138
|
null,
|
|
131
139
|
null
|
|
132
140
|
);
|
|
133
|
-
const
|
|
141
|
+
const w = v.exports;
|
|
134
142
|
export {
|
|
135
|
-
|
|
143
|
+
w as default
|
|
136
144
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NcTextField.mjs","sources":["../../node_modules/vue-material-design-icons/UndoVariant.vue","../../src/components/NcTextField/NcTextField.vue"],"sourcesContent":["<template>\n <span v-bind=\"$attrs\"\n :aria-hidden=\"!title\"\n :aria-label=\"title\"\n class=\"material-design-icon undo-variant-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=\"M13.5,7A6.5,6.5 0 0,1 20,13.5A6.5,6.5 0 0,1 13.5,20H10V18H13.5C16,18 18,16 18,13.5C18,11 16,9 13.5,9H7.83L10.91,12.09L9.5,13.5L4,8L9.5,2.5L10.92,3.91L7.83,7H13.5M6,18H8V20H6V18Z\">\n <title v-if=\"title\">{{ title }}</title>\n </path>\n </svg>\n </span>\n</template>\n\n<script>\nexport default {\n name: \"UndoVariantIcon\",\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>","<!--\n - @copyright Copyright (c) 2022 Marco Ambrosini <marcoambrosini@pm.me>\n -\n - @author Marco Ambrosini <marcoambrosini@pm.me>\n -\n - @license GNU AGPL version 3 or any later version\n -\n - This program is free software: you can redistribute it and/or modify\n - it under the terms of the GNU Affero General Public License as\n - published by the Free Software Foundation, either version 3 of the\n - License, or (at your option) any later version.\n -\n - This program is distributed in the hope that it will be useful,\n - but WITHOUT ANY WARRANTY; without even the implied warranty of\n - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n - GNU Affero General Public License for more details.\n -\n - You should have received a copy of the GNU Affero General Public License\n - along with this program. If not, see <http://www.gnu.org/licenses/>.\n-->\n\n<docs>\n### Description\nSee [NcInputField](#/Components/NcFields?id=ncinputfield) for a list of all available props.\n\nGeneral purpose text field component.\nIt is recommended to not only provide a placeholder, but also a label.\nThe label should describe what input is expected and the placehold what format the input should have.\n\nNote: the inner html `input` element inherits all the attributes from the\nNcTextField component so you can add things like `autocomplete`, `maxlength`\nand `minlength`.\n\n```\n<template>\n\t<div class=\"wrapper\">\n\t\t<NcTextField :value.sync=\"text1\"\n\t\t\tlabel=\"Leading icon and clear trailing button\"\n\t\t\ttrailing-button-icon=\"close\"\n\t\t\t:show-trailing-button=\"text1 !== ''\"\n\t\t\t@trailing-button-click=\"clearText\">\n\t\t\t<Magnify :size=\"20\" />\n\t\t</NcTextField>\n\t\t<NcTextField :value.sync=\"text4\"\n\t\t\tlabel=\"Internal label\"\n\t\t\tplaceholder=\"That can be used together with placeholder\"\n\t\t\ttrailing-button-icon=\"close\"\n\t\t\t:show-trailing-button=\"text4 !== ''\"\n\t\t\t@trailing-button-click=\"clearText\">\n\t\t\t<Lock :size=\"20\" />\n\t\t</NcTextField>\n\t\t<NcTextField :value.sync=\"text2\"\n\t\t\tlabel=\"Success state\"\n\t\t\tplaceholder=\"Placeholders are possible\"\n\t\t\t:success=\"true\"\n\t\t\t@trailing-button-click=\"clearText\">\n\t\t</NcTextField>\n\t\t<NcTextField :value.sync=\"text3\"\n\t\t\tlabel=\"Error state\"\n\t\t\tplaceholder=\"Enter something valid\"\n\t\t\t:error=\"true\"\n\t\t\t@trailing-button-click=\"clearText\">\n\t\t</NcTextField>\n\t\t<NcTextField label=\"Disabled\"\n\t\t\t:disabled=\"true\" />\n\t\t<NcTextField label=\"Disabled + Success\"\n\t\t\t:success=\"true\"\n\t\t\t:disabled=\"true\" />\n\t\t<div class=\"external-label\">\n\t\t\t<label for=\"textField\">External label</label>\n\t\t\t<NcTextField :value.sync=\"text5\"\n\t\t\t\tid=\"textField\"\n\t\t\t\t:label-outside=\"true\"\n\t\t\t\tplaceholder=\"Input with external label\"\n\t\t\t\t@trailing-button-click=\"clearText\" />\n\t\t</div>\n\t</div>\n</template>\n<script>\nimport Magnify from 'vue-material-design-icons/Magnify'\nimport Lock from 'vue-material-design-icons/Lock'\nimport Close from 'vue-material-design-icons/Close'\n\nexport default {\n\tdata() {\n\t\treturn {\n\t\t\ttext1: '',\n\t\t\ttext2: '',\n\t\t\ttext3: '',\n\t\t\ttext4: '',\n\t\t\ttext5: '',\n\t\t}\n\t},\n\n\tcomponents: {\n\t\tMagnify,\n\t\tLock,\n\t\tClose,\n\t},\n\n\tmethods: {\n\t\tclearText() {\n\t\t\tthis.text1 = ''\n\t\t\tthis.text3 = ''\n\t\t}\n\t}\n}\n</script>\n<style lang=\"scss\" scoped>\n.wrapper {\n\tdisplay: flex;\n\tgap: 4px;\n\talign-items: flex-end;\n\tflex-wrap: wrap;\n}\n\n.external-label {\n\tdisplay: flex;\n\twidth: 100%;\n\tmargin-top: 1rem;\n}\n\n.external-label label {\n\tpadding-top: 7px;\n\tpadding-right: 14px;\n\twhite-space: nowrap;\n}\n</style>\n```\n</docs>\n\n<template>\n\t<NcInputField v-bind=\"propsAndAttrsToForward\"\n\t\tref=\"inputField\"\n\t\tv-on=\"$listeners\"\n\t\t@input=\"handleInput\">\n\t\t<!-- Default slot for the leading icon -->\n\t\t<slot />\n\n\t\t<!-- Trailing icon slot, except for search type input as the browser already adds a trailing close icon -->\n\t\t<template v-if=\"type !== 'search'\" #trailing-button-icon>\n\t\t\t<Close v-if=\"trailingButtonIcon === 'close'\" :size=\"20\" />\n\t\t\t<ArrowRight v-else-if=\"trailingButtonIcon === 'arrowRight'\" :size=\"20\" />\n\t\t\t<Undo v-else-if=\"trailingButtonIcon === 'undo'\" :size=\"20\" />\n\t\t</template>\n\t</NcInputField>\n</template>\n\n<script>\n\nimport NcInputField from '../NcInputField/NcInputField.vue'\n\nimport Close from 'vue-material-design-icons/Close.vue'\nimport ArrowRight from 'vue-material-design-icons/ArrowRight.vue'\nimport Undo from 'vue-material-design-icons/UndoVariant.vue'\n\nimport { t } from '../../l10n.js'\n\nconst NcInputFieldProps = new Set(Object.keys(NcInputField.props))\n\nexport default {\n\tname: 'NcTextField',\n\n\tcomponents: {\n\t\tNcInputField,\n\t\tClose,\n\t\tArrowRight,\n\t\tUndo,\n\t},\n\n\t// Allow forwarding all attributes\n\tinheritAttrs: false,\n\n\tprops: {\n\t\t/**\n\t\t * Any [NcInputField](#/Components/NcFields?id=ncinputfield) props\n\t\t */\n\t\t// Not an actual prop but needed to show in vue-styleguidist docs\n\t\t// eslint-disable-next-line\n\t\t' ': {},\n\n\t\t// Reuse all the props from NcInputField for better typing and documentation\n\t\t...NcInputField.props,\n\n\t\t
|
|
1
|
+
{"version":3,"file":"NcTextField.mjs","sources":["../../node_modules/vue-material-design-icons/UndoVariant.vue","../../src/components/NcTextField/NcTextField.vue"],"sourcesContent":["<template>\n <span v-bind=\"$attrs\"\n :aria-hidden=\"!title\"\n :aria-label=\"title\"\n class=\"material-design-icon undo-variant-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=\"M13.5,7A6.5,6.5 0 0,1 20,13.5A6.5,6.5 0 0,1 13.5,20H10V18H13.5C16,18 18,16 18,13.5C18,11 16,9 13.5,9H7.83L10.91,12.09L9.5,13.5L4,8L9.5,2.5L10.92,3.91L7.83,7H13.5M6,18H8V20H6V18Z\">\n <title v-if=\"title\">{{ title }}</title>\n </path>\n </svg>\n </span>\n</template>\n\n<script>\nexport default {\n name: \"UndoVariantIcon\",\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>","<!--\n - @copyright Copyright (c) 2022 Marco Ambrosini <marcoambrosini@pm.me>\n -\n - @author Marco Ambrosini <marcoambrosini@pm.me>\n -\n - @license GNU AGPL version 3 or any later version\n -\n - This program is free software: you can redistribute it and/or modify\n - it under the terms of the GNU Affero General Public License as\n - published by the Free Software Foundation, either version 3 of the\n - License, or (at your option) any later version.\n -\n - This program is distributed in the hope that it will be useful,\n - but WITHOUT ANY WARRANTY; without even the implied warranty of\n - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n - GNU Affero General Public License for more details.\n -\n - You should have received a copy of the GNU Affero General Public License\n - along with this program. If not, see <http://www.gnu.org/licenses/>.\n-->\n\n<docs>\n### Description\nSee [NcInputField](#/Components/NcFields?id=ncinputfield) for a list of all available props.\n\nGeneral purpose text field component.\nIt is recommended to not only provide a placeholder, but also a label.\nThe label should describe what input is expected and the placehold what format the input should have.\n\nNote: the inner html `input` element inherits all the attributes from the\nNcTextField component so you can add things like `autocomplete`, `maxlength`\nand `minlength`.\n\n```\n<template>\n\t<div class=\"wrapper\">\n\t\t<NcTextField :value.sync=\"text1\"\n\t\t\tlabel=\"Leading icon and clear trailing button\"\n\t\t\ttrailing-button-icon=\"close\"\n\t\t\t:show-trailing-button=\"text1 !== ''\"\n\t\t\t@trailing-button-click=\"clearText\">\n\t\t\t<Magnify :size=\"20\" />\n\t\t</NcTextField>\n\t\t<NcTextField :value.sync=\"text4\"\n\t\t\tlabel=\"Internal label\"\n\t\t\tplaceholder=\"That can be used together with placeholder\"\n\t\t\ttrailing-button-icon=\"close\"\n\t\t\t:show-trailing-button=\"text4 !== ''\"\n\t\t\t@trailing-button-click=\"clearText\">\n\t\t\t<Lock :size=\"20\" />\n\t\t</NcTextField>\n\t\t<NcTextField :value.sync=\"text2\"\n\t\t\tlabel=\"Success state\"\n\t\t\tplaceholder=\"Placeholders are possible\"\n\t\t\t:success=\"true\"\n\t\t\t@trailing-button-click=\"clearText\">\n\t\t</NcTextField>\n\t\t<NcTextField :value.sync=\"text3\"\n\t\t\tlabel=\"Error state\"\n\t\t\tplaceholder=\"Enter something valid\"\n\t\t\t:error=\"true\"\n\t\t\t@trailing-button-click=\"clearText\">\n\t\t</NcTextField>\n\t\t<NcTextField label=\"Disabled\"\n\t\t\t:disabled=\"true\" />\n\t\t<NcTextField label=\"Disabled + Success\"\n\t\t\t:success=\"true\"\n\t\t\t:disabled=\"true\" />\n\t\t<div class=\"external-label\">\n\t\t\t<label for=\"textField\">External label</label>\n\t\t\t<NcTextField :value.sync=\"text5\"\n\t\t\t\tid=\"textField\"\n\t\t\t\t:label-outside=\"true\"\n\t\t\t\tplaceholder=\"Input with external label\"\n\t\t\t\t@trailing-button-click=\"clearText\" />\n\t\t</div>\n\t</div>\n</template>\n<script>\nimport Magnify from 'vue-material-design-icons/Magnify'\nimport Lock from 'vue-material-design-icons/Lock'\nimport Close from 'vue-material-design-icons/Close'\n\nexport default {\n\tdata() {\n\t\treturn {\n\t\t\ttext1: '',\n\t\t\ttext2: '',\n\t\t\ttext3: '',\n\t\t\ttext4: '',\n\t\t\ttext5: '',\n\t\t}\n\t},\n\n\tcomponents: {\n\t\tMagnify,\n\t\tLock,\n\t\tClose,\n\t},\n\n\tmethods: {\n\t\tclearText() {\n\t\t\tthis.text1 = ''\n\t\t\tthis.text3 = ''\n\t\t}\n\t}\n}\n</script>\n<style lang=\"scss\" scoped>\n.wrapper {\n\tdisplay: flex;\n\tgap: 4px;\n\talign-items: flex-end;\n\tflex-wrap: wrap;\n}\n\n.external-label {\n\tdisplay: flex;\n\twidth: 100%;\n\tmargin-top: 1rem;\n}\n\n.external-label label {\n\tpadding-top: 7px;\n\tpadding-right: 14px;\n\twhite-space: nowrap;\n}\n</style>\n```\n</docs>\n\n<template>\n\t<NcInputField v-bind=\"propsAndAttrsToForward\"\n\t\tref=\"inputField\"\n\t\tv-on=\"$listeners\"\n\t\t@input=\"handleInput\">\n\t\t<!-- Default slot for the leading icon -->\n\t\t<slot />\n\n\t\t<!-- Trailing icon slot, except for search type input as the browser already adds a trailing close icon -->\n\t\t<template v-if=\"type !== 'search'\" #trailing-button-icon>\n\t\t\t<Close v-if=\"trailingButtonIcon === 'close'\" :size=\"20\" />\n\t\t\t<ArrowRight v-else-if=\"trailingButtonIcon === 'arrowRight'\" :size=\"20\" />\n\t\t\t<Undo v-else-if=\"trailingButtonIcon === 'undo'\" :size=\"20\" />\n\t\t</template>\n\t</NcInputField>\n</template>\n\n<script>\n\nimport NcInputField from '../NcInputField/NcInputField.vue'\n\nimport Close from 'vue-material-design-icons/Close.vue'\nimport ArrowRight from 'vue-material-design-icons/ArrowRight.vue'\nimport Undo from 'vue-material-design-icons/UndoVariant.vue'\n\nimport { t } from '../../l10n.js'\n\nconst NcInputFieldProps = new Set(Object.keys(NcInputField.props))\n\nexport default {\n\tname: 'NcTextField',\n\n\tcomponents: {\n\t\tNcInputField,\n\t\tClose,\n\t\tArrowRight,\n\t\tUndo,\n\t},\n\n\t// Allow forwarding all attributes\n\tinheritAttrs: false,\n\n\tprops: {\n\t\t/**\n\t\t * Any [NcInputField](#/Components/NcFields?id=ncinputfield) props\n\t\t */\n\t\t// Not an actual prop but needed to show in vue-styleguidist docs\n\t\t// eslint-disable-next-line\n\t\t' ': {},\n\n\t\t// Reuse all the props from NcInputField for better typing and documentation\n\t\t...NcInputField.props,\n\n\t\t/**\n\t\t * The `aria-label` to set on the trailing button\n\t\t * If no explicit value is set it will default to the one matching the `trailingButtonIcon`:\n\t\t * @default 'Clear text'|'Save changes'|'Undo changes'\n\t\t */\n\t\ttrailingButtonLabel: {\n\t\t\ttype: String,\n\t\t\tdefault: '',\n\t\t},\n\n\t\t// Custom props\n\n\t\t/**\n\t\t * Specifies which material design icon should be used for the trailing\n\t\t * button.\n\t\t * @type {'close'|'arrowRight'|'undo'}\n\t\t */\n\t\ttrailingButtonIcon: {\n\t\t\ttype: String,\n\t\t\tdefault: 'close',\n\t\t\tvalidator: (value) => [\n\t\t\t\t'close',\n\t\t\t\t'arrowRight',\n\t\t\t\t'undo',\n\t\t\t].includes(value),\n\t\t},\n\t},\n\n\temits: [\n\t\t'update:value',\n\t],\n\n\tcomputed: {\n\t\tpropsAndAttrsToForward() {\n\t\t\tconst predefinedLabels = {\n\t\t\t\tundo: t('Undo changes'),\n\t\t\t\tclose: t('Clear text'),\n\t\t\t\tarrowRight: t('Save changes'),\n\t\t\t}\n\n\t\t\treturn {\n\t\t\t\t// Proxy all the HTML attributes\n\t\t\t\t...this.$attrs,\n\t\t\t\t// Proxy original NcInputField's props\n\t\t\t\t...Object.fromEntries(\n\t\t\t\t\tObject.entries(this.$props).filter(([key]) => NcInputFieldProps.has(key)),\n\t\t\t\t),\n\t\t\t\t// Adjust aria-label for predefined trailing buttons\n\t\t\t\ttrailingButtonLabel: this.trailingButtonLabel || predefinedLabels[this.trailingButtonIcon],\n\t\t\t}\n\t\t},\n\t},\n\n\tmethods: {\n\t\t/**\n\t\t * Focus the input element\n\t\t *\n\t\t * @public\n\t\t */\n\t\tfocus() {\n\t\t\tthis.$refs.inputField.focus()\n\t\t},\n\n\t\t/**\n\t\t * Select all the text in the input\n\t\t *\n\t\t * @public\n\t\t */\n\t\tselect() {\n\t\t\tthis.$refs.inputField.select()\n\t\t},\n\n\t\thandleInput(event) {\n\t\t\tthis.$emit('update:value', event.target.value)\n\t\t},\n\t},\n}\n</script>\n"],"names":["_sfc_main","NcInputFieldProps","NcInputField","Close","ArrowRight","Undo","value","predefinedLabels","t","key","event"],"mappings":";;;;;AAoBA,MAAAA,IAAA;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;;;;;;;;;;;;;;;;qBC0HAC,IAAA,IAAA,IAAA,OAAA,KAAAC,EAAA,KAAA,CAAA,GAEAF,IAAA;AAAA,EACA,MAAA;AAAA,EAEA,YAAA;AAAA,IACA,cAAAE;AAAA,IACA,OAAAC;AAAA,IACA,YAAAC;AAAA,IACA,MAAAC;AAAA,EACA;AAAA;AAAA,EAGA,cAAA;AAAA,EAEA,OAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAMA,KAAA,CAAA;AAAA;AAAA,IAGA,GAAAH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAOA,qBAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IASA,oBAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,MACA,WAAA,CAAAI,MAAA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,MACA,EAAA,SAAAA,CAAA;AAAA,IACA;AAAA,EACA;AAAA,EAEA,OAAA;AAAA,IACA;AAAA,EACA;AAAA,EAEA,UAAA;AAAA,IACA,yBAAA;AACA,YAAAC,IAAA;AAAA,QACA,MAAAC,EAAA,cAAA;AAAA,QACA,OAAAA,EAAA,YAAA;AAAA,QACA,YAAAA,EAAA,cAAA;AAAA,MACA;AAEA,aAAA;AAAA;AAAA,QAEA,GAAA,KAAA;AAAA;AAAA,QAEA,GAAA,OAAA;AAAA,UACA,OAAA,QAAA,KAAA,MAAA,EAAA,OAAA,CAAA,CAAAC,CAAA,MAAAR,EAAA,IAAAQ,CAAA,CAAA;AAAA,QACA;AAAA;AAAA,QAEA,qBAAA,KAAA,uBAAAF,EAAA,KAAA,kBAAA;AAAA,MACA;AAAA,IACA;AAAA,EACA;AAAA,EAEA,SAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAMA,QAAA;AACA,WAAA,MAAA,WAAA,MAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAOA,SAAA;AACA,WAAA,MAAA,WAAA,OAAA;AAAA,IACA;AAAA,IAEA,YAAAG,GAAA;AACA,WAAA,MAAA,gBAAAA,EAAA,OAAA,KAAA;AAAA,IACA;AAAA,EACA;AACA;;;;;;;;;;;;;;;;;","x_google_ignoreList":[0]}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
const N = require("../chunks/l10n-
|
|
2
|
+
const N = require("../chunks/l10n-c3dbf018.cjs"), t = require("../chunks/logger-4998b668.cjs"), e = require("@nextcloud/calendar-js"), Z = require("../chunks/GenRandomId-c214d235.cjs"), Y = require("./NcSelect.cjs"), M = require("../chunks/_plugin-vue2_normalizer-7f9efb60.cjs");
|
|
3
3
|
/**
|
|
4
4
|
* @copyright Copyright (c) 2019 Georg Ehrke
|
|
5
5
|
*
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as N } from "../chunks/l10n-
|
|
1
|
+
import { t as N } from "../chunks/l10n-f51d3415.mjs";
|
|
2
2
|
import { l as t } from "../chunks/logger-3612e664.mjs";
|
|
3
3
|
import { getTimezoneManager as e } from "@nextcloud/calendar-js";
|
|
4
4
|
import { G as Z } from "../chunks/GenRandomId-cb9ccebe.mjs";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
var y = require("../assets/index-c221fe05.css");
|
|
2
|
-
const s = require("../chunks/_plugin-vue2_normalizer-7f9efb60.cjs"), a = require("../chunks/index-
|
|
2
|
+
const s = require("../chunks/_plugin-vue2_normalizer-7f9efb60.cjs"), a = require("../chunks/index-ac31691c.cjs"), n = require("./NcPopover.cjs"), i = require("vue"), o = (t) => t && t.__esModule ? t : { default: t }, u = /* @__PURE__ */ o(i), l = {
|
|
3
3
|
name: "NcUserBubbleDiv"
|
|
4
4
|
};
|
|
5
5
|
var c = function() {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import "../assets/index-c221fe05.css";
|
|
2
2
|
import { n as s } from "../chunks/_plugin-vue2_normalizer-71e2aa87.mjs";
|
|
3
|
-
import { N as a } from "../chunks/index-
|
|
3
|
+
import { N as a } from "../chunks/index-831524a1.mjs";
|
|
4
4
|
import n from "./NcPopover.mjs";
|
|
5
5
|
import i from "vue";
|
|
6
6
|
const o = {
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
+
const e = require("vue");
|
|
4
|
+
/**
|
|
5
|
+
* @copyright Copyright (c) 2019 John Molakvoæ <skjnldsv@protonmail.com>
|
|
6
|
+
*
|
|
7
|
+
* @author John Molakvoæ <skjnldsv@protonmail.com>
|
|
8
|
+
* @author Grigorii K. Shartsev <me@shgk.me>
|
|
9
|
+
*
|
|
10
|
+
* @license AGPL-3.0-or-later
|
|
11
|
+
*
|
|
12
|
+
* This program is free software: you can redistribute it and/or modify
|
|
13
|
+
* it under the terms of the GNU Affero General Public License as
|
|
14
|
+
* published by the Free Software Foundation, either version 3 of the
|
|
15
|
+
* License, or (at your option) any later version.
|
|
16
|
+
*
|
|
17
|
+
* This program is distributed in the hope that it will be useful,
|
|
18
|
+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
19
|
+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
20
|
+
* GNU Affero General Public License for more details.
|
|
21
|
+
*
|
|
22
|
+
* You should have received a copy of the GNU Affero General Public License
|
|
23
|
+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
24
|
+
*
|
|
25
|
+
*/
|
|
26
|
+
const n = () => window.outerHeight === screen.height, s = e.ref(n());
|
|
27
|
+
window.addEventListener("resize", () => {
|
|
28
|
+
s.value = n();
|
|
29
|
+
});
|
|
30
|
+
function r() {
|
|
31
|
+
return e.readonly(s);
|
|
32
|
+
}
|
|
33
|
+
const t = e.readonly(s);
|
|
34
|
+
exports.isFullscreenState = t;
|
|
35
|
+
exports.useIsFullscreen = r;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useIsFullscreen.cjs","sources":["../../src/composables/useIsFullscreen/index.js"],"sourcesContent":["/**\n * @copyright Copyright (c) 2019 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n * @author Grigorii K. Shartsev <me@shgk.me>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport { readonly, ref } from 'vue'\n\n// if the window height is equal to the screen height,\n// we're in full screen mode\nconst checkIfIsFullscreen = () => window.outerHeight === screen.height\n\nconst isFullscreen = ref(checkIfIsFullscreen())\n\nwindow.addEventListener('resize', () => {\n\tisFullscreen.value = checkIfIsFullscreen()\n})\n\n/**\n * Use global isFullscreen state, based on the screen height check\n *\n * @return {import('vue').DeepReadonly<import('vue').Ref<boolean>>}\n */\nexport function useIsFullscreen() {\n\treturn readonly(isFullscreen)\n}\n\n/**\n * @deprecated Is to be removed in v9.0.0 with Vue 3 migration.\n * Use `composables/useIsFullscreen` instead.\n * Defined and exported only for isFullscreen mixin.\n */\nexport const isFullscreenState = readonly(isFullscreen)\n"],"names":["checkIfIsFullscreen","isFullscreen","ref","useIsFullscreen","readonly","isFullscreenState"],"mappings":";;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AA2BA,MAAMA,IAAsB,MAAM,OAAO,gBAAgB,OAAO,QAE1DC,IAAeC,EAAAA,IAAIF,GAAqB;AAE9C,OAAO,iBAAiB,UAAU,MAAM;AACvC,EAAAC,EAAa,QAAQD,EAAqB;AAC3C,CAAC;AAOM,SAASG,IAAkB;AACjC,SAAOC,EAAAA,SAASH,CAAY;AAC7B;AAOY,MAACI,IAAoBD,EAAQ,SAACH,CAAY;;;"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { ref as s, readonly as n } from "vue";
|
|
2
|
+
/**
|
|
3
|
+
* @copyright Copyright (c) 2019 John Molakvoæ <skjnldsv@protonmail.com>
|
|
4
|
+
*
|
|
5
|
+
* @author John Molakvoæ <skjnldsv@protonmail.com>
|
|
6
|
+
* @author Grigorii K. Shartsev <me@shgk.me>
|
|
7
|
+
*
|
|
8
|
+
* @license AGPL-3.0-or-later
|
|
9
|
+
*
|
|
10
|
+
* This program is free software: you can redistribute it and/or modify
|
|
11
|
+
* it under the terms of the GNU Affero General Public License as
|
|
12
|
+
* published by the Free Software Foundation, either version 3 of the
|
|
13
|
+
* License, or (at your option) any later version.
|
|
14
|
+
*
|
|
15
|
+
* This program is distributed in the hope that it will be useful,
|
|
16
|
+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
17
|
+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
18
|
+
* GNU Affero General Public License for more details.
|
|
19
|
+
*
|
|
20
|
+
* You should have received a copy of the GNU Affero General Public License
|
|
21
|
+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
22
|
+
*
|
|
23
|
+
*/
|
|
24
|
+
const r = () => window.outerHeight === screen.height, e = s(r());
|
|
25
|
+
window.addEventListener("resize", () => {
|
|
26
|
+
e.value = r();
|
|
27
|
+
});
|
|
28
|
+
function c() {
|
|
29
|
+
return n(e);
|
|
30
|
+
}
|
|
31
|
+
const o = n(e);
|
|
32
|
+
export {
|
|
33
|
+
o as isFullscreenState,
|
|
34
|
+
c as useIsFullscreen
|
|
35
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useIsFullscreen.mjs","sources":["../../src/composables/useIsFullscreen/index.js"],"sourcesContent":["/**\n * @copyright Copyright (c) 2019 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n * @author Grigorii K. Shartsev <me@shgk.me>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport { readonly, ref } from 'vue'\n\n// if the window height is equal to the screen height,\n// we're in full screen mode\nconst checkIfIsFullscreen = () => window.outerHeight === screen.height\n\nconst isFullscreen = ref(checkIfIsFullscreen())\n\nwindow.addEventListener('resize', () => {\n\tisFullscreen.value = checkIfIsFullscreen()\n})\n\n/**\n * Use global isFullscreen state, based on the screen height check\n *\n * @return {import('vue').DeepReadonly<import('vue').Ref<boolean>>}\n */\nexport function useIsFullscreen() {\n\treturn readonly(isFullscreen)\n}\n\n/**\n * @deprecated Is to be removed in v9.0.0 with Vue 3 migration.\n * Use `composables/useIsFullscreen` instead.\n * Defined and exported only for isFullscreen mixin.\n */\nexport const isFullscreenState = readonly(isFullscreen)\n"],"names":["checkIfIsFullscreen","isFullscreen","ref","useIsFullscreen","readonly","isFullscreenState"],"mappings":";AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AA2BA,MAAMA,IAAsB,MAAM,OAAO,gBAAgB,OAAO,QAE1DC,IAAeC,EAAIF,GAAqB;AAE9C,OAAO,iBAAiB,UAAU,MAAM;AACvC,EAAAC,EAAa,QAAQD,EAAqB;AAC3C,CAAC;AAOM,SAASG,IAAkB;AACjC,SAAOC,EAASH,CAAY;AAC7B;AAOY,MAACI,IAAoBD,EAASH,CAAY;"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
+
const e = require("vue");
|
|
4
|
+
/**
|
|
5
|
+
* @copyright Copyright (c) 2023 Grigorii K. Shartsev <me@shgk.me>
|
|
6
|
+
*
|
|
7
|
+
* @author Grigorii K. Shartsev <me@shgk.me>
|
|
8
|
+
*
|
|
9
|
+
* @license AGPL-3.0-or-later
|
|
10
|
+
*
|
|
11
|
+
* This program is free software: you can redistribute it and/or modify
|
|
12
|
+
* it under the terms of the GNU Affero General Public License as
|
|
13
|
+
* published by the Free Software Foundation, either version 3 of the
|
|
14
|
+
* License, or (at your option) any later version.
|
|
15
|
+
*
|
|
16
|
+
* This program is distributed in the hope that it will be useful,
|
|
17
|
+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
18
|
+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
19
|
+
* GNU Affero General Public License for more details.
|
|
20
|
+
*
|
|
21
|
+
* You should have received a copy of the GNU Affero General Public License
|
|
22
|
+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
23
|
+
*
|
|
24
|
+
*/
|
|
25
|
+
const o = 1024, i = () => document.documentElement.clientWidth < o, t = e.ref(i());
|
|
26
|
+
window.addEventListener("resize", () => {
|
|
27
|
+
t.value = i();
|
|
28
|
+
});
|
|
29
|
+
function n() {
|
|
30
|
+
return e.readonly(t);
|
|
31
|
+
}
|
|
32
|
+
const s = e.readonly(t);
|
|
33
|
+
exports.MOBILE_BREAKPOINT = o;
|
|
34
|
+
exports.isMobileState = s;
|
|
35
|
+
exports.useIsMobile = n;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useIsMobile.cjs","sources":["../../src/composables/useIsMobile/index.js"],"sourcesContent":["/**\n * @copyright Copyright (c) 2023 Grigorii K. Shartsev <me@shgk.me>\n *\n * @author Grigorii K. Shartsev <me@shgk.me>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport { readonly, ref } from 'vue'\n\n/**\n * The minimal width of the viewport to be considered a desktop device\n */\nexport const MOBILE_BREAKPOINT = 1024\n\nconst checkIfIsMobile = () => document.documentElement.clientWidth < MOBILE_BREAKPOINT\n\nconst isMobile = ref(checkIfIsMobile())\n\nwindow.addEventListener('resize', () => {\n\tisMobile.value = checkIfIsMobile()\n})\n\n/**\n * Use global isMobile state, based on the viewport width\n *\n * @return {import('vue').DeepReadonly<import('vue').Ref<boolean>>}\n */\nexport function useIsMobile() {\n\treturn readonly(isMobile)\n}\n\n/**\n * @deprecated Is to be removed in v9.0.0 with Vue 3 migration.\n * Use `composables/useIsMobile` instead.\n * Defined and exported only for isMobile mixin.\n */\nexport const isMobileState = readonly(isMobile)\n"],"names":["MOBILE_BREAKPOINT","checkIfIsMobile","isMobile","ref","useIsMobile","readonly","isMobileState"],"mappings":";;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AA2BY,MAACA,IAAoB,MAE3BC,IAAkB,MAAM,SAAS,gBAAgB,cAAcD,GAE/DE,IAAWC,EAAAA,IAAIF,GAAiB;AAEtC,OAAO,iBAAiB,UAAU,MAAM;AACvC,EAAAC,EAAS,QAAQD,EAAiB;AACnC,CAAC;AAOM,SAASG,IAAc;AAC7B,SAAOC,EAAAA,SAASH,CAAQ;AACzB;AAOY,MAACI,IAAgBD,EAAQ,SAACH,CAAQ;;;;"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { ref as n, readonly as t } from "vue";
|
|
2
|
+
/**
|
|
3
|
+
* @copyright Copyright (c) 2023 Grigorii K. Shartsev <me@shgk.me>
|
|
4
|
+
*
|
|
5
|
+
* @author Grigorii K. Shartsev <me@shgk.me>
|
|
6
|
+
*
|
|
7
|
+
* @license AGPL-3.0-or-later
|
|
8
|
+
*
|
|
9
|
+
* This program is free software: you can redistribute it and/or modify
|
|
10
|
+
* it under the terms of the GNU Affero General Public License as
|
|
11
|
+
* published by the Free Software Foundation, either version 3 of the
|
|
12
|
+
* License, or (at your option) any later version.
|
|
13
|
+
*
|
|
14
|
+
* This program is distributed in the hope that it will be useful,
|
|
15
|
+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
16
|
+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
17
|
+
* GNU Affero General Public License for more details.
|
|
18
|
+
*
|
|
19
|
+
* You should have received a copy of the GNU Affero General Public License
|
|
20
|
+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
21
|
+
*
|
|
22
|
+
*/
|
|
23
|
+
const i = 1024, o = () => document.documentElement.clientWidth < i, e = n(o());
|
|
24
|
+
window.addEventListener("resize", () => {
|
|
25
|
+
e.value = o();
|
|
26
|
+
});
|
|
27
|
+
function c() {
|
|
28
|
+
return t(e);
|
|
29
|
+
}
|
|
30
|
+
const r = t(e);
|
|
31
|
+
export {
|
|
32
|
+
i as MOBILE_BREAKPOINT,
|
|
33
|
+
r as isMobileState,
|
|
34
|
+
c as useIsMobile
|
|
35
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useIsMobile.mjs","sources":["../../src/composables/useIsMobile/index.js"],"sourcesContent":["/**\n * @copyright Copyright (c) 2023 Grigorii K. Shartsev <me@shgk.me>\n *\n * @author Grigorii K. Shartsev <me@shgk.me>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport { readonly, ref } from 'vue'\n\n/**\n * The minimal width of the viewport to be considered a desktop device\n */\nexport const MOBILE_BREAKPOINT = 1024\n\nconst checkIfIsMobile = () => document.documentElement.clientWidth < MOBILE_BREAKPOINT\n\nconst isMobile = ref(checkIfIsMobile())\n\nwindow.addEventListener('resize', () => {\n\tisMobile.value = checkIfIsMobile()\n})\n\n/**\n * Use global isMobile state, based on the viewport width\n *\n * @return {import('vue').DeepReadonly<import('vue').Ref<boolean>>}\n */\nexport function useIsMobile() {\n\treturn readonly(isMobile)\n}\n\n/**\n * @deprecated Is to be removed in v9.0.0 with Vue 3 migration.\n * Use `composables/useIsMobile` instead.\n * Defined and exported only for isMobile mixin.\n */\nexport const isMobileState = readonly(isMobile)\n"],"names":["MOBILE_BREAKPOINT","checkIfIsMobile","isMobile","ref","useIsMobile","readonly","isMobileState"],"mappings":";AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AA2BY,MAACA,IAAoB,MAE3BC,IAAkB,MAAM,SAAS,gBAAgB,cAAcD,GAE/DE,IAAWC,EAAIF,GAAiB;AAEtC,OAAO,iBAAiB,UAAU,MAAM;AACvC,EAAAC,EAAS,QAAQD,EAAiB;AACnC,CAAC;AAOM,SAASG,IAAc;AAC7B,SAAOC,EAASH,CAAQ;AACzB;AAOY,MAACI,IAAgBD,EAASH,CAAQ;"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
const e = require("../Composables/useIsFullscreen.cjs");
|
|
2
3
|
/**
|
|
3
4
|
* @copyright Copyright (c) 2019 John Molakvoæ <skjnldsv@protonmail.com>
|
|
4
5
|
*
|
|
@@ -20,25 +21,15 @@
|
|
|
20
21
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
21
22
|
*
|
|
22
23
|
*/
|
|
23
|
-
const
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
},
|
|
32
|
-
beforeDestroy() {
|
|
33
|
-
window.removeEventListener("resize", this._onResize);
|
|
34
|
-
},
|
|
35
|
-
methods: {
|
|
36
|
-
_onResize() {
|
|
37
|
-
this.isFullscreen = this._isFullscreen();
|
|
38
|
-
},
|
|
39
|
-
_isFullscreen() {
|
|
40
|
-
return window.outerHeight === screen.height;
|
|
24
|
+
const s = {
|
|
25
|
+
computed: {
|
|
26
|
+
/**
|
|
27
|
+
* @deprecated Is to be removed in v9.0.0 with Vue 3 migration.
|
|
28
|
+
* Use `composables/useIsFullscreen` instead.
|
|
29
|
+
*/
|
|
30
|
+
isFullscreen() {
|
|
31
|
+
return e.isFullscreenState.value;
|
|
41
32
|
}
|
|
42
33
|
}
|
|
43
34
|
};
|
|
44
|
-
module.exports =
|
|
35
|
+
module.exports = s;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"isFullscreen.cjs","sources":["../../src/mixins/isFullscreen/index.js"],"sourcesContent":["/**\n * @copyright Copyright (c) 2019 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\
|
|
1
|
+
{"version":3,"file":"isFullscreen.cjs","sources":["../../src/mixins/isFullscreen/index.js"],"sourcesContent":["/**\n * @copyright Copyright (c) 2019 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport { isFullscreenState } from '../../composables/useIsFullscreen/index.js'\n\nexport default {\n\tcomputed: {\n\t\t/**\n\t\t * @deprecated Is to be removed in v9.0.0 with Vue 3 migration.\n\t\t * Use `composables/useIsFullscreen` instead.\n\t\t */\n\t\tisFullscreen() {\n\t\t\treturn isFullscreenState.value\n\t\t},\n\t},\n}\n"],"names":["index","isFullscreenState"],"mappings":";;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAwBA,MAAeA,IAAA;AAAA,EACd,UAAU;AAAA;AAAA;AAAA;AAAA;AAAA,IAKT,eAAe;AACd,aAAOC,EAAiB,kBAAC;AAAA,IACzB;AAAA,EACD;AACF;;"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { isFullscreenState as e } from "../Composables/useIsFullscreen.mjs";
|
|
1
2
|
/**
|
|
2
3
|
* @copyright Copyright (c) 2019 John Molakvoæ <skjnldsv@protonmail.com>
|
|
3
4
|
*
|
|
@@ -19,27 +20,17 @@
|
|
|
19
20
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
20
21
|
*
|
|
21
22
|
*/
|
|
22
|
-
const
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
},
|
|
31
|
-
beforeDestroy() {
|
|
32
|
-
window.removeEventListener("resize", this._onResize);
|
|
33
|
-
},
|
|
34
|
-
methods: {
|
|
35
|
-
_onResize() {
|
|
36
|
-
this.isFullscreen = this._isFullscreen();
|
|
37
|
-
},
|
|
38
|
-
_isFullscreen() {
|
|
39
|
-
return window.outerHeight === screen.height;
|
|
23
|
+
const r = {
|
|
24
|
+
computed: {
|
|
25
|
+
/**
|
|
26
|
+
* @deprecated Is to be removed in v9.0.0 with Vue 3 migration.
|
|
27
|
+
* Use `composables/useIsFullscreen` instead.
|
|
28
|
+
*/
|
|
29
|
+
isFullscreen() {
|
|
30
|
+
return e.value;
|
|
40
31
|
}
|
|
41
32
|
}
|
|
42
33
|
};
|
|
43
34
|
export {
|
|
44
|
-
|
|
35
|
+
r as default
|
|
45
36
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"isFullscreen.mjs","sources":["../../src/mixins/isFullscreen/index.js"],"sourcesContent":["/**\n * @copyright Copyright (c) 2019 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\
|
|
1
|
+
{"version":3,"file":"isFullscreen.mjs","sources":["../../src/mixins/isFullscreen/index.js"],"sourcesContent":["/**\n * @copyright Copyright (c) 2019 John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @author John Molakvoæ <skjnldsv@protonmail.com>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport { isFullscreenState } from '../../composables/useIsFullscreen/index.js'\n\nexport default {\n\tcomputed: {\n\t\t/**\n\t\t * @deprecated Is to be removed in v9.0.0 with Vue 3 migration.\n\t\t * Use `composables/useIsFullscreen` instead.\n\t\t */\n\t\tisFullscreen() {\n\t\t\treturn isFullscreenState.value\n\t\t},\n\t},\n}\n"],"names":["index","isFullscreenState"],"mappings":";AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAwBA,MAAeA,IAAA;AAAA,EACd,UAAU;AAAA;AAAA;AAAA;AAAA;AAAA,IAKT,eAAe;AACd,aAAOC,EAAkB;AAAA,IACzB;AAAA,EACD;AACF;"}
|
package/dist/Mixins/isMobile.cjs
CHANGED
|
@@ -1,50 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
const
|
|
3
|
-
/**
|
|
4
|
-
* @copyright Copyright (c) 2019 Kristof Hamann, Paul Schwörer
|
|
5
|
-
*
|
|
6
|
-
* @author Kristof Hamann
|
|
7
|
-
* @author Paul Schwörer
|
|
8
|
-
*
|
|
9
|
-
* @license AGPL-3.0-or-later
|
|
10
|
-
*
|
|
11
|
-
* This program is free software: you can redistribute it and/or modify
|
|
12
|
-
* it under the terms of the GNU Affero General Public License as
|
|
13
|
-
* published by the Free Software Foundation, either version 3 of the
|
|
14
|
-
* License, or (at your option) any later version.
|
|
15
|
-
*
|
|
16
|
-
* This program is distributed in the hope that it will be useful,
|
|
17
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
18
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
19
|
-
* GNU Affero General Public License for more details.
|
|
20
|
-
*
|
|
21
|
-
* You should have received a copy of the GNU Affero General Public License
|
|
22
|
-
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
23
|
-
*
|
|
24
|
-
*/
|
|
25
|
-
const i = /* @__PURE__ */ new o.default({
|
|
26
|
-
data() {
|
|
27
|
-
return {
|
|
28
|
-
isMobile: !1
|
|
29
|
-
};
|
|
30
|
-
},
|
|
31
|
-
watch: {
|
|
32
|
-
isMobile(e) {
|
|
33
|
-
this.$emit("changed", e);
|
|
34
|
-
}
|
|
35
|
-
},
|
|
36
|
-
created() {
|
|
37
|
-
window.addEventListener("resize", this.handleWindowResize), this.handleWindowResize();
|
|
38
|
-
},
|
|
39
|
-
beforeDestroy() {
|
|
40
|
-
window.removeEventListener("resize", this.handleWindowResize);
|
|
41
|
-
},
|
|
42
|
-
methods: {
|
|
43
|
-
handleWindowResize() {
|
|
44
|
-
this.isMobile = document.documentElement.clientWidth < 1024;
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
});
|
|
2
|
+
const e = require("../Composables/useIsMobile.cjs");
|
|
48
3
|
/**
|
|
49
4
|
* @copyright Copyright (c) 2019 John Molakvoæ <skjnldsv@protonmail.com>
|
|
50
5
|
*
|
|
@@ -66,22 +21,15 @@ const i = /* @__PURE__ */ new o.default({
|
|
|
66
21
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
67
22
|
*
|
|
68
23
|
*/
|
|
69
|
-
const
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
},
|
|
78
|
-
beforeDestroy() {
|
|
79
|
-
i.$off("changed", this.onIsMobileChanged);
|
|
80
|
-
},
|
|
81
|
-
methods: {
|
|
82
|
-
onIsMobileChanged(e) {
|
|
83
|
-
this.isMobile = e;
|
|
24
|
+
const s = {
|
|
25
|
+
computed: {
|
|
26
|
+
/**
|
|
27
|
+
* @deprecated Is to be removed in v9.0.0 with Vue 3 migration.
|
|
28
|
+
* Use `composables/useIsMobile` instead.
|
|
29
|
+
*/
|
|
30
|
+
isMobile() {
|
|
31
|
+
return e.isMobileState.value;
|
|
84
32
|
}
|
|
85
33
|
}
|
|
86
34
|
};
|
|
87
|
-
module.exports =
|
|
35
|
+
module.exports = s;
|