Commit Graph

2557 Commits

Author SHA1 Message Date
Johnny 97ba15450f chore: prevent unnecessary API calls when timestamp unchanged in MemoDetailSidebar
- Add same value check before updating createTime/updateTime
- Skip request if new timestamp equals current timestamp
- Simplify callback handlers and improve code readability
- Use .some() instead of .filter().length for cleaner code
2026-01-31 15:12:27 +08:00
Johnny f7a81296fb style: enhance ActivityCalendar components with improved styling and layout adjustments 2026-01-30 00:13:58 +08:00
Johnny fcb9e377c1 chore: streamline memo editor insert menu 2026-01-29 23:34:40 +08:00
Steven b0558824c4 feat: update instance profile to use admin user instead of initialized flag
- Changed InstanceProfile to include admin user field
- Updated GetInstanceProfile method to retrieve admin user
- Modified related tests to reflect changes in admin user retrieval
- Removed owner cache logic and tests, introducing new admin cache tests
2026-01-28 23:27:53 +08:00
Johnny 81022123a1 chore: simplify page loading logic 2026-01-27 23:37:32 +08:00
cui c5d9770fd1
typo: lenght to length (#5539) 2026-01-27 22:21:55 +08:00
Johnny 6731eccded feat: add EditableTimestamp component for inline date editing in MemoDetailSidebar 2026-01-26 23:23:14 +08:00
Brent Bilis 2f7c8dcea7
fix(ui): correct calendar header month parsing (#5532)
Co-authored-by: Local Admin <root@localhost>
2026-01-26 22:01:11 +08:00
Johnny e1888153f8 chore: polish dark styles 2026-01-26 21:59:36 +08:00
Johnny 98eaff1277 style: adjust spacing and background colors for improved UI consistency across components 2026-01-26 21:49:26 +08:00
Johnny 72c7965c8f chore: enable binary format for transport 2026-01-26 21:16:06 +08:00
itzmk21 f22b3dad25
chore(i18n): update British English spelling (#5529) 2026-01-26 08:48:43 +08:00
XIN_____ 45945a1df7
chore: update Chinese translation (#5519) 2026-01-23 23:32:58 +08:00
Johnny ad327a4a8d fix: adjust compact mode styling for MemoContent component 2026-01-23 09:11:33 +08:00
Johnny 7154ce0228 feat: implement markdown components for enhanced rendering 2026-01-23 09:04:42 +08:00
Steven c0d6224155 chore: enable compact mode for list view 2026-01-22 22:52:14 +08:00
Steven 6c9ea31de0 chore: add translation for saving status in EditorToolbar 2026-01-22 22:31:19 +08:00
Steven ba099b72ed feat: update InstanceProfile to include initialization status
- Removed the owner field from InstanceProfile as it is no longer needed.
- Added an initialized field to InstanceProfile to indicate if the instance has completed first-time setup.
- Updated GetInstanceProfile method to set initialized based on the existence of an admin user.
- Modified tests to reflect changes in InstanceProfile and ensure correct behavior regarding instance initialization.
- Adjusted frontend logic to redirect users based on the initialized status instead of the owner field.
2026-01-22 20:59:40 +08:00
Steven c240b70591 feat: add enabled option to useInfiniteMemos and PagedMemoList for conditional fetching 2026-01-22 20:21:16 +08:00
Johnny 0f3c9a467d refactor: migrate HOST roles to ADMIN
- Updated the isSuperUser function to only check for ADMIN role.
- Added SQL migration scripts for MySQL, PostgreSQL, and SQLite to change user roles from HOST to ADMIN.
- Created a new SQLite migration to alter the user table structure and ensure data integrity during the migration process.
2026-01-20 23:38:30 +08:00
Johnny 47ebb04dc3 refactor: remove mode flag and introduce explicit demo flag 2026-01-20 22:58:33 +08:00
Johnny dc7ec8a8ad feat: allow setting custom timestamps when creating memos and comments
Allow API users to set custom create_time, update_time, and display_time
when creating memos and comments. This enables importing historical data
with accurate timestamps.

Changes:
- Update proto definitions: change create_time and update_time from
  OUTPUT_ONLY to OPTIONAL to allow setting on creation
- Modify CreateMemo service to handle custom timestamps from request
- Update database drivers (SQLite, MySQL, PostgreSQL) to support
  inserting custom timestamps when provided
- Add comprehensive test coverage for custom timestamp functionality
- Maintain backward compatibility: auto-generated timestamps still
  work when custom values are not provided
- Fix golangci-lint issues in plugin/filter (godot and revive)

Fixes #5483
2026-01-17 12:56:03 +08:00
Johnny 253e79c111 style: remove unnecessary font-weight classes for cleaner UI 2026-01-13 23:19:43 +08:00
Steven 73c301072b refactor: simplify editor scroll logic
- Extract `scrollToCaret` helper to deduplicate scroll logic
- Unify precise scroll behavior for both manual triggers and auto-scroll
2026-01-13 21:23:23 +08:00
Steven 4e34ef22bf fix: improve editor auto-scroll and Safari IME handling (#5469)
- Use `textarea-caret` for precise cursor position calculation instead of line approximation
- Update `scrollToCursor` to scroll to the actual cursor position
- Fix Safari double-enter issue with IME in list completion
2026-01-13 21:19:31 +08:00
Steven 61dbca8dc2 fix: prevent browser cache from serving stale memo data (#5470)
This fixes a critical data loss issue where users editing the same memo
on multiple devices would overwrite each other's changes due to aggressive
browser caching, particularly in Chromium-based browsers and PWAs.

Changes:
- Backend: Add Cache-Control headers to all API responses to prevent
  browser HTTP caching
- Frontend: Force fresh fetch from server when opening memo editor by
  invalidating React Query cache
- Frontend: Reduce memo query staleTime from 60s to 10s for better
  collaborative editing support

Fixes #5470
2026-01-13 20:55:21 +08:00
Johnny 8f9ff5634c chore: remove redundant icon 2026-01-12 09:11:08 +08:00
Johnny 9a3451b9d1 fix(editor): filter RelationList to only show referencing memos
- Filter out COMMENT type relations, only show REFERENCE type
- When editing a memo, only show relations where current memo is the source
- Pass memoName through EditorMetadata to RelationList for filtering
2026-01-11 22:41:20 +08:00
Jongho Hong 07eac279d0
chore(i18n): add missing Korean translations (#5456)
Signed-off-by: Jongho Hong <myodan@pm.me>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-01-08 23:13:21 +08:00
Om vataliya 013ea52519
fix: apply theme and locale changes immediately on login screen (#5440) (#5442) 2026-01-07 21:58:47 +08:00
Johnny 9ccb658768 fix: sign up redirect 2026-01-07 08:50:10 +08:00
Johnny 1f755f74a4 fix(web): make login screen theme selector reactive
This fixes an issue where the theme selector on the login screen would not update its display value after selection because the component was not re-rendering. Added local state to track the current theme. Validated that this pattern is unique to the unauthenticated context.
2026-01-06 20:51:45 +08:00
Faizaan pochi 874a4a7142
fix: KaTeX math rendering with underscores (#5438) 2026-01-06 20:16:01 +08:00
Steven 62646853eb chore: tweak comments display 2026-01-06 19:08:03 +08:00
Steven ed66e0fec2 chore: fix linter 2026-01-06 09:08:27 +08:00
Steven 5a8e1845e2 fix: reaction button in mobile view 2026-01-06 09:06:52 +08:00
Johnny d68ca84832 fix: delete unused attachments by using filter 2026-01-05 22:43:57 +08:00
Johnny 4b110d0d38 fix: cursor position after slash commands 2026-01-05 22:24:13 +08:00
Steven 15646a8989 chore: fix linter 2026-01-05 21:57:07 +08:00
Steven e268a1fe9c chore: tweak memo content renderer 2026-01-05 21:50:49 +08:00
Steven ac37738148 fix: default visibility setting 2026-01-05 21:46:35 +08:00
lif cbbb585b2e
fix(frontend): ensure attachments are properly linked when creating memos (#5428)
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-04 19:17:14 +08:00
Sheep-realms b7b658358e
chore: update simplified chinese localization (#5422) 2026-01-04 19:10:24 +08:00
Roman Teitge 8cf99f5200
Update german translations (#5419)
Signed-off-by: Roman Teitge <83205200+rteitge@users.noreply.github.com>
2026-01-04 19:10:08 +08:00
Steven 06d1c60aaf chore: tweak domain format 2026-01-03 20:43:10 +08:00
Johnny d2b421213f chore: optimize RelationList and unify RelationCard usage 2026-01-03 14:27:12 +08:00
Johnny 77e9376e03 chore: improve metadata section UI consistency and maintainability 2026-01-03 13:54:47 +08:00
Johnny 5612fb8f41 feat: add HDR image and video support
- Add HDR detection utilities for wide color gamut formats (HEIC, HEIF, WebP)
- Apply colorSpace attribute to image/video elements for HDR-capable files
- Update frontend components (AttachmentCard, PreviewImageDialog, AttachmentList)
- Expand backend thumbnail generation to support HEIC, HEIF, WebP formats
- Add Color-Gamut response headers to advertise wide gamut support
- Extend avatar MIME type validation for HDR formats

Supported formats:
- Images: HEIC, HEIF, WebP, PNG, JPEG
- Videos: MP4, QuickTime, Matroska, WebM (VP9 Profile 2)

Browser support:
- Safari 14.1+, Chrome 118+, Edge 118+
- Gracefully degrades to sRGB on unsupported browsers
2026-01-03 13:16:56 +08:00
Johnny e761ef8684 chore: move memo-metadata components to MemoView and MemoEditor
- Remove shared memo-metadata folder
- Move metadata display components (AttachmentList, LocationDisplay, RelationList) to MemoView/components/metadata
- Move attachment types and utilities (LocalFile, AttachmentItem, toAttachmentItems) to MemoEditor/types/attachment
- Simplify AttachmentList and AttachmentCard to work directly with Attachment proto
- Update all imports across MemoEditor and MemoView components
- Better separation of concerns: MemoView handles display, MemoEditor handles local files + attachments
2026-01-03 13:07:53 +08:00
Johnny a6e8ba7fb2
refactor: consolidate MemoEditor components (#5409) 2026-01-03 12:49:13 +08:00