erdnaxelaweb/ibexadesignintegration
This bundle extends erdnaxelaweb/staticfakedesign to provide an abstraction layer for the Ibexa CMS in order to streamline the templates development workflow.
It serves as a bridge between static design development and the Ibexa CMS by:
composer require erdnaxelaweb/ibexadesignintegration
config/bundles.php:return [
// ...
ErdnaxelaWeb\IbexaDesignIntegrationBundle\IbexaDesignIntegrationBundle::class => ['all' => true],
// ...
Ibexa\Bundle\Core\IbexaCoreBundle::class => ['all' => true],
];
/!\ Be sure to load before the IbexaCoreBundle
showroom:
resource: "@StaticFakeDesignBundle/Resources/config/routing/showroom.yaml"
defaults:
siteaccess_group_whitelist: 'static_group'
ibexa_design_integration:
resource: "@IbexaDesignIntegrationBundle/Resources/config/routing/routes.yaml"
Refer to the erdnaxelaweb/staticfakedesign bundle documentation for detailed usage instructions.
Define content types in a standardized way using the definition pattern:
parameters:
erdnaxelaweb.static_fake_design.content_definition:
article:
name:
eng-GB: 'Article'
nameSchema: '<title>'
urlAliasSchema: '<title>'
fields:
title:
type: string
required: true
body:
type: richtext
required: false
Define taxonomy types for categorizing content:
parameters:
erdnaxelaweb.static_fake_design.taxonomy_entry_definition:
category:
fields:
name:
required: true
type: string
identifier:
required: true
type: string
Create custom landing page blocks:
ibexa_design_integration:
system:
default:
block_definition:
featured_articles:
views:
default: '@ibexadesign/landing_page/block/featured_articles.html.twig'
attributes:
title:
type: "string"
required: false
articles:
type: "content"
required: true
options:
type: article
max: 3
The bundle provide a set of twig functions to integrate templates with the Ibexa CMS.:
display_content: Renders a content view template{{ display_content(<template name>, <content>, <parameters>, <is ESI>, <view type>) }}
{{ display_content('@ibexadesign/content/list/news.html.twig', content, []) }}
display_block: Renders a block view template{{ display_block(<block>, <is ESI>) }}
{{ display_block(block) }}
display_component: Renders a component view template{{ display_component('@ibexadesign/components/footer.html.twig', []) }}
{{ display_component(<template name>, <parameters>, <controller action>, <is ESI>) }}
Thoses functions are used to switch between include and render depending on the context (static or dynamic version).
<view>/<content_type>.html.twigcontentDetailed documentation is available in the ./doc directory:
Contributions are welcome! Please feel free to submit a Pull Request.
composer config repositories.ibexadesignintegration '{"type": "path", "url": "../", "options": {"symlink": true}}' --json
composer require erdnaxelaweb/ibexadesignintegration:*
yarn install --cwd ../
cp ../doc/example/* ./ -R
This bundle is released under the MIT License.
How can I help you explore Laravel packages today?