@automattic/vip-design-system 2.18.1 → 2.19.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.
- package/.storybook/preview-head.html +1 -0
- package/build/system/Badge/Badge.js +2 -1
- package/build/system/DescriptionList/DescriptionList.js +0 -1
- package/build/system/Form/Label.d.ts +1 -3
- package/build/system/Form/Label.js +1 -3
- package/build/system/Form/RadioBoxGroup.jsx +12 -1
- package/build/system/Form/RadioBoxGroup.stories.jsx +6 -1
- package/build/system/Heading/Heading.js +2 -3
- package/build/system/Heading/Heading.stories.js +15 -2
- package/build/system/Nav/styles/variants/menu.js +1 -2
- package/build/system/Notice/Notice.js +1 -1
- package/build/system/Pagination/styles.js +1 -4
- package/build/system/Table/TableCell.js +1 -1
- package/build/system/Text/Text.js +0 -1
- package/build/system/Text/Text.stories.js +16 -13
- package/build/system/Toolbar/Logo.js +22 -6
- package/build/system/Wizard/Wizard.stories.js +11 -11
- package/build/system/Wizard/WizardStep.js +0 -2
- package/build/system/theme/generated/valet-theme-dark.json +224 -227
- package/build/system/theme/generated/valet-theme-light.json +224 -227
- package/build/system/theme/getPropValue.js +3 -7
- package/build/system/theme/index.d.ts +20 -12
- package/build/system/theme/index.js +27 -20
- package/docs/SETUP.md +1 -1
- package/package.json +1 -1
- package/src/system/Badge/Badge.tsx +2 -1
- package/src/system/DescriptionList/DescriptionList.tsx +0 -1
- package/src/system/Form/Label.tsx +1 -3
- package/src/system/Form/RadioBoxGroup.jsx +12 -1
- package/src/system/Form/RadioBoxGroup.stories.jsx +6 -1
- package/src/system/Heading/Heading.stories.tsx +10 -1
- package/src/system/Heading/Heading.tsx +1 -2
- package/src/system/Nav/styles/variants/menu.ts +1 -2
- package/src/system/Notice/Notice.tsx +1 -1
- package/src/system/Pagination/styles.ts +1 -4
- package/src/system/Table/TableCell.tsx +1 -1
- package/src/system/Text/Text.stories.tsx +7 -4
- package/src/system/Text/Text.tsx +0 -1
- package/src/system/Toolbar/Logo.tsx +19 -2
- package/src/system/Wizard/Wizard.stories.tsx +11 -11
- package/src/system/Wizard/WizardStep.tsx +0 -2
- package/src/system/theme/generated/valet-theme-dark.json +224 -227
- package/src/system/theme/generated/valet-theme-light.json +224 -227
- package/src/system/theme/getPropValue.ts +1 -8
- package/src/system/theme/index.ts +33 -18
- package/tokens/valet-core/valet-core.json +39 -9
- package/tokens/valet-core/wpvip-product-core.json +88 -125
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<link rel="stylesheet" href="https://use.typekit.net/yym8qzc.css" />
|
|
@@ -25,6 +25,7 @@ export var Badge = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
25
25
|
as: "span",
|
|
26
26
|
sx: _extends({
|
|
27
27
|
fontSize: 0,
|
|
28
|
+
letterSpacing: '0.01em',
|
|
28
29
|
padding: 0,
|
|
29
30
|
// do we need padding declared twice here?
|
|
30
31
|
bg: "tag." + variant + ".background",
|
|
@@ -34,7 +35,7 @@ export var Badge = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
34
35
|
px: 2,
|
|
35
36
|
display: 'inline-block',
|
|
36
37
|
borderRadius: 1,
|
|
37
|
-
fontWeight: '
|
|
38
|
+
fontWeight: 'medium',
|
|
38
39
|
a: {
|
|
39
40
|
color: "tag." + variant + ".text",
|
|
40
41
|
'&:hover, &:focus, &:active': {
|
|
@@ -6,9 +6,7 @@ import React from 'react';
|
|
|
6
6
|
import { BoxProps } from 'theme-ui';
|
|
7
7
|
export declare const baseLabelColor = "input.label.default";
|
|
8
8
|
export declare const baseLabelStyle: {
|
|
9
|
-
|
|
10
|
-
fontSize: number;
|
|
11
|
-
lineHeight: number;
|
|
9
|
+
variant: string;
|
|
12
10
|
color: string;
|
|
13
11
|
};
|
|
14
12
|
export interface LabelProps extends BoxProps {
|
|
@@ -16,9 +16,7 @@ import { RequiredLabel } from './RequiredLabel';
|
|
|
16
16
|
import { jsx as _jsx, jsxs as _jsxs } from "theme-ui/jsx-runtime";
|
|
17
17
|
export var baseLabelColor = 'input.label.default';
|
|
18
18
|
export var baseLabelStyle = {
|
|
19
|
-
|
|
20
|
-
fontSize: 2,
|
|
21
|
-
lineHeight: 1.5,
|
|
19
|
+
variant: 'forms.label',
|
|
22
20
|
color: baseLabelColor
|
|
23
21
|
};
|
|
24
22
|
/**
|
|
@@ -72,7 +72,14 @@ const RadioOption = ( {
|
|
|
72
72
|
{ ...restOption }
|
|
73
73
|
/>
|
|
74
74
|
<div
|
|
75
|
-
sx={ {
|
|
75
|
+
sx={ {
|
|
76
|
+
mb: 0,
|
|
77
|
+
color: 'input.radio-box.label.primary.default',
|
|
78
|
+
fontWeight: 'semibold',
|
|
79
|
+
p: 3,
|
|
80
|
+
pr: 0,
|
|
81
|
+
flex: 'auto',
|
|
82
|
+
} }
|
|
76
83
|
>
|
|
77
84
|
<label htmlFor={ forLabel } { ...labelProps }>
|
|
78
85
|
{ label }
|
|
@@ -82,7 +89,11 @@ const RadioOption = ( {
|
|
|
82
89
|
sx={ {
|
|
83
90
|
color: 'input.radio-box.label.secondary.default',
|
|
84
91
|
mb: 0,
|
|
92
|
+
mt: 1,
|
|
85
93
|
fontSize: 1,
|
|
94
|
+
fontWeight: 'regular',
|
|
95
|
+
letterSpacing: '0.01em',
|
|
96
|
+
lineHeight: '140%',
|
|
86
97
|
display: 'block',
|
|
87
98
|
} }
|
|
88
99
|
id={ describedById }
|
|
@@ -60,7 +60,12 @@ export const Primary = {
|
|
|
60
60
|
args: {
|
|
61
61
|
defaultValue: 'one',
|
|
62
62
|
options: [
|
|
63
|
-
{
|
|
63
|
+
{
|
|
64
|
+
label: 'One',
|
|
65
|
+
value: 'one',
|
|
66
|
+
description:
|
|
67
|
+
'This is a longer description that allows us to see the text wrap and determine if the line height is correct',
|
|
68
|
+
},
|
|
64
69
|
{ label: 'Two', value: 'two', description: 'This is a description' },
|
|
65
70
|
{ label: 'Three', value: 'three', description: 'This is a description' },
|
|
66
71
|
],
|
|
@@ -19,10 +19,9 @@ export var Heading = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
19
19
|
rest = _objectWithoutPropertiesLoose(_ref, _excluded);
|
|
20
20
|
return _jsx(ThemeHeading, _extends({
|
|
21
21
|
as: variant,
|
|
22
|
+
variant: variant,
|
|
22
23
|
sx: _extends({
|
|
23
|
-
color: 'heading'
|
|
24
|
-
// pass variant prop to sx
|
|
25
|
-
variant: "text." + variant.toString()
|
|
24
|
+
color: 'heading'
|
|
26
25
|
}, sx),
|
|
27
26
|
className: classNames('vip-heading-component', className),
|
|
28
27
|
ref: ref
|
|
@@ -32,8 +32,21 @@ export var Default = {
|
|
|
32
32
|
variant: "h5",
|
|
33
33
|
children: "Heading Five"
|
|
34
34
|
}), _jsx(Heading, {
|
|
35
|
-
variant: "
|
|
36
|
-
|
|
35
|
+
variant: "h3",
|
|
36
|
+
as: "h1",
|
|
37
|
+
children: "Heading One with Heading Three Styles"
|
|
38
|
+
}), _jsx(Heading, {
|
|
39
|
+
as: "p",
|
|
40
|
+
sx: {
|
|
41
|
+
variant: 'text.caps'
|
|
42
|
+
},
|
|
43
|
+
children: "Paragraph with Caps Styles"
|
|
44
|
+
}), _jsx(Heading, {
|
|
45
|
+
as: "h3",
|
|
46
|
+
sx: {
|
|
47
|
+
variant: 'text.caps'
|
|
48
|
+
},
|
|
49
|
+
children: "Heading Three with Caps Styles"
|
|
37
50
|
})]
|
|
38
51
|
});
|
|
39
52
|
}
|
|
@@ -23,8 +23,7 @@ export var pageButtonStyles = {
|
|
|
23
23
|
bg: 'transparent',
|
|
24
24
|
color: 'heading',
|
|
25
25
|
cursor: 'pointer',
|
|
26
|
-
|
|
27
|
-
fontFamily: 'body',
|
|
26
|
+
variant: 'text.default',
|
|
28
27
|
px: 2,
|
|
29
28
|
borderBottom: '3px solid',
|
|
30
29
|
borderColor: 'transparent',
|
|
@@ -79,8 +78,6 @@ export var compactTriggerStyles = {
|
|
|
79
78
|
bg: 'transparent',
|
|
80
79
|
color: 'heading',
|
|
81
80
|
cursor: 'pointer',
|
|
82
|
-
fontSize: 2,
|
|
83
|
-
fontFamily: 'body',
|
|
84
81
|
fontWeight: 'bold',
|
|
85
82
|
px: 2,
|
|
86
83
|
borderRadius: 1,
|
|
@@ -27,7 +27,7 @@ export var TableCell = function TableCell(_ref) {
|
|
|
27
27
|
borderTop: head ? '1px solid' : 'none',
|
|
28
28
|
// borderColor should come after borderTop so it can override it
|
|
29
29
|
borderColor: 'table.border',
|
|
30
|
-
|
|
30
|
+
variant: 'text.default',
|
|
31
31
|
px: 3,
|
|
32
32
|
py: 2,
|
|
33
33
|
textAlign: 'left'
|
|
@@ -20,6 +20,21 @@ export var Default = {
|
|
|
20
20
|
return _jsxs(_Fragment, {
|
|
21
21
|
children: [_jsxs(Text, {
|
|
22
22
|
children: ["Apparently we had reached a great height in the atmosphere, for the sky was a dead black, and the stars had ceased to twinkle. By the same illusion which lifts the horizon of the sea to the level of the spectator on a hillside, the sable cloud beneath was dished out, and the car seemed to float in the middle of an immense dark sphere, whose upper half was strewn with silver.", ' ']
|
|
23
|
+
}), _jsx(Text, {
|
|
24
|
+
variant: "default",
|
|
25
|
+
children: "Body Default"
|
|
26
|
+
}), _jsx(Text, {
|
|
27
|
+
variant: "small",
|
|
28
|
+
children: "Body Small"
|
|
29
|
+
}), _jsx(Text, {
|
|
30
|
+
variant: "large",
|
|
31
|
+
children: "Body Large"
|
|
32
|
+
}), _jsx(Text, {
|
|
33
|
+
variant: "mono",
|
|
34
|
+
children: "Body Mono"
|
|
35
|
+
}), _jsx(Text, {
|
|
36
|
+
variant: "mono-bold",
|
|
37
|
+
children: "Body Mono Bold"
|
|
23
38
|
}), _jsx(Text, {
|
|
24
39
|
sx: {
|
|
25
40
|
color: 'texts.accent'
|
|
@@ -33,13 +48,7 @@ export var Default = {
|
|
|
33
48
|
}), _jsx(Text, {
|
|
34
49
|
sx: {
|
|
35
50
|
color: 'texts.helper',
|
|
36
|
-
fontWeight: '
|
|
37
|
-
},
|
|
38
|
-
children: "Text Helper"
|
|
39
|
-
}), _jsx(Text, {
|
|
40
|
-
sx: {
|
|
41
|
-
color: 'texts.helper',
|
|
42
|
-
fontWeight: 'heading'
|
|
51
|
+
fontWeight: 'light'
|
|
43
52
|
},
|
|
44
53
|
children: "Text Helper"
|
|
45
54
|
}), _jsx(Text, {
|
|
@@ -60,12 +69,6 @@ export var Default = {
|
|
|
60
69
|
fontWeight: 'bold'
|
|
61
70
|
},
|
|
62
71
|
children: "Text Helper"
|
|
63
|
-
}), _jsx(Text, {
|
|
64
|
-
sx: {
|
|
65
|
-
color: 'texts.helper',
|
|
66
|
-
fontWeight: 'light'
|
|
67
|
-
},
|
|
68
|
-
children: "Text Helper"
|
|
69
72
|
}), _jsx(Text, {
|
|
70
73
|
sx: {
|
|
71
74
|
color: 'texts.secondary'
|
|
@@ -10,7 +10,7 @@ import { Link } from 'theme-ui';
|
|
|
10
10
|
/**
|
|
11
11
|
* Internal dependencies
|
|
12
12
|
*/
|
|
13
|
-
import { jsx as _jsx } from "theme-ui/jsx-runtime";
|
|
13
|
+
import { jsx as _jsx, jsxs as _jsxs } from "theme-ui/jsx-runtime";
|
|
14
14
|
var VIP_LOGO = 'vip-logo-component';
|
|
15
15
|
/**
|
|
16
16
|
* The WordPress VIP logo rendered as an SVG inside a themed link.
|
|
@@ -29,15 +29,31 @@ export var Logo = function Logo(_ref) {
|
|
|
29
29
|
},
|
|
30
30
|
href: href,
|
|
31
31
|
as: as,
|
|
32
|
-
children:
|
|
32
|
+
children: _jsxs("svg", {
|
|
33
33
|
className: classNames(VIP_LOGO, className),
|
|
34
34
|
xmlns: "http://www.w3.org/2000/svg",
|
|
35
|
-
viewBox: "0 0
|
|
35
|
+
viewBox: "0 0 393.6 176.6",
|
|
36
36
|
role: "img",
|
|
37
37
|
"aria-label": "WordPress VIP Logo",
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
38
|
+
sx: {
|
|
39
|
+
display: 'block',
|
|
40
|
+
width: '100%',
|
|
41
|
+
height: 'auto'
|
|
42
|
+
},
|
|
43
|
+
children: [_jsx("path", {
|
|
44
|
+
fill: "currentColor",
|
|
45
|
+
d: "m88.3,0C39.6,0,0,39.6,0,88.3s39.6,88.3,88.3,88.3,88.3-39.5,88.3-88.3S137.1,0,88.3,0ZM8.8,88.3c0-11.5,2.5-22.5,6.8-32.4l37.8,103.8c-26-13-44.6-39.9-44.6-71.4Zm79.5,79.5c-7.7,0-15.3-1.1-22.5-3.2l23.7-69.2,24.4,66.9c.2.4.4.7.5,1.1-8.1,2.8-16.7,4.4-26.1,4.4Zm11-116.8c4.8-.4,9-.7,9-.7,4.1-.5,3.8-6.8-.5-6.5,0,0-13,.9-21.2.9-7.7,0-20.9-.9-20.9-.9-4.1-.4-4.8,6.3-.5,6.5,0,0,4.1.5,8.3.7l12.2,34-17.2,52-28.6-86c4.8-.4,9-.7,9-.7,4.1-.5,3.8-6.8-.5-6.5,0,0-13,.9-21.2.9-1.6,0-3.2,0-5.2-.2C36.1,23,60.5,8.8,88.2,8.8c20.7,0,39.5,7.9,53.6,20.9h-1.1c-7.7,0-13.3,6.8-13.3,14.2,0,6.5,3.8,12.2,7.7,18.7,2.9,5.2,6.5,12.2,6.5,21.9,0,6.8-2,15.5-6.1,25.7l-7.9,26.3-28.3-85.5Zm29.2,106l24.3-70.1c4.5-11.3,6.1-20.3,6.1-28.4,0-2.9-.2-5.5-.5-8.1,6.3,11.3,9.7,24.3,9.7,38.1-.3,29.1-16.3,54.8-39.6,68.5Z"
|
|
46
|
+
}), _jsx("path", {
|
|
47
|
+
fill: "currentColor",
|
|
48
|
+
d: "m323.7,39.2h33.4c7.2,0,13.1.9,17.8,2.5,4.7,1.6,8.5,3.8,11.1,6.5,2.9,2.7,4.7,5.8,5.8,9.3,1.1,3.4,1.8,7.2,1.8,11,0,4.1-.5,8.1-1.8,11.9-1.1,3.8-3.1,7-5.8,10.1-2.7,2.9-6.5,5.1-11,6.6-4.5,1.6-10.4,2.5-17.5,2.5h-14.7v33.4h-19.2V39.2h.1Zm33.3,44.1c3.4,0,6.3-.4,8.5-1.1,2.4-.7,4.1-1.6,5.4-2.9,1.3-1.3,2.1-2.7,2.7-4.5.5-1.8.7-3.8.7-5.9s-.2-4.1-.7-5.8c-.5-1.6-1.4-3.1-2.7-4.1-1.3-1.1-3.1-2-5.4-2.7-2.1-.5-5.1-.9-8.5-.9h-14v27.8h14v.1Z"
|
|
49
|
+
}), _jsx("path", {
|
|
50
|
+
fill: "currentColor",
|
|
51
|
+
d: "m197.5,39.2h21.9l22.8,66.3,23.4-66.3h21l-35.3,93.9h-18.5l-35.3-93.9Z"
|
|
52
|
+
}), _jsx("path", {
|
|
53
|
+
fill: "currentColor",
|
|
54
|
+
fillRule: "evenodd",
|
|
55
|
+
d: "m311,39.2h-13.3l-6.3,16.9v76.9h19.6V39.2Z"
|
|
56
|
+
})]
|
|
41
57
|
})
|
|
42
58
|
});
|
|
43
59
|
};
|
|
@@ -24,16 +24,16 @@ export var Primary = {
|
|
|
24
24
|
summaryAs: 'dl',
|
|
25
25
|
steps: [{
|
|
26
26
|
title: 'Step One',
|
|
27
|
-
titleVariant: '
|
|
27
|
+
titleVariant: 'h3',
|
|
28
28
|
subTitle: 'First step description.',
|
|
29
29
|
children: 'Step one content'
|
|
30
30
|
}, {
|
|
31
31
|
title: 'Step Two',
|
|
32
|
-
titleVariant: '
|
|
32
|
+
titleVariant: 'h3',
|
|
33
33
|
subTitle: 'Second step description.'
|
|
34
34
|
}, {
|
|
35
35
|
title: 'Step Three',
|
|
36
|
-
titleVariant: '
|
|
36
|
+
titleVariant: 'h3'
|
|
37
37
|
}]
|
|
38
38
|
}
|
|
39
39
|
};
|
|
@@ -41,7 +41,7 @@ export var Default = {
|
|
|
41
41
|
render: function render() {
|
|
42
42
|
var steps = [{
|
|
43
43
|
title: 'Choose Domain',
|
|
44
|
-
titleVariant: '
|
|
44
|
+
titleVariant: 'h3',
|
|
45
45
|
subTitle: 'You can bring a domain name you already own, or buy a new one.',
|
|
46
46
|
children: _jsxs(Box, {
|
|
47
47
|
children: [_jsx(Label, {
|
|
@@ -57,14 +57,14 @@ export var Default = {
|
|
|
57
57
|
})
|
|
58
58
|
}, {
|
|
59
59
|
title: 'Configure DNS',
|
|
60
|
-
titleVariant: '
|
|
60
|
+
titleVariant: 'h3',
|
|
61
61
|
summaryTitle: 'Summary of Configure DNS'
|
|
62
62
|
}, {
|
|
63
63
|
title: 'Configure Certificate',
|
|
64
|
-
titleVariant: '
|
|
64
|
+
titleVariant: 'h3'
|
|
65
65
|
}, {
|
|
66
66
|
title: 'Verify Domain',
|
|
67
|
-
titleVariant: '
|
|
67
|
+
titleVariant: 'h3'
|
|
68
68
|
}];
|
|
69
69
|
return _jsx(React.Fragment, {
|
|
70
70
|
children: _jsx(Box, {
|
|
@@ -90,7 +90,7 @@ export var WithTitleAutoFocus = {
|
|
|
90
90
|
setAutoFocus = _React$useState2[1];
|
|
91
91
|
var steps = [{
|
|
92
92
|
title: 'Choose Domain',
|
|
93
|
-
titleVariant: '
|
|
93
|
+
titleVariant: 'h3',
|
|
94
94
|
summary: [{
|
|
95
95
|
label: 'Demo Label',
|
|
96
96
|
value: 'Demo value'
|
|
@@ -115,7 +115,7 @@ export var WithTitleAutoFocus = {
|
|
|
115
115
|
})
|
|
116
116
|
}, {
|
|
117
117
|
title: 'Configure DNS',
|
|
118
|
-
titleVariant: '
|
|
118
|
+
titleVariant: 'h3',
|
|
119
119
|
onChange: function onChange() {
|
|
120
120
|
return setActiveStep(1);
|
|
121
121
|
},
|
|
@@ -137,7 +137,7 @@ export var WithTitleAutoFocus = {
|
|
|
137
137
|
})
|
|
138
138
|
}, {
|
|
139
139
|
title: 'Certificate',
|
|
140
|
-
titleVariant: '
|
|
140
|
+
titleVariant: 'h3',
|
|
141
141
|
summary: [{
|
|
142
142
|
label: 'Certificate status',
|
|
143
143
|
value: 'Not found'
|
|
@@ -202,7 +202,7 @@ export var HideStepText = {
|
|
|
202
202
|
setActiveStep = _React$useState3[1];
|
|
203
203
|
var steps = [{
|
|
204
204
|
title: 'Included Logs',
|
|
205
|
-
titleVariant: '
|
|
205
|
+
titleVariant: 'h3',
|
|
206
206
|
subTitle: '',
|
|
207
207
|
children: _jsx(Text, {
|
|
208
208
|
sx: {
|