Commit graph

1302 commits

Author SHA1 Message Date
brxken128 f81c1b35a8 basic single file duplication 2023-01-20 13:12:11 +00:00
Brendan Allan 24de617b92
Fix webkit reload (#534)
* wrap WKWebView in UnsafePointer

* formatting

* more formatting
2023-01-20 00:25:12 -08:00
maxichrome 0be71dc955
Merge pull request #533 from spacedriveapp/consistent-formatting-please
Enforce consistent formatting
2023-01-19 21:51:48 -08:00
maxichrome 49218cb1bb Merge branch 'main' of github.com:spacedriveapp/spacedrive into consistent-formatting-please 2023-01-19 20:41:59 -08:00
maxichrome 10258bbb88 rm not-strictly-necessary pnpm before lefthook install 2023-01-19 20:31:35 -08:00
maxichrome 7a107f134c refresh pnpm lockfile 2023-01-19 20:29:51 -08:00
maxichrome 9903625d15 don't use symlinked binaries (pnpm bugfix!) 2023-01-19 20:29:32 -08:00
Brendan Allan ff5b80cc1a Merge branch 'main' of https://github.com/spacedriveapp/spacedrive 2023-01-20 12:21:23 +08:00
Brendan Allan 77fb8a27e8 make alias resolver independent of package/app 2023-01-20 12:21:20 +08:00
maxichrome cda8236de6 prefix lefthook install with pnpm because executability is broken 2023-01-19 19:58:49 -08:00
Ericson "Fogo" Soares 50a8eb689b
[ENG-342] Block location watcher for files that are being actively modified (#522)
* Introducing LocationManager to stop and reinit watching a location

* Temporarely ignore events for a path at location manager

* Refactoring some functions to a functional style
Also introducing a tracing directive to use info level on manager logs
and fixing pnpm prep due to a conditional compilation error

* Refactoring location manager actor

* Fixing pnpm prep due to conditional compilation problems
2023-01-19 19:49:23 -08:00
maxichrome ec4352a30a cleanup(don't hate me): prettier format everything 2023-01-19 19:32:35 -08:00
maxichrome 62bcd3e0f6 don't let prettier ruin vite config :( 2023-01-19 19:30:55 -08:00
maxichrome 5e7e484753 let prettier determine its own supported types 2023-01-19 19:27:46 -08:00
maxichrome dd6a72cedc ensure more things are ignored by prettier 2023-01-19 19:27:10 -08:00
maxichrome 5ba70c79b0 Merge branch 'main' of github.com:spacedriveapp/spacedrive into consistent-formatting-please 2023-01-19 19:24:04 -08:00
Brendan Allan c2ab9466f5
New dialog system (#531)
* use new dialog system

* rename + cleanup

* fix util imports

* remove GenericAlertDialog*

* remove unnecessary setShow
2023-01-19 19:23:22 -08:00
maxichrome a682e8c9a8 format & comment prettier ignore 2023-01-19 19:22:13 -08:00
maxichrome 7268495b6f install lint-staged 2023-01-19 19:19:35 -08:00
maxichrome 58dacf5eef prettier: ignore pnpm lockfile 2023-01-19 19:19:19 -08:00
Brendan Allan edfccd9f54 update prettierignore 2023-01-20 11:17:56 +08:00
maxichrome 289fc109fd i love lint-staged 2023-01-19 19:15:33 -08:00
maxichrome cfbd0d16aa better sort packages by external/package/local 2023-01-19 18:30:59 -08:00
maxichrome fc2e1e3ae5 integrate lefthook precommit formatting 2023-01-19 13:08:55 -08:00
maxichrome 62d731aeb9 update prettier config 2023-01-19 13:08:55 -08:00
jake 0a31e7f8ce
[ENG-257] File erasure and deletion (#524)
* add helper functions for getting context-menu related filesystem info

* update comments and such

* add a barebones delete job

* add file deletion route

* add (empty but working) delete file dialog

* add super experimental file erase function

* update function doc

* add erase files route

* add erase files job

* tweak file erasing in crypto crate

* bindings

* add erase files dialog

* add missing `?`

* fix erase file form trickery

* remove unused imports

* terrible attempt at recursion for file erase

* IT WORKS

* code cleanup + clippy

* async just dropped (not for erase yet)

* async erase just dropped (+async crypto crate)

* add "nice data" for jobs
2023-01-18 19:55:14 -08:00
Brendan Allan 2059c64e1f
stop doing useRef outside component (#530) 2023-01-18 19:49:17 -08:00
Brendan Allan 1041cb6e3c
use latest swift-rs (#526)
* use latest swift-rs

* update cargo lock
2023-01-17 06:37:32 -08:00
jake 0ef7f64bbb
[ENG-328] Keymanager mounting queue (#514)
* add `get_queue` and `is_queued` to KM and router

* mark keys as being mounted/finished mounting, use a `DashSet` instead of vec

also includes temporary `dbg!()`s for manual valdiation that it works

* remove dbg and fix build (works great)

* mark key manager as unlocking correctly

* cleanup keys api

* add `KeyAlreadyQueued` error

* use react mounting queue

* fully prevent against multiple mount jobs of the same key with the rust queue

* show keymanager as unlocking in the UI

* handle query invalidation for `isKeyManagerUnlocking` with a closure (semi-temporary)

* revert changing text (doesn't work where the keymanager is unlocked from, only the other unlock screen)

* clippy

* add `useRef` for mounting queue within react

* pass `ref.current` to `Key` instead
2023-01-17 06:19:54 -08:00
Ericson "Fogo" Soares 31d04d5594
[ENG-333] Handle .spacedrive existing instead of throwing error (#521)
* Removing metadata files that failed to be deserialized

* Reintroducing deserialize error for location metadata on prod builds
2023-01-17 06:17:14 -08:00
Jeremy Möglich 1a1ddf3409
Desktop - Add more tooltips (#519) 2023-01-16 17:32:14 -08:00
Brendan Allan a53b162f4b
make separate tsconfig for landing server (#525) 2023-01-16 17:18:20 -08:00
Ericson "Fogo" Soares 31b5c4b1db
Merge pull request #517 from spacedriveapp/eng-304-too-many-files-macos-unhappy-with-prod
[ENG-304] "Too many files" macOS unhappy with prod!
2023-01-16 20:03:45 -03:00
Brendan Allan 8e479f736f
Eng 332 auto generate sync ids (#523)
* generate sync ids and use model name from ModelActions

* cleanup AddLocationDialog imports

* rustfmt
2023-01-15 07:25:11 -08:00
maxichrome 02b4c2eba6 remove stray comma on Spaces page 2023-01-13 22:11:50 -08:00
Ericson "Fogo" Soares 6b17409a72 Fixing unit tests for MacOS 2023-01-13 17:02:57 -03:00
Ericson "Fogo" Soares 4638f104be MacOS file system event handling using FSEvents backend 2023-01-13 15:55:16 -03:00
Brendan Allan ae94ada4f8
Begin form abstraction (#515) 2023-01-12 07:26:59 -08:00
Brendan Allan 9966d8eb65 use origin instead of url for web 2023-01-12 18:56:26 +08:00
Ericson Fogo Soares a18b2f8c8b Trying to figure out why events didn't matched 2023-01-11 19:46:34 -03:00
Ericson Fogo Soares cb8820fe47 Checking MacOS file system events using FSEvents instead od Kqueue 2023-01-11 18:57:41 -03:00
jake 0d554e9d06
[ENG-331] StoredKey overhaul (#513)
* add wip storedkey versioning

* storedkey versioning! (not pretty, but it never will be)

* add version to `StoredKey` and re-gen migrations to handle serde

* use `serde` for interacting with the DB + handle errors
2023-01-11 05:15:08 -08:00
Utku 783d7736f6
Mobile Explorer (#512)
* Fix spacing

* Primitive popup menu

* Sort by & layout menu

* Add sort direction

* Style sort by menu

* new file icons

* thumb wrapper

* update packages & fix folder color

* explorer list & grid views

* Fix grid view spacing

* Grid image sizing

* Explorer store + calculation of grid item size

* Explorer list view

* Explorer store on filerow too
2023-01-11 14:39:19 +03:00
jake 4536710586
Detect SD-encrypted files and display them as such (#511)
* add encrypted file magic bytes/extension

* use archive icon for encrypted files temporarily

* use pascal case for encrypted extensions

Co-authored-by: Brendan Allan <brendonovich@outlook.com>
2023-01-11 00:40:49 -08:00
jake 434bc81deb
[ENG-329] Crypto dialog refactor (#509)
* update backup restoration dialog

* restructure MPC dialog

* refactor `EncryptFileDialog`

* dialog changes

Co-authored-by: Brendan Allan <brendonovich@outlook.com>
2023-01-11 00:38:45 -08:00
maxichrome 50b788f9e6 Update references to the core team 2023-01-10 17:41:09 -08:00
jake fbd8b6d199
[ENG-327] Crypto refactor (#510)
* fix secret key showing as `Some()` when it's empty

* rename function

* use `uuid` feature of `rspc`  so clippy works with `--all-features`

* remove dead error

* update clippy rules

* more idiomatic + cleaner hashing, that handles secrets better

* remove dead code + minor refactor of the KM

* cleanup`KeyManager::get_key()`

* cleanup keys router

* variable inlining, idiomatic rust, etc

* clean up encrypt/decrypt jobs

* embed preview media into encrypted files

* even more idiomatic rust

* fix previous file extension code (no amount of idiomatic rust can fix bad patterns)

* hopefully make large serialization slightly more efficient

* remove dead code + old tests

* inline key derivation (not so sure about this one)

* use `then` instead of `if`

* stop using expensive clones

* add `Protected::into_inner()` to prevent `.expose().clone()` patterns

* use `tokio::fs::File` where possible

* add and use `JobError::MissingData`

* use `|| null` for the secret key

* use `block_in_place` for large r/w sync tasks
2023-01-10 12:36:28 -08:00
Brendan Allan c08622827c
Use import aliases (#508)
* implement a bunch of aliases

* build packages with tsc for turbo
2023-01-06 20:21:36 -08:00
Brendan Allan c61c773147
relative imports in @sd/interface (#504) 2023-01-06 19:07:24 -08:00
jake c1b2b1f5ee
[ENG-323] Key manager onboarding fixes (#506)
* add hash with secret functions

* refactor KM to make the secret key both optional, and user-settable

* update library create function and create library dialog

* fix annoying MPC typo

* fix ordering of key manager creation and seeding

* overhaul master password changing UI to support the potentially empty secret key

* patch keymanager unlocking for potentially empty SK

* make create library dialog text more fitting

* remove dead code

* add autogeneration, view/hide, copy to clipboard icons

* cleanup older code

* make onboarding screen look a tad better

* minor UI tweaks

* patch backup restoration UI

* add pw generation to MP change dialog

* make sure passwords are same before submitting lib creation

* UI fixes and allow setting algorithm/hashing algorithm for master password

* make sure KM is re-seeded on SD load and prevent loading duplicate keys into the keystore

* remove old comment

* small organization

* update encryptfiledialog

* remove dead KM code

* cleanup some TS

* move `PasswordMeter` to separate file

* refactor master password change dialog

* cleanup the TS and improve string -> hashingalgorithm conversions

* add `key` values to selectoption

* capitalise `BLAKE3`

* fix sorting for `getHashingAlgorithmString`

* remove onboarding route

* Revert "add `key` values to selectoption"

This reverts commit 10e6456f22.

* add `key` to `SelectOptionKeyList`

* fix using rspc errors directly

* Update packages/interface/src/components/onboarding/Onboarding.tsx

Co-authored-by: Brendan Allan <brendonovich@outlook.com>

* use `navigator.clipboard.writeText`

* move `OnboardingConfig` to crypto crate

* move `zxcvbn` options outside of component

* further cleanup

* fix mobile typecheck

* fix keylist typo

* improve `SelectOptionKeyList` further

Co-authored-by: Utku Bakir <74243531+utkubakir@users.noreply.github.com>
Co-authored-by: Brendan Allan <brendonovich@outlook.com>
2023-01-06 17:03:22 +00:00