chore: update gpui and nostr sdk

This commit is contained in:
2025-06-25 20:00:05 +07:00
parent edee9305cc
commit 3c2eaabab2
14 changed files with 209 additions and 295 deletions

View File

@@ -1,11 +1,11 @@
use gpui::{actions, impl_internal_actions};
use gpui::{actions, Action};
use serde::Deserialize;
#[derive(Clone, PartialEq, Eq, Deserialize)]
#[derive(Clone, Action, PartialEq, Eq, Deserialize)]
#[action(namespace = list, no_json)]
pub struct Confirm {
/// Is confirm with secondary.
pub secondary: bool,
}
actions!(list, [Cancel, SelectPrev, SelectNext]);
impl_internal_actions!(list, [Confirm]);

View File

@@ -2,9 +2,9 @@ use std::rc::Rc;
use gpui::prelude::FluentBuilder;
use gpui::{
div, impl_internal_actions, px, App, AppContext, Corner, Element, InteractiveElement,
IntoElement, ParentElement, RenderOnce, SharedString, StatefulInteractiveElement, Styled,
WeakEntity, Window,
div, px, Action, App, AppContext, Corner, Element, InteractiveElement, IntoElement,
ParentElement, RenderOnce, SharedString, StatefulInteractiveElement, Styled, WeakEntity,
Window,
};
use serde::Deserialize;
use theme::ActiveTheme;
@@ -14,11 +14,10 @@ use crate::input::InputState;
use crate::popover::{Popover, PopoverContent};
use crate::Icon;
#[derive(PartialEq, Clone, Debug, Deserialize)]
#[derive(Action, PartialEq, Clone, Debug, Deserialize)]
#[action(namespace = emoji, no_json)]
pub struct EmitEmoji(pub SharedString);
impl_internal_actions!(emoji, [EmitEmoji]);
#[derive(IntoElement)]
pub struct EmojiPicker {
icon: Option<Icon>,

View File

@@ -4,8 +4,8 @@ use std::rc::Rc;
use gpui::prelude::FluentBuilder as _;
use gpui::{
actions, div, impl_internal_actions, point, px, App, AppContext, Bounds, ClipboardItem,
Context, DefiniteLength, Entity, EntityInputHandler, EventEmitter, FocusHandle, Focusable,
actions, div, point, px, Action, App, AppContext, Bounds, ClipboardItem, Context,
DefiniteLength, Entity, EntityInputHandler, EventEmitter, FocusHandle, Focusable,
InteractiveElement as _, IntoElement, KeyBinding, KeyDownEvent, MouseButton, MouseDownEvent,
MouseMoveEvent, MouseUpEvent, ParentElement as _, Pixels, Point, Render, ScrollHandle,
ScrollWheelEvent, SharedString, Styled as _, Subscription, UTF16Selection, Window, WrappedLine,
@@ -24,14 +24,13 @@ use crate::history::History;
use crate::scroll::ScrollbarState;
use crate::Root;
#[derive(Clone, PartialEq, Eq, Deserialize)]
#[derive(Action, Clone, PartialEq, Eq, Deserialize)]
#[action(namespace = input, no_json)]
pub struct Enter {
/// Is confirm with secondary.
pub secondary: bool,
}
impl_internal_actions!(input, [Enter]);
actions!(
input,
[