@scbt-ecom/ui 0.76.1 → 0.76.3
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-F-RYAmDP.js.map +1 -1
- package/dist/lib/shared/ui/button/model/helpers.d.ts +1 -1
- package/dist/lib/shared/ui/formElements/uncontrolled/dayPicker/DayPicker.d.ts +1 -1
- package/dist/lib/shared/ui/formElements/uncontrolled/index.d.ts +3 -3
- package/dist/lib/shared/ui/formElements/uncontrolled/select/Select.d.ts +1 -1
- package/dist/lib/shared/ui/formElements/uncontrolled/select/ui/SelectItem.d.ts +1 -1
- package/dist/lib/shared/ui/formElements/uncontrolled/textarea/Textarea.d.ts +1 -1
- package/dist/lib/widgets/banner/Banner.d.ts +1 -0
- package/dist/lib/widgets/benefit/Benefit.d.ts +1 -0
- package/dist/lib/widgets/benefit/index.d.ts +1 -1
- package/dist/lib/widgets/calculator/Calculator.d.ts +1 -0
- package/dist/lib/widgets/dynamicForm/DynamicForm.d.ts +1 -1
- package/dist/lib/widgets/footer/Footer.d.ts +1 -0
- package/dist/lib/widgets/header/Header.d.ts +1 -0
- package/dist/lib/widgets/interLinking/InterLinking.d.ts +1 -0
- package/dist/lib/widgets/longBanner/LongBanner.d.ts +1 -0
- package/dist/lib/widgets/model/helpers.d.ts +12 -12
- package/dist/lib/widgets/model/types.d.ts +6 -7
- package/dist/lib/widgets/seoHeader/SeoHeader.d.ts +1 -0
- package/dist/lib/widgets/stepper/Stepper.d.ts +1 -0
- package/dist/lib/widgets/usefulInfo/UsefulInfo.d.ts +1 -0
- package/dist/widget.js +1884 -1840
- package/dist/widget.js.map +1 -1
- package/package.json +1 -1
|
@@ -20,7 +20,7 @@ export declare const buttonPrimitiveIntent: {
|
|
|
20
20
|
export declare const buttonConfig: (props?: ({
|
|
21
21
|
intent?: "primary" | "secondary" | "ghost" | "negative" | null | undefined;
|
|
22
22
|
size?: "md" | "sm" | "lg" | null | undefined;
|
|
23
|
-
textFormat?: "
|
|
23
|
+
textFormat?: "capitalize" | "uppercase" | "lowercase" | "initial" | null | undefined;
|
|
24
24
|
isFull?: boolean | null | undefined;
|
|
25
25
|
isLoading?: boolean | null | undefined;
|
|
26
26
|
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
@@ -32,7 +32,7 @@ export type DayPickerProps = Omit<MaskInputProps, 'value' | 'onChange' | 'mask'
|
|
|
32
32
|
*/
|
|
33
33
|
externalHandlers?: ExternalHandlers;
|
|
34
34
|
};
|
|
35
|
-
export declare const DayPickerBase: import('react').ForwardRefExoticComponent<Omit<MaskInputProps, "
|
|
35
|
+
export declare const DayPickerBase: import('react').ForwardRefExoticComponent<Omit<MaskInputProps, "classes" | "value" | "onChange" | "mask"> & {
|
|
36
36
|
/**
|
|
37
37
|
* Указывает, открыт ли календарь по умолчанию
|
|
38
38
|
*/
|
|
@@ -43,7 +43,7 @@ export declare const Uncontrolled: {
|
|
|
43
43
|
mask: "datetime" | "email" | "numeric" | "currency" | "decimal" | "integer" | "percentage" | "url" | "ip" | "mac" | "ssn" | "brl-currency" | "cpf" | "cnpj" | (string & {}) | (string[] & {}) | null;
|
|
44
44
|
externalMaskDefinitions?: Record<string, import('./maskInput/MaskInput').Definition>;
|
|
45
45
|
} & import('react').RefAttributes<HTMLInputElement>>;
|
|
46
|
-
SelectBase: import('react').ForwardRefExoticComponent<Omit<import('@headlessui/react').ComboboxProps<import('./select').SelectItemOption, boolean, "li">, "
|
|
46
|
+
SelectBase: import('react').ForwardRefExoticComponent<Omit<import('@headlessui/react').ComboboxProps<import('./select').SelectItemOption, boolean, "li">, "className" | "onChange" | "by" | "multiple" | "virtual"> & {
|
|
47
47
|
label: string;
|
|
48
48
|
isMulti?: boolean | undefined;
|
|
49
49
|
invalid?: boolean;
|
|
@@ -71,7 +71,7 @@ export declare const Uncontrolled: {
|
|
|
71
71
|
onFocus?: (event: React.FocusEvent<HTMLButtonElement>) => void;
|
|
72
72
|
};
|
|
73
73
|
} & import('react').RefAttributes<HTMLButtonElement>>;
|
|
74
|
-
DayPickerBase: import('react').ForwardRefExoticComponent<Omit<import('./maskInput').MaskInputProps, "
|
|
74
|
+
DayPickerBase: import('react').ForwardRefExoticComponent<Omit<import('./maskInput').MaskInputProps, "classes" | "value" | "onChange" | "mask"> & {
|
|
75
75
|
defaultOpen?: boolean;
|
|
76
76
|
value?: string;
|
|
77
77
|
onChange?: (value: string) => void;
|
|
@@ -109,7 +109,7 @@ export declare const Uncontrolled: {
|
|
|
109
109
|
};
|
|
110
110
|
renderComponent?: (props: import('./radio').RadioGroupBaseProps) => React.JSX.Element;
|
|
111
111
|
} & import('react').RefAttributes<HTMLDivElement>>;
|
|
112
|
-
TextareaBase: import('react').ForwardRefExoticComponent<Omit<import('react').TextareaHTMLAttributes<HTMLTextAreaElement>, "
|
|
112
|
+
TextareaBase: import('react').ForwardRefExoticComponent<Omit<import('react').TextareaHTMLAttributes<HTMLTextAreaElement>, "className" | "size"> & {
|
|
113
113
|
classes?: {
|
|
114
114
|
container?: string;
|
|
115
115
|
textarea?: string;
|
|
@@ -81,7 +81,7 @@ export type SelectBaseProps<Multi extends boolean> = Omit<ComboboxProps<SelectIt
|
|
|
81
81
|
*/
|
|
82
82
|
reset?: string;
|
|
83
83
|
};
|
|
84
|
-
export declare const SelectBase: import('react').ForwardRefExoticComponent<Omit<ComboboxProps<SelectItemOption, boolean, "li">, "
|
|
84
|
+
export declare const SelectBase: import('react').ForwardRefExoticComponent<Omit<ComboboxProps<SelectItemOption, boolean, "li">, "className" | "onChange" | "by" | "multiple" | "virtual"> & {
|
|
85
85
|
/**
|
|
86
86
|
* Отображаемый лейбл
|
|
87
87
|
*/
|
|
@@ -15,7 +15,7 @@ export type SelectItemProps = Omit<ComboboxOptionProps, 'className' | 'value'> &
|
|
|
15
15
|
displayValue?: (option: SelectItemOption) => string;
|
|
16
16
|
motionProps?: React.ComponentPropsWithoutRef<typeof motion.li>;
|
|
17
17
|
};
|
|
18
|
-
export declare const SelectItem: React.ForwardRefExoticComponent<Omit<ComboboxOptionProps, "
|
|
18
|
+
export declare const SelectItem: React.ForwardRefExoticComponent<Omit<ComboboxOptionProps, "className" | "value"> & {
|
|
19
19
|
option: SelectItemOption;
|
|
20
20
|
isMulti?: boolean;
|
|
21
21
|
classes?: SelectItemClasses;
|
|
@@ -34,7 +34,7 @@ export type TextareaBaseProps = Omit<React.TextareaHTMLAttributes<HTMLTextAreaEl
|
|
|
34
34
|
*/
|
|
35
35
|
externalHandlers?: ExternalHandlers;
|
|
36
36
|
};
|
|
37
|
-
export declare const TextareaBase: import('react').ForwardRefExoticComponent<Omit<import('react').TextareaHTMLAttributes<HTMLTextAreaElement>, "
|
|
37
|
+
export declare const TextareaBase: import('react').ForwardRefExoticComponent<Omit<import('react').TextareaHTMLAttributes<HTMLTextAreaElement>, "className" | "size"> & {
|
|
38
38
|
/**
|
|
39
39
|
* Дополнительные стили внутренних компонентов
|
|
40
40
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export
|
|
1
|
+
export * from './Benefit';
|
|
@@ -38,4 +38,4 @@ export type DynamicFormProps<AType extends ApprovementType, CType extends ChipsT
|
|
|
38
38
|
classes?: DynamicFormClasses;
|
|
39
39
|
};
|
|
40
40
|
export declare const DynamicForm: <AType extends ApprovementType, CType extends ChipsType, PType extends ProgressType>({ fields, title, progress, approvement, chips, submitProps, classes }: DynamicFormProps<AType, CType, PType>) => import("react/jsx-runtime").JSX.Element;
|
|
41
|
-
export
|
|
41
|
+
export default DynamicForm;
|
|
@@ -10,3 +10,4 @@ export interface FooterProps<Enabled extends boolean> {
|
|
|
10
10
|
classes?: FooterClasses;
|
|
11
11
|
}
|
|
12
12
|
export declare const Footer: <Enabled extends boolean>({ socialsLinks, phones, ligal, copyright, classes, details, siteMap }: FooterProps<Enabled>) => import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
export default Footer;
|
|
@@ -14,3 +14,4 @@ export interface InterLinkingProps extends InterLinkingRoot {
|
|
|
14
14
|
defaultOpen?: boolean;
|
|
15
15
|
}
|
|
16
16
|
export declare const InterLinking: ({ variant, details, headline, mobileAccordionProps, rootAccordionProps, classes, defaultOpen }: InterLinkingProps) => import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
export default InterLinking;
|
|
@@ -9,3 +9,4 @@ export interface LongBannerProps<Enabled extends boolean> extends LongBannerConf
|
|
|
9
9
|
classes?: LongBannerClasses;
|
|
10
10
|
}
|
|
11
11
|
export declare const LongBanner: <Enabled extends boolean>({ headline, buttonConfig, intent, details, image, classes }: LongBannerProps<Enabled>) => import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
export default LongBanner;
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
|
|
1
|
+
export type AllowedWidgets = keyof typeof WIDGET_LIST_MAP;
|
|
2
2
|
export declare const WIDGET_LIST_MAP: {
|
|
3
|
-
readonly header: <Type extends import('../header/model/types').HeaderVariantType>(props: import('../header/model/types').HeaderProps<Type>) => import("react/jsx-runtime").JSX.Element
|
|
4
|
-
readonly seoHeader: ({ categories, helpers, phone }: import('..').SeoHeaderProps) => import("react/jsx-runtime").JSX.Element
|
|
5
|
-
readonly banner: ({ variant, ...props }: import('..').BannerProps) => import("react/jsx-runtime").JSX.Element
|
|
6
|
-
readonly calculator: ({ calculators, headline }: import('..').CalculatorProps) => import("react/jsx-runtime").JSX.Element
|
|
7
|
-
readonly form: <AType extends import('../dynamicForm/model').ApprovementType, CType extends import('../dynamicForm/model').ChipsType, PType extends import('../dynamicForm/model').ProgressType>({ fields, title, progress, approvement, chips, submitProps, classes }: import('..').DynamicFormProps<AType, CType, PType>) => import("react/jsx-runtime").JSX.Element
|
|
8
|
-
readonly stepper: ({ headline, details, variant, classes }: import('..').StepperProps) => import("react/jsx-runtime").JSX.Element
|
|
9
|
-
readonly benefit: ({ headline, details, variant, classes }: import('..').BenefitProps) => import("react/jsx-runtime").JSX.Element
|
|
10
|
-
readonly longBanner: <Enabled extends boolean>({ headline, buttonConfig, intent, details, image, classes }: import('..').LongBannerProps<Enabled>) => import("react/jsx-runtime").JSX.Element
|
|
11
|
-
readonly usefulInfo: ({ headline, tabs, classes, accordionsConfig }: import('..').UsefulInfoProps) => import("react/jsx-runtime").JSX.Element | null
|
|
12
|
-
readonly interLinking: ({ variant, details, headline, mobileAccordionProps, rootAccordionProps, classes, defaultOpen }: import('..').InterLinkingProps) => import("react/jsx-runtime").JSX.Element
|
|
13
|
-
readonly footer: <Enabled extends boolean>({ socialsLinks, phones, ligal, copyright, classes, details, siteMap }: import('..').FooterProps<Enabled>) => import("react/jsx-runtime").JSX.Element
|
|
3
|
+
readonly header: import('react').LazyExoticComponent<(<Type extends import('../header/model/types').HeaderVariantType>(props: import('../header/model/types').HeaderProps<Type>) => import("react/jsx-runtime").JSX.Element)>;
|
|
4
|
+
readonly seoHeader: import('react').LazyExoticComponent<({ categories, helpers, phone }: import('..').SeoHeaderProps) => import("react/jsx-runtime").JSX.Element>;
|
|
5
|
+
readonly banner: import('react').LazyExoticComponent<({ variant, ...props }: import('..').BannerProps) => import("react/jsx-runtime").JSX.Element>;
|
|
6
|
+
readonly calculator: import('react').LazyExoticComponent<({ calculators, headline }: import('..').CalculatorProps) => import("react/jsx-runtime").JSX.Element>;
|
|
7
|
+
readonly form: import('react').LazyExoticComponent<(<AType extends import('../dynamicForm/model').ApprovementType, CType extends import('../dynamicForm/model').ChipsType, PType extends import('../dynamicForm/model').ProgressType>({ fields, title, progress, approvement, chips, submitProps, classes }: import('..').DynamicFormProps<AType, CType, PType>) => import("react/jsx-runtime").JSX.Element)>;
|
|
8
|
+
readonly stepper: import('react').LazyExoticComponent<({ headline, details, variant, classes }: import('..').StepperProps) => import("react/jsx-runtime").JSX.Element>;
|
|
9
|
+
readonly benefit: import('react').LazyExoticComponent<({ headline, details, variant, classes }: import('..').BenefitProps) => import("react/jsx-runtime").JSX.Element>;
|
|
10
|
+
readonly longBanner: import('react').LazyExoticComponent<(<Enabled extends boolean>({ headline, buttonConfig, intent, details, image, classes }: import('..').LongBannerProps<Enabled>) => import("react/jsx-runtime").JSX.Element)>;
|
|
11
|
+
readonly usefulInfo: import('react').LazyExoticComponent<({ headline, tabs, classes, accordionsConfig }: import('..').UsefulInfoProps) => import("react/jsx-runtime").JSX.Element | null>;
|
|
12
|
+
readonly interLinking: import('react').LazyExoticComponent<({ variant, details, headline, mobileAccordionProps, rootAccordionProps, classes, defaultOpen }: import('..').InterLinkingProps) => import("react/jsx-runtime").JSX.Element>;
|
|
13
|
+
readonly footer: import('react').LazyExoticComponent<(<Enabled extends boolean>({ socialsLinks, phones, ligal, copyright, classes, details, siteMap }: import('..').FooterProps<Enabled>) => import("react/jsx-runtime").JSX.Element)>;
|
|
14
14
|
};
|
|
15
15
|
export declare const KEYS_OF_WIDGET_LIST: readonly AllowedWidgets[];
|
|
16
16
|
export declare const widgetIds: Record<"form" | "header" | "seoHeader" | "banner" | "calculator" | "stepper" | "benefit" | "longBanner" | "usefulInfo" | "interLinking" | "footer", "form" | "header" | "seoHeader" | "banner" | "calculator" | "stepper" | "benefit" | "longBanner" | "usefulInfo" | "interLinking" | "footer">;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { ComponentPropsWithoutRef } from 'react';
|
|
2
|
-
import { WIDGET_LIST_MAP } from './helpers';
|
|
3
|
-
export type AllowedWidgets = keyof typeof WIDGET_LIST_MAP;
|
|
2
|
+
import { AllowedWidgets, WIDGET_LIST_MAP } from './helpers';
|
|
4
3
|
export type WidgetExternalProps = {
|
|
5
4
|
_id: string;
|
|
6
5
|
internalName: string;
|
|
@@ -11,7 +10,7 @@ export type WidgetExternalProps = {
|
|
|
11
10
|
* export type HeaderWidget = ReturnWidgetType['header']
|
|
12
11
|
*/
|
|
13
12
|
export type ReturnWidgetType = {
|
|
14
|
-
[K in
|
|
13
|
+
[K in AllowedWidgets]: ComponentPropsWithoutRef<(typeof WIDGET_LIST_MAP)[K]> & WidgetExternalProps;
|
|
15
14
|
};
|
|
16
15
|
/**
|
|
17
16
|
* Массив кортежей из виджетов
|
|
@@ -22,8 +21,8 @@ export type ReturnWidgetType = {
|
|
|
22
21
|
* ]
|
|
23
22
|
*/
|
|
24
23
|
export type WidgetsListDTO = {
|
|
25
|
-
[K in
|
|
26
|
-
}[
|
|
24
|
+
[K in AllowedWidgets]: [K, ReturnWidgetType[K]];
|
|
25
|
+
}[AllowedWidgets][];
|
|
27
26
|
/**
|
|
28
27
|
* Массив кортежей из id виджетов или null (значение по умолчанию или сброс значения)
|
|
29
28
|
* @example
|
|
@@ -33,5 +32,5 @@ export type WidgetsListDTO = {
|
|
|
33
32
|
* ]
|
|
34
33
|
*/
|
|
35
34
|
export type WidgetsListDTOIds = {
|
|
36
|
-
[K in
|
|
37
|
-
}[
|
|
35
|
+
[K in AllowedWidgets]: [K, string | null];
|
|
36
|
+
}[AllowedWidgets][];
|