@scopetickets/checkout 0.1.3 → 0.4.0
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 +3 -3
- package/dist/{chunk-GJZKPJB5.js → chunk-WT7WSYIH.js} +1731 -252
- package/dist/chunk-WT7WSYIH.js.map +1 -0
- package/dist/index.cjs +6048 -3349
- package/dist/index.cjs.map +1 -1
- package/dist/index.css.map +1 -1
- package/dist/index.d.cts +302 -192
- package/dist/index.d.ts +302 -192
- package/dist/index.js +5620 -4323
- package/dist/index.js.map +1 -1
- package/dist/pickers.cjs +154 -76
- package/dist/pickers.cjs.map +1 -1
- package/dist/pickers.css +20 -2
- package/dist/pickers.css.map +1 -1
- package/dist/pickers.d.cts +55 -54
- package/dist/pickers.d.ts +55 -54
- package/dist/pickers.js +1 -1
- package/dist/styles.css +39 -7
- package/package.json +12 -10
- package/dist/chunk-GJZKPJB5.js.map +0 -1
package/dist/pickers.d.cts
CHANGED
|
@@ -18,24 +18,12 @@ export declare function addDays(day: string, count: number): string;
|
|
|
18
18
|
export declare function assignmentFor(product: Partial<Pick<Ticket, 'UserTypes'>>, key: string): string | undefined;
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
|
-
* THE RAMP THE
|
|
22
|
-
*
|
|
21
|
+
* THE RAMP AS THE WEB PAINTS IT — a `color-mix()` over the ramp's TOKENS rather than a
|
|
22
|
+
* computed hex, so the light appearance swaps underneath it. The ramp is a different
|
|
23
|
+
* three colours there, and a value resolved in JS would be the dark one on both.
|
|
23
24
|
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
* second, differently-grouped reading of one number: the ring could be yellow on a slot
|
|
27
|
-
* the announcement calls high, and neither would be wrong on its own terms. Pinned to
|
|
28
|
-
* 2/3 and 1/3, the colour can only ever be inside the band its own level names —
|
|
29
|
-
* `readAvailability`'s note, applied to paint instead of to words.
|
|
30
|
-
*
|
|
31
|
-
* CONTINUOUS BETWEEN THOSE STOPS, because the arc beside it is. The ring draws the raw
|
|
32
|
-
* decimal, so a colour that stepped in three would say the slot had moved when the arc
|
|
33
|
-
* said it had not. The platform quantises `Remaining` to quarters TODAY and does not
|
|
34
|
-
* promise to; interpolating costs nothing if it stops.
|
|
35
|
-
*
|
|
36
|
-
* Returns a `color-mix()` over the ramp's TOKENS rather than a computed hex, so the
|
|
37
|
-
* light appearance swaps underneath it — the ramp is a different three colours there,
|
|
38
|
-
* and a value resolved in JS would be the dark one on both.
|
|
25
|
+
* A flat token at each end rather than a colour mixed with itself: the two are the same
|
|
26
|
+
* paint, and the shorter string is the one a stylesheet test can read.
|
|
39
27
|
*/
|
|
40
28
|
export declare function availabilityColor(remaining: number | null): string;
|
|
41
29
|
|
|
@@ -365,28 +353,6 @@ export declare function formatSlotRange(startTime: string, endTime: string | nul
|
|
|
365
353
|
*/
|
|
366
354
|
export declare function formatWeekdayAndDate(day: string): string;
|
|
367
355
|
|
|
368
|
-
/**
|
|
369
|
-
* WHO THE TICKETS ARE FOR — the party step's rows, and the keys they are spent as.
|
|
370
|
-
*
|
|
371
|
-
* `AssignmentKey` IS NOT A USER TYPE. It identifies one ASSIGNMENT of a type to a product
|
|
372
|
-
* on an event. Measured on sandbox 2026-09-10, TwinkleTown — 38 events × 2 products × 3
|
|
373
|
-
* types — `EventInformation` answers with 228 entries and 228 distinct keys, 76 of them
|
|
374
|
-
* named "Child". So de-duplicating on the key cannot help: every one is already distinct.
|
|
375
|
-
* `Name` is the only field that identifies what a buyer is choosing.
|
|
376
|
-
*
|
|
377
|
-
* THE SAME NAME IS NOT THE SAME OFFER, which is why the assignments are not collapsed
|
|
378
|
-
* away: Child is 550 off Peak and 450 off Off-Peak, and needs ID on one and not the other.
|
|
379
|
-
* The type is what the buyer picks; the assignment is what it costs, and that is not
|
|
380
|
-
* settled until a product is.
|
|
381
|
-
*
|
|
382
|
-
* WHICH IS WHY THE KEY IS RESOLVED LATE. `PARTY` runs before `DATE` and `TIME`, so when
|
|
383
|
-
* the buyer picks "Child" there is no product for an assignment to belong to — the product
|
|
384
|
-
* is `productForSession`, decided by the timeslot. Committing to a key there means sending
|
|
385
|
-
* Peak's against an Off-Peak product, and a bulk add that refuses an unknown key leaves no
|
|
386
|
-
* cart at all. So the composition is keyed by NAME and `assignmentFor` converts it once
|
|
387
|
-
* `useCheckoutOrder` holds the product.
|
|
388
|
-
*/
|
|
389
|
-
|
|
390
356
|
/**
|
|
391
357
|
* THE DISTINCT TYPES, in the order the platform first names each — the organiser's own,
|
|
392
358
|
* and re-sorting on every fetch would move the rows under the pointer.
|
|
@@ -511,20 +477,12 @@ export declare type PartyStepperProps = {
|
|
|
511
477
|
readonly refused?: number | null;
|
|
512
478
|
};
|
|
513
479
|
|
|
514
|
-
/**
|
|
515
|
-
* THE PARTY STEP — one stepper per user type, or a single line when the event offers
|
|
516
|
-
* none.
|
|
517
|
-
*
|
|
518
|
-
* Controlled: the caller holds the counts, because the composition belongs to the order
|
|
519
|
-
* rather than to the control that edits it. `max` is the ticket's ceiling and is the
|
|
520
|
-
* caller's too — a row has no opinion about how many people a party may hold.
|
|
521
|
-
*/
|
|
522
480
|
/** A user type the event offers, as the row needs it. */
|
|
523
481
|
export declare type PartyUserTypeOption = {
|
|
524
482
|
/**
|
|
525
483
|
* WHAT THE COMPOSITION COUNTS UNDER. The platform's types are keyed by NAME, because an
|
|
526
|
-
* assignment key belongs to a product no one has chosen yet — see
|
|
527
|
-
* supplying its own may key them however it likes.
|
|
484
|
+
* assignment key belongs to a product no one has chosen yet — see this module's header.
|
|
485
|
+
* A host supplying its own may key them however it likes.
|
|
528
486
|
*/
|
|
529
487
|
readonly key: string;
|
|
530
488
|
/** Always present: an event with no discount types still offers a default. */
|
|
@@ -562,6 +520,34 @@ export declare type RingDirection = 'cw' | 'ccw';
|
|
|
562
520
|
/** Whether two lists of slots say the same thing. */
|
|
563
521
|
export declare function sameTimeslots(a: readonly Timeslot[], b: readonly Timeslot[]): boolean;
|
|
564
522
|
|
|
523
|
+
/** One way into a session: a band by the name a party is counted under, and its unit price. */
|
|
524
|
+
declare type SlotBand = {
|
|
525
|
+
readonly name: string;
|
|
526
|
+
readonly minorUnits: number;
|
|
527
|
+
};
|
|
528
|
+
|
|
529
|
+
/**
|
|
530
|
+
* WHAT A SESSION COSTS.
|
|
531
|
+
*
|
|
532
|
+
* `minorUnits` IS THE FLOOR — the cheapest single admission, which is what a row can say
|
|
533
|
+
* before anybody has said who is coming.
|
|
534
|
+
*
|
|
535
|
+
* `options` IS HOW IT BECOMES A TOTAL. One list of bands per product that sells the session,
|
|
536
|
+
* because the price of a party is not a property of the session alone: two Adults and a
|
|
537
|
+
* Child is a different number from three Adults, and the difference is only knowable once
|
|
538
|
+
* the party is. `priceComposition` spends this; nothing else needs to.
|
|
539
|
+
*
|
|
540
|
+
* ONE LIST PER PRODUCT AND NOT ONE MERGED LIST, because a composition has to be priced
|
|
541
|
+
* against a product that can serve ALL of it. Merging two tickets' bands would let a total
|
|
542
|
+
* be built out of an Adult from one and a Child from the other, at a price no single cart
|
|
543
|
+
* line could be filled at.
|
|
544
|
+
*/
|
|
545
|
+
declare type SlotPrice = {
|
|
546
|
+
readonly minorUnits: number;
|
|
547
|
+
readonly currency: string;
|
|
548
|
+
readonly options?: readonly (readonly SlotBand[])[];
|
|
549
|
+
};
|
|
550
|
+
|
|
565
551
|
/** The key the single line counts under when the event names no types. */
|
|
566
552
|
export declare const SOLO_KEY = "default";
|
|
567
553
|
|
|
@@ -645,6 +631,11 @@ declare interface Ticket {
|
|
|
645
631
|
* response spanning a whole series is split back into days.
|
|
646
632
|
*/
|
|
647
633
|
EventKeys?: string[] | null;
|
|
634
|
+
/**
|
|
635
|
+
* The inventories this product is sold from — the event's own `(Main)` one and any named
|
|
636
|
+
* ones that silo an allocation across events. Sent by `TicketInformation`.
|
|
637
|
+
*/
|
|
638
|
+
InventoryKeys?: string[] | null;
|
|
648
639
|
}
|
|
649
640
|
|
|
650
641
|
/** The time it is right now on a given zone's clock, as `HH:MM`. */
|
|
@@ -710,11 +701,6 @@ export declare type TimeSelection = {
|
|
|
710
701
|
readonly startTime: string | null;
|
|
711
702
|
};
|
|
712
703
|
|
|
713
|
-
/**
|
|
714
|
-
* The times within one day that a ticket is sold for — the timeslot picker's whole
|
|
715
|
-
* domain.
|
|
716
|
-
*/
|
|
717
|
-
|
|
718
704
|
/** One slot a ticket is sold for. */
|
|
719
705
|
export declare type Timeslot = {
|
|
720
706
|
/**
|
|
@@ -729,6 +715,21 @@ export declare type Timeslot = {
|
|
|
729
715
|
* reports it. Null where the slot does not say.
|
|
730
716
|
*/
|
|
731
717
|
readonly remaining: number | null;
|
|
718
|
+
/**
|
|
719
|
+
* THE CHEAPEST WAY INTO THIS SESSION, where the host knows one. Absent draws no price,
|
|
720
|
+
* which is the default and what every existing caller gets.
|
|
721
|
+
*
|
|
722
|
+
* COMPUTED, NEVER READ. A slot carries no money on the wire — `EventTimeslot` is two
|
|
723
|
+
* times, a total and a remaining — so a price is reached through the TICKET that owns
|
|
724
|
+
* the slot, and the discount bands hang off that ticket too. `slot-price.ts` is the
|
|
725
|
+
* package's answer to all of that, and `runView` spends it for the schedule the widget
|
|
726
|
+
* builds itself; a host composing its own rows reaches the same functions.
|
|
727
|
+
*
|
|
728
|
+
* SO THIS IS A FIGURE AND NOT A RULE. The picker writes the word in front of it and
|
|
729
|
+
* formats the money — that is copy and presentation, which stay here — and takes no view
|
|
730
|
+
* on how the number was arrived at.
|
|
731
|
+
*/
|
|
732
|
+
readonly fromPrice?: SlotPrice | null;
|
|
732
733
|
};
|
|
733
734
|
|
|
734
735
|
/** One slot, resolved: what it is, when it is, and what it can do. */
|
package/dist/pickers.d.ts
CHANGED
|
@@ -18,24 +18,12 @@ export declare function addDays(day: string, count: number): string;
|
|
|
18
18
|
export declare function assignmentFor(product: Partial<Pick<Ticket, 'UserTypes'>>, key: string): string | undefined;
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
|
-
* THE RAMP THE
|
|
22
|
-
*
|
|
21
|
+
* THE RAMP AS THE WEB PAINTS IT — a `color-mix()` over the ramp's TOKENS rather than a
|
|
22
|
+
* computed hex, so the light appearance swaps underneath it. The ramp is a different
|
|
23
|
+
* three colours there, and a value resolved in JS would be the dark one on both.
|
|
23
24
|
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
* second, differently-grouped reading of one number: the ring could be yellow on a slot
|
|
27
|
-
* the announcement calls high, and neither would be wrong on its own terms. Pinned to
|
|
28
|
-
* 2/3 and 1/3, the colour can only ever be inside the band its own level names —
|
|
29
|
-
* `readAvailability`'s note, applied to paint instead of to words.
|
|
30
|
-
*
|
|
31
|
-
* CONTINUOUS BETWEEN THOSE STOPS, because the arc beside it is. The ring draws the raw
|
|
32
|
-
* decimal, so a colour that stepped in three would say the slot had moved when the arc
|
|
33
|
-
* said it had not. The platform quantises `Remaining` to quarters TODAY and does not
|
|
34
|
-
* promise to; interpolating costs nothing if it stops.
|
|
35
|
-
*
|
|
36
|
-
* Returns a `color-mix()` over the ramp's TOKENS rather than a computed hex, so the
|
|
37
|
-
* light appearance swaps underneath it — the ramp is a different three colours there,
|
|
38
|
-
* and a value resolved in JS would be the dark one on both.
|
|
25
|
+
* A flat token at each end rather than a colour mixed with itself: the two are the same
|
|
26
|
+
* paint, and the shorter string is the one a stylesheet test can read.
|
|
39
27
|
*/
|
|
40
28
|
export declare function availabilityColor(remaining: number | null): string;
|
|
41
29
|
|
|
@@ -365,28 +353,6 @@ export declare function formatSlotRange(startTime: string, endTime: string | nul
|
|
|
365
353
|
*/
|
|
366
354
|
export declare function formatWeekdayAndDate(day: string): string;
|
|
367
355
|
|
|
368
|
-
/**
|
|
369
|
-
* WHO THE TICKETS ARE FOR — the party step's rows, and the keys they are spent as.
|
|
370
|
-
*
|
|
371
|
-
* `AssignmentKey` IS NOT A USER TYPE. It identifies one ASSIGNMENT of a type to a product
|
|
372
|
-
* on an event. Measured on sandbox 2026-09-10, TwinkleTown — 38 events × 2 products × 3
|
|
373
|
-
* types — `EventInformation` answers with 228 entries and 228 distinct keys, 76 of them
|
|
374
|
-
* named "Child". So de-duplicating on the key cannot help: every one is already distinct.
|
|
375
|
-
* `Name` is the only field that identifies what a buyer is choosing.
|
|
376
|
-
*
|
|
377
|
-
* THE SAME NAME IS NOT THE SAME OFFER, which is why the assignments are not collapsed
|
|
378
|
-
* away: Child is 550 off Peak and 450 off Off-Peak, and needs ID on one and not the other.
|
|
379
|
-
* The type is what the buyer picks; the assignment is what it costs, and that is not
|
|
380
|
-
* settled until a product is.
|
|
381
|
-
*
|
|
382
|
-
* WHICH IS WHY THE KEY IS RESOLVED LATE. `PARTY` runs before `DATE` and `TIME`, so when
|
|
383
|
-
* the buyer picks "Child" there is no product for an assignment to belong to — the product
|
|
384
|
-
* is `productForSession`, decided by the timeslot. Committing to a key there means sending
|
|
385
|
-
* Peak's against an Off-Peak product, and a bulk add that refuses an unknown key leaves no
|
|
386
|
-
* cart at all. So the composition is keyed by NAME and `assignmentFor` converts it once
|
|
387
|
-
* `useCheckoutOrder` holds the product.
|
|
388
|
-
*/
|
|
389
|
-
|
|
390
356
|
/**
|
|
391
357
|
* THE DISTINCT TYPES, in the order the platform first names each — the organiser's own,
|
|
392
358
|
* and re-sorting on every fetch would move the rows under the pointer.
|
|
@@ -511,20 +477,12 @@ export declare type PartyStepperProps = {
|
|
|
511
477
|
readonly refused?: number | null;
|
|
512
478
|
};
|
|
513
479
|
|
|
514
|
-
/**
|
|
515
|
-
* THE PARTY STEP — one stepper per user type, or a single line when the event offers
|
|
516
|
-
* none.
|
|
517
|
-
*
|
|
518
|
-
* Controlled: the caller holds the counts, because the composition belongs to the order
|
|
519
|
-
* rather than to the control that edits it. `max` is the ticket's ceiling and is the
|
|
520
|
-
* caller's too — a row has no opinion about how many people a party may hold.
|
|
521
|
-
*/
|
|
522
480
|
/** A user type the event offers, as the row needs it. */
|
|
523
481
|
export declare type PartyUserTypeOption = {
|
|
524
482
|
/**
|
|
525
483
|
* WHAT THE COMPOSITION COUNTS UNDER. The platform's types are keyed by NAME, because an
|
|
526
|
-
* assignment key belongs to a product no one has chosen yet — see
|
|
527
|
-
* supplying its own may key them however it likes.
|
|
484
|
+
* assignment key belongs to a product no one has chosen yet — see this module's header.
|
|
485
|
+
* A host supplying its own may key them however it likes.
|
|
528
486
|
*/
|
|
529
487
|
readonly key: string;
|
|
530
488
|
/** Always present: an event with no discount types still offers a default. */
|
|
@@ -562,6 +520,34 @@ export declare type RingDirection = 'cw' | 'ccw';
|
|
|
562
520
|
/** Whether two lists of slots say the same thing. */
|
|
563
521
|
export declare function sameTimeslots(a: readonly Timeslot[], b: readonly Timeslot[]): boolean;
|
|
564
522
|
|
|
523
|
+
/** One way into a session: a band by the name a party is counted under, and its unit price. */
|
|
524
|
+
declare type SlotBand = {
|
|
525
|
+
readonly name: string;
|
|
526
|
+
readonly minorUnits: number;
|
|
527
|
+
};
|
|
528
|
+
|
|
529
|
+
/**
|
|
530
|
+
* WHAT A SESSION COSTS.
|
|
531
|
+
*
|
|
532
|
+
* `minorUnits` IS THE FLOOR — the cheapest single admission, which is what a row can say
|
|
533
|
+
* before anybody has said who is coming.
|
|
534
|
+
*
|
|
535
|
+
* `options` IS HOW IT BECOMES A TOTAL. One list of bands per product that sells the session,
|
|
536
|
+
* because the price of a party is not a property of the session alone: two Adults and a
|
|
537
|
+
* Child is a different number from three Adults, and the difference is only knowable once
|
|
538
|
+
* the party is. `priceComposition` spends this; nothing else needs to.
|
|
539
|
+
*
|
|
540
|
+
* ONE LIST PER PRODUCT AND NOT ONE MERGED LIST, because a composition has to be priced
|
|
541
|
+
* against a product that can serve ALL of it. Merging two tickets' bands would let a total
|
|
542
|
+
* be built out of an Adult from one and a Child from the other, at a price no single cart
|
|
543
|
+
* line could be filled at.
|
|
544
|
+
*/
|
|
545
|
+
declare type SlotPrice = {
|
|
546
|
+
readonly minorUnits: number;
|
|
547
|
+
readonly currency: string;
|
|
548
|
+
readonly options?: readonly (readonly SlotBand[])[];
|
|
549
|
+
};
|
|
550
|
+
|
|
565
551
|
/** The key the single line counts under when the event names no types. */
|
|
566
552
|
export declare const SOLO_KEY = "default";
|
|
567
553
|
|
|
@@ -645,6 +631,11 @@ declare interface Ticket {
|
|
|
645
631
|
* response spanning a whole series is split back into days.
|
|
646
632
|
*/
|
|
647
633
|
EventKeys?: string[] | null;
|
|
634
|
+
/**
|
|
635
|
+
* The inventories this product is sold from — the event's own `(Main)` one and any named
|
|
636
|
+
* ones that silo an allocation across events. Sent by `TicketInformation`.
|
|
637
|
+
*/
|
|
638
|
+
InventoryKeys?: string[] | null;
|
|
648
639
|
}
|
|
649
640
|
|
|
650
641
|
/** The time it is right now on a given zone's clock, as `HH:MM`. */
|
|
@@ -710,11 +701,6 @@ export declare type TimeSelection = {
|
|
|
710
701
|
readonly startTime: string | null;
|
|
711
702
|
};
|
|
712
703
|
|
|
713
|
-
/**
|
|
714
|
-
* The times within one day that a ticket is sold for — the timeslot picker's whole
|
|
715
|
-
* domain.
|
|
716
|
-
*/
|
|
717
|
-
|
|
718
704
|
/** One slot a ticket is sold for. */
|
|
719
705
|
export declare type Timeslot = {
|
|
720
706
|
/**
|
|
@@ -729,6 +715,21 @@ export declare type Timeslot = {
|
|
|
729
715
|
* reports it. Null where the slot does not say.
|
|
730
716
|
*/
|
|
731
717
|
readonly remaining: number | null;
|
|
718
|
+
/**
|
|
719
|
+
* THE CHEAPEST WAY INTO THIS SESSION, where the host knows one. Absent draws no price,
|
|
720
|
+
* which is the default and what every existing caller gets.
|
|
721
|
+
*
|
|
722
|
+
* COMPUTED, NEVER READ. A slot carries no money on the wire — `EventTimeslot` is two
|
|
723
|
+
* times, a total and a remaining — so a price is reached through the TICKET that owns
|
|
724
|
+
* the slot, and the discount bands hang off that ticket too. `slot-price.ts` is the
|
|
725
|
+
* package's answer to all of that, and `runView` spends it for the schedule the widget
|
|
726
|
+
* builds itself; a host composing its own rows reaches the same functions.
|
|
727
|
+
*
|
|
728
|
+
* SO THIS IS A FIGURE AND NOT A RULE. The picker writes the word in front of it and
|
|
729
|
+
* formats the money — that is copy and presentation, which stay here — and takes no view
|
|
730
|
+
* on how the number was arrived at.
|
|
731
|
+
*/
|
|
732
|
+
readonly fromPrice?: SlotPrice | null;
|
|
732
733
|
};
|
|
733
734
|
|
|
734
735
|
/** One slot, resolved: what it is, when it is, and what it can do. */
|
package/dist/pickers.js
CHANGED
package/dist/styles.css
CHANGED
|
@@ -208,6 +208,7 @@
|
|
|
208
208
|
--scopetickets-island-timeslot-base-height: calc( var(--scopetickets-island-timeslot-padding) * 2 + var(--scopetickets-island-leading-sm) );
|
|
209
209
|
--scopetickets-island-timeslot-height: calc( var(--scopetickets-island-timeslot-base-height) + var(--scopetickets-island-day-accessory-gap) + var(--scopetickets-island-day-accessory-height) );
|
|
210
210
|
--scopetickets-island-timeslot-times-gap: var(--scopetickets-island-space-1);
|
|
211
|
+
--scopetickets-island-timeslot-price-gap: var(--scopetickets-island-space-2);
|
|
211
212
|
--scopetickets-island-timeslot-list-gap: var(--scopetickets-island-space-1);
|
|
212
213
|
--scopetickets-island-timeslot-unavailable: 0.4;
|
|
213
214
|
--scopetickets-island-timeslot-track: var(--scopetickets-island-surface-base);
|
|
@@ -731,15 +732,32 @@
|
|
|
731
732
|
font-variant-numeric: tabular-nums;
|
|
732
733
|
white-space: nowrap;
|
|
733
734
|
}
|
|
734
|
-
:is([data-scopetickets-picker], [data-scopetickets-island]) .scopetickets-island-
|
|
735
|
+
:is([data-scopetickets-picker], [data-scopetickets-island]) .scopetickets-island-timeslot__trailing {
|
|
735
736
|
display: flex;
|
|
736
737
|
flex: 1 1 0;
|
|
737
738
|
min-width: 0;
|
|
738
739
|
align-items: center;
|
|
739
740
|
justify-content: flex-end;
|
|
741
|
+
gap: var(--scopetickets-island-timeslot-price-gap);
|
|
742
|
+
}
|
|
743
|
+
:is([data-scopetickets-picker], [data-scopetickets-island]) .scopetickets-island-timeslot__price {
|
|
744
|
+
flex: 0 1 auto;
|
|
745
|
+
min-width: 0;
|
|
746
|
+
color: var(--scopetickets-island-text-muted);
|
|
747
|
+
font-size: var(--scopetickets-island-size-xs);
|
|
748
|
+
line-height: var(--scopetickets-island-leading-xs);
|
|
749
|
+
white-space: nowrap;
|
|
750
|
+
overflow: hidden;
|
|
751
|
+
text-overflow: ellipsis;
|
|
752
|
+
}
|
|
753
|
+
:is([data-scopetickets-picker], [data-scopetickets-island]) .scopetickets-island-timeslot__remaining {
|
|
754
|
+
display: flex;
|
|
755
|
+
flex: none;
|
|
756
|
+
align-items: center;
|
|
757
|
+
justify-content: flex-end;
|
|
740
758
|
}
|
|
741
759
|
:is([data-scopetickets-picker], [data-scopetickets-island]) .scopetickets-island-timeslot__soldout {
|
|
742
|
-
flex:
|
|
760
|
+
flex: 0 1 auto;
|
|
743
761
|
min-width: 0;
|
|
744
762
|
font-size: var(--scopetickets-island-size-sm);
|
|
745
763
|
line-height: var(--scopetickets-island-leading-sm);
|
|
@@ -1582,7 +1600,10 @@
|
|
|
1582
1600
|
font-size: var(--scopetickets-island-size-body);
|
|
1583
1601
|
line-height: var(--scopetickets-island-leading-body);
|
|
1584
1602
|
color: var(--scopetickets-island-secondary-text);
|
|
1585
|
-
|
|
1603
|
+
--scopetickets-island-button-fill: var(--scopetickets-island-secondary-bg);
|
|
1604
|
+
background: var(--scopetickets-island-button-fill);
|
|
1605
|
+
-webkit-backdrop-filter: blur(var(--scopetickets-island-button-blur));
|
|
1606
|
+
backdrop-filter: blur(var(--scopetickets-island-button-blur));
|
|
1586
1607
|
}
|
|
1587
1608
|
[data-scopetickets-island] .scopetickets-island-header-button__title[data-grain-short] {
|
|
1588
1609
|
min-width: max-content;
|
|
@@ -1718,6 +1739,9 @@
|
|
|
1718
1739
|
font-size: var(--scopetickets-island-size-body);
|
|
1719
1740
|
line-height: var(--scopetickets-island-leading-body);
|
|
1720
1741
|
cursor: pointer;
|
|
1742
|
+
background: var(--scopetickets-island-button-fill, none);
|
|
1743
|
+
-webkit-backdrop-filter: blur(var(--scopetickets-island-button-blur));
|
|
1744
|
+
backdrop-filter: blur(var(--scopetickets-island-button-blur));
|
|
1721
1745
|
}
|
|
1722
1746
|
[data-scopetickets-island] .scopetickets-island-button--block {
|
|
1723
1747
|
width: 100%;
|
|
@@ -1725,16 +1749,16 @@
|
|
|
1725
1749
|
[data-scopetickets-island] .scopetickets-island-button--action {
|
|
1726
1750
|
font-weight: var(--scopetickets-island-weight-strong);
|
|
1727
1751
|
color: var(--scopetickets-island-action-text);
|
|
1728
|
-
|
|
1752
|
+
--scopetickets-island-button-fill: var(--scopetickets-island-action-bg);
|
|
1729
1753
|
}
|
|
1730
1754
|
[data-scopetickets-island] .scopetickets-island-button--primary {
|
|
1731
|
-
|
|
1755
|
+
--scopetickets-island-button-fill: var(--scopetickets-island-primary-bg);
|
|
1732
1756
|
color: var(--scopetickets-island-primary-text);
|
|
1733
1757
|
}
|
|
1734
1758
|
[data-scopetickets-island] .scopetickets-island-button--secondary {
|
|
1735
1759
|
font-weight: var(--scopetickets-island-weight-regular);
|
|
1736
1760
|
color: var(--scopetickets-island-secondary-text);
|
|
1737
|
-
|
|
1761
|
+
--scopetickets-island-button-fill: var(--scopetickets-island-secondary-bg);
|
|
1738
1762
|
}
|
|
1739
1763
|
[data-scopetickets-island] .scopetickets-island-button--marked-separate {
|
|
1740
1764
|
gap: var(--scopetickets-island-space-3);
|
|
@@ -1751,7 +1775,15 @@
|
|
|
1751
1775
|
line-height: 1;
|
|
1752
1776
|
}
|
|
1753
1777
|
[data-scopetickets-island] .scopetickets-island-button:disabled,
|
|
1754
|
-
[data-scopetickets-island] .scopetickets-island-button--disabled
|
|
1778
|
+
[data-scopetickets-island] .scopetickets-island-button--disabled,
|
|
1779
|
+
[data-scopetickets-island] button.scopetickets-island-chrome-pill:disabled {
|
|
1780
|
+
background: color-mix(in srgb, var(--scopetickets-island-button-fill, transparent) calc(var(--scopetickets-island-disabled-opacity) * 100%), transparent);
|
|
1781
|
+
color: color-mix(in srgb, currentColor calc(var(--scopetickets-island-disabled-opacity) * 100%), transparent);
|
|
1782
|
+
border-color: color-mix(in srgb, var(--scopetickets-island-button-stroke) calc(var(--scopetickets-island-disabled-opacity) * 100%), transparent);
|
|
1783
|
+
}
|
|
1784
|
+
[data-scopetickets-island] .scopetickets-island-button:disabled .scopetickets-island-button__mark,
|
|
1785
|
+
[data-scopetickets-island] .scopetickets-island-button--disabled .scopetickets-island-button__mark,
|
|
1786
|
+
[data-scopetickets-island] button.scopetickets-island-chrome-pill:disabled > * {
|
|
1755
1787
|
opacity: var(--scopetickets-island-disabled-opacity);
|
|
1756
1788
|
}
|
|
1757
1789
|
[data-scopetickets-island] .scopetickets-island-button:disabled {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@scopetickets/checkout",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.0",
|
|
4
4
|
"description": "ScopeTicketsCheckout — the embeddable checkout widget: the island, its motion, and the steps it mounts.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -38,15 +38,23 @@
|
|
|
38
38
|
"engines": {
|
|
39
39
|
"node": ">=20"
|
|
40
40
|
},
|
|
41
|
+
"scripts": {
|
|
42
|
+
"build": "pnpm --filter @scopetickets/api --filter @scopetickets/checkout-core build && tsup && node scripts/verify-declarations.mjs",
|
|
43
|
+
"dev": "tsup --watch",
|
|
44
|
+
"typecheck": "tsc --noEmit",
|
|
45
|
+
"prepublishOnly": "node scripts/assert-packed-dist.mjs"
|
|
46
|
+
},
|
|
41
47
|
"peerDependencies": {
|
|
42
48
|
"react": "^18.0.0 || ^19.0.0"
|
|
43
49
|
},
|
|
44
50
|
"dependencies": {
|
|
45
|
-
"@scopetickets/avatar": "^0.
|
|
51
|
+
"@scopetickets/avatar": "^0.2.1",
|
|
46
52
|
"@scopetickets/icons": "^0.1.0"
|
|
47
53
|
},
|
|
48
54
|
"devDependencies": {
|
|
49
55
|
"@microsoft/api-extractor": "^7.59.1",
|
|
56
|
+
"@scopetickets/api": "workspace:*",
|
|
57
|
+
"@scopetickets/checkout-core": "workspace:*",
|
|
50
58
|
"@testing-library/dom": "^10.4.0",
|
|
51
59
|
"@testing-library/jest-dom": "^6.6.3",
|
|
52
60
|
"@testing-library/react": "^16.1.0",
|
|
@@ -57,12 +65,6 @@
|
|
|
57
65
|
"react": "^18.3.1",
|
|
58
66
|
"react-dom": "^18.3.1",
|
|
59
67
|
"tsup": "^8.3.5",
|
|
60
|
-
"typescript": "^5.7.2"
|
|
61
|
-
"@scopetickets/api": "0.1.0"
|
|
62
|
-
},
|
|
63
|
-
"scripts": {
|
|
64
|
-
"build": "pnpm --filter @scopetickets/api build && tsup && node scripts/verify-declarations.mjs",
|
|
65
|
-
"dev": "tsup --watch",
|
|
66
|
-
"typecheck": "tsc --noEmit"
|
|
68
|
+
"typescript": "^5.7.2"
|
|
67
69
|
}
|
|
68
|
-
}
|
|
70
|
+
}
|