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

Data Views: Revisit layout config structure #60507

Open
ntsekouras opened this issue Apr 5, 2024 · 0 comments
Open

Data Views: Revisit layout config structure #60507

ntsekouras opened this issue Apr 5, 2024 · 0 comments
Labels
[Feature] Data Views Work surrounding upgrading and evolving views in the site editor and beyond [Type] Code Quality Issues or PRs that relate to code quality

Comments

@ntsekouras
Copy link
Contributor

Currently in view config we have an optional config prop (layout) per layout type (grid, table, etc..).

We're starting to have several kind of displays for fields: primary, media, badge (maybe others in other layouts). It would be good to check if we can consolidate somehow.

We should check whether existing layout config props could be reused in every layout and moved to fields API (example primaryField), we should check whether existing props should be moved to the render function of a field (example badgeFields), and we should explore how/whether to update the visibleFields with a different structure. An example suggestion by @youknowriad is:

Maybe visibleFields could support arrays as fields: [ [ { field: 'preview', display: 'media' }], { field: 'title', display: 'primary' }], { field: 'sync-status', display: 'badge' }, 'anyrandomfield' ]

@ntsekouras ntsekouras added [Type] Code Quality Issues or PRs that relate to code quality [Feature] Data Views Work surrounding upgrading and evolving views in the site editor and beyond labels Apr 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Data Views Work surrounding upgrading and evolving views in the site editor and beyond [Type] Code Quality Issues or PRs that relate to code quality
Projects
None yet
Development

No branches or pull requests

1 participant