Repository navigation
Conversation
kebabCase keeps the leading dash a vendor-prefixed CSS property needs. kebabCaseName converts identifiers such as PlayButton to play-button, which the HTML element tables use for public names.
Lower targets in three stages (source, lower, finalize) that share one bindings index and one set of imports. Split the style plugin into candidate, reference, virtual CSS, and file-cache modules. Move the HTML, React, and icon target tables into their own packages. Build skins on typed variant, metadata, graph, and registry APIs, with generated outputs and the source layout each declared once. Correctness fixes: checkout-independent scope ids and graph module order, style isolation errors in every build, errors for unconsumed parts and $render markers, a declared cascade order, bundle dedupe within parents, template siblings and nested templates, namespaced build metadata that keeps other plugins' data, contained and conditional CSS imports, and normalized generated-file ownership. Performance: a per-file render cache, one compile per theme for reusable React components, per-piece bundle analysis, and memoized style utilities take skins generate from about 5.0 s to 2.2 s wall.
Task configs load before any package builds, so in a fresh checkout vjsc has no dist and importing the plugin through `vjsc/plugins` fails to load the task graph. Core's config imports the plugin's source again, and the modules that source loads use inline type checks instead of `@videojs/utils`, which is not built yet either.
The cascade-order check treated every array and call argument holding two style references as a composition, and every shared property as a conflict. Alternatives passed to a chooser or kept in an array never meet on one element, and rules for exclusive attribute states, such as `[data-state="open"]` and `[data-state="closed"]`, or `[data-pip]` and `:not([data-pip])`, never apply together, yet both failed builds that compiled before the check existed. Only the arrays a `className` or `class` attribute composes count now, including nested and spread arrays and each branch of a conditional value, and declarations under exclusive attribute states of one element do not compete.
…he cascade The cascade-order check rejected two composed rules that set one property in an order the CSS output reverses. The cascade compares importance and then specificity before source order, so an `!important` override, or one whose selector is more specific, wins in CSS and Tailwind output alike wherever each rule is emitted. The Compat and Scaffold skins compose both kinds, `overflow-visible!` over the container's `overflow-hidden` and status icons shown by a `group-data-*` variant over `hidden`, and failed to build. Declarations of equal importance and specificity are still checked. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
✅ Deploy Preview for vjs10-site ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
@videojs/cdn
@videojs/cli
@videojs/core
@videojs/element
@videojs/html
@videojs/media
@videojs/react
@videojs/spf
@videojs/store
@videojs/utils
@videojs/cloudflare-video
@videojs/dash-video
@videojs/hlsjs-video
@videojs/mux-audio
@videojs/mux-video
@videojs/native-hls-video
@videojs/playerjs-video
@videojs/shaka-video
@videojs/spotify-audio
@videojs/tiktok-video
@videojs/twitch-video
@videojs/vimeo-video
@videojs/wistia-video
@videojs/youtube-video
@videojs/google-cast
@videojs/mux-data
commit: |
Contributor
📦 Bundle Size Report🎨 @videojs/html — 73 small size changes
Presets (7)
Media (19)
Players (5)
Skins (53)
UI Components (62)
⚛️ @videojs/react — 41 small size changes
Presets (7)
Media (23)
Extensions (2)
Players (5)
Skins (34)
UI Components (39)
🧩 @videojs/core — no changesEntries (76)
🏷️ @videojs/element — no changesEntries (2)
📦 @videojs/store — no changesEntries (3)
🔧 @videojs/utils — 2 small size changes
Entries (13)
📦 @videojs/cdn — no changes📦 @videojs/cloudflare-video — no changes📦 @videojs/dash-video — no changes📦 @videojs/google-cast — no changes📦 @videojs/hlsjs-video — no changes📦 @videojs/media — 1 small size change
Entries (3)
📦 @videojs/mux — 1 small size change
📦 @videojs/mux-audio — 1 small size change
Entries (2)
📦 @videojs/mux-data — no changes📦 @videojs/mux-video — 1 small size change
Entries (2)
📦 @videojs/native-hls-video — no changes📦 @videojs/playerjs-video — no changes📦 @videojs/shaka-video — no changes📦 @videojs/spf — no changesEntries (7)
📦 @videojs/spotify-audio — no changes📦 @videojs/tiktok-video — no changes📦 @videojs/twitch-video — no changes📦 @videojs/other — no changesEntries (3)
📦 @videojs/vimeo-video — no changes📦 @videojs/wistia-video — 1 small size change
Entries (2)
📦 @videojs/youtube-video — no changesℹ️ How to interpretEach entry is independently bundled, minified, and brotli-compressed. Initial size includes its static import graph; lazy dynamic chunks are reported separately. Entries are not additive because their dependency graphs overlap. Preset rows represent realistic combined bundles. Changes of 300 B or less across initial, lazy, and total size are collapsed, not discarded. Run |
✅ Deploy Preview for vjs-registry ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
This branch has not been deployed
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
Restructures VJSC, the compiler behind the skins, and the skins build after a review, and fixes the correctness issues the review found. Skins generate drops from about 5.0 s to 2.2 s wall (build step 4.4 s → 1.8 s), and the generated output no longer depends on the checkout path.
Ported from videojs/v10#2970, rebased onto
main. Second of three stacked PRs: videojs/v10#2971 (merged) → this → #9479.Changes
vjsc:target-source,vjsc:target-lower, andvjsc:target-finalizereplace ten separate passes. They share one bindings index and one set of imports, and rule errors report source positions.path:line:columnand run once per style set.packages/html/vjsc,packages/react/vjsc, andpackages/icons/vjsc.kebabCaseNamein@videojs/utils(its own commit) converts component names to element names.$rendermarkers, are now errors.classNameorclassattribute composes count, including nested, spread, and conditional ones. Rules for exclusive attribute states, such as[data-state="open"]and[data-state="closed"], never conflict, and neither do declarations whose importance or specificity already decides the winner.meta.vjsc, so other plugins' resolver metadata survives.url()imports,layer()/supports()/media conditions, and commented-out imports are handled.@videojs/coreno longer packsdist/*/vjsc.*ordist/*/core/ui/*/component.*(144 files). Its published exports never reach them, and they import the privatevjsc.Intentional output changes
:where(.media-skin)shadow-host copies. React never renders those elements as shadow hosts, and HTML CSS is unchanged.:scoperules outside@scopeare gone.@supports {}/@media {}blocks left behind by deduplication are removed.live-audiobeforeaudio, because every theme's skins are now declared once.vjsc/componentsimport, such asText, shares one import declaration with the next primitive from the same module. The bindings are unchanged.Changes from the v10 PR
The stack's base was v10
89c1c5803.mainhas since renamed the Minimal skin to Neutral (videojs/v10#3092) and added the Compat (videojs/v10#3026, #9252) and Scaffold (#9251, #9269, #9287) skins, so the rebase carries those into this PR's structure:skinStylesscopes, catalog metadata, style variants) coversdefault,neutral,compat, andscaffold. Modules underskins/<theme>/shared/get their ownthemesource kind and install under the preset'sshared/directory, as before.generatetask caches and the writer owns are derived from the theme list. They replace thepresets/*/*skin.{tsx,css}globs from refactor(packages)!: rename the minimal skin to neutral v10#3092, so renaming a theme later also needs its old generated files removed once.main(feat(skin): publish the button tooltip as a registry component v10#3194), so this PR'sprivatecomponent metadata and its private registry item are removed.menu-chevron'stype: 'support'metadata replaces the hand-written support path table.main's test audit (test(packages): audit every test with the maintain-tests skill v10#3080): its fixtures, and fixture source read throughgetModuleInfo().codein place of the deletedcomponent-sourcehelper. Its check that every canonical React component and part resolves to a real export moved with the React target table intopackages/react/vjsc/tests/components.test.ts.!importantor a more specific selector settles to the cascade. Compat and Scaffold compose both kinds,overflow-visible!over the container'soverflow-hiddenand status icons shown by agroup-data-*variant overhidden, and failed to build.@internaltags (chore: tag undocumented public exports @internal and enforce it in CI v10#3068), per-packageVERSION(feat(packages): export a per-package VERSION from core, html, and react v10#3078), and the repository links (chore(root): point repository links at videojs/video.js #9253) frommainare kept.Implementation details
VariantCodec.inherit()lets a relative import compile for a narrower variant than its importer. Skins uses it to compile reusable React components withoutskin.resolveIdandloadhooks now declare id filters. The handlers still check ids themselves, so Vite versions that ignore filters behave the same.vjscPlugintype parameters are now<Node, Variant>.readLocalCssImports(filename, root)now requiresroot.placeis now a method signature.Testing
mainand this branch:pnpm install --frozen-lockfile, then every package built with nothing cached. Both pass.generateoutput (package skins, React presets, background copies, anddist/registry/source) compared across v10's base89c1c5803, the v10 headfa7d82978,main, and this branch, withminimalread asneutraland scope ids numbered per file:main's, and 31 equalmainplus the v10 change byte for byte. 19 stylesheets match it rule for rule, with only the root-relative block order differing. The rest aremain's button tooltip: its UI item gets this PR's metadata shape, and the private support item the v10 PR edited no longer exists.main's. The others differ only by the intended changes above: scope ids, block order, 34 WebKit shadow-host copies dropped from React CSS registry files, registry metadata, catalog order, and import grouping.@videojs/skins(103),@videojs/react(589),@videojs/core(1474),@videojs/icons(14),@videojs/utils(496),@videojs/installation(306),@videojs/html(454 of 455), and every other package'stest:ciexcept@videojs/spf. The@videojs/htmlfailure,ThumbnailElement› "adopts an image assigned to a forwarding slot after mount", fails the same way onmainon this machine under load, and this PR does not touchpackages/html/src.pnpm typecheck,pnpm lint,pnpm check:workspace,pnpm test:shadcn, andpnpm -F site check:api-stability@videojs/spf's browser tests. Playwright has no Chromium for this machine's OS release. On this machine, Vite+'s cache tracing also fails concurrenttsgospawns withEBUSY, onmaintoo, so tasks ran with--no-cache.🤖 Generated with Claude Code