Hide Promoted/Sticky fields by default in Form display

Created on 21 August 2005, over 19 years ago
Updated 29 August 2024, 4 months ago

The problem

The sticky/promoted fields in core date from 2004, and are only used by the default front page + forum module. Some sites use them as a shortcut when they don't need a full entityqueue/flag solution.

As such they're a (small) usability issue since they're quite redundant and often don't do anything depending on how a site is configured. They're also outdated in the sense that this kind of 'feature-y' field would normally be added by entityqueue/flag or a configurable field.

Proposed solution

  1. Make sticky/promoted fields hidden by default in Form Display.
  2. Keep BC.
πŸ“Œ Task
Status

Active

Version

11.0 πŸ”₯

Component
Node systemΒ  β†’

Last updated 4 days ago

No maintainer
Created by

πŸ‡©πŸ‡ͺGermany killes@www.drop.org

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡§πŸ‡ͺBelgium flyke

    Just my two cents: for the love of god, get rid of them both. Please. I beg you.

    Currently, we manage around 30 Drupal projects we've created for clients.
    Only 3 of them implement a blog like funcitonality.
    Literarally none of them use sticky or promoted.
    Yes we had a blog where the client wished for some control to have some blog items on top.
    That means more than one. In the order that he likes, like first node F, then node D, then the rest automatic on date.
    But if your use case is give the client option to set more than 1 node on top of a view, then sticky or promote fields are useless.
    You can add a 'Priority' field with default value set to 0 that you first sort on in the view for example to solve this use case. Or use the node_weight module so client can drag and drop nodes to set the order. But sticky or promoted are useless for having > 1 items on top.

    If its really impossible to replicate this functionality with existing contrib modules (but I think it is) for the few projects that need them, then create a new contrib module that does this so we can remove this from core and those (few) that need it can use contrib modules (or just create a priority field for example and sort on that).

    When I first started going to client meetings many years ago to present a project, those options confused all clients because they were there because its just core, but were not used for anything.
    A beginner mistake to not heavily customize the drupal out of the box (backend) experience for customers if they need access to the backend, for example for content editing.

    So then at first we had a custom module that removed these fields (for client user roles) via form alters I think - and did many other backend adjustments -, then later on we could hide them via the override_node_options module. But those useless (for most projects, not all projects in the world, I know) fields have been a pet peeve of mine for many years now.

  • πŸ‡¬πŸ‡§United Kingdom longwave UK

    We could move these out to a feature flag module, disable it by default on new installs but enable it on existing sites, and eventually move it out to contrib.

  • πŸ‡¬πŸ‡§United Kingdom catch

    When this issue was opened we didn't have dynamic base fields, but now that we have hook_entity_base_field_info() it should be possible for a contrib module to provide these fields as-is. Only issue might be compound database indexes to replicate the core ones, but could fall back to the database API + field database schema for that bit.

  • πŸ‡¨πŸ‡­Switzerland berdir Switzerland

    #24 tells me that people don't don't that you can hide both promote and sticky through the manage form display page, since 8.0. No extra modules or custom code required.

    Removing/moving those fields sounds like a very scary upgrade path issue to me. We know that people don't read and they also don't do backups, so upgrading means that we will drop their data.

    What if we just do a very basic change for now, and that's to have those fields hidden by default. If you want to use them, make them visible, otherwise you likely won't notice that they still exist. That's as simple as removing two method calls in the field definitions and has very limited risk.

  • πŸ‡¨πŸ‡¦Canada xmacinfo Canada

    What if we just do a very basic change for now, and that's to have those fields hidden by default.

    I vote for this so that I can keep those flags for current sites but hide those for sites I don’t need those.

  • πŸ‡³πŸ‡ΏNew Zealand john pitcairn

    +1 to #27. Removing them outright would be disastrous.

    I use (or abuse) those fields on some sites, though I usually change their labels to reflect the specific outcome for each site.

  • πŸ‡§πŸ‡ͺBelgium flyke

    +1 to #27: I don't want to be responsible for existing projects to fail after an update. Hiding is a good first step.
    I would still like to see them deprecated and maybe moved to contrib over time. Or maybe sort of disabled for new installs, but I'm guessing thats almost the same as the proposal from #27.

    Side note: I checked and we do actually just hide them in form display now. Still, would be nice if this is default behavior to improve the out of the box content editor experience in case you added a new content type or started a new project and you forgot to do this for the millionth time.

  • πŸ‡¨πŸ‡¦Canada xmacinfo Canada

    Changing issue title and summary.

  • πŸ‡¨πŸ‡¦Canada xmacinfo Canada
Production build 0.71.5 2024