This commit is contained in:
Cai
2025-09-21 14:04:05 +08:00
88 changed files with 1743 additions and 448 deletions

View File

@@ -114,7 +114,7 @@
/* 主容器,使用 grid 布局 */
#maxcontainer {
display: grid;
grid-template-columns: 1fr 5px 3fr 5px 1fr; /* 默认宽度比例 */
grid-template-columns: 2fr 5px 3fr 5px 1fr; /* 默认宽度比例 */
height: 100%;
}

View File

@@ -725,6 +725,10 @@ function sanitizeHeadingsBeyondFirst(text = "") {
// PUT 请求保存更新
try {
console.log("saveToOrigin", CURRENT.links.lesson, CURRENT.links.prompt, CURRENT.links.score);
console.log("updatedLesson", updatedLesson);
console.log("updatedPrompt", updatedPrompt);
console.log("updatedScore", updatedScore);
const result = await saveToOrigin({
lesson: { cdn_link: CURRENT.links.lesson, content: updatedLesson },
prompt: { cdn_link: CURRENT.links.prompt, content: updatedPrompt },
@@ -771,6 +775,11 @@ function sanitizeHeadingsBeyondFirst(text = "") {
// 替换该步骤内容
const lines = [...parsed.lines];
console.log("lines length", lines.length);
console.log("startLine", startLine);
console.log("endLine", endLine);
console.log("endLine - startLine + 1", endLine - startLine + 1);
console.log("newContent", newContent);
lines.splice(startLine, endLine - startLine + 1, newContent); // 用新内容替换
return lines.join('\n'); // 返回更新后的完整内容