Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Documents] Headless CMS #8197

Closed
brusch opened this issue Feb 17, 2021 · 2 comments
Closed

[Documents] Headless CMS #8197

brusch opened this issue Feb 17, 2021 · 2 comments
Assignees

Comments

@brusch
Copy link
Member

brusch commented Feb 17, 2021

It should be possible to define a content structure without the need of specifying a template.
The concept could be similar to the one we're using already in a minimal version for the Editable Dialog.

Possible approach:

  • Defining the content-structure in a YAML file
  • The YAML file is then specified as the "template" on a page/snippet
  • If a YAML file is provided as a template, then Pimcore knows it's a headless content strucure
  • The editing interface is generated according to the content structure defined in the YAML

Additionally it would be nice to have a preview generator, that is used to generate the preview URL (see also Link Generators for Objects )

Example YAML

Could be stored in /config/pimcore/headless-definitions/example.yaml

content:
    headline:
        type: input
        config:
            placeholder: 'Headline'
            required: true

    selectTest:
        type: select
        config:
            store:
                - ["one-month", "One month"]
                - ["three-months", "three-months"]
                - ["unlimited", "unlimited"]
    mainContent:
        type: wysiwyg
        config:
            height: 200

    contentBlocks:
        type: areablock
        bricks:
            teasers:
                teaser_1:
                    type: snippet
                teaser_2:
                    type: snippet
            gallery:
                imagesBlock:
                    type: block
                    items:
                        image:
                            type: image
                            width: 200
                            height: 200
                            thumbnail: gallery
            video:
                video:
                    type: video
            productListing:
                products:
                    type: relations
                    types: ["object"]
                    classes: ["Product"]
@julkue
Copy link
Contributor

julkue commented Jun 16, 2021

@brusch Thanks for bringing this up. I've also brought this up in a similar way in the DataHub repository:
pimcore/data-hub#113

@brusch brusch changed the title [Documents] Decoupled CMS / Headless CMS [Documents] Headless CMS Jul 8, 2021
@brusch brusch removed this from the 10.1.0 milestone Aug 2, 2021
@brusch
Copy link
Member Author

brusch commented Oct 4, 2021

We've decided to implement this feature in a bundle, all necessary core changes have been made (#9816), so I'll close this ticket here.

@brusch brusch closed this as completed Oct 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants