@sarunyu/system-one 1.1.2 → 1.3.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/index.cjs +160 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +160 -0
- package/dist/index.js.map +1 -1
- package/dist/src/components/layout.d.ts +50 -0
- package/dist/src/components/layout.d.ts.map +1 -0
- package/dist/src/index.d.ts +2 -0
- package/dist/src/index.d.ts.map +1 -1
- package/dist/style.css +1 -1
- package/llms.txt +24 -146
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -396,6 +396,160 @@ const Card = React.forwardRef(function Card2({
|
|
|
396
396
|
);
|
|
397
397
|
});
|
|
398
398
|
Card.displayName = "Card";
|
|
399
|
+
const pageWidthClass = {
|
|
400
|
+
sm: "max-w-[640px]",
|
|
401
|
+
md: "max-w-[960px]",
|
|
402
|
+
lg: "max-w-[1200px]",
|
|
403
|
+
xl: "max-w-[1440px]",
|
|
404
|
+
full: "max-w-none"
|
|
405
|
+
};
|
|
406
|
+
const Page = React.forwardRef(function Page2({ width = "lg", className, children, ...rest }, ref) {
|
|
407
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
408
|
+
"main",
|
|
409
|
+
{
|
|
410
|
+
ref,
|
|
411
|
+
className: cn(
|
|
412
|
+
"mx-auto w-full px-6 md:px-8 py-10 flex flex-col gap-12",
|
|
413
|
+
pageWidthClass[width],
|
|
414
|
+
className
|
|
415
|
+
),
|
|
416
|
+
...rest,
|
|
417
|
+
children
|
|
418
|
+
}
|
|
419
|
+
);
|
|
420
|
+
});
|
|
421
|
+
const PageHeader = React.forwardRef(
|
|
422
|
+
function PageHeader2({ title, description, actions, eyebrow, className, ...rest }, ref) {
|
|
423
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
424
|
+
"header",
|
|
425
|
+
{
|
|
426
|
+
ref,
|
|
427
|
+
className: cn(
|
|
428
|
+
"flex flex-col gap-4 sm:flex-row sm:items-start sm:justify-between",
|
|
429
|
+
className
|
|
430
|
+
),
|
|
431
|
+
...rest,
|
|
432
|
+
children: [
|
|
433
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-2 min-w-0", children: [
|
|
434
|
+
eyebrow && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-wrap items-center gap-2", children: eyebrow }),
|
|
435
|
+
/* @__PURE__ */ jsxRuntime.jsx("h1", { children: title }),
|
|
436
|
+
description && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground max-w-[720px]", children: description })
|
|
437
|
+
] }),
|
|
438
|
+
actions && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-wrap items-center gap-3 shrink-0", children: actions })
|
|
439
|
+
]
|
|
440
|
+
}
|
|
441
|
+
);
|
|
442
|
+
}
|
|
443
|
+
);
|
|
444
|
+
const Section = React.forwardRef(function Section2({ title, description, actions, className, children, ...rest }, ref) {
|
|
445
|
+
const hasHeader = Boolean(title || description || actions);
|
|
446
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
447
|
+
"section",
|
|
448
|
+
{
|
|
449
|
+
ref,
|
|
450
|
+
className: cn("flex flex-col gap-6", className),
|
|
451
|
+
...rest,
|
|
452
|
+
children: [
|
|
453
|
+
hasHeader && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-2 sm:flex-row sm:items-start sm:justify-between", children: [
|
|
454
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-1 min-w-0", children: [
|
|
455
|
+
title && /* @__PURE__ */ jsxRuntime.jsx("h2", { children: title }),
|
|
456
|
+
description && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground max-w-[720px]", children: description })
|
|
457
|
+
] }),
|
|
458
|
+
actions && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-wrap items-center gap-3 shrink-0", children: actions })
|
|
459
|
+
] }),
|
|
460
|
+
children
|
|
461
|
+
]
|
|
462
|
+
}
|
|
463
|
+
);
|
|
464
|
+
});
|
|
465
|
+
const Toolbar = React.forwardRef(
|
|
466
|
+
function Toolbar2({ end, className, children, ...rest }, ref) {
|
|
467
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
468
|
+
"div",
|
|
469
|
+
{
|
|
470
|
+
ref,
|
|
471
|
+
className: cn(
|
|
472
|
+
"flex flex-wrap items-center gap-3",
|
|
473
|
+
className
|
|
474
|
+
),
|
|
475
|
+
...rest,
|
|
476
|
+
children: [
|
|
477
|
+
children,
|
|
478
|
+
end && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "ml-auto flex items-center gap-3", children: end })
|
|
479
|
+
]
|
|
480
|
+
}
|
|
481
|
+
);
|
|
482
|
+
}
|
|
483
|
+
);
|
|
484
|
+
const cardGridColsClass = {
|
|
485
|
+
2: "grid-cols-1 sm:grid-cols-2",
|
|
486
|
+
3: "grid-cols-1 sm:grid-cols-2 lg:grid-cols-3",
|
|
487
|
+
4: "grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4"
|
|
488
|
+
};
|
|
489
|
+
const CardGrid = React.forwardRef(
|
|
490
|
+
function CardGrid2({ cols = 3, className, children, ...rest }, ref) {
|
|
491
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
492
|
+
"div",
|
|
493
|
+
{
|
|
494
|
+
ref,
|
|
495
|
+
className: cn("grid gap-6", cardGridColsClass[cols], className),
|
|
496
|
+
...rest,
|
|
497
|
+
children
|
|
498
|
+
}
|
|
499
|
+
);
|
|
500
|
+
}
|
|
501
|
+
);
|
|
502
|
+
const stackGapClass = {
|
|
503
|
+
1: "gap-1",
|
|
504
|
+
2: "gap-2",
|
|
505
|
+
3: "gap-3",
|
|
506
|
+
4: "gap-4",
|
|
507
|
+
6: "gap-6",
|
|
508
|
+
8: "gap-8",
|
|
509
|
+
10: "gap-10",
|
|
510
|
+
12: "gap-12"
|
|
511
|
+
};
|
|
512
|
+
const stackAlignClass = {
|
|
513
|
+
start: "items-start",
|
|
514
|
+
center: "items-center",
|
|
515
|
+
end: "items-end",
|
|
516
|
+
stretch: "items-stretch"
|
|
517
|
+
};
|
|
518
|
+
const stackJustifyClass = {
|
|
519
|
+
start: "justify-start",
|
|
520
|
+
center: "justify-center",
|
|
521
|
+
end: "justify-end",
|
|
522
|
+
between: "justify-between",
|
|
523
|
+
around: "justify-around"
|
|
524
|
+
};
|
|
525
|
+
const Stack = React.forwardRef(function Stack2({
|
|
526
|
+
direction = "col",
|
|
527
|
+
gap = 4,
|
|
528
|
+
align,
|
|
529
|
+
justify,
|
|
530
|
+
wrap,
|
|
531
|
+
className,
|
|
532
|
+
children,
|
|
533
|
+
...rest
|
|
534
|
+
}, ref) {
|
|
535
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
536
|
+
"div",
|
|
537
|
+
{
|
|
538
|
+
ref,
|
|
539
|
+
className: cn(
|
|
540
|
+
"flex",
|
|
541
|
+
direction === "col" ? "flex-col" : "flex-row",
|
|
542
|
+
stackGapClass[gap],
|
|
543
|
+
align && stackAlignClass[align],
|
|
544
|
+
justify && stackJustifyClass[justify],
|
|
545
|
+
wrap && "flex-wrap",
|
|
546
|
+
className
|
|
547
|
+
),
|
|
548
|
+
...rest,
|
|
549
|
+
children
|
|
550
|
+
}
|
|
551
|
+
);
|
|
552
|
+
});
|
|
399
553
|
const sizeStyles$1 = {
|
|
400
554
|
large: {
|
|
401
555
|
container: "h-9 px-3 gap-1",
|
|
@@ -3894,18 +4048,24 @@ const TimeInput = React.forwardRef(
|
|
|
3894
4048
|
TimeInput.displayName = "TimeInput";
|
|
3895
4049
|
exports.Button = Button;
|
|
3896
4050
|
exports.Card = Card;
|
|
4051
|
+
exports.CardGrid = CardGrid;
|
|
3897
4052
|
exports.Chip = Chip;
|
|
3898
4053
|
exports.DateInput = DateInput;
|
|
3899
4054
|
exports.Dropdown = Dropdown;
|
|
3900
4055
|
exports.DropdownMultiple = DropdownMultiple;
|
|
3901
4056
|
exports.Input = Input;
|
|
3902
4057
|
exports.OptionList = OptionList;
|
|
4058
|
+
exports.Page = Page;
|
|
4059
|
+
exports.PageHeader = PageHeader;
|
|
3903
4060
|
exports.SearchInput = SearchInput;
|
|
4061
|
+
exports.Section = Section;
|
|
4062
|
+
exports.Stack = Stack;
|
|
3904
4063
|
exports.StatusTag = StatusTag;
|
|
3905
4064
|
exports.Tab = Tab;
|
|
3906
4065
|
exports.TabGroup = TabGroup;
|
|
3907
4066
|
exports.Tag = Tag;
|
|
3908
4067
|
exports.TextArea = TextArea;
|
|
3909
4068
|
exports.TimeInput = TimeInput;
|
|
4069
|
+
exports.Toolbar = Toolbar;
|
|
3910
4070
|
exports.cn = cn;
|
|
3911
4071
|
//# sourceMappingURL=index.cjs.map
|