Move the shared card presentation out of the engine into an orchestra_presentation submodule

Moves the shared card presentation out of the engine, as [#3613906] describes.

What moved

css/cards.css, templates/orchestra-card-row.html.twig and orchestra.libraries.yml now live in a new orchestra_presentation submodule, which depends on nothing but the engine and ships no routes, permissions or services. orchestra keeps src/, its config and its tests: it can be installed headless again, with no theme assets at all.

orchestra_ui, orchestra_views, orchestra_inbox and orchestra_inbox_views each declare the dependency, so a site running the Views integration without the UI still gets styled rows and no pages, which is the case that rules out putting the component in orchestra_ui.

Renames

  • the library orchestra/cards becomes orchestra_presentation/cards, in 9 places: the row template's own attach_library(), two libraries.yml files, MyInstancesController, the three Views field plugins that attach it for their status tags, and two docblocks;
  • the Twig namespace @orchestra/orchestra-card-row.html.twig becomes @orchestra_presentation/... in the two shipped Views row templates.

Nothing user-visible changes: a theme overriding orchestra-card-row.html.twig still overrides it by template name. Only a site naming the library id directly needs the new name, which is free before 1.0.

Tests

Kernel tests do not enable a module's dependencies for it, so the six classes that render a card row or a library-attaching field now list orchestra_presentation. A new PresentationAssetsTest pins the two things a silent rename would break and one rule worth keeping:

  • the library resolves and its stylesheet exists on disk (a surface naming a library that does not exist loses its styling with no error anywhere);
  • the row template resolves under the new Twig namespace;
  • the engine ships no CSS, no templates and no libraries file, so the component cannot drift back into it.

Docs: the module table in architecture.md gains the module, and views.md and concepts.md name the new library and location.

Merge request reports

Loading
Loading