Commit graph

1499 commits

Author SHA1 Message Date
Utku 54a2eee827
Mobile CI with Tests (#631)
* stuff

* stuff (but for android)

* test mobile ci

* move pnpm up

* install ndk

* add ios & cleanup

* onboarding flow test

* test ci

* fixes, cleanup, caches

* why you do this cargo

* fix pnpm-lock

* add path to build rust script?

* ci is fun

* yolo

* fix broken flow..

* fix pnpm

* probably not gonna work

* test x2

* use real branch of pcr

* android emulator and try ios x2

* Use react native architectures, instead of all.

* override architecture to speed up android build

* protoc & build android on macos too

* fix java ndk

* android gradle

* disable ios for now

* use simulator sdk & debug configuration on ios build

* cleanup

* avd test

* fix avd settings.

* only build for x86_64 on ci

* Fix ios build

* Add IOS testing

* maestro script

* ios release build & wait for library creation

* clean up and disable android for now

* fix pnpm-lock

* Add concurrency to cancel previous runs

* fix pnpm-lock

---------

Co-authored-by: Brendan Allan <brendonovich@outlook.com>
2023-04-03 08:12:28 +00:00
Jamie Pine 76c70d1052
[Fix] Convert blog to markdown, remove Ghost 2023-04-02 14:05:52 -07:00
vloe 8d20fcfe33
added title icons for slots (#660)
slot icons now works w phosphor
2023-03-31 13:36:20 +00:00
Brendan Allan 3aac6254bb
standardise vite configs (#662)
* standardise vite configs

* remove storybook from @sd/ui

* update pnpm lock
2023-03-31 04:08:22 -07:00
nikec fc830ff922
[Desktop] Add label & error to form field (#659)
* Add label and error to form field

* Add error styling

* Update other form fields

* Update FormField.tsx

* Update Input.tsx

* Move field state to hook

* remove required
2023-03-31 10:34:52 +00:00
Brendan Allan 5782af36eb
fix ts (#661)
* fix ts

* eslint
2023-03-31 00:22:54 -07:00
Brendan Allan fcf32575db
remove haden from codeowners 2023-03-30 22:49:11 -07:00
nikec 8aa1a5ff28
[Desktop] Fix edit library navigation (#658)
Fix edit lib navigation
2023-03-31 05:41:54 +00:00
nikec 8584f23b9c
[Desktop] Fix current library label (#656)
Fix current lib label
2023-03-31 05:01:13 +00:00
Ericson "Fogo" Soares b346e7ac52
Eng 372 location awareness improvements (#612)
* Complying with a pedantic Clippy

* Solving duplicated directories events
When creating a directory through MacOS's Finder, for some reason
FSEvents receives 2 Create Folder events that we have to handle

* Handling moving to trash bin and restoring on Mac
Still missing the feature to restore a directory and its children

* Now handling creation of empty files on MacOS

* Enabling restore of directories and its children

* Now working: moving a directory to another
inside the same location

* Now Indexer also remove file_paths not on fs

* Enabling multiple file moves on location watcher

* Fix Windows conditional compilation issues

* Fixing cas_id generation and bumping some deps

* Many Windows specific improvs and some refactors

* Rust fmt

* Using conditional compilation on extract inode function

* Linux fixes and some MaterializedPath improvements

* Rust fmt again

* Introducing tick behavior on location watchers

* Making LastFilePathIdManager more atomic

* Some vscode launch configs for lldb debugger

* Simplifying some lifetimes

* Making all watchers more consistent
2023-03-31 04:59:33 +00:00
nikec 7d996a10cc
[Desktop] Menu tag assignment (#647)
* [Desktop] Improve explorer item context menu tags

* [Desktop] Add tag assignment to file inspector

* clean up

* Update tags/CreateDialog.tsx

---------

Co-authored-by: Brendan Allan <brendonovich@outlook.com>
2023-03-30 03:11:21 +00:00
nikec 04542a367c
[Desktop] Fix popover props (#653)
* clean up, add fade in animation

* Update DebugPopover.tsx
2023-03-30 03:09:01 +00:00
nikec afb2cea12d
[Desktop] Fix input right buttons (#651)
* update color picker

* fix position and ref

* style hex input

* update input field

* add Icon type option

* Update input

* change right padding on lg size

* update other inputs

* update color picker input

---------

Co-authored-by: Brendan Allan <brendonovich@outlook.com>
2023-03-30 03:08:04 +00:00
nikec 5377f1b012
[Desktop] Fix color picker ref forwarding, add hex input and styles (#649)
* update color picker

* fix position and ref

* style hex input
2023-03-30 02:49:19 +00:00
Vítor Vasconcellos fb405f55df
Replace thumbnail server shutdown signal with a channel Receiver (#644)
- Fix tauri signal handlers being overwritten by `axum_shutdown_signal`
2023-03-29 15:47:37 +00:00
nikec 35e8b78634
[Desktop] Fix inspector tag overflow (#637)
* [Desktop] Truncate inspector tag names

* replace title with tooltip
2023-03-29 04:59:41 -07:00
Brendan Allan b2455f9e8c fix typescript 2023-03-29 18:58:41 +08:00
nikec 8f3d135caa
[Desktop] Fix menu colors and arrow highlighting (#639)
* [Desktop] Context Menu cleanup

* [Desktop] Update dropdown with new menu changes

* [UI] Change dark menu line color

* [Desktop] remove menu animate prop and make it a default

* Remove duplicate classes
2023-03-29 10:54:02 +00:00
Brendan Allan faefab2bd6
storybook v7 (#645)
storybook b7
2023-03-29 03:06:19 -07:00
Brendan Allan 21bacba28f
Sync debugging (#643)
* sync no networkey

* sync technically wired up

* fix p2p endianness for sync payload

* some sync debug stuff

* feature gate message production

* bump lockfile

* execute queries when sync messages disabled

* maybe fix ci?

---------

Co-authored-by: Oscar Beaumont <oscar@otbeaumont.me>
2023-03-29 00:38:48 -07:00
Vítor Vasconcellos 94a1f07094
Improve the way react-devtools script is injected in dev mode (#641)
* Improve the way react-devtools script is injected in dev mode
 - Implement a simple vite plugin to inject the reactdevtools script tag before serving index.html
 - Install reactdevtools and concurrently in desktop workspace
 - Replace tauri beforeDevCommand with concurrently for managing background process

* Revert adding concurrently and executing react-devtools alongside tauri desktop app
 - Add instructions on how to run desktop app alongside react-devtools to CONTRIBUTING.md

* Remove unnecessary 'react-devtools' script
 - Update wording in CONTRIBUTING.md to clarify how to launch 'react-devtools'
2023-03-29 05:14:54 +00:00
Vítor Vasconcellos c84e28189c
Fix thumbnails and file previews on Linux (#635)
* Fix thumbnails and file previews on Linux
 - Restructure auth_middleware to use axum's primitives to handle the auth tokens
 - Fix incorrect token loading in App.tsx
 - Add required dependencies for video playback to the Linux setup script
 - Minor improvements to the Linux setup script, make it less error prone
 - Fix a minor bug in the script_failure function in the Linux setup script

* Use a more idiomatic rust syntax in auth_middleware
2023-03-28 21:19:11 +00:00
Vítor Vasconcellos 20f0e7f15a
Fix adding Locations that already have a .spacedrive file (#627)
* Handle RPC errors when adding Locations
 - Add custom error codes for NeedRelink and AddLibraryToMetadata errors in backend
 - Handle errors in AddLocationDialog form
 - Show custom error message for above errors and ask user to confirm action
 - Handle user action confirmation with appropriate RPC method (`locations.relink`/`locations.addLibrary`)

* Abstract openDirectoryPickerDialog logic to a function
 - Add 'Unkown Error' when code doesn't match a know one

* Fix bugs in logic to handle `locations.create` errors
 - Fix minor issue: AddLocationButton opened the dialog in desktop even when the user cancelled the file picker
 - Replace ternary with object for custom form error messages to allow for easier expansion
 - Break onSubmit logic up into functions
 - Remove incorrect `locations.indexer_rules.delete` call
 - Fix Checkbox element state not updating on external form state changes

* Adjust AddLocationDialog style to match other Dialogs in the app
 - Reset exception code at the end of `confirmAfterError`

* Rework how backend errors are handled when adding Locations
 - Change NeedRelink and AddLibraryToMetadata errors to use 409 (Conflict) status code and a static message.
 - Only enable custom submit logic in AddLocationDialog for 409 (Conflict) errors that have a known custom error form message.
 - Differentiate previous errors based on their messages instead of status code in AddLocationDialog onSubmit.
 - Add @hookform/error-message dependency for improved form validation error rendering.

* Invalidate library.list to ensure it is shown on sidebar

* Improvements to AddLocationDialog
 - Remove uncessary scope block and make useEffect depend directly on `form`
 - Move `form.handleSubmit` from `onSubmit` call to `handleSubmit` definition
 - Change basic Checkbox to RadixCheckbox and adapt onChange logic to onCheckedChange
 - Some simple styling improvements to the error message
2023-03-28 07:09:52 +00:00
Oscar Beaumont c2666f7f63
Sync over p2p (#606)
* sync no networkey

* sync technically wired up

* fix p2p endianness for sync payload

* some sync debug stuff

* feature gate message production

* bump lockfile

* execute queries when sync messages disabled

---------

Co-authored-by: Brendan Allan <brendonovich@outlook.com>
2023-03-21 06:03:08 -07:00
nikec bf7d728730
[Desktop] Fix initial edit location load (#626)
[Desktop] Fix initial load
2023-03-21 05:02:16 +00:00
nikec 29f0dfb338
[Desktop, UI] Fix library dropdown overflow & navigation (#619)
* add radix dropdown menu

* [desktop] Improve Libraries Dropdown

* rename alignToParent prop and fix sizing

* Update pnpm-lock.yaml

* Revert "Update pnpm-lock.yaml"

This reverts commit 6113361c51.

* fix pnpm lock
2023-03-21 05:01:48 +00:00
Vítor Vasconcellos 0fd53d1287
Improve AddLocationButton & Implement UI for indexer rules (#620)
* Improve AddLocationButton + Implement UI for indexer rules

* Minor code clean-ups
 - Remove unused variables and imports

* cleanup AddLocationDialog props

---------

Co-authored-by: Brendan Allan <brendonovich@outlook.com>
2023-03-19 17:08:48 +00:00
Vítor Vasconcellos a6a57bbd50
Fix pnpm format command failing with some files (#622)
* Fix `pnpm format` command failure
 - Update prettier and plugins dependencies
 - Add auto-install-peers to .npmrc
 - Fix formating of previously failing files
 - Some basic security mitigations (`pnpm audit --fix`)

* setup-system.sh: Don't do a full system update on ArchLinux

* Revert "Some basic security mitigations (`pnpm audit --fix`)"
2023-03-19 16:47:10 +00:00
nikec 249d5b5534
[desktop] fix tag & location name overflow (#618) 2023-03-19 06:02:10 +00:00
Jamie Pine 2e3c708db8
[Fix] lockfile 2023-03-18 01:49:15 -07:00
Jamie Pine 3ddd83000e
[Refactor] CAS id generation code simplify
Credit: ChatGPT 4
"In this simplified version, the code calculates the sample interval based on the file size and then uses a single loop to handle both the small and large file cases. The last sample is always taken from the end of the file."
2023-03-17 20:11:08 -07:00
Jamie Pine 3b8c866cbc
[Landing Fix] App embed horizontal padding 2023-03-17 20:08:53 -07:00
Utku 902a3b5ba1
Onboarding, Spacedrop & Location Settings Screen & Styled API (#596)
* fix wrong current lib logic

* add delete lib dialog to LibraryGeneralSettings

* add delete lib to mobile LibraryGeneralSettings too

* onboarding screens

* move zxcvbn to @sd/client

* get started screen and bloom

* merge fix

* move generatePassword back to interface

* add useZodForm to mobile and match react-hook-form versions

* new lib screen

* Implement styled api

* create lib screen and some tweaks

* password input

* fix password meter comp

* new library style tweaks

* Fix remove password bug (interface)

* master password screen

* privacy screen

* creating lib screen

* hexagons are cool

* Expo 48

* keyboard handling

* fix P2P on IOS

* fix types

* asset script

* new icons

* Spacedrop screen

* Fix mobile asset imports

* fix import cycle warning

* Edit Location Settings screen and style changes on other setting screens

* fix library creating bug? hopefully lol

* move PasswordMeter to interface

---------

Co-authored-by: Oscar Beaumont <oscar@otbeaumont.me>
2023-03-17 02:00:02 +00:00
Jamie Pine 3b4248c836
[ENG-441] Explorer size toggle (#611)
explorer size toggle + light theme icons start + radix checkbox
2023-03-16 18:59:06 -07:00
Jamie Pine 776c2afd6c
update team page 2023-03-16 14:09:04 -07:00
nikec 1694b09057
add available positions to mobile nav (#613) 2023-03-16 13:20:38 +00:00
nikec e874aed431
fix docs sidebar search input (#614)
fix search input
2023-03-16 13:03:47 +00:00
nikec ff0742441a
fix careers phosphor icons (#615)
fix phosphor icons
2023-03-16 12:54:04 +00:00
Oscar Beaumont d430a56101
fix README logo 2023-03-16 14:34:51 +08:00
Jamie Pine 888e1f6205
job posting 2023-03-15 13:20:54 -07:00
Brendan Allan 145f87cdab
Data Router (#609)
* data router time

* update pnpm.lock
2023-03-15 16:11:47 +00:00
jake e12475a4e1
[ENG-430] *Nix setup script improvements (#602)
* add `protobuf` deps to arch and fedora

* update webkit2gtk package name for fedora >= 37

* revert last change as fedora 37/38 can still use the old name

This reverts commit cc9b2d7053.

* shfmt

* re-introduce webkit changes (and fix my bad bash)

* remove duplicate webkit dep

* update mac setup logic

* remove ffmpeg versioning (we don't use it on any other system)

* check that RPMFusion is enabled

* more verbose protobuf variable names

* add comments/todos and remove unnecessary 64 bit declaration

* fix incorrect command & use latest ffmpeg on macos

* update deps & remove comments
2023-03-15 16:11:15 +00:00
jake 171f19bc71
[ENG-429] Crypto organization/refactor (#607)
* update comment

* key manager feature gating

* update deps & more feature gating

* fix keyring feature gating

* add an `exhaustive_read` function for crypto/stream

* restructure STREAM module

* move tests+shared utils

* clean up stream decryption

* further cleanup

* impl to `GenericArray` for `Nonce`

* update examples

* update refs & `use`s

* fix `Nonce` -> `GenericArray` conversions

* better `Protected` conversions + remove `Password` type

* a work of art

* finishing touches

* some API changes

* rename `StreamX` to `X`

* fix everything else

* separate `primitives` from `types`

* update imports & fix build
2023-03-15 16:09:36 +00:00
Utku 5b6c8c9165
Assets Export Script (#608)
* asset script

* Add commonjs vite plugin

* Use the index file and rename some images

* Delete unsued files and imports

* Change require to import

* Remove @ts-nocheck bcs why not
2023-03-15 11:15:59 +00:00
Brendan Allan 53229809ca
update swift-rs (#605) 2023-03-13 07:53:28 -07:00
Oscar Beaumont 1978e2ff48
Eng 432 refactor mdns service/state (#604)
clean up mdns state and refactor advertisement system
2023-03-13 18:05:46 +08:00
Oscar Beaumont 0c25239c53
Typesafe stream handling (#603)
* typesafe stream handling
Now it's impossible for your to respond to a broadcast stream. Previously this would just fail due to the TCP connection having been closed by the sender.

* remove connected_peers state from `SpaceTime`

* use `OutEvent` instead of `tokio::spawn` for `SpaceTime` events

* Polling for events > tokio::mpsc

* extend max length of sync messages to ~4GB + broadcast done message

* Fix "actOS" operating system decode error
2023-03-13 16:58:35 +08:00
Ericson "Fogo" Soares 4a6b057872
[ENG-371] Subpath shallow re indexing (#599)
* Introducing sub path indexing for IndexerJob

* Introducing shallow indexer job

* Some feature flags to avoid warnings at pnpm prep

* Many fixes at shallow indexer job

* Changing how we implement the bookkeeping for file_path ids
Now we're account for independent locations, and also integrating
better with the LibraryContext, instead of using a static global

* Making indexer job reentrant

* Introducing shallow file identifier job
And a bunch of minor refactors

* Rust fmt

* Removing light scan from getExplorerData query
Light scan is a mutation, so we can call it on useEffect function from
the Explorer component in the frontend, when a location_id or the explorer
path changes

* Handling job early finish on init for identifier

* Only invalidate query if we have orphan paths

* Introducing ShalowThumbnailerJob

* Clippy warnings about `into_iter()`

* Naming scheme for Prisma's selects and includes

* Invalidating getExplorerData at thumbnailer

* Small mistakes lol

* Some nitpicks with pnpm prep

* Rust fmt

* Changing indexer's walk log to `trace!`

* Not deleting all file_paths on location fullRescan

* TS typecheck

* Removing `file_path` selection just with id
2023-03-10 16:25:58 +00:00
Oscar Beaumont 7c5f760fbd
Basic Spacedrop working with rspc! (#601) 2023-03-09 06:23:17 -08:00
Jamie Pine f98d7ad6e0
[ENG-408] Dynamic Object icons (#600)
* improved object icons

* remove redundant control flow

* added support for base icon overrides by extension
+ deleted old icons folder and moved official icons into there

* fixed folder icon error

* removed temp nodes example

---------

Co-authored-by: Brendan Allan <brendonovich@outlook.com>
2023-03-09 11:08:10 +00:00