From d38071168ac343a952643647996fca5f1018f2b1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karol=20S=C3=B3jko?= Date: Wed, 6 Jul 2022 14:18:36 +0200 Subject: [PATCH] fix: deps on weba and mobile --- packages/mobile/package.json | 3 --- packages/mobile/src/Lib/ComponentManager.ts | 6 ++++-- packages/mobile/src/Screens/Settings/Settings.tsx | 3 +-- packages/mobile/src/Screens/SideMenu/Files.tsx | 3 +-- packages/mobile/src/Screens/SideMenu/NoteSideMenu.tsx | 3 ++- packages/web/package.json | 2 -- .../Components/Preferences/Panes/Backups/DataBackups.tsx | 2 +- packages/web/src/javascripts/Services/AlertService.ts | 3 +-- packages/web/src/javascripts/Services/ArchiveManager.ts | 2 +- 9 files changed, 11 insertions(+), 16 deletions(-) diff --git a/packages/mobile/package.json b/packages/mobile/package.json index 3764cda7a..d1967ccb9 100644 --- a/packages/mobile/package.json +++ b/packages/mobile/package.json @@ -36,8 +36,6 @@ "@react-navigation/native": "^6.0.10", "@react-navigation/stack": "^6.2.1", "@standardnotes/components-meta": "workspace:*", - "@standardnotes/encryption": "workspace:*", - "@standardnotes/features": "workspace:*", "@standardnotes/filepicker": "workspace:*", "@standardnotes/files": "workspace:*", "@standardnotes/icons": "workspace:*", @@ -47,7 +45,6 @@ "@standardnotes/sncrypto-common": "workspace:*", "@standardnotes/snjs": "workspace:*", "@standardnotes/stylekit": "5.29.3", - "@standardnotes/utils": "workspace:*", "@standardnotes/web": "workspace:*", "@types/styled-components-react-native": "5.1.3", "dompurify": "^2.3.8", diff --git a/packages/mobile/src/Lib/ComponentManager.ts b/packages/mobile/src/Lib/ComponentManager.ts index 43e8418e7..b4752d327 100644 --- a/packages/mobile/src/Lib/ComponentManager.ts +++ b/packages/mobile/src/Lib/ComponentManager.ts @@ -1,10 +1,12 @@ import { MobileTheme } from '@Root/Style/MobileTheme' import { ComponentChecksumsType } from '@standardnotes/components-meta' import RawComponentChecksumsFile from '@standardnotes/components-meta/dist/zips/checksums.json' -import { EncryptionService } from '@standardnotes/encryption' -import { FeatureDescription, FeatureIdentifier, GetFeatures } from '@standardnotes/features' import { ComponentMutator, + EncryptionService, + FeatureDescription, + FeatureIdentifier, + GetFeatures, isRightVersionGreaterThanLeft, PermissionDialog, SNApplication, diff --git a/packages/mobile/src/Screens/Settings/Settings.tsx b/packages/mobile/src/Screens/Settings/Settings.tsx index 15ad7850d..4afb312ae 100644 --- a/packages/mobile/src/Screens/Settings/Settings.tsx +++ b/packages/mobile/src/Screens/Settings/Settings.tsx @@ -4,8 +4,7 @@ import { ModalStackNavigationProp } from '@Root/ModalStack' import { SCREEN_SETTINGS } from '@Root/Screens/screens' import { FilesSection } from '@Screens/Settings/Sections/FilesSection' import { WorkspacesSection } from '@Screens/Settings/Sections/WorkspacesSection' -import { FeatureIdentifier } from '@standardnotes/features' -import { ApplicationEvent, FeatureStatus } from '@standardnotes/snjs' +import { ApplicationEvent, FeatureIdentifier, FeatureStatus } from '@standardnotes/snjs' import React, { useCallback, useEffect, useState } from 'react' import { AuthSection } from './Sections/AuthSection' import { CompanySection } from './Sections/CompanySection' diff --git a/packages/mobile/src/Screens/SideMenu/Files.tsx b/packages/mobile/src/Screens/SideMenu/Files.tsx index 6b80f4cd1..31933f0fd 100644 --- a/packages/mobile/src/Screens/SideMenu/Files.tsx +++ b/packages/mobile/src/Screens/SideMenu/Files.tsx @@ -17,8 +17,7 @@ import { import { SideMenuOptionIconDescriptionType } from '@Root/Screens/SideMenu/SideMenuSection' import { SideMenuCell } from '@Screens/SideMenu/SideMenuCell' import { UploadedFileItemActionType } from '@Screens/UploadedFilesList/UploadedFileItemAction' -import { FeatureIdentifier } from '@standardnotes/features' -import { FeatureStatus, SNNote } from '@standardnotes/snjs' +import { FeatureIdentifier, FeatureStatus, SNNote } from '@standardnotes/snjs' import React, { FC } from 'react' type Props = { diff --git a/packages/mobile/src/Screens/SideMenu/NoteSideMenu.tsx b/packages/mobile/src/Screens/SideMenu/NoteSideMenu.tsx index 499f655d9..20715962b 100644 --- a/packages/mobile/src/Screens/SideMenu/NoteSideMenu.tsx +++ b/packages/mobile/src/Screens/SideMenu/NoteSideMenu.tsx @@ -6,14 +6,15 @@ import { useSafeApplicationContext } from '@Root/Hooks/useSafeApplicationContext import { SCREEN_COMPOSE, SCREEN_INPUT_MODAL_TAG, SCREEN_NOTE_HISTORY } from '@Root/Screens/screens' import { Files } from '@Root/Screens/SideMenu/Files' import { Listed } from '@Root/Screens/SideMenu/Listed' -import { FeatureIdentifier, FindNativeFeature } from '@standardnotes/features' import { ApplicationEvent, ButtonType, ComponentArea, ComponentMutator, ContentType, + FeatureIdentifier, FeatureStatus, + FindNativeFeature, NoteMutator, NoteViewController, PayloadEmitSource, diff --git a/packages/web/package.json b/packages/web/package.json index d321acf5d..107b519ed 100644 --- a/packages/web/package.json +++ b/packages/web/package.json @@ -68,11 +68,9 @@ "@reach/listbox": "^0.16.2", "@reach/tooltip": "^0.16.2", "@reach/visually-hidden": "^0.16.0", - "@standardnotes/encryption": "workspace:*", "@standardnotes/filepicker": "workspace:*", "@standardnotes/files": "workspace:*", "@standardnotes/icons": "workspace:*", - "@standardnotes/services": "workspace:*", "@standardnotes/sncrypto-web": "workspace:*", "@standardnotes/snjs": "workspace:*", "@standardnotes/styles": "workspace:*", diff --git a/packages/web/src/javascripts/Components/Preferences/Panes/Backups/DataBackups.tsx b/packages/web/src/javascripts/Components/Preferences/Panes/Backups/DataBackups.tsx index fe3ce6dcd..a387b2562 100644 --- a/packages/web/src/javascripts/Components/Preferences/Panes/Backups/DataBackups.tsx +++ b/packages/web/src/javascripts/Components/Preferences/Panes/Backups/DataBackups.tsx @@ -10,7 +10,7 @@ import { STRING_LOCAL_ENC_ENABLED, STRING_ENC_NOT_ENABLED, } from '@/Constants/Strings' -import { BackupFile } from '@standardnotes/encryption' +import { BackupFile } from '@standardnotes/snjs' import { ChangeEventHandler, MouseEventHandler, useCallback, useEffect, useRef, useState } from 'react' import { WebApplication } from '@/Application/Application' import { ViewControllerManager } from '@/Services/ViewControllerManager' diff --git a/packages/web/src/javascripts/Services/AlertService.ts b/packages/web/src/javascripts/Services/AlertService.ts index 22af51002..c36685164 100644 --- a/packages/web/src/javascripts/Services/AlertService.ts +++ b/packages/web/src/javascripts/Services/AlertService.ts @@ -1,5 +1,4 @@ -import { ButtonType, sanitizeHtmlString } from '@standardnotes/snjs' -import { AlertService } from '@standardnotes/services' +import { AlertService, ButtonType, sanitizeHtmlString } from '@standardnotes/snjs' import { SKAlert } from '@standardnotes/styles' /** @returns a promise resolving to true if the user confirmed, false if they canceled */ diff --git a/packages/web/src/javascripts/Services/ArchiveManager.ts b/packages/web/src/javascripts/Services/ArchiveManager.ts index ef426a049..4f4976498 100644 --- a/packages/web/src/javascripts/Services/ArchiveManager.ts +++ b/packages/web/src/javascripts/Services/ArchiveManager.ts @@ -1,12 +1,12 @@ import { WebApplication } from '@/Application/Application' import { parseFileName } from '@standardnotes/filepicker' import { + BackupFile, ContentType, BackupFileDecryptedContextualPayload, NoteContent, EncryptedItemInterface, } from '@standardnotes/snjs' -import { BackupFile } from '@standardnotes/encryption' function sanitizeFileName(name: string): string { return name.trim().replace(/[.\\/:"?*|<>]/g, '_')