From 5433f4721fcb978fcff407ff8bf65c350cc3ff7d Mon Sep 17 00:00:00 2001 From: Matheus Clemente Date: Mon, 10 Jun 2024 19:14:16 -0300 Subject: [PATCH] linting --- src/styles/_chat.scss | 12 +- src/styles/_fonts.scss | 184 +++++++++++------------ src/styles/_init.scss | 10 +- src/styles/_journal.scss | 8 +- src/styles/_language-selector.scss | 138 ++++++++--------- src/styles/_system-specific.scss | 12 +- src/styles/forms/_common.scss | 34 ++--- src/styles/forms/_font-settings.scss | 74 ++++----- src/styles/forms/_general-settings.scss | 22 +-- src/styles/forms/_language-settings.scss | 58 +++---- src/styles/polyglot.scss | 22 +-- 11 files changed, 284 insertions(+), 290 deletions(-) diff --git a/src/styles/_chat.scss b/src/styles/_chat.scss index 15bd567..3215dee 100644 --- a/src/styles/_chat.scss +++ b/src/styles/_chat.scss @@ -1,11 +1,11 @@ .polyglot-translation-text { - border-top: 1px solid var(--color-border-light-2); - -webkit-user-select: text; - -moz-user-select: text; - -ms-user-select: text; - user-select: text; + border-top: 1px solid var(--color-border-light-2); + -webkit-user-select: text; + -moz-user-select: text; + -ms-user-select: text; + user-select: text; } a.polyglot-message-language.unclickable { - cursor: default; + cursor: default; } diff --git a/src/styles/_fonts.scss b/src/styles/_fonts.scss index 7878220..0a0977f 100644 --- a/src/styles/_fonts.scss +++ b/src/styles/_fonts.scss @@ -1,184 +1,184 @@ @font-face { - font-family: "ArCiela"; - src: url("../fonts/ArCiela.ttf"); + font-family: "ArCiela"; + src: url("../fonts/ArCiela.ttf"); } @font-face { - font-family: "Aztec"; - src: url("../fonts/Aztec.ttf"); + font-family: "Aztec"; + src: url("../fonts/Aztec.ttf"); } @font-face { - font-family: "Barazhad"; - src: url("../fonts/Barazhad.otf"); + font-family: "Barazhad"; + src: url("../fonts/Barazhad.otf"); } @font-face { - font-family: "Celestial"; - src: url("../fonts/Celestial.ttf"); + font-family: "Celestial"; + src: url("../fonts/Celestial.ttf"); } @font-face { - font-family: "Daedra"; - src: url("../fonts/Daedra.otf"); + font-family: "Daedra"; + src: url("../fonts/Daedra.otf"); } @font-face { - font-family: "DarkEldar"; - src: url("../fonts/DarkEldar.ttf"); + font-family: "DarkEldar"; + src: url("../fonts/DarkEldar.ttf"); } @font-face { - font-family: "Davek"; - src: url("../fonts/Davek.otf"); + font-family: "Davek"; + src: url("../fonts/Davek.otf"); } @font-face { - font-family: "Dethek"; - src: url("../fonts/Dethek.otf"); + font-family: "Dethek"; + src: url("../fonts/Dethek.otf"); } @font-face { - font-family: "DragonAlphabet"; - src: url("../fonts/dragon_alphabet.ttf"); + font-family: "DragonAlphabet"; + src: url("../fonts/dragon_alphabet.ttf"); } @font-face { - font-family: "ElderFuthark"; - src: url("../fonts/ElderFutharkFS.ttf"); + font-family: "ElderFuthark"; + src: url("../fonts/ElderFutharkFS.ttf"); } @font-face { - font-family: "Eltharin"; - src: url("../fonts/Eltharin.ttf"); + font-family: "Eltharin"; + src: url("../fonts/Eltharin.ttf"); } @font-face { - font-family: "Espruar"; - src: url("../fonts/Espruar.otf"); + font-family: "Espruar"; + src: url("../fonts/Espruar.otf"); } @font-face { - font-family: "Floki"; - src: url("../fonts/Floki.ttf"); + font-family: "Floki"; + src: url("../fonts/Floki.ttf"); } @font-face { - font-family: "FingerAlphabet"; - src: url("../fonts/FingerAlphabet.ttf"); + font-family: "FingerAlphabet"; + src: url("../fonts/FingerAlphabet.ttf"); } @font-face { - font-family: "HighDrowic"; - src: url("../fonts/HighDrowic.otf"); + font-family: "HighDrowic"; + src: url("../fonts/HighDrowic.otf"); } @font-face { - font-family: "HighschoolRunes"; - src: url("../fonts/HighschoolRunes.ttf"); + font-family: "HighschoolRunes"; + src: url("../fonts/HighschoolRunes.ttf"); } @font-face { - font-family: "Infernal"; - src: url("../fonts/Infernal.ttf"); + font-family: "Infernal"; + src: url("../fonts/Infernal.ttf"); } @font-face { - font-family: "Iokharic"; - src: url("../fonts/Iokharic.otf"); + font-family: "Iokharic"; + src: url("../fonts/Iokharic.otf"); } @font-face { - font-family: "JungleSlang"; - src: url("../fonts/JungleSlang.ttf"); + font-family: "JungleSlang"; + src: url("../fonts/JungleSlang.ttf"); } @font-face { - font-family: "Kargi"; - src: url("../fonts/Kargi.ttf"); + font-family: "Kargi"; + src: url("../fonts/Kargi.ttf"); } @font-face { - font-family: "KremlinPremier"; - src: url("../fonts/KremlinPremier.ttf"); + font-family: "KremlinPremier"; + src: url("../fonts/KremlinPremier.ttf"); } @font-face { - font-family: "MageScript"; - src: url("../fonts/MageScript.otf"); + font-family: "MageScript"; + src: url("../fonts/MageScript.otf"); } @font-face { - font-family: "MarasEye"; - src: url("../fonts/MarasEye.otf"); + font-family: "MarasEye"; + src: url("../fonts/MarasEye.otf"); } @font-face { - font-family: "MeroiticDemotic"; - src: url("../fonts/MeroiticDemotic.ttf"); + font-family: "MeroiticDemotic"; + src: url("../fonts/MeroiticDemotic.ttf"); } @font-face { - font-family: "MiroslavNormal"; - src: url("../fonts/MiroslavNormal.ttf"); + font-family: "MiroslavNormal"; + src: url("../fonts/MiroslavNormal.ttf"); } @font-face { - font-family: "MusiQwik"; - src: url("../fonts/MusiQwik.ttf"); + font-family: "MusiQwik"; + src: url("../fonts/MusiQwik.ttf"); } @font-face { - font-family: "NyStormning"; - src: url("../fonts/NyStormning.otf"); + font-family: "NyStormning"; + src: url("../fonts/NyStormning.otf"); } @font-face { - font-family: "OldeEnglish"; - src: url("../fonts/OldeEnglish.ttf"); + font-family: "OldeEnglish"; + src: url("../fonts/OldeEnglish.ttf"); } @font-face { - font-family: "OldeEspruar"; - src: url("../fonts/OldeEspruar.otf"); + font-family: "OldeEspruar"; + src: url("../fonts/OldeEspruar.otf"); } @font-face { - font-family: "OldeThorass"; - src: url("../fonts/OldeThorass.otf"); + font-family: "OldeThorass"; + src: url("../fonts/OldeThorass.otf"); } @font-face { - font-family: "Ophidian"; - src: url("../fonts/Ophidian.otf"); + font-family: "Ophidian"; + src: url("../fonts/Ophidian.otf"); } @font-face { - font-family: "Pulsian"; - src: url("../fonts/Pulsian.ttf"); + font-family: "Pulsian"; + src: url("../fonts/Pulsian.ttf"); } @font-face { - font-family: "Oriental"; - src: url("../fonts/Oriental.ttf"); + font-family: "Oriental"; + src: url("../fonts/Oriental.ttf"); } @font-face { - font-family: "OrkGlyphs"; - src: url("../fonts/OrkGlyphs.ttf"); + font-family: "OrkGlyphs"; + src: url("../fonts/OrkGlyphs.ttf"); } @font-face { - font-family: "Qijomi"; - src: url("../fonts/Qijomi.otf"); + font-family: "Qijomi"; + src: url("../fonts/Qijomi.otf"); } @font-face { - font-family: "Reanaarian"; - src: url("../fonts/Reanaarian.otf"); + font-family: "Reanaarian"; + src: url("../fonts/Reanaarian.otf"); } @font-face { - font-family: "Rellanic"; - src: url("../fonts/Rellanic.otf"); + font-family: "Rellanic"; + src: url("../fonts/Rellanic.otf"); } @font-face { - font-family: "Saurian"; - src: url("../fonts/Saurian.ttf"); + font-family: "Saurian"; + src: url("../fonts/Saurian.ttf"); } @font-face { - font-family: "ScrapbookChinese"; - src: url("../fonts/ScrapbookChinese.ttf"); + font-family: "ScrapbookChinese"; + src: url("../fonts/ScrapbookChinese.ttf"); } @font-face { - font-family: "Semphari"; - src: url("../fonts/Semphari.otf"); + font-family: "Semphari"; + src: url("../fonts/Semphari.otf"); } @font-face { - font-family: "Skaven"; - src: url("../fonts/Skaven.ttf"); + font-family: "Skaven"; + src: url("../fonts/Skaven.ttf"); } @font-face { - font-family: "Tengwar"; - src: url("../fonts/Tengwar.ttf"); + font-family: "Tengwar"; + src: url("../fonts/Tengwar.ttf"); } @font-face { - font-family: "Thassilonian"; - src: url("../fonts/Thassilonian.ttf"); + font-family: "Thassilonian"; + src: url("../fonts/Thassilonian.ttf"); } @font-face { - font-family: "Thorass"; - src: url("../fonts/Thorass.otf"); + font-family: "Thorass"; + src: url("../fonts/Thorass.otf"); } @font-face { - font-family: "Tuzluca"; - src: url("../fonts/Tuzluca.ttf"); + font-family: "Tuzluca"; + src: url("../fonts/Tuzluca.ttf"); } @font-face { - font-family: "Valmaric"; - src: url("../fonts/Valmaric.ttf"); + font-family: "Valmaric"; + src: url("../fonts/Valmaric.ttf"); } diff --git a/src/styles/_init.scss b/src/styles/_init.scss index 7fd1d71..629a570 100644 --- a/src/styles/_init.scss +++ b/src/styles/_init.scss @@ -2,13 +2,7 @@ $color_1: #e2e2e2; $color_2: fieldtext; $color_3: red; $font-family_1: var(--polyglot-chat-bubble-font); -$background-color_1: rgba( - var(--polyglot-journal-color), - var(--polyglot-journal-opacity) -); -$background-color_2: rgba( - var(--polyglot-journal-color-temp), - var(--polyglot-journal-opacity-temp) -); +$background-color_1: rgba(var(--polyglot-journal-color), var(--polyglot-journal-opacity)); +$background-color_2: rgba(var(--polyglot-journal-color-temp), var(--polyglot-journal-opacity-temp)); $background-color_3: rgba(255, 255, 255, 0.4); $border-color_1: fieldtext transparent transparent transparent; diff --git a/src/styles/_journal.scss b/src/styles/_journal.scss index 15fa8a0..0b797ab 100644 --- a/src/styles/_journal.scss +++ b/src/styles/_journal.scss @@ -1,7 +1,7 @@ &-journal { - background-color: $background-color_1; + background-color: $background-color_1; - &-temp { - background-color: $background-color_2; - } + &-temp { + background-color: $background-color_2; + } } diff --git a/src/styles/_language-selector.scss b/src/styles/_language-selector.scss index fb24cd1..fa682aa 100644 --- a/src/styles/_language-selector.scss +++ b/src/styles/_language-selector.scss @@ -1,74 +1,74 @@ &.polyglot-lang-select { - flex: 0 0 28px; - margin: 0 6px; - align-items: center; - input { - margin-left: 0; - &:checked { - accent-color: rgb(255, 255, 245); - } - } - label { - flex: 0; - } - select { - height: 24px; - margin-left: 6px; - background: rgba(255, 255, 245, 0.8); - } - > span.select2-container { - margin-left: 6px; - } - span.select2-selection { - background: rgba(255, 255, 245, 0.8); - height: 24px; - border: 1px solid var(--color-border-light-tertiary); - border-radius: 3px; - cursor: default; - } - .select2 { - &-container--default { - .select2-selection--single { - .select2-selection__rendered { - max-height: 24px; - line-height: 24px; - color: $color_2; - } - .select2-selection__arrow { - height: 22px; - b { - border-color: $border-color_1; - } - } - } - } - &-dropdown.polyglot-language { - background: rgb(255, 255, 245); - } - &-results__option { - .tags { - margin: 0; - } - .tags.paizo-style { - padding: 0; - max-width: fit-content; - .tag { - border: 0; - } - } - } - } + flex: 0 0 28px; + margin: 0 6px; + align-items: center; + input { + margin-left: 0; + &:checked { + accent-color: rgb(255, 255, 245); + } + } + label { + flex: 0; + } + select { + height: 24px; + margin-left: 6px; + background: rgba(255, 255, 245, 0.8); + } + > span.select2-container { + margin-left: 6px; + } + span.select2-selection { + background: rgba(255, 255, 245, 0.8); + height: 24px; + border: 1px solid var(--color-border-light-tertiary); + border-radius: 3px; + cursor: default; + } + .select2 { + &-container--default { + .select2-selection--single { + .select2-selection__rendered { + max-height: 24px; + line-height: 24px; + color: $color_2; + } + .select2-selection__arrow { + height: 22px; + b { + border-color: $border-color_1; + } + } + } + } + &-dropdown.polyglot-language { + background: rgb(255, 255, 245); + } + &-results__option { + .tags { + margin: 0; + } + .tags.paizo-style { + padding: 0; + max-width: fit-content; + .tag { + border: 0; + } + } + } + } } &.polyglot-user-list { - display: inline-flex; - max-width: max-content; - margin: auto; - flex-wrap: wrap; - div { - width: 10px; - height: 10px; - border-radius: 50%; - margin: 1px 2px; - } + display: inline-flex; + max-width: max-content; + margin: auto; + flex-wrap: wrap; + div { + width: 10px; + height: 10px; + border-radius: 50%; + margin: 1px 2px; + } } diff --git a/src/styles/_system-specific.scss b/src/styles/_system-specific.scss index 3420713..02c7127 100644 --- a/src/styles/_system-specific.scss +++ b/src/styles/_system-specific.scss @@ -1,8 +1,8 @@ &.wfrp4e { - select { - color: $color_1; - option { - color: $color_2; - } - } + select { + color: $color_1; + option { + color: $color_2; + } + } } diff --git a/src/styles/forms/_common.scss b/src/styles/forms/_common.scss index 903e787..729f1ef 100644 --- a/src/styles/forms/_common.scss +++ b/src/styles/forms/_common.scss @@ -1,21 +1,21 @@ & { - .polyglot-languages-list { - list-style: none; - padding: 0; + .polyglot-languages-list { + list-style: none; + padding: 0; - li { - &.flexrow { - flex-wrap: nowrap; - } - } - } + li { + &.flexrow { + flex-wrap: nowrap; + } + } + } - input.selectatr[type="number"] { - width: 30px; - height: 100%; - background: none; - border: none; - border-radius: 0; - border-bottom: 1px solid var(--color-border-light-tertiary); - } + input.selectatr[type="number"] { + width: 30px; + height: 100%; + background: none; + border: none; + border-radius: 0; + border-bottom: 1px solid var(--color-border-light-tertiary); + } } diff --git a/src/styles/forms/_font-settings.scss b/src/styles/forms/_font-settings.scss index 63fa3ae..cfa156a 100644 --- a/src/styles/forms/_font-settings.scss +++ b/src/styles/forms/_font-settings.scss @@ -1,42 +1,42 @@ &.polyglot-font-settings { - min-height: 255px; - min-width: 780px; + min-height: 255px; + min-width: 780px; - .polyglot-alphabet { - margin: auto; - } - .font-name { - flex: 0 0 150px; - margin: auto; - } + .polyglot-alphabet { + margin: auto; + } + .font-name { + flex: 0 0 150px; + margin: auto; + } - .window-content { - padding: 0; - } - form { - height: 100%; - section { - padding: 1rem; - overflow: hidden auto; - } - footer { - margin: 1rem; - flex: 0; - } - } - .polyglot-languages-list { - margin: 0; + .window-content { + padding: 0; + } + form { + height: 100%; + section { + padding: 1rem; + overflow: hidden auto; + } + footer { + margin: 1rem; + flex: 0; + } + } + .polyglot-languages-list { + margin: 0; - li { - .font-name { - flex: 0 0 150px; - margin: auto; - } - .fontSize { - flex: 0 0 90px; - text-align: center; - margin: auto; - } - } - } + li { + .font-name { + flex: 0 0 150px; + margin: auto; + } + .fontSize { + flex: 0 0 90px; + text-align: center; + margin: auto; + } + } + } } diff --git a/src/styles/forms/_general-settings.scss b/src/styles/forms/_general-settings.scss index 33e38ef..bc1530f 100644 --- a/src/styles/forms/_general-settings.scss +++ b/src/styles/forms/_general-settings.scss @@ -1,13 +1,13 @@ &.polyglot-general-settings { - .tab { - .form-group { - textarea { - resize: vertical; - min-height: 57px; - } - select[name="allowOOC"] { - flex: 1; - } - } - } + .tab { + .form-group { + textarea { + resize: vertical; + min-height: 57px; + } + select[name="allowOOC"] { + flex: 1; + } + } + } } diff --git a/src/styles/forms/_language-settings.scss b/src/styles/forms/_language-settings.scss index f93ea2e..5fd4339 100644 --- a/src/styles/forms/_language-settings.scss +++ b/src/styles/forms/_language-settings.scss @@ -1,33 +1,33 @@ &.polyglot-language-settings { - min-height: 265px; - min-width: 600px; + min-height: 265px; + min-width: 600px; - .font-name { - text-transform: capitalize; - } - .selectatr { - text-transform: capitalize; - } - .window-content { - padding: 0; - } - form { - height: 100%; - section { - padding: 1rem; - overflow: hidden auto; - } - footer { - margin: 1rem; - flex: 0; - } - } + .font-name { + text-transform: capitalize; + } + .selectatr { + text-transform: capitalize; + } + .window-content { + padding: 0; + } + form { + height: 100%; + section { + padding: 1rem; + overflow: hidden auto; + } + footer { + margin: 1rem; + flex: 0; + } + } - .polyglot-languages-warn { - font-weight: bold; - color: $color_3; - text-align: center; - margin-bottom: 0.5em; - display: none; - } + .polyglot-languages-warn { + font-weight: bold; + color: $color_3; + text-align: center; + margin-bottom: 0.5em; + display: none; + } } diff --git a/src/styles/polyglot.scss b/src/styles/polyglot.scss index cc18fa9..36c620b 100644 --- a/src/styles/polyglot.scss +++ b/src/styles/polyglot.scss @@ -3,19 +3,19 @@ @import "chat"; :root { - --polyglot-journal-color: 255, 180, 0; - --polyglot-journal-opacity: 0.25; - --polyglot-journal-color-temp: 255, 180, 0; - --polyglot-journal-opacity-temp: 0.25; + --polyglot-journal-color: 255, 180, 0; + --polyglot-journal-opacity: 0.25; + --polyglot-journal-color-temp: 255, 180, 0; + --polyglot-journal-opacity-temp: 0.25; } .polyglot { - .polyglot-chat-bubble { - font-family: $font-family_1; - } + .polyglot-chat-bubble { + font-family: $font-family_1; + } - @import "journal"; - @import "forms"; - @import "language-selector"; - @import "system-specific"; + @import "journal"; + @import "forms"; + @import "language-selector"; + @import "system-specific"; }