Skip to content

feat(html): add slider element#655

Merged
mihar-22 merged 1 commit intomainfrom
feat/html-slider
Mar 1, 2026
Merged

feat(html): add slider element#655
mihar-22 merged 1 commit intomainfrom
feat/html-slider

Conversation

@mihar-22
Copy link
Copy Markdown
Member

@mihar-22 mihar-22 commented Mar 1, 2026

Refs #275

Summary

Generic slider custom elements — structural building blocks that domain sliders (time, volume) compose with.

API Surface

Elements: <media-slider>, <media-slider-track>, <media-slider-fill>, <media-slider-buffer>, <media-slider-thumb>, <media-slider-value>

Context: sliderContext / SliderContextValue — state, pointerValue, thumbAttrs, thumbProps, formatValue

Events: SliderEventMapvalue-change, value-commit, drag-start, drag-end

Properties (<media-slider>): label, disabled, thumbAlignment

Testing

pnpm -F @videojs/html test src/ui/slider — 23 tests

@vercel
Copy link
Copy Markdown

vercel bot commented Mar 1, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
vjs-10-demo-react Ignored Ignored Preview Mar 1, 2026 4:09am

Request Review

@netlify
Copy link
Copy Markdown

netlify bot commented Mar 1, 2026

Deploy Preview for vjs10-site ready!

Name Link
🔨 Latest commit 0a9ab4c
🔍 Latest deploy log https://app.netlify.com/projects/vjs10-site/deploys/69a3bbed2d93c700089debcb
😎 Deploy Preview https://deploy-preview-655--vjs10-site.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Mar 1, 2026

📦 Bundle Size Report

Package Size Diff %
@videojs/core 10.22 kB +5 B ░░░░░░░░ +0.0% 🔺
@videojs/element 1.60 kB 0 B ░░░░░░░░ 0%
@videojs/html 17.94 kB +684 B ████████ +3.9% 🔺
@videojs/icons 3.79 kB 0 B ░░░░░░░░ 0%
@videojs/react 14.83 kB -10 B ░░░░░░░░ -0.1% 🔽
@videojs/store 1.95 kB 0 B ░░░░░░░░ 0%
@videojs/utils 2.81 kB 0 B ░░░░░░░░ 0%

Total: 53.13 kB · +679 B · +1.3%


Entry Breakdown

Subpath sizes are the additional bytes on top of the root entry point, measured by bundling root + subpath together and subtracting the root-only size.

@videojs/core
Entry Base PR Diff %
. 4.21 kB 4.21 kB -2 B -0.0% 🔽
./dom 6.01 kB 6.01 kB +7 B +0.1% 🔺
total 10.21 kB 10.22 kB +5 B +0.0%
@videojs/element
Entry Base PR Diff %
. 817 B 817 B 0 B 0%
./context 823 B 823 B 0 B 0%
total 1.60 kB 1.60 kB 0 B 0%
@videojs/html
Entry Base PR Diff %
. 14.07 kB 14.73 kB +674 B +4.7% 🔺
./video 1.08 kB 1.08 kB +4 B +0.4% 🔺
./audio 1.07 kB 1.06 kB -10 B -0.9% 🔽
./background 1.05 kB 1.07 kB +16 B +1.5% 🔺
total 17.27 kB 17.94 kB +684 B +3.9%
@videojs/icons
Entry Base PR Diff %
./react 2.27 kB 2.27 kB 0 B 0%
./html 1.52 kB 1.52 kB 0 B 0%
total 3.79 kB 3.79 kB 0 B 0%
@videojs/store
Entry Base PR Diff %
. 1.29 kB 1.29 kB 0 B 0%
./html 468 B 468 B 0 B 0%
./react 204 B 204 B 0 B 0%
total 1.95 kB 1.95 kB 0 B 0%
@videojs/utils
Entry Base PR Diff %
./array 104 B 104 B 0 B 0%
./dom 928 B 928 B 0 B 0%
./events 227 B 227 B 0 B 0%
./function 261 B 261 B 0 B 0%
./object 119 B 119 B 0 B 0%
./predicate 265 B 265 B 0 B 0%
./string 148 B 148 B 0 B 0%
./style 185 B 185 B 0 B 0%
./time 478 B 478 B 0 B 0%
./number 158 B 158 B 0 B 0%
total 2.81 kB 2.81 kB 0 B 0%

ℹ️ How to interpret

Sizes are minified + brotli, measured with esbuild.
Package totals are computed as root size + marginal subpath costs.
Subpath marginal cost = (root + subpath bundled together) − root alone.

Icon Meaning
No change
🔺 Increased ≤ 10%
🔴 Increased > 10%
🔽 Decreased
🆕 New (no baseline)

Run pnpm size locally to check current sizes.

@mihar-22 mihar-22 force-pushed the feat/html-slider branch 4 times, most recently from 0fa563b to 9c8925a Compare March 1, 2026 02:38
@mihar-22 mihar-22 marked this pull request as ready for review March 1, 2026 02:41
Generic slider custom element with compound children and context-based
communication. Includes root (<media-slider>), track, fill, buffer,
thumb, and value child elements with shared context propagation.
@mihar-22 mihar-22 merged commit d5df015 into main Mar 1, 2026
12 checks passed
@mihar-22 mihar-22 deleted the feat/html-slider branch March 1, 2026 04:13
@github-actions github-actions bot mentioned this pull request Mar 10, 2026
This was referenced Apr 11, 2026
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.

1 participant