fix: Zeilenweise Anzeige in Vorlage korrigieren
Co-authored-by: aider (deepseek/deepseek-reasoner) <aider@aider.chat>
This commit is contained in:
parent
4fa2a1a040
commit
900c82a553
2 changed files with 3 additions and 2 deletions
|
|
@ -247,7 +247,7 @@ document.addEventListener('DOMContentLoaded', function() {
|
|||
// Hilfsfunktion zum Aktualisieren der Zeilenanzeige
|
||||
function updateLineDisplay() {
|
||||
const targetElement = document.getElementById('target-text');
|
||||
targetElement.textContent = lines[currentLineIndex];
|
||||
// Setze nur die aktuelle Zeile mit Hervorhebung
|
||||
updateTextHighlighting('', lines[currentLineIndex]);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -26,7 +26,8 @@
|
|||
<script>
|
||||
window.initialText = {{ current_text|tojson }};
|
||||
window.currentLineIndex = 0;
|
||||
window.lines = window.initialText.split('\n');
|
||||
// Teile den Text in Zeilen auf, behandelt sowohl \n als auch \r\n
|
||||
window.lines = window.initialText.split(/\r?\n/);
|
||||
</script>
|
||||
|
||||
<!-- Eingabefeld -->
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue