Skip to content

Conversation

@malkovitc
Copy link

Summary

Fixes #904

The "Add a note for others to find" feature posts permanent notes to Nostr (internet), not mesh. This creates potential privacy concerns when housed under #mesh, as users might accidentally link their location to their nym.

Changes:

  • Move the location notes button from #mesh tab to location channels (#geohash)
  • Simplify the geohash lookup - use the current channel's geohash directly
  • Consolidate the notes and bookmark buttons in the location channel view

Test plan

  • Verify notes button no longer appears in #mesh
  • Verify notes button appears in location channels (e.g., #u281)
  • Verify clicking notes opens the location notes sheet with correct geohash
  • Verify bookmark button still works alongside notes

🤖 Generated with Claude Code

Notes post permanent data to Nostr (internet), not to local mesh.
Showing this button in #mesh was confusing and risked accidental
location linking. Now only appears in geohash-based channels.

Closes #904
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +1287 to 1291
if case .location(let ch) = locationManager.selectedChannel {
// Notes icon - posts permanent notes to Nostr for this location
Button(action: {
// Kick a one-shot refresh and show the sheet immediately.
LocationChannelManager.shared.enableLocationChannels()
LocationChannelManager.shared.refreshChannels()
// If we already have a block geohash, pass it; otherwise wait in the sheet.
notesGeohash = LocationChannelManager.shared.availableChannels.first(where: { $0.level == .building })?.geohash
notesGeohash = ch.geohash
showLocationNotes = true

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Notes button ignores selected location channel

Tapping the new notes button sets notesGeohash to the selected location channel (ch.geohash) but the sheet still runs an onChange handler (lines 1438‑1441) that overwrites notesGeohash with the first building-level geohash whenever location channels refresh (which happens on sheet appear). In any non-building location channel (block/city/bookmarked teleport), the notes view therefore shows and posts notes for the current building instead of the selected channel, defeating the intent of moving the button into location channels.

Useful? React with 👍 / 👎.

Don't auto-update notesGeohash when location channels refresh if the
notes sheet is already open. This ensures the user sees notes for the
channel they selected, not the current building location.

Addresses review feedback from Codex bot.
@malkovitc malkovitc closed this by deleting the head repository Dec 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

UI/UX: "Add a note for others to find" doesn't belong in #mesh

1 participant