Skip to content

Drop upload-button feature #2014

Closed

Description

@fregante

The feature is currently broken. It was initially added because we hide this bar via CSS:

However now we have two reasons why this is not useful:

  • upload-button now also takes care of hiding the bar; i.e. the feature can be disabled altogether and the bar reappears
  • we now also offer a CSS field to restore the bar

Additionally:

Therefore we can either:

  • 👎 Keep the feature as JS, but not add the alternative button
  • 👍 Drop the JS feature and just hide the bar via CSS (who doesn't want it can undo it easily in the custom CSS field)

Activity

  1. added
    small
    on May 6, 2019
  2. Mange commented on May 31, 2019

    @Mange

    who doesn't want it can undo it easily in the custom CSS field

    How can I undo this? I cannot use drag-and-drop so I need to be able to click this button to get a file selector up and it's not clear to me what I can do to get it back.

  3. fregante commented on May 31, 2019

    @fregante
    MemberAuthor

    Probably

    .drag-and-drop {
    	display: block !important;
    }
  4. Mange commented on May 31, 2019

    @Mange

    I finally got it working with

    /* Restore upload message on comment box */
    body file-attachment.is-default .drag-and-drop {
    	display: flex !important;
    }

    I had to add body to add extra specificity since the stylesheet overrides in the settings are loaded before the stylesheet, so it didn't win the specificity war.

    Screenshot showing stylesheet order in Firefox

  5. fregante commented on Jun 1, 2019

    @fregante
    Author
  6. Mange commented on Jun 1, 2019

    @Mange
  7. Mange commented on Jun 1, 2019

    @Mange

    An update for any future searchonauts:

    Since #2086, you need to use this override in the CSS:

    /* Restore upload message on comment box */
    body file-attachment.js-upload-markdown-image.is-default .drag-and-drop {
    	display: flex !important;
    }
  8. ShalokShalom commented on Jun 2, 2019

    @ShalokShalom

    Can we add an option for this?

  9. fabiospampinato commented on Jun 13, 2019

    @fabiospampinato

    Shouldn't the currently hidden bar for uploading a file be re-enabled then?

    Basically forcing users to always use drag & drop provides no advantage whatsoever to me.

  10. fregante commented on Jun 13, 2019

    @fregante
    MemberAuthor

    The option is the CSS

  11. locked and limited conversation to collaborators on Jun 13, 2019
  12. fregante commented on Jun 13, 2019

    @fregante
    MemberAuthor
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

    acceptedbugsmall

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions