<?xml version="1.0" encoding="UTF-8"?>
<interface>
  <menu id="primary-menu">
    <section>
      <item>
        <attribute name="label" translatable="yes">Help</attribute>
        <attribute name="action">win.show-help</attribute>
      </item>
      <item>
        <attribute name="label" translatable="yes">About Extensions</attribute>
        <attribute name="action">win.show-about</attribute>
      </item>
    </section>
  </menu>
  <template class="ExtensionsWindow" parent="GtkApplicationWindow">
    <property name="default-width">800</property>
    <property name="default-height">500</property>
    <property name="title" translatable="yes">Extensions</property>
    <child type="titlebar">
      <object class="GtkHeaderBar">
        <child type="end">
          <object class="GtkMenuButton" id="menuButton">
            <property name="receives-default">True</property>
            <property name="menu-model">primary-menu</property>
            <property name="icon-name">open-menu-symbolic</property>
          </object>
        </child>
        <child type="end">
          <object class="GtkToggleButton" id="searchButton">
            <property name="receives-default">True</property>
            <property name="icon-name">edit-find-symbolic</property>
            <child>
              <object class="GtkShortcutController">
                <property name='scope'>global</property>
                <child>
                  <object class='GtkShortcut'>
                    <property name='trigger'>&lt;Control&gt;f</property>
                    <property name='action'>activate</property>
                  </object>
                </child>
                <child>
                  <object class='GtkShortcut'>
                    <property name='trigger'>&lt;Control&gt;s</property>
                    <property name='action'>activate</property>
                  </object>
                </child>
              </object>
            </child>
          </object>
        </child>
      </object>
    </child>
    <child>
      <object class="GtkBox">
        <property name="orientation">vertical</property>
        <child>
          <object class="GtkSearchBar" id="searchBar">
            <property name="key-capture-widget">ExtensionsWindow</property>
            <property name="search-mode-enabled"
                      bind-source="searchButton"
                      bind-property="active"
                      bind-flags="bidirectional"/>
            <child>
              <object class="GtkSearchEntry" id="searchEntry">
                <property name="max-width-chars">35</property>
              </object>
            </child>
          </object>
        </child>
        <child>
          <object class="GtkStack" id="mainStack">
            <property name="transition-type">crossfade</property>
            <property name="vexpand">True</property>
            <child>
              <object class="GtkStackPage">
                <property name="name">main</property>
                <property name="child">
                  <object class="AdwPreferencesPage">
                    <child>
                      <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="activatable-widget">enabledSwitch</property>
                            <child>
                              <object class="GtkSwitch" id="enabledSwitch">
                                <property name="action-name">win.user-extensions-enabled</property>
                                <property name="valign">center</property>
                              </object>
                            </child>
                          </object>
                        </child>
                      </object>
                    </child>
                    <child>
                      <object class="AdwPreferencesGroup" id="userGroup">
                        <property name="title" translatable="yes">Manually Installed</property>
                        <property name="description" translatable="yes">To find and add extensions, visit &lt;a href="https://extensions.gnome.org"&gt;extensions.gnome.org&lt;/a&gt;.</property>
                        <child>
                          <object class="GtkListBox" id="userList">
                            <property name="selection-mode">none</property>
                            <style>
                              <class name="boxed-list"/>
                            </style>
                          </object>
                        </child>
                      </object>
                    </child>
                    <child>
                      <object class="AdwPreferencesGroup" id="systemGroup">
                        <property name="title" translatable="yes">Built-In</property>
                        <child>
                          <object class="GtkListBox" id="systemList">
                            <property name="selection-mode">none</property>
                            <style>
                              <class name="boxed-list"/>
                            </style>
                          </object>
                        </child>
                      </object>
                    </child>
                  </object>
                </property>
              </object>
            </child>
            <child>
              <object class="GtkStackPage">
                <property name="name">placeholder</property>
                <property name="child">
                  <object class="AdwStatusPage">
                    <property name="icon-name">org.gnome.Extensions-symbolic</property>
                    <property name="title" translatable="yes">No Installed Extensions</property>
                    <property name="description" translatable="yes">To find and add extensions, visit &lt;a href="https://extensions.gnome.org"&gt;extensions.gnome.org&lt;/a&gt;.</property>
                  </object>
                </property>
              </object>
            </child>
            <child>
              <object class="GtkStackPage">
                <property name="name">noshell</property>
                <property name="child">
                  <object class="AdwStatusPage">
                    <property name="title" translatable="yes">Something’s gone wrong</property>
                    <property name="description" translatable="yes">We’re very sorry, but it was not possible to get the list of installed extensions. Make sure you are logged into GNOME and try again.</property>
                  </object>
                </property>
              </object>
            </child>
          </object>
        </child>
        <child>
          <object class="GtkActionBar" id="updatesBar">
            <property name="revealed">False</property>
            <child>
              <object class="GtkImage">
                <property name="pixel-size">24</property>
                <property name="margin-start">6</property>
                <property name="margin-end">6</property>
                <property name="margin-top">6</property>
                <property name="margin-bottom">6</property>
                <property name="icon-name">software-update-available-symbolic</property>
                <style>
                  <class name="warning"/>
                </style>
              </object>
            </child>
            <child>
              <object class="GtkBox">
                <property name="orientation">vertical</property>
                <property name="valign">center</property>
                <child>
                  <object class="GtkLabel">
                    <property name="halign">start</property>
                    <property name="label" translatable="yes">Extension Updates Ready</property>
                    <style>
                      <class name="heading"/>
                    </style>
                  </object>
                </child>
                <child>
                  <object class="GtkLabel" id="updatesLabel">
                    <property name="halign">start</property>
                  </object>
                </child>
              </object>
            </child>
            <child type="end">
              <object class="GtkButton">
                <property name="label" translatable="yes">Log Out…</property>
                <property name="valign">center</property>
                <property name="action-name">win.logout</property>
                <property name="receives-default">True</property>
                <style>
                  <class name="suggested-action"/>
                </style>
              </object>
            </child>
          </object>
        </child>
      </object>
    </child>
  </template>
</interface>