@ap-gen/ui 1.0.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.
Files changed (93) hide show
  1. package/dist/components/alert/index.d.ts +11 -0
  2. package/dist/components/badge/index.d.ts +10 -0
  3. package/dist/components/breadcrumb/index.d.ts +10 -0
  4. package/dist/components/button/index.d.ts +17 -0
  5. package/dist/components/button/text.d.ts +17 -0
  6. package/dist/components/calendar/amount.d.ts +7 -0
  7. package/dist/components/calendar/date.d.ts +12 -0
  8. package/dist/components/calendar/index.d.ts +1 -0
  9. package/dist/components/calendar/month.d.ts +1 -0
  10. package/dist/components/calendar/schedule.d.ts +9 -0
  11. package/dist/components/calendar/week.d.ts +1 -0
  12. package/dist/components/calendar/year.d.ts +3 -0
  13. package/dist/components/card/index.d.ts +11 -0
  14. package/dist/components/cell-picker/index.d.ts +13 -0
  15. package/dist/components/cell-picker/item.d.ts +8 -0
  16. package/dist/components/checkbox/index.d.ts +7 -0
  17. package/dist/components/chip/index.d.ts +13 -0
  18. package/dist/components/color-picker/index.d.ts +6 -0
  19. package/dist/components/combo-box/index.d.ts +18 -0
  20. package/dist/components/combo-box/text.d.ts +17 -0
  21. package/dist/components/description/index.d.ts +15 -0
  22. package/dist/components/divider/index.d.ts +7 -0
  23. package/dist/components/empty/index.d.ts +5 -0
  24. package/dist/components/header/index.d.ts +8 -0
  25. package/dist/components/header/list.d.ts +13 -0
  26. package/dist/components/header/section.d.ts +19 -0
  27. package/dist/components/header/tab.d.ts +9 -0
  28. package/dist/components/icon/index.d.ts +553 -0
  29. package/dist/components/index.d.ts +48 -0
  30. package/dist/components/input/index.d.ts +20 -0
  31. package/dist/components/list/compact.d.ts +11 -0
  32. package/dist/components/list/default.d.ts +22 -0
  33. package/dist/components/list/index.d.ts +8 -0
  34. package/dist/components/list/tab.d.ts +11 -0
  35. package/dist/components/list-group/index.d.ts +14 -0
  36. package/dist/components/loading/index.d.ts +6 -0
  37. package/dist/components/motion-pressable/index.d.ts +3 -0
  38. package/dist/components/motion-pressable-div/index.d.ts +3 -0
  39. package/dist/components/navigation-bar/index.d.ts +10 -0
  40. package/dist/components/page-indicator/index.d.ts +8 -0
  41. package/dist/components/pagination/index.d.ts +8 -0
  42. package/dist/components/paragraph/index.d.ts +13 -0
  43. package/dist/components/popover/index.d.ts +16 -0
  44. package/dist/components/progress-bar/index.d.ts +10 -0
  45. package/dist/components/radio/index.d.ts +6 -0
  46. package/dist/components/search-bar/index.d.ts +7 -0
  47. package/dist/components/search-box/index.d.ts +8 -0
  48. package/dist/components/segmented-control/index.d.ts +17 -0
  49. package/dist/components/slider/index.d.ts +14 -0
  50. package/dist/components/snackbar/index.d.ts +19 -0
  51. package/dist/components/switch/index.d.ts +6 -0
  52. package/dist/components/tab-bar/index.d.ts +14 -0
  53. package/dist/components/table/column.d.ts +1 -0
  54. package/dist/components/table/front-checkbox.d.ts +2 -0
  55. package/dist/components/table/head-column.d.ts +15 -0
  56. package/dist/components/table/head-row.d.ts +17 -0
  57. package/dist/components/table/index.d.ts +1 -0
  58. package/dist/components/table/item.d.ts +14 -0
  59. package/dist/components/tabs/index.d.ts +13 -0
  60. package/dist/components/text/constant/variants.d.ts +153 -0
  61. package/dist/components/text/index.d.ts +278 -0
  62. package/dist/components/timeline/index.d.ts +10 -0
  63. package/dist/components/tooltip/index.d.ts +11 -0
  64. package/dist/components/tooltip/popover.d.ts +5 -0
  65. package/dist/components/upload/dropbox.d.ts +10 -0
  66. package/dist/components/upload/file.d.ts +8 -0
  67. package/dist/components/upload/image.d.ts +7 -0
  68. package/dist/components/upload/index.d.ts +8 -0
  69. package/dist/hooks/useCalendar.d.ts +21 -0
  70. package/dist/hooks/useClickOutside.d.ts +6 -0
  71. package/dist/index.d.ts +2 -0
  72. package/dist/index.js +2834 -0
  73. package/dist/index.js.map +1 -0
  74. package/dist/provider/CalendarProvider.d.ts +16 -0
  75. package/dist/provider/ClientProvider.d.ts +15 -0
  76. package/dist/provider/ColorThemeProvider.d.ts +10 -0
  77. package/dist/provider/Provider.d.ts +2 -0
  78. package/dist/provider/index.d.ts +2 -0
  79. package/dist/styles/color/base.d.ts +282 -0
  80. package/dist/styles/color/index.d.ts +293 -0
  81. package/dist/styles/color/themes/dark.d.ts +3 -0
  82. package/dist/styles/color/themes/elevated.d.ts +3 -0
  83. package/dist/styles/color/themes/light.d.ts +3 -0
  84. package/dist/styles/color/themes/trueDark.d.ts +3 -0
  85. package/dist/styles/color/themes/type.d.ts +322 -0
  86. package/dist/styles/color/type.d.ts +7 -0
  87. package/dist/utils/debounce.d.ts +1 -0
  88. package/dist/utils/getNestedValue.d.ts +1 -0
  89. package/dist/utils/hexToRgb.d.ts +1 -0
  90. package/dist/utils/index.d.ts +0 -0
  91. package/esm/index.mjs +2757 -0
  92. package/esm/index.mjs.map +1 -0
  93. package/package.json +214 -0
@@ -0,0 +1,8 @@
1
+ import { Default } from './default';
2
+ import { Compact } from './compact';
3
+ import { Tab } from './tab';
4
+ export declare const List: {
5
+ Default: typeof Default;
6
+ Compact: typeof Compact;
7
+ Tab: typeof Tab;
8
+ };
@@ -0,0 +1,11 @@
1
+ import { IconProps } from '../icon';
2
+ type TabProps = {
3
+ minimized?: boolean;
4
+ activated?: boolean;
5
+ description?: string;
6
+ tabName: string;
7
+ iconName?: IconProps['name'];
8
+ onClick?: () => void;
9
+ };
10
+ export declare function Tab({ minimized, activated, description, tabName, iconName, onClick, }: TabProps): JSX.Element;
11
+ export {};
@@ -0,0 +1,14 @@
1
+ export type ListItemProps = {
2
+ id: string;
3
+ label: string;
4
+ type: 'default' | 'radio' | 'check';
5
+ activated?: boolean;
6
+ children?: ListItemProps[];
7
+ };
8
+ type ListGroupProps = {
9
+ items: ListItemProps[];
10
+ onChange: (id: string, value: boolean) => void;
11
+ mode: 'single' | 'multi';
12
+ };
13
+ export declare function ListGroup({ items, onChange, mode, }: ListGroupProps): JSX.Element;
14
+ export {};
@@ -0,0 +1,6 @@
1
+ type LoadingProps = {
2
+ height?: number;
3
+ width?: number;
4
+ };
5
+ export declare function Loading({ height, width }: LoadingProps): import("@emotion/react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,3 @@
1
+ export declare const MotionPressable: ({ children, ...props }: {
2
+ children: React.ReactNode;
3
+ } & any) => import("@emotion/react/jsx-runtime").JSX.Element;
@@ -0,0 +1,3 @@
1
+ export declare const MotionPressableDiv: ({ children, ...props }: {
2
+ children: React.ReactNode;
3
+ } & any) => import("@emotion/react/jsx-runtime").JSX.Element;
@@ -0,0 +1,10 @@
1
+ type NavigationBarProps = {
2
+ leading: {
3
+ primary?: React.ReactNode;
4
+ secondary?: React.ReactNode;
5
+ };
6
+ center?: React.ReactNode;
7
+ trailing?: React.ReactNode[] | React.ReactNode;
8
+ };
9
+ export declare function NavigationBar({ leading, center, trailing, }: NavigationBarProps): import("@emotion/react/jsx-runtime").JSX.Element;
10
+ export {};
@@ -0,0 +1,8 @@
1
+ type SizeType = 'small' | 'medium';
2
+ type PageIndicatorProps = {
3
+ size?: SizeType;
4
+ total: number;
5
+ activeIndex: number;
6
+ };
7
+ export declare function PageIndicator({ size, total, activeIndex, }: PageIndicatorProps): import("@emotion/react/jsx-runtime").JSX.Element;
8
+ export {};
@@ -0,0 +1,8 @@
1
+ type PaginationProps = {
2
+ showLastPage?: boolean;
3
+ value: number;
4
+ total: number;
5
+ onChange: (value: number) => void;
6
+ };
7
+ export declare function Pagination({ showLastPage, value, total, onChange, }: PaginationProps): import("@emotion/react/jsx-runtime").JSX.Element;
8
+ export {};
@@ -0,0 +1,13 @@
1
+ import React from 'react';
2
+ type Align = 'left' | 'center' | 'right';
3
+ type Size = 'small' | 'medium' | 'large';
4
+ type Color = 'primary' | 'secondary' | 'tertiary';
5
+ type ParagraphProps = {
6
+ children: React.ReactNode;
7
+ align: Align;
8
+ size: Size;
9
+ color: Color;
10
+ showDot?: boolean;
11
+ };
12
+ export declare function Paragraph({ children, align, size, color, showDot, }: ParagraphProps): import("@emotion/react/jsx-runtime").JSX.Element;
13
+ export {};
@@ -0,0 +1,16 @@
1
+ import React from 'react';
2
+ type PopoverProps = {
3
+ children?: React.ReactNode;
4
+ options?: {
5
+ label: string;
6
+ value: string;
7
+ }[];
8
+ value?: string;
9
+ type: 'list' | 'shortcut' | 'component';
10
+ headline?: string;
11
+ primaryButton?: React.ReactNode;
12
+ secondaryButton?: React.ReactNode;
13
+ onChange?: (value: string) => void;
14
+ };
15
+ export declare function Popover({ children, type, options, headline, primaryButton, secondaryButton, onChange, value, }: PopoverProps): import("@emotion/react/jsx-runtime").JSX.Element;
16
+ export {};
@@ -0,0 +1,10 @@
1
+ type Type = 'basic' | 'bold';
2
+ interface ProgressBarProps {
3
+ type?: Type;
4
+ defaultValue?: number;
5
+ value: number;
6
+ padding?: boolean;
7
+ containerStyle?: React.CSSProperties;
8
+ }
9
+ export declare function ProgressBar({ type, value, defaultValue, padding, containerStyle, }: ProgressBarProps): import("@emotion/react/jsx-runtime").JSX.Element;
10
+ export {};
@@ -0,0 +1,6 @@
1
+ export type RadioProps = {
2
+ value: boolean;
3
+ onChange: (value: boolean) => void;
4
+ disabled?: boolean;
5
+ };
6
+ export declare function Radio({ value, onChange, disabled }: RadioProps): import("@emotion/react/jsx-runtime").JSX.Element;
@@ -0,0 +1,7 @@
1
+ import { ChangeEvent } from 'react';
2
+ interface SearchBarProps {
3
+ value: string;
4
+ onChange: (e: ChangeEvent<HTMLInputElement>) => void;
5
+ }
6
+ export declare function SearchBar({ value, onChange, ...rest }: SearchBarProps): import("@emotion/react/jsx-runtime").JSX.Element;
7
+ export {};
@@ -0,0 +1,8 @@
1
+ import { ChangeEvent } from 'react';
2
+ interface SearchBoxProps {
3
+ value: string;
4
+ onChange: (e: ChangeEvent<HTMLInputElement>) => void;
5
+ placeholder?: string;
6
+ }
7
+ export declare function SearchBox({ value, onChange, ...rest }: SearchBoxProps): import("@emotion/react/jsx-runtime").JSX.Element;
8
+ export {};
@@ -0,0 +1,17 @@
1
+ import { IconProps } from '../icon';
2
+ type SegmentedControlPropsSize = 'small' | 'medium' | 'large';
3
+ type SegmentedControlProps = {
4
+ value: string;
5
+ options: {
6
+ value: string;
7
+ label: string;
8
+ leadingIcon?: IconProps['name'];
9
+ trailingIcon?: IconProps['name'];
10
+ }[];
11
+ onChange: (value: string) => void;
12
+ size: SegmentedControlPropsSize;
13
+ fullWidth?: boolean;
14
+ paddingDisabled?: boolean;
15
+ };
16
+ export declare function SegmentedControl({ value, options, onChange, size, fullWidth, paddingDisabled, }: SegmentedControlProps): import("@emotion/react/jsx-runtime").JSX.Element;
17
+ export {};
@@ -0,0 +1,14 @@
1
+ type SliderProps = {
2
+ value: [number, number] | number;
3
+ onChange: (value: [number, number] | number) => void;
4
+ doubleRange?: boolean;
5
+ options?: {
6
+ value: number;
7
+ label: string;
8
+ }[];
9
+ min?: number;
10
+ max?: number;
11
+ className?: string;
12
+ };
13
+ export declare function Slider({ doubleRange, value, onChange, options, min, max, className, }: SliderProps): import("@emotion/react/jsx-runtime").JSX.Element;
14
+ export {};
@@ -0,0 +1,19 @@
1
+ import { IconProps } from '../icon';
2
+ type ButtonProps = {
3
+ label: string;
4
+ onClick: () => void;
5
+ leadingIcon?: IconProps['name'];
6
+ trailingIcon?: IconProps['name'];
7
+ variant?: 'mono' | 'core' | 'warning';
8
+ };
9
+ type SnackbarProps = {
10
+ compact?: boolean;
11
+ label?: string;
12
+ inputBox?: boolean;
13
+ buttons: Array<ButtonProps & {
14
+ variant?: 'mono' | 'core' | 'warning';
15
+ size?: 'small' | 'medium' | 'large';
16
+ }>;
17
+ };
18
+ export declare function Snackbar({ label, inputBox, compact, buttons }: SnackbarProps): import("@emotion/react/jsx-runtime").JSX.Element;
19
+ export {};
@@ -0,0 +1,6 @@
1
+ export type ToggleProps = {
2
+ value: boolean;
3
+ onChange: (value: boolean) => void;
4
+ disabled?: boolean;
5
+ };
6
+ export declare function Switch({ value, onChange, disabled }: ToggleProps): import("@emotion/react/jsx-runtime").JSX.Element;
@@ -0,0 +1,14 @@
1
+ type TabOption = {
2
+ label: string;
3
+ value: string;
4
+ };
5
+ type TabBarProps = {
6
+ value: string;
7
+ onChange: (tab: string) => void;
8
+ options: TabOption[];
9
+ size?: SizeType;
10
+ side?: boolean;
11
+ };
12
+ type SizeType = 'large' | 'medium' | 'small';
13
+ export declare function TabBar({ value, onChange, options, size, side, }: TabBarProps): import("@emotion/react/jsx-runtime").JSX.Element;
14
+ export {};
@@ -0,0 +1 @@
1
+ export declare function TableColumn(): import("@emotion/react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ import { CheckboxProps } from '../checkbox';
2
+ export declare function FrontCheckbox({ ...props }: CheckboxProps): import("@emotion/react/jsx-runtime").JSX.Element;
@@ -0,0 +1,15 @@
1
+ import { ChangeEvent } from 'react';
2
+ type HeadColumnProps = {
3
+ spacingLevel?: 0 | 1 | 2;
4
+ value?: string;
5
+ };
6
+ type HeadColumnCollapsableProps = {
7
+ collapsable?: boolean;
8
+ expanded?: boolean;
9
+ };
10
+ type HeadColumnEditableProps = {
11
+ onChange?: (e: ChangeEvent<HTMLInputElement>) => void;
12
+ editable?: boolean;
13
+ };
14
+ export declare function HeadColumn({ collapsable, expanded, spacingLevel, onChange, editable, value, }: HeadColumnProps & HeadColumnEditableProps & HeadColumnCollapsableProps): import("@emotion/react/jsx-runtime").JSX.Element;
15
+ export {};
@@ -0,0 +1,17 @@
1
+ import { ChangeEvent } from 'react';
2
+ type HeadBaseProps = {
3
+ value?: string;
4
+ align?: 'left' | 'center' | 'right';
5
+ fullWidth?: boolean;
6
+ width?: string;
7
+ };
8
+ type HeadEditableProps = {
9
+ editable?: boolean;
10
+ onChange?: (e: ChangeEvent<HTMLInputElement>) => void;
11
+ };
12
+ type HeadSortableProps = {
13
+ sortable?: boolean;
14
+ sortDirection?: 'asc' | 'desc' | 'none';
15
+ };
16
+ export declare function HeadRow({ align, onChange, value, editable, sortable, sortDirection, fullWidth, width, }: HeadBaseProps & HeadEditableProps & HeadSortableProps): import("@emotion/react/jsx-runtime").JSX.Element;
17
+ export {};
@@ -0,0 +1 @@
1
+ export declare function Table(): import("@emotion/react/jsx-runtime").JSX.Element;
@@ -0,0 +1,14 @@
1
+ import { ChangeEvent } from 'react';
2
+ type ItemBaseProps = {
3
+ children?: React.ReactNode;
4
+ align?: 'left' | 'center' | 'right';
5
+ value?: string;
6
+ fullWidth?: boolean;
7
+ width?: string;
8
+ };
9
+ type ItemEditableProps = {
10
+ editable?: boolean;
11
+ onChange?: (e: ChangeEvent<HTMLInputElement>) => void;
12
+ };
13
+ export declare function Item({ children, align, onChange, value, editable, fullWidth, width, }: ItemBaseProps & ItemEditableProps): import("@emotion/react/jsx-runtime").JSX.Element;
14
+ export {};
@@ -0,0 +1,13 @@
1
+ type TabOption = {
2
+ label: string;
3
+ value: string;
4
+ };
5
+ type TabsProps = {
6
+ value: string;
7
+ onChange: (tab: string) => void;
8
+ options: TabOption[];
9
+ size?: SizeType;
10
+ };
11
+ type SizeType = 'large' | 'medium';
12
+ export declare function Tabs({ value, onChange, options, size }: TabsProps): import("@emotion/react/jsx-runtime").JSX.Element;
13
+ export {};
@@ -0,0 +1,153 @@
1
+ export declare const TEXT_SCALE: {
2
+ '100%': number;
3
+ '135%': number;
4
+ '150%': number;
5
+ '200%': number;
6
+ };
7
+ export declare const TEXT_VARIANTS: {
8
+ readonly DisplayL: {
9
+ readonly fontSize: 48;
10
+ readonly fontWeight: 800;
11
+ readonly lineHeight: 68;
12
+ readonly letterSpacing: -0.96;
13
+ };
14
+ readonly DisplayS: {
15
+ readonly fontSize: 32;
16
+ readonly fontWeight: 800;
17
+ readonly lineHeight: 46;
18
+ readonly letterSpacing: -0.64;
19
+ };
20
+ readonly TitleL: {
21
+ readonly fontSize: 24;
22
+ readonly fontWeight: 600;
23
+ readonly lineHeight: 34;
24
+ readonly letterSpacing: -0.48;
25
+ };
26
+ readonly TitleM: {
27
+ readonly fontSize: 20;
28
+ readonly fontWeight: 600;
29
+ readonly lineHeight: 28;
30
+ readonly letterSpacing: -0.4;
31
+ };
32
+ readonly TitleS: {
33
+ readonly fontSize: 18;
34
+ readonly fontWeight: 600;
35
+ readonly lineHeight: 26;
36
+ readonly letterSpacing: -0.36;
37
+ };
38
+ readonly BodyL: {
39
+ readonly fontSize: 16;
40
+ readonly fontWeight: 400;
41
+ readonly lineHeight: 24;
42
+ readonly letterSpacing: -0.32;
43
+ };
44
+ readonly BodyM: {
45
+ readonly fontSize: 14;
46
+ readonly fontWeight: 400;
47
+ readonly lineHeight: 20;
48
+ readonly letterSpacing: -0.28;
49
+ };
50
+ readonly BodyS: {
51
+ readonly fontSize: 12;
52
+ readonly fontWeight: 400;
53
+ readonly lineHeight: 18;
54
+ readonly letterSpacing: -0.24;
55
+ };
56
+ readonly Caption: {
57
+ readonly fontSize: 10;
58
+ readonly fontWeight: 400;
59
+ readonly lineHeight: 14;
60
+ readonly letterSpacing: -0.2;
61
+ };
62
+ readonly BodyL_Bold: {
63
+ readonly fontSize: 16;
64
+ readonly fontWeight: 500;
65
+ readonly lineHeight: 24;
66
+ readonly letterSpacing: -0.32;
67
+ };
68
+ readonly BodyM_Bold: {
69
+ readonly fontSize: 14;
70
+ readonly fontWeight: 500;
71
+ readonly lineHeight: 20;
72
+ readonly letterSpacing: -0.28;
73
+ };
74
+ readonly BodyS_Bold: {
75
+ readonly fontSize: 12;
76
+ readonly fontWeight: 500;
77
+ readonly lineHeight: 18;
78
+ readonly letterSpacing: -0.24;
79
+ };
80
+ readonly Caption_Bold: {
81
+ readonly fontSize: 10;
82
+ readonly fontWeight: 500;
83
+ readonly lineHeight: 14;
84
+ readonly letterSpacing: -0.2;
85
+ };
86
+ readonly TextualL: {
87
+ readonly fontSize: 16;
88
+ readonly fontWeight: 400;
89
+ readonly lineHeight: 26;
90
+ readonly letterSpacing: -0.32;
91
+ };
92
+ readonly TextualM: {
93
+ readonly fontSize: 14;
94
+ readonly fontWeight: 400;
95
+ readonly lineHeight: 22;
96
+ readonly letterSpacing: -0.28;
97
+ };
98
+ readonly TextualS: {
99
+ readonly fontSize: 12;
100
+ readonly fontWeight: 400;
101
+ readonly lineHeight: 18;
102
+ readonly letterSpacing: -0.24;
103
+ };
104
+ readonly ValueXL: {
105
+ readonly fontSize: 24;
106
+ readonly fontWeight: 600;
107
+ readonly lineHeight: 34;
108
+ readonly letterSpacing: -1.44;
109
+ };
110
+ readonly ValueL: {
111
+ readonly fontSize: 18;
112
+ readonly fontWeight: 600;
113
+ readonly lineHeight: 26;
114
+ readonly letterSpacing: -1.08;
115
+ };
116
+ readonly ValueM: {
117
+ readonly fontSize: 14;
118
+ readonly fontWeight: 500;
119
+ readonly lineHeight: 20;
120
+ readonly letterSpacing: -0.84;
121
+ };
122
+ readonly ValueS: {
123
+ readonly fontSize: 12;
124
+ readonly fontWeight: 400;
125
+ readonly lineHeight: 18;
126
+ readonly letterSpacing: -0.72;
127
+ };
128
+ readonly TableM: {
129
+ readonly fontSize: 14;
130
+ readonly fontWeight: 400;
131
+ readonly lineHeight: 16;
132
+ readonly letterSpacing: -0.42;
133
+ };
134
+ readonly TableS: {
135
+ readonly fontSize: 12;
136
+ readonly fontWeight: 400;
137
+ readonly lineHeight: 14;
138
+ readonly letterSpacing: -0.36;
139
+ };
140
+ readonly TableM_Bold: {
141
+ readonly fontSize: 14;
142
+ readonly fontWeight: 500;
143
+ readonly lineHeight: 15;
144
+ readonly letterSpacing: -0.42;
145
+ };
146
+ readonly TableS_Bold: {
147
+ readonly fontSize: 12;
148
+ readonly fontWeight: 500;
149
+ readonly lineHeight: 14;
150
+ readonly letterSpacing: -0.36;
151
+ };
152
+ };
153
+ export type TextVariant = keyof typeof TEXT_VARIANTS;