Skip to content
Snippets Groups Projects

Hide contextual links on xb pages.

1 file
+ 2
1
Compare changes
  • Side-by-side
  • Inline
+ 2
1
@@ -13,6 +13,7 @@ const fullComponentDir = isSubtheme ? './components_combined/' : componentDir;
const baseOutDir = './dist/';
const cssHeader = '/**\n * This file was automatically generated. Please run `npm run dist` to update.\n */\n\n';
const cssFooter = '\nimg \{\n display: block;\n max-width: 100%;\n height: auto;\n\}\n\n';
const cssContextual = '\nbody.path-xb .contextual \{\n display: none;\n}\n\n';
// Get Mixin file paths.
const mixins = globSync(`00-base/mixins/**/*.scss`, { cwd: fullComponentDir });
@@ -30,7 +31,7 @@ const baseData = `
@import 'style.css_variables';
`;
const baseResult = sass.compileString(baseData, { loadPaths: [fullComponentDir] });
fs.writeFileSync(`${baseOutDir}/base.css`, cssHeader + baseResult.css);
fs.writeFileSync(`${baseOutDir}/base.css`, cssHeader + cssContextual + baseResult.css);
// Get component file paths.
const atoms = globSync(`01-atoms/**/*.scss`, { cwd: componentDir });
Loading