216 Commits

Author SHA1 Message Date
William Casarin
968d9bc245 dave is alive
Signed-off-by: William Casarin <jb55@jb55.com>
2025-04-14 11:16:12 -07:00
kernelkind
fd2299f5f0 add hashbrown
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-04-08 22:50:00 -04:00
kernelkind
a7da4d6a11 add Zap
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-04-08 22:50:00 -04:00
kernelkind
7213c1b7eb add nwc dependency
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-04-04 18:52:43 -04:00
William Casarin
499bac5ca4 fix again 2025-03-23 18:49:04 -07:00
William Casarin
3cc46b8a7d attempt macos fix 2025-03-23 18:45:14 -07:00
William Casarin
a2a119ec5c nostrdb: add author_kind index 2025-03-23 13:00:20 -07:00
William Casarin
54deb2dd88 switch to profiling crates
This switches to the profiling crate for compatible
profiling between rust libraries.

To enable:

$ cargo build --release --features puffin

Feel free to experiment with other profiling backends
as well! Would be great to get tracy working.
2025-03-23 11:30:18 -07:00
kernelkind
69b651bbc5 remove security framework storage
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-03-22 00:06:31 -04:00
William Casarin
d1f38c3d19 Merge right click paste #507
jglad (1):
      #507 add right click paste in search
2025-03-21 16:46:49 -07:00
William Casarin
26b58683b8 feat: integrate nostrdb relay indexing
- Upgrade `nostrdb` to v0.6.1 with relay metadata support
- Switch to `nostr::RelayUrl` for typed relay URLs
- Use `process_event_with()` to pass relay info during ingestion
- Update `Relay`, `RelayPool`, and unknown ID logic accordingly

This enables richer indexing with relay provenance in events.

Signed-off-by: William Casarin <jb55@jb55.com>
2025-03-21 16:20:37 -07:00
jglad
318f96e37e #507 add right click paste in search
Signed-off-by: Jakub Gladysz <jakub.gladysz@protonmail.com>
2025-03-21 21:49:45 +01:00
William Casarin
2d801408b2 egui: bump to 0.31.1 2025-03-17 19:45:26 -07:00
William Casarin
beece0eb95 filter: fix memory leak in nostrdb Filter
Signed-off-by: William Casarin <jb55@jb55.com>
2025-03-17 16:44:51 -07:00
William Casarin
33f570678d android: switch to android-activity out of path
Signed-off-by: William Casarin <jb55@jb55.com>
2025-03-11 10:53:15 -07:00
William Casarin
bd85233120 android: capture current keyboard height
expose a new virtual_keyboard_height function under notedeck::platform::android

which gets the current height of the virtual keyboard. We can use this
to tranlate the view out of the way

Signed-off-by: William Casarin <jb55@jb55.com>
2025-03-11 10:53:13 -07:00
William Casarin
a168a38760 android: misc testing
Signed-off-by: William Casarin <jb55@jb55.com>
2025-03-11 10:52:29 -07:00
Ken Sedgwick
27f4acea1c WIP: use modified version of egui 2025-03-11 10:52:00 -07:00
William Casarin
51457a0260 android: update to latest winit/egui/android-activity
so we can start fixing this shit

Signed-off-by: William Casarin <jb55@jb55.com>
2025-03-11 10:51:56 -07:00
William Casarin
da9b2bcd46 android: 0.30.0 game activity
still no text input, at least it's not crashing

Signed-off-by: William Casarin <jb55@jb55.com>
2025-03-11 10:47:32 -07:00
William Casarin
b33346a25d update to egui 0.30.0 2025-03-11 10:47:32 -07:00
William Casarin
b21e39dea9 android: get GameActivity to launch
For some reason there are no touch inputs though

Signed-off-by: William Casarin <jb55@jb55.com>
2025-03-11 10:47:32 -07:00
William Casarin
63f8790380 FIX BUILD YET AGAIN
because i'm retarded

Signed-off-by: William Casarin <jb55@jb55.com>
2025-03-07 14:06:07 -08:00
William Casarin
e92e78126f windows: fix build due to outdated nostrdb-rs bindings
Signed-off-by: William Casarin <jb55@jb55.com>
2025-03-07 13:59:34 -08:00
William Casarin
e09df3e7c3 timeline: add nip50 search timelines
Fixes: https://github.com/damus-io/notedeck/issues/456
Signed-off-by: William Casarin <jb55@jb55.com>
2025-03-07 13:24:41 -08:00
William Casarin
d3bae69465 Merge avoid duplicate crates by rex4539 #746 2025-02-28 15:26:22 -08:00
kernelkind
5791b0c5b1 use mime_guess
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-02-25 16:49:00 -05:00
kernelkind
fa9e318e41 update ehttp to 0.5.0
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-02-25 16:49:00 -05:00
kernelkind
9466c10875 use bincode
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-02-25 16:49:00 -05:00
Dimitris Apostolou
cc5941e919 avoid duplicate crates 2025-02-24 22:06:37 +02:00
William Casarin
a95bc6ad5e egui: replace with damus-io repo
Signed-off-by: William Casarin <jb55@jb55.com>
2025-02-10 15:57:50 -08:00
kernelkind
07c6b27493 use updated TextEdit::layouter in egui
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-02-07 15:58:57 -05:00
Ken Sedgwick
482313f883 add relay hints to Mention::{Profile,Event} and UnknownIds 2025-02-06 10:08:01 -08:00
William Casarin
fd030f5b5c Merge rewrite deck serialization, timeline cache, add algo timelines #712
William Casarin (19):
      algos: introduce last_n_per_pubkey_from_tags
      wip algo timelines
      Initial token parser combinator
      token_parser: unify parsing and serialization
      token_serializer: introduce TokenWriter
      token_parser: simplify AddColumnRoute serialization
      tokens: add a more advanced tokens parser
      tokens: add AccountsRoute token serializer
      tokens: add PubkeySource and ListKinds token serializer
      tokens: add TimelineRoute token serializer
      tokens: initial Route token serializer
      add tokenator crate
      note_id: add hex helpers for root notes
      tokens: add token serialization for AlgoTimeline
      tokens: add token serialization for TimelineKind
      tokens: switch over to using token serialization
      Switch to unified timeline cache via TimelineKinds
      hashtags: click hashtags to open them
2025-02-05 18:46:16 -08:00
William Casarin
ae85f2dd34 version: bump to 0.3.1
Just a binary fix for ubuntu

Signed-off-by: William Casarin <jb55@jb55.com>
2025-02-04 11:51:16 -08:00
William Casarin
ed455f7ea4 add tokenator crate
also remove a lot of the "advanced" token parsing style
which was a bit too verbose for my tastes

Signed-off-by: William Casarin <jb55@jb55.com>
2025-02-04 08:08:08 -08:00
kernelkind
2bce115b21 import base64
Signed-off-by: kernelkind <kernelkind@gmail.com>
2025-01-24 15:43:48 -05:00
kieran
06417ff69e image-cache: use sha256 hash of url for key 2025-01-07 12:00:46 +00:00
William Casarin
c7d3aae856 nav: slow down nav animation a bit
you care barely see it
2025-01-04 16:01:24 -08:00
William Casarin
5f21d32d96 android: fix android logging 2025-01-04 13:14:05 -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
William Casarin
eeab1666e7 query: fix since filter on kind queries
Before kind queries with since filters wasn't working. Now it does.

Changelog-Fixed: Fixed since kind filters
2024-12-30 11:41:30 -08:00
William Casarin
11274ac4df nav: make back nav faster
Changed the egui-nav spring function so its now so slow near the
end of the aniation.

Fixes: https://github.com/damus-io/notedeck/issues/595
2024-12-18 13:04:09 -08:00
William Casarin
47e0b0ed52 nostrdb: update to fix sub memleak 2024-12-17 09:19:35 -08:00
Ken Sedgwick
e1a55c6532 update nostrdb-rs for async stream support
Closes: https://github.com/damus-io/notedeck/pull/584
2024-12-17 08:56:48 -08:00
William Casarin
e5ab8d5b9c nostrdb: update to fix profile queries
before profile queries were not working at the database level,
because there was no note_pubkey or note_pubkey_kind index. Now there
is! So profiles should be much faster to query now, and will actually
return results.

There still appears to be an issue with the profile NotesHolder which
is preventing it from updating, via the logic in poll_notes_into_view.
The original Timeline version of this function works fine, but it looks
like the NotesHolder one is broken.

Going to work on refactoring the notes holder next to fix.

Signed-off-by: William Casarin <jb55@jb55.com>
2024-12-13 23:35:08 -08:00
kernelkind
13a406b9cd deps: remove reqwest
This was preventing us from building on windows amd

Closes: https://github.com/damus-io/notedeck/pull/567
Signed-off-by: kernelkind <kernelkind@gmail.com>
Signed-off-by: William Casarin <jb55@jb55.com>
2024-12-13 10:01:26 -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
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
Ken Sedgwick
35138cd951 android: update to winit 0.30.5 2024-12-09 10:40:04 -08:00