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

Support Component Story Format (CSF) #24

Closed
9 tasks done
Tracked by #66
kof opened this issue Apr 13, 2022 · 4 comments · Fixed by #53
Closed
9 tasks done
Tracked by #66

Support Component Story Format (CSF) #24

kof opened this issue Apr 13, 2022 · 4 comments · Fixed by #53
Assignees
Labels
area:settings Settings panel on the right complexity:high Multiple weeks of work or more prio:1 The most important thing to work on type:feat Features and enhancements

Comments

@kof
Copy link
Member

kof commented Apr 13, 2022

The idea is to use csf as a way to describe a component to the designer.

This format should let a component express:

  • controls in the properties and style panels
  • supported values for style and properties
  • enable designer render any component with a story out of the box

This is a complex topic that needs research and prototyping.

Tasks

  • add stories to primitives and describe all available properties for each component (includes all available html properties)
  • make sure storybook can display those stories
  • render autocomplete inputs in props panel using options and controls from stories
  • think about how predefined styles on each component could also be expressed via CSF
  • support boolean prop types
  • support numeric prop types
  • use docgen to generate argTypes
  • improve types if needed for primitives to generate good argTypes
  • better ux that lets user discover properties

PRs

@kof kof added enhancement type:feat Features and enhancements complexity:high Multiple weeks of work or more and removed type:enhancement type:feat Features and enhancements labels Apr 13, 2022
@kof kof added type:research Just research, no implementation and removed type:feat Features and enhancements labels May 17, 2022
@kof kof self-assigned this May 17, 2022
@kof kof added area:settings Settings panel on the right and removed area:csf labels May 23, 2022
@kof kof assigned kof and unassigned kof May 27, 2022
@kof kof linked a pull request May 27, 2022 that will close this issue
17 tasks
@kof kof added type:feat Features and enhancements and removed type:research Just research, no implementation labels Jun 8, 2022
@kof kof added the prio:1 The most important thing to work on label Jun 16, 2022
@kof
Copy link
Member Author

kof commented Jul 5, 2022

Known issues in properties section

  • Layout with value as an input field seems broken
    Screenshot 2022-07-04 at 21 15 56

  • Wrong props don't show as error or something and also don't let me enter value, one of these needs to be enabled I guess?
    Screenshot 2022-07-04 at 21 19 08

  • data- properties should always be enabled, right? Maybe except of the once we use in the system? e.g. data-component, data-id and a few more .... though maybe we just need to switch to something like data-webstudio-something to avoid conflicts
    Screenshot 2022-07-04 at 21 20 26

@kof kof closed this as completed in #53 Jul 5, 2022
@kof kof mentioned this issue Jul 5, 2022
17 tasks
@kof kof reopened this Jul 5, 2022
@SaraVieira
Copy link
Contributor

  • The HTML attribute class is not recognized as a valid attribute while classname is

@kof
Copy link
Member Author

kof commented Jul 5, 2022

  • cloned website in production now doesn't show correct attributes on elements: e.g. links don't have the href they used to have, saving new href works, but somehow we are not rendering the current value of an existing href neither in the properties panel nor on canvas

@kof
Copy link
Member Author

kof commented Jul 27, 2022

I think we should close this one and create follow-up issues

@kof kof closed this as completed Jul 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:settings Settings panel on the right complexity:high Multiple weeks of work or more prio:1 The most important thing to work on type:feat Features and enhancements
Projects
No open projects
Status: Done
Development

Successfully merging a pull request may close this issue.

3 participants