@thecb/components 9.0.6-beta.3 → 9.0.8-beta.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/dist/index.cjs.js +14 -19
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +14 -19
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/atoms/dropdown/Dropdown.js +5 -5
- package/src/components/atoms/form-layouts/FormInput.js +1 -1
- package/src/components/atoms/form-select/FormSelect.js +2 -4
- package/src/components/atoms/form-select/FormSelect.stories.js +8 -4
- package/src/components/atoms/icons/icons.stories.js +0 -2
- package/src/components/atoms/layouts/Box.js +2 -0
- package/src/components/atoms/searchable-select/SearchableSelect.js +2 -0
- package/src/components/atoms/searchable-select/SearchableSelect.stories.js +61 -0
- package/src/components/atoms/state-province-dropdown/StateProvinceDropdown.js +2 -3
- package/src/components/atoms/state-province-dropdown/StateProvinceDropdown.stories.js +1 -0
- package/src/components/molecules/address-form/AddressForm.js +0 -1
- /package/src/components/atoms/icons/{ExternalLinkicon.js → ExternalLinkIcon.js} +0 -0
package/dist/index.cjs.js
CHANGED
|
@@ -6530,7 +6530,7 @@ var BoxWrapper = styled__default(function (_ref) {
|
|
|
6530
6530
|
});
|
|
6531
6531
|
/* eslint-enable no-unused-vars */
|
|
6532
6532
|
|
|
6533
|
-
var _excluded$3 = ["padding", "borderSize", "borderColor", "borderRadius", "boxShadow", "background", "color", "minHeight", "width", "minWidth", "maxWidth", "borderWidthOverride", "border", "textAlign", "hoverStyles", "activeStyles", "disabledStyles", "variant", "as", "onClick", "onKeyDown", "onMouseEnter", "onMouseLeave", "onFocus", "onBlur", "onTouchEnd", "theme", "hiddenStyles", "extraStyles", "srOnly", "dataQa", "children"];
|
|
6533
|
+
var _excluded$3 = ["autocompleteValue", "padding", "borderSize", "borderColor", "borderRadius", "boxShadow", "background", "color", "minHeight", "width", "minWidth", "maxWidth", "borderWidthOverride", "border", "textAlign", "hoverStyles", "activeStyles", "disabledStyles", "variant", "as", "onClick", "onKeyDown", "onMouseEnter", "onMouseLeave", "onFocus", "onBlur", "onTouchEnd", "theme", "hiddenStyles", "extraStyles", "srOnly", "dataQa", "children"];
|
|
6534
6534
|
/*
|
|
6535
6535
|
Box component to create generic boxes
|
|
6536
6536
|
Supply padding, border, background, and color values
|
|
@@ -6540,7 +6540,8 @@ var _excluded$3 = ["padding", "borderSize", "borderColor", "borderRadius", "boxS
|
|
|
6540
6540
|
*/
|
|
6541
6541
|
|
|
6542
6542
|
var Box = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
6543
|
-
var
|
|
6543
|
+
var autocompleteValue = _ref.autocompleteValue,
|
|
6544
|
+
_ref$padding = _ref.padding,
|
|
6544
6545
|
padding = _ref$padding === void 0 ? "16px" : _ref$padding,
|
|
6545
6546
|
_ref$borderSize = _ref.borderSize,
|
|
6546
6547
|
borderSize = _ref$borderSize === void 0 ? "0px" : _ref$borderSize,
|
|
@@ -6580,6 +6581,7 @@ var Box = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
6580
6581
|
rest = _objectWithoutProperties(_ref, _excluded$3);
|
|
6581
6582
|
|
|
6582
6583
|
return /*#__PURE__*/React__default.createElement(BoxWrapper, _extends({
|
|
6584
|
+
autoComplete: autocompleteValue,
|
|
6583
6585
|
padding: padding,
|
|
6584
6586
|
borderSize: borderSize,
|
|
6585
6587
|
borderColor: borderColor,
|
|
@@ -23758,8 +23760,7 @@ var Dropdown = function Dropdown(_ref8) {
|
|
|
23758
23760
|
autoEraseTypeAhead = _ref8$autoEraseTypeAh === void 0 ? true : _ref8$autoEraseTypeAh,
|
|
23759
23761
|
ariaLabelledby = _ref8.ariaLabelledby,
|
|
23760
23762
|
ariaDescribedby = _ref8.ariaDescribedby,
|
|
23761
|
-
|
|
23762
|
-
autocompleteValue = _ref8$autocompleteVal === void 0 ? null : _ref8$autocompleteVal,
|
|
23763
|
+
autocompleteValue = _ref8.autocompleteValue,
|
|
23763
23764
|
_ref8$smoothScroll = _ref8.smoothScroll,
|
|
23764
23765
|
smoothScroll = _ref8$smoothScroll === void 0 ? true : _ref8$smoothScroll,
|
|
23765
23766
|
_ref8$ariaInvalid = _ref8.ariaInvalid,
|
|
@@ -24088,7 +24089,7 @@ var Dropdown = function Dropdown(_ref8) {
|
|
|
24088
24089
|
}, /*#__PURE__*/React__default.createElement(Text$1, {
|
|
24089
24090
|
variant: "p",
|
|
24090
24091
|
color: choice.value === value ? WHITE : disabledValues.includes(choice.value) ? STORM_GREY : MINESHAFT_GREY,
|
|
24091
|
-
extraStyles: "padding-left: 16px
|
|
24092
|
+
extraStyles: "padding-left: 16px;\n cursor: ".concat(disabledValues.includes(choice.value) ? "default" : "pointer", ";\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;")
|
|
24092
24093
|
}, choice.text));
|
|
24093
24094
|
}))) : /*#__PURE__*/React__default.createElement(React.Fragment, null)));
|
|
24094
24095
|
};
|
|
@@ -24192,14 +24193,11 @@ var FormSelect = function FormSelect(_ref) {
|
|
|
24192
24193
|
themeValues = _ref.themeValues,
|
|
24193
24194
|
_ref$hasTitles = _ref.hasTitles,
|
|
24194
24195
|
hasTitles = _ref$hasTitles === void 0 ? false : _ref$hasTitles,
|
|
24195
|
-
|
|
24196
|
-
autocompleteValue = _ref$autocompleteValu === void 0 ? null : _ref$autocompleteValu,
|
|
24196
|
+
autocompleteValue = _ref.autocompleteValue,
|
|
24197
24197
|
_ref$smoothScroll = _ref.smoothScroll,
|
|
24198
24198
|
smoothScroll = _ref$smoothScroll === void 0 ? true : _ref$smoothScroll,
|
|
24199
24199
|
_ref$dataQa = _ref.dataQa,
|
|
24200
|
-
dataQa = _ref$dataQa === void 0 ? null : _ref$dataQa
|
|
24201
|
-
_ref$widthFitOptions = _ref.widthFitOptions,
|
|
24202
|
-
widthFitOptions = _ref$widthFitOptions === void 0 ? false : _ref$widthFitOptions;
|
|
24200
|
+
dataQa = _ref$dataQa === void 0 ? null : _ref$dataQa;
|
|
24203
24201
|
|
|
24204
24202
|
var _useState = React.useState(false),
|
|
24205
24203
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -24242,7 +24240,6 @@ var FormSelect = function FormSelect(_ref) {
|
|
|
24242
24240
|
ariaLabelledby: createIdFromString(labelTextWhenNoError),
|
|
24243
24241
|
ariaDescribedby: createIdFromString(labelTextWhenNoError, "error message"),
|
|
24244
24242
|
maxHeight: dropdownMaxHeight,
|
|
24245
|
-
widthFitOptions: widthFitOptions,
|
|
24246
24243
|
hasTitles: hasTitles,
|
|
24247
24244
|
placeholder: options[0] ? options[0].text : "",
|
|
24248
24245
|
options: options,
|
|
@@ -25968,8 +25965,7 @@ var FormInput = function FormInput(_ref15) {
|
|
|
25968
25965
|
themeValues = _ref15.themeValues,
|
|
25969
25966
|
background = _ref15.background,
|
|
25970
25967
|
customHeight = _ref15.customHeight,
|
|
25971
|
-
|
|
25972
|
-
autocompleteValue = _ref15$autocompleteVa === void 0 ? null : _ref15$autocompleteVa,
|
|
25968
|
+
autocompleteValue = _ref15.autocompleteValue,
|
|
25973
25969
|
extraStyles = _ref15.extraStyles,
|
|
25974
25970
|
removeFromValue = _ref15.removeFromValue,
|
|
25975
25971
|
_ref15$dataQa = _ref15.dataQa,
|
|
@@ -27324,7 +27320,8 @@ var fallbackValues$w = {
|
|
|
27324
27320
|
var SELECT_ALL = "Select All";
|
|
27325
27321
|
|
|
27326
27322
|
var SearchableSelect = function SearchableSelect(_ref) {
|
|
27327
|
-
var
|
|
27323
|
+
var autocompleteValue = _ref.autocompleteValue,
|
|
27324
|
+
items = _ref.items,
|
|
27328
27325
|
selectedItems = _ref.selectedItems,
|
|
27329
27326
|
allSelected = _ref.allSelected,
|
|
27330
27327
|
toggleSelectAllItems = _ref.toggleSelectAllItems,
|
|
@@ -27366,6 +27363,7 @@ var SearchableSelect = function SearchableSelect(_ref) {
|
|
|
27366
27363
|
border: themeValues.border,
|
|
27367
27364
|
extraStyles: disabled && "color: #6e727e; background-color: #f7f7f7; pointer-events: none;"
|
|
27368
27365
|
}, /*#__PURE__*/React__default.createElement(FormInput$1, {
|
|
27366
|
+
autocompleteValue: autocompleteValue,
|
|
27369
27367
|
errorMessages: {},
|
|
27370
27368
|
field: fields.searchTerm,
|
|
27371
27369
|
fieldActions: actions.fields.searchTerm,
|
|
@@ -37983,9 +37981,7 @@ var FormStateDropdown = function FormStateDropdown(_ref) {
|
|
|
37983
37981
|
field = _ref.field,
|
|
37984
37982
|
fieldActions = _ref.fieldActions,
|
|
37985
37983
|
showErrors = _ref.showErrors,
|
|
37986
|
-
countryCode = _ref.countryCode
|
|
37987
|
-
_ref$autocompleteValu = _ref.autocompleteValue,
|
|
37988
|
-
autocompleteValue = _ref$autocompleteValu === void 0 ? null : _ref$autocompleteValu;
|
|
37984
|
+
countryCode = _ref.countryCode;
|
|
37989
37985
|
var placeholder = countryCode === "US" ? placeHolderOptionUS : placeHolderOption;
|
|
37990
37986
|
var options = [placeholder].concat(_toConsumableArray(getOptions(countryCode)));
|
|
37991
37987
|
return /*#__PURE__*/React__default.createElement(FormSelect$1, {
|
|
@@ -37995,7 +37991,7 @@ var FormStateDropdown = function FormStateDropdown(_ref) {
|
|
|
37995
37991
|
labelTextWhenNoError: labelTextWhenNoError,
|
|
37996
37992
|
errorMessages: errorMessages,
|
|
37997
37993
|
showErrors: showErrors,
|
|
37998
|
-
autocompleteValue:
|
|
37994
|
+
autocompleteValue: "address-level1"
|
|
37999
37995
|
});
|
|
38000
37996
|
};
|
|
38001
37997
|
|
|
@@ -39377,7 +39373,6 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
39377
39373
|
onKeyDown: function onKeyDown(e) {
|
|
39378
39374
|
return e.key === "Enter" && handleSubmit(e);
|
|
39379
39375
|
},
|
|
39380
|
-
autocompleteValue: "address-level1",
|
|
39381
39376
|
dataQa: "State or Province"
|
|
39382
39377
|
}), /*#__PURE__*/React__default.createElement(FormInput$1, {
|
|
39383
39378
|
isNum: isUS,
|