@asdp/ferryui 0.1.22-dev.10391 → 0.1.22-dev.10407

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.mjs CHANGED
@@ -283,6 +283,8 @@ var foundationColors = {
283
283
  "Foundation_Danger_error": "#FD3A3A"
284
284
  };
285
285
  var lightModeColors = {
286
+ "Neutral_Background_2_Hover": "#f0f0f0",
287
+ "Neutral_Background_3_Pressed": "#d6d6d6",
286
288
  "Neutral_Foreground_Disabled_Rest": "#bdbdbd",
287
289
  "Brand_Stroke_1_Rest": "#00B3BD"};
288
290
  var tokensV2_default = {
@@ -13881,6 +13883,9 @@ var DEFAULT_LABELS27 = {
13881
13883
  routeTitle: "Rute Perjalanan",
13882
13884
  estimationPrefix: "Estimasi",
13883
13885
  totalPriceLabel: "Total Harga",
13886
+ agreementPrefix: "Saya menyetujui",
13887
+ termsAndConditions: "Syarat & Ketentuan",
13888
+ agreementSuffix: "Ferizy",
13884
13889
  nextButton: "Lanjutkan",
13885
13890
  cancelButton: "Batalkan Pesanan",
13886
13891
  previousButton: "Sebelumnya",
@@ -13898,6 +13903,9 @@ var DEFAULT_LABELS27 = {
13898
13903
  routeTitle: "Travel Route",
13899
13904
  estimationPrefix: "Estimation",
13900
13905
  totalPriceLabel: "Total Price",
13906
+ agreementPrefix: "I agree to the",
13907
+ termsAndConditions: "Terms & Conditions",
13908
+ agreementSuffix: "Ferizy",
13901
13909
  nextButton: "Continue",
13902
13910
  cancelButton: "Cancel Booking",
13903
13911
  previousButton: "Previous",
@@ -13986,7 +13994,14 @@ var useStyles28 = makeStyles({
13986
13994
  display: "flex",
13987
13995
  justifyContent: "space-between",
13988
13996
  alignItems: "center",
13989
- gap: "0.5em"
13997
+ gap: "0.5em",
13998
+ backgroundColor: lightModeColors.Neutral_Background_2_Hover,
13999
+ ...shorthands.padding(
14000
+ tokens.spacingHorizontalM,
14001
+ tokens.spacingHorizontalMNudge
14002
+ ),
14003
+ border: `${tokens.strokeWidthThin} solid ${lightModeColors.Neutral_Background_3_Pressed}`,
14004
+ borderRadius: tokens.borderRadiusXLarge
13990
14005
  },
13991
14006
  ticketTime: {
13992
14007
  display: "flex",
@@ -14071,6 +14086,7 @@ var CardBookingTicket = ({
14071
14086
  reservationStep,
14072
14087
  paymentStep,
14073
14088
  onPriceDetailClick,
14089
+ onTermsAndConditionsClick,
14074
14090
  onCancel,
14075
14091
  onNext,
14076
14092
  onPrevious,
@@ -14079,6 +14095,9 @@ var CardBookingTicket = ({
14079
14095
  const styles = useStyles28();
14080
14096
  const mergedLabels = { ...DEFAULT_LABELS27[language], ...labels };
14081
14097
  const [cancelDialogOpen, setCancelDialogOpen] = useState(false);
14098
+ const handleTermsAndConditionsClick = () => {
14099
+ onTermsAndConditionsClick?.();
14100
+ };
14082
14101
  return /* @__PURE__ */ jsx("div", { className: `${styles.container} ${className || ""}`, children: /* @__PURE__ */ jsxs("div", { className: styles.bookingDetail, children: [
14083
14102
  /* @__PURE__ */ jsxs(Card, { className: styles.bookingDetailTop, children: [
14084
14103
  /* @__PURE__ */ jsx(Subtitle1, { children: mergedLabels.bookingDetails }),
@@ -14126,7 +14145,7 @@ var CardBookingTicket = ({
14126
14145
  {
14127
14146
  style: {
14128
14147
  height: "1px",
14129
- backgroundColor: tokens.colorNeutralStroke2,
14148
+ backgroundColor: "tokens.colorNeutralStroke2",
14130
14149
  margin: "1rem 0"
14131
14150
  }
14132
14151
  }
@@ -14158,22 +14177,58 @@ var CardBookingTicket = ({
14158
14177
  /* @__PURE__ */ jsxs(Card, { className: styles.bookingDetailBottom, children: [
14159
14178
  /* @__PURE__ */ jsxs("div", { className: styles.totalPrice, children: [
14160
14179
  /* @__PURE__ */ jsx(Subtitle1, { children: mergedLabels.totalPriceLabel }),
14161
- /* @__PURE__ */ jsxs("div", { style: { display: "flex", gap: tokens.spacingHorizontalL, alignItems: "center" }, children: [
14162
- /* @__PURE__ */ jsxs(Title3, { className: styles.priceText, children: [
14163
- mergedLabels.currencySymbol,
14164
- " ",
14165
- totalPrice
14166
- ] }),
14167
- /* @__PURE__ */ jsx(
14168
- Icon,
14169
- {
14170
- icon: "fluent:chevron-down-24-filled",
14171
- onClick: onPriceDetailClick,
14172
- style: { cursor: "pointer" }
14173
- }
14174
- )
14175
- ] })
14180
+ /* @__PURE__ */ jsxs(
14181
+ "div",
14182
+ {
14183
+ style: {
14184
+ display: "flex",
14185
+ gap: tokens.spacingHorizontalL,
14186
+ alignItems: "center"
14187
+ },
14188
+ children: [
14189
+ /* @__PURE__ */ jsxs(Title3, { className: styles.priceText, children: [
14190
+ mergedLabels.currencySymbol,
14191
+ " ",
14192
+ totalPrice
14193
+ ] }),
14194
+ /* @__PURE__ */ jsx(
14195
+ Icon,
14196
+ {
14197
+ icon: "fluent:chevron-down-24-filled",
14198
+ onClick: onPriceDetailClick,
14199
+ style: { cursor: "pointer" }
14200
+ }
14201
+ )
14202
+ ]
14203
+ }
14204
+ )
14176
14205
  ] }),
14206
+ reservationStep === "review" && /* @__PURE__ */ jsx(
14207
+ Checkbox,
14208
+ {
14209
+ label: /* @__PURE__ */ jsxs(Body1, { children: [
14210
+ mergedLabels.agreementPrefix,
14211
+ " ",
14212
+ /* @__PURE__ */ jsx(
14213
+ "button",
14214
+ {
14215
+ type: "button",
14216
+ onClick: handleTermsAndConditionsClick,
14217
+ style: {
14218
+ color: brandColors[80],
14219
+ background: "transparent",
14220
+ border: "none",
14221
+ padding: 0,
14222
+ cursor: "pointer"
14223
+ },
14224
+ children: mergedLabels.termsAndConditions
14225
+ }
14226
+ ),
14227
+ " ",
14228
+ mergedLabels.agreementSuffix
14229
+ ] })
14230
+ }
14231
+ ),
14177
14232
  /* @__PURE__ */ jsxs("div", { className: styles.gapButton, children: [
14178
14233
  !(paymentStep === "pay") && /* @__PURE__ */ jsx(
14179
14234
  Button,
@@ -15466,7 +15521,8 @@ var useStyles34 = makeStyles({
15466
15521
  boxShadow: "none",
15467
15522
  border: `${tokens.strokeWidthThin} solid ${tokens.colorNeutralStroke1}`,
15468
15523
  borderRadius: tokens.borderRadiusXLarge,
15469
- padding: `${tokens.spacingHorizontalL} ${tokens.spacingHorizontalXXL}`
15524
+ padding: `${tokens.spacingHorizontalL} ${tokens.spacingHorizontalXXL}`,
15525
+ zIndex: 10
15470
15526
  },
15471
15527
  titleRow: {
15472
15528
  display: "flex",
@@ -15553,9 +15609,14 @@ var CardReviewPassenger = ({
15553
15609
  ] }) }) }, index)) : passengers.map((passenger, index) => {
15554
15610
  const badgeConfig = getBadgeConfig(passenger.serviceClass);
15555
15611
  const passengerMeta = `${passenger.ageLabel} \xB7 ${mergedLabels.idNumber} ${passenger.identityNumber}`;
15612
+ const passengerTitle = passenger.titleName?.trim() || "Tuan";
15556
15613
  return /* @__PURE__ */ jsx(Col, { xs: 12, children: /* @__PURE__ */ jsx(Card, { className: styles.passengerCard, children: /* @__PURE__ */ jsxs(Row, { nogutter: true, className: styles.passengerRow, children: [
15557
15614
  /* @__PURE__ */ jsx(Col, { children: /* @__PURE__ */ jsxs("div", { className: styles.passengerInfo, children: [
15558
- /* @__PURE__ */ jsx(Subtitle2, { className: styles.passengerName, children: passenger.name }),
15615
+ /* @__PURE__ */ jsxs(Subtitle2, { className: styles.passengerName, children: [
15616
+ passengerTitle,
15617
+ " ",
15618
+ passenger.name
15619
+ ] }),
15559
15620
  /* @__PURE__ */ jsx(Body1, { className: styles.passengerMeta, children: passengerMeta })
15560
15621
  ] }) }),
15561
15622
  /* @__PURE__ */ jsx(Col, { xs: "content", children: /* @__PURE__ */ jsxs(