chore: upgrade deps
This commit is contained in:
@@ -57,7 +57,7 @@ export const ExtensionPane: FunctionComponent<IProps> = observer(
|
||||
extension={extension}
|
||||
first={false}
|
||||
uninstall={() =>
|
||||
application
|
||||
application.mutator
|
||||
.deleteItem(extension)
|
||||
.then(() => preferencesMenu.loadExtensionsPanes())
|
||||
}
|
||||
|
||||
@@ -48,7 +48,7 @@ export const Extensions: FunctionComponent<{
|
||||
)
|
||||
.then(async (shouldRemove: boolean) => {
|
||||
if (shouldRemove) {
|
||||
await application.deleteItem(extension);
|
||||
await application.mutator.deleteItem(extension);
|
||||
setExtensions(loadExtensions(application));
|
||||
}
|
||||
})
|
||||
@@ -73,7 +73,7 @@ export const Extensions: FunctionComponent<{
|
||||
};
|
||||
|
||||
const confirmExtension = async () => {
|
||||
await application.insertItem(confirmableExtension as SNComponent);
|
||||
await application.mutator.insertItem(confirmableExtension as SNComponent);
|
||||
application.sync.sync();
|
||||
setExtensions(loadExtensions(application));
|
||||
};
|
||||
|
||||
@@ -95,7 +95,7 @@ export const DataBackups = observer(({ application, appState }: Props) => {
|
||||
const performImport = async (data: BackupFile) => {
|
||||
setIsImportDataLoading(true);
|
||||
|
||||
const result = await application.importData(data);
|
||||
const result = await application.mutator.importData(data);
|
||||
|
||||
setIsImportDataLoading(false);
|
||||
|
||||
|
||||
@@ -46,7 +46,7 @@ export const ExtensionItem: FunctionComponent<ExtensionItemProps> = ({
|
||||
const toggleOffllineOnly = () => {
|
||||
const newOfflineOnly = !offlineOnly;
|
||||
setOfflineOnly(newOfflineOnly);
|
||||
application
|
||||
application.mutator
|
||||
.changeAndSaveItem(extension.uuid, (m: any) => {
|
||||
if (m.content == undefined) m.content = {};
|
||||
m.content.offlineOnly = newOfflineOnly;
|
||||
@@ -62,7 +62,7 @@ export const ExtensionItem: FunctionComponent<ExtensionItemProps> = ({
|
||||
|
||||
const changeExtensionName = (newName: string) => {
|
||||
setExtensionName(newName);
|
||||
application
|
||||
application.mutator
|
||||
.changeAndSaveItem(extension.uuid, (m: any) => {
|
||||
if (m.content == undefined) m.content = {};
|
||||
m.content.name = newName;
|
||||
|
||||
@@ -34,7 +34,7 @@ const makeEditorDefault = (
|
||||
if (currentDefault) {
|
||||
removeEditorDefault(application, currentDefault);
|
||||
}
|
||||
application.changeAndSaveItem(component.uuid, (m) => {
|
||||
application.mutator.changeAndSaveItem(component.uuid, (m) => {
|
||||
const mutator = m as ComponentMutator;
|
||||
mutator.defaultEditor = true;
|
||||
});
|
||||
@@ -44,7 +44,7 @@ const removeEditorDefault = (
|
||||
application: WebApplication,
|
||||
component: SNComponent
|
||||
) => {
|
||||
application.changeAndSaveItem(component.uuid, (m) => {
|
||||
application.mutator.changeAndSaveItem(component.uuid, (m) => {
|
||||
const mutator = m as ComponentMutator;
|
||||
mutator.defaultEditor = false;
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user