comand-component-library 4.2.76 → 4.2.78
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/comand-component-library.js +2596 -2525
- package/package.json +2 -2
- package/src/ComponentLibrary.vue +3 -2
- package/src/componentSettingsDataAndControls.vue +988 -960
- package/src/components/CmdHeadline.vue +12 -5
- package/src/components/CmdSiteHeader.vue +1 -1
- package/src/components/CmdSystemMessage.vue +27 -4
|
@@ -2,15 +2,15 @@
|
|
|
2
2
|
<!-- begin CmdHeadline ---------------------------------------------------------------------------------------- -->
|
|
3
3
|
<!-- begin default-view -->
|
|
4
4
|
<div v-if="!editModeContext || settingsContext || mainSidebarContext || headlineText"
|
|
5
|
-
:class="['cmd-headline', {'has-pre-headline-text': preHeadlineText, 'has-icon': cmdIcon?.iconClass}
|
|
5
|
+
:class="['cmd-headline', {'has-pre-headline-text': preHeadlineText, 'has-icon': cmdIcon?.iconClass}]">
|
|
6
6
|
<!-- begin headline with pre-headline-text -->
|
|
7
7
|
<template v-if="preHeadlineText">
|
|
8
|
-
<component v-if="headlineText" :is="headlineTag" :class="highlightLevel">
|
|
8
|
+
<component v-if="headlineText" :is="headlineTag" :class="[highlightLevel, headlineTextAlign]">
|
|
9
9
|
<!-- begin CmdIcon -->
|
|
10
10
|
<CmdIcon v-if="cmdIcon" v-bind="cmdIcon"/>
|
|
11
11
|
<!-- end CmdIcon -->
|
|
12
12
|
|
|
13
|
-
<span class="pre-headline-text-wrapper">
|
|
13
|
+
<span :class="['pre-headline-text-wrapper', 'text-align-' + textAlign]">
|
|
14
14
|
<!-- begin pre-headline-text -->
|
|
15
15
|
<span class="pre-headline-text" v-html="preHeadlineText"></span>
|
|
16
16
|
<!-- end pre-headline-text -->
|
|
@@ -178,7 +178,7 @@ export default {
|
|
|
178
178
|
*/
|
|
179
179
|
textAlign: {
|
|
180
180
|
type: String,
|
|
181
|
-
default:
|
|
181
|
+
default: "left",
|
|
182
182
|
validator(value) {
|
|
183
183
|
return value === "left" ||
|
|
184
184
|
value === "center" ||
|
|
@@ -208,7 +208,14 @@ export default {
|
|
|
208
208
|
},
|
|
209
209
|
headlineTextAlign() {
|
|
210
210
|
if (this.textAlign) {
|
|
211
|
-
|
|
211
|
+
switch (this.textAlign) {
|
|
212
|
+
case "right":
|
|
213
|
+
return "justify-content-flex-end"
|
|
214
|
+
case "center":
|
|
215
|
+
return "justify-content-center"
|
|
216
|
+
default:
|
|
217
|
+
return "justify-content-flex-start"
|
|
218
|
+
}
|
|
212
219
|
}
|
|
213
220
|
return ""
|
|
214
221
|
}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
<transition :name="transition">
|
|
4
4
|
<div
|
|
5
5
|
v-if="showSystemMessage"
|
|
6
|
-
:class="['cmd-system-message', 'system-message', 'flex-container', 'vertical', { 'full-width': fullWidth }, validationStatus]"
|
|
6
|
+
:class="['cmd-system-message', 'system-message', 'flex-container', 'vertical', { 'full-width': fullWidth }, 'text-align-' + textAlign, validationStatus]"
|
|
7
7
|
:role="validationStatus === 'error' ? 'alert' : 'dialog'"
|
|
8
8
|
:aria-labelledby="htmlId"
|
|
9
9
|
>
|
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
:cmdIcon="headlineIcon"
|
|
16
16
|
:headlineText="systemMessage"
|
|
17
17
|
:headlineLevel="messageHeadlineLevel"
|
|
18
|
+
:textAlign="textAlign"
|
|
18
19
|
:id="htmlId"
|
|
19
20
|
/>
|
|
20
21
|
<!-- end CmdHeadline -->
|
|
@@ -48,10 +49,32 @@ export default {
|
|
|
48
49
|
mixins: [Identifier],
|
|
49
50
|
data() {
|
|
50
51
|
return {
|
|
51
|
-
showSystemMessage: true
|
|
52
|
+
showSystemMessage: true,
|
|
53
|
+
id: this.ariaReferenceId || this.buildHtmlId("system-message") // mixin requires id to be defined
|
|
52
54
|
}
|
|
53
55
|
},
|
|
54
|
-
props:
|
|
56
|
+
props: {
|
|
57
|
+
/**
|
|
58
|
+
* define the text-align for the system message (will be inherited to CmdHeadline in slot)
|
|
59
|
+
*
|
|
60
|
+
* @allowedValues: "left", "center", "right"
|
|
61
|
+
*/
|
|
62
|
+
textAlign: {
|
|
63
|
+
type: String,
|
|
64
|
+
default: "center",
|
|
65
|
+
validator(value) {
|
|
66
|
+
return value === "left" ||
|
|
67
|
+
value === "center" ||
|
|
68
|
+
value === "right"
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
/**
|
|
72
|
+
* define the aria-reference-id for the system message (will be used as aria-labelledby)
|
|
73
|
+
*/
|
|
74
|
+
ariaReferenceId: {
|
|
75
|
+
type: String,
|
|
76
|
+
required: false
|
|
77
|
+
},
|
|
55
78
|
/**
|
|
56
79
|
* define the transition when system message disappears
|
|
57
80
|
*
|
|
@@ -78,7 +101,7 @@ export default {
|
|
|
78
101
|
}
|
|
79
102
|
},
|
|
80
103
|
/**
|
|
81
|
-
* activate to stretch message-box as wide as parent container (else message-box is as wide as message (+padding))
|
|
104
|
+
* activate to stretch message-box as wide as parent container (else message-box is as wide as message (+ padding))
|
|
82
105
|
*/
|
|
83
106
|
fullWidth: {
|
|
84
107
|
type: Boolean,
|