Co-authored-by: Cristina Amico <criamico@users.noreply.github.com>
This commit is contained in:
parent
6072b5e12e
commit
352695e656
1 changed files with 33 additions and 25 deletions
|
@ -17,12 +17,17 @@ import {
|
|||
EuiFieldPassword,
|
||||
EuiCodeBlock,
|
||||
} from '@elastic/eui';
|
||||
import styled from 'styled-components';
|
||||
|
||||
import type { RegistryVarsEntry } from '../../../../types';
|
||||
import { CodeEditor } from '../../../../../../../../../../src/plugins/kibana_react/public';
|
||||
|
||||
import { MultiTextInput } from './multi_text_input';
|
||||
|
||||
const FixedHeightDiv = styled.div`
|
||||
height: 300px;
|
||||
`;
|
||||
|
||||
export const PackagePolicyInputVarField: React.FunctionComponent<{
|
||||
varDef: RegistryVarsEntry;
|
||||
value: any;
|
||||
|
@ -55,6 +60,7 @@ export const PackagePolicyInputVarField: React.FunctionComponent<{
|
|||
<pre>{value}</pre>
|
||||
</EuiCodeBlock>
|
||||
) : (
|
||||
<FixedHeightDiv>
|
||||
<CodeEditor
|
||||
languageId="yaml"
|
||||
width="100%"
|
||||
|
@ -78,8 +84,10 @@ export const PackagePolicyInputVarField: React.FunctionComponent<{
|
|||
glyphMargin: false,
|
||||
folding: false,
|
||||
lineDecorationsWidth: 0,
|
||||
overviewRulerBorder: false,
|
||||
}}
|
||||
/>
|
||||
</FixedHeightDiv>
|
||||
);
|
||||
case 'bool':
|
||||
return (
|
||||
|
|
Loading…
Reference in a new issue