@pelcro/react-pelcro-js 4.0.0-alpha.71 → 4.0.0-alpha.73
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.js +22 -19
- package/dist/index.esm.js +22 -19
- package/dist/pelcro.css +0 -20
- package/package.json +1 -1
package/dist/index.cjs.js
CHANGED
|
@@ -34728,12 +34728,12 @@ const PaymentMethodDeleteBack = ({
|
|
|
34728
34728
|
t
|
|
34729
34729
|
} = useTranslation("paymentMethod");
|
|
34730
34730
|
const {
|
|
34731
|
-
|
|
34731
|
+
switchDashboardView
|
|
34732
34732
|
} = usePelcro();
|
|
34733
34733
|
return /*#__PURE__*/React__default['default'].createElement(Button, Object.assign({
|
|
34734
34734
|
variant: "outline",
|
|
34735
34735
|
onClick: () => {
|
|
34736
|
-
|
|
34736
|
+
switchDashboardView("payment-cards");
|
|
34737
34737
|
onClick === null || onClick === void 0 ? void 0 : onClick();
|
|
34738
34738
|
},
|
|
34739
34739
|
className: "plc-w-full"
|
|
@@ -36323,7 +36323,6 @@ const DashboardContent = ({
|
|
|
36323
36323
|
const {
|
|
36324
36324
|
switchView,
|
|
36325
36325
|
dashboardView,
|
|
36326
|
-
switchDashboardView,
|
|
36327
36326
|
logout
|
|
36328
36327
|
} = usePelcro();
|
|
36329
36328
|
const {
|
|
@@ -36376,10 +36375,6 @@ const DashboardContent = ({
|
|
|
36376
36375
|
dispatch({
|
|
36377
36376
|
type: CLOSE_DASHBOARD
|
|
36378
36377
|
});
|
|
36379
|
-
};
|
|
36380
|
-
|
|
36381
|
-
const closeSubMenusTab = () => {
|
|
36382
|
-
switchDashboardView(null);
|
|
36383
36378
|
}; // useEffect(() => {
|
|
36384
36379
|
// return () => {
|
|
36385
36380
|
// document.removeEventListener("click", hideMenuIfClickedOutside);
|
|
@@ -36387,7 +36382,9 @@ const DashboardContent = ({
|
|
|
36387
36382
|
// }, []); // eslint-disable-line react-hooks/exhaustive-deps
|
|
36388
36383
|
|
|
36389
36384
|
|
|
36390
|
-
return /*#__PURE__*/React__default['default'].createElement(
|
|
36385
|
+
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
36386
|
+
className: "pelcro-modal-overlay"
|
|
36387
|
+
}, /*#__PURE__*/React__default['default'].createElement(Transition, {
|
|
36391
36388
|
className: `plc-fixed plc-inset-y-0 plc-h-full lg:plc-w-3/12 plc-w-full plc-overflow-y-auto plc-text-left plc-bg-white plc-shadow-xl plc-z-max ${dashboardLayout == "left" ? "plc-left-0" : "plc-right-0"}`,
|
|
36392
36389
|
show: isOpen,
|
|
36393
36390
|
enter: "plc-transform plc-transition plc-duration-500",
|
|
@@ -36419,7 +36416,7 @@ const DashboardContent = ({
|
|
|
36419
36416
|
}, userHasName && /*#__PURE__*/React__default['default'].createElement("p", {
|
|
36420
36417
|
className: "plc-font-bold plc-break-all"
|
|
36421
36418
|
}, user.first_name, " ", user.last_name), /*#__PURE__*/React__default['default'].createElement("p", {
|
|
36422
|
-
className: `plc-m-0 plc-
|
|
36419
|
+
className: `plc-m-0 plc-break-all ${userHasName ? "plc-text-sm" : "plc-text-sm plc-font-bold plc-mt-auto"}`
|
|
36423
36420
|
}, user.email)), /*#__PURE__*/React__default['default'].createElement("div", null, /*#__PURE__*/React__default['default'].createElement(Button, {
|
|
36424
36421
|
variant: "ghost",
|
|
36425
36422
|
type: "button",
|
|
@@ -36448,13 +36445,6 @@ const DashboardContent = ({
|
|
|
36448
36445
|
key: i
|
|
36449
36446
|
})) : /*#__PURE__*/React__default['default'].cloneElement(subView, {
|
|
36450
36447
|
store: store$4
|
|
36451
|
-
})), /*#__PURE__*/React__default['default'].createElement(Button, {
|
|
36452
|
-
variant: "ghost",
|
|
36453
|
-
type: "button",
|
|
36454
|
-
className: `plc-text-gray-500 plc-rounded-2xl plc-absolute plc-z-max plc-top-2 md:plc-top-5 ${dashboardLayout == "left" ? "plc-right-2 md:plc-right-10" : "plc-left-2 md:plc-left-10"}`,
|
|
36455
|
-
onClick: closeSubMenusTab
|
|
36456
|
-
}, /*#__PURE__*/React__default['default'].createElement(SvgXIcon, {
|
|
36457
|
-
className: "plc-fill-current"
|
|
36458
36448
|
}))));
|
|
36459
36449
|
};
|
|
36460
36450
|
|
|
@@ -37147,6 +37137,7 @@ const Card = ({
|
|
|
37147
37137
|
className = "",
|
|
37148
37138
|
title,
|
|
37149
37139
|
requestStates,
|
|
37140
|
+
dashboardLayout,
|
|
37150
37141
|
back,
|
|
37151
37142
|
...restProps
|
|
37152
37143
|
}) => {
|
|
@@ -37154,11 +37145,16 @@ const Card = ({
|
|
|
37154
37145
|
const {
|
|
37155
37146
|
switchDashboardView
|
|
37156
37147
|
} = usePelcro();
|
|
37148
|
+
|
|
37149
|
+
const closeSubMenusTab = () => {
|
|
37150
|
+
switchDashboardView(null);
|
|
37151
|
+
};
|
|
37152
|
+
|
|
37157
37153
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
37158
|
-
className: `plc-bg-white plc-border-2 plc-p-6 md:plc-p-8 plc-rounded plc-my-11 md:plc-mb-20 md:plc-mt-40 ${className}`,
|
|
37154
|
+
className: `plc-relative plc-bg-white plc-border-2 plc-p-6 md:plc-p-8 plc-rounded plc-my-11 md:plc-mb-20 md:plc-mt-40 ${className}`,
|
|
37159
37155
|
id: "plc-dashboard-card"
|
|
37160
37156
|
}, title && /*#__PURE__*/React__default['default'].createElement(React__default['default'].Fragment, null, /*#__PURE__*/React__default['default'].createElement("div", {
|
|
37161
|
-
className: "plc-flex plc-items-end plc-justify-between plc-border-b-2 plc-border-primary-400 plc-pb-2 plc-mb-10"
|
|
37157
|
+
className: "plc-flex plc-items-end plc-justify-between plc-border-b-2 plc-border-primary-400 plc-pb-2 plc-mb-10 plc-mt-5"
|
|
37162
37158
|
}, /*#__PURE__*/React__default['default'].createElement("h3", {
|
|
37163
37159
|
className: "plc-font-bold plc-text-xl"
|
|
37164
37160
|
}, title), (requestStates === null || requestStates === void 0 ? void 0 : requestStates.loading) && /*#__PURE__*/React__default['default'].createElement("span", {
|
|
@@ -37171,7 +37167,14 @@ const Card = ({
|
|
|
37171
37167
|
onClick: () => {
|
|
37172
37168
|
switchDashboardView(back === null || back === void 0 ? void 0 : back.target);
|
|
37173
37169
|
}
|
|
37174
|
-
}, "Back"))), children
|
|
37170
|
+
}, "Back"))), children, /*#__PURE__*/React__default['default'].createElement(Button, {
|
|
37171
|
+
variant: "ghost",
|
|
37172
|
+
type: "button",
|
|
37173
|
+
className: "plc-text-gray-500 plc-rounded-2xl plc-absolute plc-z-max plc-top-1 plc-right-1",
|
|
37174
|
+
onClick: closeSubMenusTab
|
|
37175
|
+
}, /*#__PURE__*/React__default['default'].createElement(SvgXIcon, {
|
|
37176
|
+
className: "plc-fill-current"
|
|
37177
|
+
})));
|
|
37175
37178
|
};
|
|
37176
37179
|
|
|
37177
37180
|
const ProfileMenu = props => {
|
package/dist/index.esm.js
CHANGED
|
@@ -34698,12 +34698,12 @@ const PaymentMethodDeleteBack = ({
|
|
|
34698
34698
|
t
|
|
34699
34699
|
} = useTranslation("paymentMethod");
|
|
34700
34700
|
const {
|
|
34701
|
-
|
|
34701
|
+
switchDashboardView
|
|
34702
34702
|
} = usePelcro();
|
|
34703
34703
|
return /*#__PURE__*/React__default.createElement(Button, Object.assign({
|
|
34704
34704
|
variant: "outline",
|
|
34705
34705
|
onClick: () => {
|
|
34706
|
-
|
|
34706
|
+
switchDashboardView("payment-cards");
|
|
34707
34707
|
onClick === null || onClick === void 0 ? void 0 : onClick();
|
|
34708
34708
|
},
|
|
34709
34709
|
className: "plc-w-full"
|
|
@@ -36293,7 +36293,6 @@ const DashboardContent = ({
|
|
|
36293
36293
|
const {
|
|
36294
36294
|
switchView,
|
|
36295
36295
|
dashboardView,
|
|
36296
|
-
switchDashboardView,
|
|
36297
36296
|
logout
|
|
36298
36297
|
} = usePelcro();
|
|
36299
36298
|
const {
|
|
@@ -36346,10 +36345,6 @@ const DashboardContent = ({
|
|
|
36346
36345
|
dispatch({
|
|
36347
36346
|
type: CLOSE_DASHBOARD
|
|
36348
36347
|
});
|
|
36349
|
-
};
|
|
36350
|
-
|
|
36351
|
-
const closeSubMenusTab = () => {
|
|
36352
|
-
switchDashboardView(null);
|
|
36353
36348
|
}; // useEffect(() => {
|
|
36354
36349
|
// return () => {
|
|
36355
36350
|
// document.removeEventListener("click", hideMenuIfClickedOutside);
|
|
@@ -36357,7 +36352,9 @@ const DashboardContent = ({
|
|
|
36357
36352
|
// }, []); // eslint-disable-line react-hooks/exhaustive-deps
|
|
36358
36353
|
|
|
36359
36354
|
|
|
36360
|
-
return /*#__PURE__*/React__default.createElement(
|
|
36355
|
+
return /*#__PURE__*/React__default.createElement("div", {
|
|
36356
|
+
className: "pelcro-modal-overlay"
|
|
36357
|
+
}, /*#__PURE__*/React__default.createElement(Transition, {
|
|
36361
36358
|
className: `plc-fixed plc-inset-y-0 plc-h-full lg:plc-w-3/12 plc-w-full plc-overflow-y-auto plc-text-left plc-bg-white plc-shadow-xl plc-z-max ${dashboardLayout == "left" ? "plc-left-0" : "plc-right-0"}`,
|
|
36362
36359
|
show: isOpen,
|
|
36363
36360
|
enter: "plc-transform plc-transition plc-duration-500",
|
|
@@ -36389,7 +36386,7 @@ const DashboardContent = ({
|
|
|
36389
36386
|
}, userHasName && /*#__PURE__*/React__default.createElement("p", {
|
|
36390
36387
|
className: "plc-font-bold plc-break-all"
|
|
36391
36388
|
}, user.first_name, " ", user.last_name), /*#__PURE__*/React__default.createElement("p", {
|
|
36392
|
-
className: `plc-m-0 plc-
|
|
36389
|
+
className: `plc-m-0 plc-break-all ${userHasName ? "plc-text-sm" : "plc-text-sm plc-font-bold plc-mt-auto"}`
|
|
36393
36390
|
}, user.email)), /*#__PURE__*/React__default.createElement("div", null, /*#__PURE__*/React__default.createElement(Button, {
|
|
36394
36391
|
variant: "ghost",
|
|
36395
36392
|
type: "button",
|
|
@@ -36418,13 +36415,6 @@ const DashboardContent = ({
|
|
|
36418
36415
|
key: i
|
|
36419
36416
|
})) : /*#__PURE__*/React__default.cloneElement(subView, {
|
|
36420
36417
|
store: store$4
|
|
36421
|
-
})), /*#__PURE__*/React__default.createElement(Button, {
|
|
36422
|
-
variant: "ghost",
|
|
36423
|
-
type: "button",
|
|
36424
|
-
className: `plc-text-gray-500 plc-rounded-2xl plc-absolute plc-z-max plc-top-2 md:plc-top-5 ${dashboardLayout == "left" ? "plc-right-2 md:plc-right-10" : "plc-left-2 md:plc-left-10"}`,
|
|
36425
|
-
onClick: closeSubMenusTab
|
|
36426
|
-
}, /*#__PURE__*/React__default.createElement(SvgXIcon, {
|
|
36427
|
-
className: "plc-fill-current"
|
|
36428
36418
|
}))));
|
|
36429
36419
|
};
|
|
36430
36420
|
|
|
@@ -37117,6 +37107,7 @@ const Card = ({
|
|
|
37117
37107
|
className = "",
|
|
37118
37108
|
title,
|
|
37119
37109
|
requestStates,
|
|
37110
|
+
dashboardLayout,
|
|
37120
37111
|
back,
|
|
37121
37112
|
...restProps
|
|
37122
37113
|
}) => {
|
|
@@ -37124,11 +37115,16 @@ const Card = ({
|
|
|
37124
37115
|
const {
|
|
37125
37116
|
switchDashboardView
|
|
37126
37117
|
} = usePelcro();
|
|
37118
|
+
|
|
37119
|
+
const closeSubMenusTab = () => {
|
|
37120
|
+
switchDashboardView(null);
|
|
37121
|
+
};
|
|
37122
|
+
|
|
37127
37123
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
37128
|
-
className: `plc-bg-white plc-border-2 plc-p-6 md:plc-p-8 plc-rounded plc-my-11 md:plc-mb-20 md:plc-mt-40 ${className}`,
|
|
37124
|
+
className: `plc-relative plc-bg-white plc-border-2 plc-p-6 md:plc-p-8 plc-rounded plc-my-11 md:plc-mb-20 md:plc-mt-40 ${className}`,
|
|
37129
37125
|
id: "plc-dashboard-card"
|
|
37130
37126
|
}, title && /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement("div", {
|
|
37131
|
-
className: "plc-flex plc-items-end plc-justify-between plc-border-b-2 plc-border-primary-400 plc-pb-2 plc-mb-10"
|
|
37127
|
+
className: "plc-flex plc-items-end plc-justify-between plc-border-b-2 plc-border-primary-400 plc-pb-2 plc-mb-10 plc-mt-5"
|
|
37132
37128
|
}, /*#__PURE__*/React__default.createElement("h3", {
|
|
37133
37129
|
className: "plc-font-bold plc-text-xl"
|
|
37134
37130
|
}, title), (requestStates === null || requestStates === void 0 ? void 0 : requestStates.loading) && /*#__PURE__*/React__default.createElement("span", {
|
|
@@ -37141,7 +37137,14 @@ const Card = ({
|
|
|
37141
37137
|
onClick: () => {
|
|
37142
37138
|
switchDashboardView(back === null || back === void 0 ? void 0 : back.target);
|
|
37143
37139
|
}
|
|
37144
|
-
}, "Back"))), children
|
|
37140
|
+
}, "Back"))), children, /*#__PURE__*/React__default.createElement(Button, {
|
|
37141
|
+
variant: "ghost",
|
|
37142
|
+
type: "button",
|
|
37143
|
+
className: "plc-text-gray-500 plc-rounded-2xl plc-absolute plc-z-max plc-top-1 plc-right-1",
|
|
37144
|
+
onClick: closeSubMenusTab
|
|
37145
|
+
}, /*#__PURE__*/React__default.createElement(SvgXIcon, {
|
|
37146
|
+
className: "plc-fill-current"
|
|
37147
|
+
})));
|
|
37145
37148
|
};
|
|
37146
37149
|
|
|
37147
37150
|
const ProfileMenu = props => {
|
package/dist/pelcro.css
CHANGED
|
@@ -2044,10 +2044,6 @@ apple-pay-button {
|
|
|
2044
2044
|
top: 0.25rem;
|
|
2045
2045
|
}
|
|
2046
2046
|
|
|
2047
|
-
.pelcro-root .plc-top-2{
|
|
2048
|
-
top: 0.5rem;
|
|
2049
|
-
}
|
|
2050
|
-
|
|
2051
2047
|
.pelcro-root .plc-top-4{
|
|
2052
2048
|
top: 1rem;
|
|
2053
2049
|
}
|
|
@@ -2120,10 +2116,6 @@ apple-pay-button {
|
|
|
2120
2116
|
left: 0px;
|
|
2121
2117
|
}
|
|
2122
2118
|
|
|
2123
|
-
.pelcro-root .plc-left-2{
|
|
2124
|
-
left: 0.5rem;
|
|
2125
|
-
}
|
|
2126
|
-
|
|
2127
2119
|
.pelcro-root .plc-left-4{
|
|
2128
2120
|
left: 1rem;
|
|
2129
2121
|
}
|
|
@@ -3852,18 +3844,6 @@ apple-pay-button {
|
|
|
3852
3844
|
}
|
|
3853
3845
|
|
|
3854
3846
|
@media (min-width: 768px){
|
|
3855
|
-
.pelcro-root .md\:plc-top-5{
|
|
3856
|
-
top: 1.25rem;
|
|
3857
|
-
}
|
|
3858
|
-
|
|
3859
|
-
.pelcro-root .md\:plc-right-10{
|
|
3860
|
-
right: 2.5rem;
|
|
3861
|
-
}
|
|
3862
|
-
|
|
3863
|
-
.pelcro-root .md\:plc-left-10{
|
|
3864
|
-
left: 2.5rem;
|
|
3865
|
-
}
|
|
3866
|
-
|
|
3867
3847
|
.pelcro-root .md\:plc-mx-auto{
|
|
3868
3848
|
margin-left: auto;
|
|
3869
3849
|
margin-right: auto;
|