aloha-vue 1.0.207 → 1.0.209
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
|
@@ -13,7 +13,7 @@ import ASafeHtml from "../directives/ASafeHtml";
|
|
|
13
13
|
|
|
14
14
|
import {
|
|
15
15
|
cloneDeep,
|
|
16
|
-
get,
|
|
16
|
+
get, isUndefined,
|
|
17
17
|
} from "lodash-es";
|
|
18
18
|
|
|
19
19
|
export default {
|
|
@@ -167,19 +167,30 @@ export default {
|
|
|
167
167
|
}
|
|
168
168
|
},
|
|
169
169
|
|
|
170
|
+
readonlyLocal() {
|
|
171
|
+
return this.readonly || this.item.readonly;
|
|
172
|
+
},
|
|
173
|
+
|
|
174
|
+
isCaretLocal() {
|
|
175
|
+
if (!isUndefined(this.item.isCaret)) {
|
|
176
|
+
return this.item.isCaret;
|
|
177
|
+
}
|
|
178
|
+
return this.isCaret;
|
|
179
|
+
},
|
|
180
|
+
|
|
170
181
|
buttonTag() {
|
|
171
|
-
return this.
|
|
182
|
+
return this.readonlyLocal ? "div" : "button";
|
|
172
183
|
},
|
|
173
184
|
|
|
174
185
|
buttonAttributes() {
|
|
175
186
|
const ATTRIBUTES = {
|
|
176
187
|
class: ["a_accordion__button", this.classButton, {
|
|
177
188
|
a_accordion__button_collapsed: !this.isOpen,
|
|
178
|
-
a_accordion__button_has_not_caret: !this.
|
|
189
|
+
a_accordion__button_has_not_caret: !this.isCaretLocal,
|
|
179
190
|
}],
|
|
180
191
|
};
|
|
181
192
|
|
|
182
|
-
if (!this.
|
|
193
|
+
if (!this.readonlyLocal) {
|
|
183
194
|
ATTRIBUTES.ariaExpanded = this.isOpen;
|
|
184
195
|
ATTRIBUTES["aria-controls"] = this.idForCollapse;
|
|
185
196
|
ATTRIBUTES.type = "button";
|
|
@@ -64,10 +64,15 @@ export default {
|
|
|
64
64
|
]);
|
|
65
65
|
}
|
|
66
66
|
if (this.type === "link") {
|
|
67
|
-
|
|
67
|
+
const LINK_TAG = this.action.to ?
|
|
68
|
+
resolveComponent("RouterLink") :
|
|
69
|
+
"a";
|
|
70
|
+
|
|
71
|
+
return h(LINK_TAG, {
|
|
68
72
|
id: this.action.id,
|
|
69
73
|
class: ["a_table__action", this.action.class],
|
|
70
74
|
to: this.action.to,
|
|
75
|
+
href: this.action.href,
|
|
71
76
|
disabled: this.action.disabled,
|
|
72
77
|
}, () => [
|
|
73
78
|
this.action.title && h("span", {
|
|
@@ -182,7 +182,10 @@ export default {
|
|
|
182
182
|
h("div", {
|
|
183
183
|
class: "a_table__top_panel__actions",
|
|
184
184
|
}, [
|
|
185
|
-
this.$slots.
|
|
185
|
+
this.$slots.tableActionsStart && this.$slots.tableActionsStart({
|
|
186
|
+
isMultipleActionsActive: this.isMultipleActionsActive,
|
|
187
|
+
modelView: this.modelView,
|
|
188
|
+
}),
|
|
186
189
|
this.tableActionFiltered.map(action => {
|
|
187
190
|
return h(ATableActionItem, {
|
|
188
191
|
action,
|
|
@@ -279,6 +282,10 @@ export default {
|
|
|
279
282
|
}),
|
|
280
283
|
]),
|
|
281
284
|
]),
|
|
285
|
+
this.$slots.tableActionsEnd && this.$slots.tableActionsEnd({
|
|
286
|
+
isMultipleActionsActive: this.isMultipleActionsActive,
|
|
287
|
+
modelView: this.modelView,
|
|
288
|
+
}),
|
|
282
289
|
h("div", {
|
|
283
290
|
class: "a_table__multiple_panel__actions",
|
|
284
291
|
}, [
|