@wordpress/block-library
Version:
Block library for the WordPress editor.
32 lines (31 loc) • 977 B
JavaScript
import { __ } from "@wordpress/i18n";
import { InspectorControls, privateApis } from "@wordpress/block-editor";
import { unlock } from "../../lock-unlock.mjs";
import { jsx } from "react/jsx-runtime";
// packages/block-library/src/comments/edit/comments-inspector-controls.jsx
const { HTMLElementControl } = unlock(privateApis);
function CommentsInspectorControls({ attributes: { tagName }, setAttributes }) {
return /* @__PURE__ */ jsx(InspectorControls, { children: /* @__PURE__ */ jsx(InspectorControls, {
group: "advanced",
children: /* @__PURE__ */ jsx(HTMLElementControl, {
tagName,
onChange: (value) => setAttributes({ tagName: value }),
options: [
{
label: __("Default (<div>)"),
value: "div"
},
{
label: "<section>",
value: "section"
},
{
label: "<aside>",
value: "aside"
}
]
})
}) });
}
export { CommentsInspectorControls as default };
//# sourceMappingURL=comments-inspector-controls.mjs.map