fix monaco editor script view resize 24437 (#3503)

This commit is contained in:
LevVadim 2022-12-05 12:17:15 +02:00 committed by GitHub
parent b941ca89cc
commit 06aee918c3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 12 additions and 4 deletions

View file

@ -9,10 +9,18 @@
left: 0;
top: 0;
width: 100%;
height: 100%;
max-height: 100% !important;
max-width: 100%;
min-height: 130px;
max-height: 200px !important;
margin: 0;
padding: 0;
--tw-border-opacity: 1;
border: 1px solid rgb(209 213 219 / var(--tw-border-opacity));
-moz-appearance: textfield-multiline;
-webkit-appearance: textarea;
overflow: auto;
resize: both;
min-width: 100%;
}
.monaco-editor {

View file

@ -213,9 +213,9 @@ export class MonacoEditor {
const padding = this.padding || 'pt-1.5 pl-1';
return (
<Host
class="monaco-editor-host border focus:ring-blue-500 focus:border-blue-500 block w-full min-w-0 rounded-md sm:text-sm border-gray-300 p-4"
class="monaco-editor-host focus:ring-blue-500 focus:border-blue-500 block w-full min-w-0 sm:text-sm border-gray-300 p-4"
style={{'min-height': this.editorHeight}}>
<div ref={el => this.container = el} class={`monaco-editor-container ${padding}`}/>
<div ref={el => this.container = el} class={`rounded-md monaco-editor-container ${padding}`}/>
</Host>
)
}