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

Headless Pages #2621

Open
wants to merge 12 commits into
base: next
Choose a base branch
from
Open

Headless Pages #2621

wants to merge 12 commits into from

Conversation

Pavel910
Copy link
Collaborator

@Pavel910 Pavel910 commented Sep 13, 2022

Changes

This PR introduces tagging of content models and model fields, and adds a "page template" list view. This serves as a starting point to develop a dedicated "Page Template Editor" and Headless Pages functionality. Since page templates are still content models at its core, tags are the simplest way to differentiate between various types of content models.

From the API perspective, we're still using the same listContentModels query, but we're filtering models on the client side, to render type specific UI. However, from the GraphQL schema standpoint, all models are processed the same way, and their respective schemas are generated using the same underlying logic.

I'll use this PR as an umbrella PR for all further tasks.

  1. feat(ui): add protectedTags prop #2623
  2. Extract base content model editor #2627

Copy link
Contributor

@brunozoric brunozoric left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I left some comments which we can discuss. I didn't comment on all the export default, but try to avoid those.

}
})
},
tags: ["content-model", ...(model.tags || [])]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tag here is content-model and I saw in some other places type:contentModel. I assume the difference is due to one being model and other a field...? Maybe use the camel case in both cases?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah good catch. That content-model is a left-over. Tags will be pulled in from model.tags exclusively, so I'll remove this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants