refactor(web): dependency management (#2386)
This commit is contained in:
@@ -153,7 +153,7 @@ const IframeFeatureView: FunctionComponent<Props> = ({ onLoad, componentViewer,
|
||||
application.keyboardService.handleComponentKeyUp(data.keyboardModifier)
|
||||
break
|
||||
case ComponentAction.Click:
|
||||
application.controllers.notesController.setContextMenuOpen(false)
|
||||
application.notesController.setContextMenuOpen(false)
|
||||
break
|
||||
default:
|
||||
return
|
||||
@@ -165,13 +165,13 @@ const IframeFeatureView: FunctionComponent<Props> = ({ onLoad, componentViewer,
|
||||
}, [componentViewer, application])
|
||||
|
||||
useEffect(() => {
|
||||
const unregisterDesktopObserver = application
|
||||
.getDesktopService()
|
||||
?.registerUpdateObserver((updatedComponent: ComponentInterface) => {
|
||||
const unregisterDesktopObserver = application.desktopManager?.registerUpdateObserver(
|
||||
(updatedComponent: ComponentInterface) => {
|
||||
if (updatedComponent.uuid === uiFeature.uniqueIdentifier.value) {
|
||||
requestReload?.(componentViewer)
|
||||
}
|
||||
})
|
||||
},
|
||||
)
|
||||
|
||||
return () => {
|
||||
unregisterDesktopObserver?.()
|
||||
|
||||
@@ -3,7 +3,6 @@ import { FunctionComponent, useCallback } from 'react'
|
||||
import Button from '@/Components/Button/Button'
|
||||
import { WarningCircle } from '../UIElements/WarningCircle'
|
||||
import { useApplication } from '../ApplicationProvider'
|
||||
import { openSubscriptionDashboard } from '@/Utils/ManageSubscription'
|
||||
|
||||
type Props = {
|
||||
feature: AnyFeatureDescription
|
||||
@@ -33,7 +32,7 @@ const NotEntitledBanner: FunctionComponent<Props> = ({ featureStatus, feature })
|
||||
const expiredDate = application.subscriptions.userSubscriptionExpirationDate
|
||||
|
||||
const manageSubscription = useCallback(() => {
|
||||
void openSubscriptionDashboard(application)
|
||||
void application.openSubscriptionDashboard.execute()
|
||||
}, [application])
|
||||
|
||||
return (
|
||||
|
||||
Reference in New Issue
Block a user