@everchron/ec-shards 7.5.0 → 7.5.2
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 +101 -84
- package/dist/ec-shards.common.js.map +1 -1
- package/dist/ec-shards.css +1 -1
- package/dist/ec-shards.umd.js +101 -84
- 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/banner/banner.vue +1 -1
- package/src/components/pagination/pagination.vue +19 -2
- package/src/components/select/select.vue +5 -3
package/package.json
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
</ecs-flex-row>
|
|
9
9
|
<ecs-flex-row :gap="4">
|
|
10
10
|
<span>Page</span>
|
|
11
|
-
<ecs-select @change="$emit('updatePage',
|
|
11
|
+
<ecs-select v-model="updatedCurrentPage" @change="$emit('updatePage', Number(updatedCurrentPage))" :disabled="!totalPages" size="sml">
|
|
12
12
|
<option v-for="n in totalPages" :key="n" :value="n" :selected="n === currentPage">{{ n }}</option>
|
|
13
13
|
</ecs-select>
|
|
14
14
|
<span v-if="totalPages" class="total">of {{ totalPages }}</span>
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
|
|
37
37
|
<ecs-flex-row v-if="showItemsPerPage && type == 'paginated'" :gap="4" class="ecs-pagination-items">
|
|
38
38
|
<span>Items per page</span>
|
|
39
|
-
<ecs-select @change="$emit('itemsPerPage',
|
|
39
|
+
<ecs-select v-model="updatedItemsPerPageSelected" @change="$emit('itemsPerPage', Number(updatedItemsPerPageSelected))" :disabled="loading" size="sml">
|
|
40
40
|
<option v-for="n in itemsPerPage" :key="n" :value="n" :selected="n === itemsPerPageSelected">{{ n }}</option>
|
|
41
41
|
</ecs-select>
|
|
42
42
|
</ecs-flex-row>
|
|
@@ -123,6 +123,13 @@
|
|
|
123
123
|
}
|
|
124
124
|
},
|
|
125
125
|
|
|
126
|
+
data() {
|
|
127
|
+
return {
|
|
128
|
+
updatedItemsPerPageSelected: this.itemsPerPageSelected,
|
|
129
|
+
updatedCurrentPage: this.currentPage,
|
|
130
|
+
}
|
|
131
|
+
},
|
|
132
|
+
|
|
126
133
|
computed: {
|
|
127
134
|
hasRange() {
|
|
128
135
|
if (
|
|
@@ -134,6 +141,16 @@
|
|
|
134
141
|
this.itemRangeTotal !== '')
|
|
135
142
|
return true
|
|
136
143
|
}
|
|
144
|
+
},
|
|
145
|
+
|
|
146
|
+
watch: {
|
|
147
|
+
currentPage(newVal) {
|
|
148
|
+
this.updatedCurrentPage = newVal;
|
|
149
|
+
},
|
|
150
|
+
|
|
151
|
+
itemsPerPageSelected(newVal) {
|
|
152
|
+
this.updatedItemsPerPageSelected = newVal;
|
|
153
|
+
},
|
|
137
154
|
}
|
|
138
155
|
}
|
|
139
156
|
</script>
|
|
@@ -48,7 +48,9 @@ export default {
|
|
|
48
48
|
/** Sets the `name` attribute. */
|
|
49
49
|
name: String,
|
|
50
50
|
/** Allows to programmatically select a specific option item via it's value. */
|
|
51
|
-
value:
|
|
51
|
+
value: {
|
|
52
|
+
type: [String, Number]
|
|
53
|
+
}
|
|
52
54
|
},
|
|
53
55
|
|
|
54
56
|
data() {
|
|
@@ -95,8 +97,8 @@ export default {
|
|
|
95
97
|
onChange(event) {
|
|
96
98
|
this.currentValue = event.target.value;
|
|
97
99
|
this.hasPlaceholder = false
|
|
98
|
-
this.$emit('change', event)
|
|
99
100
|
this.$emit('input', this.currentValue)
|
|
101
|
+
this.$emit('change', event)
|
|
100
102
|
}
|
|
101
103
|
},
|
|
102
104
|
|
|
@@ -109,8 +111,8 @@ export default {
|
|
|
109
111
|
option.selected = true
|
|
110
112
|
if (newValue !== this.currentValue) {
|
|
111
113
|
this.currentValue = newValue
|
|
112
|
-
this.$emit('change', { target: { value: newValue } });
|
|
113
114
|
this.$emit('input', this.currentValue)
|
|
115
|
+
this.$emit('change', { target: { value: newValue } });
|
|
114
116
|
}
|
|
115
117
|
}
|
|
116
118
|
}
|