Skip to content

A platform for community discussion. Free, open, simple.

DEV: remove `:has` selector from chat settings (#25248)

Kris92708f2ff5ed
diff --git a/plugins/chat/assets/javascripts/discourse/components/chat/routes/channel-info-settings.gjs b/plugins/chat/assets/javascripts/discourse/components/chat/routes/channel-info-settings.gjs
index 211d791e364..6765a1a1859 100644
--- a/plugins/chat/assets/javascripts/discourse/components/chat/routes/channel-info-settings.gjs
+++ b/plugins/chat/assets/javascripts/discourse/components/chat/routes/channel-info-settings.gjs
@@ -578,7 +578,7 @@ export default class ChatRouteChannelInfoSettings extends Component {
</form.section>
{{/if}}
- <form.section as |section|>
+ <form.section class="--leave-channel" as |section|>
<section.row>
<:action>
<ToggleChannelMembershipButton
diff --git a/plugins/chat/assets/stylesheets/common/chat-channel-settings.scss b/plugins/chat/assets/stylesheets/common/chat-channel-settings.scss
index 223148c815f..716a192fc8c 100644
--- a/plugins/chat/assets/stylesheets/common/chat-channel-settings.scss
+++ b/plugins/chat/assets/stylesheets/common/chat-channel-settings.scss
@@ -19,7 +19,9 @@
}
}
- .chat-form__section-content:has(.c-channel-settings__leave-info) {
- gap: 0.25rem;
+ .chat-form__section.--leave-channel {
+ .chat-form__section-content {
+ gap: 0.25rem 0.5rem;
+ }
}
}