Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generated CSS works running with npm, but not embedded in Magento #40

Open
rafabandero opened this issue Sep 27, 2023 · 0 comments
Open

Comments

@rafabandero
Copy link

I've changed primary background colors in tailwind.config.js and it works properly while runing the app through npm, but not embedded in Magento.

Preconditions (*)

  1. Magento 2.4.6-p2
  2. hyva-themes/magento2-react-checkout 1.1.3
  3. node v16.20.2 and npm 8.19.4

Steps to reproduce (*)

  1. Change primary background color in reactapp/tailwind.config.js
      backgroundColor: {
        primary: {
          lighter: '#e8697f',
          DEFAULT: '#ea0029',
          darker: '#a7001f',
        },
        secondary: {
          lighter: colors.blue['100'],
          DEFAULT: colors.blue['200'],
          darker: colors.blue['300'],
        },
        container: {
          lighter: '#ffffff',
          DEFAULT: '#fafafa',
          darker: '#f5f5f5',
        },
      },
  1. Execute npm install
  2. Execute npm run build
  3. In magento checkout the CSS changes doesn't get applied:

image

  1. Executing npm run start the changes works properly:

image

** I figured out that the new style classes I've included in reactapp/src/tailwindcss/components/theming.css are not accessible in Magento too. Tried to redeploy static content but nothing changes.

@rafabandero rafabandero changed the title Generated CSS works ruinning with npm, but not embedded in Magento Generated CSS works running with npm, but not embedded in Magento Sep 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant