wave-ui 3.0.4 → 3.0.5

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
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "wave-ui",
3
- "version": "3.0.4",
3
+ "version": "3.0.5",
4
4
  "description": "An emerging UI framework for Vue.js (2 & 3) with only the bright side. :sunny:",
5
5
  "author": "Antoni Andre <antoniandre.web@gmail.com>",
6
6
  "homepage": "https://antoniandre.github.io/wave-ui",
@@ -23,6 +23,7 @@
23
23
  "./package.json": "./package.json",
24
24
  "./dist/*": "./dist/*",
25
25
  "./src/wave-ui": "./src/wave-ui/index.js",
26
+ "./src/wave-ui/components": "./src/wave-ui/components/index.js",
26
27
  "./src/wave-ui/*": "./src/wave-ui/*"
27
28
  },
28
29
  "type": "module",
@@ -48,7 +49,7 @@
48
49
  "lint": "vite lint"
49
50
  },
50
51
  "devDependencies": {
51
- "@babel/core": "^7.20.5",
52
+ "@babel/core": "^7.21.0",
52
53
  "@babel/eslint-parser": "^7.19.1",
53
54
  "@babel/plugin-proposal-class-properties": "^7.18.6",
54
55
  "@mdi/font": "^5.9.55",
@@ -57,21 +58,21 @@
57
58
  "autoprefixer": "^10.4.13",
58
59
  "axios": "^0.25.0",
59
60
  "eslint": "^7.32.0",
60
- "eslint-plugin-vue": "^9.8.0",
61
+ "eslint-plugin-vue": "^9.9.0",
61
62
  "font-awesome": "^4.7.0",
62
- "gsap": "^3.11.3",
63
+ "gsap": "^3.11.4",
63
64
  "ionicons": "^4.6.3",
64
65
  "material-design-icons": "^3.0.1",
65
- "postcss": "^8.4.20",
66
+ "postcss": "^8.4.21",
66
67
  "pug": "^3.0.2",
67
68
  "rollup-plugin-delete": "^2.0.0",
68
- "sass": "^1.57.1",
69
+ "sass": "^1.58.3",
69
70
  "simple-syntax-highlighter": "^2.2.5",
70
71
  "splitpanes": "^3.1.5",
71
72
  "standard": "^17.0.0",
72
73
  "vite": "^3.2.5",
73
74
  "vite-svg-loader": "^4.0.0",
74
- "vue": "^3.2.45",
75
+ "vue": "^3.2.47",
75
76
  "vue-router": "^4.1.6",
76
77
  "vueperslides": "^3.5.1",
77
78
  "vuex": "^4.1.0"
@@ -348,7 +348,10 @@ export default {
348
348
  if (!this.isMultipleSelect) this.listItems.forEach(item => (item._selected = false))
349
349
 
350
350
  this.checkSelection(selection) // Create an array with the selected values.
351
- .forEach(val => (this.listItems.find(item => item._value === val)._selected = true))
351
+ .forEach(val => {
352
+ const foundItem = this.listItems.find(item => item._value === val)
353
+ if (foundItem) foundItem._selected = true
354
+ })
352
355
  }
353
356
  },
354
357
 
@@ -78,6 +78,7 @@ export default {
78
78
  counts: { type: Boolean },
79
79
  itemIconKey: { type: String, default: 'icon' }, // Support a different icon per item.
80
80
  iconColor: { type: String }, // Applies a color on all the label item icons.
81
+ itemLabelKey: { type: String, default: 'label' }, // Specify a different key for the item label.
81
82
  itemIconColorKey: { type: String, default: 'iconColor' }, // Applies a specific color on each label item icons.
82
83
  itemRouteKey: { type: String, default: 'route' }, // Uses a router link if the item has the `route` key.
83
84
  itemDisabledKey: { type: String, default: 'disabled' }, // Disables the item click and selection.
@@ -117,7 +118,7 @@ export default {
117
118
  this.currentDepthItems.push({
118
119
  originalItem: item, // Store the original item to return it on event emits.
119
120
  _uid: this.depth.toString() + (i + 1),
120
- label: item.label,
121
+ label: item[this.itemLabelKey],
121
122
  children: !!item.children, // The children tree remains available in originalItem.
122
123
  branch: item.branch,
123
124
  route: item[this.itemRouteKey],
@@ -103,7 +103,6 @@ export default class WaveUI {
103
103
  const wApp = document.querySelector(config.on) || document.body
104
104
  wApp.classList.add('w-app')
105
105
 
106
- let themeColors = config.colors[config.theme]
107
106
  if (config.theme === 'auto') detectOSDarkMode($waveui) // Also switches the theme.
108
107
  else $waveui.switchTheme(config.theme, true)
109
108
 
@@ -15,6 +15,7 @@
15
15
  --w-base-color-rgb: #{map.get($theme-light, 'base-color-rgb')};
16
16
  --w-contrast-bg-color-rgb: #{map.get($theme-light, 'contrast-bg-color-rgb')};
17
17
  --w-contrast-color-rgb: #{map.get($theme-light, 'contrast-color-rgb')};
18
+ --w-caption-color-rgb: #{map.get($theme-light, 'caption-color-rgb')};
18
19
  --w-disabled-color-rgb: #{map.get($theme-light, 'disabled-color-rgb')};
19
20
  }
20
21
 
@@ -23,6 +24,7 @@
23
24
  --w-base-color-rgb: #{map.get($theme-dark, 'base-color-rgb')};
24
25
  --w-contrast-bg-color-rgb: #{map.get($theme-dark, 'contrast-bg-color-rgb')};
25
26
  --w-contrast-color-rgb: #{map.get($theme-dark, 'contrast-color-rgb')};
27
+ --w-caption-color-rgb: #{map.get($theme-dark, 'caption-color-rgb')};
26
28
  --w-disabled-color-rgb: #{map.get($theme-dark, 'disabled-color-rgb')};
27
29
  }
28
30
 
@@ -33,7 +33,7 @@
33
33
  .caption {
34
34
  font-size: round(0.85 * $base-font-size);
35
35
  font-style: italic;
36
- color: rgba(80, 80, 80, 0.7);
36
+ color: $caption-color;
37
37
  }
38
38
 
39
39
  .text-upper {text-transform: uppercase;}
@@ -14,6 +14,7 @@ $theme-light: (
14
14
  base-color-rgb: (0, 0, 0), // #000.
15
15
  contrast-bg-color-rgb: (0, 0, 0), // #000.
16
16
  contrast-color-rgb: (255, 255, 255), // #fff.
17
+ caption-color-rgb: (80, 80, 80, 0.7), // #505050.
17
18
  disabled-color-rgb: (204, 204, 204), // #ccc.
18
19
  ) !default;
19
20
 
@@ -22,6 +23,7 @@ $theme-dark: (
22
23
  base-color-rgb: (255, 255, 255), // #fff.
23
24
  contrast-bg-color-rgb: (255, 255, 255), // #fff.
24
25
  contrast-color-rgb: (0, 0, 0), // #000.
26
+ caption-color-rgb: (175, 175, 175, 0.7), // #afafaf.
25
27
  disabled-color-rgb: (74, 74, 74), // #4a4a4a.
26
28
  ) !default;
27
29
 
@@ -32,6 +34,7 @@ $base-bg-color: rgb(var(--w-base-bg-color-rgb));
32
34
  $base-color: rgb(var(--w-base-color-rgb));
33
35
  $contrast-bg-color: rgb(var(--w-contrast-bg-color-rgb));
34
36
  $contrast-color: rgb(var(--w-contrast-color-rgb));
37
+ $caption-color: rgb(var(--w-caption-color-rgb));
35
38
  // When a form element is disabled (checkbox, radio, input, select list).
36
39
  $disabled-color: rgb(var(--w-disabled-color-rgb));
37
40