@sproutsocial/racine 20.7.0 → 20.9.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 +17 -0
- package/__flow__/Drawer/Drawer.flow.js +1 -0
- package/__flow__/LogoViewBoxes.js +4 -4
- package/commonjs/Drawer/Drawer.js +13 -7
- package/commonjs/LogoViewBoxes.js +4 -4
- package/dist/logo.svg +1 -1
- package/dist/themes/dark/theme.scss +36 -36
- package/dist/themes/extendedThemes/sproutTheme/dark/theme.scss +42 -42
- package/dist/themes/extendedThemes/sproutTheme/light/theme.scss +44 -44
- package/dist/themes/light/theme.scss +36 -36
- package/dist/types/Drawer/Drawer.d.ts +1 -1
- package/dist/types/Drawer/Drawer.d.ts.map +1 -1
- package/dist/types/Drawer/DrawerTypes.d.ts +2 -0
- package/dist/types/Drawer/DrawerTypes.d.ts.map +1 -1
- package/lib/Drawer/Drawer.js +13 -7
- package/lib/LogoViewBoxes.js +4 -4
- package/package.json +3 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,22 @@
|
|
|
1
1
|
# Change Log
|
|
2
2
|
|
|
3
|
+
## 20.9.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 2e135c53a: Add prop to Drawer to allow certain elements to be exempt from the Drawer focus lock
|
|
8
|
+
|
|
9
|
+
This is helpful when Pendo Guide are activated while a drawer is open.
|
|
10
|
+
|
|
11
|
+
- 60ba119e2: The width of Drawer can now be customized using the `width` prop.
|
|
12
|
+
|
|
13
|
+
## 20.8.0
|
|
14
|
+
|
|
15
|
+
### Minor Changes
|
|
16
|
+
|
|
17
|
+
- ba43d9369: Updates the seeds-color dependency which includes the new blue
|
|
18
|
+
- d77544cb6: Update sproutsocial PartnerLogo to latest look
|
|
19
|
+
|
|
3
20
|
## 20.7.0
|
|
4
21
|
|
|
5
22
|
### Minor Changes
|
|
@@ -73,12 +73,12 @@ module.exports = {
|
|
|
73
73
|
"shopify": "0 0 140 159",
|
|
74
74
|
"slack-dark": "0 0 140 140",
|
|
75
75
|
"slack": "0 0 140 140",
|
|
76
|
-
"sproutsocial-dark": "0 0
|
|
77
|
-
"sproutsocial-lockup-dark": "0 0 291
|
|
78
|
-
"sproutsocial-lockup": "0 0 291
|
|
76
|
+
"sproutsocial-dark": "0 0 16 18",
|
|
77
|
+
"sproutsocial-lockup-dark": "0 0 291 59",
|
|
78
|
+
"sproutsocial-lockup": "0 0 291 59",
|
|
79
79
|
"sproutsocial-wordmark-dark": "0 0 320 52",
|
|
80
80
|
"sproutsocial-wordmark": "0 0 320 52",
|
|
81
|
-
"sproutsocial": "0 0
|
|
81
|
+
"sproutsocial": "0 0 16 18",
|
|
82
82
|
"tableau-dark": "0 0 18 18",
|
|
83
83
|
"tableau-lockup-dark": "0 0 291 56",
|
|
84
84
|
"tableau-lockup": "0 0 291 56",
|
|
@@ -17,8 +17,8 @@ var _SlideTransition = require("./SlideTransition");
|
|
|
17
17
|
var _styles = _interopRequireWildcard(require("./styles"));
|
|
18
18
|
var _excluded = ["title", "id", "children", "render"],
|
|
19
19
|
_excluded2 = ["children"],
|
|
20
|
-
_excluded3 = ["id", "style", "offset", "direction", "children", "disableCloseOnClickOutside", "onClose", "zIndex", "closeTargets"],
|
|
21
|
-
_excluded4 = ["children", "closeButtonLabel", "direction", "disableCloseOnClickOutside", "id", "isOpen", "offset", "onClose", "zIndex", "closeTargets"];
|
|
20
|
+
_excluded3 = ["id", "style", "offset", "direction", "children", "disableCloseOnClickOutside", "onClose", "zIndex", "closeTargets", "width", "focusLockExemptCheck"],
|
|
21
|
+
_excluded4 = ["children", "closeButtonLabel", "direction", "disableCloseOnClickOutside", "id", "isOpen", "offset", "onClose", "zIndex", "closeTargets", "width"];
|
|
22
22
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
23
23
|
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); }
|
|
24
24
|
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; }
|
|
@@ -30,8 +30,6 @@ function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input ==
|
|
|
30
30
|
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
31
31
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
32
32
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); } // eslint-disable-next-line import/no-deprecated
|
|
33
|
-
// If ever we needed to make drawer width configurable, move this to a default prop
|
|
34
|
-
var DRAWER_WIDTH = 600;
|
|
35
33
|
var AnimatedDrawer = (0, _reactSpring.animated)(_styles.default);
|
|
36
34
|
var doesRefContainEventTarget = function doesRefContainEventTarget(ref, event) {
|
|
37
35
|
return ref.current && event.target instanceof Node && ref.current.contains(event.target);
|
|
@@ -103,6 +101,8 @@ var Drawer = function Drawer(_ref3) {
|
|
|
103
101
|
onClose = _ref3.onClose,
|
|
104
102
|
zIndex = _ref3.zIndex,
|
|
105
103
|
closeTargets = _ref3.closeTargets,
|
|
104
|
+
width = _ref3.width,
|
|
105
|
+
focusLockExemptCheck = _ref3.focusLockExemptCheck,
|
|
106
106
|
rest = _objectWithoutProperties(_ref3, _excluded3);
|
|
107
107
|
var drawerRef = (0, React.useRef)(null);
|
|
108
108
|
(0, React.useEffect)(function () {
|
|
@@ -141,11 +141,14 @@ var Drawer = function Drawer(_ref3) {
|
|
|
141
141
|
return /*#__PURE__*/React.createElement(_reactFocusLock.default, {
|
|
142
142
|
key: id,
|
|
143
143
|
autoFocus: true,
|
|
144
|
-
returnFocus: true
|
|
144
|
+
returnFocus: true,
|
|
145
|
+
whiteList: focusLockExemptCheck ? function (e) {
|
|
146
|
+
return !focusLockExemptCheck(e);
|
|
147
|
+
} : undefined
|
|
145
148
|
}, /*#__PURE__*/React.createElement(AnimatedDrawer, _extends({
|
|
146
149
|
ref: drawerRef,
|
|
147
150
|
style: style,
|
|
148
|
-
width:
|
|
151
|
+
width: width,
|
|
149
152
|
offset: offset,
|
|
150
153
|
direction: direction,
|
|
151
154
|
"data-qa-drawer": id,
|
|
@@ -168,6 +171,8 @@ var DrawerContainer = function DrawerContainer(_ref4) {
|
|
|
168
171
|
zIndex = _ref4$zIndex === void 0 ? 7 : _ref4$zIndex,
|
|
169
172
|
_ref4$closeTargets = _ref4.closeTargets,
|
|
170
173
|
closeTargets = _ref4$closeTargets === void 0 ? [] : _ref4$closeTargets,
|
|
174
|
+
_ref4$width = _ref4.width,
|
|
175
|
+
width = _ref4$width === void 0 ? 600 : _ref4$width,
|
|
171
176
|
rest = _objectWithoutProperties(_ref4, _excluded4);
|
|
172
177
|
return /*#__PURE__*/React.createElement(_Portal.default, {
|
|
173
178
|
id: id
|
|
@@ -177,7 +182,7 @@ var DrawerContainer = function DrawerContainer(_ref4) {
|
|
|
177
182
|
closeButtonLabel: closeButtonLabel
|
|
178
183
|
}
|
|
179
184
|
}, /*#__PURE__*/React.createElement(_SlideTransition.SlideTransition, {
|
|
180
|
-
width:
|
|
185
|
+
width: width + offset,
|
|
181
186
|
direction: direction,
|
|
182
187
|
isVisible: isOpen
|
|
183
188
|
}, function (_ref5) {
|
|
@@ -196,6 +201,7 @@ var DrawerContainer = function DrawerContainer(_ref4) {
|
|
|
196
201
|
onClose: onClose,
|
|
197
202
|
zIndex: zIndex,
|
|
198
203
|
closeTargets: closeTargets,
|
|
204
|
+
width: width,
|
|
199
205
|
"data-qa-drawer": id || '',
|
|
200
206
|
"data-qa-drawer-isopen": isOpen === true
|
|
201
207
|
}, rest), children);
|
|
@@ -75,12 +75,12 @@ module.exports = {
|
|
|
75
75
|
"shopify": "0 0 140 159",
|
|
76
76
|
"slack-dark": "0 0 140 140",
|
|
77
77
|
"slack": "0 0 140 140",
|
|
78
|
-
"sproutsocial-dark": "0 0
|
|
79
|
-
"sproutsocial-lockup-dark": "0 0 291
|
|
80
|
-
"sproutsocial-lockup": "0 0 291
|
|
78
|
+
"sproutsocial-dark": "0 0 16 18",
|
|
79
|
+
"sproutsocial-lockup-dark": "0 0 291 59",
|
|
80
|
+
"sproutsocial-lockup": "0 0 291 59",
|
|
81
81
|
"sproutsocial-wordmark-dark": "0 0 320 52",
|
|
82
82
|
"sproutsocial-wordmark": "0 0 320 52",
|
|
83
|
-
"sproutsocial": "0 0
|
|
83
|
+
"sproutsocial": "0 0 16 18",
|
|
84
84
|
"tableau-dark": "0 0 18 18",
|
|
85
85
|
"tableau-lockup-dark": "0 0 291 56",
|
|
86
86
|
"tableau-lockup": "0 0 291 56",
|