[6.x]: No way for custom element types to add top level buttons in toolbar or beside the Save menu
Los mantenedores suelen responder en 1 día
@brianjhanson ya está trabajando en esto.
Desde el 9/10/2026.
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 15/100
Línea de trabajo
Start with ElementEditorActions::buttonActions() and the ElementEditorPayloadResolving hook, which the issue says only ever wire buttons to submitAction(), and with the payload.previewTargets path used for the toolbar's View links. The open question is the API design: how a plugin can declare a non-submitting link, download or modal button for the toolbar or beside Save. Done means a maintainer-agreed extension point, not a patch, so check for a decision in the thread before writing code.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
What happened?
The legacy editor rendered getAdditionalButtons() / additionalButtonsHtml() beside Save, which in Craft 5 sat in the page header, so these buttons were prominent at the top of the edit page. On the Inertia elements/Edit page:
editorActions.buttons(beside Save in the footer) is built from core actions (Create a draft, Apply draft, etc.) inElementEditorActions::buttonActions(). Plugins can append to it viaElementEditorPayloadResolving, but every button is wired tosubmitAction(), so it submits the editor's form. That suits save variants, not links, downloads or modals.- The toolbar's "View" links come from
payload.previewTargets. They're front-end URLs that also feed Live Preview, so they're not a fit for CP links.
There doesn't appear to be a way to add a non-submitting button (link, download, or modal) to the toolbar or beside Save, other than preview targets.
As a workaround, I've currently added previous custom plugin buttons that lived in these locations to the ⋯ action menu via extraActionMenuDescriptors(), but they're less discoverable there.
Craft CMS version
6.0.0-alpha.20
PHP version
No response
Operating system and version
No response
Database type and version
No response
Image driver and version
No response
Installed plugins and versions
- Lenguaje dominante
- PHP
- Estrellas
- 3.6k
- Forks
- 710
- Merge medio
- 12 h 19 min
- PR fusionados (30 d)
- 293
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Sin plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de craftcms/cms
-
[5.x]: Moving an asset with “Replace it” throws TypeError: volumeUid must be of type string, null givenPosiblemente ocupada @i-just la tomó hace 1 día. Abiertobug repo:cms
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
craftcms/cms#20128 · 2 comentarios · 1 asignado ·
Los mantenedores suelen responder en 1 día
-
bug repo:cms
Dificultad 4/5 3-5 días Aptitud para principiantes 45/100
craftcms/cms#20151 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
bug repo:cms
Dificultad 5/5 Más de una semana Aptitud para principiantes 25/100
craftcms/cms#20150 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
bug repo:cms
Dificultad 3/5 1-2 días Aptitud para principiantes 57/100
craftcms/cms#20143 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
bug repo:cms
Dificultad 3/5 1-2 días Aptitud para principiantes 56/100
craftcms/cms#20142 · 1 comentario ·
Los mantenedores suelen responder en 1 día
Todos los issues de craftcms/cms
Issues similares
-
Dificultad 1/5 Menos de una hora Aptitud para principiantes 84/100
wp-graphql/wp-graphql-woocommerce#1026 ·
-
ServiceMapMissingAnalyser reads @method in docblock prose as a tag and reports a phantom accessorAbiertoagent-ready area:static-analysis bug p3
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
gacela-project/gacela#1050 ·
Los mantenedores suelen responder en 1 día
-
Navigation Container's menu button needs the pointer cursorPosiblemente ocupada @bd-viget la tomó hoy. Abierto
Dificultad 1/5 Menos de una hora Aptitud para principiantes 82/100
vigetlabs/wordpress-site-starter#322 ·
Los mantenedores suelen responder en 15 días
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
grokability/massdriver-server#38 ·
Los mantenedores suelen responder en 1 día
-
bug review needed
Dificultad 1/5 Menos de una hora Aptitud para principiantes 86/100
OpenMage/magento-lts#5816 ·
Los mantenedores suelen responder en 2 días