Hi everyone @MB.IO,
As an improvement, would you consider creating a Control::Wysiwyg for custom_hml (and others if needed) ?
is there any way we could add our own Control ?
I'm currently working on a solution, but i think we are stuck with that list of Control, with no way to filter/add some :
'Checkbox' => false,
'KeyValue' => [],
'ReactSelect' => [],
'IncludeExclude' => [],
'ShowHide' => [],
'ConditionalLogic' => [],
'CustomTable' => [],
Found in wp-content/plugins/meta-box-aio/vendor/meta-box/meta-box-builder/src/Control.php
i also check in app.js for the builder, i guess something should be added like so :
/****/ "./app/controls/Wysiwyg.js":
/*!*********************************!*\
!*** ./app/controls/Wysiwyg.js ***!
\*********************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
"use strict";
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (__WEBPACK_DEFAULT_EXPORT__)\n/* harmony export */ });\n/* harmony import */ var _DivRow__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./DivRow */ \"./app/controls/DivRow.js\");\n/* harmony import */ var _hooks_useApi__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../hooks/useApi */ \"./app/hooks/useApi.js\");\n\n\n\nconst Wysiwyg = ({\n componentId,\n name,\n defaultValue,\n ...rest\n}) => {\n const {\n getEditorSettings\n } = (0,_hooks_useApi__WEBPACK_IMPORTED_MODULE_1__[\"default\"])();\n const editorSettings = getEditorSettings();\n return /*#__PURE__*/React.createElement(_DivRow__WEBPACK_IMPORTED_MODULE_0__[\"default\"], rest, /*#__PURE__*/React.createElement(\"div\", {\n id: componentId\n }, /*#__PURE__*/React.createElement(wp.editor.Editor, {\n name: name,\n value: defaultValue,\n settings: editorSettings\n })));\n};\n\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (Wysiwyg);\n\n//# sourceURL=webpack:///./app/controls/Wysiwyg.js?");
/***/ }),
can you check on this ?
It will add flexibility for clients to compose their own html without specific code Knowledge.
have a nice day