October 21, 2024
Chicago 12, Melborne City, USA

CSS

CSS (Cascading Style Sheets) is a representation style sheet language used for describing the look and formatting of HTML

CSS

About styling a table dynamically and adding or removing columns

The columns wraps weirdly and I can’t figure out why it is happening. const [isHidden, setIsHidden] = useState([]); const { data: leadsData, isPending } = useLeads(); let columns = tableHead.length - isHidden.length const handleVisiblity = (id) => { setIsHidden((prevHidden) => { if (prevHidden.includes(id)) { return prevHidden.filter((hiddenId) => hiddenId !== id); } else { return [...prevHidden,

Read More
CSS

Does Google Chrome have a bug with css: background-position-y: bottom 40%?

In Chrome/Dev tools: Using the shorthand: background-position: bottom 40% center; seems be correctly "translated" into its background-position-x and background-position-y parts. Yet the exact same string is marked invalid and won’t also work in the UI: background-position-y: bottom 40%; It seems to work in Firefox: I tested with Chrome versions: Where can this be reported, if

Read More
CSS

How do I un-constrain an absolutely positioned element's width so that it may grow beyond the parent

Why are absolutely positioned elements in React-Native still relative to the parent with their width? If I use a text with a flairText style as I’ve written in my example the text inside will still wrap if it would exceed the height of the parent it has been absolutely positioned from. How can I un-constrain

Read More
CSS

How to add a delay or smooth out scroll-driven animations using the animation-timeline property?

I’m currently using CSS scroll-driven animations with the new animation-timeline property. An example of the technique I’m referring to can be seen here: Image Reveal Example. However, I’m facing an issue: I would like to add an animation delay to smooth out the animation, especially when scrolling with a mouse. Currently, the animation looks a

Read More
CSS

How can I apply a multi-color box shadow to my countdown component in React using Tailwind CSS?

I’m working on a countdown component in React using Tailwind CSS and inline styles. I want to apply a multi-colored shadow effect around a container, but I can’t seem to get the colors to show correctly. The box shadow either shows only one color (orange) or doesn’t appear as expected. 'use client'; import React, {useState,

Read More
CSS

Vertical fly-out column navigation

We need a fly-out column navigation for our Drupal website, and during my research, I found the Navigation module (https://www.drupal.org/project/navigation), which offers the exact style I’m looking for. This module is already part of Core. However, it only transforms the administration menu, while I need it to apply to my custom left-sidebar navigation. Specifically, I

Read More
CSS

Hotspot overlay for videos in fullscreen mode on web browsers

I have cooked up some code to display video overlay hotspots. However, when I make the video fullscreen, the hotspots are no longer visible or clickable. I tried to inspect element in fullscreen mode and the hotspots would highlight(not visible or clickable) when I dragged my pointer over their <div> but they would be in

Read More
CSS

How to change container border based on child inputs placeholder state (tailwind)

I’m trying to set border color of a parent container which contains an input element when placeholder is not shown anymore – the closest working solution that i got was with focus-within but that isn’t ideal as i want for the border to stay colored even after focus is lost – depending on whether text

Read More
CSS

How to change font color of closed captions on Udemy in Firefox

I’m using the Udemy player for watching tutorials. I’m used to green font color of closed captions from Youtube. How can I change the font color of closed captions in Udemy player? I’m using Firefox Stylish addon. There are many styles and it is difficult to find the right one. You need to sign in

Read More
CSS

React, Mantine, CSS Modules Do Not Load Properly

I’m developing a React project with TypeScript and Mantine. I’m using CSS Modules for styling components. However, at seemingly random times, the CSS stops loading (as far as I can observe from DevTools), and the webpage looks like it has no CSS applied. When I remove each import of the CSS Module in respective components,

Read More