@kiva/kv-components 3.8.0 → 3.9.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 CHANGED
@@ -3,6 +3,22 @@
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
+ # [3.9.0](https://github.com/kiva/kv-ui-elements/compare/@kiva/kv-components@3.8.0...@kiva/kv-components@3.9.0) (2022-10-07)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * removed extra space on line 23 ([c8a3226](https://github.com/kiva/kv-ui-elements/commit/c8a32264ede0b628f578b98c4ac8256a539fd28d))
12
+
13
+
14
+ ### Features
15
+
16
+ * fixed bugs in KvExpandableQuestion (arrow functionality and slot content rendering) ([4ab9f47](https://github.com/kiva/kv-ui-elements/commit/4ab9f477200d53b89ce6a4ae0328215268dd4019))
17
+
18
+
19
+
20
+
21
+
6
22
  # [3.8.0](https://github.com/kiva/kv-ui-elements/compare/@kiva/kv-components@3.7.1...@kiva/kv-components@3.8.0) (2022-10-04)
7
23
 
8
24
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kiva/kv-components",
3
- "version": "3.8.0",
3
+ "version": "3.9.0",
4
4
  "type": "module",
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -69,5 +69,5 @@
69
69
  "optional": true
70
70
  }
71
71
  },
72
- "gitHead": "ea1adfefc0d8e3169fc80b7745a01a6cd1b07c58"
72
+ "gitHead": "327d1a08978aeb0d03b2764368f558599a379dec"
73
73
  }
@@ -10,15 +10,20 @@
10
10
  <kv-material-icon
11
11
  class="tw-w-4 tw-h-4"
12
12
  :icon="open ? mdiChevronUp : mdiChevronDown"
13
- @click="open = !open"
13
+ @click="toggleFAQ"
14
14
  />
15
15
  </button>
16
16
  <kv-expandable easing="ease-in-out">
17
17
  <div
18
18
  v-show="open"
19
19
  class="tw-prose tw-pb-4 tw-pt-2"
20
- v-html="content"
21
20
  >
21
+ <slot></slot>
22
+ <div
23
+ v-if="content !== ''"
24
+ v-html="content"
25
+ >
26
+ </div>
22
27
  </div>
23
28
  </kv-expandable>
24
29
  </div>
@@ -22,17 +22,17 @@ export const Default = DefaultTemplate.bind({});
22
22
 
23
23
  const expandableQuestions = [
24
24
  {
25
- title: 'expandable question title one',
25
+ title: 'expandable question one',
26
26
  content: '<p> Hello, KvAccordion Contents! </p>',
27
27
  id: 'expandable-question-test-1',
28
28
  },
29
29
  {
30
- title: 'expandable question title two',
30
+ title: 'expandable question two',
31
31
  content: '<p> Hello, KvAccordion Contents! </p>',
32
32
  id: 'expandable-question-test-2',
33
33
  },
34
34
  {
35
- title: 'expandable question title three',
35
+ title: 'expandable question three',
36
36
  content: '<p> Hello, KvAccordion Contents! </p>',
37
37
  id: 'expandable-question-test-3',
38
38
  },
@@ -68,3 +68,19 @@ const GroupTemplate = () => ({
68
68
  });
69
69
 
70
70
  export const ExpandableSet = GroupTemplate.bind({});
71
+
72
+ const SlotContentTemplate = () => ({
73
+ components: { KvExpandableQuestion },
74
+ template: `
75
+ <div style="padding: 20px;">
76
+ <kv-expandable-question
77
+ id="expandable-question-test"
78
+ title="expandable question with slot content"
79
+ >
80
+ <p> A created slot! </p>
81
+ </kv-expandable-question>
82
+ </div>
83
+ `,
84
+ });
85
+
86
+ export const SlotContent = SlotContentTemplate.bind({});