Skip to content

refactor(starter): l-section Z パターン命名整合化 — --l-section-padding-min/max (#178)#180

Merged
shunei-web merged 1 commit into
v1.2from
feature/l-section-z-pattern
Apr 29, 2026
Merged

refactor(starter): l-section Z パターン命名整合化 — --l-section-padding-min/max (#178)#180
shunei-web merged 1 commit into
v1.2from
feature/l-section-z-pattern

Conversation

@shunei-web
Copy link
Copy Markdown
Collaborator

概要

l-section.css の Custom Property 命名を Z パターン整合形に変更し、参照側の Project ファイルを一括更新。

変更内容

l-section.css — Z パターン整合形

Before:

.l-section {
  --section-padding-min: var(--section-standard-min);
  --section-padding-max: var(--section-standard-max);
  padding-block: clamp(var(--section-padding-min), 3.462vi + 3.1346rem, var(--section-padding-max));
}

After:

/* 公開 API:
     --l-section-padding-min    (default: var(--section-standard-min))
     --l-section-padding-max    (default: var(--section-standard-max)) */
.l-section {
  --_padding-min: var(--l-section-padding-min, var(--section-standard-min));
  --_padding-max: var(--l-section-padding-max, var(--section-standard-max));
  padding-block: clamp(var(--_padding-min), 3.462vi + 3.1346rem, var(--_padding-max));
}

Project ファイル(3 件 6 箇所)

  • p-numbers.css: --section-padding-min/max--l-section-padding-min/max
  • p-cta.css: 同上
  • p-problem.css: 同上

副次的修正

  • p-faq.css: stylelint --fix による CSS プロパティ順序修正(recess-order: gapmax-inline-size

命名根拠

spec §7 の公開 API 命名規則 --{対象}-{名前} を適用し、Layout Block l-section を対象とした命名。

暫定注記: 現行 spec §7 の例(--section-padding)と一時的に乖離するが、Task #21(mflocss-spec-lead delegate)で spec/agent-reference 側の更新が進行中のため、本 PR では starter 側を先行実装。

確認

  • grep -rn "section-padding-min\|section-padding-max" src/ の旧命名: 0 件
  • pnpm run lint:css — stylelint エラーなし
  • pnpm run lint:js — eslint エラーなし
  • pnpm run build — ビルド成功 (✓ built in 272ms)

参照

@cloudflare-workers-and-pages
Copy link
Copy Markdown

cloudflare-workers-and-pages Bot commented Apr 29, 2026

Deploying starter with  Cloudflare Pages  Cloudflare Pages

Latest commit: b9f358e
Status: ✅  Deploy successful!
Preview URL: https://33ef13c7.starter-20t.pages.dev
Branch Preview URL: https://feature-l-section-z-pattern.starter-20t.pages.dev

View logs

#178)

- 公開 API を `--l-section-padding-min/max` に改名
- Block 冒頭に private 変数(`--_padding-min/max`)を分離し fallback 付き代入
- `padding-block` は private 変数のみ参照

- p-numbers.css: `--section-padding-min/max` → `--l-section-padding-min/max`
- p-cta.css: 同上
- p-problem.css: 同上

- p-faq.css: プロパティ順序修正(gap → max-inline-size の recess-order 整合)

- spec §7 公開 API 命名 `--{対象}-{名前}` から `l-section` を対象とした形式
- 現行 spec §7 例(`--section-padding`)と一時的に乖離するが、
  Task #21(mflocss-spec-lead)で spec/agent-reference 側の更新が進行中

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@shunei-web shunei-web force-pushed the feature/l-section-z-pattern branch from 04cbc6c to b9f358e Compare April 29, 2026 17:55
@shunei-web shunei-web merged commit 0554693 into v1.2 Apr 29, 2026
2 checks passed
@shunei-web shunei-web deleted the feature/l-section-z-pattern branch April 29, 2026 17:56
shunei-web added a commit that referenced this pull request Apr 29, 2026
…revert(spec L695 準拠) (#181)

PR #180 で `--l-section-padding-min/max` に変更した公開 API 名を
`--section-padding-min/max` に戻す。
spec §6 L695 「公開 API は Block 名からプレフィックス除外」原則違反のため。

- l-section.css: コメント + var() 参照を修正
- p-cta.css / p-numbers.css / p-problem.css: override 変数名を修正
- Block 冒頭 --_padding-min/max の private alias 構造は維持

修正前 grep `l-section-padding`: 10件 / 修正後: 0件

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant