@kiva/kv-components 1.1.2 → 1.2.2

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 CHANGED
@@ -3,6 +3,44 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [1.2.2](https://github.com/kiva/kv-ui-elements/compare/@kiva/kv-components@1.2.1...@kiva/kv-components@1.2.2) (2021-11-24)
7
+
8
+ **Note:** Version bump only for package @kiva/kv-components
9
+
10
+
11
+
12
+
13
+
14
+ ## [1.2.1](https://github.com/kiva/kv-ui-elements/compare/@kiva/kv-components@1.2.0...@kiva/kv-components@1.2.1) (2021-11-17)
15
+
16
+ **Note:** Version bump only for package @kiva/kv-components
17
+
18
+
19
+
20
+
21
+
22
+ # [1.2.0](https://github.com/kiva/kv-ui-elements/compare/@kiva/kv-components@1.1.3...@kiva/kv-components@1.2.0) (2021-11-12)
23
+
24
+
25
+ ### Features
26
+
27
+ * **KvCheckbox:** add a prop and visual styling to tell a user the input is invalid ([b587ffd](https://github.com/kiva/kv-ui-elements/commit/b587ffdcb4834eb6dda25a880646cdcd4137a337))
28
+
29
+
30
+
31
+
32
+
33
+ ## [1.1.3](https://github.com/kiva/kv-ui-elements/compare/@kiva/kv-components@1.1.2...@kiva/kv-components@1.1.3) (2021-11-10)
34
+
35
+
36
+ ### Bug Fixes
37
+
38
+ * **KvLightbox:** allow for an empty lightbox body ([3d36755](https://github.com/kiva/kv-ui-elements/commit/3d367551d52dcc1d1b3aea7d98b7e733cd703ddc))
39
+
40
+
41
+
42
+
43
+
6
44
  ## [1.1.2](https://github.com/kiva/kv-ui-elements/compare/@kiva/kv-components@1.1.1...@kiva/kv-components@1.1.2) (2021-11-08)
7
45
 
8
46
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kiva/kv-components",
3
- "version": "1.1.2",
3
+ "version": "1.2.2",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -46,7 +46,7 @@
46
46
  "test": "jest"
47
47
  },
48
48
  "dependencies": {
49
- "@kiva/kv-tokens": "^1.1.0",
49
+ "@kiva/kv-tokens": "^1.2.1",
50
50
  "@mdi/js": "^5.9.55",
51
51
  "aria-hidden": "^1.1.3",
52
52
  "embla-carousel": "^4.5.3",
@@ -54,5 +54,5 @@
54
54
  "vue": "^2.6.12",
55
55
  "vue-focus-lock": "^1.4.1"
56
56
  },
57
- "gitHead": "b03a6318531a48279ba1455c30ab6a2472151431"
57
+ "gitHead": "766ee90e4bae55b37a638e9dd30c01aac140f6b0"
58
58
  }
@@ -28,8 +28,11 @@
28
28
  tw-transition-all tw-duration-100
29
29
  peer-focus-visible:tw-ring-2 peer-focus-visible:tw-ring-action"
30
30
  :class="{
31
- 'tw-bg-white tw-border-secondary' : !isChecked,
32
- 'tw-bg-action tw-border-action' : isChecked,
31
+ 'tw-bg-white' : !isChecked,
32
+ 'tw-bg-action' : isChecked,
33
+ 'tw-border-secondary' : !isChecked && valid,
34
+ 'tw-border-action' : isChecked && valid,
35
+ 'tw-border-danger' : !valid,
33
36
  }"
34
37
  >
35
38
  <!-- checkbox icon -->
@@ -93,6 +96,14 @@ export default {
93
96
  type: String,
94
97
  default: '',
95
98
  },
99
+ /**
100
+ * When set to false, visually indicates to the user that the contents of the input need
101
+ * to be changed
102
+ * */
103
+ valid: {
104
+ type: Boolean,
105
+ default: true,
106
+ },
96
107
  },
97
108
  data() {
98
109
  return {
@@ -104,7 +104,7 @@
104
104
  "
105
105
  >
106
106
  <!-- @slot default -->
107
- <slot>Lightbox body</slot>
107
+ <slot></slot>
108
108
  </div>
109
109
 
110
110
  <!-- controls -->
@@ -6,6 +6,7 @@ export default {
6
6
  args: {
7
7
  checked: false,
8
8
  disabled: false,
9
+ valid: true,
9
10
  },
10
11
  };
11
12
 
@@ -23,6 +24,7 @@ const Template = (args, {
23
24
  <div>
24
25
  <kv-checkbox
25
26
  :disabled="disabled"
27
+ :valid="valid"
26
28
  v-model="checkboxExampleModel"
27
29
  @change="onChange"
28
30
  @focus="onFocus"
@@ -47,6 +49,11 @@ Disabled.args = {
47
49
  disabled: true,
48
50
  };
49
51
 
52
+ export const Invalid = Template.bind({});
53
+ Invalid.args = {
54
+ valid: false,
55
+ };
56
+
50
57
  export const WithoutVModel = (args, {
51
58
  argTypes,
52
59
  }) => ({