quasar 2.2.4 → 2.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api/QCircularProgress.json +14 -0
- package/dist/api/QLinearProgress.json +14 -0
- package/dist/api/QSkeleton.json +1 -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-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 +2 -1
- package/dist/quasar.esm.prod.js +2 -2
- package/dist/quasar.prod.css +1 -1
- package/dist/quasar.rtl.css +2 -1
- package/dist/quasar.rtl.prod.css +1 -1
- package/dist/quasar.sass +3 -2
- package/dist/quasar.umd.js +119 -64
- package/dist/quasar.umd.prod.js +2 -2
- package/dist/ssr-directives/Morph.js +1 -1
- package/dist/types/index.d.ts +10 -0
- package/dist/vetur/quasar-attributes.json +8 -0
- package/dist/vetur/quasar-tags.json +4 -2
- package/dist/web-types/web-types.json +21 -1
- package/package.json +1 -1
- package/src/api.extends.json +7 -0
- package/src/components/circular-progress/QCircularProgress.js +6 -1
- package/src/components/circular-progress/QCircularProgress.json +6 -0
- package/src/components/infinite-scroll/QInfiniteScroll.js +48 -31
- package/src/components/linear-progress/QLinearProgress.js +10 -1
- package/src/components/linear-progress/QLinearProgress.json +6 -0
- package/src/components/linear-progress/QLinearProgress.sass +2 -1
- package/src/components/popup-proxy/QPopupProxy.js +6 -15
- package/src/components/skeleton/QSkeleton.json +1 -4
- package/src/components/table/table-pagination.js +2 -2
- package/src/components/virtual-scroll/use-virtual-scroll.js +17 -1
- package/src/composables/use-dialog-plugin-component.js +6 -1
- package/src/utils/create-uploader-component.js +6 -4
- package/src/utils/private/get-emits-object.js +11 -0
- package/src/utils/private/vm.js +3 -3
package/dist/types/index.d.ts
CHANGED
|
@@ -2699,6 +2699,11 @@ export interface QCircularProgressProps {
|
|
|
2699
2699
|
* No animation when model changes
|
|
2700
2700
|
*/
|
|
2701
2701
|
instantFeedback?: boolean | undefined;
|
|
2702
|
+
/**
|
|
2703
|
+
* Animation speed (in milliseconds, without unit)
|
|
2704
|
+
* Default value: 600
|
|
2705
|
+
*/
|
|
2706
|
+
animationSpeed?: string | number | undefined;
|
|
2702
2707
|
}
|
|
2703
2708
|
|
|
2704
2709
|
export interface QCircularProgressSlots {
|
|
@@ -5932,6 +5937,11 @@ export interface QLinearProgressProps {
|
|
|
5932
5937
|
* No transition when model changes
|
|
5933
5938
|
*/
|
|
5934
5939
|
instantFeedback?: boolean | undefined;
|
|
5940
|
+
/**
|
|
5941
|
+
* Animation speed (in milliseconds, without unit)
|
|
5942
|
+
* Default value: 300
|
|
5943
|
+
*/
|
|
5944
|
+
animationSpeed?: string | number | undefined;
|
|
5935
5945
|
}
|
|
5936
5946
|
|
|
5937
5947
|
export interface QLinearProgressSlots {
|
|
@@ -1027,6 +1027,10 @@
|
|
|
1027
1027
|
"type": "boolean",
|
|
1028
1028
|
"description": "No animation when model changes"
|
|
1029
1029
|
},
|
|
1030
|
+
"q-circular-progress/animation-speed": {
|
|
1031
|
+
"type": "string|number",
|
|
1032
|
+
"description": "Animation speed (in milliseconds, without unit)"
|
|
1033
|
+
},
|
|
1030
1034
|
"q-color/name": {
|
|
1031
1035
|
"type": "string",
|
|
1032
1036
|
"description": "Used to specify the name of the control; Useful if dealing with forms submitted directly to a URL"
|
|
@@ -2819,6 +2823,10 @@
|
|
|
2819
2823
|
"type": "boolean",
|
|
2820
2824
|
"description": "No transition when model changes"
|
|
2821
2825
|
},
|
|
2826
|
+
"q-linear-progress/animation-speed": {
|
|
2827
|
+
"type": "string|number",
|
|
2828
|
+
"description": "Animation speed (in milliseconds, without unit)"
|
|
2829
|
+
},
|
|
2822
2830
|
"q-markup-table/dense": {
|
|
2823
2831
|
"type": "boolean",
|
|
2824
2832
|
"description": "Dense mode; occupies less space"
|
|
@@ -357,7 +357,8 @@
|
|
|
357
357
|
"indeterminate",
|
|
358
358
|
"show-value",
|
|
359
359
|
"reverse",
|
|
360
|
-
"instant-feedback"
|
|
360
|
+
"instant-feedback",
|
|
361
|
+
"animation-speed"
|
|
361
362
|
],
|
|
362
363
|
"description": ""
|
|
363
364
|
},
|
|
@@ -939,7 +940,8 @@
|
|
|
939
940
|
"indeterminate",
|
|
940
941
|
"query",
|
|
941
942
|
"rounded",
|
|
942
|
-
"instant-feedback"
|
|
943
|
+
"instant-feedback",
|
|
944
|
+
"animation-speed"
|
|
943
945
|
],
|
|
944
946
|
"description": ""
|
|
945
947
|
},
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"$schema": "",
|
|
3
3
|
"framework": "vue",
|
|
4
4
|
"name": "quasar",
|
|
5
|
-
"version": "2.
|
|
5
|
+
"version": "2.3.0",
|
|
6
6
|
"contributions": {
|
|
7
7
|
"html": {
|
|
8
8
|
"types-syntax": "typescript",
|
|
@@ -3155,6 +3155,16 @@
|
|
|
3155
3155
|
"description": "No animation when model changes",
|
|
3156
3156
|
"doc-url": "https://v2.quasar.dev/vue-components/circular-progress",
|
|
3157
3157
|
"type": "boolean"
|
|
3158
|
+
},
|
|
3159
|
+
{
|
|
3160
|
+
"name": "animation-speed",
|
|
3161
|
+
"value": {
|
|
3162
|
+
"kind": "expression",
|
|
3163
|
+
"type": "string|number"
|
|
3164
|
+
},
|
|
3165
|
+
"description": "Animation speed (in milliseconds, without unit)\n\nExamples:\n500\n1200",
|
|
3166
|
+
"doc-url": "https://v2.quasar.dev/vue-components/circular-progress",
|
|
3167
|
+
"default": "600"
|
|
3158
3168
|
}
|
|
3159
3169
|
],
|
|
3160
3170
|
"slots": [
|
|
@@ -8952,6 +8962,16 @@
|
|
|
8952
8962
|
"description": "No transition when model changes",
|
|
8953
8963
|
"doc-url": "https://v2.quasar.dev/vue-components/linear-progress",
|
|
8954
8964
|
"type": "boolean"
|
|
8965
|
+
},
|
|
8966
|
+
{
|
|
8967
|
+
"name": "animation-speed",
|
|
8968
|
+
"value": {
|
|
8969
|
+
"kind": "expression",
|
|
8970
|
+
"type": "string|number"
|
|
8971
|
+
},
|
|
8972
|
+
"description": "Animation speed (in milliseconds, without unit)\n\nExamples:\n500\n1200",
|
|
8973
|
+
"doc-url": "https://v2.quasar.dev/vue-components/linear-progress",
|
|
8974
|
+
"default": "300"
|
|
8955
8975
|
}
|
|
8956
8976
|
],
|
|
8957
8977
|
"slots": [
|
package/package.json
CHANGED
package/src/api.extends.json
CHANGED
|
@@ -95,6 +95,13 @@
|
|
|
95
95
|
"category": "transition"
|
|
96
96
|
},
|
|
97
97
|
|
|
98
|
+
"animation-speed": {
|
|
99
|
+
"type": [ "String", "Number" ],
|
|
100
|
+
"desc": "Animation speed (in milliseconds, without unit)",
|
|
101
|
+
"examples": [ 500, "1200" ],
|
|
102
|
+
"category": "style"
|
|
103
|
+
},
|
|
104
|
+
|
|
98
105
|
"model-value": {
|
|
99
106
|
"desc": "Model of the component; Either use this property (along with a listener for 'update:model-value' event) OR use v-model directive",
|
|
100
107
|
"required": true,
|
|
@@ -24,6 +24,11 @@ export default createComponent({
|
|
|
24
24
|
default: 0
|
|
25
25
|
},
|
|
26
26
|
|
|
27
|
+
animationSpeed: {
|
|
28
|
+
type: [ String, Number ],
|
|
29
|
+
default: 600
|
|
30
|
+
},
|
|
31
|
+
|
|
27
32
|
indeterminate: Boolean
|
|
28
33
|
},
|
|
29
34
|
|
|
@@ -43,7 +48,7 @@ export default createComponent({
|
|
|
43
48
|
|
|
44
49
|
const circleStyle = computed(() => (
|
|
45
50
|
props.instantFeedback !== true && props.indeterminate !== true
|
|
46
|
-
? { transition:
|
|
51
|
+
? { transition: `stroke-dashoffset ${ props.animationSpeed }ms ease 0s, stroke ${ props.animationSpeed }ms ease` }
|
|
47
52
|
: ''
|
|
48
53
|
))
|
|
49
54
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { h, ref, computed, watch, onMounted, onBeforeUnmount, nextTick, getCurrentInstance } from 'vue'
|
|
1
|
+
import { h, ref, computed, watch, onMounted, onActivated, onDeactivated, onBeforeUnmount, nextTick, getCurrentInstance } from 'vue'
|
|
2
2
|
|
|
3
3
|
import { createComponent } from '../../utils/private/create.js'
|
|
4
4
|
import debounce from '../../utils/debounce.js'
|
|
@@ -7,6 +7,8 @@ import { getScrollTarget, getScrollHeight, getVerticalScrollPosition, setVertica
|
|
|
7
7
|
import { listenOpts } from '../../utils/event.js'
|
|
8
8
|
import { hSlot, hUniqueSlot } from '../../utils/private/render.js'
|
|
9
9
|
|
|
10
|
+
const { passive } = listenOpts
|
|
11
|
+
|
|
10
12
|
export default createComponent({
|
|
11
13
|
name: 'QInfiniteScroll',
|
|
12
14
|
|
|
@@ -34,20 +36,21 @@ export default createComponent({
|
|
|
34
36
|
emits: [ 'load' ],
|
|
35
37
|
|
|
36
38
|
setup (props, { slots, emit }) {
|
|
37
|
-
const
|
|
39
|
+
const isFetching = ref(false)
|
|
40
|
+
const isWorking = ref(true)
|
|
38
41
|
const rootRef = ref(null)
|
|
39
42
|
|
|
40
43
|
let index = props.initialIndex || 0
|
|
41
|
-
let
|
|
44
|
+
let scrollPos = false
|
|
42
45
|
let localScrollTarget, poll
|
|
43
46
|
|
|
44
47
|
const classes = computed(() =>
|
|
45
48
|
'q-infinite-scroll__loading'
|
|
46
|
-
+ (
|
|
49
|
+
+ (isFetching.value === true ? '' : ' invisible')
|
|
47
50
|
)
|
|
48
51
|
|
|
49
52
|
function immediatePoll () {
|
|
50
|
-
if (props.disable === true ||
|
|
53
|
+
if (props.disable === true || isFetching.value === true || isWorking.value === false) {
|
|
51
54
|
return
|
|
52
55
|
}
|
|
53
56
|
|
|
@@ -69,18 +72,18 @@ export default createComponent({
|
|
|
69
72
|
}
|
|
70
73
|
|
|
71
74
|
function trigger () {
|
|
72
|
-
if (props.disable === true ||
|
|
75
|
+
if (props.disable === true || isFetching.value === true || isWorking.value === false) {
|
|
73
76
|
return
|
|
74
77
|
}
|
|
75
78
|
|
|
76
79
|
index++
|
|
77
|
-
|
|
80
|
+
isFetching.value = true
|
|
78
81
|
|
|
79
82
|
const heightBefore = getScrollHeight(localScrollTarget)
|
|
80
83
|
|
|
81
84
|
emit('load', index, isDone => {
|
|
82
|
-
if (isWorking === true) {
|
|
83
|
-
|
|
85
|
+
if (isWorking.value === true) {
|
|
86
|
+
isFetching.value = false
|
|
84
87
|
nextTick(() => {
|
|
85
88
|
if (props.reverse === true) {
|
|
86
89
|
const
|
|
@@ -107,31 +110,31 @@ export default createComponent({
|
|
|
107
110
|
}
|
|
108
111
|
|
|
109
112
|
function resume () {
|
|
110
|
-
if (isWorking === false) {
|
|
111
|
-
isWorking = true
|
|
112
|
-
localScrollTarget.addEventListener('scroll', poll,
|
|
113
|
+
if (isWorking.value === false) {
|
|
114
|
+
isWorking.value = true
|
|
115
|
+
localScrollTarget.addEventListener('scroll', poll, passive)
|
|
113
116
|
}
|
|
114
117
|
|
|
115
118
|
immediatePoll()
|
|
116
119
|
}
|
|
117
120
|
|
|
118
121
|
function stop () {
|
|
119
|
-
if (isWorking === true) {
|
|
120
|
-
isWorking = false
|
|
121
|
-
|
|
122
|
-
localScrollTarget.removeEventListener('scroll', poll,
|
|
122
|
+
if (isWorking.value === true) {
|
|
123
|
+
isWorking.value = false
|
|
124
|
+
isFetching.value = false
|
|
125
|
+
localScrollTarget.removeEventListener('scroll', poll, passive)
|
|
123
126
|
}
|
|
124
127
|
}
|
|
125
128
|
|
|
126
129
|
function updateScrollTarget () {
|
|
127
|
-
if (localScrollTarget && isWorking === true) {
|
|
128
|
-
localScrollTarget.removeEventListener('scroll', poll,
|
|
130
|
+
if (localScrollTarget && isWorking.value === true) {
|
|
131
|
+
localScrollTarget.removeEventListener('scroll', poll, passive)
|
|
129
132
|
}
|
|
130
133
|
|
|
131
134
|
localScrollTarget = getScrollTarget(rootRef.value, props.scrollTarget)
|
|
132
135
|
|
|
133
|
-
if (isWorking === true) {
|
|
134
|
-
localScrollTarget.addEventListener('scroll', poll,
|
|
136
|
+
if (isWorking.value === true) {
|
|
137
|
+
localScrollTarget.addEventListener('scroll', poll, passive)
|
|
135
138
|
}
|
|
136
139
|
}
|
|
137
140
|
|
|
@@ -155,30 +158,44 @@ export default createComponent({
|
|
|
155
158
|
? immediatePoll
|
|
156
159
|
: debounce(immediatePoll, isNaN(val) === true ? 100 : val)
|
|
157
160
|
|
|
158
|
-
if (localScrollTarget && isWorking === true) {
|
|
161
|
+
if (localScrollTarget && isWorking.value === true) {
|
|
159
162
|
if (oldPoll !== void 0) {
|
|
160
|
-
localScrollTarget.removeEventListener('scroll', oldPoll,
|
|
163
|
+
localScrollTarget.removeEventListener('scroll', oldPoll, passive)
|
|
161
164
|
}
|
|
162
165
|
|
|
163
|
-
localScrollTarget.addEventListener('scroll', poll,
|
|
166
|
+
localScrollTarget.addEventListener('scroll', poll, passive)
|
|
164
167
|
}
|
|
165
168
|
}
|
|
166
169
|
|
|
167
170
|
watch(() => props.disable, val => {
|
|
168
|
-
if (val === true) {
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
171
|
+
if (val === true) { stop() }
|
|
172
|
+
else { resume() }
|
|
173
|
+
})
|
|
174
|
+
|
|
175
|
+
watch(() => props.reverse, val => {
|
|
176
|
+
if (isFetching.value === false && isWorking.value === true) {
|
|
177
|
+
immediatePoll()
|
|
173
178
|
}
|
|
174
179
|
})
|
|
175
180
|
|
|
176
181
|
watch(() => props.scrollTarget, updateScrollTarget)
|
|
177
182
|
watch(() => props.debounce, setDebounce)
|
|
178
183
|
|
|
184
|
+
onActivated(() => {
|
|
185
|
+
if (localScrollTarget && scrollPos !== false) {
|
|
186
|
+
setVerticalScrollPosition(localScrollTarget, scrollPos)
|
|
187
|
+
}
|
|
188
|
+
})
|
|
189
|
+
|
|
190
|
+
onDeactivated(() => {
|
|
191
|
+
scrollPos = localScrollTarget
|
|
192
|
+
? getVerticalScrollPosition(localScrollTarget)
|
|
193
|
+
: false
|
|
194
|
+
})
|
|
195
|
+
|
|
179
196
|
onBeforeUnmount(() => {
|
|
180
|
-
if (isWorking === true) {
|
|
181
|
-
localScrollTarget.removeEventListener('scroll', poll,
|
|
197
|
+
if (isWorking.value === true) {
|
|
198
|
+
localScrollTarget.removeEventListener('scroll', poll, passive)
|
|
182
199
|
}
|
|
183
200
|
})
|
|
184
201
|
|
|
@@ -201,7 +218,7 @@ export default createComponent({
|
|
|
201
218
|
return () => {
|
|
202
219
|
const child = hUniqueSlot(slots.default, [])
|
|
203
220
|
|
|
204
|
-
if (props.disable !== true && isWorking === true) {
|
|
221
|
+
if (props.disable !== true && isWorking.value === true) {
|
|
205
222
|
child[ props.reverse === false ? 'push' : 'unshift' ](
|
|
206
223
|
h('div', { class: classes.value }, hSlot(slots.loading))
|
|
207
224
|
)
|
|
@@ -44,6 +44,11 @@ export default createComponent({
|
|
|
44
44
|
query: Boolean,
|
|
45
45
|
rounded: Boolean,
|
|
46
46
|
|
|
47
|
+
animationSpeed: {
|
|
48
|
+
type: [ String, Number ],
|
|
49
|
+
default: 2100
|
|
50
|
+
},
|
|
51
|
+
|
|
47
52
|
instantFeedback: Boolean
|
|
48
53
|
},
|
|
49
54
|
|
|
@@ -53,6 +58,10 @@ export default createComponent({
|
|
|
53
58
|
const sizeStyle = useSize(props, defaultSizes)
|
|
54
59
|
|
|
55
60
|
const motion = computed(() => props.indeterminate === true || props.query === true)
|
|
61
|
+
const style = computed(() => ({
|
|
62
|
+
...(sizeStyle.value !== null ? sizeStyle.value : {}),
|
|
63
|
+
'--q-linear-progress-speed': `${ props.animationSpeed }ms`
|
|
64
|
+
}))
|
|
56
65
|
|
|
57
66
|
const classes = computed(() =>
|
|
58
67
|
'q-linear-progress'
|
|
@@ -103,7 +112,7 @@ export default createComponent({
|
|
|
103
112
|
|
|
104
113
|
return h('div', {
|
|
105
114
|
class: classes.value,
|
|
106
|
-
style:
|
|
115
|
+
style: style.value,
|
|
107
116
|
role: 'progressbar',
|
|
108
117
|
'aria-valuemin': 0,
|
|
109
118
|
'aria-valuemax': 1,
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
.q-linear-progress
|
|
2
|
+
--q-linear-progress-speed: .3s
|
|
2
3
|
position: relative
|
|
3
4
|
width: 100%
|
|
4
5
|
overflow: hidden
|
|
@@ -10,7 +11,7 @@
|
|
|
10
11
|
transform-origin: 0 0
|
|
11
12
|
|
|
12
13
|
&--with-transition
|
|
13
|
-
transition: transform
|
|
14
|
+
transition: transform var(--q-linear-progress-speed)
|
|
14
15
|
|
|
15
16
|
&--reverse
|
|
16
17
|
.q-linear-progress
|
|
@@ -6,7 +6,6 @@ import QMenu from '../menu/QMenu.js'
|
|
|
6
6
|
import useAnchor, { useAnchorProps } from '../../composables/private/use-anchor.js'
|
|
7
7
|
|
|
8
8
|
import { createComponent } from '../../utils/private/create.js'
|
|
9
|
-
import { hSlot } from '../../utils/private/render.js'
|
|
10
9
|
|
|
11
10
|
export default createComponent({
|
|
12
11
|
name: 'QPopupProxy',
|
|
@@ -40,6 +39,10 @@ export default createComponent({
|
|
|
40
39
|
|
|
41
40
|
const type = ref(getType())
|
|
42
41
|
|
|
42
|
+
const popupProps = computed(() => (
|
|
43
|
+
type.value === 'menu' ? { maxHeight: '99vh' } : {})
|
|
44
|
+
)
|
|
45
|
+
|
|
43
46
|
watch(() => getType(), val => {
|
|
44
47
|
if (showing.value !== true) {
|
|
45
48
|
type.value = val
|
|
@@ -65,21 +68,9 @@ export default createComponent({
|
|
|
65
68
|
}
|
|
66
69
|
|
|
67
70
|
return () => {
|
|
68
|
-
const def = hSlot(slots.default)
|
|
69
|
-
|
|
70
|
-
const popupProps = (
|
|
71
|
-
type.value === 'menu'
|
|
72
|
-
&& def !== void 0
|
|
73
|
-
&& def[ 0 ] !== void 0
|
|
74
|
-
&& def[ 0 ].type !== void 0
|
|
75
|
-
&& [ 'QDate', 'QTime', 'QCarousel', 'QColor' ].includes(
|
|
76
|
-
def[ 0 ].type.name
|
|
77
|
-
)
|
|
78
|
-
) ? { cover: true, maxHeight: '99vh' } : {}
|
|
79
|
-
|
|
80
71
|
const data = {
|
|
81
72
|
ref: popupRef,
|
|
82
|
-
...popupProps,
|
|
73
|
+
...popupProps.value,
|
|
83
74
|
...attrs,
|
|
84
75
|
onShow,
|
|
85
76
|
onHide
|
|
@@ -100,7 +91,7 @@ export default createComponent({
|
|
|
100
91
|
})
|
|
101
92
|
}
|
|
102
93
|
|
|
103
|
-
return h(component, data,
|
|
94
|
+
return h(component, data, slots.default)
|
|
104
95
|
}
|
|
105
96
|
}
|
|
106
97
|
})
|
|
@@ -33,11 +33,8 @@
|
|
|
33
33
|
},
|
|
34
34
|
|
|
35
35
|
"animation-speed": {
|
|
36
|
-
"
|
|
37
|
-
"desc": "Animation speed (in milliseconds, without unit)",
|
|
36
|
+
"extends": "animation-speed",
|
|
38
37
|
"default": 300,
|
|
39
|
-
"examples": [ 500, "1200" ],
|
|
40
|
-
"category": "style",
|
|
41
38
|
"addedIn": "v2.2"
|
|
42
39
|
},
|
|
43
40
|
|
|
@@ -26,7 +26,7 @@ export const useTablePaginationProps = {
|
|
|
26
26
|
default: () => [ 5, 7, 10, 15, 20, 25, 50, 0 ]
|
|
27
27
|
},
|
|
28
28
|
|
|
29
|
-
'onUpdate:pagination': Function
|
|
29
|
+
'onUpdate:pagination': [ Function, Array ]
|
|
30
30
|
}
|
|
31
31
|
|
|
32
32
|
export function useTablePaginationState (vm, getCellValue) {
|
|
@@ -76,7 +76,7 @@ export function useTablePaginationState (vm, getCellValue) {
|
|
|
76
76
|
...val
|
|
77
77
|
})
|
|
78
78
|
|
|
79
|
-
if (samePagination(computedPagination.value, newPagination)) {
|
|
79
|
+
if (samePagination(computedPagination.value, newPagination) === true) {
|
|
80
80
|
if (isServerSide.value === true && forceServerRequest === true) {
|
|
81
81
|
sendServerRequest(newPagination)
|
|
82
82
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { h, ref, computed, watch, onBeforeMount, onBeforeUnmount, nextTick, getCurrentInstance } from 'vue'
|
|
1
|
+
import { h, ref, computed, watch, onActivated, onBeforeMount, onBeforeUnmount, nextTick, getCurrentInstance } from 'vue'
|
|
2
2
|
|
|
3
3
|
import debounce from '../../utils/debounce.js'
|
|
4
4
|
import { noop } from '../../utils/event.js'
|
|
@@ -679,6 +679,22 @@ export function useVirtualScroll ({
|
|
|
679
679
|
setVirtualScrollSize()
|
|
680
680
|
})
|
|
681
681
|
|
|
682
|
+
onActivated(() => {
|
|
683
|
+
const scrollEl = getVirtualScrollTarget()
|
|
684
|
+
|
|
685
|
+
if (prevScrollStart !== void 0 && scrollEl !== void 0 && scrollEl !== null && scrollEl.nodeType !== 8) {
|
|
686
|
+
setScroll(
|
|
687
|
+
scrollEl,
|
|
688
|
+
prevScrollStart,
|
|
689
|
+
props.virtualScrollHorizontal,
|
|
690
|
+
$q.lang.rtl
|
|
691
|
+
)
|
|
692
|
+
}
|
|
693
|
+
else {
|
|
694
|
+
scrollTo(prevToIndex)
|
|
695
|
+
}
|
|
696
|
+
})
|
|
697
|
+
|
|
682
698
|
setOverflowAnchor !== noop && onBeforeUnmount(() => {
|
|
683
699
|
const styleSheet = document.getElementById(vsId + '_ss')
|
|
684
700
|
styleSheet !== null && styleSheet.remove()
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { ref, getCurrentInstance } from 'vue'
|
|
2
2
|
|
|
3
|
+
import getEmitsObject from '../utils/private/get-emits-object'
|
|
4
|
+
|
|
3
5
|
// To be used for the custom component
|
|
4
6
|
// used on a Dialog plugin
|
|
5
7
|
|
|
@@ -34,6 +36,9 @@ function useDialogPluginComponent () {
|
|
|
34
36
|
}
|
|
35
37
|
}
|
|
36
38
|
|
|
37
|
-
|
|
39
|
+
const emits = [ 'ok', 'hide' ]
|
|
40
|
+
|
|
41
|
+
useDialogPluginComponent.emits = emits
|
|
42
|
+
useDialogPluginComponent.emitsObject = getEmitsObject(emits)
|
|
38
43
|
|
|
39
44
|
export default useDialogPluginComponent
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import { coreProps, coreEmits, getRenderer } from '../components/uploader/uploader-core.js'
|
|
2
2
|
|
|
3
3
|
import { createComponent } from './private/create.js'
|
|
4
|
+
import getEmitsObject from './private/get-emits-object.js'
|
|
5
|
+
|
|
6
|
+
const coreEmitsObject = getEmitsObject(coreEmits)
|
|
4
7
|
|
|
5
8
|
export default ({ name, props, emits, injectPlugin }) => createComponent({
|
|
6
9
|
name,
|
|
@@ -10,10 +13,9 @@ export default ({ name, props, emits, injectPlugin }) => createComponent({
|
|
|
10
13
|
...props
|
|
11
14
|
},
|
|
12
15
|
|
|
13
|
-
emits:
|
|
14
|
-
...
|
|
15
|
-
...emits
|
|
16
|
-
],
|
|
16
|
+
emits: Object(emits) === emits
|
|
17
|
+
? { ...coreEmitsObject, ...emits }
|
|
18
|
+
: [ ...coreEmits, ...emits ],
|
|
17
19
|
|
|
18
20
|
setup () {
|
|
19
21
|
return getRenderer(injectPlugin)
|
package/src/utils/private/vm.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
// used directly by docs too
|
|
2
2
|
export function getParentVm (vm) {
|
|
3
|
-
if (vm.$parent
|
|
3
|
+
if (Object(vm.$parent) === vm.$parent) {
|
|
4
4
|
return vm.$parent
|
|
5
5
|
}
|
|
6
6
|
|
|
7
7
|
vm = vm.$.parent
|
|
8
8
|
|
|
9
|
-
while (vm
|
|
10
|
-
if (vm.proxy
|
|
9
|
+
while (Object(vm) === vm) {
|
|
10
|
+
if (Object(vm.proxy) === vm.proxy) {
|
|
11
11
|
return vm.proxy
|
|
12
12
|
}
|
|
13
13
|
|