@itfin/components 1.0.86 → 1.0.87
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
|
@@ -92,6 +92,9 @@ class itfApp extends Vue {
|
|
|
92
92
|
}
|
|
93
93
|
|
|
94
94
|
showSuccess(message, title = '') {
|
|
95
|
+
if (typeof document === 'undefined') {
|
|
96
|
+
return;
|
|
97
|
+
}
|
|
95
98
|
return Message.success({
|
|
96
99
|
isCollapsed: false,
|
|
97
100
|
showClose: true,
|
|
@@ -104,6 +107,9 @@ class itfApp extends Vue {
|
|
|
104
107
|
}
|
|
105
108
|
|
|
106
109
|
showError(message, opts = {}) {
|
|
110
|
+
if (typeof document === 'undefined') {
|
|
111
|
+
return;
|
|
112
|
+
}
|
|
107
113
|
return Message.error({
|
|
108
114
|
isCollapsed: false,
|
|
109
115
|
showClose: true,
|
|
@@ -116,6 +122,9 @@ class itfApp extends Vue {
|
|
|
116
122
|
}
|
|
117
123
|
|
|
118
124
|
showMessage(options) {
|
|
125
|
+
if (typeof document === 'undefined') {
|
|
126
|
+
return;
|
|
127
|
+
}
|
|
119
128
|
return Message.toast({
|
|
120
129
|
isCollapsed: false,
|
|
121
130
|
showClose: true,
|
|
@@ -90,9 +90,13 @@ class itfForm extends Vue {
|
|
|
90
90
|
}
|
|
91
91
|
|
|
92
92
|
doValidation(showError = true) {
|
|
93
|
+
const invalidComponents = this.components.filter(
|
|
94
|
+
(component) => (component.doValidation && !component.doValidation(true)) || (component.validate && !component.validate(true))
|
|
95
|
+
);
|
|
93
96
|
// @todo remove validate when migrate from vuetify
|
|
94
|
-
const isValid = !
|
|
97
|
+
const isValid = !invalidComponents.length;
|
|
95
98
|
if (showError && !isValid && this.$showError) {
|
|
99
|
+
console.debug('Invalid', invalidComponents);
|
|
96
100
|
this.$showError('Please fix the errors below to proceed.', { duration: 3000 });
|
|
97
101
|
}
|
|
98
102
|
return isValid;
|
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
@click="!row.summary && $emit('row-click', { row, index: r })">
|
|
45
45
|
<div
|
|
46
46
|
class="itf-table__cell"
|
|
47
|
-
:class="{'itf-table__cell--sorted': sortedColumns[column.name]}"
|
|
47
|
+
:class="{'itf-table__cell--sorted': sortedColumns[column.name], 'align-left': column.alignLeft}"
|
|
48
48
|
v-for="(column, k) in columns" :key="`${r}-${k}`">
|
|
49
49
|
<span>
|
|
50
50
|
<slot v-if="$scopedSlots[`column.${column.name}${row.summary ? '.summary' : ''}`]" :name="`column.${column.name}${row.summary ? '.summary' : ''}`" :item="row" :column="column">
|
|
@@ -223,7 +223,7 @@ html {
|
|
|
223
223
|
text-align: right;
|
|
224
224
|
word-break: break-word;
|
|
225
225
|
|
|
226
|
-
&:first-child {
|
|
226
|
+
&:first-child, &.align-left {
|
|
227
227
|
justify-content: flex-start;
|
|
228
228
|
text-align: left;
|
|
229
229
|
}
|