Skip to content

Commit 9be76fa

Browse files
committed
Move inline CSS Variables to end of file
1 parent 660204f commit 9be76fa

File tree

3 files changed

+14
-17
lines changed

3 files changed

+14
-17
lines changed

lib/index.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -306,7 +306,6 @@ Builder.prototype.build = function(options) {
306306
}));
307307
const varsOverride = oVariableCollector.getAllVariables();
308308
const cssVariablesSource = oCSSVariablesCollector.toLessVariables(varsOverride);
309-
// eslint-disable-next-line no-unused-vars
310309
const cssVariablesOnly = oCSSVariablesCollector.getCssVariablesDeclaration();
311310

312311
let cssSkeletonRtl;
@@ -407,9 +406,9 @@ Builder.prototype.build = function(options) {
407406
--sapThemeMetaData-UI5-${libraryNameDashed}: ${metadataJson};
408407
}
409408
`;
410-
result.css = additionalVariables + result.cssVariables + "\n" + result.css;
409+
result.css += additionalVariables + result.cssVariables;
411410
if (options.rtl) {
412-
result.cssRtl = additionalVariables + result.cssVariables + "\n" + result.cssRtl;
411+
result.cssRtl += additionalVariables + result.cssVariables;
413412
}
414413
}
415414

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
.myOtherUiLibRule1 {
2+
color: #fefefe;
3+
}
4+
.myOtherUiLibRule2 {
5+
padding: 1px 4px 3px 2px;
6+
}
17

28
:root {
39
--sapUiTheme-my-other-ui-lib: true;
@@ -7,10 +13,3 @@
713
--_my_other_ui_lib_MyControl_color1: var(--color1);
814
--_my_other_ui_lib_MyOtherControl_color1: var(--color1);
915
}
10-
11-
.myOtherUiLibRule1 {
12-
color: #fefefe;
13-
}
14-
.myOtherUiLibRule2 {
15-
padding: 1px 4px 3px 2px;
16-
}
Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
.myOtherUiLibRule1 {
2+
color: #fefefe;
3+
}
4+
.myOtherUiLibRule2 {
5+
padding: 1px 2px 3px 4px;
6+
}
17

28
:root {
39
--sapUiTheme-my-other-ui-lib: true;
@@ -7,10 +13,3 @@
713
--_my_other_ui_lib_MyControl_color1: var(--color1);
814
--_my_other_ui_lib_MyOtherControl_color1: var(--color1);
915
}
10-
11-
.myOtherUiLibRule1 {
12-
color: #fefefe;
13-
}
14-
.myOtherUiLibRule2 {
15-
padding: 1px 2px 3px 4px;
16-
}

0 commit comments

Comments
 (0)