NPM Resource Changed ? ? Pending

User tests: Successful: Unsuccessful:

avatar bembelimen
bembelimen
31 Dec 2018

Summary of Changes

Joomla has an internal LoadingLayer which appears if you change e.g. the category in an article while having custom fields.

This layer could be generated unlimited times by calling Joomla.loadingLayer('load'); but this make no sense. This PR prevents multi loading of this layer

Testing Instructions

  • open the edit form of an article
  • open your developer console in your browser
  • type in Joomla.loadingLayer('load');

Expected result

only one instance of the layer is created

Actual result

unlimited layers are creatable

Documentation Changes Required

avatar bembelimen bembelimen - open - 31 Dec 2018
avatar bembelimen bembelimen - change - 31 Dec 2018
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 31 Dec 2018
Category JavaScript Repository
avatar bembelimen bembelimen - change - 31 Dec 2018
Labels Added: ?
avatar dgrammatiko
dgrammatiko - comment - 31 Dec 2018

/**
* Add Joomla! loading image layer.
*
* Used in: /administrator/components/com_installer/views/languages/tmpl/default.php
* /installation/template/js/installation.js
*
* @param {String} task The task to do [load, show, hide] (defaults to show).
* @param {HTMLElement} parentElement The HTML element where we are appending the layer (defaults to body).
*
* @return {HTMLElement} The HTML loading layer element.
*
* @since 3.6.0
*
* @deprecated 4.0 No direct replacement.
* 4.0 will introduce a web component for the loading spinner, therefore the spinner will need to
* explicitly be loaded in all relevant pages.
*/
Joomla.loadingLayer = function(task, parentElement) {

This method will be removed

avatar mbabker
mbabker - comment - 31 Dec 2018
  1. Bug fixes really should go to staging if they apply there (hint, this one does)
  2. Even if something is deprecated, until it is removed there is no reason to block optimizations/changes to the deprecated element (well, short of adding new functionality unless it is to help bridge to the replacement); if the web component is ready then it should be in use and this method removed otherwise at best it is just a note stating an intention.
avatar dgrammatiko
dgrammatiko - comment - 31 Dec 2018

there is no reason to block optimizations/changes

I wasn't meant to block but defer to the staging. I guess I need to write a bit more text on these comments...

avatar mbabker
mbabker - comment - 31 Dec 2018

Lesson I learned the hard way, short and direct doesn't always communicate well ?

avatar PhocaCz
PhocaCz - comment - 5 Jan 2019

I have tested this item successfully on df9a13f

I do not know what is the state of this PR for now but I get the same results when applying the patch/without applying the patch:

OK


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/23407.

avatar PhocaCz PhocaCz - test_item - 5 Jan 2019 - Tested successfully
avatar joomla-cms-bot joomla-cms-bot - change - 26 Feb 2019
Category JavaScript Repository JavaScript Repository NPM Change
avatar chmst chmst - test_item - 27 Feb 2019 - Tested successfully
avatar chmst
chmst - comment - 27 Feb 2019

I have tested this item successfully on cf97ada


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/23407.

avatar HLeithner HLeithner - change - 27 Feb 2019
Title
Prevent loading LoadingLayer twice
[4.0] Prevent loading LoadingLayer twice
avatar HLeithner HLeithner - edited - 27 Feb 2019
avatar Quy Quy - change - 27 Feb 2019
Status Pending Ready to Commit
avatar Quy
Quy - comment - 27 Feb 2019

RTC


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/23407.

avatar wilsonge wilsonge - change - 27 Feb 2019
Labels Added: ?
avatar wilsonge wilsonge - change - 27 Feb 2019
Status Ready to Commit Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2019-02-27 16:09:46
Closed_By wilsonge
Labels Added: NPM Resource Changed
avatar wilsonge wilsonge - close - 27 Feb 2019
avatar wilsonge wilsonge - merge - 27 Feb 2019
avatar wilsonge
wilsonge - comment - 27 Feb 2019

Thanks!

Add a Comment

Login with GitHub to post a comment