Skip to content

Specify model width height - #159

Merged
zachernuk merged 1 commit into
immersive-web:mainfrom
cabanier:specify-model-width-height
Oct 13, 2026
Merged

zachernuk merged 1 commit into
immersive-web:mainfrom
cabanier:specify-model-width-height

Conversation

@cabanier

@cabanier cabanier commented Oct 13, 2026 •

Copy link
Copy Markdown
Member

Specify non-negative integer content attributes and reflected unsigned-long IDL properties.


Preview | Diff


Preview | Diff

Specify the width and height content attributes as valid non-negative integers giving the desired dimensions in CSS pixels, including zero. Limit this change to the two attribute paragraphs; IDL declarations and CSS sizing behavior will be proposed separately.
@cabanier
cabanier force-pushed the specify-model-width-height branch from a19448f to 70b5c8f Compare October 13, 2026 20:14
@zachernuk
zachernuk merged commit 116f567 into immersive-web:main Oct 13, 2026
3 checks passed
github-actions Bot added a commit that referenced this pull request Oct 13, 2026
SHA: 116f567
Reason: push, by zachernuk

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
cabanier added a commit to cabanier/model-element that referenced this pull request Oct 14, 2026
Align the fitting text with the width and height content-attribute definitions merged in immersive-web#159. Use the element's actual laid-out content box for initial fitting, and explicitly distinguish used CSS dimensions from the desired dimensions specified by the attributes. Preserve the existing resize trigger and zero-size handling; leave the deferred IDL and general CSS sizing work out of this PR.
cabanier added a commit that referenced this pull request Oct 14, 2026
* Fix model fitting and define coordinate-space units

Define metric model bounds and CSS-derived element-space meters, including resource-unit normalization, CSS pixel conversion, and zoom/DPR semantics. Correct initial and orbit fitting scale ratios, centering, and depth clearance.

Fixes #155.

* Clarify CSS units and align automatic fitting with WebKit

Define automatic refitting after layout-size changes, preserving rotation
and leaving script-assigned transforms unchanged. Reuse stored resource
bounds without restarting or seeking animations, and specify how stage-mode
changes and new resource loads re-enable automatic fitting.

Reference CSS Values and Units and CSSOM View for CSS-derived meters,
page zoom, visual viewport scaling, and devicePixelRatio.

Remove displayed Issues 6 and 7 (GitHub #1 and #5) and regenerate
index.html from the Bikeshed source.

Validation: bikeshed --die-on=everything spec index.bs index.html;
git diff --check.

* Clarify that model fitting uses laid-out dimensions

Align the fitting text with the width and height content-attribute definitions merged in #159. Use the element's actual laid-out content box for initial fitting, and explicitly distinguish used CSS dimensions from the desired dimensions specified by the attributes. Preserve the existing resize trigger and zero-size handling; leave the deferred IDL and general CSS sizing work out of this PR.

* Ground model fitting in CSS and Geometry specifications

Reference CSS Box Model 3, CSS Cascading 5, CSS Sizing 3, and
Geometry Interfaces 1 for content-box dimensions, used values,
sizing properties, and point/matrix operations.

Flag the proposed one-meter fallback for formats without declared
or default length units as needing further discussion, using a
native Bikeshed issue linked to #155.

Keep the fitting arithmetic and width/height attribute definitions
unchanged. Strict Bikeshed validation passes.
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.

2 participants