@algorithm-shift/design-system 1.2.4 → 1.2.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.d.mts +55 -15
- package/dist/index.d.ts +55 -15
- package/dist/index.js +582 -206
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +571 -203
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import * as class_variance_authority_dist_types from 'class-variance-authority/dist/types';
|
|
3
3
|
import * as React$1 from 'react';
|
|
4
|
+
import React__default from 'react';
|
|
4
5
|
import { VariantProps } from 'class-variance-authority';
|
|
5
6
|
import { ClassValue } from 'clsx';
|
|
6
7
|
|
|
@@ -18,6 +19,16 @@ interface ElementProps {
|
|
|
18
19
|
style?: React.CSSProperties;
|
|
19
20
|
}
|
|
20
21
|
|
|
22
|
+
interface TypographyProps extends ElementProps {
|
|
23
|
+
tagName: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'p' | 'span';
|
|
24
|
+
textContent: string;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
interface ImageProps extends ElementProps {
|
|
28
|
+
imageUrl?: string;
|
|
29
|
+
altText?: string;
|
|
30
|
+
}
|
|
31
|
+
|
|
21
32
|
type InputProperties = {
|
|
22
33
|
placeholder?: string;
|
|
23
34
|
regexPattern?: string;
|
|
@@ -35,54 +46,75 @@ type InputProperties = {
|
|
|
35
46
|
interface TextInputProps extends ElementProps, InputProperties { }
|
|
36
47
|
interface EmailInputProps extends ElementProps, InputProperties { }
|
|
37
48
|
interface PasswordInputProps extends ElementProps, InputProperties { }
|
|
49
|
+
interface NumberInputProps extends ElementProps, InputProperties { }
|
|
38
50
|
interface TextAreaProps extends ElementProps, InputProperties { }
|
|
39
51
|
interface UrlInputProps extends ElementProps, InputProperties { }
|
|
52
|
+
interface SearchInputProps extends ElementProps, InputProperties { }
|
|
53
|
+
interface FileInputProps extends ElementProps, Pick<InputProperties, 'placeholder'> { }
|
|
40
54
|
interface CheckboxInputProps extends ElementProps, Pick<InputProperties, 'text'> { }
|
|
41
55
|
interface RadioInputProps extends ElementProps, Pick<InputProperties, 'text'> { }
|
|
42
56
|
interface MultiCheckboxInputProps extends ElementProps, Pick<InputProperties, 'text'> { }
|
|
57
|
+
interface RichTextInputProps extends ElementProps { }
|
|
43
58
|
interface SelectDropdownInputProps extends ElementProps, InputProperties { }
|
|
44
59
|
interface SwitchToggleInputProps extends ElementProps, Pick<InputProperties, 'text'> { }
|
|
45
60
|
interface PhoneInputProps extends ElementProps, InputProperties { }
|
|
46
61
|
interface DateRangeInputProps extends ElementProps { }
|
|
62
|
+
interface DatePickerInputProps extends ElementProps, InputProperties {
|
|
63
|
+
minimumDate?: string;
|
|
64
|
+
customMinimumDate?: string;
|
|
65
|
+
maximumDate?: string;
|
|
66
|
+
customMaximumDate?: string;
|
|
67
|
+
}
|
|
47
68
|
|
|
48
69
|
interface TableProps extends ElementProps {
|
|
49
|
-
columns
|
|
50
|
-
rowActions
|
|
51
|
-
data
|
|
70
|
+
columns?: Record<string, any>;
|
|
71
|
+
rowActions?: Record<string, any>;
|
|
72
|
+
data?: Record<string, any>;
|
|
52
73
|
}
|
|
53
74
|
|
|
54
75
|
interface TabsProps extends ElementProps {
|
|
55
|
-
tabs
|
|
76
|
+
tabs?: Record<string, any>;
|
|
56
77
|
}
|
|
57
78
|
|
|
58
79
|
interface StagesProps extends ElementProps {
|
|
59
|
-
stages
|
|
60
|
-
isShowBtn
|
|
61
|
-
buttonText
|
|
80
|
+
stages?: Record<string, any>;
|
|
81
|
+
isShowBtn?: boolean;
|
|
82
|
+
buttonText?: string;
|
|
62
83
|
}
|
|
63
84
|
|
|
64
85
|
interface ProfileProps extends ElementProps {
|
|
65
|
-
profileType
|
|
66
|
-
showName
|
|
67
|
-
userName
|
|
86
|
+
profileType?: 'avatar' | 'initial';
|
|
87
|
+
showName?: boolean;
|
|
88
|
+
userName?: string;
|
|
68
89
|
}
|
|
69
90
|
|
|
70
91
|
interface NotificationProps extends ElementProps {
|
|
71
|
-
badgeType
|
|
72
|
-
badgeCount
|
|
73
|
-
hideBadgeWhenZero
|
|
92
|
+
badgeType?: 'number' | 'dot';
|
|
93
|
+
badgeCount?: number;
|
|
94
|
+
hideBadgeWhenZero?: boolean;
|
|
74
95
|
}
|
|
75
96
|
|
|
76
97
|
interface LogoProps extends ElementProps {
|
|
77
|
-
imageUrl
|
|
98
|
+
imageUrl?: string;
|
|
78
99
|
}
|
|
79
100
|
|
|
80
101
|
declare const Flex: ({ children, className, style }: ElementProps) => react_jsx_runtime.JSX.Element;
|
|
81
102
|
|
|
82
103
|
declare const Grid: ({ children, className, style }: ElementProps) => react_jsx_runtime.JSX.Element;
|
|
83
104
|
|
|
105
|
+
declare const Typography: ({ className, style, tagName, textContent, }: TypographyProps) => React__default.DetailedReactHTMLElement<{
|
|
106
|
+
style: React__default.CSSProperties | undefined;
|
|
107
|
+
className: string;
|
|
108
|
+
}, HTMLElement>;
|
|
109
|
+
|
|
110
|
+
declare const Shape: ({ children, className, style }: ElementProps) => react_jsx_runtime.JSX.Element;
|
|
111
|
+
|
|
112
|
+
declare const ImageControl$1: ({ className, style, imageUrl, altText, }: ImageProps) => react_jsx_runtime.JSX.Element;
|
|
113
|
+
|
|
84
114
|
declare const TextInput: ({ className, style, ...props }: TextInputProps) => react_jsx_runtime.JSX.Element;
|
|
85
115
|
|
|
116
|
+
declare const NumberInput: ({ className, style, ...props }: NumberInputProps) => react_jsx_runtime.JSX.Element;
|
|
117
|
+
|
|
86
118
|
declare const EmailInput: ({ className, style, ...props }: EmailInputProps) => react_jsx_runtime.JSX.Element;
|
|
87
119
|
|
|
88
120
|
declare const PasswordInput: ({ className, style, ...props }: PasswordInputProps) => react_jsx_runtime.JSX.Element;
|
|
@@ -97,12 +129,20 @@ declare const RadioInput: ({ className, style, ...props }: RadioInputProps) => r
|
|
|
97
129
|
|
|
98
130
|
declare const MultiCheckbox: ({ className, style, ...props }: MultiCheckboxInputProps) => react_jsx_runtime.JSX.Element;
|
|
99
131
|
|
|
132
|
+
declare function RichText({ className, style }: RichTextInputProps): react_jsx_runtime.JSX.Element;
|
|
133
|
+
|
|
100
134
|
declare const Dropdown: ({ className, style, ...props }: SelectDropdownInputProps) => react_jsx_runtime.JSX.Element;
|
|
101
135
|
|
|
102
136
|
declare const SwitchToggle: ({ className, style, ...props }: SwitchToggleInputProps) => react_jsx_runtime.JSX.Element;
|
|
103
137
|
|
|
104
138
|
declare const PhoneInput: ({ className, style, ...props }: PhoneInputProps) => react_jsx_runtime.JSX.Element;
|
|
105
139
|
|
|
140
|
+
declare const SearchInput: ({ className, style, ...props }: SearchInputProps) => react_jsx_runtime.JSX.Element;
|
|
141
|
+
|
|
142
|
+
declare const FileInput: ({ className, style, ...props }: FileInputProps) => react_jsx_runtime.JSX.Element;
|
|
143
|
+
|
|
144
|
+
declare function DatePicker({ className, style, ...props }: DatePickerInputProps): react_jsx_runtime.JSX.Element;
|
|
145
|
+
|
|
106
146
|
declare const DateRange: ({ className, style }: DateRangeInputProps) => react_jsx_runtime.JSX.Element;
|
|
107
147
|
|
|
108
148
|
declare const Table: ({ columns, data, rowActions }: TableProps) => react_jsx_runtime.JSX.Element;
|
|
@@ -121,4 +161,4 @@ declare const ImageControl: ({ className, style, imageUrl }: LogoProps) => react
|
|
|
121
161
|
|
|
122
162
|
declare function cn(...inputs: ClassValue[]): string;
|
|
123
163
|
|
|
124
|
-
export { Button, CheckboxInput, DateRange, Dropdown, EmailInput, Flex as FlexLayout, Grid as GridLayout, ImageControl as Logo, MultiCheckbox, Notification, PasswordInput, PhoneInput, Profile, RadioInput, Spacer, StagesComponent as Stages, SwitchToggle, Table, Tabs, TextInput, Textarea, UrlInput, buttonVariants, cn };
|
|
164
|
+
export { Button, CheckboxInput, DatePicker, DateRange, Dropdown, EmailInput, FileInput, Flex as FlexLayout, Grid as GridLayout, ImageControl$1 as Image, ImageControl as Logo, MultiCheckbox, Notification, NumberInput, PasswordInput, PhoneInput, Profile, RadioInput, RichText, SearchInput, Shape, Spacer, StagesComponent as Stages, SwitchToggle, Table, Tabs, TextInput, Textarea, Typography, UrlInput, buttonVariants, cn };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import * as class_variance_authority_dist_types from 'class-variance-authority/dist/types';
|
|
3
3
|
import * as React$1 from 'react';
|
|
4
|
+
import React__default from 'react';
|
|
4
5
|
import { VariantProps } from 'class-variance-authority';
|
|
5
6
|
import { ClassValue } from 'clsx';
|
|
6
7
|
|
|
@@ -18,6 +19,16 @@ interface ElementProps {
|
|
|
18
19
|
style?: React.CSSProperties;
|
|
19
20
|
}
|
|
20
21
|
|
|
22
|
+
interface TypographyProps extends ElementProps {
|
|
23
|
+
tagName: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'p' | 'span';
|
|
24
|
+
textContent: string;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
interface ImageProps extends ElementProps {
|
|
28
|
+
imageUrl?: string;
|
|
29
|
+
altText?: string;
|
|
30
|
+
}
|
|
31
|
+
|
|
21
32
|
type InputProperties = {
|
|
22
33
|
placeholder?: string;
|
|
23
34
|
regexPattern?: string;
|
|
@@ -35,54 +46,75 @@ type InputProperties = {
|
|
|
35
46
|
interface TextInputProps extends ElementProps, InputProperties { }
|
|
36
47
|
interface EmailInputProps extends ElementProps, InputProperties { }
|
|
37
48
|
interface PasswordInputProps extends ElementProps, InputProperties { }
|
|
49
|
+
interface NumberInputProps extends ElementProps, InputProperties { }
|
|
38
50
|
interface TextAreaProps extends ElementProps, InputProperties { }
|
|
39
51
|
interface UrlInputProps extends ElementProps, InputProperties { }
|
|
52
|
+
interface SearchInputProps extends ElementProps, InputProperties { }
|
|
53
|
+
interface FileInputProps extends ElementProps, Pick<InputProperties, 'placeholder'> { }
|
|
40
54
|
interface CheckboxInputProps extends ElementProps, Pick<InputProperties, 'text'> { }
|
|
41
55
|
interface RadioInputProps extends ElementProps, Pick<InputProperties, 'text'> { }
|
|
42
56
|
interface MultiCheckboxInputProps extends ElementProps, Pick<InputProperties, 'text'> { }
|
|
57
|
+
interface RichTextInputProps extends ElementProps { }
|
|
43
58
|
interface SelectDropdownInputProps extends ElementProps, InputProperties { }
|
|
44
59
|
interface SwitchToggleInputProps extends ElementProps, Pick<InputProperties, 'text'> { }
|
|
45
60
|
interface PhoneInputProps extends ElementProps, InputProperties { }
|
|
46
61
|
interface DateRangeInputProps extends ElementProps { }
|
|
62
|
+
interface DatePickerInputProps extends ElementProps, InputProperties {
|
|
63
|
+
minimumDate?: string;
|
|
64
|
+
customMinimumDate?: string;
|
|
65
|
+
maximumDate?: string;
|
|
66
|
+
customMaximumDate?: string;
|
|
67
|
+
}
|
|
47
68
|
|
|
48
69
|
interface TableProps extends ElementProps {
|
|
49
|
-
columns
|
|
50
|
-
rowActions
|
|
51
|
-
data
|
|
70
|
+
columns?: Record<string, any>;
|
|
71
|
+
rowActions?: Record<string, any>;
|
|
72
|
+
data?: Record<string, any>;
|
|
52
73
|
}
|
|
53
74
|
|
|
54
75
|
interface TabsProps extends ElementProps {
|
|
55
|
-
tabs
|
|
76
|
+
tabs?: Record<string, any>;
|
|
56
77
|
}
|
|
57
78
|
|
|
58
79
|
interface StagesProps extends ElementProps {
|
|
59
|
-
stages
|
|
60
|
-
isShowBtn
|
|
61
|
-
buttonText
|
|
80
|
+
stages?: Record<string, any>;
|
|
81
|
+
isShowBtn?: boolean;
|
|
82
|
+
buttonText?: string;
|
|
62
83
|
}
|
|
63
84
|
|
|
64
85
|
interface ProfileProps extends ElementProps {
|
|
65
|
-
profileType
|
|
66
|
-
showName
|
|
67
|
-
userName
|
|
86
|
+
profileType?: 'avatar' | 'initial';
|
|
87
|
+
showName?: boolean;
|
|
88
|
+
userName?: string;
|
|
68
89
|
}
|
|
69
90
|
|
|
70
91
|
interface NotificationProps extends ElementProps {
|
|
71
|
-
badgeType
|
|
72
|
-
badgeCount
|
|
73
|
-
hideBadgeWhenZero
|
|
92
|
+
badgeType?: 'number' | 'dot';
|
|
93
|
+
badgeCount?: number;
|
|
94
|
+
hideBadgeWhenZero?: boolean;
|
|
74
95
|
}
|
|
75
96
|
|
|
76
97
|
interface LogoProps extends ElementProps {
|
|
77
|
-
imageUrl
|
|
98
|
+
imageUrl?: string;
|
|
78
99
|
}
|
|
79
100
|
|
|
80
101
|
declare const Flex: ({ children, className, style }: ElementProps) => react_jsx_runtime.JSX.Element;
|
|
81
102
|
|
|
82
103
|
declare const Grid: ({ children, className, style }: ElementProps) => react_jsx_runtime.JSX.Element;
|
|
83
104
|
|
|
105
|
+
declare const Typography: ({ className, style, tagName, textContent, }: TypographyProps) => React__default.DetailedReactHTMLElement<{
|
|
106
|
+
style: React__default.CSSProperties | undefined;
|
|
107
|
+
className: string;
|
|
108
|
+
}, HTMLElement>;
|
|
109
|
+
|
|
110
|
+
declare const Shape: ({ children, className, style }: ElementProps) => react_jsx_runtime.JSX.Element;
|
|
111
|
+
|
|
112
|
+
declare const ImageControl$1: ({ className, style, imageUrl, altText, }: ImageProps) => react_jsx_runtime.JSX.Element;
|
|
113
|
+
|
|
84
114
|
declare const TextInput: ({ className, style, ...props }: TextInputProps) => react_jsx_runtime.JSX.Element;
|
|
85
115
|
|
|
116
|
+
declare const NumberInput: ({ className, style, ...props }: NumberInputProps) => react_jsx_runtime.JSX.Element;
|
|
117
|
+
|
|
86
118
|
declare const EmailInput: ({ className, style, ...props }: EmailInputProps) => react_jsx_runtime.JSX.Element;
|
|
87
119
|
|
|
88
120
|
declare const PasswordInput: ({ className, style, ...props }: PasswordInputProps) => react_jsx_runtime.JSX.Element;
|
|
@@ -97,12 +129,20 @@ declare const RadioInput: ({ className, style, ...props }: RadioInputProps) => r
|
|
|
97
129
|
|
|
98
130
|
declare const MultiCheckbox: ({ className, style, ...props }: MultiCheckboxInputProps) => react_jsx_runtime.JSX.Element;
|
|
99
131
|
|
|
132
|
+
declare function RichText({ className, style }: RichTextInputProps): react_jsx_runtime.JSX.Element;
|
|
133
|
+
|
|
100
134
|
declare const Dropdown: ({ className, style, ...props }: SelectDropdownInputProps) => react_jsx_runtime.JSX.Element;
|
|
101
135
|
|
|
102
136
|
declare const SwitchToggle: ({ className, style, ...props }: SwitchToggleInputProps) => react_jsx_runtime.JSX.Element;
|
|
103
137
|
|
|
104
138
|
declare const PhoneInput: ({ className, style, ...props }: PhoneInputProps) => react_jsx_runtime.JSX.Element;
|
|
105
139
|
|
|
140
|
+
declare const SearchInput: ({ className, style, ...props }: SearchInputProps) => react_jsx_runtime.JSX.Element;
|
|
141
|
+
|
|
142
|
+
declare const FileInput: ({ className, style, ...props }: FileInputProps) => react_jsx_runtime.JSX.Element;
|
|
143
|
+
|
|
144
|
+
declare function DatePicker({ className, style, ...props }: DatePickerInputProps): react_jsx_runtime.JSX.Element;
|
|
145
|
+
|
|
106
146
|
declare const DateRange: ({ className, style }: DateRangeInputProps) => react_jsx_runtime.JSX.Element;
|
|
107
147
|
|
|
108
148
|
declare const Table: ({ columns, data, rowActions }: TableProps) => react_jsx_runtime.JSX.Element;
|
|
@@ -121,4 +161,4 @@ declare const ImageControl: ({ className, style, imageUrl }: LogoProps) => react
|
|
|
121
161
|
|
|
122
162
|
declare function cn(...inputs: ClassValue[]): string;
|
|
123
163
|
|
|
124
|
-
export { Button, CheckboxInput, DateRange, Dropdown, EmailInput, Flex as FlexLayout, Grid as GridLayout, ImageControl as Logo, MultiCheckbox, Notification, PasswordInput, PhoneInput, Profile, RadioInput, Spacer, StagesComponent as Stages, SwitchToggle, Table, Tabs, TextInput, Textarea, UrlInput, buttonVariants, cn };
|
|
164
|
+
export { Button, CheckboxInput, DatePicker, DateRange, Dropdown, EmailInput, FileInput, Flex as FlexLayout, Grid as GridLayout, ImageControl$1 as Image, ImageControl as Logo, MultiCheckbox, Notification, NumberInput, PasswordInput, PhoneInput, Profile, RadioInput, RichText, SearchInput, Shape, Spacer, StagesComponent as Stages, SwitchToggle, Table, Tabs, TextInput, Textarea, Typography, UrlInput, buttonVariants, cn };
|