807,308 questions
0
votes
0
answers
28
views
How to align the data upload button with other types of button?
I am writing an R Shiny app and use CSS to format the buttons on the header and footer of the page. I am running into a sticky situation with the Upload button, where no matter how I configure, it ...
-2
votes
1
answer
30
views
I'm trying to apply a simple hover effect to a <div>, but nothing changes when I move the mouse over it and i need a perfect answer
I'm trying to apply a simple hover effect to a <div>, but nothing changes when I move the mouse over it
Here is my exact code: .btn { width:150px; height:50px; background-color:green; } .btn :...
-3
votes
1
answer
30
views
Why does the entire viewport fills in red when the element is not that big in size? [duplicate]
Hello! just trying to figure out what is going on here.
I am trying to understand in a comprehensive way, how all this works (I am an experienced one but always with some doubts about the things ...
0
votes
0
answers
79
views
How to recreate Ethopia flag using HTML and CSS [closed]
I am trying to recreate Ethopia flag using HTML and CSS but I am unable to do the middle part of the flag. The star inside the circle is not coming as expected. HTML and CSS I have applied:
body {
...
-1
votes
0
answers
21
views
I'm trying to apply a simple hover effect to a <div>, but nothing changes when I move the mouse over it [closed]
Here is my exact code:
.btn { width:150px; height:50px; background-color:green; }
.btn :hover{ background-color:red; font-size: 19px; color: white; }
<div class="btn">SIGN UP</div>
-1
votes
0
answers
63
views
Why are my CSS class styles not applying even though the class name is correct? [closed]
I am trying to apply simple CSS to a paragraph but the styles are not being applied. The CSS file is in the same folder as the HTML file.
Here is the minimal code:
<!DOCTYPE html>
<html>
&...
1
vote
2
answers
59
views
How to prevent rerender of identical component in child?
I'm trying to make a progress bar that has a transition animation. Think: a multi-page wizard, and when you advance to the next page the progress bar animates to the next step.
When the progress bar ...
0
votes
0
answers
80
views
Set gap between list marker and content
Take the following HTML:
<ol>
<li>one</li>
<li>two</li>
<li>three</li>
</ol>
Is it possible to set the gap between “1.” and “one”, which is the ...
1
vote
1
answer
36
views
CSS single property auto-indent in VSCODE [closed]
How to configure VScode to keep CSS rules with only one property on a single line when autoformatting? Here is the expected result :
.p-auto { padding: auto !important; }
.px-0 {
padding-left: 0 !...
-3
votes
0
answers
30
views
All browsers (on multiple computers) are loading older versions of style.css for my footer [closed]
Out of the blue today, I noticed that the css for my footer had changed. When I used the inspector, I saw that an older version of style.css had been loaded (for the footer only). The latest version ...
0
votes
0
answers
24
views
how to change body section style using checkbox in header tag section in a html page [duplicate]
I want to change background color of "maincontent" div element to red when I clicked check box, which is in header tag of my HTML page. please give any idea how to do that.
<!DOCTYPE html&...
-2
votes
0
answers
41
views
Why is there a space present on the left side of my div? [closed]
HTML:
<div id="div-area">
<p id="title-div1">
Find pages with...
</p>
<label>
all these words:
<input type="text" name="...
Advice
0
votes
0
replies
44
views
css/react/mui border radius like
Graphic designer designed this component that should display forms and messages like an auth form...
I'm a bit confused on how should I code the top right border... I was thinking a simple border-...
-3
votes
0
answers
33
views
Why is my web display not full when I add aos js? (bootstrap5) [closed]
I'm a junior web developer and I want to create a portfolio website using Bootstrap 5. When it's finalized, I want to add animations using AOS JS. However, when I add these, the website doesn't ...
Advice
1
vote
2
replies
114
views
HTML static webpage - how would I have any of the files present in a particular directory be selected in a src
How would I go about, in an HTML webpage, having a random file in a specific directory be selected in a src? My intent is to have a randomized audio file autoplay whenever I open any webpage on my ...
-1
votes
0
answers
50
views
Why doesn’t my CSS animation trigger when toggling a class with JavaScript? [closed]
I’m trying to animate a div when a button is clicked. The class is added correctly, but the animation doesn’t run. Here’s my minimal code:
function toggleBox() {
document.getElementById("box")....
0
votes
0
answers
48
views
Mobile Chrome: Fixed position overlay disappears when scrolling inside sidebar [closed]
Problem
I have a mobile sidebar with a dark overlay (backdrop). When the sidebar is open and the user scrolls inside the sidebar, the overlay disappears or becomes unstable on Chrome mobile (Android). ...
Best practices
0
votes
2
replies
65
views
How to respect other elements when breaking out of container?
I got a layout that is two columns where the right column will contain some text and a header. The header should also have the possibility to either remain in its column or span across both columns ...
2
votes
2
answers
118
views
Light Mode Flash (in dark mode) On Reload Page
Always I reload any page happens a quick flash that changes the entire system to dark mode and comes back again, but really quick.
Before, this was happens also on dark mode too, but I could fix it ...
0
votes
0
answers
25
views
Vuetify v-data-table fixed-header: rows visible behind rounded header when scrolling vertically in Chrome
How can I clip table rows under a header with rounded corners when scrolling?
When the table scrolls, the rows slide under the rounded corners of the header. Since the rows have regular (non-rounded) ...
3
votes
2
answers
71
views
z-index animation issue in CSS
I am new to web design and basically made a gradient outline for my button. I am trying to make the button and the gradient background behind it appear together with an animation. When I do this ...
0
votes
1
answer
43
views
Why do buttons have box-sizing of content-box even though I have a global box-sizing rule? [closed]
I am using the following rule globally:
*,
*::before,
*::after {
box-sizing: border-box;
margin: 0;
padding: 0;
}
But from some reason the buttons are content-box, even though there is no ...
4
votes
2
answers
75
views
CSS aspect-ratio inside a column flex container takes more than parent's height
To simplify a complex CSS issue, I’m trying to place three elements inside a vertical flex container:
two fixed-height divs, and in the middle a div that should keep a specific aspect-ratio.
Here is a ...
0
votes
0
answers
34
views
PrimeNg OverlayPanel is displayed with and without scrolling for the same content
I use the PrimeNG OverlayPanel to display popups in my Angular app.
I noticed that for the same content, it sometimes displays a scrollbar and sometimes does not.
As you can see in the screenshots, ...
Best practices
0
votes
2
replies
78
views
javascript : how to display and scroll a remote pdf, on a browser non dependant way
I wish to display in an html page and control its scrolling, the image of a pdf hosted on a server.
I am currently using Mozilla’s pdf.js scripts, which work well for pdf files stored on my computer.
...
-2
votes
0
answers
23
views
Optimal layout of nested wrapping blocks [duplicate]
My layout consists of blocks, each block contains images. Blocks as well as images should wrap if needed to take up the least amount of space possible. It needs to be responsive and fully dynamic.
I ...
-3
votes
3
answers
160
views
Why does the checkbox become unclickable when width is lowered?
This is a incomplete website design I have been working with. The problem is when I reduce the width of the browser the triple dash appears but for some reason the checkbox becomes unclickable. I ...
3
votes
1
answer
54
views
ECharts x-axis labels truncated with grid left/right 0: How to offset first/last labels without affecting spacing?
The Problem I am using ECharts and I need the chart to take up the full width of the container. Therefore, I set grid.left and grid.right to 0. However, this causes the first and last labels on the x-...
0
votes
0
answers
72
views
Vercel build error: “Cannot find module '../lightningcss.linux-x64-gnu.node'” when building (Vite + Tailwind + React) project [closed]
I’m trying to deploy my personal website to Vercel using Vite + React + Tailwind CSS. The project builds and runs fine locally (npm run build works without errors), but the Vercel build fails with the ...
0
votes
0
answers
77
views
Flexbox: align-self depending on row
I've got some short flexbox items and some long/tall items in a multi row (flex-wrap) container with flex-direction: row.
Depending on which row they appear in, I'd like to align the short items ...
5
votes
3
answers
117
views
Why does a different row height in the 4th row change the row height distribution among the first three rows?
I have a Grid with two columns and 4 rows. The grid-areas are as follows
grid-template-areas:
"v p"
"v o"
"v t"
"m t";
I have one Item per area. So my item v (...
3
votes
2
answers
71
views
Changing the size of the image/gif I used for the list-style in css
I put my list-style into the CSS code:
.contentsT {
justify-content: space-evenly;
flex-direction: column;
list-style: url('zvezdica.webp');
}
<ul class="contentsT">
<li>
...
3
votes
0
answers
99
views
Can't get scroll animation code to execute
Thanks for the help in advance. For the life of me, I cannot get a particular scroll animation to execute which utilizes gsap and lenis.
I've assembled the code to the best of my ability: https://...
-1
votes
1
answer
47
views
Plotly Dash dbc column width
In a Plotly Dash application I'm trying to use the horizontal space optimaly.
There are four columns in the first row. Right now this is what I have:
from dash import Dash, dcc, html, Input, Output, ...
2
votes
1
answer
62
views
mix-blend-mode on blur background
I’m trying to build a glass-style pill component with text inside it.
What I want:
the text uses mix-blend-mode exculsion
the pill has a semi-transparent background
the pill applies a backdrop-filter: ...
3
votes
2
answers
37
views
How to cross-reference colours in a css file
I want to make the background-color of a <div> to be the same colour as the track colour of its scrollbar, which I've not changed from the default. Is this possible?
This works, but I was ...
2
votes
1
answer
72
views
CSS Universal Selector Combinator omits style on table tag (1st descendant) in a div
I have a table (in a div with an id) and I want to apply styling on it (to collapse its borders) using CSS's universal selector combinator (*) and all of the div's descendants (in order to isolate the ...
5
votes
1
answer
62
views
Make overlapping flex items stay centered as a group
I'm trying to create a hand of cards effect where the cards overlap each other, similar to how cards look when you're holding them in your hands.
I'm using a flex container to center the cards ...
0
votes
0
answers
66
views
How can I apply this SVG curve path to a div background or clip-path in CSS? [closed]
I’m trying to create a header layout with a specific curved shape.
The small squares are SVGs, but I can’t reproduce the curved blue border using CSS clip-path.
Here is the path I want to apply to a ...
2
votes
1
answer
73
views
CSS Lists in a specific format
I am wondering if you could automatically create a list in the following format:
A.
I.
1.
a)
aa)
(1)
(a)
(aa)
etc. etc.
Could anyone help me accomplish this?
I am asking for my Anki-template
I ...
1
vote
0
answers
58
views
Is it possible to create a custom cursor with page scrolling on mobile using JS? [closed]
I've tried to create a custom cursor for mobile devices, but when the page is scrollable, the custom cursor doesn't follow your finger properly or it drops frames.
Has anyone succeeded in creating a ...
Advice
2
votes
4
replies
66
views
Make native pinch-to-zoom trigger real layout reflow (without horizontal scroll) on mobile
I need the native pinch-to-zoom gesture in mobile browsers to behave like true browser zoom: when the user pinches, media queries should reevaluate and the layout should reflow. At the same time, the ...
0
votes
2
answers
55
views
Tailwind dark mode classes not working even though .dark class is applied [duplicate]
I'm trying to implement dark mode in my Next.js app using TailwindCSS. However, TailwindCSS's dark: classes are not being applied, even when the .dark class is present on the <html> tag.
global....
1
vote
3
answers
194
views
Why is my CSS outline appearing on input for both mouse click and keyboard focus despite using :focus-visible? [closed]
I have a simple HTML page with an input element:
input {
outline: none;
}
input:focus {
outline: none;
}
input:focus-visible {
outline: 1px solid black;
}
<input />
My goal is to remove ...
-1
votes
0
answers
44
views
How to override Radix theme ::before ::after styles [closed]
I am using Radix theme https://www.radix-ui.com/themes/docs/overview/getting-started and I am specifically using the Table component.
I want to override default styling for just the Table.Header ...
0
votes
1
answer
152
views
Position sticky top animation works only when scrolling down, otherwise there is a jump
I have a sticky bar on the right side of my page and I want to animate its top property (and height) to nicely fit its transition to disappearing announcement bar at the top of the page. Below video ...
0
votes
0
answers
76
views
How must I set a title <h1> with logo and top- and bottom- border with CSS?
My goal is to create a section with a title, a left-aligned logo, and a colored background. The logo and background must also be enclosed in a border. Something like this:
The correct alignment is ...
-1
votes
0
answers
79
views
Web carousel very slow on Safari desktop, fine everywhere else [closed]
I have a web carousel on a site I built (here) that slides automatically (although you can also use controls to move through the slides manually). It works fine on all browsers, and manual controls ...
-3
votes
0
answers
71
views
Elementor Pro 3.32 Reduced Motion Preference [closed]
In Elementor 3.32 Pro, the builder now fully respects the user’s reduced-motion preference. This means that no Motion Effects are activated when reduced motion is enabled.
I manage a school website, ...
-3
votes
1
answer
128
views
How to give a pixel wood texture to font similar to Stardew Valley?
I'm currently working on my bachelor's project, I downloaded the Stardew Valley Title font to use it in my Web Game but I'm having problems getting that wooden texture. Here is how my title related ...