@travories/frontend-sdk 0.1.3 → 0.1.5
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/README.md +334 -169
- package/dist/index.d.mts +20 -15
- package/dist/index.d.ts +20 -15
- package/dist/index.js +3 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +3 -2
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -999,10 +999,11 @@ var BookingCardLite = ({
|
|
|
999
999
|
const handleReserve = () => {
|
|
1000
1000
|
if (!onReserve) return;
|
|
1001
1001
|
if (allPeopleCount === 0) return;
|
|
1002
|
+
const travelers = options.filter((o) => o.count > 0).map((o) => ({ name: o.name, count: o.count }));
|
|
1002
1003
|
const result = onReserve({
|
|
1003
1004
|
arrival,
|
|
1004
1005
|
departure,
|
|
1005
|
-
travelers
|
|
1006
|
+
travelers,
|
|
1006
1007
|
totalCost,
|
|
1007
1008
|
pricePerPerson: currentPrice
|
|
1008
1009
|
});
|
|
@@ -2076,7 +2077,7 @@ var DescriptionSection = ({
|
|
|
2076
2077
|
{
|
|
2077
2078
|
DescriptionData,
|
|
2078
2079
|
currency,
|
|
2079
|
-
onReserve: onReserve ? () => onReserve(pkg) : void 0
|
|
2080
|
+
onReserve: onReserve ? (booking) => onReserve({ pkg, ...booking }) : void 0
|
|
2080
2081
|
}
|
|
2081
2082
|
) })
|
|
2082
2083
|
]
|