@xjur-ui/react 1.0.3 → 1.0.4
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/.turbo/turbo-build.log +20 -14
- package/CHANGELOG.md +13 -0
- package/dist/components/date-picker.js +1 -1
- package/dist/components/divider.js +2 -1
- package/dist/components/dropdown-menu.js +3 -2
- package/dist/components/icon.d.ts +1 -1
- package/dist/components/icon.js +5 -1
- package/dist/components/input.js +1 -1
- package/dist/components/otp-input.js +1 -1
- package/dist/components/rich-editor.d.ts +25 -0
- package/dist/components/rich-editor.js +723 -0
- package/dist/components/search-input.js +1 -1
- package/dist/components/select.js +2 -2
- package/dist/components/skeleton.d.ts +6 -0
- package/dist/components/skeleton.js +16 -0
- package/dist/components/tooltip.d.ts +11 -0
- package/dist/components/tooltip.js +58 -0
- package/dist/index.css +247 -25
- package/package.json +12 -2
- package/src/components/date-picker.tsx +1 -1
- package/src/components/divider.tsx +2 -1
- package/src/components/dropdown-menu.tsx +1 -1
- package/src/components/input.tsx +1 -1
- package/src/components/otp-input.tsx +1 -1
- package/src/components/rich-editor.tsx +371 -0
- package/src/components/search-input.tsx +1 -2
- package/src/components/select.tsx +1 -1
- package/src/components/skeleton.tsx +12 -0
- package/src/components/tooltip.tsx +63 -0
- package/src/hooks/index.ts +1 -0
- package/src/hooks/use-os.ts +32 -0
- package/src/resources/icons.ts +5 -1
|
@@ -201,7 +201,7 @@ function SearchInputContent({
|
|
|
201
201
|
{
|
|
202
202
|
variants: {
|
|
203
203
|
variant: {
|
|
204
|
-
outlined: "rounded-circle focus-within:border-primary-idle
|
|
204
|
+
outlined: "rounded-circle focus-within:border-primary-idle ",
|
|
205
205
|
line: "rounded-none border-t-0 border-b-1 border-x-0",
|
|
206
206
|
action: "rounded-tr-none rounded-br-none border-r-0"
|
|
207
207
|
}
|
|
@@ -285,7 +285,7 @@ function SearchInputContent({
|
|
|
285
285
|
{
|
|
286
286
|
variants: {
|
|
287
287
|
variant: {
|
|
288
|
-
outlined: "rounded-circle focus-within:border-primary-idle
|
|
288
|
+
outlined: "rounded-circle focus-within:border-primary-idle ",
|
|
289
289
|
line: "rounded-none border-t-0 border-b-1 border-x-0",
|
|
290
290
|
action: "rounded-tr-none rounded-br-none border-r-0"
|
|
291
291
|
}
|
|
@@ -349,7 +349,7 @@ function SelectTrigger({
|
|
|
349
349
|
className,
|
|
350
350
|
"group h-large-4x rounded-small-1x gap-small py-small_1x-alt px-small relative flex w-full cursor-pointer items-center",
|
|
351
351
|
"bg-layer-2-idle border-border-layer-2 hover:border-border-layer-3 border",
|
|
352
|
-
"data-[state=open]:border-primary-idle
|
|
352
|
+
"data-[state=open]:border-primary-idle",
|
|
353
353
|
"has-[input:not(:placeholder-shown)]:text-primary-idle",
|
|
354
354
|
"has-[input:not(:placeholder-shown)]:border-primary-idle"
|
|
355
355
|
),
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
// src/components/skeleton.tsx
|
|
2
|
+
import { cx } from "@xjur-ui/util";
|
|
3
|
+
import { jsx } from "react/jsx-runtime";
|
|
4
|
+
function Skeleton({ className, ...props }) {
|
|
5
|
+
return /* @__PURE__ */ jsx(
|
|
6
|
+
"div",
|
|
7
|
+
{
|
|
8
|
+
className: cx("bg-layer-skeleton animate-pulse", className),
|
|
9
|
+
"data-slot": "skeleton",
|
|
10
|
+
...props
|
|
11
|
+
}
|
|
12
|
+
);
|
|
13
|
+
}
|
|
14
|
+
export {
|
|
15
|
+
Skeleton
|
|
16
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as TooltipPrimitive from '@radix-ui/react-tooltip';
|
|
3
|
+
|
|
4
|
+
declare function TooltipProvider({ delayDuration, ...props }: React.ComponentProps<typeof TooltipPrimitive.Provider>): react_jsx_runtime.JSX.Element;
|
|
5
|
+
declare function Tooltip({ ...props }: React.ComponentProps<typeof TooltipPrimitive.Root>): react_jsx_runtime.JSX.Element;
|
|
6
|
+
declare function TooltipTrigger({ ...props }: React.ComponentProps<typeof TooltipPrimitive.Trigger>): react_jsx_runtime.JSX.Element;
|
|
7
|
+
declare function TooltipContent({ className, sideOffset, variant, children, ...props }: React.ComponentProps<typeof TooltipPrimitive.Content> & {
|
|
8
|
+
variant?: 'simple' | 'rich';
|
|
9
|
+
}): react_jsx_runtime.JSX.Element;
|
|
10
|
+
|
|
11
|
+
export { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger };
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
// src/components/tooltip.tsx
|
|
2
|
+
import * as TooltipPrimitive from "@radix-ui/react-tooltip";
|
|
3
|
+
import { cx } from "@xjur-ui/util";
|
|
4
|
+
import { jsx } from "react/jsx-runtime";
|
|
5
|
+
function TooltipProvider({
|
|
6
|
+
delayDuration = 0,
|
|
7
|
+
...props
|
|
8
|
+
}) {
|
|
9
|
+
return /* @__PURE__ */ jsx(
|
|
10
|
+
TooltipPrimitive.Provider,
|
|
11
|
+
{
|
|
12
|
+
"data-slot": "tooltip-provider",
|
|
13
|
+
delayDuration,
|
|
14
|
+
...props
|
|
15
|
+
}
|
|
16
|
+
);
|
|
17
|
+
}
|
|
18
|
+
function Tooltip({
|
|
19
|
+
...props
|
|
20
|
+
}) {
|
|
21
|
+
return /* @__PURE__ */ jsx(TooltipProvider, { children: /* @__PURE__ */ jsx(TooltipPrimitive.Root, { "data-slot": "tooltip", ...props }) });
|
|
22
|
+
}
|
|
23
|
+
function TooltipTrigger({
|
|
24
|
+
...props
|
|
25
|
+
}) {
|
|
26
|
+
return /* @__PURE__ */ jsx(TooltipPrimitive.Trigger, { "data-slot": "tooltip-trigger", ...props });
|
|
27
|
+
}
|
|
28
|
+
function TooltipContent({
|
|
29
|
+
className,
|
|
30
|
+
sideOffset = 1,
|
|
31
|
+
variant = "simple",
|
|
32
|
+
children,
|
|
33
|
+
...props
|
|
34
|
+
}) {
|
|
35
|
+
return /* @__PURE__ */ jsx(TooltipPrimitive.Portal, { children: /* @__PURE__ */ jsx(
|
|
36
|
+
TooltipPrimitive.Content,
|
|
37
|
+
{
|
|
38
|
+
className: cx(
|
|
39
|
+
"text-size-body-sm text-balance",
|
|
40
|
+
"data-[variant=simple]:bg-alt-2 data-[variant=simple]:text-neutral-label data-[variant=simple]:rounded-small-1x data-[variant=simple]:px-small data-[variant=simple]:py-small-1x",
|
|
41
|
+
"data-[variant=rich]:bg-layer-2-idle data-[variant=rich]:text-neutral-dark data-[variant=rich]:rounded-small data-[variant=rich]:border-border-layer-2 data-[variant=rich]:p-large data-[variant=rich]:border",
|
|
42
|
+
"animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 w-fit origin-(--radix-tooltip-content-transform-origin)",
|
|
43
|
+
className
|
|
44
|
+
),
|
|
45
|
+
"data-slot": "tooltip-content",
|
|
46
|
+
"data-variant": variant,
|
|
47
|
+
sideOffset,
|
|
48
|
+
...props,
|
|
49
|
+
children
|
|
50
|
+
}
|
|
51
|
+
) });
|
|
52
|
+
}
|
|
53
|
+
export {
|
|
54
|
+
Tooltip,
|
|
55
|
+
TooltipContent,
|
|
56
|
+
TooltipProvider,
|
|
57
|
+
TooltipTrigger
|
|
58
|
+
};
|
package/dist/index.css
CHANGED
|
@@ -37,6 +37,7 @@
|
|
|
37
37
|
--ease-in: cubic-bezier(0.4, 0, 1, 1);
|
|
38
38
|
--ease-out: cubic-bezier(0, 0, 0.2, 1);
|
|
39
39
|
--ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
|
|
40
|
+
--animate-pulse: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
|
|
40
41
|
--default-transition-duration: 150ms;
|
|
41
42
|
--default-transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
|
42
43
|
--default-font-family: var(--font-sans);
|
|
@@ -88,7 +89,9 @@
|
|
|
88
89
|
--color-layer-2-hover: #F8F8FA;
|
|
89
90
|
--color-layer-2-pressed: #F0F0F2;
|
|
90
91
|
--color-layer-2-active: #E7E7EB;
|
|
92
|
+
--color-layer-skeleton: #E5E7EB;
|
|
91
93
|
--color-alt-1: #17171A;
|
|
94
|
+
--color-alt-2: #3D3D47;
|
|
92
95
|
--color-alt-4: #9C9CAD;
|
|
93
96
|
--color-border-layer-1: #D6D6DC;
|
|
94
97
|
--color-border-layer-2: #DEDEE3;
|
|
@@ -490,12 +493,18 @@
|
|
|
490
493
|
.h-large-8x {
|
|
491
494
|
height: var(--spacing-large-8x);
|
|
492
495
|
}
|
|
496
|
+
.max-h-\[116px\] {
|
|
497
|
+
max-height: 116px;
|
|
498
|
+
}
|
|
493
499
|
.max-h-\[400px\] {
|
|
494
500
|
max-height: 400px;
|
|
495
501
|
}
|
|
496
502
|
.max-h-\[var\(--radix-popover-content-available-height\)\] {
|
|
497
503
|
max-height: var(--radix-popover-content-available-height);
|
|
498
504
|
}
|
|
505
|
+
.min-h-\[116px\] {
|
|
506
|
+
min-height: 116px;
|
|
507
|
+
}
|
|
499
508
|
.w-3\/4 {
|
|
500
509
|
width: calc(3/4 * 100%);
|
|
501
510
|
}
|
|
@@ -523,9 +532,6 @@
|
|
|
523
532
|
.max-w-full {
|
|
524
533
|
max-width: 100%;
|
|
525
534
|
}
|
|
526
|
-
.min-w-\[240px\] {
|
|
527
|
-
min-width: 240px;
|
|
528
|
-
}
|
|
529
535
|
.min-w-\[var\(--radix-popover-trigger-width\)\] {
|
|
530
536
|
min-width: var(--radix-popover-trigger-width);
|
|
531
537
|
}
|
|
@@ -538,6 +544,9 @@
|
|
|
538
544
|
.caption-bottom {
|
|
539
545
|
caption-side: bottom;
|
|
540
546
|
}
|
|
547
|
+
.origin-\(--radix-tooltip-content-transform-origin\) {
|
|
548
|
+
transform-origin: var(--radix-tooltip-content-transform-origin);
|
|
549
|
+
}
|
|
541
550
|
.-translate-y-1\/2 {
|
|
542
551
|
--tw-translate-y: calc(calc(1/2 * 100%) * -1);
|
|
543
552
|
translate: var(--tw-translate-x) var(--tw-translate-y);
|
|
@@ -545,15 +554,30 @@
|
|
|
545
554
|
.animate-in {
|
|
546
555
|
animation: enter var(--tw-animation-duration,var(--tw-duration,.15s))var(--tw-ease,ease)var(--tw-animation-delay,0s)var(--tw-animation-iteration-count,1)var(--tw-animation-direction,normal)var(--tw-animation-fill-mode,none);
|
|
547
556
|
}
|
|
557
|
+
.animate-pulse {
|
|
558
|
+
animation: var(--animate-pulse);
|
|
559
|
+
}
|
|
548
560
|
.cursor-pointer {
|
|
549
561
|
cursor: pointer;
|
|
550
562
|
}
|
|
563
|
+
.list-outside {
|
|
564
|
+
list-style-position: outside;
|
|
565
|
+
}
|
|
566
|
+
.list-decimal {
|
|
567
|
+
list-style-type: decimal;
|
|
568
|
+
}
|
|
569
|
+
.list-disc {
|
|
570
|
+
list-style-type: disc;
|
|
571
|
+
}
|
|
551
572
|
.list-none {
|
|
552
573
|
list-style-type: none;
|
|
553
574
|
}
|
|
554
575
|
.flex-col {
|
|
555
576
|
flex-direction: column;
|
|
556
577
|
}
|
|
578
|
+
.flex-nowrap {
|
|
579
|
+
flex-wrap: nowrap;
|
|
580
|
+
}
|
|
557
581
|
.items-center {
|
|
558
582
|
align-items: center;
|
|
559
583
|
}
|
|
@@ -590,9 +614,18 @@
|
|
|
590
614
|
.overflow-hidden {
|
|
591
615
|
overflow: hidden;
|
|
592
616
|
}
|
|
617
|
+
.overflow-x-auto {
|
|
618
|
+
overflow-x: auto;
|
|
619
|
+
}
|
|
620
|
+
.overflow-x-hidden {
|
|
621
|
+
overflow-x: hidden;
|
|
622
|
+
}
|
|
593
623
|
.overflow-y-auto {
|
|
594
624
|
overflow-y: auto;
|
|
595
625
|
}
|
|
626
|
+
.overflow-y-hidden {
|
|
627
|
+
overflow-y: hidden;
|
|
628
|
+
}
|
|
596
629
|
.rounded-\[6px\] {
|
|
597
630
|
border-radius: 6px;
|
|
598
631
|
}
|
|
@@ -729,6 +762,9 @@
|
|
|
729
762
|
.bg-layer-2-idle {
|
|
730
763
|
background-color: var(--color-layer-2-idle);
|
|
731
764
|
}
|
|
765
|
+
.bg-layer-skeleton {
|
|
766
|
+
background-color: var(--color-layer-skeleton);
|
|
767
|
+
}
|
|
732
768
|
.bg-primary-alt-active {
|
|
733
769
|
background-color: var(--color-primary-alt-active);
|
|
734
770
|
}
|
|
@@ -798,6 +834,9 @@
|
|
|
798
834
|
.pr-large-3x {
|
|
799
835
|
padding-right: var(--spacing-large-3x);
|
|
800
836
|
}
|
|
837
|
+
.pl-large-1x {
|
|
838
|
+
padding-left: var(--spacing-large-1x);
|
|
839
|
+
}
|
|
801
840
|
.text-center {
|
|
802
841
|
text-align: center;
|
|
803
842
|
}
|
|
@@ -906,6 +945,9 @@
|
|
|
906
945
|
--tw-font-weight: var(--font-weight-thin);
|
|
907
946
|
font-weight: var(--font-weight-thin);
|
|
908
947
|
}
|
|
948
|
+
.text-balance {
|
|
949
|
+
text-wrap: balance;
|
|
950
|
+
}
|
|
909
951
|
.whitespace-nowrap {
|
|
910
952
|
white-space: nowrap;
|
|
911
953
|
}
|
|
@@ -942,6 +984,12 @@
|
|
|
942
984
|
.text-white {
|
|
943
985
|
color: var(--color-white);
|
|
944
986
|
}
|
|
987
|
+
.italic {
|
|
988
|
+
font-style: italic;
|
|
989
|
+
}
|
|
990
|
+
.underline {
|
|
991
|
+
text-decoration-line: underline;
|
|
992
|
+
}
|
|
945
993
|
.opacity-60 {
|
|
946
994
|
opacity: 60%;
|
|
947
995
|
}
|
|
@@ -1074,13 +1122,37 @@
|
|
|
1074
1122
|
--tw-ease: var(--ease-out);
|
|
1075
1123
|
transition-timing-function: var(--ease-out);
|
|
1076
1124
|
}
|
|
1125
|
+
.fade-in-0 {
|
|
1126
|
+
--tw-enter-opacity: calc(0/100);
|
|
1127
|
+
--tw-enter-opacity: 0;
|
|
1128
|
+
}
|
|
1077
1129
|
.outline-none {
|
|
1078
1130
|
--tw-outline-style: none;
|
|
1079
1131
|
outline-style: none;
|
|
1080
1132
|
}
|
|
1133
|
+
.zoom-in-95 {
|
|
1134
|
+
--tw-enter-scale: calc(95*1%);
|
|
1135
|
+
--tw-enter-scale: .95;
|
|
1136
|
+
}
|
|
1081
1137
|
.fade-in {
|
|
1082
1138
|
--tw-enter-opacity: 0;
|
|
1083
1139
|
}
|
|
1140
|
+
.\*\:h-full {
|
|
1141
|
+
:is(& > *) {
|
|
1142
|
+
height: 100%;
|
|
1143
|
+
}
|
|
1144
|
+
}
|
|
1145
|
+
.\*\:w-full {
|
|
1146
|
+
:is(& > *) {
|
|
1147
|
+
width: 100%;
|
|
1148
|
+
}
|
|
1149
|
+
}
|
|
1150
|
+
.\*\:outline-0 {
|
|
1151
|
+
:is(& > *) {
|
|
1152
|
+
outline-style: var(--tw-outline-style);
|
|
1153
|
+
outline-width: 0px;
|
|
1154
|
+
}
|
|
1155
|
+
}
|
|
1084
1156
|
.group-focus-within\:-top-\[3px\] {
|
|
1085
1157
|
&:is(:where(.group):focus-within *) {
|
|
1086
1158
|
top: calc(3px * -1);
|
|
@@ -1409,6 +1481,62 @@
|
|
|
1409
1481
|
}
|
|
1410
1482
|
}
|
|
1411
1483
|
}
|
|
1484
|
+
.before\:absolute {
|
|
1485
|
+
&::before {
|
|
1486
|
+
content: var(--tw-content);
|
|
1487
|
+
position: absolute;
|
|
1488
|
+
}
|
|
1489
|
+
}
|
|
1490
|
+
.before\:top-0 {
|
|
1491
|
+
&::before {
|
|
1492
|
+
content: var(--tw-content);
|
|
1493
|
+
top: calc(var(--spacing) * 0);
|
|
1494
|
+
}
|
|
1495
|
+
}
|
|
1496
|
+
.before\:left-0 {
|
|
1497
|
+
&::before {
|
|
1498
|
+
content: var(--tw-content);
|
|
1499
|
+
left: calc(var(--spacing) * 0);
|
|
1500
|
+
}
|
|
1501
|
+
}
|
|
1502
|
+
.before\:text-neutral-placeholder {
|
|
1503
|
+
&::before {
|
|
1504
|
+
content: var(--tw-content);
|
|
1505
|
+
color: var(--color-neutral-placeholder);
|
|
1506
|
+
}
|
|
1507
|
+
}
|
|
1508
|
+
.before\:content-\[attr\(data-placeholder\)\] {
|
|
1509
|
+
&::before {
|
|
1510
|
+
content: var(--tw-content);
|
|
1511
|
+
--tw-content: attr(data-placeholder);
|
|
1512
|
+
content: var(--tw-content);
|
|
1513
|
+
}
|
|
1514
|
+
}
|
|
1515
|
+
.first\:before\:pointer-events-none {
|
|
1516
|
+
&:first-child {
|
|
1517
|
+
&::before {
|
|
1518
|
+
content: var(--tw-content);
|
|
1519
|
+
pointer-events: none;
|
|
1520
|
+
}
|
|
1521
|
+
}
|
|
1522
|
+
}
|
|
1523
|
+
.first\:before\:float-left {
|
|
1524
|
+
&:first-child {
|
|
1525
|
+
&::before {
|
|
1526
|
+
content: var(--tw-content);
|
|
1527
|
+
float: left;
|
|
1528
|
+
}
|
|
1529
|
+
}
|
|
1530
|
+
}
|
|
1531
|
+
.first\:before\:content-\[attr\(data-placeholder\)\] {
|
|
1532
|
+
&:first-child {
|
|
1533
|
+
&::before {
|
|
1534
|
+
content: var(--tw-content);
|
|
1535
|
+
--tw-content: attr(data-placeholder);
|
|
1536
|
+
content: var(--tw-content);
|
|
1537
|
+
}
|
|
1538
|
+
}
|
|
1539
|
+
}
|
|
1412
1540
|
.focus-within\:border {
|
|
1413
1541
|
&:focus-within {
|
|
1414
1542
|
border-style: var(--tw-border-style);
|
|
@@ -1420,17 +1548,6 @@
|
|
|
1420
1548
|
border-color: var(--color-primary-idle);
|
|
1421
1549
|
}
|
|
1422
1550
|
}
|
|
1423
|
-
.focus-within\:shadow-focus-primary {
|
|
1424
|
-
&:focus-within {
|
|
1425
|
-
--tw-shadow: 0 0 0 var(--tw-shadow-color, var(--shadow-medium, 4px)) rgba(232, 125, 48, 0.16);
|
|
1426
|
-
box-shadow:
|
|
1427
|
-
var(--tw-inset-shadow),
|
|
1428
|
-
var(--tw-inset-ring-shadow),
|
|
1429
|
-
var(--tw-ring-offset-shadow),
|
|
1430
|
-
var(--tw-ring-shadow),
|
|
1431
|
-
var(--tw-shadow);
|
|
1432
|
-
}
|
|
1433
|
-
}
|
|
1434
1551
|
.hover\:overflow-x-auto {
|
|
1435
1552
|
&:hover {
|
|
1436
1553
|
@media (hover: hover) {
|
|
@@ -1438,6 +1555,13 @@
|
|
|
1438
1555
|
}
|
|
1439
1556
|
}
|
|
1440
1557
|
}
|
|
1558
|
+
.hover\:border-border-layer-2 {
|
|
1559
|
+
&:hover {
|
|
1560
|
+
@media (hover: hover) {
|
|
1561
|
+
border-color: var(--color-border-layer-2);
|
|
1562
|
+
}
|
|
1563
|
+
}
|
|
1564
|
+
}
|
|
1441
1565
|
.hover\:border-border-layer-3 {
|
|
1442
1566
|
&:hover {
|
|
1443
1567
|
@media (hover: hover) {
|
|
@@ -1696,6 +1820,26 @@
|
|
|
1696
1820
|
background-color: var(--color-primary-alt-active);
|
|
1697
1821
|
}
|
|
1698
1822
|
}
|
|
1823
|
+
.data-\[side\=bottom\]\:slide-in-from-top-2 {
|
|
1824
|
+
&[data-side=bottom] {
|
|
1825
|
+
--tw-enter-translate-y: calc(2*var(--spacing)*-1);
|
|
1826
|
+
}
|
|
1827
|
+
}
|
|
1828
|
+
.data-\[side\=left\]\:slide-in-from-right-2 {
|
|
1829
|
+
&[data-side=left] {
|
|
1830
|
+
--tw-enter-translate-x: calc(2*var(--spacing));
|
|
1831
|
+
}
|
|
1832
|
+
}
|
|
1833
|
+
.data-\[side\=right\]\:slide-in-from-left-2 {
|
|
1834
|
+
&[data-side=right] {
|
|
1835
|
+
--tw-enter-translate-x: calc(2*var(--spacing)*-1);
|
|
1836
|
+
}
|
|
1837
|
+
}
|
|
1838
|
+
.data-\[side\=top\]\:slide-in-from-bottom-2 {
|
|
1839
|
+
&[data-side=top] {
|
|
1840
|
+
--tw-enter-translate-y: calc(2*var(--spacing));
|
|
1841
|
+
}
|
|
1842
|
+
}
|
|
1699
1843
|
.data-\[size\=lg\]\:size-large-8x {
|
|
1700
1844
|
&[data-size=lg] {
|
|
1701
1845
|
width: var(--spacing-large-8x);
|
|
@@ -1842,6 +1986,12 @@
|
|
|
1842
1986
|
--tw-exit-opacity: 0;
|
|
1843
1987
|
}
|
|
1844
1988
|
}
|
|
1989
|
+
.data-\[state\=closed\]\:zoom-out-95 {
|
|
1990
|
+
&[data-state=closed] {
|
|
1991
|
+
--tw-exit-scale: calc(95*1%);
|
|
1992
|
+
--tw-exit-scale: .95;
|
|
1993
|
+
}
|
|
1994
|
+
}
|
|
1845
1995
|
.data-\[state\=closed\]\:slide-out-to-bottom {
|
|
1846
1996
|
&[data-state=closed] {
|
|
1847
1997
|
--tw-exit-translate-y: 100%;
|
|
@@ -1877,17 +2027,6 @@
|
|
|
1877
2027
|
border-color: var(--color-primary-idle);
|
|
1878
2028
|
}
|
|
1879
2029
|
}
|
|
1880
|
-
.data-\[state\=open\]\:shadow-focus-primary {
|
|
1881
|
-
&[data-state=open] {
|
|
1882
|
-
--tw-shadow: 0 0 0 var(--tw-shadow-color, var(--shadow-medium, 4px)) rgba(232, 125, 48, 0.16);
|
|
1883
|
-
box-shadow:
|
|
1884
|
-
var(--tw-inset-shadow),
|
|
1885
|
-
var(--tw-inset-ring-shadow),
|
|
1886
|
-
var(--tw-ring-offset-shadow),
|
|
1887
|
-
var(--tw-ring-shadow),
|
|
1888
|
-
var(--tw-shadow);
|
|
1889
|
-
}
|
|
1890
|
-
}
|
|
1891
2030
|
.data-\[state\=open\]\:duration-500 {
|
|
1892
2031
|
&[data-state=open] {
|
|
1893
2032
|
--tw-duration: 500ms;
|
|
@@ -1938,11 +2077,77 @@
|
|
|
1938
2077
|
}
|
|
1939
2078
|
}
|
|
1940
2079
|
}
|
|
2080
|
+
.data-\[variant\=rich\]\:rounded-small {
|
|
2081
|
+
&[data-variant=rich] {
|
|
2082
|
+
border-radius: var(--radius-small);
|
|
2083
|
+
}
|
|
2084
|
+
}
|
|
2085
|
+
.data-\[variant\=rich\]\:border {
|
|
2086
|
+
&[data-variant=rich] {
|
|
2087
|
+
border-style: var(--tw-border-style);
|
|
2088
|
+
border-width: 1px;
|
|
2089
|
+
}
|
|
2090
|
+
}
|
|
2091
|
+
.data-\[variant\=rich\]\:border-border-layer-2 {
|
|
2092
|
+
&[data-variant=rich] {
|
|
2093
|
+
border-color: var(--color-border-layer-2);
|
|
2094
|
+
}
|
|
2095
|
+
}
|
|
2096
|
+
.data-\[variant\=rich\]\:bg-layer-2-idle {
|
|
2097
|
+
&[data-variant=rich] {
|
|
2098
|
+
background-color: var(--color-layer-2-idle);
|
|
2099
|
+
}
|
|
2100
|
+
}
|
|
2101
|
+
.data-\[variant\=rich\]\:p-large {
|
|
2102
|
+
&[data-variant=rich] {
|
|
2103
|
+
padding: var(--spacing-large);
|
|
2104
|
+
}
|
|
2105
|
+
}
|
|
2106
|
+
.data-\[variant\=rich\]\:text-neutral-dark {
|
|
2107
|
+
&[data-variant=rich] {
|
|
2108
|
+
color: var(--color-neutral-dark);
|
|
2109
|
+
}
|
|
2110
|
+
}
|
|
2111
|
+
.data-\[variant\=simple\]\:rounded-small-1x {
|
|
2112
|
+
&[data-variant=simple] {
|
|
2113
|
+
border-radius: var(--radius-small-1x);
|
|
2114
|
+
}
|
|
2115
|
+
}
|
|
2116
|
+
.data-\[variant\=simple\]\:bg-alt-2 {
|
|
2117
|
+
&[data-variant=simple] {
|
|
2118
|
+
background-color: var(--color-alt-2);
|
|
2119
|
+
}
|
|
2120
|
+
}
|
|
2121
|
+
.data-\[variant\=simple\]\:px-small {
|
|
2122
|
+
&[data-variant=simple] {
|
|
2123
|
+
padding-inline: var(--spacing-small);
|
|
2124
|
+
}
|
|
2125
|
+
}
|
|
2126
|
+
.data-\[variant\=simple\]\:py-small-1x {
|
|
2127
|
+
&[data-variant=simple] {
|
|
2128
|
+
padding-block: var(--spacing-small-1x);
|
|
2129
|
+
}
|
|
2130
|
+
}
|
|
2131
|
+
.data-\[variant\=simple\]\:text-neutral-label {
|
|
2132
|
+
&[data-variant=simple] {
|
|
2133
|
+
color: var(--color-neutral-label);
|
|
2134
|
+
}
|
|
2135
|
+
}
|
|
1941
2136
|
.sm\:max-w-sm {
|
|
1942
2137
|
@media (width >= 40rem) {
|
|
1943
2138
|
max-width: var(--container-sm);
|
|
1944
2139
|
}
|
|
1945
2140
|
}
|
|
2141
|
+
.\[\&_ol_ol\]\:list-\[lower-alpha\] {
|
|
2142
|
+
& ol ol {
|
|
2143
|
+
list-style-type: lower-alpha;
|
|
2144
|
+
}
|
|
2145
|
+
}
|
|
2146
|
+
.\[\&_ol_ol_ol\]\:list-\[lower-roman\] {
|
|
2147
|
+
& ol ol ol {
|
|
2148
|
+
list-style-type: lower-roman;
|
|
2149
|
+
}
|
|
2150
|
+
}
|
|
1946
2151
|
.\[\&_tr\]\:border-b {
|
|
1947
2152
|
& tr {
|
|
1948
2153
|
border-bottom-style: var(--tw-border-style);
|
|
@@ -1960,6 +2165,16 @@
|
|
|
1960
2165
|
border-width: 0px;
|
|
1961
2166
|
}
|
|
1962
2167
|
}
|
|
2168
|
+
.\[\&_ul_ul\]\:list-\[circle\] {
|
|
2169
|
+
& ul ul {
|
|
2170
|
+
list-style-type: circle;
|
|
2171
|
+
}
|
|
2172
|
+
}
|
|
2173
|
+
.\[\&_ul_ul_ul\]\:list-\[square\] {
|
|
2174
|
+
& ul ul ul {
|
|
2175
|
+
list-style-type: square;
|
|
2176
|
+
}
|
|
2177
|
+
}
|
|
1963
2178
|
.\[\&\>tr\]\:last\:border-b-0 {
|
|
1964
2179
|
& > tr {
|
|
1965
2180
|
&:last-child {
|
|
@@ -2015,6 +2230,12 @@
|
|
|
2015
2230
|
@property --tw-outline-style { syntax: "*"; inherits: false; initial-value: solid; }
|
|
2016
2231
|
@property --tw-duration { syntax: "*"; inherits: false; }
|
|
2017
2232
|
@property --tw-ease { syntax: "*"; inherits: false; }
|
|
2233
|
+
@property --tw-content { syntax: "*"; initial-value: ""; inherits: false; }
|
|
2234
|
+
@keyframes pulse {
|
|
2235
|
+
50% {
|
|
2236
|
+
opacity: 0.5;
|
|
2237
|
+
}
|
|
2238
|
+
}
|
|
2018
2239
|
@keyframes enter {
|
|
2019
2240
|
from {
|
|
2020
2241
|
opacity: var(--tw-enter-opacity,1);
|
|
@@ -2074,6 +2295,7 @@
|
|
|
2074
2295
|
--tw-outline-style: solid;
|
|
2075
2296
|
--tw-duration: initial;
|
|
2076
2297
|
--tw-ease: initial;
|
|
2298
|
+
--tw-content: "";
|
|
2077
2299
|
--tw-animation-delay: 0s;
|
|
2078
2300
|
--tw-animation-direction: normal;
|
|
2079
2301
|
--tw-animation-duration: initial;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xjur-ui/react",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.4",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "React components for XJur Design System",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
"types": "dist/index.d.ts",
|
|
9
9
|
"exports": {
|
|
10
10
|
"./index.css": "./dist/index.css",
|
|
11
|
+
"./hooks": "./dist/hooks/index.js",
|
|
11
12
|
"./button": "./dist/components/button.js",
|
|
12
13
|
"./icon": "./dist/components/icon.js",
|
|
13
14
|
"./typography": "./dist/components/typography.js",
|
|
@@ -32,7 +33,10 @@
|
|
|
32
33
|
"./sheet": "./dist/components/sheet.js",
|
|
33
34
|
"./badge": "./dist/components/badge.js",
|
|
34
35
|
"./table": "./dist/components/table.js",
|
|
35
|
-
"./avatar-group": "./dist/components/avatar-group.js"
|
|
36
|
+
"./avatar-group": "./dist/components/avatar-group.js",
|
|
37
|
+
"./skeleton": "./dist/components/skeleton.js",
|
|
38
|
+
"./rich-editor": "./dist/components/rich-editor.js",
|
|
39
|
+
"./tooltip": "./dist/components/tooltip.js"
|
|
36
40
|
},
|
|
37
41
|
"dependencies": {
|
|
38
42
|
"@radix-ui/react-avatar": "^1.1.10",
|
|
@@ -48,8 +52,14 @@
|
|
|
48
52
|
"@radix-ui/react-slot": "^1.2.3",
|
|
49
53
|
"@radix-ui/react-switch": "^1.2.6",
|
|
50
54
|
"@radix-ui/react-tabs": "^1.1.13",
|
|
55
|
+
"@radix-ui/react-tooltip": "^1.2.8",
|
|
51
56
|
"@react-input/mask": "^2.0.4",
|
|
52
57
|
"@react-input/number-format": "^2.0.3",
|
|
58
|
+
"@tiptap/extension-heading": "^3.3.0",
|
|
59
|
+
"@tiptap/extensions": "^3.3.0",
|
|
60
|
+
"@tiptap/pm": "^3.3.0",
|
|
61
|
+
"@tiptap/react": "^3.3.0",
|
|
62
|
+
"@tiptap/starter-kit": "^3.3.0",
|
|
53
63
|
"@xjur-ui/styles": "*",
|
|
54
64
|
"@xjur-ui/util": "*",
|
|
55
65
|
"react-day-picker": "^9.9.0",
|
|
@@ -19,7 +19,7 @@ export function DatePickerTrigger({
|
|
|
19
19
|
className,
|
|
20
20
|
'group h-large-4x rounded-small-1x gap-small py-small_1x-alt px-small relative flex w-full cursor-pointer items-center',
|
|
21
21
|
'bg-layer-2-idle border-border-layer-2 hover:border-border-layer-3 border',
|
|
22
|
-
'data-[state=open]:border-primary-idle
|
|
22
|
+
'data-[state=open]:border-primary-idle',
|
|
23
23
|
'has-[input:not(:placeholder-shown)]:text-primary-idle',
|
|
24
24
|
'has-[input:not(:placeholder-shown)]:border-primary-idle'
|
|
25
25
|
)}
|
|
@@ -11,7 +11,8 @@ export function Divider({
|
|
|
11
11
|
return (
|
|
12
12
|
<SeparatorPrimitive.Root
|
|
13
13
|
className={cx(
|
|
14
|
-
'bg-border-layer-2 shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full
|
|
14
|
+
'bg-border-layer-2 shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full',
|
|
15
|
+
'data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px',
|
|
15
16
|
className
|
|
16
17
|
)}
|
|
17
18
|
data-slot="separator"
|
|
@@ -49,7 +49,7 @@ export function DropdownMenuContent({
|
|
|
49
49
|
<DropdownMenuPrimitive.Content
|
|
50
50
|
align={align}
|
|
51
51
|
className={cx(
|
|
52
|
-
'group z-10 max-h-[var(--radix-popover-content-available-height)] max-w-[var(--radix-popover-trigger-width)] min-w-[
|
|
52
|
+
'group z-10 max-h-[var(--radix-popover-content-available-height)] max-w-[var(--radix-popover-trigger-width)] min-w-[var(--radix-popover-trigger-width)]',
|
|
53
53
|
className
|
|
54
54
|
)}
|
|
55
55
|
data-slot="dropdown-menu-content"
|
package/src/components/input.tsx
CHANGED
|
@@ -43,7 +43,7 @@ export function InputContent({ className, ...props }: ComponentProps<'div'>) {
|
|
|
43
43
|
const variants = cva(
|
|
44
44
|
[
|
|
45
45
|
'relative h-large-4x rounded-small-1x gap-small py-small_1x-alt px-small flex items-center w-full',
|
|
46
|
-
'focus-within:border-primary-idle focus-within:
|
|
46
|
+
'focus-within:border-primary-idle focus-within:border',
|
|
47
47
|
'group-has-[div[data-slot=input-right-action-slot]]:rounded-r-none',
|
|
48
48
|
'group-has-[div[data-slot=input-left-action-slot]]:rounded-l-none'
|
|
49
49
|
],
|
|
@@ -25,7 +25,7 @@ function Input({
|
|
|
25
25
|
className={cx(
|
|
26
26
|
className,
|
|
27
27
|
'text-neutral-dark h-large-6x bg-layer-2-hover rounded-small-1x w-full text-center outline-0',
|
|
28
|
-
'focus-within:border-primary-idle focus-within:
|
|
28
|
+
'focus-within:border-primary-idle focus-within:border'
|
|
29
29
|
)}
|
|
30
30
|
{...props}
|
|
31
31
|
/>
|