From 656b00134edf5df6d7de6c6350f3ccd8f31a8afd Mon Sep 17 00:00:00 2001 From: Fomafix Date: Fri, 4 Oct 2024 08:24:01 +0000 Subject: [PATCH] Use - instead of _ in LESS file names as language code Change-Id: Ifcd6d8f927a651d13e8a01ac3995210292551bc8 --- ...xt.cite.style.crh_latn.less => ext.cite.style.crh-latn.less} | 0 ...{ext.cite.style.kk_arab.less => ext.cite.style.kk-arab.less} | 0 ...{ext.cite.style.kk_cyrl.less => ext.cite.style.kk-cyrl.less} | 0 ...{ext.cite.style.ks_arab.less => ext.cite.style.ks-arab.less} | 0 ...{ext.cite.style.ks_deva.less => ext.cite.style.ks-deva.less} | 0 ...{ext.cite.style.ku_arab.less => ext.cite.style.ku-arab.less} | 0 ...{ext.cite.style.ku_latn.less => ext.cite.style.ku-latn.less} | 0 .../{ext.cite.style.pt_br.less => ext.cite.style.pt-br.less} | 0 ...xt.cite.style.skr_arab.less => ext.cite.style.skr-arab.less} | 0 .../{ext.cite.style.sr_ec.less => ext.cite.style.sr-ec.less} | 0 .../{ext.cite.style.sr_el.less => ext.cite.style.sr-el.less} | 0 src/ResourceLoader/CiteCSSFileModule.php | 2 +- 12 files changed, 1 insertion(+), 1 deletion(-) rename modules/parsoid-styles/{ext.cite.style.crh_latn.less => ext.cite.style.crh-latn.less} (100%) rename modules/parsoid-styles/{ext.cite.style.kk_arab.less => ext.cite.style.kk-arab.less} (100%) rename modules/parsoid-styles/{ext.cite.style.kk_cyrl.less => ext.cite.style.kk-cyrl.less} (100%) rename modules/parsoid-styles/{ext.cite.style.ks_arab.less => ext.cite.style.ks-arab.less} (100%) rename modules/parsoid-styles/{ext.cite.style.ks_deva.less => ext.cite.style.ks-deva.less} (100%) rename modules/parsoid-styles/{ext.cite.style.ku_arab.less => ext.cite.style.ku-arab.less} (100%) rename modules/parsoid-styles/{ext.cite.style.ku_latn.less => ext.cite.style.ku-latn.less} (100%) rename modules/parsoid-styles/{ext.cite.style.pt_br.less => ext.cite.style.pt-br.less} (100%) rename modules/parsoid-styles/{ext.cite.style.skr_arab.less => ext.cite.style.skr-arab.less} (100%) rename modules/parsoid-styles/{ext.cite.style.sr_ec.less => ext.cite.style.sr-ec.less} (100%) rename modules/parsoid-styles/{ext.cite.style.sr_el.less => ext.cite.style.sr-el.less} (100%) diff --git a/modules/parsoid-styles/ext.cite.style.crh_latn.less b/modules/parsoid-styles/ext.cite.style.crh-latn.less similarity index 100% rename from modules/parsoid-styles/ext.cite.style.crh_latn.less rename to modules/parsoid-styles/ext.cite.style.crh-latn.less diff --git a/modules/parsoid-styles/ext.cite.style.kk_arab.less b/modules/parsoid-styles/ext.cite.style.kk-arab.less similarity index 100% rename from modules/parsoid-styles/ext.cite.style.kk_arab.less rename to modules/parsoid-styles/ext.cite.style.kk-arab.less diff --git a/modules/parsoid-styles/ext.cite.style.kk_cyrl.less b/modules/parsoid-styles/ext.cite.style.kk-cyrl.less similarity index 100% rename from modules/parsoid-styles/ext.cite.style.kk_cyrl.less rename to modules/parsoid-styles/ext.cite.style.kk-cyrl.less diff --git a/modules/parsoid-styles/ext.cite.style.ks_arab.less b/modules/parsoid-styles/ext.cite.style.ks-arab.less similarity index 100% rename from modules/parsoid-styles/ext.cite.style.ks_arab.less rename to modules/parsoid-styles/ext.cite.style.ks-arab.less diff --git a/modules/parsoid-styles/ext.cite.style.ks_deva.less b/modules/parsoid-styles/ext.cite.style.ks-deva.less similarity index 100% rename from modules/parsoid-styles/ext.cite.style.ks_deva.less rename to modules/parsoid-styles/ext.cite.style.ks-deva.less diff --git a/modules/parsoid-styles/ext.cite.style.ku_arab.less b/modules/parsoid-styles/ext.cite.style.ku-arab.less similarity index 100% rename from modules/parsoid-styles/ext.cite.style.ku_arab.less rename to modules/parsoid-styles/ext.cite.style.ku-arab.less diff --git a/modules/parsoid-styles/ext.cite.style.ku_latn.less b/modules/parsoid-styles/ext.cite.style.ku-latn.less similarity index 100% rename from modules/parsoid-styles/ext.cite.style.ku_latn.less rename to modules/parsoid-styles/ext.cite.style.ku-latn.less diff --git a/modules/parsoid-styles/ext.cite.style.pt_br.less b/modules/parsoid-styles/ext.cite.style.pt-br.less similarity index 100% rename from modules/parsoid-styles/ext.cite.style.pt_br.less rename to modules/parsoid-styles/ext.cite.style.pt-br.less diff --git a/modules/parsoid-styles/ext.cite.style.skr_arab.less b/modules/parsoid-styles/ext.cite.style.skr-arab.less similarity index 100% rename from modules/parsoid-styles/ext.cite.style.skr_arab.less rename to modules/parsoid-styles/ext.cite.style.skr-arab.less diff --git a/modules/parsoid-styles/ext.cite.style.sr_ec.less b/modules/parsoid-styles/ext.cite.style.sr-ec.less similarity index 100% rename from modules/parsoid-styles/ext.cite.style.sr_ec.less rename to modules/parsoid-styles/ext.cite.style.sr-ec.less diff --git a/modules/parsoid-styles/ext.cite.style.sr_el.less b/modules/parsoid-styles/ext.cite.style.sr-el.less similarity index 100% rename from modules/parsoid-styles/ext.cite.style.sr_el.less rename to modules/parsoid-styles/ext.cite.style.sr-el.less diff --git a/src/ResourceLoader/CiteCSSFileModule.php b/src/ResourceLoader/CiteCSSFileModule.php index 1374c938b..d2bf6d163 100644 --- a/src/ResourceLoader/CiteCSSFileModule.php +++ b/src/ResourceLoader/CiteCSSFileModule.php @@ -27,7 +27,7 @@ class CiteCSSFileModule extends FileModule { // Get the content language code, and all the fallbacks. The first that // has a ext.cite.style..css file present will be used. foreach ( [ $contLang->getCode(), ...$contLang->getFallbackLanguages() ] as $lang ) { - $langStyleFile = 'ext.cite.style.' . strtr( $lang, '-', '_' ) . '.less'; + $langStyleFile = "ext.cite.style.$lang.less"; if ( file_exists( $this->getLocalPath( $langStyleFile ) ) ) { $this->styles[] = $langStyleFile; break;