@rededor/cura 0.3.1 → 0.3.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/dist/cjs/{app-globals-5f5b9fbf.js → app-globals-0f70160b.js} +57 -15
- package/dist/cjs/cura-display_4.cjs.entry.js +257 -0
- package/dist/cjs/cura-icon.cjs.entry.js +59 -0
- package/dist/cjs/cura-icons-view.cjs.entry.js +27 -0
- package/dist/cjs/cura.cjs.js +2 -2
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/collection/api/cura-api.js +4 -1
- package/dist/collection/api/modules/cura-theme-module.js +2 -0
- package/dist/collection/api/modules/cura-theme-spacing-module.js +12 -0
- package/dist/collection/api/theme-presets/static.js +0 -13
- package/dist/collection/api/theme-presets/theme-oncology.js +38 -0
- package/dist/collection/api/theme-presets/theme-presets.js +3 -1
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/cura-icons-view/cura-icons-view.css +1 -15
- package/dist/collection/components/cura-page-template/cura-page-template.css +123 -0
- package/dist/collection/components/cura-page-template/cura-page-template.js +54 -0
- package/dist/collection/components/text/cura-display/cura-display.css +25 -2
- package/dist/collection/components/text/cura-display/cura-display.js +56 -5
- package/dist/collection/components/text/cura-heading/cura-heading.css +25 -2
- package/dist/collection/components/text/cura-heading/cura-heading.js +53 -2
- package/dist/collection/components/text/cura-paragraph/cura-paragraph.css +25 -2
- package/dist/collection/components/text/cura-paragraph/cura-paragraph.js +54 -3
- package/dist/components/cura-display.js +24 -7
- package/dist/components/cura-heading.js +21 -4
- package/dist/components/cura-icons-view.js +1 -1
- package/dist/components/cura-page-template.d.ts +11 -0
- package/dist/components/cura-page-template.js +47 -0
- package/dist/components/cura-paragraph.js +22 -5
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.js +58 -15
- package/dist/cura/cura.esm.js +1 -1
- package/dist/cura/cura.js +1 -1
- package/dist/cura/p-22290742.entry.js +1 -0
- package/dist/cura/p-32769783.system.js +1 -0
- package/dist/cura/p-5b5cf2e4.system.entry.js +1 -0
- package/dist/cura/p-84b2ad25.entry.js +1 -0
- package/dist/cura/p-8b416bc6.system.js +1 -0
- package/dist/cura/p-aca36c98.js +1 -0
- package/dist/cura/p-e3facf6a.system.entry.js +1 -0
- package/dist/cura/p-e8fadcfa.system.entry.js +1 -0
- package/dist/cura/p-fbcea891.entry.js +1 -0
- package/dist/esm/{app-globals-d7dd3a4d.js → app-globals-cb45bff3.js} +57 -15
- package/dist/esm/cura-display_4.entry.js +250 -0
- package/dist/esm/cura-icon.entry.js +55 -0
- package/dist/esm/cura-icons-view.entry.js +23 -0
- package/dist/esm/cura.js +2 -2
- package/dist/esm/loader.js +2 -2
- package/dist/esm-es5/app-globals-cb45bff3.js +1 -0
- package/dist/esm-es5/cura-display_4.entry.js +1 -0
- package/dist/esm-es5/cura-icon.entry.js +1 -0
- package/dist/esm-es5/cura-icons-view.entry.js +1 -0
- package/dist/esm-es5/cura.js +1 -1
- package/dist/esm-es5/loader.js +1 -1
- package/dist/types/api/cura-api.type.d.ts +4 -1
- package/dist/types/api/modules/cura-theme-module.d.ts +2 -0
- package/dist/types/api/modules/cura-theme-spacing-module.d.ts +6 -0
- package/dist/types/api/theme-presets/static.d.ts +0 -11
- package/dist/types/api/theme-presets/theme-oncology.d.ts +50 -0
- package/dist/types/api/theme-presets/theme-presets.d.ts +50 -0
- package/dist/types/components/cura-page-template/cura-page-template.d.ts +8 -0
- package/dist/types/components/text/cura-display/cura-display.d.ts +13 -3
- package/dist/types/components/text/cura-heading/cura-heading.d.ts +10 -0
- package/dist/types/components/text/cura-paragraph/cura-paragraph.d.ts +10 -0
- package/dist/types/components.d.ts +63 -0
- package/package.json +2 -2
- package/dist/cjs/cura-display_5.cjs.entry.js +0 -261
- package/dist/cura/p-265c1706.js +0 -1
- package/dist/cura/p-3d8bbf37.system.js +0 -1
- package/dist/cura/p-a8dcaaed.system.js +0 -1
- package/dist/cura/p-fc50b109.system.entry.js +0 -1
- package/dist/cura/p-fc80cb18.entry.js +0 -1
- package/dist/esm/cura-display_5.entry.js +0 -253
- package/dist/esm-es5/app-globals-d7dd3a4d.js +0 -1
- package/dist/esm-es5/cura-display_5.entry.js +0 -1
|
@@ -73,9 +73,47 @@ const ThemeMaternity = Object.assign(Object.assign({}, ThemeDefault), {
|
|
|
73
73
|
}
|
|
74
74
|
} });
|
|
75
75
|
|
|
76
|
+
/**
|
|
77
|
+
* Oncology Theme
|
|
78
|
+
*/
|
|
79
|
+
const ThemeOncology = Object.assign(Object.assign({}, ThemeDefault), {
|
|
80
|
+
/* Custom */
|
|
81
|
+
/* Colors */
|
|
82
|
+
color: {
|
|
83
|
+
primary: {
|
|
84
|
+
'100': '#99CFFF',
|
|
85
|
+
'300': '#47A9FF',
|
|
86
|
+
'500': '#0083F5',
|
|
87
|
+
'700': '#006DCC',
|
|
88
|
+
'900': '#0058A4',
|
|
89
|
+
},
|
|
90
|
+
secondary: {
|
|
91
|
+
'100': '#CDD7E3',
|
|
92
|
+
'300': '#9BAFC7',
|
|
93
|
+
'500': '#6886AB',
|
|
94
|
+
'700': '#365E8F',
|
|
95
|
+
'900': '#043673',
|
|
96
|
+
},
|
|
97
|
+
aux1: {
|
|
98
|
+
'100': '#AABEE1',
|
|
99
|
+
'300': '#557EC4',
|
|
100
|
+
'500': '#003DA6',
|
|
101
|
+
'700': '#00296F',
|
|
102
|
+
'900': '#000C21',
|
|
103
|
+
},
|
|
104
|
+
aux2: {
|
|
105
|
+
'100': '#DAF2EF',
|
|
106
|
+
'300': '#84D4CA',
|
|
107
|
+
'500': '#47BFB0',
|
|
108
|
+
'700': '#2F7F75',
|
|
109
|
+
'900': '#0E2623',
|
|
110
|
+
},
|
|
111
|
+
} });
|
|
112
|
+
|
|
76
113
|
const ThemePresets = {
|
|
77
114
|
'default': ThemeDefault,
|
|
78
|
-
'maternidade': ThemeMaternity
|
|
115
|
+
'maternidade': ThemeMaternity,
|
|
116
|
+
'oncologia': ThemeOncology,
|
|
79
117
|
};
|
|
80
118
|
|
|
81
119
|
/**
|
|
@@ -167,19 +205,6 @@ const Static = {
|
|
|
167
205
|
'900': '#262626',
|
|
168
206
|
},
|
|
169
207
|
},
|
|
170
|
-
/* Icons */
|
|
171
|
-
icons: {
|
|
172
|
-
'sizes': ['128', '72', '64', '48', '40', '32', '24', '20', '16'],
|
|
173
|
-
'strokes': ['5.25', '3.5', '3.25', '2.75', '2.5', '2.25', '2', '1.75', '1.5'],
|
|
174
|
-
'default-size': '24',
|
|
175
|
-
},
|
|
176
|
-
/* Breakpoints */
|
|
177
|
-
breakpoints: {
|
|
178
|
-
small: '576px',
|
|
179
|
-
medium: '768px',
|
|
180
|
-
large: '992px',
|
|
181
|
-
xlarge: '1200px',
|
|
182
|
-
},
|
|
183
208
|
};
|
|
184
209
|
|
|
185
210
|
class CuraThemeColorsModule {
|
|
@@ -251,6 +276,19 @@ class CuraThemeColorsModule {
|
|
|
251
276
|
}
|
|
252
277
|
}
|
|
253
278
|
|
|
279
|
+
class CuraThemeSpacingModule {
|
|
280
|
+
constructor() {
|
|
281
|
+
this.curaSpacing = '--cura-spacing-base';
|
|
282
|
+
}
|
|
283
|
+
/** Returns the base spacing var defined in the theme */
|
|
284
|
+
getSpacing() {
|
|
285
|
+
if (getComputedStyle(document.body).getPropertyValue(this.curaSpacing)) {
|
|
286
|
+
return `var(${this.curaSpacing})`;
|
|
287
|
+
}
|
|
288
|
+
return '4';
|
|
289
|
+
}
|
|
290
|
+
}
|
|
291
|
+
|
|
254
292
|
class CuraThemeFontsModule {
|
|
255
293
|
constructor() {
|
|
256
294
|
/**
|
|
@@ -290,6 +328,7 @@ class CuraThemeModule {
|
|
|
290
328
|
constructor() {
|
|
291
329
|
this.prefix = '--cura';
|
|
292
330
|
this.colors = new CuraThemeColorsModule();
|
|
331
|
+
this.spacing = new CuraThemeSpacingModule();
|
|
293
332
|
this.fonts = new CuraThemeFontsModule();
|
|
294
333
|
/* Private */
|
|
295
334
|
/** Set css var based on object structure */
|
|
@@ -372,7 +411,10 @@ class CuraAPI {
|
|
|
372
411
|
getWeights: function () { return themeModule.fonts.getWeights(); },
|
|
373
412
|
getSize: function () { return themeModule.fonts.getSize(); },
|
|
374
413
|
getColor: function () { return themeModule.fonts.getColor(); }
|
|
375
|
-
}
|
|
414
|
+
},
|
|
415
|
+
spacing: {
|
|
416
|
+
getSpacing: function () { return themeModule.spacing.getSpacing(); },
|
|
417
|
+
},
|
|
376
418
|
};
|
|
377
419
|
if (config && config.customTheme) {
|
|
378
420
|
this.theme.setCustom(config.customTheme);
|
|
@@ -0,0 +1,257 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
const index = require('./index-8686299e.js');
|
|
6
|
+
|
|
7
|
+
const curaDisplayCss = ":host{display:block;font-size:var(--font-size);text-transform:uppercase}:host h1,:host h2,:host h3,:host h4,:host h5,:host 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)}:host h1.large,:host h2.large,:host h3.large,:host h4.large,:host h5.large,:host h6.large{font-size:6.21em}:host h1.small,:host h2.small,:host h3.small,:host h4.small,:host h5.small,:host h6.small{font-size:3em;font-weight:var(--font-weight-bold)}@media (min-width: 768px) and (max-width: 1365px){:host h1,:host h2,:host h3,:host h4,:host h5,:host h6{font-size:4.92em}:host h1.large,:host h2.large,:host h3.large,:host h4.large,:host h5.large,:host h6.large{font-size:7.07em}:host h1.small,:host h2.small,:host h3.small,:host h4.small,:host h5.small,:host h6.small{font-size:3.428em}}@media (min-width: 1366px){:host h1,:host h2,:host h3,:host h4,:host h5,:host h6{font-size:6.14em;line-height:125%}:host h1.large,:host h2.large,:host h3.large,:host h4.large,:host h5.large,:host h6.large{font-size:8.857em;letter-spacing:-6%}:host h1.small,:host h2.small,:host h3.small,:host h4.small,:host h5.small,:host h6.small{font-size:4.285em;letter-spacing:-2%}}:host ::slotted(b),:host ::slotted(strong){font-weight:var(--font-weight-bold)}:host ::slotted(a){font-weight:var(--font-weight-bold);color:var(--color-link);text-decoration:none;text-underline-offset:10%;cursor:pointer}:host ::slotted(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}";
|
|
8
|
+
|
|
9
|
+
const CuraDisplay = class {
|
|
10
|
+
constructor(hostRef) {
|
|
11
|
+
index.registerInstance(this, hostRef);
|
|
12
|
+
/**
|
|
13
|
+
* Heading level for semantics.
|
|
14
|
+
* Values: 1(default)-6.
|
|
15
|
+
*/
|
|
16
|
+
this.level = 1;
|
|
17
|
+
/**
|
|
18
|
+
* Heading style size.
|
|
19
|
+
* Values: small | regular(default) | large.
|
|
20
|
+
*/
|
|
21
|
+
this.size = 'regular';
|
|
22
|
+
/**
|
|
23
|
+
* Apply light color to text in dark background.
|
|
24
|
+
* Values: boolean.
|
|
25
|
+
*/
|
|
26
|
+
this.inverted = false;
|
|
27
|
+
/**
|
|
28
|
+
* Apply base system color to elements like <a> and <abbr>.
|
|
29
|
+
* Values: String primary(default) | secondary | accent | neutral | success | error | warning | info.
|
|
30
|
+
*/
|
|
31
|
+
this.spotColor = 'primary';
|
|
32
|
+
}
|
|
33
|
+
connectedCallback() {
|
|
34
|
+
this.weights = window.CuraAPI.theme.fonts.getWeights();
|
|
35
|
+
this.setFontProperties();
|
|
36
|
+
this.setColors();
|
|
37
|
+
}
|
|
38
|
+
getClasses() {
|
|
39
|
+
const classes = {};
|
|
40
|
+
classes[this.size.toLowerCase()] = true;
|
|
41
|
+
return classes;
|
|
42
|
+
}
|
|
43
|
+
setFontProperties() {
|
|
44
|
+
this.styles = {
|
|
45
|
+
'--font-family': window.CuraAPI.theme.fonts.getFamily('display'),
|
|
46
|
+
'--font-size': window.CuraAPI.theme.fonts.getSize(),
|
|
47
|
+
'--font-weight-bold': this.weights.bold,
|
|
48
|
+
'--font-weight-black': this.weights.black
|
|
49
|
+
};
|
|
50
|
+
this.setHostProperty('--font-size', window.CuraAPI.theme.fonts.getSize());
|
|
51
|
+
this.setHostProperty('--block-margin', '0.5em');
|
|
52
|
+
}
|
|
53
|
+
setColors() {
|
|
54
|
+
const fontColor = this.inverted
|
|
55
|
+
? window.CuraAPI.theme.colors.getColor('neutral-100')
|
|
56
|
+
: window.CuraAPI.theme.fonts.getColor();
|
|
57
|
+
this.styles['--color-body'] = fontColor || window.CuraAPI.theme.colors.getColor('neutral-darker');
|
|
58
|
+
this.styles['--color-link'] = this.inverted
|
|
59
|
+
? window.CuraAPI.theme.colors.getColor(`${this.spotColor}-100`)
|
|
60
|
+
: window.CuraAPI.theme.colors.getColor(`${this.spotColor}-700`);
|
|
61
|
+
}
|
|
62
|
+
setHostProperty(prop, value) {
|
|
63
|
+
this.host.style.setProperty(prop, value);
|
|
64
|
+
}
|
|
65
|
+
getHeadingTag() {
|
|
66
|
+
const tags = {
|
|
67
|
+
'1': index.h("h1", { style: this.styles, class: this.getClasses() }, index.h("slot", null)),
|
|
68
|
+
'2': index.h("h2", { style: this.styles, class: this.getClasses() }, index.h("slot", null)),
|
|
69
|
+
'3': index.h("h3", { style: this.styles, class: this.getClasses() }, index.h("slot", null)),
|
|
70
|
+
'4': index.h("h4", { style: this.styles, class: this.getClasses() }, index.h("slot", null)),
|
|
71
|
+
'5': index.h("h5", { style: this.styles, class: this.getClasses() }, index.h("slot", null)),
|
|
72
|
+
'6': index.h("h6", { style: this.styles, class: this.getClasses() }, index.h("slot", null)),
|
|
73
|
+
'default': index.h("h1", { style: this.styles, class: this.getClasses() }, index.h("slot", null))
|
|
74
|
+
};
|
|
75
|
+
return tags[`${this.level}`] || tags['default'];
|
|
76
|
+
}
|
|
77
|
+
render() {
|
|
78
|
+
return (index.h(index.Host, null, this.getHeadingTag()));
|
|
79
|
+
}
|
|
80
|
+
get host() { return index.getElement(this); }
|
|
81
|
+
};
|
|
82
|
+
CuraDisplay.style = curaDisplayCss;
|
|
83
|
+
|
|
84
|
+
const curaHeadingCss = ":host{display:block;font-size:var(--font-size)}:host h1,:host h2,:host h3,:host h4,:host h5,:host 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)}:host h1.bold-weight,:host h2.bold-weight,:host h3.bold-weight,:host h4.bold-weight,:host h5.bold-weight,:host h6.bold-weight{font-weight:var(--font-weight-medium)}:host h1.large,:host h2.large,:host h3.large,:host h4.large,:host h5.large,:host h6.large{font-size:2.07em;letter-spacing:-2%}:host h1.small,:host h2.small,:host h3.small,:host h4.small,:host h5.small,:host h6.small{font-size:1.214em;line-height:150%;letter-spacing:0%}:host h1.small.bold-weight,:host h2.small.bold-weight,:host h3.small.bold-weight,:host h4.small.bold-weight,:host h5.small.bold-weight,:host h6.small.bold-weight{font-weight:var(--font-weight-bold)}@media (min-width: 768px) and (max-width: 1365px){:host h1,:host h2,:host h3,:host h4,:host h5,:host h6{font-size:2em}:host h1.large,:host h2.large,:host h3.large,:host h4.large,:host h5.large,:host h6.large{font-size:2.357em}:host h1.small,:host h2.small,:host h3.small,:host h4.small,:host h5.small,:host h6.small{font-size:1.357em}}@media (min-width: 1366px){:host h1,:host h2,:host h3,:host h4,:host h5,:host h6{font-size:2.5em;line-height:135%;letter-spacing:-2%}:host h1.large,:host h2.large,:host h3.large,:host h4.large,:host h5.large,:host h6.large{font-size:2.92em}:host h1.small,:host h2.small,:host h3.small,:host h4.small,:host h5.small,:host h6.small{font-size:1.71em;line-height:160%;letter-spacing:0%}}:host ::slotted(b),:host ::slotted(strong){font-weight:var(--font-weight-bold)}:host ::slotted(a){font-weight:var(--font-weight-bold);color:var(--color-link);text-decoration:none;text-underline-offset:10%;cursor:pointer}:host ::slotted(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}";
|
|
85
|
+
|
|
86
|
+
const CuraHeading = class {
|
|
87
|
+
constructor(hostRef) {
|
|
88
|
+
index.registerInstance(this, hostRef);
|
|
89
|
+
/**
|
|
90
|
+
* Heading level for semantics.
|
|
91
|
+
* Values: 1(default)-6.
|
|
92
|
+
*/
|
|
93
|
+
this.level = 1;
|
|
94
|
+
/**
|
|
95
|
+
* Heading style size.
|
|
96
|
+
* Values: small | regular(default) | large.
|
|
97
|
+
*/
|
|
98
|
+
this.size = 'regular';
|
|
99
|
+
/**
|
|
100
|
+
* Heading font weight.
|
|
101
|
+
* Values: regular(default) | bold.
|
|
102
|
+
*/
|
|
103
|
+
this.weight = 'regular';
|
|
104
|
+
/**
|
|
105
|
+
* Apply light color to text in dark background.
|
|
106
|
+
* Values: boolean.
|
|
107
|
+
*/
|
|
108
|
+
this.inverted = false;
|
|
109
|
+
/**
|
|
110
|
+
* Apply base system color to elements like <a> and <abbr>.
|
|
111
|
+
* Values: String primary(default) | secondary | accent | neutral | success | error | warning | info.
|
|
112
|
+
*/
|
|
113
|
+
this.spotColor = 'primary';
|
|
114
|
+
}
|
|
115
|
+
connectedCallback() {
|
|
116
|
+
this.weights = window.CuraAPI.theme.fonts.getWeights();
|
|
117
|
+
this.setFontProperties();
|
|
118
|
+
this.setColors();
|
|
119
|
+
}
|
|
120
|
+
getClasses() {
|
|
121
|
+
const classes = {};
|
|
122
|
+
classes[this.size.toLowerCase()] = true;
|
|
123
|
+
classes[`${this.weight.toLowerCase()}-weight`] = true;
|
|
124
|
+
return classes;
|
|
125
|
+
}
|
|
126
|
+
setFontProperties() {
|
|
127
|
+
this.styles = {
|
|
128
|
+
'--font-family': window.CuraAPI.theme.fonts.getFamily('heading'),
|
|
129
|
+
'--font-size': window.CuraAPI.theme.fonts.getSize(),
|
|
130
|
+
'--font-weight-regular': this.weights.regular,
|
|
131
|
+
'--font-weight-medium': this.weights.medium,
|
|
132
|
+
'--font-weight-bold': this.weights.bold,
|
|
133
|
+
'--font-weight-black': this.weights.black
|
|
134
|
+
};
|
|
135
|
+
this.setHostProperty('--font-size', window.CuraAPI.theme.fonts.getSize());
|
|
136
|
+
this.setHostProperty('--block-margin', '0.5em');
|
|
137
|
+
}
|
|
138
|
+
setColors() {
|
|
139
|
+
const fontColor = this.inverted
|
|
140
|
+
? window.CuraAPI.theme.colors.getColor('neutral-100')
|
|
141
|
+
: window.CuraAPI.theme.fonts.getColor();
|
|
142
|
+
this.styles['--color-body'] = fontColor || window.CuraAPI.theme.colors.getColor('neutral-darker');
|
|
143
|
+
this.styles['--color-link'] = this.inverted
|
|
144
|
+
? window.CuraAPI.theme.colors.getColor(`${this.spotColor}-100`)
|
|
145
|
+
: window.CuraAPI.theme.colors.getColor(`${this.spotColor}-700`);
|
|
146
|
+
}
|
|
147
|
+
setHostProperty(prop, value) {
|
|
148
|
+
this.host.style.setProperty(prop, value);
|
|
149
|
+
}
|
|
150
|
+
getHeadingTag() {
|
|
151
|
+
const tags = {
|
|
152
|
+
'1': index.h("h1", { style: this.styles, class: this.getClasses() }, index.h("slot", null)),
|
|
153
|
+
'2': index.h("h2", { style: this.styles, class: this.getClasses() }, index.h("slot", null)),
|
|
154
|
+
'3': index.h("h3", { style: this.styles, class: this.getClasses() }, index.h("slot", null)),
|
|
155
|
+
'4': index.h("h4", { style: this.styles, class: this.getClasses() }, index.h("slot", null)),
|
|
156
|
+
'5': index.h("h5", { style: this.styles, class: this.getClasses() }, index.h("slot", null)),
|
|
157
|
+
'6': index.h("h6", { style: this.styles, class: this.getClasses() }, index.h("slot", null)),
|
|
158
|
+
'default': index.h("h1", { style: this.styles, class: this.getClasses() }, index.h("slot", null))
|
|
159
|
+
};
|
|
160
|
+
return tags[`${this.level}`] || tags['default'];
|
|
161
|
+
}
|
|
162
|
+
render() {
|
|
163
|
+
return (index.h(index.Host, null, this.getHeadingTag()));
|
|
164
|
+
}
|
|
165
|
+
get host() { return index.getElement(this); }
|
|
166
|
+
};
|
|
167
|
+
CuraHeading.style = curaHeadingCss;
|
|
168
|
+
|
|
169
|
+
const curaPageTemplateCss = ":host{display:block}:host .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\"}:host .grid-template #sub-header{grid-area:sub-header}:host .grid-template #header{grid-area:header}:host .grid-template #pre-content{grid-area:pre-content}:host .grid-template #content-container{grid-area:content-container}:host .grid-template #post-body{grid-area:post-body}:host .grid-template #footer{grid-area:footer}:host .grid-template #sub-footer{grid-area:sub-footer}@media (max-width: 360px){:host .grid-template{padding:0px}:host .grid-template #pre-content,:host .grid-template #content-container,:host .grid-template #post-body,:host .grid-template #footer{margin-top:calc(var(--spacing) * 4px)}}@media (min-width: 768px) and (max-width: 1365px){:host .grid-template{padding:0px}:host .grid-template #pre-content,:host .grid-template #content-container,:host .grid-template #post-body,:host .grid-template #footer{margin-top:calc(var(--spacing) * 5px)}}@media (min-width: 1366px) and (max-width: 1919px){:host .grid-template{padding:0px}:host .grid-template #content-container #sidebar-left ::slotted(div[slot=sidebar-left]){margin-right:calc(var(--spacing) * 5px)}:host .grid-template #content-container #sidebar-right ::slotted(div[slot=sidebar-right]){margin-left:calc(var(--spacing) * 5px)}:host .grid-template #pre-content,:host .grid-template #content-container,:host .grid-template #post-body,:host .grid-template #footer{margin-top:calc(var(--spacing) * 5px)}:host .grid-template #content-container{display:-ms-flexbox;display:flex}:host .grid-template #content-container #sidebar-left,:host .grid-template #content-container #sidebar-right{max-width:20%}}@media (min-width: 1920px){:host .grid-template{padding:0px}:host .grid-template #content-container #sidebar-left ::slotted(div[slot=sidebar-left]){margin-right:calc(var(--spacing) * 7px)}:host .grid-template #content-container #sidebar-right ::slotted(div[slot=sidebar-right]){margin-left:calc(var(--spacing) * 7px)}:host .grid-template #pre-content,:host .grid-template #content-container,:host .grid-template #post-body,:host .grid-template #footer{margin-top:calc(var(--spacing) * 7px)}:host .grid-template #content-container{display:-ms-flexbox;display:flex}:host .grid-template #content-container #sidebar-left,:host .grid-template #content-container #sidebar-right{max-width:20%}:host .grid-template #content-container.centered{max-width:1920px;justify-self:center}}";
|
|
170
|
+
|
|
171
|
+
const CuraPageTemplate = class {
|
|
172
|
+
constructor(hostRef) {
|
|
173
|
+
index.registerInstance(this, hostRef);
|
|
174
|
+
this.contentwidth = 'default';
|
|
175
|
+
}
|
|
176
|
+
connectedCallback() {
|
|
177
|
+
this.styles = {
|
|
178
|
+
'--spacing': window.CuraAPI.theme.spacing.getSpacing(),
|
|
179
|
+
};
|
|
180
|
+
}
|
|
181
|
+
getClasses() {
|
|
182
|
+
const classes = {};
|
|
183
|
+
classes[this.contentwidth.toLowerCase()] = true;
|
|
184
|
+
return classes;
|
|
185
|
+
}
|
|
186
|
+
render() {
|
|
187
|
+
return (index.h(index.Host, null, index.h("div", { style: this.styles, class: "grid-template" }, index.h("div", { id: "sub-header" }, index.h("slot", { name: 'sub-header' })), index.h("div", { id: "header" }, index.h("slot", { name: 'header' })), index.h("div", { id: "pre-content" }, index.h("slot", { name: 'pre-content' })), index.h("div", { id: "content-container", class: this.getClasses() }, index.h("div", { id: "sidebar-left" }, index.h("slot", { name: 'sidebar-left' })), index.h("div", { id: "content" }, index.h("slot", { name: "content" }), index.h("slot", null)), index.h("div", { id: "sidebar-right" }, index.h("slot", { name: 'sidebar-right' }))), index.h("div", { id: "post-body" }, index.h("slot", { name: 'post-body' })), index.h("div", { id: "footer" }, index.h("slot", { name: 'footer' })), index.h("div", { id: "sub-footer" }, index.h("slot", { name: 'sub-footer' })))));
|
|
188
|
+
}
|
|
189
|
+
get host() { return index.getElement(this); }
|
|
190
|
+
};
|
|
191
|
+
CuraPageTemplate.style = curaPageTemplateCss;
|
|
192
|
+
|
|
193
|
+
const curaParagraphCss = ":host{display:block;font-size:var(--font-size)}:host 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)}:host p.large{font-size:1.21em;line-height:150%;letter-spacing:0%}:host p.small{font-size:0.85em;line-height:135%;letter-spacing:4%}:host p.caption{font-size:0.71em;line-height:135%;letter-spacing:6%}@media (min-width: 768px) and (max-width: 1365px){:host p{font-size:1.14em;line-height:145%}:host p.large{font-size:1.35em;line-height:150%}:host p.small{font-size:1em;line-height:135%}:host p.caption{font-size:0.85em;line-height:135%;letter-spacing:6%}}@media (min-width: 1366px){:host p{font-size:1.42em;line-height:150%;letter-spacing:0%}:host p.large{font-size:1.71em;line-height:160%}:host p.small{font-size:1.21em;line-height:145%;letter-spacing:0%}:host p.caption{font-size:1em;line-height:145%;letter-spacing:2%}}:host ::slotted(b),:host ::slotted(strong){font-weight:var(--font-weight-bold)}:host ::slotted(a){font-weight:var(--font-weight-medium);color:var(--color-link);text-underline-offset:10%}:host ::slotted(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}";
|
|
194
|
+
|
|
195
|
+
const CuraParagraph = class {
|
|
196
|
+
constructor(hostRef) {
|
|
197
|
+
index.registerInstance(this, hostRef);
|
|
198
|
+
/**
|
|
199
|
+
* Set size of body text.
|
|
200
|
+
* Values: regular (default) | large | small | caption.
|
|
201
|
+
*/
|
|
202
|
+
this.size = 'regular';
|
|
203
|
+
/**
|
|
204
|
+
* Apply light color to text in dark background.
|
|
205
|
+
* Values: boolean.
|
|
206
|
+
*/
|
|
207
|
+
this.inverted = false;
|
|
208
|
+
/**
|
|
209
|
+
* Apply base system color to elements like <a> and <abbr>.
|
|
210
|
+
* Values: String primary(default) | secondary | accent | neutral | success | error | warning | info.
|
|
211
|
+
*/
|
|
212
|
+
this.spotColor = 'primary';
|
|
213
|
+
}
|
|
214
|
+
connectedCallback() {
|
|
215
|
+
this.weights = window.CuraAPI.theme.fonts.getWeights();
|
|
216
|
+
this.setFontProperties();
|
|
217
|
+
this.setColors();
|
|
218
|
+
}
|
|
219
|
+
setsizeClass() {
|
|
220
|
+
const sizeclass = {};
|
|
221
|
+
sizeclass[this.size.toLowerCase()] = true;
|
|
222
|
+
return sizeclass;
|
|
223
|
+
}
|
|
224
|
+
setFontProperties() {
|
|
225
|
+
this.styles = {
|
|
226
|
+
'--font-family': window.CuraAPI.theme.fonts.getFamily('body'),
|
|
227
|
+
'--font-size': window.CuraAPI.theme.fonts.getSize(),
|
|
228
|
+
'--font-weight-regular': this.weights.regular,
|
|
229
|
+
'--font-weight-medium': this.weights.medium,
|
|
230
|
+
'--font-weight-bold': this.weights.bold
|
|
231
|
+
};
|
|
232
|
+
this.setHostProperty('--font-size', window.CuraAPI.theme.fonts.getSize());
|
|
233
|
+
this.setHostProperty('--block-margin', '1.25em');
|
|
234
|
+
}
|
|
235
|
+
setColors() {
|
|
236
|
+
const fontColor = this.inverted
|
|
237
|
+
? window.CuraAPI.theme.colors.getColor('neutral-100')
|
|
238
|
+
: window.CuraAPI.theme.fonts.getColor();
|
|
239
|
+
this.styles['--color-body'] = fontColor || window.CuraAPI.theme.colors.getColor('neutral-darker');
|
|
240
|
+
this.styles['--color-link'] = this.inverted
|
|
241
|
+
? window.CuraAPI.theme.colors.getColor(`${this.spotColor}-100`)
|
|
242
|
+
: window.CuraAPI.theme.colors.getColor(`${this.spotColor}-700`);
|
|
243
|
+
}
|
|
244
|
+
setHostProperty(prop, value) {
|
|
245
|
+
this.host.style.setProperty(prop, value);
|
|
246
|
+
}
|
|
247
|
+
render() {
|
|
248
|
+
return (index.h(index.Host, null, index.h("p", { style: this.styles, class: this.setsizeClass() }, index.h("slot", null))));
|
|
249
|
+
}
|
|
250
|
+
get host() { return index.getElement(this); }
|
|
251
|
+
};
|
|
252
|
+
CuraParagraph.style = curaParagraphCss;
|
|
253
|
+
|
|
254
|
+
exports.cura_display = CuraDisplay;
|
|
255
|
+
exports.cura_heading = CuraHeading;
|
|
256
|
+
exports.cura_page_template = CuraPageTemplate;
|
|
257
|
+
exports.cura_paragraph = CuraParagraph;
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
const index = require('./index-8686299e.js');
|
|
6
|
+
|
|
7
|
+
const curaIconCss = ":host{width:var(--size);height:var(--size)}:host svg{display:inline-block;stroke:var(--color);width:var(--size);height:var(--size);stroke-width:var(--stroke);fill:none}";
|
|
8
|
+
|
|
9
|
+
const CuraIcon = class {
|
|
10
|
+
constructor(hostRef) {
|
|
11
|
+
index.registerInstance(this, hostRef);
|
|
12
|
+
this.name = '';
|
|
13
|
+
this.color = 'neutral-base';
|
|
14
|
+
this.iconset = 'default';
|
|
15
|
+
this.disabled = false;
|
|
16
|
+
this.sizes = {
|
|
17
|
+
"128": { size: 128, stroke: 5.25 },
|
|
18
|
+
"72": { size: 72, stroke: 3.5 },
|
|
19
|
+
"64": { size: 64, stroke: 3.25 },
|
|
20
|
+
"48": { size: 48, stroke: 2.75 },
|
|
21
|
+
"40": { size: 40, stroke: 2.5 },
|
|
22
|
+
"32": { size: 32, stroke: 2.25 },
|
|
23
|
+
"24": { size: 24, stroke: 2 },
|
|
24
|
+
"20": { size: 20, stroke: 1.75 },
|
|
25
|
+
"16": { size: 16, stroke: 1.5 },
|
|
26
|
+
"default": { size: 24, stroke: 2 }
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
sizeHandler(size) {
|
|
30
|
+
const scaledStroke = (iconSize) => {
|
|
31
|
+
return `${this.sizes[iconSize].stroke * (this.sizes.default.size / this.sizes[iconSize].size)}px`;
|
|
32
|
+
};
|
|
33
|
+
this.setHostProperty('--size', this.sizes[`${size}`] ? `${this.sizes[size].size}px` : `${this.sizes.default.size}px`);
|
|
34
|
+
this.setHostProperty('--stroke', this.sizes[`${size}`] ? scaledStroke(size) : scaledStroke("default"));
|
|
35
|
+
}
|
|
36
|
+
colorHandler() {
|
|
37
|
+
this.setHostProperty('--color', window.CuraAPI.theme.colors.getColor(this.disabled ? 'neutral-light' : this.color));
|
|
38
|
+
}
|
|
39
|
+
connectedCallback() {
|
|
40
|
+
this.assetsPath = window.CuraAPI.localAssetsPath;
|
|
41
|
+
this.sizeHandler(this.size);
|
|
42
|
+
this.colorHandler();
|
|
43
|
+
}
|
|
44
|
+
setHostProperty(prop, value) {
|
|
45
|
+
this.host.style.setProperty(prop, value);
|
|
46
|
+
}
|
|
47
|
+
render() {
|
|
48
|
+
return (index.h(index.Host, null, index.h("svg", { version: "1.1", viewBox: "0 0 24 24", preserveAspectRatio: "xMidYMid meet", xmlns: "http://www.w3.org/2000/svg" }, index.h("use", { xlinkHref: `${this.assetsPath}/icons/iconset-${this.iconset}.svg#${this.name}` }))));
|
|
49
|
+
}
|
|
50
|
+
get host() { return index.getElement(this); }
|
|
51
|
+
static get watchers() { return {
|
|
52
|
+
"size": ["sizeHandler"],
|
|
53
|
+
"color": ["colorHandler"],
|
|
54
|
+
"disabled": ["colorHandler"]
|
|
55
|
+
}; }
|
|
56
|
+
};
|
|
57
|
+
CuraIcon.style = curaIconCss;
|
|
58
|
+
|
|
59
|
+
exports.cura_icon = CuraIcon;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
const index = require('./index-8686299e.js');
|
|
6
|
+
|
|
7
|
+
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"];
|
|
8
|
+
|
|
9
|
+
const curaIconsViewCss = ":host{display:block;padding:24px;font-family:\"Roboto\", Arial, Helvetica, sans-serif}.iconDetail{display:block}.iconSizes{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}.iconSizes .size{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;text-align:center;margin-right:9px;padding:8px}.iconSizes .size:last-child{margin-right:0}.iconSizes .size span{font-size:10px}.iconSizes.invert{margin-top:12px}.iconSizes.invert .size{background-color:#262626;color:#F6F6F6;border-radius:3px}.icons{margin-top:28px;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;position:relative}.icons .icon{position:relative;padding:4px;cursor:pointer;opacity:0.6;-webkit-transition:opacity 0.2s linear;transition:opacity 0.2s linear}.icons .icon span{font-size:12px;padding:6px;-webkit-box-sizing:border-box;box-sizing:border-box;background:#000;color:#FFF;border-radius:2px;position:absolute;top:-2px;left:50%;-webkit-transform:translateX(-50%) translateY(-100%);transform:translateX(-50%) translateY(-100%);display:none}.icons .icon:hover{opacity:1}.icons .icon:hover span{display:block}";
|
|
10
|
+
|
|
11
|
+
const CuraIconsView = class {
|
|
12
|
+
constructor(hostRef) {
|
|
13
|
+
index.registerInstance(this, hostRef);
|
|
14
|
+
this.sizes = [16, 20, 24, 32, 40, 48, 64, 72, 128];
|
|
15
|
+
this.colors = ['primary', 'secondary', 'accent', 'info', 'warning', 'error', 'success', 'neutral'];
|
|
16
|
+
this.selected = '360';
|
|
17
|
+
this.setSelected = (icon) => {
|
|
18
|
+
this.selected = icon;
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
render() {
|
|
22
|
+
return (index.h(index.Host, null, index.h("div", { class: "iconDetail" }, index.h("h4", null, this.selected), index.h("div", { class: "iconSizes" }, this.sizes.map(size => index.h("div", { class: "size" }, index.h("cura-icon", { name: this.selected, size: size }), index.h("span", null, size)))), index.h("div", { class: "iconSizes invert" }, this.sizes.map(size => index.h("div", { class: "size" }, index.h("cura-icon", { name: this.selected, size: size, color: "neutral-white" }), index.h("span", null, size)))), index.h("div", { class: "iconSizes" }, this.colors.map(color => index.h("div", { class: "size" }, index.h("cura-icon", { name: this.selected, color: color }), index.h("span", null, color))), index.h("div", { class: "size" }, index.h("cura-icon", { name: this.selected, disabled: true }), index.h("span", null, "Disabled")))), index.h("div", { class: "icons" }, iconsetdefaulticons.map(icon => index.h("div", { class: "icon", onClick: () => this.setSelected(icon) }, index.h("cura-icon", { name: icon }), index.h("span", null, icon))))));
|
|
23
|
+
}
|
|
24
|
+
};
|
|
25
|
+
CuraIconsView.style = curaIconsViewCss;
|
|
26
|
+
|
|
27
|
+
exports.cura_icons_view = CuraIconsView;
|
package/dist/cjs/cura.cjs.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
const index = require('./index-8686299e.js');
|
|
4
|
-
const appGlobals = require('./app-globals-
|
|
4
|
+
const appGlobals = require('./app-globals-0f70160b.js');
|
|
5
5
|
|
|
6
6
|
/*
|
|
7
7
|
Stencil Client Patch Browser v2.18.1 | MIT Licensed | https://stenciljs.com
|
|
@@ -17,5 +17,5 @@ const patchBrowser = () => {
|
|
|
17
17
|
|
|
18
18
|
patchBrowser().then(options => {
|
|
19
19
|
appGlobals.globalScripts();
|
|
20
|
-
return index.bootstrapLazy([["cura-
|
|
20
|
+
return index.bootstrapLazy([["cura-icon.cjs",[[1,"cura-icon",{"name":[513],"color":[1],"size":[8],"iconset":[513],"disabled":[4]}]]],["cura-icons-view.cjs",[[1,"cura-icons-view",{"selected":[32]}]]],["cura-display_4.cjs",[[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"]}]]]], options);
|
|
21
21
|
});
|
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-8686299e.js');
|
|
6
|
-
const appGlobals = require('./app-globals-
|
|
6
|
+
const appGlobals = require('./app-globals-0f70160b.js');
|
|
7
7
|
|
|
8
8
|
/*
|
|
9
9
|
Stencil Client Patch Esm v2.18.1 | MIT Licensed | https://stenciljs.com
|
|
@@ -16,7 +16,7 @@ const defineCustomElements = (win, options) => {
|
|
|
16
16
|
if (typeof window === 'undefined') return Promise.resolve();
|
|
17
17
|
return patchEsm().then(() => {
|
|
18
18
|
appGlobals.globalScripts();
|
|
19
|
-
return index.bootstrapLazy([["cura-
|
|
19
|
+
return index.bootstrapLazy([["cura-icon.cjs",[[1,"cura-icon",{"name":[513],"color":[1],"size":[8],"iconset":[513],"disabled":[4]}]]],["cura-icons-view.cjs",[[1,"cura-icons-view",{"selected":[32]}]]],["cura-display_4.cjs",[[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"]}]]]], options);
|
|
20
20
|
});
|
|
21
21
|
};
|
|
22
22
|
|
|
@@ -14,7 +14,10 @@ export default class CuraAPI {
|
|
|
14
14
|
getWeights: function () { return themeModule.fonts.getWeights(); },
|
|
15
15
|
getSize: function () { return themeModule.fonts.getSize(); },
|
|
16
16
|
getColor: function () { return themeModule.fonts.getColor(); }
|
|
17
|
-
}
|
|
17
|
+
},
|
|
18
|
+
spacing: {
|
|
19
|
+
getSpacing: function () { return themeModule.spacing.getSpacing(); },
|
|
20
|
+
},
|
|
18
21
|
};
|
|
19
22
|
if (config && config.customTheme) {
|
|
20
23
|
this.theme.setCustom(config.customTheme);
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import { ThemePresets } from "../theme-presets/theme-presets";
|
|
2
2
|
import CuraThemeColorsModule from "./cura-theme-colors-module";
|
|
3
|
+
import CuraThemeSpacingModule from "./cura-theme-spacing-module";
|
|
3
4
|
import CuraThemeFontsModule from "./cura-theme-fonts-module";
|
|
4
5
|
export default class CuraThemeModule {
|
|
5
6
|
constructor() {
|
|
6
7
|
this.prefix = '--cura';
|
|
7
8
|
this.colors = new CuraThemeColorsModule();
|
|
9
|
+
this.spacing = new CuraThemeSpacingModule();
|
|
8
10
|
this.fonts = new CuraThemeFontsModule();
|
|
9
11
|
/* Private */
|
|
10
12
|
/** Set css var based on object structure */
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export default class CuraThemeSpacingModule {
|
|
2
|
+
constructor() {
|
|
3
|
+
this.curaSpacing = '--cura-spacing-base';
|
|
4
|
+
}
|
|
5
|
+
/** Returns the base spacing var defined in the theme */
|
|
6
|
+
getSpacing() {
|
|
7
|
+
if (getComputedStyle(document.body).getPropertyValue(this.curaSpacing)) {
|
|
8
|
+
return `var(${this.curaSpacing})`;
|
|
9
|
+
}
|
|
10
|
+
return '4';
|
|
11
|
+
}
|
|
12
|
+
}
|
|
@@ -87,17 +87,4 @@ export const Static = {
|
|
|
87
87
|
'900': '#262626',
|
|
88
88
|
},
|
|
89
89
|
},
|
|
90
|
-
/* Icons */
|
|
91
|
-
icons: {
|
|
92
|
-
'sizes': ['128', '72', '64', '48', '40', '32', '24', '20', '16'],
|
|
93
|
-
'strokes': ['5.25', '3.5', '3.25', '2.75', '2.5', '2.25', '2', '1.75', '1.5'],
|
|
94
|
-
'default-size': '24',
|
|
95
|
-
},
|
|
96
|
-
/* Breakpoints */
|
|
97
|
-
breakpoints: {
|
|
98
|
-
small: '576px',
|
|
99
|
-
medium: '768px',
|
|
100
|
-
large: '992px',
|
|
101
|
-
xlarge: '1200px',
|
|
102
|
-
},
|
|
103
90
|
};
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Oncology Theme
|
|
3
|
+
*/
|
|
4
|
+
import { ThemeDefault } from "./theme-default";
|
|
5
|
+
export const ThemeOncology = Object.assign(Object.assign({}, ThemeDefault), {
|
|
6
|
+
/* Custom */
|
|
7
|
+
/* Colors */
|
|
8
|
+
color: {
|
|
9
|
+
primary: {
|
|
10
|
+
'100': '#99CFFF',
|
|
11
|
+
'300': '#47A9FF',
|
|
12
|
+
'500': '#0083F5',
|
|
13
|
+
'700': '#006DCC',
|
|
14
|
+
'900': '#0058A4',
|
|
15
|
+
},
|
|
16
|
+
secondary: {
|
|
17
|
+
'100': '#CDD7E3',
|
|
18
|
+
'300': '#9BAFC7',
|
|
19
|
+
'500': '#6886AB',
|
|
20
|
+
'700': '#365E8F',
|
|
21
|
+
'900': '#043673',
|
|
22
|
+
},
|
|
23
|
+
aux1: {
|
|
24
|
+
'100': '#AABEE1',
|
|
25
|
+
'300': '#557EC4',
|
|
26
|
+
'500': '#003DA6',
|
|
27
|
+
'700': '#00296F',
|
|
28
|
+
'900': '#000C21',
|
|
29
|
+
},
|
|
30
|
+
aux2: {
|
|
31
|
+
'100': '#DAF2EF',
|
|
32
|
+
'300': '#84D4CA',
|
|
33
|
+
'500': '#47BFB0',
|
|
34
|
+
'700': '#2F7F75',
|
|
35
|
+
'900': '#0E2623',
|
|
36
|
+
},
|
|
37
|
+
}
|
|
38
|
+
});
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { ThemeDefault } from './theme-default';
|
|
2
2
|
import { ThemeMaternity } from './theme-maternity';
|
|
3
|
+
import { ThemeOncology } from './theme-oncology';
|
|
3
4
|
export const ThemePresets = {
|
|
4
5
|
'default': ThemeDefault,
|
|
5
|
-
'maternidade': ThemeMaternity
|
|
6
|
+
'maternidade': ThemeMaternity,
|
|
7
|
+
'oncologia': ThemeOncology,
|
|
6
8
|
};
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
"entries": [
|
|
3
3
|
"./components/cura-icon/cura-icon.js",
|
|
4
4
|
"./components/cura-icons-view/cura-icons-view.js",
|
|
5
|
+
"./components/cura-page-template/cura-page-template.js",
|
|
5
6
|
"./components/text/cura-display/cura-display.js",
|
|
6
7
|
"./components/text/cura-heading/cura-heading.js",
|
|
7
8
|
"./components/text/cura-paragraph/cura-paragraph.js"
|
|
@@ -1,21 +1,7 @@
|
|
|
1
|
-
/* SASS Variables Map */
|
|
2
|
-
/* Private */
|
|
3
|
-
/*
|
|
4
|
-
* Family
|
|
5
|
-
* $scope: body (default) | title.
|
|
6
|
-
*/
|
|
7
|
-
/*
|
|
8
|
-
* Size
|
|
9
|
-
* $scope: base (default) | title.
|
|
10
|
-
* $level (for titles): 1 (default) | 2 | 3 | 4 | 5 | 6
|
|
11
|
-
*/
|
|
12
|
-
/* Private */
|
|
13
|
-
/* Colors */
|
|
14
|
-
/* Lists */
|
|
15
1
|
:host {
|
|
16
2
|
display: block;
|
|
17
3
|
padding: 24px;
|
|
18
|
-
font-family:
|
|
4
|
+
font-family: "Roboto", Arial, Helvetica, sans-serif;
|
|
19
5
|
}
|
|
20
6
|
|
|
21
7
|
.iconDetail {
|