Interface IWidgetDataDrivenEditor
Describes the API and properties of the Data-Driven Editor widget.
Package: ui-framework
Properties
idStr
Identification string.
Declaration
idStr: string
Property Value
| Type | Description |
|---|---|
| string | Identification string. |
isValid
Whether the form is filled out correctly.
Declaration
isValid: boolean
Property Value
| Type | Description |
|---|---|
| boolean | Whether the form is filled out correctly. |
pdfUrl
URL to download the rendered PDF.
Declaration
pdfUrl: string
Property Value
| Type | Description |
|---|---|
| string | URL to download the rendered PDF. |
previewUrlLink
URL of the first page preview image.
Declaration
previewUrlLink: string
Property Value
| Type | Description |
|---|---|
| string | URL of the first page preview image. |
previewUrls
URLs of preview images.
Declaration
previewUrls: string[]
Property Value
| Type | Description |
|---|---|
| string[] | URLs of preview images. |
stateId
The private design state ID.
Declaration
stateId: string
Property Value
| Type | Description |
|---|---|
| string | The private design state ID. |
userId
The current user ID.
Declaration
userId: string
Property Value
| Type | Description |
|---|---|
| string | The current user ID. |
Methods
createIdStr()
Creates an identification string.
Declaration
function createIdStr()
Returns
| Type | Description |
|---|---|
| Promise<string> |
createPdfPreview(IRendererConfig)
Creates a PDF preview and returns a download URL.
Declaration
function createPdfPreview(config: IRendererConfig)
Parameters
| Type | Name | Description |
|---|---|---|
| IRendererConfig | config |
Returns
| Type | Description |
|---|---|
| Promise<string> |
createPreview(IRendererConfig)
Creates preview images and returns their URLs.
Declaration
function createPreview(config: IRendererConfig)
Parameters
| Type | Name | Description |
|---|---|---|
| IRendererConfig | config |
Returns
| Type | Description |
|---|---|
| Promise<string[]> |
getFormData(IFormDataConfig)
Retrieves the filled-in form data.
Declaration
function getFormData(config: IFormDataConfig)
Parameters
| Type | Name | Description |
|---|---|---|
| IFormDataConfig | config |
Returns
| Type | Description |
|---|---|
| Record<string, string> |
saveProduct(boolean)
Saves the edited design. If asNew is true, creates a new private design.
Declaration
function saveProduct(asNew?: boolean)
Parameters
| Type | Name | Description |
|---|---|---|
| boolean | asNew |
Returns
| Type | Description |
|---|---|
| Promise<void> |
setEditorConfig(IEditorConfig)
Sets the editor configuration.
Declaration
function setEditorConfig(config: IEditorConfig)
Parameters
| Type | Name | Description |
|---|---|---|
| IEditorConfig | config |
setUserInfo(Record<string, string>)
Sets user information and updates the form and design.
Declaration
function setUserInfo(userInfo: Record<string, string>)
Parameters
| Type | Name | Description |
|---|---|---|
| Record<string, string> | userInfo |
validate()
Validates the form.
Declaration
function validate()
Returns
| Type | Description |
|---|---|
| boolean |