Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update the onModified event description #5671

Merged
merged 1 commit into from
Jul 12, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 3 additions & 20 deletions packages/survey-creator-core/src/creator-events-api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -447,29 +447,21 @@ export interface LogicRuleGetDisplayTextEvent {

export interface ModifiedEvent {
/**
* A value that indicates the modification: `"ADDED_FROM_TOOLBOX"`, `"PAGE_ADDED"`, `"PAGE_MOVED"`, `"QUESTION_CONVERTED"`, `"QUESTION_CHANGED_BY_EDITOR"`, `"PROPERTY_CHANGED"`, `"ELEMENT_REORDERED"`, `"OBJECT_DELETED"`, `"VIEW_TYPE_CHANGED"`, `"DO_DROP"`, `"TRANSLATIONS_CHANGED"`, `"JSON_EDITOR"`, `"THEME_MODIFIED"`
* A value that indicates the modification: `"ADDED_FROM_TOOLBOX"`, "ADDED_FROM_PAGEBUTTON", `"PAGE_ADDED"`, `"QUESTION_CONVERTED"`, `"ELEMENT_COPIED"`, `"PROPERTY_CHANGED"`, `"ELEMENT_REORDERED"`, `"OBJECT_DELETED"`, `"JSON_EDITOR"`
*
* Depending on the `options.type` value, the `options` object contains parameters listed below:
*
* `options.type`: `"ADDED_FROM_TOOLBOX"`
* - `options.question` - An added question.
* `options.type`: `"ADDED_FROM_TOOLBOX"` | `"ADDED_FROM_PAGEBUTTON"` | `"ELEMENT_COPIED"`
* - `options.question` - An added or copied survey element.
*
* `options.type`: `"PAGE_ADDED"`
* - `options.newValue` - An added page.
*
* `options.type`: `"PAGE_MOVED"`
* - `options.page` - A moved page.
* - `options.indexFrom` - A previous index.
* - `options.indexTo` - A current index.
*
* `options.type`: `"QUESTION_CONVERTED"`
* - `options.className` - The name of a class to which a question has been converted.
* - `options.oldValue` - An object of a previous class.
* - `options.newValue` - An object of a class specified by `options.className`.
*
* `options.type`: `"QUESTION_CHANGED_BY_EDITOR"`
* - `options.question` - A question that has been edited in a pop-up editor.
*
* `options.type`: `"PROPERTY_CHANGED"`
* - `options.name` - The name of the changed property.
* - `options.target` - An object that contains the changed property.
Expand All @@ -485,15 +477,6 @@ export interface ModifiedEvent {
*
* `options.type`: `"OBJECT_DELETED"`
* - `options.target` - A deleted object.
*
* `options.type`: `"VIEW_TYPE_CHANGED"`
* - `options.newType` - A current view: `"editor"` or `"designer"`.
*
* `options.type`: `"DO_DROP"`
* - `options.page` - A parent page of the dragged element.
* - `options.source` - A dragged element.
* - `options.target` - A drop target.
* - `options.newElement` - A new element. This parameter is defined only if users drag a question or panel from the Toolbox.
*/
type: string;
question?: Question;
Expand Down
Loading