<?xml version="1.0" encoding="UTF-8"?>
<interface>
  <requires lib="gtk" version="4.0"/>
  <object class="GtkStack" id="stack">
    <child>
      <object class="GtkStackPage">
        <property name="name">search</property>
        <property name="child">
          <object class="GtkBox">
            <property name="orientation">1</property>
            <child>
              <object class="GtkRevealer" id="infobar">
                <property name="reveal-child">true</property>
                <style>
                  <class name="infobar"/>
                  <class name="info"/>
                </style>
                <child>
                  <object class="GtkBox">
                    <property name="spacing">12</property>
                    <child>
                      <object class="GtkImage">
                        <property name="icon-name">lucide-info-symbolic</property>
                      </object>
                    </child>
                    <child>
                      <object class="GtkLabel">
                        <property name="label" translatable="yes">Start a new chat, join a group chat or search for new group chats globally. You can also enter an XMPP address.</property>
                        <property name="hexpand">1</property>
                        <property name="wrap">true</property>
                        <property name="max-width-chars">46</property>
                        <property name="xalign">0</property>
                      </object>
                    </child>
                    <child>
                      <object class="GtkButton" id="infobar_close_button">
                        <property name="valign">center</property>
                        <child>
                          <object class="GtkImage">
                            <property name="icon-name">lucide-x-symbolic</property>
                          </object>
                        </child>
                      </object>
                    </child>
                  </object>
                </child>
              </object>
            </child>
            <child>
              <object class="GtkBox" id="box">
                <property name="vexpand">1</property>
                <property name="orientation">vertical</property>
                <property name="spacing">6</property>
                <style>
                  <class name="p-18"/>
                </style>
                <child>
                  <object class="GtkBox" id="controls_box">
                    <property name="spacing">6</property>
                    <child>
                      <object class="GtkSearchEntry" id="search_entry">
                        <property name="focusable">1</property>
                        <property name="hexpand">1</property>
                        <property name="placeholder-text" translatable="yes">Search…</property>
                      </object>
                    </child>
                    <child>
                      <object class="GtkToggleButton" id="global_search_toggle">
                        <property name="focusable">1</property>
                        <property name="receives-default">1</property>
                        <property name="tooltip-text" translatable="yes">Global Group Chat Search</property>
                        <property name="halign">end</property>
                        <child>
                          <object class="GtkImage">
                            <property name="icon-name">lucide-globe-symbolic</property>
                          </object>
                        </child>
                      </object>
                    </child>
                    <child>
                      <object class="GtkMenuButton" id="settings_menu">
                        <property name="focusable">1</property>
                        <property name="receives-default">1</property>
                        <property name="halign">end</property>
                        <child>
                          <object class="GtkImage">
                            <property name="icon-name">lucide-ellipsis-vertical-symbolic</property>
                          </object>
                        </child>
                      </object>
                    </child>
                  </object>
                </child>
                <child>
                  <object class="GtkBox" id="search_error_box">
                    <property name="spacing">12</property>
                    <property name="visible">0</property>
                    <child>
                      <object class="GtkImage">
                        <property name="icon-name">lucide-circle-alert-symbolic</property>
                      </object>
                    </child>
                    <child>
                      <object class="GtkLabel" id="search_error_label">
                        <property name="label" translatable="yes">Invalid Address</property>
                        <property name="wrap">true</property>
                        <property name="max-width-chars">46</property>
                        <property name="xalign">0</property>
                      </object>
                    </child>
                  </object>
                </child>
                <child>
                  <object class="GtkStack" id="list_stack">
                    <child>
                      <object class="GtkStackPage">
                        <property name="name">contacts</property>
                        <property name="child">
                          <object class="GtkOverlay">
                            <property name="vexpand">1</property>
                            <property name="child">
                              <object class="GtkScrolledWindow" id="contact_scrolled">
                                <property name="vexpand">1</property>
                                <property name="focusable">1</property>
                                <property name="hscrollbar-policy">never</property>
                              </object>
                            </property>
                            <child type="overlay">
                              <object class="GtkBox" id="no_contacts_placeholder">
                                <property name="visible">0</property>
                                <property name="halign">center</property>
                                <property name="valign">center</property>
                                <property name="orientation">vertical</property>
                                <property name="spacing">12</property>
                                <child>
                                  <object class="GtkImage">
                                    <property name="icon-name">lucide-user-symbolic</property>
                                    <property name="pixel-size">44</property>
                                    <style>
                                      <class name="dimmed"/>
                                    </style>
                                  </object>
                                </child>
                                <child>
                                  <object class="GtkLabel">
                                    <property name="label" translatable="yes">No contacts found
You can also type an XMPP address</property>
                                    <property name="justify">center</property>
                                    <property name="wrap">1</property>
                                    <property name="max-width-chars">35</property>
                                    <style>
                                      <class name="dimmed"/>
                                    </style>
                                  </object>
                                </child>
                              </object>
                            </child>
                          </object>
                        </property>
                      </object>
                    </child>
                    <child>
                      <object class="GtkStackPage">
                        <property name="name">global</property>
                        <property name="child">
                          <object class="GtkOverlay">
                            <property name="vexpand">1</property>
                            <property name="child">
                              <object class="GtkScrolledWindow" id="global_scrolled">
                                <property name="vexpand">1</property>
                                <property name="focusable">1</property>
                                <property name="hscrollbar-policy">never</property>
                              </object>
                            </property>
                            <child type="overlay">
                              <object class="GtkStack" id="global_search_placeholder_stack">
                                <property name="visible">0</property>
                                <child>
                                  <object class="GtkStackPage">
                                    <property name="name">global-search-hint</property>
                                    <property name="child">
                                      <object class="GtkBox" id="global_search_placeholder_hints">
                                        <property name="halign">center</property>
                                        <property name="valign">center</property>
                                        <property name="orientation">vertical</property>
                                        <property name="spacing">12</property>
                                        <child>
                                          <object class="GtkImage">
                                            <property name="icon-name">lucide-search-symbolic</property>
                                            <property name="pixel-size">44</property>
                                            <style>
                                              <class name="dimmed"/>
                                            </style>
                                          </object>
                                        </child>
                                        <child>
                                          <object class="GtkLabel">
                                            <property name="label" translatable="yes">Search for group chats globally
(press Return to start search)</property>
                                            <property name="justify">center</property>
                                            <property name="wrap">1</property>
                                            <property name="max-width-chars">35</property>
                                            <style>
                                              <class name="dimmed"/>
                                            </style>
                                          </object>
                                        </child>
                                      </object>
                                    </property>
                                  </object>
                                </child>
<child>
                                  <object class="GtkStackPage">
                                    <property name="name">global-search-no-results</property>
                                    <property name="child">
                                      <object class="GtkBox">
                                        <property name="halign">center</property>
                                        <property name="valign">center</property>
                                        <property name="orientation">vertical</property>
                                        <property name="spacing">12</property>
                                        <child>
                                          <object class="GtkImage">
                                            <property name="icon-name">lucide-search-symbolic</property>
                                            <property name="pixel-size">44</property>
                                            <style>
                                              <class name="dimmed"/>
                                            </style>
                                          </object>
                                        </child>
                                        <child>
                                          <object class="GtkLabel">
                                            <property name="label" translatable="yes">No results</property>
                                            <style>
                                              <class name="dimmed"/>
                                            </style>
                                          </object>
                                        </child>
                                      </object>
                                    </property>
                                  </object>
                                </child>
                                <child>
                                  <object class="GtkStackPage">
                                    <property name="name">global-search-progress</property>
                                    <property name="child">
                                      <object class="GtkBox">
                                        <property name="halign">center</property>
                                        <property name="valign">center</property>
                                        <property name="orientation">vertical</property>
                                        <property name="spacing">12</property>
                                        <child>
                                          <object class="AdwSpinner">
                                            <property name="width-request">200</property>
                                            <property name="height-request">32</property>
                                          </object>
                                        </child>
                                        <child>
                                          <object class="GtkLabel" id="global_search_results_label">
                                            <property name="label"/>
                                          </object>
                                        </child>
                                        <style>
                                          <class name="toolbar"/>
                                          <class name="osd"/>
                                        </style>
                                      </object>
                                    </property>
                                  </object>
                                </child>
                              </object>
                            </child>
                          </object>
                        </property>
                      </object>
                    </child>
                  </object>
                </child>
              </object>
            </child>
          </object>
        </property>
      </object>
    </child>
    <child>
      <object class="GtkStackPage">
        <property name="name">progress</property>
        <property name="child">
          <object class="GtkBox">
            <property name="orientation">vertical</property>
            <child>
              <object class="AdwSpinner" id="spinner">
                <property name="halign">center</property>
                <property name="valign">center</property>
                <property name="vexpand">1</property>
              </object>
            </child>
          </object>
        </property>
      </object>
    </child>
    <child>
      <object class="GtkStackPage">
        <property name="name">error</property>
        <property name="child">
          <object class="GtkBox">
            <property name="orientation">vertical</property>
            <child>
              <object class="GtkBox">
                <property name="vexpand">1</property>
                <property name="orientation">vertical</property>
                <property name="spacing">12</property>
                <property name="homogeneous">1</property>
                <child>
                  <object class="GtkImage">
                    <property name="valign">end</property>
                    <property name="icon-name">lucide-circle-x-symbolic</property>
                    <property name="pixel-size">48</property>
                  </object>
                </child>
                <child>
                  <object class="GtkLabel" id="error_label">
                    <property name="valign">start</property>
                    <property name="justify">center</property>
                    <property name="wrap">1</property>
                    <style>
                      <class name="title-3"/>
                    </style>
                  </object>
                </child>
              </object>
            </child>
            <child>
              <object class="GtkButton" id="error_back_button">
                <property name="label" translatable="yes">_Back</property>
                <property name="focusable">1</property>
                <property name="receives-default">1</property>
                <property name="halign">start</property>
                <property name="use-underline">1</property>
              </object>
            </child>
            <style>
              <class name="m-18"/>
            </style>
          </object>
        </property>
      </object>
    </child>
    <child>
      <object class="GtkStackPage">
        <property name="name">info</property>
        <property name="child">
          <object class="GtkBox" id="info_box">
            <property name="orientation">vertical</property>
            <property name="spacing">6</property>
            <child>
              <placeholder/>
            </child>
            <child>
              <object class="GtkBox">
                <child>
                  <object class="GtkButton" id="info_back_button">
                    <property name="label" translatable="yes">_Back</property>
                    <property name="focusable">1</property>
                    <property name="receives-default">1</property>
                    <property name="halign">start</property>
                    <property name="use-underline">1</property>
                  </object>
                </child>
                <child>
                  <object class="GtkBox" id="join_box">
                    <property name="halign">end</property>
                    <property name="hexpand">true</property>
                    <child>
                      <placeholder/>
                    </child>
                    <child>
                      <object class="GtkButton" id="join_button">
                        <property name="label" translatable="yes">_Join</property>
                        <property name="focusable">1</property>
                        <property name="receives-default">1</property>
                        <property name="halign">end</property>
                        <property name="use-underline">1</property>
                        <style>
                          <class name="suggested-action"/>
                        </style>
                      </object>
                    </child>
                    <style>
                      <class name="linked"/>
                    </style>
                  </object>
                </child>
              </object>
            </child>
            <style>
              <class name="m-18"/>
            </style>
          </object>
        </property>
      </object>
    </child>
    <child>
      <object class="GtkStackPage">
        <property name="name">account</property>
        <property name="child">
          <object class="GtkBox">
            <property name="orientation">vertical</property>
            <property name="spacing">6</property>
            <child>
              <object class="GtkLabel">
                <property name="label" translatable="yes">Select Account</property>
                <property name="justify">center</property>
                <property name="wrap">1</property>
                <style>
                  <class name="title-2"/>
                  <class name="m-12"/>
                </style>
              </object>
            </child>
            <child>
              <object class="GtkScrolledWindow">
                <property name="focusable">1</property>
                <property name="vexpand">1</property>
                <property name="has-frame">1</property>
                <property name="hscrollbar-policy">never</property>
                <property name="child">
                  <object class="GtkTreeView" id="account_view">
                    <property name="focusable">1</property>
                    <property name="headers-visible">0</property>
                    <property name="enable-search">0</property>
                    <property name="show-expanders">0</property>
                    <child internal-child="selection">
                      <object class="GtkTreeSelection"/>
                    </child>
                    <child>
                      <object class="GtkTreeViewColumn">
                        <child>
                          <object class="GtkCellRendererPixbuf" id="icon_pixbuf"/>
                          <attributes>
                            <attribute name="pixbuf">0</attribute>
                          </attributes>
                        </child>
                      </object>
                    </child>
                    <child>
                      <object class="GtkTreeViewColumn">
                        <child>
                          <object class="GtkCellRendererText" id="account_text"/>
                          <attributes>
                            <attribute name="text">2</attribute>
                          </attributes>
                        </child>
                      </object>
                    </child>
                    <style>
                      <class name="start-chat-treeview"/>
                    </style>
                  </object>
                </property>
              </object>
            </child>
            <child>
              <object class="GtkBox">
                <property name="homogeneous">1</property>
                <child>
                  <object class="GtkButton" id="account_back_button">
                    <property name="label" translatable="yes">_Back</property>
                    <property name="focusable">1</property>
                    <property name="receives-default">1</property>
                    <property name="halign">start</property>
                    <property name="use-underline">1</property>
                  </object>
                </child>
                <child>
                  <object class="GtkButton" id="account_select_button">
                    <property name="label" translatable="yes">_Select</property>
                    <property name="focusable">1</property>
                    <property name="receives-default">1</property>
                    <property name="halign">end</property>
                    <property name="use-underline">1</property>
                    <style>
                      <class name="suggested-action"/>
                    </style>
                  </object>
                </child>
              </object>
            </child>
            <style>
              <class name="m-18"/>
            </style>
          </object>
        </property>
      </object>
    </child>
    <child>
      <placeholder/>
    </child>
  </object>
</interface>
