Skip to main content

RenewStayModal

packages/mobility/components/molecules/RenewStayModal.js · Tier: molecule · Module: mobility · Rendering: Client Component ('use client')

Purpose​

A lightweight modal hosting a duration slider for renewing an active street reservation. On submit (after validation) it opens a Stripe Embedded Checkout inside the same modal; payment triggers the backend renewal via the /{lang}/mobility/parking-checkout/return return page. The parent remounts it with a fresh key per reservation target so internal state resets.

Props​

PropTypeRequiredDefaultDescription
openbooleanyes—Visibility.
reservation{ id, carId, licensePlate, latitude, longitude } | nullyes—The reservation to renew.
labelsobjectyes—Modal copy.
stayLabelsobjectyes—Stay/duration copy.
langstringyes—Locale (checkout return path).
onClose() => voidyes—Close handler.

Composition​

  • Uses: molecules/core/Modal, atoms/core/DurationSlider, molecules/core/StripeCheckoutEmbed, the mobility Stripe-checkout action.
  • Used by: organisms/mobility/StaysPanel.

Internationalisation​

Copy via labels / stayLabels.

Accessibility​

The accessible core/Modal; the slider carries its own labelling.

atoms/core/DurationSlider, molecules/core/StripeCheckoutEmbed, organisms/mobility/StaysPanel.