806,228 questions
Score of -5
0 answers
49 views
How can I provide my custom CSS framework documentation to an LLM/Copilot to prevent hallucinated class names? [closed]
I am using a highly customized utility-first CSS setup. When I ask ChatGPT or GitHub Copilot to generate UI components, it frequently guesses the wrong class names (e.g., using bg-brand-primary when ...
Score of 1
0 answers
80 views
Conditional scroll-timeline binding inside CSS Container Queries
I am attempting to bind a CSS Scroll-driven Animation only when an element's container drops below a specific width.
When nesting animation-timeline inside a @container rule, it creates a style ...
Score of -7
0 answers
229 views
What's causing the empty space in this HTML/CSS? [closed]
I accidentally edited something I shouldn't have in my code, and now there is a huge empty space that I have no idea what is making it appear. This empty space was not here before and I really want to ...
Score of 3
3 answers
170 views
How do I make my website change layouts depending on screen size? [duplicate]
I have a website I'm working on that uses bootstrap 5.3 for its layout. Currently, I am trying to figure out how to change my layout when on mobile screens.
Here is the body of my main page:
/* ...
Score of 2
1 answer
106 views
Expand square flexboxes two dimensionally within bounds
I have a dynamically generated grid that I would like to appear responsive, that is, it should expand up to a reasonable size on the screen while keeping aspect ratio. What I would like is something ...
Score of 0
0 answers
121 views
How do I make it so that the element that holds the canvas stands on top of the button? [closed]
I'm trying to implement a color picker with a specific style in my menu bar, but the canvas element constantly clips down the button:
What it's supposed to look like (taken from the old version of my ...
Score of 2
1 answer
66 views
Adding page breaks in EPUB 3
I am trying to make an EPUB 3 with a file that I exported from InDesign.
Because the EPUB was made through InDesign, each chapter of the book is not in a separate HTML file. That's why I need to add a ...
Score of -6
0 answers
157 views
Cards in HTML Bootstrap [closed]
<div align="center">
<div class="row ">
<div class="col-sm ">
<div class="w3-card" style="width:400px;max-...
Score of 3
2 answers
142 views
Use CSS to hide/show arbitrary elements via data attributes?
Is there any way to set up a CSS rule so that only elements matching a certain attribute are displayed?
Say I have HTML like this:
<div data-active-slug="def-42">
<div data-slug=&...
Score of -3
0 answers
61 views
How to turn this inspect element change to max width into a Tampermonkey script? [duplicate]
I'm trying to adjust the max width of a long string of images because they're far too large. It's a webcomic site like webtoon where several of the webcomics i read are located, but the size of the ...
Score of -4
1 answer
146 views
How to achieve absolute positioning in Angular
I'm working on an Angular app and need to place an element in the corner of another one. I was planning to use CSS positioning as follows:
.extra-large-avatar {
width: 256px;
height: 256px;
...
Score of 1
3 answers
216 views
Get the playPause function to switch icons in the browser
I'm using fontawesome and all the icons show up just fine but the playPause function won't switch between the two icons, I have the HTML set up like this,
// mplayer.js
let progress = document....
Score of 0
1 answer
142 views
How to render a text message thread in CSS [closed]
I want to render a text message thread in a epub. I have managed to write the code for the messages on the left or long messages on the right of the page. However, I am struggling with short messages ...
Score of 0
1 answer
178 views
How to create a smooth sliding overlay sidebar in CSS without layout jitter and unwanted horizontal scrollbar?
I am building an overlay sidebar component next to a Leaflet/Mapbox map in a Rails application.
Requirements:
No Map Bounds Recalculation: The sidebar wrapper stays in the layout flow with a static ...
Score of 2
1 answer
133 views
How do I move a grid in CSS upwards from the bottom of the page?
The problem I am facing is that my grid is placed at the bottom of the page, and I have been trying multiple tactics, including padding, to move it, but none have worked.
I really would like to get an ...