@mindly/ui-components 5.20.0 → 5.22.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/cjs/index.js +6 -6
- package/dist/cjs/lib2/shared/assets/icons/IconArrowDown.d.ts +2 -0
- package/dist/cjs/lib2/shared/assets/icons/IconBookmark.d.ts +2 -0
- package/dist/cjs/lib2/shared/assets/icons/IconCalendarFilled.d.ts +3 -0
- package/dist/cjs/lib2/shared/assets/icons/IconCancel.d.ts +2 -0
- package/dist/cjs/lib2/shared/assets/icons/IconChatFilled.d.ts +3 -0
- package/dist/cjs/lib2/shared/assets/icons/IconClient.d.ts +2 -0
- package/dist/cjs/lib2/shared/assets/icons/IconClientFilled.d.ts +2 -0
- package/dist/cjs/lib2/shared/assets/icons/IconPaid.d.ts +2 -0
- package/dist/cjs/lib2/shared/assets/icons/IconSearch.d.ts +2 -0
- package/dist/cjs/lib2/shared/assets/icons/IconUserNotFound.d.ts +3 -0
- package/dist/cjs/lib2/shared/assets/icons/index.d.ts +10 -0
- package/dist/cjs/lib2/shared/hooks/useCircleRating.d.ts +7 -4
- package/dist/cjs/lib2/shared/types/ratingCircleTypes.d.ts +6 -2
- package/dist/cjs/lib2/shared/ui/ListItems/{ListItem.d.ts → Item.d.ts} +3 -3
- package/dist/cjs/lib2/shared/ui/ListItems/index.d.ts +1 -1
- package/dist/cjs/lib2/shared/ui/RatingCircle/RatingCircleWrapper.d.ts +3 -1
- package/dist/cjs/lib2/shared/ui/RatingCircle/styles.d.ts +35 -0
- package/dist/esm/index.js +6 -6
- package/dist/esm/lib2/shared/assets/icons/IconArrowDown.d.ts +2 -0
- package/dist/esm/lib2/shared/assets/icons/IconBookmark.d.ts +2 -0
- package/dist/esm/lib2/shared/assets/icons/IconCalendarFilled.d.ts +3 -0
- package/dist/esm/lib2/shared/assets/icons/IconCancel.d.ts +2 -0
- package/dist/esm/lib2/shared/assets/icons/IconChatFilled.d.ts +3 -0
- package/dist/esm/lib2/shared/assets/icons/IconClient.d.ts +2 -0
- package/dist/esm/lib2/shared/assets/icons/IconClientFilled.d.ts +2 -0
- package/dist/esm/lib2/shared/assets/icons/IconPaid.d.ts +2 -0
- package/dist/esm/lib2/shared/assets/icons/IconSearch.d.ts +2 -0
- package/dist/esm/lib2/shared/assets/icons/IconUserNotFound.d.ts +3 -0
- package/dist/esm/lib2/shared/assets/icons/index.d.ts +10 -0
- package/dist/esm/lib2/shared/hooks/useCircleRating.d.ts +7 -4
- package/dist/esm/lib2/shared/types/ratingCircleTypes.d.ts +6 -2
- package/dist/esm/lib2/shared/ui/ListItems/{ListItem.d.ts → Item.d.ts} +3 -3
- package/dist/esm/lib2/shared/ui/ListItems/index.d.ts +1 -1
- package/dist/esm/lib2/shared/ui/RatingCircle/RatingCircleWrapper.d.ts +3 -1
- package/dist/esm/lib2/shared/ui/RatingCircle/styles.d.ts +35 -0
- package/dist/index.d.ts +41 -11
- package/package.json +1 -1
|
@@ -43,3 +43,13 @@ export * from './IconCheckSmall';
|
|
|
43
43
|
export * from './IconCheck';
|
|
44
44
|
export * from './IconCapFilled';
|
|
45
45
|
export * from './IconCancelRounded';
|
|
46
|
+
export * from './IconUserNotFound';
|
|
47
|
+
export * from './IconSearch';
|
|
48
|
+
export * from './IconPaid';
|
|
49
|
+
export * from './IconClient';
|
|
50
|
+
export * from './IconClientFilled';
|
|
51
|
+
export * from './IconChatFilled';
|
|
52
|
+
export * from './IconCancel';
|
|
53
|
+
export * from './IconCalendarFilled';
|
|
54
|
+
export * from './IconBookmark';
|
|
55
|
+
export * from './IconArrowDown';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { WithTranslation } from 'react-i18next';
|
|
2
2
|
import { CircleRatingRange, CircleRatingDataProps, CircleRatingDataResult, ProgressRangeProps, BreakPointPositionResult, CircleRatingContextData } from '../types/ratingCircleTypes';
|
|
3
3
|
export declare const BREAKPOINT_ICON_SIZE = 20;
|
|
4
|
-
export declare function useCircleRatingRenderData({ progress, size }: CircleRatingDataProps): CircleRatingDataResult;
|
|
5
|
-
export declare function useRangeIndex({ progress, ranges }: ProgressRangeProps): number;
|
|
4
|
+
export declare function useCircleRatingRenderData({ progress, size, maxValue, isReverse, }: CircleRatingDataProps): CircleRatingDataResult;
|
|
5
|
+
export declare function useRangeIndex({ progress, maxValue, ranges, isReverse }: ProgressRangeProps): number;
|
|
6
6
|
export declare function getProgressForBreakPoint({ maxValue, breakPoint, }: {
|
|
7
7
|
maxValue: number;
|
|
8
8
|
breakPoint: number;
|
|
@@ -13,11 +13,14 @@ export declare function useBreakPointsPosition({ maxValue, breakPoints, radius,
|
|
|
13
13
|
radius?: number;
|
|
14
14
|
strokeWidth?: number;
|
|
15
15
|
}): BreakPointPositionResult[];
|
|
16
|
-
export declare function useRatingCircleLegend({ ranges, t }: {
|
|
16
|
+
export declare function useRatingCircleLegend({ ranges, t, isReverse }: {
|
|
17
17
|
ranges: CircleRatingRange[];
|
|
18
18
|
t: WithTranslation['t'];
|
|
19
|
+
isReverse?: boolean;
|
|
19
20
|
}): string[];
|
|
20
|
-
export declare function useRatingCircleBreakPoints({ ranges }: {
|
|
21
|
+
export declare function useRatingCircleBreakPoints({ ranges, maxValue, isReverse, }: {
|
|
21
22
|
ranges: CircleRatingRange[];
|
|
23
|
+
maxValue: number;
|
|
24
|
+
isReverse?: boolean;
|
|
22
25
|
}): number[];
|
|
23
26
|
export declare function useRatingContext(): CircleRatingContextData;
|
|
@@ -14,6 +14,8 @@ export type CircleRatingContent = {
|
|
|
14
14
|
export type CircleRatingDataProps = {
|
|
15
15
|
progress: number;
|
|
16
16
|
size: keyof typeof CircleRatingSize;
|
|
17
|
+
maxValue: number;
|
|
18
|
+
isReverse?: boolean;
|
|
17
19
|
};
|
|
18
20
|
export type CircleRatingDataResult = {
|
|
19
21
|
circleSize: number;
|
|
@@ -27,11 +29,11 @@ export type CircleRatingRange = {
|
|
|
27
29
|
min: number | null;
|
|
28
30
|
max: number | null;
|
|
29
31
|
};
|
|
30
|
-
export type CircleRatingCommonProps = {};
|
|
31
32
|
export type ProgressRangeProps = {
|
|
32
33
|
progress: number;
|
|
34
|
+
maxValue: number;
|
|
33
35
|
ranges: CircleRatingRange[];
|
|
34
|
-
|
|
36
|
+
isReverse?: boolean;
|
|
35
37
|
};
|
|
36
38
|
export type BreakPointPositionProps = {
|
|
37
39
|
radius?: number;
|
|
@@ -51,6 +53,8 @@ export type CircleRatingComponentProps = {
|
|
|
51
53
|
isRatingDisabled?: boolean;
|
|
52
54
|
isShowLegend?: boolean;
|
|
53
55
|
isShowBreakPoints?: boolean;
|
|
56
|
+
isReverse?: boolean;
|
|
57
|
+
isZeroTransparent?: boolean;
|
|
54
58
|
};
|
|
55
59
|
export type CircleRatingContextProps = CircleRatingComponentProps & {
|
|
56
60
|
legend?: string[];
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
type
|
|
2
|
+
type ItemProps = React.HTMLAttributes<HTMLIonItemElement> & {
|
|
3
3
|
leftContent?: React.ReactNode;
|
|
4
4
|
rightContent?: React.ReactNode;
|
|
5
5
|
withBorders?: boolean;
|
|
6
6
|
isDisabled?: boolean;
|
|
7
7
|
};
|
|
8
|
-
export declare const
|
|
8
|
+
export declare const Item: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLIonItemElement> & {
|
|
9
9
|
leftContent?: React.ReactNode;
|
|
10
10
|
rightContent?: React.ReactNode;
|
|
11
11
|
withBorders?: boolean | undefined;
|
|
12
12
|
isDisabled?: boolean | undefined;
|
|
13
13
|
} & React.RefAttributes<HTMLIonItemElement>>;
|
|
14
|
-
declare const _default: React.NamedExoticComponent<
|
|
14
|
+
declare const _default: React.NamedExoticComponent<ItemProps>;
|
|
15
15
|
export default _default;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export { default as ListItems } from './ListItems';
|
|
2
|
-
export { default as
|
|
2
|
+
export { default as Item } from './Item';
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { FC } from 'react';
|
|
2
2
|
import { WithTranslation } from 'react-i18next';
|
|
3
3
|
import { CircleRatingComponentProps } from '../../types';
|
|
4
|
-
declare const RatingCircleWrapper: FC<CircleRatingComponentProps &
|
|
4
|
+
declare const RatingCircleWrapper: FC<CircleRatingComponentProps & {
|
|
5
|
+
t: WithTranslation | any;
|
|
6
|
+
}>;
|
|
5
7
|
export default RatingCircleWrapper;
|
|
@@ -1,4 +1,9 @@
|
|
|
1
1
|
export declare const circleRatingStyles: import("tailwind-variants").TVReturnType<{
|
|
2
|
+
transparent: {
|
|
3
|
+
true: {
|
|
4
|
+
coloredStroke: string;
|
|
5
|
+
};
|
|
6
|
+
};
|
|
2
7
|
isColorless: {
|
|
3
8
|
true: {
|
|
4
9
|
coloredStroke: string;
|
|
@@ -32,6 +37,11 @@ export declare const circleRatingStyles: import("tailwind-variants").TVReturnTyp
|
|
|
32
37
|
contentColor: string;
|
|
33
38
|
legendItem: string;
|
|
34
39
|
}, "", import("tailwind-variants/dist/config").TVConfig<{
|
|
40
|
+
transparent: {
|
|
41
|
+
true: {
|
|
42
|
+
coloredStroke: string;
|
|
43
|
+
};
|
|
44
|
+
};
|
|
35
45
|
isColorless: {
|
|
36
46
|
true: {
|
|
37
47
|
coloredStroke: string;
|
|
@@ -57,6 +67,11 @@ export declare const circleRatingStyles: import("tailwind-variants").TVReturnTyp
|
|
|
57
67
|
};
|
|
58
68
|
};
|
|
59
69
|
}, {
|
|
70
|
+
transparent: {
|
|
71
|
+
true: {
|
|
72
|
+
coloredStroke: string;
|
|
73
|
+
};
|
|
74
|
+
};
|
|
60
75
|
isColorless: {
|
|
61
76
|
true: {
|
|
62
77
|
coloredStroke: string;
|
|
@@ -82,6 +97,11 @@ export declare const circleRatingStyles: import("tailwind-variants").TVReturnTyp
|
|
|
82
97
|
};
|
|
83
98
|
};
|
|
84
99
|
}>, {
|
|
100
|
+
transparent: {
|
|
101
|
+
true: {
|
|
102
|
+
coloredStroke: string;
|
|
103
|
+
};
|
|
104
|
+
};
|
|
85
105
|
isColorless: {
|
|
86
106
|
true: {
|
|
87
107
|
coloredStroke: string;
|
|
@@ -115,6 +135,11 @@ export declare const circleRatingStyles: import("tailwind-variants").TVReturnTyp
|
|
|
115
135
|
contentColor: string;
|
|
116
136
|
legendItem: string;
|
|
117
137
|
}, import("tailwind-variants").TVReturnType<{
|
|
138
|
+
transparent: {
|
|
139
|
+
true: {
|
|
140
|
+
coloredStroke: string;
|
|
141
|
+
};
|
|
142
|
+
};
|
|
118
143
|
isColorless: {
|
|
119
144
|
true: {
|
|
120
145
|
coloredStroke: string;
|
|
@@ -148,6 +173,11 @@ export declare const circleRatingStyles: import("tailwind-variants").TVReturnTyp
|
|
|
148
173
|
contentColor: string;
|
|
149
174
|
legendItem: string;
|
|
150
175
|
}, "", import("tailwind-variants/dist/config").TVConfig<{
|
|
176
|
+
transparent: {
|
|
177
|
+
true: {
|
|
178
|
+
coloredStroke: string;
|
|
179
|
+
};
|
|
180
|
+
};
|
|
151
181
|
isColorless: {
|
|
152
182
|
true: {
|
|
153
183
|
coloredStroke: string;
|
|
@@ -173,6 +203,11 @@ export declare const circleRatingStyles: import("tailwind-variants").TVReturnTyp
|
|
|
173
203
|
};
|
|
174
204
|
};
|
|
175
205
|
}, {
|
|
206
|
+
transparent: {
|
|
207
|
+
true: {
|
|
208
|
+
coloredStroke: string;
|
|
209
|
+
};
|
|
210
|
+
};
|
|
176
211
|
isColorless: {
|
|
177
212
|
true: {
|
|
178
213
|
coloredStroke: string;
|