@app-studio/web 0.9.35 → 0.9.37
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/Calendar/Calendar/Calendar.props.d.ts +8 -0
- package/dist/components/KanbanBoard/KanbanBoard/KanbanBoard.props.d.ts +5 -0
- package/dist/components/KanbanBoard/KanbanBoard/KanbanBoard.state.d.ts +7 -3
- package/dist/components/OKR/OKR/OKR.props.d.ts +72 -0
- package/dist/components/OKR/OKR/OKR.style.d.ts +19 -0
- package/dist/components/OKR/OKR/OKR.view.d.ts +4 -0
- package/dist/components/OKR/OKR.d.ts +4 -0
- package/dist/components/index.d.ts +4 -0
- package/dist/pages/okr.page.d.ts +3 -0
- package/dist/web.cjs.development.js +774 -199
- package/dist/web.cjs.development.js.map +1 -1
- package/dist/web.cjs.production.min.js +1 -1
- package/dist/web.cjs.production.min.js.map +1 -1
- package/dist/web.esm.js +774 -200
- package/dist/web.esm.js.map +1 -1
- package/dist/web.umd.development.js +774 -199
- package/dist/web.umd.development.js.map +1 -1
- package/dist/web.umd.production.min.js +1 -1
- package/dist/web.umd.production.min.js.map +1 -1
- package/docs/README.md +2 -1
- package/docs/components/Calendar.mdx +3 -0
- package/docs/components/Flow.mdx +1 -0
- package/docs/components/KanbanBoard.mdx +4 -0
- package/docs/components/OKR.mdx +475 -0
- package/docs/components/Title.mdx +1 -0
- package/docs/components/Tree.mdx +1 -0
- package/docs/components.md +178 -0
- package/package.json +1 -1
- package/docs/api-reference/README.md +0 -103
- package/docs/api-reference/data-display/flow.md +0 -220
- package/docs/api-reference/data-display/tree.md +0 -210
- package/docs/api-reference/form/chat-input.md +0 -206
- package/docs/api-reference/utility/button.md +0 -145
- package/docs/api-reference/utility/title.md +0 -301
|
@@ -5,6 +5,8 @@ export interface CalendarEvent {
|
|
|
5
5
|
id: string;
|
|
6
6
|
/** Event title/label */
|
|
7
7
|
title: string;
|
|
8
|
+
/** Event description */
|
|
9
|
+
description?: string;
|
|
8
10
|
/** Start date in ISO format (YYYY-MM-DD) or datetime (YYYY-MM-DDTHH:MM) */
|
|
9
11
|
start: string;
|
|
10
12
|
/** End date in ISO format (YYYY-MM-DD) or datetime (YYYY-MM-DDTHH:MM) */
|
|
@@ -63,6 +65,12 @@ export interface CalendarProps {
|
|
|
63
65
|
onViewChange?: (view: CalendarView) => void;
|
|
64
66
|
/** Callback when double-clicking to add new event */
|
|
65
67
|
onEventAdd?: (start: string, end: string) => void;
|
|
68
|
+
/** Callback when an event's title changes */
|
|
69
|
+
onEventTitleChange?: (event: CalendarEvent, newTitle: string) => void;
|
|
70
|
+
/** Callback when an event's description changes */
|
|
71
|
+
onEventDescriptionChange?: (event: CalendarEvent, newDescription: string) => void;
|
|
72
|
+
/** Callback when an event is deleted */
|
|
73
|
+
onEventDelete?: (event: CalendarEvent) => void;
|
|
66
74
|
/** Style overrides for various parts of the component */
|
|
67
75
|
views?: CalendarViews;
|
|
68
76
|
/** Width of the calendar (default: '100%') */
|
|
@@ -19,6 +19,11 @@ export interface KanbanBoardColumn {
|
|
|
19
19
|
export interface KanbanBoardProps {
|
|
20
20
|
columns: KanbanBoardColumn[];
|
|
21
21
|
onChange?: (columns: KanbanBoardColumn[]) => void;
|
|
22
|
+
onCardMove?: (card: KanbanBoardCard, fromColumn: KanbanBoardColumn, toColumn: KanbanBoardColumn) => void;
|
|
23
|
+
onCardCreate?: (card: KanbanBoardCard, column: KanbanBoardColumn) => void;
|
|
24
|
+
onCardDelete?: (card: KanbanBoardCard, column: KanbanBoardColumn) => void;
|
|
25
|
+
onCardTitleChange?: (card: KanbanBoardCard, column: KanbanBoardColumn, newTitle: string) => void;
|
|
26
|
+
onCardDescriptionChange?: (card: KanbanBoardCard, column: KanbanBoardColumn, newDescription: string) => void;
|
|
22
27
|
renderCard?: (card: KanbanBoardCard, column: KanbanBoardColumn) => React.ReactNode;
|
|
23
28
|
renderColumnHeader?: (column: KanbanBoardColumn) => React.ReactNode;
|
|
24
29
|
renderEmptyState?: (column: KanbanBoardColumn) => React.ReactNode;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type React from 'react';
|
|
2
|
-
import { KanbanBoardProps } from './KanbanBoard.props';
|
|
3
|
-
export declare const useKanbanBoardState: ({ columns: initialColumns, onChange, }: KanbanBoardProps) => {
|
|
4
|
-
columns:
|
|
2
|
+
import { KanbanBoardCard, KanbanBoardColumn, KanbanBoardProps } from './KanbanBoard.props';
|
|
3
|
+
export declare const useKanbanBoardState: ({ columns: initialColumns, onChange, onCardMove, onCardCreate: onCardCreateProp, onCardDelete: onCardDeleteProp, onCardTitleChange: onCardTitleChangeProp, onCardDescriptionChange: onCardDescriptionChangeProp, }: KanbanBoardProps) => {
|
|
4
|
+
columns: KanbanBoardColumn[];
|
|
5
5
|
draggedCardId: string | null;
|
|
6
6
|
hoveredColumnId: string | null;
|
|
7
7
|
onCardDragStart: (columnId: string, cardId: string, event: React.DragEvent<HTMLDivElement>) => void;
|
|
@@ -10,4 +10,8 @@ export declare const useKanbanBoardState: ({ columns: initialColumns, onChange,
|
|
|
10
10
|
onCardDragOver: (columnId: string, cardId: string | null, event: React.DragEvent<HTMLDivElement>) => void;
|
|
11
11
|
onColumnDrop: (columnId: string, event: React.DragEvent<HTMLDivElement>) => void;
|
|
12
12
|
onCardDrop: (columnId: string, cardId: string | null, event: React.DragEvent<HTMLDivElement>) => void;
|
|
13
|
+
onCardCreate: (card: KanbanBoardCard, column: KanbanBoardColumn) => void;
|
|
14
|
+
onCardDelete: (card: KanbanBoardCard, column: KanbanBoardColumn) => void;
|
|
15
|
+
onCardTitleChange: (card: KanbanBoardCard, column: KanbanBoardColumn, newTitle: string) => void;
|
|
16
|
+
onCardDescriptionChange: (card: KanbanBoardCard, column: KanbanBoardColumn, newDescription: string) => void;
|
|
13
17
|
};
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
import type { ViewProps } from 'app-studio';
|
|
2
|
+
import type { ReactNode } from 'react';
|
|
3
|
+
import type { ProgressBarStyles } from '../../ProgressBar/ProgressBar/ProgressBar.props';
|
|
4
|
+
import type { StatusIndicatorStyles } from '../../StatusIndicator/StatusIndicator/StatusIndicator.type';
|
|
5
|
+
import type { TextProps } from '../../Text/Text/Text.props';
|
|
6
|
+
export declare type OKRStatus = 'notStarted' | 'onTrack' | 'atRisk' | 'offTrack' | 'achieved';
|
|
7
|
+
export interface OKRKeyResult {
|
|
8
|
+
id: string;
|
|
9
|
+
title: string;
|
|
10
|
+
description?: string;
|
|
11
|
+
progress?: number;
|
|
12
|
+
metric?: string;
|
|
13
|
+
target?: string;
|
|
14
|
+
current?: string;
|
|
15
|
+
owner?: string;
|
|
16
|
+
status?: OKRStatus;
|
|
17
|
+
confidence?: 'low' | 'medium' | 'high';
|
|
18
|
+
lastUpdated?: string;
|
|
19
|
+
tags?: string[];
|
|
20
|
+
}
|
|
21
|
+
export interface OKRObjective {
|
|
22
|
+
id: string;
|
|
23
|
+
title: string;
|
|
24
|
+
description?: string;
|
|
25
|
+
owner?: string;
|
|
26
|
+
timeframe?: string;
|
|
27
|
+
tags?: string[];
|
|
28
|
+
progress?: number;
|
|
29
|
+
status?: OKRStatus;
|
|
30
|
+
keyResults: OKRKeyResult[];
|
|
31
|
+
}
|
|
32
|
+
export interface OKRViews {
|
|
33
|
+
container?: ViewProps;
|
|
34
|
+
objectiveCard?: ViewProps;
|
|
35
|
+
objectiveHeader?: ViewProps;
|
|
36
|
+
objectiveTitle?: TextProps;
|
|
37
|
+
objectiveDescription?: TextProps;
|
|
38
|
+
objectiveMeta?: ViewProps;
|
|
39
|
+
objectiveOwner?: TextProps;
|
|
40
|
+
objectiveTimeframe?: TextProps;
|
|
41
|
+
objectiveTags?: ViewProps;
|
|
42
|
+
tag?: ViewProps;
|
|
43
|
+
tagText?: TextProps;
|
|
44
|
+
objectiveProgressSection?: ViewProps;
|
|
45
|
+
objectiveProgressLabel?: TextProps;
|
|
46
|
+
objectiveProgressValue?: TextProps;
|
|
47
|
+
objectiveProgressBar?: ProgressBarStyles;
|
|
48
|
+
objectiveStatus?: StatusIndicatorStyles;
|
|
49
|
+
keyResultList?: ViewProps;
|
|
50
|
+
keyResultItem?: ViewProps;
|
|
51
|
+
keyResultHeader?: ViewProps;
|
|
52
|
+
keyResultTitle?: TextProps;
|
|
53
|
+
keyResultDescription?: TextProps;
|
|
54
|
+
keyResultMeta?: ViewProps;
|
|
55
|
+
keyResultOwner?: TextProps;
|
|
56
|
+
keyResultStatus?: StatusIndicatorStyles;
|
|
57
|
+
keyResultTags?: ViewProps;
|
|
58
|
+
keyResultTag?: ViewProps;
|
|
59
|
+
keyResultTagText?: TextProps;
|
|
60
|
+
keyResultProgressSection?: ViewProps;
|
|
61
|
+
keyResultProgressValue?: TextProps;
|
|
62
|
+
keyResultProgressBar?: ProgressBarStyles;
|
|
63
|
+
footer?: ViewProps;
|
|
64
|
+
}
|
|
65
|
+
export interface OKRProps {
|
|
66
|
+
objectives: OKRObjective[];
|
|
67
|
+
themeMode?: 'light' | 'dark';
|
|
68
|
+
views?: OKRViews;
|
|
69
|
+
onKeyResultClick?: (keyResult: OKRKeyResult, objective: OKRObjective) => void;
|
|
70
|
+
renderObjectiveFooter?: (objective: OKRObjective) => ReactNode;
|
|
71
|
+
renderKeyResultFooter?: (keyResult: OKRKeyResult, objective: OKRObjective) => ReactNode;
|
|
72
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { ViewProps } from 'app-studio';
|
|
2
|
+
import type { Status } from '../../StatusIndicator/StatusIndicator/StatusIndicator.type';
|
|
3
|
+
import type { OKRStatus } from './OKR.props';
|
|
4
|
+
declare type ThemeMode = 'light' | 'dark';
|
|
5
|
+
declare type OKRTheme = {
|
|
6
|
+
container: ViewProps;
|
|
7
|
+
objectiveCard: ViewProps;
|
|
8
|
+
tag: ViewProps;
|
|
9
|
+
keyResultItem: ViewProps;
|
|
10
|
+
divider: ViewProps;
|
|
11
|
+
};
|
|
12
|
+
export declare const getOKRTheme: (mode: ThemeMode) => OKRTheme;
|
|
13
|
+
export declare const STATUS_METADATA: Record<OKRStatus, {
|
|
14
|
+
indicator: Status;
|
|
15
|
+
label: string;
|
|
16
|
+
}>;
|
|
17
|
+
export declare const deriveStatusFromProgress: (progress: number) => OKRStatus;
|
|
18
|
+
export declare const clampProgress: (value?: number | undefined) => number;
|
|
19
|
+
export {};
|
|
@@ -36,6 +36,7 @@ export * from './Message/Message';
|
|
|
36
36
|
export * from './MediaPreview';
|
|
37
37
|
export * from './Modal/Modal';
|
|
38
38
|
export * from './NavigationMenu/NavigationMenu';
|
|
39
|
+
export * from './OKR/OKR';
|
|
39
40
|
export * from './Table/Table';
|
|
40
41
|
export * from './Tabs/Tabs';
|
|
41
42
|
export * from './Text/Text';
|
|
@@ -62,6 +63,7 @@ export * from './Command/Command';
|
|
|
62
63
|
export * from './Tooltip/Tooltip';
|
|
63
64
|
export * from './Tree/Tree';
|
|
64
65
|
export * from './Flow/Flow';
|
|
66
|
+
export * from './OKR/OKR';
|
|
65
67
|
export * from './ChatInput/ChatInput';
|
|
66
68
|
export * from './Background/Background';
|
|
67
69
|
export { default as AgentChat } from './adk/AgentChat/AgentChat';
|
|
@@ -106,6 +108,7 @@ export * from './Toggle/Toggle/Toggle.props';
|
|
|
106
108
|
export * from './ToggleGroup/ToggleGroup/ToggleGroup.props';
|
|
107
109
|
export * from './HoverCard/HoverCard/HoverCard.props';
|
|
108
110
|
export * from './NavigationMenu/NavigationMenu/NavigationMenu.props';
|
|
111
|
+
export * from './OKR/OKR/OKR.props';
|
|
109
112
|
export * from './DropdownMenu/DropdownMenu/DropdownMenu.props';
|
|
110
113
|
export * from './ColorPicker/ColorPicker/ColorPicker.props';
|
|
111
114
|
export * from './EmojiPicker/EmojiPicker/EmojiPicker.props';
|
|
@@ -122,6 +125,7 @@ export * from './Command/Command/Command.props';
|
|
|
122
125
|
export * from './Tooltip/Tooltip/Tooltip.props';
|
|
123
126
|
export * from './Tree/Tree/Tree.props';
|
|
124
127
|
export * from './Flow/Flow/Flow.props';
|
|
128
|
+
export * from './OKR/OKR/OKR.props';
|
|
125
129
|
export * from './ChatInput/ChatInput/ChatInput.props';
|
|
126
130
|
export * from './Background/Background/Background.props';
|
|
127
131
|
export type { AgentRunRequest, MessagePart, AgentMessage, MessageAttachment, AgentChatViews, AgentChatEventHandlers, AgentChatProps, } from './adk/AgentChat/AgentChat/AgentChat.props';
|