Comments (2)
Thank you for the report. I noticed your codepen didn't have any atomizer classes in it. I tried the following out in our REPL:
<div class="Mx(0)"></div>
<div class="Mend(0):lc"></div>
<div class="Mend(0):l"></div>
Which produced:
.Mx\(0\) {
margin-left: 0;
}
.Mx\(0\), .Mend\(0\)\:l:left, .Mend\(0\)\:lc:last-child {
margin-right: 0;
}
I see Mx(0)
getting both margin's applied. Which issue were you seeing again?
from atomizer.
Yes, those are the classes produced, but that style(margin-right: 0) isn't getting applied to the elements for me.
I took those atomizer classes and tried to showcase the issue better in this codepen: https://codepen.io/maheshbansod/pen/xxJYRbj
Pasting the same code here too:
CSS:
div {
margin: 30px;
color: white;
}
.Mx\(0\) {
margin-left: 0;
}
.Mx\(0\), .Mend\(0\)\:l:left, .Mend\(0\)\:lc:last-child {
margin-right: 0;
}
HTML:
<div style="background-color: blue;">
<div style="background-color: red;" class="Mx(0)">
Expected margin 0 on both sides but observed margin 0 only on left
</div>
</div>
<div style="background-color: blue;">
<div style="background-color: red" class="Mend(0):lc">Expected margin zero on both sides(because this div is the last child), but observed 30px on both sides</div>
</div>
If we look in Chrome devtools, you'll notice that the margin-right:0 style isn't even getting overridden, it's just not applied at all to the divs.
Removing the class .Mend\(0\)\:l:left
from there fixes it and the observations will match the expectations.
I can see this on Chrome on Mac.
Let me know if any other information is required if this isn't getting reproduced at your end.
from atomizer.
Related Issues (20)
- RFC: Optional specificity bump for media queries HOT 14
- add support for multiple combinators? HOT 1
- Atomizer getConfig mutates provided object, should be pure
- !important generation in atomic classes which have symbols like descendent selector (_) and Sibling selector (+) in it HOT 1
- Are there any plugin or plans to add attribute mode? HOT 1
- Landing page should be updated to show atomizer HOT 2
- Make it easier to search on right/left equivalents start/end
- Atomizer Roadmap HOT 11
- acss.io is inaccessible HOT 1
- Support space separated functions
- config: Mirror cli arguments to config
- Combine Helper atomic classes elements with others, where same set of properties & values are being used HOT 3
- Atomizer plugin not working on a vite project HOT 7
- Add aspect ratio HOT 4
- Webpack atomizer-plugins: images are broken after webpack build HOT 5
- Can we have a support of "inset" CSS Property in AtomicCSS? HOT 5
- Update Remix integration to use PostCSS plugin
- Shift lower specificity classes first, then higher specificity classes (when using namespace) HOT 2
- Update the atomizer version to the latest version HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from atomizer.