
We've been able to get the length of the viewport in CSS since... checks notes... 2013! Surprisingly, that was more than a decade ago. Getting the

Typecasting And Viewport Transitions In CSS With Tan(atan2())
We've been able to get the length of the viewport in CSS since... checks notes... 2013! Surprisingly, that was more than a decade ago. Getting the
Tailwind Animations Examples ✨
Cool animations implemented with tailwindcss. Contribute to canopas/tailwind-animations-examples development by creating an account on GitHub.
Hey guys!
I’ve got something awesome for you—Tailwind Animations Examples, a brand-new collection of cool, ready-to-use animations built with Tailwind CSS.
🌟 Features
🎯 Perfect for developers and designers who want to save time and create stunning UIs!
Check it out now!👇
Small CSS rant + Asking for advice
Making a site JavaScript-less with bootstrap but the CSS is kicking my ass- I do the code directly as it is meant to be, then I try to add one thing and it breaks. I'm gripping on w3schools for dear life and I just can't seem to wrap my head around anything other than the basics. CSS is pain ESPECIALLY when I'm doing it on an external sheet. (I don't want to do internal because all the text gets overwhelming.) Anyone have some ideas to help with this?
Edit: So I realized the browser tool thing is really easy for visuals + that BOOTSTRAP IS INSANELY VAST. For just about every CSS element theirs another 1.5k sub rules which is great for getting specific but not great when you are basically creating a rule for a already ruled element that you have no way of finding easily. Bootstrap is just a functionality CSS sheet I think and not the equivalent to a HTML DLC
(Image is my CSS sheet compared to the crazy amount of CSS sub sheets that exist in bootstrap. My measly little 16 rules look p
CSS, select an element that have div:not(something) possible ?
Hi everyone,
I have something like this
html
<div id="container"> <div> <div class="foobar"></div> </div> <div> <div class="foobar"></div> </div> <div> <div class="foobar"></div> <div class="barfoo"></div> </div> <div> <div class="foobar"></div> </div> <div> <div class="foobar"></div> </div> <div>
I would like to select all the #container > div
(the childs of container)
that do not have a div.barfoo
in their childs.
is it possible with CSS ?
I'm at
css
#container> div :not(div.barfoo) {}
but this is not working, and will select anyway #container > div > div
Any ideas ?
background-attachment: fixed
still scroll :'(
Hi everyone,
I would like one of my div
to have an background-attachment: fixed
But the background still scroll 😤
This div is under html body div div div div div
and it CSS properties are
css
#TheDiv { min-height: 100vh; min-width: 100vw; background-image: url('/anImage.jpg'); background-size: cover; background-attachment: fixed; background-repeat: no-repeat; background-position: center center; position: absolute; left: 0; padding: 40px; box-sizing: border-box }
Any Ideas, what could cause the background to scroll anyway ?
Thanks
CSS Selectors
A complete guide covering all of the various methods we have to select elements in CSS and how to use them for applying styles.
How remove vertical gap between characters ?
Hi,
No matter what I try
html
<style> .FlexColumn {display: flex;flex-flow: column nowrap } </style> <div class="FlexColumn"> <div>X</div> <div>X</div> <div>X</div> <div>X</div> <div>X</div> </div>
html
<!-- I tried many CSS trick here... --> <div> <span>X</span><br><span>X</span><br><span>X</span><br><span>X</span> </div>
I always get a vertical gap between the characters !
Any ideas ?
Thanks.
Lightning CSS: Sourcemap @include paths not updated
When I use the --sourcemap
argument in the CLI to generate the CSS builds with sourcemaps, when the CSS uses @include
, it does not update the path and therefore will not work.
In the code below, the builds are stored in the dist directory, while the CSS source code is stored in the src directory.
This is my simple code to reproduce this...
undefined
- src/ - stylesheet.css - dist - my-package.css - my-package.css.map - demo.html - bundle.css - package.json
bundle.css
undefined
@import 'src/stylesheet.css';
demo.html
undefined
<link rel="stylesheet" href="dist/my-package.css">
package.json
undefined
{ "name": "my-package", "version": "1.0.0", "license": "MIT", "scripts": { "build": "lightningcss --sourcemap bundle.css -o dist/my-package.css" }, "devDependencies": { "lightningcss-cli": "^1.25.1" } }
src/stylesheet.css
undefined
body { background-color: red; }
dist/my-package.css output
undefined
@import "src/stylesheet.css"; /*# sourceMappingURL=dist/my-pac
Using CSS flexbox default stretching behaviour to create a dynamic line separator.
Infinite-Scrolling Logos In Single HTML Container And Pure CSS
Remember the HTML `` element? It’s deprecated, so it’s not like you’re going to use it when you need some sort of horizontal auto-scrolling feature. That’s where CSS comes in because it has all the tools we need to pull it off. Silvestar Bistrović demonstrates a technique that makes it possible with...
CSS Folding Effect
In this post, we'll explore a technique we can use to "fold" a DOM node, like folding a letter in real-life. On that journey, we'll learn a lot about 3D transforms and CSS animation techniques!
Yesterday, we learned about CSS variables. Today, I wanted to show you an advanced approach to working with them that I often use with client projects. Let’s dig in! Globals for system or theme defaults I like to scope design system or theme defaults to the :root element. This makes them accessible ...
Yesterday, I mentioned that I love CSS variables. Today, I thought I’d explain what they are and how they work, for those who aren’t already familiar with them. Let’s dig in! How to define CSS variables You define a CSS variable by typing its name with a leading double-dash (--). It uses the same sy...
What You Need to Know about Modern CSS (Spring 2024 Edition)
My goal with this bookmarkable guide is to provide a list of (frankly: incredible) new additions to CSS lately. There is no hardline criteria for this list other than that these things are all fairly new and my sense is that many people aren’t aware of these things. Or even if they are, they don’t [...
You Want border-color: transparent, Not border: none
If you find yourself removing a border from an element that has a border and are tempted to use border: 0 , border: none, or outline: none, I’d urge you to stop for a moment and reconsider. It’s like the old G.K. Chesterton saying about fences: Do not remove a fence until you know why […]
Finder 3.2: CSS Selector Generator - Given an element, it produces the shortest possible selector that reaches (solely) that element
CSS Selector Generator 🗺. Contribute to antonmedv/finder development by creating an account on GitHub.
A minigame for learning Tailwind CSS
Alternative approach to container and wrapper classes
Click to view this content.
Video basically explaining how to use named grid columns to avoid those negative margins for breakout and full-width sections