comand-component-library 3.1.68 → 3.1.69

Sign up to get free protection for your applications and to get access to all the features.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "comand-component-library",
3
- "version": "3.1.68",
3
+ "version": "3.1.69",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "serve": "vue-cli-service serve",
@@ -18,7 +18,7 @@
18
18
  ],
19
19
  "dependencies": {
20
20
  "clickout-event": "^1.1.2",
21
- "comand-frontend-framework": "^3.2.48",
21
+ "comand-frontend-framework": "^3.2.53",
22
22
  "core-js": "^3.20.1",
23
23
  "prismjs": "^1.27.0",
24
24
  "vue": "^3.2.31",
package/src/App.vue CHANGED
@@ -2,6 +2,13 @@
2
2
  <template>
3
3
  <a id="anchor-back-to-top"></a>
4
4
  <CmdSiteHeader :cmdMainNavigation="navigationData" :sticky="true">
5
+ <template v-slot:top-header>
6
+ <CmdListOfLinks
7
+ :links="listOfLinksData"
8
+ orientation="horizontal"
9
+ align="right"
10
+ />
11
+ </template>
5
12
  <template v-slot:logo>
6
13
  <CmdCompanyLogo :link="companyLogoData.link"
7
14
  altText="CoManD Logo"
@@ -77,6 +84,7 @@
77
84
  <fieldset class="grid-container-create-columns">
78
85
  <legend>Legend</legend>
79
86
  <h2>Form Element-Component</h2>
87
+ <CmdToggleDarkMode :showLabel="true" />
80
88
  <div class="flex-container">
81
89
  <CmdFormElement labelText="Input (type text):"
82
90
  element="input"
@@ -102,6 +110,23 @@
102
110
  tooltipText="This is a tooltip"
103
111
  />
104
112
  </div>
113
+ <CmdFormElement labelText="Input (type search (without search-button)):"
114
+ element="input"
115
+ type="search"
116
+ :status="formElementStatus"
117
+ :showSearchButton="false"
118
+ placeholder="Search"
119
+ tooltipText="This is a tooltip"
120
+ v-bind="{useCustomTooltip: false}"
121
+ />
122
+ <CmdFormElement labelText="Input (type search (with search-button)):"
123
+ element="input"
124
+ type="search"
125
+ :status="formElementStatus"
126
+ placeholder="Search"
127
+ tooltipText="This is a tooltip"
128
+ v-bind="{useCustomTooltip: false}"
129
+ />
105
130
  <h2>Fake Selects</h2>
106
131
  <div class="flex-container">
107
132
  <!-- type === default: normal selectbox (with optional icons) -->
@@ -178,111 +203,59 @@
178
203
  <label for="range-slider" :class="formElementStatus">
179
204
  <span>Single-Slider (with in- and output):</span>
180
205
  <span class="flex-container no-flex">
181
- <input type="number" :class="formElementStatus" v-model="rangeValue"
182
- :disabled="formElementStatus === 'disabled'" min="0" max="100"/>
183
- <input type="range"
184
- class="range-slider"
185
- :class="{'disabled': formElementStatus === 'disabled'}"
186
- id="range-slider"
187
- v-model="rangeValue"
188
- :disabled="formElementStatus === 'disabled'"
189
- min="0"
190
- max="100"/>
206
+ <input
207
+ type="number"
208
+ :class="formElementStatus"
209
+ v-model="rangeValue"
210
+ :disabled="formElementStatus === 'disabled'"
211
+ min="0"
212
+ max="100"
213
+ />
214
+ <input
215
+ type="range"
216
+ class="range-slider"
217
+ :class="{'disabled': formElementStatus === 'disabled'}"
218
+ id="range-slider"
219
+ v-model="rangeValue"
220
+ :disabled="formElementStatus === 'disabled'"
221
+ min="0"
222
+ max="100"
223
+ />
191
224
  </span>
192
225
  </label>
193
226
  <!-- end slider -->
194
227
 
195
228
  <hr/>
196
229
 
197
- <!-- begin toggle-switch-radio with switch-label -->
198
- <h2>Toggle-Switches (Radio and Checkbox) with Switch-Label</h2>
199
- <div class="label inline">
200
- <span>Label for Toggle-Switch-Checkbox with Switch-Label:</span>
201
- <span class="flex-container no-flex">
202
- <CmdSwitchButton
203
- type="checkbox"
204
- id="checkbox1"
205
- name="checkbox1"
206
- onLabel="Label on"
207
- offLabel="Label off"
208
- inputValue="checkbox1"
209
- :disabled="formElementStatus === 'disabled'"
210
- v-model="switchButtonCheckbox"/>
211
- <CmdSwitchButton
212
- type="checkbox"
213
- id="checkbox2"
214
- name="checkbox2"
215
- onLabel="Label on"
216
- offLabel="Label off"
217
- labelText="Labeltext"
218
- inputValue="checkbox2"
219
- :disabled="formElementStatus === 'disabled'"
220
- v-model="switchButtonCheckbox"/>
221
- <CmdSwitchButton
222
- type="checkbox"
223
- id="checkbox3"
224
- name="checkbox3"
225
- inputValue="checkbox3"
226
- labelText="Labeltext"
227
- :disabled="formElementStatus === 'disabled'"
228
- v-model="switchButtonCheckbox"/>
229
- </span>
230
- <span>Current value: {{ switchButtonCheckbox }}</span>
231
- </div>
232
- <!-- end toggle-switch-radio with switch-label -->
233
-
234
- <div class="label inline">
235
- <span>Label for Toggle-Switch-Checkbox with Switch-Label (colored):</span>
236
- <span class="flex-container no-flex">
237
- <CmdSwitchButton
238
- type="checkbox"
239
- id="checkbox4"
240
- name="checkbox4"
241
- onLabel="Label on"
242
- offLabel="Label off"
243
- :colored="true"
244
- inputValue="checkbox3"
245
- :disabled="formElementStatus === 'disabled'"
246
- v-model="switchButtonCheckboxColored"/>
247
- </span>
248
- <span>Current value: {{ switchButtonCheckboxColored }}</span>
249
- </div>
250
- <!-- end toggle-switch-radio with switch-label -->
230
+ <h2>Group of checkboxes with CmdInputGroup</h2>
231
+ <CmdInputGroup label-text="Group-label:" :label-inline="true">
232
+ <CmdFormElement
233
+ element="input"
234
+ type="checkbox"
235
+ id="input-group-checkbox"
236
+ labelText="Checkbox-label #1"
237
+ />
238
+ <CmdFormElement
239
+ element="input"
240
+ type="checkbox"
241
+ id="input-group-checkbox"
242
+ labelText="Checkbox-label #2"
243
+ />
244
+ <CmdFormElement
245
+ element="input"
246
+ type="checkbox"
247
+ id="input-group-checkbox"
248
+ labelText="Checkbox-label #3"
249
+ />
250
+ </CmdInputGroup>
251
251
 
252
252
  <!-- begin toggle-switch-radio with switch-label (colored) -->
253
- <div class="label inline">
254
- <span>Label for Toggle-Switch-Radio with Switch-Label (colored):</span>
255
- <span class="flex-container no-flex">
256
- <CmdSwitchButton
257
- type="radio"
258
- id="radio1"
259
- name="radiogroup"
260
- onLabel="Label on"
261
- offLabel="Label off"
262
- :colored="true"
263
- inputValue="radio1"
264
- :disabled="formElementStatus === 'disabled'"
265
- v-model="switchButtonRadio"/>
266
- <CmdSwitchButton
267
- type="radio"
268
- id="radio2"
269
- name="radiogroup"
270
- onLabel="Label on"
271
- offLabel="Label off"
272
- :colored="true"
273
- inputValue="radio2"
274
- :disabled="formElementStatus === 'disabled'"
275
- v-model="switchButtonRadio"/>
276
- </span>
277
- </div>
278
- <hr />
279
- <h3>Toggle Switches with CmdFormElement</h3>
253
+ <h2>Toggle Switches with CmdFormElement</h2>
280
254
  <CmdFormElement element="input"
281
255
  type="checkbox"
282
256
  id="toggle-switch-checkbox"
283
257
  v-model="switchButtonCheckbox"
284
- :displayLabelInline="true"
285
- labelText="Labeltext for Single-SwitchButton (Checkbox)"
258
+ labelText="Labeltext for Switch-Button without Switch-Label"
286
259
  :toggleSwitch="true"
287
260
  :status="formElementStatus"
288
261
  />
@@ -290,8 +263,7 @@
290
263
  type="checkbox"
291
264
  id="toggle-switch-checkbox"
292
265
  v-model="switchButtonCheckbox"
293
- :displayLabelInline="true"
294
- labelText="Labeltext for SwitchButton (Checkbox)"
266
+ labelText="Labeltext for Switch-Button with Switch-Label"
295
267
  onLabel="Label on"
296
268
  offLabel="Label off"
297
269
  :toggleSwitch="true"
@@ -301,7 +273,7 @@
301
273
  type="checkbox"
302
274
  id="toggle-switch-checkbox-colored"
303
275
  v-model="switchButtonCheckbox"
304
- labelText="Labeltext for SwitchButton (Checkbox, colored)"
276
+ labelText="Labeltext for Switch-Button (Checkbox, colored)"
305
277
  onLabel="Label on"
306
278
  offLabel="Label off"
307
279
  :colored="true"
@@ -319,6 +291,7 @@
319
291
  :toggleSwitch="true"
320
292
  :status="formElementStatus"
321
293
  inputValue="radio1"
294
+ labelText="Labeltext for Switch-Button (Radio, colored) #1"
322
295
  />
323
296
  <CmdFormElement element="input"
324
297
  type="radio"
@@ -331,6 +304,7 @@
331
304
  :toggleSwitch="true"
332
305
  :status="formElementStatus"
333
306
  inputValue="radio2"
307
+ labelText="Labeltext for Switch-Button (Radio, colored) #2"
334
308
  />
335
309
  <!-- end toggle-switch-radio with switch-label (colored) -->
336
310
 
@@ -715,7 +689,20 @@
715
689
  </div>
716
690
  </div>
717
691
  <h3>Box Site Search</h3>
718
- <CmdBoxSiteSearch :results="executeSearch()" @click="executeSearch($event)"/>
692
+ <CmdBoxSiteSearch
693
+ v-model:modelValueInput1="siteSearchInput1"
694
+ v-model:modelValueInput2="siteSearchInput2"
695
+ v-model:modelValueRadius="radius"
696
+ v-model:modelValueSearchFilters="filters"
697
+ @search="siteSearchOutput"
698
+ textLegend="Search"
699
+ :cmdFakeSelect="siteSearchFilters" />
700
+ <dl>
701
+ <dt>siteSearchInput1:</dt><dd>{{ siteSearchInput1 }}</dd>
702
+ <dt>siteSearchInput2:</dt><dd>{{ siteSearchInput2 }}</dd>
703
+ <dt>Radius:</dt><dd>{{ radius }}</dd>
704
+ <dt>Filters:</dt><dd>{{ filters }}</dd>
705
+ </dl>
719
706
  </CmdWidthLimitationWrapper>
720
707
  <!-- end boxes ------------------------------------------------------------------------------------------------------------------------------------------------------->
721
708
 
@@ -1059,12 +1046,12 @@ import CmdProgressBar from "@/components/CmdProgressBar.vue"
1059
1046
  import CmdShareButtons from "@/components/CmdShareButtons.vue"
1060
1047
  import CmdSiteHeader from "./components/CmdSiteHeader"
1061
1048
  import CmdSlideshow from "@/components/CmdSlideshow.vue"
1062
- import CmdSwitchButton from "@/components/CmdSwitchButton.vue"
1063
1049
  import CmdSwitchLanguage from "@/components/CmdSwitchLanguage.vue"
1064
1050
  import CmdSystemMessage from "@/components/CmdSystemMessage.vue"
1065
1051
  import CmdTabs from "@/components/CmdTabs.vue"
1066
1052
  import CmdTable from "@/components/CmdTable.vue"
1067
1053
  import CmdThumbnailScroller from "@/components/CmdThumbnailScroller.vue"
1054
+ import CmdToggleDarkMode from "@/components/CmdToggleDarkMode.vue"
1068
1055
  import CmdTooltip from "@/components/CmdTooltip.vue"
1069
1056
  import CmdUploadForm from "@/components/CmdUploadForm.vue"
1070
1057
  import CmdWidthLimitationWrapper from "@/components/CmdWidthLimitationWrapper"
@@ -1106,12 +1093,12 @@ export default {
1106
1093
  CmdShareButtons,
1107
1094
  CmdSiteHeader,
1108
1095
  CmdSlideshow,
1109
- CmdSwitchButton,
1110
1096
  CmdSwitchLanguage,
1111
1097
  CmdSystemMessage,
1112
1098
  CmdTabs,
1113
1099
  CmdTable,
1114
1100
  CmdThumbnailScroller,
1101
+ CmdToggleDarkMode,
1115
1102
  CmdTooltip,
1116
1103
  CmdUploadForm,
1117
1104
  CmdWidthLimitationWrapper
@@ -1134,7 +1121,18 @@ export default {
1134
1121
  selectedColor: "",
1135
1122
  rangeValue: 50,
1136
1123
  loginData: {},
1124
+ siteSearchFilters: {
1125
+ show: true,
1126
+ selectData: fakeSelectFilterOptionsData,
1127
+ defaultOptionName: "Select filters:",
1128
+ labelText: "Filters:",
1129
+ type: "checkboxOptions"
1130
+ },
1137
1131
  formElementStatus: "",
1132
+ siteSearchInput1: "Doctor",
1133
+ siteSearchInput2: "New York",
1134
+ radius: 10,
1135
+ filters: ["2"],
1138
1136
  switchButtonRadio: "radio1",
1139
1137
  switchButtonCheckbox: ["checkbox1"],
1140
1138
  switchButtonCheckboxColored: false,
@@ -1202,7 +1200,13 @@ export default {
1202
1200
  thumbnailScrollerData
1203
1201
  }
1204
1202
  },
1203
+ mounted() {
1204
+ document.querySelector('html').addEventListener('toggle-color-scheme', (event) => console.log('colorScheme:', event.detail))
1205
+ },
1205
1206
  methods: {
1207
+ siteSearchOutput(event) {
1208
+ console.log(event)
1209
+ },
1206
1210
  showError(event) {
1207
1211
  console.log("EventMessages", event.messages)
1208
1212
  alert("Error")
@@ -1,4 +1,4 @@
1
- /* global-styles.scss - last update: 2021/08/10 by Raphael Biock - IT IS NOT RECOMMENDED TO EDIT THIS FILE (TO AVOID TROUBLESHOOTING AFTER UPDATING) - DO CHANGES IN template.css ONLY */
1
+ /* global-styles.scss - last update: 2022/06/11 - IT IS NOT RECOMMENDED TO EDIT THIS FILE (TO AVOID TROUBLESHOOTING AFTER UPDATING) - DO CHANGES IN template.css ONLY */
2
2
 
3
3
  /* begin table of contents --------------------------------------------------------------------------------------------------------------------------------------------------- */
4
4
  /*
@@ -16,11 +16,16 @@
16
16
  P ------------------------
17
17
  - product-listing
18
18
 
19
+ T ------------------------
20
+ - tooltip
21
+
19
22
  - MEDIA QUERIES ------------------------
20
23
  - styles for medium screens
21
24
  - styles for small screens
22
25
 
23
- - DARK MODE ------------------------
26
+ - COLOR SCHEMES ------------------------
27
+ - custom light-mode
28
+ - custom dark-mode
24
29
  */
25
30
  /* end table of contents --------------------------------------------------------------------------------------------------------------------------------------------------- */
26
31
 
@@ -98,13 +103,13 @@ body.avoid-scrolling {
98
103
 
99
104
  &.products-squares {
100
105
  > a {
101
- grid-column: span 6;
106
+ grid-column: span calc(var(--grid-columns) / 2);
102
107
  }
103
108
  }
104
109
 
105
110
  &.products-lines {
106
111
  > a {
107
- grid-column: span 12;
112
+ grid-column: span var(--grid-columns);
108
113
  flex-direction: unset;
109
114
 
110
115
  img {
@@ -166,6 +171,8 @@ body.avoid-scrolling {
166
171
  }
167
172
  }
168
173
  /* end product-listing --------------------------------------------------------------------------------------------------------------------------------------------------- */
174
+
175
+ /* begin tooltip for cmd-form-element and cmd-fake-select ---------------------------------------------------------------------------------------------------------------- */
169
176
  .cmd-form-element, .cmd-fake-select {
170
177
  & + .cmd-tooltip {
171
178
  border-color: var(--status-color);
@@ -209,6 +216,7 @@ body.avoid-scrolling {
209
216
  }
210
217
  }
211
218
  }
219
+ /* end tooltip for cmd-form-element and cmd-fake-select ------------------------------------------------------------------------------------------------------------------ */
212
220
  /* ---------------------------------------------- END COMPONENTS AND GLOBAL STYLES -------------------------------------------------- */
213
221
 
214
222
  /* ---------------------------------------------- BEGIN MEDIA QUERIES AND BROWSER SPECIFIC STYLES -------------------------------------------------- */
@@ -261,51 +269,25 @@ body.avoid-scrolling {
261
269
  /* end styles for small screens --------------------------------------------------------------------------------------------------------------------------------------------------- */
262
270
  /* ---------------------------------------------- END MEDIA QUERIES AND BROWSER SPECIFIC STYLES -------------------------------------------------- */
263
271
 
264
- /* ---------------------------------------------- BEGIN DARK-MODE -------------------------------------------------- */
265
- @media (prefers-color-scheme: dark) {
266
- html {
267
- --dark-mode-background-color: rgb(50, 50, 50);
268
- scrollbar-color: var(--primary-color) var(--dark-gray); /* firefox only */
269
- }
270
-
271
- /* webkit only */
272
- html::-webkit-scrollbar-track {
273
- background-color: var(--dark-gray);
272
+ /* ---------------------------------------------- BEGIN COLORS-SCHEMES (LIGHT-/DARK-MODE) -------------------------------------------------- */
273
+ html {
274
+ &.light-mode {
275
+ /* assign default colors for custom light-mode set by class */
276
+ --color-scheme-text-color: var(--light-mode-text-color);
277
+ --color-scheme-background-color: var(--light-mode-background-color);
278
+ --color-scheme-text-color-inverted: var(--dark-mode-text-color);
279
+ --color-scheme-background-inverted: var(--dark-mode-background-color);
280
+ --default-background-color-lightness: 97%;
274
281
  }
275
282
 
276
- html, body,
277
- .cmd-site-header,
278
- .cmd-width-limitation-wrapper#site-footer {
279
- background: var(--dark-mode-background-color);
280
- color: var(--pure-white);
281
- }
282
-
283
- legend {
284
- background: var(--default-background-color);
285
- border: var(--default-border);
286
- }
287
-
288
- .cmd-breadcrumbs,
289
- .cmd-breadcrumbs > *,
290
- .cmd-top-header-navigation a,
291
- .cmd-pager > p, main {
292
- color: var(--pure-white);
293
- }
294
-
295
- hr {
296
- border-color: var(--pure-white);
297
- }
298
-
299
- .cmd-accordion,
300
- .cmd-tabs,
301
- fieldset, table, .box, {
302
- color: var(--text-color);
303
- }
304
-
305
- .cmd-accordion hr,
306
- .cmd-tabs hr,
307
- fieldset hr, table hr, .box hr {
308
- border-color: var(--text-color);
283
+ &.dark-mode {
284
+ /* assign default colors for custom dark-mode set by class */
285
+ --color-scheme-text-color: var(--dark-mode-text-color);
286
+ --color-scheme-background-color: var(--dark-mode-background-color);
287
+ --color-scheme-text-color-inverted: var(--light-mode-text-color);
288
+ --color-scheme-background-inverted: var(--light-mode-background-color);
289
+ --default-background-color-lightness: 20%;
309
290
  }
310
291
  }
311
- /* ---------------------------------------------- END DARK-MODE -------------------------------------------------- */
292
+
293
+ /* ---------------------------------------------- END COLORS-SCHEMES (LIGHT-/DARK-MODE) -------------------------------------------------- */
@@ -70,7 +70,7 @@ export default {
70
70
  text-decoration: none;
71
71
  z-index: 1000;
72
72
  border: var(--default-border);
73
- background: var(--pure-white);
73
+ background: var(--color-scheme-background-color);
74
74
  border-radius: var(--full-circle);
75
75
 
76
76
  &:hover, &:active, &:focus {