@rededor/cura 0.3.4-alpha.0 → 0.3.4-alpha.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.
Files changed (188) hide show
  1. package/dist/cjs/{app-globals-a41d7f40.js → app-globals-0f70160b.js} +17 -40
  2. package/dist/cjs/cura-display_4.cjs.entry.js +257 -0
  3. package/dist/cjs/cura-icon.cjs.entry.js +59 -0
  4. package/dist/cjs/cura-icons-view.cjs.entry.js +2 -4
  5. package/dist/cjs/cura.cjs.js +4 -19
  6. package/dist/cjs/{index-29633529.js → index-76f95c4b.js} +39 -502
  7. package/dist/cjs/index.cjs.js +0 -2
  8. package/dist/cjs/loader.cjs.js +4 -23
  9. package/dist/collection/api/cura-api.js +0 -1
  10. package/dist/collection/api/cura-api.type.js +0 -1
  11. package/dist/collection/api/modules/cura-theme-colors-module.js +0 -1
  12. package/dist/collection/api/modules/cura-theme-fonts-module.js +0 -1
  13. package/dist/collection/api/modules/cura-theme-module.js +0 -1
  14. package/dist/collection/api/modules/cura-theme-spacing-module.js +0 -1
  15. package/dist/collection/api/theme-presets/static.js +0 -1
  16. package/dist/collection/api/theme-presets/theme-default.js +5 -6
  17. package/dist/collection/api/theme-presets/theme-maternity.js +0 -8
  18. package/dist/collection/api/theme-presets/theme-oncology.js +12 -27
  19. package/dist/collection/api/theme-presets/theme-presets.js +0 -1
  20. package/dist/collection/assets/icons/iconset-default-list.js +0 -1
  21. package/dist/collection/collection-manifest.json +2 -3
  22. package/dist/collection/components/cura-icon/cura-icon.css +2 -2
  23. package/dist/collection/components/cura-icon/cura-icon.js +5 -8
  24. package/dist/collection/components/cura-icons-view/cura-icons-view.js +1 -3
  25. package/dist/collection/components/cura-page-template/cura-page-template.css +24 -24
  26. package/dist/collection/components/cura-page-template/cura-page-template.js +1 -3
  27. package/dist/collection/components/text/cura-display/cura-display.css +14 -13
  28. package/dist/collection/components/text/cura-display/cura-display.js +17 -3
  29. package/dist/collection/components/text/cura-heading/cura-heading.css +15 -15
  30. package/dist/collection/components/text/cura-heading/cura-heading.js +21 -3
  31. package/dist/collection/components/text/cura-paragraph/cura-paragraph.css +17 -16
  32. package/dist/collection/components/text/cura-paragraph/cura-paragraph.js +13 -3
  33. package/dist/collection/index.js +0 -1
  34. package/dist/collection/rededor-cura-start.js +0 -1
  35. package/dist/collection/utils/utils.js +0 -1
  36. package/dist/components/cura-display.js +20 -7
  37. package/dist/components/cura-heading.js +24 -7
  38. package/dist/components/cura-icon.js +0 -2
  39. package/dist/components/cura-icon2.js +8 -12
  40. package/dist/components/cura-icons-view.js +3 -6
  41. package/dist/components/cura-page-template.js +4 -7
  42. package/dist/components/cura-paragraph.js +16 -7
  43. package/dist/components/index.d.ts +9 -21
  44. package/dist/components/index.js +24 -67
  45. package/dist/cura/cura.esm.js +1 -2
  46. package/dist/cura/cura.js +1 -3
  47. package/dist/cura/index.esm.js +0 -2
  48. package/dist/cura/p-0b79032f.system.js +2 -0
  49. package/dist/cura/p-11002b56.system.js +1 -0
  50. package/dist/cura/p-32769783.system.js +1 -0
  51. package/dist/cura/p-50ea2036.system.js +1 -2
  52. package/dist/cura/{p-958c8695.system.entry.js → p-54c09404.system.entry.js} +1 -2
  53. package/dist/cura/p-57c5329e.js +2 -0
  54. package/dist/cura/p-5a6643e1.entry.js +1 -0
  55. package/dist/cura/p-a2ad5637.system.entry.js +1 -0
  56. package/dist/cura/p-aca36c98.js +1 -0
  57. package/dist/cura/p-bd91ecb9.system.entry.js +1 -0
  58. package/dist/cura/p-d69916ee.entry.js +1 -0
  59. package/dist/cura/p-f8a5b97d.entry.js +1 -0
  60. package/dist/dist/loader/index.d.ts +0 -9
  61. package/dist/esm/{app-globals-8ed931e6.js → app-globals-cb45bff3.js} +17 -40
  62. package/dist/esm/cura-display_4.entry.js +250 -0
  63. package/dist/esm/cura-icon.entry.js +55 -0
  64. package/dist/esm/cura-icons-view.entry.js +2 -4
  65. package/dist/esm/cura.js +4 -16
  66. package/dist/esm/{index-e11775ce.js → index-7e8c969d.js} +40 -499
  67. package/dist/esm/index.js +0 -2
  68. package/dist/esm/loader.js +4 -23
  69. package/dist/esm/polyfills/css-shim.js +1 -1
  70. package/dist/esm-es5/app-globals-cb45bff3.js +1 -0
  71. package/dist/esm-es5/cura-display_4.entry.js +1 -0
  72. package/dist/esm-es5/cura-icon.entry.js +1 -0
  73. package/dist/esm-es5/cura-icons-view.entry.js +1 -2
  74. package/dist/esm-es5/cura.js +1 -2
  75. package/dist/esm-es5/index-7e8c969d.js +2 -0
  76. package/dist/esm-es5/index.js +0 -2
  77. package/dist/esm-es5/loader.js +1 -2
  78. package/dist/types/api/theme-presets/theme-maternity.d.ts +0 -7
  79. package/dist/types/api/theme-presets/theme-oncology.d.ts +5 -5
  80. package/dist/types/api/theme-presets/theme-presets.d.ts +5 -12
  81. package/dist/types/components.d.ts +0 -93
  82. package/dist/types/stencil-public-runtime.d.ts +15 -77
  83. package/package.json +7 -7
  84. package/dist/cjs/app-globals-a41d7f40.js.map +0 -1
  85. package/dist/cjs/css-shim-83cf0349.js +0 -8
  86. package/dist/cjs/css-shim-83cf0349.js.map +0 -1
  87. package/dist/cjs/cura-button_6.cjs.entry.js +0 -322
  88. package/dist/cjs/cura-button_6.cjs.entry.js.map +0 -1
  89. package/dist/cjs/cura-icons-view.cjs.entry.js.map +0 -1
  90. package/dist/cjs/cura.cjs.js.map +0 -1
  91. package/dist/cjs/index-29633529.js.map +0 -1
  92. package/dist/cjs/index.cjs.js.map +0 -1
  93. package/dist/cjs/loader.cjs.js.map +0 -1
  94. package/dist/cjs/shadow-css-8baae635.js +0 -391
  95. package/dist/cjs/shadow-css-8baae635.js.map +0 -1
  96. package/dist/collection/api/cura-api.js.map +0 -1
  97. package/dist/collection/api/cura-api.type.js.map +0 -1
  98. package/dist/collection/api/modules/cura-theme-colors-module.js.map +0 -1
  99. package/dist/collection/api/modules/cura-theme-fonts-module.js.map +0 -1
  100. package/dist/collection/api/modules/cura-theme-module.js.map +0 -1
  101. package/dist/collection/api/modules/cura-theme-spacing-module.js.map +0 -1
  102. package/dist/collection/api/theme-presets/static.js.map +0 -1
  103. package/dist/collection/api/theme-presets/theme-default.js.map +0 -1
  104. package/dist/collection/api/theme-presets/theme-maternity.js.map +0 -1
  105. package/dist/collection/api/theme-presets/theme-oncology.js.map +0 -1
  106. package/dist/collection/api/theme-presets/theme-presets.js.map +0 -1
  107. package/dist/collection/assets/icons/iconset-default-list.js.map +0 -1
  108. package/dist/collection/components/buttons/cura-button/cura-button.css +0 -70
  109. package/dist/collection/components/buttons/cura-button/cura-button.js +0 -255
  110. package/dist/collection/components/buttons/cura-button/cura-button.js.map +0 -1
  111. package/dist/collection/components/cura-icon/cura-icon.js.map +0 -1
  112. package/dist/collection/components/cura-icons-view/cura-icons-view.js.map +0 -1
  113. package/dist/collection/components/cura-page-template/cura-page-template.js.map +0 -1
  114. package/dist/collection/components/text/cura-display/cura-display.js.map +0 -1
  115. package/dist/collection/components/text/cura-heading/cura-heading.js.map +0 -1
  116. package/dist/collection/components/text/cura-paragraph/cura-paragraph.js.map +0 -1
  117. package/dist/collection/index.js.map +0 -1
  118. package/dist/collection/rededor-cura-start.js.map +0 -1
  119. package/dist/collection/utils/utils.js.map +0 -1
  120. package/dist/collection/utils/utils.spec.js +0 -16
  121. package/dist/collection/utils/utils.spec.js.map +0 -1
  122. package/dist/components/cura-button.d.ts +0 -11
  123. package/dist/components/cura-button.js +0 -97
  124. package/dist/components/cura-button.js.map +0 -1
  125. package/dist/components/cura-display.js.map +0 -1
  126. package/dist/components/cura-heading.js.map +0 -1
  127. package/dist/components/cura-icon.js.map +0 -1
  128. package/dist/components/cura-icon2.js.map +0 -1
  129. package/dist/components/cura-icons-view.js.map +0 -1
  130. package/dist/components/cura-page-template.js.map +0 -1
  131. package/dist/components/cura-paragraph.js.map +0 -1
  132. package/dist/components/index.js.map +0 -1
  133. package/dist/cura/cura.esm.js.map +0 -1
  134. package/dist/cura/index.esm.js.map +0 -1
  135. package/dist/cura/p-118112e5.system.js +0 -14
  136. package/dist/cura/p-118112e5.system.js.map +0 -1
  137. package/dist/cura/p-183305c3.js +0 -2
  138. package/dist/cura/p-183305c3.js.map +0 -1
  139. package/dist/cura/p-3f6aaefc.system.js +0 -2
  140. package/dist/cura/p-3f6aaefc.system.js.map +0 -1
  141. package/dist/cura/p-4c60d085.entry.js +0 -2
  142. package/dist/cura/p-4c60d085.entry.js.map +0 -1
  143. package/dist/cura/p-4fc49972.system.js +0 -2
  144. package/dist/cura/p-4fc49972.system.js.map +0 -1
  145. package/dist/cura/p-50ea2036.system.js.map +0 -1
  146. package/dist/cura/p-61953b75.system.js +0 -2
  147. package/dist/cura/p-61953b75.system.js.map +0 -1
  148. package/dist/cura/p-731abb13.entry.js +0 -2
  149. package/dist/cura/p-731abb13.entry.js.map +0 -1
  150. package/dist/cura/p-958c8695.system.entry.js.map +0 -1
  151. package/dist/cura/p-b5872ed0.system.entry.js +0 -2
  152. package/dist/cura/p-b5872ed0.system.entry.js.map +0 -1
  153. package/dist/cura/p-bac0b4ab.js +0 -2
  154. package/dist/cura/p-bac0b4ab.js.map +0 -1
  155. package/dist/cura/p-beab48cd.js +0 -13
  156. package/dist/cura/p-beab48cd.js.map +0 -1
  157. package/dist/cura/p-c30e14d5.system.js +0 -3
  158. package/dist/cura/p-c30e14d5.system.js.map +0 -1
  159. package/dist/cura/p-d5990392.js +0 -3
  160. package/dist/cura/p-d5990392.js.map +0 -1
  161. package/dist/esm/app-globals-8ed931e6.js.map +0 -1
  162. package/dist/esm/css-shim-d13f0738.js +0 -6
  163. package/dist/esm/css-shim-d13f0738.js.map +0 -1
  164. package/dist/esm/cura-button_6.entry.js +0 -313
  165. package/dist/esm/cura-button_6.entry.js.map +0 -1
  166. package/dist/esm/cura-icons-view.entry.js.map +0 -1
  167. package/dist/esm/cura.js.map +0 -1
  168. package/dist/esm/index-e11775ce.js.map +0 -1
  169. package/dist/esm/index.js.map +0 -1
  170. package/dist/esm/loader.js.map +0 -1
  171. package/dist/esm/shadow-css-07b0c8c8.js +0 -389
  172. package/dist/esm/shadow-css-07b0c8c8.js.map +0 -1
  173. package/dist/esm-es5/app-globals-8ed931e6.js +0 -2
  174. package/dist/esm-es5/app-globals-8ed931e6.js.map +0 -1
  175. package/dist/esm-es5/css-shim-d13f0738.js +0 -2
  176. package/dist/esm-es5/css-shim-d13f0738.js.map +0 -1
  177. package/dist/esm-es5/cura-button_6.entry.js +0 -2
  178. package/dist/esm-es5/cura-button_6.entry.js.map +0 -1
  179. package/dist/esm-es5/cura-icons-view.entry.js.map +0 -1
  180. package/dist/esm-es5/cura.js.map +0 -1
  181. package/dist/esm-es5/index-e11775ce.js +0 -3
  182. package/dist/esm-es5/index-e11775ce.js.map +0 -1
  183. package/dist/esm-es5/index.js.map +0 -1
  184. package/dist/esm-es5/loader.js.map +0 -1
  185. package/dist/esm-es5/shadow-css-07b0c8c8.js +0 -13
  186. package/dist/esm-es5/shadow-css-07b0c8c8.js.map +0 -1
  187. package/dist/loader/index.d.ts +0 -12
  188. package/dist/types/components/buttons/cura-button/cura-button.d.ts +0 -49
@@ -0,0 +1,250 @@
1
+ import { r as registerInstance, h, H as Host, g as getElement } from './index-7e8c969d.js';
2
+
3
+ const curaDisplayCss = ".cura-display{display:block;font-size:var(--font-size);text-transform:uppercase}.cura-display h1,.cura-display h2,.cura-display h3,.cura-display h4,.cura-display h5,.cura-display h6{font-family:var(--font-family);font-size:4.285em;font-weight:var(--font-weight-black);color:var(--color-body);line-height:120%;letter-spacing:-4%;-webkit-margin-before:var(--block-margin);margin-block-start:var(--block-margin);-webkit-margin-after:var(--block-margin);margin-block-end:var(--block-margin)}.cura-display h1.large,.cura-display h2.large,.cura-display h3.large,.cura-display h4.large,.cura-display h5.large,.cura-display h6.large{font-size:6.21em}.cura-display h1.small,.cura-display h2.small,.cura-display h3.small,.cura-display h4.small,.cura-display h5.small,.cura-display h6.small{font-size:3em;font-weight:var(--font-weight-bold)}@media (min-width: 768px) and (max-width: 1365px){.cura-display h1,.cura-display h2,.cura-display h3,.cura-display h4,.cura-display h5,.cura-display h6{font-size:4.92em}.cura-display h1.large,.cura-display h2.large,.cura-display h3.large,.cura-display h4.large,.cura-display h5.large,.cura-display h6.large{font-size:7.07em}.cura-display h1.small,.cura-display h2.small,.cura-display h3.small,.cura-display h4.small,.cura-display h5.small,.cura-display h6.small{font-size:3.428em}}@media (min-width: 1366px){.cura-display h1,.cura-display h2,.cura-display h3,.cura-display h4,.cura-display h5,.cura-display h6{font-size:6.14em;line-height:125%}.cura-display h1.large,.cura-display h2.large,.cura-display h3.large,.cura-display h4.large,.cura-display h5.large,.cura-display h6.large{font-size:8.857em;letter-spacing:-6%}.cura-display h1.small,.cura-display h2.small,.cura-display h3.small,.cura-display h4.small,.cura-display h5.small,.cura-display h6.small{font-size:4.285em;letter-spacing:-2%}}.cura-display b,.cura-display strong{font-weight:var(--font-weight-bold)}.cura-display a{font-weight:var(--font-weight-bold);color:var(--color-link);text-decoration:none;text-underline-offset:10%;cursor:pointer}.cura-display abbr{color:var(--color-link);-webkit-text-decoration:underline dashed 1px var(--color-link);text-decoration:underline dashed 1px var(--color-link);text-underline-offset:10%;cursor:default}";
4
+
5
+ const CuraDisplay = class {
6
+ constructor(hostRef) {
7
+ registerInstance(this, hostRef);
8
+ /**
9
+ * Heading level for semantics.
10
+ * Values: 1(default)-6.
11
+ */
12
+ this.level = 1;
13
+ /**
14
+ * Heading style size.
15
+ * Values: small | regular(default) | large.
16
+ */
17
+ this.size = 'regular';
18
+ /**
19
+ * Apply light color to text in dark background.
20
+ * Values: boolean.
21
+ */
22
+ this.inverted = false;
23
+ /**
24
+ * Apply base system color to elements like <a> and <abbr>.
25
+ * Values: String primary(default) | secondary | accent | neutral | success | error | warning | info.
26
+ */
27
+ this.spotColor = 'primary';
28
+ }
29
+ connectedCallback() {
30
+ this.weights = window.CuraAPI.theme.fonts.getWeights();
31
+ this.setFontProperties();
32
+ this.setColors();
33
+ }
34
+ getClasses() {
35
+ const classes = {};
36
+ classes[this.size.toLowerCase()] = true;
37
+ return classes;
38
+ }
39
+ setFontProperties() {
40
+ this.styles = {
41
+ '--font-family': window.CuraAPI.theme.fonts.getFamily('display'),
42
+ '--font-size': window.CuraAPI.theme.fonts.getSize(),
43
+ '--font-weight-bold': this.weights.bold,
44
+ '--font-weight-black': this.weights.black
45
+ };
46
+ this.setHostProperty('--font-size', window.CuraAPI.theme.fonts.getSize());
47
+ this.setHostProperty('--block-margin', '0.5em');
48
+ }
49
+ setColors() {
50
+ const fontColor = this.inverted
51
+ ? window.CuraAPI.theme.colors.getColor('neutral-100')
52
+ : window.CuraAPI.theme.fonts.getColor();
53
+ this.styles['--color-body'] = fontColor || window.CuraAPI.theme.colors.getColor('neutral-darker');
54
+ this.styles['--color-link'] = this.inverted
55
+ ? window.CuraAPI.theme.colors.getColor(`${this.spotColor}-100`)
56
+ : window.CuraAPI.theme.colors.getColor(`${this.spotColor}-700`);
57
+ }
58
+ setHostProperty(prop, value) {
59
+ this.host.style.setProperty(prop, value);
60
+ }
61
+ getHeadingTag() {
62
+ const tags = {
63
+ '1': h("h1", { style: this.styles, class: this.getClasses() }, h("slot", null)),
64
+ '2': h("h2", { style: this.styles, class: this.getClasses() }, h("slot", null)),
65
+ '3': h("h3", { style: this.styles, class: this.getClasses() }, h("slot", null)),
66
+ '4': h("h4", { style: this.styles, class: this.getClasses() }, h("slot", null)),
67
+ '5': h("h5", { style: this.styles, class: this.getClasses() }, h("slot", null)),
68
+ '6': h("h6", { style: this.styles, class: this.getClasses() }, h("slot", null)),
69
+ 'default': h("h1", { style: this.styles, class: this.getClasses() }, h("slot", null))
70
+ };
71
+ return tags[`${this.level}`] || tags['default'];
72
+ }
73
+ render() {
74
+ return (h(Host, { class: "cura-display" }, this.getHeadingTag()));
75
+ }
76
+ get host() { return getElement(this); }
77
+ };
78
+ CuraDisplay.style = curaDisplayCss;
79
+
80
+ const curaHeadingCss = ".cura-heading{display:block;font-size:var(--font-size)}.cura-heading h1,.cura-heading h2,.cura-heading h3,.cura-heading h4,.cura-heading h5,.cura-heading h6{font-family:var(--font-family);font-size:1.71em;font-weight:var(--font-weight-regular);color:var(--color-body);line-height:130%;letter-spacing:0%;-webkit-margin-before:var(--block-margin);margin-block-start:var(--block-margin);-webkit-margin-after:var(--block-margin);margin-block-end:var(--block-margin)}.cura-heading h1.bold-weight,.cura-heading h2.bold-weight,.cura-heading h3.bold-weight,.cura-heading h4.bold-weight,.cura-heading h5.bold-weight,.cura-heading h6.bold-weight{font-weight:var(--font-weight-medium)}.cura-heading h1.large,.cura-heading h2.large,.cura-heading h3.large,.cura-heading h4.large,.cura-heading h5.large,.cura-heading h6.large{font-size:2.07em;letter-spacing:-2%}.cura-heading h1.small,.cura-heading h2.small,.cura-heading h3.small,.cura-heading h4.small,.cura-heading h5.small,.cura-heading h6.small{font-size:1.214em;line-height:150%;letter-spacing:0%}.cura-heading h1.small.bold-weight,.cura-heading h2.small.bold-weight,.cura-heading h3.small.bold-weight,.cura-heading h4.small.bold-weight,.cura-heading h5.small.bold-weight,.cura-heading h6.small.bold-weight{font-weight:var(--font-weight-bold)}@media (min-width: 768px) and (max-width: 1365px){.cura-heading h1,.cura-heading h2,.cura-heading h3,.cura-heading h4,.cura-heading h5,.cura-heading h6{font-size:2em}.cura-heading h1.large,.cura-heading h2.large,.cura-heading h3.large,.cura-heading h4.large,.cura-heading h5.large,.cura-heading h6.large{font-size:2.357em}.cura-heading h1.small,.cura-heading h2.small,.cura-heading h3.small,.cura-heading h4.small,.cura-heading h5.small,.cura-heading h6.small{font-size:1.357em}}@media (min-width: 1366px){.cura-heading h1,.cura-heading h2,.cura-heading h3,.cura-heading h4,.cura-heading h5,.cura-heading h6{font-size:2.5em;line-height:135%;letter-spacing:-2%}.cura-heading h1.large,.cura-heading h2.large,.cura-heading h3.large,.cura-heading h4.large,.cura-heading h5.large,.cura-heading h6.large{font-size:2.92em}.cura-heading h1.small,.cura-heading h2.small,.cura-heading h3.small,.cura-heading h4.small,.cura-heading h5.small,.cura-heading h6.small{font-size:1.71em;line-height:160%;letter-spacing:0%}}.cura-heading b,.cura-heading strong{font-weight:var(--font-weight-bold)}.cura-heading a{font-weight:var(--font-weight-bold);color:var(--color-link);text-decoration:none;text-underline-offset:10%;cursor:pointer}.cura-heading abbr{color:var(--color-link);-webkit-text-decoration:underline dashed 1px var(--color-link);text-decoration:underline dashed 1px var(--color-link);text-underline-offset:10%;cursor:default}";
81
+
82
+ const CuraHeading = class {
83
+ constructor(hostRef) {
84
+ registerInstance(this, hostRef);
85
+ /**
86
+ * Heading level for semantics.
87
+ * Values: 1(default)-6.
88
+ */
89
+ this.level = 1;
90
+ /**
91
+ * Heading style size.
92
+ * Values: small | regular(default) | large.
93
+ */
94
+ this.size = 'regular';
95
+ /**
96
+ * Heading font weight.
97
+ * Values: regular(default) | bold.
98
+ */
99
+ this.weight = 'regular';
100
+ /**
101
+ * Apply light color to text in dark background.
102
+ * Values: boolean.
103
+ */
104
+ this.inverted = false;
105
+ /**
106
+ * Apply base system color to elements like <a> and <abbr>.
107
+ * Values: String primary(default) | secondary | accent | neutral | success | error | warning | info.
108
+ */
109
+ this.spotColor = 'primary';
110
+ }
111
+ connectedCallback() {
112
+ this.weights = window.CuraAPI.theme.fonts.getWeights();
113
+ this.setFontProperties();
114
+ this.setColors();
115
+ }
116
+ getClasses() {
117
+ const classes = {};
118
+ classes[this.size.toLowerCase()] = true;
119
+ classes[`${this.weight.toLowerCase()}-weight`] = true;
120
+ return classes;
121
+ }
122
+ setFontProperties() {
123
+ this.styles = {
124
+ '--font-family': window.CuraAPI.theme.fonts.getFamily('heading'),
125
+ '--font-size': window.CuraAPI.theme.fonts.getSize(),
126
+ '--font-weight-regular': this.weights.regular,
127
+ '--font-weight-medium': this.weights.medium,
128
+ '--font-weight-bold': this.weights.bold,
129
+ '--font-weight-black': this.weights.black
130
+ };
131
+ this.setHostProperty('--font-size', window.CuraAPI.theme.fonts.getSize());
132
+ this.setHostProperty('--block-margin', '0.5em');
133
+ }
134
+ setColors() {
135
+ const fontColor = this.inverted
136
+ ? window.CuraAPI.theme.colors.getColor('neutral-100')
137
+ : window.CuraAPI.theme.fonts.getColor();
138
+ this.styles['--color-body'] = fontColor || window.CuraAPI.theme.colors.getColor('neutral-darker');
139
+ this.styles['--color-link'] = this.inverted
140
+ ? window.CuraAPI.theme.colors.getColor(`${this.spotColor}-100`)
141
+ : window.CuraAPI.theme.colors.getColor(`${this.spotColor}-700`);
142
+ }
143
+ setHostProperty(prop, value) {
144
+ this.host.style.setProperty(prop, value);
145
+ }
146
+ getHeadingTag() {
147
+ const tags = {
148
+ '1': h("h1", { style: this.styles, class: this.getClasses() }, h("slot", null)),
149
+ '2': h("h2", { style: this.styles, class: this.getClasses() }, h("slot", null)),
150
+ '3': h("h3", { style: this.styles, class: this.getClasses() }, h("slot", null)),
151
+ '4': h("h4", { style: this.styles, class: this.getClasses() }, h("slot", null)),
152
+ '5': h("h5", { style: this.styles, class: this.getClasses() }, h("slot", null)),
153
+ '6': h("h6", { style: this.styles, class: this.getClasses() }, h("slot", null)),
154
+ 'default': h("h1", { style: this.styles, class: this.getClasses() }, h("slot", null))
155
+ };
156
+ return tags[`${this.level}`] || tags['default'];
157
+ }
158
+ render() {
159
+ return (h(Host, { class: "cura-heading" }, this.getHeadingTag()));
160
+ }
161
+ get host() { return getElement(this); }
162
+ };
163
+ CuraHeading.style = curaHeadingCss;
164
+
165
+ const curaPageTemplateCss = ".cura-template{display:block}.cura-template .grid-template{display:grid;grid-template-rows:auto;grid-template-columns:auto;grid-template-areas:\"sub-header\" \"header\" \"pre-content\" \"content-container\" \"post-body\" \"footer\" \"sub-footer\"}.cura-template .grid-template #sub-header{grid-area:sub-header}.cura-template .grid-template #header{grid-area:header}.cura-template .grid-template #pre-content{grid-area:pre-content}.cura-template .grid-template #content-container{grid-area:content-container}.cura-template .grid-template #post-body{grid-area:post-body}.cura-template .grid-template #footer{grid-area:footer}.cura-template .grid-template #sub-footer{grid-area:sub-footer}@media (max-width: 360px){.cura-template .grid-template{padding:0px}}@media (min-width: 768px) and (max-width: 1365px){.cura-template .grid-template{padding:0px}}@media (min-width: 1366px) and (max-width: 1919px){.cura-template .grid-template{padding:0px}.cura-template .grid-template #content-container #sidebar-left ::slotted(div[slot=sidebar-left]){margin-right:calc(var(--spacing) * 5px)}.cura-template .grid-template #content-container #sidebar-right ::slotted(div[slot=sidebar-right]){margin-left:calc(var(--spacing) * 5px)}.cura-template .grid-template #content-container{display:-ms-flexbox;display:flex}.cura-template .grid-template #content-container #content{-ms-flex-positive:1;flex-grow:1}.cura-template .grid-template #content-container #sidebar-left,.cura-template .grid-template #content-container #sidebar-right{max-width:20%}}@media (min-width: 1920px){.cura-template .grid-template{padding:0px}.cura-template .grid-template #content-container #sidebar-left ::slotted(div[slot=sidebar-left]){margin-right:calc(var(--spacing) * 7px)}.cura-template .grid-template #content-container #sidebar-right ::slotted(div[slot=sidebar-right]){margin-left:calc(var(--spacing) * 7px)}.cura-template .grid-template #content-container{display:-ms-flexbox;display:flex}.cura-template .grid-template #content-container #content{-ms-flex-positive:1;flex-grow:1}.cura-template .grid-template #content-container #sidebar-left,.cura-template .grid-template #content-container #sidebar-right{max-width:20%}.cura-template .grid-template #content-container.centered{max-width:1920px;justify-self:center}}";
166
+
167
+ const CuraPageTemplate = class {
168
+ constructor(hostRef) {
169
+ registerInstance(this, hostRef);
170
+ this.contentwidth = 'default';
171
+ }
172
+ connectedCallback() {
173
+ this.styles = {
174
+ '--spacing': window.CuraAPI.theme.spacing.getSpacing(),
175
+ };
176
+ }
177
+ getClasses() {
178
+ const classes = {};
179
+ classes[this.contentwidth.toLowerCase()] = true;
180
+ return classes;
181
+ }
182
+ render() {
183
+ return (h(Host, { class: "cura-template" }, h("div", { style: this.styles, class: "grid-template" }, h("div", { id: "sub-header" }, h("slot", { name: 'sub-header' })), h("div", { id: "header" }, h("slot", { name: 'header' })), h("div", { id: "pre-content" }, h("slot", { name: 'pre-content' })), h("div", { id: "content-container", class: this.getClasses() }, h("div", { id: "sidebar-left" }, h("slot", { name: 'sidebar-left' })), h("div", { id: "content" }, h("slot", { name: "content" }), h("slot", null)), h("div", { id: "sidebar-right" }, h("slot", { name: 'sidebar-right' }))), h("div", { id: "post-body" }, h("slot", { name: 'post-body' })), h("div", { id: "footer" }, h("slot", { name: 'footer' })), h("div", { id: "sub-footer" }, h("slot", { name: 'sub-footer' })))));
184
+ }
185
+ get host() { return getElement(this); }
186
+ };
187
+ CuraPageTemplate.style = curaPageTemplateCss;
188
+
189
+ const curaParagraphCss = ".cura-paragraph{display:block;font-size:var(--font-size)}.cura-paragraph p{font-family:var(--font-family);font-size:var(--font-size);font-weight:var(--font-weight-regular);color:var(--color-body);line-height:140%;letter-spacing:2%;-webkit-margin-before:var(--block-margin);margin-block-start:var(--block-margin);-webkit-margin-after:var(--block-margin);margin-block-end:var(--block-margin)}.cura-paragraph p.large{font-size:1.21em;line-height:150%;letter-spacing:0%}.cura-paragraph p.small{font-size:0.85em;line-height:135%;letter-spacing:4%}.cura-paragraph p.caption{font-size:0.71em;line-height:135%;letter-spacing:6%}@media (min-width: 768px) and (max-width: 1365px){.cura-paragraph p{font-size:1.14em;line-height:145%}.cura-paragraph p.large{font-size:1.35em;line-height:150%}.cura-paragraph p.small{font-size:1em;line-height:135%}.cura-paragraph p.caption{font-size:0.85em;line-height:135%;letter-spacing:6%}}@media (min-width: 1366px){.cura-paragraph p{font-size:1.42em;line-height:150%;letter-spacing:0%}.cura-paragraph p.large{font-size:1.71em;line-height:160%}.cura-paragraph p.small{font-size:1.21em;line-height:145%;letter-spacing:0%}.cura-paragraph p.caption{font-size:1em;line-height:145%;letter-spacing:2%}}.cura-paragraph b,.cura-paragraph strong{font-weight:var(--font-weight-bold)}.cura-paragraph a{font-weight:var(--font-weight-medium);color:var(--color-link);text-underline-offset:10%}.cura-paragraph abbr{color:var(--color-link);-webkit-text-decoration:underline dashed 1px var(--color-link);text-decoration:underline dashed 1px var(--color-link);text-underline-offset:10%;cursor:default}";
190
+
191
+ const CuraParagraph = class {
192
+ constructor(hostRef) {
193
+ registerInstance(this, hostRef);
194
+ /**
195
+ * Set size of body text.
196
+ * Values: regular (default) | large | small | caption.
197
+ */
198
+ this.size = 'regular';
199
+ /**
200
+ * Apply light color to text in dark background.
201
+ * Values: boolean.
202
+ */
203
+ this.inverted = false;
204
+ /**
205
+ * Apply base system color to elements like <a> and <abbr>.
206
+ * Values: String primary(default) | secondary | accent | neutral | success | error | warning | info.
207
+ */
208
+ this.spotColor = 'primary';
209
+ }
210
+ connectedCallback() {
211
+ this.weights = window.CuraAPI.theme.fonts.getWeights();
212
+ this.setFontProperties();
213
+ this.setColors();
214
+ }
215
+ setsizeClass() {
216
+ const sizeclass = {};
217
+ sizeclass[this.size.toLowerCase()] = true;
218
+ return sizeclass;
219
+ }
220
+ setFontProperties() {
221
+ this.styles = {
222
+ '--font-family': window.CuraAPI.theme.fonts.getFamily('body'),
223
+ '--font-size': window.CuraAPI.theme.fonts.getSize(),
224
+ '--font-weight-regular': this.weights.regular,
225
+ '--font-weight-medium': this.weights.medium,
226
+ '--font-weight-bold': this.weights.bold
227
+ };
228
+ this.setHostProperty('--font-size', window.CuraAPI.theme.fonts.getSize());
229
+ this.setHostProperty('--block-margin', '1.25em');
230
+ }
231
+ setColors() {
232
+ const fontColor = this.inverted
233
+ ? window.CuraAPI.theme.colors.getColor('neutral-100')
234
+ : window.CuraAPI.theme.fonts.getColor();
235
+ this.styles['--color-body'] = fontColor || window.CuraAPI.theme.colors.getColor('neutral-darker');
236
+ this.styles['--color-link'] = this.inverted
237
+ ? window.CuraAPI.theme.colors.getColor(`${this.spotColor}-100`)
238
+ : window.CuraAPI.theme.colors.getColor(`${this.spotColor}-700`);
239
+ }
240
+ setHostProperty(prop, value) {
241
+ this.host.style.setProperty(prop, value);
242
+ }
243
+ render() {
244
+ return (h(Host, { class: "cura-paragraph" }, h("p", { style: this.styles, class: this.setsizeClass() }, h("slot", null))));
245
+ }
246
+ get host() { return getElement(this); }
247
+ };
248
+ CuraParagraph.style = curaParagraphCss;
249
+
250
+ export { CuraDisplay as cura_display, CuraHeading as cura_heading, CuraPageTemplate as cura_page_template, CuraParagraph as cura_paragraph };
@@ -0,0 +1,55 @@
1
+ import { r as registerInstance, h, H as Host, g as getElement } from './index-7e8c969d.js';
2
+
3
+ const curaIconCss = ".cura-icon{width:var(--size);height:var(--size)}.cura-icon svg{display:inline-block;stroke:var(--color);width:var(--size);height:var(--size);stroke-width:var(--stroke);fill:none}";
4
+
5
+ const CuraIcon = class {
6
+ constructor(hostRef) {
7
+ registerInstance(this, hostRef);
8
+ this.name = '';
9
+ this.color = 'neutral-base';
10
+ this.iconset = 'default';
11
+ this.disabled = false;
12
+ this.sizes = {
13
+ "128": { size: 128, stroke: 5.25 },
14
+ "72": { size: 72, stroke: 3.5 },
15
+ "64": { size: 64, stroke: 3.25 },
16
+ "48": { size: 48, stroke: 2.75 },
17
+ "40": { size: 40, stroke: 2.5 },
18
+ "32": { size: 32, stroke: 2.25 },
19
+ "24": { size: 24, stroke: 2 },
20
+ "20": { size: 20, stroke: 1.75 },
21
+ "16": { size: 16, stroke: 1.5 },
22
+ "default": { size: 24, stroke: 2 }
23
+ };
24
+ }
25
+ sizeHandler(size) {
26
+ const scaledStroke = (iconSize) => {
27
+ return `${this.sizes[iconSize].stroke * (this.sizes.default.size / this.sizes[iconSize].size)}px`;
28
+ };
29
+ this.setHostProperty('--size', this.sizes[`${size}`] ? `${this.sizes[size].size}px` : `${this.sizes.default.size}px`);
30
+ this.setHostProperty('--stroke', this.sizes[`${size}`] ? scaledStroke(size) : scaledStroke("default"));
31
+ }
32
+ colorHandler() {
33
+ this.setHostProperty('--color', window.CuraAPI.theme.colors.getColor(this.disabled ? 'neutral-light' : this.color));
34
+ }
35
+ connectedCallback() {
36
+ this.assetsPath = window.CuraAPI.localAssetsPath;
37
+ this.sizeHandler(this.size);
38
+ this.colorHandler();
39
+ }
40
+ setHostProperty(prop, value) {
41
+ this.host.style.setProperty(prop, value);
42
+ }
43
+ render() {
44
+ return (h(Host, { class: 'cura-icon' }, h("svg", { version: "1.1", viewBox: "0 0 24 24", preserveAspectRatio: "xMidYMid meet", xmlns: "http://www.w3.org/2000/svg" }, h("use", { xlinkHref: `${this.assetsPath}/icons/iconset-${this.iconset}.svg#${this.name}` }))));
45
+ }
46
+ get host() { return getElement(this); }
47
+ static get watchers() { return {
48
+ "size": ["sizeHandler"],
49
+ "color": ["colorHandler"],
50
+ "disabled": ["colorHandler"]
51
+ }; }
52
+ };
53
+ CuraIcon.style = curaIconCss;
54
+
55
+ export { CuraIcon as cura_icon };
@@ -1,4 +1,4 @@
1
- import { r as registerInstance, h, H as Host } from './index-e11775ce.js';
1
+ import { r as registerInstance, h, H as Host } from './index-7e8c969d.js';
2
2
 
3
3
  const iconsetdefaulticons = ["360", "accessibility", "alertCircle", "alertTriangle", "arrowDown", "arrowDownCircle", "arrowLeft", "arrowLeftCircle", "arrowRight", "arrowRightCircle", "arrowUp", "arrowUpCircle", "attach", "avatarF", "avatarM", "biometry", "bloodGroup", "calendar", "cam", "camOff", "central", "chatCircle", "check", "checkBadge", "checkCircle", "checkDouble", "clock", "close", "closeCircle", "collapse", "config", "delete", "desktop", "deslike", "download", "duplicate", "edit", "exam", "expand", "facebook", "fileBmp", "fileJpg", "filePdf", "filePng", "fileUpload", "fileXls", "filter", "fullscreen", "gallery", "geotag", "google", "hate", "healthPlan", "height", "height2", "home", "horizontalList", "imageUp", "info2", "infoCircle", "instagram", "key", "language", "language2", "languageEN", "languagePT", "lattes", "like", "likeHand", "link", "linkExternal", "linkedin", "list", "login", "logout", "love", "mail", "mail2", "medical", "menuHamburguer", "menuKebab", "menuMeatballs", "mic", "micOff", "minus", "minusCircle", "minusSquare", "mobile", "neutral", "news", "notification", "order", "partner", "phone", "play", "plus", "plusCircle", "plusSquare", "print", "profile", "profile2", "pulldownG", "pulldownP", "pullupG", "pullupP", "questionCircle", "questionSquare", "range", "reload", "schedule", "search", "secure", "share", "share2", "sound", "soundOff", "subItem", "target", "team", "twitter", "unLink", "unSecure", "unlikeHand", "upload", "verticalList", "viewFalse", "viewTrue", "weight", "whatsapp", "wifi", "youtube", "zoomIn", "zoomOut"];
4
4
 
@@ -9,10 +9,10 @@ const CuraIconsView = class {
9
9
  registerInstance(this, hostRef);
10
10
  this.sizes = [16, 20, 24, 32, 40, 48, 64, 72, 128];
11
11
  this.colors = ['primary', 'secondary', 'accent', 'info', 'warning', 'error', 'success', 'neutral'];
12
+ this.selected = '360';
12
13
  this.setSelected = (icon) => {
13
14
  this.selected = icon;
14
15
  };
15
- this.selected = '360';
16
16
  }
17
17
  render() {
18
18
  return (h(Host, null, h("div", { class: "iconDetail" }, h("h4", null, this.selected), h("div", { class: "iconSizes" }, this.sizes.map(size => h("div", { class: "size" }, h("cura-icon", { name: this.selected, size: size }), h("span", null, size)))), h("div", { class: "iconSizes invert" }, this.sizes.map(size => h("div", { class: "size" }, h("cura-icon", { name: this.selected, size: size, color: "neutral-white" }), h("span", null, size)))), h("div", { class: "iconSizes" }, this.colors.map(color => h("div", { class: "size" }, h("cura-icon", { name: this.selected, color: color }), h("span", null, color))), h("div", { class: "size" }, h("cura-icon", { name: this.selected, disabled: true }), h("span", null, "Disabled")))), h("div", { class: "icons" }, iconsetdefaulticons.map(icon => h("div", { class: "icon", onClick: () => this.setSelected(icon) }, h("cura-icon", { name: icon }), h("span", null, icon))))));
@@ -21,5 +21,3 @@ const CuraIconsView = class {
21
21
  CuraIconsView.style = curaIconsViewCss;
22
22
 
23
23
  export { CuraIconsView as cura_icons_view };
24
-
25
- //# sourceMappingURL=cura-icons-view.entry.js.map
package/dist/esm/cura.js CHANGED
@@ -1,31 +1,19 @@
1
- import { p as plt, w as win, a as promiseResolve, b as bootstrapLazy } from './index-e11775ce.js';
2
- export { s as setNonce } from './index-e11775ce.js';
3
- import { g as globalScripts } from './app-globals-8ed931e6.js';
1
+ import { p as promiseResolve, b as bootstrapLazy } from './index-7e8c969d.js';
2
+ import { g as globalScripts } from './app-globals-cb45bff3.js';
4
3
 
5
4
  /*
6
- Stencil Client Patch Browser v3.3.0 | MIT Licensed | https://stenciljs.com
5
+ Stencil Client Patch Browser v2.18.1 | MIT Licensed | https://stenciljs.com
7
6
  */
8
7
  const patchBrowser = () => {
9
- // TODO(STENCIL-659): Remove code implementing the CSS variable shim
10
- {
11
- // shim css vars
12
- // TODO(STENCIL-659): Remove code implementing the CSS variable shim
13
- plt.$cssShim$ = win.__cssshim;
14
- }
15
8
  const importMeta = import.meta.url;
16
9
  const opts = {};
17
- // TODO(STENCIL-663): Remove code related to deprecated `safari10` field.
18
10
  if (importMeta !== '') {
19
11
  opts.resourcesUrl = new URL('.', importMeta).href;
20
- // TODO(STENCIL-661): Remove code related to the dynamic import shim
21
- // TODO(STENCIL-663): Remove code related to deprecated `safari10` field.
22
12
  }
23
13
  return promiseResolve(opts);
24
14
  };
25
15
 
26
16
  patchBrowser().then(options => {
27
17
  globalScripts();
28
- return bootstrapLazy([["cura-button_6",[[1,"cura-button",{"type":[513],"size":[513],"disabled":[516],"isLoading":[516,"is-loading"],"iconName":[513,"icon-name"],"iconset":[513],"iconPosition":[513,"icon-position"],"href":[513],"target":[1],"color":[1],"styles":[32]}],[1,"cura-display",{"level":[514],"size":[513],"inverted":[516],"spotColor":[513,"spot-color"]}],[1,"cura-heading",{"level":[514],"size":[513],"weight":[513],"inverted":[516],"spotColor":[513,"spot-color"]}],[1,"cura-page-template",{"contentwidth":[513]}],[1,"cura-paragraph",{"size":[513],"inverted":[516],"spotColor":[513,"spot-color"]}],[1,"cura-icon",{"name":[513],"color":[1],"size":[8],"iconset":[513],"disabled":[4]}]]],["cura-icons-view",[[1,"cura-icons-view",{"selected":[32]}]]]], options);
18
+ return bootstrapLazy([["cura-icon",[[0,"cura-icon",{"name":[513],"color":[1],"size":[8],"iconset":[513],"disabled":[4]}]]],["cura-icons-view",[[0,"cura-icons-view",{"selected":[32]}]]],["cura-display_4",[[4,"cura-display",{"level":[514],"size":[513],"inverted":[516],"spotColor":[513,"spot-color"]}],[4,"cura-heading",{"level":[514],"size":[513],"weight":[513],"inverted":[516],"spotColor":[513,"spot-color"]}],[4,"cura-page-template",{"contentwidth":[513]}],[4,"cura-paragraph",{"size":[513],"inverted":[516],"spotColor":[513,"spot-color"]}]]]], options);
29
19
  });
30
-
31
- //# sourceMappingURL=cura.js.map