@sofya-ds/react 1.1.1 → 1.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/dist/index.cjs +72 -168
- package/dist/index.css +1 -1
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +72 -168
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -354,7 +354,7 @@ Icon.displayName = "Icon";
|
|
|
354
354
|
// src/components/text.tsx
|
|
355
355
|
import * as React3 from "react";
|
|
356
356
|
import { jsx as jsx3 } from "react/jsx-runtime";
|
|
357
|
-
var textSizeOptions = ["h1", "h2", "h3", "h4", "body", "tiny"];
|
|
357
|
+
var textSizeOptions = ["h1", "h2", "h3", "h4", "h5", "body", "tiny"];
|
|
358
358
|
var textVariantOptions = ["default", "gradient", "shiny", "split"];
|
|
359
359
|
var textSplitTypeOptions = ["chars", "words", "words, chars"];
|
|
360
360
|
var defaultElements = {
|
|
@@ -362,6 +362,7 @@ var defaultElements = {
|
|
|
362
362
|
h2: "h2",
|
|
363
363
|
h3: "h3",
|
|
364
364
|
h4: "h4",
|
|
365
|
+
h5: "h5",
|
|
365
366
|
body: "p",
|
|
366
367
|
tiny: "span"
|
|
367
368
|
};
|
|
@@ -584,7 +585,7 @@ var AccordionTrigger = React4.forwardRef(({ className, children, indicator, ...p
|
|
|
584
585
|
{
|
|
585
586
|
ref,
|
|
586
587
|
className: cn(
|
|
587
|
-
"sofya-accordion-trigger flex flex-1 items-center justify-between gap-4 py-4 text-left text-[
|
|
588
|
+
"sofya-accordion-trigger flex flex-1 items-center justify-between gap-4 py-4 text-left [font-family:var(--sofya-text-body-font-family)] text-[length:var(--sofya-text-body-font-size)] font-medium leading-[var(--sofya-text-body-line-height)] tracking-[var(--sofya-text-body-letter-spacing)] text-foreground transition-colors duration-sofya ease-sofya focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:pointer-events-none disabled:opacity-50",
|
|
588
589
|
className
|
|
589
590
|
),
|
|
590
591
|
...props,
|
|
@@ -594,8 +595,12 @@ var AccordionTrigger = React4.forwardRef(({ className, children, indicator, ...p
|
|
|
594
595
|
className: "block text-foreground",
|
|
595
596
|
size: "body",
|
|
596
597
|
style: {
|
|
597
|
-
|
|
598
|
-
|
|
598
|
+
color: "inherit",
|
|
599
|
+
fontFamily: "inherit",
|
|
600
|
+
fontSize: "inherit",
|
|
601
|
+
fontWeight: "inherit",
|
|
602
|
+
letterSpacing: "inherit",
|
|
603
|
+
lineHeight: "inherit"
|
|
599
604
|
}
|
|
600
605
|
}) }),
|
|
601
606
|
/* @__PURE__ */ jsx4(
|
|
@@ -696,7 +701,7 @@ var Alert = React5.forwardRef(function Alert2({
|
|
|
696
701
|
"span",
|
|
697
702
|
{
|
|
698
703
|
"data-slot": "alert-icon",
|
|
699
|
-
className: "mt-
|
|
704
|
+
className: "mt-2 inline-flex h-4 w-4 shrink-0 items-center justify-center text-current [&>svg]:h-4 [&>svg]:w-4",
|
|
700
705
|
children: resolvedIcon
|
|
701
706
|
}
|
|
702
707
|
) : null,
|
|
@@ -716,12 +721,7 @@ var AlertTitle = React5.forwardRef(function AlertTitle2({ children, className, .
|
|
|
716
721
|
children: renderTextContent(children, {
|
|
717
722
|
as: "span",
|
|
718
723
|
className: "block text-current",
|
|
719
|
-
size: "h4"
|
|
720
|
-
style: {
|
|
721
|
-
fontWeight: 500,
|
|
722
|
-
lineHeight: "22px",
|
|
723
|
-
letterSpacing: "-0.02em"
|
|
724
|
-
}
|
|
724
|
+
size: "h4"
|
|
725
725
|
})
|
|
726
726
|
}
|
|
727
727
|
);
|
|
@@ -737,10 +737,7 @@ var AlertDescription = React5.forwardRef(function AlertDescription2({ children,
|
|
|
737
737
|
children: renderTextContent(children, {
|
|
738
738
|
as: "span",
|
|
739
739
|
className: "block text-current/80",
|
|
740
|
-
size: "body"
|
|
741
|
-
style: {
|
|
742
|
-
lineHeight: "24px"
|
|
743
|
-
}
|
|
740
|
+
size: "body"
|
|
744
741
|
})
|
|
745
742
|
}
|
|
746
743
|
);
|
|
@@ -1433,13 +1430,7 @@ function CardTitle({ children, className, ...props }) {
|
|
|
1433
1430
|
children: renderTextContent(children, {
|
|
1434
1431
|
as: "span",
|
|
1435
1432
|
className: "block text-card-foreground",
|
|
1436
|
-
size: "h4"
|
|
1437
|
-
style: {
|
|
1438
|
-
fontSize: "1.25rem",
|
|
1439
|
-
fontWeight: 600,
|
|
1440
|
-
lineHeight: "1.75rem",
|
|
1441
|
-
letterSpacing: "-0.025em"
|
|
1442
|
-
}
|
|
1433
|
+
size: "h4"
|
|
1443
1434
|
})
|
|
1444
1435
|
}
|
|
1445
1436
|
);
|
|
@@ -1452,10 +1443,7 @@ function CardDescription({
|
|
|
1452
1443
|
return /* @__PURE__ */ jsx9("p", { className: cn("text-muted-foreground", className), ...props, children: renderTextContent(children, {
|
|
1453
1444
|
as: "span",
|
|
1454
1445
|
className: "block text-muted-foreground",
|
|
1455
|
-
size: "body"
|
|
1456
|
-
style: {
|
|
1457
|
-
lineHeight: "20px"
|
|
1458
|
-
}
|
|
1446
|
+
size: "body"
|
|
1459
1447
|
}) });
|
|
1460
1448
|
}
|
|
1461
1449
|
function CardContent({ children, className, ...props }) {
|
|
@@ -1555,12 +1543,7 @@ var Checkbox = React8.forwardRef(
|
|
|
1555
1543
|
children: renderTextContent(label, {
|
|
1556
1544
|
as: "span",
|
|
1557
1545
|
className: "text-[color:var(--sofya-text-default)]",
|
|
1558
|
-
size: "
|
|
1559
|
-
style: {
|
|
1560
|
-
fontWeight: 400,
|
|
1561
|
-
lineHeight: "22px",
|
|
1562
|
-
letterSpacing: "-0.02em"
|
|
1563
|
-
}
|
|
1546
|
+
size: "body"
|
|
1564
1547
|
})
|
|
1565
1548
|
}
|
|
1566
1549
|
) : null,
|
|
@@ -1572,10 +1555,7 @@ var Checkbox = React8.forwardRef(
|
|
|
1572
1555
|
children: renderTextContent(description, {
|
|
1573
1556
|
as: "span",
|
|
1574
1557
|
className: "text-muted-foreground",
|
|
1575
|
-
size: "body"
|
|
1576
|
-
style: {
|
|
1577
|
-
lineHeight: "20px"
|
|
1578
|
-
}
|
|
1558
|
+
size: "body"
|
|
1579
1559
|
})
|
|
1580
1560
|
}
|
|
1581
1561
|
) : null
|
|
@@ -1606,7 +1586,7 @@ var dropdownTriggerClasses = {
|
|
|
1606
1586
|
card: "h-12 rounded-[20px] px-6 py-2 text-primary",
|
|
1607
1587
|
panel: "h-12 rounded-[10px] px-6 py-2 text-foreground",
|
|
1608
1588
|
language: "",
|
|
1609
|
-
selected: "h-10 w-full rounded-[10px] border-[color:var(--sofya-border-strong)] px-4 py-2 text-[
|
|
1589
|
+
selected: "h-10 w-full rounded-[10px] border-[color:var(--sofya-border-strong)] px-4 py-2 [font-family:var(--sofya-text-body-font-family)] text-[length:var(--sofya-text-body-font-size)] [font-weight:var(--sofya-text-body-font-weight)] leading-[var(--sofya-text-body-line-height)] tracking-[var(--sofya-text-body-letter-spacing)]"
|
|
1610
1590
|
};
|
|
1611
1591
|
var dropdownContentClasses = {
|
|
1612
1592
|
card: "rounded-[20px] border-[color:var(--sofya-border-strong)] text-foreground shadow-[var(--sofya-shadow-soft)]",
|
|
@@ -1740,12 +1720,7 @@ function Dropdown({
|
|
|
1740
1720
|
children: isLanguageVariant ? null : /* @__PURE__ */ jsx11("span", { className: "min-w-0 truncate", children: renderTextContent(triggerLabel, {
|
|
1741
1721
|
as: "span",
|
|
1742
1722
|
className: "block min-w-0 truncate text-inherit",
|
|
1743
|
-
size: "body"
|
|
1744
|
-
style: {
|
|
1745
|
-
fontWeight: 400,
|
|
1746
|
-
lineHeight: "22px",
|
|
1747
|
-
letterSpacing: isSelectedVariant ? "-0.02em" : 0
|
|
1748
|
-
}
|
|
1723
|
+
size: "body"
|
|
1749
1724
|
}) })
|
|
1750
1725
|
}
|
|
1751
1726
|
) }),
|
|
@@ -1776,7 +1751,7 @@ function Dropdown({
|
|
|
1776
1751
|
value: item.value,
|
|
1777
1752
|
disabled: item.disabled,
|
|
1778
1753
|
className: cn(
|
|
1779
|
-
"flex w-full cursor-pointer items-center rounded-[4px] text-[
|
|
1754
|
+
"flex w-full cursor-pointer items-center rounded-[4px] [font-family:var(--sofya-text-body-font-family)] text-[length:var(--sofya-text-body-font-size)] [font-weight:var(--sofya-text-body-font-weight)] leading-[22px] tracking-[var(--sofya-text-body-letter-spacing)] outline-none transition-colors duration-sofya ease-sofya data-[disabled]:pointer-events-none data-[disabled]:opacity-40",
|
|
1780
1755
|
usesDefaultListStyle ? "px-0 py-0 data-[highlighted]:bg-transparent [&[data-highlighted]_span[data-dropdown-item-body]]:bg-[color:var(--sofya-surface-selected)]" : "px-2 py-2 data-[highlighted]:bg-[color:var(--sofya-surface-hover)]",
|
|
1781
1756
|
dropdownItemClasses[variant],
|
|
1782
1757
|
itemClassName
|
|
@@ -1794,11 +1769,7 @@ function Dropdown({
|
|
|
1794
1769
|
/* @__PURE__ */ jsx11("span", { className: "truncate", children: renderTextContent(item.label, {
|
|
1795
1770
|
as: "span",
|
|
1796
1771
|
className: "block truncate text-inherit",
|
|
1797
|
-
size: "body"
|
|
1798
|
-
style: {
|
|
1799
|
-
fontWeight: 400,
|
|
1800
|
-
lineHeight: "22px"
|
|
1801
|
-
}
|
|
1772
|
+
size: "body"
|
|
1802
1773
|
}) }),
|
|
1803
1774
|
isSelected ? /* @__PURE__ */ jsx11(
|
|
1804
1775
|
"span",
|
|
@@ -1816,11 +1787,7 @@ function Dropdown({
|
|
|
1816
1787
|
/* @__PURE__ */ jsx11("span", { className: "truncate", children: renderTextContent(item.label, {
|
|
1817
1788
|
as: "span",
|
|
1818
1789
|
className: "block truncate text-inherit",
|
|
1819
|
-
size: "body"
|
|
1820
|
-
style: {
|
|
1821
|
-
fontWeight: 400,
|
|
1822
|
-
lineHeight: "22px"
|
|
1823
|
-
}
|
|
1790
|
+
size: "body"
|
|
1824
1791
|
}) })
|
|
1825
1792
|
] }),
|
|
1826
1793
|
/* @__PURE__ */ jsx11(
|
|
@@ -1951,13 +1918,7 @@ var DialogTitle = React10.forwardRef(({ children, className, ...props }, ref) =>
|
|
|
1951
1918
|
children: renderTextContent(children, {
|
|
1952
1919
|
as: "span",
|
|
1953
1920
|
className: "block text-card-foreground",
|
|
1954
|
-
size: "h4"
|
|
1955
|
-
style: {
|
|
1956
|
-
fontSize: "1.25rem",
|
|
1957
|
-
fontWeight: 600,
|
|
1958
|
-
lineHeight: "1.75rem",
|
|
1959
|
-
letterSpacing: "-0.025em"
|
|
1960
|
-
}
|
|
1921
|
+
size: "h4"
|
|
1961
1922
|
})
|
|
1962
1923
|
}
|
|
1963
1924
|
));
|
|
@@ -1971,10 +1932,7 @@ var DialogDescription = React10.forwardRef(({ children, className, ...props }, r
|
|
|
1971
1932
|
children: renderTextContent(children, {
|
|
1972
1933
|
as: "span",
|
|
1973
1934
|
className: "block text-muted-foreground",
|
|
1974
|
-
size: "body"
|
|
1975
|
-
style: {
|
|
1976
|
-
lineHeight: "24px"
|
|
1977
|
-
}
|
|
1935
|
+
size: "body"
|
|
1978
1936
|
})
|
|
1979
1937
|
}
|
|
1980
1938
|
));
|
|
@@ -2020,10 +1978,7 @@ function EmptyTitle({ children, className, ...props }) {
|
|
|
2020
1978
|
children: renderTextContent(children, {
|
|
2021
1979
|
as: "span",
|
|
2022
1980
|
className: "block text-foreground",
|
|
2023
|
-
size: "h2"
|
|
2024
|
-
style: {
|
|
2025
|
-
letterSpacing: "-0.02em"
|
|
2026
|
-
}
|
|
1981
|
+
size: "h2"
|
|
2027
1982
|
})
|
|
2028
1983
|
}
|
|
2029
1984
|
);
|
|
@@ -2041,10 +1996,7 @@ function EmptyDescription({
|
|
|
2041
1996
|
children: renderTextContent(children, {
|
|
2042
1997
|
as: "span",
|
|
2043
1998
|
className: "inline-block whitespace-nowrap text-muted-foreground",
|
|
2044
|
-
size: "body"
|
|
2045
|
-
style: {
|
|
2046
|
-
lineHeight: "24px"
|
|
2047
|
-
}
|
|
1999
|
+
size: "body"
|
|
2048
2000
|
})
|
|
2049
2001
|
}
|
|
2050
2002
|
);
|
|
@@ -2295,7 +2247,7 @@ function InputShell({
|
|
|
2295
2247
|
if (!label && !containerClassName) {
|
|
2296
2248
|
return control;
|
|
2297
2249
|
}
|
|
2298
|
-
return /* @__PURE__ */ jsxs10("div", { className: cn("grid w-full gap-
|
|
2250
|
+
return /* @__PURE__ */ jsxs10("div", { className: cn("grid w-full gap-2", containerClassName), children: [
|
|
2299
2251
|
label ? /* @__PURE__ */ jsx15(
|
|
2300
2252
|
"label",
|
|
2301
2253
|
{
|
|
@@ -2307,11 +2259,9 @@ function InputShell({
|
|
|
2307
2259
|
children: renderTextContent(label, {
|
|
2308
2260
|
as: "span",
|
|
2309
2261
|
className: "block text-[color:var(--sofya-text-default)]",
|
|
2310
|
-
size: "
|
|
2262
|
+
size: "body",
|
|
2311
2263
|
style: {
|
|
2312
|
-
fontWeight: 500
|
|
2313
|
-
lineHeight: "22px",
|
|
2314
|
-
letterSpacing: "-0.02em"
|
|
2264
|
+
fontWeight: 500
|
|
2315
2265
|
}
|
|
2316
2266
|
})
|
|
2317
2267
|
}
|
|
@@ -2343,19 +2293,13 @@ function UploadInputShell({
|
|
|
2343
2293
|
className: "text-[color:var(--sofya-text-default)]",
|
|
2344
2294
|
size: "body",
|
|
2345
2295
|
style: {
|
|
2346
|
-
fontWeight: 700
|
|
2347
|
-
lineHeight: "normal",
|
|
2348
|
-
letterSpacing: "-0.02em"
|
|
2296
|
+
fontWeight: 700
|
|
2349
2297
|
}
|
|
2350
2298
|
}),
|
|
2351
2299
|
optionalLabel ? /* @__PURE__ */ jsx15("span", { className: "ml-2 text-[color:var(--sofya-text-subtle)]", children: renderTextContent(optionalLabel, {
|
|
2352
2300
|
as: "span",
|
|
2353
2301
|
className: "text-[color:var(--sofya-text-subtle)]",
|
|
2354
|
-
size: "tiny"
|
|
2355
|
-
style: {
|
|
2356
|
-
fontWeight: 400,
|
|
2357
|
-
lineHeight: "normal"
|
|
2358
|
-
}
|
|
2302
|
+
size: "tiny"
|
|
2359
2303
|
}) }) : null
|
|
2360
2304
|
]
|
|
2361
2305
|
}
|
|
@@ -2710,20 +2654,13 @@ var UploadInputControl = React13.forwardRef(function UploadInputControl2({
|
|
|
2710
2654
|
className: "block text-[color:var(--sofya-text-default)]",
|
|
2711
2655
|
size: "body",
|
|
2712
2656
|
style: {
|
|
2713
|
-
fontWeight: 500
|
|
2714
|
-
lineHeight: "normal",
|
|
2715
|
-
letterSpacing: "-0.02em"
|
|
2657
|
+
fontWeight: 500
|
|
2716
2658
|
}
|
|
2717
2659
|
}) }),
|
|
2718
2660
|
resolvedDescription ? /* @__PURE__ */ jsx15("span", { className: "text-[color:var(--sofya-text-subtle)]", children: renderTextContent(resolvedDescription, {
|
|
2719
2661
|
as: "span",
|
|
2720
2662
|
className: "block text-[color:var(--sofya-text-subtle)]",
|
|
2721
|
-
size: "tiny"
|
|
2722
|
-
style: {
|
|
2723
|
-
fontWeight: 500,
|
|
2724
|
-
lineHeight: "normal",
|
|
2725
|
-
letterSpacing: "-0.02em"
|
|
2726
|
-
}
|
|
2663
|
+
size: "tiny"
|
|
2727
2664
|
}) }) : null
|
|
2728
2665
|
]
|
|
2729
2666
|
}
|
|
@@ -2754,9 +2691,7 @@ var UploadInputControl = React13.forwardRef(function UploadInputControl2({
|
|
|
2754
2691
|
className: "block truncate text-[color:var(--sofya-text-default)]",
|
|
2755
2692
|
size: "body",
|
|
2756
2693
|
style: {
|
|
2757
|
-
fontWeight: 500
|
|
2758
|
-
lineHeight: "normal",
|
|
2759
|
-
letterSpacing: "-0.02em"
|
|
2694
|
+
fontWeight: 500
|
|
2760
2695
|
}
|
|
2761
2696
|
}) }),
|
|
2762
2697
|
/* @__PURE__ */ jsx15("p", { className: "mt-2 text-[color:var(--sofya-text-subtle)]", children: renderTextContent(
|
|
@@ -2766,12 +2701,7 @@ var UploadInputControl = React13.forwardRef(function UploadInputControl2({
|
|
|
2766
2701
|
{
|
|
2767
2702
|
as: "span",
|
|
2768
2703
|
className: "block text-[color:var(--sofya-text-subtle)]",
|
|
2769
|
-
size: "tiny"
|
|
2770
|
-
style: {
|
|
2771
|
-
fontWeight: 500,
|
|
2772
|
-
lineHeight: "normal",
|
|
2773
|
-
letterSpacing: "-0.02em"
|
|
2774
|
-
}
|
|
2704
|
+
size: "tiny"
|
|
2775
2705
|
}
|
|
2776
2706
|
) })
|
|
2777
2707
|
] }),
|
|
@@ -2955,7 +2885,7 @@ var Input = React13.forwardRef((props, ref) => {
|
|
|
2955
2885
|
ref,
|
|
2956
2886
|
type: resolvedType,
|
|
2957
2887
|
className: cn(
|
|
2958
|
-
"flex h-10 w-full rounded-[10px] border border-[color:var(--sofya-border-strong)] bg-card px-4 py-2 text-[
|
|
2888
|
+
"flex h-10 w-full rounded-[10px] border border-[color:var(--sofya-border-strong)] bg-card px-4 py-2 [font-family:var(--sofya-text-body-font-family)] text-[length:var(--sofya-text-body-font-size)] [font-weight:var(--sofya-text-body-font-weight)] leading-[var(--sofya-text-body-line-height)] tracking-[var(--sofya-text-body-letter-spacing)] text-[color:var(--sofya-text-default)] shadow-none transition-[border-color,box-shadow,background-color,color] duration-sofya ease-sofya placeholder:text-[color:var(--sofya-text-placeholder)] hover:border-[color:var(--sofya-border-hover)] focus:border-transparent focus:outline-none focus:ring-2 focus:ring-[color:var(--sofya-focus-ring-soft)] focus:ring-offset-0 active:border-transparent active:ring-2 active:ring-[color:var(--sofya-focus-ring-soft)] disabled:cursor-not-allowed disabled:bg-muted disabled:opacity-50",
|
|
2959
2889
|
className
|
|
2960
2890
|
),
|
|
2961
2891
|
...nativeProps,
|
|
@@ -2994,9 +2924,7 @@ var Label = React14.forwardRef(
|
|
|
2994
2924
|
className: "block text-foreground",
|
|
2995
2925
|
size: "body",
|
|
2996
2926
|
style: {
|
|
2997
|
-
|
|
2998
|
-
fontWeight: 500,
|
|
2999
|
-
lineHeight: 1
|
|
2927
|
+
fontWeight: 500
|
|
3000
2928
|
}
|
|
3001
2929
|
})
|
|
3002
2930
|
}
|
|
@@ -3222,8 +3150,16 @@ Logo.displayName = "Logo";
|
|
|
3222
3150
|
import { Slot as Slot4 } from "@radix-ui/react-slot";
|
|
3223
3151
|
import { cva as cva7 } from "class-variance-authority";
|
|
3224
3152
|
import { jsx as jsx19, jsxs as jsxs12 } from "react/jsx-runtime";
|
|
3153
|
+
var inheritTypographyStyle = {
|
|
3154
|
+
color: "inherit",
|
|
3155
|
+
fontFamily: "inherit",
|
|
3156
|
+
fontSize: "inherit",
|
|
3157
|
+
fontWeight: "inherit",
|
|
3158
|
+
letterSpacing: "inherit",
|
|
3159
|
+
lineHeight: "inherit"
|
|
3160
|
+
};
|
|
3225
3161
|
var paginationLinkVariants = cva7(
|
|
3226
|
-
"inline-flex h-10 min-w-10 items-center justify-center rounded-full border border-transparent px-4 text-[
|
|
3162
|
+
"inline-flex h-10 min-w-10 items-center justify-center rounded-full border border-transparent px-4 [font-family:var(--sofya-text-body-font-family)] text-[length:var(--sofya-text-body-font-size)] font-medium leading-[var(--sofya-text-body-line-height)] tracking-[var(--sofya-text-body-letter-spacing)] text-[color:var(--sofya-text-soft)] no-underline transition-[transform,background-color,border-color,color,box-shadow] duration-sofya ease-sofya motion-safe:active:scale-[0.985] focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[color:var(--sofya-focus-ring-soft)] focus-visible:ring-offset-0",
|
|
3227
3163
|
{
|
|
3228
3164
|
variants: {
|
|
3229
3165
|
isActive: {
|
|
@@ -3347,11 +3283,7 @@ function PaginationPrevious({
|
|
|
3347
3283
|
as: "span",
|
|
3348
3284
|
className: "block text-inherit",
|
|
3349
3285
|
size: "body",
|
|
3350
|
-
style:
|
|
3351
|
-
fontWeight: 500,
|
|
3352
|
-
lineHeight: 1,
|
|
3353
|
-
letterSpacing: "0.01em"
|
|
3354
|
-
}
|
|
3286
|
+
style: inheritTypographyStyle
|
|
3355
3287
|
}) })
|
|
3356
3288
|
]
|
|
3357
3289
|
}
|
|
@@ -3373,11 +3305,7 @@ function PaginationNext({
|
|
|
3373
3305
|
as: "span",
|
|
3374
3306
|
className: "block text-inherit",
|
|
3375
3307
|
size: "body",
|
|
3376
|
-
style:
|
|
3377
|
-
fontWeight: 500,
|
|
3378
|
-
lineHeight: 1,
|
|
3379
|
-
letterSpacing: "0.01em"
|
|
3380
|
-
}
|
|
3308
|
+
style: inheritTypographyStyle
|
|
3381
3309
|
}) }),
|
|
3382
3310
|
/* @__PURE__ */ jsx19(PaginationChevronRight, {})
|
|
3383
3311
|
]
|
|
@@ -3393,7 +3321,7 @@ function PaginationEllipsis({
|
|
|
3393
3321
|
{
|
|
3394
3322
|
"aria-hidden": "true",
|
|
3395
3323
|
className: cn(
|
|
3396
|
-
"flex h-10 w-10 items-center justify-center rounded-full text-[
|
|
3324
|
+
"flex h-10 w-10 items-center justify-center rounded-full [font-family:var(--sofya-text-h5-font-family)] text-[length:var(--sofya-text-h5-font-size)] [font-weight:var(--sofya-text-h5-font-weight)] leading-[var(--sofya-text-h5-line-height)] tracking-[var(--sofya-text-h5-letter-spacing)] text-[color:var(--sofya-text-subtle)]",
|
|
3397
3325
|
className
|
|
3398
3326
|
),
|
|
3399
3327
|
...props,
|
|
@@ -3401,12 +3329,8 @@ function PaginationEllipsis({
|
|
|
3401
3329
|
/* @__PURE__ */ jsx19("span", { children: renderTextContent("...", {
|
|
3402
3330
|
as: "span",
|
|
3403
3331
|
className: "block text-inherit",
|
|
3404
|
-
size: "
|
|
3405
|
-
style:
|
|
3406
|
-
fontSize: "18px",
|
|
3407
|
-
fontWeight: 400,
|
|
3408
|
-
lineHeight: 1
|
|
3409
|
-
}
|
|
3332
|
+
size: "h5",
|
|
3333
|
+
style: inheritTypographyStyle
|
|
3410
3334
|
}) }),
|
|
3411
3335
|
/* @__PURE__ */ jsx19("span", { className: "sr-only", children: "More pages" })
|
|
3412
3336
|
]
|
|
@@ -3458,12 +3382,7 @@ var PopoverTitle = React17.forwardRef(function PopoverTitle2({ children, classNa
|
|
|
3458
3382
|
children: renderTextContent(children, {
|
|
3459
3383
|
as: "span",
|
|
3460
3384
|
className: "block text-[hsl(var(--sofya-popover-foreground))]",
|
|
3461
|
-
size: "h4"
|
|
3462
|
-
style: {
|
|
3463
|
-
fontWeight: 600,
|
|
3464
|
-
lineHeight: "24px",
|
|
3465
|
-
letterSpacing: "-0.025em"
|
|
3466
|
-
}
|
|
3385
|
+
size: "h4"
|
|
3467
3386
|
})
|
|
3468
3387
|
}
|
|
3469
3388
|
);
|
|
@@ -3480,10 +3399,7 @@ var PopoverDescription = React17.forwardRef(function PopoverDescription2({ child
|
|
|
3480
3399
|
children: renderTextContent(children, {
|
|
3481
3400
|
as: "span",
|
|
3482
3401
|
className: "block text-muted-foreground",
|
|
3483
|
-
size: "body"
|
|
3484
|
-
style: {
|
|
3485
|
-
lineHeight: "24px"
|
|
3486
|
-
}
|
|
3402
|
+
size: "body"
|
|
3487
3403
|
})
|
|
3488
3404
|
}
|
|
3489
3405
|
);
|
|
@@ -3626,12 +3542,7 @@ var RadioGroupItem = React19.forwardRef(function RadioGroupItem2({
|
|
|
3626
3542
|
children: renderTextContent(label, {
|
|
3627
3543
|
as: "span",
|
|
3628
3544
|
className: "text-[color:var(--sofya-text-default)]",
|
|
3629
|
-
size: "
|
|
3630
|
-
style: {
|
|
3631
|
-
fontWeight: 400,
|
|
3632
|
-
lineHeight: "22px",
|
|
3633
|
-
letterSpacing: "-0.02em"
|
|
3634
|
-
}
|
|
3545
|
+
size: "body"
|
|
3635
3546
|
})
|
|
3636
3547
|
}
|
|
3637
3548
|
) : null,
|
|
@@ -3643,10 +3554,7 @@ var RadioGroupItem = React19.forwardRef(function RadioGroupItem2({
|
|
|
3643
3554
|
children: renderTextContent(description, {
|
|
3644
3555
|
as: "span",
|
|
3645
3556
|
className: "text-muted-foreground",
|
|
3646
|
-
size: "body"
|
|
3647
|
-
style: {
|
|
3648
|
-
lineHeight: "20px"
|
|
3649
|
-
}
|
|
3557
|
+
size: "body"
|
|
3650
3558
|
})
|
|
3651
3559
|
}
|
|
3652
3560
|
) : null
|
|
@@ -3732,6 +3640,14 @@ ScrollAreaCorner.displayName = ScrollAreaPrimitive.Corner.displayName;
|
|
|
3732
3640
|
import * as React21 from "react";
|
|
3733
3641
|
import * as SelectPrimitive from "@radix-ui/react-select";
|
|
3734
3642
|
import { jsx as jsx24, jsxs as jsxs14 } from "react/jsx-runtime";
|
|
3643
|
+
var inheritTypographyStyle2 = {
|
|
3644
|
+
color: "inherit",
|
|
3645
|
+
fontFamily: "inherit",
|
|
3646
|
+
fontSize: "inherit",
|
|
3647
|
+
fontWeight: "inherit",
|
|
3648
|
+
letterSpacing: "inherit",
|
|
3649
|
+
lineHeight: "inherit"
|
|
3650
|
+
};
|
|
3735
3651
|
var selectSizeOptions = ["default", "sm"];
|
|
3736
3652
|
var Select = SelectPrimitive.Root;
|
|
3737
3653
|
var SelectGroup = SelectPrimitive.Group;
|
|
@@ -3765,7 +3681,7 @@ var SelectTrigger = React21.forwardRef(function SelectTrigger2({ className, chil
|
|
|
3765
3681
|
"data-slot": "select-trigger",
|
|
3766
3682
|
"data-size": size,
|
|
3767
3683
|
className: cn(
|
|
3768
|
-
"flex w-full items-center justify-between gap-4 rounded-[10px] border border-[color:var(--sofya-border-strong)] bg-card px-4 text-left text-[
|
|
3684
|
+
"flex w-full items-center justify-between gap-4 rounded-[10px] border border-[color:var(--sofya-border-strong)] bg-card px-4 text-left [font-family:var(--sofya-text-body-font-family)] text-[length:var(--sofya-text-body-font-size)] [font-weight:var(--sofya-text-body-font-weight)] leading-[var(--sofya-text-body-line-height)] tracking-[var(--sofya-text-body-letter-spacing)] text-[color:var(--sofya-text-default)] shadow-none transition-[border-color,box-shadow,background-color,color] duration-sofya ease-sofya hover:border-[color:var(--sofya-border-hover)] focus:outline-none focus:ring-2 focus:ring-[color:var(--sofya-focus-ring-soft)] focus:ring-offset-0 active:border-transparent active:ring-2 active:ring-[color:var(--sofya-focus-ring-soft)] disabled:cursor-not-allowed disabled:bg-muted disabled:opacity-50 aria-invalid:border-destructive aria-invalid:focus:ring-destructive/20 data-[placeholder]:text-[color:var(--sofya-text-placeholder)] data-[size=default]:h-10 data-[size=default]:py-2 data-[size=sm]:h-9 data-[size=sm]:px-2 data-[size=sm]:text-[14px] data-[size=sm]:leading-5 [&>span]:line-clamp-1 [&>span]:flex-1",
|
|
3769
3685
|
className
|
|
3770
3686
|
),
|
|
3771
3687
|
...props,
|
|
@@ -3875,7 +3791,7 @@ var SelectItem = React21.forwardRef(function SelectItem2({ className, children,
|
|
|
3875
3791
|
ref,
|
|
3876
3792
|
"data-slot": "select-item",
|
|
3877
3793
|
className: cn(
|
|
3878
|
-
"relative flex min-w-0 cursor-pointer select-none items-center self-stretch rounded-[8px] px-4 py-2 pr-8 text-[
|
|
3794
|
+
"relative flex min-w-0 cursor-pointer select-none items-center self-stretch rounded-[8px] px-4 py-2 pr-8 [font-family:var(--sofya-text-body-font-family)] text-[length:var(--sofya-text-body-font-size)] [font-weight:var(--sofya-text-body-font-weight)] leading-[var(--sofya-text-body-line-height)] tracking-[var(--sofya-text-body-letter-spacing)] text-[color:var(--sofya-text-default)] outline-none transition-colors duration-sofya ease-sofya data-[disabled]:pointer-events-none data-[disabled]:opacity-40 data-[highlighted]:bg-[color:var(--sofya-surface-hover)] data-[highlighted]:text-[color:var(--sofya-text-default)] data-[state=checked]:bg-[color:var(--sofya-surface-selected)]",
|
|
3879
3795
|
className
|
|
3880
3796
|
),
|
|
3881
3797
|
...props,
|
|
@@ -3884,9 +3800,7 @@ var SelectItem = React21.forwardRef(function SelectItem2({ className, children,
|
|
|
3884
3800
|
as: "span",
|
|
3885
3801
|
className: "block truncate text-[color:var(--sofya-text-default)]",
|
|
3886
3802
|
size: "body",
|
|
3887
|
-
style:
|
|
3888
|
-
lineHeight: "20px"
|
|
3889
|
-
}
|
|
3803
|
+
style: inheritTypographyStyle2
|
|
3890
3804
|
}) }),
|
|
3891
3805
|
/* @__PURE__ */ jsx24(SelectPrimitive.ItemIndicator, { asChild: true, children: /* @__PURE__ */ jsx24("span", { className: "absolute right-4 inline-flex h-4 w-4 items-center justify-center text-primary", children: /* @__PURE__ */ jsx24(Icon, { name: "check", size: 14 }) }) })
|
|
3892
3806
|
]
|
|
@@ -4459,7 +4373,7 @@ function Tabs({
|
|
|
4459
4373
|
value: item.value,
|
|
4460
4374
|
disabled: isUnavailable,
|
|
4461
4375
|
className: cn(
|
|
4462
|
-
"relative inline-flex min-h-[76px] shrink-0 items-center justify-center px-8 pb-4 pt-6 text-[
|
|
4376
|
+
"relative inline-flex min-h-[76px] shrink-0 items-center justify-center px-8 pb-4 pt-6 [font-family:var(--sofya-text-h5-font-family)] text-[length:var(--sofya-text-h5-font-size)] [font-weight:var(--sofya-text-h5-font-weight)] leading-[var(--sofya-text-h5-line-height)] tracking-[var(--sofya-text-h5-letter-spacing)] text-[color:var(--sofya-text-subtle)] transition-[color,opacity] duration-sofya ease-sofya focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[color:var(--sofya-focus-ring-soft)] focus-visible:ring-offset-0 disabled:pointer-events-none disabled:text-[color:var(--sofya-text-placeholder)] data-[state=active]:text-primary",
|
|
4463
4377
|
item.loading && "disabled:text-[color:var(--sofya-text-soft)]",
|
|
4464
4378
|
triggerClassName,
|
|
4465
4379
|
item.triggerClassName
|
|
@@ -4486,13 +4400,7 @@ function Tabs({
|
|
|
4486
4400
|
/* @__PURE__ */ jsx31("span", { children: renderTextContent(item.label, {
|
|
4487
4401
|
as: "span",
|
|
4488
4402
|
className: "block text-inherit",
|
|
4489
|
-
size: "
|
|
4490
|
-
style: {
|
|
4491
|
-
fontSize: "18px",
|
|
4492
|
-
fontWeight: 600,
|
|
4493
|
-
lineHeight: "18px",
|
|
4494
|
-
letterSpacing: "-0.01em"
|
|
4495
|
-
}
|
|
4403
|
+
size: "h5"
|
|
4496
4404
|
}) })
|
|
4497
4405
|
] })
|
|
4498
4406
|
]
|
|
@@ -4545,7 +4453,7 @@ var Textarea = React29.forwardRef(
|
|
|
4545
4453
|
"textarea",
|
|
4546
4454
|
{
|
|
4547
4455
|
className: cn(
|
|
4548
|
-
"flex min-h-[120px] w-full resize-y rounded-[10px] border border-[color:var(--sofya-border-strong)] bg-card px-4 py-2 text-[
|
|
4456
|
+
"flex min-h-[120px] w-full resize-y rounded-[10px] border border-[color:var(--sofya-border-strong)] bg-card px-4 py-2 [font-family:var(--sofya-text-body-font-family)] text-[length:var(--sofya-text-body-font-size)] [font-weight:var(--sofya-text-body-font-weight)] leading-[var(--sofya-text-body-line-height)] tracking-[var(--sofya-text-body-letter-spacing)] text-[color:var(--sofya-text-default)] shadow-none transition-[border-color,box-shadow,background-color,color] duration-sofya ease-sofya placeholder:text-[color:var(--sofya-text-placeholder)] hover:border-[color:var(--sofya-border-hover)] focus:border-[color:var(--sofya-border-hover)] focus:outline-none focus:ring-2 focus:ring-[color:var(--sofya-focus-ring-soft)] focus:ring-offset-0 active:border-[color:var(--sofya-border-hover)] disabled:cursor-not-allowed disabled:bg-muted disabled:opacity-50",
|
|
4549
4457
|
className
|
|
4550
4458
|
),
|
|
4551
4459
|
id: resolvedId,
|
|
@@ -4558,7 +4466,7 @@ var Textarea = React29.forwardRef(
|
|
|
4558
4466
|
if (!label && !containerClassName) {
|
|
4559
4467
|
return control;
|
|
4560
4468
|
}
|
|
4561
|
-
return /* @__PURE__ */ jsxs17("div", { className: cn("grid w-full gap-
|
|
4469
|
+
return /* @__PURE__ */ jsxs17("div", { className: cn("grid w-full gap-2", containerClassName), children: [
|
|
4562
4470
|
label ? /* @__PURE__ */ jsx32(
|
|
4563
4471
|
"label",
|
|
4564
4472
|
{
|
|
@@ -4570,11 +4478,9 @@ var Textarea = React29.forwardRef(
|
|
|
4570
4478
|
children: renderTextContent(label, {
|
|
4571
4479
|
as: "span",
|
|
4572
4480
|
className: "block text-[color:var(--sofya-text-default)]",
|
|
4573
|
-
size: "
|
|
4481
|
+
size: "body",
|
|
4574
4482
|
style: {
|
|
4575
|
-
fontWeight: 500
|
|
4576
|
-
lineHeight: "22px",
|
|
4577
|
-
letterSpacing: "-0.02em"
|
|
4483
|
+
fontWeight: 500
|
|
4578
4484
|
}
|
|
4579
4485
|
})
|
|
4580
4486
|
}
|
|
@@ -4608,9 +4514,7 @@ var TooltipContent = React30.forwardRef(function TooltipContent2({ className, si
|
|
|
4608
4514
|
className: "block text-[color:var(--sofya-tooltip-foreground)]",
|
|
4609
4515
|
size: "tiny",
|
|
4610
4516
|
style: {
|
|
4611
|
-
fontWeight: 500
|
|
4612
|
-
lineHeight: "16px",
|
|
4613
|
-
letterSpacing: "0.01em"
|
|
4517
|
+
fontWeight: 500
|
|
4614
4518
|
}
|
|
4615
4519
|
})
|
|
4616
4520
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sofya-ds/react",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.3",
|
|
4
4
|
"description": "Sofya React design system with official brand tokens, provider and UI components.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.cjs",
|
|
@@ -58,7 +58,7 @@
|
|
|
58
58
|
"motion": "^12.38.0",
|
|
59
59
|
"sonner": "^2.0.7",
|
|
60
60
|
"tailwind-merge": "^3.5.0",
|
|
61
|
-
"@sofya-ds/tokens": "1.1.
|
|
61
|
+
"@sofya-ds/tokens": "1.1.3"
|
|
62
62
|
},
|
|
63
63
|
"devDependencies": {
|
|
64
64
|
"@testing-library/jest-dom": "^6.9.1",
|