salla-next-order-coupon
Shows the "coupon for your next order" offered by the store, with its discount amount, minimum spend, expiry date, a button to copy the code and a "shop now" button.
Shows the "coupon for your next order" offered by the store, with its discount amount, minimum spend, expiry date, a button to copy the code and a "shop now" button. Use it on the order thank-you page. It has no attributes: it loads the store's thank-you coupon by itself (the first one returned), shows a placeholder while loading, and renders nothing when there is no coupon or loading fails.
When the customer copies the code, it shows a success notification and dispatches the salla::next-order-coupon.code.copied event through salla.event, with { code } as the payload.
Use it
In HTML or JSX, use the tag <salla-next-order-coupon> with the Attribute names below. In React, the wrapper takes the Property names (camelCase).
import { SallaNextOrderCoupon } from '@salla.sa/twilight-components-react/next-order-coupon';Example
import { SallaNextOrderCoupon } from '@salla.sa/twilight-components-react/next-order-coupon';
export function Example() {
return (
<SallaNextOrderCoupon />
);
}Related
Renders: <salla-skeleton>, <salla-button>.
salla-installment
Shows the "pay in installments" promo widgets of the installment providers the store has enabled (Tamara, Tabby, Spotii, Mispay, Emkan, Madfu, Mokafaa Alrajhi points and Klarna) for a given price.
salla-offer
Shows the store's special offers (special price, buy X get Y, discounts table, bank, percentage and fixed discounts) as a carousel of cards, with a "show more" card and modals when there are more than