feat(web): remove upload file limit with rxjs and improve import size (#1743)

* feat(web): remove upload file limit with rxjs

* refactor: remove exif

* refactor: remove unused code

* fix: import lodash-es instead of lodash

* refactor: optimize import
This commit is contained in:
Alex
2023-02-13 13:18:11 -06:00
committed by GitHub
parent 37cfac27b8
commit 2c1aab154a
10 changed files with 62 additions and 66 deletions

View File

@@ -2,7 +2,7 @@ import { AssetGridState } from '$lib/models/asset-grid-state';
import { api, AssetResponseDto } from '@api';
import { derived, writable } from 'svelte/store';
import { assetGridState, assetStore } from './assets.store';
import _ from 'lodash-es';
import { sortBy } from 'lodash-es';
// Asset Viewer
export const viewingAssetStoreState = writable<AssetResponseDto>();
@@ -65,7 +65,7 @@ function createAssetInteractionStore() {
const navigateAsset = async (direction: 'next' | 'previous') => {
// Flatten and sort the asset by date if there are new assets
if (assetSortedByDate.length === 0 || savedAssetLength !== _assetGridState.assets.length) {
assetSortedByDate = _.sortBy(_assetGridState.assets, (a) => a.createdAt);
assetSortedByDate = sortBy(_assetGridState.assets, (a) => a.createdAt);
savedAssetLength = _assetGridState.assets.length;
}