Commit Graph

171 Commits (cb04e2c6b79ea4023d0e0f06fbc30586d9533f2a)
 

Author SHA1 Message Date
OFF0 cb04e2c6b7
0.0.28
ci/woodpecker/push/woodpecker Pipeline was successful Details
1 year ago
OFF0 86ac5e47fa
feed: fix too many subscriptions
ci/woodpecker/pr/woodpecker Pipeline was successful Details
ci/woodpecker/push/woodpecker Pipeline was successful Details
fetch profile meta data only for future notes for pubkeys that are
not known of if the event kind is a text note, but not for reactions
or meta data.

this drastically reduces one time subscriptions.
1 year ago
OFF0 b67f59ebec
noxy: disable images and link previews
ci/woodpecker/pr/woodpecker Pipeline was successful Details
ci/woodpecker/push/woodpecker Pipeline was successful Details
noxy is not running at the moment and was enabled for events
with enough POW.

temporary disabled noxy link previews and images.
1 year ago
OFF0 9036f6a073
0.0.27
ci/woodpecker/push/woodpecker Pipeline was successful Details
2 years ago
OFF0 abf0ae7249
0.0.26
ci/woodpecker/push/woodpecker Pipeline was successful Details
2 years ago
OFF0 30809ccbce
feed: update subscriptions
ci/woodpecker/pr/woodpecker Pipeline was successful Details
ci/woodpecker/push/woodpecker Pipeline was successful Details
playing around with subscriptions, feed now loads profile names,
profile views also show replied to notes and notes recursively
search for replies or replies.

this commit does too many subscriptions, ideally a max of three
subscriptions are done at once. in future commit it would be nice
to subscribe modularly, have done callbacks or push into subscribe
next queues.
2 years ago
OFF0 7113bf1a4d
feed: visually improve threads styling
CSS is a bit messy and should be redone, but threads are now styled
a bit as branches.
2 years ago
OFF0 6910a4da4e
0.0.25
ci/woodpecker/push/woodpecker Pipeline was successful Details
2 years ago
OFF0 683b500121
cleanup
ci/woodpecker/pr/woodpecker Pipeline was successful Details
ci/woodpecker/push/woodpecker Pipeline was successful Details
- remove X icon placeholder
- remove weird unicode whitespace
- delete comment out code
2 years ago
OFF0 c88cfa74bb
refactor: improve view and move code to ui and notes
ci/woodpecker/push/woodpecker Pipeline was successful Details
ci/woodpecker/pr/woodpecker Pipeline was successful Details
cleanup code and move parts to ui.ts and notes.ts.

simplify view and fix some weird animation issue, it should run
pretty stable now.

updated color and spacings.

profile view now showing kind 0 name, but it is unnecessarily
re-rendering. this part should probably go to a custom profil
subscription callback in the future. keeping as is for now and
refactor later.
2 years ago
OFF0 42fbd7c4c8
feed: ignore ctrl click
ctrl/command click should do the native browser thing and not be
intercepted as normal click, i.e. ctrl click open-in-new-tab works
2 years ago
OFF0 77711d655d
feed: ignore vmess protocol messages
Drop encrypted vmess messages.
2 years ago
OFF0 2fa7cce511
about: fix styling 2 years ago
OFF0 aec72b6c62
refactor: function to es6 arrow functions
so that it doesnt depend on function hoisting.
2 years ago
OFF0 bbfa4ae545
main: fix global click handler
settings view and write new message didnt show. reason was typescript
expected an instance of an HTMLElement but this didnt allow for
SVG elements inside the write button. Another reason was that the
condition expected a parent with data-id which isn't the case for
settings button nor write-new-message.
2 years ago
OFF0 f9fe892937
main: convert remaining main to typescript 2 years ago
OFF0 e1ba0b4c6f
profile: move and type profile metadata 2 years ago
OFF0 ab1ea2fa41
view: fix hidden settings view
css regression, somehow flex order doesnt overlay on the main
views, fixed with z-index.
2 years ago
OFF0 78588ec1c7
media: move noxy preview link fetch logic to media.ts 2 years ago
OFF0 7abd6fdc6e
nav: change from data-nav to simple href check 2 years ago
OFF0 976ea21d52
write: move reply and write-new-text note to write.ts 2 years ago
OFF0 9a34d4f31e
refactor: global click listener and cleanup
breaking up the global click callback to make it easier in the future
to move some parts into ui modules such as settings.ts.
2 years ago
OFF0 52e2a31421
reactions: move reaction logic to typed module 2 years ago
OFF0 43754149a9
settings: move remaining settings code
with this change everything related to user settings is now
in settings.ts module.
2 years ago
OFF0 efda7737c8
utils: move updateelemheight to dom utils 2 years ago
OFF0 ca4594a7e7
settings: move mining difficulty, filter and timeout configs
type and move mining related configs to settings.ts.
2 years ago
OFF0 b44fe10870
system: move pow function and error overlay to system
type and move powEvent and its error overlay to system.ts
2 years ago
OFF0 d654028a86
settings: refactor pubkey into config.pubkey global
starting to move global application user config to settings.ts.
plan is to only share user settings via the config object, with
this all settings related ui can be moved out of main.js into its
own module.
2 years ago
OFF0 cadd0302a5
utils: cleanup and move isvalidurl to utils/url 2 years ago
OFF0 23188c161f
utils: move lock and unlock scroll functions to utils 2 years ago
OFF0 70fb0da35a
utils: import directly from utils
it is not worth to import everything from utils, as there are too
many functions, better import them directly from each module.
2 years ago
OFF0 495e755844
styles: move stylesheets to styles 2 years ago
OFF0 33dd40bae5
typescript 2 years ago
OFF0 6e404eac6b
refactor: type element attributes
use attributes of html element type.

so that the following example is correctly typed:

elem('input', {
  className: 'foo',
  hidden: false,
  onclick: () => alert('hi'),
  tabIndex: 1,
  valueAsNumber: 1,
});

but this fails as foo is no valid attribute on div element:

elem('div', {foo: 'bar'});
2 years ago
OFF0 489a260427
refactor: type elem and enforce inferred generic type
typed elem so that it returns the exact type of the HTMLElement,
and that name must be a key of HTMLElementTagNameMap.

example:

elem('form'); // returns HTMLFormElement

elem('abc'); // not assignable to parameter of type 'keyof HTMLElementTagNameMap'
2 years ago
OFF0 2d46687e12
refactor: type events.ts, url.ts and crypto.ts 2 years ago
OFF0 fa97027321
refactor: type view.ts, dom.ts and time.ts 2 years ago
OFF0 35b8baef92
refactor: type subscriptions.ts
typed subscribe functions in subscriptions.ts
2 years ago
OFF0 309367852a
routes: use nip19 as routes
so we need no guessing logic and know what to subscribe too. in a
later step it add more to the view i.e. show profile meta data for
npub.
2 years ago
OFF0 b0e190fd22
nip19: use bech32 npub and note in uris
convert pubkey to npub and event id to note and store for
later. use npub and note for uri's so that we dont need to
guess what the view of a specific uri has to render.

this is only the first step that changes uri's, next step is
for the view to react to npub or note and render the
correct view accordingly.
2 years ago
OFF0 87cd5f21b3
relays: type and upgrade to nostr-tools@1.6.0
move and typed relay related code to relays.ts

upgrade nostr-tools to latest greatest, major version with
breaking changes:

- relayPool is gone in favor of SimplePool, but this commit just
  used relayInit directly as relays should become configurable at
  some point
2 years ago
OFF0 57be701ef9
routes: use generic view containers
proof of concept to use generic view containers instead of specifc
functions to show and hide particular views.

a view has an identifier (path) which is used to subscribe to
relevant data. changing a view updates the history so that browser
back displays the last view. each view container has its own
scrollbar so that the scrolling position should be preserved when
changing back and forth between different views.

this change also removes CSS tabs in favor of view or overlays
such settings or write a new text note.

profile and notes deeplink use now native HTML anchors to improve
accessibility (copy/paste, open-in-new-tab, search engines).
2 years ago
OFF0 784b9d9ea0
0.0.24
ci/woodpecker/push/woodpecker Pipeline was successful Details
2 years ago
OFF0 46bd581950
replay: temp disable overloaded relays
ci/woodpecker/push/woodpecker Pipeline was successful Details
there is currently lots of chinese spam, probably since damus was
accepted in appstore.

temporary disabled damus, snort.social and nostr.info relays, and
added some less known german and swiss relays.
2 years ago
OFF0 9e46342250
0.0.23
ci/woodpecker/push/woodpecker Pipeline was successful Details
2 years ago
OFF0 e84af81b97
relay: add snort.social relay
ci/woodpecker/push/woodpecker Pipeline was successful Details
relay.snort.social seems to be a popular relay, adding a new one
to the hardcoded list of relays, this should be configurable in
the future.

related damus relay is often not responding or slow, but keeping
it for now.
2 years ago
OFF0 5a18e2952c
profile: increase number of notes shown on profile
ci/woodpecker/push/woodpecker Pipeline was successful Details
there is no good reason to show less notes on a profile deeplink.
changed limit to 450, same as explore feed.
2 years ago
OFF0 593d4c6e38
relay: change wlvs.space to eden.land
ci/woodpecker/push/woodpecker Pipeline was successful Details
wss://nostr-relay.wlvs.space is not working anymore, seems they
moved, see:
- https://nostr.ch/cbb15cbd3a36a79a4611ee2852bea503f764c4d48fdb5988b1124a146efccc55
2 years ago
OFF0 4544ccc996
0.0.22
ci/woodpecker/push/woodpecker Pipeline was successful Details
2 years ago
OFF0 339e1ed97c
feed: style 3 levels of nested threads
ci/woodpecker/pr/woodpecker Pipeline was successful Details
ci/woodpecker/push/woodpecker Pipeline was successful Details
instead of just adding 1 line for all replies to point to the
original note, using smaller profile pic for replies of replies
help to understand the context of the replies.

this is done without increasing indentation as heavy nesting can
mess up the layout so only indentation is visible and the space
for the actual content gets to small.

if needed users can inspect replies and navigate to the deeplink
to see how the next 3 levels are nested.
2 years ago