@fc-components/monaco-editor 0.1.22 → 0.1.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "publishConfig": {
4
4
  "access": "public"
5
5
  },
6
- "version": "0.1.22",
6
+ "version": "0.1.24",
7
7
  "license": "MIT",
8
8
  "main": "dist/index.js",
9
9
  "module": "dist/monaco-editor.esm.js",
package/src/sql/index.tsx CHANGED
@@ -165,7 +165,7 @@ export default function SqlEditor(props: SqlEditorProps) {
165
165
  const containerDiv = containerRef.current;
166
166
  if (containerDiv !== null) {
167
167
  const pixelHeight = editor.getContentHeight();
168
- containerDiv.style.height = `${pixelHeight}px`;
168
+ containerDiv.style.minHeight = `${pixelHeight}px`;
169
169
  containerDiv.style.width = '100%';
170
170
  const pixelWidth = containerDiv.clientWidth;
171
171
  editor.layout({ width: pixelWidth, height: pixelHeight });
@@ -242,7 +242,12 @@ export default function SqlEditor(props: SqlEditorProps) {
242
242
  maxHeight,
243
243
  }}
244
244
  >
245
- <div ref={containerRef}>
245
+ <div
246
+ ref={containerRef}
247
+ style={{
248
+ height: '100%',
249
+ }}
250
+ >
246
251
  <MonacoEditor
247
252
  width='100%'
248
253
  height='100%'
@@ -262,7 +267,6 @@ export default function SqlEditor(props: SqlEditorProps) {
262
267
  scrollBeyondLastLine: false,
263
268
  smoothScrolling: true,
264
269
  fontSize,
265
- lineHeight: 24,
266
270
  tabSize: 2,
267
271
  wordWrap: 'on',
268
272
  automaticLayout: true,