fix(css): stabilize scoped rosview styling#13
Merged
Conversation
Restore scoped preflight behavior for standalone and embedded builds, and isolate playback scrubber centering from host Tailwind transforms for v1.5.3.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Restore scoped preflight behavior for standalone and embedded builds, and isolate playback scrubber centering from host Tailwind transforms for v1.5.3.
Description
standalone.cssfor the SPA shell (html/body/#rootmargin and full-viewport sizing) without leaking global resets into the npm library bundle.#rosview-root: typography/list/fieldset margin resets, form control border normalization, and Tailwind.border*utility initialization so shadcn-style borders render correctly withpreflight: false.#rosview-rootlayout: explicit root dimensions plus an innerh-full w-fullwrapper so Tailwind utilities scoped withimportant: '#rosview-root'apply to descendants, not only to the root element itself.App.tsxouter shell to use inline viewport sizing instead of scopedw-screen/h-screenclasses outside#rosview-root.-translate-x/y-1/2utilities withros-playback-center-x/ros-playback-center-xyandtranslate: noneso host apps using Tailwind v4 do not double-applytranslate(thumb offset + broken track hit-testing).1.5.3.Motivation / related issue
After
v1.5.2scoped CSS (important: '#rosview-root',preflight: false):body,pmargins, visible.borderon buttons) made the main site look broken compared to pre-1.5.x.translateutilities stacked on top of rosview’s transform-based centering, andpointer-events-noneoverlays no longer hit#playback-track.This PR restores predictable styling in both modes without re-enabling global preflight that would affect the host page.
Type of change
Checklist
npm run lintpasses with no errorsnpm testpasses (unit tests)npm run buildandnpm run build:libsucceedTests: Visual/CSS integration fix; no new unit tests. Manually verified standalone
localhost:5173and embedded/visualizeplayback track centering and scrubber hit-testing.API compatibility
N/A — no changes to
src/entrypoints/index.tsexports. CSS-only and internal component structure changes; consumers should upgrade to@ioai/rosview@1.5.3and continue importing@ioai/rosview/style.cssonce published.Screenshots / recordings