@kausal/themes 0.5.5 → 0.6.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.
- package/dist/themes/default/theme.json +1 -1
- package/package.json +1 -1
- package/props.js +8 -24
- package/types.ts +3 -20
|
@@ -1 +1 @@
|
|
|
1
|
-
{"name":"default","brandLight":"rgb(212, 235, 255)","brandDark":"rgb(16, 114, 81)","neutralLight":"rgb(225, 223, 218)","neutralDark":"rgb(92, 88, 83)","themeColors":{"light":"rgb(236, 234, 230)","dark":"rgb(70, 66, 62)","black":"rgb(26, 24, 23)","white":"rgb(247, 246, 243)"},"imageOverlay":"rgb(255, 255, 255)","fontFamily":"Inter","fontFamilyHeadings":"Inter","fontFamilyContent":"Inter","fontFamilyTiny":"'-apple-system', 'BlinkMacSystemFont', 'Segoe UI', 'Roboto', 'Oxygen-Sans', 'Ubuntu', 'Cantarell', 'Helvetica Neue', sans-serif","headingsFontWeight":700,"headingsColor":"rgb(26, 24, 23)","fontFamilyFallback":"'-apple-system', 'BlinkMacSystemFont', 'Segoe UI', 'Roboto', 'Oxygen-Sans', 'Ubuntu', 'Cantarell', 'Helvetica Neue', sans-serif","fontFamilyFallbackHeadings":"'-apple-system', 'BlinkMacSystemFont', 'Segoe UI', 'Roboto', 'Oxygen-Sans', 'Ubuntu', 'Cantarell', 'Helvetica Neue', sans-serif","fontSizeSm":"0.8rem","fontSizeBase":"1rem","fontSizeMd":"1.25rem","fontSizeLg":"1.5rem","fontSizeXl":"2rem","fontSizeXxl":"3rem","fontWeightNormal":400,"fontWeightBold":700,"fontWeightBase":400,"lineHeightBase":1.666,"lineHeightSm":1,"lineHeightMd":1.2,"lineHeightLg":1.75,"space":"0.8rem","spaces":{"s000":0,"s025":"0.2rem","s050":"0.4rem","s100":"0.8rem","s150":"1.2000000000000002rem","s200":"1.6rem","s300":"2.4000000000000004rem","s400":"3.2rem","s600":"4.800000000000001rem","s800":"6.4rem"},"linkColor":"rgb(16, 114, 81)","linkHoverColor":"rgb(12, 83, 59)","
|
|
1
|
+
{"name":"default","brandLight":"rgb(212, 235, 255)","brandDark":"rgb(16, 114, 81)","neutralLight":"rgb(225, 223, 218)","neutralDark":"rgb(92, 88, 83)","themeColors":{"light":"rgb(236, 234, 230)","dark":"rgb(70, 66, 62)","black":"rgb(26, 24, 23)","white":"rgb(247, 246, 243)"},"imageOverlay":"rgb(255, 255, 255)","fontFamily":"Inter","fontFamilyHeadings":"Inter","fontFamilyContent":"Inter","fontFamilyTiny":"'-apple-system', 'BlinkMacSystemFont', 'Segoe UI', 'Roboto', 'Oxygen-Sans', 'Ubuntu', 'Cantarell', 'Helvetica Neue', sans-serif","headingsFontWeight":700,"headingsColor":"rgb(26, 24, 23)","fontFamilyFallback":"'-apple-system', 'BlinkMacSystemFont', 'Segoe UI', 'Roboto', 'Oxygen-Sans', 'Ubuntu', 'Cantarell', 'Helvetica Neue', sans-serif","fontFamilyFallbackHeadings":"'-apple-system', 'BlinkMacSystemFont', 'Segoe UI', 'Roboto', 'Oxygen-Sans', 'Ubuntu', 'Cantarell', 'Helvetica Neue', sans-serif","fontSizeSm":"0.8rem","fontSizeBase":"1rem","fontSizeMd":"1.25rem","fontSizeLg":"1.5rem","fontSizeXl":"2rem","fontSizeXxl":"3rem","fontWeightNormal":400,"fontWeightBold":700,"fontWeightBase":400,"lineHeightBase":1.666,"lineHeightSm":1,"lineHeightMd":1.2,"lineHeightLg":1.75,"space":"0.8rem","spaces":{"s000":0,"s025":"0.2rem","s050":"0.4rem","s100":"0.8rem","s150":"1.2000000000000002rem","s200":"1.6rem","s300":"2.4000000000000004rem","s400":"3.2rem","s600":"4.800000000000001rem","s800":"6.4rem"},"linkColor":"rgb(16, 114, 81)","linkHoverColor":"rgb(12, 83, 59)","inputBtnFocusColor":"rgb(78, 128, 166)","inputBtnPaddingY":"0.5rem","inputBtnPaddingX":"0.75rem","btnBorderRadius":"0.25rem","btnBorderWidth":"1px","inputPaddingY":"0.5rem","inputPaddingX":"0.75rem","inputBg":"rgb(255, 255, 255)","inputBorderWidth":"1px","inputLineHeight":1.5,"inputBorderRadius":"4px","customSelectIndicator":"url(\"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTQiIGhlaWdodD0iMTQiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0iTTExLjg5NiAzTDcgNy44NDIgMi4xMDQgMyAwIDUuMDggNyAxMmw3LTYuOTJMMTEuODk2IDN6IiBmaWxsPSIjMDAwIi8+PC9zdmc+\")","formLabelFontWeight":400,"brandNavColor":"rgb(247, 246, 243)","brandNavBackground":"rgb(92, 88, 83)","navLogoVisible":true,"navTitleVisible":true,"footerLogoPlacement":"left","footerLogoSize":"1","footerBackgroundColor":"rgb(92, 88, 83)","footerColor":"rgb(247, 246, 243)","cardBorderWidth":"1px","cardBorderRadius":"0.5rem","badgeBorderRadius":"3px","badgePaddingY":"0.5em","badgePaddingX":"0.75em","badgeFontWeight":700,"tableHeadBg":"rgba(0, 0, 0, 0)","tableHoverBg":"rgb(247, 246, 243)","actionCompletedColor":"rgb(12, 75, 43)","actionOnTimeColor":"rgb(12, 75, 43)","actionColor":"rgb(20, 80, 112)","breakpointSm":"576px","breakpointMd":"768px","breakpointLg":"992px","breakpointXl":"1200px","iconsUrl":"/static/themes/default/icons","combinedIconsFilename":"combined-icon-symbols","themeLogoUrl":"/static/themes/default/images/default-logo-white.svg","themeLogoWhiteUrl":"/static/themes/default/images/default-logo-white.svg","iconIndicatorsUrl":"","iconActionsUrl":"","themeCustomStylesUrl":"","graphColors":{"grey000":"rgb(248, 248, 248)","grey005":"rgb(243, 243, 243)","grey010":"rgb(238, 238, 238)","grey020":"rgb(217, 217, 217)","grey030":"rgb(199, 199, 199)","grey040":"rgb(183, 183, 183)","grey050":"rgb(160, 160, 160)","grey060":"rgb(123, 123, 123)","grey070":"rgb(99, 99, 99)","grey080":"rgb(75, 75, 75)","grey090":"rgb(63, 63, 63)","grey100":"rgb(29, 29, 29)","green010":"rgb(167, 235, 192)","green030":"rgb(86, 195, 142)","green050":"rgb(39, 154, 109)","green070":"rgb(16, 114, 81)","green090":"rgb(7, 74, 53)","red010":"rgb(252, 216, 216)","red030":"rgb(239, 154, 154)","red050":"rgb(212, 98, 98)","red070":"rgb(167, 57, 57)","red090":"rgb(102, 29, 29)","blue010":"rgb(194, 217, 237)","blue030":"rgb(109, 151, 184)","blue050":"rgb(78, 128, 166)","blue070":"rgb(32, 93, 130)","blue090":"rgb(13, 68, 94)","yellow010":"rgb(251, 230, 174)","yellow030":"rgb(220, 157, 42)","yellow050":"rgb(200, 130, 23)","yellow070":"rgb(143, 70, 4)","yellow090":"rgb(60, 19, 0)"},"settings":{"dashboard":{"showResponsibles":true,"showIndicators":true},"homeLink":"text","categories":{"filterIndicatorsByAllLevels":true},"fundingInstruments":[],"otherLogos":[]}}
|
package/package.json
CHANGED
package/props.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import PropTypes from
|
|
1
|
+
import PropTypes from "prop-types";
|
|
2
2
|
|
|
3
|
-
const { number, exact, string, oneOfType, bool, array, object } =
|
|
3
|
+
const { number, exact, string, oneOfType, bool, array, object, arrayOf } =
|
|
4
|
+
PropTypes;
|
|
4
5
|
|
|
5
6
|
export function makeThemePropType(cssv = null) {
|
|
6
7
|
if (!cssv) {
|
|
@@ -13,21 +14,14 @@ export function makeThemePropType(cssv = null) {
|
|
|
13
14
|
if (val === null || val === undefined) {
|
|
14
15
|
return new Error(`${propName} missing or null`);
|
|
15
16
|
}
|
|
16
|
-
}
|
|
17
|
+
};
|
|
17
18
|
return validate;
|
|
18
|
-
}
|
|
19
|
+
};
|
|
19
20
|
}
|
|
20
21
|
const props = {
|
|
21
22
|
actionColor: cssv("color").isRequired,
|
|
22
|
-
actionColorFg: cssv("color").isRequired,
|
|
23
23
|
actionCompletedColor: cssv("color").isRequired,
|
|
24
|
-
actionLateColor: cssv("color").isRequired,
|
|
25
|
-
actionMergedColor: cssv("color").isRequired,
|
|
26
|
-
actionNotStartedColor: cssv("color").isRequired,
|
|
27
24
|
actionOnTimeColor: cssv("color").isRequired,
|
|
28
|
-
actionSeverelyLateColor: cssv("color").isRequired,
|
|
29
|
-
badgeBackground: cssv("color"),
|
|
30
|
-
badgeColor: cssv("color"),
|
|
31
25
|
badgeBorderRadius: oneOfType([string, number]).isRequired,
|
|
32
26
|
badgeFontWeight: number.isRequired,
|
|
33
27
|
badgePaddingX: string.isRequired,
|
|
@@ -44,11 +38,7 @@ export function makeThemePropType(cssv = null) {
|
|
|
44
38
|
btnBorderWidth: cssv("border-width"),
|
|
45
39
|
cardBorderRadius: cssv("border-radius"),
|
|
46
40
|
cardBorderWidth: cssv("border-width"),
|
|
47
|
-
causalityDecreasesColor: cssv("color"),
|
|
48
|
-
causalityIncreasesColor: cssv("color"),
|
|
49
|
-
causalityIsPartOfColor: cssv("color"),
|
|
50
41
|
combinedIconsFilename: string.isRequired,
|
|
51
|
-
componentActiveBg: string.isRequired,
|
|
52
42
|
customSelectIndicator: string.isRequired,
|
|
53
43
|
fontFamily: cssv("font-family").allowEmpty,
|
|
54
44
|
fontFamilyContent: cssv("font-family").allowEmpty,
|
|
@@ -129,14 +119,9 @@ export function makeThemePropType(cssv = null) {
|
|
|
129
119
|
lineHeightSm: number.isRequired,
|
|
130
120
|
linkColor: string.isRequired,
|
|
131
121
|
linkHoverColor: string.isRequired,
|
|
132
|
-
listGroupActiveBg: string.isRequired,
|
|
133
|
-
listGroupActiveBorderColor: string.isRequired,
|
|
134
122
|
name: string.isRequired,
|
|
135
|
-
navPillsLinkActiveBg: string.isRequired,
|
|
136
123
|
neutralDark: string.isRequired,
|
|
137
124
|
neutralLight: string.isRequired,
|
|
138
|
-
operationalIndicatorColor: string.isRequired,
|
|
139
|
-
operationalIndicatorColorFg: string.isRequired,
|
|
140
125
|
space: string.isRequired,
|
|
141
126
|
spaces: exact({
|
|
142
127
|
s000: number.isRequired,
|
|
@@ -150,12 +135,8 @@ export function makeThemePropType(cssv = null) {
|
|
|
150
135
|
s600: string.isRequired,
|
|
151
136
|
s800: string.isRequired,
|
|
152
137
|
}).isRequired,
|
|
153
|
-
strategicIndicatorColor: string.isRequired,
|
|
154
|
-
strategicIndicatorColorFg: string.isRequired,
|
|
155
138
|
tableHeadBg: string.isRequired,
|
|
156
139
|
tableHoverBg: string.isRequired,
|
|
157
|
-
tacticalIndicatorColor: string.isRequired,
|
|
158
|
-
tacticalIndicatorColorFg: string.isRequired,
|
|
159
140
|
themeColors: exact({
|
|
160
141
|
black: string.isRequired,
|
|
161
142
|
dark: string.isRequired,
|
|
@@ -177,13 +158,16 @@ export function makeThemePropType(cssv = null) {
|
|
|
177
158
|
categories: exact({
|
|
178
159
|
filterIndicatorsByAllLevels: bool.isRequired,
|
|
179
160
|
}),
|
|
161
|
+
hiddenLocales: arrayOf(string),
|
|
180
162
|
fundingInstruments: array.isRequired,
|
|
163
|
+
leftAlignCategoryPages: bool,
|
|
181
164
|
otherLogos: array.isRequired,
|
|
182
165
|
attentionBannerContent: object,
|
|
183
166
|
footerLogoOnly: bool,
|
|
184
167
|
footerStatement: string,
|
|
185
168
|
footerAdditionalLinks: array,
|
|
186
169
|
navigationLogoOnly: bool,
|
|
170
|
+
stickyNavigation: bool,
|
|
187
171
|
homeLink: string,
|
|
188
172
|
a11y: exact({
|
|
189
173
|
responsibleBody: string,
|
package/types.ts
CHANGED
|
@@ -6,15 +6,8 @@ type cssColor = NonNullable<css['color']>;
|
|
|
6
6
|
|
|
7
7
|
export interface Theme {
|
|
8
8
|
actionColor: string;
|
|
9
|
-
actionColorFg: string;
|
|
10
9
|
actionCompletedColor: string;
|
|
11
|
-
actionLateColor: string;
|
|
12
|
-
actionMergedColor: string;
|
|
13
|
-
actionNotStartedColor: string;
|
|
14
10
|
actionOnTimeColor: string;
|
|
15
|
-
actionSeverelyLateColor: string;
|
|
16
|
-
badgeBackground: cssColor;
|
|
17
|
-
badgeColor: cssColor;
|
|
18
11
|
badgeBorderRadius: string | number;
|
|
19
12
|
badgeFontWeight: number;
|
|
20
13
|
badgePaddingX: string;
|
|
@@ -31,11 +24,7 @@ export interface Theme {
|
|
|
31
24
|
btnBorderWidth: css["borderWidth"];
|
|
32
25
|
cardBorderRadius: css["borderRadius"];
|
|
33
26
|
cardBorderWidth: css["borderWidth"];
|
|
34
|
-
causalityDecreasesColor: cssColor;
|
|
35
|
-
causalityIncreasesColor: cssColor;
|
|
36
|
-
causalityIsPartOfColor: cssColor;
|
|
37
27
|
combinedIconsFilename: string;
|
|
38
|
-
componentActiveBg: string;
|
|
39
28
|
customSelectIndicator: string;
|
|
40
29
|
fontFamily: string;
|
|
41
30
|
fontFamilyContent: string;
|
|
@@ -116,14 +105,9 @@ export interface Theme {
|
|
|
116
105
|
lineHeightSm: number;
|
|
117
106
|
linkColor: cssColor;
|
|
118
107
|
linkHoverColor: string;
|
|
119
|
-
listGroupActiveBg: string;
|
|
120
|
-
listGroupActiveBorderColor: string;
|
|
121
108
|
name: string;
|
|
122
|
-
navPillsLinkActiveBg: string;
|
|
123
109
|
neutralDark: cssColor;
|
|
124
110
|
neutralLight: cssColor;
|
|
125
|
-
operationalIndicatorColor: cssColor;
|
|
126
|
-
operationalIndicatorColorFg: cssColor;
|
|
127
111
|
space: string;
|
|
128
112
|
spaces: {
|
|
129
113
|
s000: number;
|
|
@@ -137,12 +121,8 @@ export interface Theme {
|
|
|
137
121
|
s600: string;
|
|
138
122
|
s800: string;
|
|
139
123
|
};
|
|
140
|
-
strategicIndicatorColor: string;
|
|
141
|
-
strategicIndicatorColorFg: string;
|
|
142
124
|
tableHeadBg: string;
|
|
143
125
|
tableHoverBg: string;
|
|
144
|
-
tacticalIndicatorColor: string;
|
|
145
|
-
tacticalIndicatorColorFg: string;
|
|
146
126
|
themeColors: {
|
|
147
127
|
black: string;
|
|
148
128
|
dark: string;
|
|
@@ -163,11 +143,14 @@ export interface Theme {
|
|
|
163
143
|
categories: {
|
|
164
144
|
filterIndicatorsByAllLevels: boolean;
|
|
165
145
|
};
|
|
146
|
+
hiddenLocales: string[];
|
|
166
147
|
fundingInstruments: object[];
|
|
148
|
+
leftAlignCategoryPages: boolean;
|
|
167
149
|
otherLogos: object[];
|
|
168
150
|
attentionBannerContent?: object;
|
|
169
151
|
footerLogoOnly?: boolean;
|
|
170
152
|
navigationLogoOnly?: boolean;
|
|
153
|
+
stickyNavigation?: boolean;
|
|
171
154
|
homeLink?: string;
|
|
172
155
|
a11y?: {
|
|
173
156
|
responsibleBody?: string;
|