forked from opensearch-project/dashboards-query-workbench
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Shenoy Pratik <[email protected]>
- Loading branch information
Showing
3 changed files
with
196 additions
and
93 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
/* | ||
* Copyright OpenSearch Contributors | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
import { | ||
EuiButtonEmpty, | ||
EuiFlexGroup, | ||
EuiFlexItem, | ||
EuiFlyout, | ||
EuiFlyoutBody, | ||
EuiFlyoutFooter, | ||
EuiFlyoutHeader, | ||
EuiPageHeader, | ||
EuiPageHeaderSection, | ||
EuiSpacer, | ||
EuiTitle, | ||
} from '@elastic/eui'; | ||
import React from 'react'; | ||
|
||
interface AccelerationIndexFlyoutProps { | ||
dataSource: string; | ||
database: string; | ||
dataTable: string; | ||
indexName: string; | ||
resetFlyout: () => void; | ||
} | ||
|
||
export const AccelerationIndexFlyout = ({ | ||
dataSource, | ||
database, | ||
dataTable, | ||
indexName, | ||
resetFlyout, | ||
}: AccelerationIndexFlyoutProps) => { | ||
return ( | ||
<> | ||
<EuiFlyout ownFocus onClose={resetFlyout} aria-labelledby="flyoutTitle" size="m"> | ||
<EuiFlyoutHeader hasBorder> | ||
<div> | ||
<EuiPageHeader> | ||
<EuiPageHeaderSection> | ||
<EuiTitle size="l" data-test-subj="acceleration-index-desc-header"> | ||
<h1>{indexName}</h1> | ||
</EuiTitle> | ||
</EuiPageHeaderSection> | ||
</EuiPageHeader> | ||
</div> | ||
</EuiFlyoutHeader> | ||
<EuiFlyoutBody> | ||
<EuiFlexGroup> | ||
<EuiFlexItem> | ||
<h3>Data Source</h3> | ||
<EuiSpacer /> | ||
<p>{dataSource}</p> | ||
</EuiFlexItem> | ||
<EuiFlexItem> | ||
<h3>Database</h3> | ||
<EuiSpacer /> | ||
<p>{database}</p> | ||
</EuiFlexItem> | ||
<EuiFlexItem> | ||
<h3>Table</h3> | ||
<EuiSpacer /> | ||
<p>{dataTable}</p> | ||
</EuiFlexItem> | ||
</EuiFlexGroup> | ||
</EuiFlyoutBody> | ||
<EuiFlyoutFooter> | ||
<EuiFlexGroup justifyContent="spaceBetween"> | ||
<EuiFlexItem grow={false}> | ||
<EuiButtonEmpty iconType="cross" onClick={resetFlyout} flush="left"> | ||
Close | ||
</EuiButtonEmpty> | ||
</EuiFlexItem> | ||
</EuiFlexGroup> | ||
</EuiFlyoutFooter> | ||
</EuiFlyout> | ||
</> | ||
); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters