@scbt-ecom/ui 0.166.1 → 0.167.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/lib/shared/ui/formElements/uncontrolled/slider/ui/sliderAlgorithmic/SliderAlgorithmic.js +1 -1
- package/dist/lib/shared/ui/formElements/uncontrolled/slider/ui/sliderAlgorithmic/hooks/useSliderAlgorithmic.js +1 -1
- package/dist/lib/shared/ui/formElements/uncontrolled/slider/ui/sliderAlgorithmic/hooks/useSliderAlgorithmic.js.map +1 -1
- package/dist/lib/shared/utils/variableHolder/variableContextHolder.js.map +1 -1
- package/dist/lib/shared/utils/variables/variableResolver.js.map +1 -1
- package/dist/lib/widgets/calculator/CalculatorView.js +1 -1
- package/dist/lib/widgets/calculator/CalculatorView.js.map +1 -1
- package/dist/lib/widgets/calculator/model/helpers.js +1 -1
- package/dist/lib/widgets/calculator/model/helpers.js.map +1 -1
- package/dist/lib/widgets/calculator/model/index.js +1 -1
- package/dist/lib/widgets/calculator/model/utils.js +1 -1
- package/dist/lib/widgets/calculator/model/utils.js.map +1 -1
- package/dist/lib/widgets/calculator/ui/calculatorFields/CalculatorFields.js.map +1 -1
- package/dist/lib/widgets/calculator/ui/calculatorInfo/CalculatorInfo.js +1 -1
- package/dist/lib/widgets/calculator/ui/calculatorInfo/CalculatorInfo.js.map +1 -1
- package/dist/lib/widgets/calculator/ui/calculatorInfo/ui/CalculatedBlock.js.map +1 -1
- package/dist/lib/widgets/calculator/ui/calculatorInfo/ui/CalculatorInfoBody.js.map +1 -1
- package/dist/lib/widgets/calculator/ui/calculatorInfo/ui/InfoListItem.js.map +1 -1
- package/dist/lib/widgets/model/helpers.js +1 -1
- package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js.map +1 -1
- package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js.map +1 -1
- package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js.map +1 -1
- package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/defineProperty.js.map +1 -1
- package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/extends.js.map +1 -1
- package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/iterableToArray.js.map +1 -1
- package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/iterableToArrayLimit.js.map +1 -1
- package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/nonIterableRest.js.map +1 -1
- package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js.map +1 -1
- package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/objectSpread2.js.map +1 -1
- package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js.map +1 -1
- package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js.map +1 -1
- package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/slicedToArray.js.map +1 -1
- package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/toConsumableArray.js.map +1 -1
- package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/toPrimitive.js.map +1 -1
- package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/toPropertyKey.js.map +1 -1
- package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/typeof.js.map +1 -1
- package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js.map +1 -1
- package/dist/node_modules/.pnpm/rc-slider@11.1.8_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-slider/es/Handles/Handle.js +1 -1
- package/dist/node_modules/.pnpm/rc-slider@11.1.8_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-slider/es/Handles/index.js +1 -1
- package/dist/node_modules/.pnpm/rc-slider@11.1.8_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-slider/es/Marks/Mark.js +1 -1
- package/dist/node_modules/.pnpm/rc-slider@11.1.8_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-slider/es/Slider.js +1 -1
- package/dist/node_modules/.pnpm/rc-slider@11.1.8_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-slider/es/Steps/Dot.js +1 -1
- package/dist/node_modules/.pnpm/rc-slider@11.1.8_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-slider/es/Tracks/Track.js +1 -1
- package/dist/node_modules/.pnpm/rc-slider@11.1.8_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-slider/es/Tracks/index.js +1 -1
- package/dist/node_modules/.pnpm/rc-slider@11.1.8_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-slider/es/hooks/useDrag.js +1 -1
- package/dist/node_modules/.pnpm/rc-slider@11.1.8_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-slider/es/hooks/useOffset.js +1 -1
- package/dist/node_modules/.pnpm/rc-util@5.44.4_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-util/es/hooks/useMergedState.js +1 -1
- package/dist/node_modules/.pnpm/rc-util@5.44.4_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-util/es/hooks/useState.js +1 -1
- package/dist/node_modules/.pnpm/rc-util@5.44.4_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-util/es/isEqual.js +1 -1
- package/dist/stats.html +1 -1
- package/dist/types/lib/shared/utils/variableHolder/variableContextHolder.d.ts +3 -0
- package/dist/types/lib/shared/utils/variables/variableResolver.d.ts +4 -3
- package/dist/types/lib/widgets/calculator/model/helpers.d.ts +2 -2
- package/dist/types/lib/widgets/calculator/model/types.d.ts +1 -4
- package/dist/types/lib/widgets/calculator/model/utils.d.ts +1 -2
- package/dist/types/lib/widgets/calculator/ui/calculatorInfo/CalculatorInfo.d.ts +1 -1
- package/dist/types/lib/widgets/calculator/ui/calculatorInfo/ui/CalculatedBlock.d.ts +3 -2
- package/dist/types/lib/widgets/calculator/ui/calculatorInfo/ui/CalculatorInfoBody.d.ts +2 -2
- package/dist/types/lib/widgets/calculator/ui/calculatorInfo/ui/InfoListItem.d.ts +5 -9
- package/package.json +1 -1
- /package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js +0 -0
- /package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js +0 -0
- /package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js +0 -0
- /package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/defineProperty.js +0 -0
- /package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/extends.js +0 -0
- /package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/iterableToArray.js +0 -0
- /package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/iterableToArrayLimit.js +0 -0
- /package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/nonIterableRest.js +0 -0
- /package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js +0 -0
- /package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/objectSpread2.js +0 -0
- /package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js +0 -0
- /package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js +0 -0
- /package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/slicedToArray.js +0 -0
- /package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/toConsumableArray.js +0 -0
- /package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/toPrimitive.js +0 -0
- /package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/toPropertyKey.js +0 -0
- /package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/typeof.js +0 -0
- /package/dist/node_modules/.pnpm/{@babel_runtime@7.28.4 → @babel_runtime@7.28.6}/node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js +0 -0
|
@@ -152,6 +152,9 @@ export interface VariableStore {
|
|
|
152
152
|
* const processedString = transformVariable(stringWithVariables)
|
|
153
153
|
* ```
|
|
154
154
|
*/
|
|
155
|
+
/**
|
|
156
|
+
* @deprecated dont use
|
|
157
|
+
*/
|
|
155
158
|
export declare class VariableContextHolder<Key extends string = string, Value = string> implements IVariableContextHolder<Key, Value> {
|
|
156
159
|
private _store;
|
|
157
160
|
private _variables;
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import { AllowedVariablePrefix, Resolved, VariablePattern, VariableType } from './types';
|
|
2
2
|
export declare const defaultAllowedPrefixes: AllowedVariablePrefix[];
|
|
3
|
-
export
|
|
4
|
-
addPattern: (start: VariablePattern[
|
|
5
|
-
addVariables: (vars: Variable[]) =>
|
|
3
|
+
export type VariableResolver<Variable extends VariableType> = {
|
|
4
|
+
addPattern: (start: VariablePattern['start'], end: VariablePattern['end']) => VariableResolver<Variable>;
|
|
5
|
+
addVariables: (vars: Variable[]) => VariableResolver<Variable>;
|
|
6
6
|
unwrapVariable: (string: string, allowedPrefixes?: AllowedVariablePrefix[]) => string;
|
|
7
7
|
wrapVariable: (string: string, allowedPrefixes?: AllowedVariablePrefix[]) => string;
|
|
8
8
|
escapeVariable: (string: string) => string;
|
|
9
9
|
resolve: <T>(data: T) => Resolved<T>;
|
|
10
10
|
};
|
|
11
|
+
export declare const variableResolver: <Variable extends VariableType>() => VariableResolver<Variable>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { InfoListItemProps } from '../ui';
|
|
2
2
|
import { CalculatorVariables } from './types';
|
|
3
3
|
export declare const evaluateFormula: (formula: string, variables: CalculatorVariables) => string;
|
|
4
|
-
export declare const formatInfoList: (list:
|
|
4
|
+
export declare const formatInfoList: (list: InfoListItemProps[], variables: CalculatorVariables) => InfoListItemProps[];
|
|
@@ -1,9 +1,6 @@
|
|
|
1
1
|
import { getCalculatorSchema } from './utils';
|
|
2
2
|
export type CalculatorVariables = Record<string, any>;
|
|
3
3
|
export type CalculatorSuffix = 'percent' | 'currency';
|
|
4
|
-
export type
|
|
5
|
-
formula: string;
|
|
6
|
-
};
|
|
7
|
-
export type CalculatorValue = ValueWithFormula | string;
|
|
4
|
+
export type CalculatorRootValue = string;
|
|
8
5
|
export type ModalContentVariant = 'content1' | 'content2';
|
|
9
6
|
export type CalculatorSchema = ReturnType<typeof getCalculatorSchema>;
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
import { FieldValues } from 'react-hook-form';
|
|
2
2
|
import { z } from 'zod';
|
|
3
3
|
import { CalculatorViewProps } from '../..';
|
|
4
|
-
import { CalculatorSuffix
|
|
4
|
+
import { CalculatorSuffix } from './types';
|
|
5
5
|
import { InfoListItemMode } from '../ui';
|
|
6
|
-
export declare const isFormula: (value: ValueWithFormula | string) => value is ValueWithFormula;
|
|
7
6
|
export declare const formatWithIntl: (suffix: CalculatorSuffix, value: number) => string | null;
|
|
8
7
|
export declare const formatValueToRenderInfoItem: (renderMode: InfoListItemMode, value: string) => string | null;
|
|
9
8
|
export declare const getCalculatorSchema: <T extends FieldValues>(props: CalculatorViewProps<T>["calculatorFieldsConfig"]["fieldsGroup"]) => z.ZodObject<any, z.UnknownKeysParam, z.ZodTypeAny, {
|
|
@@ -10,4 +10,4 @@ export interface CalculatorInfoProps extends Omit<CalculatedBlockProps, 'classes
|
|
|
10
10
|
classes?: CalculatorInfoClasses;
|
|
11
11
|
headline?: string;
|
|
12
12
|
}
|
|
13
|
-
export declare const CalculatorInfo: ({ rootDescription, bottomDescription, rootValue, title, subtitle, buttonsConfig, infoList, suffix, assistHint, headline, classes }: CalculatorInfoProps) => import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
export declare const CalculatorInfo: ({ rootDescription, bottomDescription, rootValue, title, subtitle, buttonsConfig, infoList, suffix, assistHint, headline, isFormula, classes }: CalculatorInfoProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { CalculatorRootValue, CalculatorSuffix } from '../../../model';
|
|
2
2
|
export type CalculatedBlockClasses = {
|
|
3
3
|
wrapper?: string;
|
|
4
4
|
description?: string;
|
|
@@ -6,7 +6,8 @@ export type CalculatedBlockClasses = {
|
|
|
6
6
|
};
|
|
7
7
|
export interface CalculatedBlockProps {
|
|
8
8
|
rootDescription: string;
|
|
9
|
-
rootValue:
|
|
9
|
+
rootValue: CalculatorRootValue;
|
|
10
|
+
isFormula: boolean;
|
|
10
11
|
suffix: CalculatorSuffix;
|
|
11
12
|
classes?: CalculatedBlockClasses;
|
|
12
13
|
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { InfoListItemProps } from '../..';
|
|
2
2
|
export type CalculatorInfoBodyClasses = {
|
|
3
3
|
wrapper?: string;
|
|
4
4
|
};
|
|
5
5
|
export interface CalculatedInfoBodyProps {
|
|
6
|
-
infoList:
|
|
6
|
+
infoList: InfoListItemProps[];
|
|
7
7
|
classes?: CalculatorInfoBodyClasses;
|
|
8
8
|
withoutDivider?: boolean;
|
|
9
9
|
}
|
|
@@ -1,18 +1,14 @@
|
|
|
1
|
-
import { CalculatorSuffix
|
|
1
|
+
import { CalculatorSuffix } from '../../../model';
|
|
2
2
|
export type InfoListItemMode = CalculatorSuffix | 'text';
|
|
3
3
|
export type InfoListItemColor = 'dark' | 'blue';
|
|
4
|
-
export
|
|
4
|
+
export type InfoListItemValue = string;
|
|
5
|
+
export interface InfoListItemProps {
|
|
5
6
|
label: string;
|
|
6
7
|
mode: InfoListItemMode;
|
|
7
8
|
hint?: string;
|
|
8
9
|
accent?: boolean;
|
|
9
10
|
color?: InfoListItemColor;
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
export interface InfoListItemDTO extends InfoListItemCommon {
|
|
13
|
-
value: CalculatorValue;
|
|
14
|
-
}
|
|
15
|
-
export interface InfoListItemProps extends InfoListItemCommon {
|
|
16
|
-
value: string;
|
|
11
|
+
isFormula: boolean;
|
|
12
|
+
value: InfoListItemValue;
|
|
17
13
|
}
|
|
18
14
|
export declare const InfoListItem: ({ hint, value, label, mode, color, accent }: InfoListItemProps) => import("react/jsx-runtime").JSX.Element;
|
package/package.json
CHANGED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|