mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Extract states of application update to be usable from all environments
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com> Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
This commit is contained in:
1 parent
d07fd7f4ee
commit
efc8d87d0c
4 files changed
+88
-25
No files matched your search
+18
@@ -0,0 +1,18 @@
|
||||
/**
|
||||
* Copyright (c) OpenLens Authors. All rights reserved.
|
||||
* Licensed under MIT License. See LICENSE in root directory for more information.
|
||||
*/
|
||||
import { getInjectable } from "@ogre-tools/injectable";
|
||||
import createSyncBoxInjectable from "../../sync-box/create-sync-box.injectable";
|
||||
|
||||
const checkingForUpdatesStateInjectable = getInjectable({
|
||||
id: "checking-for-updates-state",
|
||||
|
||||
instantiate: (di) => {
|
||||
const createSyncBox = di.inject(createSyncBoxInjectable);
|
||||
|
||||
return createSyncBox("checking-for-updates");
|
||||
},
|
||||
});
|
||||
|
||||
export default checkingForUpdatesStateInjectable;
|
||||
+18
@@ -0,0 +1,18 @@
|
||||
/**
|
||||
* Copyright (c) OpenLens Authors. All rights reserved.
|
||||
* Licensed under MIT License. See LICENSE in root directory for more information.
|
||||
*/
|
||||
import { getInjectable } from "@ogre-tools/injectable";
|
||||
import createSyncBoxInjectable from "../../sync-box/create-sync-box.injectable";
|
||||
|
||||
const discoveredVersionStateInjectable = getInjectable({
|
||||
id: "discovered-version-state",
|
||||
|
||||
instantiate: (di) => {
|
||||
const createSyncBox = di.inject(createSyncBoxInjectable);
|
||||
|
||||
return createSyncBox("discovered-version-state");
|
||||
},
|
||||
});
|
||||
|
||||
export default discoveredVersionStateInjectable;
|
||||
+18
@@ -0,0 +1,18 @@
|
||||
/**
|
||||
* Copyright (c) OpenLens Authors. All rights reserved.
|
||||
* Licensed under MIT License. See LICENSE in root directory for more information.
|
||||
*/
|
||||
import { getInjectable } from "@ogre-tools/injectable";
|
||||
import createSyncBoxInjectable from "../../sync-box/create-sync-box.injectable";
|
||||
|
||||
const downloadingUpdateStateInjectable = getInjectable({
|
||||
id: "downloading-update-state",
|
||||
|
||||
instantiate: (di) => {
|
||||
const createSyncBox = di.inject(createSyncBoxInjectable);
|
||||
|
||||
return createSyncBox("downloading-update");
|
||||
},
|
||||
});
|
||||
|
||||
export default downloadingUpdateStateInjectable;
|
||||
Reference in new issue
Block a user