hc-oss / react-multi-select-component

Lightweight (~5KB gzipped) multiple selection dropdown component

Home Page:https://codesandbox.io/s/react-multi-select-example-uqtgs

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Component styles fail in Docker, works fine locally

donaldev opened this issue · comments

Describe the bug
Component styling fails when serving a Docker build - works fine locally.
Screenshots show the issue

  • locally the CSS variables are in kebab-case
  • in production, the CSS variables are in camelCase meaning the component can't find the correct styles to apply

Sandbox / Git Repo

Can't reproduce as it only seems to happen in Docker - build steps below

FROM node:14.15.3

EXPOSE 3000

RUN npm run build

# install production file server
RUN npm install -g serve

# start the server at port 3000 by default
CMD ["serve", "-s", "build"]

Expected behavior
I expected Docker to show the same component styling as locally

Screenshots

Localhost

UI:

https://user-images.githubusercontent.com/30258920/184251617-5dc53f79-4c91-433f-9365-cb52a4baa903.jpg

Styles:

https://user-images.githubusercontent.com/30258920/184251777-f195a2c5-6997-44c2-b2bb-844c887b8e0c.jpg

Docker

UI:

https://user-images.githubusercontent.com/30258920/184251861-afef0300-98ee-4c0c-ba15-3b74ccfd9dc7.jpg

Styles:

https://user-images.githubusercontent.com/30258920/184251982-081d43e6-f409-4ea8-8245-987824c8f5d9.jpg

Desktop (please complete the following information):

  • OS: MacOS
  • Browser : Chrome & Safari
  • Version : Google Chrome | 104.0.5112.79 (Official Build)
  • NODE: node:14.15.3

@donaldev looks like you are using old version of react-multi-select-component since .go classes are generated by goober which we were using in v3.x please update component to latest v4.x