@sproutsocial/racine 9.1.0-token-beta.0 → 9.1.1-theme-extension.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/CHANGELOG.md +0 -28
- package/__flow__/Breadcrumb/styles.js +5 -0
- package/__flow__/Button/styles.js +1 -1
- package/__flow__/Card/index.stories.js +1 -0
- package/__flow__/Card/styles.js +1 -1
- package/__flow__/CustomThemeProvider/index.js +16 -0
- package/__flow__/Drawer/index.stories.js +3 -3
- package/__flow__/Drawer/styles.js +1 -1
- package/__flow__/KeyboardKey/styles.js +1 -1
- package/__flow__/Menu/index.stories.js +1 -1
- package/__flow__/Modal/__snapshots__/index.test.js.snap +1 -1
- package/__flow__/Modal/styles.js +1 -1
- package/__flow__/Popout/index.js +1 -1
- package/__flow__/ThemeProvider/index.js +2 -2
- package/__flow__/Token/index.js +1 -4
- package/__flow__/Token/index.stories.js +0 -11
- package/__flow__/Token/styles.js +33 -43
- package/__flow__/Tooltip/index.js +1 -1
- package/__flow__/index.js +1 -0
- package/__flow__/themes/dark/theme.js +156 -180
- package/__flow__/themes/default/theme.js +8 -19
- package/__flow__/themes/sprout/theme.js +22 -0
- package/__flow__/types/system-props.flow.js +2 -1
- package/__flow__/utils/extendTheme.js +17 -0
- package/commonjs/Breadcrumb/styles.js +1 -1
- package/commonjs/Button/styles.js +1 -1
- package/commonjs/Card/styles.js +1 -1
- package/commonjs/CustomThemeProvider/index.js +23 -0
- package/commonjs/Drawer/styles.js +1 -1
- package/commonjs/KeyboardKey/styles.js +1 -1
- package/commonjs/Modal/styles.js +1 -1
- package/commonjs/Popout/index.js +1 -1
- package/commonjs/Token/index.js +2 -5
- package/commonjs/Token/styles.js +50 -19
- package/commonjs/Tooltip/index.js +1 -1
- package/commonjs/index.js +5 -1
- package/commonjs/themes/dark/theme.js +154 -179
- package/commonjs/themes/default/theme.js +8 -19
- package/commonjs/themes/sprout/theme.js +29 -0
- package/commonjs/utils/extendTheme.js +22 -0
- package/lib/Breadcrumb/styles.js +1 -1
- package/lib/Button/styles.js +1 -1
- package/lib/Card/styles.js +1 -1
- package/lib/CustomThemeProvider/index.js +12 -0
- package/lib/Drawer/styles.js +1 -1
- package/lib/KeyboardKey/styles.js +1 -1
- package/lib/Modal/styles.js +1 -1
- package/lib/Popout/index.js +1 -1
- package/lib/Token/index.js +2 -5
- package/lib/Token/styles.js +50 -19
- package/lib/Tooltip/index.js +1 -1
- package/lib/index.js +1 -0
- package/lib/themes/dark/theme.js +153 -174
- package/lib/themes/default/theme.js +8 -18
- package/lib/themes/sprout/theme.js +19 -0
- package/lib/utils/extendTheme.js +12 -0
- package/package.json +9 -6
- package/__flow__/themes/_themes.scss +0 -138
- package/__flow__/themes/utils/interact.js +0 -12
- package/commonjs/themes/utils/interact.js +0 -19
- package/dist/themes/_themes.scss +0 -138
- package/dist/themes/dark.scss +0 -601
- package/dist/themes/default.scss +0 -692
- package/lib/themes/utils/interact.js +0 -13
package/commonjs/Token/styles.js
CHANGED
|
@@ -16,25 +16,56 @@ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj &&
|
|
|
16
16
|
var Container = _styledComponents.default.button.withConfig({
|
|
17
17
|
displayName: "styles__Container",
|
|
18
18
|
componentId: "nyn5zy-0"
|
|
19
|
-
})(["position:relative;display:inline-block;margin:0;line-height:1;vertical-align:middle;outline:none;", "
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
19
|
+
})(["font-family:", ";", ";position:relative;display:inline-block;padding:", " ", ";margin:0;color:", ";background:", ";border:1px solid ", ";font-weight:", ";line-height:1;vertical-align:middle;border-radius:", ";outline:none;transition:all ", " ", ";&:focus{", "}", " ", " ", " ", ""], function (props) {
|
|
20
|
+
return props.theme.fontFamily;
|
|
21
|
+
}, function (props) {
|
|
22
|
+
return props.theme.typography[200];
|
|
23
|
+
}, function (props) {
|
|
24
|
+
return props.theme.space[200];
|
|
25
|
+
}, function (props) {
|
|
26
|
+
return props.theme.space[300];
|
|
27
|
+
}, function (props) {
|
|
28
|
+
return props.theme.colors.text.body;
|
|
29
|
+
}, function (props) {
|
|
30
|
+
return props.theme.colors.container.background.base;
|
|
31
|
+
}, function (props) {
|
|
32
|
+
return props.theme.colors.container.border.base;
|
|
33
|
+
}, function (props) {
|
|
34
|
+
return props.theme.fontWeights.normal;
|
|
35
|
+
}, function (props) {
|
|
36
|
+
return props.theme.radii[500];
|
|
37
|
+
}, function (props) {
|
|
38
|
+
return props.theme.duration.fast;
|
|
39
|
+
}, function (props) {
|
|
40
|
+
return props.theme.easing.ease_inout;
|
|
41
|
+
}, _mixins.focusRing, function (props) {
|
|
42
|
+
return props.closeable && (0, _styledComponents.css)(["cursor:pointer;&:hover,&:active{color:", ";border:1px solid ", ";background-color:", ";}"], function (props) {
|
|
43
|
+
return props.theme.colors.text.body;
|
|
44
|
+
}, function (props) {
|
|
45
|
+
return props.theme.colors.container.border.decorative.neutral;
|
|
46
|
+
}, function (props) {
|
|
47
|
+
return props.theme.colors.container.background.decorative.neutral;
|
|
48
|
+
});
|
|
49
|
+
}, function (props) {
|
|
50
|
+
return props.disabled && (0, _styledComponents.css)(["opacity:0.4;cursor:not-allowed;&:hover,&:active{background:", ";border:1px solid ", ";}"], function (props) {
|
|
51
|
+
return props.theme.colors.container.background.base;
|
|
52
|
+
}, function (props) {
|
|
53
|
+
return props.theme.colors.container.border.base;
|
|
54
|
+
});
|
|
55
|
+
}, function (props) {
|
|
56
|
+
return !props.valid && (0, _styledComponents.css)(["color:", ";border-color:", ";background:", ";&:hover{color:", ";border:1px solid ", ";background-color:", ";}"], function (props) {
|
|
57
|
+
return props.theme.colors.text.body;
|
|
58
|
+
}, function (props) {
|
|
59
|
+
return props.theme.colors.container.border.error;
|
|
60
|
+
}, function (props) {
|
|
61
|
+
return props.theme.colors.container.background.error;
|
|
62
|
+
}, function (props) {
|
|
63
|
+
return props.theme.colors.text.body;
|
|
64
|
+
}, function (props) {
|
|
65
|
+
return props.theme.colors.container.border.error;
|
|
66
|
+
}, function (props) {
|
|
67
|
+
return props.theme.colors.container.background.error;
|
|
68
|
+
});
|
|
38
69
|
}, _systemProps.COMMON);
|
|
39
70
|
|
|
40
71
|
var _default = Container;
|
|
@@ -132,7 +132,7 @@ var Content = function Content(_ref2) {
|
|
|
132
132
|
m: 200,
|
|
133
133
|
color: "text.body",
|
|
134
134
|
bg: "container.background.base",
|
|
135
|
-
boxShadow:
|
|
135
|
+
boxShadow: 300,
|
|
136
136
|
border: 500,
|
|
137
137
|
borderColor: "container.border.base" // $FlowIssue - upgrade v0.112.0
|
|
138
138
|
|
package/commonjs/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
exports.__esModule = true;
|
|
4
|
-
exports.VisuallyHidden = exports.DateRangePicker = exports.SingleDatePicker = exports.ListboxButton = exports.MenuItemContainer = exports.MenuButtonContext = exports.MenuButton = exports.toast = exports.OverflowList = exports.Listbox = exports.Menu = exports.ToastContainer = exports.Skeleton = exports.Breadcrumb = exports.Avatar = exports.Stack = exports.Message = exports.Fieldset = exports.FormField = exports.EmptyState = exports.SegmentedControl = exports.Collapsible = exports.Numeral = exports.LoaderButton = exports.Drawer = exports.Tooltip = exports.ThemeProvider = exports.Popout = exports.Modal = exports.Tabs = exports.TokenInput = exports.Token = exports.Switch = exports.Link = exports.Button = exports.Select = exports.Input = exports.Label = exports.Box = exports.TableRowAccordion = exports.TableHeaderCell = exports.TableCell = exports.Table = exports.ChartLegend = exports.KeyboardKey = exports.Image = exports.Text = exports.Loader = exports.ToggleHint = exports.Textarea = exports.Radio = exports.Checkbox = exports.CharacterCounter = exports.Card = exports.Indicator = exports.Badge = exports.Banner = exports.Alert = exports.Icon = exports.darkTheme = exports.theme = exports.useTextContent = exports.useMultiselect = exports.useSelect = exports.disabled = exports.focusRing = exports.visuallyHidden = void 0;
|
|
4
|
+
exports.VisuallyHidden = exports.DateRangePicker = exports.SingleDatePicker = exports.ListboxButton = exports.MenuItemContainer = exports.MenuButtonContext = exports.MenuButton = exports.toast = exports.OverflowList = exports.Listbox = exports.Menu = exports.ToastContainer = exports.Skeleton = exports.Breadcrumb = exports.Avatar = exports.Stack = exports.Message = exports.Fieldset = exports.FormField = exports.EmptyState = exports.SegmentedControl = exports.Collapsible = exports.Numeral = exports.LoaderButton = exports.Drawer = exports.Tooltip = exports.CustomThemeProvider = exports.ThemeProvider = exports.Popout = exports.Modal = exports.Tabs = exports.TokenInput = exports.Token = exports.Switch = exports.Link = exports.Button = exports.Select = exports.Input = exports.Label = exports.Box = exports.TableRowAccordion = exports.TableHeaderCell = exports.TableCell = exports.Table = exports.ChartLegend = exports.KeyboardKey = exports.Image = exports.Text = exports.Loader = exports.ToggleHint = exports.Textarea = exports.Radio = exports.Checkbox = exports.CharacterCounter = exports.Card = exports.Indicator = exports.Badge = exports.Banner = exports.Alert = exports.Icon = exports.darkTheme = exports.theme = exports.useTextContent = exports.useMultiselect = exports.useSelect = exports.disabled = exports.focusRing = exports.visuallyHidden = void 0;
|
|
5
5
|
|
|
6
6
|
var _mixins = require("./utils/mixins");
|
|
7
7
|
|
|
@@ -152,6 +152,10 @@ var _ThemeProvider = _interopRequireDefault(require("./ThemeProvider"));
|
|
|
152
152
|
|
|
153
153
|
exports.ThemeProvider = _ThemeProvider.default;
|
|
154
154
|
|
|
155
|
+
var _CustomThemeProvider = _interopRequireDefault(require("./CustomThemeProvider"));
|
|
156
|
+
|
|
157
|
+
exports.CustomThemeProvider = _CustomThemeProvider.default;
|
|
158
|
+
|
|
155
159
|
var _Tooltip = _interopRequireDefault(require("./Tooltip"));
|
|
156
160
|
|
|
157
161
|
exports.Tooltip = _Tooltip.default;
|
|
@@ -1,221 +1,196 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
exports.__esModule = true;
|
|
4
|
-
exports.default =
|
|
4
|
+
exports.default = void 0;
|
|
5
5
|
|
|
6
6
|
var _seedsColor = _interopRequireDefault(require("@sproutsocial/seeds-color"));
|
|
7
7
|
|
|
8
|
-
var _seedsDepth = _interopRequireDefault(require("@sproutsocial/seeds-depth"));
|
|
9
|
-
|
|
10
8
|
var _theme = _interopRequireDefault(require("../default/theme"));
|
|
11
9
|
|
|
12
10
|
var _datavizPalette = require("./dataviz-palette");
|
|
13
11
|
|
|
14
12
|
var _decorativePalettes = require("./decorative-palettes");
|
|
15
13
|
|
|
16
|
-
var _interact = _interopRequireDefault(require("../utils/interact"));
|
|
17
|
-
|
|
18
14
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
19
15
|
|
|
20
16
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
21
17
|
|
|
22
|
-
var
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
medium: _seedsDepth.default.ELEVATION_LEVEL_300 + " " + _seedsColor.default.COLOR_NEUTRAL_1100 + "FF",
|
|
26
|
-
high: _seedsDepth.default.ELEVATION_LEVEL_400 + " " + _seedsColor.default.COLOR_NEUTRAL_1100 + "FF"
|
|
27
|
-
};
|
|
28
|
-
exports.shadows = shadows;
|
|
29
|
-
|
|
30
|
-
var colors = _extends({}, _theme.default.colors, {
|
|
31
|
-
utils: {
|
|
32
|
-
interact: (0, _interact.default)(MODE)
|
|
33
|
-
},
|
|
34
|
-
app: {
|
|
35
|
-
background: {
|
|
36
|
-
base: _seedsColor.default.COLOR_NEUTRAL_1000
|
|
37
|
-
}
|
|
38
|
-
},
|
|
39
|
-
container: {
|
|
40
|
-
background: {
|
|
41
|
-
base: _seedsColor.default.COLOR_NEUTRAL_900,
|
|
42
|
-
success: _decorativePalettes.green.background,
|
|
43
|
-
warning: _decorativePalettes.yellow.background,
|
|
44
|
-
error: _decorativePalettes.red.background,
|
|
45
|
-
info: _decorativePalettes.blue.background,
|
|
46
|
-
opportunity: _decorativePalettes.purple.background,
|
|
47
|
-
danger: _decorativePalettes.red.background,
|
|
48
|
-
decorative: {
|
|
49
|
-
green: _decorativePalettes.green.background,
|
|
50
|
-
blue: _decorativePalettes.blue.background,
|
|
51
|
-
purple: _decorativePalettes.purple.background,
|
|
52
|
-
yellow: _decorativePalettes.yellow.background,
|
|
53
|
-
orange: _decorativePalettes.orange.background,
|
|
54
|
-
red: _decorativePalettes.red.background,
|
|
55
|
-
neutral: _decorativePalettes.neutral.background
|
|
56
|
-
},
|
|
57
|
-
selected: _seedsColor.default.COLOR_NEUTRAL_0
|
|
58
|
-
},
|
|
59
|
-
border: {
|
|
60
|
-
base: _seedsColor.default.COLOR_NEUTRAL_1100,
|
|
61
|
-
success: _decorativePalettes.green.highlight,
|
|
62
|
-
warning: _decorativePalettes.yellow.highlight,
|
|
63
|
-
error: _decorativePalettes.red.highlight,
|
|
64
|
-
danger: _decorativePalettes.red.highlight,
|
|
65
|
-
info: _decorativePalettes.blue.highlight,
|
|
66
|
-
opportunity: _decorativePalettes.purple.highlight,
|
|
67
|
-
decorative: {
|
|
68
|
-
green: _decorativePalettes.green.highlight,
|
|
69
|
-
blue: _decorativePalettes.blue.highlight,
|
|
70
|
-
purple: _decorativePalettes.purple.highlight,
|
|
71
|
-
yellow: _decorativePalettes.yellow.highlight,
|
|
72
|
-
orange: _decorativePalettes.orange.highlight,
|
|
73
|
-
red: _decorativePalettes.red.highlight,
|
|
74
|
-
neutral: _decorativePalettes.neutral.highlight
|
|
75
|
-
},
|
|
76
|
-
selected: _seedsColor.default.COLOR_NEUTRAL_0
|
|
77
|
-
}
|
|
78
|
-
},
|
|
79
|
-
button: {
|
|
80
|
-
primary: {
|
|
18
|
+
var darkTheme = _extends({}, _theme.default, {
|
|
19
|
+
colors: _extends({}, _theme.default.colors, {
|
|
20
|
+
app: {
|
|
81
21
|
background: {
|
|
82
|
-
base: _seedsColor.default.
|
|
83
|
-
hover: _seedsColor.default.COLOR_BLUE_300,
|
|
84
|
-
active: _seedsColor.default.COLOR_BLUE_200
|
|
85
|
-
},
|
|
86
|
-
border: {
|
|
87
|
-
base: "transparent"
|
|
88
|
-
},
|
|
89
|
-
text: {
|
|
90
|
-
base: _seedsColor.default.COLOR_NEUTRAL_900,
|
|
91
|
-
hover: _seedsColor.default.COLOR_NEUTRAL_1000
|
|
22
|
+
base: _seedsColor.default.COLOR_NEUTRAL_1000
|
|
92
23
|
}
|
|
93
24
|
},
|
|
94
|
-
|
|
25
|
+
container: {
|
|
95
26
|
background: {
|
|
96
|
-
base:
|
|
97
|
-
|
|
98
|
-
|
|
27
|
+
base: _seedsColor.default.COLOR_NEUTRAL_900,
|
|
28
|
+
success: _decorativePalettes.green.background,
|
|
29
|
+
warning: _decorativePalettes.yellow.background,
|
|
30
|
+
error: _decorativePalettes.red.background,
|
|
31
|
+
info: _decorativePalettes.blue.background,
|
|
32
|
+
opportunity: _decorativePalettes.purple.background,
|
|
33
|
+
danger: _decorativePalettes.red.background,
|
|
34
|
+
decorative: {
|
|
35
|
+
green: _decorativePalettes.green.background,
|
|
36
|
+
blue: _decorativePalettes.blue.background,
|
|
37
|
+
purple: _decorativePalettes.purple.background,
|
|
38
|
+
yellow: _decorativePalettes.yellow.background,
|
|
39
|
+
orange: _decorativePalettes.orange.background,
|
|
40
|
+
red: _decorativePalettes.red.background,
|
|
41
|
+
neutral: _decorativePalettes.neutral.background
|
|
42
|
+
},
|
|
43
|
+
selected: _seedsColor.default.COLOR_NEUTRAL_0
|
|
99
44
|
},
|
|
100
45
|
border: {
|
|
101
|
-
base: _seedsColor.default.
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
46
|
+
base: _seedsColor.default.COLOR_NEUTRAL_1100,
|
|
47
|
+
success: _decorativePalettes.green.highlight,
|
|
48
|
+
warning: _decorativePalettes.yellow.highlight,
|
|
49
|
+
error: _decorativePalettes.red.highlight,
|
|
50
|
+
danger: _decorativePalettes.red.highlight,
|
|
51
|
+
info: _decorativePalettes.blue.highlight,
|
|
52
|
+
opportunity: _decorativePalettes.purple.highlight,
|
|
53
|
+
decorative: {
|
|
54
|
+
green: _decorativePalettes.green.highlight,
|
|
55
|
+
blue: _decorativePalettes.blue.highlight,
|
|
56
|
+
purple: _decorativePalettes.purple.highlight,
|
|
57
|
+
yellow: _decorativePalettes.yellow.highlight,
|
|
58
|
+
orange: _decorativePalettes.orange.highlight,
|
|
59
|
+
red: _decorativePalettes.red.highlight,
|
|
60
|
+
neutral: _decorativePalettes.neutral.highlight
|
|
61
|
+
},
|
|
62
|
+
selected: _seedsColor.default.COLOR_NEUTRAL_0
|
|
106
63
|
}
|
|
107
64
|
},
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
65
|
+
button: {
|
|
66
|
+
primary: {
|
|
67
|
+
background: {
|
|
68
|
+
base: _seedsColor.default.COLOR_BLUE_400,
|
|
69
|
+
hover: _seedsColor.default.COLOR_BLUE_300,
|
|
70
|
+
active: _seedsColor.default.COLOR_BLUE_200
|
|
71
|
+
},
|
|
72
|
+
border: {
|
|
73
|
+
base: "transparent"
|
|
74
|
+
},
|
|
75
|
+
text: {
|
|
76
|
+
base: _seedsColor.default.COLOR_NEUTRAL_900,
|
|
77
|
+
hover: _seedsColor.default.COLOR_NEUTRAL_1000
|
|
78
|
+
}
|
|
113
79
|
},
|
|
114
|
-
|
|
115
|
-
|
|
80
|
+
secondary: {
|
|
81
|
+
background: {
|
|
82
|
+
base: "transparent",
|
|
83
|
+
hover: _seedsColor.default.COLOR_NEUTRAL_100,
|
|
84
|
+
active: _seedsColor.default.COLOR_NEUTRAL_0
|
|
85
|
+
},
|
|
86
|
+
border: {
|
|
87
|
+
base: _seedsColor.default.COLOR_NEUTRAL_0
|
|
88
|
+
},
|
|
89
|
+
text: {
|
|
90
|
+
base: _seedsColor.default.COLOR_NEUTRAL_0,
|
|
91
|
+
hover: _seedsColor.default.COLOR_NEUTRAL_800
|
|
92
|
+
}
|
|
116
93
|
},
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
94
|
+
pill: {
|
|
95
|
+
background: {
|
|
96
|
+
base: "transparent",
|
|
97
|
+
hover: _seedsColor.default.COLOR_NEUTRAL_1000,
|
|
98
|
+
active: _seedsColor.default.COLOR_NEUTRAL_900
|
|
99
|
+
},
|
|
100
|
+
border: {
|
|
101
|
+
base: "transparent"
|
|
102
|
+
},
|
|
103
|
+
text: {
|
|
104
|
+
base: _seedsColor.default.COLOR_NEUTRAL_100,
|
|
105
|
+
hover: _seedsColor.default.COLOR_NEUTRAL_0
|
|
106
|
+
}
|
|
127
107
|
},
|
|
128
|
-
|
|
129
|
-
|
|
108
|
+
destructive: {
|
|
109
|
+
background: {
|
|
110
|
+
base: _seedsColor.default.COLOR_RED_400,
|
|
111
|
+
hover: _seedsColor.default.COLOR_RED_300,
|
|
112
|
+
active: _seedsColor.default.COLOR_RED_200
|
|
113
|
+
},
|
|
114
|
+
border: {
|
|
115
|
+
base: "transparent"
|
|
116
|
+
},
|
|
117
|
+
text: {
|
|
118
|
+
base: _seedsColor.default.COLOR_NEUTRAL_900,
|
|
119
|
+
hover: _seedsColor.default.COLOR_NEUTRAL_1000
|
|
120
|
+
}
|
|
130
121
|
},
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
122
|
+
placeholder: {
|
|
123
|
+
background: {
|
|
124
|
+
base: "transparent",
|
|
125
|
+
hover: _seedsColor.default.COLOR_NEUTRAL_1100,
|
|
126
|
+
active: _seedsColor.default.COLOR_NEUTRAL_1100
|
|
127
|
+
},
|
|
128
|
+
border: {
|
|
129
|
+
base: _seedsColor.default.COLOR_NEUTRAL_500
|
|
130
|
+
},
|
|
131
|
+
text: {
|
|
132
|
+
base: _seedsColor.default.COLOR_BLUE_400,
|
|
133
|
+
hover: _seedsColor.default.COLOR_BLUE_300
|
|
134
|
+
}
|
|
135
|
+
},
|
|
136
|
+
unstyled: {
|
|
137
|
+
background: {
|
|
138
|
+
base: "transparent"
|
|
139
|
+
},
|
|
140
|
+
border: {
|
|
141
|
+
base: "transparent"
|
|
142
|
+
},
|
|
143
|
+
text: {
|
|
144
|
+
base: _seedsColor.default.COLOR_NEUTRAL_300,
|
|
145
|
+
hover: _seedsColor.default.COLOR_NEUTRAL_200
|
|
146
|
+
}
|
|
134
147
|
}
|
|
135
148
|
},
|
|
136
|
-
|
|
149
|
+
link: {
|
|
150
|
+
base: _seedsColor.default.COLOR_BLUE_400,
|
|
151
|
+
hover: _seedsColor.default.COLOR_BLUE_300
|
|
152
|
+
},
|
|
153
|
+
text: {
|
|
154
|
+
headline: _seedsColor.default.COLOR_NEUTRAL_0,
|
|
155
|
+
subtext: _seedsColor.default.COLOR_NEUTRAL_300,
|
|
156
|
+
body: _seedsColor.default.COLOR_NEUTRAL_100,
|
|
157
|
+
inverse: _seedsColor.default.COLOR_NEUTRAL_900,
|
|
158
|
+
error: _seedsColor.default.COLOR_RED_400
|
|
159
|
+
},
|
|
160
|
+
icon: {
|
|
161
|
+
base: _seedsColor.default.COLOR_NEUTRAL_100,
|
|
162
|
+
inverse: _seedsColor.default.COLOR_NEUTRAL_900,
|
|
163
|
+
success: _decorativePalettes.green.foreground,
|
|
164
|
+
warning: _decorativePalettes.yellow.foreground,
|
|
165
|
+
error: _decorativePalettes.red.foreground,
|
|
166
|
+
danger: _decorativePalettes.red.foreground,
|
|
167
|
+
info: _decorativePalettes.blue.foreground,
|
|
168
|
+
opportunity: _decorativePalettes.purple.foreground
|
|
169
|
+
},
|
|
170
|
+
form: {
|
|
137
171
|
background: {
|
|
138
|
-
base:
|
|
139
|
-
|
|
140
|
-
active: _seedsColor.default.COLOR_NEUTRAL_1100
|
|
172
|
+
base: _seedsColor.default.COLOR_NEUTRAL_900,
|
|
173
|
+
selected: _seedsColor.default.COLOR_NEUTRAL_0
|
|
141
174
|
},
|
|
142
175
|
border: {
|
|
143
|
-
base: _seedsColor.default.COLOR_NEUTRAL_500
|
|
176
|
+
base: _seedsColor.default.COLOR_NEUTRAL_500,
|
|
177
|
+
error: _decorativePalettes.red.highlight,
|
|
178
|
+
warning: _decorativePalettes.yellow.highlight,
|
|
179
|
+
selected: _seedsColor.default.COLOR_NEUTRAL_0
|
|
144
180
|
},
|
|
145
|
-
|
|
146
|
-
base: _seedsColor.default.
|
|
147
|
-
hover: _seedsColor.default.COLOR_BLUE_300
|
|
181
|
+
placeholder: {
|
|
182
|
+
base: _seedsColor.default.COLOR_NEUTRAL_500
|
|
148
183
|
}
|
|
149
184
|
},
|
|
150
|
-
|
|
185
|
+
listItem: {
|
|
151
186
|
background: {
|
|
152
|
-
base: "transparent"
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
base: "transparent"
|
|
156
|
-
},
|
|
157
|
-
text: {
|
|
158
|
-
base: _seedsColor.default.COLOR_NEUTRAL_300,
|
|
159
|
-
hover: _seedsColor.default.COLOR_NEUTRAL_200
|
|
187
|
+
base: "transparent",
|
|
188
|
+
hover: _seedsColor.default.COLOR_NEUTRAL_800,
|
|
189
|
+
selected: _seedsColor.default.COLOR_NEUTRAL_0
|
|
160
190
|
}
|
|
161
191
|
}
|
|
162
|
-
},
|
|
163
|
-
|
|
164
|
-
base: _seedsColor.default.COLOR_BLUE_400,
|
|
165
|
-
hover: _seedsColor.default.COLOR_BLUE_300
|
|
166
|
-
},
|
|
167
|
-
text: {
|
|
168
|
-
headline: _seedsColor.default.COLOR_NEUTRAL_0,
|
|
169
|
-
subtext: _seedsColor.default.COLOR_NEUTRAL_300,
|
|
170
|
-
body: _seedsColor.default.COLOR_NEUTRAL_100,
|
|
171
|
-
inverse: _seedsColor.default.COLOR_NEUTRAL_900,
|
|
172
|
-
error: _seedsColor.default.COLOR_RED_400
|
|
173
|
-
},
|
|
174
|
-
icon: {
|
|
175
|
-
base: _seedsColor.default.COLOR_NEUTRAL_100,
|
|
176
|
-
inverse: _seedsColor.default.COLOR_NEUTRAL_900,
|
|
177
|
-
success: _decorativePalettes.green.foreground,
|
|
178
|
-
warning: _decorativePalettes.yellow.foreground,
|
|
179
|
-
error: _decorativePalettes.red.foreground,
|
|
180
|
-
danger: _decorativePalettes.red.foreground,
|
|
181
|
-
info: _decorativePalettes.blue.foreground,
|
|
182
|
-
opportunity: _decorativePalettes.purple.foreground
|
|
183
|
-
},
|
|
184
|
-
form: {
|
|
185
|
-
background: {
|
|
186
|
-
base: _seedsColor.default.COLOR_NEUTRAL_900,
|
|
187
|
-
selected: _seedsColor.default.COLOR_NEUTRAL_0
|
|
188
|
-
},
|
|
189
|
-
border: {
|
|
190
|
-
base: _seedsColor.default.COLOR_NEUTRAL_500,
|
|
191
|
-
error: _decorativePalettes.red.highlight,
|
|
192
|
-
warning: _decorativePalettes.yellow.highlight,
|
|
193
|
-
selected: _seedsColor.default.COLOR_NEUTRAL_0
|
|
194
|
-
},
|
|
195
|
-
placeholder: {
|
|
196
|
-
base: _seedsColor.default.COLOR_NEUTRAL_500
|
|
197
|
-
}
|
|
198
|
-
},
|
|
199
|
-
listItem: {
|
|
200
|
-
background: {
|
|
201
|
-
base: "transparent",
|
|
202
|
-
hover: _seedsColor.default.COLOR_NEUTRAL_800,
|
|
203
|
-
selected: _seedsColor.default.COLOR_NEUTRAL_0
|
|
204
|
-
}
|
|
205
|
-
},
|
|
206
|
-
elevation: {
|
|
207
|
-
base: _seedsColor.default.COLOR_NEUTRAL_1100
|
|
208
|
-
},
|
|
209
|
-
dataviz: {
|
|
210
|
-
map: _datavizPalette.datavizPalette.DATAVIZ_COLORS_MAP,
|
|
211
|
-
list: _datavizPalette.datavizPalette.DATAVIZ_COLORS_LIST
|
|
212
|
-
}
|
|
213
|
-
}, _datavizPalette.datavizPalette);
|
|
214
|
-
|
|
215
|
-
var darkTheme = _extends({}, _theme.default, {
|
|
216
|
-
colors: colors,
|
|
217
|
-
shadows: shadows,
|
|
218
|
-
mode: MODE
|
|
192
|
+
}, _datavizPalette.datavizPalette),
|
|
193
|
+
mode: "dark"
|
|
219
194
|
});
|
|
220
195
|
|
|
221
196
|
var _default = darkTheme;
|
|
@@ -23,15 +23,12 @@ var _seedsMotion = _interopRequireDefault(require("@sproutsocial/seeds-motion"))
|
|
|
23
23
|
|
|
24
24
|
var _seedsBorder = _interopRequireDefault(require("@sproutsocial/seeds-border"));
|
|
25
25
|
|
|
26
|
-
var _interact = _interopRequireDefault(require("../utils/interact"));
|
|
27
|
-
|
|
28
26
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
29
27
|
|
|
30
28
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
31
29
|
|
|
32
30
|
var breakpoints = ["900px", "1200px", "1500px", "1800px"];
|
|
33
31
|
exports.breakpoints = breakpoints;
|
|
34
|
-
var MODE = "default-light";
|
|
35
32
|
|
|
36
33
|
var colors = _extends({
|
|
37
34
|
app: {
|
|
@@ -206,9 +203,6 @@ var colors = _extends({
|
|
|
206
203
|
selected: _seedsColor.default.COLOR_NEUTRAL_800
|
|
207
204
|
}
|
|
208
205
|
},
|
|
209
|
-
elevation: {
|
|
210
|
-
base: _seedsColor.default.COLOR_NEUTRAL_900 + "3D"
|
|
211
|
-
},
|
|
212
206
|
network: {
|
|
213
207
|
twitter: _seedsNetworkcolor.default.NETWORK_COLOR_TWITTER,
|
|
214
208
|
twitter_like: _seedsNetworkcolor.default.NETWORK_COLOR_TWITTER_LIKE,
|
|
@@ -235,10 +229,6 @@ var colors = _extends({
|
|
|
235
229
|
yelp: _seedsNetworkcolor.default.NETWORK_COLOR_YELP,
|
|
236
230
|
whatsapp: _seedsNetworkcolor.default.NETWORK_COLOR_WHATSAPP,
|
|
237
231
|
tiktok: _seedsNetworkcolor.default.NETWORK_COLOR_TIKTOK
|
|
238
|
-
},
|
|
239
|
-
dataviz: {
|
|
240
|
-
map: _datavizPalette.datavizPalette.DATAVIZ_COLORS_MAP,
|
|
241
|
-
list: _datavizPalette.datavizPalette.DATAVIZ_COLORS_LIST
|
|
242
232
|
}
|
|
243
233
|
}, _literalColors.default, _datavizPalette.datavizPalette);
|
|
244
234
|
|
|
@@ -297,9 +287,10 @@ var borderWidths = {
|
|
|
297
287
|
};
|
|
298
288
|
exports.borderWidths = borderWidths;
|
|
299
289
|
var shadows = {
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
290
|
+
"100": _seedsDepth.default.ELEVATION_LEVEL_100,
|
|
291
|
+
"200": _seedsDepth.default.ELEVATION_LEVEL_200,
|
|
292
|
+
"300": _seedsDepth.default.ELEVATION_LEVEL_300,
|
|
293
|
+
"400": _seedsDepth.default.ELEVATION_LEVEL_400
|
|
303
294
|
};
|
|
304
295
|
exports.shadows = shadows;
|
|
305
296
|
var easing = {
|
|
@@ -315,9 +306,6 @@ var duration = {
|
|
|
315
306
|
};
|
|
316
307
|
exports.duration = duration;
|
|
317
308
|
var theme = {
|
|
318
|
-
utils: {
|
|
319
|
-
interact: (0, _interact.default)(MODE)
|
|
320
|
-
},
|
|
321
309
|
breakpoints: breakpoints,
|
|
322
310
|
colors: colors,
|
|
323
311
|
typography: _extends({}, typography, {
|
|
@@ -338,10 +326,11 @@ var theme = {
|
|
|
338
326
|
}),
|
|
339
327
|
borders: borders,
|
|
340
328
|
borderWidths: borderWidths,
|
|
341
|
-
shadows: shadows,
|
|
329
|
+
shadows: _extends({}, shadows, {
|
|
330
|
+
shadows: shadows
|
|
331
|
+
}),
|
|
342
332
|
easing: easing,
|
|
343
|
-
duration: duration
|
|
344
|
-
mode: MODE
|
|
333
|
+
duration: duration
|
|
345
334
|
};
|
|
346
335
|
var _default = theme;
|
|
347
336
|
exports.default = _default;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
exports.__esModule = true;
|
|
4
|
+
exports.default = void 0;
|
|
5
|
+
|
|
6
|
+
var _theme = _interopRequireDefault(require("../default/theme"));
|
|
7
|
+
|
|
8
|
+
var _seedsColor = require("@sproutsocial/seeds-color");
|
|
9
|
+
|
|
10
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
11
|
+
|
|
12
|
+
var sproutTheme = {
|
|
13
|
+
container: {
|
|
14
|
+
background: {
|
|
15
|
+
error: {
|
|
16
|
+
hover: _seedsColor.COLOR_RED_800
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
button: {
|
|
21
|
+
primary: {
|
|
22
|
+
background: {
|
|
23
|
+
base: "purple"
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
};
|
|
28
|
+
var _default = sproutTheme;
|
|
29
|
+
exports.default = _default;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
exports.__esModule = true;
|
|
4
|
+
exports.extendColorTheme = extendColorTheme;
|
|
5
|
+
|
|
6
|
+
var merge = _interopRequireWildcard(require("deepmerge"));
|
|
7
|
+
|
|
8
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
9
|
+
|
|
10
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
11
|
+
|
|
12
|
+
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
13
|
+
|
|
14
|
+
function extendColorTheme(baseTheme, extension) {
|
|
15
|
+
var newColorTheme = merge(baseTheme.colors, extension);
|
|
16
|
+
|
|
17
|
+
var newTheme = _extends({}, baseTheme, {
|
|
18
|
+
colors: _extends({}, newColorTheme)
|
|
19
|
+
});
|
|
20
|
+
|
|
21
|
+
return newTheme;
|
|
22
|
+
}
|
package/lib/Breadcrumb/styles.js
CHANGED
|
@@ -2,7 +2,7 @@ import styled from "styled-components";
|
|
|
2
2
|
var Nav = styled.nav.withConfig({
|
|
3
3
|
displayName: "styles__Nav",
|
|
4
4
|
componentId: "sc-1ub1apc-0"
|
|
5
|
-
})(["ol{", ";margin:0;font-family:", ";padding:0;display:flex;}li{margin-right:", ";display:flex;}a,button{", ";max-width:200px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;&:not(.overflow--menu){margin:0;padding:0;}}ol > div + li::before{content:\"/\";margin-right:", ";}li:last-child a,li:last-child button{color:", ";font-weight:bold;}li:not(:last-child)::after{content:\"/\";color:", ";margin-left:", ";}"], function (props) {
|
|
5
|
+
})(["ol{", ";margin:0;font-family:", ";padding:0;display:flex;}li{margin-right:", ";display:flex;}a,button{", ";max-width:200px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;&:not(.overflow--menu){margin:0;padding:0;}}ol > div + li::before{content:\"/\";margin-right:", ";}li:last-child a,li:last-child button{color:", ";font-weight:bold;}li:not(:last-child) a,li:not(:last-child) button{font-weight:normal;}li:not(:last-child)::after{content:\"/\";color:", ";margin-left:", ";}"], function (props) {
|
|
6
6
|
return props.theme.typography[200];
|
|
7
7
|
}, function (props) {
|
|
8
8
|
return props.theme.fontFamily;
|
package/lib/Button/styles.js
CHANGED
|
@@ -32,7 +32,7 @@ var Container = styled.button.withConfig({
|
|
|
32
32
|
}, function (props) {
|
|
33
33
|
return props.theme.colors.button[props.appearance].background.hover;
|
|
34
34
|
}, function (props) {
|
|
35
|
-
return props.appearance === "placeholder" ? props.theme.shadows
|
|
35
|
+
return props.appearance === "placeholder" ? props.theme.shadows[100] : "none";
|
|
36
36
|
}, function (props) {
|
|
37
37
|
return props.theme.colors.button[props.appearance].text.hover;
|
|
38
38
|
}, function (props) {
|
package/lib/Card/styles.js
CHANGED
|
@@ -9,7 +9,7 @@ var Container = styled(Box).withConfig({
|
|
|
9
9
|
}, function (props) {
|
|
10
10
|
return props.theme.radii[500];
|
|
11
11
|
}, function (props) {
|
|
12
|
-
return props.theme.shadows
|
|
12
|
+
return props.theme.shadows[100];
|
|
13
13
|
}, function (props) {
|
|
14
14
|
return props.theme.duration.medium;
|
|
15
15
|
}, function (props) {
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
2
|
+
|
|
3
|
+
import * as React from "react";
|
|
4
|
+
import { ThemeProvider } from "styled-components";
|
|
5
|
+
|
|
6
|
+
var CustomThemeProvider = function CustomThemeProvider(props) {
|
|
7
|
+
return /*#__PURE__*/React.createElement(ThemeProvider, _extends({
|
|
8
|
+
theme: props.theme
|
|
9
|
+
}, props));
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
export default CustomThemeProvider;
|