@nubisco/ui 1.53.0 → 1.53.1
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/dist/components/AiLabel.d.ts +19 -0
- package/dist/components/Badge.d.ts +23 -0
- package/dist/components/BlueprintControls.d.ts +21 -0
- package/dist/components/BlueprintMinimap.d.ts +17 -0
- package/dist/components/Board.d.ts +64 -0
- package/dist/components/BottomPanel.d.ts +13 -0
- package/dist/components/Button.d.ts +34 -0
- package/dist/components/Button.vue.d.ts +1 -1
- package/dist/components/Calendar.d.ts +32 -0
- package/dist/components/Charts/BarChart.d.ts +12 -0
- package/dist/components/Charts/GanttChart.d.ts +81 -0
- package/dist/components/Charts/InterpolationChart.d.ts +33 -0
- package/dist/components/Charts/LineChart.d.ts +15 -0
- package/dist/components/Charts/PieChart.d.ts +11 -0
- package/dist/components/Charts/Sparkline.d.ts +11 -0
- package/dist/components/Charts/shared/types.d.ts +53 -0
- package/dist/components/Checkbox.d.ts +9 -0
- package/dist/components/CheckboxGroup.d.ts +17 -0
- package/dist/components/ColorStrip.d.ts +22 -0
- package/dist/components/CommandPalette.d.ts +40 -0
- package/dist/components/DataTable.d.ts +131 -0
- package/dist/components/DatePicker.d.ts +52 -0
- package/dist/components/Field.d.ts +33 -0
- package/dist/components/FileUploader.d.ts +27 -0
- package/dist/components/FileUploader.vue.d.ts +1 -1
- package/dist/components/Flag.d.ts +9 -0
- package/dist/components/Form.d.ts +5 -0
- package/dist/components/Grid.d.ts +345 -0
- package/dist/components/Icon.d.ts +59 -0
- package/dist/components/Icon.vue.d.ts +1 -1
- package/dist/components/ImageCropper.d.ts +27 -0
- package/dist/components/JsonTree.d.ts +33 -0
- package/dist/components/Label.d.ts +14 -0
- package/dist/components/Menu.d.ts +53 -0
- package/dist/components/Message.d.ts +17 -0
- package/dist/components/Modal.d.ts +10 -0
- package/dist/components/Modal.vue.d.ts +1 -1
- package/dist/components/NumberInput.vue.d.ts +1 -1
- package/dist/components/Pagination.d.ts +38 -0
- package/dist/components/Pagination.vue.d.ts +1 -1
- package/dist/components/ProgressBar.d.ts +27 -0
- package/dist/components/Radio.d.ts +28 -0
- package/dist/components/Select.d.ts +23 -0
- package/dist/components/Shell.d.ts +60 -0
- package/dist/components/ShellPanel.d.ts +33 -0
- package/dist/components/SidebarBrand.d.ts +14 -0
- package/dist/components/SidebarLink.d.ts +24 -0
- package/dist/components/SidebarMenu.d.ts +10 -0
- package/dist/components/SidebarMenuGroup.d.ts +16 -0
- package/dist/components/SidebarMenuItem.d.ts +42 -0
- package/dist/components/Slider.d.ts +26 -0
- package/dist/components/Switch.d.ts +20 -0
- package/dist/components/TextInput.vue.d.ts +1 -1
- package/dist/components/Tree.d.ts +68 -0
- package/dist/components/UserMenu.d.ts +43 -0
- package/dist/components/labs/Spreadsheet.d.ts +104 -0
- package/dist/directives/ToolTip.directive.d.ts +1 -1
- package/dist/global.d.ts +135 -0
- package/dist/types/Decoration.d.ts +6 -0
- package/dist/types/Option.d.ts +29 -0
- package/dist/types/Props.d.ts +121 -0
- package/dist/types/Size.d.ts +33 -0
- package/dist/types/Variants.d.ts +12 -0
- package/dist/types/Vite.d.ts +3 -0
- package/package.json +6 -3
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
enum EAiLabelVariant {
|
|
2
|
+
Default = 'default',
|
|
3
|
+
Inline = 'inline',
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
// #region EAiLabelSize
|
|
7
|
+
enum EAiLabelSize {
|
|
8
|
+
Small = 'sm',
|
|
9
|
+
Medium = 'md',
|
|
10
|
+
Large = 'lg',
|
|
11
|
+
}
|
|
12
|
+
// #endregion EAiLabelSize
|
|
13
|
+
|
|
14
|
+
interface IAiLabelProps {
|
|
15
|
+
variant?: EAiLabelVariant
|
|
16
|
+
size?: EAiLabelSize
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
export { EAiLabelVariant, EAiLabelSize, IAiLabelProps }
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
// FIXME replace the variant with the existing variants
|
|
2
|
+
enum EBadgeVariant {
|
|
3
|
+
Grey = 'grey',
|
|
4
|
+
Blue = 'blue',
|
|
5
|
+
Orange = 'orange',
|
|
6
|
+
Green = 'green',
|
|
7
|
+
Red = 'red',
|
|
8
|
+
Purple = 'purple',
|
|
9
|
+
Primary = 'primary',
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
enum EBadgeSize {
|
|
13
|
+
Small = 'sm',
|
|
14
|
+
Medium = 'md',
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
interface IBadgeProps {
|
|
18
|
+
variant?: EBadgeVariant
|
|
19
|
+
size?: EBadgeSize
|
|
20
|
+
dot?: boolean
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
export { EBadgeVariant, EBadgeSize, IBadgeProps }
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/** Corner a floating blueprint chrome element docks to. */
|
|
2
|
+
export type TBlueprintChromePosition =
|
|
3
|
+
| 'top-left'
|
|
4
|
+
| 'top-right'
|
|
5
|
+
| 'bottom-left'
|
|
6
|
+
| 'bottom-right'
|
|
7
|
+
|
|
8
|
+
export interface IBlueprintControlsProps {
|
|
9
|
+
/** Corner the toolbar floats in. */
|
|
10
|
+
position?: TBlueprintChromePosition
|
|
11
|
+
/** Stack direction. */
|
|
12
|
+
orientation?: 'horizontal' | 'vertical'
|
|
13
|
+
/** When to show the toolbar: always, or only while the blueprint is in edit
|
|
14
|
+
* mode (`editable` prop / `isEditMode`). */
|
|
15
|
+
show?: 'always' | 'edit'
|
|
16
|
+
/** Show the auto-layout button. */
|
|
17
|
+
autoLayout?: boolean
|
|
18
|
+
/** Show the alignment/distribution cluster (appears when 2+ cards are
|
|
19
|
+
* selected). */
|
|
20
|
+
alignment?: boolean
|
|
21
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import type { IBlueprintCard } from './Blueprint.types'
|
|
2
|
+
import type { TBlueprintChromePosition } from './BlueprintControls.d'
|
|
3
|
+
|
|
4
|
+
export interface IBlueprintMinimapProps {
|
|
5
|
+
/** The same cards passed to NbBlueprint (windowed API). Their geometry
|
|
6
|
+
* drives the overview. */
|
|
7
|
+
cards: IBlueprintCard[]
|
|
8
|
+
/** Corner the minimap floats in. */
|
|
9
|
+
position?: TBlueprintChromePosition
|
|
10
|
+
width?: number
|
|
11
|
+
height?: number
|
|
12
|
+
/** Click / drag on the minimap to recenter the viewport. */
|
|
13
|
+
pannable?: boolean
|
|
14
|
+
/** Override node color (CSS color). Defaults to each card's accent, else a
|
|
15
|
+
* muted token. */
|
|
16
|
+
nodeColor?: string
|
|
17
|
+
}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
interface IBoardColumn {
|
|
2
|
+
/** Unique column identifier. */
|
|
3
|
+
id: string
|
|
4
|
+
/** Display label for the column header. */
|
|
5
|
+
label: string
|
|
6
|
+
/** Optional accent color for the column header border. */
|
|
7
|
+
color?: string
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
interface IBoardLane {
|
|
11
|
+
/** Unique lane identifier. Use `null` for the catch-all/backlog lane. */
|
|
12
|
+
id: string | null
|
|
13
|
+
/** Display label for the lane header. */
|
|
14
|
+
label: string
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
interface IBoardItem {
|
|
18
|
+
/** Unique item identifier. */
|
|
19
|
+
id: string
|
|
20
|
+
/** Which column this item belongs to. */
|
|
21
|
+
columnId: string
|
|
22
|
+
/** Which lane this item belongs to (optional, only used when lanes are provided). */
|
|
23
|
+
laneId?: string | null
|
|
24
|
+
/** Arbitrary payload passed through to the card slot. */
|
|
25
|
+
[key: string]: unknown
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
interface IBoardMoveEvent {
|
|
29
|
+
/** The ID of the item that was moved. */
|
|
30
|
+
itemId: string
|
|
31
|
+
/** The column the item was moved from. */
|
|
32
|
+
fromColumnId: string
|
|
33
|
+
/** The column the item was moved to. */
|
|
34
|
+
toColumnId: string
|
|
35
|
+
/** The lane the item was moved from (only when lanes are used). */
|
|
36
|
+
fromLaneId?: string | null
|
|
37
|
+
/** The lane the item was moved to (only when lanes are used). */
|
|
38
|
+
toLaneId?: string | null
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
interface IBoardProps {
|
|
42
|
+
/** Column definitions (one per status/stage). */
|
|
43
|
+
columns: IBoardColumn[]
|
|
44
|
+
/** Items to display on the board. Each item must have an `id` and `columnId`. */
|
|
45
|
+
items: IBoardItem[]
|
|
46
|
+
/** Optional swim lanes. When provided, the board renders horizontal lane rows. */
|
|
47
|
+
lanes?: IBoardLane[]
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
export type {
|
|
51
|
+
IBoardColumn,
|
|
52
|
+
IBoardLane,
|
|
53
|
+
IBoardItem,
|
|
54
|
+
IBoardMoveEvent,
|
|
55
|
+
IBoardProps,
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export type {
|
|
59
|
+
IBoardColumn as NbBoardColumn,
|
|
60
|
+
IBoardLane as NbBoardLane,
|
|
61
|
+
IBoardItem as NbBoardItem,
|
|
62
|
+
IBoardMoveEvent as NbBoardMoveEvent,
|
|
63
|
+
IBoardProps as NbBoardProps,
|
|
64
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export type TBottomPanelSize = 'collapsed' | 'default' | 'half' | 'full'
|
|
2
|
+
|
|
3
|
+
export interface IBottomPanelProps {
|
|
4
|
+
/**
|
|
5
|
+
* Current panel size. Use v-model:size for two-way binding.
|
|
6
|
+
* @default 'default'
|
|
7
|
+
*/
|
|
8
|
+
size?: TBottomPanelSize
|
|
9
|
+
/**
|
|
10
|
+
* Panel title shown in the header.
|
|
11
|
+
*/
|
|
12
|
+
title?: string
|
|
13
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { ESizeShort } from '../types/Size.d'
|
|
2
|
+
|
|
3
|
+
enum EButtonType {
|
|
4
|
+
Button = 'button',
|
|
5
|
+
Submit = 'submit',
|
|
6
|
+
Reset = 'reset',
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
interface IButtonProps {
|
|
10
|
+
variant?: string
|
|
11
|
+
outlined?: boolean
|
|
12
|
+
size?: ESizeShort
|
|
13
|
+
disabled?: boolean
|
|
14
|
+
loading?: boolean
|
|
15
|
+
/** Icon name passed directly to NbIcon. Rendered in the trailing padding area. Hidden while loading. */
|
|
16
|
+
icon?: string
|
|
17
|
+
/** Native button type. Ignored when `href` is provided. */
|
|
18
|
+
type?: EButtonType
|
|
19
|
+
/** When provided the component renders as an `<a>` element instead of `<button>`. */
|
|
20
|
+
href?: string
|
|
21
|
+
/** Forwarded to the `<a>` element. Only used when `href` is set. */
|
|
22
|
+
target?: string
|
|
23
|
+
/** Forwarded to the `<a>` element. Only used when `href` is set. */
|
|
24
|
+
rel?: string
|
|
25
|
+
/**
|
|
26
|
+
* Target route. When vue-router is installed, the button renders as a
|
|
27
|
+
* `<RouterLink>` and accepts any value valid for its `to` prop (string path or
|
|
28
|
+
* location object). Without vue-router, a string `to` falls back to a plain
|
|
29
|
+
* `<a>` and an object `to` falls back to a `<button>` that emits `click`.
|
|
30
|
+
*/
|
|
31
|
+
to?: string | Record<string, unknown>
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
export { EButtonType, IButtonProps }
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
interface ICalendarEvent {
|
|
2
|
+
/** Unique event identifier. */
|
|
3
|
+
id: string
|
|
4
|
+
/** Display label for the event. */
|
|
5
|
+
label: string
|
|
6
|
+
/** Start date (ISO string YYYY-MM-DD or Date). */
|
|
7
|
+
start: string | Date
|
|
8
|
+
/** End date (ISO string YYYY-MM-DD or Date). Defaults to start if omitted. */
|
|
9
|
+
end?: string | Date
|
|
10
|
+
/** CSS color for the event bar. Falls back to primary. */
|
|
11
|
+
color?: string
|
|
12
|
+
/** Arbitrary payload passed through to the event slot. */
|
|
13
|
+
[key: string]: unknown
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
interface ICalendarProps {
|
|
17
|
+
/** Events to display on the calendar. */
|
|
18
|
+
events?: ICalendarEvent[]
|
|
19
|
+
/** Initial month to display (ISO string YYYY-MM or Date). Defaults to today. */
|
|
20
|
+
month?: string | Date
|
|
21
|
+
/** First day of the week: 0 = Sunday, 1 = Monday. Defaults to 1 (Monday). */
|
|
22
|
+
weekStart?: 0 | 1
|
|
23
|
+
/** Locale for month/day names. Defaults to browser locale. */
|
|
24
|
+
locale?: string
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
export type { ICalendarEvent, ICalendarProps }
|
|
28
|
+
|
|
29
|
+
export type {
|
|
30
|
+
ICalendarEvent as NbCalendarEvent,
|
|
31
|
+
ICalendarProps as NbCalendarProps,
|
|
32
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { IChartCommonProps, IChartSeries } from './shared/types.d'
|
|
2
|
+
|
|
3
|
+
type TBarOrientation = 'vertical' | 'horizontal'
|
|
4
|
+
|
|
5
|
+
interface IBarChartProps extends IChartCommonProps {
|
|
6
|
+
series?: IChartSeries[]
|
|
7
|
+
orientation?: TBarOrientation
|
|
8
|
+
// When true and multiple series share an x value, bars stack instead of group.
|
|
9
|
+
stacked?: boolean
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export type { IBarChartProps, TBarOrientation }
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import type { IChartCommonProps } from './shared/types.d'
|
|
2
|
+
|
|
3
|
+
// Dependency relationship between two tasks.
|
|
4
|
+
type TDependencyType =
|
|
5
|
+
| 'finish-to-start'
|
|
6
|
+
| 'start-to-start'
|
|
7
|
+
| 'finish-to-finish'
|
|
8
|
+
| 'start-to-finish'
|
|
9
|
+
|
|
10
|
+
type TGanttTaskStatus =
|
|
11
|
+
| 'default'
|
|
12
|
+
| 'on-track'
|
|
13
|
+
| 'at-risk'
|
|
14
|
+
| 'behind'
|
|
15
|
+
| 'complete'
|
|
16
|
+
|
|
17
|
+
type TGanttTimeScale = 'day' | 'week' | 'month' | 'quarter' | 'year'
|
|
18
|
+
|
|
19
|
+
interface IGanttDependency {
|
|
20
|
+
// ID of the predecessor task.
|
|
21
|
+
from: string
|
|
22
|
+
// ID of the successor task.
|
|
23
|
+
to: string
|
|
24
|
+
type?: TDependencyType
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
interface IGanttTask {
|
|
28
|
+
id: string
|
|
29
|
+
label: string
|
|
30
|
+
// Start date (ISO string or Date).
|
|
31
|
+
start: string | Date
|
|
32
|
+
// End date (ISO string or Date). Omit for milestones.
|
|
33
|
+
end?: string | Date
|
|
34
|
+
// Progress percentage (0 to 100).
|
|
35
|
+
progress?: number
|
|
36
|
+
// Visual status for the task bar.
|
|
37
|
+
status?: TGanttTaskStatus
|
|
38
|
+
// Optional group/parent ID for hierarchical grouping.
|
|
39
|
+
group?: string
|
|
40
|
+
// Explicit color override.
|
|
41
|
+
color?: string
|
|
42
|
+
// When true, this task renders as a milestone diamond instead of a bar.
|
|
43
|
+
milestone?: boolean
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
interface IGanttGroup {
|
|
47
|
+
id: string
|
|
48
|
+
label: string
|
|
49
|
+
// Whether the group starts collapsed.
|
|
50
|
+
collapsed?: boolean
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
interface IGanttChartProps extends IChartCommonProps {
|
|
54
|
+
tasks?: IGanttTask[]
|
|
55
|
+
dependencies?: IGanttDependency[]
|
|
56
|
+
groups?: IGanttGroup[]
|
|
57
|
+
// Time granularity for the header and grid.
|
|
58
|
+
timeScale?: TGanttTimeScale
|
|
59
|
+
// Height of each task row in pixels.
|
|
60
|
+
rowHeight?: number
|
|
61
|
+
// Width of the task list panel on the left.
|
|
62
|
+
listWidth?: number
|
|
63
|
+
// Show the vertical "today" marker line.
|
|
64
|
+
showTodayMarker?: boolean
|
|
65
|
+
// Override the date used for the today marker (useful for demos).
|
|
66
|
+
today?: string | Date
|
|
67
|
+
// Show task progress fill inside bars.
|
|
68
|
+
showProgress?: boolean
|
|
69
|
+
// Custom status color map (status name to CSS color string).
|
|
70
|
+
statusColors?: Partial<Record<TGanttTaskStatus, string>>
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export type {
|
|
74
|
+
TDependencyType,
|
|
75
|
+
TGanttTaskStatus,
|
|
76
|
+
TGanttTimeScale,
|
|
77
|
+
IGanttDependency,
|
|
78
|
+
IGanttTask,
|
|
79
|
+
IGanttGroup,
|
|
80
|
+
IGanttChartProps,
|
|
81
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import type { IChartCommonProps } from './shared/types.d'
|
|
2
|
+
|
|
3
|
+
interface IInterpolationPoint {
|
|
4
|
+
input: number
|
|
5
|
+
output: number
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
interface IInterpolationChartProps extends IChartCommonProps {
|
|
9
|
+
/** The mapping points (sorted by input). Supports v-model. */
|
|
10
|
+
modelValue?: IInterpolationPoint[]
|
|
11
|
+
/** Label for the X (input) axis. */
|
|
12
|
+
inputLabel?: string
|
|
13
|
+
/** Label for the Y (output) axis. */
|
|
14
|
+
outputLabel?: string
|
|
15
|
+
/** Minimum allowed input value. */
|
|
16
|
+
inputMin?: number
|
|
17
|
+
/** Maximum allowed input value. */
|
|
18
|
+
inputMax?: number
|
|
19
|
+
/** Minimum allowed output value. */
|
|
20
|
+
outputMin?: number
|
|
21
|
+
/** Maximum allowed output value. */
|
|
22
|
+
outputMax?: number
|
|
23
|
+
/** Whether the user can drag, add, and remove points. */
|
|
24
|
+
editable?: boolean
|
|
25
|
+
/** Minimum number of points that must remain (cannot remove below this). */
|
|
26
|
+
minPoints?: number
|
|
27
|
+
/** Step size for snapping input values (e.g. 0.5). 0 = no snap. */
|
|
28
|
+
inputStep?: number
|
|
29
|
+
/** Step size for snapping output values (e.g. 1). 0 = no snap. */
|
|
30
|
+
outputStep?: number
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export type { IInterpolationPoint, IInterpolationChartProps }
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type { IChartCommonProps, IChartSeries } from './shared/types.d'
|
|
2
|
+
|
|
3
|
+
type TLineCurve = 'linear' | 'smooth' | 'step'
|
|
4
|
+
|
|
5
|
+
interface ILineChartProps extends IChartCommonProps {
|
|
6
|
+
series?: IChartSeries[]
|
|
7
|
+
// Render filled area under each line.
|
|
8
|
+
area?: boolean
|
|
9
|
+
// Show data points along each line.
|
|
10
|
+
points?: boolean
|
|
11
|
+
// Curve style.
|
|
12
|
+
curve?: TLineCurve
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export type { ILineChartProps, TLineCurve }
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { IChartCommonProps, ICategoricalDatum } from './shared/types.d'
|
|
2
|
+
|
|
3
|
+
interface IPieChartProps extends Omit<IChartCommonProps, 'showGrid'> {
|
|
4
|
+
data?: ICategoricalDatum[]
|
|
5
|
+
// Inner radius ratio (0-1). > 0 produces a donut chart.
|
|
6
|
+
innerRadius?: number
|
|
7
|
+
// Label rendering: 'none' | 'percent' | 'value'.
|
|
8
|
+
labels?: 'none' | 'percent' | 'value'
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export type { IPieChartProps }
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
// Shared type definitions for the chart family.
|
|
2
|
+
// All cartesian charts (Bar, Line, Area, Bubble, Histogram) consume the
|
|
3
|
+
// IChartSeries shape; pie / categorical charts consume ICategoricalDatum.
|
|
4
|
+
|
|
5
|
+
type TChartScalar = number | string | Date
|
|
6
|
+
|
|
7
|
+
interface IChartPoint {
|
|
8
|
+
x: TChartScalar
|
|
9
|
+
y: number
|
|
10
|
+
// Optional third dimension (used by Bubble for radius / Heatmap for value).
|
|
11
|
+
z?: number
|
|
12
|
+
// Optional label override for tooltips.
|
|
13
|
+
label?: string
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
interface IChartSeries {
|
|
17
|
+
name: string
|
|
18
|
+
data: IChartPoint[]
|
|
19
|
+
// Optional explicit color override for this series.
|
|
20
|
+
color?: string
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
interface ICategoricalDatum {
|
|
24
|
+
label: string
|
|
25
|
+
value: number
|
|
26
|
+
color?: string
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
interface IChartMargins {
|
|
30
|
+
top: number
|
|
31
|
+
right: number
|
|
32
|
+
bottom: number
|
|
33
|
+
left: number
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
interface IChartCommonProps {
|
|
37
|
+
title?: string
|
|
38
|
+
subtitle?: string
|
|
39
|
+
height?: number | string
|
|
40
|
+
showLegend?: boolean
|
|
41
|
+
showTooltip?: boolean
|
|
42
|
+
showGrid?: boolean
|
|
43
|
+
colors?: string[]
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
export {
|
|
47
|
+
TChartScalar,
|
|
48
|
+
IChartPoint,
|
|
49
|
+
IChartSeries,
|
|
50
|
+
ICategoricalDatum,
|
|
51
|
+
IChartMargins,
|
|
52
|
+
IChartCommonProps,
|
|
53
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { IHumanInputComponent, IWithLabel } from '../types/Props.d'
|
|
2
|
+
|
|
3
|
+
interface ICheckboxProps extends IHumanInputComponent, IWithLabel {
|
|
4
|
+
modelValue?: boolean
|
|
5
|
+
/** Shows a dash instead of a tick — used for "select all" rows where some children are checked. */
|
|
6
|
+
indeterminate?: boolean
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
export { ICheckboxProps }
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import {
|
|
2
|
+
IHumanInputComponent,
|
|
3
|
+
IWithLabel,
|
|
4
|
+
IWithMessages,
|
|
5
|
+
} from '../types/Props.d'
|
|
6
|
+
|
|
7
|
+
enum ECheckboxGroupDirection {
|
|
8
|
+
Horizontal = 'horizontal',
|
|
9
|
+
Vertical = 'vertical',
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
interface ICheckboxGroupProps
|
|
13
|
+
extends IHumanInputComponent, IWithLabel, IWithMessages {
|
|
14
|
+
direction?: ECheckboxGroupDirection
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export { ECheckboxGroupDirection, ICheckboxGroupProps }
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { IDefaultProps, IWithLabel } from '../types/Props.d'
|
|
2
|
+
import type { IOption } from '../types/Option'
|
|
3
|
+
|
|
4
|
+
interface IColorStripProps extends IDefaultProps, IWithLabel {
|
|
5
|
+
options?: string[] | IOption[]
|
|
6
|
+
/** Disables interaction — only renders the color dots without selection. */
|
|
7
|
+
onlyView?: boolean
|
|
8
|
+
/** Allows more than one color to be selected at a time. */
|
|
9
|
+
allowMultiple?: boolean
|
|
10
|
+
/** Wraps color dots onto multiple lines instead of scrolling horizontally. */
|
|
11
|
+
wrap?: boolean
|
|
12
|
+
/** Shows a null / "no color" option as the first item. */
|
|
13
|
+
showNull?: boolean
|
|
14
|
+
/**
|
|
15
|
+
* Presentation variant:
|
|
16
|
+
* - `default` — label above the strip.
|
|
17
|
+
* - `fluid` — label inside the field box.
|
|
18
|
+
*/
|
|
19
|
+
variant?: 'default' | 'fluid'
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
export { IColorStripProps, IOption }
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
export interface ICommand {
|
|
2
|
+
/** Unique identifier */
|
|
3
|
+
id: string
|
|
4
|
+
/** Display label */
|
|
5
|
+
label: string
|
|
6
|
+
/** Phosphor icon name */
|
|
7
|
+
icon?: string
|
|
8
|
+
/** Namespace for grouping (e.g. "File", "Edit") */
|
|
9
|
+
namespace?: string
|
|
10
|
+
/** Keyboard shortcut display text (e.g. "Cmd+S") */
|
|
11
|
+
shortcut?: string
|
|
12
|
+
/** Function to execute when the command is invoked */
|
|
13
|
+
handler: () => void | Promise<void>
|
|
14
|
+
/** Context key: command only appears when this context is active */
|
|
15
|
+
context?: string
|
|
16
|
+
/** Additional search keywords */
|
|
17
|
+
keywords?: string[]
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
export interface ICommandPaletteProps {
|
|
21
|
+
/** Keyboard shortcut to open the palette (default: 'Meta+k') */
|
|
22
|
+
openShortcut?: string
|
|
23
|
+
/** Placeholder text for the search input */
|
|
24
|
+
placeholder?: string
|
|
25
|
+
/** Maximum number of results to display */
|
|
26
|
+
maxResults?: number
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export interface ICommandPaletteState {
|
|
30
|
+
commands: Map<string, ICommand>
|
|
31
|
+
isOpen: boolean
|
|
32
|
+
activeContext: string | undefined
|
|
33
|
+
searchFilter: string | undefined
|
|
34
|
+
register: (command: ICommand) => void
|
|
35
|
+
registerMany: (commands: ICommand[]) => void
|
|
36
|
+
unregister: (id: string) => void
|
|
37
|
+
open: (filter?: string) => void
|
|
38
|
+
close: () => void
|
|
39
|
+
setContext: (context: string | undefined) => void
|
|
40
|
+
}
|