Skip to content
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

refactor(chat): Flatten rules in chat.scss #1779

Merged
merged 1 commit into from
Nov 21, 2024
Merged

Conversation

gadenbuie
Copy link
Collaborator

@gadenbuie gadenbuie commented Nov 20, 2024

Small refactor to flatten nested rules in chat.scss, since the custom element rules don't need to be nested.

Flatter rules are easier to modify from userland and I contend they're easier to maintain because we retain nesting where class and element interactions are important.

@cpsievert
Copy link
Collaborator

The inspiration for nesting is two-fold:

  1. Reduce the chance of clashing with other rules
  2. Provide a signal that the nested elements should only exist inside certain parent elements

That said, I don't feel those things necessarily trump simpler selectors in this case, so OK with me

@gadenbuie gadenbuie merged commit e60dad5 into main Nov 21, 2024
41 checks passed
@gadenbuie gadenbuie deleted the chat/refactor-sass branch November 21, 2024 21:29
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