@thecb/components 6.0.0-beta.8 → 6.0.0-beta.9
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/dist/index.cjs.js +12 -16
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +12 -16
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/atoms/dropdown/Dropdown.js +40 -55
package/dist/index.cjs.js
CHANGED
|
@@ -19528,7 +19528,8 @@ var Dropdown = function Dropdown(_ref8) {
|
|
|
19528
19528
|
var onKeyDown = function onKeyDown(e) {
|
|
19529
19529
|
var _optionRefs$current$l, _optionRefs$current;
|
|
19530
19530
|
|
|
19531
|
-
console.log("key down event is", e);
|
|
19531
|
+
console.log("key down event is", e.target);
|
|
19532
|
+
console.log("key down event value is", e.target.value);
|
|
19532
19533
|
var key = e.key,
|
|
19533
19534
|
keyCode = e.keyCode;
|
|
19534
19535
|
var focus = document.activeElement;
|
|
@@ -19647,28 +19648,22 @@ var Dropdown = function Dropdown(_ref8) {
|
|
|
19647
19648
|
return /*#__PURE__*/React__default.createElement(Box, {
|
|
19648
19649
|
onKeyDown: onKeyDown,
|
|
19649
19650
|
onClick: onClick,
|
|
19650
|
-
padding: "
|
|
19651
|
+
padding: "12px",
|
|
19651
19652
|
width: "100%",
|
|
19652
19653
|
hoverStyles: "background-color: ".concat(themeValues.hoverColor, ";"),
|
|
19654
|
+
background: isOpen ? themeValues.hoverColor : WHITE,
|
|
19653
19655
|
"aria-expanded": isOpen,
|
|
19654
19656
|
role: "combobox",
|
|
19655
19657
|
"aria-owns": "".concat(ariaLabelledby, "_listbox"),
|
|
19656
19658
|
"aria-haspopup": "listbox",
|
|
19657
19659
|
"aria-labelledby": ariaLabelledby,
|
|
19658
19660
|
extraStyles: disabled && "color: #6e727e;\n background-color: #f7f7f7;\n pointer-events: none;",
|
|
19659
|
-
title: hasTitles ? getSelection() : null
|
|
19660
|
-
}, /*#__PURE__*/React__default.createElement(Box, {
|
|
19661
|
-
as: "button",
|
|
19662
|
-
background: isOpen ? themeValues.hoverColor : WHITE,
|
|
19663
|
-
width: "100%",
|
|
19664
|
-
padding: "12px",
|
|
19665
|
-
hoverStyles: "background-color: ".concat(themeValues.hoverColor, ";"),
|
|
19666
|
-
borderSize: "1px",
|
|
19667
|
-
borderColor: isError ? ERROR_COLOR : isOpen ? themeValues.selectedColor : GREY_CHATEAU,
|
|
19668
|
-
borderRadius: "2px",
|
|
19669
|
-
tabIndex: 0,
|
|
19661
|
+
title: hasTitles ? getSelection() : null,
|
|
19670
19662
|
dataQa: placeholder,
|
|
19671
|
-
|
|
19663
|
+
tabIndex: 0,
|
|
19664
|
+
borderRadius: "2px",
|
|
19665
|
+
borderSize: "1px",
|
|
19666
|
+
borderColor: isError ? ERROR_COLOR : isOpen ? themeValues.selectedColor : GREY_CHATEAU
|
|
19672
19667
|
}, /*#__PURE__*/React__default.createElement(Stack, {
|
|
19673
19668
|
direction: "row",
|
|
19674
19669
|
bottomItem: 2,
|
|
@@ -19678,7 +19673,8 @@ var Dropdown = function Dropdown(_ref8) {
|
|
|
19678
19673
|
placeholder: getSelection(),
|
|
19679
19674
|
value: inputValue,
|
|
19680
19675
|
onChange: function onChange(e) {
|
|
19681
|
-
console.log("input change event", e);
|
|
19676
|
+
console.log("input change event", e.target);
|
|
19677
|
+
console.log("input change event value", e.target.value);
|
|
19682
19678
|
},
|
|
19683
19679
|
themeValues: themeValues,
|
|
19684
19680
|
role: "searchbox",
|
|
@@ -19693,7 +19689,7 @@ var Dropdown = function Dropdown(_ref8) {
|
|
|
19693
19689
|
autocomplete: autocompleteValue
|
|
19694
19690
|
}), /*#__PURE__*/React__default.createElement(IconWrapper, {
|
|
19695
19691
|
open: isOpen
|
|
19696
|
-
}, /*#__PURE__*/React__default.createElement(DropdownIcon, null)))
|
|
19692
|
+
}, /*#__PURE__*/React__default.createElement(DropdownIcon, null))), isOpen ? /*#__PURE__*/React__default.createElement(DropdownContentWrapper, {
|
|
19697
19693
|
maxHeight: maxHeight,
|
|
19698
19694
|
open: isOpen,
|
|
19699
19695
|
ref: dropdownRef,
|