designing independant section titling pattern for grey box and white box

This commit is contained in:
Antoine M 2023-10-19 17:23:27 +02:00
parent 63ffbc5fe6
commit 0695af78d3
7 changed files with 7 additions and 30 deletions

View File

@ -1 +1 @@
<?php return array('dependencies' => array('wp-block-editor', 'wp-blocks', 'wp-components', 'wp-element', 'wp-i18n', 'wp-primitives'), 'version' => 'eda629d6cb8729df82b6'); <?php return array('dependencies' => array('wp-block-editor', 'wp-blocks', 'wp-components', 'wp-element', 'wp-i18n', 'wp-primitives'), 'version' => 'e990beec383c9a2090f2');

View File

@ -1,12 +0,0 @@
/*!****************************************************************************************************************************************************************************************************************************************!*\
!*** css ./node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[4].use[1]!./node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/editor.scss ***!
\****************************************************************************************************************************************************************************************************************************************/
.homegrade-blocks-staff-list .homegrade-blocks-staff-list__staff-list {
display: unset;
}
.homegrade-blocks-staff-list .block-editor-block-list__layout {
display: grid;
grid-template-columns: repeat(3, 1fr);
}
/*# sourceMappingURL=index.css.map*/

View File

@ -1 +0,0 @@
{"version":3,"file":"index.css","mappings":";;;AACC;EACC;AAAF;AAEC;EACC;EACA;AAAF,C","sources":["webpack://multiblocks/./src/editor.scss"],"sourcesContent":[".homegrade-blocks-staff-list {\r\n\t.homegrade-blocks-staff-list__staff-list {\r\n\t\tdisplay: unset;\r\n\t}\r\n\t.block-editor-block-list__layout {\r\n\t\tdisplay: grid;\r\n\t\tgrid-template-columns: repeat(3, 1fr);\r\n\t}\r\n}\r\n"],"names":[],"sourceRoot":""}

View File

@ -120,7 +120,7 @@ function save({
sectionTitle, sectionTitle,
sectionSubtitle sectionSubtitle
} = attributes; } = attributes;
return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("section", { return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", {
..._wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.useBlockProps.save({ ..._wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.useBlockProps.save({
className: `section_titling` className: `section_titling`
}) })
@ -132,9 +132,7 @@ function save({
value: sectionSubtitle, value: sectionSubtitle,
tagName: "p", tagName: "p",
className: "section_titling__subtitle" className: "section_titling__subtitle"
}), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { }));
className: "starter-nested-parent__children-container"
}, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.InnerBlocks.Content, null)));
} }
/***/ }), /***/ }),

File diff suppressed because one or more lines are too long

View File

@ -1,4 +0,0 @@
/*!***************************************************************************************************************************************************************************************************************************************!*\
!*** css ./node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[4].use[1]!./node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/style.scss ***!
\***************************************************************************************************************************************************************************************************************************************/

View File

@ -1,10 +1,10 @@
import { useBlockProps, RichText, InnerBlocks } from "@wordpress/block-editor"; import { useBlockProps, RichText } from "@wordpress/block-editor";
export default function save({ attributes }) { export default function save({ attributes }) {
let { sectionTitle, sectionSubtitle } = attributes; let { sectionTitle, sectionSubtitle } = attributes;
return ( return (
<section <div
{...useBlockProps.save({ {...useBlockProps.save({
className: `section_titling`, className: `section_titling`,
})} })}
@ -19,10 +19,6 @@ export default function save({ attributes }) {
tagName="p" tagName="p"
className="section_titling__subtitle" className="section_titling__subtitle"
/> />
<div className="starter-nested-parent__children-container">
<InnerBlocks.Content />
</div> </div>
</section>
); );
} }