quasar 2.3.2 → 2.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api/AppFullscreen.json +15 -8
- package/dist/api/BottomSheet.json +6 -0
- package/dist/api/Cookies.json +4 -3
- package/dist/api/Dialog.json +24 -10
- package/dist/api/Loading.json +0 -2
- package/dist/api/LoadingBar.json +8 -3
- package/dist/api/Morph.json +14 -7
- package/dist/api/Mutation.json +1 -1
- package/dist/api/Notify.json +41 -27
- package/dist/api/QAjaxBar.json +6 -3
- package/dist/api/QBreadcrumbs.json +8 -4
- package/dist/api/QBreadcrumbsEl.json +35 -12
- package/dist/api/QBtn.json +36 -17
- package/dist/api/QBtnDropdown.json +41 -20
- package/dist/api/QBtnToggle.json +7 -2
- package/dist/api/QCard.json +2 -1
- package/dist/api/QCardActions.json +2 -1
- package/dist/api/QCardSection.json +2 -1
- package/dist/api/QCarousel.json +10 -5
- package/dist/api/QCarouselControl.json +4 -2
- package/dist/api/QChatMessage.json +0 -4
- package/dist/api/QCheckbox.json +8 -4
- package/dist/api/QChip.json +2 -1
- package/dist/api/QCircularProgress.json +14 -7
- package/dist/api/QColor.json +6 -3
- package/dist/api/QDate.json +33 -5
- package/dist/api/QDialog.json +8 -4
- package/dist/api/QDrawer.json +10 -5
- package/dist/api/QEditor.json +10 -5
- package/dist/api/QExpansionItem.json +36 -13
- package/dist/api/QFab.json +41 -6
- package/dist/api/QFabAction.json +12 -2
- package/dist/api/QField.json +3 -1
- package/dist/api/QFile.json +8 -2
- package/dist/api/QFooter.json +2 -1
- package/dist/api/QForm.json +1 -1
- package/dist/api/QHeader.json +4 -2
- package/dist/api/QIcon.json +2 -1
- package/dist/api/QImg.json +8 -4
- package/dist/api/QInfiniteScroll.json +6 -3
- package/dist/api/QInnerLoading.json +8 -4
- package/dist/api/QInput.json +3 -1
- package/dist/api/QIntersection.json +4 -2
- package/dist/api/QItem.json +33 -11
- package/dist/api/QKnob.json +8 -4
- package/dist/api/QLayout.json +9 -1
- package/dist/api/QLinearProgress.json +4 -2
- package/dist/api/QMarkupTable.json +2 -1
- package/dist/api/QMenu.json +8 -4
- package/dist/api/QNoSsr.json +2 -1
- package/dist/api/QOptionGroup.json +76 -5
- package/dist/api/QPage.json +2 -1
- package/dist/api/QPageScroller.json +8 -4
- package/dist/api/QPageSticky.json +2 -1
- package/dist/api/QPagination.json +10 -6
- package/dist/api/QParallax.json +2 -1
- package/dist/api/QPopupEdit.json +5 -2
- package/dist/api/QPopupProxy.json +7 -4
- package/dist/api/QRange.json +600 -111
- package/dist/api/QRating.json +5 -2
- package/dist/api/QResizeObserver.json +4 -1
- package/dist/api/QRouteTab.json +35 -13
- package/dist/api/QScrollArea.json +29 -6
- package/dist/api/QScrollObserver.json +13 -1
- package/dist/api/QSelect.json +76 -47
- package/dist/api/QSeparator.json +2 -1
- package/dist/api/QSkeleton.json +8 -4
- package/dist/api/QSlideItem.json +9 -0
- package/dist/api/QSlideTransition.json +2 -1
- package/dist/api/QSlider.json +512 -43
- package/dist/api/QSpinner.json +2 -1
- package/dist/api/QSplitter.json +4 -2
- package/dist/api/QStep.json +2 -1
- package/dist/api/QStepper.json +6 -3
- package/dist/api/QTab.json +4 -2
- package/dist/api/QTabPanels.json +6 -3
- package/dist/api/QTable.json +154 -88
- package/dist/api/QTabs.json +4 -2
- package/dist/api/QTime.json +16 -4
- package/dist/api/QTimeline.json +4 -2
- package/dist/api/QTimelineEntry.json +4 -2
- package/dist/api/QToggle.json +8 -4
- package/dist/api/QTooltip.json +18 -9
- package/dist/api/QTree.json +34 -19
- package/dist/api/QUploader.json +28 -6
- package/dist/api/QVirtualScroll.json +26 -11
- package/dist/api/ScrollFire.json +1 -1
- package/dist/api/TouchHold.json +2 -1
- package/dist/api/TouchRepeat.json +2 -1
- package/dist/api/TouchSwipe.json +2 -1
- package/dist/icon-set/bootstrap-icons.umd.prod.js +1 -1
- package/dist/icon-set/eva-icons.umd.prod.js +1 -1
- package/dist/icon-set/fontawesome-v5-pro.umd.prod.js +1 -1
- package/dist/icon-set/fontawesome-v5.umd.prod.js +1 -1
- package/dist/icon-set/ionicons-v4.umd.prod.js +1 -1
- package/dist/icon-set/line-awesome.umd.prod.js +1 -1
- package/dist/icon-set/material-icons-outlined.umd.prod.js +1 -1
- package/dist/icon-set/material-icons-round.umd.prod.js +1 -1
- package/dist/icon-set/material-icons-sharp.umd.prod.js +1 -1
- package/dist/icon-set/material-icons.umd.prod.js +1 -1
- package/dist/icon-set/mdi-v3.umd.prod.js +1 -1
- package/dist/icon-set/mdi-v4.umd.prod.js +1 -1
- package/dist/icon-set/mdi-v5.umd.prod.js +1 -1
- package/dist/icon-set/mdi-v6.umd.prod.js +1 -1
- package/dist/icon-set/svg-bootstrap-icons.umd.prod.js +1 -1
- package/dist/icon-set/svg-eva-icons.umd.prod.js +1 -1
- package/dist/icon-set/svg-fontawesome-v5.umd.prod.js +1 -1
- package/dist/icon-set/svg-ionicons-v4.umd.prod.js +1 -1
- package/dist/icon-set/svg-ionicons-v5.umd.prod.js +1 -1
- package/dist/icon-set/svg-ionicons-v6.umd.prod.js +1 -1
- package/dist/icon-set/svg-line-awesome.umd.prod.js +1 -1
- package/dist/icon-set/svg-material-icons-outlined.umd.prod.js +1 -1
- package/dist/icon-set/svg-material-icons-round.umd.prod.js +1 -1
- package/dist/icon-set/svg-material-icons-sharp.umd.prod.js +1 -1
- package/dist/icon-set/svg-material-icons.umd.prod.js +1 -1
- package/dist/icon-set/svg-mdi-v4.umd.prod.js +1 -1
- package/dist/icon-set/svg-mdi-v5.umd.prod.js +1 -1
- package/dist/icon-set/svg-mdi-v6.umd.prod.js +1 -1
- package/dist/icon-set/svg-themify.umd.prod.js +1 -1
- package/dist/icon-set/themify.umd.prod.js +1 -1
- package/dist/lang/ar.umd.prod.js +1 -1
- package/dist/lang/az-Latn.umd.prod.js +1 -1
- package/dist/lang/bg.umd.prod.js +1 -1
- package/dist/lang/bn.umd.prod.js +1 -1
- package/dist/lang/ca.umd.prod.js +1 -1
- package/dist/lang/cs.umd.prod.js +1 -1
- package/dist/lang/da.umd.prod.js +1 -1
- package/dist/lang/de.umd.prod.js +1 -1
- package/dist/lang/el.umd.prod.js +1 -1
- package/dist/lang/en-GB.umd.prod.js +1 -1
- package/dist/lang/en-US.umd.prod.js +1 -1
- package/dist/lang/eo.umd.prod.js +1 -1
- package/dist/lang/es.umd.prod.js +1 -1
- package/dist/lang/et.umd.prod.js +1 -1
- package/dist/lang/fa-IR.umd.prod.js +1 -1
- package/dist/lang/fa.umd.prod.js +1 -1
- package/dist/lang/fi.umd.prod.js +1 -1
- package/dist/lang/fr.umd.prod.js +1 -1
- package/dist/lang/gn.umd.prod.js +1 -1
- package/dist/lang/he.umd.prod.js +1 -1
- package/dist/lang/hr.umd.prod.js +1 -1
- package/dist/lang/hu.umd.prod.js +1 -1
- package/dist/lang/id.umd.prod.js +1 -1
- package/dist/lang/is.umd.prod.js +1 -1
- package/dist/lang/it.umd.prod.js +1 -1
- package/dist/lang/ja.umd.prod.js +1 -1
- package/dist/lang/km.umd.prod.js +1 -1
- package/dist/lang/ko-KR.umd.prod.js +1 -1
- package/dist/lang/kur-CKB.umd.prod.js +1 -1
- package/dist/lang/lt.umd.prod.js +1 -1
- package/dist/lang/lu.umd.prod.js +1 -1
- package/dist/lang/lv.umd.prod.js +1 -1
- package/dist/lang/ml.umd.prod.js +1 -1
- package/dist/lang/ms.umd.prod.js +1 -1
- package/dist/lang/nb-NO.umd.prod.js +1 -1
- package/dist/lang/nl.umd.prod.js +1 -1
- package/dist/lang/pl.umd.prod.js +1 -1
- package/dist/lang/pt-BR.umd.prod.js +1 -1
- package/dist/lang/pt.umd.prod.js +1 -1
- package/dist/lang/ro.umd.prod.js +1 -1
- package/dist/lang/ru.umd.prod.js +1 -1
- package/dist/lang/sk.umd.prod.js +1 -1
- package/dist/lang/sl.umd.prod.js +1 -1
- package/dist/lang/sr-CYR.umd.prod.js +1 -1
- package/dist/lang/sr.umd.prod.js +1 -1
- package/dist/lang/sv.umd.prod.js +1 -1
- package/dist/lang/ta.umd.prod.js +1 -1
- package/dist/lang/th.umd.prod.js +1 -1
- package/dist/lang/tr.umd.prod.js +1 -1
- package/dist/lang/ug.umd.prod.js +1 -1
- package/dist/lang/uk.umd.prod.js +1 -1
- package/dist/lang/vi.umd.prod.js +1 -1
- package/dist/lang/zh-CN.umd.prod.js +1 -1
- package/dist/lang/zh-TW.umd.prod.js +1 -1
- package/dist/quasar.cjs.prod.js +2 -2
- package/dist/quasar.css +268 -184
- package/dist/quasar.esm.prod.js +2 -2
- package/dist/quasar.prod.css +1 -1
- package/dist/quasar.rtl.css +340 -263
- package/dist/quasar.rtl.prod.css +1 -1
- package/dist/quasar.sass +272 -212
- package/dist/quasar.umd.js +16522 -16213
- package/dist/quasar.umd.prod.js +2 -2
- package/dist/ssr-directives/Morph.js +1 -1
- package/dist/transforms/loader-asset-urls.json +20 -0
- package/dist/types/api/cookies.d.ts +1 -1
- package/dist/types/api/slider.d.ts +46 -0
- package/dist/types/api/validation.d.ts +4 -0
- package/dist/types/api.d.ts +2 -0
- package/dist/types/composables.d.ts +3 -3
- package/dist/types/index.d.ts +759 -177
- package/dist/vetur/quasar-attributes.json +251 -83
- package/dist/vetur/quasar-tags.json +59 -17
- package/dist/web-types/web-types.json +587 -155
- package/package.json +1 -1
- package/src/api.extends.json +0 -1
- package/src/components/breadcrumbs/QBreadcrumbs.js +7 -2
- package/src/components/breadcrumbs/QBreadcrumbs.sass +0 -3
- package/src/components/breadcrumbs/QBreadcrumbsEl.js +14 -8
- package/src/components/btn/QBtn.js +6 -5
- package/src/components/btn/use-btn.js +21 -21
- package/src/components/btn/use-btn.json +22 -13
- package/src/components/btn-dropdown/QBtnDropdown.json +1 -0
- package/src/components/btn-toggle/QBtnToggle.json +3 -0
- package/src/components/checkbox/use-checkbox.js +1 -1
- package/src/components/chip/QChip.json +1 -2
- package/src/components/color/QColor.js +32 -26
- package/src/components/color/QColor.sass +10 -23
- package/src/components/date/QDate.json +25 -1
- package/src/components/date/QDate.sass +2 -0
- package/src/components/drawer/QDrawer.js +18 -15
- package/src/components/editor/QEditor.js +1 -1
- package/src/components/editor/QEditor.sass +10 -1
- package/src/components/expansion-item/QExpansionItem.js +4 -1
- package/src/components/expansion-item/QExpansionItem.json +2 -1
- package/src/components/fab/QFab.js +18 -12
- package/src/components/fab/QFab.json +36 -1
- package/src/components/fab/QFab.sass +1 -1
- package/src/components/fab/QFabAction.js +14 -7
- package/src/components/fab/QFabAction.json +10 -0
- package/src/components/field/QField.json +3 -3
- package/src/components/file/QFile.js +12 -5
- package/src/components/file/QFile.json +9 -6
- package/src/components/file/QFile.sass +4 -2
- package/src/components/footer/QFooter.js +1 -1
- package/src/components/form/QForm.json +2 -3
- package/src/components/header/QHeader.js +1 -1
- package/src/components/icon/QIcon.js +2 -2
- package/src/components/infinite-scroll/QInfiniteScroll.js +4 -5
- package/src/components/item/QItem.js +2 -3
- package/src/components/layout/QLayout.json +8 -1
- package/src/components/linear-progress/QLinearProgress.js +3 -2
- package/src/components/linear-progress/QLinearProgress.sass +1 -1
- package/src/components/option-group/QOptionGroup.js +3 -0
- package/src/components/option-group/QOptionGroup.json +48 -2
- package/src/components/pagination/QPagination.json +0 -1
- package/src/components/parallax/QParallax.js +4 -2
- package/src/components/popup-edit/QPopupEdit.js +2 -5
- package/src/components/popup-edit/QPopupEdit.json +1 -0
- package/src/components/popup-proxy/QPopupProxy.json +2 -1
- package/src/components/radio/QRadio.js +2 -7
- package/src/components/range/QRange.js +103 -222
- package/src/components/range/QRange.json +11 -121
- package/src/components/rating/QRating.json +1 -1
- package/src/components/resize-observer/QResizeObserver.json +2 -0
- package/src/components/scroll-area/QScrollArea.js +10 -13
- package/src/components/scroll-area/QScrollArea.json +29 -9
- package/src/components/scroll-observer/QScrollObserver.json +11 -0
- package/src/components/select/QSelect.json +41 -15
- package/src/components/slide-item/QSlideItem.json +9 -0
- package/src/components/slider/QSlider.js +46 -132
- package/src/components/slider/QSlider.json +1 -121
- package/src/components/slider/QSlider.sass +198 -132
- package/src/components/slider/use-slider.js +453 -109
- package/src/components/slider/use-slider.json +546 -0
- package/src/components/stepper/QStepper.js +3 -3
- package/src/components/stepper/QStepper.sass +24 -26
- package/src/components/table/QTable.js +27 -47
- package/src/components/table/QTable.json +104 -55
- package/src/components/table/table-pagination.js +4 -0
- package/src/components/tabs/QRouteTab.js +1 -2
- package/src/components/tabs/QRouteTab.json +0 -7
- package/src/components/tabs/QTabs.js +71 -20
- package/src/components/tabs/use-tab.js +26 -13
- package/src/components/time/QTime.json +8 -0
- package/src/components/tree/QTree.js +14 -12
- package/src/components/tree/QTree.json +26 -21
- package/src/components/tree/QTree.sass +45 -41
- package/src/components/uploader/QUploader.json +14 -2
- package/src/components/uploader/uploader-core.js +16 -9
- package/src/components/uploader/xhr-uploader-plugin.json +8 -3
- package/src/components/virtual-scroll/QVirtualScroll.json +15 -0
- package/src/components/virtual-scroll/QVirtualScroll.sass +1 -0
- package/src/components/virtual-scroll/use-virtual-scroll.js +30 -17
- package/src/components/virtual-scroll/use-virtual-scroll.json +7 -5
- package/src/composables/private/use-field.js +5 -5
- package/src/composables/private/use-file.js +20 -5
- package/src/composables/private/use-form.js +2 -3
- package/src/composables/private/use-fullscreen.js +15 -4
- package/src/composables/private/use-router-link.js +44 -23
- package/src/composables/private/use-router-link.json +26 -10
- package/src/composables/private/use-split-attrs.js +7 -10
- package/src/composables/private/use-validate.js +21 -15
- package/src/composables/private/use-validate.json +1 -0
- package/src/css/core/helpers.sass +3 -0
- package/src/css/core/positioning.sass +5 -0
- package/src/directives/Mutation.json +2 -3
- package/src/directives/ScrollFire.js +1 -0
- package/src/directives/ScrollFire.json +2 -3
- package/src/icon-set.js +2 -4
- package/src/plugins/AppFullscreen.js +70 -53
- package/src/plugins/AppFullscreen.json +8 -8
- package/src/plugins/AppVisibility.js +2 -3
- package/src/plugins/BottomSheet.js +3 -5
- package/src/plugins/Cookies.json +2 -2
- package/src/plugins/Dialog.js +3 -5
- package/src/plugins/Dialog.json +6 -5
- package/src/plugins/LoadingBar.js +17 -18
- package/src/plugins/LoadingBar.json +4 -3
- package/src/plugins/Notify.js +296 -295
- package/src/plugins/Notify.json +13 -19
- package/src/plugins/Platform.js +14 -14
- package/src/utils/date.js +4 -4
- package/src/utils/dom.js +2 -2
- package/src/utils/open-url.js +2 -2
- package/src/utils/patterns.js +1 -0
- package/src/utils/private/define-reactive-plugin.js +10 -8
- package/src/utils/private/global-dialog.js +6 -8
- package/src/utils/private/global-dialog.json +6 -0
- package/src/utils/private/inject-obj-prop.js +13 -0
- package/src/utils/private/is.js +2 -2
package/package.json
CHANGED
package/src/api.extends.json
CHANGED
|
@@ -6,6 +6,8 @@ import { createComponent } from '../../utils/private/create.js'
|
|
|
6
6
|
import { hSlot } from '../../utils/private/render.js'
|
|
7
7
|
import { getNormalizedVNodes } from '../../utils/private/vm.js'
|
|
8
8
|
|
|
9
|
+
const disabledValues = [ void 0, true ]
|
|
10
|
+
|
|
9
11
|
export default createComponent({
|
|
10
12
|
name: 'QBreadcrumbs',
|
|
11
13
|
|
|
@@ -59,12 +61,15 @@ export default createComponent({
|
|
|
59
61
|
vnodes.forEach(comp => {
|
|
60
62
|
if (comp.type !== void 0 && comp.type.name === 'QBreadcrumbsEl') {
|
|
61
63
|
const middle = els < len
|
|
64
|
+
const disabled = comp.props !== null && disabledValues.includes(comp.props.disable)
|
|
65
|
+
const cls = (middle === true ? ' q-breadcrumbs--last' : '')
|
|
66
|
+
+ (disabled !== true && middle === true ? ' ' + activeClass.value : '')
|
|
67
|
+
|
|
62
68
|
els++
|
|
63
69
|
|
|
64
70
|
child.push(
|
|
65
71
|
h('div', {
|
|
66
|
-
class:
|
|
67
|
-
+ (middle === true ? activeClass.value : 'q-breadcrumbs--last')
|
|
72
|
+
class: `flex items-center${ cls }`
|
|
68
73
|
}, [ comp ])
|
|
69
74
|
)
|
|
70
75
|
|
|
@@ -22,12 +22,17 @@ export default createComponent({
|
|
|
22
22
|
},
|
|
23
23
|
|
|
24
24
|
setup (props, { slots }) {
|
|
25
|
-
const { linkTag, linkProps,
|
|
25
|
+
const { linkTag, linkProps, hasRouterLink, navigateToRouterLink } = useRouterLink()
|
|
26
26
|
|
|
27
27
|
const data = computed(() => {
|
|
28
|
-
const acc = {
|
|
29
|
-
|
|
30
|
-
|
|
28
|
+
const acc = {
|
|
29
|
+
class: 'q-breadcrumbs__el q-link '
|
|
30
|
+
+ 'flex inline items-center relative-position '
|
|
31
|
+
+ (props.disable !== true ? 'q-link--focusable' : 'q-breadcrumbs__el--disable'),
|
|
32
|
+
...linkProps.value
|
|
33
|
+
}
|
|
34
|
+
if (hasRouterLink.value === true) {
|
|
35
|
+
acc.onClick = navigateToRouterLink
|
|
31
36
|
}
|
|
32
37
|
return acc
|
|
33
38
|
})
|
|
@@ -49,10 +54,11 @@ export default createComponent({
|
|
|
49
54
|
|
|
50
55
|
props.label !== void 0 && child.push(props.label)
|
|
51
56
|
|
|
52
|
-
return h(
|
|
53
|
-
|
|
54
|
-
...data.value
|
|
55
|
-
|
|
57
|
+
return h(
|
|
58
|
+
linkTag.value,
|
|
59
|
+
{ ...data.value },
|
|
60
|
+
hMergeSlot(slots.default, child)
|
|
61
|
+
)
|
|
56
62
|
}
|
|
57
63
|
}
|
|
58
64
|
})
|
|
@@ -37,7 +37,7 @@ export default createComponent({
|
|
|
37
37
|
const {
|
|
38
38
|
classes, style, innerClasses,
|
|
39
39
|
attributes,
|
|
40
|
-
hasLink,
|
|
40
|
+
hasRouterLink, hasLink, linkTag, navigateToRouterLink,
|
|
41
41
|
isActionable
|
|
42
42
|
} = useBtn(props)
|
|
43
43
|
|
|
@@ -54,7 +54,7 @@ export default createComponent({
|
|
|
54
54
|
props.disable === true || props.ripple === false
|
|
55
55
|
? false
|
|
56
56
|
: {
|
|
57
|
-
keyCodes:
|
|
57
|
+
keyCodes: hasLink.value === true ? [ 13, 32 ] : [ 13 ],
|
|
58
58
|
...(props.ripple === true ? {} : props.ripple)
|
|
59
59
|
}
|
|
60
60
|
))
|
|
@@ -135,10 +135,10 @@ export default createComponent({
|
|
|
135
135
|
}
|
|
136
136
|
}
|
|
137
137
|
|
|
138
|
-
if (
|
|
138
|
+
if (hasRouterLink.value === true) {
|
|
139
139
|
const go = () => {
|
|
140
140
|
e.__qNavigate = true
|
|
141
|
-
|
|
141
|
+
navigateToRouterLink(e)
|
|
142
142
|
}
|
|
143
143
|
|
|
144
144
|
emit('click', e, go)
|
|
@@ -277,6 +277,7 @@ export default createComponent({
|
|
|
277
277
|
}
|
|
278
278
|
|
|
279
279
|
function onLoadingEvt (evt) {
|
|
280
|
+
stopAndPrevent(evt)
|
|
280
281
|
evt.qSkipRipple = true
|
|
281
282
|
}
|
|
282
283
|
|
|
@@ -359,7 +360,7 @@ export default createComponent({
|
|
|
359
360
|
|
|
360
361
|
return withDirectives(
|
|
361
362
|
h(
|
|
362
|
-
|
|
363
|
+
linkTag.value,
|
|
363
364
|
nodeProps.value,
|
|
364
365
|
child
|
|
365
366
|
),
|
|
@@ -21,6 +21,9 @@ const defaultSizes = {
|
|
|
21
21
|
xl: 24
|
|
22
22
|
}
|
|
23
23
|
|
|
24
|
+
const formTypes = [ 'submit', 'reset' ]
|
|
25
|
+
const mediaTypeRE = /[^\s]\/[^\s]/
|
|
26
|
+
|
|
24
27
|
export const useBtnProps = {
|
|
25
28
|
...useSizeProps,
|
|
26
29
|
...useRouterLinkProps,
|
|
@@ -76,7 +79,7 @@ export const useBtnProps = {
|
|
|
76
79
|
export default function (props) {
|
|
77
80
|
const sizeStyle = useSize(props, defaultSizes)
|
|
78
81
|
const alignClass = useAlign(props)
|
|
79
|
-
const { hasLink, linkProps,
|
|
82
|
+
const { hasRouterLink, hasLink, linkTag, linkProps, navigateToRouterLink } = useRouterLink('button')
|
|
80
83
|
|
|
81
84
|
const style = computed(() => {
|
|
82
85
|
const obj = props.fab === false && props.fabMini === false
|
|
@@ -107,10 +110,6 @@ export default function (props) {
|
|
|
107
110
|
isActionable.value === true ? props.tabindex || 0 : -1
|
|
108
111
|
))
|
|
109
112
|
|
|
110
|
-
const isLink = computed(() =>
|
|
111
|
-
props.type === 'a' || hasLink.value === true
|
|
112
|
-
)
|
|
113
|
-
|
|
114
113
|
const design = computed(() => {
|
|
115
114
|
if (props.flat === true) return 'flat'
|
|
116
115
|
if (props.outline === true) return 'outline'
|
|
@@ -122,19 +121,24 @@ export default function (props) {
|
|
|
122
121
|
const attributes = computed(() => {
|
|
123
122
|
const acc = { tabindex: tabIndex.value }
|
|
124
123
|
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
if (
|
|
124
|
+
if (hasLink.value === true) {
|
|
125
|
+
Object.assign(acc, linkProps.value)
|
|
126
|
+
}
|
|
127
|
+
else if (formTypes.includes(props.type) === true) {
|
|
129
128
|
acc.type = props.type
|
|
130
129
|
}
|
|
131
130
|
|
|
132
|
-
if (
|
|
133
|
-
|
|
134
|
-
|
|
131
|
+
if (linkTag.value === 'a') {
|
|
132
|
+
if (acc.href === void 0) {
|
|
133
|
+
acc.role = 'button'
|
|
134
|
+
}
|
|
135
|
+
if (hasRouterLink.value !== true && mediaTypeRE.test(props.type) === true) {
|
|
136
|
+
acc.type = props.type
|
|
137
|
+
}
|
|
135
138
|
}
|
|
136
|
-
else {
|
|
137
|
-
acc.
|
|
139
|
+
else if (props.disable === true) {
|
|
140
|
+
acc.disabled = ''
|
|
141
|
+
acc[ 'aria-disabled' ] = 'true'
|
|
138
142
|
}
|
|
139
143
|
|
|
140
144
|
if (props.loading === true && props.percentage !== void 0) {
|
|
@@ -146,11 +150,6 @@ export default function (props) {
|
|
|
146
150
|
})
|
|
147
151
|
}
|
|
148
152
|
|
|
149
|
-
if (props.disable === true) {
|
|
150
|
-
acc.disabled = ''
|
|
151
|
-
acc[ 'aria-disabled' ] = 'true'
|
|
152
|
-
}
|
|
153
|
-
|
|
154
153
|
return acc
|
|
155
154
|
})
|
|
156
155
|
|
|
@@ -191,9 +190,10 @@ export default function (props) {
|
|
|
191
190
|
style,
|
|
192
191
|
innerClasses,
|
|
193
192
|
attributes,
|
|
193
|
+
hasRouterLink,
|
|
194
194
|
hasLink,
|
|
195
|
-
|
|
196
|
-
|
|
195
|
+
linkTag,
|
|
196
|
+
navigateToRouterLink,
|
|
197
197
|
isActionable
|
|
198
198
|
}
|
|
199
199
|
}
|
|
@@ -4,37 +4,46 @@
|
|
|
4
4
|
"props": {
|
|
5
5
|
"type":{
|
|
6
6
|
"type": "String",
|
|
7
|
-
"desc": "Define the button
|
|
7
|
+
"desc": "1) Define the button native type attribute (submit, reset, button) or 2) render component with <a> tag so you can access events even if disable or 3) Use 'href' prop and specify 'type' as a media tag",
|
|
8
8
|
"default": "button",
|
|
9
|
-
"values": [
|
|
10
|
-
"a", "submit", "button", "reset"
|
|
11
|
-
],
|
|
12
9
|
"examples": [
|
|
13
|
-
"
|
|
10
|
+
"a", "submit", "button", "reset",
|
|
11
|
+
"image/png",
|
|
12
|
+
"href=\"https://quasar.dev\" target=\"_blank\""
|
|
14
13
|
],
|
|
15
14
|
"category": "general"
|
|
16
15
|
},
|
|
17
16
|
|
|
18
17
|
"to": {
|
|
19
18
|
"type": [ "String", "Object" ],
|
|
20
|
-
"desc": "Equivalent to Vue Router <router-link> 'to' property",
|
|
19
|
+
"desc": "Equivalent to Vue Router <router-link> 'to' property; Superseeded by 'href' prop if used",
|
|
21
20
|
"examples": [
|
|
22
21
|
"/home/dashboard",
|
|
23
22
|
":to=\"{ name: 'my-route-name' }\""
|
|
24
23
|
],
|
|
25
|
-
"category": "
|
|
24
|
+
"category": "navigation"
|
|
26
25
|
},
|
|
27
26
|
|
|
28
27
|
"replace": {
|
|
29
28
|
"type": "Boolean",
|
|
30
|
-
"desc": "Equivalent to Vue Router <router-link> 'replace' property",
|
|
31
|
-
"category": "
|
|
29
|
+
"desc": "Equivalent to Vue Router <router-link> 'replace' property; Superseeded by 'href' prop if used",
|
|
30
|
+
"category": "navigation"
|
|
32
31
|
},
|
|
33
32
|
|
|
34
|
-
"
|
|
35
|
-
"type": "
|
|
36
|
-
"desc": "
|
|
37
|
-
"
|
|
33
|
+
"href": {
|
|
34
|
+
"type": "String",
|
|
35
|
+
"desc": "Native <a> link href attribute; Has priority over the 'to' and 'replace' props",
|
|
36
|
+
"examples": [ "http://quasar.dev", "href=\"https://quasar.dev\" target=\"_blank\"" ],
|
|
37
|
+
"category": "navigation",
|
|
38
|
+
"addedIn": "v2.4"
|
|
39
|
+
},
|
|
40
|
+
|
|
41
|
+
"target": {
|
|
42
|
+
"type": "String",
|
|
43
|
+
"desc": "Native <a> link target attribute; Use it only with 'to' or 'href' props",
|
|
44
|
+
"examples": [ "_blank", "_self", "_parent", "_top" ],
|
|
45
|
+
"category": "navigation",
|
|
46
|
+
"addedIn": "v2.4"
|
|
38
47
|
},
|
|
39
48
|
|
|
40
49
|
"label":{
|
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
"extends": "model-value",
|
|
11
11
|
"type": "Boolean",
|
|
12
12
|
"desc": "Controls Menu show/hidden state; Either use this property (along with a listener for 'update:modelValue' event) OR use v-model directive",
|
|
13
|
+
"required": false,
|
|
13
14
|
"examples": [ "v-model=\"menuState\"" ]
|
|
14
15
|
},
|
|
15
16
|
|
|
@@ -107,7 +107,7 @@ export default function (type, getInner) {
|
|
|
107
107
|
const prop = { type: 'checkbox' }
|
|
108
108
|
|
|
109
109
|
props.name !== void 0 && Object.assign(prop, {
|
|
110
|
-
checked: isTrue.value,
|
|
110
|
+
'^checked': isTrue.value === true ? 'checked' : void 0,
|
|
111
111
|
name: props.name,
|
|
112
112
|
value: modelIsArray.value === true
|
|
113
113
|
? props.val
|
|
@@ -35,6 +35,7 @@ const palette = [
|
|
|
35
35
|
]
|
|
36
36
|
|
|
37
37
|
const thumbPath = 'M5 5 h10 v10 h-10 v-10 z'
|
|
38
|
+
const alphaTrackImg = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAYAAADED76LAAAAH0lEQVQoU2NkYGAwZkAFZ5G5jPRRgOYEVDeB3EBjBQBOZwTVugIGyAAAAABJRU5ErkJggg=='
|
|
38
39
|
|
|
39
40
|
export default createComponent({
|
|
40
41
|
name: 'QColor',
|
|
@@ -653,37 +654,42 @@ export default createComponent({
|
|
|
653
654
|
]
|
|
654
655
|
|
|
655
656
|
const sliders = [
|
|
656
|
-
h(
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
657
|
+
h(QSlider, {
|
|
658
|
+
class: 'q-color-picker__hue non-selectable',
|
|
659
|
+
modelValue: model.value.h,
|
|
660
|
+
min: 0,
|
|
661
|
+
max: 360,
|
|
662
|
+
trackSize: '8px',
|
|
663
|
+
innerTrackColor: 'transparent',
|
|
664
|
+
selectionColor: 'transparent',
|
|
665
|
+
readonly: editable.value !== true,
|
|
666
|
+
thumbPath,
|
|
667
|
+
'onUpdate:modelValue': onHueChange,
|
|
668
|
+
...getCache('lazyhue', {
|
|
669
|
+
onChange: val => onHueChange(val, true)
|
|
668
670
|
})
|
|
669
|
-
|
|
671
|
+
})
|
|
670
672
|
]
|
|
671
673
|
|
|
672
674
|
hasAlpha.value === true && sliders.push(
|
|
673
|
-
h(
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
675
|
+
h(QSlider, {
|
|
676
|
+
class: 'q-color-picker__alpha non-selectable',
|
|
677
|
+
modelValue: model.value.a,
|
|
678
|
+
min: 0,
|
|
679
|
+
max: 100,
|
|
680
|
+
trackSize: '8px',
|
|
681
|
+
trackColor: 'white',
|
|
682
|
+
innerTrackColor: 'transparent',
|
|
683
|
+
selectionColor: 'transparent',
|
|
684
|
+
trackImg: alphaTrackImg,
|
|
685
|
+
readonly: editable.value !== true,
|
|
686
|
+
hideSelection: true,
|
|
687
|
+
thumbPath,
|
|
688
|
+
...getCache('alphaSlide', {
|
|
689
|
+
'onUpdate:modelValue': value => onNumericChange(value, 'a', 100),
|
|
690
|
+
onChange: value => onNumericChange(value, 'a', 100, void 0, true)
|
|
685
691
|
})
|
|
686
|
-
|
|
692
|
+
})
|
|
687
693
|
)
|
|
688
694
|
|
|
689
695
|
return [
|
|
@@ -97,47 +97,34 @@
|
|
|
97
97
|
border-radius: 50%
|
|
98
98
|
transform: translate(-5px, -5px)
|
|
99
99
|
|
|
100
|
-
&__hue .q-slider__track
|
|
100
|
+
&__hue .q-slider__track
|
|
101
101
|
background: linear-gradient(to right, #f00 0%, #ff0 17%, #0f0 33%, #0ff 50%, #00f 67%, #f0f 83%, #f00 100%) !important // @stylint ignore
|
|
102
102
|
opacity: 1
|
|
103
103
|
|
|
104
|
-
&__alpha
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
background-color: #fff !important
|
|
109
|
-
background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAYAAADED76LAAAAH0lEQVQoU2NkYGAwZkAFZ5G5jPRRgOYEVDeB3EBjBQBOZwTVugIGyAAAAABJRU5ErkJggg==') !important
|
|
110
|
-
&:after
|
|
104
|
+
&__alpha
|
|
105
|
+
.q-slider__track-container
|
|
106
|
+
padding-top: 0
|
|
107
|
+
.q-slider__track:before
|
|
111
108
|
content: ''
|
|
112
109
|
position: absolute
|
|
113
110
|
top: 0
|
|
114
111
|
right: 0
|
|
115
112
|
bottom: 0
|
|
116
113
|
left: 0
|
|
114
|
+
border-radius: inherit
|
|
117
115
|
background: linear-gradient(90deg, rgba(255,255,255,0), $grey-7)
|
|
118
116
|
|
|
119
117
|
&__sliders
|
|
120
|
-
padding:
|
|
121
|
-
|
|
122
|
-
.q-slider__track-container
|
|
123
|
-
height: 10px
|
|
124
|
-
margin-top: -5px
|
|
125
|
-
|
|
126
|
-
.q-slider__track
|
|
127
|
-
display: none
|
|
118
|
+
padding: 0 16px
|
|
128
119
|
|
|
129
120
|
.q-slider__thumb
|
|
121
|
+
color: $grey-9
|
|
130
122
|
path
|
|
131
123
|
stroke-width: 2px
|
|
132
124
|
fill: transparent
|
|
133
125
|
.q-slider--active path
|
|
134
126
|
stroke-width: 3px
|
|
135
127
|
|
|
136
|
-
.q-slider
|
|
137
|
-
height: 16px
|
|
138
|
-
margin-top: 8px
|
|
139
|
-
color: $grey-9
|
|
140
|
-
|
|
141
128
|
/* Tune Tab */
|
|
142
129
|
|
|
143
130
|
&__tune-tab
|
|
@@ -188,5 +175,5 @@
|
|
|
188
175
|
.q-color-picker__tune-tab input
|
|
189
176
|
border: 1px solid rgba(#fff, .3)
|
|
190
177
|
|
|
191
|
-
.q-
|
|
192
|
-
color: $grey-
|
|
178
|
+
.q-slider__thumb
|
|
179
|
+
color: $grey-1
|
|
@@ -209,35 +209,42 @@
|
|
|
209
209
|
"definition": {
|
|
210
210
|
"year": {
|
|
211
211
|
"type": "Number",
|
|
212
|
+
"required": true,
|
|
212
213
|
"desc": "The year of the date that the user has clicked/tapped on",
|
|
213
214
|
"__exemption": [ "examples" ]
|
|
214
215
|
},
|
|
215
216
|
"month": {
|
|
216
217
|
"type": "Number",
|
|
218
|
+
"required": true,
|
|
217
219
|
"desc": "The month of the date that the user has clicked/tapped on",
|
|
218
220
|
"__exemption": [ "examples" ]
|
|
219
221
|
},
|
|
220
222
|
"day": {
|
|
221
223
|
"type": "Number",
|
|
224
|
+
"required": true,
|
|
222
225
|
"desc": "The day of the month that the user has clicked/tapped on",
|
|
223
226
|
"__exemption": [ "examples" ]
|
|
224
227
|
},
|
|
225
228
|
"from": {
|
|
226
229
|
"type": "Object",
|
|
230
|
+
"required": false,
|
|
227
231
|
"desc": "Object of properties of the range starting point (only if range)",
|
|
228
232
|
"definition": {
|
|
229
233
|
"year": {
|
|
230
234
|
"type": "Number",
|
|
235
|
+
"required": true,
|
|
231
236
|
"desc": "The year",
|
|
232
237
|
"__exemption": [ "examples" ]
|
|
233
238
|
},
|
|
234
239
|
"month": {
|
|
235
240
|
"type": "Number",
|
|
241
|
+
"required": true,
|
|
236
242
|
"desc": "The month",
|
|
237
243
|
"__exemption": [ "examples" ]
|
|
238
244
|
},
|
|
239
245
|
"day": {
|
|
240
246
|
"type": "Number",
|
|
247
|
+
"required": true,
|
|
241
248
|
"desc": "The day of month",
|
|
242
249
|
"__exemption": [ "examples" ]
|
|
243
250
|
}
|
|
@@ -245,20 +252,24 @@
|
|
|
245
252
|
},
|
|
246
253
|
"to": {
|
|
247
254
|
"type": "Object",
|
|
255
|
+
"required": false,
|
|
248
256
|
"desc": "Object of properties of the range ending point (only if range)",
|
|
249
257
|
"definition": {
|
|
250
258
|
"year": {
|
|
251
259
|
"type": "Number",
|
|
260
|
+
"required": true,
|
|
252
261
|
"desc": "The year",
|
|
253
262
|
"__exemption": [ "examples" ]
|
|
254
263
|
},
|
|
255
264
|
"month": {
|
|
256
265
|
"type": "Number",
|
|
266
|
+
"required": true,
|
|
257
267
|
"desc": "The month",
|
|
258
268
|
"__exemption": [ "examples" ]
|
|
259
269
|
},
|
|
260
270
|
"day": {
|
|
261
271
|
"type": "Number",
|
|
272
|
+
"required": true,
|
|
262
273
|
"desc": "The day of month",
|
|
263
274
|
"__exemption": [ "examples" ]
|
|
264
275
|
}
|
|
@@ -278,11 +289,13 @@
|
|
|
278
289
|
"definition": {
|
|
279
290
|
"year": {
|
|
280
291
|
"type": "Number",
|
|
292
|
+
"required": true,
|
|
281
293
|
"desc": "The year",
|
|
282
294
|
"__exemption": [ "examples" ]
|
|
283
295
|
},
|
|
284
296
|
"month": {
|
|
285
297
|
"type": "Number",
|
|
298
|
+
"required": true,
|
|
286
299
|
"desc": "The month",
|
|
287
300
|
"__exemption": [ "examples" ]
|
|
288
301
|
}
|
|
@@ -300,16 +313,19 @@
|
|
|
300
313
|
"definition": {
|
|
301
314
|
"year": {
|
|
302
315
|
"type": "Number",
|
|
316
|
+
"required": true,
|
|
303
317
|
"desc": "The year",
|
|
304
318
|
"__exemption": [ "examples" ]
|
|
305
319
|
},
|
|
306
320
|
"month": {
|
|
307
321
|
"type": "Number",
|
|
322
|
+
"required": true,
|
|
308
323
|
"desc": "The month",
|
|
309
324
|
"__exemption": [ "examples" ]
|
|
310
325
|
},
|
|
311
326
|
"day": {
|
|
312
327
|
"type": "Number",
|
|
328
|
+
"required": true,
|
|
313
329
|
"desc": "The day of month",
|
|
314
330
|
"__exemption": [ "examples" ]
|
|
315
331
|
}
|
|
@@ -327,20 +343,24 @@
|
|
|
327
343
|
"definition": {
|
|
328
344
|
"from": {
|
|
329
345
|
"type": "Object",
|
|
346
|
+
"required": true,
|
|
330
347
|
"desc": "Definition of date from where the range begins",
|
|
331
348
|
"definition": {
|
|
332
349
|
"year": {
|
|
333
350
|
"type": "Number",
|
|
351
|
+
"required": true,
|
|
334
352
|
"desc": "The year",
|
|
335
353
|
"__exemption": [ "examples" ]
|
|
336
354
|
},
|
|
337
355
|
"month": {
|
|
338
356
|
"type": "Number",
|
|
357
|
+
"required": true,
|
|
339
358
|
"desc": "The month",
|
|
340
359
|
"__exemption": [ "examples" ]
|
|
341
360
|
},
|
|
342
361
|
"day": {
|
|
343
362
|
"type": "Number",
|
|
363
|
+
"required": true,
|
|
344
364
|
"desc": "The day of month",
|
|
345
365
|
"__exemption": [ "examples" ]
|
|
346
366
|
}
|
|
@@ -348,20 +368,24 @@
|
|
|
348
368
|
},
|
|
349
369
|
"to": {
|
|
350
370
|
"type": "Object",
|
|
371
|
+
"required": true,
|
|
351
372
|
"desc": "Definition of date to where the range ends",
|
|
352
373
|
"definition": {
|
|
353
374
|
"year": {
|
|
354
375
|
"type": "Number",
|
|
376
|
+
"required": true,
|
|
355
377
|
"desc": "The year",
|
|
356
378
|
"__exemption": [ "examples" ]
|
|
357
379
|
},
|
|
358
380
|
"month": {
|
|
359
381
|
"type": "Number",
|
|
382
|
+
"required": true,
|
|
360
383
|
"desc": "The month",
|
|
361
384
|
"__exemption": [ "examples" ]
|
|
362
385
|
},
|
|
363
386
|
"day": {
|
|
364
387
|
"type": "Number",
|
|
388
|
+
"required": true,
|
|
365
389
|
"desc": "The day of month",
|
|
366
390
|
"__exemption": [ "examples" ]
|
|
367
391
|
}
|
|
@@ -383,8 +407,8 @@
|
|
|
383
407
|
"params": {
|
|
384
408
|
"view": {
|
|
385
409
|
"type": "String",
|
|
386
|
-
"desc": "QDate view name",
|
|
387
410
|
"required": true,
|
|
411
|
+
"desc": "QDate view name",
|
|
388
412
|
"values": [ "Calendar", "Months", "Years" ]
|
|
389
413
|
}
|
|
390
414
|
}
|