Commit Graph

206 Commits (master)
 

Author SHA1 Message Date
OFF0 2e94d59028
feed: fix expand long notes
Text notes longer than 280 are shortened and appended with '…' to
indicate that this note can be expanded, but this dotdotdot was
real text and was not removed once the note is expanded.

Changed to showing the dots through CSS and only if the attribute
exists, so it does not show on expanded notes.
1 year ago
OFF0 b4392bf215
layout: highlight kind 0 name and dummy profile pics
- added experimental dummy profile pics
- highlight kind 0 usernames
- improved dark mode colors
1 year ago
OFF0 b7c47a7a50
0.0.7
ci/woodpecker/push/woodpecker Pipeline was successful Details
1 year ago
OFF0 fecbb8ff50
feed: show picture (kind 0) with noyx
ci/woodpecker/pr/woodpecker Pipeline was successful Details
ci/woodpecker/push/woodpecker Pipeline was successful Details
Loading images from random url leaks meta data to other servers.

Enabled showing kind 0 picture from noxy (nostr proxy),
see https://git.qcode.ch/nostr/noxy

Only href that are a valid url and use http(s) should be allowed
to prevent malicious urls such as 'javascript:alert(1)'.

Kept the fallback to the speak bubble if there is no kind 0 event
for this pubkey or picture is missing.
1 year ago
OFF0 6a4266526d
keys: fix key validation
ci/woodpecker/pr/woodpecker Pipeline was successful Details
ci/woodpecker/push/woodpecker Pipeline was successful Details
Pub and private key settings only showed errors if both values were
truthy, but it did not validate if one input was falsy, in which
case it only showed the last error.

Removed truthy check as it is not needed.
1 year ago
OFF0 4dd8dae483
layout: fix nav positioning on ios
ci/woodpecker/pr/woodpecker Pipeline was successful Details
ci/woodpecker/push/woodpecker Pipeline was successful Details
Safari does not take the addressbar into account when using 100vh,
this is the cauase that the navigation is sometimes hidden when
the user scrolls up/down.

changed to 100dvh with fallback to 100vh.
1 year ago
OFF0 a7a2acfc0c
0.0.6
ci/woodpecker/push/woodpecker Pipeline was successful Details
1 year ago
OFF0 4576355b03
layout: visual interface improvements
ci/woodpecker/pr/woodpecker Pipeline was successful Details
ci/woodpecker/push/woodpecker Pipeline was successful Details
- writing a new message is now presented in full-screen, so that
  there are no distractions, i.e. other posts
- added back button and listen to esc key to close new message
- on portrait mode the navigation buttons are now positioned at
  the bottom of the screen
- write new message botton (bubble) is also positioned bottomright
- replies now use a line to the last reply instead of indentation,
  better use of available space, especially on small screen
- ignore newlines at the end of a post
- added subtile growin effect to the multiline textfield, to hint
  that the textarea is growing with more content
1 year ago
OFF0 3ab815c30e
post: remove whitespace of textnote content (trim right only)
Send button should be disabled if there are only white spaces or
newlines, trimming only right as white spaces at the beginning
could mean somethig i.e in markdown.
1 year ago
OFF0 8081d12254
post: disable input field resizing
Textarea can be resized manually, but this does play well
with the automatic resizing (yet), disabling for now.
1 year ago
OFF0 7d9f31f7c6
refactor: use evt as variable name if possible
This was we can use evt.id consistently instead of mental overhead
of textNoteEvent.id
1 year ago
OFF0 06686ba9a7
post: improve write and reply to textnote usability
- use growing textarea input to support multiline textnotes
- keep replyTo id in localstorage instead of global variable
- render reply to form on load if there was a replyTo in storage
1 year ago
OFF0 b10a63b932
comment code about textNoteList and eventRelayMap 1 year ago
OFF0 e9cc165738
utils: move multiline function to domutils 1 year ago
OFF0 409ff80d64
test multiline comments 1 year ago
OFF0 7b7b4d3f28
use nostr x1ddos only for now 1 year ago
OFF0 730db777b6
refactor: rename form to settingsform 1 year ago
OFF0 76861501cc
0.0.5
ci/woodpecker/push/woodpecker Pipeline was successful Details
1 year ago
OFF0 8109a22bb8
style: make page mobile friendly 1 year ago
alex d401564cca
ci: remove "branch" from conditional release pipeline execution
ci/woodpecker/push/woodpecker Pipeline was successful Details
the v0.0.3 should've trigger automated release but it didn't.
going to try removing branch from the condition, only the tag pattern.
1 year ago
alex 64170846d3
v0.0.3: bump from 0.0.2 to trigger an automated deployment
ci/woodpecker/push/woodpecker Pipeline was successful Details
i broke the ci while moving the repo from x1ddos/nostrweb to
nostr/nostrweb - all settings remained in the old repo and pipelines
didn't run at the new location.

could've overwritten the git tag but what happens in public git,
stays in git. so, just making a new dummy tag to trigger the ci.
1 year ago
alex d6e49dc769
ci: empty commit to trigger a build
ci/woodpecker/push/woodpecker Pipeline was successful Details
1 year ago
OFF0 14f67cb85e
0.0.2 1 year ago
OFF0 56da8772db
Merge branch 'change-everything' 1 year ago
OFF0 4a710ee5d1
getting ready
- added favicon.ico to get rid of anoying logs in the future
- clicking the idea bubble brings back the text input field
- stop accidentally submitting the reply form
- updated idea cloud to dark/light mode neutral gray
- contact list not needed yet, disabled
- add a detailed list of reactions in star tooltip
- removed debug debounce was for testing chronological feed order
- started username prototype
1 year ago
OFF0 e7ad8e468b
feed: handle reactions (kind 7)
Added support for starring.

Stores recation events in a reactionMap, so rendering can use it
later.

Improved reply to replies, by keeping a separate replyDomMap.

Changed from heart to star, reason: thumbsup or a heart are good
for positive events, but not so suitable to react to a bad event.
So currently negavtive votes are just counted as a star as well.

Did not add another dom map, but just querySelector in case an
existing star needs to be updated later.
1 year ago
OFF0 13b3db4302
layout: update navigation and add icons
Used different CSS-only tab technique. The implementation before
messed up the whole height of the page and used unnecessary
absolute positioning.

Added comment icon from MFG Labs iconset (SIL)
- https://github.com/MfgLabs/mfglabs-iconset

Added outlined and filled heart from Elusiv icons (SIL)
- https://github.com/dovy/elusive-iconfont

Time ago seconds should be rounded.
1 year ago
OFF0 a71de21302
feed: playing with ui
- shorten text notes after 280 chars
- add expand button to shortened text
- play around with profile image and username layout
1 year ago
OFF0 c896789ccd
settings: prevent accidental form data submitting in html mode
If JavaScript is disabled the form in the settings should not leak
private or pubkey data.
1 year ago
OFF0 2d8e60a6df
feed: support reply and render incoming replies
Keeping current reply info so it can be accessed later to
publish the reply.

Before only known replies were rendered, now incoming replies
get added to the existing text note  instantly. This needs to
create a reply container if this is the first reply of this event.

Added time ago formatting and a helper function that switches
between relative time (if event < 24h) or absolute formatted time
(if older than 1 day).
1 year ago
OFF0 397df6d5a4
feed: show replies
Render known replies, also added debounce debug info to test
chronological order and keep an eye on.
1 year ago
OFF0 80a9e82f79
refactor: name sort by created_at function 1 year ago
OFF0 a2a5cfa341
refactoring: eleanup part I
Styled profile image to be aligned at the top together with the
event metadata and content.

Still need to decide on which relays to enable.

JavaScript lint fixes.
1 year ago
OFF0 b2ad1d4c60
enable send
Send is enabled now, but some errors do not surface, for exmaple
if the network is down, tried catching those but will need to dig
deeper into that.
1 year ago
OFF0 09bb691f6c
feed: refactoring and deterministic chronological feed order (maybe)
chronological order: Getting there..

cleanup: removed debounce code for now

keep also recommend server events in the dom map, not sure if just
everything should be in the map.
1 year ago
OFF0 549bfed7dd
feed: render textnotes from multiple relays in chronological order
Events should be ordered by created_at.

The randomly incoming events should be injected to their closest
event sibling. Keeping a map of eventIds and dom nodes to reference
and inject the new events.

An alternative to keeping a map could be to add a data-attribute
to each event and use querySelector. It is a trade-off os using
more memory in order to not query the dom tree.
1 year ago
OFF0 d2a7f4a603
refactor: just moving helper functions around 1 year ago
OFF0 d5fa2f420b
feed: add formatted absolute time
Useful to see when a text note was written.
1 year ago
OFF0 5d701c8767
utils: append string child directly
Strings can be appended directly without spreading.
1 year ago
OFF0 380b79038d
feed: change recommend server styling to show on oneline
As recommend servers is secondary meta information, it is enough to
show it smaller and on one line.
1 year ago
OFF0 cab1d14603
feed: add reply to info
Add reply to event id and if available relay info. Relay info is
not always available, see positional e tags (DEPRECATED) NIP-10.
1 year ago
OFF0 69afa63201
feed: style text note reply
Indent textNotes that are replies to an event.
1 year ago
OFF0 7621989b43
layout update
- limit max width of feed content
- better profile image positioning
1 year ago
OFF0 f7eb5ff7f6
contacts: trying to create a contactlist
- disabled user picture, loading external resources leaks metadata
  and is bad for privacy.
- refactored code to share profile rendering.
- wip: keep a contact list to display user follows otheruser
1 year ago
OFF0 44568060c0
feed: add inline form for writing new messages
Just a prototype, not functioning yet
1 year ago
alex 8a81a18183 docs: clarify how the live instance is currently updated from the CI
ci/woodpecker/push/woodpecker Pipeline was successful Details
1 year ago
alex 5de7d8c485 ci: rsync dist/ over to the live server
ci/woodpecker/push/woodpecker Pipeline was successful Details
this is a quick&dirty solution to update the live
server whenever a git tag on master matching v* pattern is pushed.

a longer term permanent idea is to use a nostr relay to push
notifications about new releases.
1 year ago
OFF0 bac4b9c5e6
change everything
- reverse timeline
- add publish test button
- renamed variables to pubkey, privatekey
- subscribe to self (currently only on load)
- listen to more events before closing
2 years ago
OFF0 f33c787a9a
updated some styling
- change max-width to apply ti all tabs instead of just forms
- use monospace font for buttons and labels
- add tiny 2px border radius to buttons and prepare bottombar
2 years ago
alex 6b72fb8205 ci: add steps to create releases on vA.B.C tag events
ci/woodpecker/pr/woodpecker Pipeline was successful Details
ci/woodpecker/push/woodpecker Pipeline was successful Details
the steps create a tar.gz with all files found in dist/ dir.
additionally, an ad-hoc build.txt file is created with build info.
the bot then creates a release and uploads the tar.gz as an artifact.

the idea is that all nostr web app instances are notified about the new
release, download the tar.gz and update their local copy. this is not
yet implemented.
2 years ago