@elliemae/ds-slider-v2 3.62.1 → 3.70.0-alpha.10
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/cjs/DSSliderV2.js.map +2 -2
- package/dist/cjs/DSSliderV2CTX.js.map +2 -2
- package/dist/cjs/config/useSliderV2.js +1 -4
- package/dist/cjs/config/useSliderV2.js.map +2 -2
- package/dist/cjs/config/useTickMarksValues.js.map +2 -2
- package/dist/cjs/config/useValidateProps.js +13 -0
- package/dist/cjs/config/useValidateProps.js.map +2 -2
- package/dist/cjs/parts/MainContent.js +40 -19
- package/dist/cjs/parts/MainContent.js.map +2 -2
- package/dist/cjs/parts/Thumb.js +79 -46
- package/dist/cjs/parts/Thumb.js.map +2 -2
- package/dist/cjs/parts/TickMarks.js +10 -27
- package/dist/cjs/parts/TickMarks.js.map +2 -2
- package/dist/cjs/parts/TickMarksValues.js +15 -19
- package/dist/cjs/parts/TickMarksValues.js.map +2 -2
- package/dist/cjs/parts/Track.js +14 -8
- package/dist/cjs/parts/Track.js.map +2 -2
- package/dist/cjs/{styles.js → parts/styles.js} +54 -25
- package/dist/cjs/parts/styles.js.map +7 -0
- package/dist/cjs/react-desc-prop-types.js +9 -3
- package/dist/cjs/react-desc-prop-types.js.map +2 -2
- package/dist/cjs/typescript-testing/typescript-slider-v2-valid-auto-polymorph-multiple.js +96 -0
- package/dist/cjs/typescript-testing/typescript-slider-v2-valid-auto-polymorph-multiple.js.map +7 -0
- package/dist/cjs/typescript-testing/typescript-slider-v2-valid-auto-polymorph-single.js +97 -0
- package/dist/cjs/typescript-testing/typescript-slider-v2-valid-auto-polymorph-single.js.map +7 -0
- package/dist/cjs/typescript-testing/typescript-slider-v2-valid-multiple.js +98 -0
- package/dist/cjs/typescript-testing/typescript-slider-v2-valid-multiple.js.map +7 -0
- package/dist/cjs/typescript-testing/{typescript-slider-v2-valid.js → typescript-slider-v2-valid-single.js} +2 -5
- package/dist/cjs/typescript-testing/{typescript-slider-v2-valid.js.map → typescript-slider-v2-valid-single.js.map} +3 -3
- package/dist/esm/DSSliderV2.js.map +2 -2
- package/dist/esm/DSSliderV2CTX.js.map +2 -2
- package/dist/esm/config/useSliderV2.js +1 -4
- package/dist/esm/config/useSliderV2.js.map +2 -2
- package/dist/esm/config/useTickMarksValues.js.map +2 -2
- package/dist/esm/config/useValidateProps.js +13 -0
- package/dist/esm/config/useValidateProps.js.map +2 -2
- package/dist/esm/parts/MainContent.js +41 -20
- package/dist/esm/parts/MainContent.js.map +2 -2
- package/dist/esm/parts/Thumb.js +78 -45
- package/dist/esm/parts/Thumb.js.map +2 -2
- package/dist/esm/parts/TickMarks.js +11 -28
- package/dist/esm/parts/TickMarks.js.map +2 -2
- package/dist/esm/parts/TickMarksValues.js +15 -19
- package/dist/esm/parts/TickMarksValues.js.map +2 -2
- package/dist/esm/parts/Track.js +15 -9
- package/dist/esm/parts/Track.js.map +2 -2
- package/dist/esm/{styles.js → parts/styles.js} +55 -26
- package/dist/esm/parts/styles.js.map +7 -0
- package/dist/esm/react-desc-prop-types.js +9 -3
- package/dist/esm/react-desc-prop-types.js.map +2 -2
- package/dist/esm/typescript-testing/typescript-slider-v2-valid-auto-polymorph-multiple.js +73 -0
- package/dist/esm/typescript-testing/typescript-slider-v2-valid-auto-polymorph-multiple.js.map +7 -0
- package/dist/esm/typescript-testing/typescript-slider-v2-valid-auto-polymorph-single.js +74 -0
- package/dist/esm/typescript-testing/typescript-slider-v2-valid-auto-polymorph-single.js.map +7 -0
- package/dist/esm/typescript-testing/typescript-slider-v2-valid-multiple.js +75 -0
- package/dist/esm/typescript-testing/typescript-slider-v2-valid-multiple.js.map +7 -0
- package/dist/esm/typescript-testing/{typescript-slider-v2-valid.js → typescript-slider-v2-valid-single.js} +2 -5
- package/dist/esm/typescript-testing/{typescript-slider-v2-valid.js.map → typescript-slider-v2-valid-single.js.map} +3 -3
- package/dist/types/DSSliderV2.d.ts +3 -2
- package/dist/types/DSSliderV2CTX.d.ts +1 -1
- package/dist/types/config/useSliderV2.d.ts +6 -6
- package/dist/types/config/useTickMarksValues.d.ts +1 -1
- package/dist/types/config/useValidateProps.d.ts +1 -1
- package/dist/types/parts/MainContent.d.ts +1 -1
- package/dist/types/parts/Thumb.d.ts +8 -1
- package/dist/types/parts/TickMarks.d.ts +1 -1
- package/dist/types/parts/TickMarksValues.d.ts +1 -1
- package/dist/types/parts/Track.d.ts +1 -1
- package/dist/types/{styles.d.ts → parts/styles.d.ts} +12 -9
- package/dist/types/react-desc-prop-types.d.ts +36 -16
- package/package.json +12 -12
- package/dist/cjs/styles.js.map +0 -7
- package/dist/cjs/utils/thumbLabels.js +0 -51
- package/dist/cjs/utils/thumbLabels.js.map +0 -7
- package/dist/esm/styles.js.map +0 -7
- package/dist/esm/utils/thumbLabels.js +0 -21
- package/dist/esm/utils/thumbLabels.js.map +0 -7
- package/dist/types/tests/DSSliderV2.PUI-15228.test.d.ts +0 -1
- package/dist/types/tests/DSSliderV2.PUI-15992.test.d.ts +0 -1
- package/dist/types/tests/DSSliderV2.a11y.test.d.ts +0 -1
- package/dist/types/tests/DSSliderV2.clickjump.test.d.ts +0 -1
- package/dist/types/tests/DSSliderV2.data-testid.test.d.ts +0 -1
- package/dist/types/tests/DSSliderV2.events.test.d.ts +0 -1
- package/dist/types/tests/DSSliderV2.exports.test.d.ts +0 -1
- package/dist/types/tests/DSSliderV2.keyboard.test.d.ts +0 -1
- package/dist/types/tests/DSSliderv2.api.test.d.ts +0 -1
- package/dist/types/tests/axe-core.test.d.ts +0 -1
- package/dist/types/typescript-testing/typescript-slider-v2-valid.d.ts +0 -1
- package/dist/types/utils/thumbLabels.d.ts +0 -7
|
@@ -1,7 +1,8 @@
|
|
|
1
|
+
import React from 'react';
|
|
1
2
|
import { type DSSliderV2T } from './react-desc-prop-types.js';
|
|
2
3
|
declare const DSSliderV2: {
|
|
3
|
-
|
|
4
|
+
(props: DSSliderV2T.Props): React.JSX.Element;
|
|
4
5
|
displayName: string;
|
|
5
6
|
};
|
|
6
|
-
declare const DSSliderV2WithSchema: import("@elliemae/ds-props-helpers/dist/types/propTypes/types.js").DocumentedReactComponent<DSSliderV2T.Props
|
|
7
|
+
declare const DSSliderV2WithSchema: import("@elliemae/ds-props-helpers/dist/types/propTypes/types.js").DocumentedReactComponent<DSSliderV2T.Props>;
|
|
7
8
|
export { DSSliderV2, DSSliderV2WithSchema };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import type { DSSliderV2CTX } from './config/useSliderV2.js';
|
|
2
2
|
/** Context for cross component communication */
|
|
3
|
-
export declare const DSSliderV2Context: import("react").Context<DSSliderV2CTX
|
|
3
|
+
export declare const DSSliderV2Context: import("react").Context<DSSliderV2CTX>;
|
|
4
4
|
export default DSSliderV2Context;
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { XstyledProps } from '@elliemae/ds-props-helpers';
|
|
3
3
|
import { type DSSliderV2T } from '../react-desc-prop-types.js';
|
|
4
|
-
export interface DSSliderV2CTX
|
|
5
|
-
propsWithDefault: DSSliderV2T.InternalProps
|
|
4
|
+
export interface DSSliderV2CTX {
|
|
5
|
+
propsWithDefault: DSSliderV2T.InternalProps;
|
|
6
6
|
xstyledProps: XstyledProps;
|
|
7
7
|
instanceUid: string;
|
|
8
8
|
rangeValues: [number, number] | [number];
|
|
9
9
|
tickMarkPositions: number[];
|
|
10
|
-
getOwnerProps: () => DSSliderV2T.InternalProps
|
|
10
|
+
getOwnerProps: () => DSSliderV2T.InternalProps;
|
|
11
11
|
getOwnerPropsArguments: () => Record<string, unknown>;
|
|
12
12
|
hasUserInteractedAfterFocus: boolean;
|
|
13
13
|
setHasUserInteractedAfterFocus: (value: boolean) => void;
|
|
14
14
|
}
|
|
15
|
-
export declare const useSliderV2:
|
|
16
|
-
getOwnerProps: () => DSSliderV2T.InternalProps
|
|
15
|
+
export declare const useSliderV2: (propsFromUser: DSSliderV2T.Props) => {
|
|
16
|
+
getOwnerProps: () => DSSliderV2T.InternalProps;
|
|
17
17
|
getOwnerPropsArguments: () => {};
|
|
18
|
-
propsWithDefault: DSSliderV2T.InternalProps
|
|
18
|
+
propsWithDefault: DSSliderV2T.InternalProps;
|
|
19
19
|
xstyledProps: XstyledProps;
|
|
20
20
|
instanceUid: string;
|
|
21
21
|
rangeValues: [number, number] | [number];
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import type { DSSliderV2T } from '../react-desc-prop-types.js';
|
|
2
|
-
export declare const useTickMarksValues:
|
|
2
|
+
export declare const useTickMarksValues: (props: DSSliderV2T.InternalProps) => number[];
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type ValidationMap } from '@elliemae/ds-props-helpers';
|
|
2
2
|
import { type DSSliderV2T } from '../react-desc-prop-types.js';
|
|
3
|
-
export declare const useValidateProps:
|
|
3
|
+
export declare const useValidateProps: (props: DSSliderV2T.InternalProps, propTypes: ValidationMap<unknown>, { tickMarkPositions }: {
|
|
4
4
|
tickMarkPositions: number[];
|
|
5
5
|
}) => void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const MainContent: () => import("react
|
|
1
|
+
export declare const MainContent: () => import("react").JSX.Element;
|
|
@@ -1,2 +1,9 @@
|
|
|
1
1
|
import type { IRenderThumbParams } from 'react-range/lib/types.js';
|
|
2
|
-
export declare const
|
|
2
|
+
export declare const conformedThumbLabel: (config: {
|
|
3
|
+
rangeValues: [number] | [number, number];
|
|
4
|
+
customTickMarksValues: string[];
|
|
5
|
+
index: number;
|
|
6
|
+
step: number;
|
|
7
|
+
minValue: number;
|
|
8
|
+
}) => string;
|
|
9
|
+
export declare const Thumb: ({ index, props: reactRangeOpinionatedProps, isDragged }: Omit<IRenderThumbParams, "key">) => import("react").JSX.Element;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const TickMarks: () => import("react
|
|
1
|
+
export declare const TickMarks: () => import("react").JSX.Element;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const TickMarksValues: () => import("react
|
|
1
|
+
export declare const TickMarksValues: () => import("react").JSX.Element;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import type { IRenderTrackParams } from 'react-range/lib/types.js';
|
|
2
|
-
export declare const Track: ({ children, props, disabled }: IRenderTrackParams) => import("react
|
|
2
|
+
export declare const Track: ({ children, props: reactRangeOpinionatedProps, disabled }: IRenderTrackParams) => import("react").JSX.Element;
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
export declare const StyledWrapper: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("@elliemae/ds-grid").DSGridT.Props & import("react").RefAttributes<HTMLDivElement>>, import("@elliemae/ds-system").Theme, object & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<import("react").ForwardRefExoticComponent<import("@elliemae/ds-grid").DSGridT.Props & import("react").RefAttributes<HTMLDivElement>>>, never>;
|
|
2
2
|
export declare const StyledRangeWrapper: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("@elliemae/ds-grid").DSGridT.Props & import("react").RefAttributes<HTMLDivElement>>, import("@elliemae/ds-system").Theme, object & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<import("react").ForwardRefExoticComponent<import("@elliemae/ds-grid").DSGridT.Props & import("react").RefAttributes<HTMLDivElement>>>, never>;
|
|
3
|
-
|
|
3
|
+
interface TrackProps {
|
|
4
4
|
disabled: boolean;
|
|
5
|
-
applyAriaDisabled: boolean;
|
|
5
|
+
$applyAriaDisabled: boolean;
|
|
6
|
+
$readOnly: boolean;
|
|
6
7
|
multiple: boolean;
|
|
7
8
|
minValue: number;
|
|
8
9
|
maxValue: number;
|
|
9
10
|
rangeValues: [number] | [number, number];
|
|
10
|
-
}
|
|
11
|
-
export declare const
|
|
12
|
-
|
|
13
|
-
} & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<"div">, never>;
|
|
11
|
+
}
|
|
12
|
+
export declare const StyledTrack: import("styled-components").StyledComponent<"div", import("@elliemae/ds-system").Theme, TrackProps & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<"div">, never>;
|
|
13
|
+
export declare const StyledDot: import("styled-components").StyledComponent<"div", import("@elliemae/ds-system").Theme, object & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<"div">, never>;
|
|
14
14
|
export declare const StyledDotsContainer: import("styled-components").StyledComponent<"div", import("@elliemae/ds-system").Theme, object & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<"div">, never>;
|
|
15
15
|
export declare const StyledTickMarkValue: import("styled-components").StyledComponent<"div", import("@elliemae/ds-system").Theme, {
|
|
16
16
|
isSelected: boolean;
|
|
@@ -19,7 +19,10 @@ export declare const StyledTickMarksContainer: import("styled-components").Style
|
|
|
19
19
|
columnCount: number;
|
|
20
20
|
columnWidth: string;
|
|
21
21
|
} & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<"div">, never>;
|
|
22
|
-
|
|
22
|
+
interface ThumbProps {
|
|
23
23
|
disabled: boolean;
|
|
24
|
-
applyAriaDisabled: boolean;
|
|
25
|
-
|
|
24
|
+
$applyAriaDisabled: boolean;
|
|
25
|
+
$readOnly: boolean;
|
|
26
|
+
}
|
|
27
|
+
export declare const StyledThumb: import("styled-components").StyledComponent<"div", import("@elliemae/ds-system").Theme, ThumbProps & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<"div">, never>;
|
|
28
|
+
export {};
|
|
@@ -2,31 +2,51 @@ import type { DSPropTypesSchema, GlobalAttributesT, ValidationMap, XstyledProps
|
|
|
2
2
|
import { type TypescriptHelpersT } from '@elliemae/ds-typescript-helpers';
|
|
3
3
|
import { DSSliderV2Name, SLIDER_V2_SLOTS } from './constants/index.js';
|
|
4
4
|
export declare namespace DSSliderV2T {
|
|
5
|
-
type
|
|
6
|
-
interface RequiredProps<TMultiple extends boolean> {
|
|
7
|
-
value: ValueType<TMultiple>;
|
|
5
|
+
type CommonRequiredProps = {
|
|
8
6
|
minValue: number;
|
|
9
7
|
maxValue: number;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
multiple: TMultiple;
|
|
8
|
+
};
|
|
9
|
+
type CommonDefaultProps = {
|
|
13
10
|
disabled: boolean;
|
|
14
11
|
applyAriaDisabled: boolean;
|
|
15
12
|
readOnly: boolean;
|
|
16
13
|
step: number;
|
|
17
|
-
onValueChange: (newValue: ValueType<TMultiple>) => void;
|
|
18
14
|
withTickMarks: boolean;
|
|
19
15
|
withTickMarksValues: boolean;
|
|
20
16
|
customTickMarksValues: string[];
|
|
21
|
-
}
|
|
22
|
-
interface
|
|
17
|
+
};
|
|
18
|
+
interface CommonOptionalProps extends TypescriptHelpersT.PropsForGlobalOnSlots<typeof DSSliderV2Name, typeof SLIDER_V2_SLOTS> {
|
|
23
19
|
className?: string;
|
|
24
20
|
}
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
21
|
+
type RequiredPropsMultiple = CommonRequiredProps & {
|
|
22
|
+
value: [number, number];
|
|
23
|
+
};
|
|
24
|
+
type DefaultPropsMultiple = CommonDefaultProps & {
|
|
25
|
+
multiple: true;
|
|
26
|
+
onValueChange: (newValue: [number, number]) => void;
|
|
27
|
+
minRange: number;
|
|
28
|
+
};
|
|
29
|
+
type OptionalPropsMultiple = CommonOptionalProps;
|
|
30
|
+
type PropsMultiple = Partial<DefaultPropsMultiple> & OptionalPropsMultiple & Omit<GlobalAttributesT<HTMLButtonElement>, keyof DefaultPropsMultiple | keyof OptionalPropsMultiple | keyof XstyledProps | keyof RequiredPropsMultiple> & XstyledProps & RequiredPropsMultiple;
|
|
31
|
+
type InternalPropsMultiple = DefaultPropsMultiple & OptionalPropsMultiple & Omit<GlobalAttributesT<HTMLButtonElement>, keyof DefaultPropsMultiple | keyof OptionalPropsMultiple | keyof XstyledProps | keyof RequiredPropsMultiple> & XstyledProps & RequiredPropsMultiple;
|
|
32
|
+
type RequiredPropsSingle = CommonRequiredProps & {
|
|
33
|
+
value: number;
|
|
34
|
+
};
|
|
35
|
+
type DefaultPropsSingle = CommonDefaultProps & {
|
|
36
|
+
multiple: false;
|
|
37
|
+
onValueChange: (newValue: number) => void;
|
|
38
|
+
};
|
|
39
|
+
type OptionalPropsSingle = CommonOptionalProps & {
|
|
40
|
+
minRange?: never;
|
|
41
|
+
};
|
|
42
|
+
type PropsSingle = Partial<DefaultPropsSingle> & OptionalPropsSingle & Omit<GlobalAttributesT<HTMLButtonElement>, keyof DefaultPropsSingle | keyof OptionalPropsSingle | keyof XstyledProps | keyof RequiredPropsSingle> & XstyledProps & RequiredPropsSingle;
|
|
43
|
+
type InternalPropsSingle = DefaultPropsSingle & OptionalPropsSingle & Omit<GlobalAttributesT<HTMLButtonElement>, keyof DefaultPropsSingle | keyof OptionalPropsSingle | keyof XstyledProps | keyof RequiredPropsSingle> & XstyledProps & RequiredPropsSingle;
|
|
44
|
+
type DefaultProps = DefaultPropsMultiple | DefaultPropsSingle;
|
|
45
|
+
type RequiredProps = RequiredPropsMultiple | RequiredPropsSingle;
|
|
46
|
+
type OptionalProps = OptionalPropsMultiple | OptionalPropsSingle;
|
|
47
|
+
type Props = PropsMultiple | PropsSingle;
|
|
48
|
+
type InternalProps = InternalPropsMultiple | InternalPropsSingle;
|
|
29
49
|
}
|
|
30
|
-
export declare const defaultProps: DSSliderV2T.DefaultProps
|
|
31
|
-
export declare const DSSliderV2PropTypes: DSPropTypesSchema<DSSliderV2T.Props
|
|
32
|
-
export declare const DSSliderV2PropTypesSchema: ValidationMap<DSSliderV2T.Props
|
|
50
|
+
export declare const defaultProps: DSSliderV2T.DefaultProps;
|
|
51
|
+
export declare const DSSliderV2PropTypes: DSPropTypesSchema<DSSliderV2T.Props>;
|
|
52
|
+
export declare const DSSliderV2PropTypesSchema: ValidationMap<DSSliderV2T.Props>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elliemae/ds-slider-v2",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.70.0-alpha.10",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "ICE MT - Dimsum - Slider V 2",
|
|
6
6
|
"files": [
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
],
|
|
23
23
|
"repository": {
|
|
24
24
|
"type": "git",
|
|
25
|
-
"url": "https://
|
|
25
|
+
"url": "https://github.com/intcx/PLATFORM-UI.dimsum.git"
|
|
26
26
|
},
|
|
27
27
|
"engines": {
|
|
28
28
|
"pnpm": ">=9",
|
|
@@ -38,18 +38,18 @@
|
|
|
38
38
|
"dependencies": {
|
|
39
39
|
"react-range": "~1.10.0",
|
|
40
40
|
"uid": "^2.0.2",
|
|
41
|
-
"@elliemae/ds-grid": "3.
|
|
42
|
-
"@elliemae/ds-
|
|
43
|
-
"@elliemae/ds-
|
|
44
|
-
"@elliemae/ds-
|
|
45
|
-
"@elliemae/ds-
|
|
41
|
+
"@elliemae/ds-grid": "3.70.0-alpha.10",
|
|
42
|
+
"@elliemae/ds-props-helpers": "3.70.0-alpha.10",
|
|
43
|
+
"@elliemae/ds-tooltip-v3": "3.70.0-alpha.10",
|
|
44
|
+
"@elliemae/ds-typescript-helpers": "3.70.0-alpha.10",
|
|
45
|
+
"@elliemae/ds-system": "3.70.0-alpha.10"
|
|
46
46
|
},
|
|
47
47
|
"devDependencies": {
|
|
48
48
|
"jest": "^30.0.0",
|
|
49
49
|
"lodash-es": "^4.18.1",
|
|
50
|
-
"styled-components": "~5.3.
|
|
51
|
-
"@elliemae/ds-monorepo-devops": "3.
|
|
52
|
-
"@elliemae/ds-test-utils": "3.
|
|
50
|
+
"styled-components": "~5.3.11",
|
|
51
|
+
"@elliemae/ds-monorepo-devops": "3.70.0-alpha.10",
|
|
52
|
+
"@elliemae/ds-test-utils": "3.70.0-alpha.10"
|
|
53
53
|
},
|
|
54
54
|
"peerDependencies": {
|
|
55
55
|
"@testing-library/jest-dom": "^6.6.3",
|
|
@@ -58,7 +58,7 @@
|
|
|
58
58
|
"lodash-es": "^4.18.1",
|
|
59
59
|
"react": "^18.3.1",
|
|
60
60
|
"react-dom": "^18.3.1",
|
|
61
|
-
"styled-components": "~5.3.
|
|
61
|
+
"styled-components": "~5.3.11"
|
|
62
62
|
},
|
|
63
63
|
"publishConfig": {
|
|
64
64
|
"access": "public",
|
|
@@ -66,7 +66,7 @@
|
|
|
66
66
|
},
|
|
67
67
|
"scripts": {
|
|
68
68
|
"dev": "cross-env NODE_ENV=development node ../../../scripts/build/build.mjs --watch",
|
|
69
|
-
"test": "ds-monorepo-devops test --passWithNoTests --coverage=\"false\"",
|
|
69
|
+
"test": "playwright test -c ./playwright.config.mjs && ds-monorepo-devops test --passWithNoTests --coverage=\"false\"",
|
|
70
70
|
"lint": "node ../../../scripts/lint.mjs --fix",
|
|
71
71
|
"lint:strict": "node ../../../scripts/lint-strict.mjs",
|
|
72
72
|
"dts": "node ../../../scripts/dts.mjs",
|
package/dist/cjs/styles.js.map
DELETED
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../src/styles.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import { getTrackBackground } from 'react-range';\nimport { Grid } from '@elliemae/ds-grid';\nimport { styled } from '@elliemae/ds-system';\nimport { DSSliderV2Name, SLIDER_V2_SLOTS } from './constants/index.js';\n\nexport const StyledWrapper = styled(Grid, { name: DSSliderV2Name, slot: SLIDER_V2_SLOTS.ROOT })``;\n\nexport const StyledRangeWrapper = styled(Grid, { name: DSSliderV2Name, slot: SLIDER_V2_SLOTS.RANGE_WRAPPER })``;\n\nexport const StyledTrack = styled('div', { name: DSSliderV2Name, slot: SLIDER_V2_SLOTS.TRACK })<{\n disabled: boolean;\n applyAriaDisabled: boolean;\n multiple: boolean;\n minValue: number;\n maxValue: number;\n rangeValues: [number] | [number, number];\n}>`\n position: relative;\n height: ${(props) => props.theme.space.xxxs};\n width: 100%;\n min-width: ${(props) => props.theme.space.xl};\n border-radius: ${(props) => props.theme.space.xxxs};\n background: ${(props) =>\n props.disabled || props.applyAriaDisabled\n ? props.theme.colors.neutral[100]\n : getTrackBackground({\n values: props.rangeValues,\n colors: props.multiple\n ? [props.theme.colors.neutral[100], props.theme.colors.brand[600], props.theme.colors.neutral[100]]\n : [props.theme.colors.brand[600], props.theme.colors.neutral[100]],\n min: props.minValue,\n max: props.maxValue,\n })};\n`;\n\nexport const StyledDot = styled('div', { name: DSSliderV2Name, slot: SLIDER_V2_SLOTS.DOT })<{ isActive: boolean }>`\n &:after {\n content: '';\n background: ${(props) => (props.isActive ? props.theme.colors.brand[300] : props.theme.colors.neutral[400])};\n border-radius: ${(props) => props.theme.space.xxxs};\n display: block;\n position: relative;\n width: 2px;\n height: 2px;\n }\n`;\n\nexport const StyledDotsContainer = styled('div', { name: DSSliderV2Name, slot: SLIDER_V2_SLOTS.DOT_CONTAINER })`\n padding: 0 2px;\n align-items: center;\n display: flex;\n justify-content: space-between;\n pointer-events: none;\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n z-index: ${(props) => props.theme.zIndex.tooltip - 1};\n`;\n\nexport const StyledTickMarkValue = styled('div', { name: DSSliderV2Name, slot: SLIDER_V2_SLOTS.TICK_MARK_VALUE })<{\n isSelected: boolean;\n}>`\n display: flex;\n justify-content: center;\n text-align: center;\n min-height: ${(props) => props.theme.space.xs};\n overflow: visible;\n color: ${(props) => (props.isSelected ? props.theme.colors.neutral[800] : props.theme.colors.neutral[500])};\n place-self: baseline;\n transform: translateX(-50%);\n white-space: normal;\n overflow-wrap: break-word;\n word-break: break-word;\n`;\n\nexport const StyledTickMarksContainer = styled('div', {\n name: DSSliderV2Name,\n slot: SLIDER_V2_SLOTS.TICK_MARK_CONTAINER,\n})<{ columnCount: number; columnWidth: string }>`\n display: grid;\n grid-template-columns: repeat(${(props) => props.columnCount}, calc(${(props) => props.columnWidth} - 4px));\n gap: 4px;\n justify-content: space-between;\n // this next property-value reverts the sanitize.css value\n overflow-wrap: normal;\n`;\n\nexport const StyledThumb = styled('div', { name: DSSliderV2Name, slot: SLIDER_V2_SLOTS.THUMB })<{\n disabled: boolean;\n applyAriaDisabled: boolean;\n}>`\n height: 20px;\n width: 20px;\n top: 0;\n background-color: ${(props) =>\n props.disabled || props.applyAriaDisabled ? props.theme.colors.neutral[100] : props.theme.colors.neutral['000']};\n border-radius: 10px;\n border: 1px solid\n ${(props) =>\n props.disabled || props.applyAriaDisabled ? props.theme.colors.neutral[100] : props.theme.colors.neutral[400]};\n\n :focus {\n border: 2px solid brand-700;\n outline: unset;\n }\n\n :hover {\n background-color: ${({ disabled, applyAriaDisabled, theme }) =>\n disabled || applyAriaDisabled ? theme.colors.neutral[100] : theme.colors.brand[200]};\n }\n\n cursor: ${({ disabled, applyAriaDisabled }) => (disabled || applyAriaDisabled ? 'not-allowed' : undefined)};\n\n z-index: ${(props) => props.theme.zIndex.tooltip};\n`;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,yBAAmC;AACnC,qBAAqB;AACrB,uBAAuB;AACvB,uBAAgD;AAEzC,MAAM,oBAAgB,yBAAO,qBAAM,EAAE,MAAM,iCAAgB,MAAM,iCAAgB,KAAK,CAAC;AAEvF,MAAM,yBAAqB,yBAAO,qBAAM,EAAE,MAAM,iCAAgB,MAAM,iCAAgB,cAAc,CAAC;AAErG,MAAM,kBAAc,yBAAO,OAAO,EAAE,MAAM,iCAAgB,MAAM,iCAAgB,MAAM,CAAC;AAAA;AAAA,YASlF,CAAC,UAAU,MAAM,MAAM,MAAM,IAAI;AAAA;A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AQ,GAAG,IAAI,MAAM,MAAM,OAAO,QAAQ,GAAG,CAAE;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAQrG,MAAM,+BAA2B,yBAAO,OAAO;AAAA,EACpD,MAAM;AAAA,EACN,MAAM,iCAAgB;AACxB,CAAC;AAAA;AAAA,kCAEiC,CAAC,UAAU,MAAM,WAAW,UAAU,CAAC,UAAU,MAAM,WAAW;AAAA;AAAA;AAAA;AAAA;AAAA;AAO7F,MAAM,kBAAc,yBAAO,OAAO,EAAE,MAAM,iCAAgB,MAAM,iCAAgB,MAAM,CAAC;AAAA;AAAA;AAAA;AAAA,sBAOxE,CAAC,UACnB,MAAM,YAAY,MAAM,oBAAoB,MAAM,MAAM,OAAO,QAAQ,GAAG,IAAI,MAAM,MAAM,OAAO,QAAQ,KAAK,CAAC;AAAA;AAAA;AAAA,MAG7G,CAAC,UACD,MAAM,YAAY,MAAM,oBAAoB,MAAM,MAAM,OAAO,QAAQ,GAAG,IAAI,MAAM,MAAM,OAAO,QAAQ,GAAG,CAAC;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,wBAQ3F,CAAC,EAAE,UAAU,mBAAmB,MAAM,MACxD,YAAY,oBAAoB,MAAM,OAAO,QAAQ,GAAG,IAAI,MAAM,OAAO,MAAM,GAAG,CAAC;AAAA;AAAA;AAAA,YAG7E,CAAC,EAAE,UAAU,kBAAkB,MAAO,YAAY,oBAAoB,gBAAgB,MAAU;AAAA;AAAA,aAE/F,CAAC,UAAU,MAAM,MAAM,OAAO,OAAO;AAAA;",
|
|
6
|
-
"names": []
|
|
7
|
-
}
|
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __create = Object.create;
|
|
3
|
-
var __defProp = Object.defineProperty;
|
|
4
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
-
var __export = (target, all) => {
|
|
9
|
-
for (var name in all)
|
|
10
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
-
};
|
|
12
|
-
var __copyProps = (to, from, except, desc) => {
|
|
13
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
-
for (let key of __getOwnPropNames(from))
|
|
15
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
-
}
|
|
18
|
-
return to;
|
|
19
|
-
};
|
|
20
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
-
mod
|
|
27
|
-
));
|
|
28
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
-
var thumbLabels_exports = {};
|
|
30
|
-
__export(thumbLabels_exports, {
|
|
31
|
-
conformedThumbLabel: () => conformedThumbLabel
|
|
32
|
-
});
|
|
33
|
-
module.exports = __toCommonJS(thumbLabels_exports);
|
|
34
|
-
var React = __toESM(require("react"));
|
|
35
|
-
const conformedThumbLabel = ({
|
|
36
|
-
rangeValues,
|
|
37
|
-
customTickMarksValues,
|
|
38
|
-
index,
|
|
39
|
-
step,
|
|
40
|
-
minValue
|
|
41
|
-
}) => {
|
|
42
|
-
let msg = `Value: `;
|
|
43
|
-
if (customTickMarksValues.length) {
|
|
44
|
-
const foundValue = customTickMarksValues[Math.floor((rangeValues[index] - minValue) / step)];
|
|
45
|
-
msg += `${foundValue ?? rangeValues[index].toFixed(1)}`;
|
|
46
|
-
} else {
|
|
47
|
-
msg += `${rangeValues[index].toFixed(1)}`;
|
|
48
|
-
}
|
|
49
|
-
return msg;
|
|
50
|
-
};
|
|
51
|
-
//# sourceMappingURL=thumbLabels.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../src/utils/thumbLabels.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["export const conformedThumbLabel = ({\n rangeValues,\n customTickMarksValues,\n index,\n step,\n minValue,\n}: {\n rangeValues: [number] | [number, number];\n customTickMarksValues: string[];\n index: number;\n step: number;\n minValue: number;\n}) => {\n let msg = `Value: `;\n if (customTickMarksValues.length) {\n const foundValue = customTickMarksValues[Math.floor((rangeValues[index] - minValue) / step)];\n msg += `${foundValue ?? rangeValues[index].toFixed(1)}`;\n } else {\n msg += `${rangeValues[index].toFixed(1)}`;\n }\n\n return msg;\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAhB,MAAM,sBAAsB,CAAC;AAAA,EAClC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,MAMM;AACJ,MAAI,MAAM;AACV,MAAI,sBAAsB,QAAQ;AAChC,UAAM,aAAa,sBAAsB,KAAK,OAAO,YAAY,KAAK,IAAI,YAAY,IAAI,CAAC;AAC3F,WAAO,GAAG,cAAc,YAAY,KAAK,EAAE,QAAQ,CAAC,CAAC;AAAA,EACvD,OAAO;AACL,WAAO,GAAG,YAAY,KAAK,EAAE,QAAQ,CAAC,CAAC;AAAA,EACzC;AAEA,SAAO;AACT;",
|
|
6
|
-
"names": []
|
|
7
|
-
}
|
package/dist/esm/styles.js.map
DELETED
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/styles.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { getTrackBackground } from 'react-range';\nimport { Grid } from '@elliemae/ds-grid';\nimport { styled } from '@elliemae/ds-system';\nimport { DSSliderV2Name, SLIDER_V2_SLOTS } from './constants/index.js';\n\nexport const StyledWrapper = styled(Grid, { name: DSSliderV2Name, slot: SLIDER_V2_SLOTS.ROOT })``;\n\nexport const StyledRangeWrapper = styled(Grid, { name: DSSliderV2Name, slot: SLIDER_V2_SLOTS.RANGE_WRAPPER })``;\n\nexport const StyledTrack = styled('div', { name: DSSliderV2Name, slot: SLIDER_V2_SLOTS.TRACK })<{\n disabled: boolean;\n applyAriaDisabled: boolean;\n multiple: boolean;\n minValue: number;\n maxValue: number;\n rangeValues: [number] | [number, number];\n}>`\n position: relative;\n height: ${(props) => props.theme.space.xxxs};\n width: 100%;\n min-width: ${(props) => props.theme.space.xl};\n border-radius: ${(props) => props.theme.space.xxxs};\n background: ${(props) =>\n props.disabled || props.applyAriaDisabled\n ? props.theme.colors.neutral[100]\n : getTrackBackground({\n values: props.rangeValues,\n colors: props.multiple\n ? [props.theme.colors.neutral[100], props.theme.colors.brand[600], props.theme.colors.neutral[100]]\n : [props.theme.colors.brand[600], props.theme.colors.neutral[100]],\n min: props.minValue,\n max: props.maxValue,\n })};\n`;\n\nexport const StyledDot = styled('div', { name: DSSliderV2Name, slot: SLIDER_V2_SLOTS.DOT })<{ isActive: boolean }>`\n &:after {\n content: '';\n background: ${(props) => (props.isActive ? props.theme.colors.brand[300] : props.theme.colors.neutral[400])};\n border-radius: ${(props) => props.theme.space.xxxs};\n display: block;\n position: relative;\n width: 2px;\n height: 2px;\n }\n`;\n\nexport const StyledDotsContainer = styled('div', { name: DSSliderV2Name, slot: SLIDER_V2_SLOTS.DOT_CONTAINER })`\n padding: 0 2px;\n align-items: center;\n display: flex;\n justify-content: space-between;\n pointer-events: none;\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n z-index: ${(props) => props.theme.zIndex.tooltip - 1};\n`;\n\nexport const StyledTickMarkValue = styled('div', { name: DSSliderV2Name, slot: SLIDER_V2_SLOTS.TICK_MARK_VALUE })<{\n isSelected: boolean;\n}>`\n display: flex;\n justify-content: center;\n text-align: center;\n min-height: ${(props) => props.theme.space.xs};\n overflow: visible;\n color: ${(props) => (props.isSelected ? props.theme.colors.neutral[800] : props.theme.colors.neutral[500])};\n place-self: baseline;\n transform: translateX(-50%);\n white-space: normal;\n overflow-wrap: break-word;\n word-break: break-word;\n`;\n\nexport const StyledTickMarksContainer = styled('div', {\n name: DSSliderV2Name,\n slot: SLIDER_V2_SLOTS.TICK_MARK_CONTAINER,\n})<{ columnCount: number; columnWidth: string }>`\n display: grid;\n grid-template-columns: repeat(${(props) => props.columnCount}, calc(${(props) => props.columnWidth} - 4px));\n gap: 4px;\n justify-content: space-between;\n // this next property-value reverts the sanitize.css value\n overflow-wrap: normal;\n`;\n\nexport const StyledThumb = styled('div', { name: DSSliderV2Name, slot: SLIDER_V2_SLOTS.THUMB })<{\n disabled: boolean;\n applyAriaDisabled: boolean;\n}>`\n height: 20px;\n width: 20px;\n top: 0;\n background-color: ${(props) =>\n props.disabled || props.applyAriaDisabled ? props.theme.colors.neutral[100] : props.theme.colors.neutral['000']};\n border-radius: 10px;\n border: 1px solid\n ${(props) =>\n props.disabled || props.applyAriaDisabled ? props.theme.colors.neutral[100] : props.theme.colors.neutral[400]};\n\n :focus {\n border: 2px solid brand-700;\n outline: unset;\n }\n\n :hover {\n background-color: ${({ disabled, applyAriaDisabled, theme }) =>\n disabled || applyAriaDisabled ? theme.colors.neutral[100] : theme.colors.brand[200]};\n }\n\n cursor: ${({ disabled, applyAriaDisabled }) => (disabled || applyAriaDisabled ? 'not-allowed' : undefined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O,QAAQ,GAAG,IAAI,MAAM,OAAO,MAAM,GAAG,CAAC;AAAA;AAAA;AAAA,YAG7E,CAAC,EAAE,UAAU,kBAAkB,MAAO,YAAY,oBAAoB,gBAAgB,MAAU;AAAA;AAAA,aAE/F,CAAC,UAAU,MAAM,MAAM,OAAO,OAAO;AAAA;",
|
|
6
|
-
"names": []
|
|
7
|
-
}
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
const conformedThumbLabel = ({
|
|
3
|
-
rangeValues,
|
|
4
|
-
customTickMarksValues,
|
|
5
|
-
index,
|
|
6
|
-
step,
|
|
7
|
-
minValue
|
|
8
|
-
}) => {
|
|
9
|
-
let msg = `Value: `;
|
|
10
|
-
if (customTickMarksValues.length) {
|
|
11
|
-
const foundValue = customTickMarksValues[Math.floor((rangeValues[index] - minValue) / step)];
|
|
12
|
-
msg += `${foundValue ?? rangeValues[index].toFixed(1)}`;
|
|
13
|
-
} else {
|
|
14
|
-
msg += `${rangeValues[index].toFixed(1)}`;
|
|
15
|
-
}
|
|
16
|
-
return msg;
|
|
17
|
-
};
|
|
18
|
-
export {
|
|
19
|
-
conformedThumbLabel
|
|
20
|
-
};
|
|
21
|
-
//# sourceMappingURL=thumbLabels.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/utils/thumbLabels.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "export const conformedThumbLabel = ({\n rangeValues,\n customTickMarksValues,\n index,\n step,\n minValue,\n}: {\n rangeValues: [number] | [number, number];\n customTickMarksValues: string[];\n index: number;\n step: number;\n minValue: number;\n}) => {\n let msg = `Value: `;\n if (customTickMarksValues.length) {\n const foundValue = customTickMarksValues[Math.floor((rangeValues[index] - minValue) / step)];\n msg += `${foundValue ?? rangeValues[index].toFixed(1)}`;\n } else {\n msg += `${rangeValues[index].toFixed(1)}`;\n }\n\n return msg;\n};\n"],
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACAhB,MAAM,sBAAsB,CAAC;AAAA,EAClC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,MAMM;AACJ,MAAI,MAAM;AACV,MAAI,sBAAsB,QAAQ;AAChC,UAAM,aAAa,sBAAsB,KAAK,OAAO,YAAY,KAAK,IAAI,YAAY,IAAI,CAAC;AAC3F,WAAO,GAAG,cAAc,YAAY,KAAK,EAAE,QAAQ,CAAC,CAAC;AAAA,EACvD,OAAO;AACL,WAAO,GAAG,YAAY,KAAK,EAAE,QAAQ,CAAC,CAAC;AAAA,EACzC;AAEA,SAAO;AACT;",
|
|
6
|
-
"names": []
|
|
7
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|