@clickpalm/react 1.2.1 → 1.2.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.d.ts +1 -1
- package/dist/index.js +28 -19
- package/dist/index.mjs +28 -19
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -2301,7 +2301,7 @@ declare const CheckboxContainer: _stitches_react_types_styled_component.StyledCo
|
|
|
2301
2301
|
|
|
2302
2302
|
interface CheckboxProps extends ComponentProps<typeof CheckboxContainer> {
|
|
2303
2303
|
label: string;
|
|
2304
|
-
checked
|
|
2304
|
+
checked?: boolean;
|
|
2305
2305
|
onCheckedChange: (checked: boolean) => void;
|
|
2306
2306
|
errorMessage?: string;
|
|
2307
2307
|
}
|
package/dist/index.js
CHANGED
|
@@ -1165,7 +1165,7 @@ var Checkbox2 = (0, import_react5.forwardRef)(
|
|
|
1165
1165
|
CheckboxContainer,
|
|
1166
1166
|
{
|
|
1167
1167
|
ref,
|
|
1168
|
-
checked,
|
|
1168
|
+
checked: !!checked,
|
|
1169
1169
|
onCheckedChange,
|
|
1170
1170
|
hasError: !!errorMessage,
|
|
1171
1171
|
...rest,
|
|
@@ -1511,9 +1511,9 @@ var StyledContent = styled(Dialog.Content, {
|
|
|
1511
1511
|
left: "50%",
|
|
1512
1512
|
display: "flex",
|
|
1513
1513
|
flexDirection: "column",
|
|
1514
|
-
padding: "$4",
|
|
1514
|
+
padding: "0 $4",
|
|
1515
1515
|
width: "90%",
|
|
1516
|
-
maxWidth: "
|
|
1516
|
+
maxWidth: "600px",
|
|
1517
1517
|
backgroundColor: "$white",
|
|
1518
1518
|
borderRadius: "$md",
|
|
1519
1519
|
boxShadow: "0px 10px 38px -10px rgba(22, 23, 24, 0.35), 0px 10px 20px -15px rgba(22, 23, 24, 0.2)",
|
|
@@ -1533,10 +1533,9 @@ var StyledTitle = styled(Dialog.Title, {
|
|
|
1533
1533
|
color: "$black"
|
|
1534
1534
|
});
|
|
1535
1535
|
var StyledClose = styled(Dialog.Close, {
|
|
1536
|
-
|
|
1537
|
-
|
|
1538
|
-
|
|
1539
|
-
right: "16px",
|
|
1536
|
+
// position: 'absolute',
|
|
1537
|
+
// top: '24px',
|
|
1538
|
+
// right: '16px',
|
|
1540
1539
|
cursor: "pointer",
|
|
1541
1540
|
fontSize: "18px",
|
|
1542
1541
|
color: "#999",
|
|
@@ -1547,20 +1546,30 @@ var StyledClose = styled(Dialog.Close, {
|
|
|
1547
1546
|
var StyledDivider = styled("hr", {
|
|
1548
1547
|
width: "100%",
|
|
1549
1548
|
border: "none",
|
|
1550
|
-
borderTop: "1px solid $gray_mid"
|
|
1549
|
+
borderTop: "1px solid $gray_mid",
|
|
1550
|
+
margin: "0px"
|
|
1551
1551
|
});
|
|
1552
1552
|
var StyledDescription = styled(Dialog.Description, {
|
|
1553
1553
|
display: "flex",
|
|
1554
1554
|
fontFamily: "$default",
|
|
1555
1555
|
fontWeight: "$regular",
|
|
1556
1556
|
fontSize: "$md",
|
|
1557
|
-
|
|
1557
|
+
color: "$black",
|
|
1558
|
+
marginTop: "$4",
|
|
1559
|
+
marginBottom: 0
|
|
1560
|
+
});
|
|
1561
|
+
var StyledChildren = styled(Dialog.Description, {
|
|
1562
|
+
fontFamily: "$default",
|
|
1563
|
+
fontWeight: "$regular",
|
|
1564
|
+
fontSize: "$md",
|
|
1565
|
+
color: "$black",
|
|
1566
|
+
margin: "$4 0"
|
|
1558
1567
|
});
|
|
1559
1568
|
|
|
1560
1569
|
// src/components/Modal/index.tsx
|
|
1561
1570
|
var import_jsx_runtime22 = require("react/jsx-runtime");
|
|
1562
1571
|
var Modal = ({ open, onOpenChange, title, description, children }) => {
|
|
1563
|
-
return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(Dialog2.Root, { open, onOpenChange, children: /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(Dialog2.Portal, { children: [
|
|
1572
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(Dialog2.Root, { open, onOpenChange, modal: true, children: /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(Dialog2.Portal, { children: [
|
|
1564
1573
|
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)(StyledOverlay, {}),
|
|
1565
1574
|
/* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(StyledContent, { children: [
|
|
1566
1575
|
/* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(Wrapper, { children: [
|
|
@@ -1569,7 +1578,7 @@ var Modal = ({ open, onOpenChange, title, description, children }) => {
|
|
|
1569
1578
|
] }),
|
|
1570
1579
|
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)(StyledDivider, {}),
|
|
1571
1580
|
description && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(StyledDescription, { children: description }),
|
|
1572
|
-
children
|
|
1581
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)(StyledChildren, { children })
|
|
1573
1582
|
] })
|
|
1574
1583
|
] }) });
|
|
1575
1584
|
};
|
|
@@ -3807,17 +3816,17 @@ var AccordionItem = styled(Accordion.Item, {
|
|
|
3807
3816
|
}
|
|
3808
3817
|
});
|
|
3809
3818
|
var AccordionHeader = styled(Accordion.Header, {
|
|
3810
|
-
display: "flex"
|
|
3819
|
+
display: "flex",
|
|
3820
|
+
alignItems: "center",
|
|
3821
|
+
justifyContent: "space-between",
|
|
3822
|
+
padding: "0 $5"
|
|
3811
3823
|
});
|
|
3812
3824
|
var AccordionTrigger = styled(Accordion.Trigger, {
|
|
3813
3825
|
all: "unset",
|
|
3814
3826
|
fontFamily: "$default",
|
|
3815
3827
|
backgroundColor: "transparent",
|
|
3816
|
-
padding: "0 $5",
|
|
3817
|
-
flex: 1,
|
|
3818
3828
|
display: "flex",
|
|
3819
3829
|
alignItems: "center",
|
|
3820
|
-
justifyContent: "space-between",
|
|
3821
3830
|
fontSize: "$md",
|
|
3822
3831
|
lineHeight: "$regular",
|
|
3823
3832
|
color: "$black",
|
|
@@ -3867,13 +3876,13 @@ var import_jsx_runtime43 = require("react/jsx-runtime");
|
|
|
3867
3876
|
var Accordion2 = import_react21.default.forwardRef(
|
|
3868
3877
|
({ title, children, dropdownItems }, ref) => {
|
|
3869
3878
|
return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(AccordionContainer, { type: "single", collapsible: true, ref, children: /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(AccordionItem, { value: "item-1", children: [
|
|
3870
|
-
/* @__PURE__ */ (0, import_jsx_runtime43.
|
|
3871
|
-
title,
|
|
3879
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(AccordionHeader, { children: [
|
|
3880
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)(AccordionTrigger, { children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { children: title }) }),
|
|
3872
3881
|
/* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(TriggerContent, { children: [
|
|
3873
3882
|
dropdownItems && dropdownItems,
|
|
3874
|
-
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
3883
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)(RadixAccordion.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(StyledButton, { as: "div", variant: "secondary", size: "sm", children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(AccordionChevron, { name: "TriangleDown", size: 16, "aria-hidden": true }) }) })
|
|
3875
3884
|
] })
|
|
3876
|
-
] })
|
|
3885
|
+
] }),
|
|
3877
3886
|
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)(RadixAccordion.Content, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(AccordionContent, { children }) })
|
|
3878
3887
|
] }) });
|
|
3879
3888
|
}
|
package/dist/index.mjs
CHANGED
|
@@ -1093,7 +1093,7 @@ var Checkbox2 = forwardRef2(
|
|
|
1093
1093
|
CheckboxContainer,
|
|
1094
1094
|
{
|
|
1095
1095
|
ref,
|
|
1096
|
-
checked,
|
|
1096
|
+
checked: !!checked,
|
|
1097
1097
|
onCheckedChange,
|
|
1098
1098
|
hasError: !!errorMessage,
|
|
1099
1099
|
...rest,
|
|
@@ -1439,9 +1439,9 @@ var StyledContent = styled(Dialog.Content, {
|
|
|
1439
1439
|
left: "50%",
|
|
1440
1440
|
display: "flex",
|
|
1441
1441
|
flexDirection: "column",
|
|
1442
|
-
padding: "$4",
|
|
1442
|
+
padding: "0 $4",
|
|
1443
1443
|
width: "90%",
|
|
1444
|
-
maxWidth: "
|
|
1444
|
+
maxWidth: "600px",
|
|
1445
1445
|
backgroundColor: "$white",
|
|
1446
1446
|
borderRadius: "$md",
|
|
1447
1447
|
boxShadow: "0px 10px 38px -10px rgba(22, 23, 24, 0.35), 0px 10px 20px -15px rgba(22, 23, 24, 0.2)",
|
|
@@ -1461,10 +1461,9 @@ var StyledTitle = styled(Dialog.Title, {
|
|
|
1461
1461
|
color: "$black"
|
|
1462
1462
|
});
|
|
1463
1463
|
var StyledClose = styled(Dialog.Close, {
|
|
1464
|
-
|
|
1465
|
-
|
|
1466
|
-
|
|
1467
|
-
right: "16px",
|
|
1464
|
+
// position: 'absolute',
|
|
1465
|
+
// top: '24px',
|
|
1466
|
+
// right: '16px',
|
|
1468
1467
|
cursor: "pointer",
|
|
1469
1468
|
fontSize: "18px",
|
|
1470
1469
|
color: "#999",
|
|
@@ -1475,20 +1474,30 @@ var StyledClose = styled(Dialog.Close, {
|
|
|
1475
1474
|
var StyledDivider = styled("hr", {
|
|
1476
1475
|
width: "100%",
|
|
1477
1476
|
border: "none",
|
|
1478
|
-
borderTop: "1px solid $gray_mid"
|
|
1477
|
+
borderTop: "1px solid $gray_mid",
|
|
1478
|
+
margin: "0px"
|
|
1479
1479
|
});
|
|
1480
1480
|
var StyledDescription = styled(Dialog.Description, {
|
|
1481
1481
|
display: "flex",
|
|
1482
1482
|
fontFamily: "$default",
|
|
1483
1483
|
fontWeight: "$regular",
|
|
1484
1484
|
fontSize: "$md",
|
|
1485
|
-
|
|
1485
|
+
color: "$black",
|
|
1486
|
+
marginTop: "$4",
|
|
1487
|
+
marginBottom: 0
|
|
1488
|
+
});
|
|
1489
|
+
var StyledChildren = styled(Dialog.Description, {
|
|
1490
|
+
fontFamily: "$default",
|
|
1491
|
+
fontWeight: "$regular",
|
|
1492
|
+
fontSize: "$md",
|
|
1493
|
+
color: "$black",
|
|
1494
|
+
margin: "$4 0"
|
|
1486
1495
|
});
|
|
1487
1496
|
|
|
1488
1497
|
// src/components/Modal/index.tsx
|
|
1489
1498
|
import { jsx as jsx22, jsxs as jsxs6 } from "react/jsx-runtime";
|
|
1490
1499
|
var Modal = ({ open, onOpenChange, title, description, children }) => {
|
|
1491
|
-
return /* @__PURE__ */ jsx22(Dialog2.Root, { open, onOpenChange, children: /* @__PURE__ */ jsxs6(Dialog2.Portal, { children: [
|
|
1500
|
+
return /* @__PURE__ */ jsx22(Dialog2.Root, { open, onOpenChange, modal: true, children: /* @__PURE__ */ jsxs6(Dialog2.Portal, { children: [
|
|
1492
1501
|
/* @__PURE__ */ jsx22(StyledOverlay, {}),
|
|
1493
1502
|
/* @__PURE__ */ jsxs6(StyledContent, { children: [
|
|
1494
1503
|
/* @__PURE__ */ jsxs6(Wrapper, { children: [
|
|
@@ -1497,7 +1506,7 @@ var Modal = ({ open, onOpenChange, title, description, children }) => {
|
|
|
1497
1506
|
] }),
|
|
1498
1507
|
/* @__PURE__ */ jsx22(StyledDivider, {}),
|
|
1499
1508
|
description && /* @__PURE__ */ jsx22(StyledDescription, { children: description }),
|
|
1500
|
-
children
|
|
1509
|
+
/* @__PURE__ */ jsx22(StyledChildren, { children })
|
|
1501
1510
|
] })
|
|
1502
1511
|
] }) });
|
|
1503
1512
|
};
|
|
@@ -3739,17 +3748,17 @@ var AccordionItem = styled(Accordion.Item, {
|
|
|
3739
3748
|
}
|
|
3740
3749
|
});
|
|
3741
3750
|
var AccordionHeader = styled(Accordion.Header, {
|
|
3742
|
-
display: "flex"
|
|
3751
|
+
display: "flex",
|
|
3752
|
+
alignItems: "center",
|
|
3753
|
+
justifyContent: "space-between",
|
|
3754
|
+
padding: "0 $5"
|
|
3743
3755
|
});
|
|
3744
3756
|
var AccordionTrigger = styled(Accordion.Trigger, {
|
|
3745
3757
|
all: "unset",
|
|
3746
3758
|
fontFamily: "$default",
|
|
3747
3759
|
backgroundColor: "transparent",
|
|
3748
|
-
padding: "0 $5",
|
|
3749
|
-
flex: 1,
|
|
3750
3760
|
display: "flex",
|
|
3751
3761
|
alignItems: "center",
|
|
3752
|
-
justifyContent: "space-between",
|
|
3753
3762
|
fontSize: "$md",
|
|
3754
3763
|
lineHeight: "$regular",
|
|
3755
3764
|
color: "$black",
|
|
@@ -3799,13 +3808,13 @@ import { jsx as jsx43, jsxs as jsxs20 } from "react/jsx-runtime";
|
|
|
3799
3808
|
var Accordion2 = React6.forwardRef(
|
|
3800
3809
|
({ title, children, dropdownItems }, ref) => {
|
|
3801
3810
|
return /* @__PURE__ */ jsx43(AccordionContainer, { type: "single", collapsible: true, ref, children: /* @__PURE__ */ jsxs20(AccordionItem, { value: "item-1", children: [
|
|
3802
|
-
/* @__PURE__ */
|
|
3803
|
-
title,
|
|
3811
|
+
/* @__PURE__ */ jsxs20(AccordionHeader, { children: [
|
|
3812
|
+
/* @__PURE__ */ jsx43(AccordionTrigger, { children: /* @__PURE__ */ jsx43("span", { children: title }) }),
|
|
3804
3813
|
/* @__PURE__ */ jsxs20(TriggerContent, { children: [
|
|
3805
3814
|
dropdownItems && dropdownItems,
|
|
3806
|
-
/* @__PURE__ */ jsx43(
|
|
3815
|
+
/* @__PURE__ */ jsx43(RadixAccordion.Trigger, { asChild: true, children: /* @__PURE__ */ jsx43(StyledButton, { as: "div", variant: "secondary", size: "sm", children: /* @__PURE__ */ jsx43(AccordionChevron, { name: "TriangleDown", size: 16, "aria-hidden": true }) }) })
|
|
3807
3816
|
] })
|
|
3808
|
-
] })
|
|
3817
|
+
] }),
|
|
3809
3818
|
/* @__PURE__ */ jsx43(RadixAccordion.Content, { asChild: true, children: /* @__PURE__ */ jsx43(AccordionContent, { children }) })
|
|
3810
3819
|
] }) });
|
|
3811
3820
|
}
|
package/package.json
CHANGED