@everchron/ec-shards 7.4.13 → 7.4.15
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/ec-shards.common.js +59 -56
- package/dist/ec-shards.common.js.map +1 -1
- package/dist/ec-shards.css +1 -1
- package/dist/ec-shards.umd.js +59 -56
- package/dist/ec-shards.umd.js.map +1 -1
- package/dist/ec-shards.umd.min.js +2 -2
- package/dist/ec-shards.umd.min.js.map +1 -1
- package/package.json +1 -1
- package/src/components/input/input.vue +2 -2
- package/src/components/select/select.vue +4 -1
- package/src/stories/input/input.stories.js +7 -1
- package/src/stories/select/select.stories.js +2 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<input v-if="type != 'textarea'" class="ecs-form-control"
|
|
3
|
-
@input="$emit('input', $event)"
|
|
3
|
+
@input="$emit('input', $event.target.value)"
|
|
4
4
|
@change="$emit('change', $event)"
|
|
5
5
|
@keyup="$emit('keyup', $event)"
|
|
6
6
|
@blur="$emit('blur', $event)"
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
:id="refr"
|
|
25
25
|
/>
|
|
26
26
|
<textarea v-else class="ecs-form-control"
|
|
27
|
-
@input="$emit('input', $event)"
|
|
27
|
+
@input="$emit('input', $event.target.value)"
|
|
28
28
|
@change="$emit('change', $event)"
|
|
29
29
|
@keyup="$emit('keyup', $event)"
|
|
30
30
|
@blur="$emit('blur', $event)"
|
|
@@ -7,7 +7,8 @@
|
|
|
7
7
|
v-bind="{ id, name, disabled, required }"
|
|
8
8
|
:id="id"
|
|
9
9
|
:name="name"
|
|
10
|
-
:class="hasPlaceholder? 'placeholder' : ''"
|
|
10
|
+
:class="hasPlaceholder? 'placeholder' : ''"
|
|
11
|
+
v-model="currentValue">
|
|
11
12
|
<option v-if="placeholder" selected hidden disabled>{{placeholder}}</option>
|
|
12
13
|
<slot></slot>
|
|
13
14
|
</select>
|
|
@@ -96,6 +97,7 @@ export default {
|
|
|
96
97
|
this.currentValue = event.target.value;
|
|
97
98
|
this.hasPlaceholder = false
|
|
98
99
|
this.$emit('change', event)
|
|
100
|
+
this.$emit('input', this.currentValue)
|
|
99
101
|
}
|
|
100
102
|
},
|
|
101
103
|
|
|
@@ -109,6 +111,7 @@ export default {
|
|
|
109
111
|
if (newValue !== this.currentValue) {
|
|
110
112
|
this.currentValue = newValue
|
|
111
113
|
this.$emit('change', { target: { value: newValue } });
|
|
114
|
+
this.$emit('input', this.currentValue)
|
|
112
115
|
}
|
|
113
116
|
}
|
|
114
117
|
}
|
|
@@ -7,8 +7,14 @@ export default {
|
|
|
7
7
|
|
|
8
8
|
export const input = () => ({
|
|
9
9
|
components: { EcsInput },
|
|
10
|
+
data() {
|
|
11
|
+
return {
|
|
12
|
+
name: '',
|
|
13
|
+
}
|
|
14
|
+
},
|
|
10
15
|
template: `<div>
|
|
11
|
-
<
|
|
16
|
+
<div class="mb-2">Name: {{ name }}</div>
|
|
17
|
+
<ecs-input v-model="name" placeholder="Enter your name" class="mb-2" />
|
|
12
18
|
<ecs-input readonly value="Readonly" class="mb-2" />
|
|
13
19
|
<ecs-input disabled value="Disabled" />
|
|
14
20
|
</div>`,
|
|
@@ -21,7 +21,8 @@ export const select = () => ({
|
|
|
21
21
|
Set to: <button @click="value = 'admin'">admin</button>
|
|
22
22
|
<button @click="value = 'basic'">basic</button>
|
|
23
23
|
<button @click="value = 'guest'">guest</button>
|
|
24
|
-
<
|
|
24
|
+
<div>Set: {{ value }}</div>
|
|
25
|
+
<ecs-select class="mb-4" v-model="value" id="test" name="testname">
|
|
25
26
|
<option value="admin">Admin</option>
|
|
26
27
|
<option value="basic">Basic</option>
|
|
27
28
|
<option value="guest">Guest</option>
|