@billpeng/surveyjs-editor
Version:
Use surveyjs Builder(Editor) to create or edit JSON for surveyjs library.
1,535 lines (1,514 loc) • 109 kB
TypeScript
/*Type definitions for Surveyjs Builder(Editor) JavaScript library v1.0.46-4
(c) Devsoft Baltic O� - http://surveyjs.io/
Github: https://github.com/surveyjs/editor
License: https://surveyjs.io/Licenses#BuildSurvey
*/
// Dependencies for this module:
// ../../../survey-knockout
import * as Survey from "survey-knockout";
import "../utils/custom-checkbox.scss";
import "../utils/custom-select.scss";
import "../utils/ddmenu.scss";
import "../main.scss";
import "../localization/french";
import "../localization/german";
import "../localization/italian";
import "../localization/korean";
import "../localization/persian";
import "../localization/polish";
import "../localization/portuguese";
import "../localization/simplified-chinese";
import "../localization/spanish";
import "../localization/traditional-chinese";
export declare var enStrings: {
survey: {
edit: string;
dropQuestion: string;
copy: string;
addToToolbox: string;
deletePanel: string;
deleteQuestion: string;
convertTo: string;
drag: string;
};
qt: {
default: string;
checkbox: string;
comment: string;
imagepicker: string;
dropdown: string;
file: string;
html: string;
matrix: string;
matrixdropdown: string;
matrixdynamic: string;
multipletext: string;
panel: string;
paneldynamic: string;
radiogroup: string;
rating: string;
text: string;
boolean: string;
expression: string;
};
ed: {
defaultLocale: string;
survey: string;
settings: string;
editSurvey: string;
addNewPage: string;
moveRight: string;
moveLeft: string;
deletePage: string;
editPage: string;
edit: string;
newPageName: string;
newQuestionName: string;
newPanelName: string;
testSurvey: string;
testSurveyAgain: string;
testSurveyWidth: string;
embedSurvey: string;
translation: string;
saveSurvey: string;
designer: string;
jsonEditor: string;
undo: string;
redo: string;
options: string;
generateValidJSON: string;
generateReadableJSON: string;
toolbox: string;
toolboxGeneralCategory: string;
delSelObject: string;
editSelObject: string;
correctJSON: string;
surveyResults: string;
modified: string;
saving: string;
saved: string;
saveError: string;
translationAddLanguage: string;
translationShowAllStrings: string;
translationShowAllPages: string;
translationNoStrings: string;
translationExportToSCVButton: string;
translationImportFromSCVButton: string;
};
pel: {
isRequired: string;
};
pe: {
apply: string;
ok: string;
cancel: string;
reset: string;
close: string;
delete: string;
addNew: string;
addItem: string;
removeAll: string;
edit: string;
itemValueEdit: string;
editChoices: string;
move: string;
empty: string;
notEmpty: string;
fastEntry: string;
formEntry: string;
testService: string;
conditionSelectQuestion: string;
conditionValueQuestionTitle: string;
conditionButtonAdd: string;
conditionButtonReplace: string;
conditionHelp: string;
expressionHelp: string;
aceEditorHelp: string;
aceEditorRowTitle: string;
aceEditorPanelTitle: string;
showMore: string;
conditionShowMoreUrl: string;
assistantTitle: string;
cellsEmptyRowsColumns: string;
propertyIsEmpty: string;
value: string;
text: string;
rowid: string;
imageLink: string;
columnEdit: string;
itemEdit: string;
url: string;
path: string;
valueName: string;
titleName: string;
hasOther: string;
otherText: string;
name: string;
title: string;
cellType: string;
colCount: string;
choicesOrder: string;
visible: string;
isRequired: string;
startWithNewLine: string;
rows: string;
placeHolder: string;
showPreview: string;
storeDataAsText: string;
maxSize: string;
imageHeight: string;
imageWidth: string;
rowCount: string;
columnLayout: string;
addRowLocation: string;
addRowText: string;
removeRowText: string;
minRateDescription: string;
maxRateDescription: string;
inputType: string;
optionsCaption: string;
defaultValue: string;
cellsDefaultRow: string;
surveyEditorTitle: string;
qEditorTitle: string;
maxLength: string;
showTitle: string;
locale: string;
mode: string;
clearInvisibleValues: string;
cookieName: string;
sendResultOnPageNext: string;
storeOthersAsComment: string;
showPageTitles: string;
showPageNumbers: string;
pagePrevText: string;
pageNextText: string;
completeText: string;
startSurveyText: string;
showNavigationButtons: string;
showPrevButton: string;
firstPageIsStarted: string;
showCompletedPage: string;
goNextPageAutomatic: string;
showProgressBar: string;
questionTitleLocation: string;
requiredText: string;
questionStartIndex: string;
showQuestionNumbers: string;
questionTitleTemplate: string;
questionErrorLocation: string;
focusFirstQuestionAutomatic: string;
questionsOrder: string;
maxTimeToFinish: string;
maxTimeToFinishPage: string;
showTimerPanel: string;
showTimerPanelMode: string;
renderMode: string;
allowAddPanel: string;
allowRemovePanel: string;
panelAddText: string;
panelRemoveText: string;
isSinglePage: string;
tabs: {
general: string;
fileOptions: string;
html: string;
columns: string;
rows: string;
choices: string;
items: string;
visibleIf: string;
enableIf: string;
rateValues: string;
choicesByUrl: string;
matrixChoices: string;
multipleTextItems: string;
validators: string;
navigation: string;
question: string;
completedHtml: string;
loadingHtml: string;
timer: string;
triggers: string;
templateTitle: string;
};
editProperty: string;
items: string;
enterNewValue: string;
noquestions: string;
createtrigger: string;
triggerOn: string;
triggerMakePagesVisible: string;
triggerMakeQuestionsVisible: string;
triggerCompleteText: string;
triggerNotSet: string;
triggerRunIf: string;
triggerSetToName: string;
triggerFromName: string;
triggerRunExpression: string;
triggerSetValue: string;
triggerIsVariable: string;
};
pv: {
true: string;
false: string;
inherit: string;
show: string;
hide: string;
default: string;
initial: string;
random: string;
collapsed: string;
expanded: string;
none: string;
asc: string;
desc: string;
indeterminate: string;
decimal: string;
currency: string;
percent: string;
firstExpanded: string;
off: string;
onPanel: string;
onSurvey: string;
list: string;
progressTop: string;
progressBottom: string;
progressTopBottom: string;
horizontal: string;
vertical: string;
top: string;
bottom: string;
topBottom: string;
left: string;
color: string;
date: string;
datetime: string;
"datetime-local": string;
email: string;
month: string;
number: string;
password: string;
range: string;
tel: string;
text: string;
time: string;
url: string;
week: string;
hidden: string;
on: string;
onPage: string;
edit: string;
display: string;
onComplete: string;
onHidden: string;
all: string;
page: string;
survey: string;
onNextPage: string;
onValueChanged: string;
};
op: {
empty: string;
notempty: string;
equal: string;
notequal: string;
contains: string;
notcontains: string;
greater: string;
less: string;
greaterorequal: string;
lessorequal: string;
};
ew: {
angular: string;
jquery: string;
knockout: string;
react: string;
vue: string;
bootstrap: string;
standard: string;
showOnPage: string;
showInWindow: string;
loadFromServer: string;
titleScript: string;
titleHtml: string;
titleJavaScript: string;
};
ts: {
selectPage: string;
};
validators: {
answercountvalidator: string;
emailvalidator: string;
expressionvalidator: string;
numericvalidator: string;
regexvalidator: string;
textvalidator: string;
};
triggers: {
completetrigger: string;
setvaluetrigger: string;
copyvaluetrigger: string;
runexpressiontrigger: string;
visibletrigger: string;
};
p: {
name: string;
title: {
name: string;
title: string;
};
navigationButtonsVisibility: string;
questionsOrder: string;
maxTimeToFinish: string;
visible: string;
visibleIf: string;
questionTitleLocation: string;
description: string;
state: string;
isRequired: string;
indent: string;
requiredErrorText: string;
startWithNewLine: string;
innerIndent: string;
page: string;
width: string;
commentText: string;
valueName: string;
enableIf: string;
defaultValue: string;
correctAnswer: string;
readOnly: string;
validators: string;
titleLocation: string;
hasComment: string;
hasOther: string;
choices: string;
choicesOrder: string;
choicesByUrl: string;
otherText: string;
otherErrorText: string;
storeOthersAsComment: string;
label: string;
showTitle: string;
valueTrue: string;
valueFalse: string;
cols: string;
rows: string;
placeHolder: string;
optionsCaption: string;
expression: string;
format: string;
displayStyle: string;
currency: string;
useGrouping: string;
showPreview: string;
allowMultiple: string;
imageHeight: string;
imageWidth: string;
storeDataAsText: string;
maxSize: string;
html: string;
columns: string;
cells: string;
isAllRowRequired: string;
horizontalScroll: string;
cellType: string;
columnsLayout: string;
columnColCount: string;
columnMinWidth: string;
rowCount: string;
minRowCount: string;
maxRowCount: string;
keyName: string;
keyDuplicationError: string;
confirmDelete: string;
confirmDeleteText: string;
addRowLocation: string;
addRowText: string;
removeRowText: string;
items: string;
itemSize: string;
colCount: string;
templateTitle: string;
templateDescription: string;
allowAddPanel: string;
allowRemovePanel: string;
panelCount: string;
minPanelCount: string;
maxPanelCount: string;
panelsState: string;
panelAddText: string;
panelRemoveText: string;
panelPrevText: string;
panelNextText: string;
showQuestionNumbers: string;
showRangeInProgress: string;
renderMode: string;
templateTitleLocation: string;
rateValues: string;
rateMin: string;
rateMax: string;
rateStep: string;
minRateDescription: string;
maxRateDescription: string;
inputType: string;
size: string;
locale: string;
focusFirstQuestionAutomatic: string;
completedHtml: string;
completedBeforeHtml: string;
loadingHtml: string;
triggers: string;
cookieName: string;
sendResultOnPageNext: string;
showNavigationButtons: string;
showPrevButton: string;
showPageTitles: string;
showCompletedPage: string;
showPageNumbers: string;
questionErrorLocation: string;
showProgressBar: string;
mode: string;
goNextPageAutomatic: string;
checkErrorsMode: string;
clearInvisibleValues: string;
startSurveyText: string;
pagePrevText: string;
pageNextText: string;
completeText: string;
requiredText: string;
questionStartIndex: string;
questionTitleTemplate: string;
firstPageIsStarted: string;
isSinglePage: string;
maxTimeToFinishPage: string;
showTimerPanel: string;
showTimerPanelMode: string;
defaultPanelValue: string;
defaultRowValue: string;
hasNone: string;
noneText: string;
text: string;
minValue: string;
maxValue: string;
minLength: string;
maxLength: string;
allowDigits: string;
minCount: string;
maxCount: string;
regex: string;
};
};
export declare var editorLocalization: {
currentLocale: string;
locales: {};
getString: (strName: string, locale?: string) => any;
hasString: (strName: string, locale?: string) => boolean;
getLocaleName: (loc: string) => string;
getPropertyName: (strName: string, locale?: string) => any;
getPropertyTitle: (strName: string, locale?: string) => any;
getProperty: (strName: string, locale?: string) => any;
getPropertyValue: (value: any, locale?: string) => any;
getValidatorName: (name: string, locale?: string) => any;
getTriggerName: (name: string, locale?: string) => any;
getLocale(locale: string): any;
getValueInternal(value: any, prefix: string, locale?: string): any;
getLocales: () => string[];
};
export declare var defaultStrings: {
survey: {
edit: string;
dropQuestion: string;
copy: string;
addToToolbox: string;
deletePanel: string;
deleteQuestion: string;
convertTo: string;
drag: string;
};
qt: {
default: string;
checkbox: string;
comment: string;
imagepicker: string;
dropdown: string;
file: string;
html: string;
matrix: string;
matrixdropdown: string;
matrixdynamic: string;
multipletext: string;
panel: string;
paneldynamic: string;
radiogroup: string;
rating: string;
text: string;
boolean: string;
expression: string;
};
ed: {
defaultLocale: string;
survey: string;
settings: string;
editSurvey: string;
addNewPage: string;
moveRight: string;
moveLeft: string;
deletePage: string;
editPage: string;
edit: string;
newPageName: string;
newQuestionName: string;
newPanelName: string;
testSurvey: string;
testSurveyAgain: string;
testSurveyWidth: string;
embedSurvey: string;
translation: string;
saveSurvey: string;
designer: string;
jsonEditor: string;
undo: string;
redo: string;
options: string;
generateValidJSON: string;
generateReadableJSON: string;
toolbox: string;
toolboxGeneralCategory: string;
delSelObject: string;
editSelObject: string;
correctJSON: string;
surveyResults: string;
modified: string;
saving: string;
saved: string;
saveError: string;
translationAddLanguage: string;
translationShowAllStrings: string;
translationShowAllPages: string;
translationNoStrings: string;
translationExportToSCVButton: string;
translationImportFromSCVButton: string;
};
pel: {
isRequired: string;
};
pe: {
apply: string;
ok: string;
cancel: string;
reset: string;
close: string;
delete: string;
addNew: string;
addItem: string;
removeAll: string;
edit: string;
itemValueEdit: string;
editChoices: string;
move: string;
empty: string;
notEmpty: string;
fastEntry: string;
formEntry: string;
testService: string;
conditionSelectQuestion: string;
conditionValueQuestionTitle: string;
conditionButtonAdd: string;
conditionButtonReplace: string;
conditionHelp: string;
expressionHelp: string;
aceEditorHelp: string;
aceEditorRowTitle: string;
aceEditorPanelTitle: string;
showMore: string;
conditionShowMoreUrl: string;
assistantTitle: string;
cellsEmptyRowsColumns: string;
propertyIsEmpty: string;
value: string;
text: string;
rowid: string;
imageLink: string;
columnEdit: string;
itemEdit: string;
url: string;
path: string;
valueName: string;
titleName: string;
hasOther: string;
otherText: string;
name: string;
title: string;
cellType: string;
colCount: string;
choicesOrder: string;
visible: string;
isRequired: string;
startWithNewLine: string;
rows: string;
placeHolder: string;
showPreview: string;
storeDataAsText: string;
maxSize: string;
imageHeight: string;
imageWidth: string;
rowCount: string;
columnLayout: string;
addRowLocation: string;
addRowText: string;
removeRowText: string;
minRateDescription: string;
maxRateDescription: string;
inputType: string;
optionsCaption: string;
defaultValue: string;
cellsDefaultRow: string;
surveyEditorTitle: string;
qEditorTitle: string;
maxLength: string;
showTitle: string;
locale: string;
mode: string;
clearInvisibleValues: string;
cookieName: string;
sendResultOnPageNext: string;
storeOthersAsComment: string;
showPageTitles: string;
showPageNumbers: string;
pagePrevText: string;
pageNextText: string;
completeText: string;
startSurveyText: string;
showNavigationButtons: string;
showPrevButton: string;
firstPageIsStarted: string;
showCompletedPage: string;
goNextPageAutomatic: string;
showProgressBar: string;
questionTitleLocation: string;
requiredText: string;
questionStartIndex: string;
showQuestionNumbers: string;
questionTitleTemplate: string;
questionErrorLocation: string;
focusFirstQuestionAutomatic: string;
questionsOrder: string;
maxTimeToFinish: string;
maxTimeToFinishPage: string;
showTimerPanel: string;
showTimerPanelMode: string;
renderMode: string;
allowAddPanel: string;
allowRemovePanel: string;
panelAddText: string;
panelRemoveText: string;
isSinglePage: string;
tabs: {
general: string;
fileOptions: string;
html: string;
columns: string;
rows: string;
choices: string;
items: string;
visibleIf: string;
enableIf: string;
rateValues: string;
choicesByUrl: string;
matrixChoices: string;
multipleTextItems: string;
validators: string;
navigation: string;
question: string;
completedHtml: string;
loadingHtml: string;
timer: string;
triggers: string;
templateTitle: string;
};
editProperty: string;
items: string;
enterNewValue: string;
noquestions: string;
createtrigger: string;
triggerOn: string;
triggerMakePagesVisible: string;
triggerMakeQuestionsVisible: string;
triggerCompleteText: string;
triggerNotSet: string;
triggerRunIf: string;
triggerSetToName: string;
triggerFromName: string;
triggerRunExpression: string;
triggerSetValue: string;
triggerIsVariable: string;
};
pv: {
true: string;
false: string;
inherit: string;
show: string;
hide: string;
default: string;
initial: string;
random: string;
collapsed: string;
expanded: string;
none: string;
asc: string;
desc: string;
indeterminate: string;
decimal: string;
currency: string;
percent: string;
firstExpanded: string;
off: string;
onPanel: string;
onSurvey: string;
list: string;
progressTop: string;
progressBottom: string;
progressTopBottom: string;
horizontal: string;
vertical: string;
top: string;
bottom: string;
topBottom: string;
left: string;
color: string;
date: string;
datetime: string;
"datetime-local": string;
email: string;
month: string;
number: string;
password: string;
range: string;
tel: string;
text: string;
time: string;
url: string;
week: string;
hidden: string;
on: string;
onPage: string;
edit: string;
display: string;
onComplete: string;
onHidden: string;
all: string;
page: string;
survey: string;
onNextPage: string;
onValueChanged: string;
};
op: {
empty: string;
notempty: string;
equal: string;
notequal: string;
contains: string;
notcontains: string;
greater: string;
less: string;
greaterorequal: string;
lessorequal: string;
};
ew: {
angular: string;
jquery: string;
knockout: string;
react: string;
vue: string;
bootstrap: string;
standard: string;
showOnPage: string;
showInWindow: string;
loadFromServer: string;
titleScript: string;
titleHtml: string;
titleJavaScript: string;
};
ts: {
selectPage: string;
};
validators: {
answercountvalidator: string;
emailvalidator: string;
expressionvalidator: string;
numericvalidator: string;
regexvalidator: string;
textvalidator: string;
};
triggers: {
completetrigger: string;
setvaluetrigger: string;
copyvaluetrigger: string;
runexpressiontrigger: string;
visibletrigger: string;
};
p: {
name: string;
title: {
name: string;
title: string;
};
navigationButtonsVisibility: string;
questionsOrder: string;
maxTimeToFinish: string;
visible: string;
visibleIf: string;
questionTitleLocation: string;
description: string;
state: string;
isRequired: string;
indent: string;
requiredErrorText: string;
startWithNewLine: string;
innerIndent: string;
page: string;
width: string;
commentText: string;
valueName: string;
enableIf: string;
defaultValue: string;
correctAnswer: string;
readOnly: string;
validators: string;
titleLocation: string;
hasComment: string;
hasOther: string;
choices: string;
choicesOrder: string;
choicesByUrl: string;
otherText: string;
otherErrorText: string;
storeOthersAsComment: string;
label: string;
showTitle: string;
valueTrue: string;
valueFalse: string;
cols: string;
rows: string;
placeHolder: string;
optionsCaption: string;
expression: string;
format: string;
displayStyle: string;
currency: string;
useGrouping: string;
showPreview: string;
allowMultiple: string;
imageHeight: string;
imageWidth: string;
storeDataAsText: string;
maxSize: string;
html: string;
columns: string;
cells: string;
isAllRowRequired: string;
horizontalScroll: string;
cellType: string;
columnsLayout: string;
columnColCount: string;
columnMinWidth: string;
rowCount: string;
minRowCount: string;
maxRowCount: string;
keyName: string;
keyDuplicationError: string;
confirmDelete: string;
confirmDeleteText: string;
addRowLocation: string;
addRowText: string;
removeRowText: string;
items: string;
itemSize: string;
colCount: string;
templateTitle: string;
templateDescription: string;
allowAddPanel: string;
allowRemovePanel: string;
panelCount: string;
minPanelCount: string;
maxPanelCount: string;
panelsState: string;
panelAddText: string;
panelRemoveText: string;
panelPrevText: string;
panelNextText: string;
showQuestionNumbers: string;
showRangeInProgress: string;
renderMode: string;
templateTitleLocation: string;
rateValues: string;
rateMin: string;
rateMax: string;
rateStep: string;
minRateDescription: string;
maxRateDescription: string;
inputType: string;
size: string;
locale: string;
focusFirstQuestionAutomatic: string;
completedHtml: string;
completedBeforeHtml: string;
loadingHtml: string;
triggers: string;
cookieName: string;
sendResultOnPageNext: string;
showNavigationButtons: string;
showPrevButton: string;
showPageTitles: string;
showCompletedPage: string;
showPageNumbers: string;
questionErrorLocation: string;
showProgressBar: string;
mode: string;
goNextPageAutomatic: string;
checkErrorsMode: string;
clearInvisibleValues: string;
startSurveyText: string;
pagePrevText: string;
pageNextText: string;
completeText: string;
requiredText: string;
questionStartIndex: string;
questionTitleTemplate: string;
firstPageIsStarted: string;
isSinglePage: string;
maxTimeToFinishPage: string;
showTimerPanel: string;
showTimerPanelMode: string;
defaultPanelValue: string;
defaultRowValue: string;
hasNone: string;
noneText: string;
text: string;
minValue: string;
maxValue: string;
minLength: string;
maxLength: string;
allowDigits: string;
minCount: string;
maxCount: string;
regex: string;
};
};
export declare class DragDropTargetElement {
page: Survey.Page;
target: any;
source: any;
moveToParent: any;
moveToIndex: number;
nestedPanelDepth: number;
constructor(page: Survey.Page, target: any, source: any);
moveTo(destination: any, isBottom: boolean, isEdge?: boolean): boolean;
doDrop(): any;
clear(): void;
}
export declare class DragDropHelper {
data: Survey.ISurvey;
static edgeHeight: number;
static nestedPanelDepth: number;
static dataStart: string;
static dragData: any;
static prevEvent: {
element: any;
x: number;
y: number;
};
static counter: number;
constructor(data: Survey.ISurvey, onModifiedCallback: (options?: any) => any, parent?: HTMLElement);
attachToElement(domElement: any, surveyElement: any): void;
readonly survey: Survey.Survey;
startDragQuestion(event: DragEvent, element: any): void;
startDragToolboxItem(event: DragEvent, elementName: string, elementJson: any): void;
isSurveyDragging(event: DragEvent): boolean;
doDragDropOver(event: DragEvent, element: any, isEdge?: boolean): void;
replaceTargetElement(element: any): any;
end(): void;
readonly isMoving: boolean;
doDrop(event: DragEvent): void;
doLeavePage(event: DragEvent): void;
scrollToElement(el: HTMLElement): void;
}
export interface ISurveyObjectEditorOptions {
alwaySaveTextInPropertyEditors: boolean;
showApplyButtonInEditors: boolean;
useTabsInElementEditor: boolean;
onItemValueAddedCallback(propertyName: string, itemValue: Survey.ItemValue, itemValues: Array<Survey.ItemValue>): any;
onMatrixDropdownColumnAddedCallback(column: Survey.MatrixDropdownColumn): any;
onSetPropertyEditorOptionsCallback(propertyName: string, obj: Survey.Base, editorOptions: any): any;
onGetErrorTextOnValidationCallback(propertyName: string, obj: Survey.Base, value: any): string;
onValueChangingCallback(options: any): any;
onPropertyEditorObjectSetCallback(propertyName: string, obj: Survey.Base, editor: SurveyPropertyEditorBase): any;
onPropertyEditorKeyDownCallback(propertyName: string, obj: Survey.Base, editor: SurveyPropertyEditorBase, event: KeyboardEvent): any;
onPropertyEditorModalShowDescriptionCallback(propertyName: string, obj: Survey.Base): any;
onGetElementEditorTitleCallback(obj: Survey.Base, title: string): string;
}
export declare class SurveyPropertyEditorBase implements Survey.ILocalizableOwner {
koValue: any;
koText: any;
koIsDefault: any;
koHasError: any;
koErrorText: any;
koDisplayError: any;
isTabProperty: boolean;
isInplaceProperty: boolean;
onChanged: (newValue: any) => any;
onGetLocale: () => string;
onValueUpdated: (newValue: any) => any;
setup(): void;
beforeShow(): void;
constructor(property: Survey.JsonObjectProperty);
readonly editorType: string;
readonly editorTypeTemplate: string;
readonly property: Survey.JsonObjectProperty;
readonly defaultValue: any;
readonly editablePropertyName: string;
readonly readOnly: boolean;
readonly alwaysShowEditor: boolean;
readonly title: string;
readonly isDiplayNameVisible: boolean;
displayName: string;
readonly showDisplayNameOnTop: boolean;
readonly canShowDisplayNameOnTop: boolean;
readonly contentTemplateName: string;
readonly isModal: boolean;
object: any;
getValueText(value: any): string;
editingValue: any;
hasError(): boolean;
getLocString(name: string): any;
hasLocString(name: string): boolean;
protected checkForErrors(): boolean;
readonly isRequired: boolean;
protected setIsRequired(): void;
protected setTitleAndDisplayName(): void;
protected onBeforeApply(): void;
apply(): boolean;
readonly locale: string;
getLocale(): string;
getMarkdownHtml(text: string): string;
getProcessedText(text: string): string;
options: ISurveyObjectEditorOptions;
protected onOptionsChanged(): void;
protected setValueCore(value: any): void;
setObject(value: any): void;
activate(): void;
protected createEditorOptions(): any;
protected onSetEditorOptions(editorOptions: any): void;
protected onValueChanged(): void;
protected getCorrectedValue(value: any): any;
protected beginValueUpdating(): void;
protected endValueUpdating(): void;
protected updateValue(): void;
protected getValue(): any;
keyDownHandler(property: any, event: any): boolean;
}
export declare class SurveyPropertyCustomEditor extends SurveyPropertyEditorBase {
onValueChangedCallback: (newValue: any) => void;
constructor(property: Survey.JsonObjectProperty, widgetJSON?: any);
readonly editorType: string;
readonly widgetJSON: any;
protected onValueChanged(): void;
protected readonly widgetRender: any;
protected doAfterRender(elements: any, con: any): void;
}
export declare class SurveyPropertyEditorFactory {
static defaultEditor: string;
static getOperators(): Array<any>;
static registerEditor(name: string, creator: (property: Survey.JsonObjectProperty) => SurveyPropertyEditorBase, editableClassName?: string): void;
static registerCustomEditor(name: string, widgetJSON: any): void;
static createEditor(property: Survey.JsonObjectProperty, func: (newValue: any) => any): SurveyPropertyEditorBase;
}
export declare class SurveyStringPropertyEditor extends SurveyPropertyEditorBase {
constructor(property: Survey.JsonObjectProperty);
readonly editorType: string;
}
export declare class SurveyDropdownPropertyEditor extends SurveyPropertyEditorBase {
koChoices: any;
koHasFocus: any;
constructor(property: Survey.JsonObjectProperty);
readonly editorType: string;
getValueText(value: any): string;
setObject(value: any): void;
}
export declare class SurveyBooleanPropertyEditor extends SurveyPropertyEditorBase {
constructor(property: Survey.JsonObjectProperty);
readonly editorType: string;
readonly alwaysShowEditor: boolean;
readonly canShowDisplayNameOnTop: boolean;
getValueText(value: any): string;
}
export declare class SurveyNumberPropertyEditor extends SurveyPropertyEditorBase {
constructor(property: Survey.JsonObjectProperty);
readonly editorType: string;
protected getCorrectedValue(value: any): any;
}
export declare class SurveyPropertyTextItemsEditor extends SurveyNestedPropertyEditor {
constructor(property: Survey.JsonObjectProperty);
readonly editorType: string;
protected getEditorName(): string;
protected createNewEditorItem(): any;
protected createEditorItem(item: any): SurveyPropertyTextItemsItem;
protected createItemFromEditorItem(editorItem: any): any;
protected getProperties(): Array<Survey.JsonObjectProperty>;
}
export declare class SurveyPropertyTextItemsItem extends SurveyNestedPropertyEditorItem {
item: Survey.MultipleTextItem;
columns: Array<SurveyNestedPropertyEditorColumn>;
constructor(item: Survey.MultipleTextItem, columns: Array<SurveyNestedPropertyEditorColumn>, options: ISurveyObjectEditorOptions);
protected createSurveyQuestionEditor(): SurveyQuestionEditor;
}
export declare class SurveyPropertyItemsEditor extends SurveyPropertyModalEditor {
koItems: any;
onDeleteClick: any;
onAddClick: any;
onClearClick: any;
koAllowAddRemoveItems: any;
constructor(property: Survey.JsonObjectProperty);
getValueText(value: any): string;
protected getCorrectedValue(value: any): any;
protected createEditorOptions(): any;
protected onSetEditorOptions(editorOptions: any): void;
sortableOptions: {
handle: string;
animation: number;
};
protected AddItem(): void;
protected setupItems(): void;
protected onValueChanged(): void;
setup(): void;
protected getItemsFromValue(value?: any): Array<any>;
protected onBeforeApply(): void;
protected createNewEditorItem(): any;
protected createEditorItem(item: any): any;
protected createItemFromEditorItem(editorItem: any): any;
}
export declare class SurveyPropertyItemValuesEditor extends SurveyNestedPropertyEditor {
koItemsText: any;
koShowTextView: any;
changeToTextViewClick: any;
changeToFormViewClick: any;
constructor(property: Survey.JsonObjectProperty);
readonly editorType: string;
readonly hasDetailButton: boolean;
protected getItemValueClassName(): string;
protected getEditorName(): string;
beforeShow(): void;
protected getProperties(): Array<Survey.JsonObjectProperty>;
protected readonly itemValueClasseName: string;
protected getDefinedProperties(): Array<any>;
protected getDefaultProperties(): Array<Survey.JsonObjectProperty>;
protected createEditorOptions(): any;
protected onSetEditorOptions(editorOptions: any): void;
protected createNewEditorItem(): any;
protected createEditorItem(item: any): any;
protected createItemFromEditorItem(editorItem: any): Survey.ItemValue;
protected onValueChanged(): void;
protected onBeforeApply(): void;
protected onListDetailViewChanged(): void;
protected updateItems(text: string): void;
protected getItemsText(): string;
}
export declare class SurveyPropertyItemValuesEditorItem extends SurveyNestedPropertyEditorItem {
item: Survey.ItemValue;
columns: Array<SurveyNestedPropertyEditorColumn>;
constructor(item: Survey.ItemValue, columns: Array<SurveyNestedPropertyEditorColumn>, options: ISurveyObjectEditorOptions, className?: string);
protected createSurveyQuestionEditor(): SurveyQuestionEditor;
}
export declare class SurveyPropertyMultipleValuesEditor extends SurveyPropertyModalEditor {
koItems: any;
koEditingValue: any;
constructor(property: Survey.JsonObjectProperty);
getValueText(value: any): string;
setObject(value: any): void;
protected updateValue(): void;
protected onBeforeApply(): void;
readonly editorType: string;
getBackgroundCls(value: any): "svd-light-background-color" | "svd-main-background-color";
}
export declare class SurveyNestedPropertyEditor extends SurveyPropertyItemsEditor {
koEditItem: any;
koIsList: any;
koActiveView: any;
onEditItemClick: any;
onCancelEditItemClick: any;
koEditorName: any;
constructor(property: Survey.JsonObjectProperty);
readonly canShowDisplayNameOnTop: boolean;
readonly columns: Array<SurveyNestedPropertyEditorColumn>;
beforeShow(): void;
protected createColumns(): void;
protected getProperties(): Array<Survey.JsonObjectProperty>;
protected getPropertiesNames(definitionName: string, defaultNames: Array<string>): Array<string>;
protected getPropertiesByNames(className: string, names: Array<any>): Array<Survey.JsonObjectProperty>;
protected getEditorName(): string;
protected onListDetailViewChanged(): void;
protected checkForErrors(): boolean;
protected onBeforeApply(): void;
}
export declare class SurveyNestedPropertyEditorItem {
obj: any;
columns: Array<SurveyNestedPropertyEditorColumn>;
protected options: ISurveyObjectEditorOptions;
constructor(obj: any, columns: Array<SurveyNestedPropertyEditorColumn>, options: ISurveyObjectEditorOptions);
readonly itemEditor: SurveyQuestionEditor;
readonly cells: Array<SurveyNestedPropertyEditorEditorCell>;
hasError(): boolean;
protected resetSurveyQuestionEditor(): void;
protected createSurveyQuestionEditor(): any;
apply(): void;
}
export declare class SurveyNestedPropertyEditorColumn {
property: Survey.JsonObjectProperty;
constructor(property: Survey.JsonObjectProperty);
readonly text: string;
}
export declare class SurveyNestedPropertyEditorEditorCell {
obj: any;
property: Survey.JsonObjectProperty;
constructor(obj: any, property: Survey.JsonObjectProperty, options?: ISurveyObjectEditorOptions);
readonly objectProperty: SurveyObjectProperty;
readonly editor: SurveyPropertyEditorBase;
readonly koValue: any;
value: any;
readonly hasError: boolean;
}
export declare class SurveyPropertyDropdownColumnsEditor extends SurveyNestedPropertyEditor {
constructor(property: Survey.JsonObjectProperty);
readonly editorType: string;
protected getEditorName(): string;
protected createNewEditorItem(): any;
protected createEditorItem(item: any): SurveyPropertyMatrixDropdownColumnsItem;
protected createItemFromEditorItem(editorItem: any): any;
protected createEditorItemCore(item: any): Survey.MatrixDropdownColumn;
protected getProperties(): Array<Survey.JsonObjectProperty>;
}
export declare class SurveyPropertyMatrixDropdownColumnsItem extends SurveyNestedPropertyEditorItem {
column: Survey.MatrixDropdownColumn;
columns: Array<SurveyNestedPropertyEditorColumn>;
constructor(column: Survey.MatrixDropdownColumn, columns: Array<SurveyNestedPropertyEditorColumn>, options?: ISurveyObjectEditorOptions);
protected createSurveyQuestionEditor(): SurveyQuestionEditor;
}
export declare class SurveyPropertyModalEditorCustomWidget {
json: any;
constructor(json: any);
afterRender(editor: SurveyPropertyModalEditor, el: HTMLElement): void;
destroy(editor: SurveyPropertyModalEditor, el: HTMLElement): void;
}
export declare class SurveyPropertyModalEditor extends SurveyPropertyEditorBase {
static registerCustomWidget(editorType: string, json: any): void;
static getCustomWidget(editorType: string): SurveyPropertyModalEditorCustomWidget;
editingObject: any;
onApplyClick: any;
onOkClick: any;
onResetClick: any;
onShowModal: any;
onHideModal: any;
modalName: string;
modalNameTarget: string;
koShowApplyButton: any;
koTitleCaption: any;
koAfterRender: any;
koHtmlTop: any;
koHtmlBottom: any;
constructor(property: Survey.JsonObjectProperty);
setup(): void;
readonly isModal: boolean;
readonly isShowingModal: boolean;
beforeShow(): void;
beforeCloseModal(): void;
protected onOptionsChanged(): void;
setObject(value: any): void;
readonly isEditable: boolean;
protected afterRender(elements: any, con: any): void;
}
export declare class SurveyPropertyTextEditor extends SurveyPropertyModalEditor {
koTextValue: any;
constructor(property: Survey.JsonObjectProperty);
readonly editorType: string;
readonly isEditable: boolean;
getValueText(value: any): string;
protected onkoTextValueChanged(newValue: any): void;
protected onValueChanged(): void;
protected onBeforeApply(): void;
}
export declare class SurveyPropertyHtmlEditor extends SurveyPropertyTextEditor {
constructor(property: Survey.JsonObjectProperty);
readonly editorType: string;
}
export declare class SurveyPropertyConditionEditor extends SurveyPropertyTextEditor {
syntaxCheckMethodName: string;
availableOperators: any[];
showHelpText: boolean;
koIsValid: any;
koCanAddCondition: any;
koAddConditionQuestions: any;
koAddConditionQuestion: any;
koAddConditionOperator: any;
koAddConditionValue: any;
koAddConditionType: any;
koShowAddConditionType: any;
koAddConditionButtonText: any;
koAddContionValueEnabled: any;
koHasValueSurvey: any;
onConditionAddClick: any;
koValueSurvey: any;
constructor(property: Survey.JsonObjectProperty, _type?: string, syntaxCheckMethodName?: string);
setObject(value: any): void;
readonly editorType: string;
readonly availableQuestions: any[];
readonly allConditionQuestions: any[];
readonly hasAceEditor: boolean;
readonly addConditionQuestionOptions: string;
addCondition(): void;
protected onBeforeApply(): void;
protected onkoTextValueChanged(newValue: any): void;
}
export declare function doGetCompletions(prevIdentifier: string, prefix: string, config: {
question: Survey.Question;
questions: Survey.Question[];
}, completer?: any): any[];
export declare function insertMatch(editor: any, data: any): void;
export declare class SurveyPropertyResultfullEditor extends SurveyPropertyModalEditor {
koItems: any;
survey: Survey.Survey;
question: Survey.QuestionDropdown;
constructor(property: Survey.JsonObjectProperty);
readonly editorType: string;
readonly restfullValue: any;
getValueText(value: any): string;
protected onValueChanged(): void;
protected onBeforeApply(): void;
}
export declare class SurveyPropertyResultfullEditorItem {
name: string;
onValueChanged: (item: SurveyPropertyResultfullEditorItem) => any;
koValue: any;
constructor(name: string, val: string, onValueChanged: (item: SurveyPropertyResultfullEditorItem) => any);
setValue(val: string): void;
}
export declare class SurveyPropertyDefaultValueEditor extends SurveyPropertyModalEditor {
static defaultQuestionName: string;
static createJsonFromQuestion(obj: any): any;
static createSurveyFromJsonQuestion(questionJson: any): Survey.Survey;
survey: Survey.Survey;
koSurvey: any;
constructor(property: Survey.JsonObjectProperty);
getValueText(value: any): string;
beforeShow(): void;
protected onBeforeApply(): void;
readonly editorType: string;
protected buildQuestionJson(): any;
protected getSurveyInitialValue(): any;
protected getSurveyResult(): any;
}
export declare class SurveyPropertyDefaultRowValueEditorBase extends SurveyPropertyDefaultValueEditor {
constructor(property: Survey.JsonObjectProperty);
readonly editorTypeTemplate: string;
protected getSurveyInitialValue(): any;
protected getSurveyResult(): any;
}
export declare class SurveyPropertyDefaultRowValueEditor extends SurveyPropertyDefaultRowValueEditorBase {
constructor(property: Survey.JsonObjectProperty);
protected buildQuestionJson(): any;
readonly editorType: string;
}
export declare class SurveyPropertyDefaultPanelValueEditor extends SurveyPropertyDefaultRowValueEditorBase {
constructor(property: Survey.JsonObjectProperty);
protected buildQuestionJson(): any;
readonly editorType: string;
}
export declare class SurveyPropertyTriggersEditor extends SurveyPropertyItemsEditor {
koElements: any;
koQuestions: any;
koPages: any;
koQuestionNames: any;
koSelected: any;
koTriggers: any;
availableTriggers: Array<string>;
constructor(property: Survey.JsonObjectProperty);
readonly editorType: string;
protected onValueChanged(): void;
protected createEditorItem(item: any): SurveyPropertyTrigger;
protected createItemFromEditorItem(editorItem: any): Survey.SurveyTrigger;
}
export declare class SurveyPropertyTrigger {
trigger: Survey.SurveyTrigger;
availableOperators: any[];
koName: any;
koOperator: any;
koValue: any;
koType: any;
koText: any;
koIsValid: any;
koRequireValue: any;
conditionEditor: SurveyPropertyConditionEditor;
constructor(trigger: Survey.SurveyTrigger);
createTrigger(): Survey.SurveyTrigger;
}
export declare class SurveyPropertyVisibleTrigger extends SurveyPropertyTrigger {
trigger: Survey.SurveyTriggerVisible;
pages: SurveyPropertyTriggerObjects;
questions: SurveyPropertyTriggerObjects;
constructor(trigger: Survey.SurveyTriggerVisible, koPages: any, koQuestions: any);
createTrigger(): Survey.SurveyTrigger;
}
export declare class SurveyPropertySetValueTrigger extends SurveyPropertyTrigger {
trigger: Survey.SurveyTriggerSetValue;
triggerSurvey: Survey.Survey;
koQuestions: any;
kosetToName: any;
kosetValue: any;
koisVariable: any;
koSurvey: any;
koHasSurvey: any;
survey: Survey.Survey;
constructor(trigger: Survey.SurveyTriggerSetValue, koQuestions: any, triggerSurvey: Survey.Survey);
createTrigger(): Survey.SurveyTrigger;
readonly setToNameOptions: string;
}
export declare class SurveyPropertyCopyValueTrigger extends SurveyPropertyTrigger {
trigger: Survey.SurveyTrigger;
koQuestions: any;
kosetToName: any;
kofromName: any;
constructor(trigger: Survey.SurveyTrigger, koQuestions: any);
createTrigger(): Survey.SurveyTrigger;
}
export declare class SurveyPropertyRunExpressionTrigger extends SurveyPropertyTrigger {
trigger: Survey.SurveyTrigger;
koQuestions: any;
kosetToName: any;
korunExpression: any;
constructor(trigger: Survey.SurveyTrigger, koQuestions: any);
createTrigger(): Survey.SurveyTrigger;
}
export declare class SurveyPropertyTriggerObjects {
title: string;
koObjects: any;
koChoosen: any;
koSelected: any;
koChoosenSelected: any;
onDeleteClick: any;
onAddClick: any;
constructor(title: string, allObjects: Array<string>, choosenObjects: Array<string>);
}
export declare class SurveyPropertyValidatorsEditor extends SurveyPropertyItemsEditor {
koSelected: any;
koValidators: any;
availableValidators: Array<string>;
constructor(property: Survey.JsonObjectProperty);
readonly editorType: string;
protected onValueChanged(): void;
protected createEditorItem(item: any): SurveyPropertyValidatorItem;
protected createItemFromEditorItem(editorItem: any): Survey.SurveyValidator;
}
export declare class SurveyPropertyValidatorItem {
validator: Survey.Surve