@cypress-design/vue-checkbox 0.2.1 → 0.3.0
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/CHANGELOG.md +6 -0
- package/Checkbox.vue +21 -6
- package/dist/Checkbox.vue.d.ts +43 -7
- package/dist/Checkbox.vue.d.ts.map +1 -1
- package/dist/index.es.js +3 -3
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +1 -1
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# @cypress-design/vue-checkbox
|
|
2
2
|
|
|
3
|
+
## 0.3.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#44](https://github.com/cypress-io/cypress-design/pull/44) [`2fdaf6b`](https://github.com/cypress-io/cypress-design/commit/2fdaf6be6f81a2a851761258347ed213577c5b26) Thanks [@elevatebart](https://github.com/elevatebart)! - Add missing descriptions of props in button, tooltip, checkbox
|
|
8
|
+
|
|
3
9
|
## 0.2.1
|
|
4
10
|
|
|
5
11
|
### Patch Changes
|
package/Checkbox.vue
CHANGED
|
@@ -2,17 +2,32 @@
|
|
|
2
2
|
import { ref, computed } from 'vue'
|
|
3
3
|
import { IconCheckmarkSmall } from '@cypress-design/vue-icon'
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
type CheckboxColor = 'red' | 'indigo' | 'jade'
|
|
7
|
-
|
|
8
5
|
const props = withDefaults(
|
|
9
6
|
defineProps<{
|
|
7
|
+
/**
|
|
8
|
+
* A unique identifier for the checkbox on the whole page.
|
|
9
|
+
* It will be used to give match label with input for a11y.
|
|
10
|
+
*/
|
|
10
11
|
id?: string
|
|
12
|
+
/**
|
|
13
|
+
* Is the checkbox checked when it is first rendered.
|
|
14
|
+
*/
|
|
15
|
+
checked?: boolean
|
|
16
|
+
/**
|
|
17
|
+
* The color of the background in the checkbox.
|
|
18
|
+
* The checkmark will always be white.
|
|
19
|
+
*/
|
|
20
|
+
color?: 'red' | 'indigo' | 'jade'
|
|
21
|
+
/**
|
|
22
|
+
* If the checkbox is disabled, it will not be clickable.
|
|
23
|
+
*/
|
|
24
|
+
disabled?: boolean
|
|
11
25
|
modelValue?: boolean
|
|
12
|
-
|
|
26
|
+
/**
|
|
27
|
+
* Label for the checkbox.
|
|
28
|
+
* It is very important to set this to make the checkbox accessible.
|
|
29
|
+
*/
|
|
13
30
|
label?: string
|
|
14
|
-
disabled?: boolean
|
|
15
|
-
checked?: boolean
|
|
16
31
|
}>(),
|
|
17
32
|
{
|
|
18
33
|
// @ts-ignore
|
package/dist/Checkbox.vue.d.ts
CHANGED
|
@@ -1,22 +1,58 @@
|
|
|
1
1
|
declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
2
|
+
/**
|
|
3
|
+
* A unique identifier for the checkbox on the whole page.
|
|
4
|
+
* It will be used to give match label with input for a11y.
|
|
5
|
+
*/
|
|
2
6
|
id?: string | undefined;
|
|
7
|
+
/**
|
|
8
|
+
* Is the checkbox checked when it is first rendered.
|
|
9
|
+
*/
|
|
10
|
+
checked?: boolean | undefined;
|
|
11
|
+
/**
|
|
12
|
+
* The color of the background in the checkbox.
|
|
13
|
+
* The checkmark will always be white.
|
|
14
|
+
*/
|
|
15
|
+
color?: "indigo" | "red" | "jade" | undefined;
|
|
16
|
+
/**
|
|
17
|
+
* If the checkbox is disabled, it will not be clickable.
|
|
18
|
+
*/
|
|
19
|
+
disabled?: boolean | undefined;
|
|
3
20
|
modelValue?: boolean | undefined;
|
|
4
|
-
|
|
21
|
+
/**
|
|
22
|
+
* Label for the checkbox.
|
|
23
|
+
* It is very important to set this to make the checkbox accessible.
|
|
24
|
+
*/
|
|
5
25
|
label?: string | undefined;
|
|
6
|
-
disabled?: boolean | undefined;
|
|
7
|
-
checked?: boolean | undefined;
|
|
8
26
|
}>, {
|
|
9
27
|
id: any;
|
|
10
28
|
color: string;
|
|
11
29
|
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
12
30
|
"update:modelValue": (value: boolean) => void;
|
|
13
31
|
}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
32
|
+
/**
|
|
33
|
+
* A unique identifier for the checkbox on the whole page.
|
|
34
|
+
* It will be used to give match label with input for a11y.
|
|
35
|
+
*/
|
|
14
36
|
id?: string | undefined;
|
|
37
|
+
/**
|
|
38
|
+
* Is the checkbox checked when it is first rendered.
|
|
39
|
+
*/
|
|
40
|
+
checked?: boolean | undefined;
|
|
41
|
+
/**
|
|
42
|
+
* The color of the background in the checkbox.
|
|
43
|
+
* The checkmark will always be white.
|
|
44
|
+
*/
|
|
45
|
+
color?: "indigo" | "red" | "jade" | undefined;
|
|
46
|
+
/**
|
|
47
|
+
* If the checkbox is disabled, it will not be clickable.
|
|
48
|
+
*/
|
|
49
|
+
disabled?: boolean | undefined;
|
|
15
50
|
modelValue?: boolean | undefined;
|
|
16
|
-
|
|
51
|
+
/**
|
|
52
|
+
* Label for the checkbox.
|
|
53
|
+
* It is very important to set this to make the checkbox accessible.
|
|
54
|
+
*/
|
|
17
55
|
label?: string | undefined;
|
|
18
|
-
disabled?: boolean | undefined;
|
|
19
|
-
checked?: boolean | undefined;
|
|
20
56
|
}>, {
|
|
21
57
|
id: any;
|
|
22
58
|
color: string;
|
|
@@ -24,7 +60,7 @@ declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_T
|
|
|
24
60
|
"onUpdate:modelValue"?: ((value: boolean) => any) | undefined;
|
|
25
61
|
}, {
|
|
26
62
|
id: string;
|
|
27
|
-
color:
|
|
63
|
+
color: 'red' | 'indigo' | 'jade';
|
|
28
64
|
}>;
|
|
29
65
|
export default _default;
|
|
30
66
|
declare type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Checkbox.vue.d.ts","sourceRoot":"","sources":["../Checkbox.vue.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Checkbox.vue.d.ts","sourceRoot":"","sources":["../Checkbox.vue.ts"],"names":[],"mappings":";IAsEI;;;OAGG;;IAEH;;OAEG;;IAEH;;;OAGG;;IAEH;;OAEG;;;IAGH;;;OAGG;;;;;;;;IAtBH;;;OAGG;;IAEH;;OAEG;;IAEH;;;OAGG;;IAEH;;OAEG;;;IAGH;;;OAGG;;;;;;;;QAlBE,MAAM;WASH,KAAK,GAAG,QAAQ,GAAG,MAAM;;AA/ErC,wBAwIK;AACL,aAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AACjE,aAAK,6BAA6B,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAAG;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CAAE,CAAC;AAC9M,aAAK,kBAAkB,CAAC,CAAC,EAAE,CAAC,IAAI;KAE5B,CAAC,IAAI,MAAM,IAAI,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC,GAAG,CAAC,SAAS,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG;QACzD,OAAO,EAAE,CAAC,CAAC,CAAC,CAAC,CAAA;KACb,GAAG,CAAC,CAAC,CAAC,CAAC;CACR,CAAC"}
|
package/dist/index.es.js
CHANGED
|
@@ -47,11 +47,11 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
47
47
|
__name: "Checkbox",
|
|
48
48
|
props: {
|
|
49
49
|
id: { default: crypto.randomUUID() },
|
|
50
|
-
|
|
50
|
+
checked: { type: Boolean },
|
|
51
51
|
color: { default: "indigo" },
|
|
52
|
-
label: null,
|
|
53
52
|
disabled: { type: Boolean },
|
|
54
|
-
|
|
53
|
+
modelValue: { type: Boolean },
|
|
54
|
+
label: null
|
|
55
55
|
},
|
|
56
56
|
emits: ["update:modelValue"],
|
|
57
57
|
setup(__props, { emit }) {
|