Skip to content

Commit 0782a2a

Browse files
committed
fix: full screen focus trigger
trigger focus on the editor by clicking anywhere in the available editor area
1 parent 4d95adb commit 0782a2a

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

src/components/editor.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
<template>
2-
<div class="bg-white p-3">
2+
<div class="bg-white p-3 min-80-screen">
33
<div
44
name=""
55
ref="texteditor"
66
autofocus="true"
7-
class="code-editor outline-none min-h-screen w-full"
7+
class="code-editor min-80-screen outline-none min-h-screen w-full"
88
></div>
99
</div>
1010
</template>

src/styles/index.css

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,3 +23,7 @@ span.hljs-bullet {
2323
span.hljs-code {
2424
color: #868e96;
2525
}
26+
27+
.min-80-screen {
28+
min-height: 80vh;
29+
}

0 commit comments

Comments
 (0)