comand-component-library 3.1.53 → 3.1.54

Sign up to get free protection for your applications and to get access to all the features.
Files changed (141) hide show
  1. package/dist/comand-component-library.css +1 -1
  2. package/dist/comand-component-library.umd.min.js +1 -1
  3. package/package.json +1 -1
  4. package/src/App.vue +0 -55
  5. package/src/assets/data/breadcrumbs.json +2 -2
  6. package/src/components/CmdCookieDisclaimer.vue +63 -65
  7. package/src/index.js +0 -1
  8. package/src/router/index.js +0 -57
  9. package/src/ComponentDocumentation.vue +0 -156
  10. package/src/ComponentLibraryHelp.vue +0 -20
  11. package/src/components/CmdAccordion.vue +0 -253
  12. package/src/documentation/commonProps.js +0 -6
  13. package/src/documentation/components/ComponentCode.vue +0 -50
  14. package/src/documentation/components/ComponentProperties.vue +0 -237
  15. package/src/documentation/components/ExampleSectionWrapper.vue +0 -46
  16. package/src/documentation/components/ViewCodeData.vue +0 -113
  17. package/src/documentation/data/CmdAccordionHelp.js +0 -22
  18. package/src/documentation/data/CmdAddressDataHelp.js +0 -17
  19. package/src/documentation/data/CmdBackToTopButtonHelp.js +0 -3
  20. package/src/documentation/data/CmdBankAccountDataHelp.js +0 -8
  21. package/src/documentation/data/CmdBoxHelp.js +0 -45
  22. package/src/documentation/data/CmdBoxSiteSearchHelp.js +0 -11
  23. package/src/documentation/data/CmdBreadcrumbsHelp.js +0 -6
  24. package/src/documentation/data/CmdCompanyLogoHelp.js +0 -8
  25. package/src/documentation/data/CmdCookieDisclaimerHelp.js +0 -9
  26. package/src/documentation/data/CmdCopyrightInformation.js +0 -2
  27. package/src/documentation/data/CmdCustomHeadlineHelp.js +0 -8
  28. package/src/documentation/data/CmdFakeSelectHelp.js +0 -60
  29. package/src/documentation/data/CmdFancyBoxHelp.js +0 -7
  30. package/src/documentation/data/CmdFooterNavigationHelp.js +0 -5
  31. package/src/documentation/data/CmdFormElementHelp.js +0 -189
  32. package/src/documentation/data/CmdFormFiltersHelp.js +0 -6
  33. package/src/documentation/data/CmdFormHelp.js +0 -10
  34. package/src/documentation/data/CmdGoogleMapsHelp.js +0 -5
  35. package/src/documentation/data/CmdImageGalleryHelp.js +0 -5
  36. package/src/documentation/data/CmdImageZoomHelp.js +0 -6
  37. package/src/documentation/data/CmdListOfLinksHelp.js +0 -24
  38. package/src/documentation/data/CmdLoginFormHelp.js +0 -6
  39. package/src/documentation/data/CmdMainNavigationHelp.js +0 -7
  40. package/src/documentation/data/CmdMultistepFormProgressBarHelp.js +0 -6
  41. package/src/documentation/data/CmdOpeningHoursHelp.js +0 -10
  42. package/src/documentation/data/CmdPagerHelp.js +0 -7
  43. package/src/documentation/data/CmdProgressBarHelp.js +0 -13
  44. package/src/documentation/data/CmdShareButtonsHelp.js +0 -13
  45. package/src/documentation/data/CmdSiteHeaderHelp.js +0 -21
  46. package/src/documentation/data/CmdSlideButtonHelp.js +0 -10
  47. package/src/documentation/data/CmdSlideshowHelp.js +0 -7
  48. package/src/documentation/data/CmdSwitchLanguageHelp.js +0 -6
  49. package/src/documentation/data/CmdSystemMessageHelp.js +0 -32
  50. package/src/documentation/data/CmdTableHelp.js +0 -14
  51. package/src/documentation/data/CmdTabsHelp.js +0 -10
  52. package/src/documentation/data/CmdThumbnailScrollerHelp.js +0 -5
  53. package/src/documentation/data/CmdTooltipHelp.js +0 -13
  54. package/src/documentation/data/CmdUploadFormHelp.js +0 -17
  55. package/src/documentation/data/CmdWidthLimitationWrapperHelp.js +0 -7
  56. package/src/documentation/data/componentsDescription.json +0 -158
  57. package/src/documentation/generated/CmdAccordionPropertyDescriptions.json +0 -57
  58. package/src/documentation/generated/CmdAddressDataPropertyDescriptions.json +0 -32
  59. package/src/documentation/generated/CmdBackToTopButtonPropertyDescriptions.json +0 -12
  60. package/src/documentation/generated/CmdBankAccountDataPropertyDescriptions.json +0 -34
  61. package/src/documentation/generated/CmdBoxPropertyDescriptions.json +0 -91
  62. package/src/documentation/generated/CmdBoxSiteSearchPropertyDescriptions.json +0 -46
  63. package/src/documentation/generated/CmdBoxWrapperPropertyDescriptions.json +0 -47
  64. package/src/documentation/generated/CmdBreadcrumbsPropertyDescriptions.json +0 -17
  65. package/src/documentation/generated/CmdCompanyLogoPropertyDescriptions.json +0 -27
  66. package/src/documentation/generated/CmdCookieDisclaimerPropertyDescriptions.json +0 -22
  67. package/src/documentation/generated/CmdCustomHeadlinePropertyDescriptions.json +0 -22
  68. package/src/documentation/generated/CmdFakeSelectPropertyDescriptions.json +0 -84
  69. package/src/documentation/generated/CmdFancyBoxPropertyDescriptions.json +0 -62
  70. package/src/documentation/generated/CmdFooterNavigationPropertyDescriptions.json +0 -17
  71. package/src/documentation/generated/CmdFormElementPropertyDescriptions.json +0 -178
  72. package/src/documentation/generated/CmdFormFiltersPropertyDescriptions.json +0 -32
  73. package/src/documentation/generated/CmdFormPropertyDescriptions.json +0 -40
  74. package/src/documentation/generated/CmdGoogleMapsPropertyDescriptions.json +0 -7
  75. package/src/documentation/generated/CmdImageGalleryPropertyDescriptions.json +0 -22
  76. package/src/documentation/generated/CmdImageZoomPropertyDescriptions.json +0 -12
  77. package/src/documentation/generated/CmdListOfLinksPropertyDescriptions.json +0 -60
  78. package/src/documentation/generated/CmdLoginFormPropertyDescriptions.json +0 -90
  79. package/src/documentation/generated/CmdMainNavigationPropertyDescriptions.json +0 -62
  80. package/src/documentation/generated/CmdMultipleSwitchPropertyDescriptions.json +0 -52
  81. package/src/documentation/generated/CmdMultistepFormProgressBarPropertyDescriptions.json +0 -17
  82. package/src/documentation/generated/CmdOpeningHoursPropertyDescriptions.json +0 -42
  83. package/src/documentation/generated/CmdPagerPropertyDescriptions.json +0 -37
  84. package/src/documentation/generated/CmdProgressBarPropertyDescriptions.json +0 -32
  85. package/src/documentation/generated/CmdShareButtonsPropertyDescriptions.json +0 -34
  86. package/src/documentation/generated/CmdSiteHeaderPropertyDescriptions.json +0 -27
  87. package/src/documentation/generated/CmdSlideButtonPropertyDescriptions.json +0 -25
  88. package/src/documentation/generated/CmdSlideshowPropertyDescriptions.json +0 -42
  89. package/src/documentation/generated/CmdSwitchButtonPropertyDescriptions.json +0 -79
  90. package/src/documentation/generated/CmdSwitchLanguagePropertyDescriptions.json +0 -7
  91. package/src/documentation/generated/CmdSystemMessagePropertyDescriptions.json +0 -40
  92. package/src/documentation/generated/CmdTablePropertyDescriptions.json +0 -62
  93. package/src/documentation/generated/CmdTabsPropertyDescriptions.json +0 -27
  94. package/src/documentation/generated/CmdThumbnailScrollerPropertyDescriptions.json +0 -32
  95. package/src/documentation/generated/CmdTooltipPropertyDescriptions.json +0 -17
  96. package/src/documentation/generated/CmdUploadFormPropertyDescriptions.json +0 -90
  97. package/src/documentation/generated/CmdWidthLimitationWrapperPropertyDescriptions.json +0 -41
  98. package/src/documentation/generated/frameworkIcons.json +0 -730
  99. package/src/documentation/generated/logosIcons.json +0 -110
  100. package/src/documentation/tabs.js +0 -46
  101. package/src/documentation/views/ContainerPage.vue +0 -237
  102. package/src/documentation/views/HelpHome.vue +0 -13
  103. package/src/documentation/views/IconFont.vue +0 -80
  104. package/src/documentation/views/components/CmdAccordionHelp.vue +0 -78
  105. package/src/documentation/views/components/CmdAddressDataHelp.vue +0 -65
  106. package/src/documentation/views/components/CmdBackToTopButtonHelp.vue +0 -62
  107. package/src/documentation/views/components/CmdBankAccountDataHelp.vue +0 -88
  108. package/src/documentation/views/components/CmdBoxHelp.vue +0 -137
  109. package/src/documentation/views/components/CmdBoxSiteSearchHelp.vue +0 -60
  110. package/src/documentation/views/components/CmdBoxWrapperHelp.vue +0 -111
  111. package/src/documentation/views/components/CmdBreadcrumbsHelp.vue +0 -51
  112. package/src/documentation/views/components/CmdCompanyLogoHelp.vue +0 -48
  113. package/src/documentation/views/components/CmdCookieDisclaimerHelp.vue +0 -105
  114. package/src/documentation/views/components/CmdCustomHeadlineHelp.vue +0 -53
  115. package/src/documentation/views/components/CmdFakeSelectHelp.vue +0 -175
  116. package/src/documentation/views/components/CmdFancyBoxHelp.vue +0 -79
  117. package/src/documentation/views/components/CmdFormElementHelp.vue +0 -412
  118. package/src/documentation/views/components/CmdFormFiltersHelp.vue +0 -69
  119. package/src/documentation/views/components/CmdFormHelp.vue +0 -41
  120. package/src/documentation/views/components/CmdGoogleMapsHelp.vue +0 -55
  121. package/src/documentation/views/components/CmdImageGalleryHelp.vue +0 -46
  122. package/src/documentation/views/components/CmdImageZoomHelp.vue +0 -34
  123. package/src/documentation/views/components/CmdListOfLinksHelp.vue +0 -64
  124. package/src/documentation/views/components/CmdLoginFormHelp.vue +0 -117
  125. package/src/documentation/views/components/CmdMainNavigationHelp.vue +0 -94
  126. package/src/documentation/views/components/CmdMultistepFormProgressBarHelp.vue +0 -49
  127. package/src/documentation/views/components/CmdOpeningHoursHelp.vue +0 -49
  128. package/src/documentation/views/components/CmdPagerHelp.vue +0 -57
  129. package/src/documentation/views/components/CmdProgressBarHelp.vue +0 -47
  130. package/src/documentation/views/components/CmdShareButtonsHelp.vue +0 -65
  131. package/src/documentation/views/components/CmdSiteHeaderHelp.vue +0 -72
  132. package/src/documentation/views/components/CmdSlideButtonHelp.vue +0 -90
  133. package/src/documentation/views/components/CmdSlideshowHelp.vue +0 -60
  134. package/src/documentation/views/components/CmdSwitchLanguageHelp.vue +0 -64
  135. package/src/documentation/views/components/CmdSystemMessageHelp.vue +0 -86
  136. package/src/documentation/views/components/CmdTableHelp.vue +0 -84
  137. package/src/documentation/views/components/CmdTabsHelp.vue +0 -52
  138. package/src/documentation/views/components/CmdThumbnailScrollerHelp.vue +0 -50
  139. package/src/documentation/views/components/CmdTooltipHelp.vue +0 -59
  140. package/src/documentation/views/components/CmdUploadFormHelp.vue +0 -59
  141. package/src/documentation/views/components/CmdWidthLimitationWrapperHelp.vue +0 -46
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "comand-component-library",
3
- "version": "3.1.53",
3
+ "version": "3.1.54",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "serve": "vue-cli-service serve",
package/src/App.vue CHANGED
@@ -46,59 +46,6 @@
46
46
  </div>
47
47
  <hr/>
48
48
  </CmdWidthLimitationWrapper>
49
-
50
- <a id="section-accordion"></a>
51
- <CmdWidthLimitationWrapper>
52
- <h2 class="headline-demopage">Accordion</h2>
53
- <h3>Single mode (only one can be opened)</h3>
54
- <a href="#" @click.prevent="toggleAllAccordions()">Toggle all accordions</a>
55
- <CmdAccordion :accordionData="accordionData.accordionData1"
56
- toggleMode="single"
57
- tooltip="Click to toggle content"
58
- openIconClass="icon-single-arrow-up"
59
- closeIconClass="icon-single-arrow-down"
60
- ref="accordionGroup1"
61
- />
62
- <h3>Multiple mode (all can be opened)</h3>
63
- <CmdAccordion :accordionData="accordionData.accordionData2"
64
- toggleMode="multiple"
65
- tooltip="Click to toggle content"
66
- openIconClass="icon-single-arrow-up"
67
- closeIconClass="icon-single-arrow-down"
68
- ref="accordionGroup2"
69
- />
70
- <h3>Customized headline-level (without transition of content)</h3>
71
- <CmdAccordion :accordionData="accordionData.accordionData2"
72
- toggleMode="multiple"
73
- tooltip="Click to toggle content"
74
- openIconClass="icon-single-arrow-up"
75
- closeIconClass="icon-single-arrow-down"
76
- accordion-headline-level="h4"
77
- :use-transition="false"
78
- />
79
- <h3>Data given by slots</h3>
80
- <CmdAccordion :accordionData="1">
81
- <template v-slot:accordionHeadline0>
82
- <h3><span class="icon-user-group"></span><span>User groups</span></h3>
83
- </template>
84
- <template v-slot:accordionContent0>
85
- <p>
86
- Content
87
- </p>
88
- </template>
89
- </CmdAccordion>
90
- <CmdAccordion :accordionData="1" :useCustomHeader="true">
91
- <template v-slot:customHeadline0>
92
- <h4>Some headline</h4>
93
- </template>
94
- <template v-slot:accordionContent0>
95
- <p>
96
- Content
97
- </p>
98
- </template>
99
- </CmdAccordion>
100
- </CmdWidthLimitationWrapper>
101
-
102
49
  <!-- begin advanced form elements --------------------------------------------------------------------------------------------------------------------------------------------------->
103
50
  <a id="section-advanced-form-elements"></a>
104
51
  <CmdWidthLimitationWrapper>
@@ -1025,7 +972,6 @@ import thumbnailScrollerData from '@/assets/data/thumbnail-scroller.json'
1025
972
  import topHeaderNavigationData from '@/assets/data/list-of-links-top-header-navigation.json'
1026
973
 
1027
974
  // import used components
1028
- import CmdAccordion from "@/components/CmdAccordion.vue"
1029
975
  import CmdAddressData from "@/components/CmdAddressData"
1030
976
  import CmdBackToTopButton from "@/components/CmdBackToTopButton.vue"
1031
977
  import CmdBankAccountData from "./components/CmdBankAccountData"
@@ -1071,7 +1017,6 @@ import * as functions from "@/mixins/FieldValidation.js"
1071
1017
  export default {
1072
1018
  name: "App",
1073
1019
  components: {
1074
- CmdAccordion, // short form of 'CmdAccordion': CmdAccordion
1075
1020
  CmdAddressData,
1076
1021
  CmdBackToTopButton,
1077
1022
  CmdBankAccountData,
@@ -7,14 +7,14 @@
7
7
  },
8
8
  {
9
9
  "text": "Subpage",
10
- "type": "router",
10
+ "type": "href",
11
11
  "route": {
12
12
  "path": "/subpage"
13
13
  }
14
14
  },
15
15
  {
16
16
  "text": "Subsubpage",
17
- "type": "router",
17
+ "type": "href",
18
18
  "route": {
19
19
  "name": "subsubpage",
20
20
  "params": {
@@ -13,70 +13,70 @@
13
13
  <div v-if="cookieOptions.required">
14
14
  <h3>{{ cookieOptions.required.headline }}</h3>
15
15
 
16
- <!-- begin CmdAccordion -->
17
- <CmdAccordion :accordion-data="cookieOptions.required.cookies.length" :accordionData="2">
18
- <template v-for="(cookie, index) in cookieOptions.required.cookies"
19
- v-slot:[`accordionHeadline${index}`]
20
- :key="index">
21
- <!-- begin CmdSwitchButton -->
22
- <CmdSwitchButton
23
- type="checkbox"
24
- :id="cookie.id"
25
- :labelText="cookie.labelText"
26
- v-model="cookie.checked"
27
- :status="cookie.status"
28
- disabled="disabled"
29
- />
30
- <!-- end CmdSwitchButton -->
31
- </template>
32
- <template v-for="(cookie, index) in cookieOptions.required.cookies"
33
- v-slot:[`accordionContent${index}`]
34
- :key="index">
35
- <p v-if="cookie.description">{{ cookie.description }}</p>
36
- <p v-if="cookie.linkDataPrivacy">
37
- {{ cookie.linkDataPrivacy.label }}
38
- <a @click="openDataPrivacy"
39
- :href="cookie.linkDataPrivacy.link"
40
- :target="cookie.linkDataPrivacy.target">
41
- {{ cookie.linkDataPrivacy.linkText }}
42
- </a>
43
- </p>
44
- <div v-if="dataPrivacyContent" v-html="dataPrivacyContent"></div>
45
- </template>
46
- </CmdAccordion>
47
- <!-- end CmdAccordion -->
16
+ <!-- &lt;!&ndash; begin CmdAccordion &ndash;&gt;-->
17
+ <!-- <CmdAccordion :accordion-data="cookieOptions.required.cookies.length" :accordionData="2">-->
18
+ <!-- <template v-for="(cookie, index) in cookieOptions.required.cookies"-->
19
+ <!-- v-slot:[`accordionHeadline${index}`]-->
20
+ <!-- :key="index">-->
21
+ <!-- &lt;!&ndash; begin CmdSwitchButton &ndash;&gt;-->
22
+ <!-- <CmdSwitchButton-->
23
+ <!-- type="checkbox"-->
24
+ <!-- :id="cookie.id"-->
25
+ <!-- :labelText="cookie.labelText"-->
26
+ <!-- v-model="cookie.checked"-->
27
+ <!-- :status="cookie.status"-->
28
+ <!-- disabled="disabled"-->
29
+ <!-- />-->
30
+ <!-- &lt;!&ndash; end CmdSwitchButton &ndash;&gt;-->
31
+ <!-- </template>-->
32
+ <!-- <template v-for="(cookie, index) in cookieOptions.required.cookies"-->
33
+ <!-- v-slot:[`accordionContent${index}`]-->
34
+ <!-- :key="index">-->
35
+ <!-- <p v-if="cookie.description">{{ cookie.description }}</p>-->
36
+ <!-- <p v-if="cookie.linkDataPrivacy">-->
37
+ <!-- {{ cookie.linkDataPrivacy.label }}-->
38
+ <!-- <a @click="openDataPrivacy"-->
39
+ <!-- :href="cookie.linkDataPrivacy.link"-->
40
+ <!-- :target="cookie.linkDataPrivacy.target">-->
41
+ <!-- {{ cookie.linkDataPrivacy.linkText }}-->
42
+ <!-- </a>-->
43
+ <!-- </p>-->
44
+ <!-- <div v-if="dataPrivacyContent" v-html="dataPrivacyContent"></div>-->
45
+ <!-- </template>-->
46
+ <!-- </CmdAccordion>-->
47
+ <!-- &lt;!&ndash; end CmdAccordion &ndash;&gt;-->
48
48
  </div>
49
49
  <hr />
50
50
  <div v-if="cookieOptions.optional">
51
51
  <h3>{{ cookieOptions.optional.headline }}</h3>
52
- <!-- begin CmdAccordion -->
53
- <CmdAccordion :accordion-data="cookieOptions.optional.cookies.length" :accordionData="2">
54
- <template v-for="(cookie, index) in cookieOptions.optional.cookies"
55
- v-slot:[`accordionHeadline${index}`]
56
- :key="index">
57
- <!-- begin CmdSwitchButton -->
58
- <CmdSwitchButton
59
- type="checkbox"
60
- :id="cookie.id"
61
- :labelText="cookie.labelText"
62
- v-model="cookie.checked"
63
- :status="cookie.status"
64
- />
65
- <!-- end CmdSwitchButton -->
66
- </template>
67
- <template v-for="(cookie, index) in cookieOptions.optional.cookies"
68
- v-slot:[`accordionContent${index}`]
69
- :key="index">
70
- <p>{{ cookie.description }}</p>
71
- <p v-if="cookie.linkDataPrivacy">
72
- {{ cookie.linkDataPrivacy.label }}
73
- <a @click="openDataPrivacy" :href="cookie.linkDataPrivacy.link"
74
- :target="cookie.linkDataPrivacy.target">{{ cookie.linkDataPrivacy.linkText }}</a>
75
- </p>
76
- <div v-if="dataPrivacyContent" v-html="dataPrivacyContent"></div>
77
- </template>
78
- </CmdAccordion>
79
- <!-- end CmdAccordion -->
52
+ <!-- &lt;!&ndash; begin CmdAccordion &ndash;&gt;-->
53
+ <!-- <CmdAccordion :accordion-data="cookieOptions.optional.cookies.length" :accordionData="2">-->
54
+ <!-- <template v-for="(cookie, index) in cookieOptions.optional.cookies"-->
55
+ <!-- v-slot:[`accordionHeadline${index}`]-->
56
+ <!-- :key="index">-->
57
+ <!-- &lt;!&ndash; begin CmdSwitchButton &ndash;&gt;-->
58
+ <!-- <CmdSwitchButton-->
59
+ <!-- type="checkbox"-->
60
+ <!-- :id="cookie.id"-->
61
+ <!-- :labelText="cookie.labelText"-->
62
+ <!-- v-model="cookie.checked"-->
63
+ <!-- :status="cookie.status"-->
64
+ <!-- />-->
65
+ <!-- &lt;!&ndash; end CmdSwitchButton &ndash;&gt;-->
66
+ <!-- </template>-->
67
+ <!-- <template v-for="(cookie, index) in cookieOptions.optional.cookies"-->
68
+ <!-- v-slot:[`accordionContent${index}`]-->
69
+ <!-- :key="index">-->
70
+ <!-- <p>{{ cookie.description }}</p>-->
71
+ <!-- <p v-if="cookie.linkDataPrivacy">-->
72
+ <!-- {{ cookie.linkDataPrivacy.label }}-->
73
+ <!-- <a @click="openDataPrivacy" :href="cookie.linkDataPrivacy.link"-->
74
+ <!-- :target="cookie.linkDataPrivacy.target">{{ cookie.linkDataPrivacy.linkText }}</a>-->
75
+ <!-- </p>-->
76
+ <!-- <div v-if="dataPrivacyContent" v-html="dataPrivacyContent"></div>-->
77
+ <!-- </template>-->
78
+ <!-- </CmdAccordion>-->
79
+ <!-- &lt;!&ndash; end CmdAccordion &ndash;&gt;-->
80
80
  </div>
81
81
  </slot>
82
82
  <!-- end slot for cookie-options -->
@@ -101,16 +101,14 @@
101
101
 
102
102
  <script>
103
103
  // import components
104
- import CmdAccordion from "./CmdAccordion"
105
104
  import CmdCustomHeadline from "./CmdCustomHeadline"
106
- import CmdSwitchButton from "./CmdSwitchButton"
105
+ // import CmdSwitchButton from "./CmdSwitchButton"
107
106
 
108
107
  export default {
109
108
  name: "CmdCookieDisclaimer",
110
109
  components: {
111
- CmdAccordion,
112
- CmdCustomHeadline,
113
- CmdSwitchButton
110
+ CmdCustomHeadline
111
+ // CmdSwitchButton
114
112
  },
115
113
  data() {
116
114
  return {
package/src/index.js CHANGED
@@ -1,7 +1,6 @@
1
1
  import "clickout-event"
2
2
 
3
3
  // export components
4
- export { default as CmdAccordion } from '@/components/CmdAccordion'
5
4
  export { default as CmdAddressData } from '@/components/CmdAddressData'
6
5
  export { default as CmdBackToTopButton } from '@/components/CmdBackToTopButton'
7
6
  export { default as CmdBankAccountData } from '@/components/CmdBankAccountData'
@@ -1,67 +1,10 @@
1
1
  import { createRouter, createWebHistory } from "vue-router"
2
- import {routeHandler as tabsRouteHandler} from "../documentation/tabs"
3
- import ContainerPage from "../documentation/views/ContainerPage"
4
- import HelpHome from "../documentation/views/HelpHome"
5
- import IconFont from "../documentation/views/IconFont"
6
- import componentsDescription from "../documentation/data/componentsDescription"
7
- import ComponentDocumentation from "../ComponentDocumentation"
8
2
 
9
3
  const routes = []
10
4
 
11
- const componentNames = Object.keys(componentsDescription)
12
-
13
- routes.push({
14
- path: "/",
15
- name: "home",
16
- component: HelpHome
17
- })
18
-
19
- routes.push({
20
- path: "/subsubpage/:param1/:param2",
21
- name: "subsubpage",
22
- redirect: {
23
- name: componentNames[0]
24
- }
25
- })
26
-
27
- const componentsRoute = {
28
- path: "/components",
29
- name: "components",
30
- component: ComponentDocumentation,
31
- redirect: {
32
- name: componentNames[0]
33
- },
34
- children: []
35
- }
36
-
37
- for(let i = 0 ; i < componentNames.length ; i++) {
38
- componentsRoute.children.push(
39
- {
40
- path: componentNames[i] + "/:tab?",
41
- name: componentNames[i],
42
- component: ContainerPage,
43
- props: () => ({
44
- componentName: componentNames[i],
45
- previousComponentName: i === 0 ? componentNames[componentNames.length - 1] : componentNames[i - 1],
46
- nextComponentName: i === componentNames.length - 1 ? componentNames[0] : componentNames[i + 1]
47
- })
48
- }
49
- )
50
- }
51
-
52
- routes.push(componentsRoute)
53
-
54
- routes.push({
55
- path: "/iconfont",
56
- name: "iconfont",
57
- component: IconFont
58
- })
59
-
60
5
  const router = createRouter({
61
6
  history: createWebHistory(process.env.BASE_URL),
62
7
  routes
63
8
  })
64
9
 
65
- router.beforeEach(tabsRouteHandler)
66
-
67
10
  export default router
@@ -1,156 +0,0 @@
1
- <template>
2
- <div id="component-documentation">
3
- <div v-if="!isFrameMode()" class="nav-wrapper">
4
- <CmdFormElement
5
- element="input"
6
- type="search"
7
- id="component-search"
8
- labelText="Search components"
9
- placeholder="Search components"
10
- :showLabel="false"
11
- :showSearchButton="false"
12
- fieldIconClass="icon-search"
13
- v-model="filterComponents"
14
- />
15
- <CmdSystemMessage
16
- v-if="!componentNames.length"
17
- validationStatus="warning"
18
- :systemMessage="'Cannot find component name including &quot;' + filterComponents + '&quot;'"
19
- />
20
- <nav class="flex-container">
21
- <template v-for="startingLetter in startingLetters" :key="startingLetter">
22
- <h4>{{ startingLetter }}</h4>
23
- <ul>
24
- <li v-for="componentName in componentNamesWithStartingLetter(startingLetter)" :key="componentName">
25
- <router-link :to="{name: componentName}">{{ componentNameText(componentName) }}</router-link>
26
- </li>
27
- </ul>
28
- </template>
29
- </nav>
30
- </div>
31
- <router-view></router-view>
32
- <CmdBackToTopButton/>
33
- </div>
34
- </template>
35
-
36
- <script>
37
- // import functions
38
- import {isFrameMode} from "./utils/common"
39
-
40
- // import components
41
- import CmdBackToTopButton from "./components/CmdBackToTopButton"
42
- import CmdFormElement from "./components/CmdFormElement"
43
- import CmdSystemMessage from "./components/CmdSystemMessage"
44
-
45
- // import list of components
46
- import componentsDescription from "./documentation/data/componentsDescription.json"
47
-
48
- export default {
49
- components: {
50
- CmdBackToTopButton,
51
- CmdFormElement,
52
- CmdSystemMessage
53
- },
54
- data() {
55
- return {
56
- filterComponents: ""
57
- }
58
- },
59
- computed: {
60
- componentNames() {
61
- const filterTerm = this.filterComponents.trim().toLowerCase()
62
-
63
- if(filterTerm) {
64
- return Object.keys(componentsDescription).filter((componentName) => {
65
- return componentName.toLowerCase().includes(filterTerm)
66
- })
67
- }
68
- return Object.keys(componentsDescription)
69
- },
70
- startingLetters() {
71
- const startingLetters = []
72
- for (let i = 0; i < this.componentNames.length; i++) {
73
- const componentStartingLetter = this.getComponentStartingLetter(this.componentNames[i])
74
- if (!startingLetters.includes(componentStartingLetter)) {
75
- startingLetters.push(componentStartingLetter)
76
- }
77
- }
78
- return startingLetters.sort()
79
- }
80
- },
81
- methods: {
82
- isFrameMode() {
83
- return isFrameMode()
84
- },
85
- componentNameText(componentName) {
86
- return componentName.replace("Cmd", "")
87
- },
88
- componentNamesWithStartingLetter(startingLetter) {
89
- const components = []
90
- for (let i = 0; i < this.componentNames.length; i++) {
91
- const componentStartingLetter = this.getComponentStartingLetter(this.componentNames[i])
92
-
93
- if (startingLetter === componentStartingLetter) {
94
- components.push(this.componentNames[i])
95
- }
96
- }
97
- return components.sort()
98
- },
99
- getComponentStartingLetter(componentName) {
100
- return this.componentNameText(componentName).slice(0, 1)
101
- }
102
- }
103
- }
104
- </script>
105
-
106
- <style lang="scss">
107
- #responsive-view {
108
- resize: vertical;
109
- }
110
-
111
- #component-documentation {
112
- display: flex;
113
-
114
- .nav-wrapper {
115
- background: var(--default-background-color);
116
- flex: none;
117
- border-right: var(--default-border);
118
- box-shadow: .2rem 0 .4rem #999;
119
- max-width: 20rem;
120
-
121
- nav {
122
- width: auto;
123
- flex-direction: column;
124
- gap: 0;
125
- padding: var(--default-padding) 0;
126
-
127
- h4 {
128
- padding-left: var(--default-padding);
129
- margin-bottom: 0;
130
- }
131
-
132
- ul {
133
- flex-direction: column;
134
- border: 0;
135
- background: none;
136
- border-top: var(--border-color);
137
-
138
- li {
139
- border: 0;
140
- border-bottom: var(--default-border);
141
-
142
- a.router-link-active {
143
- background: var(--primary-color);
144
- color: var(--pure-white);
145
- }
146
- }
147
- }
148
- }
149
- }
150
-
151
- main {
152
- width: 100%;
153
- padding: calc(var(--default-padding) * 2);
154
- }
155
- }
156
- </style>
@@ -1,20 +0,0 @@
1
- <template>
2
- <header>
3
- <router-link :to="{ name: 'home'}">Home</router-link>
4
- <router-link :to="{ name: 'components'}">Components</router-link>
5
- <router-link :to="{ name: 'iconfont'}">Iconfont</router-link>
6
- </header>
7
- <div>
8
- <router-view></router-view>
9
- </div>
10
- </template>
11
-
12
- <script>
13
- export default {
14
- name: "ComponentLibraryHelp"
15
- }
16
- </script>
17
-
18
- <style>
19
-
20
- </style>