Skip to content

refactor(html): move more tailwind usage to defined classes #553

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Apr 22, 2024

Conversation

crowlKats
Copy link
Member

No description provided.

Copy link
Contributor

@josh-collinsworth josh-collinsworth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Other than one small concern (which may be for nothing), looks all right to me.

Comment on lines +216 to 245
.usage {
@apply px-6 py-5 mb-4 border max-md:border-x-0 md:rounded-lg bg-stone-50 border-stone-200;

nav {
@apply flex items-center flex-row gap-2 mb-3 font-semibold;

details {
> summary {
@apply flex gap-1 select-none cursor-pointer rounded border border-gray-300 py-2 px-3;
}

> div {
@apply md:relative;

> div {
@apply absolute max-md:inset-x-0 mt-1.5 p-2 block z-30 md:w-72 bg-white md:rounded border max-md:border-x-0 border-gray-300;

label {
@apply flex items-center justify-between cursor-pointer select-none px-2 py-1 leading-normal rounded-sm hover:bg-gray-50;
}
}
}
}
}

pre.highlight {
@apply border border-gray-300 max-md:border-x-0;
}
}

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Question: is this selector nesting compiled away?

If so, disregard this comment. But otherwise, nesting is fairly well supported, but still new enough it may be risky to use, especially without the & syntax. https://caniuse.com/?search=nesting

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yep, its compiled away. I know tailwind supports nesting, but as also pass the stylesheet through lightningcss

@crowlKats crowlKats merged commit 7bdbb2d into main Apr 22, 2024
5 checks passed
@crowlKats crowlKats deleted the stylesheet-rework branch April 22, 2024 15:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants