vuetify-swatches 2.0.0 → 2.1.1
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/LICENSE +1 -1
- package/README.ja.md +159 -0
- package/README.md +51 -128
- package/dist/components/SwatchButton.vue.d.ts +2 -1
- package/dist/components/VSwatches.vue.d.ts +30 -173
- package/dist/index.cjs.js +3 -3
- package/dist/index.es.js +247 -262
- package/dist/index.iife.js +3 -3
- package/dist/index.umd.js +3 -3
- package/dist/presets/advanced.js +237 -233
- package/dist/presets/basic.js +34 -26
- package/dist/presets/index.d.ts +2 -2
- package/dist/presets/index.js +3 -6
- package/dist/presets/src/Meta.d.ts +3 -0
- package/dist/presets/src/components/SwatchButton.vue.d.ts +36 -0
- package/dist/presets/src/components/VSwatches.vue.d.ts +81 -0
- package/dist/presets/src/index.d.ts +3 -0
- package/dist/presets/src/interfaces/MetaInterface.d.ts +7 -0
- package/dist/vuetify-swatches.css +4 -3
- package/package.json +79 -59
- package/src/components/VSwatches.vue +85 -117
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import { Variant } from 'vuetify/lib/composables/variant.d.ts';
|
|
2
|
+
import { Anchor } from 'vuetify/lib/util/index.d.ts';
|
|
3
|
+
/** Swatches prop type */
|
|
4
|
+
type SwatchesProp = (string | undefined)[] | (string | undefined)[][] | Record<string, (string | undefined)[]> | readonly (string | undefined)[] | readonly (readonly (string | undefined)[])[];
|
|
5
|
+
/** Props */
|
|
6
|
+
type __VLS_Props = {
|
|
7
|
+
/** Model value */
|
|
8
|
+
modelValue?: string;
|
|
9
|
+
/** Swatch colors */
|
|
10
|
+
swatches?: SwatchesProp;
|
|
11
|
+
/** Swatch size */
|
|
12
|
+
size?: string;
|
|
13
|
+
/**
|
|
14
|
+
* Selected icon
|
|
15
|
+
* @see {@link https://vuetifyjs.com/en/components/icons/#usage}
|
|
16
|
+
*/
|
|
17
|
+
icon?: string;
|
|
18
|
+
/** Selected icon size */
|
|
19
|
+
iconSize?: string;
|
|
20
|
+
/** Display swatches in a single row */
|
|
21
|
+
inline?: boolean;
|
|
22
|
+
/**
|
|
23
|
+
* The variant prop gives you easy access to several different button styles.
|
|
24
|
+
* @see {@link https://vuetifyjs.com/en/components/buttons/#variant}
|
|
25
|
+
*/
|
|
26
|
+
variant?: Variant;
|
|
27
|
+
/**
|
|
28
|
+
* Removes the ability to click or target the component.
|
|
29
|
+
* @see {@link https://vuetifyjs.com/en/api/v-btn/#props-disabled}
|
|
30
|
+
*/
|
|
31
|
+
disabled?: boolean;
|
|
32
|
+
/**
|
|
33
|
+
* Applies a large border radius on the button.
|
|
34
|
+
* @see {@link https://vuetifyjs.com/en/components/buttons/#rounded}
|
|
35
|
+
*/
|
|
36
|
+
rounded?: string | number | boolean;
|
|
37
|
+
/**
|
|
38
|
+
* Applies border styles to component.
|
|
39
|
+
* @see {@link https://vuetifyjs.com/en/api/v-btn/#props-border}
|
|
40
|
+
*/
|
|
41
|
+
border?: string | number | boolean;
|
|
42
|
+
/**
|
|
43
|
+
* Designates an elevation applied to the component between 0 and 24.
|
|
44
|
+
* @see {@link https://vuetifyjs.com/en/api/v-btn/#props-elevation}
|
|
45
|
+
*/
|
|
46
|
+
elevation?: string | number;
|
|
47
|
+
/** Swap cols and rows */
|
|
48
|
+
transpose?: boolean;
|
|
49
|
+
/**
|
|
50
|
+
* Tooltip
|
|
51
|
+
* @see {@link https://vuetifyjs.com/en/components/tooltips/}
|
|
52
|
+
*/
|
|
53
|
+
tooltip?: boolean;
|
|
54
|
+
/**
|
|
55
|
+
* Tooltip location
|
|
56
|
+
* @see {@link https://vuetifyjs.com/en/components/tooltips/#props-location}
|
|
57
|
+
*/
|
|
58
|
+
tooltipLocation?: Anchor;
|
|
59
|
+
};
|
|
60
|
+
declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
61
|
+
"update:modelValue": (value: string) => any;
|
|
62
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
63
|
+
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
64
|
+
}>, {
|
|
65
|
+
size: string;
|
|
66
|
+
icon: string;
|
|
67
|
+
iconSize: string;
|
|
68
|
+
variant: Variant;
|
|
69
|
+
disabled: boolean;
|
|
70
|
+
rounded: string | number | boolean;
|
|
71
|
+
border: string | number | boolean;
|
|
72
|
+
elevation: string | number;
|
|
73
|
+
tooltip: boolean;
|
|
74
|
+
tooltipLocation: Anchor;
|
|
75
|
+
modelValue: string;
|
|
76
|
+
swatches: SwatchesProp;
|
|
77
|
+
inline: boolean;
|
|
78
|
+
transpose: boolean;
|
|
79
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
80
|
+
declare const _default: typeof __VLS_export;
|
|
81
|
+
export default _default;
|
|
@@ -3,10 +3,11 @@
|
|
|
3
3
|
*
|
|
4
4
|
* @description Color Swatch component for Vuetify3.
|
|
5
5
|
* @author Logue <logue@hotmail.co.jp>
|
|
6
|
-
* @copyright 2022-
|
|
6
|
+
* @copyright 2022-2026 By Masashi Yoshikawa All rights reserved.
|
|
7
7
|
* @license MIT
|
|
8
|
-
* @version 2.
|
|
8
|
+
* @version 2.1.1
|
|
9
9
|
* @see {@link https://github.com/logue/vuetify-swatches}
|
|
10
10
|
*/
|
|
11
11
|
|
|
12
|
-
.v-swatches .v-btn{margin:.1rem}.v-swatches .v-btn .v-icon{filter:invert(
|
|
12
|
+
.v-swatches .v-btn{margin:.1rem}.v-swatches .v-btn .v-icon{filter:invert()grayscale()contrast(100)}.v-swatches .v-btn.bg-transparent{background:linear-gradient(to top left, transparent 0, transparent calc(50% - .1rem), rgb(var(--v-theme-error)) 50%, transparent calc(50% + .1rem), transparent)}.v-swatches .v-btn.bg-transparent .v-icon{filter:none}
|
|
13
|
+
/*$vite$:1*/
|
package/package.json
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
{
|
|
2
|
-
"$schema": "https://schemastore.org/package.json",
|
|
3
2
|
"name": "vuetify-swatches",
|
|
4
|
-
"version": "2.
|
|
3
|
+
"version": "2.1.1",
|
|
5
4
|
"description": "Color Swatch component for Vuetify3.",
|
|
6
5
|
"keywords": [
|
|
7
6
|
"vue",
|
|
@@ -66,74 +65,95 @@
|
|
|
66
65
|
"src/components/VSwatches.vue"
|
|
67
66
|
],
|
|
68
67
|
"engines": {
|
|
69
|
-
"node": ">=
|
|
68
|
+
"node": "^20.19.0 || >=22.12.0"
|
|
70
69
|
},
|
|
71
|
-
"packageManager": "pnpm@
|
|
72
|
-
"sideEffects": false,
|
|
70
|
+
"packageManager": "pnpm@11.9.0",
|
|
73
71
|
"scripts": {
|
|
74
72
|
"dev": "vite",
|
|
75
|
-
"clean": "rimraf node_modules/.vite",
|
|
76
|
-
"
|
|
77
|
-
"build": "run-
|
|
78
|
-
"build:analyze": "vite build --mode=analyze",
|
|
79
|
-
"build:clean": "rimraf dist docs",
|
|
73
|
+
"clean": "rimraf ./node_modules/.vite",
|
|
74
|
+
"build": "run-s build:lib build:presets",
|
|
75
|
+
"build:lib": "run-p type-check build-only",
|
|
80
76
|
"build:docs": "vite build --mode=docs",
|
|
81
|
-
"build-only": "vite build",
|
|
82
77
|
"build:presets": "vite build --config vite.config.presets.ts",
|
|
83
|
-
"
|
|
84
|
-
"
|
|
85
|
-
"
|
|
86
|
-
"
|
|
78
|
+
"build:analyze": "vite build --mode analyze",
|
|
79
|
+
"build:clean": "rimraf dist",
|
|
80
|
+
"lint": "run-s lint:*",
|
|
81
|
+
"lint:oxlint": "oxlint . --fix",
|
|
82
|
+
"lint:eslint": "eslint . --fix --cache --cache-location ./node_modules/.vite/eslint-cache",
|
|
83
|
+
"lint:prettier": "prettier \"./**/*.{js,ts,json,css,sass,scss,htm,html,vue,md}\" -w -u",
|
|
84
|
+
"lint:style": "stylelint \"./**/*.{css,sass,scss,htm,html,vue}\" --fix --cache-location ./node_modules/.vite/stylelint-cache && prettier \"./**/*.{css,sass,scss,htm,html,vue}\" -w -u",
|
|
85
|
+
"preview": "vite preview",
|
|
86
|
+
"test:unit": "vitest",
|
|
87
87
|
"test:coverage": "vitest run --coverage",
|
|
88
|
-
"test:
|
|
89
|
-
"
|
|
90
|
-
"
|
|
88
|
+
"test:e2e": "playwright test",
|
|
89
|
+
"build-only": "vite build",
|
|
90
|
+
"type-check": "vue-tsc --build",
|
|
91
|
+
"prepare": "husky"
|
|
91
92
|
},
|
|
92
93
|
"peerDependencies": {
|
|
93
|
-
"vue": ">=3.5
|
|
94
|
-
"vuetify": ">=
|
|
94
|
+
"vue": ">=3.5",
|
|
95
|
+
"vuetify": ">=4"
|
|
95
96
|
},
|
|
96
97
|
"dependencies": {
|
|
97
|
-
"es-toolkit": "^1.
|
|
98
|
+
"es-toolkit": "^1.49.0"
|
|
98
99
|
},
|
|
99
100
|
"devDependencies": {
|
|
100
|
-
"@codemirror/lang-vue": "0.1.3",
|
|
101
|
+
"@codemirror/lang-vue": "^0.1.3",
|
|
102
|
+
"@eslint-community/eslint-plugin-eslint-comments": "^4.7.2",
|
|
103
|
+
"@eslint/markdown": "^8.0.3",
|
|
104
|
+
"@mdi/font": "^7.4.47",
|
|
105
|
+
"@playwright/test": "^1.61.1",
|
|
101
106
|
"@tsconfig/node-lts": "^24.0.0",
|
|
102
|
-
"@types/jsdom": "^
|
|
103
|
-
"@types/node": "^
|
|
104
|
-
"@vitejs/plugin-vue": "^6.0.
|
|
105
|
-
"@vitest/coverage-v8": "^4.
|
|
107
|
+
"@types/jsdom": "^28.0.3",
|
|
108
|
+
"@types/node": "^26.1.0",
|
|
109
|
+
"@vitejs/plugin-vue": "^6.0.7",
|
|
110
|
+
"@vitest/coverage-v8": "^4.1.9",
|
|
111
|
+
"@vitest/eslint-plugin": "1.6.20",
|
|
106
112
|
"@vue/eslint-config-prettier": "^10.2.0",
|
|
107
|
-
"@vue/eslint-config-typescript": "^14.
|
|
108
|
-
"@vue/test-utils": "^2.4.
|
|
109
|
-
"@vue/tsconfig": "^0.
|
|
110
|
-
"
|
|
113
|
+
"@vue/eslint-config-typescript": "^14.9.0",
|
|
114
|
+
"@vue/test-utils": "^2.4.11",
|
|
115
|
+
"@vue/tsconfig": "^0.9.1",
|
|
116
|
+
"esbuild": "^0.28.1",
|
|
117
|
+
"eslint": "^10.6.0",
|
|
111
118
|
"eslint-import-resolver-custom-alias": "^1.3.2",
|
|
112
|
-
"eslint-import-resolver-typescript": "^4.4.
|
|
113
|
-
"eslint-plugin-import": "^
|
|
114
|
-
"eslint-plugin-
|
|
115
|
-
"eslint-plugin-
|
|
116
|
-
"eslint-plugin-
|
|
119
|
+
"eslint-import-resolver-typescript": "^4.4.5",
|
|
120
|
+
"eslint-plugin-import-x": "^4.17.1",
|
|
121
|
+
"eslint-plugin-node": "^11.1.0",
|
|
122
|
+
"eslint-plugin-oxlint": "^1.72.0",
|
|
123
|
+
"eslint-plugin-playwright": "^2.10.4",
|
|
124
|
+
"eslint-plugin-security": "^4.0.1",
|
|
125
|
+
"eslint-plugin-vue": "^10.9.2",
|
|
126
|
+
"eslint-plugin-vuejs-accessibility": "^2.5.0",
|
|
127
|
+
"eslint-plugin-vuetify": "^2.7.2",
|
|
117
128
|
"husky": "^9.1.7",
|
|
118
|
-
"
|
|
119
|
-
"
|
|
120
|
-
"
|
|
121
|
-
"
|
|
122
|
-
"
|
|
123
|
-
"
|
|
124
|
-
"
|
|
125
|
-
"
|
|
126
|
-
"
|
|
127
|
-
"
|
|
129
|
+
"jiti": "^2.7.0",
|
|
130
|
+
"jsdom": "29.1.1",
|
|
131
|
+
"lint-staged": "^17.0.8",
|
|
132
|
+
"npm-run-all2": "^9.0.2",
|
|
133
|
+
"oxlint": "^1.72.0",
|
|
134
|
+
"postcss-html": "^1.8.1",
|
|
135
|
+
"prettier": "^3.9.4",
|
|
136
|
+
"resize-observer-polyfill": "^1.5.1",
|
|
137
|
+
"rimraf": "^6.1.3",
|
|
138
|
+
"rollup-plugin-visualizer": "^7.0.1",
|
|
139
|
+
"sass-embedded": "^1.100.0",
|
|
140
|
+
"stylelint": "^17.14.0",
|
|
141
|
+
"stylelint-config-html": "^1.1.0",
|
|
142
|
+
"stylelint-config-recommended-scss": "^17.0.1",
|
|
143
|
+
"stylelint-config-recommended-vue": "^1.6.1",
|
|
144
|
+
"stylelint-order": "^8.1.1",
|
|
145
|
+
"stylelint-scss": "^7.2.0",
|
|
146
|
+
"typescript": "^6.0.3",
|
|
147
|
+
"typescript-eslint": "^8.62.1",
|
|
148
|
+
"vite": "^8.1.3",
|
|
128
149
|
"vite-plugin-banner": "^0.8.1",
|
|
129
|
-
"vite-plugin-checker": "
|
|
130
|
-
"vite-plugin-dts": "^
|
|
131
|
-
"vite-plugin-
|
|
132
|
-
"
|
|
133
|
-
"
|
|
134
|
-
"vue-codemirror6": "^1.
|
|
135
|
-
"vue-
|
|
136
|
-
"vue-tsc": "^3.1.5"
|
|
150
|
+
"vite-plugin-checker": "0.14.4",
|
|
151
|
+
"vite-plugin-dts": "^5.0.3",
|
|
152
|
+
"vite-plugin-vue-devtools": "^8.1.5",
|
|
153
|
+
"vite-plugin-vuetify": "^2.1.3",
|
|
154
|
+
"vitest": "^4.1.9",
|
|
155
|
+
"vue-codemirror6": "^1.5.2",
|
|
156
|
+
"vue-tsc": "^3.3.6"
|
|
137
157
|
},
|
|
138
158
|
"husky": {
|
|
139
159
|
"hooks": {
|
|
@@ -141,12 +161,12 @@
|
|
|
141
161
|
}
|
|
142
162
|
},
|
|
143
163
|
"lint-staged": {
|
|
144
|
-
"
|
|
145
|
-
"*.{css,sass,scss,vue}": "stylelint --fix --cache",
|
|
146
|
-
"*": "prettier -w -u"
|
|
164
|
+
"*": "run-s lint:*"
|
|
147
165
|
},
|
|
148
166
|
"resolutions": {
|
|
149
|
-
"
|
|
150
|
-
|
|
167
|
+
"js-yaml": ">=4.1.1"
|
|
168
|
+
},
|
|
169
|
+
"stackblitz": {
|
|
170
|
+
"startCommand": "pnpm run test:unit"
|
|
151
171
|
}
|
|
152
|
-
}
|
|
172
|
+
}
|
|
@@ -1,13 +1,6 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
2
|
/** Vuetify Swatches */
|
|
3
|
-
import {
|
|
4
|
-
computed,
|
|
5
|
-
ref,
|
|
6
|
-
watch,
|
|
7
|
-
type ComputedRef,
|
|
8
|
-
type PropType,
|
|
9
|
-
type Ref,
|
|
10
|
-
} from 'vue';
|
|
3
|
+
import { computed, ref, watch, type ComputedRef, type Ref } from 'vue';
|
|
11
4
|
|
|
12
5
|
import { zip } from 'es-toolkit';
|
|
13
6
|
import { VItem, VItemGroup } from 'vuetify/components';
|
|
@@ -18,117 +11,92 @@ import SwatchButton from './SwatchButton.vue';
|
|
|
18
11
|
import type { Variant } from 'vuetify/lib/composables/variant.d.ts';
|
|
19
12
|
import type { Anchor } from 'vuetify/lib/util/index.d.ts';
|
|
20
13
|
|
|
14
|
+
/** Swatches prop type */
|
|
15
|
+
type SwatchesProp =
|
|
16
|
+
| (string | undefined)[]
|
|
17
|
+
| (string | undefined)[][]
|
|
18
|
+
| Record<string, (string | undefined)[]>
|
|
19
|
+
| readonly (string | undefined)[]
|
|
20
|
+
| readonly (readonly (string | undefined)[])[];
|
|
21
|
+
|
|
21
22
|
/** Emits */
|
|
22
|
-
const
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
});
|
|
23
|
+
const emit = defineEmits<{
|
|
24
|
+
'update:modelValue': [value: string];
|
|
25
|
+
}>();
|
|
26
26
|
|
|
27
27
|
/** Props */
|
|
28
|
-
const props =
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
},
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
},
|
|
101
|
-
/**
|
|
102
|
-
* Designates an elevation applied to the component between 0 and 24.
|
|
103
|
-
*
|
|
104
|
-
* @see {@link https://vuetifyjs.com/en/api/v-btn/#props-elevation}
|
|
105
|
-
*/
|
|
106
|
-
elevation: {
|
|
107
|
-
type: [String, Number],
|
|
108
|
-
default: undefined,
|
|
109
|
-
},
|
|
110
|
-
/** Swap cols and rows */
|
|
111
|
-
transpose: {
|
|
112
|
-
type: Boolean,
|
|
113
|
-
default: false,
|
|
114
|
-
},
|
|
115
|
-
/**
|
|
116
|
-
* Tooltip
|
|
117
|
-
* @see {@link https://vuetifyjs.com/en/components/tooltips/}
|
|
118
|
-
*/
|
|
119
|
-
tooltip: {
|
|
120
|
-
type: Boolean,
|
|
121
|
-
default: false,
|
|
122
|
-
},
|
|
123
|
-
/**
|
|
124
|
-
* Tooltip location
|
|
125
|
-
* @see {@link https://vuetifyjs.com/en/components/tooltips/#props-location}
|
|
126
|
-
*/
|
|
127
|
-
tooltipLocation: {
|
|
128
|
-
type: String as PropType<Anchor>,
|
|
129
|
-
default: undefined,
|
|
130
|
-
},
|
|
131
|
-
});
|
|
28
|
+
const props = withDefaults(
|
|
29
|
+
defineProps<{
|
|
30
|
+
/** Model value */
|
|
31
|
+
modelValue?: string;
|
|
32
|
+
/** Swatch colors */
|
|
33
|
+
swatches?: SwatchesProp;
|
|
34
|
+
/** Swatch size */
|
|
35
|
+
size?: string;
|
|
36
|
+
/**
|
|
37
|
+
* Selected icon
|
|
38
|
+
* @see {@link https://vuetifyjs.com/en/components/icons/#usage}
|
|
39
|
+
*/
|
|
40
|
+
icon?: string;
|
|
41
|
+
/** Selected icon size */
|
|
42
|
+
iconSize?: string;
|
|
43
|
+
/** Display swatches in a single row */
|
|
44
|
+
inline?: boolean;
|
|
45
|
+
/**
|
|
46
|
+
* The variant prop gives you easy access to several different button styles.
|
|
47
|
+
* @see {@link https://vuetifyjs.com/en/components/buttons/#variant}
|
|
48
|
+
*/
|
|
49
|
+
variant?: Variant;
|
|
50
|
+
/**
|
|
51
|
+
* Removes the ability to click or target the component.
|
|
52
|
+
* @see {@link https://vuetifyjs.com/en/api/v-btn/#props-disabled}
|
|
53
|
+
*/
|
|
54
|
+
disabled?: boolean;
|
|
55
|
+
/**
|
|
56
|
+
* Applies a large border radius on the button.
|
|
57
|
+
* @see {@link https://vuetifyjs.com/en/components/buttons/#rounded}
|
|
58
|
+
*/
|
|
59
|
+
rounded?: string | number | boolean;
|
|
60
|
+
/**
|
|
61
|
+
* Applies border styles to component.
|
|
62
|
+
* @see {@link https://vuetifyjs.com/en/api/v-btn/#props-border}
|
|
63
|
+
*/
|
|
64
|
+
border?: string | number | boolean;
|
|
65
|
+
/**
|
|
66
|
+
* Designates an elevation applied to the component between 0 and 24.
|
|
67
|
+
* @see {@link https://vuetifyjs.com/en/api/v-btn/#props-elevation}
|
|
68
|
+
*/
|
|
69
|
+
elevation?: string | number;
|
|
70
|
+
/** Swap cols and rows */
|
|
71
|
+
transpose?: boolean;
|
|
72
|
+
/**
|
|
73
|
+
* Tooltip
|
|
74
|
+
* @see {@link https://vuetifyjs.com/en/components/tooltips/}
|
|
75
|
+
*/
|
|
76
|
+
tooltip?: boolean;
|
|
77
|
+
/**
|
|
78
|
+
* Tooltip location
|
|
79
|
+
* @see {@link https://vuetifyjs.com/en/components/tooltips/#props-location}
|
|
80
|
+
*/
|
|
81
|
+
tooltipLocation?: Anchor;
|
|
82
|
+
}>(),
|
|
83
|
+
{
|
|
84
|
+
modelValue: colors.shades.white,
|
|
85
|
+
swatches: () => [],
|
|
86
|
+
size: '2rem',
|
|
87
|
+
icon: 'mdi-checkbox-marked-circle',
|
|
88
|
+
iconSize: '1rem',
|
|
89
|
+
inline: false,
|
|
90
|
+
variant: undefined,
|
|
91
|
+
disabled: false,
|
|
92
|
+
rounded: undefined,
|
|
93
|
+
border: false,
|
|
94
|
+
elevation: undefined,
|
|
95
|
+
transpose: false,
|
|
96
|
+
tooltip: false,
|
|
97
|
+
tooltipLocation: undefined,
|
|
98
|
+
}
|
|
99
|
+
);
|
|
132
100
|
|
|
133
101
|
/** Normalized swatches structure for rendering */
|
|
134
102
|
const normalizedSwatches: ComputedRef<string[][]> = computed(() => {
|
|
@@ -156,7 +124,7 @@ const selected: Ref<string> = ref(colors.shades.white);
|
|
|
156
124
|
|
|
157
125
|
watch(
|
|
158
126
|
() => selected.value,
|
|
159
|
-
s =>
|
|
127
|
+
s => emit('update:modelValue', s)
|
|
160
128
|
);
|
|
161
129
|
|
|
162
130
|
watch(
|