@cnc-ti/layout-basic 8.3.0 → 8.3.1
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.css +166 -0
- package/dist/index.css.map +1 -1
- package/dist/index.d.mts +91 -2
- package/dist/index.d.ts +91 -2
- package/dist/index.js +241 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +227 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +2 -1
package/dist/index.mjs
CHANGED
|
@@ -9245,6 +9245,8 @@ import { jsx as jsx24, jsxs as jsxs10 } from "react/jsx-runtime";
|
|
|
9245
9245
|
var Select = SelectPrimitive.Root;
|
|
9246
9246
|
var SelectGroup = SelectPrimitive.Group;
|
|
9247
9247
|
var SelectValue = SelectPrimitive.Value;
|
|
9248
|
+
var SelectPortal = SelectPrimitive.Portal;
|
|
9249
|
+
var SelectViewport = SelectPrimitive.Viewport;
|
|
9248
9250
|
var SelectTrigger = React38.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ jsxs10(
|
|
9249
9251
|
SelectPrimitive.Trigger,
|
|
9250
9252
|
{
|
|
@@ -9319,7 +9321,10 @@ var SelectLabel = React38.forwardRef(({ className, ...props }, ref) => /* @__PUR
|
|
|
9319
9321
|
SelectPrimitive.Label,
|
|
9320
9322
|
{
|
|
9321
9323
|
ref,
|
|
9322
|
-
className: cn(
|
|
9324
|
+
className: cn(
|
|
9325
|
+
"cnc-py-1.5 cnc-pl-8 cnc-pr-2 cnc-text-sm cnc-font-semibold",
|
|
9326
|
+
className
|
|
9327
|
+
),
|
|
9323
9328
|
...props
|
|
9324
9329
|
}
|
|
9325
9330
|
));
|
|
@@ -9349,9 +9354,225 @@ var SelectSeparator = React38.forwardRef(({ className, ...props }, ref) => /* @_
|
|
|
9349
9354
|
}
|
|
9350
9355
|
));
|
|
9351
9356
|
SelectSeparator.displayName = SelectPrimitive.Separator.displayName;
|
|
9357
|
+
|
|
9358
|
+
// src/components/atoms/forms/input.tsx
|
|
9359
|
+
import * as React39 from "react";
|
|
9360
|
+
import { jsx as jsx25, jsxs as jsxs11 } from "react/jsx-runtime";
|
|
9361
|
+
var Input = React39.forwardRef(
|
|
9362
|
+
({ className, type, id, label, ...props }, ref) => {
|
|
9363
|
+
const idGenerate = id ? id : label && `field-${Date.now()}-${Math.random() * 1e5}`;
|
|
9364
|
+
return /* @__PURE__ */ jsxs11("div", { className: "cnc-w-full", children: [
|
|
9365
|
+
label && /* @__PURE__ */ jsx25(
|
|
9366
|
+
"label",
|
|
9367
|
+
{
|
|
9368
|
+
htmlFor: idGenerate,
|
|
9369
|
+
className: "cnc-block cnc-text-sm cnc-mb-1 cnc-font-medium cnc-text-brand-gray-600",
|
|
9370
|
+
children: label
|
|
9371
|
+
}
|
|
9372
|
+
),
|
|
9373
|
+
/* @__PURE__ */ jsx25(
|
|
9374
|
+
"input",
|
|
9375
|
+
{
|
|
9376
|
+
type,
|
|
9377
|
+
id: idGenerate,
|
|
9378
|
+
className: cn(
|
|
9379
|
+
"cnc-flex cnc-h-8 cnc-w-full cnc-rounded-md cnc-border cnc-border-input cnc-bg-transparent cnc-px-3 cnc-py-1 cnc-text-base cnc-shadow-sm cnc-transition-colors",
|
|
9380
|
+
" file:cnc-border-0 file:cnc-bg-transparent file:cnc-text-sm file:cnc-font-medium file:cnc-text-foreground placeholder:cnc-text-muted-foreground focus-visible:cnc-outline-none",
|
|
9381
|
+
"focus-visible:cnc-ring-2 focus-visible:cnc-ring-brand-gray-500/50 disabled:cnc-cursor-not-allowed disabled:cnc-opacity-50 md:cnc-text-sm ",
|
|
9382
|
+
"not-disabled:hover:cnc-border-brand-gray-500",
|
|
9383
|
+
className
|
|
9384
|
+
),
|
|
9385
|
+
ref,
|
|
9386
|
+
...props
|
|
9387
|
+
}
|
|
9388
|
+
)
|
|
9389
|
+
] });
|
|
9390
|
+
}
|
|
9391
|
+
);
|
|
9392
|
+
Input.displayName = "Input";
|
|
9393
|
+
|
|
9394
|
+
// src/components/atoms/display/badge.tsx
|
|
9395
|
+
import { jsx as jsx26 } from "react/jsx-runtime";
|
|
9396
|
+
var Badge = ({
|
|
9397
|
+
variant = "default",
|
|
9398
|
+
rounded = true,
|
|
9399
|
+
size: size4 = "md",
|
|
9400
|
+
className,
|
|
9401
|
+
...rest
|
|
9402
|
+
}) => {
|
|
9403
|
+
const baseStyle = "cnc-inline-flex cnc-items-center cnc-font-semibold cnc-transition-colors";
|
|
9404
|
+
const variants = {
|
|
9405
|
+
default: "cnc-bg-brand-gray-20 cnc-text-brand-gray-600",
|
|
9406
|
+
primary: "cnc-bg-brand-blue-100 cnc-text-white",
|
|
9407
|
+
success: "cnc-bg-brand-green-200 cnc-text-white",
|
|
9408
|
+
warning: "cnc-bg-brand-gold-400 cnc-text-white",
|
|
9409
|
+
danger: "cnc-bg-brand-red-500 cnc-text-white",
|
|
9410
|
+
info: "cnc-bg-brand-blue-60 cnc-text-brand-blue-900"
|
|
9411
|
+
};
|
|
9412
|
+
const sizes = {
|
|
9413
|
+
sm: "cnc-text-xs cnc-px-2 cnc-py-0.5",
|
|
9414
|
+
md: "cnc-text-sm cnc-px-3 cnc-py-1",
|
|
9415
|
+
lg: "cnc-text-base cnc-px-4 cnc-py-2"
|
|
9416
|
+
};
|
|
9417
|
+
return /* @__PURE__ */ jsx26(
|
|
9418
|
+
"span",
|
|
9419
|
+
{
|
|
9420
|
+
className: cn(
|
|
9421
|
+
baseStyle,
|
|
9422
|
+
variants[variant],
|
|
9423
|
+
sizes[size4],
|
|
9424
|
+
rounded ? "cnc-rounded-full" : "",
|
|
9425
|
+
className
|
|
9426
|
+
),
|
|
9427
|
+
...rest
|
|
9428
|
+
}
|
|
9429
|
+
);
|
|
9430
|
+
};
|
|
9431
|
+
|
|
9432
|
+
// src/components/molecules/card.tsx
|
|
9433
|
+
import { jsx as jsx27 } from "react/jsx-runtime";
|
|
9434
|
+
function Card({
|
|
9435
|
+
className,
|
|
9436
|
+
...rest
|
|
9437
|
+
}) {
|
|
9438
|
+
return /* @__PURE__ */ jsx27(
|
|
9439
|
+
"div",
|
|
9440
|
+
{
|
|
9441
|
+
className: cn(
|
|
9442
|
+
"cnc-w-full cnc-flex cnc-flex-col cnc-border-2 cnc-border-brand-gray-50 cnc-rounded-md cnc-shadow",
|
|
9443
|
+
className
|
|
9444
|
+
),
|
|
9445
|
+
...rest
|
|
9446
|
+
}
|
|
9447
|
+
);
|
|
9448
|
+
}
|
|
9449
|
+
function CardHeader({
|
|
9450
|
+
className,
|
|
9451
|
+
...rest
|
|
9452
|
+
}) {
|
|
9453
|
+
return /* @__PURE__ */ jsx27("div", { className: "cnc-px-6 cnc-pt-6", children: /* @__PURE__ */ jsx27(
|
|
9454
|
+
"div",
|
|
9455
|
+
{
|
|
9456
|
+
className: cn(
|
|
9457
|
+
"cnc-flex cnc-items-center cnc-justify-between cnc-w-full cnc-border-b-2 cnc-border-brand-gray-50 cnc-pb-4",
|
|
9458
|
+
className
|
|
9459
|
+
),
|
|
9460
|
+
...rest
|
|
9461
|
+
}
|
|
9462
|
+
) });
|
|
9463
|
+
}
|
|
9464
|
+
function CardContent({
|
|
9465
|
+
className,
|
|
9466
|
+
...rest
|
|
9467
|
+
}) {
|
|
9468
|
+
return /* @__PURE__ */ jsx27("div", { className: cn("cnc-px-6 cnc-py-2", className), ...rest });
|
|
9469
|
+
}
|
|
9470
|
+
function CardFooter({
|
|
9471
|
+
className,
|
|
9472
|
+
...rest
|
|
9473
|
+
}) {
|
|
9474
|
+
return /* @__PURE__ */ jsx27(
|
|
9475
|
+
"div",
|
|
9476
|
+
{
|
|
9477
|
+
className: cn(
|
|
9478
|
+
"cnc-mt-4 cnc-flex cnc-border-t-2 cnc-border-brand-gray-50",
|
|
9479
|
+
className
|
|
9480
|
+
),
|
|
9481
|
+
...rest
|
|
9482
|
+
}
|
|
9483
|
+
);
|
|
9484
|
+
}
|
|
9485
|
+
function CardFooterItem({
|
|
9486
|
+
className,
|
|
9487
|
+
...rest
|
|
9488
|
+
}) {
|
|
9489
|
+
return /* @__PURE__ */ jsx27(
|
|
9490
|
+
"div",
|
|
9491
|
+
{
|
|
9492
|
+
className: cn(
|
|
9493
|
+
"cnc-molecule-card-item cnc-flex cnc-flex-1 cnc-items-center cnc-justify-center cnc-py-3 cnc-px-8",
|
|
9494
|
+
className
|
|
9495
|
+
),
|
|
9496
|
+
...rest
|
|
9497
|
+
}
|
|
9498
|
+
);
|
|
9499
|
+
}
|
|
9500
|
+
|
|
9501
|
+
// src/components/molecules/collapsible.tsx
|
|
9502
|
+
import * as CollapsiblePrimitive from "@radix-ui/react-collapsible";
|
|
9503
|
+
import { jsx as jsx28 } from "react/jsx-runtime";
|
|
9504
|
+
var Collapsible = CollapsiblePrimitive.Root;
|
|
9505
|
+
var CollapsibleTrigger2 = CollapsiblePrimitive.CollapsibleTrigger;
|
|
9506
|
+
var CollapsibleContent2 = CollapsiblePrimitive.CollapsibleContent;
|
|
9507
|
+
var AnimatedCollapsibleContent = ({
|
|
9508
|
+
className,
|
|
9509
|
+
...rest
|
|
9510
|
+
}) => {
|
|
9511
|
+
const state = rest["data-state"];
|
|
9512
|
+
return /* @__PURE__ */ jsx28(CollapsibleContent2, { className: "cnc-collapsible-content", ...rest });
|
|
9513
|
+
};
|
|
9514
|
+
|
|
9515
|
+
// src/components/molecules/display/page-header.tsx
|
|
9516
|
+
import { Fragment as Fragment8, jsx as jsx29, jsxs as jsxs12 } from "react/jsx-runtime";
|
|
9517
|
+
function PageHeader({
|
|
9518
|
+
title,
|
|
9519
|
+
description,
|
|
9520
|
+
actions,
|
|
9521
|
+
titleAs = "h1",
|
|
9522
|
+
showGoBack = false
|
|
9523
|
+
}) {
|
|
9524
|
+
const ComponentTitle = titleAs;
|
|
9525
|
+
return /* @__PURE__ */ jsx29(Fragment8, { children: title && /* @__PURE__ */ jsxs12("header", { className: "cnc-w-full cnc-flex cnc-items-center cnc-justify-between cnc-p-8 cnc-bg-brand-blue-50 cnc-border-b-2 cnc-border-brand-blue-60", children: [
|
|
9526
|
+
/* @__PURE__ */ jsx29("div", { className: "cnc-flex cnc-flex-col cnc-gap-2", children: /* @__PURE__ */ jsxs12("div", { className: "cnc-flex cnc-items-start cnc-gap-2", children: [
|
|
9527
|
+
showGoBack && /* @__PURE__ */ jsx29(
|
|
9528
|
+
"button",
|
|
9529
|
+
{
|
|
9530
|
+
className: "cnc-mt-1 hover:cnc-opacity-60",
|
|
9531
|
+
onClick: () => window.history.back(),
|
|
9532
|
+
children: /* @__PURE__ */ jsx29(
|
|
9533
|
+
"svg",
|
|
9534
|
+
{
|
|
9535
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
9536
|
+
className: "cnc-w-6 cnc-h-6 cnc-text-[#1F2C4D]",
|
|
9537
|
+
fill: "none",
|
|
9538
|
+
viewBox: "0 0 24 24",
|
|
9539
|
+
strokeWidth: 1.5,
|
|
9540
|
+
stroke: "currentColor",
|
|
9541
|
+
children: /* @__PURE__ */ jsx29(
|
|
9542
|
+
"path",
|
|
9543
|
+
{
|
|
9544
|
+
strokeLinecap: "round",
|
|
9545
|
+
strokeLinejoin: "round",
|
|
9546
|
+
d: "M15.75 19.5 8.25 12l7.5-7.5"
|
|
9547
|
+
}
|
|
9548
|
+
)
|
|
9549
|
+
}
|
|
9550
|
+
)
|
|
9551
|
+
}
|
|
9552
|
+
),
|
|
9553
|
+
/* @__PURE__ */ jsxs12("div", { children: [
|
|
9554
|
+
/* @__PURE__ */ jsx29(ComponentTitle, { className: "cnc-text-2xl cnc-leading-8 cnc-font-semibold cnc-text-brand-blue-600", children: title }),
|
|
9555
|
+
description && /* @__PURE__ */ jsx29("p", { className: "cnc-text-brand-gray-500 cnc-leading-4", children: description })
|
|
9556
|
+
] })
|
|
9557
|
+
] }) }),
|
|
9558
|
+
actions && /* @__PURE__ */ jsx29("div", { className: "cnc-flex cnc-gap-4", children: actions })
|
|
9559
|
+
] }) });
|
|
9560
|
+
}
|
|
9561
|
+
function Title2({ title, as: Component = "h1" }) {
|
|
9562
|
+
return /* @__PURE__ */ jsx29(Component, { className: "cnc-text-[28px] cnc-text-[#1F2C4D] cnc-font-bold cnc-mt-[10px] cnc-mb-5", children: title });
|
|
9563
|
+
}
|
|
9352
9564
|
export {
|
|
9353
9565
|
AplicationsHeader,
|
|
9566
|
+
Badge,
|
|
9354
9567
|
Button,
|
|
9568
|
+
Card,
|
|
9569
|
+
CardContent,
|
|
9570
|
+
CardFooter,
|
|
9571
|
+
CardFooterItem,
|
|
9572
|
+
CardHeader,
|
|
9573
|
+
Collapsible,
|
|
9574
|
+
AnimatedCollapsibleContent as CollapsibleContent,
|
|
9575
|
+
CollapsibleTrigger2 as CollapsibleTrigger,
|
|
9355
9576
|
Dialog2 as Dialog,
|
|
9356
9577
|
DialogClose2 as DialogClose,
|
|
9357
9578
|
DialogContent2 as DialogContent,
|
|
@@ -9381,9 +9602,11 @@ export {
|
|
|
9381
9602
|
HeaderContainer,
|
|
9382
9603
|
HeaderProfileHeader,
|
|
9383
9604
|
HeaderProfileItem,
|
|
9605
|
+
Input,
|
|
9384
9606
|
Modal,
|
|
9385
9607
|
ModalEntidade,
|
|
9386
9608
|
ModalMudancaEntidade,
|
|
9609
|
+
PageHeader,
|
|
9387
9610
|
Popover2 as Popover,
|
|
9388
9611
|
PopoverContent2 as PopoverContent,
|
|
9389
9612
|
PopoverTrigger2 as PopoverTrigger,
|
|
@@ -9392,16 +9615,19 @@ export {
|
|
|
9392
9615
|
SelectGroup,
|
|
9393
9616
|
SelectItem,
|
|
9394
9617
|
SelectLabel,
|
|
9618
|
+
SelectPortal,
|
|
9395
9619
|
SelectScrollDownButton,
|
|
9396
9620
|
SelectScrollUpButton,
|
|
9397
9621
|
SelectSeparator,
|
|
9398
9622
|
SelectTrigger,
|
|
9399
9623
|
SelectValue,
|
|
9624
|
+
SelectViewport,
|
|
9400
9625
|
Sidebar,
|
|
9401
9626
|
SidebarContainer,
|
|
9402
9627
|
SidebarImageBrand,
|
|
9403
9628
|
SidebarNavCollapse,
|
|
9404
9629
|
SidebarNavLink,
|
|
9630
|
+
Title2 as Title,
|
|
9405
9631
|
buttonVariants
|
|
9406
9632
|
};
|
|
9407
9633
|
/*! Bundled license information:
|