Skip to content
Advertisement

Tag: material-ui

Import SASS variables into Material UI theme with NextJS

In my project I have the following files: materialTheme.ts palette.scss I want to de-duplicate these files. I thought I could import the variables from palette.scss into materialTheme.ts but Next.JS throws an error about only importing global CSS into _app.tsx materialTheme.ts (not working) Is there any way I can make NextJS ignore this error just for materialTheme.ts and correctly import the

responsive buttongroup buttons in material ui + reactjs app

How to achieve responsive ButtonGroup Buttons? I found some information that material-ui’s ButtonGroup can use an attribute called “Orientation” but I don’t understand how to use it with media queries which means changing its orientation in real-time when the device has a narrow width etc. I’m new to this so bear with me. Answer First you need to specify the

Material-UI: How to add border in TreeView

Here, I have a code in React. I want to show dashed lines on the left of the tree. How can I do that? I need something like this: And, I want to merge the style of TreeView with this code: ] Now, I want TreeView to not show borderBottom at OrganizationalUnitName as ‘A’,’C’ and ‘D’. Because they will be

Material-UI Select doesn’t update after onChange

I’ve seen this problem about all around the web but nothing could come short of giving me a valid explanation. I’m using Material-UI Select and the good ol’ setState(…) from React (not hooks though) My component is composed essentially of those lines : And my problem is that my Select component dosen’t update its value after selecting another option. So

Why cant I export and use my custom js styles?

This my main class And this is my style class called FoodStyles.js They both are in the same folder but still styles cannot be accessed Answer This could be the solution to your problem: (You need destructuring as done in line 7 for your styles to be used in your file.) With React, which fully embraces the ES6 syntax, destructuring

Advertisement