JSON Schema#
The settings schema drives the JupyterLab Advanced Settings user interface, and is the source-of-truth for a number of parts of IPyDrawio.
Diagram Documents#
Configure Diagram Settings
type |
object |
||
properties |
|||
|
disable returning focus to the main frame when the escape key is pressed |
||
default |
False |
||
|
Configuration options sent to each drawio editor. https://www.diagrams.net/doc/faq/configure-diagram-editor |
||
default |
compressXml |
False |
|
override |
True |
||
showStartScreen |
False |
||
|
URL parameters for the export URL. |
||
|
URL parameters for the drawio iframe https://web.archive.org/web/20210425055302/https://www.diagrams.net/doc/faq/supported-url-parameters |
||
default |
db |
0 |
|
drafts |
0 |
||
gapi |
0 |
||
gh |
0 |
||
gl |
0 |
||
od |
0 |
||
p |
ex;tips;svgdata;sql;anim;trees;replay;anon;flow;webcola;tags |
||
picker |
0 |
||
stealth |
1 |
||
svg-warning |
0 |
||
thumb |
0 |
||
tr |
0 |
||
ui |
min |
||
color#
type |
string |
color-scheme#
properties |
||
|
||
|
type |
string |
|
||
|
color-set#
type |
array |
items |
|
uniqueItems |
True |
Drawio Configuration#
type |
object |
|
properties |
||
|
Defines the delay (in ms) between the last change and the autosave of the file |
|
type |
number |
|
|
Specifies if the XML output should be compressed. |
|
type |
boolean |
|
|
Defines a string with CSS rules to be used to configure the diagrams.net user interface. |
|
type |
string |
|
|
TBD: see https://www.diagrams.net/doc/faq/configure-diagram-editor |
|
|
An array of font family names to be added before defaultFonts |
|
|
Colour codes to be added before presetColors (no leading # for the colour codes) |
|
|
Set the server endpoint region. The default is to use your closest region, (either EU or US). If lockdown is set to true, dataGovernance is ignored. |
|
type |
string |
|
|
TBD: see https://www.diagrams.net/doc/faq/configure-diagram-editor |
|
|
Colour codes for the lower palette in the colour dialog (no leading # for the colour codes). |
|
|
Defines an array of IDs to load custom libraries. |
|
|
Defines the default length for new connectors |
|
type |
number |
|
|
TBD: see https://www.diagrams.net/doc/faq/configure-diagram-editor |
|
|
An array of font family names in the format panel font drop-down list. All fonts must be installed on the server and all clients or be added using the fontCss option. |
|
|
Defines a semicolon-separated list of library keys (unique names) in a string to be initially displayed in the left panel (e.g. general;uml;company-graphics). Possible keys include custom entry IDs from the libraries field, or keys for the libs URL parameter |
|
default |
general;uml;er;bpmn;flowchart;basic;arrows2 |
|
|
TBD: see https://www.diagrams.net/doc/faq/configure-diagram-editor |
|
|
Defines the XML for blank diagrams |
|
type |
string |
|
|
Defines the XML for blank diagrams and libraries |
|
type |
string |
|
|
Specifies if the open and new library functions are enabled (true or false, the default true). |
|
type |
boolean |
|
|
Defines an array of strings of library keys which will be available in the More Shapes dialog. If you define this as null, all libraries will be visible. If you leave the array empty, no libraries will be visible |
|
|
Defines a string with CSS rules for web fonts to be used in diagrams. This should be one or more @font-face rule, |
|
type |
string |
|
|
JSON structure with key, value pairs to define global variables for system-wide placeholders. You should keep the number of entries small. |
|
type |
object |
|
|
Defines the number of minor grid steps (14.3.2 and later). |
|
type |
number |
|
|
Defines an array of objects that list additional libraries and sections in the left panel and the More Shapes dialog |
|
|
Disable data transmission, apart from directly between your browser and your selected data storage location. Default is false. |
|
type |
boolean |
|
default |
False |
|
|
Defines the maximum size for images in bytes. Default is 1000000. |
|
type |
number |
|
default |
1000000 |
|
|
Defines the maximum width or height of the image, where the lowest value is used. |
|
type |
number |
|
default |
520 |
|
|
Ignores the current settings on the client-side if this is set to true |
|
type |
boolean |
|
|
Defines an array of plugin URLs that should be loaded with the diagram editor. Plugins are JavaScript files that can modify the editor UI and behaviour. |
|
|
Colour codes for the upper palette in the colour dialog (no leading # for the colour codes). |
|
|
Disables word wrap and complex formatting for labels by default to avoid foreignObjects in the SVG output (14.5.9 and later). |
|
type |
boolean |
|
default |
True |
|
|
type |
array |
items |
||
|
Defines the URL of the source file for the Templates dialog (multiple <template> tags are allowed). |
|
type |
string |
|
format |
uri |
|
|
Defines the height for the entries in the left panel |
|
type |
number |
|
|
Defines the width for the entries in the left panel |
|
type |
number |
|
|
The current version of the configuration (any string, e.g. 1.0). If this is different from the last used version, then the current settings on the client-side (.drawio-config) will be reset. The default is null. Change this to force the stored settings in the client to be reset and apply the current configuration |
|
type |
string |
|
|
Defines the zoom factor for mouse wheel and trackpad zoom. Default is 1.2. (14.7.0 and later). |
|
type |
number |
|
default |
1.2 |
Drawio Export URL#
export URL params https://github.com/jgraph/draw-image-export2/blob/dev/README.md
properties |
|||
|
type |
object |
|
properties |
|||
|
Whether all pages should be rendered 0 0 1 |
||
type |
string |
||
|
Whether the response data should be base64 (and png embedded data) encoded 0 or 1 |
||
type |
string |
||
|
The background colour for the image #ff8888 |
||
type |
string |
||
|
The size of the border for the page 0 10 |
||
type |
number |
||
|
The data to embed into the png - |
||
type |
string |
||
|
The key to use when embedding the data into the png myKey |
||
type |
string |
||
|
Embed data in the png with the dataHeader key null 0 or 1 |
||
type |
string |
||
|
Embed the diagram data in the png 0 or 1 |
||
type |
string |
||
|
Additional detail how what should be rendered, e.g. layer-names |
||
|
The filename to included in the content-disposition header myFile.png |
||
type |
string |
||
|
The renderering format for the diagram png pdf |
||
type |
string |
||
|
The index of the page to start rendering from 1 |
||
type |
number |
||
|
Set the view port width 0 10 |
||
type |
number |
||
|
The id of the page to render page id |
||
type |
string |
||
|
The scale for the rendered diagram 1 1.5 |
||
type |
number |
||
|
The index of the page to finish rendering at 2 |
||
type |
number |
||
|
Set the view port height 0 10 |
||
type |
number |
||
|
URL for (local) drawio-export server https://github.com/jgraph/draw-image-export2 |
||
type |
string |
||
default |
./drawio/export/ |
Drawio URL Params#
type |
object |
|
properties |
||
|
url: Sets the base URL to use for links (use this if document.referrer is not available in embed mode). |
|
type |
string |
|
format |
uri |
|
|
60: Sets the border width used in lightbox mode (the default is 60). |
|
type |
number |
|
|
0/1: Disables local storage as a storage location (0) or shows the browser option in the storage dialog (1). |
|
|
0: Uses the chromeless read-only viewer. |
|
|
key1;key2;key;…;keyN: Specifies custom libraries (keys are file IDs or _URLs with a U-prefix_) |
|
|
1: Runs diagrams.net in client mode. This displays a normal UI and sends a ready message to the opener or parent when the page is loaded. After receiving a message containing XML or compressed XML, a local file is created. The file is then set to modified so the connection to the window can be closed after sending the initial XML. Whether the XML is loaded again after a page refresh, depends on the caller implementation. Use proto=json to use a custom protocol for special cases. |
|
|
1: Shows the Close button in chromeless mode which closes the window when selected. |
|
|
1: Sends the configure event and waits for the configure action. See more about the _embed mode_. NEW `14.6.10` |
|
|
regex: Checks whether URLS have CORS enabled using a URL encoded regular expression, e.g.cors=%5Ehttps%3F%3A%5C%2F%5C%2F.*%5C.github%5C.io%5C%2F TBD `14.6.10` |
|
type |
string |
|
format |
regex |
|
|
url/name: Creates a new file from a template URL. If the value is not a URL and is not empty, the script will try to use window.opener_url]. In [embed mode_, window.opener[name] will be used to get the initial XML. Note that this requires the same origin policy in the opener/parent for reading the variable. |
|
type |
string |
|
|
[0|1]: Disables/enables dark mode in Sketch and Minimal editor themes. |
|
|
data: Gets the XML data for the diagram (used in client mode to bypass message passing and cross frame access). TBD `14.6.10` |
|
type |
string |
|
|
0: Disables the Dropbox integration. |
|
|
1: Shortcut for db=0&gapi=0&math=0&picker=0, disables the splash screen and creates an empty, local diagram file. |
|
|
{compressed-json}: Passes the CSV import descriptor (_example](https://web.archive.org/web/20210425055302/https://www.draw.io/?desc=SnVTtjpswEHwafl50gUP5nZC7F7i+gIMdvI3xIrMkSp++u7bh0tKoVSUE9sx6PPuRFLtDUZZTcPwuqj2/LdEwxuUHP9+7oAa76YDsdNoAMqSDugG+aFDM9aMgX0sMXWtVoE07XkWybPh9xtArWm54pLQitRBFWTl1Mi7uXouy9qo3/Cmq5hSK6p2/wMRId2eK6ljUotCiQyb37OBeVIcESnBZDzgCAfokwe4gicxifPOrDea8aPUKHGG8vjaykZOz4HsEoo6S83XDwlU2I4az9wP0qov+yjot5frDzQKZz0G1Qt24qoxZ6vnAccvLgJPXRufdGZxrUmIiI9ukMlLAi3mgEpDIbAm08QR0T65eMiq1HNP1AnMToB8w0My36L1pKdd+lwt5DtjPFYhErpPnvEImpJGZ4OKtgmMTV5HgrybQYzSFyTxGpHI+uXv8XTE+kkecnCdPPJM6ttJtp3Bd6m+83oeAN96eHLaXbxZ8gj+kFblJ6OkTfkg/t9uv0dsd/6OiPIWrlP5cTtDruH9J6W9unTnTclgAwuGX/Q002YSoKToT1BroLK3gQWkNvssjuC3n0ew8hjyBnEjZ5B9Ikya8ydOcHYG/pFD5f8pTjDpO8aL9NtszunvCOHXH6dFiTPsn)). Works with the [www.draw.io_ domain only. NEW `14.6.10` |
|
|
0: Disables draft states (does not save unsaved files in IndexedDB). |
|
|
0: Simulates _app.diagrams.net_ regardless of the domain name (uses the old app ID). |
|
|
move: Disables the handling of connector segments without having previously selected the connector. |
|
type |
string |
|
|
edit=url: Adds a link for the Edit button in chromeless mode (use edit=_blank to edit the diagram as a new copy). |
|
|
embed=1: Runs diagrams.net in _embed mode](/web/20210425055302/https://www.diagrams.net/doc/faq/embed-mode.html). Use this mode with [embed.diagrams.net_ only. NEW `14.6.10` |
|
|
0: Disables the format panel on the right. |
|
|
0: Disables the Google integration. |
|
|
0: Disables the Github integration. |
|
|
url: Sets the URL-encoded path to a custom GitLab installation to use for GitLab file operations. |
|
type |
string |
|
format |
uri |
|
|
ID: Specifies the _client ID of the custom GitLab application_ when using a custom GitLab instance. |
|
type |
string |
|
|
0: Disables the GitLab integration. |
|
|
1: Uses the chromeles mode with the grid enabled. |
|
|
1: Hides the controls that allow you to change the current page in lightbox mode. NEW `14.6.10` |
|
|
hex: Specifies the highlight colour (with no leading #) for links in chromeless mode. |
|
|
1: If modified specifies a resource key, this is used to keep the modified state after Save is selected. TBD `14.6.10` |
|
|
xy: Specifies the language of the user interface. Possible values for xy include i18n ar, bs, ca, cs, da, de, el, en, es, et, fi, fil, fr, he, hu, id, it, ja, ko, ms, nl, no, pl, pt, pt-br, ro, ru, sr, sv, th, tr, uk, vi, zh, zh-tw |
|
type |
string |
|
examples |
ar |
|
bs |
||
ca |
||
cs |
||
da |
||
de |
||
el |
||
en |
||
es |
||
et |
||
fi |
||
fil |
||
fr |
||
he |
||
hu |
||
id |
||
it |
||
ja |
||
ko |
||
ms |
||
nl |
||
no |
||
pl |
||
pt |
||
pt-br |
||
ro |
||
ru |
||
sr |
||
sv |
||
th |
||
tr |
||
uk |
||
vi |
||
zh |
||
zh-tw |
||
|
1: Adds layer control in chromeless mode |
|
|
1: Specifies whether libraries should be enabled in embed mode. The default is disabled (0). TBD `14.6.10` |
|
|
key1;key2;…;keyN: Specifies the current libraries. Possible keys are allied_telesis, android, archimate, archimate3, arrows2, atlassian, aws3, aws3d, aws4, azure, basic, bootstrap, bpmn, cabinets, cisco, cisco_safe, citrix, clipart, dfd, eip, electrical, er, floorplan, flowchart, gcp2, general, gmdl, ibm, images, infographic, ios, lean_mapping, mockups, mscae, network, office, pid, rack, signs, sitemap, sysml, uml, veeam and webicons. |
|
|
1: Uses the lightbox in chromeless mode (larger zoom, no page visible, chromeless). |
|
|
1: Uses device mode only. |
|
|
0: Disables MathJax support. |
|
|
: Sets the font to use for math typesetting. Possible values are STIX-Web and TeX (default). TBD `14.6.10` |
|
type |
string |
|
|
html: Sets the math typesetting output to HTML-CSS. NEW `14.6.10` |
|
examples |
html |
|
|
[google|onedrive|github|dropobox|device|browser]: Switches to the specified mode. |
|
|
1: Enables folding in chromeless mode. |
|
|
1: Displays no Exit button. Instead of using this URL parameter, you can specify this setting in the load message. TBD `14.6.10` |
|
|
1: Displays a Save and Exit button instead of a Save button. Instead of using this URL parameter, you can specify this setting in the load message. If this is used, then saveAndExit is ignored. TBD `14.6.10` |
|
|
1: Uses the default filename for new files (used with the url parameter) |
|
|
1: Suppresses the warning before an unload for local files. |
|
|
0: Disables the OneDrive integration. |
|
|
[1|0]: Registers or unregisters the progressive web app (all remote storage locations are disabled). |
|
|
prefix+ID: If _location hash properties_ are not available, use this as a replacement. The browser will add the hash property to the URL immediately and not remove the URL parameter. Existing hash property takes precedence. |
|
type |
string |
|
|
1: Saves all Google Drive files as application/vnd.jgraph.mxfile. |
|
|
id1;id2;…;idN: Selects which plugins to load. _See the list of available plugins_. |
|
|
index: Starts with the given page (the default is the first page, where the index for the first page is 0) |
|
type |
number |
|
|
ID: Starts with the given page ID (has precedence over the page URL parameter). To find the ID of the current page, right click on the canvas and select Edit Data. The ID is the first entry in this dialog. |
|
type |
string |
|
|
0/1: Disables/enables the Google file picker in dialogs. |
|
|
0: Does not load _plugins_. |
|
|
client=1: Runs diagrams.net in client mode. This displays a normal UI and sends a ready message to the opener or parent when the page is loaded. After receiving a message containing XML or compressed XML, a local file is created. The file is then set to modified so the connection to the window can be closed after sending the initial XML. Whether the XML is loaded again after a page refresh, depends on the caller implementation. Use proto=json to use a custom protocol for special cases. NEW `14.6.10` |
|
|
0: Sets the default pageVisible to false. |
|
|
0: Disables the ability to (un)register the progressive web app (when installed it will stay installed). NEW `14.6.10` |
|
|
1: Returns a JSON structure with the diagram bounds in embed and client mode. This message is dispatched immediately after receiving the diagram XML. TBD `14.6.10` |
|
|
id: Selects a specific revision of a Google Drive or Dropbox file. |
|
type |
string |
|
|
[0|1]: Disables/enables the rough sketch style (default is 1 for sketch theme and 0 for all other themes). |
|
|
1: Uses chromeless mode with Google Drive realtime enabled. |
|
|
1: Starts with the ruler enabled. |
|
|
local/remote: Enables/disables saving files locally (default is local). If this is disabled, then files are echoed via a servlet for a local save. |
|
|
1: Displays a Save and Exit button ne. Instead of using this URL parameter, you can specify this setting in the load message. TBD `14.6.10` |
|
|
0: Starts with scrollbars disabled. |
|
|
value: Starts with given value in the search shapes box. ## Modes NEW `14.6.10` |
|
type |
string |
|
|
1: Shows a Loading… spinner while waiting for the diagram data to load in embed mode. TBD `14.6.10` |
|
|
0: Does not show the splash screen. |
|
|
1: Disables all features that require external web services (such as _PDF export_). |
|
|
device: Adds a device storage option for touch devices. |
|
|
0: Suppresses the warning for old viewers in SVG export. NEW `14.6.10` |
|
|
[none|manual|auto]: Enables/disables collaborative editing (default is auto). |
|
|
[auto|self|frame|blank]: Opens links in the same window or frame or in a blank window in chromeless mode (auto is the default which opens relative links and anchors in the same window in chromeless mode, and all links in a new window in editing mode). |
|
|
name: If the #U hash property is used but the URL does not contain a filename to determine binary mode. See the list of _supported location hash properties_. |
|
type |
string |
|
|
0: Disables the creation of thumbnails in Drive. |
|
|
title: Sets a new file title (used with the create and url parameters). |
|
type |
string |
|
|
0: Disables the toolbar in chromeless mode. |
|
|
0: Disables the Trello integration. |
|
|
[min|atlas|dark|sketch]: Uses the Minimal, Atlas, Dark or Sketch UI theme (default is Kennedy). |
|
examples |
min |
|
atlas |
||
dark |
||
sketch |
||
|
url: Deprecated - Use U hash property #U{uri_encoded_url} to open a diagram from a URI-encoded URL, eg. https://app.diagrams.net/#Uhttps%3A%2F%2Fraw.githubusercontent.com%2Fjgraph%2Fdrawio-diagrams%2Fmaster%2Fdiagrams%2Fschema.xml NEW `14.6.10` |
|
|
vars=json: Uses a URI-encoded JSON string for global _placeholders for use in labels and tooltips_ where enabled, e.g. vars={“key”:”value”}. |
|
type |
string |
|
|
{“x”: int, “y”: int, “width”: int, “height”: int}: Sets the initial viewport when you specify file IDs. NEW `14.6.10` |
|
|
nocss: Disables the CSS zoom preview. |
|
type |
string |
font-set#
type |
array |
|||
items |
oneOf |
type |
string |
|
type |
object |
|||
properties |
||||
|
type |
string |
||
|
type |
string |
||
format |
uri |
Drawio Library#
type |
object |
||
properties |
|||
|
type |
object |
|
properties |
|||
|
type |
string |
|
|
type |
number |
|
|
type |
number |
|
|
NB: appears to be base64-encoded |
||
type |
string |
||
|
type |
string |
|
|
|||
|
type |
string |
|
format |
uri |
library-def-list#
type |
array |
items |
library-entry#
type |
object |
|
properties |
||
|
||
|
type |
string |
|
type |
array |
items |
||
|
type |
string |
|
library-id-list#
type |
array |
|
items |
type |
string |
library-key-list#
type |
array |
|
items |
type |
string |
library-keys-string#
type |
string |
library-resource#
type |
object |
|
properties |
||
|
type |
string |
library-section#
type |
object |
|
properties |
||
|
type |
array |
items |
||
|
off-switch#
type |
number |
maximum |
0 |
minimum |
0 |
on-off-switch#
type |
number |
maximum |
1 |
minimum |
0 |
on-switch#
type |
number |
maximum |
1 |
minimum |
1 |
plugin-url-list#
type |
array |
|
items |
type |
string |
format |
uri |
style#
properties |
||
|
type |
object |
|
type |
object |
|
type |
object |
UI Theme#
type |
string |
enum |
min, atlas, dark, kennedy, sketch |
url-param-mode#
type |
string |
enum |
google, onedrive, github, dropobox, device, browser |
url-param-save#
type |
string |
enum |
local, remote |
url-param-storage#
type |
string |
enum |
device |
url-param-sync#
type |
string |
enum |
none, manual, auto |
url-param-target#
type |
string |
enum |
auto, self, frame, blank |
url-param-url-or-blank#
anyOf |
type |
string |
format |
uri |
|
type |
string |
|
enum |
_blank |