@thecb/components 8.4.8-beta.4 → 8.4.8-beta.6
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 +18 -11
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.ts +23 -1
- package/dist/index.esm.js +18 -11
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/atoms/index.d.ts +1 -0
- package/src/components/atoms/searchable-select/index.d.ts +24 -0
- package/src/components/molecules/module/Module.js +15 -8
- package/src/types/common/SearchableSelectOption.ts +4 -0
- package/src/types/common/index.ts +1 -0
package/dist/index.d.ts
CHANGED
|
@@ -429,6 +429,11 @@ interface FormSelectOption {
|
|
|
429
429
|
value?: string;
|
|
430
430
|
}
|
|
431
431
|
|
|
432
|
+
interface SearchableSelectOption {
|
|
433
|
+
name?: string;
|
|
434
|
+
value?: string;
|
|
435
|
+
}
|
|
436
|
+
|
|
432
437
|
interface ErrorMessageDictionary {
|
|
433
438
|
[fieldName: string]: string;
|
|
434
439
|
}
|
|
@@ -814,6 +819,23 @@ interface ParagraphProps {
|
|
|
814
819
|
declare const Paragraph: React.FC<Expand<ParagraphProps> &
|
|
815
820
|
React.HTMLAttributes<HTMLElement>>;
|
|
816
821
|
|
|
822
|
+
interface SearchableSelectProps {
|
|
823
|
+
items: SearchableSelectOption[];
|
|
824
|
+
selectedItems: SearchableSelectOption[];
|
|
825
|
+
allSelected: boolean;
|
|
826
|
+
toggleSelectAllItems: (isSelectAll: boolean) => void;
|
|
827
|
+
selectItem: (item: SearchableSelectOption) => void;
|
|
828
|
+
fields: {
|
|
829
|
+
searchTerm: Field;
|
|
830
|
+
};
|
|
831
|
+
actions: FieldActions;
|
|
832
|
+
disabled?: boolean;
|
|
833
|
+
placeholder: string;
|
|
834
|
+
}
|
|
835
|
+
|
|
836
|
+
declare const SearchableSelect: React.FC<Expand<SearchableSelectProps> &
|
|
837
|
+
React.HTMLAttributes<HTMLElement>>;
|
|
838
|
+
|
|
817
839
|
interface SpinnerProps {
|
|
818
840
|
size?: string;
|
|
819
841
|
centerSpinner?: boolean;
|
|
@@ -1036,5 +1058,5 @@ interface DefaultPageTemplateProps {
|
|
|
1036
1058
|
declare const DefaultPageTemplate: React.FC<Expand<DefaultPageTemplateProps> &
|
|
1037
1059
|
React.HTMLAttributes<HTMLElement>>;
|
|
1038
1060
|
|
|
1039
|
-
export { AddValidatorAction, Alert, AlertProps, ArrowDownCircleIconSmall, ArrowDownCircleIconSmallProps, ArrowLeftCircleIconMedium, ArrowLeftCircleIconMediumProps, ArrowLeftCircleIconSmall, ArrowLeftCircleIconSmallProps, ArrowRightCircleIconSmall, ArrowRightCircleIconSmallProps, ArrowUpCircleIconSmall, ArrowUpCircleIconSmallProps, BankIconLarge, BankIconLargeProps, Box, BoxProps, ButtonWithAction, ButtonWithActionProps, ButtonWithLink, ButtonWithLinkProps, Card, CardProps, Center, CenterProps, ChargebackIconMedium, ChargebackIconMediumProps, ChargebackIconSmall, ChargebackIconSmallProps, ChargebackReversalIconMedium, ChargebackReversalIconMediumProps, ChargebackReversalIconSmall, ChargebackReversalIconSmallProps, ClearAction, Cluster, ClusterProps, CollapsibleSection, CollapsibleSectionProps, Copyable, CopyableProps, Cover, CoverProps, DefaultPageTemplate, DefaultPageTemplateProps, EditableTable, EditableTableProps, ErrorMessageDictionary, ExternalLink, ExternalLinkProps, Field, FieldActionPayload, FieldActions, FooterWithSubfooter, FooterWithSubfooterProps, FormInput, FormInputProps, FormSelect, FormSelectOption, FormSelectProps, GuidedCheckoutImage, HistoryIconSmall, InternalLink, InternalLinkProps, KioskImage, Loading, LoadingProps, NavFooter, NavFooterProps, NavHeader, NavHeaderProps, NavTabs, NavTabsProps, Paragraph, ParagraphProps, PointOfSaleImage, Popover, PopoverProps, ProfileImage, RadioGroup, RadioGroupProps, ReduxAction, RefundIconMedium, RefundIconMediumProps, RefundIconSmall, RefundIconSmallProps, RemoveValidatorAction, RevenueManagementImage, SetAction, Spinner, SpinnerProps, Stack, StackProps, StandardCheckoutImage, SuccessfulIconMedium, SuccessfulIconMediumProps, SuccessfulIconSmall, SuccessfulIconSmallProps, Switcher, SwitcherProps, Table, TableBody, TableBodyProps, TableCell, TableCellProps, TableHead, TableHeadProps, TableHeading, TableHeadingProps, TableListItem, TableListItemProps, TableProps, TableRow, TableRowProps, Text, TextProps, Title, TitleProps, ValidatorFn, XCircleIconMedium, XCircleIconMediumProps, XCircleIconSmall, XCircleIconSmallProps, index_d as constants };
|
|
1061
|
+
export { AddValidatorAction, Alert, AlertProps, ArrowDownCircleIconSmall, ArrowDownCircleIconSmallProps, ArrowLeftCircleIconMedium, ArrowLeftCircleIconMediumProps, ArrowLeftCircleIconSmall, ArrowLeftCircleIconSmallProps, ArrowRightCircleIconSmall, ArrowRightCircleIconSmallProps, ArrowUpCircleIconSmall, ArrowUpCircleIconSmallProps, BankIconLarge, BankIconLargeProps, Box, BoxProps, ButtonWithAction, ButtonWithActionProps, ButtonWithLink, ButtonWithLinkProps, Card, CardProps, Center, CenterProps, ChargebackIconMedium, ChargebackIconMediumProps, ChargebackIconSmall, ChargebackIconSmallProps, ChargebackReversalIconMedium, ChargebackReversalIconMediumProps, ChargebackReversalIconSmall, ChargebackReversalIconSmallProps, ClearAction, Cluster, ClusterProps, CollapsibleSection, CollapsibleSectionProps, Copyable, CopyableProps, Cover, CoverProps, DefaultPageTemplate, DefaultPageTemplateProps, EditableTable, EditableTableProps, ErrorMessageDictionary, ExternalLink, ExternalLinkProps, Field, FieldActionPayload, FieldActions, FooterWithSubfooter, FooterWithSubfooterProps, FormInput, FormInputProps, FormSelect, FormSelectOption, FormSelectProps, GuidedCheckoutImage, HistoryIconSmall, InternalLink, InternalLinkProps, KioskImage, Loading, LoadingProps, NavFooter, NavFooterProps, NavHeader, NavHeaderProps, NavTabs, NavTabsProps, Paragraph, ParagraphProps, PointOfSaleImage, Popover, PopoverProps, ProfileImage, RadioGroup, RadioGroupProps, ReduxAction, RefundIconMedium, RefundIconMediumProps, RefundIconSmall, RefundIconSmallProps, RemoveValidatorAction, RevenueManagementImage, SearchableSelect, SearchableSelectOption, SearchableSelectProps, SetAction, Spinner, SpinnerProps, Stack, StackProps, StandardCheckoutImage, SuccessfulIconMedium, SuccessfulIconMediumProps, SuccessfulIconSmall, SuccessfulIconSmallProps, Switcher, SwitcherProps, Table, TableBody, TableBodyProps, TableCell, TableCellProps, TableHead, TableHeadProps, TableHeading, TableHeadingProps, TableListItem, TableListItemProps, TableProps, TableRow, TableRowProps, Text, TextProps, Title, TitleProps, ValidatorFn, XCircleIconMedium, XCircleIconMediumProps, XCircleIconSmall, XCircleIconSmallProps, index_d as constants };
|
|
1040
1062
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.esm.js
CHANGED
|
@@ -46805,28 +46805,30 @@ var fallbackValues$J = {
|
|
|
46805
46805
|
*/
|
|
46806
46806
|
|
|
46807
46807
|
var Module = function Module(_ref) {
|
|
46808
|
-
var
|
|
46808
|
+
var _ref$variant = _ref.variant,
|
|
46809
|
+
variant = _ref$variant === void 0 ? "default" : _ref$variant,
|
|
46810
|
+
as = _ref.as,
|
|
46811
|
+
disabled = _ref.disabled,
|
|
46812
|
+
heading = _ref.heading,
|
|
46813
|
+
rightTitleContent = _ref.rightTitleContent,
|
|
46814
|
+
_ref$titleID = _ref.titleID,
|
|
46815
|
+
titleID = _ref$titleID === void 0 ? "" : _ref$titleID,
|
|
46809
46816
|
_ref$spacing = _ref.spacing,
|
|
46810
46817
|
spacing = _ref$spacing === void 0 ? "1rem" : _ref$spacing,
|
|
46811
46818
|
_ref$padding = _ref.padding,
|
|
46812
46819
|
padding = _ref$padding === void 0 ? "0" : _ref$padding,
|
|
46813
|
-
_ref$spacingBottom = _ref.spacingBottom,
|
|
46814
|
-
spacingBottom = _ref$spacingBottom === void 0 ? "2.5rem" : _ref$spacingBottom,
|
|
46815
46820
|
_ref$margin = _ref.margin,
|
|
46816
46821
|
margin = _ref$margin === void 0 ? "0" : _ref$margin,
|
|
46817
|
-
|
|
46818
|
-
_ref$
|
|
46819
|
-
variant = _ref$variant === void 0 ? "default" : _ref$variant,
|
|
46822
|
+
_ref$spacingBottom = _ref.spacingBottom,
|
|
46823
|
+
spacingBottom = _ref$spacingBottom === void 0 ? "2.5rem" : _ref$spacingBottom,
|
|
46820
46824
|
fontSize = _ref.fontSize,
|
|
46821
|
-
|
|
46822
|
-
_ref$titleID = _ref.titleID,
|
|
46823
|
-
titleID = _ref$titleID === void 0 ? "" : _ref$titleID,
|
|
46824
|
-
rightTitleContent = _ref.rightTitleContent,
|
|
46825
|
+
themeValues = _ref.themeValues,
|
|
46825
46826
|
children = _ref.children;
|
|
46826
46827
|
var themedFontSize = variant === "small" ? "1.25rem" : variant === "default" ? "1.375rem" : "2rem";
|
|
46827
46828
|
var computedFontSize = fontSize || themedFontSize;
|
|
46828
46829
|
var themedElemType = variant === "small" ? "h6" : variant === "default" ? "h5" : "h2";
|
|
46829
46830
|
var computedElemType = as || themedElemType;
|
|
46831
|
+
var disabledStyles = 'opacity: 0.40;"';
|
|
46830
46832
|
var headingText = /*#__PURE__*/React.createElement(Title$1, {
|
|
46831
46833
|
weight: themeValues.fontWeight,
|
|
46832
46834
|
color: themeValues.fontColor,
|
|
@@ -46836,7 +46838,12 @@ var Module = function Module(_ref) {
|
|
|
46836
46838
|
extraStyles: "font-size: ".concat(computedFontSize, ";"),
|
|
46837
46839
|
id: titleID
|
|
46838
46840
|
}, heading);
|
|
46839
|
-
return /*#__PURE__*/React.createElement(
|
|
46841
|
+
return /*#__PURE__*/React.createElement(Box, {
|
|
46842
|
+
"aria-disabled": "true",
|
|
46843
|
+
extraStyles: disabled && disabledStyles,
|
|
46844
|
+
padding: "0",
|
|
46845
|
+
role: "group"
|
|
46846
|
+
}, heading && !rightTitleContent && headingText, heading && rightTitleContent && /*#__PURE__*/React.createElement(Cluster, {
|
|
46840
46847
|
justify: "space-between",
|
|
46841
46848
|
align: "center",
|
|
46842
46849
|
nowrap: true
|