Compare commits

...

39 Commits

Author SHA1 Message Date
5a387f5b4d chore(deps): lock file maintenance
Some checks failed
Continuous integration / Check (push) Successful in 2m9s
Continuous integration / Trunk (push) Successful in 1m21s
Continuous integration / Test Suite (push) Successful in 3m13s
Continuous integration / Rustfmt (push) Failing after 47s
Continuous integration / Disallow unused dependencies (push) Successful in 3m4s
Continuous integration / build (push) Successful in 6m34s
2026-02-03 16:33:01 +00:00
b9df41559f Merge pull request 'chore(deps): update rust crate clap to v4.5.57' (#249) from renovate/all-minor-patch into master
Some checks failed
Continuous integration / Check (push) Successful in 1m50s
Continuous integration / Test Suite (push) Successful in 3m11s
Continuous integration / Trunk (push) Successful in 2m1s
Continuous integration / Rustfmt (push) Failing after 1m33s
Continuous integration / Disallow unused dependencies (push) Failing after 29s
Continuous integration / build (push) Successful in 2m7s
2026-02-03 08:16:57 -08:00
4bb5307904 chore(deps): update rust crate clap to v4.5.57
Some checks failed
Continuous integration / Check (push) Successful in 1m47s
Continuous integration / Trunk (push) Successful in 1m1s
Continuous integration / Test Suite (push) Successful in 3m14s
Continuous integration / Rustfmt (push) Failing after 50s
Continuous integration / Disallow unused dependencies (push) Successful in 2m35s
Continuous integration / build (push) Successful in 3m26s
2026-02-03 16:16:47 +00:00
0cbe860d0d Merge pull request 'chore(deps): update rust crate regex to v1.12.3' (#248) from renovate/all-minor-patch into master
Some checks failed
Continuous integration / Check (push) Successful in 1m29s
Continuous integration / Trunk (push) Successful in 1m3s
Continuous integration / Rustfmt (push) Failing after 44s
Continuous integration / Test Suite (push) Successful in 3m33s
Continuous integration / build (push) Successful in 2m12s
Continuous integration / Disallow unused dependencies (push) Successful in 5m42s
2026-02-03 06:31:26 -08:00
6eaedfaae8 chore(deps): update rust crate regex to v1.12.3
Some checks failed
Continuous integration / Check (push) Successful in 2m20s
Continuous integration / Test Suite (push) Successful in 4m12s
Continuous integration / Trunk (push) Successful in 2m18s
Continuous integration / Rustfmt (push) Failing after 59s
Continuous integration / Disallow unused dependencies (push) Successful in 2m36s
Continuous integration / build (push) Successful in 4m5s
2026-02-03 14:31:20 +00:00
d1787bac32 Merge pull request 'chore(deps): update rust crate flate2 to v1.1.9' (#247) from renovate/all-minor-patch into master
Some checks failed
Continuous integration / Check (push) Successful in 1m43s
Continuous integration / Trunk (push) Successful in 1m4s
Continuous integration / Rustfmt (push) Failing after 44s
Continuous integration / Test Suite (push) Successful in 3m26s
Continuous integration / build (push) Successful in 2m33s
Continuous integration / Disallow unused dependencies (push) Successful in 5m42s
2026-02-02 23:31:36 -08:00
58554e7f40 chore(deps): update rust crate flate2 to v1.1.9
Some checks failed
Continuous integration / Test Suite (push) Successful in 3m14s
Continuous integration / Check (push) Successful in 4m58s
Continuous integration / Rustfmt (push) Failing after 1m35s
Continuous integration / Trunk (push) Successful in 7m49s
Continuous integration / Disallow unused dependencies (push) Successful in 2m28s
Continuous integration / build (push) Successful in 7m50s
2026-02-03 07:31:27 +00:00
fa6fe673bd chore: Release
Some checks failed
Continuous integration / Check (push) Successful in 1m13s
Continuous integration / Test Suite (push) Successful in 2m2s
Continuous integration / Trunk (push) Successful in 59s
Continuous integration / Rustfmt (push) Failing after 47s
Continuous integration / build (push) Successful in 1m42s
Continuous integration / Disallow unused dependencies (push) Successful in 5m40s
2026-02-01 17:16:48 -08:00
44961f6ef1 web: conditionally show spam button in catchup 2026-02-01 17:16:24 -08:00
cd09594347 Merge pull request 'chore(deps): lock file maintenance' (#245) from renovate/lock-file-maintenance into master
Some checks failed
Continuous integration / Check (push) Successful in 1m8s
Continuous integration / Test Suite (push) Successful in 2m12s
Continuous integration / Rustfmt (push) Failing after 46s
Continuous integration / Trunk (push) Successful in 2m11s
Continuous integration / build (push) Successful in 2m0s
Continuous integration / Disallow unused dependencies (push) Successful in 5m47s
2026-02-01 16:02:24 -08:00
3d09ab7c15 chore(deps): lock file maintenance
Some checks failed
Continuous integration / Check (push) Successful in 2m11s
Continuous integration / Test Suite (push) Successful in 4m10s
Continuous integration / Rustfmt (push) Failing after 45s
Continuous integration / Trunk (push) Successful in 2m58s
Continuous integration / build (push) Successful in 3m48s
Continuous integration / Disallow unused dependencies (push) Successful in 5m46s
2026-02-02 00:02:21 +00:00
0cf3e3ce05 chore: Release
Some checks failed
Continuous integration / Check (push) Successful in 1m15s
Continuous integration / Trunk (push) Successful in 1m25s
Continuous integration / Test Suite (push) Successful in 2m54s
Continuous integration / Rustfmt (push) Failing after 1m7s
Continuous integration / build (push) Successful in 3m12s
Continuous integration / Disallow unused dependencies (push) Successful in 3m16s
2026-02-01 15:27:54 -08:00
d10a34e32e web: allow currently unused RemoveTag for symmetry 2026-02-01 15:27:25 -08:00
f311e517a9 chore: Release 2026-02-01 15:26:22 -08:00
aacee2f537 chore: Release 2026-02-01 15:25:23 -08:00
e2bec7760b web: don't return to search page when marking spam in catchup 2026-02-01 15:24:35 -08:00
a4ef7e48a6 web: add mark as spam button to catchup mode 2026-02-01 15:10:58 -08:00
1aa6f22461 chore: Release
Some checks failed
Continuous integration / Check (push) Successful in 1m24s
Continuous integration / Test Suite (push) Successful in 1m36s
Continuous integration / Trunk (push) Successful in 1m27s
Continuous integration / Rustfmt (push) Failing after 1m34s
Continuous integration / build (push) Successful in 2m35s
Continuous integration / Disallow unused dependencies (push) Successful in 5m43s
2026-02-01 09:05:58 -08:00
2f5026c75b server: disable lzma in zip to work around crc api error 2026-02-01 09:05:29 -08:00
dcb90ca2c8 Merge pull request 'chore(deps): update rust crate clap to v4.5.56' (#244) from renovate/all-minor-patch into master
Some checks failed
Continuous integration / Check (push) Failing after 1m4s
Continuous integration / Test Suite (push) Failing after 1m16s
Continuous integration / Trunk (push) Successful in 1m2s
Continuous integration / Rustfmt (push) Failing after 48s
Continuous integration / build (push) Failing after 1m16s
Continuous integration / Disallow unused dependencies (push) Failing after 4m56s
2026-01-29 08:46:27 -08:00
772548f10d chore(deps): update rust crate clap to v4.5.56
Some checks failed
Continuous integration / Test Suite (push) Failing after 1m27s
Continuous integration / Check (push) Failing after 1m52s
Continuous integration / Trunk (push) Successful in 1m4s
Continuous integration / Rustfmt (push) Failing after 1m34s
Continuous integration / build (push) Failing after 1m19s
Continuous integration / Disallow unused dependencies (push) Failing after 4m56s
2026-01-29 16:46:23 +00:00
c62e925016 Merge pull request 'chore(deps): update rust crate html2text to v0.16.7' (#243) from renovate/all-minor-patch into master
Some checks failed
Continuous integration / Test Suite (push) Failing after 1m12s
Continuous integration / Check (push) Failing after 1m51s
Continuous integration / Trunk (push) Successful in 1m26s
Continuous integration / Rustfmt (push) Failing after 1m34s
Continuous integration / Disallow unused dependencies (push) Failing after 28s
Continuous integration / build (push) Failing after 1m46s
2026-01-28 23:16:42 -08:00
4570a6ea1c chore(deps): update rust crate html2text to v0.16.7
Some checks failed
Continuous integration / Test Suite (push) Failing after 1m23s
Continuous integration / Check (push) Failing after 2m1s
Continuous integration / Rustfmt (push) Failing after 1m35s
Continuous integration / build (push) Failing after 28s
Continuous integration / Disallow unused dependencies (push) Failing after 4m59s
Continuous integration / Trunk (push) Successful in 8m1s
2026-01-29 07:16:38 +00:00
ae06df21a0 Merge pull request 'chore(deps): update rust crate askama to v0.15.4' (#242) from renovate/all-minor-patch into master
Some checks failed
Continuous integration / Check (push) Failing after 1m0s
Continuous integration / Test Suite (push) Failing after 1m21s
Continuous integration / Rustfmt (push) Failing after 1m27s
Continuous integration / build (push) Failing after 1m21s
Continuous integration / Disallow unused dependencies (push) Failing after 2m29s
Continuous integration / Trunk (push) Successful in 21m4s
2026-01-28 15:02:43 -08:00
02d43feb79 chore(deps): update rust crate askama to v0.15.4 2026-01-28 23:02:41 +00:00
0e6508498a Merge pull request 'chore(deps): update rust crate askama to v0.15.3' (#241) from renovate/all-minor-patch into master
Some checks failed
Continuous integration / Check (push) Failing after 1m3s
Continuous integration / Test Suite (push) Failing after 1m12s
Continuous integration / Trunk (push) Successful in 1m14s
Continuous integration / Rustfmt (push) Failing after 42s
Continuous integration / build (push) Failing after 1m15s
Continuous integration / Disallow unused dependencies (push) Failing after 2m19s
2026-01-27 16:16:38 -08:00
a94bd8a341 chore(deps): update rust crate askama to v0.15.3
Some checks failed
Continuous integration / Check (push) Failing after 1m57s
Continuous integration / Test Suite (push) Failing after 1m9s
Continuous integration / Rustfmt (push) Failing after 1m11s
Continuous integration / build (push) Failing after 1m30s
Continuous integration / Disallow unused dependencies (push) Failing after 2m51s
Continuous integration / Trunk (push) Successful in 21m26s
2026-01-28 00:16:35 +00:00
788baf9e86 Merge pull request 'chore(deps): update rust crate clap to v4.5.55' (#240) from renovate/all-minor-patch into master
Some checks failed
Continuous integration / Check (push) Failing after 1m1s
Continuous integration / Test Suite (push) Failing after 1m21s
Continuous integration / Trunk (push) Successful in 59s
Continuous integration / Rustfmt (push) Failing after 42s
Continuous integration / build (push) Failing after 1m18s
Continuous integration / Disallow unused dependencies (push) Failing after 4m53s
2026-01-27 12:46:31 -08:00
fdf910b1a1 chore(deps): update rust crate clap to v4.5.55
Some checks failed
Continuous integration / Test Suite (push) Failing after 1m15s
Continuous integration / Check (push) Failing after 1m55s
Continuous integration / Trunk (push) Successful in 1m0s
Continuous integration / Rustfmt (push) Failing after 1m35s
Continuous integration / build (push) Failing after 1m16s
Continuous integration / Disallow unused dependencies (push) Failing after 4m56s
2026-01-27 20:46:28 +00:00
714c94e40b Merge pull request 'chore(deps): update rust crate askama to v0.15.2' (#239) from renovate/all-minor-patch into master
Some checks failed
Continuous integration / Check (push) Failing after 1m16s
Continuous integration / Test Suite (push) Failing after 1m18s
Continuous integration / Trunk (push) Successful in 1m9s
Continuous integration / Rustfmt (push) Failing after 1m33s
Continuous integration / build (push) Failing after 1m44s
Continuous integration / Disallow unused dependencies (push) Failing after 4m58s
2026-01-27 07:46:48 -08:00
667893b6a3 chore(deps): update rust crate askama to v0.15.2
Some checks failed
Continuous integration / Test Suite (push) Failing after 1m55s
Continuous integration / Check (push) Failing after 4m53s
Continuous integration / Rustfmt (push) Failing after 1m35s
Continuous integration / build (push) Failing after 2m4s
Continuous integration / Trunk (push) Successful in 7m48s
Continuous integration / Disallow unused dependencies (push) Failing after 4m57s
2026-01-27 15:46:42 +00:00
687b050410 Merge pull request 'chore(deps): lock file maintenance' (#238) from renovate/lock-file-maintenance into master
Some checks failed
Continuous integration / Check (push) Failing after 1m31s
Continuous integration / Test Suite (push) Failing after 1m20s
Continuous integration / Trunk (push) Successful in 7m44s
Continuous integration / Rustfmt (push) Failing after 52s
Continuous integration / build (push) Failing after 1m21s
Continuous integration / Disallow unused dependencies (push) Failing after 2m25s
2026-01-25 19:31:55 -08:00
48bad8cbb0 chore(deps): lock file maintenance
Some checks failed
Continuous integration / Check (push) Failing after 58s
Continuous integration / Test Suite (push) Failing after 1m12s
Continuous integration / Rustfmt (push) Failing after 43s
Continuous integration / build (push) Failing after 3m37s
Continuous integration / Disallow unused dependencies (push) Failing after 2m51s
Continuous integration / Trunk (push) Successful in 21m3s
2026-01-26 03:31:53 +00:00
d156fe8282 Merge pull request 'chore(deps): lock file maintenance' (#237) from renovate/lock-file-maintenance into master
Some checks failed
Continuous integration / Check (push) Failing after 2m5s
Continuous integration / Test Suite (push) Failing after 3m28s
Continuous integration / Rustfmt (push) Failing after 46s
Continuous integration / build (push) Failing after 1m2s
Continuous integration / Disallow unused dependencies (push) Failing after 2m14s
Continuous integration / Trunk (push) Successful in 21m12s
2026-01-25 16:02:05 -08:00
fc66759e92 chore(deps): lock file maintenance
Some checks failed
Continuous integration / Check (push) Failing after 1m2s
Continuous integration / Test Suite (push) Failing after 1m11s
Continuous integration / Rustfmt (push) Failing after 1m36s
Continuous integration / Trunk (push) Successful in 7m46s
Continuous integration / Disallow unused dependencies (push) Failing after 2m18s
Continuous integration / build (push) Failing after 8m46s
2026-01-26 00:02:01 +00:00
fcdc2d56a9 Merge pull request 'chore(deps): update rust crate uuid to v1.20.0' (#236) from renovate/all-minor-patch into master
Some checks failed
Continuous integration / Check (push) Successful in 55s
Continuous integration / Test Suite (push) Successful in 1m20s
Continuous integration / Trunk (push) Successful in 7m49s
Continuous integration / Rustfmt (push) Failing after 48s
Continuous integration / build (push) Successful in 1m40s
Continuous integration / Disallow unused dependencies (push) Successful in 3m8s
2026-01-24 15:31:30 -08:00
60993abd6f chore(deps): update rust crate uuid to v1.20.0
Some checks failed
Continuous integration / Check (push) Successful in 1m0s
Continuous integration / Test Suite (push) Successful in 1m46s
Continuous integration / Rustfmt (push) Failing after 43s
Continuous integration / build (push) Successful in 1m27s
Continuous integration / Disallow unused dependencies (push) Successful in 2m40s
Continuous integration / Trunk (push) Successful in 21m14s
2026-01-24 23:31:28 +00:00
c1112e5538 Merge pull request 'chore(deps): update rust crate css-inline to v0.19.1' (#235) from renovate/all-minor-patch into master
Some checks failed
Continuous integration / Check (push) Successful in 58s
Continuous integration / Test Suite (push) Successful in 4m42s
Continuous integration / Rustfmt (push) Failing after 44s
Continuous integration / build (push) Successful in 1m26s
Continuous integration / Disallow unused dependencies (push) Successful in 2m28s
Continuous integration / Trunk (push) Successful in 21m17s
2026-01-23 07:16:21 -08:00
1b59c7a287 chore(deps): update rust crate css-inline to v0.19.1
Some checks failed
Continuous integration / Check (push) Successful in 2m38s
Continuous integration / Test Suite (push) Successful in 10m15s
Continuous integration / Trunk (push) Successful in 7m44s
Continuous integration / Rustfmt (push) Failing after 1m38s
Continuous integration / build (push) Successful in 4m54s
Continuous integration / Disallow unused dependencies (push) Successful in 5m43s
2026-01-23 15:16:17 +00:00
5 changed files with 278 additions and 221 deletions

430
Cargo.lock generated

File diff suppressed because it is too large Load Diff

View File

@@ -8,7 +8,7 @@ authors = ["Bill Thiede <git@xinu.tv>"]
edition = "2021"
license = "UNLICENSED"
publish = ["xinu"]
version = "0.17.61"
version = "0.17.66"
repository = "https://git.z.xinu.tv/wathiede/letterbox"
[profile.dev]

View File

@@ -56,7 +56,7 @@ urlencoding = "2.1.3"
#xtracing = { git = "http://git-private.h.xinu.tv/wathiede/xtracing.git" }
#xtracing = { path = "../../xtracing" }
xtracing = { version = "0.3.2", registry = "xinu" }
zip = "7.0.0"
zip = { version = "7.0.0", default-features = false, features = ["aes-crypto", "bzip2", "deflate64", "deflate", "time", "zstd"] }
[build-dependencies]

View File

@@ -224,6 +224,24 @@ pub fn update(msg: Msg, model: &mut Model, orders: &mut impl Orders<Msg>) {
});
}
Msg::AddTag(query, tag) => {
orders.skip().perform_cmd(async move {
let res: Result<
graphql_client::Response<graphql::add_tag_mutation::ResponseData>,
gloo_net::Error,
> = send_graphql(graphql::AddTagMutation::build_query(
graphql::add_tag_mutation::Variables {
query: query.clone(),
tag: tag.clone(),
},
))
.await;
if let Err(e) = res {
error!("Failed to add tag {tag} to {query}: {e}");
}
Msg::Refresh
});
}
Msg::AddTagAndGoToSearch(query, tag) => {
orders.skip().perform_cmd(async move {
let res: Result<
graphql_client::Response<graphql::add_tag_mutation::ResponseData>,
@@ -256,7 +274,24 @@ pub fn update(msg: Msg, model: &mut Model, orders: &mut impl Orders<Msg>) {
if let Err(e) = res {
error!("Failed to remove tag {tag} to {query}: {e}");
}
// TODO: reconsider this behavior
Msg::Refresh
});
}
Msg::RemoveTagAndGoToSearch(query, tag) => {
orders.skip().perform_cmd(async move {
let res: Result<
graphql_client::Response<graphql::remove_tag_mutation::ResponseData>,
gloo_net::Error,
> = send_graphql(graphql::RemoveTagMutation::build_query(
graphql::remove_tag_mutation::Variables {
query: query.clone(),
tag: tag.clone(),
},
))
.await;
if let Err(e) = res {
error!("Failed to remove tag {tag} to {query}: {e}");
}
Msg::GoToSearchResults
});
}
@@ -505,7 +540,7 @@ pub fn update(msg: Msg, model: &mut Model, orders: &mut impl Orders<Msg>) {
.join(" ");
orders
.skip()
.perform_cmd(async move { Msg::AddTag(threads, tag) });
.perform_cmd(async move { Msg::AddTagAndGoToSearch(threads, tag) });
}
}
Msg::SelectionRemoveTag(tag) => {
@@ -520,7 +555,7 @@ pub fn update(msg: Msg, model: &mut Model, orders: &mut impl Orders<Msg>) {
.join(" ");
orders
.skip()
.perform_cmd(async move { Msg::RemoveTag(threads, tag) });
.perform_cmd(async move { Msg::RemoveTagAndGoToSearch(threads, tag) });
}
}
Msg::SelectionMarkAsRead => {
@@ -692,6 +727,13 @@ pub fn update(msg: Msg, model: &mut Model, orders: &mut impl Orders<Msg>) {
};
orders.send_msg(Msg::CatchupNext);
}
Msg::CatchupMarkAsSpam => {
if let Some(thread_id) = current_thread_id(&model.context) {
orders.send_msg(Msg::AddTag(thread_id.clone(), "Spam".to_string()));
orders.send_msg(Msg::SetUnread(thread_id, false));
};
orders.send_msg(Msg::CatchupNext);
}
Msg::CatchupNext => {
orders.send_msg(Msg::ScrollToTop);
let Some(catchup) = &mut model.catchup else {
@@ -852,7 +894,10 @@ pub enum Msg {
SetUnread(String, bool),
AddTag(String, String),
AddTagAndGoToSearch(String, String),
#[allow(dead_code)]
RemoveTag(String, String),
RemoveTagAndGoToSearch(String, String),
Snooze(String, DateTime<Utc>),
FrontPageRequest {
@@ -902,6 +947,7 @@ pub enum Msg {
CatchupStart,
CatchupKeepUnread,
CatchupMarkAsRead,
CatchupMarkAsSpam,
CatchupNext,
CatchupExit,

View File

@@ -100,6 +100,7 @@ pub fn view(model: &Model) -> Node<Msg> {
&catchup.items,
is_loading,
model.read_completion_ratio,
true, // show spam button for email
)
} else {
normal_view(
@@ -127,6 +128,7 @@ pub fn view(model: &Model) -> Node<Msg> {
&catchup.items,
is_loading,
model.read_completion_ratio,
false, // no spam button for news
)
} else {
normal_view(
@@ -193,6 +195,7 @@ fn catchup_view(
items: &[CatchupItem],
is_loading: bool,
read_completion_ratio: f64,
show_spam_button: bool,
) -> Node<Msg> {
div![
C!["w-full", "relative", "text-white"],
@@ -268,6 +271,14 @@ fn catchup_view(
Msg::GoToSearchResults
]))
],
IF!(show_spam_button => button![
tw_classes::button(),
C!["text-red-500"],
attrs! {At::Title => "Mark as spam"},
span![i![C!["far", "fa-hand"]]],
span![C!["pl-2"], "Spam"],
ev(Ev::Click, |_| Msg::CatchupMarkAsSpam)
]),
button![
tw_classes::button_with_color("bg-green-800", "hover:bg-green-700"),
span![i![C!["far", "fa-envelope-open"]]],
@@ -450,7 +461,7 @@ fn removable_tags_chiclet<'a>(thread_id: &'a str, tags: &'a [String]) -> Node<Ms
a![
C![&tw_classes::TAG_X],
span![i![C!["fa-solid", "fa-xmark"]]],
ev(Ev::Click, move |_| Msg::RemoveTag(thread_id, rm_tag))
ev(Ev::Click, move |_| Msg::RemoveTagAndGoToSearch(thread_id, rm_tag))
]
]
})