Constructor
new UiEditorPresenter(startOnCode, tabRoot, contentsRoot, getCodeAsObj, onCodeObjUpdate, onTabChange)
Creates a new UiEditorPresenter.
Parameters:
| Name | Type | Description |
|---|---|---|
startOnCode |
boolean | Whether to start in code view. |
tabRoot |
HTMLElement | Root element for editor tabs. |
contentsRoot |
HTMLElement | Root element for editor contents. |
getCodeAsObj |
function | Callback to get current code object. |
onCodeObjUpdate |
function | Callback when code object updates. |
onTabChange |
function | Callback when active tab changes. |
- Source:
Methods
enableAllSections()
Show all sections in the UI editor as enabled.
- Source:
forceCodeObj(codeObj)
Forces update with new code object.
Parameters:
| Name | Type | Description |
|---|---|---|
codeObj |
Object | The code object to force update with. |
- Source:
refresh(codeObj)
Refreshes the UI with new code object data.
Parameters:
| Name | Type | Description |
|---|---|---|
codeObj |
Object | The new code object to display. |
- Source:
showCode()
Shows the code editor interface.
- Source: