Commit Graph

116 Commits

Author SHA1 Message Date
Tienson Qin
2dfac3d774 deprecate: on-disk encryption
Why?
1. there're still a lot issues on it and there's no resource to
maintain and develop it considering we need to support it on all the
platforms.
2. it creates more bugs with Logseq Sync.
2022-11-07 10:46:17 +08:00
Gabriel Horner
2386cbe254 Instrument to debug failure in file/alter-file
Also create a fn to handle uncertain global-config-dir paths.
Follow up to 24975cda01
2022-10-12 15:41:02 -04:00
Tienson Qin
24975cda01 fix: global config root directory may not be ready when used 2022-10-12 22:47:18 +08:00
Peng Xiao
cca1d35510 Merge remote-tracking branch 'upstream/master' into whiteboards 2022-10-08 17:26:45 +08:00
Junyi Du
0e4037ab61 Feat: new file name escaping rules (#6134)
* feat: new file name escaping for namespace

feat: new file name decoding back to page name

* test: file name sanitization

feat: use _0x to encode %

feat: don't create title property

test: extra URL encoding for escaped file names

fix: fit pdf prefix into new file name rules

fix: encoding rules on some characters

fix: handle the buggy file names imported by users

fix: pdf block ref failed to jump

fix: #6167

* fix: enhance backward compatibility

chore: title validation

test: fix namespace queries test

chore: use index version stored in config.edn instead of search.versions

* feat: convert old version graph mechanism

ui: file conversion UI

feat: rename files for conversion

feat: don't trigger conversion when title property is manually edited

fix: file conflict notification while renaming files on some OS

feat: re-index on update version

feat: clicking NO in the re-index dialog would update the index-ver flag to suppress the dialog

feat: use html entities for reserved char escaping

dev: remove unresolved vars & minor refactor

chore: move file name sanity from gp-util to fs-util, as it's for encoding only but not parsing

test: update file name tests to html entities rule

test: convert files from dir ver 3 for repo_tests

feat: convert Windows reserved file names

fix: save index version into idb instead of file

fix: decode uri of path while parsing files on mobile

fix: couple dir version and index version to ensure only re-index on converted dirs

feat: go back to url-encode for special chars

* chore: fix lint

chore: improve codebase to address Gabriel's comments

fix: remove file remnants on add conflict

fix: remove file remnants on rename conflict

chore: add test ns to nbb runner

Also fix typoed fn and remove unused code

* fix: issues of rebase PR6134 to master after file-sync merged

* feat: switchable filename format

* fix: use  go block to replace promesa for rename all with blocking

* feat: re-index after apply rename all

* ui: file conversion enhancement

* fix: merging filename format PR with master

* fix: filename format lint & CI

* ui: filename format flow

* fix: error handling on the rare internal file path confliction case

* chore: shorten component code for files-breaking-changed

* chore: fix CI

* Minor fixes per latest code review

- Remove unused page-name-order
- Update catch usage to be consistent with what's on master
- Place state fn in right place
- Wording fixes:
  - select and apply -> manual. There are no checkboxes for the user
  - Update -> Edit. We use edit for all other settings button
  - Alternatives to starting sentences with May. Not a common way to
    start a sentence
  - update outdated template comment

* ux: rename instruction update

* ux: rename instruction update (2)

* Tweak wording of conversion modal

Simplifed first paragraph and explained the page to the user in first
sentence, may isn't a common way to start sentences and updated outdated
wording

* Fix large-var warning by splitting out a piece of component

* fix: right slash on Windows; legacy format file sanitization

* fix: triple lowbar renaming fns

Co-authored-by: Gabriel Horner <gabriel@logseq.com>
2022-10-08 15:47:45 +08:00
Peng Xiao
fd94862312 Merge remote-tracking branch 'upstream/master' into whiteboards 2022-09-24 09:42:00 +08:00
Andelf
ae114afbd8 Feat: sync progress for electron (#6662)
* fix: state shouldn't be returned in ipc

* feat: download && upload processing

* enhance(ui):  interaction of show password checkbox

* feat: time left

* feat: download progress

* Set download batch size to 100

* improve(ui): progress pane of file sync indicator

* improve(ui): progress pie of each file state

* improve(ui): progress pie of each file state

* improve(ui): progress pie of each downloading file

* fix: add last changed time

* enhance: time left

* fix: total needs to be larger than finished

* fix: wait for update-graphs-txid!

* enhance: show in-progress files first

* chore: ui polish

* improve(ui): persist stauts of sync files list toggle switch

* fix(ui): visibility of sync now button on mobile

* chore: remove ios static out after sync

* fix: debounce clicking on sync icon

* fix: repos not refreshed after unlink or delete

* enhance: automatically save page-metadata.edn to avoid sync when restart

* improve(ui): sync now shortcut for file sync progress pane

* enhance: data transfer icons

* fix: stop sync if switched to another graph

* fix: can't switch

* enhance: sort files first before uploading or downloading

* fix: clear current graph uuid when sync stops

* fix: separate progress by graphs

* fix: check files only in the current progress

* fix: prevent multiple sync managers for the same graph

* fix: remove redundant files watchers

* enhance(sync): re-exec remote->local-full-sync when exception

re-exec remote->local-full-sync when <update-local-files return exceptions

* enhance(sync): re-exec remote->local-full-sync when exception

re-exec remote->local-full-sync when <update-local-files return exceptions

* fix(sync): set-progress-callback, update rsapi

* fix(sync): uploading progress bar

Co-authored-by: Tienson Qin <tiensonqin@gmail.com>
Co-authored-by: charlie <xyhp915@qq.com>
Co-authored-by: rcmerci <rcmerci@gmail.com>
2022-09-23 02:00:24 +08:00
Peng Xiao
d59e7fdbe8 Merge remote-tracking branch 'upstream/master' into whiteboards 2022-09-17 13:04:43 +08:00
Tienson Qin
c300d6bc02 fix: sync status 2022-09-15 23:58:55 +08:00
Peng Xiao
eaec72e676 Merge remote-tracking branch 'upstream/master' into whiteboards 2022-09-14 00:26:16 +08:00
Gabriel Horner
f157490d61 3 fixes where global-config as incorrectly called for non desktop
These issues were introduced with #6531. The global-config component
should not be called if not in a supported platform. This fixes
re-index, switching graphs and editing config.edn for mobile.  Switching
graphs was partially fixed in #6664 but didn't address the root cause
which is the global-handler component shouldn't be called if not enabled
for a platform
2022-09-13 12:25:41 +08:00
Peng Xiao
4d86f4f53f Merge remote-tracking branch 'upstream/master' into whiteboards 2022-09-10 00:45:27 +08:00
Gabriel Horner
b1d210d26b Merge configs and create global config file if not present
- Cleanup repo and global config with system components
- test merging
- fix edge cases
2022-09-08 12:34:27 +08:00
Gabriel Horner
095a4ef1cd Save global config edits
Also alert user if write fails
2022-09-08 12:34:27 +08:00
Gabriel Horner
9c0bb02dcd Can access read global config file from UI
Only for reload case
2022-09-08 12:34:27 +08:00
Andelf
5b50e229e0 refactor(sync): rename graph-txid to graphs-txid 2022-09-08 11:38:59 +08:00
Peng Xiao
5e44055984 Merge remote-tracking branch 'upstream/master' into whiteboards 2022-09-02 09:46:58 +08:00
Andelf
ba0a67ae05 fix(ios): handle ios indexedDB preload 2022-09-02 00:09:51 +08:00
Andelf
63d268f5f0 fix: aways clean all load state when nfs open 2022-09-01 16:50:15 +08:00
Peng Xiao
33885e619b Merge remote-tracking branch 'upstream/master' into whiteboards 2022-09-01 10:29:29 +08:00
Charlie
01d879c18e feat!: File Sync (#5355)
- file sync for electron/ios/android
- age encryption of both file content and file path
- massive UI enhancement
- corresponding CI tasks

Co-authored-by: llcc <lzhes43@gmail.com>
Co-authored-by: rcmerci <rcmerci@gmail.com>
Co-authored-by: Tienson Qin <tiensonqin@gmail.com>
Co-authored-by: Andelf <andelf@gmail.com>
Co-authored-by: Gabriel Horner <gabriel@logseq.com>
2022-09-01 00:31:49 +08:00
Peng Xiao
4de59c6d63 wip whiteboard page 2022-07-04 00:00:08 +08:00
Tienson Qin
b7ae3684be fix: notify graph dir is gone when starting or running the apps
Also, disabled both re-index and refresh when logseq detects that
a graph's dir doesn't exists anymore.
2022-06-13 19:16:34 +08:00
Tienson Qin
156b152129 fix: slow re-index for large graphs with page-metadata.edn
related to #5547
2022-06-13 17:43:24 +08:00
Gabriel Horner
5bce219ca4 Remove unused db-type being passed to start-conn
Also removed other unused db fns
2022-05-26 18:04:45 -04:00
Gabriel Horner
11d3d5b3cd Remove unused :me/* attributes
These were removed in b3f67c69b1.
Also removed related, unused spec
2022-05-26 18:04:45 -04:00
llcc
df33aba4e6 Merge branch 'master' into disable-webview-resize 2022-05-23 21:09:38 +08:00
Andelf
1e3a628c31 fix(fs-watcher): notify all files, skip read non-text files 2022-05-21 13:21:02 +08:00
llcc
edf4943298 Merge branch 'master' into disable-webview-resize 2022-05-10 17:12:14 +08:00
Tienson Qin
83569141fc feat: add encryption back 2022-05-09 22:15:30 +08:00
llcc
628fd0f3e4 Merge branch 'master' into disable-webview-resize 2022-05-09 19:44:40 +08:00
Gabriel Horner
a58a411567 Move config fns and remaining util fns that mldoc depends on 2022-05-04 12:02:36 -04:00
Gabriel Horner
85bd1fecb2 Move first batch of util fns to graph-parser.util
Still need to fix external.roam
2022-05-04 12:02:36 -04:00
llcc
9e568c8016 enhance(iOS): disable webview resize 2022-04-29 11:19:44 +08:00
Tienson Qin
b3f67c69b1 misc: delete both web github integration and encryption 2022-04-24 11:17:47 +08:00
Tienson Qin
71e9bdee49 enhance: parsing progress bar 2022-04-21 08:42:52 +08:00
Charlie
0d3ac91ca3 Feature/Setups of Onboarding Process (#4580)
UX enhancement: onboarding setup graphs 

Co-authored-by: llcc <lzhes43@gmail.com>
Co-authored-by: Tienson Qin <tiensonqin@gmail.com>
2022-04-02 21:37:38 +08:00
Andelf
b260648b60 feat(ios): add polling based file watcher 2022-03-04 18:03:33 +08:00
leizhe
86ea102b89 fix(android): app crashes 2022-02-20 23:41:02 +08:00
Tienson Qin
faea913a40 enhance: cut memory usage 2022-02-08 15:49:09 +08:00
Junyi Du
1fd160d9dd fix: ignore changes in bak folder 2022-01-27 09:33:00 +08:00
leizhe
170b2e6f93 remove unnecessary icloud download function 2022-01-24 13:26:04 +08:00
Junyi Du
37f08d96e1 enhance: normalize all paths in app 2022-01-20 10:33:50 +08:00
Gabriel Horner
3ec587d6eb lint :all-the-things: 2022-01-16 12:42:34 +08:00
leizhe
55fdfa6ae9 fix iCloud files conflict
Files in iCloud will be downloaded at first by clicking New Graph/Re-index/Refresh.

But remember that if your file created on mobile or desktop is not
uploaded to cloud, you will never get your file synced correctly.
So please confirm if the file (with cloud icon at the top right
corner) in File/Finder at first if you failed to see you file's
update.
2022-01-06 20:26:57 +08:00
Tienson Qin
8de131c0e1 fix: separate loading status for different graphs 2021-12-21 23:05:28 +08:00
Tienson Qin
6fb7121397 feat: multiple windows support 2021-12-21 23:05:28 +08:00
Andelf
fd6f6d033c fix: local graph should popup encryption dialog when re-index 2021-12-05 12:06:14 +08:00
Tienson Qin
7101b8c491 fix: can't open graph again on Android 2021-11-27 13:10:34 +08:00
Tienson Qin
7491857460 fix: close the existing watcher when adding new graph
Also, don't create today's journal file during parsing
2021-11-25 13:30:49 +08:00