carbon-react 104.23.1 → 104.24.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.
@@ -7,15 +7,12 @@ exports.StyledCounterWrapper = exports.StyledCounter = void 0;
7
7
 
8
8
  var _styledComponents = _interopRequireDefault(require("styled-components"));
9
9
 
10
- var _base = _interopRequireDefault(require("../../../../style/themes/base"));
11
-
12
10
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
13
11
 
14
12
  const StyledCounter = _styledComponents.default.span`
15
13
  color: ${({
16
- theme,
17
14
  hasError
18
- }) => hasError ? `${theme.colors.error};` : `${theme.editor.counter};`}
15
+ }) => hasError ? "var(--colorsSemanticNegative500)" : "var(--colorsUtilityYin055)"};
19
16
  width: 100%;
20
17
  `;
21
18
  exports.StyledCounter = StyledCounter;
@@ -29,7 +26,4 @@ const StyledCounterWrapper = _styledComponents.default.div`
29
26
  text-align: right;
30
27
  align-items: center;
31
28
  `;
32
- exports.StyledCounterWrapper = StyledCounterWrapper;
33
- StyledCounter.defaultProps = {
34
- theme: _base.default
35
- };
29
+ exports.StyledCounterWrapper = StyledCounterWrapper;
@@ -7,8 +7,6 @@ exports.default = void 0;
7
7
 
8
8
  var _styledComponents = _interopRequireWildcard(require("styled-components"));
9
9
 
10
- var _base = _interopRequireDefault(require("../../../../../style/themes/base"));
11
-
12
10
  var _icon = _interopRequireDefault(require("../../../../icon/icon.style"));
13
11
 
14
12
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
@@ -32,26 +30,22 @@ const StyledToolbarButton = _styledComponents.default.button.attrs({
32
30
  }
33
31
 
34
32
  ${({
35
- theme,
36
33
  isActive
37
34
  }) => (0, _styledComponents.css)`
38
35
  :focus,
39
36
  :active {
40
- outline: 2px solid ${theme.colors.focus};
37
+ outline: 2px solid var(--colorsSemanticFocus500);
41
38
  outline-offset: -2px;
42
39
  }
43
40
 
44
41
  :hover {
45
- background-color: ${theme.editor.button.hover};
42
+ background-color: var(--colorsActionMinor200);
46
43
  }
47
44
 
48
45
  ${isActive && (0, _styledComponents.css)`
49
- background-color: ${theme.editor.button.hover};
46
+ background-color: var(--colorsActionMinor200);
50
47
  `}
51
48
  `}
52
49
  `;
53
- StyledToolbarButton.defaultProps = {
54
- theme: _base.default
55
- };
56
50
  var _default = StyledToolbarButton;
57
51
  exports.default = _default;
@@ -9,8 +9,6 @@ var _styledComponents = _interopRequireDefault(require("styled-components"));
9
9
 
10
10
  var _button = _interopRequireDefault(require("../../../button/button.style"));
11
11
 
12
- var _base = _interopRequireDefault(require("../../../../style/themes/base"));
13
-
14
12
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
15
13
 
16
14
  const StyledToolbar = _styledComponents.default.div`
@@ -23,19 +21,12 @@ const StyledToolbar = _styledComponents.default.div`
23
21
  user-select: none;
24
22
  order: 2;
25
23
  border: none;
26
- ${({
27
- theme
28
- }) => `
29
- background-color: ${theme.editor.toolbar.background};
30
- border-top: 1px solid ${theme.editor.border};
31
- `}
24
+ border-top: 1px solid var(--colorsUtilityMajor200);
25
+ background-color: var(--colorsUtilityMajor025);
32
26
  min-width: 290px;
33
27
  z-index: 10;
34
28
  `;
35
29
  exports.StyledToolbar = StyledToolbar;
36
- StyledToolbar.defaultProps = {
37
- theme: _base.default
38
- };
39
30
  const StyledEditorStyleControls = _styledComponents.default.div`
40
31
  display: inline-block;
41
32
  text-align: left;
@@ -44,9 +35,6 @@ const StyledEditorStyleControls = _styledComponents.default.div`
44
35
  margin-left: -2px;
45
36
  `;
46
37
  exports.StyledEditorStyleControls = StyledEditorStyleControls;
47
- StyledEditorStyleControls.defaultProps = {
48
- theme: _base.default
49
- };
50
38
  const StyledEditorActionControls = _styledComponents.default.div`
51
39
  display: inline-block;
52
40
  text-align: right;
@@ -58,7 +46,4 @@ const StyledEditorActionControls = _styledComponents.default.div`
58
46
  min-height: 33px;
59
47
  }
60
48
  `;
61
- exports.StyledEditorActionControls = StyledEditorActionControls;
62
- StyledEditorActionControls.defaultProps = {
63
- theme: _base.default
64
- };
49
+ exports.StyledEditorActionControls = StyledEditorActionControls;
@@ -29,7 +29,6 @@ StyledEditorWrapper.defaultProps = {
29
29
  };
30
30
  const StyledEditorContainer = _styledComponents.default.div`
31
31
  ${({
32
- theme,
33
32
  hasError,
34
33
  rows,
35
34
  hasPreview
@@ -50,7 +49,7 @@ const StyledEditorContainer = _styledComponents.default.div`
50
49
  min-height: inherit;
51
50
  height: 100%;
52
51
  min-width: 290px;
53
- background-color: ${theme.colors.white};
52
+ background-color: var(--colorsUtilityYang100);
54
53
  line-height: ${lineHeight}px;
55
54
 
56
55
  ${!(0, _browserTypeCheck.isSafari)(navigator) && (0, _styledComponents.css)`
@@ -70,17 +69,13 @@ const StyledEditorContainer = _styledComponents.default.div`
70
69
  padding: 14px 8px;
71
70
  }
72
71
 
73
- background-color: ${theme.colors.white};
74
- outline: ${hasError ? `2px solid ${theme.colors.error};` : `1px solid ${theme.editor.border};`};
72
+ background-color: var(--colorsUtilityYang100);
73
+ outline: ${hasError ? "2px solid var(--colorsSemanticNegative500)" : "1px solid var(--colorsUtilityMajor200)"};
75
74
  `}
76
75
  `;
77
76
  exports.StyledEditorContainer = StyledEditorContainer;
78
- StyledEditorContainer.defaultProps = {
79
- theme: _base.default
80
- };
81
77
  const StyledEditorOutline = _styledComponents.default.div`
82
78
  ${({
83
- theme,
84
79
  isFocused,
85
80
  hasError
86
81
  }) => (0, _styledComponents.css)`
@@ -88,12 +83,9 @@ const StyledEditorOutline = _styledComponents.default.div`
88
83
  min-width: 320px;
89
84
 
90
85
  ${isFocused && (0, _styledComponents.css)`
91
- outline: 3px solid ${theme.colors.focus};
86
+ outline: 3px solid var(--colorsSemanticFocus500);
92
87
  outline-offset: ${hasError ? "2px;" : "1px;"};
93
88
  `}
94
89
  `}
95
90
  `;
96
- exports.StyledEditorOutline = StyledEditorOutline;
97
- StyledEditorOutline.defaultProps = {
98
- theme: _base.default
99
- };
91
+ exports.StyledEditorOutline = StyledEditorOutline;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "carbon-react",
3
- "version": "104.23.1",
3
+ "version": "104.24.0",
4
4
  "description": "A library of reusable React components for easily building user interfaces.",
5
5
  "engineStrict": true,
6
6
  "engines": {