@zvk/ui 0.1.1 → 0.1.3
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/README.md +4 -3
- package/dist/components/calendar/calendar.d.ts +16 -0
- package/dist/components/calendar/calendar.js +178 -0
- package/dist/components/calendar/index.d.ts +2 -0
- package/dist/components/calendar/index.js +2 -0
- package/dist/components/carousel/carousel.d.ts +51 -0
- package/dist/components/carousel/carousel.js +210 -0
- package/dist/components/carousel/index.d.ts +2 -0
- package/dist/components/carousel/index.js +2 -0
- package/dist/components/date-picker/date-picker.d.ts +16 -0
- package/dist/components/date-picker/date-picker.js +50 -0
- package/dist/components/date-picker/index.d.ts +2 -0
- package/dist/components/date-picker/index.js +2 -0
- package/dist/components/hover-card/hover-card.d.ts +31 -0
- package/dist/components/hover-card/hover-card.js +268 -0
- package/dist/components/hover-card/index.d.ts +2 -0
- package/dist/components/hover-card/index.js +2 -0
- package/dist/components/index.d.ts +10 -2
- package/dist/components/index.js +5 -1
- package/dist/components/popover/popover.d.ts +2 -1
- package/dist/components/popover/popover.js +4 -3
- package/dist/components/toast/index.d.ts +2 -2
- package/dist/components/toast/index.js +2 -1
- package/dist/components/toast/toast.d.ts +26 -0
- package/dist/components/toast/toast.js +101 -1
- package/dist/styles.css +335 -3
- package/package.json +17 -1
package/dist/styles.css
CHANGED
|
@@ -1687,6 +1687,168 @@
|
|
|
1687
1687
|
}
|
|
1688
1688
|
|
|
1689
1689
|
|
|
1690
|
+
/* src/components/calendar/calendar.css */
|
|
1691
|
+
@layer liano-components {
|
|
1692
|
+
:where(.liano-calendar) {
|
|
1693
|
+
color: var(--liano-color-foreground);
|
|
1694
|
+
display: grid;
|
|
1695
|
+
font-family: var(--liano-font-family-sans);
|
|
1696
|
+
gap: var(--liano-space-3);
|
|
1697
|
+
inline-size: max-content;
|
|
1698
|
+
min-inline-size: 17.5rem;
|
|
1699
|
+
}
|
|
1700
|
+
|
|
1701
|
+
:where(.liano-calendar__header) {
|
|
1702
|
+
align-items: center;
|
|
1703
|
+
display: grid;
|
|
1704
|
+
gap: var(--liano-space-2);
|
|
1705
|
+
grid-template-columns: var(--liano-control-height-sm) 1fr var(--liano-control-height-sm);
|
|
1706
|
+
}
|
|
1707
|
+
|
|
1708
|
+
:where(.liano-calendar__heading) {
|
|
1709
|
+
font-size: var(--liano-font-size-sm);
|
|
1710
|
+
font-weight: 700;
|
|
1711
|
+
line-height: var(--liano-line-height-tight);
|
|
1712
|
+
margin: 0;
|
|
1713
|
+
text-align: center;
|
|
1714
|
+
}
|
|
1715
|
+
|
|
1716
|
+
:where(.liano-calendar__nav, .liano-calendar__day) {
|
|
1717
|
+
align-items: center;
|
|
1718
|
+
appearance: none;
|
|
1719
|
+
background: transparent;
|
|
1720
|
+
border: 1px solid transparent;
|
|
1721
|
+
border-radius: var(--liano-radius-sm);
|
|
1722
|
+
color: inherit;
|
|
1723
|
+
cursor: pointer;
|
|
1724
|
+
display: inline-flex;
|
|
1725
|
+
font: inherit;
|
|
1726
|
+
justify-content: center;
|
|
1727
|
+
padding: 0;
|
|
1728
|
+
}
|
|
1729
|
+
|
|
1730
|
+
:where(.liano-calendar__nav) {
|
|
1731
|
+
block-size: var(--liano-control-height-sm);
|
|
1732
|
+
color: var(--liano-color-muted-foreground);
|
|
1733
|
+
font-size: var(--liano-font-size-lg);
|
|
1734
|
+
}
|
|
1735
|
+
|
|
1736
|
+
:where(.liano-calendar__nav:hover) {
|
|
1737
|
+
background: var(--liano-control-hover);
|
|
1738
|
+
color: var(--liano-color-foreground);
|
|
1739
|
+
}
|
|
1740
|
+
|
|
1741
|
+
:where(.liano-calendar__grid) {
|
|
1742
|
+
display: grid;
|
|
1743
|
+
gap: var(--liano-space-1);
|
|
1744
|
+
}
|
|
1745
|
+
|
|
1746
|
+
:where(.liano-calendar__weekdays, .liano-calendar__week) {
|
|
1747
|
+
display: grid;
|
|
1748
|
+
gap: var(--liano-space-1);
|
|
1749
|
+
grid-template-columns: repeat(7, minmax(0, 1fr));
|
|
1750
|
+
}
|
|
1751
|
+
|
|
1752
|
+
:where(.liano-calendar__weekday) {
|
|
1753
|
+
color: var(--liano-color-muted-foreground);
|
|
1754
|
+
font-size: var(--liano-font-size-xs);
|
|
1755
|
+
font-weight: 700;
|
|
1756
|
+
line-height: var(--liano-line-height-tight);
|
|
1757
|
+
padding-block: var(--liano-space-1);
|
|
1758
|
+
text-align: center;
|
|
1759
|
+
}
|
|
1760
|
+
|
|
1761
|
+
:where(.liano-calendar__cell) {
|
|
1762
|
+
display: inline-flex;
|
|
1763
|
+
}
|
|
1764
|
+
|
|
1765
|
+
:where(.liano-calendar__day) {
|
|
1766
|
+
aspect-ratio: 1;
|
|
1767
|
+
block-size: var(--liano-control-height-sm);
|
|
1768
|
+
font-size: var(--liano-font-size-sm);
|
|
1769
|
+
inline-size: var(--liano-control-height-sm);
|
|
1770
|
+
}
|
|
1771
|
+
|
|
1772
|
+
:where(.liano-calendar__day:hover:not(:disabled)) {
|
|
1773
|
+
background: var(--liano-control-hover);
|
|
1774
|
+
border-color: var(--liano-color-border);
|
|
1775
|
+
}
|
|
1776
|
+
|
|
1777
|
+
:where(.liano-calendar__day:focus-visible, .liano-calendar__nav:focus-visible) {
|
|
1778
|
+
box-shadow: var(--liano-focus-ring);
|
|
1779
|
+
outline: 0;
|
|
1780
|
+
}
|
|
1781
|
+
|
|
1782
|
+
:where(.liano-calendar__day[data-outside-month="true"]) {
|
|
1783
|
+
color: var(--liano-color-muted-foreground);
|
|
1784
|
+
opacity: 0.62;
|
|
1785
|
+
}
|
|
1786
|
+
|
|
1787
|
+
:where(.liano-calendar__day[data-today="true"]) {
|
|
1788
|
+
border-color: var(--liano-color-border-strong);
|
|
1789
|
+
font-weight: 700;
|
|
1790
|
+
}
|
|
1791
|
+
|
|
1792
|
+
:where(.liano-calendar__day[data-selected="true"]) {
|
|
1793
|
+
background: var(--liano-color-primary);
|
|
1794
|
+
border-color: var(--liano-color-primary);
|
|
1795
|
+
color: var(--liano-color-primary-foreground);
|
|
1796
|
+
font-weight: 700;
|
|
1797
|
+
}
|
|
1798
|
+
|
|
1799
|
+
:where(.liano-calendar__day:disabled) {
|
|
1800
|
+
cursor: not-allowed;
|
|
1801
|
+
opacity: var(--liano-opacity-disabled);
|
|
1802
|
+
}
|
|
1803
|
+
}
|
|
1804
|
+
|
|
1805
|
+
|
|
1806
|
+
/* src/components/date-picker/date-picker.css */
|
|
1807
|
+
@layer liano-components {
|
|
1808
|
+
:where(.liano-date-picker) {
|
|
1809
|
+
display: grid;
|
|
1810
|
+
gap: var(--liano-space-2);
|
|
1811
|
+
}
|
|
1812
|
+
|
|
1813
|
+
:where(.liano-date-picker .liano-popover) {
|
|
1814
|
+
display: block;
|
|
1815
|
+
inline-size: 100%;
|
|
1816
|
+
}
|
|
1817
|
+
|
|
1818
|
+
:where(.liano-date-picker__trigger) {
|
|
1819
|
+
justify-content: flex-start;
|
|
1820
|
+
line-height: var(--liano-line-height-tight);
|
|
1821
|
+
min-inline-size: 12rem;
|
|
1822
|
+
text-align: start;
|
|
1823
|
+
width: 100%;
|
|
1824
|
+
}
|
|
1825
|
+
|
|
1826
|
+
:where(.liano-date-picker__trigger[data-state="open"]) {
|
|
1827
|
+
border-color: var(--liano-color-ring);
|
|
1828
|
+
box-shadow: var(--liano-shadow-xs), var(--liano-focus-ring);
|
|
1829
|
+
}
|
|
1830
|
+
|
|
1831
|
+
:where(.liano-date-picker__trigger[aria-invalid="true"]) {
|
|
1832
|
+
border-color: var(--liano-color-destructive);
|
|
1833
|
+
}
|
|
1834
|
+
|
|
1835
|
+
:where(.liano-date-picker__trigger--placeholder) {
|
|
1836
|
+
color: var(--liano-color-muted-foreground);
|
|
1837
|
+
font-weight: 500;
|
|
1838
|
+
}
|
|
1839
|
+
|
|
1840
|
+
:where(.liano-date-picker__value) {
|
|
1841
|
+
overflow: hidden;
|
|
1842
|
+
text-overflow: ellipsis;
|
|
1843
|
+
white-space: nowrap;
|
|
1844
|
+
}
|
|
1845
|
+
|
|
1846
|
+
:where(.liano-date-picker__content) {
|
|
1847
|
+
padding: var(--liano-space-3);
|
|
1848
|
+
}
|
|
1849
|
+
}
|
|
1850
|
+
|
|
1851
|
+
|
|
1690
1852
|
/* src/components/select/select.css */
|
|
1691
1853
|
@layer liano-components {
|
|
1692
1854
|
:where(.liano-select) {
|
|
@@ -2843,6 +3005,66 @@
|
|
|
2843
3005
|
}
|
|
2844
3006
|
|
|
2845
3007
|
|
|
3008
|
+
/* src/components/hover-card/hover-card.css */
|
|
3009
|
+
@layer liano-components {
|
|
3010
|
+
:where(.liano-hover-card__trigger) {
|
|
3011
|
+
border-radius: var(--liano-radius-sm);
|
|
3012
|
+
}
|
|
3013
|
+
|
|
3014
|
+
:where(.liano-hover-card__trigger:focus-visible) {
|
|
3015
|
+
box-shadow: var(--liano-focus-ring);
|
|
3016
|
+
outline: 0;
|
|
3017
|
+
}
|
|
3018
|
+
|
|
3019
|
+
:where(.liano-hover-card__content) {
|
|
3020
|
+
animation: liano-hover-card-enter var(--liano-duration-fast) var(--liano-ease-standard);
|
|
3021
|
+
background: var(--liano-color-surface-raised);
|
|
3022
|
+
border: 1px solid var(--liano-color-border);
|
|
3023
|
+
border-radius: var(--liano-radius-md);
|
|
3024
|
+
box-shadow: var(--liano-shadow-md);
|
|
3025
|
+
color: var(--liano-color-foreground);
|
|
3026
|
+
font-family: var(--liano-font-family-sans);
|
|
3027
|
+
font-size: var(--liano-font-size-sm);
|
|
3028
|
+
max-width: min(20rem, var(--liano-floating-available-width));
|
|
3029
|
+
padding: var(--liano-space-3);
|
|
3030
|
+
pointer-events: auto;
|
|
3031
|
+
position: absolute;
|
|
3032
|
+
z-index: var(--liano-z-index-popover, var(--liano-z-index-overlay));
|
|
3033
|
+
}
|
|
3034
|
+
|
|
3035
|
+
:where(.liano-hover-card__content:focus-visible) {
|
|
3036
|
+
box-shadow: var(--liano-shadow-md), var(--liano-focus-ring);
|
|
3037
|
+
outline: 0;
|
|
3038
|
+
}
|
|
3039
|
+
|
|
3040
|
+
:where(.liano-hover-card__content[data-state="closed"]) {
|
|
3041
|
+
animation: none;
|
|
3042
|
+
}
|
|
3043
|
+
|
|
3044
|
+
:where(.liano-hover-card__content[hidden]) {
|
|
3045
|
+
display: none;
|
|
3046
|
+
}
|
|
3047
|
+
|
|
3048
|
+
@keyframes liano-hover-card-enter {
|
|
3049
|
+
from {
|
|
3050
|
+
opacity: 0;
|
|
3051
|
+
transform: scale(0.98) translateY(0.125rem);
|
|
3052
|
+
}
|
|
3053
|
+
|
|
3054
|
+
to {
|
|
3055
|
+
opacity: 1;
|
|
3056
|
+
transform: scale(1) translateY(0);
|
|
3057
|
+
}
|
|
3058
|
+
}
|
|
3059
|
+
|
|
3060
|
+
@media (prefers-reduced-motion: reduce) {
|
|
3061
|
+
:where(.liano-hover-card__content) {
|
|
3062
|
+
animation: none;
|
|
3063
|
+
}
|
|
3064
|
+
}
|
|
3065
|
+
}
|
|
3066
|
+
|
|
3067
|
+
|
|
2846
3068
|
/* src/components/tooltip/tooltip.css */
|
|
2847
3069
|
@layer liano-components {
|
|
2848
3070
|
:where(.liano-tooltip) {
|
|
@@ -3439,6 +3661,101 @@
|
|
|
3439
3661
|
}
|
|
3440
3662
|
|
|
3441
3663
|
|
|
3664
|
+
/* src/components/carousel/carousel.css */
|
|
3665
|
+
@layer liano-components {
|
|
3666
|
+
:where(.liano-carousel) {
|
|
3667
|
+
--liano-carousel-gap: var(--liano-space-3);
|
|
3668
|
+
--liano-carousel-slide-size: 100%;
|
|
3669
|
+
|
|
3670
|
+
color: var(--liano-color-foreground);
|
|
3671
|
+
display: grid;
|
|
3672
|
+
gap: var(--liano-carousel-gap);
|
|
3673
|
+
}
|
|
3674
|
+
|
|
3675
|
+
:where(.liano-carousel:focus-visible) {
|
|
3676
|
+
outline: 0;
|
|
3677
|
+
box-shadow: var(--liano-focus-ring);
|
|
3678
|
+
}
|
|
3679
|
+
|
|
3680
|
+
:where(.liano-carousel__viewport) {
|
|
3681
|
+
overflow: auto;
|
|
3682
|
+
overscroll-behavior: contain;
|
|
3683
|
+
scrollbar-width: none;
|
|
3684
|
+
scroll-behavior: smooth;
|
|
3685
|
+
scroll-snap-type: x mandatory;
|
|
3686
|
+
}
|
|
3687
|
+
|
|
3688
|
+
:where(.liano-carousel__viewport[data-orientation="vertical"]) {
|
|
3689
|
+
scroll-snap-type: y mandatory;
|
|
3690
|
+
}
|
|
3691
|
+
|
|
3692
|
+
.liano-carousel__viewport::-webkit-scrollbar {
|
|
3693
|
+
display: none;
|
|
3694
|
+
}
|
|
3695
|
+
|
|
3696
|
+
:where(.liano-carousel__track) {
|
|
3697
|
+
display: flex;
|
|
3698
|
+
gap: var(--liano-carousel-gap);
|
|
3699
|
+
}
|
|
3700
|
+
|
|
3701
|
+
:where(.liano-carousel__track[data-orientation="vertical"]) {
|
|
3702
|
+
flex-direction: column;
|
|
3703
|
+
}
|
|
3704
|
+
|
|
3705
|
+
:where(.liano-carousel__slide) {
|
|
3706
|
+
flex: 0 0 var(--liano-carousel-slide-size);
|
|
3707
|
+
min-inline-size: 0;
|
|
3708
|
+
scroll-snap-align: start;
|
|
3709
|
+
}
|
|
3710
|
+
|
|
3711
|
+
:where(.liano-carousel__slide[data-selected="true"]) {
|
|
3712
|
+
scroll-snap-stop: always;
|
|
3713
|
+
}
|
|
3714
|
+
|
|
3715
|
+
:where(.liano-carousel__button) {
|
|
3716
|
+
align-items: center;
|
|
3717
|
+
appearance: none;
|
|
3718
|
+
background: var(--liano-color-surface);
|
|
3719
|
+
border: 1px solid var(--liano-color-border);
|
|
3720
|
+
border-radius: var(--liano-radius-sm);
|
|
3721
|
+
color: var(--liano-color-foreground);
|
|
3722
|
+
cursor: pointer;
|
|
3723
|
+
display: inline-flex;
|
|
3724
|
+
font-family: var(--liano-font-family-sans);
|
|
3725
|
+
font-size: var(--liano-font-size-sm);
|
|
3726
|
+
font-weight: 600;
|
|
3727
|
+
justify-content: center;
|
|
3728
|
+
line-height: 1;
|
|
3729
|
+
min-block-size: var(--liano-control-height-sm);
|
|
3730
|
+
padding-block: 0;
|
|
3731
|
+
padding-inline: var(--liano-control-padding-x);
|
|
3732
|
+
transition: background var(--liano-duration-fast) var(--liano-ease-standard), border-color var(--liano-duration-fast) var(--liano-ease-standard), box-shadow var(--liano-duration-fast) var(--liano-ease-standard), color var(--liano-duration-fast) var(--liano-ease-standard);
|
|
3733
|
+
}
|
|
3734
|
+
|
|
3735
|
+
:where(.liano-carousel__button:hover:not(:disabled)) {
|
|
3736
|
+
background: var(--liano-control-hover);
|
|
3737
|
+
border-color: var(--liano-color-border-strong);
|
|
3738
|
+
}
|
|
3739
|
+
|
|
3740
|
+
:where(.liano-carousel__button:focus-visible) {
|
|
3741
|
+
outline: 0;
|
|
3742
|
+
box-shadow: var(--liano-focus-ring);
|
|
3743
|
+
}
|
|
3744
|
+
|
|
3745
|
+
:where(.liano-carousel__button:disabled) {
|
|
3746
|
+
cursor: not-allowed;
|
|
3747
|
+
opacity: var(--liano-opacity-disabled);
|
|
3748
|
+
}
|
|
3749
|
+
|
|
3750
|
+
:where(.liano-carousel__page) {
|
|
3751
|
+
color: var(--liano-color-muted-foreground);
|
|
3752
|
+
font-family: var(--liano-font-family-sans);
|
|
3753
|
+
font-size: var(--liano-font-size-sm);
|
|
3754
|
+
line-height: var(--liano-line-height-normal);
|
|
3755
|
+
}
|
|
3756
|
+
}
|
|
3757
|
+
|
|
3758
|
+
|
|
3442
3759
|
/* src/components/responsive-container/responsive-container.css */
|
|
3443
3760
|
@layer liano-components {
|
|
3444
3761
|
:where(.liano-responsive-container) {
|
|
@@ -3799,14 +4116,27 @@
|
|
|
3799
4116
|
line-height: var(--liano-line-height-tight);
|
|
3800
4117
|
}
|
|
3801
4118
|
|
|
4119
|
+
:where(.liano-toast__content) {
|
|
4120
|
+
display: grid;
|
|
4121
|
+
gap: var(--liano-space-1);
|
|
4122
|
+
}
|
|
4123
|
+
|
|
3802
4124
|
:where(.liano-toast__description) {
|
|
3803
4125
|
color: var(--liano-color-muted-foreground);
|
|
3804
4126
|
font-size: var(--liano-font-size-sm);
|
|
3805
4127
|
line-height: var(--liano-line-height-normal);
|
|
3806
4128
|
}
|
|
3807
4129
|
|
|
4130
|
+
:where(.liano-toast__controls) {
|
|
4131
|
+
align-items: center;
|
|
4132
|
+
display: flex;
|
|
4133
|
+
flex-wrap: wrap;
|
|
4134
|
+
gap: var(--liano-space-2);
|
|
4135
|
+
}
|
|
4136
|
+
|
|
3808
4137
|
:where(.liano-toast__action),
|
|
3809
|
-
:where(.liano-toast__close)
|
|
4138
|
+
:where(.liano-toast__close),
|
|
4139
|
+
:where(.liano-toast__controls > button) {
|
|
3810
4140
|
align-items: center;
|
|
3811
4141
|
appearance: none;
|
|
3812
4142
|
background: transparent;
|
|
@@ -3822,12 +4152,14 @@
|
|
|
3822
4152
|
}
|
|
3823
4153
|
|
|
3824
4154
|
:where(.liano-toast__action:hover:not(:disabled)),
|
|
3825
|
-
:where(.liano-toast__close:hover:not(:disabled))
|
|
4155
|
+
:where(.liano-toast__close:hover:not(:disabled)),
|
|
4156
|
+
:where(.liano-toast__controls > button:hover:not(:disabled)) {
|
|
3826
4157
|
background: var(--liano-control-hover);
|
|
3827
4158
|
}
|
|
3828
4159
|
|
|
3829
4160
|
:where(.liano-toast__action:focus-visible),
|
|
3830
|
-
:where(.liano-toast__close:focus-visible)
|
|
4161
|
+
:where(.liano-toast__close:focus-visible),
|
|
4162
|
+
:where(.liano-toast__controls > button:focus-visible) {
|
|
3831
4163
|
outline: 0;
|
|
3832
4164
|
box-shadow: var(--liano-focus-ring);
|
|
3833
4165
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zvk/ui",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.3",
|
|
4
4
|
"description": "A polished, zero-runtime-dependency React component library for Liano applications.",
|
|
5
5
|
"private": false,
|
|
6
6
|
"type": "module",
|
|
@@ -173,6 +173,10 @@
|
|
|
173
173
|
"types": "./dist/components/popover/index.d.ts",
|
|
174
174
|
"import": "./dist/components/popover/index.js"
|
|
175
175
|
},
|
|
176
|
+
"./hover-card": {
|
|
177
|
+
"types": "./dist/components/hover-card/index.d.ts",
|
|
178
|
+
"import": "./dist/components/hover-card/index.js"
|
|
179
|
+
},
|
|
176
180
|
"./tooltip": {
|
|
177
181
|
"types": "./dist/components/tooltip/index.d.ts",
|
|
178
182
|
"import": "./dist/components/tooltip/index.js"
|
|
@@ -209,6 +213,18 @@
|
|
|
209
213
|
"types": "./dist/components/menubar/index.d.ts",
|
|
210
214
|
"import": "./dist/components/menubar/index.js"
|
|
211
215
|
},
|
|
216
|
+
"./calendar": {
|
|
217
|
+
"types": "./dist/components/calendar/index.d.ts",
|
|
218
|
+
"import": "./dist/components/calendar/index.js"
|
|
219
|
+
},
|
|
220
|
+
"./date-picker": {
|
|
221
|
+
"types": "./dist/components/date-picker/index.d.ts",
|
|
222
|
+
"import": "./dist/components/date-picker/index.js"
|
|
223
|
+
},
|
|
224
|
+
"./carousel": {
|
|
225
|
+
"types": "./dist/components/carousel/index.d.ts",
|
|
226
|
+
"import": "./dist/components/carousel/index.js"
|
|
227
|
+
},
|
|
212
228
|
"./responsive-container": {
|
|
213
229
|
"types": "./dist/components/responsive-container/index.d.ts",
|
|
214
230
|
"import": "./dist/components/responsive-container/index.js"
|