feat(desktop): built-in Han/Eng layout auto-switching, terminal/Vim support, and Unicode input
This commit is contained in:
parent
1da04b9e46
commit
a3ac44da2b
109 changed files with 8234 additions and 242 deletions
|
|
@ -39,6 +39,8 @@
|
|||
var correction = null
|
||||
var generatingSince = 0
|
||||
var tickTimer = null
|
||||
// 후보 없이 끝났을 때 잠깐 보이는 알림 ('no-suggestion') — 메인이 1초 뒤 창을 닫는다
|
||||
var notice = null
|
||||
|
||||
function render() {
|
||||
candidatesContainer.textContent = ''
|
||||
|
|
@ -46,9 +48,13 @@
|
|||
// 후보가 이미 있으면(채우기 루프가 배경에서 더 만드는 중이어도) 헤더 스피너는
|
||||
// 끈다 — 진행률 줄의 작은 표시가 그 역할을 대신한다(중복 표시 방지).
|
||||
var busy = warmingUp || (generating && candidates.length === 0)
|
||||
if (statusRow) statusRow.hidden = !busy
|
||||
var showNotice = !busy && notice === 'no-suggestion' && candidates.length === 0
|
||||
if (statusRow) statusRow.hidden = !busy && !showNotice
|
||||
if (statusRow) statusRow.classList.toggle('notice', showNotice)
|
||||
if (statusText) {
|
||||
if (warmingUp) {
|
||||
if (showNotice) {
|
||||
statusText.textContent = i18nStrings.suggestionNone || ''
|
||||
} else if (warmingUp) {
|
||||
statusText.textContent = i18nStrings.suggestionWarming || '...'
|
||||
} else if (busy) {
|
||||
// 경과 시간을 보여준다 — 모델이 바쁘면 몇 초 걸리는지 보이는 편이 덜 답답하다.
|
||||
|
|
@ -197,6 +203,7 @@
|
|||
var entries = [
|
||||
[keyHints.move, i18nStrings.suggestionHintMoveLabel, ''],
|
||||
[keyHints.accept, i18nStrings.suggestionHintAcceptLabel, ''],
|
||||
[keyHints.word, i18nStrings.suggestionHintWordLabel, ''],
|
||||
[keyHints.close, i18nStrings.suggestionHintCloseLabel, ' close-hint']
|
||||
]
|
||||
for (var i = 0; i < entries.length; i++) {
|
||||
|
|
@ -252,6 +259,7 @@
|
|||
if (payload.partialText !== undefined) partialText = payload.partialText || null
|
||||
if (payload.provenance !== undefined) provenance = payload.provenance || null
|
||||
if (payload.correction !== undefined) correction = payload.correction || null
|
||||
if (payload.notice !== undefined) notice = payload.notice || null
|
||||
}
|
||||
|
||||
function startTick() {
|
||||
|
|
@ -296,6 +304,7 @@
|
|||
partialText = null
|
||||
provenance = null
|
||||
correction = null
|
||||
notice = null
|
||||
candidates = []
|
||||
activeIndex = 0
|
||||
targetTotal = 0
|
||||
|
|
|
|||
|
|
@ -129,6 +129,15 @@ body {
|
|||
font-size: 12px;
|
||||
}
|
||||
|
||||
/* 후보 없이 끝났을 때의 "제안 사항 없음" — 같은 자리에 스피너 없이 1초 */
|
||||
.status.notice .spinner {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.status.notice .status-text {
|
||||
color: var(--d3-text-tertiary);
|
||||
}
|
||||
|
||||
/* ── 후보 (한 페이지 = 3개, 각 최대 2줄, 고정 높이라 채워져도 창이 흔들리지 않는다) ── */
|
||||
.candidates {
|
||||
display: flex;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue