@case-framework/survey-ui 0.3.4 → 0.5.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.
- package/dist/src/modules/survey-editor/hooks/useEditorStateChange.d.ts +2 -1
- package/dist/src/modules/survey-editor/routes/editor/_components/main.d.ts +6 -1
- package/dist/src/modules/survey-editor/routes/editor/index.d.ts +2 -0
- package/dist/src/modules/survey-editor/routes/editor/item-editor/_components/item-editor-toolbar/item-editor-toolbar.d.ts +6 -1
- package/dist/src/modules/survey-editor/routes/editor/item-editor/index.d.ts +6 -1
- package/dist/src/modules/survey-editor/store/editor-store.d.ts +2 -1
- package/dist/src/modules/survey-editor/survey-editor.d.ts +2 -0
- package/dist/survey-ui.cjs.js +66 -78
- package/dist/survey-ui.cjs.js.map +1 -1
- package/dist/survey-ui.css +1 -1
- package/dist/survey-ui.es.js +10756 -9939
- package/dist/survey-ui.es.js.map +1 -1
- package/package.json +8 -8
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import { SerializedSurveyEditor, SurveyEditor as SurveyEditorCore } from '@case-framework/survey-core/editor';
|
|
1
|
+
import { SerializedSurveyEditor, SurveyEditorHistoryCommit, SurveyEditor as SurveyEditorCore } from '@case-framework/survey-core/editor';
|
|
2
2
|
export interface EditorStateChangePayload {
|
|
3
3
|
sessionId: string | null;
|
|
4
4
|
state: SerializedSurveyEditor;
|
|
5
5
|
revision: number;
|
|
6
6
|
hasUncommittedChanges: boolean;
|
|
7
|
+
commitsSinceInitial: SurveyEditorHistoryCommit[];
|
|
7
8
|
at: number;
|
|
8
9
|
}
|
|
9
10
|
interface UseEditorStateChangeOptions {
|
|
@@ -1,2 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
interface ItemEditorToolbarProps {
|
|
2
|
+
onBackRequested?: () => void;
|
|
3
|
+
onSimulatorRequested?: () => void;
|
|
4
|
+
onSaveRequested: () => void;
|
|
5
|
+
}
|
|
6
|
+
declare const ItemEditorToolbar: React.FC<ItemEditorToolbarProps>;
|
|
2
7
|
export default ItemEditorToolbar;
|
|
@@ -1,2 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
interface ItemEditorProps {
|
|
2
|
+
onBackRequested?: () => void;
|
|
3
|
+
onSimulatorRequested?: () => void;
|
|
4
|
+
onSaveRequested: () => void;
|
|
5
|
+
}
|
|
6
|
+
declare const ItemEditor: React.FC<ItemEditorProps>;
|
|
2
7
|
export default ItemEditor;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { StoreApi } from 'zustand';
|
|
2
|
-
import { SurveyEditor, Target, SurveyItemClipboardData, CommitMeta, UndoRedoConfig } from '@case-framework/survey-core/editor';
|
|
2
|
+
import { SurveyEditor, Target, SurveyItemClipboardData, CommitMeta, SurveyEditorHistoryCommit, UndoRedoConfig } from '@case-framework/survey-core/editor';
|
|
3
3
|
import { SurveyItemCore, SurveyItemTranslations, RawSurveyItem, TemplateValueDefinition, GroupItemCore, RawSurveyAsset, SurveyCardContent, NavigationContent, Content } from '@case-framework/survey-core';
|
|
4
4
|
import { ComposedEditorItemRegistry, ItemCategory, ItemLocaleMap, ItemRegistryEntry } from '../registry';
|
|
5
5
|
interface StartNewSessionOptions {
|
|
@@ -44,6 +44,7 @@ export interface EditorStore {
|
|
|
44
44
|
memorySize: number;
|
|
45
45
|
isCurrent: boolean;
|
|
46
46
|
}>;
|
|
47
|
+
getCommitsSinceInitial: () => SurveyEditorHistoryCommit[];
|
|
47
48
|
addItem: (target: Target | null, item: SurveyItemCore, content?: SurveyItemTranslations) => void;
|
|
48
49
|
removeItem: (itemId: string, nested?: boolean) => boolean;
|
|
49
50
|
moveItem: (itemId: string, newTarget: Target) => boolean;
|
|
@@ -20,6 +20,8 @@ export interface SurveyEditorProps {
|
|
|
20
20
|
helpLink?: string;
|
|
21
21
|
navigationAdapter?: SurveyEditorNavigationAdapter | null;
|
|
22
22
|
aiProvider?: SurveyEditorAIProvider | null;
|
|
23
|
+
onBackRequested?: () => void;
|
|
24
|
+
onSimulatorRequested?: () => void;
|
|
23
25
|
onSaveRequested?: () => void;
|
|
24
26
|
}
|
|
25
27
|
declare const SurveyEditor: React.FC<SurveyEditorProps>;
|