No Code Attached Yet
avatar micker
micker
20 Sep 2023

need to update the tabs in editor, options etc
image
image

avatar micker micker - open - 20 Sep 2023
avatar joomla-cms-bot joomla-cms-bot - change - 20 Sep 2023
Labels Added: No Code Attached Yet
avatar joomla-cms-bot joomla-cms-bot - labeled - 20 Sep 2023
avatar micker micker - change - 20 Sep 2023
Title
[5.0] Dark Mode: Options
[5.0] Dark Mode: tabs
avatar micker micker - edited - 20 Sep 2023
avatar micker micker - change - 20 Sep 2023
The description was changed
avatar micker micker - edited - 20 Sep 2023
avatar wilsonge
wilsonge - comment - 20 Sep 2023

image

I can't reproduce the tabs issue at all. I can only suggest you have some sort of template override in place or the file failed to compile somewhere as tabs customisations are in media/templates/administrator/atum/css/vendor/joomla-custom-elements/joomla-tab.min.css rather than the main template file.

The editor itself is a known issue and is captured in #41801

avatar wilsonge
wilsonge - comment - 20 Sep 2023

image

Article edit for completeness

avatar roland-d
roland-d - comment - 20 Sep 2023

@wilsonge When I go to Options via Template manager I see the same as Micker. This is on Firefox/Linux
image

avatar wilsonge
wilsonge - comment - 20 Sep 2023

I am testing on Chrome and Firefox on Ubuntu 22.04 :)

avatar Quy
Quy - comment - 20 Sep 2023

I cannot reproduce it with Chrome & Firefox on Windows. Is this happening with the other settings?

avatar micker
micker - comment - 20 Sep 2023

for me in all tabs (chrome, windows 11)

avatar wilsonge
wilsonge - comment - 20 Sep 2023

I just chatted to @roland-d and for some reason after a full browser cache clear everything worked

avatar micker micker - close - 20 Sep 2023
avatar micker micker - change - 20 Sep 2023
Status New Closed
Closed_Date 0000-00-00 00:00:00 2023-09-20 13:19:45
Closed_By micker
avatar micker
micker - comment - 20 Sep 2023

yes confirmed for me sorry

avatar wilsonge wilsonge - change - 20 Sep 2023
Status Closed New
Closed_Date 2023-09-20 13:19:45
Closed_By micker
avatar wilsonge wilsonge - reopen - 20 Sep 2023
avatar wilsonge
wilsonge - comment - 20 Sep 2023

Going to keep this open. @HLeithner you might want to look at bumping the asset version for that file to avoid this happening to others on upgrade. Looks like the atum override is currently pinned to the version of custom elements rather than the Joomla version. If not dark mode will bite us elsewhere at some point

avatar HLeithner
HLeithner - comment - 20 Sep 2023

which assets do you mean and where is it pinned?

avatar Fedik
Fedik - comment - 20 Sep 2023

The template assets version is auto, and generated with this

public function getMediaVersion(): string

Addittionaly it regenerates every time joomla updated.

Such issue may only happen when "mediaversion refresh" is disabled in debug plugin.
Or testing on git branch, without cleaning cache ?

avatar wilsonge
wilsonge - comment - 20 Sep 2023

That's the template one. The version for the joomla-tab.css is 0.2.0 - I can't find any hardcoded reference to that so assume that comes from the version in package.json of custom-elements we use. Assume that link is buried somewhere in the build scripts

avatar Fedik
Fedik - comment - 20 Sep 2023

yeah, joomla-tab comes from https://www.npmjs.com/package/joomla-ui-custom-elements and version also

avatar wilsonge
wilsonge - comment - 20 Sep 2023

The JS yes. The CSS comes from this https://github.com/joomla/joomla-cms/blob/4.3-dev/build/media_source/templates/administrator/atum/scss/vendor/joomla-custom-elements/joomla-tab.scss SCSS file but is still versioned as 0.2.0 anyway in it's own file (it is NOT part of the template css files). Which is why on upgrade we're getting issues.

avatar HLeithner
HLeithner - comment - 20 Sep 2023

so maybe the logic for the version could be improved

avatar wilsonge
wilsonge - comment - 20 Sep 2023

Yes hence I've reopened this issue. Otherwise we might hit it again outside of dark mode specific issues. It's unlikely that I'll have time to work on it before the RC's though so would be amazing if someone else could pick this up. Maybe @dgrammatiko could take a look if he's not super busy ?

avatar Fedik
Fedik - comment - 20 Sep 2023

Since it is an override, we can also overide the asset defination,
Add:

{
      "name": "webcomponent.joomla-tab",
      "type": "style",
      "uri": "vendor/joomla-custom-elements/joomla-tab.min.css",
},

In to Template assets administrator/templates/atum/joomla.asset.json.
Note: The version property is empty, it will use auto version.

avatar Fedik
Fedik - comment - 20 Sep 2023

This should help #41841, please test

avatar HLeithner
HLeithner - comment - 20 Sep 2023

the thing is it should go automatically in auto mode for overrides?

avatar HLeithner
HLeithner - comment - 20 Sep 2023

and auto is not so cool as it sounds ;-)

avatar Fedik
Fedik - comment - 20 Sep 2023

Yes and no,
When you overide only file, then it will keep vendor version, defined in the asset (this case we have here)
When you overide asset with new version, then it use new version (this what the fix doing #41841)

and auto is not so cool as it sounds

Why? It pretty safe, it refreshes on every joomla update,
addittionaly when you push "clean all cache" in backend, it also will force a new media version

avatar HLeithner
HLeithner - comment - 20 Sep 2023

Why? It pretty safe, it refreshes on every joomla update,
addittionaly when you push "clean all cache" in backend, it also will force a new media version

  • It doesn't check the file, if it changes I would expect this. For development it a pain point.
  • the hash is too long (unneeded traffic)
  • I would like to have a "development" or "random" mode in addition
avatar dgrammatiko
dgrammatiko - comment - 20 Sep 2023

What @Fedik did is fine and actually should be promoted as a best practice, ie: if you're about to override a static asset then it should be defined in the template's json.

This could be automated, ie check the files in the js/css and create the respected entries

avatar Fedik
Fedik - comment - 20 Sep 2023

It doesn't check the file,

Do you really want to add extra filesystem IO request ? ?

the hash is too long (unneeded traffic)

We can make it shorter, but that not really an issue, it not huge

I would like to have a "development" or "random" mode in addition

We have it: enable debug, and in debug plugin you can change "refresh every time" or "do not use it"

I think our approach is already good enough. Maybe confusing, but working ?

avatar HLeithner
HLeithner - comment - 20 Sep 2023
  1. no of course not
  2. we minifiy every asset, I have files where the content is shorter then the url ;-) 32 characters are not needed 5 could be enough
  3. the thing with the debug plugin is that it maybe hurt development
avatar Fedik
Fedik - comment - 20 Sep 2023

Here it goes:

avatar dgrammatiko
dgrammatiko - comment - 20 Sep 2023

@Fedik could you also reduce the version string here:

const hash = await createHashFromFile(path);
asset.version = hash;

Nevermind, here's the PR: #41844

avatar wilsonge
wilsonge - comment - 20 Sep 2023

Can we focus on the issue which is to use the Joomla version string for the css file from atum used for the tabs styling :)

avatar HLeithner
HLeithner - comment - 20 Sep 2023

Can we focus on the issue which is to use the Joomla version string for the css file from atum used for the tabs styling :)

that's already fixed in #41841

avatar wilsonge wilsonge - change - 20 Sep 2023
Status New Closed
Closed_Date 0000-00-00 00:00:00 2023-09-20 18:26:24
Closed_By wilsonge
avatar wilsonge wilsonge - close - 20 Sep 2023

Add a Comment

Login with GitHub to post a comment