- Issue created by @balintbrews
- 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺
Make sure the data matches the shape of how ✨ Config entity for storing code components Active expects it. (Saving is out of the scope of this issue.)
… but per that issue, it'll be exactly like SDC props. So that means … that this can get started ahead of that issue being done? :)
- 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺
This issue summary does not explicitly state which JSON schema types should be available to pick from while defining props for code components.
Are you aware that
type: array
andtype: object
are both impossible to support at this time? Which means that this issue would be restricted to "primitive/scalar" JSON schema types.Citing the relevant bit of config schema that landed in ✨ Config entity for storing code components Active :
type: type: string label: 'Type' constraints: Choice: # Not all JSON Schema basic types make sense (for example: `null`). # @see https://json-schema.org/understanding-json-schema/reference/type - 'string' - 'number' - 'integer' - 'boolean' # @todo Consider adding `array` after https://www.drupal.org/i/3467870 is fixed. # @todo Consider adding `object`, but defining _arbitrary_ object shapes is not yet supported. # @see \Drupal\experience_builder\JsonSchemaInterpreter\SdcPropJsonSchemaType::computeStorablePropShape()
- 🇳🇱Netherlands balintbrews Amsterdam, NL
Are you aware that type: array and type: object are both impossible to support at this time? Which means that this issue would be restricted to "primitive/scalar" JSON schema types.
Yes, I was aware. We'll, of course, need to conform to whatever ✨ Config entity for storing code components Active can support in terms of schema and whatever the current capabilities are when it comes to rendering a component props form (which will happen in ✨ Create a ComponentSource plugin for JS components Active ).
- 🇳🇱Netherlands balintbrews Amsterdam, NL
Crediting @callumharrod for helping with the design.
- First commit to issue fork.
- 🇳🇱Netherlands balintbrews Amsterdam, NL
We made an attempt to add auto-save in this MR, but it didn't work out as easily as I hoped. Let's land that in a new issue.
-
balintbrews →
committed 28ece862 on 0.x
Issue #3500017 by balintbrews, hooroomoo, wim leers, callumharrod,...
-
balintbrews →
committed 28ece862 on 0.x
- 🇳🇱Netherlands balintbrews Amsterdam, NL
@jessebaker, I deeply appreciate your swift review and thorough feedback. Thank you for helping to land this. 🚢
- 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺
Looks AMAZING! 🤩👏
Looking forward to being able to save it in ✨ Loading and auto-saving an edited code component Active 😄
- 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺
Signaling this still needs a screencast/GIF.
Automatically closed - issue fixed for 2 weeks with no activity.