@mackin.com/styleguide 8.2.2 → 8.2.3
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/index.js +5 -4
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -118,7 +118,6 @@ const calcDynamicThemeProps = (theme) => {
|
|
|
118
118
|
theme.controls.focusOutlineRequiredShadow = `0px 0px 4px 2px ${theme.colors.focusOutlineRequired}`;
|
|
119
119
|
theme.controls.dividerBorder = `${theme.controls.dividerThickness} solid ${theme.colors.divider}`;
|
|
120
120
|
theme.controls.inputErrorMinHeight = `calc(${theme.fonts.sizeSmall} * 1.5 + 4px)`;
|
|
121
|
-
theme.controls.buttonBoxShadow = theme.controls.boxShadow;
|
|
122
121
|
theme.mediaQueries.desktop = `@media(min-width:${theme.breakpoints.desktop})`;
|
|
123
122
|
theme.mediaQueries.tablet = `@media(min-width:${theme.breakpoints.tablet})`;
|
|
124
123
|
};
|
|
@@ -181,6 +180,8 @@ const defaultTheme = {
|
|
|
181
180
|
height: '44px',
|
|
182
181
|
heightSmall: '34px',
|
|
183
182
|
boxShadow: '2px 2px 4px rgba(0, 0, 0, 0.25)',
|
|
183
|
+
headerBoxShadow: '0px 2px 12px 6px rgba(0, 0, 0, 0.2)',
|
|
184
|
+
buttonBoxShadow: '2px 2px 4px rgba(0, 0, 0, 0.25)',
|
|
184
185
|
hoverBrightness: 'brightness(0.75)',
|
|
185
186
|
transitionDuration: '0.25s',
|
|
186
187
|
transitionEasing: 'ease-in-out',
|
|
@@ -194,8 +195,6 @@ const defaultTheme = {
|
|
|
194
195
|
dividerMargin: '1rem',
|
|
195
196
|
dividerBorder: '',
|
|
196
197
|
dividerThickness: '2px',
|
|
197
|
-
headerBoxShadow: '0px 2px 12px 6px rgba(0, 0, 0, 0.2)',
|
|
198
|
-
buttonBoxShadow: '',
|
|
199
198
|
inputErrorMinHeight: '',
|
|
200
199
|
paragraphPadding: '1rem'
|
|
201
200
|
},
|
|
@@ -4614,6 +4613,8 @@ const Link = (props) => {
|
|
|
4614
4613
|
|
|
4615
4614
|
const ThemeRenderer = (p) => {
|
|
4616
4615
|
const { backgroundColor, color } = p, theme = __rest(p, ["backgroundColor", "color"]);
|
|
4616
|
+
const flatTheme = flatten(theme);
|
|
4617
|
+
const entries = lodash.orderBy(Object.entries(flatTheme), x => x[0]);
|
|
4617
4618
|
return (React__namespace.createElement(Table, { caption: (React__namespace.createElement("div", null,
|
|
4618
4619
|
React__namespace.createElement(Text, { tag: "h1", align: "center" }, "Theme"),
|
|
4619
4620
|
React__namespace.createElement(Text, { tag: "p", align: "center", italics: true }, "Background color applied to show colors with alpha ('rgba(X, X, X, 0.X)')"))), className: css.css({
|
|
@@ -4624,7 +4625,7 @@ const ThemeRenderer = (p) => {
|
|
|
4624
4625
|
React__namespace.createElement(Tr, null,
|
|
4625
4626
|
React__namespace.createElement(Th, { align: "left" }, "Property"),
|
|
4626
4627
|
React__namespace.createElement(Th, { align: "left" }, "Value"))),
|
|
4627
|
-
React__namespace.createElement("tbody", null,
|
|
4628
|
+
React__namespace.createElement("tbody", null, entries.map(([key, value]) => {
|
|
4628
4629
|
let colorBox;
|
|
4629
4630
|
if (/color/i.test(key)) {
|
|
4630
4631
|
colorBox = (React__namespace.createElement("span", { className: css.css({
|