@reopt-ai/opt-ui 1.12.4 → 1.13.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 (39) hide show
  1. package/CHANGELOG.md +236 -0
  2. package/COMPONENT_CATALOG.md +290 -111
  3. package/dist/core/index.cjs +13 -13
  4. package/dist/core/index.d.cts +2 -2
  5. package/dist/core/index.d.ts +2 -2
  6. package/dist/core/index.js +2 -2
  7. package/dist/docs/02-components/01-core.md +49 -49
  8. package/dist/docs/02-components/02-visuals.md +1 -1
  9. package/dist/docs/02-components/03-shells.md +260 -63
  10. package/dist/docs/02-components/04-surfaces.md +1 -1
  11. package/dist/docs/02-components/index.md +4 -4
  12. package/dist/{field-sidebar-C8bDzGPs.js → field-sidebar-CRdToHRO.js} +3975 -235
  13. package/dist/{field-sidebar-DX5wP0qn.cjs → field-sidebar-CxxSK4JO.cjs} +4338 -244
  14. package/dist/{field-sidebar-Ct8c9L4V.d.cts → field-sidebar-D-rwuN_w.d.cts} +824 -2
  15. package/dist/{field-sidebar-YaWHfLLW.d.ts → field-sidebar-Dz7J4ett.d.ts} +824 -2
  16. package/dist/id-registry.cjs +72 -0
  17. package/dist/id-registry.js +72 -0
  18. package/dist/id-registry.json +153 -0
  19. package/dist/index.cjs +334 -1419
  20. package/dist/index.d.cts +51 -86
  21. package/dist/index.d.ts +51 -86
  22. package/dist/index.js +248 -1356
  23. package/dist/{key-pad-menu-1YN221Oi.cjs → key-pad-menu-0KWOnELe.cjs} +53 -483
  24. package/dist/{key-pad-menu-CwcY_Vps.d.cts → key-pad-menu-BOVu97bj.d.cts} +4 -55
  25. package/dist/{key-pad-menu-CUiQ-vKw.js → key-pad-menu-DMmbQ1jF.js} +54 -418
  26. package/dist/{key-pad-menu-WBJShCJn.d.ts → key-pad-menu-NlZ9zNF8.d.ts} +4 -55
  27. package/dist/meta.cjs +896 -7
  28. package/dist/meta.js +896 -7
  29. package/dist/shells/index.cjs +20 -1
  30. package/dist/shells/index.d.cts +2 -2
  31. package/dist/shells/index.d.ts +2 -2
  32. package/dist/shells/index.js +2 -2
  33. package/dist/{text-truncate-BFWd2cE_.js → text-truncate-Bd-0WkSP.js} +463 -99
  34. package/dist/{text-truncate-DsG5UAOY.cjs → text-truncate-BeYW6XZu.cjs} +525 -101
  35. package/dist/{text-truncate-CQyfUZvq.d.cts → text-truncate-eMzvU_7k.d.cts} +52 -1
  36. package/dist/{text-truncate-CQyfUZvq.d.ts → text-truncate-eMzvU_7k.d.ts} +52 -1
  37. package/dist/theme/server.cjs +2 -2
  38. package/dist/theme/server.js +2 -2
  39. package/package.json +6 -2
@@ -313,6 +313,57 @@ interface ChatStylePresetDef {
313
313
  systemPrompt?: string;
314
314
  }
315
315
  //#endregion
316
+ //#region src/core/date-range-picker.d.ts
317
+ /** Defines the date range shape. */
318
+ interface DateRange {
319
+ start: Date | null;
320
+ end: Date | null;
321
+ }
322
+ /** Defines the date range preset shape. */
323
+ interface DateRangePreset {
324
+ label: string;
325
+ range: () => DateRange;
326
+ }
327
+ /** Type definition for date granularity. */
328
+ type DateGranularity = "hour" | "day" | "week" | "month";
329
+ /** Type definition for comparison mode. */
330
+ type ComparisonMode = "previous" | "year-over-year";
331
+ /** Props for the date range picker component. */
332
+ interface DateRangePickerProps {
333
+ value?: DateRange;
334
+ onChange?: (range: DateRange) => void;
335
+ presets?: DateRangePreset[];
336
+ placeholder?: string;
337
+ label?: string;
338
+ required?: boolean;
339
+ error?: string;
340
+ hint?: string;
341
+ className?: string;
342
+ id?: string;
343
+ triggerClassName?: string;
344
+ "aria-label"?: string;
345
+ disabled?: boolean;
346
+ format?: (date: Date) => string;
347
+ /** Enable comparison mode toggle */
348
+ comparison?: boolean;
349
+ /** Current comparison mode */
350
+ comparisonMode?: ComparisonMode;
351
+ /** Called when comparison mode changes (null = comparison off) */
352
+ onComparisonChange?: (mode: ComparisonMode | null) => void;
353
+ /** Enable time granularity selector */
354
+ showGranularity?: boolean;
355
+ /** Current granularity */
356
+ granularity?: DateGranularity;
357
+ /** Called when granularity changes */
358
+ onGranularityChange?: (granularity: DateGranularity) => void;
359
+ }
360
+ declare const DEFAULT_PRESETS: DateRangePreset[];
361
+ /** Renders the date range picker component. */
362
+ declare function DateRangePicker({ value, onChange, presets, placeholder, label, required, error, hint, className, id, triggerClassName, "aria-label": ariaLabel, disabled, format, comparison, comparisonMode, onComparisonChange, showGranularity, granularity, onGranularityChange }: DateRangePickerProps): import("react").JSX.Element;
363
+ declare namespace DateRangePicker {
364
+ var displayName: string;
365
+ }
366
+ //#endregion
316
367
  //#region src/core/field-token.d.ts
317
368
  /**
318
369
  * The kinds of field an analytics schema actually carries. Two fields of the
@@ -449,4 +500,4 @@ interface TextTruncateProps {
449
500
  */
450
501
  declare function TextTruncate({ text, truncation, ellipsis, width, children, className }: TextTruncateProps): import("react").JSX.Element;
451
502
  //#endregion
452
- export { FilterGroupDef as A, StatCard as B, DomainDef as C, ExportFormat as D, ExportColumn as E, NavItem as F, TimePreset as G, TableColumn as H, NavItemDef as I, ToastOptions as K, ProjectDef as L, FormFieldDef as M, MenuDef as N, FailureItem as O, MenuItemDef as P, QuickActionDef as R, DeploymentStep as S, EnvVarDef as T, TaskDef as U, TabDef as V, TeamMemberDef as W, ChatConversationDef as _, FieldDataType as a, ChatStylePresetDef as b, FieldTokenLegendProps as c, ActivityDef as d, BranchDef as f, ChartSeriesDef as g, ChartMargin as h, FIELD_TYPE_TOKENS as i, FilterOption as j, FaqItem as k, FieldTokenProps as l, ChartDataPoint as m, TextTruncateProps as n, FieldToken as o, ChartConfig as p, ToolbarButtonDef as q, TruncationSide as r, FieldTokenLegend as s, TextTruncate as t, resolveFieldType as u, ChatMessageDef as v, EnvGroupDef as w, CommandDef as x, ChatModelDef as y, SelectOption as z };
503
+ export { ToastOptions as $, DomainDef as A, MenuDef as B, ChartSeriesDef as C, ChatStylePresetDef as D, ChatModelDef as E, FailureItem as F, QuickActionDef as G, NavItem as H, FaqItem as I, TabDef as J, SelectOption as K, FilterGroupDef as L, EnvVarDef as M, ExportColumn as N, CommandDef as O, ExportFormat as P, TimePreset as Q, FilterOption as R, ChartMargin as S, ChatMessageDef as T, NavItemDef as U, MenuItemDef as V, ProjectDef as W, TaskDef as X, TableColumn as Y, TeamMemberDef as Z, DateRangePreset as _, FieldDataType as a, ChartConfig as b, FieldTokenLegendProps as c, ComparisonMode as d, ToolbarButtonDef as et, DEFAULT_PRESETS as f, DateRangePickerProps as g, DateRangePicker as h, FIELD_TYPE_TOKENS as i, EnvGroupDef as j, DeploymentStep as k, FieldTokenProps as l, DateRange as m, TextTruncateProps as n, FieldToken as o, DateGranularity as p, StatCard as q, TruncationSide as r, FieldTokenLegend as s, TextTruncate as t, resolveFieldType as u, ActivityDef as v, ChatConversationDef as w, ChartDataPoint as x, BranchDef as y, FormFieldDef as z };
@@ -313,6 +313,57 @@ interface ChatStylePresetDef {
313
313
  systemPrompt?: string;
314
314
  }
315
315
  //#endregion
316
+ //#region src/core/date-range-picker.d.ts
317
+ /** Defines the date range shape. */
318
+ interface DateRange {
319
+ start: Date | null;
320
+ end: Date | null;
321
+ }
322
+ /** Defines the date range preset shape. */
323
+ interface DateRangePreset {
324
+ label: string;
325
+ range: () => DateRange;
326
+ }
327
+ /** Type definition for date granularity. */
328
+ type DateGranularity = "hour" | "day" | "week" | "month";
329
+ /** Type definition for comparison mode. */
330
+ type ComparisonMode = "previous" | "year-over-year";
331
+ /** Props for the date range picker component. */
332
+ interface DateRangePickerProps {
333
+ value?: DateRange;
334
+ onChange?: (range: DateRange) => void;
335
+ presets?: DateRangePreset[];
336
+ placeholder?: string;
337
+ label?: string;
338
+ required?: boolean;
339
+ error?: string;
340
+ hint?: string;
341
+ className?: string;
342
+ id?: string;
343
+ triggerClassName?: string;
344
+ "aria-label"?: string;
345
+ disabled?: boolean;
346
+ format?: (date: Date) => string;
347
+ /** Enable comparison mode toggle */
348
+ comparison?: boolean;
349
+ /** Current comparison mode */
350
+ comparisonMode?: ComparisonMode;
351
+ /** Called when comparison mode changes (null = comparison off) */
352
+ onComparisonChange?: (mode: ComparisonMode | null) => void;
353
+ /** Enable time granularity selector */
354
+ showGranularity?: boolean;
355
+ /** Current granularity */
356
+ granularity?: DateGranularity;
357
+ /** Called when granularity changes */
358
+ onGranularityChange?: (granularity: DateGranularity) => void;
359
+ }
360
+ declare const DEFAULT_PRESETS: DateRangePreset[];
361
+ /** Renders the date range picker component. */
362
+ declare function DateRangePicker({ value, onChange, presets, placeholder, label, required, error, hint, className, id, triggerClassName, "aria-label": ariaLabel, disabled, format, comparison, comparisonMode, onComparisonChange, showGranularity, granularity, onGranularityChange }: DateRangePickerProps): import("react").JSX.Element;
363
+ declare namespace DateRangePicker {
364
+ var displayName: string;
365
+ }
366
+ //#endregion
316
367
  //#region src/core/field-token.d.ts
317
368
  /**
318
369
  * The kinds of field an analytics schema actually carries. Two fields of the
@@ -449,4 +500,4 @@ interface TextTruncateProps {
449
500
  */
450
501
  declare function TextTruncate({ text, truncation, ellipsis, width, children, className }: TextTruncateProps): import("react").JSX.Element;
451
502
  //#endregion
452
- export { FilterGroupDef as A, StatCard as B, DomainDef as C, ExportFormat as D, ExportColumn as E, NavItem as F, TimePreset as G, TableColumn as H, NavItemDef as I, ToastOptions as K, ProjectDef as L, FormFieldDef as M, MenuDef as N, FailureItem as O, MenuItemDef as P, QuickActionDef as R, DeploymentStep as S, EnvVarDef as T, TaskDef as U, TabDef as V, TeamMemberDef as W, ChatConversationDef as _, FieldDataType as a, ChatStylePresetDef as b, FieldTokenLegendProps as c, ActivityDef as d, BranchDef as f, ChartSeriesDef as g, ChartMargin as h, FIELD_TYPE_TOKENS as i, FilterOption as j, FaqItem as k, FieldTokenProps as l, ChartDataPoint as m, TextTruncateProps as n, FieldToken as o, ChartConfig as p, ToolbarButtonDef as q, TruncationSide as r, FieldTokenLegend as s, TextTruncate as t, resolveFieldType as u, ChatMessageDef as v, EnvGroupDef as w, CommandDef as x, ChatModelDef as y, SelectOption as z };
503
+ export { ToastOptions as $, DomainDef as A, MenuDef as B, ChartSeriesDef as C, ChatStylePresetDef as D, ChatModelDef as E, FailureItem as F, QuickActionDef as G, NavItem as H, FaqItem as I, TabDef as J, SelectOption as K, FilterGroupDef as L, EnvVarDef as M, ExportColumn as N, CommandDef as O, ExportFormat as P, TimePreset as Q, FilterOption as R, ChartMargin as S, ChatMessageDef as T, NavItemDef as U, MenuItemDef as V, ProjectDef as W, TaskDef as X, TableColumn as Y, TeamMemberDef as Z, DateRangePreset as _, FieldDataType as a, ChartConfig as b, FieldTokenLegendProps as c, ComparisonMode as d, ToolbarButtonDef as et, DEFAULT_PRESETS as f, DateRangePickerProps as g, DateRangePicker as h, FIELD_TYPE_TOKENS as i, EnvGroupDef as j, DeploymentStep as k, FieldTokenProps as l, DateRange as m, TextTruncateProps as n, FieldToken as o, DateGranularity as p, StatCard as q, TruncationSide as r, FieldTokenLegend as s, TextTruncate as t, resolveFieldType as u, ActivityDef as v, ChatConversationDef as w, ChartDataPoint as x, BranchDef as y, FormFieldDef as z };
@@ -172,7 +172,7 @@ function hasStorageMutation(storage) {
172
172
  }
173
173
  /** Handles is theme preset. */
174
174
  function isThemePreset(value) {
175
- return typeof value === "string" && THEME_PRESET_VALUES.includes(value);
175
+ return typeof value === "string" && THEME_PRESET_IDS.includes(value);
176
176
  }
177
177
  /** Handles is theme mode. */
178
178
  function isThemeMode(value) {
@@ -241,7 +241,7 @@ function coerceThemeMode(mode, allowedModes, fallback = "system") {
241
241
  */
242
242
  function createThemeBootScript(defaultPreset = "default", defaultMode = "system", options = {}) {
243
243
  var _options$allowedModes, _allowedModes$2;
244
- const presetValues = JSON.stringify(THEME_PRESET_VALUES);
244
+ const presetValues = JSON.stringify(THEME_PRESET_IDS);
245
245
  const modeValues = JSON.stringify(THEME_MODE_VALUES);
246
246
  const allowedModes = ((_options$allowedModes = options.allowedModes) === null || _options$allowedModes === void 0 ? void 0 : _options$allowedModes.length) ? options.allowedModes : THEME_MODE_VALUES;
247
247
  const allowedModeValues = JSON.stringify(allowedModes);
@@ -161,7 +161,7 @@ function hasStorageMutation(storage) {
161
161
  }
162
162
  /** Handles is theme preset. */
163
163
  function isThemePreset(value) {
164
- return typeof value === "string" && THEME_PRESET_VALUES.includes(value);
164
+ return typeof value === "string" && THEME_PRESET_IDS.includes(value);
165
165
  }
166
166
  /** Handles is theme mode. */
167
167
  function isThemeMode(value) {
@@ -230,7 +230,7 @@ function coerceThemeMode(mode, allowedModes, fallback = "system") {
230
230
  */
231
231
  function createThemeBootScript(defaultPreset = "default", defaultMode = "system", options = {}) {
232
232
  var _options$allowedModes, _allowedModes$2;
233
- const presetValues = JSON.stringify(THEME_PRESET_VALUES);
233
+ const presetValues = JSON.stringify(THEME_PRESET_IDS);
234
234
  const modeValues = JSON.stringify(THEME_MODE_VALUES);
235
235
  const allowedModes = ((_options$allowedModes = options.allowedModes) === null || _options$allowedModes === void 0 ? void 0 : _options$allowedModes.length) ? options.allowedModes : THEME_MODE_VALUES;
236
236
  const allowedModeValues = JSON.stringify(allowedModes);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@reopt-ai/opt-ui",
3
- "version": "1.12.4",
3
+ "version": "1.13.0",
4
4
  "description": "접근성 우선 UI 컴포넌트 라이브러리. opt-ui-primitives Core, 비즈니스 Shells, 페이지 Surfaces.",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -148,7 +148,7 @@
148
148
  "registry": "https://registry.npmjs.org"
149
149
  },
150
150
  "dependencies": {
151
- "@reopt-ai/opt-charts": "^1.4.2",
151
+ "@reopt-ai/opt-charts": "^1.5.0",
152
152
  "@reopt-ai/opt-meta": "^0.1.0",
153
153
  "@reopt-ai/opt-palette": "^1.0.0",
154
154
  "@reopt-ai/opt-ui-primitives": "^1.5.2",
@@ -162,6 +162,7 @@
162
162
  },
163
163
  "peerDependencies": {
164
164
  "@codemirror/autocomplete": "^6.20.1",
165
+ "@codemirror/commands": "^6.8.1",
165
166
  "@codemirror/lang-sql": "^6.10.0",
166
167
  "@codemirror/state": "^6.5.4",
167
168
  "@codemirror/theme-one-dark": "^6.1.3",
@@ -174,6 +175,9 @@
174
175
  "@codemirror/autocomplete": {
175
176
  "optional": true
176
177
  },
178
+ "@codemirror/commands": {
179
+ "optional": true
180
+ },
177
181
  "@codemirror/lang-sql": {
178
182
  "optional": true
179
183
  },