brix-runtime-sdk-api-web 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 (135) hide show
  1. package/dist/index.js +190 -0
  2. package/dist/types/api-exports.test.d.ts +33 -0
  3. package/dist/types/api-exports.test.d.ts.map +1 -0
  4. package/dist/types/context/RuntimeContext.d.ts +69 -0
  5. package/dist/types/context/RuntimeContext.d.ts.map +1 -0
  6. package/dist/types/context/index.d.ts +23 -0
  7. package/dist/types/context/index.d.ts.map +1 -0
  8. package/dist/types/index.d.ts +52 -0
  9. package/dist/types/index.d.ts.map +1 -0
  10. package/dist/types/types/auth.d.ts +405 -0
  11. package/dist/types/types/auth.d.ts.map +1 -0
  12. package/dist/types/types/capability.d.ts +218 -0
  13. package/dist/types/types/capability.d.ts.map +1 -0
  14. package/dist/types/types/common.d.ts +99 -0
  15. package/dist/types/types/common.d.ts.map +1 -0
  16. package/dist/types/types/config.d.ts +85 -0
  17. package/dist/types/types/config.d.ts.map +1 -0
  18. package/dist/types/types/event.d.ts +658 -0
  19. package/dist/types/types/event.d.ts.map +1 -0
  20. package/dist/types/types/http.d.ts +132 -0
  21. package/dist/types/types/http.d.ts.map +1 -0
  22. package/dist/types/types/i18n.d.ts +327 -0
  23. package/dist/types/types/i18n.d.ts.map +1 -0
  24. package/dist/types/types/index.d.ts +61 -0
  25. package/dist/types/types/index.d.ts.map +1 -0
  26. package/dist/types/types/layout.d.ts +301 -0
  27. package/dist/types/types/layout.d.ts.map +1 -0
  28. package/dist/types/types/module.d.ts +78 -0
  29. package/dist/types/types/module.d.ts.map +1 -0
  30. package/dist/types/types/navigation.d.ts +295 -0
  31. package/dist/types/types/navigation.d.ts.map +1 -0
  32. package/dist/types/types/plugin-loader-capability.d.ts +142 -0
  33. package/dist/types/types/plugin-loader-capability.d.ts.map +1 -0
  34. package/dist/types/types/plugin.d.ts +250 -0
  35. package/dist/types/types/plugin.d.ts.map +1 -0
  36. package/dist/types/types/state.d.ts +306 -0
  37. package/dist/types/types/state.d.ts.map +1 -0
  38. package/dist/types/types/theme.d.ts +279 -0
  39. package/dist/types/types/theme.d.ts.map +1 -0
  40. package/dist/types/types/ui/adapter.d.ts +181 -0
  41. package/dist/types/types/ui/adapter.d.ts.map +1 -0
  42. package/dist/types/types/ui/avatar.d.ts +102 -0
  43. package/dist/types/types/ui/avatar.d.ts.map +1 -0
  44. package/dist/types/types/ui/badge.d.ts +101 -0
  45. package/dist/types/types/ui/badge.d.ts.map +1 -0
  46. package/dist/types/types/ui/button.d.ts +135 -0
  47. package/dist/types/types/ui/button.d.ts.map +1 -0
  48. package/dist/types/types/ui/card.d.ts +105 -0
  49. package/dist/types/types/ui/card.d.ts.map +1 -0
  50. package/dist/types/types/ui/common.d.ts +29 -0
  51. package/dist/types/types/ui/common.d.ts.map +1 -0
  52. package/dist/types/types/ui/icon.d.ts +78 -0
  53. package/dist/types/types/ui/icon.d.ts.map +1 -0
  54. package/dist/types/types/ui/index.d.ts +59 -0
  55. package/dist/types/types/ui/index.d.ts.map +1 -0
  56. package/dist/types/types/ui/input.d.ts +200 -0
  57. package/dist/types/types/ui/input.d.ts.map +1 -0
  58. package/dist/types/types/ui/menu.d.ts +211 -0
  59. package/dist/types/types/ui/menu.d.ts.map +1 -0
  60. package/dist/types/types/ui/message.d.ts +121 -0
  61. package/dist/types/types/ui/message.d.ts.map +1 -0
  62. package/dist/types/types/ui/modal.d.ts +167 -0
  63. package/dist/types/types/ui/modal.d.ts.map +1 -0
  64. package/dist/types/types/ui/select.d.ts +213 -0
  65. package/dist/types/types/ui/select.d.ts.map +1 -0
  66. package/dist/types/types/ui/theme-tokens.d.ts +226 -0
  67. package/dist/types/types/ui/theme-tokens.d.ts.map +1 -0
  68. package/dist/types/types/ui/tooltip.d.ts +98 -0
  69. package/dist/types/types/ui/tooltip.d.ts.map +1 -0
  70. package/dist/types/types/ui.d.ts +49 -0
  71. package/dist/types/types/ui.d.ts.map +1 -0
  72. package/package.json +34 -0
  73. package/src/api-exports.test.ts +199 -0
  74. package/src/context/RuntimeContext.d.ts +69 -0
  75. package/src/context/RuntimeContext.d.ts.map +1 -0
  76. package/src/context/RuntimeContext.ts +75 -0
  77. package/src/context/index.d.ts +23 -0
  78. package/src/context/index.d.ts.map +1 -0
  79. package/src/context/index.ts +23 -0
  80. package/src/index.d.ts +52 -0
  81. package/src/index.d.ts.map +1 -0
  82. package/src/index.ts +59 -0
  83. package/src/types/auth.d.ts +146 -0
  84. package/src/types/auth.d.ts.map +1 -0
  85. package/src/types/auth.ts +479 -0
  86. package/src/types/capability.d.ts +218 -0
  87. package/src/types/capability.d.ts.map +1 -0
  88. package/src/types/capability.ts +302 -0
  89. package/src/types/common.d.ts +99 -0
  90. package/src/types/common.d.ts.map +1 -0
  91. package/src/types/common.ts +115 -0
  92. package/src/types/config.d.ts +64 -0
  93. package/src/types/config.d.ts.map +1 -0
  94. package/src/types/config.ts +96 -0
  95. package/src/types/event.d.ts +206 -0
  96. package/src/types/event.d.ts.map +1 -0
  97. package/src/types/event.ts +776 -0
  98. package/src/types/http.d.ts +132 -0
  99. package/src/types/http.d.ts.map +1 -0
  100. package/src/types/http.ts +156 -0
  101. package/src/types/i18n.ts +420 -0
  102. package/src/types/index.d.ts +50 -0
  103. package/src/types/index.d.ts.map +1 -0
  104. package/src/types/index.ts +120 -0
  105. package/src/types/layout.ts +394 -0
  106. package/src/types/module.d.ts +78 -0
  107. package/src/types/module.d.ts.map +1 -0
  108. package/src/types/module.ts +92 -0
  109. package/src/types/navigation.d.ts +101 -0
  110. package/src/types/navigation.d.ts.map +1 -0
  111. package/src/types/navigation.ts +361 -0
  112. package/src/types/plugin-loader-capability.ts +159 -0
  113. package/src/types/plugin.d.ts +250 -0
  114. package/src/types/plugin.d.ts.map +1 -0
  115. package/src/types/plugin.ts +344 -0
  116. package/src/types/state.d.ts +119 -0
  117. package/src/types/state.d.ts.map +1 -0
  118. package/src/types/state.ts +366 -0
  119. package/src/types/theme.ts +378 -0
  120. package/src/types/ui/adapter.ts +222 -0
  121. package/src/types/ui/avatar.ts +113 -0
  122. package/src/types/ui/badge.ts +112 -0
  123. package/src/types/ui/button.ts +148 -0
  124. package/src/types/ui/card.ts +116 -0
  125. package/src/types/ui/common.ts +29 -0
  126. package/src/types/ui/icon.ts +85 -0
  127. package/src/types/ui/index.ts +78 -0
  128. package/src/types/ui/input.ts +225 -0
  129. package/src/types/ui/menu.ts +237 -0
  130. package/src/types/ui/message.ts +135 -0
  131. package/src/types/ui/modal.ts +188 -0
  132. package/src/types/ui/select.ts +239 -0
  133. package/src/types/ui/theme-tokens.ts +357 -0
  134. package/src/types/ui/tooltip.ts +120 -0
  135. package/src/types/ui.ts +49 -0
@@ -0,0 +1,167 @@
1
+ /**
2
+ * Copyright 2026 Brix Platform Authors
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ /**
17
+ * @file Modal Component Type Definitions
18
+ * @description Defines types for the Modal component in the UI adapter system
19
+ * @module @brix/runtime-sdk-api-web/types/ui/modal
20
+ * @version 3.2.0
21
+ */
22
+ import type { ReactNode, CSSProperties } from 'react';
23
+ /**
24
+ * Modal Size Variants
25
+ */
26
+ export type ModalSize = 'small' | 'medium' | 'large' | 'fullscreen';
27
+ /**
28
+ * Modal Component Props
29
+ *
30
+ * Dialog/modal component for displaying content in an overlay.
31
+ *
32
+ * @example
33
+ * ```tsx
34
+ * <Modal
35
+ * open={isOpen}
36
+ * title="Confirm Action"
37
+ * onClose={handleClose}
38
+ * onConfirm={handleConfirm}
39
+ * >
40
+ * <p>Are you sure you want to proceed?</p>
41
+ * </Modal>
42
+ * ```
43
+ */
44
+ export interface ModalProps {
45
+ /**
46
+ * Open State
47
+ *
48
+ * Whether the modal is visible.
49
+ */
50
+ open: boolean;
51
+ /**
52
+ * Modal Title
53
+ */
54
+ title?: ReactNode;
55
+ /**
56
+ * Modal Size
57
+ *
58
+ * @default 'medium'
59
+ */
60
+ size?: ModalSize;
61
+ /**
62
+ * Close on Overlay Click
63
+ *
64
+ * When true, clicking the overlay backdrop closes the modal.
65
+ * @default true
66
+ */
67
+ closeOnOverlayClick?: boolean;
68
+ /**
69
+ * Close on Escape Key
70
+ *
71
+ * When true, pressing Escape closes the modal.
72
+ * @default true
73
+ */
74
+ closeOnEscape?: boolean;
75
+ /**
76
+ * Show Close Button
77
+ *
78
+ * When true, displays a close button in the header.
79
+ * @default true
80
+ */
81
+ showCloseButton?: boolean;
82
+ /**
83
+ * Centered Position
84
+ *
85
+ * When true, centers the modal vertically.
86
+ * @default true
87
+ */
88
+ centered?: boolean;
89
+ /**
90
+ * Custom Width
91
+ *
92
+ * Custom width override (CSS value).
93
+ */
94
+ width?: string | number;
95
+ /**
96
+ * Footer Content
97
+ *
98
+ * Custom footer content. Set to null to hide footer.
99
+ */
100
+ footer?: ReactNode;
101
+ /**
102
+ * Confirm Button Text
103
+ *
104
+ * Text for the default confirm button.
105
+ * @default 'OK'
106
+ */
107
+ confirmText?: string;
108
+ /**
109
+ * Cancel Button Text
110
+ *
111
+ * Text for the default cancel button.
112
+ * @default 'Cancel'
113
+ */
114
+ cancelText?: string;
115
+ /**
116
+ * Confirm Button Loading
117
+ *
118
+ * When true, the confirm button shows loading state.
119
+ * @default false
120
+ */
121
+ confirmLoading?: boolean;
122
+ /**
123
+ * Close Handler
124
+ *
125
+ * Callback fired when the modal requests to be closed.
126
+ */
127
+ onClose: () => void;
128
+ /**
129
+ * Confirm Handler
130
+ *
131
+ * Callback fired when the confirm button is clicked.
132
+ */
133
+ onConfirm?: () => void;
134
+ /**
135
+ * Cancel Handler
136
+ *
137
+ * Callback fired when the cancel button is clicked.
138
+ */
139
+ onCancel?: () => void;
140
+ /**
141
+ * After Open Handler
142
+ *
143
+ * Callback fired after the modal has opened.
144
+ */
145
+ afterOpen?: () => void;
146
+ /**
147
+ * After Close Handler
148
+ *
149
+ * Callback fired after the modal has closed.
150
+ */
151
+ afterClose?: () => void;
152
+ /**
153
+ * Custom Inline Styles
154
+ *
155
+ * Styles applied to the modal content container.
156
+ */
157
+ style?: CSSProperties;
158
+ /**
159
+ * Custom CSS Class Name
160
+ */
161
+ className?: string;
162
+ /**
163
+ * Modal Content
164
+ */
165
+ children?: ReactNode;
166
+ }
167
+ //# sourceMappingURL=modal.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"modal.d.ts","sourceRoot":"","sources":["../../../../src/types/ui/modal.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AACH;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAEtD;;GAEG;AACH,MAAM,MAAM,SAAS,GAAG,OAAO,GAAG,QAAQ,GAAG,OAAO,GAAG,YAAY,CAAC;AAEpE;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,WAAW,UAAU;IACzB;;;;OAIG;IACH,IAAI,EAAE,OAAO,CAAC;IAEd;;OAEG;IACH,KAAK,CAAC,EAAE,SAAS,CAAC;IAElB;;;;OAIG;IACH,IAAI,CAAC,EAAE,SAAS,CAAC;IAEjB;;;;;OAKG;IACH,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAE9B;;;;;OAKG;IACH,aAAa,CAAC,EAAE,OAAO,CAAC;IAExB;;;;;OAKG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC;IAE1B;;;;;OAKG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IAEnB;;;;OAIG;IACH,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAExB;;;;OAIG;IACH,MAAM,CAAC,EAAE,SAAS,CAAC;IAEnB;;;;;OAKG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;;;OAKG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB;;;;;OAKG;IACH,cAAc,CAAC,EAAE,OAAO,CAAC;IAEzB;;;;OAIG;IACH,OAAO,EAAE,MAAM,IAAI,CAAC;IAEpB;;;;OAIG;IACH,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;IAEvB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;IAEtB;;;;OAIG;IACH,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;IAEvB;;;;OAIG;IACH,UAAU,CAAC,EAAE,MAAM,IAAI,CAAC;IAExB;;;;OAIG;IACH,KAAK,CAAC,EAAE,aAAa,CAAC;IAEtB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAC;CACtB"}
@@ -0,0 +1,213 @@
1
+ /**
2
+ * Copyright 2026 Brix Platform Authors
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ /**
17
+ * @file Select Component Type Definitions
18
+ * @description Defines types for the Select component in the UI adapter system
19
+ * @module @brix/runtime-sdk-api-web/types/ui/select
20
+ * @version 3.2.0
21
+ */
22
+ import type { ReactNode, CSSProperties } from 'react';
23
+ import type { ComponentSize } from './common';
24
+ /**
25
+ * Select Option Item
26
+ *
27
+ * Represents a single option in the select dropdown.
28
+ */
29
+ export interface SelectOption {
30
+ /**
31
+ * Option Value
32
+ *
33
+ * The value submitted when this option is selected.
34
+ */
35
+ value: string | number;
36
+ /**
37
+ * Display Label
38
+ *
39
+ * The text displayed to the user.
40
+ */
41
+ label: string;
42
+ /**
43
+ * Disabled State
44
+ *
45
+ * When true, this option cannot be selected.
46
+ */
47
+ disabled?: boolean;
48
+ /**
49
+ * Icon Name
50
+ *
51
+ * Optional icon displayed before the label.
52
+ */
53
+ icon?: string;
54
+ /**
55
+ * Group Label
56
+ *
57
+ * If specified, indicates this item is a group header.
58
+ */
59
+ group?: string;
60
+ }
61
+ /**
62
+ * Select Component Props
63
+ *
64
+ * UI library agnostic select/dropdown properties. Supports single and
65
+ * multiple selection modes with search functionality.
66
+ *
67
+ * @example
68
+ * ```tsx
69
+ * <Select
70
+ * label="Country"
71
+ * options={countries}
72
+ * value={selectedCountry}
73
+ * onChange={(value) => setSelectedCountry(value)}
74
+ * searchable
75
+ * placeholder="Select a country"
76
+ * />
77
+ * ```
78
+ */
79
+ export interface SelectProps {
80
+ /**
81
+ * Options List
82
+ *
83
+ * Array of selectable options.
84
+ */
85
+ options: SelectOption[];
86
+ /**
87
+ * Current Value
88
+ *
89
+ * The selected value(s). Array for multiple mode.
90
+ */
91
+ value?: string | number | Array<string | number>;
92
+ /**
93
+ * Default Value
94
+ *
95
+ * Initial value for uncontrolled usage.
96
+ */
97
+ defaultValue?: string | number | Array<string | number>;
98
+ /**
99
+ * Placeholder Text
100
+ *
101
+ * Text displayed when no option is selected.
102
+ */
103
+ placeholder?: string;
104
+ /**
105
+ * Field Label
106
+ *
107
+ * Accessible label displayed above the select.
108
+ */
109
+ label?: string;
110
+ /**
111
+ * Helper Text
112
+ *
113
+ * Descriptive text displayed below the select.
114
+ */
115
+ helperText?: string;
116
+ /**
117
+ * Error State
118
+ *
119
+ * When true, displays error styling.
120
+ * @default false
121
+ */
122
+ error?: boolean;
123
+ /**
124
+ * Disabled State
125
+ *
126
+ * When true, the select is non-interactive.
127
+ * @default false
128
+ */
129
+ disabled?: boolean;
130
+ /**
131
+ * Required Field
132
+ *
133
+ * When true, displays required indicator.
134
+ * @default false
135
+ */
136
+ required?: boolean;
137
+ /**
138
+ * Select Size
139
+ *
140
+ * Controls dimensions and font size.
141
+ * @default 'medium'
142
+ */
143
+ size?: ComponentSize;
144
+ /**
145
+ * Full Width Mode
146
+ *
147
+ * When true, fills container width.
148
+ * @default false
149
+ */
150
+ fullWidth?: boolean;
151
+ /**
152
+ * Multiple Selection Mode
153
+ *
154
+ * When true, allows selecting multiple options.
155
+ * @default false
156
+ */
157
+ multiple?: boolean;
158
+ /**
159
+ * Searchable Mode
160
+ *
161
+ * When true, enables search/filter input.
162
+ * @default false
163
+ */
164
+ searchable?: boolean;
165
+ /**
166
+ * Clearable Mode
167
+ *
168
+ * When true, shows a clear button.
169
+ * @default false
170
+ */
171
+ clearable?: boolean;
172
+ /**
173
+ * Field Name
174
+ *
175
+ * HTML name attribute for form submission.
176
+ */
177
+ name?: string;
178
+ /**
179
+ * Loading State
180
+ *
181
+ * When true, shows loading indicator.
182
+ * @default false
183
+ */
184
+ loading?: boolean;
185
+ /**
186
+ * Empty Text
187
+ *
188
+ * Text displayed when no options match search.
189
+ */
190
+ emptyText?: ReactNode;
191
+ /**
192
+ * Change Event Handler
193
+ *
194
+ * Callback fired on selection change.
195
+ * The value type depends on multiple mode.
196
+ */
197
+ onChange?: (value: string | number | Array<string | number>) => void;
198
+ /**
199
+ * Search Event Handler
200
+ *
201
+ * Callback fired when search input changes (only in searchable mode).
202
+ */
203
+ onSearch?: (searchText: string) => void;
204
+ /**
205
+ * Custom Inline Styles
206
+ */
207
+ style?: CSSProperties;
208
+ /**
209
+ * Custom CSS Class Name
210
+ */
211
+ className?: string;
212
+ }
213
+ //# sourceMappingURL=select.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"select.d.ts","sourceRoot":"","sources":["../../../../src/types/ui/select.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GA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AEnB;;;;;OAKG;IACH,UAAU,CAAC,EAAE,OAAO,CAAC;IAErB;;;;;OAKG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IAEpB;;;;OAIG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;;;;OAKG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB;;;;OAIG;IACH,SAAS,CAAC,EAAE,SAAS,CAAC;IAEtB;;;;;OAKG;IACH,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,GAAG,KAAK,CAAC,MAAM,GAAG,MAAM,CAAC,KAAK,IAAI,CAAC;IAErE;;;;OAIG;IACH,QAAQ,CAAC,EAAE,CAAC,UAAU,EAAE,MAAM,KAAK,IAAI,CAAC;IAExC;;OAEG;IACH,KAAK,CAAC,EAAE,aAAa,CAAC;IAEtB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB"}
@@ -0,0 +1,226 @@
1
+ /**
2
+ * Copyright 2026 Brix Platform Authors
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ /**
17
+ * @file Theme Tokens Type Definitions
18
+ * @description Defines theme token types and preset values for the UI adapter system
19
+ * @module @brix/runtime-sdk-api-web/types/ui/theme-tokens
20
+ * @version 3.2.0
21
+ *
22
+ * [Design Principles]
23
+ * - Theme tokens follow MUI standard color palette for broad compatibility
24
+ * - Layout-specific colors support Shell layer layout assembly
25
+ * - Preset constants provide sensible defaults for light/dark modes
26
+ */
27
+ import type { ReactNode } from 'react';
28
+ /**
29
+ * Theme Tokens (MUI Standard Color Palette)
30
+ *
31
+ * Comprehensive design tokens following Material UI conventions.
32
+ * These tokens ensure visual consistency across different UI adapter implementations.
33
+ *
34
+ * **Architectural Note:** Layout-specific colors (sidebarBackground, headerBackground, etc.)
35
+ * are included to support Shell layer layout assembly while maintaining theme consistency.
36
+ */
37
+ export interface ThemeTokens {
38
+ /**
39
+ * Primary Brand Color
40
+ *
41
+ * Main brand color for primary actions and highlights.
42
+ */
43
+ primary: string;
44
+ /**
45
+ * Primary Color - Light Variant
46
+ *
47
+ * Lighter shade of primary for hover states and backgrounds.
48
+ */
49
+ primaryLight: string;
50
+ /**
51
+ * Primary Color - Dark Variant
52
+ *
53
+ * Darker shade of primary for active states.
54
+ */
55
+ primaryDark: string;
56
+ /**
57
+ * Primary Contrast Text
58
+ *
59
+ * Text color that contrasts with primary background.
60
+ */
61
+ primaryContrastText: string;
62
+ /**
63
+ * Secondary Brand Color
64
+ */
65
+ secondary: string;
66
+ /**
67
+ * Secondary Color - Light Variant
68
+ */
69
+ secondaryLight: string;
70
+ /**
71
+ * Secondary Color - Dark Variant
72
+ */
73
+ secondaryDark: string;
74
+ /**
75
+ * Secondary Contrast Text
76
+ */
77
+ secondaryContrastText: string;
78
+ /**
79
+ * Error/Danger Color
80
+ *
81
+ * Used for error states, destructive actions, invalid inputs.
82
+ */
83
+ error: string;
84
+ /**
85
+ * Warning Color
86
+ *
87
+ * Used for warning messages and caution states.
88
+ */
89
+ warning: string;
90
+ /**
91
+ * Info Color
92
+ *
93
+ * Used for informational messages and neutral highlights.
94
+ */
95
+ info: string;
96
+ /**
97
+ * Success Color
98
+ *
99
+ * Used for success states and positive confirmations.
100
+ */
101
+ success: string;
102
+ /**
103
+ * Page Background Color
104
+ *
105
+ * Default background color for the page/viewport.
106
+ */
107
+ background: string;
108
+ /**
109
+ * Paper/Surface Color
110
+ *
111
+ * Background color for elevated surfaces like cards and dialogs.
112
+ */
113
+ paper: string;
114
+ /**
115
+ * Primary Text Color
116
+ *
117
+ * Main text color for headings and body text.
118
+ */
119
+ textPrimary: string;
120
+ /**
121
+ * Secondary Text Color
122
+ *
123
+ * Subdued text color for captions and supporting text.
124
+ */
125
+ textSecondary: string;
126
+ /**
127
+ * Disabled Text Color
128
+ *
129
+ * Text color for disabled/inactive elements.
130
+ */
131
+ textDisabled: string;
132
+ /**
133
+ * Divider Color
134
+ *
135
+ * Color for divider lines and borders.
136
+ */
137
+ divider: string;
138
+ /**
139
+ * Sidebar Background Color
140
+ *
141
+ * Background color for the sidebar navigation area.
142
+ */
143
+ sidebarBackground: string;
144
+ /**
145
+ * Sidebar Text Color
146
+ *
147
+ * Default text color in the sidebar.
148
+ */
149
+ sidebarText: string;
150
+ /**
151
+ * Sidebar Active Item Background
152
+ *
153
+ * Background color for the selected/active menu item.
154
+ */
155
+ sidebarActiveBackground: string;
156
+ /**
157
+ * Sidebar Hover Background
158
+ *
159
+ * Background color on hover for sidebar items.
160
+ */
161
+ sidebarHoverBackground: string;
162
+ /**
163
+ * Header Background Color
164
+ *
165
+ * Background color for the top header area.
166
+ */
167
+ headerBackground: string;
168
+ /**
169
+ * Header Text Color
170
+ *
171
+ * Text color in the header area.
172
+ */
173
+ headerText: string;
174
+ /**
175
+ * Border Radius - Small
176
+ *
177
+ * Small border radius for compact elements (e.g., chips, tags).
178
+ */
179
+ borderRadiusSmall: number;
180
+ /**
181
+ * Border Radius - Medium
182
+ *
183
+ * Default border radius for buttons, inputs, cards.
184
+ */
185
+ borderRadiusMedium: number;
186
+ /**
187
+ * Border Radius - Large
188
+ *
189
+ * Large border radius for modals, large cards.
190
+ */
191
+ borderRadiusLarge: number;
192
+ }
193
+ /**
194
+ * Theme Provider Component Props
195
+ *
196
+ * Provides theme context to child components.
197
+ * Implemented by each UI adapter to apply the appropriate theme.
198
+ */
199
+ export interface ThemeProviderProps {
200
+ /**
201
+ * Child Elements
202
+ *
203
+ * Components that receive theme context.
204
+ */
205
+ children: ReactNode;
206
+ /**
207
+ * Theme Mode
208
+ *
209
+ * Light or dark theme mode. Defaults to light.
210
+ * @default 'light'
211
+ */
212
+ theme?: 'light' | 'dark';
213
+ }
214
+ /**
215
+ * MUI Light Theme Tokens
216
+ *
217
+ * Default light mode theme following Material UI conventions.
218
+ */
219
+ export declare const MUI_THEME_TOKENS: ThemeTokens;
220
+ /**
221
+ * MUI Dark Theme Tokens
222
+ *
223
+ * Dark mode variant of MUI theme tokens.
224
+ */
225
+ export declare const MUI_DARK_THEME_TOKENS: ThemeTokens;
226
+ //# sourceMappingURL=theme-tokens.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"theme-tokens.d.ts","sourceRoot":"","sources":["../../../../src/types/ui/theme-tokens.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AACH;;;;;;;;;;GAUG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC;;;;;;;;GAQG;AACH,MAAM,WAAW,WAAW;IAK1B;;;;OAIG;IACH,OAAO,EAAE,MAAM,CAAC;IAEhB;;;;OAIG;IACH,YAAY,EAAE,MAAM,CAAC;IAErB;;;;OAIG;IACH,WAAW,EAAE,MAAM,CAAC;IAEpB;;;;OAIG;IACH,mBAAmB,EAAE,MAAM,CAAC;IAE5B;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC;IAElB;;OAEG;IACH,cAAc,EAAE,MAAM,CAAC;IAEvB;;OAEG;IACH,aAAa,EAAE,MAAM,CAAC;IAEtB;;OAEG;IACH,qBAAqB,EAAE,MAAM,CAAC;IAM9B;;;;OAIG;IACH,KAAK,EAAE,MAAM,CAAC;IAEd;;;;OAIG;IACH,OAAO,EAAE,MAAM,CAAC;IAEhB;;;;OAIG;IACH,IAAI,EAAE,MAAM,CAAC;IAEb;;;;OAIG;IACH,OAAO,EAAE,MAAM,CAAC;IAMhB;;;;OAIG;IACH,UAAU,EAAE,MAAM,CAAC;IAEnB;;;;OAIG;IACH,KAAK,EAAE,MAAM,CAAC;IAEd;;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