From f3cf6d5a20600d130a8ed6c7a304d6b72ee9099a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9s?= Date: Thu, 7 Mar 2019 11:12:00 +0100 Subject: [PATCH] block-editor: set up auto-generated API docs (#14285) --- bin/update-readmes.js | 2 +- packages/block-editor/README.md | 36 +++++++++++++++++++++++++++++++++ 2 files changed, 37 insertions(+), 1 deletion(-) diff --git a/bin/update-readmes.js b/bin/update-readmes.js index f40eee3d8129e3..6f1efc62ff5a8d 100755 --- a/bin/update-readmes.js +++ b/bin/update-readmes.js @@ -7,7 +7,7 @@ const packages = [ 'a11y', 'autop', 'blob', - //'block-editor', + 'block-editor', 'block-library', //'block-serialization-default-parser', //'blocks', diff --git a/packages/block-editor/README.md b/packages/block-editor/README.md index 9e07cf10eb2ce8..96f6edbf511c75 100644 --- a/packages/block-editor/README.md +++ b/packages/block-editor/README.md @@ -11,3 +11,39 @@ npm install @wordpress/block-editor --save ``` _This package assumes that your code will run in an **ES2015+** environment. If you're using an environment that has limited or no support for ES2015+ such as lower versions of IE then using [core-js](https://github.com/zloirock/core-js) or [@babel/polyfill](https://babeljs.io/docs/en/next/babel-polyfill) will add support for these methods. Learn more about it in [Babel docs](https://babeljs.io/docs/en/next/caveats)._ + +## API + + + +### BlockEditorProvider + +[src/index.js#L11-L11](src/index.js#L11-L11) + +Undocumented declaration. + +### SETTINGS_DEFAULTS + +[src/index.js#L13-L13](src/index.js#L13-L13) + +The default editor settings + + alignWide boolean Enable/Disable Wide/Full Alignments + colors Array Palette colors + disableCustomColors boolean Whether or not the custom colors are disabled + fontSizes Array Available font sizes + disableCustomFontSizes boolean Whether or not the custom font sizes are disabled + imageSizes Array Available image sizes + maxWidth number Max width to constraint resizing + allowedBlockTypes boolean|Array Allowed block types + hasFixedToolbar boolean Whether or not the editor toolbar is fixed + focusMode boolean Whether the focus mode is enabled or not + styles Array Editor Styles + isRTL boolean Whether the editor is in RTL mode + bodyPlaceholder string Empty post placeholder + titlePlaceholder string Empty title placeholder + + + + +

Code is Poetry.