From 15b78c5481c87dba66f47676f6843bfb4d77a113 Mon Sep 17 00:00:00 2001 From: netpro2k <netpro2k@gmail.com> Date: Fri, 30 Mar 2018 23:39:53 -0700 Subject: [PATCH] Changes from master broke css for 2d hud, fixing --- .../stylesheets}/2d-hud.css | 10 +++++----- src/react-components/2d-hud.js | 2 +- webpack.config.js | 3 ++- 3 files changed, 8 insertions(+), 7 deletions(-) rename src/{react-components => assets/stylesheets}/2d-hud.css (81%) diff --git a/src/react-components/2d-hud.css b/src/assets/stylesheets/2d-hud.css similarity index 81% rename from src/react-components/2d-hud.css rename to src/assets/stylesheets/2d-hud.css index 15f8a98eb..a8324a5bb 100644 --- a/src/react-components/2d-hud.css +++ b/src/assets/stylesheets/2d-hud.css @@ -30,16 +30,16 @@ width: 48px; height: 48px; background-size: 100%; - background-image: url(../assets/hud/avatar.jpg); + background-image: url(../hud/avatar.jpg); } :local(.mic) { display: flex; width: 48px; height: 48px; - -webkit-mask: url(../assets/hud/unmuted.png); + -webkit-mask: url(../hud/unmuted.png); -webkit-mask-size: 48px; - mask: url(../assets/hud/unmuted.png); + mask: url(../hud/unmuted.png); mask-size: 48px; background-color: white; cursor: pointer; @@ -58,9 +58,9 @@ } :local(.mic.muted) { - -webkit-mask: url(../assets/hud/muted.png); + -webkit-mask: url(../hud/muted.png); -webkit-mask-size: 48px; - mask: url(../assets/hud/muted.png); + mask: url(../hud/muted.png); mask-size: 48px; } diff --git a/src/react-components/2d-hud.js b/src/react-components/2d-hud.js index fda3ae06a..73c23c82f 100644 --- a/src/react-components/2d-hud.js +++ b/src/react-components/2d-hud.js @@ -2,7 +2,7 @@ import React, { Component } from "react"; import PropTypes from "prop-types"; import cx from "classnames"; -import styles from "./2d-hud.css"; +import styles from "../assets/stylesheets/2d-hud.css"; const TwoDHUD = ({ name, muted, onToggleMute }) => ( <div className={styles.container}> diff --git a/webpack.config.js b/webpack.config.js index 1fdc22406..4cf14964c 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -213,7 +213,8 @@ const config = { inject: "head" }), // Extract required css and add a content hash. - new ExtractTextPlugin("assets/stylesheets/[name]-[contenthash].css", { + new ExtractTextPlugin({ + filename: "assets/stylesheets/[name]-[contenthash].css", disable: process.env.NODE_ENV !== "production" }), // Transform the output of the html-loader using _.template -- GitLab