Problem/Motivation
From @quietone
$ git grep -li shortcut | grep -v core/modules/shortcut | grep -v core/assets/vendor | grep -v phpstan-baseline | grep -v core/.deprecation-ignore.txt | grep -v core/modules/json | grep -v core/MAINTAINERS.txt | nl
30 core/themes/claro/claro.info.yml
31 core/themes/claro/claro.libraries.yml
32 core/themes/claro/css/components/shortcut.css
33 core/themes/claro/css/components/shortcut.pcss.css
34 core/themes/default_admin/css/components/shortcut.css
35 core/themes/default_admin/css/components/shortcut.pcss.css
36 core/themes/default_admin/default_admin.info.yml
37 core/themes/default_admin/default_admin.libraries.yml
38 core/themes/default_admin/migration/css/base/gin.css
39 core/themes/default_admin/migration/css/components/toolbar.css
40 core/themes/default_admin/migration/css/layout/navigation.css
41 core/themes/default_admin/migration/js/navigation.js
42 core/themes/default_admin/migration/js/sidebar.js
43 core/themes/default_admin/migration/media/sprite.svg
44 core/themes/default_admin/templates/navigation/menu-region--top.html.twig
45 core/themes/default_admin/tests/src/Functional/AdminTest.php
46 core/themes/olivero/config/install/olivero.settings.yml
47 core/themes/olivero/config/schema/olivero.schema.yml
48 core/themes/olivero/css/components/page-title.css
49 core/themes/olivero/css/components/page-title.pcss.css
50 core/themes/olivero/src/Hook/OliveroHooks.php
51 core/themes/stable9/css/shortcut/shortcut.icons.theme.css
52 core/themes/stable9/css/shortcut/shortcut.theme.css
53 core/themes/stable9/stable9.info.yml
Steps to reproduce
NA
Proposed resolution
Move css/js code olivero, and default_admin.
Claro is skipped in https://drupal.slack.com/archives/C079NQPQUEN/p1775929853834789 @catch mentioned claro can remain and be removed when it's deprecated.
Remaining tasks
Manual review
User interface changes
None (least there shouldn't be)
Introduced terminology
NA
API changes
NA
Data model changes
NA
Release notes snippet
NA
| Comment | File | Size | Author |
|---|---|---|---|
| #24 | Screenshot from 2026-05-13 22-09-28.png | 17.1 KB | longwave |
Issue fork drupal-3582690
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
smustgrave commentedComment #3
smustgrave commentedComment #6
quietone commentedLet's get a review of this
Comment #7
smustgrave commentedFYI I'm not a fan of this approach but I don't know what's best.
Comment #8
needs-review-queue-bot commentedThe Needs Review Queue Bot tested this issue. The merge request has merge conflicts and cannot be merged. Therefore, this issue status is now "Needs work".
This does not mean that the patch necessarily needs to be re-rolled or the MR rebased. Read the Issue Summary, the issue tags and the latest discussion here to determine what needs to be done.
Consult the Drupal Contributor Guide to find step-by-step guides for working with issues.
Comment #9
quietone commentedComment #10
smustgrave commentedOkay from slack seems like this approach is the least disruptive. Probably needs some work so going to try and work on it during my flight
Comment #11
quietone commentedThis needs more detail. This should be a summary of the discussion and who participated. A link to the discussion is fine, but we can't rely on a Slack link for documenting our issue discussions.
Comment #14
smustgrave commentedComment #15
smustgrave commentedOkay this should be ready for reviews.
Comment #16
smustgrave commentedReverted stable9 per a conversation with Gabor where we discussed we shouldn't touch themes being deprecated
Comment #17
dcam commentedI think I found a couple of bad image file paths. But I also tried to help figure out what needs to be done with those third party settings. See what you think.
Comment #18
smustgrave commentedSo guess the only outstanding question is the olivero.schema?
Comment #19
smustgrave commented@dcam wonder if #3402885: olivero.settings config schema is wrong addresses the olivero.schema concerns?
Comment #20
dcam commentedI'd completely forgotten about that issue, despite having worked on it.
After doing additional analysis my answer is "No." But, it brings additional problems with this MR to light. Ultimately, I think that other issue needs to be closed as a duplicate since there's no point to enacting the change now. Some of the code from its MR needs to be copied here before that.
Comment #21
smustgrave commentedPorted over the update hook from #3402885: olivero.settings config schema is wrong but not the themeHandler stuff
I'm trying to find an answer about what to do with default_admin theme
Changed the hook approach as it wasn't loading
Comment #22
quietone commentedComment #23
longwaveShortcuts are available in both Claro and Default Admin when Navigation is enabled, although when you have no shortcuts it is not obvious how to set up the first one, unlike with Toolbar which showed it up front. Steps to reproduce:
mainYour shortcut set now appears at the top of the navigation panel, under Shortcuts.
Comment #24
longwaveRegarding the star that appears in the page title; by default this appears in Claro and not Default Admin. This is because of the theme setting
third_party_settings.shortcut.module_link.ShortcutHooks::themesInstalled()explicitly handles Claro only:If we add default_admin here:
then reinstall Default Admin, the shortcut star does show up and works, but the placement is off (the text is shown because I hovered over the star while taking the screenshot):
Comment #25
longwave@smustgrave asked me to comment on this issue. I haven't looked at any of the MRs on this issue yet, just read the comments and done some manual testing and investigation into the codebase.
Currently, both Olivero and Claro support Shortcut via
third_party_settings.shortcut.module_link. For reasons I haven't dug into Olivero sets this incore/themes/olivero/config/install/olivero.settings.ymlwhereas Claro has this set by Shortcut itself in hook_install and hook_themes_installed.In order to decouple Shortcut from Olivero I think we should take the same approach as Claro does: Shortcut should set the setting by itself in hook_install and hook_themes_installed. shortcut_uninstall should also take care of removing the setting again. This should mean that it's self contained in Shortcut module; when upgrading to Drupal 12 users will either need to download Shortcut from contrib, or uninstall it first.
Regarding the CSS I think any Shortcut CSS from Olivero or Claro will need to move to libraries in Shortcut and be attached as necessary by Shortcut itself.
Per #24 I think we can drop Shortcut support from Default Admin immediately, assuming that Navigation is purely responsible for displaying shortcuts and there is no explicit theme support there; we might need another issue to decouple Shortcut from Navigation? The only way to enable the star feature is by manually configuring the third party setting; when Shortcut is in contrib it can add support for Default Admin then if anyone wants to do the work. Similarly Shortcut in contrib can figure out a way of adding support to other themes, if anyone wants that feature.
Comment #26
longwaveIf we want to reduce scope and perhaps make things easier we could break this into one issue per theme?
Comment #27
smustgrave commentedOk I moved over olivero + claro
I deleted all the default_admin config.
As 1 of the co-maintainers in contrib for this I definitely want to make this better but lets land it first :)
Comment #28
needs-review-queue-bot commentedThe Needs Review Queue Bot tested this issue. It no longer applies to Drupal core. Therefore, this issue status is now "Needs work".
This does not mean that the patch necessarily needs to be re-rolled or the MR rebased. Read the Issue Summary, the issue tags and the latest discussion here to determine what needs to be done.
Consult the Drupal Contributor Guide to find step-by-step guides for working with issues.
Comment #29
smustgrave commentedComment #30
nicxvan commentedI think this is pretty close, I'm not sure the best way to test this. Do we pull it down and search the theme for shortcut? Then enable shortcut and confirm they work correctly?
Comment #31
smustgrave commentedYup! Just for olivero and claro since this never worked in default admin theme
Comment #32
nicxvan commentedOk I pulled this down and searched in themes.
There are no references to shortcut I can find except in stable9 which isn't part of this issue.
I then installed drupal fresh, no shortcut as expected.
I then installed shorcut and tested that the icons show up in claro and olivero.
Clicking the star adds them to shortcuts and clicking again removes them, I think this is ready!
Hook and css moves look right.
The backport folder is a bit strange, but this is moving to contrib so that can be cleaned up.
Not entirely sure about adding olivero settings in shortcut, but it does show up in the page as expected.
Comment #33
nicxvan commentedScratch that, I think shortcut needs an uninstall hook to remove olivero.settings.third_party_settings.shortcut.module_link right?
Comment #34
smustgrave commentedIt's in the olivero.post_update file, we pulled from another ticket.
Comment #35
nicxvan commentedYes, that pulls olivero's instance out, but we set it on shortcut install, so now we need to delete it when shortcut is uninstalled right?
Comment #36
smustgrave commentedGood catch I add the same snippet to the uninstall hook we had for claro.
Comment #37
smustgrave commentedComment #38
nicxvan commentedLooks great to me!
Comment #42
catchCommitted/pushed to main and cherry-picked to 11.x and 11.4.x, thanks!