@chenyqthu/tp-mobile-ui-kit 0.0.0-stage → 0.1.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/README.md +214 -2
  2. package/dist/assets.js +5 -0
  3. package/dist/catalog.json +11125 -0
  4. package/dist/chunks/OmadaAppDemo-BP4a4ch_.js +4111 -0
  5. package/dist/chunks/TPPrompt-Csg5YasJ.js +2460 -0
  6. package/dist/chunks/asset-icons-BIenKvAh.js +7613 -0
  7. package/dist/chunks/asset-illustrations-YHXzEd7z.js +3086 -0
  8. package/dist/chunks/asset-logos-DAyGwOLj.js +59 -0
  9. package/dist/chunks/asset-motion-D7fWh_JS.js +376 -0
  10. package/dist/core.js +3 -0
  11. package/dist/index.js +7 -0
  12. package/dist/libpag.wasm +0 -0
  13. package/dist/omada.js +7 -0
  14. package/dist/standalone.js +3438 -0
  15. package/dist/style.css +2 -0
  16. package/dist/types/assets-lib/TPBrandLogo.d.ts +15 -0
  17. package/dist/types/assets-lib/TPIcon.d.ts +19 -0
  18. package/dist/types/assets-lib/TPIllustration.d.ts +17 -0
  19. package/dist/types/assets-lib/TPMotion.d.ts +25 -0
  20. package/dist/types/assets-lib/assetsManifest.d.ts +22 -0
  21. package/dist/types/assets-lib/iconsManifest.d.ts +14 -0
  22. package/dist/types/assets-lib/index.d.ts +8 -0
  23. package/dist/types/assets-lib/motionsManifest.d.ts +12 -0
  24. package/dist/types/assets-lib/runtimeUrl.d.ts +4 -0
  25. package/dist/types/core/components/TPActionSheet.d.ts +4 -0
  26. package/dist/types/core/components/TPAlert.d.ts +4 -0
  27. package/dist/types/core/components/TPBadge.d.ts +7 -0
  28. package/dist/types/core/components/TPBottomSheet.d.ts +4 -0
  29. package/dist/types/core/components/TPButton.d.ts +4 -0
  30. package/dist/types/core/components/TPDatePicker.d.ts +7 -0
  31. package/dist/types/core/components/TPDaySwitcher.d.ts +7 -0
  32. package/dist/types/core/components/TPEmptyState.d.ts +7 -0
  33. package/dist/types/core/components/TPFixedButtonBar.d.ts +4 -0
  34. package/dist/types/core/components/TPHeader.d.ts +4 -0
  35. package/dist/types/core/components/TPInput.d.ts +8 -0
  36. package/dist/types/core/components/TPKeyboard.d.ts +7 -0
  37. package/dist/types/core/components/TPListButton.d.ts +7 -0
  38. package/dist/types/core/components/TPListCard.d.ts +7 -0
  39. package/dist/types/core/components/TPListItem.d.ts +7 -0
  40. package/dist/types/core/components/TPMenu.d.ts +4 -0
  41. package/dist/types/core/components/TPPageControl.d.ts +4 -0
  42. package/dist/types/core/components/TPPhoneFrame.d.ts +4 -0
  43. package/dist/types/core/components/TPPopup.d.ts +4 -0
  44. package/dist/types/core/components/TPPrompt.d.ts +4 -0
  45. package/dist/types/core/components/TPSearchBar.d.ts +7 -0
  46. package/dist/types/core/components/TPSectionHeader.d.ts +7 -0
  47. package/dist/types/core/components/TPSectionNote.d.ts +7 -0
  48. package/dist/types/core/components/TPSegment.d.ts +4 -0
  49. package/dist/types/core/components/TPSlider.d.ts +4 -0
  50. package/dist/types/core/components/TPStatusBar.d.ts +4 -0
  51. package/dist/types/core/components/TPSwitch.d.ts +4 -0
  52. package/dist/types/core/components/TPTabBar.d.ts +4 -0
  53. package/dist/types/core/components/TPTag.d.ts +7 -0
  54. package/dist/types/core/components/TPText.d.ts +7 -0
  55. package/dist/types/core/components/TPTimePicker.d.ts +7 -0
  56. package/dist/types/core/components/TPToast.d.ts +13 -0
  57. package/dist/types/core/components/TPWheelPicker.d.ts +7 -0
  58. package/dist/types/core/index.d.ts +34 -0
  59. package/dist/types/core/types.d.ts +414 -0
  60. package/dist/types/lib/assets.d.ts +1 -0
  61. package/dist/types/lib/core.d.ts +2 -0
  62. package/dist/types/lib/index.d.ts +4 -0
  63. package/dist/types/lib/omada.d.ts +4 -0
  64. package/dist/types/lib/standalone.d.ts +8 -0
  65. package/dist/types/omada/blocks/OmadaDeviceListBlock.d.ts +42 -0
  66. package/dist/types/omada/blocks/OmadaIncidentsBlock.d.ts +26 -0
  67. package/dist/types/omada/blocks/OmadaWirelessNetworkBlock.d.ts +25 -0
  68. package/dist/types/omada/components/OmadaStandardInput.d.ts +23 -0
  69. package/dist/types/omada/index.d.ts +14 -0
  70. package/dist/types/omada/pages/OmadaAppDemo.d.ts +18 -0
  71. package/dist/types/omada/pages/OmadaControllerListPage.d.ts +26 -0
  72. package/dist/types/omada/pages/OmadaDeviceDetailPage.d.ts +15 -0
  73. package/dist/types/omada/pages/OmadaHealthDetailPage.d.ts +17 -0
  74. package/dist/types/omada/pages/OmadaLaunchLoadingPage.d.ts +24 -0
  75. package/dist/types/omada/pages/OmadaSiteClientsPage.d.ts +34 -0
  76. package/dist/types/omada/pages/OmadaSiteDashboardPage.d.ts +28 -0
  77. package/dist/types/omada/pages/OmadaSiteDevicesPage.d.ts +18 -0
  78. package/dist/types/omada/pages/OmadaSiteInsightsPage.d.ts +17 -0
  79. package/dist/types/omada/pages/OmadaSiteSettingsPage.d.ts +20 -0
  80. package/dist/types/theme/TPThemeProvider.d.ts +33 -0
  81. package/dist/types/theme/index.d.ts +2 -0
  82. package/dist/types/theme/tokens.d.ts +80 -0
  83. package/package.json +88 -4
  84. package/skills/tp-mobile-ui-kit/SKILL.md +225 -0
  85. package/skills/tp-mobile-ui-kit/references/catalog.json +11125 -0
  86. package/skills/tp-mobile-ui-kit/scripts/query-catalog.mjs +289 -0
  87. package/skills/tp-mobile-ui-kit/scripts/verify-demo.mjs +193 -0
  88. package/skills/tp-mobile-ui-kit/templates/multi-brand.html +319 -0
  89. package/skills/tp-mobile-ui-kit/templates/multi-brand.tsx +337 -0
  90. package/skills/tp-mobile-ui-kit/templates/omada-dashboard.html +138 -0
  91. package/skills/tp-mobile-ui-kit/templates/omada-dashboard.tsx +119 -0
  92. package/skills/tp-mobile-ui-kit/templates/omada-device-detail.html +158 -0
  93. package/skills/tp-mobile-ui-kit/templates/omada-device-detail.tsx +135 -0
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ import type { TPSliderProps } from '../types';
3
+ import '../../styles/tp-core-nav-controls.css';
4
+ export declare const TPSlider: React.FC<TPSliderProps>;
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ import type { TPStatusBarProps } from '../types';
3
+ import '../../styles/tp-core-nav-controls.css';
4
+ export declare const TPStatusBar: React.FC<TPStatusBarProps>;
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ import type { TPSwitchProps } from '../types';
3
+ import '../../styles/tp-core-nav-controls.css';
4
+ export declare const TPSwitch: React.FC<TPSwitchProps>;
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ import type { TPTabBarProps } from '../types';
3
+ import '../../styles/tp-core-nav-controls.css';
4
+ export declare const TPTabBar: React.FC<TPTabBarProps>;
@@ -0,0 +1,7 @@
1
+ import React from 'react';
2
+ import type { TPTagProps } from '../types';
3
+ import '../../styles/tp-core-lists-inputs.css';
4
+ /**
5
+ * Pill chip/tag supporting selected filter state, semantic tones, and optional close button.
6
+ */
7
+ export declare const TPTag: React.FC<TPTagProps>;
@@ -0,0 +1,7 @@
1
+ import React from 'react';
2
+ import type { TPTextProps } from '../types';
3
+ import '../../styles/tp-core-lists-inputs.css';
4
+ /**
5
+ * Token-driven typography primitive aligned with TP-Design brand font weights and semantic tones.
6
+ */
7
+ export declare const TPText: React.FC<TPTextProps>;
@@ -0,0 +1,7 @@
1
+ import React from 'react';
2
+ import type { TPTimePickerProps } from '../types';
3
+ import '../../styles/tp-core-lists-inputs.css';
4
+ /**
5
+ * Mobile time wheel picker supporting 24-hour and 12-hour (AM/PM) modes plus custom minute steps.
6
+ */
7
+ export declare const TPTimePicker: React.FC<TPTimePickerProps>;
@@ -0,0 +1,13 @@
1
+ import React from 'react';
2
+ import type { TPToastProps } from '../types';
3
+ import '../../styles/tp-core-overlays.css';
4
+ export declare const TPToast: React.FC<TPToastProps>;
5
+ export type TPToastOptions = Omit<TPToastProps, 'open'>;
6
+ export interface TPToastContextValue {
7
+ show: (opts: TPToastOptions | string) => void;
8
+ dismiss: () => void;
9
+ }
10
+ export declare const TPToastProvider: React.FC<{
11
+ children: React.ReactNode;
12
+ }>;
13
+ export declare function useTPToast(): TPToastContextValue;
@@ -0,0 +1,7 @@
1
+ import React from 'react';
2
+ import type { TPWheelPickerProps } from '../types';
3
+ import '../../styles/tp-core-lists-inputs.css';
4
+ /**
5
+ * Multi-column scrollable/clickable wheel picker with centered highlight band and keyboard/step controls.
6
+ */
7
+ export declare const TPWheelPicker: React.FC<TPWheelPickerProps>;
@@ -0,0 +1,34 @@
1
+ export * from './types';
2
+ export { TPPhoneFrame } from './components/TPPhoneFrame';
3
+ export { TPStatusBar } from './components/TPStatusBar';
4
+ export { TPHeader } from './components/TPHeader';
5
+ export { TPTabBar } from './components/TPTabBar';
6
+ export { TPSegment } from './components/TPSegment';
7
+ export { TPPageControl } from './components/TPPageControl';
8
+ export { TPButton } from './components/TPButton';
9
+ export { TPFixedButtonBar } from './components/TPFixedButtonBar';
10
+ export { TPSwitch } from './components/TPSwitch';
11
+ export { TPSlider } from './components/TPSlider';
12
+ export { TPListCard } from './components/TPListCard';
13
+ export { TPListItem } from './components/TPListItem';
14
+ export { TPListButton } from './components/TPListButton';
15
+ export { TPSectionHeader } from './components/TPSectionHeader';
16
+ export { TPSectionNote } from './components/TPSectionNote';
17
+ export { TPText } from './components/TPText';
18
+ export { TPTag } from './components/TPTag';
19
+ export { TPBadge } from './components/TPBadge';
20
+ export { TPEmptyState } from './components/TPEmptyState';
21
+ export { TPInput } from './components/TPInput';
22
+ export { TPSearchBar } from './components/TPSearchBar';
23
+ export { TPWheelPicker } from './components/TPWheelPicker';
24
+ export { TPDatePicker } from './components/TPDatePicker';
25
+ export { TPTimePicker } from './components/TPTimePicker';
26
+ export { TPDaySwitcher } from './components/TPDaySwitcher';
27
+ export { TPKeyboard } from './components/TPKeyboard';
28
+ export { TPAlert } from './components/TPAlert';
29
+ export { TPActionSheet } from './components/TPActionSheet';
30
+ export { TPBottomSheet } from './components/TPBottomSheet';
31
+ export { TPPopup } from './components/TPPopup';
32
+ export { TPMenu } from './components/TPMenu';
33
+ export { TPToast, TPToastProvider, useTPToast, type TPToastOptions, type TPToastContextValue, } from './components/TPToast';
34
+ export { TPPrompt } from './components/TPPrompt';
@@ -0,0 +1,414 @@
1
+ import type React from 'react';
2
+ import type { TPPlatformOS, TPResolvedMode, TPScreenSize } from '../theme';
3
+ import type { TPIconName, TPIllustrationName } from '../assets-lib';
4
+ export interface TPPhoneFrameProps {
5
+ device?: 'iphone16pro' | 'iphone14' | 'android' | 'compact';
6
+ width?: number;
7
+ height?: number;
8
+ screenSize?: TPScreenSize;
9
+ showFrame?: boolean;
10
+ showDynamicIsland?: boolean;
11
+ showHomeIndicator?: boolean;
12
+ statusBar?: React.ReactNode;
13
+ bottomBar?: React.ReactNode;
14
+ floatingAction?: React.ReactNode;
15
+ className?: string;
16
+ style?: React.CSSProperties;
17
+ children: React.ReactNode;
18
+ }
19
+ export interface TPStatusBarProps {
20
+ time?: string;
21
+ os?: TPPlatformOS;
22
+ carrier?: string;
23
+ signalStrength?: 1 | 2 | 3 | 4;
24
+ wifiStrength?: 1 | 2 | 3;
25
+ battery?: number;
26
+ muted?: boolean;
27
+ locationActive?: boolean;
28
+ transparent?: boolean;
29
+ className?: string;
30
+ style?: React.CSSProperties;
31
+ }
32
+ export interface TPHeaderProps {
33
+ title?: React.ReactNode;
34
+ subtitle?: React.ReactNode;
35
+ variant?: 'standard' | 'floating';
36
+ left?: React.ReactNode;
37
+ right?: React.ReactNode;
38
+ showBack?: boolean;
39
+ onBack?: () => void;
40
+ titleDropdown?: boolean;
41
+ onTitleClick?: () => void;
42
+ rightBadge?: number | string;
43
+ translucent?: boolean;
44
+ className?: string;
45
+ style?: React.CSSProperties;
46
+ }
47
+ export interface TPTabBarItem {
48
+ key: string;
49
+ label: string;
50
+ icon: TPIconName | React.ReactNode;
51
+ activeIcon?: TPIconName | React.ReactNode;
52
+ badge?: number | string | boolean;
53
+ }
54
+ export interface TPTabBarProps {
55
+ items: readonly TPTabBarItem[];
56
+ activeKey: string;
57
+ onChange: (key: string) => void;
58
+ variant?: 'floating-pill' | 'docked';
59
+ className?: string;
60
+ style?: React.CSSProperties;
61
+ }
62
+ export interface TPSegmentOption {
63
+ key: string;
64
+ label: React.ReactNode;
65
+ badge?: number | string;
66
+ disabled?: boolean;
67
+ }
68
+ export interface TPSegmentProps {
69
+ options: readonly TPSegmentOption[];
70
+ value: string;
71
+ onChange: (key: string) => void;
72
+ variant?: 'underline' | 'pill';
73
+ fullWidth?: boolean;
74
+ className?: string;
75
+ style?: React.CSSProperties;
76
+ }
77
+ export interface TPPageControlProps {
78
+ total: number;
79
+ current: number;
80
+ onChange?: (index: number) => void;
81
+ className?: string;
82
+ style?: React.CSSProperties;
83
+ }
84
+ export interface TPButtonProps extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, 'type'> {
85
+ variant?: 'primary' | 'secondary' | 'text' | 'alert' | 'tonal' | 'in-card';
86
+ size?: 'lg' | 'md' | 'sm';
87
+ block?: boolean;
88
+ loading?: boolean;
89
+ htmlType?: 'button' | 'submit' | 'reset';
90
+ icon?: React.ReactNode;
91
+ }
92
+ export interface TPFixedButtonBarProps {
93
+ layout?: 'single' | 'dual-horizontal' | 'dual-vertical';
94
+ primaryText: string;
95
+ onPrimaryClick?: () => void;
96
+ primaryLoading?: boolean;
97
+ primaryDisabled?: boolean;
98
+ secondaryText?: string;
99
+ onSecondaryClick?: () => void;
100
+ secondaryVariant?: 'secondary' | 'text' | 'alert';
101
+ note?: React.ReactNode;
102
+ className?: string;
103
+ style?: React.CSSProperties;
104
+ }
105
+ export interface TPSwitchProps {
106
+ checked?: boolean;
107
+ defaultChecked?: boolean;
108
+ onChange?: (checked: boolean) => void;
109
+ disabled?: boolean;
110
+ loading?: boolean;
111
+ ariaLabel?: string;
112
+ className?: string;
113
+ style?: React.CSSProperties;
114
+ }
115
+ export interface TPSliderProps {
116
+ value?: number;
117
+ defaultValue?: number;
118
+ min?: number;
119
+ max?: number;
120
+ step?: number;
121
+ marks?: readonly {
122
+ value: number;
123
+ label?: string;
124
+ }[];
125
+ showValue?: boolean;
126
+ unit?: string;
127
+ disabled?: boolean;
128
+ onChange?: (value: number) => void;
129
+ onAfterChange?: (value: number) => void;
130
+ ariaLabel?: string;
131
+ className?: string;
132
+ style?: React.CSSProperties;
133
+ }
134
+ export interface TPListCardProps {
135
+ title?: React.ReactNode;
136
+ extra?: React.ReactNode;
137
+ radius?: 'theme' | 'lg';
138
+ padding?: 'none' | 'sm' | 'md';
139
+ divided?: boolean;
140
+ className?: string;
141
+ style?: React.CSSProperties;
142
+ children: React.ReactNode;
143
+ }
144
+ export interface TPListItemProps {
145
+ title: React.ReactNode;
146
+ subtitle?: React.ReactNode;
147
+ description?: React.ReactNode;
148
+ value?: React.ReactNode;
149
+ leading?: React.ReactNode;
150
+ trailing?: React.ReactNode;
151
+ badge?: number | string;
152
+ arrow?: boolean;
153
+ checked?: boolean;
154
+ switchProps?: TPSwitchProps;
155
+ danger?: boolean;
156
+ disabled?: boolean;
157
+ onClick?: () => void;
158
+ className?: string;
159
+ style?: React.CSSProperties;
160
+ }
161
+ export interface TPListButtonProps {
162
+ children: React.ReactNode;
163
+ tone?: 'primary' | 'alert' | 'neutral' | 'focus';
164
+ align?: 'center' | 'left';
165
+ disabled?: boolean;
166
+ onClick?: () => void;
167
+ className?: string;
168
+ style?: React.CSSProperties;
169
+ }
170
+ export interface TPSectionHeaderProps {
171
+ title: React.ReactNode;
172
+ count?: number | string;
173
+ action?: React.ReactNode;
174
+ className?: string;
175
+ style?: React.CSSProperties;
176
+ }
177
+ export interface TPSectionNoteProps {
178
+ children: React.ReactNode;
179
+ tone?: 'default' | 'warning' | 'alert';
180
+ className?: string;
181
+ style?: React.CSSProperties;
182
+ }
183
+ export interface TPTextProps {
184
+ variant?: 'title1' | 'title2' | 'title3' | 'title4' | 'body' | 'subhead' | 'caption' | 'footnote';
185
+ tone?: 'primary' | 'secondary' | 'secondary-alt' | 'disabled' | 'focus' | 'highlighted' | 'alert' | 'success' | 'warning';
186
+ as?: 'p' | 'span' | 'div' | 'h1' | 'h2' | 'h3' | 'h4';
187
+ weight?: 'light' | 'regular' | 'medium' | 'semibold' | 'bold';
188
+ className?: string;
189
+ style?: React.CSSProperties;
190
+ children: React.ReactNode;
191
+ }
192
+ export interface TPTagProps {
193
+ children: React.ReactNode;
194
+ tone?: 'focus' | 'neutral' | 'success' | 'warning' | 'alert' | 'info';
195
+ selected?: boolean;
196
+ size?: 'sm' | 'md';
197
+ closable?: boolean;
198
+ onClose?: () => void;
199
+ onClick?: () => void;
200
+ className?: string;
201
+ style?: React.CSSProperties;
202
+ }
203
+ export interface TPBadgeProps {
204
+ count?: number | string;
205
+ dot?: boolean;
206
+ tone?: 'alert' | 'focus' | 'warning' | 'neutral';
207
+ max?: number;
208
+ showZero?: boolean;
209
+ children?: React.ReactNode;
210
+ className?: string;
211
+ style?: React.CSSProperties;
212
+ }
213
+ export interface TPEmptyStateProps {
214
+ illustration?: TPIllustrationName;
215
+ theme?: TPResolvedMode;
216
+ icon?: React.ReactNode;
217
+ title: React.ReactNode;
218
+ description?: React.ReactNode;
219
+ actionText?: string;
220
+ onAction?: () => void;
221
+ compact?: boolean;
222
+ className?: string;
223
+ style?: React.CSSProperties;
224
+ }
225
+ export interface TPInputProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, 'onChange' | 'prefix'> {
226
+ label?: React.ReactNode;
227
+ value?: string;
228
+ defaultValue?: string;
229
+ onChange?: (value: string) => void;
230
+ clearable?: boolean;
231
+ password?: boolean;
232
+ multiline?: boolean;
233
+ rows?: number;
234
+ error?: string;
235
+ helperText?: string;
236
+ prefix?: React.ReactNode;
237
+ suffix?: React.ReactNode;
238
+ containerClassName?: string;
239
+ }
240
+ export interface TPSearchBarProps {
241
+ value?: string;
242
+ defaultValue?: string;
243
+ placeholder?: string;
244
+ onChange?: (value: string) => void;
245
+ onSearch?: (value: string) => void;
246
+ onCancel?: () => void;
247
+ showCancel?: boolean;
248
+ autoFocus?: boolean;
249
+ className?: string;
250
+ style?: React.CSSProperties;
251
+ }
252
+ export interface TPWheelPickerColumn {
253
+ key: string;
254
+ options: readonly {
255
+ value: string;
256
+ label: string;
257
+ }[];
258
+ value: string;
259
+ }
260
+ export interface TPWheelPickerProps {
261
+ columns: readonly TPWheelPickerColumn[];
262
+ onChange: (key: string, value: string) => void;
263
+ itemHeight?: number;
264
+ visibleItems?: 3 | 5;
265
+ className?: string;
266
+ style?: React.CSSProperties;
267
+ }
268
+ export interface TPDatePickerProps {
269
+ value?: Date;
270
+ defaultValue?: Date;
271
+ minYear?: number;
272
+ maxYear?: number;
273
+ onChange?: (date: Date) => void;
274
+ onConfirm?: (date: Date) => void;
275
+ onCancel?: () => void;
276
+ title?: string;
277
+ className?: string;
278
+ style?: React.CSSProperties;
279
+ }
280
+ export interface TPTimePickerProps {
281
+ value?: {
282
+ hour: number;
283
+ minute: number;
284
+ period?: 'AM' | 'PM';
285
+ };
286
+ use12Hour?: boolean;
287
+ minuteStep?: number;
288
+ onChange?: (val: {
289
+ hour: number;
290
+ minute: number;
291
+ period?: 'AM' | 'PM';
292
+ }) => void;
293
+ className?: string;
294
+ style?: React.CSSProperties;
295
+ }
296
+ export type TPDayKey = 'sun' | 'mon' | 'tue' | 'wed' | 'thu' | 'fri' | 'sat';
297
+ export interface TPDaySwitcherProps {
298
+ value?: readonly TPDayKey[];
299
+ defaultValue?: readonly TPDayKey[];
300
+ onChange?: (days: TPDayKey[]) => void;
301
+ disabled?: boolean;
302
+ locale?: 'en' | 'zh';
303
+ className?: string;
304
+ style?: React.CSSProperties;
305
+ }
306
+ export interface TPKeyboardProps {
307
+ mode?: 'numeric' | 'pin' | 'mac-hex';
308
+ onKeyPress?: (key: string) => void;
309
+ onBackspace?: () => void;
310
+ onDone?: () => void;
311
+ doneLabel?: string;
312
+ showDot?: boolean;
313
+ showDash?: boolean;
314
+ className?: string;
315
+ style?: React.CSSProperties;
316
+ }
317
+ export interface TPAlertAction {
318
+ label: string;
319
+ role?: 'default' | 'cancel' | 'destructive';
320
+ onClick?: (inputValue?: string) => void;
321
+ }
322
+ export interface TPAlertProps {
323
+ open: boolean;
324
+ title?: React.ReactNode;
325
+ message?: React.ReactNode;
326
+ actions: readonly TPAlertAction[];
327
+ os?: TPPlatformOS;
328
+ inputPlaceholder?: string;
329
+ defaultInputValue?: string;
330
+ onClose?: () => void;
331
+ children?: React.ReactNode;
332
+ }
333
+ export interface TPActionSheetOption {
334
+ key: string;
335
+ label: React.ReactNode;
336
+ description?: React.ReactNode;
337
+ icon?: React.ReactNode;
338
+ destructive?: boolean;
339
+ disabled?: boolean;
340
+ selected?: boolean;
341
+ }
342
+ export interface TPActionSheetProps {
343
+ open: boolean;
344
+ title?: React.ReactNode;
345
+ message?: React.ReactNode;
346
+ options: readonly TPActionSheetOption[];
347
+ cancelText?: string;
348
+ os?: TPPlatformOS;
349
+ onSelect: (option: TPActionSheetOption) => void;
350
+ onClose: () => void;
351
+ }
352
+ export interface TPBottomSheetProps {
353
+ open: boolean;
354
+ title?: React.ReactNode;
355
+ subtitle?: React.ReactNode;
356
+ onClose: () => void;
357
+ showCloseButton?: boolean;
358
+ showGrabber?: boolean;
359
+ footer?: React.ReactNode;
360
+ maxHeight?: number | string;
361
+ children: React.ReactNode;
362
+ }
363
+ export interface TPPopupProps {
364
+ open: boolean;
365
+ placement?: 'center' | 'top' | 'bottom';
366
+ title?: React.ReactNode;
367
+ closable?: boolean;
368
+ maskClosable?: boolean;
369
+ onClose: () => void;
370
+ footer?: React.ReactNode;
371
+ className?: string;
372
+ style?: React.CSSProperties;
373
+ children: React.ReactNode;
374
+ }
375
+ export interface TPMenuItem {
376
+ key: string;
377
+ label: React.ReactNode;
378
+ icon?: React.ReactNode;
379
+ selected?: boolean;
380
+ danger?: boolean;
381
+ disabled?: boolean;
382
+ dividerBefore?: boolean;
383
+ }
384
+ export interface TPMenuProps {
385
+ open: boolean;
386
+ items: readonly TPMenuItem[];
387
+ onSelect: (item: TPMenuItem) => void;
388
+ onClose: () => void;
389
+ align?: 'left' | 'right' | 'center';
390
+ className?: string;
391
+ style?: React.CSSProperties;
392
+ }
393
+ export type TPToastType = 'default' | 'info' | 'success' | 'warning' | 'error' | 'loading';
394
+ export interface TPToastProps {
395
+ open?: boolean;
396
+ type?: TPToastType;
397
+ message: React.ReactNode;
398
+ duration?: number;
399
+ position?: 'top' | 'center' | 'bottom';
400
+ onClose?: () => void;
401
+ className?: string;
402
+ style?: React.CSSProperties;
403
+ }
404
+ export interface TPPromptProps {
405
+ tone?: 'info' | 'focus' | 'warning' | 'alert';
406
+ title: React.ReactNode;
407
+ actionLabel?: string;
408
+ onAction?: () => void;
409
+ closable?: boolean;
410
+ onClose?: () => void;
411
+ icon?: React.ReactNode;
412
+ className?: string;
413
+ style?: React.CSSProperties;
414
+ }
@@ -0,0 +1 @@
1
+ export * from '../assets-lib';
@@ -0,0 +1,2 @@
1
+ export * from '../theme';
2
+ export * from '../core';
@@ -0,0 +1,4 @@
1
+ export * from '../theme';
2
+ export * from '../assets-lib';
3
+ export * from '../core';
4
+ export * from '../omada';
@@ -0,0 +1,4 @@
1
+ export * from '../theme';
2
+ export * from '../assets-lib';
3
+ export * from '../core';
4
+ export * from '../omada';
@@ -0,0 +1,8 @@
1
+ import * as ReactNS from 'react';
2
+ import * as ReactDOMNS from 'react-dom/client';
3
+ export * from './index';
4
+ export { ReactNS as React, ReactDOMNS as ReactDOM };
5
+ /**
6
+ * Convenience mount helper for zero-build single-file HTML demos (`window.TPMobileUI.render(...)`).
7
+ */
8
+ export declare function render(element: ReactNS.ReactElement, target?: string | HTMLElement): ReactDOMNS.Root;
@@ -0,0 +1,42 @@
1
+ import React from 'react';
2
+ import type { TPTabBarItem } from '../../core/types';
3
+ import '../../styles/tp-omada.css';
4
+ export type OmadaSiteTabKey = 'dashboard' | 'insights' | 'devices' | 'clients' | 'settings';
5
+ export declare const OMADA_SITE_TABS: readonly TPTabBarItem[];
6
+ export type OmadaDeviceType = 'gateway' | 'switch' | 'ap';
7
+ export type OmadaDeviceStatus = 'connected' | 'disconnected' | 'pending';
8
+ export interface OmadaDeviceRecord {
9
+ id: string;
10
+ mac: string;
11
+ name?: string;
12
+ model: string;
13
+ type: OmadaDeviceType;
14
+ status: OmadaDeviceStatus;
15
+ ip: string;
16
+ healthLabel: string;
17
+ healthTone?: 'good' | 'warn' | 'alert';
18
+ upgradeAvailable?: boolean;
19
+ firmwareVersion?: string;
20
+ targetVersion?: string;
21
+ uptime?: string;
22
+ cpuPct?: number;
23
+ memoryPct?: number;
24
+ }
25
+ export declare const DEFAULT_OMADA_DEVICES: readonly OmadaDeviceRecord[];
26
+ export declare const OmadaDeviceThumb: React.FC<{
27
+ type: OmadaDeviceType;
28
+ size?: number;
29
+ }>;
30
+ export interface OmadaDeviceListBlockProps {
31
+ devices?: readonly OmadaDeviceRecord[];
32
+ grouped?: boolean;
33
+ onSelectDevice?: (device: OmadaDeviceRecord) => void;
34
+ emptyTitle?: string;
35
+ emptyDescription?: string;
36
+ className?: string;
37
+ style?: React.CSSProperties;
38
+ }
39
+ /**
40
+ * Reusable Omada v5.3+ Device List block matching real-device `SiteDevices.png` row geometry.
41
+ */
42
+ export declare const OmadaDeviceListBlock: React.FC<OmadaDeviceListBlockProps>;
@@ -0,0 +1,26 @@
1
+ import React from 'react';
2
+ import '../../styles/tp-omada.css';
3
+ export type OmadaIncidentCategory = 'alert' | 'device' | 'client' | 'operation';
4
+ export type OmadaIncidentSeverity = 'warning' | 'error' | 'info';
5
+ export interface OmadaIncidentItem {
6
+ id: string;
7
+ category: OmadaIncidentCategory;
8
+ severity: OmadaIncidentSeverity;
9
+ title: string;
10
+ description: string;
11
+ timestamp: string;
12
+ unread?: boolean;
13
+ }
14
+ export declare const DEFAULT_OMADA_INCIDENTS: readonly OmadaIncidentItem[];
15
+ export interface OmadaIncidentsBlockProps {
16
+ incidents?: readonly OmadaIncidentItem[];
17
+ showHeader?: boolean;
18
+ onBack?: () => void;
19
+ onUnreadCountChange?: (count: number) => void;
20
+ className?: string;
21
+ style?: React.CSSProperties;
22
+ }
23
+ /**
24
+ * Reusable Omada v5.3+ Logs / Alerts & Events block with severity filtering and Mark All Read.
25
+ */
26
+ export declare const OmadaIncidentsBlock: React.FC<OmadaIncidentsBlockProps>;
@@ -0,0 +1,25 @@
1
+ import React from 'react';
2
+ import '../../styles/tp-omada.css';
3
+ export type OmadaBandKey = '2.4G' | '5G' | '6G';
4
+ export type OmadaSecurityMode = 'WPA3-Personal' | 'WPA2/WPA3' | 'WPA2-Personal' | 'Open';
5
+ export interface OmadaWirelessConfig {
6
+ ssid: string;
7
+ enabled: boolean;
8
+ bands: OmadaBandKey[];
9
+ security: OmadaSecurityMode;
10
+ vlanId: string;
11
+ aclGatewayIp: string;
12
+ aclMacAddress: string;
13
+ }
14
+ export interface OmadaWirelessNetworkBlockProps {
15
+ initialConfig?: Partial<OmadaWirelessConfig>;
16
+ showHeader?: boolean;
17
+ onBack?: () => void;
18
+ onSave?: (config: OmadaWirelessConfig) => void;
19
+ className?: string;
20
+ style?: React.CSSProperties;
21
+ }
22
+ /**
23
+ * Reusable Omada v5.3+ Wireless Network (WLAN/SSID) configuration block with IP/MAC ACL and `deploy-config` PAG motion.
24
+ */
25
+ export declare const OmadaWirelessNetworkBlock: React.FC<OmadaWirelessNetworkBlockProps>;
@@ -0,0 +1,23 @@
1
+ import React from 'react';
2
+ import '../../styles/tp-omada.css';
3
+ export type OmadaStandardInputType = 'ip' | 'mac' | 'text' | 'port';
4
+ export interface OmadaStandardInputProps {
5
+ type?: OmadaStandardInputType;
6
+ label?: React.ReactNode;
7
+ value?: string;
8
+ defaultValue?: string;
9
+ onChange?: (value: string) => void;
10
+ placeholder?: string;
11
+ error?: string;
12
+ helperText?: string;
13
+ disabled?: boolean;
14
+ readOnly?: boolean;
15
+ id?: string;
16
+ name?: string;
17
+ className?: string;
18
+ style?: React.CSSProperties;
19
+ }
20
+ /**
21
+ * Figma `【Omada】Standard Input` supporting segmented IPv4 (`0-255`), segmented MAC (`8C-86-DD-A6-A7-5F`), port, and text fields.
22
+ */
23
+ export declare const OmadaStandardInput: React.FC<OmadaStandardInputProps>;