@xplortech/apollo-core 0.5.2 → 0.5.3

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.
Files changed (173) hide show
  1. package/dist/apollo-core/apollo-core.css +5468 -9
  2. package/dist/apollo-core/apollo-core.esm.js +125 -1
  3. package/dist/apollo-core/app-globals-0f993ce5.js +3 -0
  4. package/dist/apollo-core/css-shim-bbdf0cc6.js +4 -0
  5. package/dist/apollo-core/dom-1f98a75f.js +73 -0
  6. package/dist/apollo-core/index-3c9f25ef.js +2938 -0
  7. package/dist/apollo-core/index-912d1a21.js +584 -0
  8. package/dist/apollo-core/index.esm.js +1 -0
  9. package/dist/{cjs/regular-872f5226.js → apollo-core/regular-133c23b5.js} +12 -3
  10. package/dist/apollo-core/shadow-css-67b66845.js +389 -0
  11. package/dist/apollo-core/xpl-application-shell.entry.js +50 -0
  12. package/dist/apollo-core/xpl-avatar.entry.js +19 -0
  13. package/dist/apollo-core/xpl-backdrop.entry.js +21 -0
  14. package/dist/{esm → apollo-core}/xpl-badge.entry.js +1 -1
  15. package/dist/{collection/components/xpl-breadcrumbs/xpl-breadcrumb-item/xpl-breadcrumb-item.js → apollo-core/xpl-breadcrumb-item.entry.js} +9 -12
  16. package/dist/apollo-core/xpl-breadcrumbs.entry.js +14 -0
  17. package/dist/{esm → apollo-core}/xpl-button-row.entry.js +1 -1
  18. package/dist/apollo-core/xpl-button.entry.js +34 -0
  19. package/dist/apollo-core/xpl-checkbox.entry.js +25 -0
  20. package/dist/{esm → apollo-core}/xpl-choicelist.entry.js +1 -1
  21. package/dist/apollo-core/xpl-content-area.entry.js +16 -0
  22. package/dist/{esm → apollo-core}/xpl-divider.entry.js +1 -1
  23. package/dist/{esm → apollo-core}/xpl-grid-item.entry.js +1 -1
  24. package/dist/{esm → apollo-core}/xpl-grid.entry.js +1 -1
  25. package/dist/{esm → apollo-core}/xpl-input.entry.js +20 -3
  26. package/dist/{esm → apollo-core}/xpl-list.entry.js +2 -2
  27. package/dist/apollo-core/xpl-main-nav.entry.js +26 -0
  28. package/dist/apollo-core/xpl-nav-item.entry.js +12 -0
  29. package/dist/{esm → apollo-core}/xpl-pagination.entry.js +1 -1
  30. package/dist/apollo-core/xpl-radio.entry.js +25 -0
  31. package/dist/apollo-core/xpl-secondary-nav.entry.js +12 -0
  32. package/dist/{esm → apollo-core}/xpl-select.entry.js +43 -3
  33. package/dist/{esm → apollo-core}/xpl-table.entry.js +1 -1
  34. package/dist/{esm → apollo-core}/xpl-tag.entry.js +1 -1
  35. package/dist/{esm → apollo-core}/xpl-toggle.entry.js +2 -2
  36. package/dist/apollo-core/xpl-utility-bar.entry.js +25 -0
  37. package/dist/types/components/xpl-choicelist/choice.d.ts +1 -1
  38. package/dist/types/components/xpl-choicelist/xpl-choicelist.d.ts +1 -0
  39. package/dist/types/components/xpl-dropdown/dropdownchoice.d.ts +5 -5
  40. package/dist/types/components/xpl-dropdown/xpl-dropdown.d.ts +1 -0
  41. package/dist/types/components/xpl-list/listitem.d.ts +15 -15
  42. package/dist/types/components/xpl-list/xpl-list.d.ts +1 -0
  43. package/dist/types/components/xpl-select/xpl-select.d.ts +1 -0
  44. package/dist/types/components.d.ts +3 -0
  45. package/package.json +1 -1
  46. package/dist/apollo-core/p-0203d4e8.entry.js +0 -1
  47. package/dist/apollo-core/p-0b2c612e.entry.js +0 -1
  48. package/dist/apollo-core/p-128a0240.entry.js +0 -1
  49. package/dist/apollo-core/p-2f90296c.js +0 -10
  50. package/dist/apollo-core/p-30003b15.entry.js +0 -1
  51. package/dist/apollo-core/p-4e56a2ca.entry.js +0 -1
  52. package/dist/apollo-core/p-5854d1e4.entry.js +0 -1
  53. package/dist/apollo-core/p-611536d8.entry.js +0 -1
  54. package/dist/apollo-core/p-7c9fee7e.entry.js +0 -1
  55. package/dist/apollo-core/p-8b6633c7.js +0 -1
  56. package/dist/apollo-core/p-97cd1f73.entry.js +0 -1
  57. package/dist/apollo-core/p-9c5ca308.entry.js +0 -1
  58. package/dist/apollo-core/p-ad90fe4d.js +0 -1
  59. package/dist/apollo-core/p-bd4a7e3c.entry.js +0 -1
  60. package/dist/apollo-core/p-dab8e7a1.entry.js +0 -1
  61. package/dist/apollo-core/p-eb63b401.entry.js +0 -1
  62. package/dist/apollo-core/p-ee2f4422.entry.js +0 -1
  63. package/dist/apollo-core/p-f167aa05.entry.js +0 -1
  64. package/dist/cjs/apollo-core.cjs.js +0 -19
  65. package/dist/cjs/index-944adb2e.js +0 -1609
  66. package/dist/cjs/index.cjs.js +0 -2
  67. package/dist/cjs/loader.cjs.js +0 -21
  68. package/dist/cjs/v4-14140ff3.js +0 -77
  69. package/dist/cjs/xpl-application-shell_11.cjs.entry.js +0 -230
  70. package/dist/cjs/xpl-badge.cjs.entry.js +0 -21
  71. package/dist/cjs/xpl-button-row.cjs.entry.js +0 -24
  72. package/dist/cjs/xpl-checkbox_2.cjs.entry.js +0 -51
  73. package/dist/cjs/xpl-choicelist.cjs.entry.js +0 -36
  74. package/dist/cjs/xpl-divider.cjs.entry.js +0 -18
  75. package/dist/cjs/xpl-grid-item.cjs.entry.js +0 -25
  76. package/dist/cjs/xpl-grid.cjs.entry.js +0 -35
  77. package/dist/cjs/xpl-input.cjs.entry.js +0 -2527
  78. package/dist/cjs/xpl-list.cjs.entry.js +0 -63
  79. package/dist/cjs/xpl-pagination.cjs.entry.js +0 -76
  80. package/dist/cjs/xpl-select.cjs.entry.js +0 -623
  81. package/dist/cjs/xpl-table.cjs.entry.js +0 -89
  82. package/dist/cjs/xpl-tag.cjs.entry.js +0 -21
  83. package/dist/cjs/xpl-toggle.cjs.entry.js +0 -34
  84. package/dist/collection/collection-manifest.json +0 -37
  85. package/dist/collection/components/xpl-application-shell/xpl-application-shell.js +0 -143
  86. package/dist/collection/components/xpl-avatar/xpl-avatar.js +0 -158
  87. package/dist/collection/components/xpl-backdrop/xpl-backdrop.js +0 -41
  88. package/dist/collection/components/xpl-badge/xpl-badge.js +0 -50
  89. package/dist/collection/components/xpl-breadcrumbs/xpl-breadcrumbs/xpl-breadcrumbs.js +0 -15
  90. package/dist/collection/components/xpl-button/xpl-button.js +0 -214
  91. package/dist/collection/components/xpl-button-row/xpl-button-row.js +0 -119
  92. package/dist/collection/components/xpl-checkbox/xpl-checkbox.js +0 -185
  93. package/dist/collection/components/xpl-choicelist/xpl-choicelist.js +0 -143
  94. package/dist/collection/components/xpl-content-area/xpl-content-area.js +0 -39
  95. package/dist/collection/components/xpl-divider/xpl-divider.js +0 -30
  96. package/dist/collection/components/xpl-dropdown/xpl-dropdown.js +0 -32
  97. package/dist/collection/components/xpl-grid/xpl-grid.js +0 -26
  98. package/dist/collection/components/xpl-grid-item/xpl-grid-item.js +0 -93
  99. package/dist/collection/components/xpl-input/xpl-input.js +0 -471
  100. package/dist/collection/components/xpl-list/xpl-list.js +0 -93
  101. package/dist/collection/components/xpl-main-nav/xpl-main-nav.js +0 -72
  102. package/dist/collection/components/xpl-nav-item/xpl-nav-item.js +0 -10
  103. package/dist/collection/components/xpl-pagination/xpl-pagination.js +0 -189
  104. package/dist/collection/components/xpl-radio/xpl-radio.js +0 -168
  105. package/dist/collection/components/xpl-secondary-nav/xpl-secondary-nav.js +0 -9
  106. package/dist/collection/components/xpl-select/xpl-select.js +0 -311
  107. package/dist/collection/components/xpl-table/xpl-table.js +0 -194
  108. package/dist/collection/components/xpl-tag/xpl-tag.js +0 -30
  109. package/dist/collection/components/xpl-toggle/xpl-toggle.js +0 -157
  110. package/dist/collection/components/xpl-utility-bar/xpl-utility-bar.js +0 -70
  111. package/dist/custom-elements/index.js +0 -19959
  112. package/dist/esm/apollo-core.js +0 -17
  113. package/dist/esm/index-899dba3b.js +0 -1580
  114. package/dist/esm/index.js +0 -1
  115. package/dist/esm/loader.js +0 -17
  116. package/dist/esm/polyfills/core-js.js +0 -11
  117. package/dist/esm/polyfills/css-shim.js +0 -1
  118. package/dist/esm/polyfills/dom.js +0 -79
  119. package/dist/esm/polyfills/es5-html-element.js +0 -1
  120. package/dist/esm/polyfills/index.js +0 -34
  121. package/dist/esm/polyfills/system.js +0 -6
  122. package/dist/esm/regular-86225e9d.js +0 -16041
  123. package/dist/esm/v4-929670b7.js +0 -75
  124. package/dist/esm/xpl-application-shell_11.entry.js +0 -216
  125. package/dist/esm/xpl-checkbox_2.entry.js +0 -46
  126. package/dist/index.cjs.js +0 -1
  127. package/dist/index.js +0 -1
  128. package/dist/stories/application-shell.stories.js +0 -766
  129. package/dist/stories/avatar.stories.js +0 -173
  130. package/dist/stories/backdrop.stories.js +0 -18
  131. package/dist/stories/badge.stories.js +0 -48
  132. package/dist/stories/breadcrumbs.stories.js +0 -115
  133. package/dist/stories/button-row.stories.js +0 -64
  134. package/dist/stories/button.stories.js +0 -98
  135. package/dist/stories/checkbox.stories.js +0 -76
  136. package/dist/stories/choicelist.stories.js +0 -112
  137. package/dist/stories/content-area.stories.js +0 -53
  138. package/dist/stories/divider.stories.js +0 -34
  139. package/dist/stories/grid.stories.js +0 -100
  140. package/dist/stories/input.stories.js +0 -252
  141. package/dist/stories/list.stories.js +0 -134
  142. package/dist/stories/main-nav.stories.js +0 -308
  143. package/dist/stories/pagination.stories.js +0 -84
  144. package/dist/stories/radio.stories.js +0 -66
  145. package/dist/stories/secondary-nav.stories.js +0 -76
  146. package/dist/stories/select.stories.js +0 -111
  147. package/dist/stories/table.stories.js +0 -107
  148. package/dist/stories/tabs.stories.js +0 -24
  149. package/dist/stories/toggle.stories.js +0 -80
  150. package/dist/stories/utility-bar.stories.js +0 -94
  151. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/application-shell.stories.d.ts +0 -0
  152. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/avatar.stories.d.ts +0 -0
  153. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/backdrop.stories.d.ts +0 -0
  154. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/badge.stories.d.ts +0 -0
  155. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/breadcrumbs.stories.d.ts +0 -0
  156. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/button-row.stories.d.ts +0 -0
  157. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/button.stories.d.ts +0 -0
  158. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/checkbox.stories.d.ts +0 -0
  159. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/choicelist.stories.d.ts +0 -0
  160. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/content-area.stories.d.ts +0 -0
  161. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/divider.stories.d.ts +0 -0
  162. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/grid.stories.d.ts +0 -0
  163. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/input.stories.d.ts +0 -0
  164. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/list.stories.d.ts +0 -0
  165. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/main-nav.stories.d.ts +0 -0
  166. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/pagination.stories.d.ts +0 -0
  167. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/radio.stories.d.ts +0 -0
  168. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/secondary-nav.stories.d.ts +0 -0
  169. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/select.stories.d.ts +0 -0
  170. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/table.stories.d.ts +0 -0
  171. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/tabs.stories.d.ts +0 -0
  172. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/toggle.stories.d.ts +0 -0
  173. /package/dist/types/Users/{fernandogelin/Projects → roc/Sites}/apollo/.stencil/stories/utility-bar.stories.d.ts +0 -0
@@ -1,214 +0,0 @@
1
- import { Component, Host, h, Prop } from "@stencil/core";
2
- import "../../../font-awesome/fontawesome";
3
- import "../../../font-awesome/regular";
4
- export class XplButton {
5
- constructor() {
6
- this.size = "default";
7
- this.variant = "primary";
8
- }
9
- render() {
10
- let className = "xpl-button";
11
- if (this.variant === "secondary")
12
- className += " xpl-button--secondary";
13
- if (this.variant === "subtle")
14
- className += " xpl-button--subtle";
15
- if (this.variant === "warning")
16
- className += " xpl-button--warning";
17
- if (this.size === "sm")
18
- className += " xpl-button--sm";
19
- if (this.size === "xs")
20
- className += " xpl-button--xs";
21
- if (this.iconOnly)
22
- className += " xpl-button--icon-only";
23
- const icon = this.icon ? (h("i", { class: `far fa-${this.icon} ${this.iconTrailing ? "trailing" : this.iconOnly ? "" : "leading"}` })) : null;
24
- return (h(Host, { role: "button" },
25
- /**
26
- * Conditionally render either an <a> or <button> element
27
- * depending on if there's an `href` or not
28
- */
29
- this.href ? (h("a", { class: className, href: this.href, role: "button" },
30
- !this.iconTrailing && icon,
31
- this.iconOnly ? (h("span", { class: "sr-only" },
32
- h("slot", null))) : (h("slot", null)),
33
- this.iconTrailing && icon)) : (h("button", { class: className, disabled: this.disabled, name: this.name, type: this.type, value: this.value },
34
- !this.iconTrailing && icon,
35
- this.iconOnly ? (h("span", { class: "sr-only" },
36
- h("slot", null))) : (h("slot", null)),
37
- this.iconTrailing && icon))));
38
- }
39
- static get is() { return "xpl-button"; }
40
- static get properties() { return {
41
- "disabled": {
42
- "type": "boolean",
43
- "mutable": false,
44
- "complexType": {
45
- "original": "boolean",
46
- "resolved": "boolean",
47
- "references": {}
48
- },
49
- "required": false,
50
- "optional": true,
51
- "docs": {
52
- "tags": [],
53
- "text": ""
54
- },
55
- "attribute": "disabled",
56
- "reflect": false
57
- },
58
- "href": {
59
- "type": "string",
60
- "mutable": false,
61
- "complexType": {
62
- "original": "string",
63
- "resolved": "string",
64
- "references": {}
65
- },
66
- "required": false,
67
- "optional": true,
68
- "docs": {
69
- "tags": [],
70
- "text": ""
71
- },
72
- "attribute": "href",
73
- "reflect": false
74
- },
75
- "icon": {
76
- "type": "string",
77
- "mutable": false,
78
- "complexType": {
79
- "original": "string",
80
- "resolved": "string",
81
- "references": {}
82
- },
83
- "required": false,
84
- "optional": true,
85
- "docs": {
86
- "tags": [],
87
- "text": ""
88
- },
89
- "attribute": "icon",
90
- "reflect": false
91
- },
92
- "iconOnly": {
93
- "type": "boolean",
94
- "mutable": false,
95
- "complexType": {
96
- "original": "boolean",
97
- "resolved": "boolean",
98
- "references": {}
99
- },
100
- "required": false,
101
- "optional": true,
102
- "docs": {
103
- "tags": [],
104
- "text": ""
105
- },
106
- "attribute": "icon-only",
107
- "reflect": false
108
- },
109
- "iconTrailing": {
110
- "type": "boolean",
111
- "mutable": false,
112
- "complexType": {
113
- "original": "boolean",
114
- "resolved": "boolean",
115
- "references": {}
116
- },
117
- "required": false,
118
- "optional": true,
119
- "docs": {
120
- "tags": [],
121
- "text": ""
122
- },
123
- "attribute": "icon-trailing",
124
- "reflect": false
125
- },
126
- "name": {
127
- "type": "string",
128
- "mutable": false,
129
- "complexType": {
130
- "original": "string",
131
- "resolved": "string",
132
- "references": {}
133
- },
134
- "required": false,
135
- "optional": true,
136
- "docs": {
137
- "tags": [],
138
- "text": ""
139
- },
140
- "attribute": "name",
141
- "reflect": false
142
- },
143
- "size": {
144
- "type": "string",
145
- "mutable": false,
146
- "complexType": {
147
- "original": "\"default\" | \"sm\" | \"xs\"",
148
- "resolved": "\"default\" | \"sm\" | \"xs\"",
149
- "references": {}
150
- },
151
- "required": false,
152
- "optional": false,
153
- "docs": {
154
- "tags": [],
155
- "text": ""
156
- },
157
- "attribute": "size",
158
- "reflect": false,
159
- "defaultValue": "\"default\""
160
- },
161
- "type": {
162
- "type": "string",
163
- "mutable": false,
164
- "complexType": {
165
- "original": "\"submit\" | \"reset\" | \"button\"",
166
- "resolved": "\"button\" | \"reset\" | \"submit\"",
167
- "references": {}
168
- },
169
- "required": false,
170
- "optional": true,
171
- "docs": {
172
- "tags": [],
173
- "text": ""
174
- },
175
- "attribute": "type",
176
- "reflect": false
177
- },
178
- "value": {
179
- "type": "string",
180
- "mutable": false,
181
- "complexType": {
182
- "original": "string",
183
- "resolved": "string",
184
- "references": {}
185
- },
186
- "required": false,
187
- "optional": true,
188
- "docs": {
189
- "tags": [],
190
- "text": ""
191
- },
192
- "attribute": "value",
193
- "reflect": false
194
- },
195
- "variant": {
196
- "type": "string",
197
- "mutable": false,
198
- "complexType": {
199
- "original": "\"primary\" | \"secondary\" | \"subtle\" | \"warning\"",
200
- "resolved": "\"primary\" | \"secondary\" | \"subtle\" | \"warning\"",
201
- "references": {}
202
- },
203
- "required": false,
204
- "optional": false,
205
- "docs": {
206
- "tags": [],
207
- "text": ""
208
- },
209
- "attribute": "variant",
210
- "reflect": false,
211
- "defaultValue": "\"primary\""
212
- }
213
- }; }
214
- }
@@ -1,119 +0,0 @@
1
- import { Component, Host, h, Prop, Event } from '@stencil/core';
2
- export class XplButtonRow {
3
- constructor() {
4
- this.onPrimary = () => this.clickPrimary.emit();
5
- this.onSecondary = () => this.clickSecondary.emit();
6
- this.onTertiary = () => this.clickTertiary.emit();
7
- }
8
- render() {
9
- return (h(Host, { class: "xpl-button-row" },
10
- h("div", { class: "xpl-button-row-inner" },
11
- h("div", { class: "xpl-button-row__left" }, this.secondary &&
12
- h("xpl-button", { variant: "secondary", type: "button", onClick: this.onSecondary }, this.secondary)),
13
- h("div", { class: "xpl-button-row__right" },
14
- this.tertiary && h("xpl-button", { variant: "subtle", type: "button", onClick: this.onTertiary }, this.tertiary),
15
- this.secondary &&
16
- h("xpl-button", { variant: "secondary", type: "button", onClick: this.onSecondary }, this.secondary),
17
- this.primary && h("xpl-button", { class: "xpl-button-row__primary", onClick: this.onPrimary }, this.primary)))));
18
- }
19
- static get is() { return "xpl-button-row"; }
20
- static get properties() { return {
21
- "primary": {
22
- "type": "string",
23
- "mutable": false,
24
- "complexType": {
25
- "original": "\"string\"",
26
- "resolved": "\"string\"",
27
- "references": {}
28
- },
29
- "required": false,
30
- "optional": false,
31
- "docs": {
32
- "tags": [],
33
- "text": "The text for the primary button."
34
- },
35
- "attribute": "primary",
36
- "reflect": false
37
- },
38
- "secondary": {
39
- "type": "string",
40
- "mutable": false,
41
- "complexType": {
42
- "original": "\"string\"",
43
- "resolved": "\"string\"",
44
- "references": {}
45
- },
46
- "required": false,
47
- "optional": false,
48
- "docs": {
49
- "tags": [],
50
- "text": "The text for the secondary button. If left\nempty, will not render a secondary button."
51
- },
52
- "attribute": "secondary",
53
- "reflect": false
54
- },
55
- "tertiary": {
56
- "type": "string",
57
- "mutable": false,
58
- "complexType": {
59
- "original": "\"string\"",
60
- "resolved": "\"string\"",
61
- "references": {}
62
- },
63
- "required": false,
64
- "optional": false,
65
- "docs": {
66
- "tags": [],
67
- "text": "The text for the tertiary button. If left\nempty, will not render a secondary button."
68
- },
69
- "attribute": "tertiary",
70
- "reflect": false
71
- }
72
- }; }
73
- static get events() { return [{
74
- "method": "clickPrimary",
75
- "name": "clickPrimary",
76
- "bubbles": true,
77
- "cancelable": true,
78
- "composed": true,
79
- "docs": {
80
- "tags": [],
81
- "text": "Fires on the primary button.\nIf not set, the button can act as a standard\nsubmit button for a form."
82
- },
83
- "complexType": {
84
- "original": "any",
85
- "resolved": "any",
86
- "references": {}
87
- }
88
- }, {
89
- "method": "clickSecondary",
90
- "name": "clickSecondary",
91
- "bubbles": true,
92
- "cancelable": true,
93
- "composed": true,
94
- "docs": {
95
- "tags": [],
96
- "text": "Adds an event listener to the secondary button."
97
- },
98
- "complexType": {
99
- "original": "any",
100
- "resolved": "any",
101
- "references": {}
102
- }
103
- }, {
104
- "method": "clickTertiary",
105
- "name": "clickTertiary",
106
- "bubbles": true,
107
- "cancelable": true,
108
- "composed": true,
109
- "docs": {
110
- "tags": [],
111
- "text": "Adds an event listener to the tertiary button."
112
- },
113
- "complexType": {
114
- "original": "any",
115
- "resolved": "any",
116
- "references": {}
117
- }
118
- }]; }
119
- }
@@ -1,185 +0,0 @@
1
- import { Component, Host, h, Prop, State, Event } from "@stencil/core";
2
- import { v4 as uuid } from "uuid";
3
- export class XplCheckbox {
4
- constructor() {
5
- this.id = uuid();
6
- }
7
- render() {
8
- return (h(Host, { class: {
9
- "xpl-checkbox-radio-container": true,
10
- "styled": this.styled,
11
- "disabled": this.disabled,
12
- } },
13
- h("input", { class: "xpl-checkbox", type: "checkbox", checked: this.checked, disabled: this.disabled, id: this.id, indeterminate: this.indeterminate, onChange: () => this.checkboxChange.emit(this.input.checked), name: this.name, ref: (el) => (this.input = el), required: this.required, value: this.value }),
14
- h("label", { class: {
15
- "xpl-label": true,
16
- "xpl-label--disabled": this.disabled
17
- }, htmlFor: this.id },
18
- h("slot", null),
19
- this.description && h("small", { class: {
20
- "xpl-description": true,
21
- "xpl-description--disabled": this.disabled
22
- } }, this.description))));
23
- }
24
- static get is() { return "xpl-checkbox"; }
25
- static get properties() { return {
26
- "checked": {
27
- "type": "boolean",
28
- "mutable": false,
29
- "complexType": {
30
- "original": "boolean",
31
- "resolved": "boolean",
32
- "references": {}
33
- },
34
- "required": false,
35
- "optional": true,
36
- "docs": {
37
- "tags": [],
38
- "text": ""
39
- },
40
- "attribute": "checked",
41
- "reflect": false
42
- },
43
- "description": {
44
- "type": "string",
45
- "mutable": false,
46
- "complexType": {
47
- "original": "string",
48
- "resolved": "string",
49
- "references": {}
50
- },
51
- "required": false,
52
- "optional": true,
53
- "docs": {
54
- "tags": [],
55
- "text": ""
56
- },
57
- "attribute": "description",
58
- "reflect": false
59
- },
60
- "disabled": {
61
- "type": "boolean",
62
- "mutable": false,
63
- "complexType": {
64
- "original": "boolean",
65
- "resolved": "boolean",
66
- "references": {}
67
- },
68
- "required": false,
69
- "optional": true,
70
- "docs": {
71
- "tags": [],
72
- "text": ""
73
- },
74
- "attribute": "disabled",
75
- "reflect": false
76
- },
77
- "indeterminate": {
78
- "type": "boolean",
79
- "mutable": false,
80
- "complexType": {
81
- "original": "boolean",
82
- "resolved": "boolean",
83
- "references": {}
84
- },
85
- "required": false,
86
- "optional": true,
87
- "docs": {
88
- "tags": [],
89
- "text": ""
90
- },
91
- "attribute": "indeterminate",
92
- "reflect": false
93
- },
94
- "name": {
95
- "type": "string",
96
- "mutable": false,
97
- "complexType": {
98
- "original": "string",
99
- "resolved": "string",
100
- "references": {}
101
- },
102
- "required": false,
103
- "optional": true,
104
- "docs": {
105
- "tags": [],
106
- "text": ""
107
- },
108
- "attribute": "name",
109
- "reflect": false
110
- },
111
- "required": {
112
- "type": "boolean",
113
- "mutable": false,
114
- "complexType": {
115
- "original": "boolean",
116
- "resolved": "boolean",
117
- "references": {}
118
- },
119
- "required": false,
120
- "optional": true,
121
- "docs": {
122
- "tags": [],
123
- "text": ""
124
- },
125
- "attribute": "required",
126
- "reflect": false
127
- },
128
- "styled": {
129
- "type": "boolean",
130
- "mutable": false,
131
- "complexType": {
132
- "original": "boolean",
133
- "resolved": "boolean",
134
- "references": {}
135
- },
136
- "required": false,
137
- "optional": true,
138
- "docs": {
139
- "tags": [],
140
- "text": ""
141
- },
142
- "attribute": "styled",
143
- "reflect": false
144
- },
145
- "value": {
146
- "type": "string",
147
- "mutable": false,
148
- "complexType": {
149
- "original": "string",
150
- "resolved": "string",
151
- "references": {}
152
- },
153
- "required": false,
154
- "optional": true,
155
- "docs": {
156
- "tags": [],
157
- "text": ""
158
- },
159
- "attribute": "value",
160
- "reflect": false
161
- }
162
- }; }
163
- static get states() { return {
164
- "id": {}
165
- }; }
166
- static get events() { return [{
167
- "method": "checkboxChange",
168
- "name": "checkboxChange",
169
- "bubbles": true,
170
- "cancelable": true,
171
- "composed": true,
172
- "docs": {
173
- "tags": [{
174
- "text": undefined,
175
- "name": "private"
176
- }],
177
- "text": ""
178
- },
179
- "complexType": {
180
- "original": "any",
181
- "resolved": "any",
182
- "references": {}
183
- }
184
- }]; }
185
- }
@@ -1,143 +0,0 @@
1
- /// <reference path="./choice.d.ts"></reference>
2
- import { Component, Host, h, Prop, State } from "@stencil/core";
3
- export class XplChoicelist {
4
- componentWillLoad() {
5
- this.selected = this.choices !== undefined && this.choices !== null && this.choices.length > 0 ? this.choices.map(() => false) : [];
6
- }
7
- render() {
8
- let className = "xpl-choicelist";
9
- if (this.styled)
10
- className += " xpl-choicelist--styled";
11
- return (h(Host, { class: "xpl-choicelist-container" },
12
- this.heading !== undefined || this.description !== undefined ? h("div", { class: "xpl-choicelist-heading" },
13
- this.heading && h("h3", null, this.heading),
14
- this.description && h("p", null, this.description)) : null,
15
- this.choices && (h("ul", { class: className }, this.choices.map(({ children, description, label }, i) => {
16
- const inner = this.multi ? (h("xpl-checkbox", { description: description, name: this.name, onCheckboxChange: (e) => {
17
- const { detail } = e;
18
- this.selected = this.selected.map((v, j) => i === j ? detail : v);
19
- } }, label)) : (h("xpl-radio", { description: description, name: this.name, onRadioChange: () => {
20
- // TypeScript errors since `v` isn't used
21
- // @ts-expect-error
22
- this.selected = this.selected.map((v, j) => i === j);
23
- } }, label));
24
- let className = this.styled && this.selected[i] ? "selected" : "";
25
- return (h("li", { class: className },
26
- inner,
27
- children && h("ul", null, children.map((child) => {
28
- const childInner = this.multi ? (h("xpl-checkbox", { description: child.description }, child.label)) : (h("xpl-radio", { description: child.description }, child.label));
29
- return h("li", null, childInner);
30
- }))));
31
- })))));
32
- }
33
- static get is() { return "xpl-choicelist"; }
34
- static get properties() { return {
35
- "choices": {
36
- "type": "unknown",
37
- "mutable": false,
38
- "complexType": {
39
- "original": "Choice[]",
40
- "resolved": "Choice[]",
41
- "references": {
42
- "Choice": {
43
- "location": "global"
44
- }
45
- }
46
- },
47
- "required": false,
48
- "optional": false,
49
- "docs": {
50
- "tags": [],
51
- "text": "An array of choices to be displayed in the list.\nEach choice should be an object with keys:\n- `checked` [boolean] - whether to precheck or not\n- `children` [Choice[]] - an array of child choices (recursive)\n- `description` [string]\n- `label` [string]"
52
- }
53
- },
54
- "description": {
55
- "type": "string",
56
- "mutable": false,
57
- "complexType": {
58
- "original": "string",
59
- "resolved": "string",
60
- "references": {}
61
- },
62
- "required": false,
63
- "optional": true,
64
- "docs": {
65
- "tags": [],
66
- "text": "Descriptive text to be displayed above the choicelist."
67
- },
68
- "attribute": "description",
69
- "reflect": false
70
- },
71
- "heading": {
72
- "type": "string",
73
- "mutable": false,
74
- "complexType": {
75
- "original": "string",
76
- "resolved": "string",
77
- "references": {}
78
- },
79
- "required": false,
80
- "optional": true,
81
- "docs": {
82
- "tags": [],
83
- "text": "The title text to be displayed above the choicelist."
84
- },
85
- "attribute": "heading",
86
- "reflect": false
87
- },
88
- "multi": {
89
- "type": "boolean",
90
- "mutable": false,
91
- "complexType": {
92
- "original": "boolean",
93
- "resolved": "boolean",
94
- "references": {}
95
- },
96
- "required": false,
97
- "optional": true,
98
- "docs": {
99
- "tags": [],
100
- "text": "Whether the user can select more than one choice (true) or only a single choice (false). Corresponds to checkboxes vs. radio buttons."
101
- },
102
- "attribute": "multi",
103
- "reflect": false
104
- },
105
- "name": {
106
- "type": "string",
107
- "mutable": false,
108
- "complexType": {
109
- "original": "string",
110
- "resolved": "string",
111
- "references": {}
112
- },
113
- "required": false,
114
- "optional": true,
115
- "docs": {
116
- "tags": [],
117
- "text": "The `name` to be associated with form data."
118
- },
119
- "attribute": "name",
120
- "reflect": false
121
- },
122
- "styled": {
123
- "type": "boolean",
124
- "mutable": false,
125
- "complexType": {
126
- "original": "boolean",
127
- "resolved": "boolean",
128
- "references": {}
129
- },
130
- "required": false,
131
- "optional": true,
132
- "docs": {
133
- "tags": [],
134
- "text": "If `true`, will include borders around the list and between individual choices."
135
- },
136
- "attribute": "styled",
137
- "reflect": false
138
- }
139
- }; }
140
- static get states() { return {
141
- "selected": {}
142
- }; }
143
- }
@@ -1,39 +0,0 @@
1
- import { Component, Host, h, Prop } from '@stencil/core';
2
- export class XplContentArea {
3
- constructor() {
4
- /**
5
- * @property {string} size - The content-area size.
6
- */
7
- this.size = "wide";
8
- }
9
- render() {
10
- return (h(Host, null,
11
- h("main", { class: `xpl-content-area-wrapper xpl-content-area-wrapper__${this.size}` },
12
- h("div", { class: "xpl-content-area" },
13
- h("slot", null)))));
14
- }
15
- static get is() { return "xpl-content-area"; }
16
- static get properties() { return {
17
- "size": {
18
- "type": "string",
19
- "mutable": false,
20
- "complexType": {
21
- "original": "\"wide\" | \"narrow\" | \"full\"",
22
- "resolved": "\"full\" | \"narrow\" | \"wide\"",
23
- "references": {}
24
- },
25
- "required": false,
26
- "optional": false,
27
- "docs": {
28
- "tags": [{
29
- "text": "{string} size - The content-area size.",
30
- "name": "property"
31
- }],
32
- "text": ""
33
- },
34
- "attribute": "size",
35
- "reflect": false,
36
- "defaultValue": "\"wide\""
37
- }
38
- }; }
39
- }