Code Monkey home page Code Monkey logo

Comments (5)

antfu avatar antfu commented on May 27, 2024 1

I am ok having it to align with tailwind, PR welcome

from unocss.

zyyv avatar zyyv commented on May 27, 2024

I implemented this in unocss-preset-useful.

Check the test case. https://github.com/unpreset/unocss-preset-useful/blob/60df1b3f0c59475637dc6b4b10bbaf69c995edbd/test/postprocess.test.ts#L39-L61

from unocss.

zyyv avatar zyyv commented on May 27, 2024

We provide postprocess hook, I guess you can handle it yourself?

from unocss.

xsjcTony avatar xsjcTony commented on May 27, 2024

I want to add #root .atomic selector before the atomic classname. Let me try whether I can figure it out using variant.

from unocss.

xsjcTony avatar xsjcTony commented on May 27, 2024

@antfu Wondering whether you want it in preset-wind or preset-mini?

Also, beyond the tailwind behavior (which I will introduce an option called important: boolean | string) which will apply globally, I also want to introduce something like ancestor-xxx:yyy variant to partially opt-in.

E.g. ancestor-#root:m-4 will be #root .m-4 { ... }, ancestor-[#root_>_#container_>]:p-2 will be #root > #container > .p-2

Any thoughts on this (e.g. the variant naming)? If you approve, would you like me to do it in the same PR or separately?

from unocss.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.