Commit Graph

55 Commits

Author SHA1 Message Date
Alex Gleason da27054a9b Fix file downloads and URL opening on Capacitor iOS
The <a download> and <a target="_blank"> patterns don't work in
WKWebView. Add downloadTextFile() and openUrl() utilities in
src/lib/downloadFile.ts that use @capacitor/filesystem and
@capacitor/share on native platforms, falling back to standard
browser behavior on web.

Update all call sites: onboarding key download (InitialSyncGate,
SignupDialog), image lightbox buttons (ImageGallery, ProfilePage).

Document Capacitor compatibility constraints in AGENTS.md.
2026-03-27 16:42:36 -05:00
Alex Gleason 9c3ec58246 Rename package from mkstack to ditto 2026-03-26 23:31:24 -05:00
Alex Gleason 58a5c470bd release: v2.1.0 2026-03-26 23:14:03 -05:00
Chad Curtis 51fffc0ae1 Merge branch 'envelope-inbox' into 'main'
Add Letters inbox page with full letter composing from lief

See merge request soapbox-pub/ditto!117
2026-03-27 03:59:48 +00:00
Alex Gleason 95db4e4dcf release: v2.0.1 2026-03-26 22:39:07 -05:00
Alex Gleason c1b33e17c8 release: v2.1.0 2026-03-26 22:31:54 -05:00
Alex Gleason cbbb576b26 Add release system with semver versioning, changelog, and release skill
- Switch from CalVer (date+SHA) to semantic versioning starting at v2.0.0
- Create release skill (.agents/skills/release/) with full AI-guided release workflow
- Add CHANGELOG.md with initial 2.0.0 entry
- Update CI tag regex to match semver tags (v2.0.0 instead of v2026.03.24-sha)
- Extract changelog content into GitLab release descriptions
- Update Android versionName to 2.0.0 in build.gradle
- Update iOS MARKETING_VERSION to 2.0.0 in pbxproj
- Expose VERSION (semver) and BUILD_DATE (ISO 8601) as build-time constants
- Display version and build date in Settings page footer
- Remove npm release script (releases are now done via the AI skill)
2026-03-26 21:15:35 -05:00
Chad Curtis 848ac15ef0 Fix CI: remove unused prop, centralize color helpers, extract constants, memoize Sets, move @types/dompurify to devDeps 2026-03-26 19:45:51 -05:00
Chad Curtis ae1f97eb08 Letters: bigger wax seals, adaptive text, inline labels, font loading, SVG sticker fix 2026-03-26 19:17:58 -05:00
Chad Curtis 865fabce98 Add Letters inbox page with full letter composing from lief
- Port letter protocol (kind 8211, NIP-44 encrypted) from lief
- LettersPage at /letters with inbox and sent tabs
- ComposeLetterSheet with full stationery, font, frame, sticker, drawing support
- LetterCard with expand-to-read animation and deletion
- LetterPreferencesSection stored in encrypted settings (NIP-78)
- /settings/letters route for letter preferences
- Letters added to sidebar nav
- All letter lib utilities: letterTypes, letterUtils, colorUtils extensions, sanitizeSvg, svgDrawing
- StationeryBackground, StationeryPicker, FramePicker, StickerPicker, DrawingCanvas all ported
2026-03-26 16:11:29 -05:00
Alex Gleason 264358c223 Upgrade @nostrify/nostrify 0.50.5 -> 0.51.0 and @nostrify/react 0.3.0 -> 0.3.1
Includes NRelay1 AUTH fix for correct NIP-42 challenge handling.
2026-03-25 01:37:07 -05:00
Alex Gleason 0666278a58 refactor: use @nostrify/react@0.3.0 for client-initiated NIP-46
Replace inline nostrconnect:// protocol logic with NLogin.fromNostrConnect(),
generateNostrConnectParams(), and generateNostrConnectURI() from upstream
@nostrify/react. Removes ~130 lines of code that is now in the library.
2026-03-24 16:21:00 -05:00
Alex Gleason ca1b055dad Add iOS platform support with Capacitor and remote build script
- Add @capacitor/ios dependency and iOS Capacitor platform
- Configure capacitor.config.ts with iOS settings (scheme, background color, content inset)
- Add scripts/build-ios.sh for building iOS over SSH on Mac Mini (orcus.lan)
- Script supports simulator, device, archive, and open-in-Xcode modes
2026-03-23 20:27:13 -05:00
Dirk Rost c58c2f52a0 Revert NIP-46 workaround, bump @nostrify/react to 0.2.31 2026-03-22 23:27:46 +00:00
Alex Gleason 98b254e296 Upgrade @nostrify/nostrify to 0.50.5 and @nostrify/react to 0.2.30 2026-03-21 20:35:01 -05:00
Alex Gleason a6f60b3da1 Add keygen script for Google Play upload keystore 2026-03-18 12:56:17 -05:00
Chad Curtis 487e32d5ac Fix release artifact URL: use - instead of + in tag format
The + character in git tags breaks GitLab's artifact download URL.
Switch tag format from v2026.03.16+abc1234 to v2026.03.16-abc1234
so the artifact URL works without any encoding workarounds.
2026-03-16 03:22:57 -05:00
Alex Gleason 77d9375fca Upgrade to Vite 8 with Rolldown and switch to @vitejs/plugin-react v6
Replace Vite 6 (esbuild + Rollup) with Vite 8 (Rolldown), reducing
build times from ~12s to ~3.5s. Switch from the archived
@vitejs/plugin-react-swc to @vitejs/plugin-react v6 which uses Oxc
for React Refresh transforms.
2026-03-13 16:07:51 -05:00
Alex Gleason f4a0f3975a Add optional Plausible analytics via @plausible-analytics/tracker
Dynamically imports and initializes Plausible when the
VITE_PLAUSIBLE_DOMAIN env variable is set at build time.
When unset, the tracker code is never loaded.
2026-03-10 13:27:42 -05:00
Mary Kate Fain 706816478c Add Clear Sky Vibes theme preset with magenta primary and cyan text 2026-03-04 19:40:23 -06:00
Mary Kate Fain 8f140c4eaa Add bundled fonts and background images for all 8 new theme presets
Install Cinzel, Nunito, Quicksand, Courier Prime, and Comic Neue as
bundled fonts and register them in the font registry. Add Unsplash
background images to every new preset (Gothic, Cottage, Candy Heart,
Midnight, Hologram, Floret, Win 95, Plush).
2026-03-04 19:34:24 -06:00
Alex Gleason f5bc5fdbe4 Upgrade Nostrify (to fix NIP-05 signer issue) 2026-03-04 15:55:57 -06:00
Chad Curtis 8db2abe23b npm audit + npm dedupe + npx depcheck missing packages 2026-03-04 02:58:10 -06:00
Alex Gleason f1191299e8 Add Sentry integration with lazy loading and user-configurable DSN
Sentry SDK is loaded via dynamic import() only when a DSN is configured
and error reporting is enabled, keeping it out of the initial bundle.
Users can control error reporting via a toggle and DSN field in
Advanced Settings, with the DSN synced across devices via encrypted
NIP-78 settings. The ErrorBoundary now reports fatal crashes to Sentry
with component stack context, and a beforeSend hook censors nsec
private keys before any data leaves the browser.
2026-03-03 17:25:14 -06:00
Alex Gleason 80eac87a15 Upgrade @nostrify/nostrify to 0.50.3 and @nostrify/react to 0.2.28
Fixes race condition where NBrowserSigner would throw 'Browser extension
not available' when app code accessed signer.nip44 before the extension's
content script had injected window.nostr on page reload.
2026-03-03 17:14:10 -06:00
Chad Curtis 7aaa3e2587 Add interactive profile editor with live card, image crop, and onboarding integration 2026-03-03 07:31:06 -06:00
Alex Gleason 1302f5933c Replace regex manifest.toml parsing with smol-toml for correct TOML handling 2026-02-27 19:27:56 -06:00
Mary Kate Fain adceba5a54 Add 7 Y2K aesthetic theme presets with bundled display fonts
Add Skater, Kawaii, Grunge, MS Paint, Retro Pop, Bubblegum, and Gamer
theme presets derived from the ditto-1 aesthetic designs. Each preset
includes tailored CoreThemeColors, a display font, and a Blossom-hosted
background image.

Install and register 7 new fontsource display fonts (Permanent Marker,
Cherry Bomb One, Creepster, Silkscreen, Bungee Shade, Luckiest Guy,
Press Start 2P) in the bundled font registry so they appear in the
FontPicker for custom theme building as well.
2026-02-27 15:55:40 -06:00
Alex Gleason cd6d5f7a7c Replace Comic Neue with Comic Relief in bundled fonts 2026-02-26 16:15:09 -06:00
Alex Gleason 3b15044919 Implement ThemeConfig type system with bundled fonts and NIP.md-compliant event parsing
- Add ThemeConfig wrapper type (colors + fonts + background) replacing bare CoreThemeColors
- Sync theme event parsing/building with NIP.md spec: colors in c tags (hex), fonts in f tags, background in bg tags (imeta-style), empty content field
- Legacy backward compat: parse old JSON-in-content format and bare CoreThemeColors in localStorage/encrypted settings
- Bundle 10 curated fonts via fontsource (Inter, DM Sans, Outfit, Montserrat, Lora, Merriweather, Playfair Display, JetBrains Mono, Comfortaa, Comic Neue) with lazy dynamic imports
- Create font loader (src/lib/fontLoader.ts) for @font-face injection from remote URLs and CSS override application for title/body roles
- Rewrite FontPicker as dual title/body picker using bundled fonts instead of Google Fonts CDN
- Remove Google Fonts integration (useGoogleFont.ts, GoogleFontLoader.tsx)
- Resolve bundled font family names to CDN URLs when publishing to Nostr
- Apply profile theme fonts when visiting other users' profiles
- Update all consumers: AppProvider, useTheme, usePublishTheme, useEncryptedSettings, ThemeSelector, ThemeBuilderPage, ProfilePage, EditProfileForm, InitialSyncGate, NostrSync
2026-02-26 14:46:30 -06:00
Chad Curtis 8e5b59c44e feat: use planet icon for feed nav item 2026-02-26 05:37:19 -06:00
Mary Kate Fain b8d7d8a730 Redesign sidebar navigation with section grouping, customization, and mobile consistency
- Desktop: Remove redundant Home/Search nav items (logo serves as Home, inline
  search covers both quick lookup and full search page navigation)
- Add visual section grouping with labeled separators (Explore, You, Settings)
- Replace ugly dashed 'Add' button with subtle 'More...' inline link
- Add edit mode with drag-and-drop reordering (@dnd-kit) and remove buttons
  for content-type items in the Explore section
- Hover-to-remove on desktop content-type items outside edit mode
- Mobile: Replace avatar menu trigger with standard hamburger icon
- Mobile: Add search icon to top bar right side
- Mobile: Redesign bottom nav as 4-tab layout (Home, Explore, Notifications, You)
- Mobile: Explore tab opens bottom sheet with content type links (vaul Drawer)
- Mobile drawer: Replace profile header with logo, restructure to match desktop
  sections, add 'Manage...' link for settings, remove redundant Profile link
- Add sidebarOrder to AppConfig for persisting custom item order
- Extend useFeedSettings hook with orderedRoutes, addToSidebar, removeFromSidebar
2026-02-25 08:54:37 -06:00
Chad Curtis ba999beb9c Add release script for calver+sha tagging 2026-02-24 01:06:05 -06:00
Chad Curtis 0d7e384431 Move engines field above dependencies in package.json 2026-02-24 01:04:58 -06:00
Chad Curtis e3a62acbd3 Pin npm 10.9.4 and Node 22.x engine requirements to prevent lockfile churn 2026-02-24 01:04:15 -06:00
Chad Curtis b02b2a9e56 Rebrand Android app icons to Ditto logo with purple background 2026-02-24 01:03:53 -06:00
Alex Gleason 8febb405e5 Use imeta dim/blurhash for media placeholders before load
- Parse NIP-94 dim and blurhash fields in parseImetaMap (NoteCard + PostDetailPage)
- ImageGallery/GridImage: use dim for correct aspect-ratio skeleton sizing; render Blurhash canvas placeholder when available
- VideoPlayer: set aspect-ratio container from dim; show Blurhash canvas before first frame/poster loads
- Install react-blurhash (+ blurhash) for canvas rendering
2026-02-23 22:58:56 -06:00
Mary Kate Fain c046e33f6b Replace hardcoded emoji picker with emoji-mart for full emoji support 2026-02-23 12:05:21 -06:00
Alex Gleason 75585b2c42 Remove nostr-wasm 2026-02-22 18:05:36 -06:00
Alex Gleason 77f699acc2 Verify events with nostr-wasm 2026-02-21 21:45:39 -06:00
Alex Gleason 408ccc72e7 Upgrade Nostrify 2026-02-21 21:15:06 -06:00
Alex Gleason cfb5659020 Replace DomainFavicon with ExternalFavicon using configurable favicon URL template
The old DomainFavicon component had a multi-step fallback chain (HTML scraping,
direct URL guessing, then the configured provider) which meant the configurable
setting was almost never reached. The new ExternalFavicon component uses the
configured favicon URL template directly via RFC 6570 URI templates.

- Rename config field faviconProvider -> faviconUrl
- Add faviconUrl() utility with uri-templates for RFC 6570 support
- Remove local Favicon component from ProfileRightSidebar
- Update all consumers to use ExternalFavicon
2026-02-21 15:14:30 -06:00
Alex Gleason 749900f853 Extract webxdc name and icon from .xdc manifest, display in embed card
- Add webxdcMeta.ts utility to extract name from manifest.toml and
  icon (icon.png/icon.jpg) from the .xdc ZIP using fflate
- Upload extracted icon to Blossom during file attach
- Add webxdc_name and webxdc_icon properties to imeta tags
- Parse webxdc_name/webxdc_icon in NoteCard and PostDetailPage
- Show app icon and name in WebxdcEmbed launch card, remove filename
  and 'Stateful · shared session' text
2026-02-21 12:15:26 -06:00
Alex Gleason 13f05936dd Add webxdc support: attach .xdc files as stateful mini apps with kind 4079 state sync
- Create useWebxdc hook bridging the Webxdc API with Nostr kind 4079 state updates
- Create WebxdcEmbed component with launch-on-click UX for sandboxed iframe rendering
- Update ComposeBox to accept .xdc files and generate imeta tags with webxdc UUID
- Update NoteCard and PostDetailPage to detect and render webxdc attachments
- Skip .xdc URLs in NoteContent to avoid rendering them as raw links
2026-02-21 04:57:05 -06:00
Chad Curtis f36c9a67b5 Add markdown rendering for articles (kind 30023)
- Create ArticleContent component using react-markdown + rehype-sanitize
- Enable @tailwindcss/typography plugin for prose styling
- NoteCard shows article preview (title, image, summary)
- PostDetailPage renders full markdown article with prose typography
- Both views support header images and hashtag links
2026-02-21 01:13:51 -06:00
Chad Curtis 4882a90403 Add NIP-53 live stream support with HLS player and live chat
Implement kind 30311 live streaming events: HLS video player (hls.js),
kind 1311 live chat with real-time subscriptions, stream detail page with
collapsible description on mobile, desktop sidebar chat, streams feed page,
and full extra-kinds integration with sidebar nav and settings.
2026-02-20 14:52:48 -06:00
Alex Gleason e2f2763d44 Upgrade nostrify 2026-02-20 00:11:49 -06:00
Chad Curtis 64726d2cf7 Add local WebSocket notification polling and Mew splash/notification icons
- Implement Signal-like local-only notifications via direct WebSocket relay polling
- Poll every 60s foreground, 15min background, no external push server
- Resolve NIP-05 display names for notification body (e.g. 'alice@nostr.com reacted to your post')
- Add Capacitor LocalNotifications plugin with POST_NOTIFICATIONS permission
- Replace default Capacitor splash with Mew logo PNG on dark background using Android 12 Theme.SplashScreen
- Add ic_stat_mew vector drawable for notification small icon
- Regenerate splash PNGs with #14161f background
2026-02-19 10:40:38 -06:00
Chad Curtis a293128176 Add mobile safe area support for status bar
- Install @capacitor/app and @capacitor/status-bar as dependencies
- Initialize StatusBar in App.tsx with dark style and overlay mode
- Add safe-area-top utility class to index.css
- Apply safe-area-top to MobileTopBar component
- Apply safe-area-top to toast notifications on mobile
- Ensures content is not hidden behind device notches/status bars
2026-02-19 06:31:18 -06:00
Chad Curtis 2f02e65ab6 Add Android Capacitor build system
- Install Capacitor dependencies (@capacitor/cli, @capacitor/core, @capacitor/android, @capacitor/app, @capacitor/status-bar, sharp)
- Create capacitor.config.ts with app configuration
- Update .gitignore to exclude Android build outputs and keystore files
- Generate icon-512.png from logo.svg
- Add scripts for icon generation, APK building, and keystore creation
- Initialize Capacitor Android platform
- Configure build.gradle with signing support
- Generate Android app icons in all required densities
- Add npm scripts: 'icons' and 'build:apk'
2026-02-19 06:18:02 -06:00