kupos-ui-components-lib 10.3.4 → 10.3.6
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/ui/BottomAmenities/BottomAmenities.js +1 -1
- package/dist/ui/mobileweb/SeatSectionMobile.d.ts +1 -0
- package/dist/ui/mobileweb/SeatSectionMobile.js +3 -1
- package/package.json +1 -1
- package/src/ui/BottomAmenities/BottomAmenities.tsx +1 -1
- package/src/ui/mobileweb/SeatSectionMobile.tsx +17 -14
|
@@ -13,7 +13,7 @@ function BottomAmenities({ otherItems, serviceItem, grayscaleClass, isSoldOut, i
|
|
|
13
13
|
React.createElement("div", { className: "grid items-center gap-[2%] flex-1 ", style: {
|
|
14
14
|
// gridTemplateColumns: " 28% 21% 23% 23%",
|
|
15
15
|
gridTemplateColumns: isTrain
|
|
16
|
-
? "
|
|
16
|
+
? "25.6% 17% 23% 23%"
|
|
17
17
|
: "25.3% 17% 23% 23%",
|
|
18
18
|
} }, otherItems.map((item) => (React.createElement("div", { key: item.key, className: "flex items-center" }, item.render)))),
|
|
19
19
|
React.createElement("div", { className: "flex items-center justify-end shrink-0 ml-[5px] w-[150px]" },
|
|
@@ -131,7 +131,9 @@ function SeatSectionMobile({ seatTypes: seatTypesData, isSoldOut, isPeru, seatPr
|
|
|
131
131
|
return uniqueSeats.map((type, i) => (React.createElement(SeatRow, { key: i, type: type, index: i, displayLabel: commonService.truncateSeatLabel(type.label), fare: getFare(type.fare), isSoldOut: isSoldOut, seatPriceColor: seatPriceColor, hasMultipleTypes: hasMultipleTypes, textSize: "text-[11px]", isTrain: isTrain })));
|
|
132
132
|
}
|
|
133
133
|
const filteredSeats = (_a = seatTypesData === null || seatTypesData === void 0 ? void 0 : seatTypesData.filter((item) => getFilteredSeats(item.label))) === null || _a === void 0 ? void 0 : _a.sort((a, b) => a.fare - b.fare);
|
|
134
|
-
return (_b = (isTrain ? filteredSeats : filteredSeats === null || filteredSeats === void 0 ? void 0 : filteredSeats.slice(0, 2))) === null || _b === void 0 ? void 0 : _b.map((type, i) =>
|
|
134
|
+
return (_b = (isTrain ? filteredSeats : filteredSeats === null || filteredSeats === void 0 ? void 0 : filteredSeats.slice(0, 2))) === null || _b === void 0 ? void 0 : _b.map((type, i) => {
|
|
135
|
+
return (React.createElement(SeatRow, { key: i, type: type, index: i, displayLabel: isTrain ? type.api_seat_type : type.label, fare: getFare(type.fare), isSoldOut: isSoldOut, seatPriceColor: seatPriceColor, hasMultipleTypes: hasMultipleTypes, textSize: "text-[12px]", isTrain: isTrain }));
|
|
136
|
+
});
|
|
135
137
|
};
|
|
136
138
|
const seats = removeDuplicateSeats
|
|
137
139
|
? getUniqueSeats(seatTypesData, 3)
|
package/package.json
CHANGED
|
@@ -17,6 +17,7 @@ interface SeatType {
|
|
|
17
17
|
label: string;
|
|
18
18
|
key?: string;
|
|
19
19
|
fare: number;
|
|
20
|
+
api_seat_type?: string;
|
|
20
21
|
}
|
|
21
22
|
|
|
22
23
|
interface SeatSectionMobileProps {
|
|
@@ -345,20 +346,22 @@ function SeatSectionMobile({
|
|
|
345
346
|
?.sort((a, b) => a.fare - b.fare);
|
|
346
347
|
|
|
347
348
|
return (isTrain ? filteredSeats : filteredSeats?.slice(0, 2))?.map(
|
|
348
|
-
(type, i) =>
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
349
|
+
(type, i) => {
|
|
350
|
+
return (
|
|
351
|
+
<SeatRow
|
|
352
|
+
key={i}
|
|
353
|
+
type={type}
|
|
354
|
+
index={i}
|
|
355
|
+
displayLabel={isTrain ? type.api_seat_type : type.label}
|
|
356
|
+
fare={getFare(type.fare)}
|
|
357
|
+
isSoldOut={isSoldOut}
|
|
358
|
+
seatPriceColor={seatPriceColor}
|
|
359
|
+
hasMultipleTypes={hasMultipleTypes}
|
|
360
|
+
textSize="text-[12px]"
|
|
361
|
+
isTrain={isTrain}
|
|
362
|
+
/>
|
|
363
|
+
);
|
|
364
|
+
},
|
|
362
365
|
);
|
|
363
366
|
};
|
|
364
367
|
|