Skip to content

Commit 8095cd1

Browse files
chore(release): 1.7.2 [skip ci]
## [1.7.2](v1.7.1...v1.7.2) (2023-05-12) ### Bug Fixes * export themeOptions and add contrast text ([2cd77a9](2cd77a9))
1 parent 2cd77a9 commit 8095cd1

File tree

5 files changed

+32
-14
lines changed

5 files changed

+32
-14
lines changed

CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,10 @@
1+
## [1.7.2](https://github.com/ocadotechnology/codeforlife-package-javascript/compare/v1.7.1...v1.7.2) (2023-05-12)
2+
3+
4+
### Bug Fixes
5+
6+
* export themeOptions and add contrast text ([2cd77a9](https://github.com/ocadotechnology/codeforlife-package-javascript/commit/2cd77a9593b234eb3e23c26c2682b8d1ba0a54ae))
7+
18
## [1.7.1](https://github.com/ocadotechnology/codeforlife-package-javascript/compare/v1.7.0...v1.7.1) (2023-05-10)
29

310

lib/cjs/theme.d.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { PaletteColor } from '@mui/material';
1+
import { ThemeOptions, PaletteColor } from '@mui/material/styles';
22
declare module '@mui/material/styles' {
33
interface CustomPaletteColors {
44
tertiary: PaletteColor;
@@ -69,5 +69,6 @@ declare module '@mui/material' {
6969
interface ToggleButtonGroupPropsColorOverrides extends PropsColorOverrides {
7070
}
7171
}
72-
declare const theme: import("@mui/material").Theme;
72+
export declare const themeOptions: ThemeOptions;
73+
declare const theme: import("@mui/material/styles").Theme;
7374
export default theme;

lib/cjs/theme.js

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ var __assign = (this && this.__assign) || function () {
1111
return __assign.apply(this, arguments);
1212
};
1313
Object.defineProperty(exports, "__esModule", { value: true });
14+
exports.themeOptions = void 0;
1415
var styles_1 = require("@mui/material/styles");
1516
var colors_1 = require("@mui/material/colors");
1617
var palette = (0, styles_1.createTheme)().palette;
@@ -47,18 +48,21 @@ function getClassStyleOverrides(className) {
4748
}
4849
return styleOverrides;
4950
}
50-
var theme = (0, styles_1.responsiveFontSizes)((0, styles_1.createTheme)({
51+
exports.themeOptions = {
5152
palette: {
5253
primary: {
5354
main: '#e0004d',
54-
light: '#fa1664'
55+
light: '#fa1664',
56+
contrastText: colors_1.common.white
5557
},
5658
secondary: {
57-
main: '#00a3e0'
59+
main: '#00a3e0',
60+
contrastText: colors_1.common.white
5861
},
5962
tertiary: palette.augmentColor({
6063
color: {
61-
main: '#ffd23b'
64+
main: '#ffd23b',
65+
contrastText: colors_1.common.black
6266
}
6367
}),
6468
white: palette.augmentColor({
@@ -138,5 +142,6 @@ var theme = (0, styles_1.responsiveFontSizes)((0, styles_1.createTheme)({
138142
}
139143
}
140144
}
141-
}));
145+
};
146+
var theme = (0, styles_1.responsiveFontSizes)((0, styles_1.createTheme)(exports.themeOptions));
142147
exports.default = theme;

lib/esm/theme.d.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { PaletteColor } from '@mui/material';
1+
import { ThemeOptions, PaletteColor } from '@mui/material/styles';
22
declare module '@mui/material/styles' {
33
interface CustomPaletteColors {
44
tertiary: PaletteColor;
@@ -69,5 +69,6 @@ declare module '@mui/material' {
6969
interface ToggleButtonGroupPropsColorOverrides extends PropsColorOverrides {
7070
}
7171
}
72-
declare const theme: import("@mui/material").Theme;
72+
export declare const themeOptions: ThemeOptions;
73+
declare const theme: import("@mui/material/styles").Theme;
7374
export default theme;

lib/esm/theme.js

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -45,18 +45,21 @@ function getClassStyleOverrides(className) {
4545
}
4646
return styleOverrides;
4747
}
48-
var theme = responsiveFontSizes(createTheme({
48+
export var themeOptions = {
4949
palette: {
5050
primary: {
5151
main: '#e0004d',
52-
light: '#fa1664'
52+
light: '#fa1664',
53+
contrastText: common.white
5354
},
5455
secondary: {
55-
main: '#00a3e0'
56+
main: '#00a3e0',
57+
contrastText: common.white
5658
},
5759
tertiary: palette.augmentColor({
5860
color: {
59-
main: '#ffd23b'
61+
main: '#ffd23b',
62+
contrastText: common.black
6063
}
6164
}),
6265
white: palette.augmentColor({
@@ -136,5 +139,6 @@ var theme = responsiveFontSizes(createTheme({
136139
}
137140
}
138141
}
139-
}));
142+
};
143+
var theme = responsiveFontSizes(createTheme(themeOptions));
140144
export default theme;

0 commit comments

Comments
 (0)