Skip to content

Commit

Permalink
fix: editor warning message hidden (microsoft#2540)
Browse files Browse the repository at this point in the history
Co-authored-by: Chris Whitten <christopher.whitten@microsoft.com>
Co-authored-by: Andy Brown <asbrown002@gmail.com>
  • Loading branch information
3 people committed Apr 7, 2020
1 parent 74203c6 commit 5314430
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Expand Up @@ -3,7 +3,7 @@

import React, { useState } from 'react';

import { RichEditor } from '../../src';
import { BaseEditor } from '../../src';

const LU_HELP = 'https://aka.ms/lu-file-format';

Expand All @@ -28,7 +28,7 @@ export default function App() {
<button onClick={() => setShowError(!showError)}>Toggle Error</button>
<button onClick={() => setShowWarning(!showWarning)}>Toggle Warning</button>
</div>
<RichEditor
<BaseEditor
onChange={newVal => setValue(newVal)}
value={value}
placeholder={placeholder}
Expand Down
2 changes: 1 addition & 1 deletion Composer/packages/lib/code-editor/src/BaseEditor.tsx
Expand Up @@ -59,7 +59,7 @@ const styles = {
border-color: ${borderColor};
transition: border-color 0.1s linear;
box-sizing: border-box;
height: calc(${typeof height === 'string' ? height : `${height}px`} - ${error ? 32 : 0}px);
height: calc(${typeof height === 'string' ? height : `${height}px`} - ${error || warning ? 32 : 0}px);
`;
},
};
Expand Down

0 comments on commit 5314430

Please sign in to comment.