- Issue created by @Kristen Pol
- ๐บ๐ธUnited States Kristen Pol Santa Cruz, CA, USA
I see now this is a core error. If we are supposed to be able to do this, I guess we'd have to have a patch that worked that we can use since it won't make it into core before Barcelona.
- ๐บ๐ธUnited States Kristen Pol Santa Cruz, CA, USA
If we are not supposed to do this or this can't be addressed until after Barcelona, I would assume that all images in components must be a slot for now... perhaps okay for the demo, but that's not always the best UX as it would depend on the component.
- Assigned to wim leers
- ๐ซ๐ฎFinland lauriii Finland
I'm wondering if this would be fixed by ๐ Fix the visually broken "image" component instance: use FileUriItem's computed `url` property, not the stored `value` property Active or if this something in the client side in the vein of ๐ฑ [META] Redux sync on ALL prop types, not just ones with a single [value] property Active ?
- ๐บ๐ธUnited States Kristen Pol Santa Cruz, CA, USA
Lauri thinks this is a bug.
from slack:
Iโm hesitant to move forward until this is fixed since, if itโs not fixed, it changes our approach.
- Issue was unassigned.
- Status changed to Postponed: needs info
3 months ago 8:00am 5 September 2024 - ๐ง๐ชBelgium wim leers Ghent ๐ง๐ช๐ช๐บ
Precise STR would help ๐ Better yet, when you reproduce it, look in the network inspector at the request body for the last request to
/api/preview/โฆ
. Find the entry forimage
and you'll see exactly what the value is that is being sent for it. That'll determine where the root cause lies: back or front end. - ๐บ๐ธUnited States tedbow Ithaca, NY, USA
wim leers โ credited tedbow โ .
- ๐ง๐ชBelgium wim leers Ghent ๐ง๐ช๐ช๐บ
Figured out the root cause while pairing with @tedbow!
- Assigned to wim leers
- Status changed to Needs work
3 months ago 1:02pm 5 September 2024 - ๐ง๐ชBelgium wim leers Ghent ๐ง๐ช๐ช๐บ
I figured out the root cause: this happens when uploading a new image using the
ImageWidget
.There simply is no Redux support yet for
ImageWidget
. That's what ๐ฑ [META] Redux sync on ALL prop types, not just ones with a single [value] property Active is for.As of yesterday, ๐ Media Library integration (includes introducing a new main content renderer/`_wrapper_format`) Fixed landed and introduced hardcoded special support for
MediaLibraryWidget
, withexperience_builder_preprocess_media_library_item__widget()
generating adata-media-file
attribute containing the updated field properties.Phased solution:
- IMMEDIATE WORK-AROUND: Just install the Media Library module and use the Media Library Widget ๐
- MR here: introduce similar behavior for
ImageWidget
, and piggy-back on what #3454173 introduced for Media. - Long-term: generic solution in ๐ฑ [META] Redux sync on ALL prop types, not just ones with a single [value] property Active .
MR incoming.
- Merge request !261#3472192: Redux support for ImageWidget: `[image] String value found, but an object is required` โ (Open) created by wim leers
- Assigned to bnjmnm
- ๐ง๐ชBelgium wim leers Ghent ๐ง๐ช๐ช๐บ
Note: AFAICT this will need to call
ImageItem::preSave()
for it to work, which is called bymassageFormValuesTemporaryRemoveThisExclamationExclamationExclamation()
. But that is only called upon actually saving an entity, and ever since ๐ Unable to save node article form โ remove obsolete TwoTerribleTextAreasWidget + fix duplicate `XB:image` SDC Fixed , that's not called at all anymore. - ๐บ๐ธUnited States Kristen Pol Santa Cruz, CA, USA
YouTube is still processing but here's a screen recording:
Steps to reproduce
- Update demo_design_system (I've added the test component)
- Delete XB component config and clear cache
- Drag "Testing title with image" component into desktop area
- Try to change the title on the sidebar
- ๐บ๐ธUnited States Kristen Pol Santa Cruz, CA, USA
I have the media library installed already so how does that work around this? I am missing something
- ๐ซ๐ฎFinland lauriii Finland
- Status changed to Postponed
3 months ago 12:14pm 6 September 2024 - ๐บ๐ธUnited States bnjmnm Ann Arbor, MI
In ๐ฑ [META] Redux sync on ALL prop types, not just ones with a single [value] property Active I am working on a holistic solution that will likely address what is reported here + expanding support for many previously unsupported prop/field types. What was reported here requires functionality that hasn't been built yet - but it is actively being worked on.
Hi, I know this issue is postponed for now
but while working on a different issue 3472900 ๐ XBEndpointRenderer & processResponseAssets() do not support `ajaxPageState` โ duplicate CSS/JS loading Fixed , I did run into this too and I was able to found some interesting things
setFormState was settings image to '' (empty string) because the prior state had an entry xb_component_props[9acb612e-748c-4f69-b07e-66b95e5d173e][image][media_library_selection]
Javascript while running the below, replace the entry image with image: ''
setFormState((prior: object) => { // Use the "checked" property when present so the value is boolean. // Additional prop types might require similar type conversion so // don't be shocked if it becomes trickier than just this ternary. const newState = { ...prior, [target.name]: value }; storeUpdateCallback(newState); return newState; });
- ๐บ๐ธUnited States Kristen Pol Santa Cruz, CA, USA
There is a fix for this issue here:
along with a fix for textarea props as well.
- ๐ง๐ชBelgium wim leers Ghent ๐ง๐ช๐ช๐บ
๐ Redux Sync all single-value types in the SDC test all props form Fixed landed, so I think @bnjmnm will soon(ish) get to this ๐
- ๐บ๐ธUnited States Kristen Pol Santa Cruz, CA, USA
Should it be put back to active @wim leers?
- ๐บ๐ธUnited States Kristen Pol Santa Cruz, CA, USA
Using MR from ๐ XBEndpointRenderer & processResponseAssets() do not support `ajaxPageState` โ duplicate CSS/JS loading Fixed ...
It took me a few tries, but I made it through all components except the last one in one go... I had to side step some issues (e.g. dragging certain things, can't upload), but this is SO DEMOABLE if you know what *not* to do :D
- Issue was unassigned.
- ๐ง๐ชBelgium wim leers Ghent ๐ง๐ช๐ช๐บ
Deprioritized for now thanks to ๐ Make Media Library a dependency Fixed .
- ๐บ๐ธUnited States Kristen Pol Santa Cruz, CA, USA
Jacob retested this yesterday on the campaign2 and this is fixed. Thanks everyone!
- ๐ง๐ชBelgium wim leers Ghent ๐ง๐ช๐ช๐บ
It is not, that's because ๐ Make Media Library a dependency Fixed masked it by automatically enforcing #10.1 ๐
- ๐บ๐ธUnited States Kristen Pol Santa Cruz, CA, USA
Oh! Haha. Forgot we did thatโฆ der. Okayโฆ thanks for the reminder. We can test again once this is ready. Sorry for the noise.