/* * CloudBeaver - Cloud Database Manager * Copyright (C) 2020-2023 DBeaver Corp and others * * Licensed under the Apache License, Version 2.0. * you may not use this file except in compliance with the License. */ import { observer } from 'mobx-react-lite'; import styled, { css } from 'reshadow'; import { Button, useTranslate } from '@cloudbeaver/core-blocks'; import { useService } from '@cloudbeaver/core-di'; import { CommonDialogBody, CommonDialogFooter, CommonDialogHeader, CommonDialogWrapper, DialogComponent } from '@cloudbeaver/core-dialogs'; import { RouterService } from '@cloudbeaver/core-routing'; const styles = css` p { margin: 0; } CommonDialogFooter { align-items: center; justify-content: flex-end; gap: 24px; } `; export const ServerNodeChangedDialog: DialogComponent = observer(function ServerNodeChangedDialog({ rejectDialog }) { const routerService = useService(RouterService); const translate = useTranslate(); function reload() { routerService.reload(); } return styled(styles)(

{translate('app_root_server_node_changed_message')}

, ); });