Closed (fixed)
Project:
Layout Builder Direct Add
Version:
8.x-1.2
Component:
User interface
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
7 Jul 2020 at 12:36 UTC
Updated:
21 Feb 2022 at 18:46 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
pyrello commented@galactus86 Thanks for checking out the module. I took a look at the definition for the 'dropbutton' render element: https://api.drupal.org/api/drupal/core%21lib%21Drupal%21Core%21Render%21.... It doesn't look like there is a way, using that element, to create the type of UX you are requesting. If you have a suggestion for an alternative, I would be happy to look into it. Also, if you want to provide a patch, I'll give it a look.
Thanks!
Sean
Comment #3
arshadkhan35 commentedThanks @pyrello for this amazing module, we are using this module too and wanted to have this feature where we can add new label at the top of the dropdown, Created a patch for the same which include
Please have look. thanks
Comment #4
arshadkhan35 commentedComment #5
pyrello commented@arshadkhan35 Thanks for submitting a patch. I'll take a look when I have some time to review it.
Comment #6
arshadkhan35 commentedHi @pyrello please ignore #3 patch as it has some missing file , Rerolling the same patch against 8.x-1.2 tag and 8.x-1.x-dev branch.
Comment #7
arshadkhan35 commentedComment #8
galactus86 commentedHi @pyrello
For some reason I missed any updates on this issue so I apologize for not following up.
I applied the patch from @arshadkhan35 with Composer and so far it seems to work as described. I am able to access the config page, update the text, and then use on a Layout Page. Not seeing any errors in the logs.
And really useful module, so thank you!
Comment #9
pyrello commentedTargeting a new version and taking the opportunity to switch to semantic versioning at the same time :)
Comment #10
pyrello commentedAfter testing the patch in #7, my impression is that using the dropbutton element no longer seems right when the first link is not an actual action and just a trigger for seeing the actions. This patch attempts to create a UI for what I think the experience should be like.
Feedback is definitely welcome.
Comment #11
pyrello commentedComment #14
pyrello commentedAdding a patch to make testing changes to the issue fork and merge request easier.
Comment #15
pyrello commentedI always forget to add these at the time when I am adding the patch.
Comment #16
pyrello commentedHere is what it looks like in practice:
Comment #17
pyrello commentedThe patch in #14 had an error in because I had failed to change a couple of variable names when I was renaming things.
New patch, new interdiff.
Comment #18
pyrello commentedComment #19
pyrello commentedComment #20
pyrello commentedComment #21
pyrello commentedComment #22
pyrello commentedBased on some limited feedback in Slack and our own testing, I think I'm ready to call this RTBC. If we need to refine the UI in the future, I guess we'll open additional issues.
Thanks to everyone for your help with this.
Comment #24
pyrello commentedComment #25
pyrello commentedComment #27
jdhaire commentedWas this patch merged into v1.2? I have 1.2 installed but it does not match branch 2.x. I tried applying the https://www.drupal.org/files/issues/2021-03-17/3157440-17_0.patch without success. On drupal 9.3.4. Any direction on how to get this functionality would be appreciated. Love this idea as it saves time and reduces clicks. Thanks!
Comment #28
jdhaire commentedNevermind! I completely overlooked the 2.x-dev (maybe add to the module page). Any way, works as expected. Is there a way to modify the + icon that displays before the label? I would like to style it to match the rest of the + icons. Thanks again! Sorry for the first message panic. Ha!