- Issue created by @Dan.Ashdown
- 🇬🇧United Kingdom Dan.Ashdown
Outstanding feedback still to be addressed.
- https://www.drupal.org/project/custom_elements/issues/3333832#comment-14... 📌 Support Views Closed: won't fix
- https://www.drupal.org/project/custom_elements/issues/3333832#comment-14... 📌 Support Views Closed: won't fix
- https://www.drupal.org/project/lupus_ce_renderer/issues/3333827#comment-... 📌 Support Views Closed: won't fix
- https://www.drupal.org/project/lupus_ce_renderer/issues/3333827#comment-... 📌 Support Views Closed: won't fix
- @danashdown opened merge request.
- Status changed to Needs review
almost 2 years ago 9:17am 29 March 2023 - First commit to issue fork.
- Status changed to Needs work
almost 2 years ago 9:53pm 11 April 2023 - 🇦🇹Austria fago Vienna
finally found some time to play with this.
unfortunately I was not really get it working for a entity rendering though. it worked fine when rendering individual fields. Somehow it ended up in an end-less loop when trying to render an entity with an custom-elements enabled view-mode. When the view mode was not custom-elements enabled, it errored out due to pre-rendering step being not called. So fixed that part by invoking the view via
$result = $view->executeDisplay($display_id, $args);
That way it works when the view-mode is not custom-elements enabled.
Also I figured routes are needlessly cloned, so I removed that part. it's a bit weird when the default route shows a custom-elements API response, but I guess this is what has been configured and should be fine for now.
So I guess main blocker here is getting this to work for renderring entity view-modes wtih custom elements. Are you using it that way or with per-field rendering?
- 🇦🇹Austria fago Vienna
ok, tested again on a fresh install. Now everything worked with and without custom-elements enableld view modes. Seems like this was some issue with my previous install.
This all works now, except that rendered entities are still wrapped in a "element": "drupal-markup".
So we need to improve the render-array support in custom-elements such that createFromRenderArray() can detect rendered-entities that render into custom elements better. opened 📌 Improve CustomElement::createFromRenderArray() to better handle entites that render to custom elements Active for that.Thus, I improved naming to be consistent.
-
fago →
committed 5d0d08f7 on 1.x authored by
Dan.Ashdown →
Issue #3340520 by Dan.Ashdown, fago: Add a module for Views support
-
fago →
committed 5d0d08f7 on 1.x authored by
Dan.Ashdown →
- 🇦🇹Austria fago Vienna
Thus, moved on and merged it! Please test and let's open new issue for remaining issues!
- Status changed to Fixed
over 1 year ago 7:54am 26 April 2023 Automatically closed - issue fixed for 2 weeks with no activity.