renusify 1.1.4 → 1.2.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/components/app/notify/notification.vue +2 -1
- package/components/app/toast/index.vue +7 -2
- package/components/app/toast/toast.vue +2 -0
- package/components/avatar/index.vue +29 -23
- package/components/bar/bottomNavigationCircle.vue +8 -3
- package/components/bar/scss/bottomNav.scss +1 -1
- package/components/bar/toolbar/laptop.vue +4 -4
- package/components/bar/toolbar/mixin.js +1 -2
- package/components/bar/toolbar/mobile.vue +5 -4
- package/components/breadcrumb/index.vue +1 -0
- package/components/button/buttonConfirm.vue +1 -1
- package/components/button/buttonGroup.vue +1 -0
- package/components/button/style.scss +1 -0
- package/components/calendar/index.vue +1 -0
- package/components/calendar/month.vue +1 -0
- package/components/calendar/year.vue +1 -0
- package/components/chat/chatInput.vue +1 -0
- package/components/chat/chatMsg.vue +1 -0
- package/components/chat/index.vue +1 -0
- package/components/chip/index.vue +1 -0
- package/components/codeEditor/index.vue +0 -2
- package/components/confirm/index.vue +1 -0
- package/components/countdown/index.vue +1 -0
- package/components/float/index.vue +1 -0
- package/components/form/address.vue +6 -2
- package/components/form/camInput.vue +10 -3
- package/components/form/check-input.vue +95 -94
- package/components/form/checkbox.vue +1 -1
- package/components/form/colorPicker/index.vue +1 -0
- package/components/form/colorPicker/picker.vue +1 -0
- package/components/form/datePicker/index.vue +349 -348
- package/components/form/datePicker/month.vue +1 -0
- package/components/form/datePicker/year.vue +1 -0
- package/components/form/fileUploader/file.js +21 -3
- package/components/form/fileUploader/index.vue +13 -2
- package/components/form/fileUploader/single.vue +4 -2
- package/components/form/form.vue +1 -0
- package/components/form/group-input.vue +42 -38
- package/components/form/input.vue +253 -1
- package/components/form/inputTel/index.vue +22 -12
- package/components/form/json/JsonView.vue +95 -94
- package/components/form/json/index.vue +2 -0
- package/components/form/mask-input.vue +1 -0
- package/components/form/number.vue +25 -12
- package/components/form/password.vue +121 -121
- package/components/form/radioInput.vue +1 -0
- package/components/form/range.vue +26 -1
- package/components/form/rating.vue +13 -1
- package/components/form/select.vue +67 -4
- package/components/form/switch.vue +64 -2
- package/components/form/text-area.vue +1 -1
- package/components/form/text-editor/index.vue +18 -11
- package/components/form/text-input.vue +1 -1
- package/components/form/timepicker/index.vue +2 -1
- package/components/form/timepicker/range.vue +2 -1
- package/components/form/timepicker/timepicker.vue +2 -1
- package/components/form/unique/index.vue +3 -1
- package/components/form/unit-input.vue +2 -1
- package/components/formCreator/index.vue +8 -6
- package/components/html2pdf/index.vue +1 -0
- package/components/img/index.vue +12 -2
- package/components/img/svgImg.vue +43 -0
- package/components/infinite/div.vue +2 -1
- package/components/infinite/page.vue +24 -23
- package/components/list/index.vue +35 -32
- package/components/map/index.vue +324 -306
- package/components/map/route.vue +1 -0
- package/components/map/select.vue +1 -0
- package/components/menu/index.vue +1 -0
- package/components/modal/index.vue +1 -0
- package/components/searchBox/index.vue +5 -3
- package/components/slider/index.vue +1 -0
- package/components/table/crud/footer.vue +1 -1
- package/components/table/crud/header.vue +10 -4
- package/components/table/crud/index.vue +463 -458
- package/components/tabs/index.vue +1 -0
- package/components/tree/index.vue +15 -13
- package/components/tree/tree-element.vue +8 -4
- package/package.json +1 -1
- package/style/colors.scss +1 -1
- package/components/form/scss/input.scss +0 -249
- package/components/form/scss/rating.scss +0 -9
- package/components/form/scss/select.scss +0 -55
- package/components/form/scss/switch.scss +0 -68
|
@@ -1,107 +1,108 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
2
|
+
<div :class="`${$r.prefix}json-view d-flex v-baseline flex-wrap`"
|
|
3
|
+
v-for="(value,key) in modelValue"
|
|
4
|
+
:key="key">
|
|
5
|
+
<div class="key d-flex v-baseline me-1" :style="{'max-width': keyWidth}">
|
|
6
|
+
<r-btn v-if="!disableDel" icon class="color-error-text" text @click="del(key)">
|
|
7
|
+
<r-icon v-html="$r.icons.delete"></r-icon>
|
|
8
|
+
</r-btn>
|
|
9
|
+
<template v-if="!is_array">
|
|
10
|
+
<r-text-input :tile="tile" :readonly="disableEditKey" :model-value="key"
|
|
11
|
+
@update:model-value="emitkey(key,$event)"></r-text-input>
|
|
12
|
+
:
|
|
13
|
+
</template>
|
|
14
|
+
</div>
|
|
15
|
+
<div v-if="typeof value==='object'" class="flex-grow-1 w-full ps-10">
|
|
16
|
+
<r-json-input :tile="tile"
|
|
17
|
+
:model-value="value"
|
|
18
|
+
@update:model-value="emit(key,$event)"
|
|
19
|
+
:disableAdd="disableAdd||template!==undefined"
|
|
20
|
+
:disableDel="disableDel||template!==undefined"
|
|
21
|
+
:disableEditKey="disableEditKey"
|
|
22
|
+
:keyWidth="keyWidth"
|
|
23
|
+
:valueWidth="valueWidth"
|
|
24
|
+
></r-json-input>
|
|
25
|
+
</div>
|
|
26
|
+
<div v-else class="mb-1" :style="{'max-width': valueWidth}">
|
|
27
|
+
<r-text-input v-if="typeof value==='string'"
|
|
28
|
+
:tile="tile"
|
|
29
|
+
:model-value="value" @update:model-value="emit(key,$event)"></r-text-input>
|
|
30
|
+
<r-number-input v-else-if="typeof value==='number'"
|
|
28
31
|
:tile="tile"
|
|
29
|
-
:model-value="value" @update:model-value="emit(key,$event)"></r-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
<r-switch-input v-else-if="typeof value==='boolean'"
|
|
34
|
-
:tile="tile"
|
|
35
|
-
:model-value="value" @update:model-value="emit(key,$event)"></r-switch-input>
|
|
36
|
-
|
|
37
|
-
</div>
|
|
32
|
+
:model-value="value" @update:model-value="emit(key,$event)"></r-number-input>
|
|
33
|
+
<r-switch-input v-else-if="typeof value==='boolean'"
|
|
34
|
+
:tile="tile"
|
|
35
|
+
:model-value="value" @update:model-value="emit(key,$event)"></r-switch-input>
|
|
38
36
|
|
|
39
37
|
</div>
|
|
38
|
+
|
|
39
|
+
</div>
|
|
40
40
|
</template>
|
|
41
41
|
<script>
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
42
|
+
export default {
|
|
43
|
+
name: 'jsonView',
|
|
44
|
+
props: {
|
|
45
|
+
modelValue: Object,
|
|
46
|
+
template: Object,
|
|
47
|
+
disableEditKey: Boolean,
|
|
48
|
+
disableAdd: Boolean,
|
|
49
|
+
disableDel: Boolean,
|
|
50
|
+
tile: Boolean,
|
|
51
|
+
keyWidth: {
|
|
52
|
+
type: String,
|
|
53
|
+
default: '140px'
|
|
54
|
+
}, valueWidth: {
|
|
55
|
+
type: String,
|
|
56
|
+
default: '300px'
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
emits: ['update:model-value'],
|
|
60
|
+
data() {
|
|
61
|
+
return {
|
|
62
|
+
time_id: null
|
|
63
|
+
}
|
|
64
|
+
},
|
|
65
|
+
computed: {
|
|
66
|
+
is_array() {
|
|
67
|
+
return Array.isArray(this.modelValue)
|
|
68
|
+
}
|
|
69
|
+
},
|
|
70
|
+
methods: {
|
|
71
|
+
del(key) {
|
|
72
|
+
let o = this.modelValue
|
|
73
|
+
if (this.is_array) {
|
|
74
|
+
o.splice(key, 1)
|
|
75
|
+
} else {
|
|
76
|
+
delete o[key]
|
|
77
|
+
}
|
|
78
|
+
this.$emit('update:model-value', o)
|
|
79
|
+
},
|
|
80
|
+
emitkey(oldKey, newKey) {
|
|
81
|
+
clearTimeout(this.time_id)
|
|
82
|
+
let o = this.modelValue
|
|
83
|
+
let n = {};
|
|
83
84
|
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
}
|
|
91
|
-
});
|
|
92
|
-
this.time_id = setTimeout(() => {
|
|
93
|
-
this.$emit('update:model-value', n)
|
|
94
|
-
}, 1000)
|
|
95
|
-
},
|
|
96
|
-
emit(k, v) {
|
|
97
|
-
let d = this.modelValue
|
|
98
|
-
d[k] = v
|
|
99
|
-
this.$emit('update:model-value', d)
|
|
100
|
-
}
|
|
85
|
+
Object.keys(o).forEach(key => {
|
|
86
|
+
if (key === oldKey) {
|
|
87
|
+
let newPair = {[newKey]: o[oldKey]};
|
|
88
|
+
n = {...n, ...newPair}
|
|
89
|
+
} else {
|
|
90
|
+
n = {...n, [key]: o[key]}
|
|
101
91
|
}
|
|
92
|
+
});
|
|
93
|
+
this.time_id = setTimeout(() => {
|
|
94
|
+
this.$emit('update:model-value', n)
|
|
95
|
+
}, 1000)
|
|
96
|
+
},
|
|
97
|
+
emit(k, v) {
|
|
98
|
+
let d = this.modelValue
|
|
99
|
+
d[k] = v
|
|
100
|
+
this.$emit('update:model-value', d)
|
|
102
101
|
}
|
|
102
|
+
}
|
|
103
|
+
}
|
|
103
104
|
</script>
|
|
104
105
|
<style lang="scss">
|
|
105
|
-
|
|
106
|
+
@import "../../../style/include";
|
|
106
107
|
|
|
107
108
|
</style>
|
|
@@ -42,6 +42,7 @@
|
|
|
42
42
|
class="me-1"
|
|
43
43
|
:items="['text','number','boolean','json','array']"
|
|
44
44
|
just-value
|
|
45
|
+
disableSearch
|
|
45
46
|
@update:model-value="info.value=null"
|
|
46
47
|
firstSelect></r-select-input>
|
|
47
48
|
</div>
|
|
@@ -100,6 +101,7 @@ export default {
|
|
|
100
101
|
disableEditKey: Boolean,
|
|
101
102
|
disableDel: Boolean
|
|
102
103
|
},
|
|
104
|
+
emits:['update:modelValue'],
|
|
103
105
|
data() {
|
|
104
106
|
return {
|
|
105
107
|
show: false,
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
:active="active"
|
|
6
6
|
inputControlClass="v-center"
|
|
7
7
|
>
|
|
8
|
-
<r-btn @click.prevent="minus" class="minus" icon :text="btnText">
|
|
8
|
+
<r-btn @click.prevent.stop="minus" class="minus" icon :text="btnText">
|
|
9
9
|
<r-icon v-html="$r.icons.minus"></r-icon>
|
|
10
10
|
</r-btn>
|
|
11
11
|
<input @input="emit"
|
|
@@ -13,11 +13,11 @@
|
|
|
13
13
|
@focusin="active=true"
|
|
14
14
|
@focusout="active=false"
|
|
15
15
|
ref="input"
|
|
16
|
-
type="
|
|
16
|
+
type="text"
|
|
17
17
|
autocomplete="no"
|
|
18
|
-
v-model
|
|
18
|
+
v-model="number"
|
|
19
19
|
/>
|
|
20
|
-
<r-btn @click.prevent="plus" class="plus" icon :text="btnText">
|
|
20
|
+
<r-btn @click.prevent.stop="plus" class="plus" icon :text="btnText">
|
|
21
21
|
<r-icon v-html="$r.icons.plus"></r-icon>
|
|
22
22
|
</r-btn>
|
|
23
23
|
</r-input>
|
|
@@ -32,6 +32,7 @@ export default {
|
|
|
32
32
|
props: {
|
|
33
33
|
modelValue: Number,
|
|
34
34
|
step: {type: Number, default: 1},
|
|
35
|
+
split: {type: Number, default: 0},
|
|
35
36
|
min: {
|
|
36
37
|
type: Number
|
|
37
38
|
},
|
|
@@ -40,27 +41,41 @@ export default {
|
|
|
40
41
|
},
|
|
41
42
|
btnText: Boolean
|
|
42
43
|
},
|
|
44
|
+
emits:['update:modelValue'],
|
|
43
45
|
data() {
|
|
44
46
|
return {
|
|
45
|
-
number: this.modelValue,
|
|
47
|
+
number: this.setSplit(this.modelValue),
|
|
46
48
|
active: false
|
|
47
49
|
}
|
|
48
50
|
},
|
|
49
51
|
watch: {
|
|
50
52
|
'modelValue': function (newVal) {
|
|
51
53
|
setTimeout(() => {
|
|
52
|
-
this.number = newVal
|
|
54
|
+
this.number = this.setSplit(newVal)
|
|
53
55
|
})
|
|
54
56
|
}
|
|
55
57
|
},
|
|
56
58
|
methods: {
|
|
59
|
+
setSplit(n) {
|
|
60
|
+
if (n && this.split > 0) {
|
|
61
|
+
const x = this.split
|
|
62
|
+
n = n.toString()
|
|
63
|
+
const step = n.indexOf('.')
|
|
64
|
+
const re = '\\d(?=(\\d{' + (x) + '})+' + (step > -1 ? '\\.' : '$') + ')';
|
|
65
|
+
return n.replace(new RegExp(re, 'g'), '$&,');
|
|
66
|
+
}
|
|
67
|
+
return n
|
|
68
|
+
},
|
|
69
|
+
removeSplit(n) {
|
|
70
|
+
return parseFloat(this.$helper.replacer(n.toString(), ',', ''))
|
|
71
|
+
},
|
|
57
72
|
emit() {
|
|
58
73
|
if (this.number === '' || this.number === null) {
|
|
59
74
|
this.number = undefined
|
|
60
|
-
this.$emit('update:modelValue',
|
|
75
|
+
this.$emit('update:modelValue', this.number)
|
|
61
76
|
return
|
|
62
77
|
}
|
|
63
|
-
let d = this.number
|
|
78
|
+
let d = this.removeSplit(this.number)
|
|
64
79
|
if (this.max !== undefined && d > this.max) {
|
|
65
80
|
d = this.max
|
|
66
81
|
}
|
|
@@ -68,13 +83,11 @@ export default {
|
|
|
68
83
|
d = this.min
|
|
69
84
|
}
|
|
70
85
|
const n = ((1 / this.step) + '').length - 1
|
|
71
|
-
this.number =
|
|
72
|
-
this.$emit('update:modelValue', this.number)
|
|
73
|
-
|
|
86
|
+
this.number = this.setSplit(d.toFixed(n))
|
|
87
|
+
this.$emit('update:modelValue', this.removeSplit(this.number))
|
|
74
88
|
},
|
|
75
89
|
plus() {
|
|
76
90
|
let n = this.modelValue || 0
|
|
77
|
-
|
|
78
91
|
this.number = n + this.step
|
|
79
92
|
this.emit()
|
|
80
93
|
},
|
|
@@ -1,129 +1,129 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
2
|
+
<div :class="$r.prefix+'password'">
|
|
3
|
+
<r-input v-bind="$attrs"
|
|
4
|
+
:active="active"
|
|
5
|
+
:model-value="modelValue"
|
|
6
|
+
@click.prevent="handleClick"
|
|
7
|
+
:error="errorState"
|
|
8
|
+
:preIcon="show?$r.icons.eye_off:$r.icons.eye"
|
|
9
|
+
ltr
|
|
10
|
+
@preIcon="show=!show"
|
|
11
|
+
>
|
|
12
|
+
<input :autofocus="autofocus"
|
|
13
|
+
:type="show?'text':'password'"
|
|
14
|
+
class="pb-0"
|
|
15
|
+
@focusin="active=true"
|
|
16
|
+
@focusout="active=false"
|
|
17
|
+
@input="emit"
|
|
18
|
+
autocomplete="no"
|
|
19
|
+
ref="input"
|
|
20
|
+
v-model="lazyValue"
|
|
21
|
+
/>
|
|
22
|
+
</r-input>
|
|
23
|
+
<template v-if="!hideLine">
|
|
24
|
+
<div :class="{'color-success-text':hasLength,'color-error-text':!hasLength}">
|
|
25
|
+
<r-icon v-if="hasLength" exact v-html="$r.icons.check"></r-icon>
|
|
26
|
+
<r-icon v-else v-html="$r.icons.close"></r-icon>
|
|
27
|
+
{{ $t(['min_length_password', [minLength]]) }}
|
|
28
|
+
</div>
|
|
29
|
+
<div v-if="lowerCase" :class="{'color-success-text':hasLowerCase,'color-error-text':!hasLowerCase}">
|
|
30
|
+
<r-icon v-if="hasLowerCase" exact v-html="$r.icons.check"></r-icon>
|
|
31
|
+
<r-icon v-else v-html="$r.icons.close"></r-icon>
|
|
32
|
+
{{ $t('lower_case_password') }}
|
|
33
|
+
</div>
|
|
34
|
+
<div v-if="number" :class="{'color-success-text':hasNumber,'color-error-text':!hasNumber}">
|
|
35
|
+
<r-icon v-if="hasNumber" exact v-html="$r.icons.check"></r-icon>
|
|
36
|
+
<r-icon v-else v-html="$r.icons.close"></r-icon>
|
|
37
|
+
{{ $t('number_password') }}
|
|
38
|
+
</div>
|
|
39
|
+
<div v-if="upperCase" :class="{'color-success-text':hasUpperCase,'color-error-text':!hasUpperCase}">
|
|
40
|
+
<r-icon v-if="hasUpperCase" exact v-html="$r.icons.check"></r-icon>
|
|
41
|
+
<r-icon v-else v-html="$r.icons.close"></r-icon>
|
|
42
|
+
{{ $t('upper_case_password') }}
|
|
43
|
+
</div>
|
|
44
|
+
<div v-if="specialChar" :class="{'color-success-text':hasSpecialChar,'color-error-text':!hasSpecialChar}">
|
|
45
|
+
<r-icon v-if="hasSpecialChar" exact v-html="$r.icons.check"></r-icon>
|
|
46
|
+
<r-icon v-else v-html="$r.icons.close"></r-icon>
|
|
47
|
+
{{ $t('special_char_password') }}
|
|
48
|
+
</div>
|
|
49
|
+
</template>
|
|
50
|
+
</div>
|
|
51
51
|
</template>
|
|
52
52
|
<script>
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
53
|
+
export default {
|
|
54
|
+
name: 'r-password',
|
|
55
|
+
props: {
|
|
56
|
+
modelValue: [String, Number],
|
|
57
|
+
hideLine: Boolean,
|
|
58
|
+
autofocus: Boolean,
|
|
59
|
+
lowerCase: {type: Boolean, default: true},
|
|
60
|
+
upperCase: Boolean,
|
|
61
|
+
specialChar: Boolean,
|
|
62
|
+
number: Boolean,
|
|
63
|
+
minLength: {type: Number, default: 8},
|
|
64
|
+
},
|
|
65
|
+
emits: ['update:modelValue'],
|
|
66
|
+
data() {
|
|
67
|
+
return {
|
|
68
|
+
lazyValue: this.modelValue,
|
|
69
|
+
show: false,
|
|
70
|
+
active: false,
|
|
71
|
+
p: 0,
|
|
72
|
+
errorState: false
|
|
73
|
+
}
|
|
74
|
+
},
|
|
75
|
+
computed: {
|
|
76
|
+
hasLength() {
|
|
77
|
+
if (!this.lazyValue) {
|
|
78
|
+
return false
|
|
79
|
+
}
|
|
80
|
+
return this.lazyValue.length >= this.minLength
|
|
81
|
+
},
|
|
82
|
+
hasUpperCase() {
|
|
83
|
+
return new RegExp("^(?=.*[A-Z])").test(this.lazyValue)
|
|
84
|
+
},
|
|
85
|
+
hasNumber() {
|
|
86
|
+
return new RegExp("^(?=.*[0-9])").test(this.lazyValue)
|
|
87
|
+
},
|
|
88
|
+
hasLowerCase() {
|
|
89
|
+
return new RegExp("^(?=.*[a-z])").test(this.lazyValue)
|
|
90
|
+
},
|
|
91
|
+
hasSpecialChar() {
|
|
92
|
+
return new RegExp("^(?=.*[!@#\$%\^&\*])").test(this.lazyValue)
|
|
93
|
+
}
|
|
94
|
+
},
|
|
95
95
|
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
96
|
+
methods: {
|
|
97
|
+
check() {
|
|
98
|
+
if (!this.hasLength) {
|
|
99
|
+
this.errorState = true
|
|
100
|
+
}
|
|
101
|
+
if (this.lowerCase && !this.hasLowerCase) {
|
|
102
|
+
this.errorState = true
|
|
103
|
+
}
|
|
104
|
+
if (this.number && !this.hasNumber) {
|
|
105
|
+
this.errorState = true
|
|
106
|
+
}
|
|
107
|
+
if (this.upperCase && !this.hasUpperCase) {
|
|
108
|
+
this.errorState = true
|
|
109
|
+
}
|
|
110
|
+
if (this.specialChar && !this.hasSpecialChar) {
|
|
111
|
+
this.errorState = true
|
|
112
|
+
}
|
|
113
113
|
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
}
|
|
126
|
-
}
|
|
114
|
+
},
|
|
115
|
+
handleClick(e) {
|
|
116
|
+
this.$refs.input.focus()
|
|
117
|
+
},
|
|
118
|
+
emit() {
|
|
119
|
+
this.$emit('update:modelValue', this.lazyValue)
|
|
120
|
+
this.errorState = false
|
|
121
|
+
this.msg = null
|
|
122
|
+
if (this.lazyValue && !this.hideLine) {
|
|
123
|
+
this.check()
|
|
124
|
+
}
|
|
127
125
|
}
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
128
|
|
|
129
129
|
</script>
|
|
@@ -77,6 +77,7 @@ export default {
|
|
|
77
77
|
isRange: Boolean
|
|
78
78
|
|
|
79
79
|
},
|
|
80
|
+
emits:['update:modelValue'],
|
|
80
81
|
data() {
|
|
81
82
|
return {
|
|
82
83
|
width: 0,
|
|
@@ -94,7 +95,7 @@ export default {
|
|
|
94
95
|
this.width = this.$refs.range.getBoundingClientRect().width - 10
|
|
95
96
|
this.preValue = this.min
|
|
96
97
|
if (this.isRange && !this.modelValue) {
|
|
97
|
-
this.$emit('update:modelValue', [
|
|
98
|
+
this.$emit('update:modelValue', [])
|
|
98
99
|
const r = this.$r.rtl ? -1 : 1
|
|
99
100
|
this.x2 = this.width * r
|
|
100
101
|
this.prePosition2 = this.width * r
|
|
@@ -241,6 +242,18 @@ export default {
|
|
|
241
242
|
height: 10px;
|
|
242
243
|
border-radius: 50%;
|
|
243
244
|
cursor: grabbing;
|
|
245
|
+
|
|
246
|
+
&:hover {
|
|
247
|
+
width: 16px;
|
|
248
|
+
height: 16px;
|
|
249
|
+
@include rtl() {
|
|
250
|
+
transform: translate(2px, -2px);
|
|
251
|
+
}
|
|
252
|
+
@include ltr() {
|
|
253
|
+
transform: translate(-2px, -2px);
|
|
254
|
+
}
|
|
255
|
+
border: 3px solid var(--color-two) !important;
|
|
256
|
+
}
|
|
244
257
|
}
|
|
245
258
|
|
|
246
259
|
.dot-tooltip {
|
|
@@ -292,6 +305,18 @@ export default {
|
|
|
292
305
|
border-radius: 50%;
|
|
293
306
|
margin-top: -3px;
|
|
294
307
|
cursor: grabbing;
|
|
308
|
+
|
|
309
|
+
&:hover {
|
|
310
|
+
width: 16px;
|
|
311
|
+
height: 16px;
|
|
312
|
+
@include rtl() {
|
|
313
|
+
transform: translate(2px, -2px);
|
|
314
|
+
}
|
|
315
|
+
@include ltr {
|
|
316
|
+
transform: translate(-2px, -2px);
|
|
317
|
+
}
|
|
318
|
+
border: 3px solid var(--color-two) !important;
|
|
319
|
+
}
|
|
295
320
|
}
|
|
296
321
|
|
|
297
322
|
.dot-tooltip {
|