Commit Graph

40 Commits

Author SHA1 Message Date
William Casarin
69b7581a53 Notedeck Alpha 2 Release - v0.3
Thanks again to kernel and ken, as well as some new contributors:
kieran, daniel saxton for our alpha 2 release!

Added
=====

- Clicking a mention now opens profile page (William Casarin)
- Note previews when hovering reply descriptions (William Casarin)
- Media uploads (kernelkind)
- Profile editing (kernelkind)
- Add hashtags to posts (Daniel Saxton)
- Enhanced command-line interface for user interactions (Ken Sedgwick)
- Various Android updates and compatibility improvements (Ken Sedgwick, William Casarin)
- Debug features for user relay-list and mute list synchronization (Ken Sedgwick)

Changed
=======

- Add confirmation when deleting columns (kernelkind)
- Enhance Android build and performance (Ken Sedgwick)
- Image cache handling using sha256 hash (kieran)
- Introduction of decks_cache and improvements (kernelkind)
- Migrated to egui v0.29.1 (William Casarin)
- Only show column delete button when not navigating (William Casarin)
- Show profile pictures in column headers (William Casarin)
- Show usernames in user columns (William Casarin)
- Switch to only notes & replies on some tabs (William Casarin)
- Tombstone muted notes (Ken)
- Pointer interactions enhancements in UI (William Casarin)
- Persistent theme setup across sessions (kernelkind)
- Increased ping intervals for network performance (William Casarin)
- Nostrdb update for async support (Ken Sedgwick)

Fixed
=====

- Fix GIT_COMMIT_HASH compilation issue (William Casarin)
- Fix avatar alignment in profile previews (William Casarin)
- Fix broken quote repost hitbox (William Casarin)
- Fix crash when navigating in debug mode (William Casarin)
- Fix long delays when reconnecting (William Casarin)
- Fix repost button size (William Casarin)
- Fixed since kind filters (kernelkind)
- Clippy warnings resolved (Dimitris Apostolou)

Refactoring & Improvements
==========================

- Numerous internal structural improvements and modularization (William Casarin, Ken Sedgwick)

Signed-off-by: William Casarin <jb55@jb55.com>
2025-01-31 10:31:07 -08:00
William Casarin
478603e16e contacts: disable hashtag follows for now
People are spamming hashtags with AI CP. Let's disable this until we
at least have image blurring.

Alternatively we could only show the link for people you don't follow.

Signed-off-by: William Casarin <jb55@jb55.com>
2025-01-27 12:30:22 -08:00
William Casarin
0c3db9a31e Merge additional account relay list improvements from Ken
Ken Sedgwick (1):
      additional account relay list improvements
2025-01-25 16:16:03 -08:00
Dimitris Apostolou
2c8f6298b8 Fix clippy warnings
Signed-off-by: Dimitris Apostolou <dimitris.apostolou@icloud.com>
2025-01-24 19:32:24 +02:00
Ken Sedgwick
1e0801f54b additional account relay list improvements
- Use the current selected account only to determine desired
  relays. Previously the desired relay list was determined from the
  union of all accounts.
- Update the relay configuration immediately when the user switches accounts.
- Delete relays from the account (instead of the relay pool
  directly). This results in the relay being removed in the pool as
  well, but is persisted correctly.
2025-01-23 16:07:49 -08:00
William Casarin
2cbae68a7f Merge remote-tracking branches 'github/pr/657' and 'github/pr/658' 2025-01-22 16:04:45 -08:00
Ken Sedgwick
94a1d78114 publish NIP-65 relay lists 2025-01-22 15:16:08 -08:00
Ken Sedgwick
3278d3ba16 upgrade url string to RelaySpec for [read|write] markers
I think RelaySpec wants to move to enostr so the RelayPool can support
read and write relays ...
2025-01-22 12:43:05 -08:00
Ken Sedgwick
fe3e2dad14 add Accounts::add_advertised_relay 2025-01-21 16:03:44 -08:00
Ken Sedgwick
366ca24ac1 drive-by clippy fixes 2025-01-21 10:18:37 -08:00
kieran
0249b5ab04 Always update accounts 2025-01-21 10:29:22 +00:00
kieran
01066bfb3d export enostr / nostrdb 2025-01-21 09:43:54 +00:00
William Casarin
835851ee52 Merge remote-tracking branch 'pr/656' 2025-01-20 15:51:03 -08:00
kieran
86e68b1c29 move Notedeck to notedeck crate 2025-01-20 23:25:31 +00:00
kieran
c401f4c484 note-ref: derive hash 2025-01-20 20:33:49 +00:00
William Casarin
4b542c0a74 switch to TimelineCache
Signed-off-by: William Casarin <jb55@jb55.com>
2025-01-19 14:18:59 -08:00
William Casarin
a94ebc3603 mutes: hide logs
these are getting spammed on each frame. not ideal

Signed-off-by: William Casarin <jb55@jb55.com>
2025-01-19 12:43:03 -08:00
William Casarin
f9a09ea2be note: introduce RootNoteId
RootNoteId is simply a newtype for specifying an ID that is a root note
id (in the sense of a nip10 note)

This makes it more clear at the type level when referring to note ids

Signed-off-by: William Casarin <jb55@jb55.com>
2025-01-19 12:43:03 -08:00
kieran
1a744d8e3b image-cache: remove expect 2025-01-10 09:31:04 +00:00
kieran
eaa9b3ae4c image-cache: migrate storage 2025-01-09 20:40:35 +00:00
kieran
06417ff69e image-cache: use sha256 hash of url for key 2025-01-07 12:00:46 +00:00
William Casarin
e08e30f912 mutes: simplify mutefun and don't render tombstone yet 2025-01-04 16:19:41 -08:00
William Casarin
212c296da5 Merge tombstone muted notes #606
Changelog-Changed: Tombstone muted notes
2025-01-04 14:16:16 -08:00
William Casarin
16b20568da Merge relay debug view
Fix a few conflicts
2025-01-04 13:54:29 -08:00
William Casarin
e1187c372f Merge profiling editing #625
Changelog-Added: Added profile editing
2025-01-04 13:18:31 -08:00
William Casarin
fe6206c546 Note multicasting
This is an initial implementation of note multicast, which sends posted
notes to other notedecks on the same network.

This came about after I nerd sniped myself thinking about p2p nostr on
local networks[1]

You can test this exclusively without joining any other relays by
passing -r multicast on the command line.

[1] https://damus.io/note1j50pseqwma38g3aqrsnhvld0m0ysdgppw6fjnvvcj0haeulgswgq80lpca

Signed-off-by: William Casarin <jb55@jb55.com>
2025-01-04 10:37:11 -08:00
kernelkind
5fd9f32ba7 prelim fns for edit profiles
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-01-03 18:39:35 -05:00
kernelkind
eac24ac982 get bolded font helper
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-01-03 18:39:35 -05:00
Ken Sedgwick
e193e00539 Mute rendering instead of ingress
Previous approach was to keep muted content from getting inserted.

Instead, this version alters it's display.  This makes toggling mutes
on and off externally much more stable (the display changes but we
don't have to rebuild content trees)

For now muted content is collapsed to a red "Muted" tombstone w/ a reason.
2025-01-02 15:21:14 -08:00
kernelkind
d88036ecba add relay_debug arg
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-01-01 15:57:08 -05:00
William Casarin
fcac49a0a5 previews: run previews as notedeck apps
This allows ./preview to be a notedeck app runner. I am currently
using it for the ProfilePic app (which will because notedeck_viz)

Signed-off-by: William Casarin <jb55@jb55.com>
2024-12-20 15:39:26 -08:00
William Casarin
475314da75 columns: navigate back when switching account
Fixes: https://github.com/damus-io/notedeck/issues/600
Signed-off-by: William Casarin <jb55@jb55.com>
2024-12-20 13:54:20 -08:00
William Casarin
6fa6a5733e timeline: auto-add yourself to your home timeline
This is the most intuitive, and damus iOS does the same thing. You
have to follow yourself, sorry. Otherwise you won't see your posts
when you post which is confusing.

Fixes: https://github.com/damus-io/notedeck/issues/509
2024-12-19 07:21:15 -08:00
kernelkind
544a41e695 helper method for FontId
Signed-off-by: kernelkind <kernelkind@gmail.com>
Signed-off-by: William Casarin <jb55@jb55.com>
2024-12-18 11:05:03 -08:00
Ken Sedgwick
0c29c89909 need mutable ndb reference to unsubscribe
Closes: https://github.com/damus-io/notedeck/pull/584
2024-12-17 08:57:06 -08:00
Ken Sedgwick
926a3f80f4 ndb.get_notekey_by_id now returns NoteKey
Closes: https://github.com/damus-io/notedeck/pull/584
2024-12-17 08:57:04 -08:00
William Casarin
c874606af5 tests: add --testrunner flag so that column tests dont fail on startup
We added a startup panic to prevent users from running as debug mode,
our tests are also hitting this. Add a new --testrunner flag which
skips this check. We want this separate from the --debug flag so that
the tests have a more consistent runtime environment.

Signed-off-by: William Casarin <jb55@jb55.com>
2024-12-13 10:01:53 -08:00
William Casarin
ec755493d9 Introducing Damus Notedeck: a nostr browser
This splits notedeck into:

- notedeck
- notedeck_chrome
- notedeck_columns

The `notedeck` crate is the library that `notedeck_chrome` and
`notedeck_columns`, use. It contains common functionality related to
notedeck apps such as the NoteCache, ImageCache, etc.

The `notedeck_chrome` crate is the binary and ui chrome. It is
responsible for managing themes, user accounts, signing, data paths,
nostrdb, image caches etc. It will eventually have its own ui which has
yet to be determined.  For now it just manages the browser data, which
is passed to apps via a new struct called `AppContext`.

`notedeck_columns` is our columns app, with less responsibility now that
more things are handled by `notedeck_chrome`

There is still much work left to do before this is a proper browser:

- process isolation
- sandboxing
- etc

This is the beginning of a new era! We're just getting started.

Signed-off-by: William Casarin <jb55@jb55.com>
2024-12-12 20:08:55 -08:00
kernelkind
2ce845c1fc log: only show notedeck logs
Closes: https://github.com/damus-io/notedeck/pull/563
Signed-off-by: kernelkind <kernelkind@gmail.com>
Signed-off-by: William Casarin <jb55@jb55.com>
2024-12-11 12:10:06 -08:00
William Casarin
74c5f0c748 split notedeck into crates
This splits notedeck into crates, separating the browser chrome and
individual apps:

* notedeck: binary file, browser chrome
* notedeck_columns: our columns app
* enostr: same as before

We still need to do more work to cleanly separate the chrome apis
from the app apis. Soon I will create notedeck-notebook to see what
makes sense to be shared between the apps.

Some obvious ones that come to mind:

1. ImageCache

We will likely want to move this to the notedeck crate, as most apps
will want some kind of image cache. In web browsers, web pages do not
need to worry about this, so we will likely have to do something similar

2. Ndb

Since NdbRef is threadsafe and Ndb is an Arc<NdbRef>, it can be safely
copied to each app. This will simplify things. In the future we might
want to create an abstraction over this? Maybe each app shouldn't have
access to the same database... we assume the data in DBs are all public
anyways, but if we have unwrapped giftwraps that could be a problem.

3. RelayPool / Subscription Manager

The browser should probably maintain these. Then apps can use ken's
high level subscription manager api and not have to worry about
connection pool details

4. Accounts

Accounts and key management should be handled by the chrome. Apps should
only have a simple signer interface.

That's all for now, just something to think about!

Signed-off-by: William Casarin <jb55@jb55.com>
2024-12-11 11:24:29 -08:00