Skip to main content
Filter by
Sorted by
Tagged with
1 vote
1 answer
71 views

I'm developing a web application using React and Next.js, and I'm using Material UI for my UI components. I have a component that renders a Material UI Card with custom styles via the sx prop. In my ...
E.Cogalan's user avatar
3 votes
0 answers
99 views

I need to style a fluent UI checkbox using the style props. However based on the documentation it is unclear how to style the checkbox differently in its checked vs unchecked state. I am able to set ...
Christopher Konopka's user avatar
0 votes
0 answers
55 views

Edit: add full html code <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" ...
신범기's user avatar
0 votes
1 answer
404 views

I’m migrating from Emotion to Vanilla Extract. I have a component which contains a third-party UI library component. This third-party component has a hardcoded class .ClassWhichICannotChange. In ...
Black Beard's user avatar
  • 1,656
1 vote
1 answer
1k views

The request to fetch the font file from the specified URL failed multiple times. Specific URL: https://fonts.gstatic.com/s/inter/v13/UcC73FwrK3iLTeHuS_fvQtMwCp50KnMa0ZL7W0Q5n-wU.woff2 and https://...
Nilima Mahadik's user avatar
1 vote
1 answer
124 views

I've some Arabic text in react native, and I want to make it justify (fill the width from both sides), but the last line be right aligned. When I set textAlign: "justify" style for <Text&...
famdude's user avatar
  • 147
-1 votes
1 answer
132 views

let's say we have a website with multiple pages and also a page for user account. the user has a setting in his panel to change the color/fontsize/style etc of certain parts in other pages of website ...
Pooria1998's user avatar
4 votes
1 answer
2k views

I'm using Next.js version 14 with app router alongside with Material-UI v5. Whenever I'm rendering Material-UI components in server pages components It's working just fine. The issue starts when I'm ...
Netanel Vaknin's user avatar
0 votes
2 answers
136 views

I'm looking for the answer to the question how should I use styles with conditional operators. What code example would be the best? Can we use non-CSS values such as undefined, null, false, etc.? ...
programmer's user avatar
0 votes
1 answer
54 views

I'm looking for the answer to the question how should I use conditional styles with conditional operators. What code example would be the best? Can we use non css values? margin: isOpen ? '10px' : ...
programmer's user avatar
8 votes
0 answers
2k views

I have been using emotion/css for my project and want to migrate to nextjs app router but have some questions regarding emotion/css server side rendering with app router. Nextjs documentation states ...
user3158803's user avatar
0 votes
1 answer
322 views

In StyleX, how to style a body? The body element that stays outside any React component, is usually styled using useEffect, but I can't figure out how to actually use that in StyleX. There's nothing ...
laggingreflex's user avatar
2 votes
1 answer
110 views

We are in a situation where we have to ship some of the global styles written with Lit tagged templates as plain css files. Basically converting the following: // global.ts import { css, unsafeCSS } ...
puter's user avatar
  • 301
0 votes
0 answers
50 views

I'm using CSS-in-JS (via JSS) in our application and we're having issues with render speeds when using dynamic values in our styles. I initially decided to use JSS because of the ability to pass in ...
SoooTired's user avatar
0 votes
2 answers
1k views

In the release build, Tauri does not render anything. After a bit of Googling, I found the same issue, but I am still confused about the right CSP configuration to set when using CSS-in-JS libraries ...
Nane's user avatar
  • 483
1 vote
1 answer
254 views

I tried applying StyleX to vite. So, I installed and applied the library called "vite-plugin-stylex": "^0.4.1". vite.config.ts import { defineConfig } from "vite" import ...
Ensnif's user avatar
  • 39
-1 votes
3 answers
827 views

I want to use StyleX in my new project, but I'm having some trouble trying to use it (with NextJS). I don't understand how to configure the "next.config.js" file (creating a "babel....
aBarl's user avatar
  • 13
-1 votes
1 answer
95 views

This was how I was importing Fontawesome icons: src/App.css @import "@fortawesome/fontawesome-free/css/all.css";` When I moved that @import to CSS-in-Js (emotion): src/App.js // JS: const ...
wyc's user avatar
  • 55.7k
0 votes
0 answers
77 views

I am working with a CSS layout where I have a tooltip element positioned above a dynamic width container (RateChart). Inside this container, there is a PercentMemory element represented by a thin ...
Beginner Professional's user avatar
1 vote
1 answer
1k views

I am using styled-components, prettier and stylelint. Here is my .stylelintrc.json: { "extends": [ "stylelint-config-standard", "stylelint-prettier", "...
Ilya Kruchinin's user avatar
1 vote
0 answers
90 views

import { x } from "@xstyled/styled-components"; import React, { ComponentProps } from "react" type WrongProps = ComponentProps<typeof x.div>; const App = () => { ...
wleklinski's user avatar
1 vote
0 answers
129 views

I've got a problem with the loading order in a NextJS app. We use Stitches CSS-in-JS, which provides globalCss() for loading global styles like resetters/normalizers and it gets invoked in _app.tsx. ...
Onkeltem's user avatar
  • 2,618
0 votes
1 answer
141 views

I'm using Kuma.js as my CSS in JS solution for Next JS 13. I'm trying to create a styled Header component using Kuma called HeaderWrapper. Here's my code: import { styled } from "@kuma-ui/core&...
Ethan's user avatar
  • 1,868
0 votes
1 answer
558 views

In a complicated aplication that was built on antd4, that has many different less files 100+, upgrading to antd5 do I have to update all the files to be using cssinjs or can I keep the old less files ...
Ivana Murray's user avatar
2 votes
2 answers
997 views

I just got a new work computer, and setting up the dev environment, I cannot seem to get my Intellisense to work while in a React.jsx file I'm using CSS-in-JS with NextJs styled JSX https://github.com/...
Barrard's user avatar
  • 2,062
6 votes
3 answers
5k views

The issue I am facing is that when I reload the page in Next.js while using Antd CSS, there is a delay in applying the CSS styles. In other words, the styles are not being applied immediately upon ...
moon's user avatar
  • 61
0 votes
2 answers
59 views

I am having array of data which I am maping using .map method. How can I remove duplicate code i.e. <a href={usp.url}> <div>{usp.text}</div> </a> Code can be found on code ...
MeAtWork's user avatar
1 vote
1 answer
2k views

I need to style Fluent UI checkbox and change checkmark color while it is in indeterminate state. I use Flueint UI 8.x. "dependencies": { "react": "16.8.6", &...
Sergiy Kostenko's user avatar
0 votes
1 answer
296 views

I wanna use @Property in emotion ,but cannot find something about this in document import styled from '@emotion/styled'; import React from 'react'; import demo from './demo_img.jpeg'; const ...
joey's user avatar
  • 41
0 votes
1 answer
126 views

Getting problem in flowing images from left to right using grid. Some images are not flowing from left to right as per number as shown in image (like 5th image should come before image 6. Same with ...
MeAtWork's user avatar
0 votes
1 answer
721 views

I am trying to override the style for the datapicker today and change the blue box around todays date to red. Inspecting the element I find the class to override is the following: :where(.css-dev-...
ask-N-answered's user avatar
1 vote
1 answer
1k views

I'm using Griffel https://griffel.js.org/ for the first time and I am struggling to achieve this simple thing. By default this button is hidden and when the user hover's over the parent I want to ...
sayayin's user avatar
  • 1,041
9 votes
2 answers
3k views

I want to customize the styles of some antd components written in cssinjs. I created a HOC component to access the theme and override some styles and call it after defining the providers import { ...
user2645494's user avatar
2 votes
1 answer
297 views

I am using csstype in a react component library. I want to add a hover effect, which is supported through simple pseudos. Unfortunately I cannot find any example of this being used and I can't get it ...
Richard George's user avatar
1 vote
1 answer
406 views

I want to change the color and background color of the Base Web Button component on button click using React. How can I change the styles of the button on button click? I tried to use $isSelected prop ...
Utku Demir's user avatar
12 votes
2 answers
4k views

I'm upgrading to antd v5 and i had some issues with keeping the variables overrides made from less files with v4 i have multiple less files inside src/theme one of them is with the following @import '...
Ilyas Ghomrani's user avatar
2 votes
1 answer
2k views

I have a style for a standard list export const useOverrides = makeStyles({ list: { ...shorthands.padding("2px", "4px", "8px", "30px"), }, I ...
TommyD's user avatar
  • 1,043
2 votes
0 answers
129 views

I need to be able to use @emotion/styled CSS-in-JS library so I can pass props to the background-color and color properties of my Button component. The background-color and color of the buttons are ...
annie's user avatar
  • 25
1 vote
0 answers
128 views

I'm migrating some CSS to Emotion, some selectors are like .a.b {...}. What's the best way to use Emotion for this? I've tried css`.${a}.${b}` but it doesn't work :(
slhsxcmy's user avatar
0 votes
0 answers
233 views

I have 2 micro frontends, which share the same component library. This creates specificity bugs, because it breaks the order of style definition. For example: Suppose we have these styles: .card { ...
Damian Pereira's user avatar
5 votes
1 answer
2k views

I was wondering if somebody could suggest a vscode extension that will allow intellisense to suggest css-in-js for customized material ui components in .tsx file. E.g. I would like intellisense to pop ...
Glen Ottley's user avatar
1 vote
1 answer
282 views

Is this the correct way to apply fallback for width with vendor prefixes and finally percentage for browsers that don't support calc? <React.Fragment> <Container style={{ ...
Nikk's user avatar
  • 7,961
2 votes
0 answers
227 views

I'd like to parse CSS-in-JS (styled-components) which is written in my tsx file into an AST so I can change the hex color into the css variable name. For example, const Wrapper = styled.div` ...
syed hussain haider zaidi's user avatar
1 vote
1 answer
3k views

I'd like to have a checkbox with a label in a wrapper. When the wrapper is hovered everything should change color. See the image: Here is my code: const styles = {formControlLabel:{ color:'#d7dae0',...
Travis Heeter's user avatar
0 votes
1 answer
569 views

I want to add props to control my css in emotion,but I don't know how to do
React-beginner's user avatar
1 vote
1 answer
665 views

I have the following code: const CardContainer = styled(Flex)` flex-direction: column; padding: 12px; width: 100%; max-width: 450px; height: auto; border-radius: 32px; overflow: hidden; ...
goplay's user avatar
  • 164
0 votes
1 answer
510 views

According to my research and twin.examples repo for Next.js, twin.macro recommends adding their preflight component, which they name <GlobalStyles />. They often alias it to <BaseStyles /> ...
Francisco Barros's user avatar
4 votes
1 answer
2k views

I'm using Mui's styled components, and i've noticed it injects a class that starts with "css-" and replaces the class name i've given to it in the code I've tried to follow everything that ...
For fun programmer's user avatar
2 votes
1 answer
449 views

You can use document.documentElement.outerHTML in order to serialize a document to a HTML string. However, if we paste the result into a file and try to render it as HTML, it will not be always be ...
Foobar's user avatar
  • 8,659
1 vote
2 answers
1k views

I have a React component roughly with this structure: // This does not work. const style = { position: 'absolute' // ...other css props } const Component = () => {...
 HigoChumbo 's user avatar

1
2 3 4 5