@jetbrains/ring-ui-built 6.0.50 → 7.0.0-beta.1
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/components/_helpers/header.js +1 -1
- package/components/form/form.js +1 -1
- package/components/header/header-icon.d.ts +32 -0
- package/components/header/header-icon.js +56 -0
- package/components/header/header.d.ts +3 -0
- package/components/header/header.js +7 -5
- package/components/header/profile.js +2 -1
- package/components/header/scrollable-section.d.ts +2 -0
- package/components/header/scrollable-section.js +47 -0
- package/components/header/services.js +3 -3
- package/components/header/smart-services.js +1 -1
- package/components/header/tray-icon.d.ts +1 -32
- package/components/header/tray-icon.js +8 -38
- package/components/heading/heading.d.ts +1 -4
- package/components/heading/heading.js +9 -21
- package/components/input/input-legacy.js +1 -1
- package/components/input-size/input-size.js +1 -1
- package/components/select/select.js +17 -22
- package/components/style.css +1 -1
- package/package.json +2 -2
@@ -510,11 +510,14 @@ var Select = /*#__PURE__*/function (_Component) {
|
|
510
510
|
var nextSelection;
|
511
511
|
if (!prevState.multipleMap[selected.key]) {
|
512
512
|
nextSelection = currentSelection.concat(selected);
|
513
|
+
_this.props.onSelect && _this.props.onSelect(selected, event);
|
513
514
|
} else {
|
514
515
|
nextSelection = currentSelection.filter(function (item) {
|
515
516
|
return item.key !== selected.key;
|
516
517
|
});
|
518
|
+
_this.props.onDeselect && _this.props.onDeselect(selected);
|
517
519
|
}
|
520
|
+
_this.props.onChange(nextSelection, event);
|
518
521
|
var nextState = {
|
519
522
|
filterValue: '',
|
520
523
|
selected: nextSelection,
|
@@ -542,14 +545,6 @@ var Select = /*#__PURE__*/function (_Component) {
|
|
542
545
|
}
|
543
546
|
return _objectSpread2(_objectSpread2({}, prevState), nextState);
|
544
547
|
}, function () {
|
545
|
-
if (_this.state.multipleMap[selected.key]) {
|
546
|
-
var _this$props$onSelect, _this$props;
|
547
|
-
(_this$props$onSelect = (_this$props = _this.props).onSelect) === null || _this$props$onSelect === void 0 || _this$props$onSelect.call(_this$props, selected, event);
|
548
|
-
} else {
|
549
|
-
var _this$props$onDeselec, _this$props2;
|
550
|
-
(_this$props$onDeselec = (_this$props2 = _this.props).onDeselect) === null || _this$props$onDeselec === void 0 || _this$props$onDeselec.call(_this$props2, selected);
|
551
|
-
}
|
552
|
-
_this.props.onChange(_this.state.selected, event);
|
553
548
|
if (tryKeepOpen) {
|
554
549
|
_this._redrawPopup();
|
555
550
|
}
|
@@ -648,11 +643,11 @@ var Select = /*#__PURE__*/function (_Component) {
|
|
648
643
|
var _this$state = this.state,
|
649
644
|
showPopup = _this$state.showPopup,
|
650
645
|
selected = _this$state.selected;
|
651
|
-
var _this$
|
652
|
-
onClose = _this$
|
653
|
-
onOpen = _this$
|
654
|
-
onChange = _this$
|
655
|
-
multiple = _this$
|
646
|
+
var _this$props = this.props,
|
647
|
+
onClose = _this$props.onClose,
|
648
|
+
onOpen = _this$props.onOpen,
|
649
|
+
onChange = _this$props.onChange,
|
650
|
+
multiple = _this$props.multiple;
|
656
651
|
if (prevState.showPopup && !showPopup) {
|
657
652
|
onClose(selected);
|
658
653
|
} else if (!prevState.showPopup && showPopup) {
|
@@ -794,9 +789,9 @@ var Select = /*#__PURE__*/function (_Component) {
|
|
794
789
|
}, {
|
795
790
|
key: "getToolbar",
|
796
791
|
value: function getToolbar() {
|
797
|
-
var _this$
|
798
|
-
hint = _this$
|
799
|
-
renderBottomToolbar = _this$
|
792
|
+
var _this$props2 = this.props,
|
793
|
+
hint = _this$props2.hint,
|
794
|
+
renderBottomToolbar = _this$props2.renderBottomToolbar;
|
800
795
|
var _ref3 = this.state.addButton || {},
|
801
796
|
prefix = _ref3.prefix,
|
802
797
|
label = _ref3.label,
|
@@ -826,8 +821,8 @@ var Select = /*#__PURE__*/function (_Component) {
|
|
826
821
|
}, {
|
827
822
|
key: "getTopbar",
|
828
823
|
value: function getTopbar() {
|
829
|
-
var _this$props$renderTop, _this$
|
830
|
-
return (_this$props$renderTop = (_this$
|
824
|
+
var _this$props$renderTop, _this$props3;
|
825
|
+
return (_this$props$renderTop = (_this$props3 = this.props).renderTopToolbar) === null || _this$props$renderTop === void 0 ? void 0 : _this$props$renderTop.call(_this$props3);
|
831
826
|
}
|
832
827
|
}, {
|
833
828
|
key: "getFilterFn",
|
@@ -908,10 +903,10 @@ var Select = /*#__PURE__*/function (_Component) {
|
|
908
903
|
key: "_getIcons",
|
909
904
|
value: function _getIcons() {
|
910
905
|
var selected = this.state.selected;
|
911
|
-
var _this$
|
912
|
-
disabled = _this$
|
913
|
-
clear = _this$
|
914
|
-
hideArrow = _this$
|
906
|
+
var _this$props4 = this.props,
|
907
|
+
disabled = _this$props4.disabled,
|
908
|
+
clear = _this$props4.clear,
|
909
|
+
hideArrow = _this$props4.hideArrow;
|
915
910
|
var icons = [];
|
916
911
|
var height = this.props.height || this.context;
|
917
912
|
if (!Array.isArray(selected) && selected !== null && selected !== void 0 && selected.icon) {
|