Skip to content

chore: Reduce amount of live stylesheets loaded in tests#7656

Draft
mbergen wants to merge 49 commits into
mainfrom
mbergen-patch-1
Draft

chore: Reduce amount of live stylesheets loaded in tests#7656
mbergen wants to merge 49 commits into
mainfrom
mbergen-patch-1

Conversation

@mbergen

@mbergen mbergen commented Jun 13, 2026

Copy link
Copy Markdown
Collaborator

Summary

Sometimes, loading stylesheets seems to (partially) fail in CI.
This removes loading of skin-specific styles from the live server, loading only fontawesome styles.

Styles used in snapshot tests are (roughly) added to Main.scss, which is only used in tests.

Further, this introduces the #snapshot tag to only execute snapshot tests when using npm run update-snapshots.

How did you test this change?

N/A

@mbergen mbergen requested review from a team as code owners June 14, 2026 18:31
@mbergen

mbergen commented Jun 14, 2026

Copy link
Copy Markdown
Collaborator Author

Topics for discussion/review:

  • Is copying CSS bits into Main.scss for use in CI the way to go? Or do we want to wait until the missing CSS is ported to this repo?
  • If no, do we still want to remove fetching it and live with the non-optimal display until CSS is ported?
  • If yes, is the current approximation fine, or should this PR aim for pixel-perfect match of current snapshots?

@hjpalpha hjpalpha left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm on phone

@hjpalpha hjpalpha left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

would it make sense to properly integrate those styles into the existing style sheets?
(possibly oos)

apart from that question: lgtm on phone

@mbergen

mbergen commented Jun 22, 2026

Copy link
Copy Markdown
Collaborator Author

would it make sense to properly integrate those styles into the existing style sheets? (possibly oos)

apart from that question: lgtm on phone

Yes, but that is way easier for an employee with access to the current style sources instead of me trying to extract what i assume are the relevant parts from the large processed stylesheet that's currently loaded

@Rathoz Rathoz removed the stylesheets label Jul 3, 2026
@Rathoz

Rathoz commented Jul 3, 2026

Copy link
Copy Markdown
Collaborator

Buttons are being tweaked atm, so just awaiting that

@Rathoz

Rathoz commented Jul 9, 2026

Copy link
Copy Markdown
Collaborator

button styling has been updated

mbergen and others added 5 commits July 9, 2026 17:26
# Conflicts:
#	lua/spec/snapshots/prize_pool.png
#	lua/spec/snapshots/tabs_dynamic_variants.png
#	lua/spec/snapshots/team_participant.png
#	lua/spec/snapshots/teamcard_legacy.png
#	lua/spec/tabs_snapshot_spec.lua
@mbergen mbergen force-pushed the mbergen-patch-1 branch from c288674 to 47ff7e4 Compare July 9, 2026 15:56
This reverts commit 254e67c.

# Conflicts:
#	stylesheets/Main.scss
@mbergen mbergen force-pushed the mbergen-patch-1 branch from a07d0c8 to 7cb1dfc Compare July 9, 2026 16:03
Comment thread stylesheets/Main.scss
Comment on lines +93 to +119
/* Styles that are not yet part of this repository, but used in snapshot tests */
:root {
--clr-moon-40: #666666;

--clr-primary-44: #1f73c1;
--clr-primary-100: #ffffff;

--clr-secondary-25: #404040;
--clr-secondary-80: #b3b3b3;
--clr-secondary-100: #ffffff;

--clr-semantic-gold-20: #665400;
--clr-semantic-gold-40: #ccab00;
--clr-semantic-gold-90: #fff5cc;

--clr-semantic-silver-40: #557177;

--clr-semantic-positive-30: #1d7c1d;
--clr-semantic-negative-40: #b81414;

--clr-on-surface-light-primary-4: rgba( 0, 0, 0, 0.04 );
--clr-on-surface-light-primary-8: rgba( 0, 0, 0, 0.08 );
--clr-on-surface-light-primary-12: rgba( 0, 0, 0, 0.12 );

--clr-wiki-primary-container: #e2e2e6;
--clr-wiki-theme-primary: var( --clr-moon-40 );
}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should. come with LH now?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've tried it without these, and infobox colors were off compared to current main

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can remove these changes and we can use this PR for testing, would that make sense?

Comment thread stylesheets/Main.scss
Comment thread lua/spec/helpers/template.html Outdated
mbergen and others added 4 commits July 10, 2026 19:27
# Conflicts:
#	lua/spec/snapshots/LeagueIcon.generate_copy_paste_gen.png
#	lua/spec/teamcard_legacy_spec.lua
@mbergen mbergen marked this pull request as draft July 10, 2026 20:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants