layout-style-css 3.0.0 → 3.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +154 -0
- package/README.md +9 -4
- package/docs/wiki/Contributing.md +38 -0
- package/docs/wiki/Demo-And-GitHub-Pages.md +44 -0
- package/docs/wiki/Getting-Started.md +63 -0
- package/docs/wiki/Home.md +27 -0
- package/docs/wiki/Installation-And-CDN.md +77 -0
- package/docs/wiki/Layout-Primitives.md +62 -0
- package/docs/wiki/Layout-Recipes.md +58 -0
- package/docs/wiki/Layout-Styles.md +67 -0
- package/docs/wiki/Migrating-To-2.0.md +186 -0
- package/docs/wiki/Migrating-To-3.0.md +205 -0
- package/docs/wiki/Release-And-Publishing.md +62 -0
- package/docs/wiki/Security-And-Support.md +32 -0
- package/docs/wiki/UI-Style-Kit-Compatibility.md +40 -0
- package/docs/wiki/_Sidebar.md +12 -0
- package/manifest.json +98 -0
- package/package.json +25 -8
- package/personalities.json +147 -0
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,154 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to `layout-style-css` are documented here. This project follows semantic versioning.
|
|
4
|
+
|
|
5
|
+
## [3.0.1] - 2026-08-09
|
|
6
|
+
|
|
7
|
+
### Changed
|
|
8
|
+
|
|
9
|
+
- Corrected the GitHub Pages homepage used by npm, kept readable package defaults alongside explicit minified CDN metadata, and included the maintained packaged documentation.
|
|
10
|
+
- Synchronized the package, lockfile, public manifest, demo metadata, Pages sitemap, release guidance, and current ecosystem contract while preserving the complete 13-export API and existing CSS behavior.
|
|
11
|
+
|
|
12
|
+
### Security
|
|
13
|
+
|
|
14
|
+
- Retained the audited dependency overrides and secure release tooling used by the protected publication workflow without adding runtime or peer dependencies.
|
|
15
|
+
|
|
16
|
+
### Tests
|
|
17
|
+
|
|
18
|
+
- Added version-sensitive package, manifest, layout, documentation, demo, Pages, release, packed-export, clean-install, and ecosystem checks for the patch candidate.
|
|
19
|
+
|
|
20
|
+
## [3.0.0] - 2026-07-29
|
|
21
|
+
|
|
22
|
+
### Breaking
|
|
23
|
+
|
|
24
|
+
- Rebuilt the package as a clean-break intrinsic responsive system with attribute-only recipes and one shared container-query engine.
|
|
25
|
+
- Removed `legacy.css`, the deprecated UI Style Kit structural bridge, v1/v2 aliases, recipe class aliases, extensionless export aliases, responsive/order utility families, and the scrollbar-unsafe `.ly-bleed` helper.
|
|
26
|
+
- Reduced the npm tarball to the public generated CSS modules and personality profiles; package metadata, README, and license remain npm-standard package files.
|
|
27
|
+
|
|
28
|
+
### Added
|
|
29
|
+
|
|
30
|
+
- Added `foundation.css` for shared reset, tokens, named `ly-scope` containment, dynamic viewport sizing, and the `44rem`/`30rem` height tiers.
|
|
31
|
+
- Made `.ly-root`, every wrapper, and every recipe root a named responsive scope so recipes work without wrappers and respond to the nearest wrapper when nested.
|
|
32
|
+
- Added `data-ly-responsive="manual"` for application-owned topology with a safe stacked fallback.
|
|
33
|
+
- Added device, independent width/height, automatic/manual, dimension, and active-topology controls to the demo.
|
|
34
|
+
|
|
35
|
+
### Changed
|
|
36
|
+
|
|
37
|
+
- Replaced breakpoint-heavy primitives with intrinsic Grid and Flexbox behavior and standardized shrink safety.
|
|
38
|
+
- Moved Split Hero, List Detail, Docs, App Shell, and Dashboard topology to the shared `42rem`, `44rem`, `48rem`, `52rem`, and `72rem` query tiers.
|
|
39
|
+
- Converted all sixteen personalities into breakpoint-free token/topology profiles with at least two distinguishing spatial characteristics.
|
|
40
|
+
- Made dynamic viewport and container-relative tokens feature-detected enhancements over valid `vh` and `vw` fallbacks.
|
|
41
|
+
- Made manual Gallery and Card Grid recipes single-column, isolated nested personality split ratios, and aligned gap utilities across Grid, Stack, and Cluster.
|
|
42
|
+
- Restricted deliberate horizontal scrolling to Reel and deliberate bounded vertical scrolling to Scroll.
|
|
43
|
+
- Corrected case-sensitive GitHub Pages metadata and versioned local demo assets to prevent stale v2/v3 asset combinations.
|
|
44
|
+
|
|
45
|
+
### Tests
|
|
46
|
+
|
|
47
|
+
- Added package/export/tarball, canonical-selector, removed-surface, generated-parity, ownership, and personality-engine contracts.
|
|
48
|
+
- Added exact flattened/minified parity, actual tarball contents, complete v2 selector migration, nested-profile isolation, and fallback-enhancement contracts.
|
|
49
|
+
- Added threshold-edge, six-device, short-height, root-direct, nearest-wrapper, manual-query, DOM/focus-order, overflow, wrapper, recipe, and all-personality rendered matrices.
|
|
50
|
+
- Made Chromium, Firefox, and WebKit the complete release gate and retained the connected-browser interaction spot check.
|
|
51
|
+
|
|
52
|
+
## [2.1.1] - 2026-07-27
|
|
53
|
+
|
|
54
|
+
### Fixed
|
|
55
|
+
|
|
56
|
+
- Made personality enhancements query the nearest inline-size container while preserving the named personality containment scope for compatibility.
|
|
57
|
+
- Deferred three- and four-track application-shell signatures until their local container reaches `64rem`; existing safe two-track signatures retain their authored thresholds.
|
|
58
|
+
- Gave the Docs recipe a distinct wide two-column shell with navigation spanning the left column and `header`, `main`, `aside`, and `footer` stacked in the right column.
|
|
59
|
+
|
|
60
|
+
### Tests
|
|
61
|
+
|
|
62
|
+
- Added root-wide, local-container fixtures at `47rem`, `49rem`, `63rem`, and `65rem` across all sixteen personalities, including internal overflow, zero-width region, DOM order, and keyboard order checks.
|
|
63
|
+
- Added static contracts for nearest-container personality queries and distinct Dashboard and Docs wide geometry.
|
|
64
|
+
|
|
65
|
+
### Security
|
|
66
|
+
|
|
67
|
+
- Refreshed the development lockfile to patched `fast-uri` and `postcss` releases so the release audit reports no known vulnerabilities; the published CSS package remains dependency-free.
|
|
68
|
+
|
|
69
|
+
## [2.1.0] - 2026-07-20
|
|
70
|
+
|
|
71
|
+
### Changed
|
|
72
|
+
|
|
73
|
+
- Updated the ecosystem demo and documentation to use `ui-style-kit-css@2.1.0` visual CSS, `ui-style-kit-css/interactive-surface-theme.css`, `interactive-surface-css@1.5.0` state core, and Layout core as the canonical import order.
|
|
74
|
+
- Kept `layout-style-css/integrations/ui-style-kit.css` available as a frozen deprecated structural bridge for legacy UI-prefixed layout aliases.
|
|
75
|
+
- Updated release metadata and the GitHub Pages demo to identify the 2.1.0 package line.
|
|
76
|
+
|
|
77
|
+
### Tests
|
|
78
|
+
|
|
79
|
+
- Switched demo fixtures to consume the staged UI Style Kit 2.1 manifest, visual bundle, and token bridge while locking Interactive Surface to the released 1.5.0 package.
|
|
80
|
+
|
|
81
|
+
## [2.0.0] - 2026-07-19
|
|
82
|
+
|
|
83
|
+
### Breaking
|
|
84
|
+
|
|
85
|
+
- Rebuilt the package as a dependency-free, container-first layout system requiring Node.js 20 or newer for development scripts.
|
|
86
|
+
- Replaced size-tier wrappers with compact, prose, content, wide, full, and breakout semantics; wrappers now include fluid logical gutters and safe-area compensation.
|
|
87
|
+
- Standardized personalities, recipes, and regions on `data-ly-layout`, `data-ly-recipe`, and `data-ly-area`.
|
|
88
|
+
- Replaced root personality exports and companion `all-with-ui-kit*` aggregates with focused modules under `personalities/` and `integrations/`.
|
|
89
|
+
- Moved v1 containers, root hooks, columns, and recipe aliases into the opt-in `legacy.css` bundle for the v2 line; removal is scheduled for v3.
|
|
90
|
+
|
|
91
|
+
### Added
|
|
92
|
+
|
|
93
|
+
- Added stack, cluster, center, cover, switcher, sidebar, grid, split, panes, media, reel, frame, and bounded-scroll primitives.
|
|
94
|
+
- Added seven functional recipes that preserve mobile DOM, reading, and focus order while rearranging named areas at `48rem` and `64rem` container thresholds.
|
|
95
|
+
- Made every `data-ly-recipe` value a complete alternative to its matching class and kept explicit wrapper measures authoritative under all personalities.
|
|
96
|
+
- Added sixteen spatially distinct personalities across left-rail, right-rail, three-zone, mosaic, and equal-split families.
|
|
97
|
+
- Added explicit base, medium-container, and large-container order escape hatches with accessibility guidance.
|
|
98
|
+
- Added a maintainable interactive layout lab with allowlisted query state, copyable snippets, ecosystem modes, and rendered coverage at 375px, 768px, 1280px, and 1440px.
|
|
99
|
+
- Added a complete 1.x-to-2.0 migration guide, Node.js 20/22 CI, and Chromium, Firefox, and WebKit release verification.
|
|
100
|
+
|
|
101
|
+
### Integration
|
|
102
|
+
|
|
103
|
+
- Pinned `ui-style-kit-css@2.0.1` and `interactive-surface-css@1.4.0` as development fixtures only; the default package has no companion imports, peer dependencies, or runtime dependencies.
|
|
104
|
+
- Documented the all-three import order as UI Style Kit bridge, Interactive Surface `state-core.css`, Layout integration bridge, then Layout core.
|
|
105
|
+
- Kept the upcoming UI Style Kit revision as a follow-up outside this release.
|
|
106
|
+
- Preserved structural v1 `.ly-content` and `.ly-divider` compatibility while leaving the removed paint-owned `.ly-surface--raised` selector to UI Style Kit or application themes.
|
|
107
|
+
|
|
108
|
+
## [1.1.2] - 2026-07-08
|
|
109
|
+
|
|
110
|
+
### Fixed
|
|
111
|
+
|
|
112
|
+
- Reissued the release metadata, package lock, README install examples, wiki checklist, and publish workflow recovery tag under `1.1.2`.
|
|
113
|
+
- Kept the additive `1.1.1` CSS and documentation contract intact while moving the publish target to a clean patch version.
|
|
114
|
+
|
|
115
|
+
## [1.1.1] - 2026-07-05
|
|
116
|
+
|
|
117
|
+
### Added
|
|
118
|
+
|
|
119
|
+
- Added versioned wiki documentation under `docs/wiki` for installation, layout primitives, recipes, UI Style Kit compatibility, demo deployment, publishing, security, and contribution workflows.
|
|
120
|
+
- Added UI Style Kit-compatible structural aliases for `saas`, `bento`, `max`, `bau`, `tactile`, `neo`, `retro`, `brutal`, `cyber`, `y2k`, and `rg` prefixes.
|
|
121
|
+
- Added layout recipe helpers for button groups, card grids, card sizing, galleries, and carousels.
|
|
122
|
+
- Added F-Pattern, Z-Pattern, Split-Screen, Mondrian, and Synthwave layout styles.
|
|
123
|
+
- Added `layout-style-css/all-with-ui-kit-and-interactive-surface.css` for the three-library import path.
|
|
124
|
+
- Added direct `./dist/*.css` package exports for consumers that need generated dist files.
|
|
125
|
+
- Added `CHANGELOG.md`, `CONTRIBUTING.md`, and `SECURITY.md` to the release documentation set.
|
|
126
|
+
|
|
127
|
+
### Changed
|
|
128
|
+
|
|
129
|
+
- Reworked the demo mobile controls into a compact drawer so the sticky header does not consume the mobile viewport.
|
|
130
|
+
- Expanded the demo to cover app shell, wrappers, split layouts, sidebars, panes, button groups, card grids, card sizes, galleries, carousels, frames, and scroll areas.
|
|
131
|
+
- Updated README examples to use exported CSS entrypoints and valid CDN links.
|
|
132
|
+
- Updated npm release metadata, package file allowlist, and release verification scripts for the `1.1.1` package.
|
|
133
|
+
- Updated the npm publish workflow to publish from `release.published` events and explicit `workflow_dispatch` tags.
|
|
134
|
+
|
|
135
|
+
### Fixed
|
|
136
|
+
|
|
137
|
+
- Fixed README quick-start imports that referenced non-exported paths.
|
|
138
|
+
- Fixed malformed UI Style Kit CDN link markup in the README.
|
|
139
|
+
- Clarified responsive column utility documentation so class groups do not imply bare numeric class names.
|
|
140
|
+
- Preserved GitHub Pages artifact generation with a Pages-root `index.html`.
|
|
141
|
+
- Fixed the release automation path so draft releases can be published before the npm workflow runs.
|
|
142
|
+
|
|
143
|
+
### Security
|
|
144
|
+
|
|
145
|
+
- Kept the layout CSS contract free of visual properties owned by `ui-style-kit-css`.
|
|
146
|
+
- Kept the package CSS-only at runtime with no network calls, dynamic script execution, or secret handling.
|
|
147
|
+
- Added release verification coverage for npm pack contents and documentation completeness.
|
|
148
|
+
|
|
149
|
+
## [1.0.0]
|
|
150
|
+
|
|
151
|
+
### Added
|
|
152
|
+
|
|
153
|
+
- Initial public release of layout primitives, layout style files, generated dist bundles, and demo coverage.
|
|
154
|
+
|
package/README.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Zero-configuration, dependency-free structural CSS that responds to the width and height a layout actually receives.
|
|
4
4
|
|
|
5
|
-
`layout-style-css@3.0.
|
|
5
|
+
`layout-style-css@3.0.1` is the current v3 patch release and preserves the clean-break structural contract introduced in 3.0.0. It provides intrinsic wrappers, composition primitives, seven semantic recipes, and sixteen spatial personalities. Layout owns structure; UI Style Kit owns paint; Interactive Surface owns interaction styling.
|
|
6
6
|
|
|
7
7
|
## Requirements
|
|
8
8
|
|
|
@@ -13,7 +13,7 @@ Zero-configuration, dependency-free structural CSS that responds to the width an
|
|
|
13
13
|
## Install
|
|
14
14
|
|
|
15
15
|
```bash
|
|
16
|
-
npm install layout-style-css@3.0.
|
|
16
|
+
npm install layout-style-css@3.0.1
|
|
17
17
|
```
|
|
18
18
|
|
|
19
19
|
Most applications need one import:
|
|
@@ -24,6 +24,8 @@ import "layout-style-css";
|
|
|
24
24
|
|
|
25
25
|
The full bundle includes the core modules and all personality profiles. No breakpoint configuration, wrapper, JavaScript, or companion library is required.
|
|
26
26
|
|
|
27
|
+
Package and bundler defaults (`main`, `style`, and the root export) resolve to the readable `dist/layout-style-css.css` bundle for straightforward inspection and debugging. The `unpkg` and `jsdelivr` convenience fields remain minified, and `layout-style-css/min.css` is the explicit minified package import.
|
|
28
|
+
|
|
27
29
|
## Zero-Configuration Start
|
|
28
30
|
|
|
29
31
|
Use `.ly-root` as the responsive boundary and keep the mobile DOM order authoritative:
|
|
@@ -151,6 +153,7 @@ Each personality is a token/topology profile consumed by the shared recipe engin
|
|
|
151
153
|
| `layout-style-css/utilities.css` | Small structural utility set |
|
|
152
154
|
| `layout-style-css/personalities.css` | All sixteen profiles |
|
|
153
155
|
| `layout-style-css/personalities/minimal-saas.css` | One profile; substitute any public personality name |
|
|
156
|
+
| `layout-style-css/personalities.json` | Public layout-to-visual pairing recommendations |
|
|
154
157
|
| `layout-style-css/package.json` | Package metadata |
|
|
155
158
|
|
|
156
159
|
The cascade order is `ly.reset`, `ly.tokens`, `ly.wrappers`, `ly.primitives`, `ly.recipes`, `ly.utilities`, and `ly.personalities`.
|
|
@@ -168,11 +171,13 @@ import "layout-style-css";
|
|
|
168
171
|
|
|
169
172
|
This order lets UI Style Kit establish paint and theme roles, Interactive Surface add interaction states, and Layout apply structure.
|
|
170
173
|
|
|
174
|
+
`data-ly-layout`, `data-ui`, `data-theme`, and `data-mode` are independently selectable. See [Layout Styles](docs/wiki/Layout-Styles.md#visual-pairing-guidance) for the full recommendation matrix; pairings are never dependencies.
|
|
175
|
+
|
|
171
176
|
## CDN
|
|
172
177
|
|
|
173
178
|
```html
|
|
174
|
-
<link rel="stylesheet" href="https://unpkg.com/layout-style-css@3.0.
|
|
175
|
-
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/layout-style-css@3.0.
|
|
179
|
+
<link rel="stylesheet" href="https://unpkg.com/layout-style-css@3.0.1/dist/layout-style-css.min.css">
|
|
180
|
+
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/layout-style-css@3.0.1/dist/layout-style-css.min.css">
|
|
176
181
|
```
|
|
177
182
|
|
|
178
183
|
## Clean-Break Migration
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# Contributing
|
|
2
|
+
|
|
3
|
+
Contributions must preserve the package boundary: Layout Style owns structure, UI Style Kit owns visual paint, and Interactive Surface owns interaction states.
|
|
4
|
+
|
|
5
|
+
## Workflow
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm ci
|
|
9
|
+
npm run build
|
|
10
|
+
npm run lint
|
|
11
|
+
npm run check:demo-js
|
|
12
|
+
npm test
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
Use `npm run test:demo:all` for rendered layout changes and `npm run release:verify` before release-facing work is merged.
|
|
16
|
+
|
|
17
|
+
## Source And Generated Files
|
|
18
|
+
|
|
19
|
+
- Edit authored modules in `styles/`.
|
|
20
|
+
- Regenerate `dist/` with `npm run build`.
|
|
21
|
+
- Keep the shared cascade-layer prelude in every public entry.
|
|
22
|
+
- Never hand-edit generated CSS or Pages output.
|
|
23
|
+
- Use professional comments for containment, accessibility, cascade, or build-safety decisions.
|
|
24
|
+
|
|
25
|
+
## Layout Rules
|
|
26
|
+
|
|
27
|
+
- Prefix public classes with `ly-`.
|
|
28
|
+
- Keep the mobile DOM, reading, and focus order authoritative.
|
|
29
|
+
- Use named areas in built-in recipes; never use `order` there.
|
|
30
|
+
- Test nested containers one rem below and above each recipe threshold: `42rem`, `44rem`, `48rem`, `52rem`, and `72rem`.
|
|
31
|
+
- Test viewport heights one rem below and above `30rem` and `44rem`.
|
|
32
|
+
- Keep personality files free of `@container`, viewport, and orientation queries.
|
|
33
|
+
- Use `minmax(0, 1fr)` or guarded floors for tracks that receive application content.
|
|
34
|
+
- Do not add colors, typography, borders, shadows, component paint, focus styles, or native control styles.
|
|
35
|
+
|
|
36
|
+
## Documentation
|
|
37
|
+
|
|
38
|
+
Update README, migration guide, wiki, changelog, demo metadata, and contract tests whenever an export, selector, recipe, compatibility rule, browser baseline, or release command changes.
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
# Demo And GitHub Pages
|
|
2
|
+
|
|
3
|
+
The v3 demo is an intrinsic responsive workbench, not a fixed-device screenshot gallery.
|
|
4
|
+
|
|
5
|
+
## Controls
|
|
6
|
+
|
|
7
|
+
- Independent preview width and height
|
|
8
|
+
- Automatic and manual recipe responsiveness
|
|
9
|
+
- Wrapper, recipe, and all sixteen personality profiles
|
|
10
|
+
- Layout-only, Layout plus UI, and all-three ecosystem modes
|
|
11
|
+
- Live rendered dimensions and active topology
|
|
12
|
+
- Copy-ready canonical attribute markup
|
|
13
|
+
|
|
14
|
+
Device presets cover the release allocations:
|
|
15
|
+
|
|
16
|
+
- Phone portrait: `360 × 800`
|
|
17
|
+
- Phone landscape: `800 × 360`
|
|
18
|
+
- Tablet portrait: `768 × 1024`
|
|
19
|
+
- Tablet landscape: `1024 × 768`
|
|
20
|
+
- Desktop landscape: `1440 × 900`
|
|
21
|
+
- Desktop portrait: `900 × 1440`
|
|
22
|
+
|
|
23
|
+
Threshold controls also cover one rem below and above `42rem`, `44rem`, `48rem`, `52rem`, and `72rem`, plus the `30rem` and `44rem` height tiers.
|
|
24
|
+
|
|
25
|
+
## Local Verification
|
|
26
|
+
|
|
27
|
+
```bash
|
|
28
|
+
npm run build
|
|
29
|
+
npm run test:demo:quick
|
|
30
|
+
npm run test:demo:all
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
The full matrix runs in Chromium, Firefox, and WebKit. It checks meaningful DOM, unchanged source/focus order, automatic and manual topologies, nearest-container behavior, short-height escape hatches, zero-width tracks, overlap, and unintended overflow.
|
|
34
|
+
|
|
35
|
+
## GitHub Pages
|
|
36
|
+
|
|
37
|
+
```bash
|
|
38
|
+
npm run pages:build
|
|
39
|
+
npm run test:pages
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
The Pages artifact is written to `output/github-pages`, carries a root `index.html`, includes the generated v3 distribution, and rewrites the demo's parent-relative Layout import to the artifact-local `./dist` path.
|
|
43
|
+
|
|
44
|
+
`pages.yml` verifies repository Pages configuration before package work, runs the package check, installs Chromium for the rendered gate, validates the artifact, and deploys the saved artifact. Deployment is separate from local implementation.
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
# Getting Started
|
|
2
|
+
|
|
3
|
+
Install `layout-style-css@3.0.1` and import the root bundle:
|
|
4
|
+
|
|
5
|
+
```bash
|
|
6
|
+
npm install layout-style-css@3.0.1
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
```js
|
|
10
|
+
import "layout-style-css";
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## First Automatic Layout
|
|
14
|
+
|
|
15
|
+
The zero-configuration path needs only `.ly-root`, a recipe attribute, and semantic areas:
|
|
16
|
+
|
|
17
|
+
```html
|
|
18
|
+
<body class="ly-root" data-ly-layout="minimal-saas">
|
|
19
|
+
<div data-ly-recipe="split-hero">
|
|
20
|
+
<main data-ly-area="content">Primary message</main>
|
|
21
|
+
<figure data-ly-area="media">Media</figure>
|
|
22
|
+
<div data-ly-area="actions">Actions</div>
|
|
23
|
+
</div>
|
|
24
|
+
</body>
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
The recipe stays stacked below `42rem` and enhances automatically when its nearest `ly-scope` container has enough room.
|
|
28
|
+
|
|
29
|
+
## Optional Wrapper
|
|
30
|
+
|
|
31
|
+
Use wrappers when a composition needs a named measure or local responsive scope:
|
|
32
|
+
|
|
33
|
+
```html
|
|
34
|
+
<section class="ly-wrapper ly-wrapper--wide">
|
|
35
|
+
<div data-ly-recipe="card-grid">
|
|
36
|
+
<article>One</article>
|
|
37
|
+
<article>Two</article>
|
|
38
|
+
</div>
|
|
39
|
+
</section>
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
Available measures are `.ly-wrapper--compact`, `.ly-wrapper--prose`, `.ly-wrapper--content`, `.ly-wrapper--wide`, `.ly-wrapper--full`, and `.ly-wrapper--breakout`.
|
|
43
|
+
|
|
44
|
+
## Manual Topology
|
|
45
|
+
|
|
46
|
+
Use `data-ly-responsive="manual"` only when application CSS must choose the topology:
|
|
47
|
+
|
|
48
|
+
```css
|
|
49
|
+
@container ly-scope (min-width: 56rem) {
|
|
50
|
+
[data-ly-recipe="docs"][data-ly-responsive="manual"] {
|
|
51
|
+
/* Application-owned topology. */
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
Keep mobile DOM order authoritative. The package never changes reading or focus order.
|
|
57
|
+
|
|
58
|
+
## Next
|
|
59
|
+
|
|
60
|
+
- [Layout Primitives](Layout-Primitives.md)
|
|
61
|
+
- [Layout Recipes](Layout-Recipes.md)
|
|
62
|
+
- [Layout Styles](Layout-Styles.md)
|
|
63
|
+
- [Migrating To 3.0](Migrating-To-3.0.md)
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# Layout Style CSS v3
|
|
2
|
+
|
|
3
|
+
`layout-style-css@3.0.1` is a dependency-free, CSS-only structural system for layouts that adapt to available width and height.
|
|
4
|
+
|
|
5
|
+
## Contract
|
|
6
|
+
|
|
7
|
+
- `.ly-root` is a usable layout and named `ly-scope` container.
|
|
8
|
+
- Wrappers are optional measure and nesting controls.
|
|
9
|
+
- Seven `data-ly-recipe` values enhance a semantic stacked fallback.
|
|
10
|
+
- `data-ly-responsive="manual"` transfers topology ownership to application CSS.
|
|
11
|
+
- Sixteen `data-ly-layout` profiles tune one shared responsive engine.
|
|
12
|
+
- `100dvh` behavior and the `44rem`/`30rem` height tiers avoid short-screen traps.
|
|
13
|
+
- The mobile DOM order remains the reading, keyboard, and focus order.
|
|
14
|
+
|
|
15
|
+
Layout owns structure. UI Style Kit owns paint. Interactive Surface owns interaction styling.
|
|
16
|
+
|
|
17
|
+
## Documentation
|
|
18
|
+
|
|
19
|
+
- [Getting Started](Getting-Started.md)
|
|
20
|
+
- [Installation And CDN](Installation-And-CDN.md)
|
|
21
|
+
- [Layout Primitives](Layout-Primitives.md)
|
|
22
|
+
- [Layout Recipes](Layout-Recipes.md)
|
|
23
|
+
- [Layout Styles](Layout-Styles.md)
|
|
24
|
+
- [Migrating To 3.0](Migrating-To-3.0.md)
|
|
25
|
+
- [Demo And GitHub Pages](Demo-And-GitHub-Pages.md)
|
|
26
|
+
- [Release And Publishing](Release-And-Publishing.md)
|
|
27
|
+
- [Security And Support](Security-And-Support.md)
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
# Installation And CDN
|
|
2
|
+
|
|
3
|
+
## Requirements
|
|
4
|
+
|
|
5
|
+
- Node.js 20 or newer for development
|
|
6
|
+
- Evergreen Chromium, Firefox, or WebKit
|
|
7
|
+
- No runtime or peer dependencies
|
|
8
|
+
|
|
9
|
+
## Package
|
|
10
|
+
|
|
11
|
+
```bash
|
|
12
|
+
npm install layout-style-css@3.0.1
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
```js
|
|
16
|
+
import "layout-style-css";
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
The root import is the zero-configuration full bundle. Focused exports are:
|
|
20
|
+
|
|
21
|
+
Package and bundler defaults (`main`, `style`, and the root export) use the readable `dist/layout-style-css.css` file. The `unpkg` and `jsdelivr` convenience fields use `dist/layout-style-css.min.css`; package consumers can select the same minified output explicitly with `layout-style-css/min.css`.
|
|
22
|
+
|
|
23
|
+
- `layout-style-css/min.css`
|
|
24
|
+
- `layout-style-css/core.css`
|
|
25
|
+
- `layout-style-css/foundation.css`
|
|
26
|
+
- `layout-style-css/wrappers.css`
|
|
27
|
+
- `layout-style-css/primitives.css`
|
|
28
|
+
- `layout-style-css/recipes.css`
|
|
29
|
+
- `layout-style-css/utilities.css`
|
|
30
|
+
- `layout-style-css/personalities.css`
|
|
31
|
+
- `layout-style-css/personalities/minimal-saas.css` and the other fifteen profile names
|
|
32
|
+
- `layout-style-css/package.json`
|
|
33
|
+
|
|
34
|
+
`core.css` contains Foundation, Wrappers, Primitives, Recipes, and Utilities. The default bundle adds all personality profiles.
|
|
35
|
+
|
|
36
|
+
## CDN
|
|
37
|
+
|
|
38
|
+
```html
|
|
39
|
+
<link rel="stylesheet" href="https://unpkg.com/layout-style-css@3.0.1/dist/layout-style-css.min.css">
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
```html
|
|
43
|
+
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/layout-style-css@3.0.1/dist/layout-style-css.min.css">
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
The CDN paths include `/dist/` because CDN clients address files in the published tarball, while package import maps use the public exports.
|
|
47
|
+
|
|
48
|
+
## Ecosystem Order
|
|
49
|
+
|
|
50
|
+
Layout has no companion imports. When all three libraries are installed, keep ownership explicit:
|
|
51
|
+
|
|
52
|
+
```js
|
|
53
|
+
import "ui-style-kit-css/visual.css";
|
|
54
|
+
import "ui-style-kit-css/interactive-surface-theme.css";
|
|
55
|
+
import "interactive-surface-css/state-core.css";
|
|
56
|
+
import "layout-style-css";
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
Layout owns structure. UI Style Kit owns paint. Interactive Surface owns interaction styling.
|
|
60
|
+
|
|
61
|
+
## Cascade Layers
|
|
62
|
+
|
|
63
|
+
The module order is:
|
|
64
|
+
|
|
65
|
+
1. `ly.reset`
|
|
66
|
+
2. `ly.tokens`
|
|
67
|
+
3. `ly.wrappers`
|
|
68
|
+
4. `ly.primitives`
|
|
69
|
+
5. `ly.recipes`
|
|
70
|
+
6. `ly.utilities`
|
|
71
|
+
7. `ly.personalities`
|
|
72
|
+
|
|
73
|
+
Application styles can override public custom properties without reordering the package modules.
|
|
74
|
+
|
|
75
|
+
## Clean-Break Note
|
|
76
|
+
|
|
77
|
+
v3 does not export a compatibility bundle, legacy aliases, the deprecated structural bridge, extensionless aliases, or responsive/order utility families. See [Migrating To 3.0](Migrating-To-3.0.md).
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
# Layout Primitives
|
|
2
|
+
|
|
3
|
+
## Foundation And Containment
|
|
4
|
+
|
|
5
|
+
`.ly-root` supplies shared structural tokens, shrink safety, the named `ly-scope` inline-size container, and height-aware defaults. Reset and public tokens live in `layout-style-css/foundation.css`.
|
|
6
|
+
|
|
7
|
+
Every primitive applies `min-inline-size: 0` and `min-block-size: 0` where tracks or children need to shrink.
|
|
8
|
+
|
|
9
|
+
## Wrappers
|
|
10
|
+
|
|
11
|
+
Wrappers are optional local responsive scopes:
|
|
12
|
+
|
|
13
|
+
- `.ly-wrapper--compact`
|
|
14
|
+
- `.ly-wrapper--prose`
|
|
15
|
+
- `.ly-wrapper--content`
|
|
16
|
+
- `.ly-wrapper--wide`
|
|
17
|
+
- `.ly-wrapper--full`
|
|
18
|
+
- `.ly-wrapper--breakout`
|
|
19
|
+
|
|
20
|
+
Breakout children select clamped lanes with `data-ly-lane="content"`, `data-ly-lane="feature"`, or `data-ly-lane="full"`.
|
|
21
|
+
|
|
22
|
+
## Flow
|
|
23
|
+
|
|
24
|
+
- `.ly-stack` creates vertical flow.
|
|
25
|
+
- `.ly-cluster` wraps inline groups.
|
|
26
|
+
- `.ly-center` centers a bounded composition.
|
|
27
|
+
- `.ly-cover` fills available block size while preserving reachable normal flow.
|
|
28
|
+
|
|
29
|
+
## Adaptive Tracks
|
|
30
|
+
|
|
31
|
+
- `.ly-switcher` wraps when its intrinsic threshold is no longer feasible.
|
|
32
|
+
- `.ly-sidebar` keeps a preferred rail while the content can meet its minimum.
|
|
33
|
+
- `.ly-grid` uses auto-fit tracks and `--ly-grid-min`.
|
|
34
|
+
- `.ly-split` creates balanced intrinsic regions.
|
|
35
|
+
- `.ly-panes` creates a preferred workspace rail and flexible pane.
|
|
36
|
+
- `.ly-media` wraps media and content without a viewport breakpoint.
|
|
37
|
+
|
|
38
|
+
## Frame And Overflow
|
|
39
|
+
|
|
40
|
+
- `.ly-frame` keeps a configurable aspect ratio.
|
|
41
|
+
- `.ly-reel` is the deliberate horizontal-flow primitive.
|
|
42
|
+
- `.ly-scroll` is the deliberate bounded vertical-scroll primitive.
|
|
43
|
+
|
|
44
|
+
In normal use, only `.ly-reel` introduces intentional horizontal scrolling, and only `.ly-scroll` introduces intentional vertical scrolling. Other wrappers, primitives, and recipes clamp to their available inline size.
|
|
45
|
+
|
|
46
|
+
## Height Behavior
|
|
47
|
+
|
|
48
|
+
Page, cover, and bounded scroll behaviors use `vh` fallbacks followed by dynamic viewport units such as `100dvh`.
|
|
49
|
+
|
|
50
|
+
At `44rem` viewport height or less, gaps and scroll maxima tighten. At `30rem` or less, forced cover/shell minimums and recipe-owned sticky positioning are removed. Required regions remain in normal document flow.
|
|
51
|
+
|
|
52
|
+
## Public Tuning
|
|
53
|
+
|
|
54
|
+
Advanced consumers can override stable custom properties for:
|
|
55
|
+
|
|
56
|
+
- gaps and spacing
|
|
57
|
+
- wrapper measures and gutters
|
|
58
|
+
- sidebar, pane, media, reel, and grid minimums
|
|
59
|
+
- frame ratios
|
|
60
|
+
- shell, cover, and bounded-scroll sizing
|
|
61
|
+
|
|
62
|
+
These tokens tune behavior without creating a second breakpoint system.
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
# Layout Recipes
|
|
2
|
+
|
|
3
|
+
Recipes are attribute-only semantic layouts. The mobile DOM order is authoritative, and automatic container enhancement is the zero-configuration default.
|
|
4
|
+
|
|
5
|
+
## Automatic Thresholds
|
|
6
|
+
|
|
7
|
+
| Recipe | Nearest `ly-scope` threshold |
|
|
8
|
+
| --- | --- |
|
|
9
|
+
| `data-ly-recipe="split-hero"` | `42rem` |
|
|
10
|
+
| `data-ly-recipe="list-detail"` | `44rem` |
|
|
11
|
+
| `data-ly-recipe="docs"` | `48rem` |
|
|
12
|
+
| `data-ly-recipe="app-shell"` | medium `52rem`, wide `72rem` |
|
|
13
|
+
| `data-ly-recipe="dashboard"` | medium `52rem`, wide `72rem` |
|
|
14
|
+
| `data-ly-recipe="gallery"` | intrinsic; no topology query |
|
|
15
|
+
| `data-ly-recipe="card-grid"` | intrinsic; no topology query |
|
|
16
|
+
|
|
17
|
+
Recipe roots also establish `ly-scope`, so child compositions can respond without extra setup.
|
|
18
|
+
|
|
19
|
+
## Areas
|
|
20
|
+
|
|
21
|
+
Canonical `data-ly-area` values are:
|
|
22
|
+
|
|
23
|
+
- App shell: `header`, `sidebar`, `main`, `aside`, `footer`
|
|
24
|
+
- Dashboard and Docs: `header`, `nav`, `main`, `aside`, `footer`
|
|
25
|
+
- List detail: `primary`, `secondary`, `actions`
|
|
26
|
+
- Split hero: `content`, `media`, `actions`
|
|
27
|
+
|
|
28
|
+
```html
|
|
29
|
+
<section data-ly-recipe="docs">
|
|
30
|
+
<header data-ly-area="header">Docs</header>
|
|
31
|
+
<nav data-ly-area="nav" aria-label="Documentation">Navigation</nav>
|
|
32
|
+
<main data-ly-area="main">Article</main>
|
|
33
|
+
<aside data-ly-area="aside">On this page</aside>
|
|
34
|
+
<footer data-ly-area="footer">Next</footer>
|
|
35
|
+
</section>
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
## Manual Responsiveness
|
|
39
|
+
|
|
40
|
+
`data-ly-responsive="manual"` disables automatic topology rules while retaining the stacked fallback.
|
|
41
|
+
|
|
42
|
+
```css
|
|
43
|
+
@container ly-scope (min-width: 56rem) {
|
|
44
|
+
[data-ly-recipe="docs"][data-ly-responsive="manual"] {
|
|
45
|
+
/* Application-owned topology. */
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
Use the nearest wrapper as the query boundary when a component needs a constrained local allocation. Use a recipe directly in `.ly-root` when no measure wrapper is needed.
|
|
51
|
+
|
|
52
|
+
## Accessibility
|
|
53
|
+
|
|
54
|
+
Write the source in mobile reading order and keep actions beside the content they control. Named grid areas can change visual placement, but they do not alter DOM, reading, keyboard, or focus order. Visual-order utilities are not part of v3.
|
|
55
|
+
|
|
56
|
+
## Vertical Responsiveness
|
|
57
|
+
|
|
58
|
+
Recipe gaps and scroll bounds tighten at `44rem` viewport height. At `30rem`, recipe-owned sticky positioning and forced shell height stop so navigation, main content, and actions remain reachable.
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
# Layout Styles
|
|
2
|
+
|
|
3
|
+
The sixteen `data-ly-layout` values are focused token and topology profiles:
|
|
4
|
+
|
|
5
|
+
`minimal-saas`, `bauhaus`, `tactile`, `cyberpunk`, `f-pattern`, `brutalism`, `neumorphism`, `y2k`, `retro-glass`, `z-pattern`, `retrofuturism`, `mondrian`, `synthwave`, `bento`, `maximalist`, and `split-screen`.
|
|
6
|
+
|
|
7
|
+
```html
|
|
8
|
+
<body class="ly-root" data-ly-layout="bento">
|
|
9
|
+
<main data-ly-recipe="dashboard">...</main>
|
|
10
|
+
</body>
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## Shared Engine
|
|
14
|
+
|
|
15
|
+
Every profile feeds the same wrapper, primitive, and recipe engine. Profiles tune values such as:
|
|
16
|
+
|
|
17
|
+
- wrapper measure
|
|
18
|
+
- base and grid gaps
|
|
19
|
+
- rail, pane, and media preferences
|
|
20
|
+
- gallery and card minimums
|
|
21
|
+
- frame ratio
|
|
22
|
+
- shared recipe area and track templates
|
|
23
|
+
|
|
24
|
+
A profile must remain visibly distinct through at least two spatial characteristics. Personality files may not declare their own `@container`, viewport, or orientation breakpoint systems.
|
|
25
|
+
|
|
26
|
+
## Ownership
|
|
27
|
+
|
|
28
|
+
Layout owns structure. UI Style Kit owns paint. Interactive Surface owns interaction styling.
|
|
29
|
+
|
|
30
|
+
The personality name does not promise colors, typography, borders, shadows, or interaction states. Pair the same name across libraries when desired, but import each library explicitly and let it own its layer.
|
|
31
|
+
|
|
32
|
+
## Visual Pairing Guidance
|
|
33
|
+
|
|
34
|
+
[`layout-style-css/personalities.json`](../../personalities.json) is the public, machine-readable pairing source used by the demo. Its entries are recommendations, never dependencies: `data-ly-layout`, `data-ui`, `data-theme`, and `data-mode` are independently selectable on the same document.
|
|
35
|
+
|
|
36
|
+
| Layout personality | Visual pairing guidance |
|
|
37
|
+
| --- | --- |
|
|
38
|
+
| Minimal SaaS | Native match: `minimal-saas` |
|
|
39
|
+
| Bento | Native match: `bento` |
|
|
40
|
+
| Maximalist | Native match: `maximalist` |
|
|
41
|
+
| Bauhaus | Native match: `bauhaus` |
|
|
42
|
+
| Tactile | Native match: `tactile` |
|
|
43
|
+
| Neumorphism | Native match: `neumorphism` |
|
|
44
|
+
| Retrofuturism | Native match: `retrofuturism` |
|
|
45
|
+
| Brutalism | Native match: `brutalism` |
|
|
46
|
+
| Cyberpunk | Native match: `cyberpunk` |
|
|
47
|
+
| Y2K | Native match: `y2k` |
|
|
48
|
+
| Retro Glass | Native match: `retro-glass` |
|
|
49
|
+
| F-pattern | Any visual preset; this is structure only |
|
|
50
|
+
| Z-pattern | Any visual preset; this is structure only |
|
|
51
|
+
| Split Screen | Any visual preset; this is structure only |
|
|
52
|
+
| Mondrian | Any visual preset; this is structure only |
|
|
53
|
+
| Synthwave | Recommended: `cyberpunk` or `retrofuturism`; the browser contract verifies each preset's distinct rendered article shadow while retaining `data-ly-layout="synthwave"` |
|
|
54
|
+
|
|
55
|
+
## Customization
|
|
56
|
+
|
|
57
|
+
Override public tokens at `.ly-root` or a narrower scope:
|
|
58
|
+
|
|
59
|
+
```css
|
|
60
|
+
.product-shell {
|
|
61
|
+
--ly-profile-gap: 1.25rem;
|
|
62
|
+
--ly-recipe-rail: 17rem;
|
|
63
|
+
--ly-card-grid-min: 18rem;
|
|
64
|
+
}
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
Use `data-ly-responsive="manual"` plus an application-owned `@container ly-scope` query when token tuning is not enough.
|