@lets-events/react 12.10.13 → 12.10.15
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/.turbo/turbo-build.log +6 -6
- package/CHANGELOG.md +12 -0
- package/dist/index.d.mts +186 -7
- package/dist/index.d.ts +186 -7
- package/dist/index.js +2 -2
- package/dist/index.mjs +2 -2
- package/package.json +1 -1
- package/src/components/Alert.tsx +1 -1
- package/src/components/Button/index.tsx +17 -8
- package/src/components/Flex.tsx +18 -6
- package/src/components/Text.tsx +18 -3
- package/src/components/TextField.tsx +1 -1
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
> @lets-events/react@12.10.
|
|
2
|
+
> @lets-events/react@12.10.15 build
|
|
3
3
|
> tsup src/index.tsx --format esm,cjs --dts --external react
|
|
4
4
|
|
|
5
5
|
[34mCLI[39m Building entry: src/index.tsx
|
|
@@ -10,10 +10,10 @@
|
|
|
10
10
|
[34mESM[39m Build start
|
|
11
11
|
[34mCJS[39m Build start
|
|
12
12
|
[32mCJS[39m [1mdist\index.js [22m[32m432.14 KB[39m
|
|
13
|
-
[32mCJS[39m ⚡️ Build success in
|
|
13
|
+
[32mCJS[39m ⚡️ Build success in 302ms
|
|
14
14
|
[32mESM[39m [1mdist\index.mjs [22m[32m416.46 KB[39m
|
|
15
|
-
[32mESM[39m ⚡️ Build success in
|
|
15
|
+
[32mESM[39m ⚡️ Build success in 303ms
|
|
16
16
|
[34mDTS[39m Build start
|
|
17
|
-
[32mDTS[39m ⚡️ Build success in
|
|
18
|
-
[32mDTS[39m [1mdist\index.d.mts [22m[
|
|
19
|
-
[32mDTS[39m [1mdist\index.d.ts [22m[
|
|
17
|
+
[32mDTS[39m ⚡️ Build success in 5091ms
|
|
18
|
+
[32mDTS[39m [1mdist\index.d.mts [22m[32m409.63 KB[39m
|
|
19
|
+
[32mDTS[39m [1mdist\index.d.ts [22m[32m409.63 KB[39m
|
package/CHANGELOG.md
CHANGED
package/dist/index.d.mts
CHANGED
|
@@ -5,11 +5,10 @@ import PropTypes from 'prop-types';
|
|
|
5
5
|
import * as _stitches_react_types_styled_component from '@stitches/react/types/styled-component';
|
|
6
6
|
import * as _stitches_react_types_css_util from '@stitches/react/types/css-util';
|
|
7
7
|
import * as React$1 from 'react';
|
|
8
|
-
import React__default, {
|
|
8
|
+
import React__default, { ElementType, ReactNode, CSSProperties, ComponentProps, ButtonHTMLAttributes, MouseEvent, HTMLAttributes, JSX } from 'react';
|
|
9
9
|
import * as _radix_ui_themes from '@radix-ui/themes';
|
|
10
10
|
import { TextField as TextField$1, RadioGroup as RadioGroup$1, CheckboxGroup as CheckboxGroup$1, DropdownMenu as DropdownMenu$1, AlertDialog, Switch as Switch$1 } from '@radix-ui/themes';
|
|
11
11
|
import { Colors } from '@lets-events/tokens';
|
|
12
|
-
import { VariantProps } from '@stitches/react';
|
|
13
12
|
import { MaskOptions, format, unformat } from '@react-input/mask';
|
|
14
13
|
import { Dialog } from 'radix-ui';
|
|
15
14
|
import * as TooltipPrimitive from '@radix-ui/react-tooltip';
|
|
@@ -31,6 +30,148 @@ declare const Icon: {
|
|
|
31
30
|
};
|
|
32
31
|
};
|
|
33
32
|
|
|
33
|
+
declare const typographyValues: {
|
|
34
|
+
displayLarge: {
|
|
35
|
+
fontSize: string;
|
|
36
|
+
lineHeight: string;
|
|
37
|
+
letterSpacing: string;
|
|
38
|
+
};
|
|
39
|
+
displayMedium: {
|
|
40
|
+
fontSize: string;
|
|
41
|
+
lineHeight: string;
|
|
42
|
+
letterSpacing: string;
|
|
43
|
+
};
|
|
44
|
+
displaySmall: {
|
|
45
|
+
fontSize: string;
|
|
46
|
+
lineHeight: string;
|
|
47
|
+
letterSpacing: string;
|
|
48
|
+
};
|
|
49
|
+
headline1: {
|
|
50
|
+
fontSize: string;
|
|
51
|
+
lineHeight: string;
|
|
52
|
+
};
|
|
53
|
+
headline2: {
|
|
54
|
+
fontSize: string;
|
|
55
|
+
lineHeight: string;
|
|
56
|
+
};
|
|
57
|
+
headline3: {
|
|
58
|
+
fontSize: string;
|
|
59
|
+
lineHeight: string;
|
|
60
|
+
};
|
|
61
|
+
headline4: {
|
|
62
|
+
fontSize: string;
|
|
63
|
+
lineHeight: string;
|
|
64
|
+
};
|
|
65
|
+
headline5: {
|
|
66
|
+
fontSize: string;
|
|
67
|
+
lineHeight: string;
|
|
68
|
+
};
|
|
69
|
+
headline6: {
|
|
70
|
+
fontSize: string;
|
|
71
|
+
lineHeight: string;
|
|
72
|
+
};
|
|
73
|
+
headline7: {
|
|
74
|
+
fontSize: string;
|
|
75
|
+
lineHeight: string;
|
|
76
|
+
};
|
|
77
|
+
headline8: {
|
|
78
|
+
fontSize: string;
|
|
79
|
+
lineHeight: string;
|
|
80
|
+
};
|
|
81
|
+
bodyXL: {
|
|
82
|
+
fontSize: string;
|
|
83
|
+
lineHeight: string;
|
|
84
|
+
};
|
|
85
|
+
bodyL: {
|
|
86
|
+
fontSize: string;
|
|
87
|
+
lineHeight: string;
|
|
88
|
+
};
|
|
89
|
+
bodyM: {
|
|
90
|
+
fontSize: string;
|
|
91
|
+
lineHeight: string;
|
|
92
|
+
};
|
|
93
|
+
bodyS: {
|
|
94
|
+
fontSize: string;
|
|
95
|
+
lineHeight: string;
|
|
96
|
+
};
|
|
97
|
+
bodyXS: {
|
|
98
|
+
fontSize: string;
|
|
99
|
+
lineHeight: string;
|
|
100
|
+
};
|
|
101
|
+
bodyXXS: {
|
|
102
|
+
fontSize: string;
|
|
103
|
+
lineHeight: string;
|
|
104
|
+
};
|
|
105
|
+
badgeLarge: {
|
|
106
|
+
fontSize: string;
|
|
107
|
+
lineHeight: string;
|
|
108
|
+
};
|
|
109
|
+
badgeMedium: {
|
|
110
|
+
fontSize: string;
|
|
111
|
+
lineHeight: string;
|
|
112
|
+
};
|
|
113
|
+
badgeSmall: {
|
|
114
|
+
fontSize: string;
|
|
115
|
+
lineHeight: string;
|
|
116
|
+
};
|
|
117
|
+
badgeExtraSmall: {
|
|
118
|
+
fontSize: string;
|
|
119
|
+
lineHeight: string;
|
|
120
|
+
};
|
|
121
|
+
tooltip: {
|
|
122
|
+
fontSize: string;
|
|
123
|
+
lineHeight: string;
|
|
124
|
+
};
|
|
125
|
+
popoversRegular: {
|
|
126
|
+
fontSize: string;
|
|
127
|
+
lineHeight: string;
|
|
128
|
+
};
|
|
129
|
+
captionLarge: {
|
|
130
|
+
fontSize: string;
|
|
131
|
+
lineHeight: string;
|
|
132
|
+
};
|
|
133
|
+
captionMedium: {
|
|
134
|
+
fontSize: string;
|
|
135
|
+
lineHeight: string;
|
|
136
|
+
};
|
|
137
|
+
captionSmall: {
|
|
138
|
+
fontSize: string;
|
|
139
|
+
lineHeight: string;
|
|
140
|
+
};
|
|
141
|
+
buttonLarge: {
|
|
142
|
+
fontSize: string;
|
|
143
|
+
lineHeight: string;
|
|
144
|
+
};
|
|
145
|
+
buttonMedium: {
|
|
146
|
+
fontSize: string;
|
|
147
|
+
lineHeight: string;
|
|
148
|
+
};
|
|
149
|
+
buttonSmall: {
|
|
150
|
+
fontSize: string;
|
|
151
|
+
lineHeight: string;
|
|
152
|
+
};
|
|
153
|
+
buttonExtraSmall: {
|
|
154
|
+
fontSize: string;
|
|
155
|
+
lineHeight: string;
|
|
156
|
+
};
|
|
157
|
+
labelLarge: {
|
|
158
|
+
fontSize: string;
|
|
159
|
+
lineHeight: string;
|
|
160
|
+
};
|
|
161
|
+
labelMedium: {
|
|
162
|
+
fontSize: string;
|
|
163
|
+
lineHeight: string;
|
|
164
|
+
};
|
|
165
|
+
labelSmall: {
|
|
166
|
+
fontSize: string;
|
|
167
|
+
lineHeight: string;
|
|
168
|
+
};
|
|
169
|
+
labelExtraSmall: {
|
|
170
|
+
fontSize: string;
|
|
171
|
+
lineHeight: string;
|
|
172
|
+
};
|
|
173
|
+
};
|
|
174
|
+
|
|
34
175
|
declare const TextStyle: _stitches_react_types_styled_component.StyledComponent<React$1.ForwardRefExoticComponent<_radix_ui_themes.TextProps & React$1.RefAttributes<HTMLSpanElement>>, {
|
|
35
176
|
typography?: "tooltip" | "displayLarge" | "displayMedium" | "displaySmall" | "headline1" | "headline2" | "headline3" | "headline4" | "headline5" | "headline6" | "headline7" | "headline8" | "bodyXL" | "bodyL" | "bodyM" | "bodyS" | "bodyXS" | "bodyXXS" | "badgeLarge" | "badgeMedium" | "badgeSmall" | "badgeExtraSmall" | "popoversRegular" | "captionLarge" | "captionMedium" | "captionSmall" | "buttonLarge" | "buttonMedium" | "buttonSmall" | "buttonExtraSmall" | "labelLarge" | "labelMedium" | "labelSmall" | "labelExtraSmall" | undefined;
|
|
36
177
|
fontWeight?: "bold" | "medium" | "regular" | "semibold" | undefined;
|
|
@@ -408,10 +549,24 @@ declare const TextStyle: _stitches_react_types_styled_component.StyledComponent<
|
|
|
408
549
|
transition: "transitions";
|
|
409
550
|
zIndex: "zIndices";
|
|
410
551
|
}, {}>>;
|
|
411
|
-
type
|
|
552
|
+
type Typography = keyof typeof typographyValues;
|
|
553
|
+
type FontWeight = "regular" | "medium" | "semibold" | "bold";
|
|
554
|
+
type TextProps = {
|
|
412
555
|
as?: ElementType;
|
|
413
556
|
asChild?: boolean;
|
|
414
557
|
color?: keyof Colors;
|
|
558
|
+
typography?: Typography;
|
|
559
|
+
fontWeight?: FontWeight;
|
|
560
|
+
children?: ReactNode;
|
|
561
|
+
id?: string;
|
|
562
|
+
role?: string;
|
|
563
|
+
"aria-label"?: string;
|
|
564
|
+
"aria-labelledby"?: string;
|
|
565
|
+
"aria-describedby"?: string;
|
|
566
|
+
"aria-hidden"?: boolean | "true" | "false";
|
|
567
|
+
className?: string;
|
|
568
|
+
style?: CSSProperties;
|
|
569
|
+
css?: ComponentProps<typeof TextStyle>["css"];
|
|
415
570
|
};
|
|
416
571
|
declare function Text({ color, ...props }: TextProps): react_jsx_runtime.JSX.Element;
|
|
417
572
|
|
|
@@ -799,10 +954,22 @@ declare const ButtonStyled: _stitches_react_types_styled_component.StyledCompone
|
|
|
799
954
|
zIndex: "zIndices";
|
|
800
955
|
}, {}>>;
|
|
801
956
|
|
|
802
|
-
type
|
|
803
|
-
interface ButtonProps extends
|
|
957
|
+
type TextAlign = "center" | "left" | "right";
|
|
958
|
+
interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
959
|
+
color?: "brand" | "purple" | "error" | "info" | "success" | "warning" | "neutral" | "white";
|
|
960
|
+
size?: "extraSmall" | "small" | "medium" | "large";
|
|
961
|
+
variant?: "text" | "toggle" | "contained" | "outlined" | "menuDropdownItem" | "menuDropdownItemDelete";
|
|
962
|
+
fontWeight?: "regular" | "medium" | "semibold" | "bold";
|
|
963
|
+
textAlign?: TextAlign;
|
|
964
|
+
outlinedBgColor?: "neutral" | "transparent";
|
|
965
|
+
radii?: "full";
|
|
966
|
+
isCircle?: boolean;
|
|
804
967
|
asChild?: boolean;
|
|
805
968
|
loading?: boolean;
|
|
969
|
+
children?: ReactNode;
|
|
970
|
+
className?: string;
|
|
971
|
+
style?: CSSProperties;
|
|
972
|
+
css?: ComponentProps<typeof ButtonStyled>["css"];
|
|
806
973
|
}
|
|
807
974
|
declare function Button({ asChild, children, loading, ...props }: ButtonProps): react_jsx_runtime.JSX.Element;
|
|
808
975
|
|
|
@@ -13154,9 +13321,21 @@ declare const FlexStyled: _stitches_react_types_styled_component.StyledComponent
|
|
|
13154
13321
|
transition: "transitions";
|
|
13155
13322
|
zIndex: "zIndices";
|
|
13156
13323
|
}, {}>>;
|
|
13157
|
-
type
|
|
13324
|
+
type StitchesFlexProps = ComponentProps<typeof FlexStyled>;
|
|
13325
|
+
type GapValue = NonNullable<StitchesFlexProps['gap']>;
|
|
13326
|
+
type FlexProps = {
|
|
13158
13327
|
as?: ElementType;
|
|
13159
|
-
children:
|
|
13328
|
+
children: ReactNode;
|
|
13329
|
+
display?: 'flex' | 'inline-flex';
|
|
13330
|
+
align?: 'start' | 'center' | 'end' | 'stretch' | 'baseline';
|
|
13331
|
+
justify?: 'start' | 'center' | 'end' | 'between' | 'around' | 'evenly';
|
|
13332
|
+
direction?: 'row' | 'column' | 'row-reverse' | 'column-reverse';
|
|
13333
|
+
gap?: GapValue;
|
|
13334
|
+
gapX?: Exclude<GapValue, 0 | '0'>;
|
|
13335
|
+
gapY?: Exclude<GapValue, 0 | '0'>;
|
|
13336
|
+
className?: string;
|
|
13337
|
+
style?: CSSProperties;
|
|
13338
|
+
css?: StitchesFlexProps['css'];
|
|
13160
13339
|
};
|
|
13161
13340
|
declare function Flex({ children, ...props }: FlexProps): react_jsx_runtime.JSX.Element;
|
|
13162
13341
|
|
package/dist/index.d.ts
CHANGED
|
@@ -5,11 +5,10 @@ import PropTypes from 'prop-types';
|
|
|
5
5
|
import * as _stitches_react_types_styled_component from '@stitches/react/types/styled-component';
|
|
6
6
|
import * as _stitches_react_types_css_util from '@stitches/react/types/css-util';
|
|
7
7
|
import * as React$1 from 'react';
|
|
8
|
-
import React__default, {
|
|
8
|
+
import React__default, { ElementType, ReactNode, CSSProperties, ComponentProps, ButtonHTMLAttributes, MouseEvent, HTMLAttributes, JSX } from 'react';
|
|
9
9
|
import * as _radix_ui_themes from '@radix-ui/themes';
|
|
10
10
|
import { TextField as TextField$1, RadioGroup as RadioGroup$1, CheckboxGroup as CheckboxGroup$1, DropdownMenu as DropdownMenu$1, AlertDialog, Switch as Switch$1 } from '@radix-ui/themes';
|
|
11
11
|
import { Colors } from '@lets-events/tokens';
|
|
12
|
-
import { VariantProps } from '@stitches/react';
|
|
13
12
|
import { MaskOptions, format, unformat } from '@react-input/mask';
|
|
14
13
|
import { Dialog } from 'radix-ui';
|
|
15
14
|
import * as TooltipPrimitive from '@radix-ui/react-tooltip';
|
|
@@ -31,6 +30,148 @@ declare const Icon: {
|
|
|
31
30
|
};
|
|
32
31
|
};
|
|
33
32
|
|
|
33
|
+
declare const typographyValues: {
|
|
34
|
+
displayLarge: {
|
|
35
|
+
fontSize: string;
|
|
36
|
+
lineHeight: string;
|
|
37
|
+
letterSpacing: string;
|
|
38
|
+
};
|
|
39
|
+
displayMedium: {
|
|
40
|
+
fontSize: string;
|
|
41
|
+
lineHeight: string;
|
|
42
|
+
letterSpacing: string;
|
|
43
|
+
};
|
|
44
|
+
displaySmall: {
|
|
45
|
+
fontSize: string;
|
|
46
|
+
lineHeight: string;
|
|
47
|
+
letterSpacing: string;
|
|
48
|
+
};
|
|
49
|
+
headline1: {
|
|
50
|
+
fontSize: string;
|
|
51
|
+
lineHeight: string;
|
|
52
|
+
};
|
|
53
|
+
headline2: {
|
|
54
|
+
fontSize: string;
|
|
55
|
+
lineHeight: string;
|
|
56
|
+
};
|
|
57
|
+
headline3: {
|
|
58
|
+
fontSize: string;
|
|
59
|
+
lineHeight: string;
|
|
60
|
+
};
|
|
61
|
+
headline4: {
|
|
62
|
+
fontSize: string;
|
|
63
|
+
lineHeight: string;
|
|
64
|
+
};
|
|
65
|
+
headline5: {
|
|
66
|
+
fontSize: string;
|
|
67
|
+
lineHeight: string;
|
|
68
|
+
};
|
|
69
|
+
headline6: {
|
|
70
|
+
fontSize: string;
|
|
71
|
+
lineHeight: string;
|
|
72
|
+
};
|
|
73
|
+
headline7: {
|
|
74
|
+
fontSize: string;
|
|
75
|
+
lineHeight: string;
|
|
76
|
+
};
|
|
77
|
+
headline8: {
|
|
78
|
+
fontSize: string;
|
|
79
|
+
lineHeight: string;
|
|
80
|
+
};
|
|
81
|
+
bodyXL: {
|
|
82
|
+
fontSize: string;
|
|
83
|
+
lineHeight: string;
|
|
84
|
+
};
|
|
85
|
+
bodyL: {
|
|
86
|
+
fontSize: string;
|
|
87
|
+
lineHeight: string;
|
|
88
|
+
};
|
|
89
|
+
bodyM: {
|
|
90
|
+
fontSize: string;
|
|
91
|
+
lineHeight: string;
|
|
92
|
+
};
|
|
93
|
+
bodyS: {
|
|
94
|
+
fontSize: string;
|
|
95
|
+
lineHeight: string;
|
|
96
|
+
};
|
|
97
|
+
bodyXS: {
|
|
98
|
+
fontSize: string;
|
|
99
|
+
lineHeight: string;
|
|
100
|
+
};
|
|
101
|
+
bodyXXS: {
|
|
102
|
+
fontSize: string;
|
|
103
|
+
lineHeight: string;
|
|
104
|
+
};
|
|
105
|
+
badgeLarge: {
|
|
106
|
+
fontSize: string;
|
|
107
|
+
lineHeight: string;
|
|
108
|
+
};
|
|
109
|
+
badgeMedium: {
|
|
110
|
+
fontSize: string;
|
|
111
|
+
lineHeight: string;
|
|
112
|
+
};
|
|
113
|
+
badgeSmall: {
|
|
114
|
+
fontSize: string;
|
|
115
|
+
lineHeight: string;
|
|
116
|
+
};
|
|
117
|
+
badgeExtraSmall: {
|
|
118
|
+
fontSize: string;
|
|
119
|
+
lineHeight: string;
|
|
120
|
+
};
|
|
121
|
+
tooltip: {
|
|
122
|
+
fontSize: string;
|
|
123
|
+
lineHeight: string;
|
|
124
|
+
};
|
|
125
|
+
popoversRegular: {
|
|
126
|
+
fontSize: string;
|
|
127
|
+
lineHeight: string;
|
|
128
|
+
};
|
|
129
|
+
captionLarge: {
|
|
130
|
+
fontSize: string;
|
|
131
|
+
lineHeight: string;
|
|
132
|
+
};
|
|
133
|
+
captionMedium: {
|
|
134
|
+
fontSize: string;
|
|
135
|
+
lineHeight: string;
|
|
136
|
+
};
|
|
137
|
+
captionSmall: {
|
|
138
|
+
fontSize: string;
|
|
139
|
+
lineHeight: string;
|
|
140
|
+
};
|
|
141
|
+
buttonLarge: {
|
|
142
|
+
fontSize: string;
|
|
143
|
+
lineHeight: string;
|
|
144
|
+
};
|
|
145
|
+
buttonMedium: {
|
|
146
|
+
fontSize: string;
|
|
147
|
+
lineHeight: string;
|
|
148
|
+
};
|
|
149
|
+
buttonSmall: {
|
|
150
|
+
fontSize: string;
|
|
151
|
+
lineHeight: string;
|
|
152
|
+
};
|
|
153
|
+
buttonExtraSmall: {
|
|
154
|
+
fontSize: string;
|
|
155
|
+
lineHeight: string;
|
|
156
|
+
};
|
|
157
|
+
labelLarge: {
|
|
158
|
+
fontSize: string;
|
|
159
|
+
lineHeight: string;
|
|
160
|
+
};
|
|
161
|
+
labelMedium: {
|
|
162
|
+
fontSize: string;
|
|
163
|
+
lineHeight: string;
|
|
164
|
+
};
|
|
165
|
+
labelSmall: {
|
|
166
|
+
fontSize: string;
|
|
167
|
+
lineHeight: string;
|
|
168
|
+
};
|
|
169
|
+
labelExtraSmall: {
|
|
170
|
+
fontSize: string;
|
|
171
|
+
lineHeight: string;
|
|
172
|
+
};
|
|
173
|
+
};
|
|
174
|
+
|
|
34
175
|
declare const TextStyle: _stitches_react_types_styled_component.StyledComponent<React$1.ForwardRefExoticComponent<_radix_ui_themes.TextProps & React$1.RefAttributes<HTMLSpanElement>>, {
|
|
35
176
|
typography?: "tooltip" | "displayLarge" | "displayMedium" | "displaySmall" | "headline1" | "headline2" | "headline3" | "headline4" | "headline5" | "headline6" | "headline7" | "headline8" | "bodyXL" | "bodyL" | "bodyM" | "bodyS" | "bodyXS" | "bodyXXS" | "badgeLarge" | "badgeMedium" | "badgeSmall" | "badgeExtraSmall" | "popoversRegular" | "captionLarge" | "captionMedium" | "captionSmall" | "buttonLarge" | "buttonMedium" | "buttonSmall" | "buttonExtraSmall" | "labelLarge" | "labelMedium" | "labelSmall" | "labelExtraSmall" | undefined;
|
|
36
177
|
fontWeight?: "bold" | "medium" | "regular" | "semibold" | undefined;
|
|
@@ -408,10 +549,24 @@ declare const TextStyle: _stitches_react_types_styled_component.StyledComponent<
|
|
|
408
549
|
transition: "transitions";
|
|
409
550
|
zIndex: "zIndices";
|
|
410
551
|
}, {}>>;
|
|
411
|
-
type
|
|
552
|
+
type Typography = keyof typeof typographyValues;
|
|
553
|
+
type FontWeight = "regular" | "medium" | "semibold" | "bold";
|
|
554
|
+
type TextProps = {
|
|
412
555
|
as?: ElementType;
|
|
413
556
|
asChild?: boolean;
|
|
414
557
|
color?: keyof Colors;
|
|
558
|
+
typography?: Typography;
|
|
559
|
+
fontWeight?: FontWeight;
|
|
560
|
+
children?: ReactNode;
|
|
561
|
+
id?: string;
|
|
562
|
+
role?: string;
|
|
563
|
+
"aria-label"?: string;
|
|
564
|
+
"aria-labelledby"?: string;
|
|
565
|
+
"aria-describedby"?: string;
|
|
566
|
+
"aria-hidden"?: boolean | "true" | "false";
|
|
567
|
+
className?: string;
|
|
568
|
+
style?: CSSProperties;
|
|
569
|
+
css?: ComponentProps<typeof TextStyle>["css"];
|
|
415
570
|
};
|
|
416
571
|
declare function Text({ color, ...props }: TextProps): react_jsx_runtime.JSX.Element;
|
|
417
572
|
|
|
@@ -799,10 +954,22 @@ declare const ButtonStyled: _stitches_react_types_styled_component.StyledCompone
|
|
|
799
954
|
zIndex: "zIndices";
|
|
800
955
|
}, {}>>;
|
|
801
956
|
|
|
802
|
-
type
|
|
803
|
-
interface ButtonProps extends
|
|
957
|
+
type TextAlign = "center" | "left" | "right";
|
|
958
|
+
interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
959
|
+
color?: "brand" | "purple" | "error" | "info" | "success" | "warning" | "neutral" | "white";
|
|
960
|
+
size?: "extraSmall" | "small" | "medium" | "large";
|
|
961
|
+
variant?: "text" | "toggle" | "contained" | "outlined" | "menuDropdownItem" | "menuDropdownItemDelete";
|
|
962
|
+
fontWeight?: "regular" | "medium" | "semibold" | "bold";
|
|
963
|
+
textAlign?: TextAlign;
|
|
964
|
+
outlinedBgColor?: "neutral" | "transparent";
|
|
965
|
+
radii?: "full";
|
|
966
|
+
isCircle?: boolean;
|
|
804
967
|
asChild?: boolean;
|
|
805
968
|
loading?: boolean;
|
|
969
|
+
children?: ReactNode;
|
|
970
|
+
className?: string;
|
|
971
|
+
style?: CSSProperties;
|
|
972
|
+
css?: ComponentProps<typeof ButtonStyled>["css"];
|
|
806
973
|
}
|
|
807
974
|
declare function Button({ asChild, children, loading, ...props }: ButtonProps): react_jsx_runtime.JSX.Element;
|
|
808
975
|
|
|
@@ -13154,9 +13321,21 @@ declare const FlexStyled: _stitches_react_types_styled_component.StyledComponent
|
|
|
13154
13321
|
transition: "transitions";
|
|
13155
13322
|
zIndex: "zIndices";
|
|
13156
13323
|
}, {}>>;
|
|
13157
|
-
type
|
|
13324
|
+
type StitchesFlexProps = ComponentProps<typeof FlexStyled>;
|
|
13325
|
+
type GapValue = NonNullable<StitchesFlexProps['gap']>;
|
|
13326
|
+
type FlexProps = {
|
|
13158
13327
|
as?: ElementType;
|
|
13159
|
-
children:
|
|
13328
|
+
children: ReactNode;
|
|
13329
|
+
display?: 'flex' | 'inline-flex';
|
|
13330
|
+
align?: 'start' | 'center' | 'end' | 'stretch' | 'baseline';
|
|
13331
|
+
justify?: 'start' | 'center' | 'end' | 'between' | 'around' | 'evenly';
|
|
13332
|
+
direction?: 'row' | 'column' | 'row-reverse' | 'column-reverse';
|
|
13333
|
+
gap?: GapValue;
|
|
13334
|
+
gapX?: Exclude<GapValue, 0 | '0'>;
|
|
13335
|
+
gapY?: Exclude<GapValue, 0 | '0'>;
|
|
13336
|
+
className?: string;
|
|
13337
|
+
style?: CSSProperties;
|
|
13338
|
+
css?: StitchesFlexProps['css'];
|
|
13160
13339
|
};
|
|
13161
13340
|
declare function Flex({ children, ...props }: FlexProps): react_jsx_runtime.JSX.Element;
|
|
13162
13341
|
|
package/dist/index.js
CHANGED
|
@@ -2881,7 +2881,7 @@ var TextField = import_react3.default.forwardRef(
|
|
|
2881
2881
|
onInput == null ? void 0 : onInput(e);
|
|
2882
2882
|
};
|
|
2883
2883
|
return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(Flex, { direction: "column", css: { width: "100%", position: "relative" }, children: [
|
|
2884
|
-
/* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(Flex, { gap:
|
|
2884
|
+
/* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(Flex, { gap: 0, css: { width: "100%" }, children: [
|
|
2885
2885
|
!!addon && /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
|
|
2886
2886
|
InputAddon,
|
|
2887
2887
|
{
|
|
@@ -9424,7 +9424,7 @@ function Alert(_a) {
|
|
|
9424
9424
|
] })
|
|
9425
9425
|
] }),
|
|
9426
9426
|
completAlert.onAction || completAlert.cancel ? /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(AlertDialoghrStyled, {}) : null,
|
|
9427
|
-
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)(AlertDialogRowStyled, { children: /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)(Flex, {
|
|
9427
|
+
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)(AlertDialogRowStyled, { children: /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)(Flex, { justify: "end", css: { width: "100%" }, children: [
|
|
9428
9428
|
completAlert.onAction && /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_themes13.AlertDialog.Action, { children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
|
|
9429
9429
|
Button,
|
|
9430
9430
|
{
|
package/dist/index.mjs
CHANGED
|
@@ -2760,7 +2760,7 @@ var TextField = React.forwardRef(
|
|
|
2760
2760
|
onInput == null ? void 0 : onInput(e);
|
|
2761
2761
|
};
|
|
2762
2762
|
return /* @__PURE__ */ jsxs2(Flex, { direction: "column", css: { width: "100%", position: "relative" }, children: [
|
|
2763
|
-
/* @__PURE__ */ jsxs2(Flex, { gap:
|
|
2763
|
+
/* @__PURE__ */ jsxs2(Flex, { gap: 0, css: { width: "100%" }, children: [
|
|
2764
2764
|
!!addon && /* @__PURE__ */ jsx7(
|
|
2765
2765
|
InputAddon,
|
|
2766
2766
|
{
|
|
@@ -9307,7 +9307,7 @@ function Alert(_a) {
|
|
|
9307
9307
|
] })
|
|
9308
9308
|
] }),
|
|
9309
9309
|
completAlert.onAction || completAlert.cancel ? /* @__PURE__ */ jsx19(AlertDialoghrStyled, {}) : null,
|
|
9310
|
-
/* @__PURE__ */ jsx19(AlertDialogRowStyled, { children: /* @__PURE__ */ jsxs11(Flex, {
|
|
9310
|
+
/* @__PURE__ */ jsx19(AlertDialogRowStyled, { children: /* @__PURE__ */ jsxs11(Flex, { justify: "end", css: { width: "100%" }, children: [
|
|
9311
9311
|
completAlert.onAction && /* @__PURE__ */ jsx19(AlertDialog.Action, { children: /* @__PURE__ */ jsx19(
|
|
9312
9312
|
Button,
|
|
9313
9313
|
{
|
package/package.json
CHANGED
package/src/components/Alert.tsx
CHANGED
|
@@ -274,7 +274,7 @@ export function Alert({
|
|
|
274
274
|
<AlertDialoghrStyled />
|
|
275
275
|
) : null}
|
|
276
276
|
<AlertDialogRowStyled>
|
|
277
|
-
<Flex
|
|
277
|
+
<Flex justify="end" css={{ width: "100%" }}>
|
|
278
278
|
{completAlert.onAction && (
|
|
279
279
|
<AlertDialog.Action>
|
|
280
280
|
<Button
|
|
@@ -1,13 +1,12 @@
|
|
|
1
|
-
import { ComponentProps, useMemo } from "react";
|
|
1
|
+
import { ButtonHTMLAttributes, ComponentProps, CSSProperties, ReactNode, useMemo } from "react";
|
|
2
2
|
import { ButtonStyled, SpinningDiv } from "./styledComponents";
|
|
3
3
|
import { Button as ButtonRadix } from "@radix-ui/themes";
|
|
4
|
-
import type { VariantProps } from "@stitches/react";
|
|
5
4
|
import Icon, { IconProps } from "../Icon";
|
|
6
5
|
import { Flex } from "../Flex";
|
|
7
6
|
|
|
8
|
-
type
|
|
7
|
+
type TextAlign = "center" | "left" | "right";
|
|
9
8
|
|
|
10
|
-
const getJustifyByTextAlign = (textAlign:
|
|
9
|
+
const getJustifyByTextAlign = (textAlign: TextAlign) => {
|
|
11
10
|
switch (textAlign) {
|
|
12
11
|
case "left":
|
|
13
12
|
return "start";
|
|
@@ -18,11 +17,21 @@ const getJustifyByTextAlign = (textAlign: ButtonVariantProps["textAlign"]) => {
|
|
|
18
17
|
}
|
|
19
18
|
};
|
|
20
19
|
|
|
21
|
-
export interface ButtonProps
|
|
22
|
-
|
|
23
|
-
|
|
20
|
+
export interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
21
|
+
color?: "brand" | "purple" | "error" | "info" | "success" | "warning" | "neutral" | "white";
|
|
22
|
+
size?: "extraSmall" | "small" | "medium" | "large";
|
|
23
|
+
variant?: "text" | "toggle" | "contained" | "outlined" | "menuDropdownItem" | "menuDropdownItemDelete";
|
|
24
|
+
fontWeight?: "regular" | "medium" | "semibold" | "bold";
|
|
25
|
+
textAlign?: TextAlign;
|
|
26
|
+
outlinedBgColor?: "neutral" | "transparent";
|
|
27
|
+
radii?: "full";
|
|
28
|
+
isCircle?: boolean;
|
|
24
29
|
asChild?: boolean;
|
|
25
30
|
loading?: boolean;
|
|
31
|
+
children?: ReactNode;
|
|
32
|
+
className?: string;
|
|
33
|
+
style?: CSSProperties;
|
|
34
|
+
css?: ComponentProps<typeof ButtonStyled>["css"];
|
|
26
35
|
}
|
|
27
36
|
|
|
28
37
|
export function Button({ asChild, children, loading, ...props }: ButtonProps) {
|
|
@@ -45,7 +54,7 @@ export function Button({ asChild, children, loading, ...props }: ButtonProps) {
|
|
|
45
54
|
}, [size]);
|
|
46
55
|
|
|
47
56
|
return (
|
|
48
|
-
<ButtonStyled as={Component} {...props} disabled={disabled || loading}>
|
|
57
|
+
<ButtonStyled as={Component} {...(props as ComponentProps<typeof ButtonStyled>)} disabled={disabled || loading}>
|
|
49
58
|
<div style={{ position: "relative" }}>
|
|
50
59
|
<Flex
|
|
51
60
|
justify={getJustifyByTextAlign(textAlign)}
|
package/src/components/Flex.tsx
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ComponentProps, ElementType } from 'react';
|
|
1
|
+
import { ComponentProps, CSSProperties, ElementType, ReactNode } from 'react';
|
|
2
2
|
import { styled } from '../styles'
|
|
3
3
|
import { Flex as FlexRadix } from "@radix-ui/themes";
|
|
4
4
|
export const FlexStyled = styled(FlexRadix, {
|
|
@@ -104,15 +104,27 @@ export const FlexStyled = styled(FlexRadix, {
|
|
|
104
104
|
|
|
105
105
|
})
|
|
106
106
|
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
children: React.ReactNode
|
|
110
|
-
}
|
|
107
|
+
type StitchesFlexProps = ComponentProps<typeof FlexStyled>;
|
|
108
|
+
type GapValue = NonNullable<StitchesFlexProps['gap']>;
|
|
111
109
|
|
|
110
|
+
export type FlexProps = {
|
|
111
|
+
as?: ElementType;
|
|
112
|
+
children: ReactNode;
|
|
113
|
+
display?: 'flex' | 'inline-flex';
|
|
114
|
+
align?: 'start' | 'center' | 'end' | 'stretch' | 'baseline';
|
|
115
|
+
justify?: 'start' | 'center' | 'end' | 'between' | 'around' | 'evenly';
|
|
116
|
+
direction?: 'row' | 'column' | 'row-reverse' | 'column-reverse';
|
|
117
|
+
gap?: GapValue;
|
|
118
|
+
gapX?: Exclude<GapValue, 0 | '0'>;
|
|
119
|
+
gapY?: Exclude<GapValue, 0 | '0'>;
|
|
120
|
+
className?: string;
|
|
121
|
+
style?: CSSProperties;
|
|
122
|
+
css?: StitchesFlexProps['css'];
|
|
123
|
+
};
|
|
112
124
|
|
|
113
125
|
export function Flex({ children, ...props }: FlexProps) {
|
|
114
126
|
return (
|
|
115
|
-
<FlexStyled {...props}>
|
|
127
|
+
<FlexStyled {...(props as ComponentProps<typeof FlexStyled>)}>
|
|
116
128
|
{children}
|
|
117
129
|
</FlexStyled>
|
|
118
130
|
)
|
package/src/components/Text.tsx
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { ComponentProps, ElementType } from "react";
|
|
1
|
+
import { ComponentProps, CSSProperties, ElementType, ReactNode } from "react";
|
|
2
2
|
import { styled } from "../styles";
|
|
3
3
|
import { Text as TextRadix } from "@radix-ui/themes";
|
|
4
4
|
import { typographyValues } from "../types/typographyValues";
|
|
5
5
|
|
|
6
|
-
import {
|
|
6
|
+
import { Colors } from "@lets-events/tokens";
|
|
7
7
|
|
|
8
8
|
export const TextStyle = styled(TextRadix, {
|
|
9
9
|
fontFamily: "$default",
|
|
@@ -19,10 +19,25 @@ export const TextStyle = styled(TextRadix, {
|
|
|
19
19
|
},
|
|
20
20
|
});
|
|
21
21
|
|
|
22
|
-
|
|
22
|
+
type Typography = keyof typeof typographyValues;
|
|
23
|
+
type FontWeight = "regular" | "medium" | "semibold" | "bold";
|
|
24
|
+
|
|
25
|
+
export type TextProps = {
|
|
23
26
|
as?: ElementType;
|
|
24
27
|
asChild?: boolean;
|
|
25
28
|
color?: keyof Colors;
|
|
29
|
+
typography?: Typography;
|
|
30
|
+
fontWeight?: FontWeight;
|
|
31
|
+
children?: ReactNode;
|
|
32
|
+
id?: string;
|
|
33
|
+
role?: string;
|
|
34
|
+
"aria-label"?: string;
|
|
35
|
+
"aria-labelledby"?: string;
|
|
36
|
+
"aria-describedby"?: string;
|
|
37
|
+
"aria-hidden"?: boolean | "true" | "false";
|
|
38
|
+
className?: string;
|
|
39
|
+
style?: CSSProperties;
|
|
40
|
+
css?: ComponentProps<typeof TextStyle>["css"];
|
|
26
41
|
};
|
|
27
42
|
|
|
28
43
|
export function Text({ color, ...props }: TextProps) {
|
|
@@ -329,7 +329,7 @@ export const TextField = React.forwardRef<HTMLInputElement, TextFieldProps>(
|
|
|
329
329
|
|
|
330
330
|
return (
|
|
331
331
|
<Flex direction="column" css={{ width: "100%", position: "relative" }}>
|
|
332
|
-
<Flex gap={
|
|
332
|
+
<Flex gap={0} css={{ width: "100%" }}>
|
|
333
333
|
{!!addon && (
|
|
334
334
|
<InputAddon
|
|
335
335
|
color={hasError ? "error" : color}
|