feat(site): tailwind style preference + tailwind demo variants#1684
Draft
decepulis wants to merge 7 commits into
Draft
feat(site): tailwind style preference + tailwind demo variants#1684decepulis wants to merge 7 commits into
decepulis wants to merge 7 commits into
Conversation
Adds 'tailwind' to FRAMEWORK_STYLES and STYLE_LABELS so the style selector, StyleCase gating, and ?style= deep links support it. Re-declares the stock Tailwind color/text tokens consumed by docs demos in a dedicated @theme block (the site theme resets those scales), and surfaces the existing Tailwind ejected-skin variants on the customize-skins guide. Refs #840 https://claude.ai/code/session_01LUcwUd8E4Ekakp7NTFb6c5
✅ Deploy Preview for vjs10-site ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Adds react/tailwind and html/tailwind demo variants for create-player, html-create-player, player-controller, render-element, use-button, use-player, and use-store, gated on the style preference via StyleCase. Refs #840 https://claude.ai/code/session_01LUcwUd8E4Ekakp7NTFb6c5
Contributor
📦 Bundle Size Report🎨 @videojs/html — no changesPresets (7)
Media (10)
Players (5)
Skins (30)
UI Components (39)
Sizes are marginal over the root entry point. ⚛️ @videojs/react — no changesPresets (7)
Media (9)
Skins (27)
UI Components (33)
Sizes are marginal over the root entry point. 🧩 @videojs/core — no changesEntries (14)
🏷️ @videojs/element — no changesEntries (2)
📦 @videojs/store — no changesEntries (3)
🔧 @videojs/utils — no changesEntries (10)
📦 @videojs/spf — no changesEntries (4)
ℹ️ How to interpretJS sizes are initial static graph totals (minified + brotli). Lazy dynamic chunks are shown separately when present.
Run |
… references The thumbnail JSON demos have no stylesheet-dependent code, so they are shared across both style preferences instead of duplicated. Refs #840 https://claude.ai/code/session_01LUcwUd8E4Ekakp7NTFb6c5
Covers airplay-button, buffering-indicator, captions-button, controls, playback-rate-button, poster, and popover. Refs #840 https://claude.ai/code/session_01LUcwUd8E4Ekakp7NTFb6c5
…ferences
Bring the tailwind style support up to date with demos added on main
since this branch was written:
- html/tailwind and react/tailwind BasicUsage variants for the new media
element references (background-video, cast-button, dash-video,
hlsjs-video, mux-audio, mux-video, native-hls-video, simple-hls-video,
simple-hls-audio-only) and the use-media reference, mirroring their
css variants 1:1
- wire the new variants into the reference pages behind
<StyleCase styles={["tailwind"]}> (react demos on the media element
pages stay source-only, matching the css variants until #1343 lands)
- sync the tooltip react tailwind demos with the Tooltip.Label change
the css variants picked up in the meantime
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WD9APXrFDbbMEUZrR1imz3
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.
Summary
Enables
tailwindas a docs style preference (refs #840) and adds Tailwind variants for the API reference demos, gated on the existing style preference plumbing.tailwindadded toFRAMEWORK_STYLES/STYLE_LABELS— the style selector,<StyleCase>gating, before-paint init, and?style=tailwinddeep links all derive from this.gray-*,blue-500,neutral-*,text-xs,text-sm) are re-declared verbatim in a dedicated@themeblock inglobals.css. Demo snippets stay copy-paste compatible with a stock Tailwind v4 setup. Follow-up Chore: Replace Demo-Support @theme Tokens with a Scoped Stock Tailwind Stylesheet for Docs Demos #1685 tracks replacing this with a scoped, demo-only stock Tailwind stylesheet so these tokens don't live in the site's global theme.<StyleCase>(closes out the original Docs: Add Tailwind as a Supported Style for Documentation #840 task list).html/tailwind/andreact/tailwind/variants for all reference demos, mirroring thecss/variants 1:1 — same markup, utilities inline, state reflection viadata-paused:/in-data-paused:variants instead of attribute selectors. The style-agnostic thumbnail JSON demos (no stylesheet) are shared across both styles instead of duplicated. Theplayer-controllerdemo keeps itsplay/pause/volumeclasses as JS hooks (querySelector targets).Update after reopen (2026-07-02)
Merged
mainand brought the branch up to date with demos added to the docs since the PR was written:background-video,cast-button,dash-video,hlsjs-video,mux-audio,mux-video,native-hls-video,simple-hls-video,simple-hls-audio-only, plus the react-onlyuse-mediareference — wired into their pages behind<StyleCase styles={["tailwind"]}>. React demos on the media element pages stay source-only, matching their css variants until Bug: React Media Components Break SSR — Top-Level hls.js/dashjs Imports Accesswindow#1343 lands.Tooltip.Labelchange the css variants picked up on main.aspect-video, spacing scale,gray-500).Verification
@tailwindcss/nodecompile check over all 78 tailwind demo files; only intentional JS-hook classes don't generate)pnpm build:site)pnpm typecheckandpnpm check:workspacepassNotes for review
display: noneviahtml[data-style], so reference pages now mount two copies of each demo (hidden videos still load). Same mechanism the css demos already used for framework gating, but worth knowing for page-weight expectations.easetiming → Tailwind default timing function,text-*utilities also set line-height,#ccc→gray-300,#1a1a1a→neutral-900.Refs #840, follow-up: #1685
https://claude.ai/code/session_01LUcwUd8E4Ekakp7NTFb6c5