Skip to content

Polish Social Icons setup state to make adding blocks more intuitive #56259

Closed

Description

@getdave

Currently this is the state fo the Social Icons block when inserted:

Screen Shot on 2023-11-17 at 14-34-45

Problems I see:

  • the instructional text contains the word "Click" which makes you assume you can click to add. This is not the case. Moreover we shouldn't need to rely on this text.
  • the + plus icon is aligned to far right and is disconnected from where the user is naturally drawn. It sholud be where the instructional text is and the text shouldn't even be there.

Other suggested improvements:

  • consider a placeholder state whereby a placeholder icon acts as the inserter. When you click the icon it brings up the block inserter to pick your social platform.

cc @richtabor who is looking into editor polish and may have other ideas for improvements

Activity

  1. added
    [Type] Enhancement
    [Block] Social
    on Nov 17, 2023
  2. added
    Needs Design
    on Nov 18, 2023
  3. jasmussen commented on Nov 29, 2023

    @jasmussen
    Contributor

    This has been an adventure ever since the first iterations of this block, and it really needs a rethink. The problem is, each service is its own block, and inserting a service is not just a single click on the plus like it is for the Buttons block, it's click and then searchm, and then click again. We've tried pre-inserting a curated list of services, but that gives bias to those over others. Even then, they won't show up on the frontend until you add a URL. How can we make it as simple to add a social link as it is to add a button?

    Just to explore an out-there idea:

    • WordPress button always inserted by default.
    • Plus button always inserts the WordPress service.
    • Clicking the service shows recent transforms right in the popover, in addition to the URL you mean to add
    • The inspector shows transforms, the most recent N, at the top, just like it does for Group blocks now, and how it might for navigation items in Navigation Items: Add transform items in the inspector, a la Group/Row/Stack #46195. Also shows the URL field.
    • Buttons are always output on the frontend, and are not considered "empty" just because they have no link. Longer term we add a design linter, a pre-publish panel that surfaces empty links.

    Quick sketch of the idea:

    Sketch

    The potential benefits I could see from this would be:

    • Click click click to insert a bunch of services.
    • Click each individual one to change the service to something else.
    • By ordering according to usage, very soon the list of social links will put Mastodon at the top of that's the one you're always inserting.
    • Patterns could pre-suggest social links, and they'd appear on the frontend even if empty.
  4. richtabor commented on Nov 29, 2023

    @richtabor
    Member

    What about a pre-publish check for empty, or #, social icons? Instead of omitting them from the front-end if empty.

  5. jasmussen commented on Nov 30, 2023

    @jasmussen
    Contributor

    Yep, I think that's a "design linting" tool that would be useful regardless. Whether we then output empty icons on the frontend or not, I could go either way.

  6. richtabor commented on Dec 5, 2023

    @richtabor
    Member

    Could we just infer icon/variation based on URL?

    i.e. You type in https://twitter.com/richard_tabor and it selects the Twitter variation for you? And if you edit the link to https://profiles.wordpress.org/richtabor/ then it changes the icon/variation to WordPress.

    If there is no variation, then just use the link variation.

  7. richtabor commented on Dec 6, 2023

    @richtabor
    Member

    Could we just infer icon/variation based on URL?

    Something like this, which leans on LinkControl UI a bit (also adding open in a new tab in the same fashion).

    social.mp4
  8. jasmussen commented on Dec 6, 2023

    @jasmussen
    Contributor

    I'm into it! What happens if you paste a URL that is not recognized? I suppose it just falls back to the generic link icon?

    Perhaps more importantly: how do we enable generic patterns to pre-build a curated selection of social links — would they have to paste in the URL? That might not be the most discoverable. Could we show, perhaps, an "advanced" chevron that lets you choose the particular icon without filling in a URL, and then leaning on the URL inferring as the main interface? Mainly, if we'll ever build a pre-publish or document-outline linting tool to surface empty URLs, it would be nice if patterns wouldn't have to pre-fill them.

  9. richtabor commented on Dec 6, 2023

    @richtabor
    Member

    I'm into it! What happens if you paste a URL that is not recognized? I suppose it just falls back to the generic link icon?

    Yes, that's what I'm thinking — which we already have a variation for.

    how do we enable generic patterns to pre-build a curated selection of social links — would they have to paste in the URL?

    Instead of # which they're typing now, the values would be twitter.com/# for a Twitter/X link.

    Though in this concept, the URL is just a quick entry for inserting the block (essentially like embeds do with relative URLs), then you could still add the block within the pattern markup, empty.

  10. jasmussen commented on Dec 6, 2023

    @jasmussen
    Contributor

    Though in this concept, as the URL is just a quick entry for inserting the block (essentially like embeds do with relative URLs), then you could still add the block within the pattern markup, empty.

    Ah yes, so the individual links exist, but this is just a shortcut. Yes, let's try this! 👍 👍

  11. krokodok commented on Dec 11, 2023

    @krokodok
    Contributor

    I think the URL recognition looks promising. I had one additional thought about improving the block: Should we allow users to upload a custom logo and enter an accompanying a11y-text for services that are not supported? As an alternative to the fallback icon?

    In addition: Would this issue here be the right place to include the issue of transforming block variations (#46726)? I think the URL auto-detect mechanism would not solve this entirely. I would need to know the exact URL scheme of a service that can be parsed and then type it out or copy-paste it from a new tab I opened to search the correct URL, just to transform a placeholder block I created to the right variation.

  12. richtabor commented on Dec 12, 2023

    @richtabor
    Member

    I think the URL auto-detect mechanism would not solve this entirely. I would need to know the exact URL scheme of a service that can be parsed and then type it out or copy-paste it from a new tab

    My expectation is that copy/paste is currently (and would continue being) the primary pattern used to add social links. The URL mechanism would just remove the step required currently, where you first insert the block before copy/paste.

  13. Mamaduka commented on Feb 21, 2024

    @Mamaduka
    Member

    Thank you, @jasmussen, for pointing me to this issue.

    I can start working on a variation auto-detect mechanism using the URLs.

  14. self-assigned this
    on Feb 21, 2024
  15. added
    [Status] In Progress
    on Feb 23, 2024
  16. Mamaduka commented on Feb 23, 2024

    @Mamaduka
    Member

    The PR is ready for testing and reviews - #59303.

  17. changed the title [-]Polish Social Icons setup state to make adding blocks more intuative[/-] [+]Polish Social Icons setup state to make adding blocks more intuitive[/+] on Mar 4, 2024
  18. afercia commented on Mar 26, 2024

    @afercia
    Contributor

    Just noting that I recently created a few issues about the Social Icons:

  19. getdave commented on Aug 28, 2024

    @getdave
    ContributorAuthor
  20. removed their assignment
    on Mar 10, 2025
  21. added
    Needs Decision
    and removed
    [Status] In Progress
    on Mar 10, 2025
  22. jasmussen commented on Aug 20, 2026

    @jasmussen
    Contributor

    This appears resolved. The specific problems described here were addressed by #64877 (merged), which removed that copy and replaced it with an inline button appender similar to the Navigation block. Related follow-ups raised in this thread were also addressed: #60120 (keyboard operability) and #60044/#60047 (preventing empty links). Closing as fixed; please reopen with a current repro if the setup state still feels unintuitive, or file a new issue if the broader "always show a default WordPress icon, click to add repeatedly" concept from this thread should be pursued separately.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Needs DecisionNeeds Design[Block] Social[Type] Enhancement

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions