extensions-app: Make kill switch more compact

Instead of using a subtitle, move the stability warning into an
information popover.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3051>
This commit is contained in:
Florian Müllner 2023-12-11 00:34:31 +01:00 committed by Marge Bot
parent 592ad186c6
commit e064c2a785
3 changed files with 37 additions and 3 deletions

View File

@ -0,0 +1 @@
<svg height="16" width="16" xmlns="http://www.w3.org/2000/svg"><path d="M7.906 1A7.002 7.002 0 0 0 1 8c0 3.867 3.133 7 7 7s7-3.133 7-7-3.133-7-7-7h-.094zM7.5 4h1c.277 0 .5.223.5.5v1c0 .277-.223.5-.5.5h-1a.498.498 0 0 1-.5-.5v-1c0-.277.223-.5.5-.5zM7 7h2v5H7zm0 0" fill="#2e3436"/></svg>

After

Width:  |  Height:  |  Size: 286 B

View File

@ -3,6 +3,8 @@
<gresource prefix="/org/gnome/Extensions@profile@">
<file alias="style.css">css/style.css</file>
<file preprocess="xml-stripblanks">icons/scalable/actions/info-symbolic.svg</file>
<file alias="gtk/help-overlay.ui">ui/help-overlay.ui</file>
</gresource>

View File

@ -92,10 +92,41 @@
<object class="AdwPreferencesGroup">
<child>
<object class="AdwActionRow">
<property name="title" translatable="yes">Extensions</property>
<property name="subtitle" translatable="yes">Extensions can cause performance and stability issues. Disable extensions if you encounter problems with your system.</property>
<property name="title" translatable="yes">_Extensions</property>
<property name="activatable-widget">enabledSwitch</property>
<child>
<property name="use-underline">true</property>
<child type="suffix">
<object class="GtkMenuButton">
<property name="valign">center</property>
<property name="has-frame">false</property>
<property name="icon-name">info-symbolic</property>
<accessibility>
<property name="label" translatable="yes">More Information</property>
</accessibility>
<property name="popover">
<object class="GtkPopover" id="infoPopover">
<property name="child">
<object class="AdwClamp">
<property name="maximum-size">350</property>
<property name="tightening-threshold">350</property>
<property name="child">
<object class="GtkLabel">
<property name="label" translatable="yes">Extensions can cause performance and stability issues. It is recommended to disable all extensions if you experience problems with your system.</property>
<property name="wrap">true</property>
<!-- Hack to make the screen reader read the label -->
<property name="selectable"
bind-source="infoPopover"
bind-property="visible"
bind-flags="invert-boolean|sync-create"/>
</object>
</property>
</object>
</property>
</object>
</property>
</object>
</child>
<child type="suffix">
<object class="GtkSwitch" id="enabledSwitch">
<property name="action-name">win.user-extensions-enabled</property>
<property name="valign">center</property>