Main/WordPress Fullstack/Blueprints/Gutenberg & FSE/Compound InnerBlocks Container with Layout Locking (templateLock='contentOnly')
Back to «Gutenberg & FSE» cardsGutenberg & FSE(ТЗ 30 из 54)
Spec: Compound InnerBlocks Container with Layout Locking (templateLock='contentOnly')Трудозатраты~9 рабочих часов
Фриланс вилка~$405 – $675 (€360 – €630)
Оценка веб-студии~$855 – $1,440 (€810 – €1350)
ТЗ заказчика (исходный бриф):
Our agency builds client websites where marketing editors constantly break page layouts by accidentally deleting column wrappers, altering padding, or inserting unsupported blocks. We need container blocks with strict template locking.
Ключевые требования:
- •Custom compound block utilizing <InnerBlocks /> with predefined block template
- •Strict allowedBlocks whitelist preventing arbitrary block insertion
- •Implementation of templateLock='contentOnly' to allow text/image edits while locking DOM structure
- •Responsive container layout with CSS Grid/Flexbox and theme.json spacing integration
- •Seamless migration and backward compatibility for existing nested layouts
Ограничения проекта:
- •Content editors must be unable to delete outer wrapper containers
- •Editor toolbar must simplify automatically to hide destructive actions
Критерии приёмки (KPI):
- 0 accidental layout breakages reported by client content team
- 100% adherence to corporate design system constraints
- Full support for core block styles and alignment presets
Пошаговое практическое руководство по ТЗ
Подробный разбор архитектуры, код реализации и советы эксперта по каждому этапу: