aloha-vue 1.0.16 → 1.0.17

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "aloha-vue",
3
3
  "description": "Project aloha",
4
- "version": "1.0.16",
4
+ "version": "1.0.17",
5
5
  "author": "Ilia Brykin",
6
6
  "dependencies": {
7
7
  "@popperjs/core": "2.11.5",
@@ -26,6 +26,10 @@ export default {
26
26
  required: false,
27
27
  default: false,
28
28
  },
29
+ loading: {
30
+ type: Boolean,
31
+ required: false,
32
+ },
29
33
  selectorClose: {
30
34
  type: [String, Array],
31
35
  required: false,
@@ -210,6 +214,10 @@ export default {
210
214
  }
211
215
  return "";
212
216
  },
217
+
218
+ disabledLocal() {
219
+ return this.disabled || this.loading;
220
+ },
213
221
  },
214
222
  watch: {
215
223
  isModalHidden() {
@@ -412,7 +420,7 @@ export default {
412
420
  type: "button",
413
421
  class: "a_btn_close",
414
422
  ariaLabel: "Close",
415
- disabled: this.disabled,
423
+ disabled: this.disabledLocal,
416
424
  onClick: this.close,
417
425
  })
418
426
  ]),
@@ -442,7 +450,7 @@ export default {
442
450
  this.save && h("button", {
443
451
  type: "button",
444
452
  class: this.saveButtonClass,
445
- disabled: this.disabled,
453
+ disabled: this.disabledLocal,
446
454
  onClick: this.save,
447
455
  }, [
448
456
  h("span", null, this.saveButtonText),
@@ -450,7 +458,7 @@ export default {
450
458
  !this.isCloseButtonHidden && h("button", {
451
459
  type: "button",
452
460
  class: this.closeButtonClass,
453
- disabled: this.disabled,
461
+ disabled: this.disabledLocal,
454
462
  onClick: this.close,
455
463
  }, [
456
464
  h("span", null, this.closeButtonText),
@@ -28,6 +28,7 @@ export default {
28
28
  render() {
29
29
  if (this.type === "button") {
30
30
  return h("button", {
31
+ id: this.action.id,
31
32
  class: ["a_table__action", this.action.class],
32
33
  disabled: this.action.disabled,
33
34
  }, [
@@ -47,6 +48,7 @@ export default {
47
48
  }
48
49
  if (this.type === "link") {
49
50
  return h(resolveComponent("RouterLink"), {
51
+ id: this.action.id,
50
52
  class: ["a_table__action", this.action.class],
51
53
  to: this.action.to,
52
54
  disabled: this.action.disabled,
@@ -104,6 +104,13 @@ export default {
104
104
  }
105
105
  return undefined;
106
106
  },
107
+
108
+ idLocal() {
109
+ if (this.rowAction.id) {
110
+ return `${ this.rowAction.id }_${ this.rowIndex }`;
111
+ }
112
+ return undefined;
113
+ },
107
114
  },
108
115
  methods: {
109
116
  onClick() {
@@ -111,6 +118,7 @@ export default {
111
118
  row: this.row,
112
119
  rowIndex: this.rowIndex,
113
120
  rowAction: this.rowAction,
121
+ id: this.idLocal,
114
122
  });
115
123
  },
116
124
  },
@@ -126,11 +134,13 @@ export default {
126
134
  row: this.row,
127
135
  rowIndex: this.rowIndex,
128
136
  rowAction: this.rowAction,
137
+ id: this.idLocal,
129
138
  });
130
139
  }
131
140
  if (this.rowAction.type === "link") {
132
141
  return h("li", null, [
133
142
  h(resolveComponent("RouterLink"), {
143
+ id: this.idLocal,
134
144
  class: ["a_dropdown__item a_table__row_action", this.classLocal],
135
145
  disabled: this.disabledLocal,
136
146
  to: this.toLocal,
@@ -152,6 +162,7 @@ export default {
152
162
  }
153
163
  return h("li", null, [
154
164
  h("button", {
165
+ id: this.idLocal,
155
166
  type: "button",
156
167
  class: ["a_dropdown__item a_table__row_action", this.classLocal],
157
168
  disabled: this.disabledLocal,
@@ -43,7 +43,7 @@
43
43
  position: relative;
44
44
  min-width: 200px;
45
45
  max-width: 400px;
46
- z-index: 999;
46
+ z-index: 1055;
47
47
  background-color: #fff;
48
48
  border: 1px solid grey;
49
49
  padding: 10px;
@@ -157,6 +157,10 @@ export default {
157
157
  required: false,
158
158
  default: true,
159
159
  },
160
+ loading: {
161
+ type: Boolean,
162
+ required: false,
163
+ },
160
164
  },
161
165
  emits: [
162
166
  "onSearchOutside",