comand-component-library 4.0.67 → 4.0.68
Sign up to get free protection for your applications and to get access to all the features.
package/package.json
CHANGED
package/src/ComponentLibrary.vue
CHANGED
@@ -1297,8 +1297,8 @@
|
|
1297
1297
|
contentOrientation="horizontal"
|
1298
1298
|
innerClass="inner-class"
|
1299
1299
|
>
|
1300
|
-
<
|
1301
|
-
<
|
1300
|
+
<component :is="componentNameForContainer" headlineText="Headline 1" headlineLevel="6" />
|
1301
|
+
<component :is="componentNameForContainer" headlineText="Headline 2" headlineLevel="6" />
|
1302
1302
|
</CmdContainer>
|
1303
1303
|
</CmdWidthLimitationWrapper>
|
1304
1304
|
<!-- end container ------------------------------------------------------------------------------------------------------------------------------------------------------->
|
@@ -1517,6 +1517,15 @@
|
|
1517
1517
|
:fancybox="true"
|
1518
1518
|
:icon="{iconClass: 'icon-chevron-one-stripe-right', position: 'right', tooltip: 'Tooltip for hyperlink'}"
|
1519
1519
|
/>
|
1520
|
+
<button @click="showCmdLink = true"><span>Add link</span></button>
|
1521
|
+
<CmdLink
|
1522
|
+
v-if="showCmdLink"
|
1523
|
+
path="#"
|
1524
|
+
linkType="href"
|
1525
|
+
text="Link added on click"
|
1526
|
+
:fancybox="true"
|
1527
|
+
:icon="{iconClass: 'icon-chevron-one-stripe-right', position: 'right', tooltip: 'Tooltip for hyperlink'}"
|
1528
|
+
/>
|
1520
1529
|
</CmdWidthLimitationWrapper>
|
1521
1530
|
<!-- end link ------------------------------------------------------------------------------------------------------------------------------------------------------->
|
1522
1531
|
|
@@ -2106,14 +2115,17 @@ import {localizedTime} from "./components/CmdOpeningHours.vue"
|
|
2106
2115
|
// import data and controls for settings
|
2107
2116
|
import componentSettingsDataAndControls from "@/componentSettingsDataAndControls.vue"
|
2108
2117
|
|
2118
|
+
import CmdHeadline from "./components/CmdHeadline.vue"
|
2109
2119
|
export default {
|
2110
2120
|
name: "App",
|
2111
2121
|
mixins: [componentSettingsDataAndControls],
|
2112
2122
|
components: {
|
2113
|
-
PageOverview
|
2123
|
+
PageOverview,
|
2124
|
+
CmdHeadline
|
2114
2125
|
},
|
2115
2126
|
data() {
|
2116
2127
|
return {
|
2128
|
+
componentNameForContainer: "CmdHeadline",
|
2117
2129
|
listOfComponents,
|
2118
2130
|
activeEntry: "CmdAddressData",
|
2119
2131
|
basicFormData: {},
|
@@ -2174,6 +2186,7 @@ export default {
|
|
2174
2186
|
accordionGroupOpen: false,
|
2175
2187
|
showPageMultistep: 1,
|
2176
2188
|
showPagePager: 1,
|
2189
|
+
showCmdLink: false,
|
2177
2190
|
selectedOption: "",
|
2178
2191
|
selectedOptions: [],
|
2179
2192
|
selectedCountry: "de",
|
@@ -100,18 +100,19 @@ export default {
|
|
100
100
|
}
|
101
101
|
|
102
102
|
const vnodes = this.$slots.default()
|
103
|
+
|
103
104
|
if (vnodes.length === 1 && typeof vnodes[0].type === "symbol" && Array.isArray(vnodes[0].children)) {
|
104
105
|
return vnodes[0].children.length === 1
|
105
106
|
}
|
107
|
+
if (vnodes.length === 1 && typeof vnodes[0].type === "object" && vnodes[0].type.name === "RenderComponents" && typeof vnodes[0].props === "object" && Array.isArray(vnodes[0].props.components)) {
|
108
|
+
return vnodes[0].props.components.length === 1
|
109
|
+
}
|
106
110
|
return vnodes.length === 1
|
107
111
|
}
|
108
112
|
},
|
109
113
|
computed: {
|
110
|
-
containerClass() {
|
111
|
-
|
112
|
-
},
|
113
114
|
setInnerClass() {
|
114
|
-
let htmlClass = this.innerClass
|
115
|
+
let htmlClass = this.innerClass || ""
|
115
116
|
switch (this.containerType) {
|
116
117
|
case "grid":
|
117
118
|
htmlClass += " grid-container-create-columns"
|
@@ -11,7 +11,7 @@ function addClickHandlerToFancyboxLinks(fancyboxLinks) {
|
|
11
11
|
export default {
|
12
12
|
// el = real dom-element
|
13
13
|
mounted(el) {
|
14
|
-
// get
|
14
|
+
// get initially loaded elements
|
15
15
|
const fancyboxLinks = el.querySelectorAll(".fancybox")
|
16
16
|
addClickHandlerToFancyboxLinks(fancyboxLinks)
|
17
17
|
|
@@ -36,7 +36,6 @@ export default {
|
|
36
36
|
}
|
37
37
|
}
|
38
38
|
}
|
39
|
-
|
40
39
|
addClickHandlerToFancyboxLinks(targetElements)
|
41
40
|
})
|
42
41
|
|