From 8b776185ab49854151cc09cf08f0ca85d8182e40 Mon Sep 17 00:00:00 2001 From: thzxx <1440196015@qq.com> Date: Fri, 24 Jul 2026 17:43:31 +0800 Subject: [PATCH] fix(style): set color on highlight layer so non-highlighted text is visible Add color: var(--md-text) to .me-highlight-layer base style Add color: var(--md-text) to .mh-bold span Without this, non-matched plain text in the highlight overlay was invisible when textarea text is transparent --- src/styles.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/styles.js b/src/styles.js index c435fdc..40c3056 100644 --- a/src/styles.js +++ b/src/styles.js @@ -139,9 +139,10 @@ const generateCSS = () => { font-family: var(--md-mono); font-size: 13.5px; line-height: 1.7; white-space: pre-wrap; word-wrap: break-word; pointer-events: none; background: transparent; + color: var(--md-text); } .mh-heading { color: var(--md-accent); font-weight: 700; } - .mh-bold { font-weight: 700; } + .mh-bold { color: var(--md-text); font-weight: 700; } .mh-italic { font-style: italic; } .mh-strike { color: var(--md-muted); text-decoration: line-through; } .mh-code { background: var(--md-code-bg); border-radius: 3px; padding: 0 2px; }