Needs review
Project:
Drupal core
Version:
main
Component:
menu_ui.module
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
30 Jun 2023 at 16:04 UTC
Updated:
1 May 2026 at 15:02 UTC
Jump to comment: Most recent, Most recent file


Comments
Comment #3
cilefen commentedComment #4
cilefen commentedComment #5
ranjith_kumar_k_u commentedThere was an issue with the functionality, so fixed that and added tests.
The current MR was created against 9.5x and I don't have permission to edit, so created patch
Comment #6
ranjith_kumar_k_u commentedComment #7
smustgrave commentedThis seems close but I don't see where we are testing that the menu link is pre-checked on the node add page.
Also will need a change record with appropriate screenshots.
Comment #8
ranjith_kumar_k_u commentedHi, I updated the tests, I hope this will be enough
Change record - https://www.drupal.org/node/3373587
Comment #10
smustgrave commentedThink this is better
Comment #11
lauriiiGiven the schema change, wouldn't this need an upgrade path?
Comment #12
smustgrave commentedClosed #1440694: Add a menu item for each "Basic page" by default (Standard install profile) as a duplicate
Comment #13
yoroy commentedExcellent idea, lets do this. Two questions:
- Provide or create? Maybe create is the simpler word? Lets also add 'a': Create a new menu item by default.
- Was this deliberately put at the bottom of this list of settings? I can also imagine it at the top, as the very first consideration and decision to make for this menu settings section.
Comment #14
chris matthews commented"Provide" is the word used in the Menu settings on the node edit form, so it might be best to keep the words consistent.
"Provide a menu link by default."
-OR-
"Provide a menu link by default when saving new content."
-OR-
"Provide a menu link by default when saving new content of this type." - My vote, fwiw
The "...content of this type" phrase comes from two other places:
"Content of this type can be placed in the selected menus."
"This text will be displayed at the top of the page when creating or editing content of this type."
The word "Add" would also make sense as it is used throughout the UI, but between the 3 proposed options (Provide, Create, Add) I'd personally vote for consistency and stick with "Provide", unless we want to change the word "Provide" to something else on the node edit form.
Note: whichever sentence ends up being used it needs a . (period) at the end of the sentence.
I think it make most sense either right above or right below the Default parent link select list as the two are related.
Comment #15
kunal.sachdev commentedComment #17
kunal.sachdev commentedComment #18
omkar.podey commentedThe MR looks good overall but I think the testing could be easily extended to check if the link was actually created at
admin/structure/menu/manage/mainComment #19
kunal.sachdev commentedComment #20
smustgrave commentedSeems additional test coverage has been added in commit https://git.drupalcode.org/project/drupal/-/merge_requests/4642/diffs?co...
Comment #21
alexpottSee the comment on the MR - we need to rewrite the post update.
Comment #22
alexpottHiding all the files to make this easier to review.
Comment #24
niklp commented+1 for putting it at the top.
I get what Chris Matthews is saying but in natural order I would say something like: "Oh definitely create a menu item by default, these are the menus I would like available, but the default one should be this." That feels right to me.
Comment #26
smustgrave commentedClosed #3405645: Auto create the menu for node. as a duplicate of this.
Triaging this one
First this needs an issue summary update.
Let me try and get a main branch up for review.
Comment #27
smustgrave commentedComment #28
smustgrave commentedComment #30
smustgrave commentedBelieve this is ready for review.