@leonardaustin/ui 0.20.0 → 0.21.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/ui/AudioPlayer.d.ts +12 -0
- package/dist/components/ui/AudioPlayer.d.ts.map +1 -1
- package/dist/index.js +2097 -2023
- package/dist/styles.css +93 -0
- package/package.json +1 -1
package/dist/styles.css
CHANGED
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
@layer utilities{.min-h-24{min-height:calc(var(--spacing) * 24)}.min-h-full{min-height:100%}.min-w-5{min-width:calc(var(--spacing) * 5)}.p-1{padding:calc(var(--spacing) * 1)}.pl-1{padding-left:calc(var(--spacing) * 1)}.self-start{align-self:flex-start}.focus-visible\:outline-none:focus-visible{--utility-outline-style:none;outline-style:none}}
|
|
10
10
|
@layer utilities{.focus-visible\:opacity-100:focus-visible{opacity:1}}
|
|
11
11
|
@layer utilities{.max-w-\[576px\]{max-width:576px}.max-w-\[768px\]{max-width:768px}.max-w-\[1024px\]{max-width:1024px}.self-center{align-self:center}}
|
|
12
|
+
@layer utilities{.w-auto{width:auto}}
|
|
12
13
|
|
|
13
14
|
|
|
14
15
|
/* ─── Theme: CSS Custom Properties ─── */
|
|
@@ -2557,3 +2558,95 @@ select:disabled + .ui-select-placeholder {
|
|
|
2557
2558
|
transition: none;
|
|
2558
2559
|
}
|
|
2559
2560
|
}
|
|
2561
|
+
|
|
2562
|
+
/* AudioPlayer draws its track, fill and thumb, with a transparent native range
|
|
2563
|
+
input on top so pointer and keyboard seeking stay native and accessible. */
|
|
2564
|
+
.ui-audio-play:disabled {
|
|
2565
|
+
background: var(--border-strong);
|
|
2566
|
+
}
|
|
2567
|
+
|
|
2568
|
+
.ui-audio-times {
|
|
2569
|
+
font-variant-numeric: tabular-nums;
|
|
2570
|
+
}
|
|
2571
|
+
|
|
2572
|
+
.ui-audio-track {
|
|
2573
|
+
position: relative;
|
|
2574
|
+
height: 0.5rem;
|
|
2575
|
+
border-radius: var(--ui-radius-md);
|
|
2576
|
+
background: var(--bg-active);
|
|
2577
|
+
}
|
|
2578
|
+
|
|
2579
|
+
.ui-audio-track:has(.ui-audio-seek:focus-visible) {
|
|
2580
|
+
outline: 2px solid var(--accent);
|
|
2581
|
+
outline-offset: 2px;
|
|
2582
|
+
}
|
|
2583
|
+
|
|
2584
|
+
.ui-audio-fill,
|
|
2585
|
+
.ui-audio-thumb {
|
|
2586
|
+
position: absolute;
|
|
2587
|
+
pointer-events: none;
|
|
2588
|
+
background: var(--accent);
|
|
2589
|
+
}
|
|
2590
|
+
|
|
2591
|
+
/* Track and fill follow the theme radius; the thumb stays circular. */
|
|
2592
|
+
.ui-audio-fill {
|
|
2593
|
+
top: 0;
|
|
2594
|
+
left: 0;
|
|
2595
|
+
height: 100%;
|
|
2596
|
+
border-radius: var(--ui-radius-md);
|
|
2597
|
+
}
|
|
2598
|
+
|
|
2599
|
+
.ui-audio-thumb {
|
|
2600
|
+
border-radius: 9999px;
|
|
2601
|
+
top: 50%;
|
|
2602
|
+
width: 0.75rem;
|
|
2603
|
+
height: 0.75rem;
|
|
2604
|
+
transform: translateY(-50%);
|
|
2605
|
+
opacity: 0;
|
|
2606
|
+
transition: opacity 100ms;
|
|
2607
|
+
}
|
|
2608
|
+
|
|
2609
|
+
.ui-audio-track:hover .ui-audio-seek:not(:disabled) ~ .ui-audio-thumb,
|
|
2610
|
+
.ui-audio-seek:is(:focus-visible, :active):not(:disabled) ~ .ui-audio-thumb {
|
|
2611
|
+
opacity: 1;
|
|
2612
|
+
}
|
|
2613
|
+
|
|
2614
|
+
.ui-audio-seek {
|
|
2615
|
+
position: absolute;
|
|
2616
|
+
z-index: 1;
|
|
2617
|
+
top: -0.25rem;
|
|
2618
|
+
/* Overhang by half a thumb on each side so the native thumb's centre
|
|
2619
|
+
travels the whole drawn track, matching the fill and drawn thumb. */
|
|
2620
|
+
left: -0.375rem;
|
|
2621
|
+
width: calc(100% + 0.75rem);
|
|
2622
|
+
height: 1rem;
|
|
2623
|
+
margin: 0;
|
|
2624
|
+
padding: 0;
|
|
2625
|
+
border: 0;
|
|
2626
|
+
appearance: none;
|
|
2627
|
+
background: transparent;
|
|
2628
|
+
cursor: pointer;
|
|
2629
|
+
opacity: 0;
|
|
2630
|
+
}
|
|
2631
|
+
|
|
2632
|
+
/* Size the invisible native thumb like the drawn one so pointer positions map
|
|
2633
|
+
to the same times. */
|
|
2634
|
+
.ui-audio-seek::-webkit-slider-thumb {
|
|
2635
|
+
width: 0.75rem;
|
|
2636
|
+
height: 0.75rem;
|
|
2637
|
+
appearance: none;
|
|
2638
|
+
}
|
|
2639
|
+
|
|
2640
|
+
.ui-audio-seek::-moz-range-thumb {
|
|
2641
|
+
width: 0.75rem;
|
|
2642
|
+
height: 0.75rem;
|
|
2643
|
+
border: 0;
|
|
2644
|
+
}
|
|
2645
|
+
|
|
2646
|
+
.ui-audio-seek:focus-visible {
|
|
2647
|
+
outline: none;
|
|
2648
|
+
}
|
|
2649
|
+
|
|
2650
|
+
.ui-audio-seek:disabled {
|
|
2651
|
+
cursor: not-allowed;
|
|
2652
|
+
}
|