docs: consolidate design documentation and standardize crate English
This commit is contained in:
@@ -10,12 +10,6 @@ Deno.test("Bevel draws a plain selectable border around semantic children", asyn
|
||||
const appCss = await Deno.readTextFile(
|
||||
new URL("../src/app.css", import.meta.url),
|
||||
);
|
||||
const designLanguage = await Deno.readTextFile(
|
||||
new URL(
|
||||
"../../../docs/development/ui-ux/design-language.md",
|
||||
import.meta.url,
|
||||
),
|
||||
);
|
||||
|
||||
for (
|
||||
const contract of [
|
||||
@@ -73,14 +67,6 @@ Deno.test("Bevel draws a plain selectable border around semantic children", asyn
|
||||
source.includes("button, input, select, textarea"),
|
||||
"Bevel must not own surface color and must keep semantic controls as children",
|
||||
);
|
||||
assert(
|
||||
designLanguage.includes("1pxの単色borderを描くvisual wrapper") &&
|
||||
designLanguage.includes(
|
||||
"照明、raised/inset、ridge/grooveを表現しない",
|
||||
) &&
|
||||
designLanguage.includes("text/content areaへ適用する"),
|
||||
"The design language must define Bevel as a plain border without surface ownership",
|
||||
);
|
||||
});
|
||||
|
||||
Deno.test("Workspace showroom exercises closed and adjacent borders", async () => {
|
||||
|
||||
@@ -83,12 +83,6 @@ Deno.test("Shell regions use selected Bevel edges while open separators use Beve
|
||||
import.meta.url,
|
||||
),
|
||||
);
|
||||
const designLanguage = await Deno.readTextFile(
|
||||
new URL(
|
||||
"../../../docs/development/ui-ux/design-language.md",
|
||||
import.meta.url,
|
||||
),
|
||||
);
|
||||
|
||||
assert(
|
||||
rootLayout.includes('class="app-shell__topbar-bevel"') &&
|
||||
@@ -109,18 +103,9 @@ Deno.test("Shell regions use selected Bevel edges while open separators use Beve
|
||||
"Desktop shell boundaries must use one selected border edge and Mobile must share Header fold state",
|
||||
);
|
||||
assert(
|
||||
designLanguage.includes(
|
||||
"Headerのbottom edgeとSidebarのright edgeだけを有効",
|
||||
) &&
|
||||
designLanguage.includes("Mobileのfold controlはHeaderに置く") &&
|
||||
designLanguage.includes("main contentと同時表示しない") &&
|
||||
designLanguage.includes("同じlayerではheading、本文、Lineの端を揃え") &&
|
||||
designLanguage.includes(
|
||||
"親layoutがそのlayer全体へinline方向の余白を与え",
|
||||
) &&
|
||||
showroomCss.includes(".resource-list {") &&
|
||||
showroomCss.includes(".resource-list {") &&
|
||||
showroomCss.includes("margin-inline: var(--space-2)"),
|
||||
"The design language and showroom must preserve adjacent area and line hierarchy",
|
||||
"showroomはresource layer全体の余白を維持する",
|
||||
);
|
||||
assert(
|
||||
sidebarCss.includes(".section-action {") &&
|
||||
|
||||
@@ -51,12 +51,6 @@ Deno.test("Workspace typography tokens bind the documented three-level scale", a
|
||||
const appCss = await Deno.readTextFile(
|
||||
new URL("../src/app.css", import.meta.url),
|
||||
);
|
||||
const designLanguage = await Deno.readTextFile(
|
||||
new URL(
|
||||
"../../../docs/development/ui-ux/design-language.md",
|
||||
import.meta.url,
|
||||
),
|
||||
);
|
||||
|
||||
for (
|
||||
const contract of [
|
||||
@@ -73,12 +67,4 @@ Deno.test("Workspace typography tokens bind the documented three-level scale", a
|
||||
) {
|
||||
assert(appCss.includes(contract), `app.css must preserve ${contract}`);
|
||||
}
|
||||
|
||||
assert(
|
||||
designLanguage.includes("--font-size-title /* 24px */") &&
|
||||
designLanguage.includes("--font-size-body /* 14px */") &&
|
||||
designLanguage.includes("--font-size-compact /* 12px */") &&
|
||||
designLanguage.includes("`12px`未満と`13px`を使わない"),
|
||||
"The design language must preserve the title, body, and compact typography contract",
|
||||
);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user