@mackin.com/styleguide 7.10.0 → 7.11.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.
Files changed (3) hide show
  1. package/index.d.ts +4 -0
  2. package/index.js +6 -0
  3. package/package.json +1 -1
package/index.d.ts CHANGED
@@ -810,6 +810,10 @@ interface MackinTheme {
810
810
  desktop: string;
811
811
  tablet: string;
812
812
  };
813
+ mediaQueries: {
814
+ desktop: string;
815
+ tablet: string;
816
+ };
813
817
  }
814
818
  /** Call this on your theme after messing with the props. It will re-build things that depend on sizes and colors. */
815
819
  declare const calcDynamicThemeProps: <T extends MackinTheme>(theme: T) => void;
package/index.js CHANGED
@@ -47,6 +47,8 @@ const calcDynamicThemeProps = (theme) => {
47
47
  theme.controls.focusOutlineShadow = `0px 0px 4px 2px ${theme.colors.focusOutline}`;
48
48
  theme.controls.focusOutlineRequiredShadow = `0px 0px 4px 2px ${theme.colors.focusOutlineRequired}`;
49
49
  theme.controls.dividerBorder = `2px solid ${theme.colors.divider}`;
50
+ theme.mediaQueries.desktop = `@media(min-width:${theme.breakpoints.desktop})`;
51
+ theme.mediaQueries.tablet = `@media(min-width:${theme.breakpoints.tablet})`;
50
52
  };
51
53
  const defaultTheme = {
52
54
  colors: {
@@ -135,6 +137,10 @@ const defaultTheme = {
135
137
  breakpoints: {
136
138
  desktop: '800px',
137
139
  tablet: '768px'
140
+ },
141
+ mediaQueries: {
142
+ desktop: '',
143
+ tablet: ''
138
144
  }
139
145
  };
140
146
  calcDynamicThemeProps(defaultTheme);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mackin.com/styleguide",
3
- "version": "7.10.0",
3
+ "version": "7.11.0",
4
4
  "description": "",
5
5
  "main": "./index.js",
6
6
  "types": "./index.d.ts",