[2.1.x] UI Patterns Library: add some interactions

Created on 14 March 2023, over 1 year ago
Updated 15 January 2024, 8 months ago

Problem/Motivation

Adding some interactions in the pattern library pages will make it more useful.

For fields (slots)

A mechanism to switch on/off an overlay to show the slots area and their machine names

Examples:

For settings (props)

Some knobs (like Storybook) to change the preview values which are acting like the patterns fields forms:

  • checkboxes
  • select lists
  • textfields
  • ....

Proposed resolution

The slots overlay is easy to do un preprocesses, pattern preview by pattern preview, the 3 examples are not mockups but real screenshots of a 15 minutes POC.

However :

  • how to (optionally) apply it to every pattern preview. There is no hook_preprocess_pattern
  • the dynamic part (on/off) seems complicated

For the props knobs, it seems tricky. Maybe an AJAX request to a renderer endpoint which send the updated HTML markup, which will override the content of the preview area.

User interface changes

Yes, some new features on the library pages.

API changes

No, it is safe.

Project with overrides of the library pages templates will not see the new fetaure, but the pages will not break.

🌱 Plan
Status

Postponed

Version

2.0

Component

UI Patterns Library

Created by

🇫🇷France pdureau Paris

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024