Skip to content

Commit

Permalink
Merge branch '4.3-dev' into 4.2-phpcs-phpversion
Browse files Browse the repository at this point in the history
  • Loading branch information
Hackwar committed Sep 24, 2022
2 parents e3f3a73 + f19fa75 commit 6bd0afa
Show file tree
Hide file tree
Showing 22 changed files with 203 additions and 619 deletions.
6 changes: 5 additions & 1 deletion build/build-modules-js/init/patches.es6.js
Expand Up @@ -27,7 +27,11 @@ module.exports.patchPackages = async (options) => {
dest = join(mediaVendorPath, 'short-and-sweet');
const shortandsweetPath = `${dest}/${options.settings.vendors['short-and-sweet'].js['dist/short-and-sweet.min.js']}`;
let ShortandsweetJs = await readFile(shortandsweetPath, { encoding: 'utf8' });
ShortandsweetJs = ShortandsweetJs.concat('shortAndSweet(\'textarea.charcount\', {counterClassName: \'small text-muted\'});');
ShortandsweetJs = ShortandsweetJs.concat(`
shortAndSweet('textarea.charcount,input.charcount', {counterClassName: 'small text-muted'});
/** Repeatable */
document.addEventListener("joomla:updated", (event) => [].slice.call(event.target.querySelectorAll('textarea.charcount,input.charcount')).map((el) => shortAndSweet(el, {counterClassName: 'small text-muted'})));
`);
await writeFile(shortandsweetPath, ShortandsweetJs, { encoding: 'utf8', mode: 0o644 });

// Patch the Font Awesome math.div sass deprecations
Expand Down
6 changes: 5 additions & 1 deletion build/build-modules-js/stylesheets/handle-scss.es6.js
@@ -1,5 +1,6 @@
const Autoprefixer = require('autoprefixer');
const CssNano = require('cssnano');
const rtlcss = require('rtlcss');
const { writeFile } = require('fs').promises;
const { ensureDir } = require('fs-extra');
const { dirname, sep } = require('path');
Expand All @@ -20,8 +21,11 @@ module.exports.handleScssFile = async (file) => {
process.exit(1);
}

const plugins = [Autoprefixer];
if (cssFile.endsWith('-rtl.css')) plugins.push(rtlcss);

// Auto prefixing
const cleaner = Postcss([Autoprefixer()]);
const cleaner = Postcss(plugins);
const res = await cleaner.process(compiled.css.toString(), { from: undefined });

// Ensure the folder exists or create it
Expand Down
Expand Up @@ -58,10 +58,6 @@
object-fit: contain;
object-position: left center;

[dir=rtl] & {
object-position: right center;
}

&.logo-collapsed {
display: none;
}
Expand Down
Expand Up @@ -19,24 +19,10 @@
text-decoration: none;

&::before {
margin-right: .5rem;
margin-inline-end: .5rem;
font-family: "Font Awesome 5 Free";
font-weight: 900;
content: "\f054";

[dir="rtl"] & {
margin-right: 0;
content: none;
}
}

&::after {
[dir="rtl"] & {
margin-inline-end: .5rem;
font-family: "Font Awesome 5 Free";
font-weight: 900;
content: "\f053";
}
content: "\f054" #{"/*!rtl:\"\f053\"*/"};
}
}

Expand Down
Expand Up @@ -143,14 +143,7 @@
width: 2rem;
font-family: "Font Awesome 5 Free";
font-weight: 900;

[dir="ltr"] & {
content: "\f054";
}

[dir="rtl"] & {
content: "\f053";
}
content: "\f054" #{"/*!rtl:\"\f053\"*/"};
}
}

Expand Down Expand Up @@ -256,11 +249,6 @@
z-index: $zindex-mobile-toggle;
padding: 10px 15px;

[dir="rtl"] & {
right: auto;
left: 0;
}

&:focus {
box-shadow: none;
}
Expand Down
Expand Up @@ -123,14 +123,7 @@
.btn-group:not(:last-child) > .dropdown-toggle-split {
order: 1;
margin-inline-start: -$border-radius;

[dir="ltr"] & {
border-radius: 0 $border-radius $border-radius 0;
}

[dir="rtl"] & {
border-radius: $border-radius 0 0 $border-radius;
}
border-radius: 0 $border-radius $border-radius 0;
}

.dropdown-menu joomla-toolbar-button,
Expand Down
@@ -1,47 +1,2 @@
// This file is a placeholder for the rtl template
@import "template";
@import "vendor/bootstrap/bootstrap-rtl";

// Global
dl,
ol,
ul {
padding-right: 0;
}

// Redirect urls fields
#jform_new_url,
#jform_old_url,
#new_url {
text-align: left;
}

// Database prefix
#jform_dbprefix {
text-align: right;
direction: ltr;
}

.input-group > .form-control:not(:last-child),
.input-group > .form-select:not(:last-child) {
@include border-start-radius(0);
@include border-end-radius($border-radius);
}

.btn-group > .btn:first-child:not(.dropdown-toggle) {
@include border-end-radius($border-radius);
}

.btn-group > .btn:not(:last-child):not(.dropdown-toggle),
.btn-group > .btn-group:not(:last-child) > .btn {
@include border-start-radius(0);
margin-left: -1px;
}

.btn-group > .btn:last-child:not(.dropdown-toggle) {
@include border-start-radius($border-radius);
}

.btn-group > .btn:not(:first-child),
.btn-group > .btn-group:not(:first-child) {
@include border-end-radius(0);
}

This file was deleted.

Expand Up @@ -7,16 +7,10 @@
.form-select {
max-width: $input-max-width;
cursor: pointer;
background: $form-select-background;
background: $form-select-background #{"/* rtl:"}$form-select-background-rtl#{"*/"};;
background-color: $form-select-bg;
border: $input-border;

[dir=rtl] & {
padding: $form-select-padding-y $form-select-padding-x $form-select-padding-y ($form-select-padding-x + $form-select-indicator-padding);
background: $form-select-background-rtl;
background-color: $form-select-bg;
}

&[multiple] {
padding: 0;
background-color: var(--white-offset);
Expand Down
Expand Up @@ -4,7 +4,7 @@
margin-top: $cassiopeia-grid-gutter;
color: $white;
background-color: var(--cassiopeia-color-primary);
background-image: $cassiopeia-header-grad;
background-image: $cassiopeia-header-grad #{"/* rtl:"}$cassiopeia-header-grad-rtl #{"*/"};

.grid-child {
align-items: center;
Expand All @@ -16,10 +16,6 @@
color: currentColor;
}

[dir=rtl] & {
background-image: $cassiopeia-header-grad-rtl;
}

.mod-menu {
position: relative;
}
Expand Down
Expand Up @@ -12,7 +12,3 @@
border-radius: .25rem;
}

[dir="rtl"] .btn.jmodedit {
right: auto;
left: 0;
}

0 comments on commit 6bd0afa

Please sign in to comment.