From a1a790e56e7def76c5a814c864d122c9e47d5128 Mon Sep 17 00:00:00 2001 From: muerwre Date: Sun, 25 Aug 2019 20:59:10 +0700 Subject: [PATCH] css hashing --- src/components/node/NodePanel/styles.scss | 11 +++++++---- webpack.config.js | 7 +++++-- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/src/components/node/NodePanel/styles.scss b/src/components/node/NodePanel/styles.scss index e16e8a1a..b1632ff8 100644 --- a/src/components/node/NodePanel/styles.scss +++ b/src/components/node/NodePanel/styles.scss @@ -1,5 +1,4 @@ .wrap { - // background: $node_title_background; background: $node_bg; padding: $gap; box-sizing: border-box; @@ -7,9 +6,9 @@ align-items: center; justify-content: stretch; border-radius: $radius $radius 0 0; - //box-shadow: transparentize(white, 0.97) 0 1px, inset transparentize(white, 0.97) 0 1px; position: relative; margin-top: -$radius; + z-index: 3; } .title { @@ -49,8 +48,12 @@ & > * { margin: 0 $gap; - &:first-child { margin-left: 0; } - &:last-child { margin-right: 0; } + &:first-child { + margin-left: 0; + } + &:last-child { + margin-right: 0; + } } //height: 54px; //border-radius: $radius $radius 0 0; diff --git a/webpack.config.js b/webpack.config.js index 0ac4dece..baba5ce5 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -16,7 +16,7 @@ const htmlPlugin = new HtmlWebPackPlugin({ const miniCssExractPlugin = new MiniCssExtractPlugin({ filename: '[name].css', - chunkFilename: '[id].css' + chunkFilename: '[id].css', }); const isDevelopment = process.env.NODE_ENV !== 'production'; @@ -54,7 +54,10 @@ module.exports = () => { { test: /\.less$/, use: [ - { loader: isDevelopment ? 'style-loader' : MiniCssExtractPlugin.loader }, + isDevelopment + ? { loader: 'style-loader' } + : { loader: MiniCssExtractPlugin.loader, options: { filename: '[name].[contenthash].css' } }, + // { loader: isDevelopment ? 'style-loader' : MiniCssExtractPlugin.loader }, // { loader: 'css-loader' }, { loader: 'css-loader',