- Issue created by @mortona2k
- π«π·France pdureau Paris
The Links prop type is an abstract data structure made to be able to "host" many Drupal data sttucture (menu, links, pager, breadcrumb...)
It is normal the structure is a bit different before after the normalization: https://git.drupalcode.org/project/ui_patterns/-/blob/2.0.x/src/Plugin/U...
We hope this work will be done by Drupal Core in the future: β¨ Add unified Links data type for menus, pagers, breadcrumbs... Active
- πΊπΈUnited States mortona2k Seattle
The main issue I encountered is that the url is a string instead of an object.
To print it in the template took extra checks and manipulation to handle the 3 different link urls.
- π«π·France pdureau Paris
The main issue I encountered is that the url is a string instead of an object.
It was done in purpose. Everything related to the application state must be resolved before being sent to component template. SDC templates must be dumb, UI-logic only.
To print it in the template took extra checks and manipulation to handle the 3 different link urls.
Are you sure you need those checks to implement an UI component like DaisyUI's footer? I guess not :)
If yes, we can talk about changing
LinksPropType::normalize()
logic.