@kausal/themes 0.6.5 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -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)","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":[]}}
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)"},"textColor":{"primary":"rgb(29, 29, 29)","secondary":"rgb(75, 75, 75)","tertiary":"rgb(160, 160, 160)"},"cardBackground":{"primary":"rgb(248, 248, 248)","secondary":"rgb(243, 243, 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
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kausal/themes",
3
- "version": "0.6.5",
3
+ "version": "0.7.0",
4
4
  "description": "Themes for Kausal products",
5
5
  "type": "module",
6
6
  "main": "setup.cjs",
package/props.js CHANGED
@@ -1,4 +1,4 @@
1
- import PropTypes from "prop-types";
1
+ import PropTypes from 'prop-types';
2
2
 
3
3
  const { number, exact, string, oneOfType, bool, array, object, arrayOf } =
4
4
  PropTypes;
@@ -19,87 +19,87 @@ export function makeThemePropType(cssv = null) {
19
19
  };
20
20
  }
21
21
  const props = {
22
- actionColor: cssv("color").isRequired,
23
- actionCompletedColor: cssv("color").isRequired,
24
- actionOnTimeColor: cssv("color").isRequired,
22
+ actionColor: cssv('color').isRequired,
23
+ actionCompletedColor: cssv('color').isRequired,
24
+ actionOnTimeColor: cssv('color').isRequired,
25
25
  badgeBorderRadius: oneOfType([string, number]).isRequired,
26
26
  badgeFontWeight: number.isRequired,
27
27
  badgePaddingX: string.isRequired,
28
28
  badgePaddingY: string.isRequired,
29
29
  brandDark: string.isRequired,
30
30
  brandLight: string.isRequired,
31
- brandNavBackground: cssv("color"),
32
- brandNavColor: cssv("color"),
31
+ brandNavBackground: cssv('color'),
32
+ brandNavColor: cssv('color'),
33
33
  breakpointLg: string.isRequired,
34
34
  breakpointMd: string.isRequired,
35
35
  breakpointSm: string.isRequired,
36
36
  breakpointXl: string.isRequired,
37
- btnBorderRadius: cssv("border-radius"),
38
- btnBorderWidth: cssv("border-width"),
39
- cardBorderRadius: cssv("border-radius"),
40
- cardBorderWidth: cssv("border-width"),
37
+ btnBorderRadius: cssv('border-radius'),
38
+ btnBorderWidth: cssv('border-width'),
39
+ cardBorderRadius: cssv('border-radius'),
40
+ cardBorderWidth: cssv('border-width'),
41
41
  combinedIconsFilename: string.isRequired,
42
42
  customSelectIndicator: string.isRequired,
43
- fontFamily: cssv("font-family").allowEmpty,
44
- fontFamilyContent: cssv("font-family").allowEmpty,
45
- fontFamilyTiny: cssv("font-family").allowEmpty,
46
- fontFamilyHeadings: cssv("font-family").allowEmpty,
47
- fontFamilyFallback: cssv("font-family").allowEmpty,
48
- fontFamilyFallbackHeadings: cssv("font-family").allowEmpty,
49
- fontSizeBase: cssv("font-size").isRequired,
50
- fontSizeLg: cssv("font-size").isRequired,
51
- fontSizeMd: cssv("font-size").isRequired,
52
- fontSizeSm: cssv("font-size").isRequired,
53
- fontSizeXl: cssv("font-size").isRequired,
54
- fontSizeXxl: cssv("font-size").isRequired,
55
- fontWeightBase: cssv("font-weight").isRequired,
56
- fontWeightBold: cssv("font-weight").isRequired,
57
- fontWeightNormal: cssv("font-weight").isRequired,
43
+ fontFamily: cssv('font-family').allowEmpty,
44
+ fontFamilyContent: cssv('font-family').allowEmpty,
45
+ fontFamilyTiny: cssv('font-family').allowEmpty,
46
+ fontFamilyHeadings: cssv('font-family').allowEmpty,
47
+ fontFamilyFallback: cssv('font-family').allowEmpty,
48
+ fontFamilyFallbackHeadings: cssv('font-family').allowEmpty,
49
+ fontSizeBase: cssv('font-size').isRequired,
50
+ fontSizeLg: cssv('font-size').isRequired,
51
+ fontSizeMd: cssv('font-size').isRequired,
52
+ fontSizeSm: cssv('font-size').isRequired,
53
+ fontSizeXl: cssv('font-size').isRequired,
54
+ fontSizeXxl: cssv('font-size').isRequired,
55
+ fontWeightBase: cssv('font-weight').isRequired,
56
+ fontWeightBold: cssv('font-weight').isRequired,
57
+ fontWeightNormal: cssv('font-weight').isRequired,
58
58
  navLogoVisible: bool.isRequired,
59
59
  navTitleVisible: bool.isRequired,
60
60
  navLinkIcons: bool,
61
61
  footerLogoPlacement: string.isRequired,
62
62
  footerLogoSize: string,
63
63
  footerLogoLink: string,
64
- footerBackgroundColor: cssv("color"),
65
- footerColor: cssv("color"),
64
+ footerBackgroundColor: cssv('color'),
65
+ footerColor: cssv('color'),
66
66
  formLabelFontWeight: number.isRequired,
67
67
  graphColors: exact({
68
- grey000: cssv("color"),
69
- grey005: cssv("color"),
70
- grey010: cssv("color"),
71
- grey020: cssv("color"),
72
- grey030: cssv("color"),
73
- grey040: cssv("color"),
74
- grey050: cssv("color"),
75
- grey060: cssv("color"),
76
- grey070: cssv("color"),
77
- grey080: cssv("color"),
78
- grey090: cssv("color"),
79
- grey100: cssv("color"),
80
- green010: cssv("color"),
81
- green030: cssv("color"),
82
- green050: cssv("color"),
83
- green070: cssv("color"),
84
- green090: cssv("color"),
85
- red010: cssv("color"),
86
- red030: cssv("color"),
87
- red050: cssv("color"),
88
- red070: cssv("color"),
89
- red090: cssv("color"),
90
- blue010: cssv("color"),
91
- blue030: cssv("color"),
92
- blue050: cssv("color"),
93
- blue070: cssv("color"),
94
- blue090: cssv("color"),
95
- yellow010: cssv("color"),
96
- yellow030: cssv("color"),
97
- yellow050: cssv("color"),
98
- yellow070: cssv("color"),
99
- yellow090: cssv("color"),
68
+ grey000: cssv('color'),
69
+ grey005: cssv('color'),
70
+ grey010: cssv('color'),
71
+ grey020: cssv('color'),
72
+ grey030: cssv('color'),
73
+ grey040: cssv('color'),
74
+ grey050: cssv('color'),
75
+ grey060: cssv('color'),
76
+ grey070: cssv('color'),
77
+ grey080: cssv('color'),
78
+ grey090: cssv('color'),
79
+ grey100: cssv('color'),
80
+ green010: cssv('color'),
81
+ green030: cssv('color'),
82
+ green050: cssv('color'),
83
+ green070: cssv('color'),
84
+ green090: cssv('color'),
85
+ red010: cssv('color'),
86
+ red030: cssv('color'),
87
+ red050: cssv('color'),
88
+ red070: cssv('color'),
89
+ red090: cssv('color'),
90
+ blue010: cssv('color'),
91
+ blue030: cssv('color'),
92
+ blue050: cssv('color'),
93
+ blue070: cssv('color'),
94
+ blue090: cssv('color'),
95
+ yellow010: cssv('color'),
96
+ yellow030: cssv('color'),
97
+ yellow050: cssv('color'),
98
+ yellow070: cssv('color'),
99
+ yellow090: cssv('color'),
100
100
  }).isRequired,
101
- headingsColor: cssv("color"),
102
- headingsFontWeight: cssv("font-weight").isRequired,
101
+ headingsColor: cssv('color'),
102
+ headingsFontWeight: cssv('font-weight').isRequired,
103
103
  iconActionsUrl: string.isRequired,
104
104
  iconIndicatorsUrl: string.isRequired,
105
105
  iconsUrl: string.isRequired,
@@ -146,6 +146,15 @@ export function makeThemePropType(cssv = null) {
146
146
  themeCustomStylesUrl: string.isRequired,
147
147
  themeLogoUrl: string.isRequired,
148
148
  themeLogoWhiteUrl: string.isRequired,
149
+ textColor: exact({
150
+ primary: cssv('color').isRequired,
151
+ secondary: cssv('color').isRequired,
152
+ tertiary: cssv('color').isRequired,
153
+ }),
154
+ cardBackground: exact({
155
+ primary: cssv('color').isRequired,
156
+ secondary: cssv('color').isRequired,
157
+ }),
149
158
  settings: exact({
150
159
  dashboard: exact({
151
160
  showResponsibles: bool.isRequired,
package/types.ts CHANGED
@@ -1,6 +1,6 @@
1
- import type { StandardProperties as css } from "csstype";
1
+ import type { StandardProperties as css } from 'csstype';
2
2
 
3
- type cssColor = NonNullable<css["color"]>;
3
+ type cssColor = NonNullable<css['color']>;
4
4
 
5
5
  export interface Theme {
6
6
  actionColor: string;
@@ -18,10 +18,10 @@ export interface Theme {
18
18
  breakpointMd: string;
19
19
  breakpointSm: string;
20
20
  breakpointXl: string;
21
- btnBorderRadius: css["borderRadius"];
22
- btnBorderWidth: css["borderWidth"];
23
- cardBorderRadius: css["borderRadius"];
24
- cardBorderWidth: css["borderWidth"];
21
+ btnBorderRadius: css['borderRadius'];
22
+ btnBorderWidth: css['borderWidth'];
23
+ cardBorderRadius: css['borderRadius'];
24
+ cardBorderWidth: css['borderWidth'];
25
25
  combinedIconsFilename: string;
26
26
  customSelectIndicator: string;
27
27
  fontFamily: string;
@@ -83,7 +83,7 @@ export interface Theme {
83
83
  yellow090: cssColor;
84
84
  };
85
85
  headingsColor: cssColor;
86
- headingsFontWeight: css["fontWeight"];
86
+ headingsFontWeight: css['fontWeight'];
87
87
  iconActionsUrl: string;
88
88
  iconIndicatorsUrl: string;
89
89
  iconsUrl: string;
@@ -130,6 +130,15 @@ export interface Theme {
130
130
  themeCustomStylesUrl: string;
131
131
  themeLogoUrl: string;
132
132
  themeLogoWhiteUrl: string;
133
+ textColor: {
134
+ primary: string;
135
+ secondary: string;
136
+ tertiary: string;
137
+ };
138
+ cardBackground: {
139
+ primary: string;
140
+ secondary: string;
141
+ };
133
142
  settings: {
134
143
  dashboard: {
135
144
  showResponsibles: boolean;