Commit Graph

94 Commits

Author SHA1 Message Date
William Casarin
3d4db820b4 i18n: make localization context non-global
- Simplify Localization{Context,Manager} to just Localization
- Fixed a bunch of lifetime issueo
- Removed all Arcs and Locks
- Removed globals
  * widgets now need access to &mut Localization for i18n

Signed-off-by: William Casarin <jb55@jb55.com>
2025-07-22 09:49:32 -07:00
Terry Yiu
3f5036bd32 Internationalize user-facing strings and export them for translations
Changelog-Added: Internationalized user-facing strings and exported them for translations
Signed-off-by: Terry Yiu <git@tyiu.xyz>
2025-07-21 12:45:29 -07:00
William Casarin
c94a418474 media/trust: always show if its yourself
Signed-off-by: William Casarin <jb55@jb55.com>
2025-07-20 16:54:34 -07:00
William Casarin
8a1398face clippy fixes
Signed-off-by: William Casarin <jb55@jb55.com>
2025-07-17 13:54:43 -07:00
William Casarin
a4c1b38116 introduce HybridFilter
This introduces a new filter construct called HybridFilter. This allows
filters to have different remote filter than local ones. For example,
adding kind0 to the remote for keeping profiles up to date on your
timeline, but only subscribing to kind1 locally.

Only home/contact filters use this feature for now.

Fixes: https://github.com/damus-io/notedeck/issues/995
Signed-off-by: William Casarin <jb55@jb55.com>
2025-07-17 13:54:43 -07:00
William Casarin
99646f8ff5 ui/mention: fix weird mention text size
Fixes: https://github.com/damus-io/notedeck/issues/975
Signed-off-by: William Casarin <jb55@jb55.com>
2025-07-16 17:36:35 -07:00
William Casarin
64ac06791a Merge show-note-client option by fernando
We should move this somewhere else before we turn it on
officially

Fernando López Guevara (2):
      refactor: use Margin:ZERO
      feat(note-view): show note client
2025-07-16 14:07:42 -07:00
Fernando López Guevara
4bf75c95de feat(note-view): show note client 2025-07-16 17:09:59 -03:00
William Casarin
872aadf279 debug: fix memory debugger
Signed-off-by: William Casarin <jb55@jb55.com>
2025-07-16 11:17:13 -07:00
William Casarin
953848ff9a anim: reduce gif fps
it's brrrring my cpu on my 240hz monitor. we don't need 240hz gifs...

Signed-off-by: William Casarin <jb55@jb55.com>
2025-07-16 10:07:37 -07:00
William Casarin
461665f599 ui: remove show_pointer
This can just be achieved by on_hover_cursor

Didn't realize this.

Signed-off-by: William Casarin <jb55@jb55.com>
2025-07-16 09:17:27 -07:00
William Casarin
a517bc69bc Merge is_following fixes from kernel
kernelkind (4):
      add `Accounts` to `NoteContext`
      remove `MuteFun` prop
      make `Contacts::is_following` use bytes instead of `Pubkey`
      migrate to check following through `Contacts::is_following`
2025-07-16 08:50:58 -07:00
William Casarin
e2d79af632 Merge remote-tracking branch 'fernando/feat/full-screen-media-dots' 2025-07-16 08:31:57 -07:00
Fernando López Guevara
44da10dc88 fix(profile): split always 2025-07-16 11:01:13 -03:00
Fernando López Guevara
8e218a1eb1 feat(full-screen-media): add image URL in top bar and navigation dots in bottom bar 2025-07-16 09:30:58 -03:00
Fernando López Guevara
ac85bdc21d feat(profile-view): split nip05 when is_narrow 2025-07-15 14:42:43 -07:00
William Casarin
23d02a9dd2 note/options: remove redundant has function
there is a contains function generated by the bitflags macro

Signed-off-by: William Casarin <jb55@jb55.com>
2025-07-15 14:35:14 -07:00
William Casarin
fa545bc077 ui/note: fix weird ... placement regression
Fixes: c402320ad3 ("ui: fix broken note previews")
Fixes: https://github.com/damus-io/notedeck/issues/974
Signed-off-by: William Casarin <jb55@jb55.com>
2025-07-15 14:33:46 -07:00
William Casarin
4e3fcad709 ui/note: show full link type in unhandled mentions
Signed-off-by: William Casarin <jb55@jb55.com>
2025-07-15 08:28:33 -07:00
kernelkind
efae62024e migrate to check following through Contacts::is_following
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-07-14 21:34:33 -04:00
kernelkind
397bfce817 add Accounts to NoteContext
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-07-14 21:34:02 -04:00
William Casarin
c4084c4117 note_follows: remove unneeded derefence
Signed-off-by: William Casarin <jb55@jb55.com>
2025-07-14 14:16:05 -07:00
William Casarin
e4ca67127e Merge unknown profile improvements by kernel #955
kernelkind (1):
      allow body on unknown profile
2025-07-14 14:10:18 -07:00
William Casarin
c402320ad3 ui: fix broken note previews
Also made the options more clear

Fixes: https://github.com/damus-io/notedeck/issues/959
Fixes: b6348b1507 ("note/options: simplify flag logic")
Signed-off-by: William Casarin <jb55@jb55.com>
2025-07-14 14:05:41 -07:00
kernelkind
8c71e154f4 allow body on unknown profile
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-07-14 15:26:07 -04:00
William Casarin
96cb5e26ce Merge follow/unfollow from kernel
Jakub Gladysz (1):
      ui: add follow button

kernelkind (14):
      bump nostrdb
      move polling responsibility to `AccountData`
      `AccountData`: decouple query from constructor
      add constructor for `AccountData`
      add `Contacts`
      use `Contacts` in `AccountData`
      expose `AccountSubs`
      Unify sub for contacts in accounts & timeline
      move `styled_button_toggleable` to notedeck_ui
      construct NoteBuilder from existing note
      send kind 3 event
      add actions for follow/unfollow
      add UI for (un)follow
      send contact list event on account creation
2025-07-11 13:06:24 -07:00
William Casarin
26d027f03e nav: nav to accounts view for actions that require key
Fixes: https://github.com/damus-io/notedeck/issues/936
Signed-off-by: William Casarin <jb55@jb55.com>
2025-07-10 16:17:08 -07:00
William Casarin
605f6f4711 android: hide new post button when navigating
Fixes: https://github.com/damus-io/notedeck/issues/898
Signed-off-by: William Casarin <jb55@jb55.com>
2025-07-10 15:45:33 -07:00
William Casarin
b6348b1507 note/options: simplify flag logic
simpler, less macro magic

Signed-off-by: William Casarin <jb55@jb55.com>
2025-07-10 14:29:56 -07:00
William Casarin
41053dd5a5 ui/carousel: refactor to use indices
This refactors our carousel control a bit, it was getting
messy

Signed-off-by: William Casarin <jb55@jb55.com>
2025-07-10 12:09:30 -07:00
Jakub Gladysz
cc541cd4ff ui: add follow button
Signed-off-by: kernelkind <kernelkind@gmail.com>
Co-authored-by: Jakub Gladysz <jakub.gladysz@protonmail.com>
Co-authored-by: William Casarin <jb55@jb55.com>
2025-07-10 13:47:21 -04:00
kernelkind
8a77ba5f8f move styled_button_toggleable to notedeck_ui
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-07-10 13:47:19 -04:00
William Casarin
e97574fcdc Merge remote-tracking branch 'github/pr/916' 2025-07-10 09:16:17 -07:00
William Casarin
298fab6471 ui/narrow: restore padding
This is a bit too tight

Signed-off-by: William Casarin <jb55@jb55.com>
2025-07-10 09:12:08 -07:00
William Casarin
22cfaaf64a Merge remote-tracking branch 'github/pr/928' 2025-07-10 09:10:28 -07:00
William Casarin
13021afa58 Revert "feat(note-actionbar): refine icons"
icons are too blurry, lets fix that

This reverts commit e1bd1d3e8b.
2025-07-09 11:18:04 -07:00
Fernando López Guevara
ec25413433 feat(mobile): improve layout and behavior on narrow screens 2025-07-08 16:20:51 -07:00
Fernando López Guevara
e1bd1d3e8b feat(note-actionbar): refine icons 2025-07-07 23:28:08 -03:00
Fernando López Guevara
14421da16d feat(image_carousel): navigate media with arrow left/right keys 2025-07-02 20:25:49 -03:00
William Casarin
400050f3fb Merge remote-tracking branches 'github/pr/877' and 'github/pr/885'
Fernando López Guevara (2):
      fix(content): handle case where notes are not loaded
      feat(app_images): add module to manage static app image assets
2025-06-25 10:30:24 -07:00
Fernando López Guevara
36667bc024 feat(app_images): add module to manage static app image assets 2025-06-25 09:53:31 -07:00
Fernando López Guevara
c6dbb0e856 fix(content): handle case where notes are not loaded 2025-06-24 09:15:52 -07:00
William Casarin
5c31bf16c8 Merge remote-tracking branch 'github/pr/899' 2025-06-23 13:48:21 -07:00
kernelkind
87b4b5fc70 add preview flag to NoteAction
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-06-22 16:03:09 -04:00
kernelkind
51476772c4 add unread note indicator option to NoteView
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-06-22 16:00:42 -04:00
kernelkind
ea91f582ed add pfp bounding box to NoteResponse
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-06-22 16:00:40 -04:00
kernelkind
b7bab1d29f note: refactor to use action composition & reduce nesting
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-06-22 16:00:37 -04:00
kernelkind
c3b8823f72 ui: add hline_with_width
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-06-22 16:00:35 -04:00
valkuros@gmail.com
2bd824bc0a Changed line 683 from Persisted to temp per Minor bug #888 2025-06-17 21:48:38 -04:00
William Casarin
9033383a29 add input context menu helper
We are going to want this in more places

Signed-off-by: William Casarin <jb55@jb55.com>
2025-06-16 16:11:15 -07:00