@dnb/eufemia 9.23.0-beta.4 → 9.23.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 +8 -31
- package/cjs/components/tabs/Tabs.js +104 -69
- package/cjs/components/tabs/style/_tabs.scss +10 -35
- package/cjs/components/tabs/style/dnb-tabs.css +13 -25
- package/cjs/components/tabs/style/dnb-tabs.min.css +1 -1
- package/cjs/components/tag/style/_tag.scss +10 -6
- package/cjs/components/tag/style/dnb-tag.css +13 -5
- package/cjs/components/tag/style/dnb-tag.min.css +1 -1
- package/cjs/shared/Eufemia.js +1 -1
- package/cjs/style/dnb-ui-components.css +26 -30
- package/cjs/style/dnb-ui-components.min.css +1 -1
- package/components/tabs/Tabs.js +104 -69
- package/components/tabs/style/_tabs.scss +10 -35
- package/components/tabs/style/dnb-tabs.css +13 -25
- package/components/tabs/style/dnb-tabs.min.css +1 -1
- package/components/tag/style/_tag.scss +10 -6
- package/components/tag/style/dnb-tag.css +13 -5
- package/components/tag/style/dnb-tag.min.css +1 -1
- package/es/components/tabs/Tabs.js +53 -23
- package/es/components/tabs/style/_tabs.scss +10 -35
- package/es/components/tabs/style/dnb-tabs.css +13 -25
- package/es/components/tabs/style/dnb-tabs.min.css +1 -1
- package/es/components/tag/style/_tag.scss +10 -6
- package/es/components/tag/style/dnb-tag.css +13 -5
- package/es/components/tag/style/dnb-tag.min.css +1 -1
- package/es/shared/Eufemia.js +1 -1
- package/es/style/dnb-ui-components.css +26 -30
- package/es/style/dnb-ui-components.min.css +1 -1
- package/esm/dnb-ui-basis.min.mjs +1 -1
- package/esm/dnb-ui-components.min.mjs +1 -1
- package/esm/dnb-ui-elements.min.mjs +1 -1
- package/esm/dnb-ui-extensions.min.mjs +1 -1
- package/esm/dnb-ui-lib.min.mjs +3 -3
- package/esm/dnb-ui-web-components.min.mjs +2 -2
- package/package.json +1 -1
- package/shared/Eufemia.js +1 -1
- package/style/dnb-ui-components.css +26 -30
- package/style/dnb-ui-components.min.css +1 -1
- package/umd/dnb-ui-basis.min.js +1 -1
- package/umd/dnb-ui-components.min.js +3 -3
- package/umd/dnb-ui-elements.min.js +1 -1
- package/umd/dnb-ui-extensions.min.js +1 -1
- package/umd/dnb-ui-lib.min.js +3 -3
- package/umd/dnb-ui-web-components.min.js +4 -4
package/CHANGELOG.md
CHANGED
|
@@ -3,50 +3,27 @@
|
|
|
3
3
|
All notable changes to @dnb/eufemia will be documented in this file. See
|
|
4
4
|
[Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
-
# [9.23.0
|
|
6
|
+
# [9.23.0](https://github.com/dnbexperience/eufemia/compare/v9.22.0...v9.23.0) (2022-02-22)
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
### Bug Fixes
|
|
10
10
|
|
|
11
11
|
* **Dropdown:** disabled tertiary dropdown ([c1b4c4b](https://github.com/dnbexperience/eufemia/commit/c1b4c4b58511a7055e95ac32e0ed849e1838f075))
|
|
12
|
-
* **Styles:** ensure independent styling packages have declared their dependencies ([8b3c230](https://github.com/dnbexperience/eufemia/commit/8b3c230b4e0c91d96695791731b61a6b8641c9db))
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
### Features
|
|
16
|
-
|
|
17
|
-
* **esm:** remove esm directory in package build ([f189b62](https://github.com/dnbexperience/eufemia/commit/f189b62dfcb620f0d0f7f8673c781c3e08060d32))
|
|
18
|
-
* **Icon:** add examples for color property ([#1275](https://github.com/dnbexperience/eufemia/issues/1275)) ([67f8121](https://github.com/dnbexperience/eufemia/commit/67f8121485bbb419c6cc5f104023ccb619aeac73))
|
|
19
|
-
* **Tabs:** Enhance parent width handling and remove auto edge detection ([d002f2c](https://github.com/dnbexperience/eufemia/commit/d002f2cada9a31d1923e6507d2015a06b751be71))
|
|
20
|
-
* **TypeScript:** remove original ts/tsx files and only leave type definition files ([#1292](https://github.com/dnbexperience/eufemia/issues/1292)) ([79bdfb4](https://github.com/dnbexperience/eufemia/commit/79bdfb404dd9ebd484fff4770e849e16b6bbff2e))
|
|
21
|
-
|
|
22
|
-
# [9.23.0-beta.3](https://github.com/dnbexperience/eufemia/compare/v9.23.0-beta.2...v9.23.0-beta.3) (2022-02-17)
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
### Features
|
|
26
|
-
|
|
27
|
-
* **esm:** remove esm directory in package build ([e36a90f](https://github.com/dnbexperience/eufemia/commit/e36a90fc6981ae6986eaebfa753cbcae4a0b29c5))
|
|
28
|
-
|
|
29
|
-
# [9.23.0-beta.2](https://github.com/dnbexperience/eufemia/compare/v9.23.0-beta.1...v9.23.0-beta.2) (2022-02-16)
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
### Bug Fixes
|
|
33
|
-
|
|
34
|
-
* ensure auto type generation dont gets overwritten by tsc afterwards ([b94a786](https://github.com/dnbexperience/eufemia/commit/b94a786572275489ba9e5b1f864d14a9f52a9022))
|
|
35
|
-
|
|
36
|
-
# [9.23.0-beta.1](https://github.com/dnbexperience/eufemia/compare/v9.22.0...v9.23.0-beta.1) (2022-02-16)
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
### Bug Fixes
|
|
40
|
-
|
|
41
12
|
* **Modal:** add possibility for camelcase props ([4127452](https://github.com/dnbexperience/eufemia/commit/4127452540c0a822f6a0c59d9dfeb4d2925d39f4))
|
|
42
13
|
* **ProgressIndicator:** css change to fix aliasing artifacts for ProgressIndicator ([ab8859e](https://github.com/dnbexperience/eufemia/commit/ab8859e5b5ec4cf728312edf87e60715a864c61f))
|
|
43
14
|
* set Eufemia.version during release ([e74d441](https://github.com/dnbexperience/eufemia/commit/e74d4412b395fe5b02cecdc9d1d962d1af73f41d))
|
|
15
|
+
* **Styles:** ensure independent styling packages have declared their dependencies ([8b3c230](https://github.com/dnbexperience/eufemia/commit/8b3c230b4e0c91d96695791731b61a6b8641c9db))
|
|
16
|
+
* **Tabs:** align to new UX designs ([794bf70](https://github.com/dnbexperience/eufemia/commit/794bf70f001feb10936c20c5023f270f34d69dfd))
|
|
17
|
+
* **Tag:** fix Tag.Group spacing ([d7b77a2](https://github.com/dnbexperience/eufemia/commit/d7b77a29c2fc368d2c05c1466a93b54e7d9c7730))
|
|
44
18
|
|
|
45
19
|
|
|
46
20
|
### Features
|
|
47
21
|
|
|
22
|
+
* **esm:** remove esm directory in package build ([f189b62](https://github.com/dnbexperience/eufemia/commit/f189b62dfcb620f0d0f7f8673c781c3e08060d32))
|
|
23
|
+
* **Icon:** add examples for color property ([#1275](https://github.com/dnbexperience/eufemia/issues/1275)) ([67f8121](https://github.com/dnbexperience/eufemia/commit/67f8121485bbb419c6cc5f104023ccb619aeac73))
|
|
48
24
|
* Separate Drawer and Dialog from Modal ([ebe8e6a](https://github.com/dnbexperience/eufemia/commit/ebe8e6a597c87885c081fcdfd76339780e90befc))
|
|
49
|
-
* **
|
|
25
|
+
* **Tabs:** Enhance parent width handling and remove auto edge detection ([99ed393](https://github.com/dnbexperience/eufemia/commit/99ed3938bcfe6303162250cae1982af13df18744))
|
|
26
|
+
* **TypeScript:** remove original ts/tsx files and only leave type definition files ([#1292](https://github.com/dnbexperience/eufemia/issues/1292)) ([79bdfb4](https://github.com/dnbexperience/eufemia/commit/79bdfb404dd9ebd484fff4770e849e16b6bbff2e))
|
|
50
27
|
|
|
51
28
|
# [9.22.0](https://github.com/dnbexperience/eufemia/compare/v9.21.0...v9.22.0) (2022-02-09)
|
|
52
29
|
|
|
@@ -153,18 +153,25 @@ var Tabs = function (_React$PureComponent) {
|
|
|
153
153
|
if (_this._isMounted) {
|
|
154
154
|
_this.addScrollBehaviour();
|
|
155
155
|
|
|
156
|
-
_this.
|
|
156
|
+
var hasScrollbar = _this.hasScrollbar();
|
|
157
157
|
|
|
158
|
-
_this.
|
|
159
|
-
type: 'focus',
|
|
160
|
-
behavior: 'auto'
|
|
161
|
-
});
|
|
158
|
+
var hasLastPosition = _this.hasLastPosition();
|
|
162
159
|
|
|
163
|
-
_this.
|
|
164
|
-
|
|
165
|
-
behavior: 'auto'
|
|
160
|
+
_this.setScrollbarState({
|
|
161
|
+
hasScrollbar: hasScrollbar
|
|
166
162
|
});
|
|
167
163
|
|
|
164
|
+
if (hasLastPosition) {
|
|
165
|
+
_this.setLeftPosition(_this.state.lastPosition);
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
if (hasScrollbar) {
|
|
169
|
+
_this.scrollToTab({
|
|
170
|
+
type: 'selected',
|
|
171
|
+
behavior: hasLastPosition ? 'smooth' : 'auto'
|
|
172
|
+
});
|
|
173
|
+
}
|
|
174
|
+
|
|
168
175
|
if (_this.hasLastUsedTab() !== null) {
|
|
169
176
|
_this.setState(null, _this.setFocusOnTabButton);
|
|
170
177
|
}
|
|
@@ -172,19 +179,25 @@ var Tabs = function (_React$PureComponent) {
|
|
|
172
179
|
});
|
|
173
180
|
|
|
174
181
|
_defineProperty(_assertThisInitialized(_this), "setScrollbarState", function () {
|
|
175
|
-
var
|
|
182
|
+
var _ref = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},
|
|
183
|
+
_ref$hasScrollbar = _ref.hasScrollbar,
|
|
184
|
+
hasScrollbar = _ref$hasScrollbar === void 0 ? _this.hasScrollbar() : _ref$hasScrollbar;
|
|
176
185
|
|
|
177
186
|
if (hasScrollbar !== _this.state.hasScrollbar) {
|
|
178
187
|
_this.setState({
|
|
179
188
|
hasScrollbar: hasScrollbar
|
|
180
189
|
});
|
|
181
190
|
}
|
|
182
|
-
|
|
183
|
-
return hasScrollbar;
|
|
184
191
|
});
|
|
185
192
|
|
|
186
193
|
_defineProperty(_assertThisInitialized(_this), "onResizeHandler", function () {
|
|
187
|
-
|
|
194
|
+
var hasScrollbar = _this.hasScrollbar();
|
|
195
|
+
|
|
196
|
+
_this.setScrollbarState({
|
|
197
|
+
hasScrollbar: hasScrollbar
|
|
198
|
+
});
|
|
199
|
+
|
|
200
|
+
if (hasScrollbar) {
|
|
188
201
|
_this.scrollToTab({
|
|
189
202
|
type: 'selected'
|
|
190
203
|
});
|
|
@@ -357,8 +370,8 @@ var Tabs = function (_React$PureComponent) {
|
|
|
357
370
|
_defineProperty(_assertThisInitialized(_this), "getCurrentTitle", function () {
|
|
358
371
|
var selected_key = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : _this.state.selected_key;
|
|
359
372
|
|
|
360
|
-
var current = _this.state.data.filter(function (
|
|
361
|
-
var key =
|
|
373
|
+
var current = _this.state.data.filter(function (_ref2) {
|
|
374
|
+
var key = _ref2.key;
|
|
362
375
|
return key == selected_key;
|
|
363
376
|
})[0];
|
|
364
377
|
|
|
@@ -472,11 +485,11 @@ var Tabs = function (_React$PureComponent) {
|
|
|
472
485
|
}
|
|
473
486
|
|
|
474
487
|
if (items) {
|
|
475
|
-
content = items.filter(function (
|
|
476
|
-
var key =
|
|
488
|
+
content = items.filter(function (_ref3) {
|
|
489
|
+
var key = _ref3.key;
|
|
477
490
|
return key && selected_key && key == selected_key;
|
|
478
|
-
}).reduce(function (acc,
|
|
479
|
-
var content =
|
|
491
|
+
}).reduce(function (acc, _ref4) {
|
|
492
|
+
var content = _ref4.content;
|
|
480
493
|
return content || acc;
|
|
481
494
|
}, null);
|
|
482
495
|
}
|
|
@@ -490,9 +503,9 @@ var Tabs = function (_React$PureComponent) {
|
|
|
490
503
|
return content;
|
|
491
504
|
});
|
|
492
505
|
|
|
493
|
-
_defineProperty(_assertThisInitialized(_this), "TabsWrapperHandler", function (
|
|
494
|
-
var children =
|
|
495
|
-
rest = _objectWithoutProperties(
|
|
506
|
+
_defineProperty(_assertThisInitialized(_this), "TabsWrapperHandler", function (_ref5) {
|
|
507
|
+
var children = _ref5.children,
|
|
508
|
+
rest = _objectWithoutProperties(_ref5, _excluded);
|
|
496
509
|
|
|
497
510
|
var _this$props2 = _this.props,
|
|
498
511
|
className = _this$props2.className,
|
|
@@ -509,10 +522,10 @@ var Tabs = function (_React$PureComponent) {
|
|
|
509
522
|
return _react.default.createElement("div", _extends({}, params, rest), children);
|
|
510
523
|
});
|
|
511
524
|
|
|
512
|
-
_defineProperty(_assertThisInitialized(_this), "TabsListHandler", function (
|
|
513
|
-
var children =
|
|
514
|
-
className =
|
|
515
|
-
rest = _objectWithoutProperties(
|
|
525
|
+
_defineProperty(_assertThisInitialized(_this), "TabsListHandler", function (_ref6) {
|
|
526
|
+
var children = _ref6.children,
|
|
527
|
+
className = _ref6.className,
|
|
528
|
+
rest = _objectWithoutProperties(_ref6, _excluded2);
|
|
516
529
|
|
|
517
530
|
var _this$props3 = _this.props,
|
|
518
531
|
align = _this$props3.align,
|
|
@@ -527,11 +540,11 @@ var Tabs = function (_React$PureComponent) {
|
|
|
527
540
|
}, rest), _react.default.createElement(ScrollNavButton, {
|
|
528
541
|
onMouseDown: _this.openPrevTab,
|
|
529
542
|
icon: "chevron_left",
|
|
530
|
-
className: (0, _classnames.default)(hasScrollbar && typeof _this.state.isFirst !== 'undefined' && 'dnb-tabs__scroll-nav-button--visible', _this.state.isFirst && 'dnb-tabs__scroll-nav-button--hide')
|
|
543
|
+
className: (0, _classnames.default)(hasScrollbar && (typeof _this.state.isFirst !== 'undefined' || _this.hasLastPosition()) && 'dnb-tabs__scroll-nav-button--visible', _this.state.isFirst && 'dnb-tabs__scroll-nav-button--hide')
|
|
531
544
|
}), children, _react.default.createElement(ScrollNavButton, {
|
|
532
545
|
onMouseDown: _this.openNextTab,
|
|
533
546
|
icon: "chevron_right",
|
|
534
|
-
className: (0, _classnames.default)(hasScrollbar && typeof _this.state.isLast !== 'undefined' && 'dnb-tabs__scroll-nav-button--visible', _this.state.isLast && 'dnb-tabs__scroll-nav-button--hide')
|
|
547
|
+
className: (0, _classnames.default)(hasScrollbar && (typeof _this.state.isLast !== 'undefined' || _this.hasLastPosition()) && 'dnb-tabs__scroll-nav-button--visible', _this.state.isLast && 'dnb-tabs__scroll-nav-button--hide')
|
|
535
548
|
}));
|
|
536
549
|
});
|
|
537
550
|
|
|
@@ -561,13 +574,13 @@ var Tabs = function (_React$PureComponent) {
|
|
|
561
574
|
var selected_key = _this.state.selected_key;
|
|
562
575
|
var TabElement = tab_element || 'button';
|
|
563
576
|
|
|
564
|
-
var tabs = _this.state.data.map(function (
|
|
565
|
-
var title =
|
|
566
|
-
key =
|
|
567
|
-
|
|
568
|
-
disabled =
|
|
569
|
-
to =
|
|
570
|
-
href =
|
|
577
|
+
var tabs = _this.state.data.map(function (_ref7) {
|
|
578
|
+
var title = _ref7.title,
|
|
579
|
+
key = _ref7.key,
|
|
580
|
+
_ref7$disabled = _ref7.disabled,
|
|
581
|
+
disabled = _ref7$disabled === void 0 ? false : _ref7$disabled,
|
|
582
|
+
to = _ref7.to,
|
|
583
|
+
href = _ref7.href;
|
|
571
584
|
var itemParams = {
|
|
572
585
|
to: to,
|
|
573
586
|
href: href
|
|
@@ -651,6 +664,7 @@ var Tabs = function (_React$PureComponent) {
|
|
|
651
664
|
selected_key: _selected_key,
|
|
652
665
|
focus_key: _selected_key,
|
|
653
666
|
atEdge: false,
|
|
667
|
+
lastPosition: lastPosition,
|
|
654
668
|
hasScrollbar: lastPosition > -1,
|
|
655
669
|
_selected_key: _selected_key,
|
|
656
670
|
_data: _props.data || _props.children,
|
|
@@ -713,14 +727,19 @@ var Tabs = function (_React$PureComponent) {
|
|
|
713
727
|
}
|
|
714
728
|
}
|
|
715
729
|
}
|
|
730
|
+
}, {
|
|
731
|
+
key: "hasLastPosition",
|
|
732
|
+
value: function hasLastPosition() {
|
|
733
|
+
return this.state.lastPosition > -1;
|
|
734
|
+
}
|
|
716
735
|
}, {
|
|
717
736
|
key: "getLastPosition",
|
|
718
737
|
value: function getLastPosition() {
|
|
719
738
|
if (typeof window !== 'undefined') {
|
|
720
739
|
try {
|
|
721
|
-
var pos = parseFloat(window.localStorage.getItem("tabs-pos-".concat(this._id)))
|
|
740
|
+
var pos = parseFloat(window.localStorage.getItem("tabs-pos-".concat(this._id)));
|
|
722
741
|
window.localStorage.removeItem("tabs-pos-".concat(this._id));
|
|
723
|
-
return pos;
|
|
742
|
+
return isNaN(pos) ? -1 : pos;
|
|
724
743
|
} catch (e) {
|
|
725
744
|
(0, _componentHelper.warn)(e);
|
|
726
745
|
}
|
|
@@ -757,11 +776,11 @@ var Tabs = function (_React$PureComponent) {
|
|
|
757
776
|
}, {
|
|
758
777
|
key: "saveLastPosition",
|
|
759
778
|
value: function saveLastPosition() {
|
|
760
|
-
var
|
|
779
|
+
var position = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : this._tablistRef.current.scrollLeft;
|
|
761
780
|
|
|
762
781
|
if (typeof window !== 'undefined') {
|
|
763
782
|
try {
|
|
764
|
-
window.localStorage.setItem("tabs-pos-".concat(this._id),
|
|
783
|
+
window.localStorage.setItem("tabs-pos-".concat(this._id), position);
|
|
765
784
|
} catch (e) {
|
|
766
785
|
(0, _componentHelper.warn)(e);
|
|
767
786
|
}
|
|
@@ -779,14 +798,23 @@ var Tabs = function (_React$PureComponent) {
|
|
|
779
798
|
window.addEventListener('resize', this.onResizeHandler);
|
|
780
799
|
}
|
|
781
800
|
}
|
|
801
|
+
}, {
|
|
802
|
+
key: "setLeftPosition",
|
|
803
|
+
value: function setLeftPosition(scrollLeft) {
|
|
804
|
+
try {
|
|
805
|
+
this._tablistRef.current.style.scrollBehavior = 'auto';
|
|
806
|
+
this._tablistRef.current.scrollLeft = scrollLeft;
|
|
807
|
+
this._tablistRef.current.style.scrollBehavior = 'smooth';
|
|
808
|
+
} catch (e) {}
|
|
809
|
+
}
|
|
782
810
|
}, {
|
|
783
811
|
key: "scrollToTab",
|
|
784
|
-
value: function scrollToTab(
|
|
812
|
+
value: function scrollToTab(_ref8) {
|
|
785
813
|
var _this2 = this;
|
|
786
814
|
|
|
787
|
-
var type =
|
|
788
|
-
|
|
789
|
-
behavior =
|
|
815
|
+
var type = _ref8.type,
|
|
816
|
+
_ref8$behavior = _ref8.behavior,
|
|
817
|
+
behavior = _ref8$behavior === void 0 ? 'smooth' : _ref8$behavior;
|
|
790
818
|
|
|
791
819
|
if (typeof window === 'undefined') {
|
|
792
820
|
return;
|
|
@@ -812,6 +840,14 @@ var Tabs = function (_React$PureComponent) {
|
|
|
812
840
|
var style = window.getComputedStyle(_this2._tabsRef.current);
|
|
813
841
|
var margin = parseFloat(style.marginLeft);
|
|
814
842
|
var padding = margin < 0 ? parseFloat(style.paddingLeft) : 0;
|
|
843
|
+
|
|
844
|
+
if (!isFirst && !isLast && parseFloat(style.paddingLeft) < 16) {
|
|
845
|
+
var navButton = _this2._tabsRef.current.querySelector('.dnb-tabs__scroll-nav-button:first-of-type');
|
|
846
|
+
|
|
847
|
+
var additionalSpace = parseFloat(window.getComputedStyle(navButton).width) * 1.5;
|
|
848
|
+
padding += additionalSpace;
|
|
849
|
+
}
|
|
850
|
+
|
|
815
851
|
var leftPadding = (margin < 0 ? Math.abs(margin) : 0) + padding + parseFloat(window.getComputedStyle(first).paddingLeft);
|
|
816
852
|
var offsetLeft = elem.offsetLeft;
|
|
817
853
|
var left = elem && !isFirst ? offsetLeft - leftPadding : 0;
|
|
@@ -848,12 +884,12 @@ var Tabs = function (_React$PureComponent) {
|
|
|
848
884
|
}, {
|
|
849
885
|
key: "getStepKey",
|
|
850
886
|
value: function getStepKey(useKey, stateKey) {
|
|
851
|
-
var currentData = this.state.data.filter(function (
|
|
852
|
-
var disabled =
|
|
887
|
+
var currentData = this.state.data.filter(function (_ref9) {
|
|
888
|
+
var disabled = _ref9.disabled;
|
|
853
889
|
return !disabled;
|
|
854
890
|
});
|
|
855
|
-
var currentIndex = currentData.reduce(function (acc,
|
|
856
|
-
var key =
|
|
891
|
+
var currentIndex = currentData.reduce(function (acc, _ref10, i) {
|
|
892
|
+
var key = _ref10.key;
|
|
857
893
|
return key == stateKey ? i : acc;
|
|
858
894
|
}, -1);
|
|
859
895
|
var nextIndex = currentIndex + useKey;
|
|
@@ -866,8 +902,8 @@ var Tabs = function (_React$PureComponent) {
|
|
|
866
902
|
nextIndex = 0;
|
|
867
903
|
}
|
|
868
904
|
|
|
869
|
-
return currentData.reduce(function (acc,
|
|
870
|
-
var key =
|
|
905
|
+
return currentData.reduce(function (acc, _ref11, i) {
|
|
906
|
+
var key = _ref11.key;
|
|
871
907
|
return i === nextIndex ? key : acc;
|
|
872
908
|
}, null);
|
|
873
909
|
}
|
|
@@ -923,10 +959,10 @@ var Tabs = function (_React$PureComponent) {
|
|
|
923
959
|
prerender = _this$props4.prerender;
|
|
924
960
|
|
|
925
961
|
if ((0, _componentHelper.isTrue)(prerender)) {
|
|
926
|
-
this._cache = Object.entries(data).reduce(function (acc,
|
|
927
|
-
var
|
|
928
|
-
idx =
|
|
929
|
-
cur =
|
|
962
|
+
this._cache = Object.entries(data).reduce(function (acc, _ref12) {
|
|
963
|
+
var _ref13 = _slicedToArray(_ref12, 2),
|
|
964
|
+
idx = _ref13[0],
|
|
965
|
+
cur = _ref13[1];
|
|
930
966
|
|
|
931
967
|
acc[cur.key] = _objectSpread(_objectSpread({}, cur), {}, {
|
|
932
968
|
content: _this3.getContent(cur.key)
|
|
@@ -939,10 +975,10 @@ var Tabs = function (_React$PureComponent) {
|
|
|
939
975
|
}));
|
|
940
976
|
}
|
|
941
977
|
|
|
942
|
-
var cachedContent = Object.entries(this._cache).map(function (
|
|
943
|
-
var
|
|
944
|
-
key =
|
|
945
|
-
content =
|
|
978
|
+
var cachedContent = Object.entries(this._cache).map(function (_ref14) {
|
|
979
|
+
var _ref15 = _slicedToArray(_ref14, 2),
|
|
980
|
+
key = _ref15[0],
|
|
981
|
+
content = _ref15[1].content;
|
|
946
982
|
|
|
947
983
|
var params = {};
|
|
948
984
|
|
|
@@ -1011,14 +1047,14 @@ var Tabs = function (_React$PureComponent) {
|
|
|
1011
1047
|
var useKey = selected_key;
|
|
1012
1048
|
|
|
1013
1049
|
if (!useKey) {
|
|
1014
|
-
useKey = data.reduce(function (acc,
|
|
1015
|
-
var selected =
|
|
1016
|
-
key =
|
|
1050
|
+
useKey = data.reduce(function (acc, _ref16) {
|
|
1051
|
+
var selected = _ref16.selected,
|
|
1052
|
+
key = _ref16.key;
|
|
1017
1053
|
return selected ? key : acc;
|
|
1018
1054
|
}, null) || data[0] && data[0].key;
|
|
1019
1055
|
} else {
|
|
1020
|
-
var keyExists = data.findIndex(function (
|
|
1021
|
-
var key =
|
|
1056
|
+
var keyExists = data.findIndex(function (_ref17) {
|
|
1057
|
+
var key = _ref17.key;
|
|
1022
1058
|
return key == selected_key;
|
|
1023
1059
|
});
|
|
1024
1060
|
|
|
@@ -1095,10 +1131,10 @@ var Tabs = function (_React$PureComponent) {
|
|
|
1095
1131
|
} else if (typeof data === 'string') {
|
|
1096
1132
|
res = data[0] === '[' ? JSON.parse(data) : [];
|
|
1097
1133
|
} else if (data && _typeof(data) === 'object') {
|
|
1098
|
-
res = Object.entries(data).reduce(function (acc,
|
|
1099
|
-
var
|
|
1100
|
-
key =
|
|
1101
|
-
obj =
|
|
1134
|
+
res = Object.entries(data).reduce(function (acc, _ref18) {
|
|
1135
|
+
var _ref19 = _slicedToArray(_ref18, 2),
|
|
1136
|
+
key = _ref19[0],
|
|
1137
|
+
obj = _ref19[1];
|
|
1102
1138
|
|
|
1103
1139
|
if (obj) {
|
|
1104
1140
|
acc.push(_objectSpread({
|
|
@@ -1196,8 +1232,8 @@ process.env.NODE_ENV !== "production" ? Tabs.propTypes = _objectSpread(_objectSp
|
|
|
1196
1232
|
on_focus: _propTypes.default.func
|
|
1197
1233
|
}) : void 0;
|
|
1198
1234
|
|
|
1199
|
-
var Dummy = function Dummy(
|
|
1200
|
-
var children =
|
|
1235
|
+
var Dummy = function Dummy(_ref20) {
|
|
1236
|
+
var children = _ref20.children;
|
|
1201
1237
|
return _react.default.createElement("span", {
|
|
1202
1238
|
"aria-hidden": true,
|
|
1203
1239
|
hidden: true,
|
|
@@ -1216,8 +1252,7 @@ var ScrollNavButton = function ScrollNavButton(props) {
|
|
|
1216
1252
|
variant: "primary",
|
|
1217
1253
|
tabIndex: "-1",
|
|
1218
1254
|
bounding: true,
|
|
1219
|
-
"aria-hidden": true
|
|
1220
|
-
icon_size: "medium"
|
|
1255
|
+
"aria-hidden": true
|
|
1221
1256
|
}, props, {
|
|
1222
1257
|
className: (0, _classnames.default)('dnb-tabs__scroll-nav-button', props.className)
|
|
1223
1258
|
}));
|
|
@@ -58,11 +58,13 @@
|
|
|
58
58
|
}
|
|
59
59
|
|
|
60
60
|
&__scroll-nav-button {
|
|
61
|
-
position:
|
|
61
|
+
position: absolute;
|
|
62
62
|
z-index: 2;
|
|
63
63
|
|
|
64
|
-
|
|
65
|
-
|
|
64
|
+
right: -2px;
|
|
65
|
+
&:first-of-type {
|
|
66
|
+
left: -2px;
|
|
67
|
+
right: auto;
|
|
66
68
|
}
|
|
67
69
|
|
|
68
70
|
display: none; // use "none" to remove it from markup by default
|
|
@@ -155,39 +157,19 @@
|
|
|
155
157
|
padding-right: 0.5rem;
|
|
156
158
|
}
|
|
157
159
|
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
&:first-of-type.selected.focus,
|
|
161
|
-
&:last-of-type.focus,
|
|
162
|
-
&:last-of-type.selected {
|
|
163
|
-
transition: padding 1s #{$defaultEasing} 10ms;
|
|
164
|
-
}
|
|
160
|
+
will-change: padding;
|
|
161
|
+
transition: padding 1s #{$defaultEasing};
|
|
165
162
|
}
|
|
166
163
|
|
|
167
|
-
|
|
168
|
-
&:first-of-type {
|
|
169
|
-
margin-left: -3rem;
|
|
170
|
-
padding-left: 3rem;
|
|
171
|
-
}
|
|
172
|
-
&:last-of-type {
|
|
173
|
-
margin-right: -3rem;
|
|
174
|
-
padding-right: 3rem;
|
|
175
|
-
}
|
|
176
|
-
|
|
177
|
-
&:first-of-type.focus,
|
|
178
|
-
&:first-of-type.selected.focus {
|
|
179
|
-
padding-left: 0;
|
|
180
|
-
|
|
164
|
+
html[data-whatinput='keyboard'] &__button__snap {
|
|
165
|
+
&:first-of-type.focus {
|
|
181
166
|
// add space so the focus ring is visible within our overflow
|
|
182
167
|
.dnb-tabs__button:focus {
|
|
183
168
|
margin-left: 0.5rem;
|
|
184
169
|
}
|
|
185
170
|
}
|
|
186
171
|
|
|
187
|
-
&:last-of-type.focus
|
|
188
|
-
&:last-of-type.selected.focus {
|
|
189
|
-
padding-right: 0;
|
|
190
|
-
|
|
172
|
+
&:last-of-type.focus {
|
|
191
173
|
// add space so the focus ring is visible within our overflow
|
|
192
174
|
/* stylelint-disable */
|
|
193
175
|
.dnb-tabs__button:focus {
|
|
@@ -197,13 +179,6 @@
|
|
|
197
179
|
}
|
|
198
180
|
}
|
|
199
181
|
|
|
200
|
-
// Do this in order to have the selected tab to be nice aligned during scrollTo
|
|
201
|
-
&--has-scrollbar &__tabs__tablist {
|
|
202
|
-
margin: 0 -2rem; // The width of the nav-button
|
|
203
|
-
padding-left: 3rem;
|
|
204
|
-
padding-right: 3rem;
|
|
205
|
-
}
|
|
206
|
-
|
|
207
182
|
/* stylelint-disable */
|
|
208
183
|
html[data-visual-test] & &__button,
|
|
209
184
|
html[data-visual-test] & &__button__snap,
|
|
@@ -152,16 +152,17 @@
|
|
|
152
152
|
.dnb-tabs__tabs--no-border::before {
|
|
153
153
|
content: none; }
|
|
154
154
|
.dnb-tabs__scroll-nav-button {
|
|
155
|
-
position:
|
|
155
|
+
position: absolute;
|
|
156
156
|
z-index: 2;
|
|
157
|
+
right: -2px;
|
|
157
158
|
display: none;
|
|
158
159
|
opacity: 0;
|
|
159
160
|
pointer-events: none;
|
|
160
161
|
-webkit-transition: opacity 600ms ease-out;
|
|
161
162
|
transition: opacity 600ms ease-out; }
|
|
162
|
-
.dnb-tabs__scroll-nav-button
|
|
163
|
-
|
|
164
|
-
|
|
163
|
+
.dnb-tabs__scroll-nav-button:first-of-type {
|
|
164
|
+
left: -2px;
|
|
165
|
+
right: auto; }
|
|
165
166
|
.dnb-tabs__scroll-nav-button--visible {
|
|
166
167
|
display: -webkit-box;
|
|
167
168
|
display: -ms-flexbox;
|
|
@@ -230,7 +231,10 @@
|
|
|
230
231
|
display: -webkit-box;
|
|
231
232
|
display: -ms-flexbox;
|
|
232
233
|
display: flex;
|
|
233
|
-
padding: 0 1rem 0 1.5rem;
|
|
234
|
+
padding: 0 1rem 0 1.5rem;
|
|
235
|
+
will-change: padding;
|
|
236
|
+
-webkit-transition: padding 1s cubic-bezier(0.42, 0, 0, 1);
|
|
237
|
+
transition: padding 1s cubic-bezier(0.42, 0, 0, 1); }
|
|
234
238
|
@media screen and (max-width: 40em) {
|
|
235
239
|
.dnb-tabs__button__snap {
|
|
236
240
|
padding: 0 1rem; } }
|
|
@@ -238,29 +242,13 @@
|
|
|
238
242
|
padding-left: 0; }
|
|
239
243
|
.dnb-tabs__button__snap:last-of-type {
|
|
240
244
|
padding-right: 0.5rem; }
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
.dnb-tabs--has-scrollbar .dnb-tabs__button__snap:first-of-type {
|
|
245
|
-
margin-left: -3rem;
|
|
246
|
-
padding-left: 3rem; }
|
|
247
|
-
.dnb-tabs--has-scrollbar .dnb-tabs__button__snap:last-of-type {
|
|
248
|
-
margin-right: -3rem;
|
|
249
|
-
padding-right: 3rem; }
|
|
250
|
-
.dnb-tabs--has-scrollbar .dnb-tabs__button__snap:first-of-type.focus, .dnb-tabs--has-scrollbar .dnb-tabs__button__snap:first-of-type.selected.focus {
|
|
251
|
-
padding-left: 0; }
|
|
252
|
-
.dnb-tabs--has-scrollbar .dnb-tabs__button__snap:first-of-type.focus .dnb-tabs__button:focus, .dnb-tabs--has-scrollbar .dnb-tabs__button__snap:first-of-type.selected.focus .dnb-tabs__button:focus {
|
|
253
|
-
margin-left: 0.5rem; }
|
|
254
|
-
.dnb-tabs--has-scrollbar .dnb-tabs__button__snap:last-of-type.focus, .dnb-tabs--has-scrollbar .dnb-tabs__button__snap:last-of-type.selected.focus {
|
|
255
|
-
padding-right: 0;
|
|
245
|
+
html[data-whatinput='keyboard'] .dnb-tabs__button__snap:first-of-type.focus .dnb-tabs__button:focus {
|
|
246
|
+
margin-left: 0.5rem; }
|
|
247
|
+
html[data-whatinput='keyboard'] .dnb-tabs__button__snap:last-of-type.focus {
|
|
256
248
|
/* stylelint-disable */
|
|
257
249
|
/* stylelint-enable */ }
|
|
258
|
-
|
|
250
|
+
html[data-whatinput='keyboard'] .dnb-tabs__button__snap:last-of-type.focus .dnb-tabs__button:focus {
|
|
259
251
|
margin-right: 0.5rem; }
|
|
260
|
-
.dnb-tabs--has-scrollbar .dnb-tabs__tabs__tablist {
|
|
261
|
-
margin: 0 -2rem;
|
|
262
|
-
padding-left: 3rem;
|
|
263
|
-
padding-right: 3rem; }
|
|
264
252
|
html[data-visual-test] .dnb-tabs .dnb-tabs__button,
|
|
265
253
|
html[data-visual-test] .dnb-tabs .dnb-tabs__button__snap,
|
|
266
254
|
html[data-visual-test] .dnb-tabs .dnb-tabs__scroll-nav-button {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.dnb-tabs{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;-webkit-tap-highlight-color:rgba(0,0,0,0);-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%;color:#333;color:var(--color-black-80,#333);font-family:DNB,sans-serif;font-family:var(--font-family-default);font-size:1rem;font-size:var(--font-size-small);font-style:normal;font-weight:400;font-weight:var(--font-weight-basis);line-height:1.5rem;line-height:var(--line-height-basis);margin:0;padding:0;-moz-tab-size:4;-o-tab-size:4;tab-size:4;word-break:break-word}.dnb-tabs *,.dnb-tabs :after,.dnb-tabs :before{background-repeat:no-repeat;-webkit-box-sizing:border-box;box-sizing:border-box}.dnb-tabs :after,.dnb-tabs :before{text-decoration:inherit;vertical-align:inherit}.dnb-tabs__tabs{-webkit-box-align:center;-ms-flex-align:center;align-items:center;display:-webkit-box;display:-ms-flexbox;display:flex;position:relative;z-index:1}.dnb-tabs__tabs,.dnb-tabs__tabs.dnb-section--spacing{padding-bottom:0}.dnb-tabs__tabs__tablist{-webkit-box-flex:0;-ms-scroll-chaining:none;-webkit-overflow-scrolling:touch;-ms-overflow-style:auto;-ms-overflow-style:none;display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex:0 1 auto;flex:0 1 auto;overflow-x:auto;overscroll-behavior:contain;scrollbar-color:#14555a transparent;scrollbar-color:var(--color-emerald-green) transparent;scrollbar-width:thin;scrollbar-width:none}.dnb-tabs__tabs__tablist:focus{outline:none}html[data-whatinput=keyboard] .dnb-tabs__tabs__tablist:focus{--border-color:var(--color-emerald-green);border-color:transparent;-webkit-box-shadow:0 0 0 .125rem var(--border-color);box-shadow:0 0 0 .125rem var(--border-color)}@media screen and (-ms-high-contrast:none){html[data-whatinput=keyboard] .dnb-tabs__tabs__tablist:focus{-webkit-box-shadow:0 0 0 .125rem #14555a;box-shadow:0 0 0 .125rem #14555a;-webkit-box-shadow:0 0 0 .125rem var(--color-emerald-green);box-shadow:0 0 0 .125rem var(--color-emerald-green)}}html:not([data-visual-test]) .dnb-tabs__tabs__tablist{scroll-behavior:smooth}html[data-visual-test] .dnb-tabs__tabs__tablist{scroll-behavior:auto!important}.dnb-tabs__tabs__tablist::-webkit-scrollbar{display:none}.dnb-tabs__tabs--left .dnb-tabs__tabs__tablist{-webkit-box-pack:start;-ms-flex-pack:start;justify-content:flex-start}.dnb-tabs__tabs--right .dnb-tabs__tabs__tablist{-webkit-box-flex:1;-webkit-box-pack:end;-ms-flex-pack:end;-ms-flex:1;flex:1;justify-content:flex-end}.dnb-tabs__tabs--center .dnb-tabs__tabs__tablist{-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.dnb-tabs__tabs:before{bottom:0;content:"";height:1px;left:-100vw;position:absolute;width:100vw;z-index:-1}.dnb-tabs__tabs--no-border:before{content:none}.dnb-tabs__scroll-nav-button{display:none;opacity:0;pointer-events:none;position:
|
|
1
|
+
.dnb-tabs{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;-webkit-tap-highlight-color:rgba(0,0,0,0);-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%;color:#333;color:var(--color-black-80,#333);font-family:DNB,sans-serif;font-family:var(--font-family-default);font-size:1rem;font-size:var(--font-size-small);font-style:normal;font-weight:400;font-weight:var(--font-weight-basis);line-height:1.5rem;line-height:var(--line-height-basis);margin:0;padding:0;-moz-tab-size:4;-o-tab-size:4;tab-size:4;word-break:break-word}.dnb-tabs *,.dnb-tabs :after,.dnb-tabs :before{background-repeat:no-repeat;-webkit-box-sizing:border-box;box-sizing:border-box}.dnb-tabs :after,.dnb-tabs :before{text-decoration:inherit;vertical-align:inherit}.dnb-tabs__tabs{-webkit-box-align:center;-ms-flex-align:center;align-items:center;display:-webkit-box;display:-ms-flexbox;display:flex;position:relative;z-index:1}.dnb-tabs__tabs,.dnb-tabs__tabs.dnb-section--spacing{padding-bottom:0}.dnb-tabs__tabs__tablist{-webkit-box-flex:0;-ms-scroll-chaining:none;-webkit-overflow-scrolling:touch;-ms-overflow-style:auto;-ms-overflow-style:none;display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex:0 1 auto;flex:0 1 auto;overflow-x:auto;overscroll-behavior:contain;scrollbar-color:#14555a transparent;scrollbar-color:var(--color-emerald-green) transparent;scrollbar-width:thin;scrollbar-width:none}.dnb-tabs__tabs__tablist:focus{outline:none}html[data-whatinput=keyboard] .dnb-tabs__tabs__tablist:focus{--border-color:var(--color-emerald-green);border-color:transparent;-webkit-box-shadow:0 0 0 .125rem var(--border-color);box-shadow:0 0 0 .125rem var(--border-color)}@media screen and (-ms-high-contrast:none){html[data-whatinput=keyboard] .dnb-tabs__tabs__tablist:focus{-webkit-box-shadow:0 0 0 .125rem #14555a;box-shadow:0 0 0 .125rem #14555a;-webkit-box-shadow:0 0 0 .125rem var(--color-emerald-green);box-shadow:0 0 0 .125rem var(--color-emerald-green)}}html:not([data-visual-test]) .dnb-tabs__tabs__tablist{scroll-behavior:smooth}html[data-visual-test] .dnb-tabs__tabs__tablist{scroll-behavior:auto!important}.dnb-tabs__tabs__tablist::-webkit-scrollbar{display:none}.dnb-tabs__tabs--left .dnb-tabs__tabs__tablist{-webkit-box-pack:start;-ms-flex-pack:start;justify-content:flex-start}.dnb-tabs__tabs--right .dnb-tabs__tabs__tablist{-webkit-box-flex:1;-webkit-box-pack:end;-ms-flex-pack:end;-ms-flex:1;flex:1;justify-content:flex-end}.dnb-tabs__tabs--center .dnb-tabs__tabs__tablist{-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.dnb-tabs__tabs:before{bottom:0;content:"";height:1px;left:-100vw;position:absolute;width:100vw;z-index:-1}.dnb-tabs__tabs--no-border:before{content:none}.dnb-tabs__scroll-nav-button{display:none;opacity:0;pointer-events:none;position:absolute;right:-2px;-webkit-transition:opacity .6s ease-out;transition:opacity .6s ease-out;z-index:2}.dnb-tabs__scroll-nav-button:first-of-type{left:-2px;right:auto}.dnb-tabs__scroll-nav-button--visible{display:-webkit-box;display:-ms-flexbox;display:flex;opacity:1;pointer-events:auto}.dnb-tabs__scroll-nav-button--hide{opacity:0!important;pointer-events:none}.dnb-core-style .dnb-tabs .dnb-tabs__button,.dnb-tabs__button{background-color:transparent;border:none;cursor:pointer;font-size:1.125rem;font-size:var(--font-size-basis);line-height:1.5rem;line-height:var(--line-height-basis);margin:0;outline:none;padding:0 .125rem;position:relative;text-decoration:none;-webkit-transition:margin .4s ease-out;transition:margin .4s ease-out;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-user-select:none;white-space:nowrap;z-index:1}.dnb-core-style .dnb-tabs .dnb-tabs__button__title .dnb-icon,.dnb-tabs__button__title .dnb-icon{font-size:1rem;font-size:var(--font-size-small);-webkit-transform:translateY(-.125rem);transform:translateY(-.125rem)}.dnb-core-style .dnb-tabs .dnb-tabs__button .dnb-dummy,.dnb-tabs__button .dnb-dummy{-webkit-box-orient:vertical;-webkit-box-direction:normal;display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;height:0;margin-top:.25rem;overflow:hidden;visibility:hidden}.dnb-core-style .dnb-tabs .dnb-tabs__button:after,.dnb-tabs__button:after{bottom:0;content:"";height:1px;left:0;position:absolute;right:0;width:100%;z-index:-1}.dnb-tabs__button__snap{display:-webkit-box;display:-ms-flexbox;display:flex;padding:0 1rem 0 1.5rem;-webkit-transition:padding 1s cubic-bezier(.42,0,0,1);transition:padding 1s cubic-bezier(.42,0,0,1);will-change:padding}@media screen and (max-width:40em){.dnb-tabs__button__snap{padding:0 1rem}}.dnb-tabs__button__snap:first-of-type{padding-left:0}.dnb-tabs__button__snap:last-of-type{padding-right:.5rem}html[data-whatinput=keyboard] .dnb-tabs__button__snap:first-of-type.focus .dnb-tabs__button:focus{margin-left:.5rem}html[data-whatinput=keyboard] .dnb-tabs__button__snap:last-of-type.focus .dnb-tabs__button:focus{margin-right:.5rem}html[data-visual-test] .dnb-tabs .dnb-tabs__button,html[data-visual-test] .dnb-tabs .dnb-tabs__button__snap,html[data-visual-test] .dnb-tabs .dnb-tabs__scroll-nav-button{-webkit-transition:none!important;transition:none!important}.dnb-tabs__content--spacing{padding-top:2rem}
|
|
@@ -90,12 +90,16 @@
|
|
|
90
90
|
|
|
91
91
|
// Default space between tags
|
|
92
92
|
&__group {
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
93
|
+
display: inline-flex;
|
|
94
|
+
flex-wrap: wrap;
|
|
95
|
+
gap: 0.5rem;
|
|
96
|
+
|
|
97
|
+
@include IS_IE {
|
|
98
|
+
.dnb-button:not([class*='dnb-space']) {
|
|
99
|
+
margin-bottom: 0.5rem;
|
|
100
|
+
&:not(:last-of-type) {
|
|
101
|
+
margin-right: 0.5rem;
|
|
102
|
+
}
|
|
99
103
|
}
|
|
100
104
|
}
|
|
101
105
|
}
|
|
@@ -1116,8 +1116,16 @@ button.dnb-button::-moz-focus-inner {
|
|
|
1116
1116
|
.dnb-tag--removable.dnb-button--size-small.dnb-button--has-icon {
|
|
1117
1117
|
padding-right: 0; }
|
|
1118
1118
|
|
|
1119
|
-
.dnb-tag__group
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
|
|
1123
|
-
|
|
1119
|
+
.dnb-tag__group {
|
|
1120
|
+
display: -webkit-inline-box;
|
|
1121
|
+
display: -ms-inline-flexbox;
|
|
1122
|
+
display: inline-flex;
|
|
1123
|
+
-ms-flex-wrap: wrap;
|
|
1124
|
+
flex-wrap: wrap;
|
|
1125
|
+
grid-gap: 0.5rem;
|
|
1126
|
+
gap: 0.5rem; }
|
|
1127
|
+
@media screen and (-ms-high-contrast: none) {
|
|
1128
|
+
.dnb-tag__group .dnb-button:not([class*='dnb-space']) {
|
|
1129
|
+
margin-bottom: 0.5rem; }
|
|
1130
|
+
.dnb-tag__group .dnb-button:not([class*='dnb-space']):not(:last-of-type) {
|
|
1131
|
+
margin-right: 0.5rem; } }
|