Problem/Motivation

The dropbutton dont follow the css coding standard. Makes it hard for themers to figure out which classes are used by javascript and which are not
[#1887918#separate-concerns]

This issue came up as we were cleaning up templates, in core as part of the banana#2

Proposed resolution

* prefix everything that the dropbutton component required of classnames with .js- refactore the css, to reflect that and ensure that the css files gets * splitted up in MAT filestructure [#1887922]
* component must be completely functional with the module.css file (or component) and running in stark, with not theme.css files loaded
* component keeps same design when *.theme.css is activated in classy, stark & seven.

dropbutton is placed on these pages
/node/1/edit
/admin/structure/views/view/aggregator_rss_feed/edit/page_1
/admin/structure/types/manage/page/fields

Remaining tasks

User interface changes

API changes

CommentFileSizeAuthor
#3 dropbottom-2.diff43.15 KBmortendk
dropbottom.diff39.97 KBmortendk
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Status: Needs review » Needs work

The last submitted patch, dropbottom.diff, failed testing.

mortendk’s picture

Issue tags: +jsbanana
mortendk’s picture

Status: Needs work » Needs review
FileSize
43.15 KB

structure in a more BEM like way

<div class="js-dropbutton-wrapper js-dropbutton-processed js-dropbutton-wrapper--multiple">
  <div class="js-dropbutton-widget">
  <ul class="js-dropbutton">
  <li class="publish js-dropbutton-action">
    <input type="submit" name="op" value="Save and keep published" class="button form-submit">
  </li>
  <li class="js-dropbutton__toggle">
    <button type="button">
      <span class="js-dropbutton__toggle__arrow">
        <span class="visually-hidden">List additional actions</span>
      </span>
    </button>
  </li>
  <li class="unpublish js-dropbutton-action js-dropbutton__secondary-action">
    <input type="submit" name="op" value="Save and unpublish" class="button form-submit">
  </li>
</ul>
</div>

Status: Needs review » Needs work

The last submitted patch, 3: dropbottom-2.diff, failed testing.

LewisNyman’s picture

Status: Needs work » Closed (duplicate)
mortendk’s picture

lewis im not sure im agreeing that this is a duplicate of the issue. This is not rewriting the markup this is purely seperating the css names from the js