DEV: Update linting (#236)

This commit is contained in:
Jarek Radosz 2025-03-17 12:41:55 +01:00 committed by GitHub
parent c07e5e1066
commit c10bd4dcf6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 1204 additions and 1341 deletions

View File

@ -1,80 +1,93 @@
GEM
remote: https://rubygems.org/
specs:
activesupport (7.1.3.3)
activesupport (8.0.2)
base64
benchmark (>= 0.3)
bigdecimal
concurrent-ruby (~> 1.0, >= 1.0.2)
concurrent-ruby (~> 1.0, >= 1.3.1)
connection_pool (>= 2.2.5)
drb
i18n (>= 1.6, < 2)
logger (>= 1.4.2)
minitest (>= 5.1)
mutex_m
tzinfo (~> 2.0)
securerandom (>= 0.3)
tzinfo (~> 2.0, >= 2.0.5)
uri (>= 0.13.1)
ast (2.4.2)
base64 (0.2.0)
bigdecimal (3.1.8)
concurrent-ruby (1.2.3)
connection_pool (2.4.1)
benchmark (0.4.0)
bigdecimal (3.1.9)
concurrent-ruby (1.3.5)
connection_pool (2.5.0)
drb (2.2.1)
i18n (1.14.5)
i18n (1.14.7)
concurrent-ruby (~> 1.0)
json (2.7.2)
language_server-protocol (3.17.0.3)
minitest (5.23.1)
mutex_m (0.2.0)
parallel (1.24.0)
parser (3.3.1.0)
json (2.10.2)
language_server-protocol (3.17.0.4)
lint_roller (1.1.0)
logger (1.6.6)
minitest (5.25.5)
parallel (1.26.3)
parser (3.3.7.1)
ast (~> 2.4.1)
racc
prettier_print (1.2.1)
racc (1.8.0)
rack (3.0.12)
racc (1.8.1)
rack (3.1.12)
rainbow (3.1.1)
regexp_parser (2.9.2)
rexml (3.3.9)
rubocop (1.64.0)
regexp_parser (2.10.0)
rubocop (1.74.0)
json (~> 2.3)
language_server-protocol (>= 3.17.0)
language_server-protocol (~> 3.17.0.2)
lint_roller (~> 1.1.0)
parallel (~> 1.10)
parser (>= 3.3.0.2)
rainbow (>= 2.2.2, < 4.0)
regexp_parser (>= 1.8, < 3.0)
rexml (>= 3.2.5, < 4.0)
rubocop-ast (>= 1.31.1, < 2.0)
regexp_parser (>= 2.9.3, < 3.0)
rubocop-ast (>= 1.38.0, < 2.0)
ruby-progressbar (~> 1.7)
unicode-display_width (>= 2.4.0, < 3.0)
rubocop-ast (1.31.3)
unicode-display_width (>= 2.4.0, < 4.0)
rubocop-ast (1.38.1)
parser (>= 3.3.1.0)
rubocop-capybara (2.20.0)
rubocop (~> 1.41)
rubocop-discourse (3.8.0)
rubocop-capybara (2.22.1)
lint_roller (~> 1.1)
rubocop (~> 1.72, >= 1.72.1)
rubocop-discourse (3.12.1)
activesupport (>= 6.1)
rubocop (>= 1.59.0)
rubocop-capybara (>= 2.0.0)
rubocop-factory_bot (>= 2.0.0)
rubocop-rails (>= 2.25.0)
rubocop-rspec (>= 2.25.0)
rubocop-factory_bot (2.25.1)
rubocop (~> 1.41)
rubocop-rails (2.25.0)
lint_roller (>= 1.1.0)
rubocop (>= 1.73.2)
rubocop-capybara (>= 2.22.0)
rubocop-factory_bot (>= 2.27.0)
rubocop-rails (>= 2.30.3)
rubocop-rspec (>= 3.0.1)
rubocop-rspec_rails (>= 2.31.0)
rubocop-factory_bot (2.27.1)
lint_roller (~> 1.1)
rubocop (~> 1.72, >= 1.72.1)
rubocop-rails (2.30.3)
activesupport (>= 4.2.0)
lint_roller (~> 1.1)
rack (>= 1.1)
rubocop (>= 1.33.0, < 2.0)
rubocop-ast (>= 1.31.1, < 2.0)
rubocop-rspec (2.29.2)
rubocop (~> 1.40)
rubocop-capybara (~> 2.17)
rubocop-factory_bot (~> 2.22)
rubocop-rspec_rails (~> 2.28)
rubocop-rspec_rails (2.28.3)
rubocop (~> 1.40)
rubocop (>= 1.72.1, < 2.0)
rubocop-ast (>= 1.38.0, < 2.0)
rubocop-rspec (3.5.0)
lint_roller (~> 1.1)
rubocop (~> 1.72, >= 1.72.1)
rubocop-rspec_rails (2.31.0)
lint_roller (~> 1.1)
rubocop (~> 1.72, >= 1.72.1)
rubocop-rspec (~> 3.5)
ruby-progressbar (1.13.0)
securerandom (0.4.1)
syntax_tree (6.2.0)
prettier_print (>= 1.2.0)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
unicode-display_width (2.5.0)
unicode-display_width (3.1.4)
unicode-emoji (~> 4.0, >= 4.0.4)
unicode-emoji (4.0.4)
uri (1.0.3)
PLATFORMS
ruby
@ -84,4 +97,4 @@ DEPENDENCIES
syntax_tree
BUNDLED WITH
2.5.10
2.6.6

View File

@ -4,29 +4,30 @@
max-width: 10%;
box-sizing: border-box;
float: left;
}
margin-top: 0.33em;
position: relative;
.vote-count-wrapper {
border: 3px solid var(--primary-low);
}
.voting-wrapper.show-pointer .vote-count-wrapper:not(.no-votes) {
cursor: pointer;
&:hover {
background-color: var(--primary-low);
.rtl & {
float: right;
padding-right: 0;
padding-left: 0.75em;
}
}
.vote-count-wrapper {
border: 3px solid var(--primary-low);
font-weight: bold;
display: flex;
align-items: center;
justify-content: center;
}
.title-voting {
margin-top: 0.33em;
position: relative;
.voting-wrapper.show-pointer .vote-count-wrapper:not(.no-votes) {
cursor: pointer;
&:hover {
background-color: var(--primary-low);
}
}
.vote-button {
@ -41,6 +42,7 @@
.vote-option {
cursor: pointer;
padding: 0.35em;
&:hover {
background-color: var(--primary-low);
}
@ -77,6 +79,7 @@
line-height: var(--line-height-medium);
z-index: z("usercard") - 1;
cursor: initial;
// voter avatars
.regular-votes {
display: flex;
@ -84,18 +87,7 @@
align-items: center;
justify-content: center;
}
}
// TEMP: RTL overrides
.title-voting {
.rtl & {
float: right;
padding-right: 0;
padding-left: 0.75em;
}
}
.voting-popup-menu {
.rtl & {
left: unset;
right: 80px;

View File

@ -3,6 +3,10 @@
float: none;
max-width: none;
text-align: inherit;
.rtl & {
float: none;
}
}
.voting-wrapper {
@ -13,6 +17,7 @@
.vote-count-wrapper {
min-width: 70px;
box-sizing: border-box;
// match button height
min-height: 30px;
}
@ -22,23 +27,14 @@
margin-left: 0.5em;
margin-top: 0;
white-space: nowrap;
}
.voting-popup-menu {
width: calc(100vw - 100px);
// 80px left positioning + 20px .wrap padding
}
// TEMP: RTL overrides
.title-voting {
.rtl & {
float: none;
}
}
.vote-button {
.rtl & {
margin-left: 0;
margin-right: 0.5em;
}
}
.voting-popup-menu {
// 80px left positioning + 20px .wrap padding
width: calc(100vw - 100px);
}

View File

@ -1,10 +1,11 @@
{
"private": true,
"devDependencies": {
"@discourse/lint-configs": "2.4.0",
"ember-template-lint": "6.1.0",
"eslint": "9.19.0",
"prettier": "2.8.8"
"@discourse/lint-configs": "2.11.1",
"ember-template-lint": "7.0.1",
"eslint": "9.22.0",
"prettier": "3.5.3",
"stylelint": "16.16.0"
},
"engines": {
"node": ">= 22",

File diff suppressed because it is too large Load Diff

3
stylelint.config.mjs Normal file
View File

@ -0,0 +1,3 @@
export default {
extends: ["@discourse/lint-configs/stylelint"],
};