chore: 添加前端还原工具并完善提交流程,移除旧指南
- 添加前端还原技能、截图比较工具和可复现测试 - 添加技能副本同步脚本及回归测试 - 补充提交前 SSH 配置与远程连通性检查 - 删除旧 CLI 指南并清理失效的 ESLint 配置 - 忽略 Python 缓存、虚拟环境和本地工具配置
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
:root { color-scheme: light; --ink: #173b36; --paper: #f4f1e8; --accent: #d8efb0; }
|
||||
* { box-sizing: border-box; }
|
||||
body { margin: 0; background: var(--paper); color: var(--ink); font-family: Georgia, serif; }
|
||||
main { max-width: 1100px; margin: auto; padding: 36px 48px; }
|
||||
header { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-bottom: 28px; border-bottom: 1px solid #bec9b6; }
|
||||
.brand, .badge, .eyebrow, label, button, footer, article > span, article > p { font-family: Verdana, sans-serif; }
|
||||
.brand { font-size: 13px; font-weight: bold; letter-spacing: 2px; }
|
||||
.badge { padding: 7px 10px; border: 1px solid #bec9b6; border-radius: 20px; font-size: 11px; }
|
||||
.intro { padding: 48px 0 30px; }
|
||||
.eyebrow { font-size: 11px; letter-spacing: 2px; }
|
||||
h1 { margin: 14px 0; font-size: clamp(36px, 5vw, 56px); font-weight: normal; }
|
||||
.intro > p:last-child { max-width: 510px; font-size: 18px; line-height: 1.6; }
|
||||
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
|
||||
article { padding: 26px; border: 1px solid #bec9b6; background: #fffdf7; border-radius: 12px; }
|
||||
article > span { font-size: 12px; }
|
||||
h2 { font-size: 28px; overflow-wrap: anywhere; }
|
||||
article > p, footer { font-size: 12px; line-height: 1.6; }
|
||||
button { cursor: pointer; padding: 12px 16px; border: 1px solid var(--ink); border-radius: 6px; background: var(--accent); color: var(--ink); font-size: 12px; }
|
||||
button:disabled { cursor: wait; opacity: .6; }
|
||||
button:focus-visible, input:focus-visible { outline: 3px solid #de9e24; outline-offset: 3px; }
|
||||
footer { display: flex; justify-content: space-between; gap: 20px; padding-top: 24px; }
|
||||
dialog { width: min(480px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); overflow: auto; border: 1px solid #bec9b6; border-radius: 14px; padding: 30px; color: var(--ink); background: #fffdf7; }
|
||||
dialog::backdrop { background: #173b3666; }
|
||||
form > label { display: block; font-size: 13px; }
|
||||
input[type="text"], input[name="name"] { width: 100%; margin-top: 10px; padding: 12px; font: 16px Verdana, sans-serif; border: 1px solid #81968c; border-radius: 6px; }
|
||||
#message { min-height: 24px; color: #a23c2a; font: 13px Verdana, sans-serif; }
|
||||
.checkbox { display: flex; gap: 8px; align-items: center; }
|
||||
.actions { display: flex; justify-content: flex-end; gap: 12px; margin-top: 28px; }
|
||||
#cancel { background: transparent; }
|
||||
@media (max-width: 640px) { main { padding: 24px 20px; } header { align-items: flex-start; } .brand { font-size: 11px; } .badge { max-width: 105px; } .intro { padding-top: 28px; } .cards { grid-template-columns: 1fr; gap: 14px; } article { padding: 22px; } footer { flex-direction: column; gap: 0; } }
|
||||
@@ -0,0 +1,32 @@
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<title>Fidelity Lab - Project settings</title>
|
||||
<link rel="icon" href="data:," />
|
||||
<link rel="stylesheet" href="reference.css" />
|
||||
<script src="reference.js" defer></script>
|
||||
</head>
|
||||
<body>
|
||||
<main>
|
||||
<header><span class="brand">FIELDNOTES / LAB</span><span class="badge">Local test fixture</span></header>
|
||||
<section class="intro"><p class="eyebrow">WORKSPACE / 01</p><h1>Project settings</h1><p>One place for a clear name, a small team, and the next release.</p></section>
|
||||
<section class="cards" aria-label="Project overview">
|
||||
<article><span>Project name</span><h2 id="project-name">Atlas studio</h2><button id="edit" type="button">Edit project</button></article>
|
||||
<article><span>Team members</span><h2>06</h2><p>Design and engineering</p></article>
|
||||
<article><span>Release stage</span><h2>Preview</h2><p>Ready for review</p></article>
|
||||
</section>
|
||||
<footer><p>All changes stay in this test page.</p><p>Successful saves: <output id="save-count">0</output></p></footer>
|
||||
</main>
|
||||
<dialog aria-labelledby="dialog-title">
|
||||
<form novalidate>
|
||||
<p class="eyebrow">PROJECT DETAILS</p><h2 id="dialog-title">Edit project</h2>
|
||||
<label for="name">Project name</label><input id="name" name="name" maxlength="40" autocomplete="off" aria-describedby="message" />
|
||||
<p id="message" role="status" aria-live="polite"></p>
|
||||
<label class="checkbox"><input id="fail" type="checkbox" />Simulate one failed request</label>
|
||||
<div class="actions"><button id="cancel" type="button">Cancel</button><button id="save" type="submit">Save changes</button></div>
|
||||
</form>
|
||||
</dialog>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,44 @@
|
||||
const dialog = document.querySelector('dialog');
|
||||
const form = document.querySelector('form');
|
||||
const nameInput = document.querySelector('#name');
|
||||
const failure = document.querySelector('#fail');
|
||||
const message = document.querySelector('#message');
|
||||
const save = document.querySelector('#save');
|
||||
const edit = document.querySelector('#edit');
|
||||
const cancel = document.querySelector('#cancel');
|
||||
const projectName = document.querySelector('#project-name');
|
||||
const count = document.querySelector('#save-count');
|
||||
let pending = false;
|
||||
|
||||
edit.addEventListener('click', () => {
|
||||
nameInput.value = projectName.textContent;
|
||||
failure.checked = false;
|
||||
message.textContent = '';
|
||||
dialog.showModal();
|
||||
nameInput.focus();
|
||||
});
|
||||
cancel.addEventListener('click', () => { if (!pending) dialog.close(); });
|
||||
dialog.addEventListener('cancel', (event) => { if (pending) event.preventDefault(); });
|
||||
dialog.addEventListener('close', () => edit.focus());
|
||||
form.addEventListener('submit', async (event) => {
|
||||
event.preventDefault();
|
||||
if (pending) return;
|
||||
const value = nameInput.value.trim();
|
||||
if (!value) { message.textContent = 'Enter a project name.'; nameInput.focus(); return; }
|
||||
pending = true;
|
||||
save.disabled = true;
|
||||
cancel.disabled = true;
|
||||
message.textContent = 'Saving...';
|
||||
await new Promise((resolve) => setTimeout(resolve, 250));
|
||||
if (failure.checked) {
|
||||
failure.checked = false;
|
||||
message.textContent = 'Request failed. Your input is preserved. Try again.';
|
||||
} else {
|
||||
projectName.textContent = value;
|
||||
count.value = String(Number(count.value) + 1);
|
||||
dialog.close();
|
||||
}
|
||||
pending = false;
|
||||
save.disabled = false;
|
||||
cancel.disabled = false;
|
||||
});
|
||||
@@ -0,0 +1,30 @@
|
||||
:root { color-scheme: light; --ink: #173b36; --paper: #f4f1e8; --accent: #d8efb0; }
|
||||
* { box-sizing: border-box; }
|
||||
body { margin: 0; background: var(--paper); color: var(--ink); font-family: Georgia, serif; }
|
||||
main { max-width: 1100px; margin: auto; padding: 36px 48px; }
|
||||
header { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-bottom: 28px; border-bottom: 1px solid #bec9b6; }
|
||||
.brand, .badge, .eyebrow, label, button, footer, article > span, article > p { font-family: Verdana, sans-serif; }
|
||||
.brand { font-size: 13px; font-weight: bold; letter-spacing: 2px; }
|
||||
.badge { padding: 7px 10px; border: 1px solid #bec9b6; border-radius: 20px; font-size: 11px; }
|
||||
.intro { padding: 48px 0 30px; }
|
||||
.eyebrow { font-size: 11px; letter-spacing: 2px; }
|
||||
h1 { margin: 14px 0; font-size: clamp(36px, 5vw, 56px); font-weight: normal; }
|
||||
.intro > p:last-child { max-width: 510px; font-size: 18px; line-height: 1.6; }
|
||||
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
|
||||
article { padding: 26px; border: 1px solid #bec9b6; background: #fffdf7; border-radius: 12px; }
|
||||
article > span { font-size: 12px; }
|
||||
h2 { font-size: 28px; overflow-wrap: anywhere; }
|
||||
article > p, footer { font-size: 12px; line-height: 1.6; }
|
||||
button { cursor: pointer; padding: 12px 16px; border: 1px solid var(--ink); border-radius: 6px; background: var(--accent); color: var(--ink); font-size: 12px; }
|
||||
button:disabled { cursor: wait; opacity: .6; }
|
||||
button:focus-visible, input:focus-visible { outline: 3px solid #de9e24; outline-offset: 3px; }
|
||||
footer { display: flex; justify-content: space-between; gap: 20px; padding-top: 24px; }
|
||||
dialog { width: min(480px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); overflow: auto; border: 1px solid #bec9b6; border-radius: 14px; padding: 30px; color: var(--ink); background: #fffdf7; }
|
||||
dialog::backdrop { background: #173b3666; }
|
||||
form > label { display: block; font-size: 13px; }
|
||||
input[type="text"], input[name="name"] { width: 100%; margin-top: 10px; padding: 12px; font: 16px Verdana, sans-serif; border: 1px solid #81968c; border-radius: 6px; }
|
||||
#message { min-height: 24px; color: #a23c2a; font: 13px Verdana, sans-serif; }
|
||||
.checkbox { display: flex; gap: 8px; align-items: center; }
|
||||
.actions { display: flex; justify-content: flex-end; gap: 12px; margin-top: 28px; }
|
||||
#cancel { background: transparent; }
|
||||
@media (max-width: 640px) { main { padding: 24px 20px; } header { align-items: flex-start; } .brand { font-size: 11px; } .badge { max-width: 105px; } .intro { padding-top: 28px; } .cards { grid-template-columns: 1fr; gap: 14px; } article { padding: 22px; } footer { flex-direction: column; gap: 0; } }
|
||||
@@ -0,0 +1,32 @@
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<title>Fidelity Lab - Project settings</title>
|
||||
<link rel="icon" href="data:," />
|
||||
<link rel="stylesheet" href="target.css" />
|
||||
<script src="target.js" defer></script>
|
||||
</head>
|
||||
<body>
|
||||
<main>
|
||||
<header><span class="brand">FIELDNOTES / LAB</span><span class="badge">Local test fixture</span></header>
|
||||
<section class="intro"><p class="eyebrow">WORKSPACE / 01</p><h1>Project settings</h1><p>One place for a clear name, a small team, and the next release.</p></section>
|
||||
<section class="cards" aria-label="Project overview">
|
||||
<article><span>Project name</span><h2 id="project-name">Atlas studio</h2><button id="edit" type="button">Edit project</button></article>
|
||||
<article><span>Team members</span><h2>06</h2><p>Design and engineering</p></article>
|
||||
<article><span>Release stage</span><h2>Preview</h2><p>Ready for review</p></article>
|
||||
</section>
|
||||
<footer><p>All changes stay in this test page.</p><p>Successful saves: <output id="save-count">0</output></p></footer>
|
||||
</main>
|
||||
<dialog aria-labelledby="dialog-title">
|
||||
<form novalidate>
|
||||
<p class="eyebrow">PROJECT DETAILS</p><h2 id="dialog-title">Edit project</h2>
|
||||
<label for="name">Project name</label><input id="name" name="name" maxlength="40" autocomplete="off" aria-describedby="message" />
|
||||
<p id="message" role="status" aria-live="polite"></p>
|
||||
<label class="checkbox"><input id="fail" type="checkbox" />Simulate one failed request</label>
|
||||
<div class="actions"><button id="cancel" type="button">Cancel</button><button id="save" type="submit">Save changes</button></div>
|
||||
</form>
|
||||
</dialog>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,44 @@
|
||||
const dialog = document.querySelector('dialog');
|
||||
const form = document.querySelector('form');
|
||||
const nameInput = document.querySelector('#name');
|
||||
const failure = document.querySelector('#fail');
|
||||
const message = document.querySelector('#message');
|
||||
const save = document.querySelector('#save');
|
||||
const edit = document.querySelector('#edit');
|
||||
const cancel = document.querySelector('#cancel');
|
||||
const projectName = document.querySelector('#project-name');
|
||||
const count = document.querySelector('#save-count');
|
||||
let pending = false;
|
||||
|
||||
edit.addEventListener('click', () => {
|
||||
nameInput.value = projectName.textContent;
|
||||
failure.checked = false;
|
||||
message.textContent = '';
|
||||
dialog.showModal();
|
||||
nameInput.focus();
|
||||
});
|
||||
cancel.addEventListener('click', () => { if (!pending) dialog.close(); });
|
||||
dialog.addEventListener('cancel', (event) => { if (pending) event.preventDefault(); });
|
||||
dialog.addEventListener('close', () => edit.focus());
|
||||
form.addEventListener('submit', async (event) => {
|
||||
event.preventDefault();
|
||||
if (pending) return;
|
||||
const value = nameInput.value.trim();
|
||||
if (!value) { message.textContent = 'Enter a project name.'; nameInput.focus(); return; }
|
||||
pending = true;
|
||||
save.disabled = true;
|
||||
cancel.disabled = true;
|
||||
message.textContent = 'Saving...';
|
||||
await new Promise((resolve) => setTimeout(resolve, 250));
|
||||
if (failure.checked) {
|
||||
failure.checked = false;
|
||||
message.textContent = 'Request failed. Your input is preserved. Try again.';
|
||||
} else {
|
||||
projectName.textContent = value;
|
||||
count.value = String(Number(count.value) + 1);
|
||||
dialog.close();
|
||||
}
|
||||
pending = false;
|
||||
save.disabled = false;
|
||||
cancel.disabled = false;
|
||||
});
|
||||
Reference in New Issue
Block a user