aboutsummaryrefslogtreecommitdiff
path: root/main/data
diff options
context:
space:
mode:
authorfiaxh <git@lightrise.org>2025-11-14 21:29:00 -0600
committerfiaxh <git@lightrise.org>2025-11-14 21:32:41 -0600
commitd479ba81a66a835913697bacf3a0d912ef68346a (patch)
tree9e2e0f81b81bf02bc199d80d428c67259e516dca /main/data
parent52a0d3544ec054edff1e0a67c800a7c18d3c689f (diff)
Make FileOverlay a proper Dialog
Diffstat (limited to 'main/data')
-rw-r--r--main/data/conversation_view.ui88
-rw-r--r--main/data/file_send_overlay.ui85
-rw-r--r--main/data/style.css12
3 files changed, 64 insertions, 121 deletions
diff --git a/main/data/conversation_view.ui b/main/data/conversation_view.ui
index 099758a3..7baac756 100644
--- a/main/data/conversation_view.ui
+++ b/main/data/conversation_view.ui
@@ -2,78 +2,50 @@
<interface>
<template class="DinoUiConversationView">
<child>
- <object class="GtkOverlay" id="overlay">
+ <object class="GtkBox">
+ <property name="orientation">vertical</property>
+ <style>
+ <class name="dino-conversation"/>
+ </style>
<child>
- <object class="GtkBox">
- <property name="orientation">vertical</property>
- <style>
- <class name="dino-conversation"/>
- </style>
+ <object class="GtkOverlay" id="conversation_overlay">
+ <property name="vexpand">True</property>
<child>
- <object class="GtkOverlay" id="conversation_overlay">
- <property name="vexpand">True</property>
+ <object class="DinoUiConversationSummaryConversationView" id="conversation_frame">
+ </object>
+ </child>
+ <child type="overlay">
+ <object class="GtkRevealer" id="goto_end_revealer">
+ <property name="halign">end</property>
+ <property name="valign">end</property>
+ <property name="transition-type">crossfade</property>
+ <property name="margin-end">30</property>
+ <property name="margin-bottom">30</property>
<child>
- <object class="DinoUiConversationSummaryConversationView" id="conversation_frame">
- </object>
- </child>
- <child type="overlay">
- <object class="GtkRevealer" id="goto_end_revealer">
+ <object class="GtkButton" id="goto_end_button">
+ <property name="width-request">30</property>
+ <property name="height-request">30</property>
+ <property name="vexpand">False</property>
<property name="halign">end</property>
<property name="valign">end</property>
- <property name="transition-type">crossfade</property>
- <property name="margin-end">30</property>
- <property name="margin-bottom">30</property>
+ <style>
+ <class name="circular"/>
+ <class name="opaque"/>
+ </style>
<child>
- <object class="GtkButton" id="goto_end_button">
- <property name="width-request">30</property>
- <property name="height-request">30</property>
- <property name="vexpand">False</property>
- <property name="halign">end</property>
- <property name="valign">end</property>
- <style>
- <class name="circular"/>
- <class name="opaque"/>
- </style>
- <child>
- <object class="GtkImage">
- <property name="icon-name">go-down-symbolic</property>
- <property name="icon-size">1</property>
- </object>
- </child>
+ <object class="GtkImage">
+ <property name="icon-name">go-down-symbolic</property>
+ <property name="icon-size">1</property>
</object>
</child>
</object>
</child>
</object>
</child>
- <child>
- <object class="DinoUiChatInputView" id="chat_input">
- </object>
- </child>
</object>
</child>
- <child type="overlay">
- <object class="GtkRevealer" id="white_revealer">
- <property name="transition-type">crossfade</property>
- <property name="transition-duration">200</property>
- <property name="reveal-child">False</property>
- <property name="visible">False</property>
- <child>
- <object class="GtkBox">
- <property name="opacity">0.7</property>
- <style>
- <class name="dino-white-overlay"/>
- </style>
- </object>
- </child>
- </object>
- </child>
- <child type="overlay">
- <object class="GtkRevealer" id="content_revealer">
- <property name="transition-type">crossfade</property>
- <property name="transition-duration">100</property>
- <property name="reveal-child">False</property>
- <property name="visible">False</property>
+ <child>
+ <object class="DinoUiChatInputView" id="chat_input">
</object>
</child>
</object>
diff --git a/main/data/file_send_overlay.ui b/main/data/file_send_overlay.ui
index 15ff35ef..77e5bd5e 100644
--- a/main/data/file_send_overlay.ui
+++ b/main/data/file_send_overlay.ui
@@ -1,73 +1,56 @@
<?xml version="1.0" encoding="UTF-8"?>
<interface>
<requires lib="gtk" version="4.0"/>
- <object class="GtkBox" id="main_box">
- <property name="hexpand">0</property>
- <property name="vexpand">0</property>
- <property name="halign">center</property>
- <property name="valign">center</property>
- <style>
- <class name="background"/>
- <class name="dino-file-overlay"/>
- </style>
+ <template class="DinoUiFileSendOverlay">
+ <property name="title" translatable="1">Send a file</property>
+ <property name="content-width">400</property>
<child>
<object class="GtkBox">
<property name="orientation">vertical</property>
- <property name="margin-end">20</property>
- <property name="margin-start">20</property>
+ <child>
+ <object class="AdwHeaderBar">
+ <style>
+ <class name="flat"/>
+ </style>
+ </object>
+ </child>
<child>
<object class="GtkBox">
- <property name="margin-top">10</property>
- <property name="margin-bottom">10</property>
+ <property name="margin-start">14</property>
+ <property name="margin-end">14</property>
+ <property name="margin-top">14</property>
+ <property name="margin-bottom">14</property>
+ <property name="halign">center</property>
+ <property name="valign">center</property>
+ <property name="spacing">14</property>
+ <property name="orientation">vertical</property>
<child>
- <object class="GtkLabel">
- <property name="label" translatable="1">Send a file</property>
- <property name="hexpand">1</property>
- <attributes>
- <attribute name="weight" value="PANGO_WEIGHT_BOLD"></attribute>
- </attributes>
+ <object class="DinoUiSizingBin" id="file_widget_insert">
+ <property name="halign">center</property>
</object>
</child>
<child>
- <object class="GtkButton" id="close_button">
- <property name="focusable">1</property>
- <style>
- <class name="titlebutton"/>
- <class name="close"/>
- </style>
+ <object class="GtkBox">
+ <property name="halign">end</property>
+ <property name="spacing">5</property>
+ <child>
+ <object class="GtkLabel" id="info_label"/>
+ </child>
<child>
- <object class="GtkImage">
- <property name="icon-name">window-close-symbolic</property>
+ <object class="GtkButton" id="send_button">
+ <property name="label" translatable="1">Send</property>
+ <property name="focusable">1</property>
+ <signal name="clicked" handler="on_send_button_clicked" />
+ <style>
+ <class name="suggested-action"/>
+ </style>
</object>
</child>
</object>
</child>
</object>
</child>
- <child>
- <object class="DinoUiSizingBin" id="file_widget_insert">
- </object>
- </child>
- <child>
- <object class="GtkBox">
- <property name="margin-top">15</property>
- <property name="margin-bottom">15</property>
- <property name="spacing">5</property>
- <child>
- <object class="GtkLabel" id="info_label"/>
- </child>
- <child>
- <object class="GtkButton" id="send_button">
- <property name="label" translatable="1">Send</property>
- <property name="focusable">1</property>
- <style>
- <class name="suggested-action"/>
- </style>
- </object>
- </child>
- </object>
- </child>
</object>
</child>
- </object>
+ </template>
</interface> \ No newline at end of file
diff --git a/main/data/style.css b/main/data/style.css
index 5762d264..625534f2 100644
--- a/main/data/style.css
+++ b/main/data/style.css
@@ -233,18 +233,6 @@ window.dino-main .dino-sidebar frame.auto-complete list > row {
transition: none;
}
-/* File overlay */
-
-window.dino-main .dino-white-overlay {
- background: @theme_base_color;
-}
-
-window.dino-main .dino-file-overlay {
- border-radius: 5px;
- border: 1px solid alpha(black, 0.2);
- box-shadow: 0 2px 3px alpha(black, 0.1);
-}
-
/* Chat Input*/
/* These rules are direved from the libadwaita style for activateable entry rows */