@microsoft/windows-admin-center-sdk
Version:
Microsoft - Windows Admin Center Shell
194 lines (193 loc) • 6.08 kB
TypeScript
import { ElementRef, EventEmitter } from '@angular/core';
import { Subject } from 'rxjs';
import { BaseDialogComponent, DialogOptions, DialogResult } from '../../controls/dialog/base-dialog.component';
import { DialogService } from '../../controls/dialog/dialog.service';
import { DataSchema, FormData } from '../schema/schema-models';
import * as i0 from "@angular/core";
/**
* The confirmation dialog result.
*/
export interface EditorResult extends DialogResult {
/**
* Was the dialog submit button clicked?
*/
confirmed: boolean;
}
export declare class SchemaFormEditorComponent extends BaseDialogComponent<DialogOptions, EditorResult> {
private elementRef;
strings: {
Title: string;
SwitchToCodeViewMessage: string;
PreviewForm: {
Title: string;
EmptySchemaMessage: string;
ValidationResult: {
Passed: string;
Failed: string;
Title: string;
};
};
Welcome: {
Title: string;
Row1: string;
Row2: string;
Row3: string;
Row4: string;
Row5: string;
Row6: string;
Row7: string;
Row8: string;
Row9: string;
Row10: string;
Row11: string;
};
SchemaView: {
Title: string;
Visual: string;
Code: string;
};
ApplySchemaButton: {
Text: string;
};
GoToCodeViewButton: {
Text: string;
};
CloseButton: {
Text: string;
};
SchemaTree: {
Welcome: {
Row1: string;
Row2: string;
Row3: string;
Row4: string;
Row5: string;
};
};
PropertyForm: {
Header: string;
Footer: string;
DataType: string;
Advance: string;
Required: string;
DefaultValue: string;
Description: string;
HideCondition: string;
ConditionForDisabled: string;
CustomValidation: string;
ReadonlyCondition: string;
MoreOptions: string;
EmptyByDefault: string;
NoOptionSchema: string;
Welcome: {
Row1: string;
Row2: string;
Row3: string;
Row4: string;
Row5: string;
Row6: string;
Row7: string;
};
Type: {
Description: string;
};
Format: {
Description: string;
};
Name: {
Description: string;
};
Label: {
Description: string;
};
MultipleLine: {
Title: string;
};
ObjectType: {
ColumnCount: string;
Collapsible: string;
HideHeader: string;
Yes: string;
State: string;
Collapsed: string;
Expanded: string;
};
Options: {
StaticOptions: string;
DynamicOptions: string;
Label: string;
Value: string;
};
CodeEditor: {
Language: {
label: string;
description: string;
};
Options: {
label: string;
description: string;
};
};
};
SchemaText: {
Message1: string;
Message2: string;
LintMessage: string;
CopyToClipboardButton: {
Text: string;
};
};
ViewModel: {
Message: string;
GenerateButton: {
Text: string;
};
};
ResourceStringPicker: {
ActualTextPrefix: string;
InvalidResourceKey: string;
NoResourceKeyMessage: string;
CannotFindResourceKey: string;
WrongFormatActualText: string;
};
};
private isInitialized;
private internalSchemaView;
private internalData;
private applySchemaButtonHasBeenClicked;
private previewFormComponent;
private schemaTreeComponent;
private schemaTextComponent;
showLoading: boolean;
editingSchema: DataSchema;
previewFormWidth: number;
isOpen: boolean;
get schemaView(): string;
set schemaView(value: string);
schema: DataSchema;
schemaChange: EventEmitter<DataSchema>;
get data(): FormData;
set data(value: FormData);
dataChange: EventEmitter<FormData>;
formController: any;
constructor(dialogService: DialogService, elementRef: ElementRef);
/**
* Shows the dialog.
*
* @param options The options for the dialog.
* @return The dialog result subject.
*/
show(options: DialogOptions): Subject<EditorResult>;
/**
* The method to call when the close button is clicked.
*/
onClose(): void;
applySchema(): void;
shouldEnableApplySchemaButton(): boolean;
getPreviewFormValidationResult(): string;
goToCodeView(): void;
shouldShowWelcomeText(): boolean;
shouldShowEmptySchemaText(): boolean;
static ɵfac: i0.ɵɵFactoryDeclaration<SchemaFormEditorComponent, never>;
static ɵcmp: i0.ɵɵComponentDeclaration<SchemaFormEditorComponent, "sme-schema-form-editor", never, { "schema": "schema"; "data": "data"; "formController": "formController"; }, { "schemaChange": "schemaChange"; "dataChange": "dataChange"; }, never, never, false, never>;
}