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

Preview mode selector #7870

Open
alansemenov opened this issue Sep 19, 2024 · 0 comments
Open

Preview mode selector #7870

alansemenov opened this issue Sep 19, 2024 · 0 comments
Assignees

Comments

@alansemenov
Copy link
Member

alansemenov commented Sep 19, 2024

Create a new dropdown component which will list available view modes for a given content item. Underlying data set of the selector will be based on the list of widgets, fetched with GetWidgetsByInterfaceRequest . Viewer class of the new dropdown should have an icon (widget icon), mode name (widget's display name) and mode description (widget's description). Existing WidgetSelectorDropdown should work just fine, but it doesn't handle order of widgets (see below).

Order of items is determined by the value in config.order field of the widgets list.

In the first revision there will be three built-in modes:

  • [skip for now]Automatic (will find the first mode in the list that matches selected content type and/or path, so it should display f.ex. "Automatic (Site Engine)" or "Automatic (JSON)" )
  • Site Engine (what Content Studio currently shows in the preview panel)
  • JSON (raw persisted JSON)

All of the built-in modes must be handled by built-in widgets in Content Studio, except for "Automatic" (which will basically use the best fitting widget and will be implemented in a separate task later on).

Selector must remember the selection. If user selected "JSON" for a content, then when another content is selected "JSON" must still be selected in the selector.

Image

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

No branches or pull requests

2 participants