Make WordPress Core

Opened 8 years ago

Closed 7 years ago

Last modified 7 years ago

#38329 closed enhancement (maybelater)

Create positioning control for Custom Logos

Reported by: melchoyce's profile melchoyce Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: Customize Keywords: needs-patch
Focuses: Cc:


It would be great to allow users to position their Custom Logos above, to either side, or below their title/tagline.

Change History (10)

#1 @westonruter
8 years ago

Should this be something that is part of core or just part of a theme that facilitates different positions for the logo? A theme could add a theme_mod setting and dropdown control for logo_position with the desired array of choices and then the theme's header.php could just move the call to get_custom_logo() according to whatever the theme_mod is set to.

#2 @celloexpressions
8 years ago

This is probably best handled either as a theme-specific option or as a rethinking of the show/hide text option entirely. For a theme like Twenty Fifteen, for example, to the side wouldn't make sense, but above, below, or in place of the text could make sense. Is there a way that this could make sense in every theme that supports logos?

It should be fairly straightforward to implement as a theme-specific option if we want to try it out in Twenty Seventeen, then see if it could come back to core later.

#3 @melchoyce
8 years ago

Yeah, I think a theme-specific option makes the most amount of sense — something that adds on to Custom Logo support in the first place, maybe. Should definitely be opt-in for themes.

#4 @karmatosed
8 years ago

+1 for this. I really think users want it.

#5 @westonruter
7 years ago

  • Keywords needs-patch added
  • Milestone changed from Awaiting Review to 4.8

Perhaps the theme options could be amended with a position_choices array?

add_theme_support( 'custom-logo', array(
        'width'       => 250,
        'height'      => 250,
        'flex-width'  => true,
        'position_choices'  => array(
                'above' => __( 'Above', 'twentyseventeen' ),
                'left_side' => __( 'Left Side', 'twentyseventeen' ),
                'right_side' => __( 'Right Side', 'twentyseventeen' ),
                'below' => __( 'Below', 'twentyseventeen' ),
) );

When this position_choices theme support config option is present, this could cause an additional custom_logo_position setting and control to appear, with a dropdown of the choices presented in the add_theme_support() call. A theme would then be responsible for looking at get_theme_mod( 'custom_logo_position' ) to determine where in the template that the logo should be displayed.

Note also that the custom_logo_position setting would probably need to default to have the refresh transport, as the template would probably need to be refreshed as a whole to move the logo to the required position.

#6 @celloexpressions
7 years ago

I'm still skeptical of whether this makes sense as a core-organized feature. It is not complicated for a theme to add these sorts of options. We really need to get theme developers on board with using the customize API rather than relying on increasingly-convoluted add theme support calls.

In order for this to make sense as a core option, we need to make the argument that there should be a unified experience for logo placement across themes. That requires a majority of themes supporting logos to use logos in a way that the design could accommodate the logo being positioned in different places, and the way those positions could be organized within the theme's design being similar across most themes. The first step here would be analyzing numerous (say, 20-100?) themes that have custom logo support and documenting what logo positioning options (if any) would make sense for their designs.

Currently, most themes make a decision on logo placement based on what fits best with their design, rather than forcing users to contemplate another option. If we're going to add an option, there needs to be a demonstrated need for this in a majority of themes that support logos. I don't think I've ever seen a theme implementing their own option for this, which makes me doubt that there's a need for this in core.

I will also note that I've never had a user want to move their logo around relative to the text - they usually liked it how the theme handled it or wanted to hide the text, which there's a checkbox for (when I was doing in-person support). If there is a demand for this, we should try to find a way to document that and determine whether it's a high enough percentage of users to justify the complexity of another option.

#7 @melchoyce
7 years ago

@celloexpressions makes a good point. Perhaps this would be better explored in some sort of header/branding block later this year, rather than as a pre-content block enhancement to the Customizer.

#8 @westonruter
7 years ago

See also #39916 which proposes positioning for the header image as well.

#9 @melchoyce
7 years ago

  • Milestone 4.8 deleted
  • Resolution set to maybelater
  • Status changed from new to closed

Closing this for now. We can resurrect if it seems relevant later this year.

#10 @Ninos Ego
7 years ago

I really don't understand why you guys are talking about such logo features if svg-support is still not implemented.
I'm a theme and plugin developer and 'll never implement logo-support to our themes until svg is supported. Lots of customers want to have logos vector-based (for good reasons).
About this feature: It makes more sense to support different logo sizes + positions e.g. header, sticky header, slide menu, footer...

Note: See TracTickets for help on using tickets.