Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
My themers ask me for first/last classes on things on a constant basis. primary/secondary links already have them, but other lists don't. Attached patch adds first/last classes to all theme_item_list lists as well as to all menu block lists. It's just extra hooks for themers to play with.
Comment | File | Size | Author |
---|---|---|---|
#6 | notices_9.patch | 642 bytes | webernet |
#2 | firstlast_0.patch | 3.4 KB | Crell |
firstlast.patch | 4.07 KB | Crell | |
Comments
Comment #1
yched CreditAttribution: yched commentedOoh yes, +1.
The parts that affect menu_local_tasks() seem unneeded ?
Comment #2
Crell CreditAttribution: Crell commentedIndeed, that's because they are. :-) I had tried to add first/last there as well, but gave up because that function scares me.
Comment #3
yched CreditAttribution: yched commentedready then...
Comment #4
Gábor HojtsyGood idea, good code, committed.
Comment #5
webernet CreditAttribution: webernet commentedThis patch introduced the following notices on admin/build/modules
* notice: Undefined variable: items in /includes/menu.inc on line 596.
* notice: Undefined variable: items in /includes/menu.inc on line 597.
* warning: Invalid argument supplied for foreach() in /includes/menu.inc on line 597.
Comment #6
webernet CreditAttribution: webernet commentedComment #7
dvessel CreditAttribution: dvessel commentedComment #8
Stefan Nagtegaal CreditAttribution: Stefan Nagtegaal commentedSimple one-liner, RTBC!
Comment #9
Gábor HojtsyThat was quick, thanks, committed.
Comment #10
(not verified) CreditAttribution: commented