Problem/Motivation

A developer is unable to use custom markup for the throbber element (e.g. when integrating existing solution that already has styles and JavaScript code).

Proposed resolution

Move HTML code for the element to Drupal.theme function and use Drupal theming mechanism for JavaScript code.

Files: 
CommentFileSizeAuthor
#10 drupal-themable-throbber-2407859-10.patch6.55 KBsidharthap
#3 drupal-themable-throbber-2407859-3.patch4.31 KBjwilson3
FAILED: [[SimpleTest]]: [PHP 5.5 MySQL] Unable to apply patch drupal-themable-throbber-2407859-3.patch. Unable to apply patch. See the log in the details link for more information. View

Comments

aprogs’s picture

FileSize
1006 bytes
PASSED: [[SimpleTest]]: [MySQL] 41,130 pass(es). View

Attached the patch.

jwilson3’s picture

Version: 7.x-dev » 8.0.x-dev
Issue tags: +TX (Themer Experience), +FX (Front End Experience), +JavaScript, +Ajax, +CSS

This feels like a super good idea and would bring the ajax throbber code inline with how the progress bar is built which also uses Drupal.theme js functionality.

This needed a re-roll because ajax.js has moved inside core/ folder and the functionality has slightly changed.

This patch also adds the new SMACSS compatibility to the throbber, and improves themability of the "fullscreen" progress indicator, as well as the "message" text that optionally accompanies the throbber in some cases.

jwilson3’s picture

FileSize
4.31 KB
FAILED: [[SimpleTest]]: [PHP 5.5 MySQL] Unable to apply patch drupal-themable-throbber-2407859-3.patch. Unable to apply patch. See the log in the details link for more information. View

Ugh, forgot the patch.

Status: Needs review » Needs work

The last submitted patch, 3: drupal-themable-throbber-2407859-3.patch, failed testing.

jwilson3’s picture

Test fail seems to be due to unrelated issues around missing schemas. Not sure... maybe try to rerun tests again later.

Status: Needs work » Needs review

Status: Needs review » Needs work

The last submitted patch, 3: drupal-themable-throbber-2407859-3.patch, failed testing.

jwilson3’s picture

Status: Needs work » Needs review

Status: Needs review » Needs work

The last submitted patch, 3: drupal-themable-throbber-2407859-3.patch, failed testing.

sidharthap’s picture

Status: Needs work » Needs review
FileSize
6.55 KB

A new patch against updated 8.0.x branch. It seems dialog.css is placed inside the theme (classy, seven, stable) and this patch changed all these css files for throbber element.

Version: 8.0.x-dev » 8.1.x-dev

Drupal 8.0.6 was released on April 6 and is the final bugfix release for the Drupal 8.0.x series. Drupal 8.0.x will not receive any further development aside from security fixes. Drupal 8.1.0-rc1 is now available and sites should prepare to update to 8.1.0.

Bug reports should be targeted against the 8.1.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.2.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

Version: 8.1.x-dev » 8.2.x-dev

Drupal 8.1.9 was released on September 7 and is the final bugfix release for the Drupal 8.1.x series. Drupal 8.1.x will not receive any further development aside from security fixes. Drupal 8.2.0-rc1 is now available and sites should prepare to upgrade to 8.2.0.

Bug reports should be targeted against the 8.2.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.3.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

lauriii’s picture

Status: Needs review » Needs work

Very nice improvement!

+++ b/core/modules/system/css/components/ajax-progress.module.css
--- a/core/themes/classy/css/components/dialog.css
+++ b/core/themes/classy/css/components/dialog.css

+++ b/core/themes/seven/css/components/dialog.css
--- a/core/themes/stable/css/system/components/ajax-progress.module.css
+++ b/core/themes/stable/css/system/components/ajax-progress.module.css

I'm afraid that we are not allowed to make CSS or markup changes for stable or classy and we should keep these changes only for core, Seven and Bartik. What we could do is override the theme functions in Stable and then override them again in Seven and Bartik.

sidharthap’s picture

Version: 8.2.x-dev » 8.3.x-dev

Version: 8.3.x-dev » 8.4.x-dev

Drupal 8.3.0-alpha1 will be released the week of January 30, 2017, which means new developments and disruptive changes should now be targeted against the 8.4.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.