@meetelise/chat 1.74.0 → 1.76.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.
Files changed (35) hide show
  1. package/dist/src/WebComponent/Scheduler/time-picker.d.ts +6 -0
  2. package/dist/src/WebComponent/Scheduler/tour-type-option.d.ts +1 -1
  3. package/dist/src/WebComponent/SchedulerV2/booking-confirmation.d.ts +2 -0
  4. package/dist/src/WebComponent/SchedulerV2/contact-form.d.ts +9 -3
  5. package/dist/src/WebComponent/SchedulerV2/itinerary-editor.d.ts +18 -1
  6. package/dist/src/WebComponent/SchedulerV2/itineraryStopStyles.d.ts +1 -2
  7. package/dist/src/WebComponent/SchedulerV2/schedulerIcons.d.ts +18 -0
  8. package/dist/src/WebComponent/SchedulerV2/schedulerRequests.d.ts +2 -0
  9. package/dist/src/WebComponent/SchedulerV2/schedulerV2Styles.d.ts +9 -0
  10. package/dist/src/WebComponent/SchedulerV2/tour-scheduler-v2.d.ts +17 -1
  11. package/dist/src/WebComponent/SchedulerV2/tourItineraryApi.d.ts +12 -0
  12. package/dist/src/WebComponent/SchedulerV2/tourTimes.d.ts +3 -1
  13. package/dist/src/WebComponent/actions/international-phone-input.d.ts +7 -0
  14. package/dist/src/WebComponent/me-select.d.ts +2 -0
  15. package/package.json +1 -1
  16. package/public/dist/index.js +2411 -1446
  17. package/src/WebComponent/Scheduler/date-picker.ts +130 -51
  18. package/src/WebComponent/Scheduler/time-picker.ts +62 -0
  19. package/src/WebComponent/Scheduler/tour-type-option.ts +31 -10
  20. package/src/WebComponent/SchedulerV2/booking-confirmation.ts +54 -45
  21. package/src/WebComponent/SchedulerV2/community-picker.ts +222 -160
  22. package/src/WebComponent/SchedulerV2/contact-form.ts +100 -70
  23. package/src/WebComponent/SchedulerV2/itinerary-editor.ts +316 -151
  24. package/src/WebComponent/SchedulerV2/itineraryStopStyles.ts +44 -21
  25. package/src/WebComponent/SchedulerV2/scheduler-popover.ts +6 -6
  26. package/src/WebComponent/SchedulerV2/schedulerIcons.ts +143 -0
  27. package/src/WebComponent/SchedulerV2/schedulerRequests.ts +10 -0
  28. package/src/WebComponent/SchedulerV2/schedulerV2Styles.ts +347 -0
  29. package/src/WebComponent/SchedulerV2/tour-scheduler-v2.ts +493 -172
  30. package/src/WebComponent/SchedulerV2/tourItineraryApi.ts +12 -0
  31. package/src/WebComponent/SchedulerV2/tourTimes.ts +16 -3
  32. package/src/WebComponent/actions/action-confirm-button.ts +4 -3
  33. package/src/WebComponent/actions/international-phone-input.ts +84 -1
  34. package/src/WebComponent/me-select.ts +74 -0
  35. package/src/tourSchedulerV2Booking.test.ts +129 -7
@@ -10,6 +10,12 @@ export declare class TimePicker extends LitElement {
10
10
  selectedDateExists: boolean;
11
11
  timezone: string;
12
12
  defaultSelectedTime?: TimePickerOption | null;
13
+ /**
14
+ * Tour-scheduler-v2's look: three white, outlined times across, the chosen
15
+ * one tinted with the brand colour. Its heading names the time zone, so the
16
+ * note under the times is left out.
17
+ */
18
+ outlined: boolean;
13
19
  private selected?;
14
20
  get selectedTime(): undefined | TimePickerOption | null;
15
21
  protected updated(changedProperties: Map<string | number | symbol, unknown>): void;
@@ -4,7 +4,7 @@ export declare class TourTypeOption extends LitElement {
4
4
  heading: string;
5
5
  subtitle: string;
6
6
  selected: boolean;
7
- /** A white row with the icon on the left, marked by a brand-colour tint when selected. */
7
+ /** The v2 scheduler's white row with the icon on the left, tinted with the brand colour when selected. */
8
8
  outlined: boolean;
9
9
  onClick?: () => void;
10
10
  primaryColor: string;
@@ -8,6 +8,7 @@ export interface ConfirmedStop {
8
8
  /** The server's prospect-facing reason, for a failed stop. */
9
9
  error: string | null;
10
10
  distanceFromPrevMi: number | null;
11
+ travelMinutesFromPrev: number | null;
11
12
  }
12
13
  /**
13
14
  * The Central Agent design's "Your Tour Is Booked" header, then an itinerary's
@@ -22,6 +23,7 @@ export declare class BookingConfirmation extends LitElement {
22
23
  private heading;
23
24
  /** Where, how and when, as one line: the stops list shows each stop's own time. */
24
25
  private summary;
26
+ private renderLeg;
25
27
  private renderStops;
26
28
  render(): TemplateResult;
27
29
  static styles: import("lit").CSSResult[];
@@ -23,8 +23,8 @@ export declare const EMPTY_CONTACT: ContactValues;
23
23
  */
24
24
  export declare const contactIsValid: (values: ContactValues, bedroomsRequired: boolean) => boolean;
25
25
  /**
26
- * The prospect's details, in today's scheduler's "Your Information" column
27
- * with its inputs. The scheduler's footer holds the submit button.
26
+ * The prospect's details: the design's "Your Information" column, each field
27
+ * labelled above. The scheduler's footer holds the submit button.
28
28
  */
29
29
  export declare class ContactForm extends LitElement {
30
30
  values: ContactValues;
@@ -38,12 +38,18 @@ export declare class ContactForm extends LitElement {
38
38
  mobile: boolean;
39
39
  private phoneHasBlurred;
40
40
  private setValues;
41
- private inputClasses;
41
+ /** A field's label, with the design's red asterisk when it is required. */
42
+ private label;
42
43
  /**
43
44
  * The bedroom preferences as the filters' chips: each tap picks or clears
44
45
  * one, as the Bedrooms filter does.
45
46
  */
46
47
  private renderLayouts;
48
+ /**
49
+ * The browser's date input, drawn as the design's "Select a date" field:
50
+ * the whole field opens the browser's calendar.
51
+ */
52
+ private renderMoveIn;
47
53
  render(): TemplateResult;
48
54
  static styles: import("lit").CSSResult[];
49
55
  }
@@ -3,6 +3,7 @@ import "../Scheduler/date-picker";
3
3
  import "../Scheduler/time-picker";
4
4
  import "../Scheduler/tour-type-option";
5
5
  import "../mini-loader";
6
+ import "./scheduler-popover";
6
7
  import { CommunitySummary, PlanStop, TourTypeId } from "./tourItineraryApi";
7
8
  export interface TourTypeChoice {
8
9
  id: TourTypeId;
@@ -46,6 +47,12 @@ export declare class ItineraryEditor extends LitElement {
46
47
  foregroundColorOnPrimaryBackgroundColor: string;
47
48
  private get offersKnown();
48
49
  private editingTimeFor;
50
+ /** The date field's calendar is open. */
51
+ private dateOpen;
52
+ private mobile;
53
+ private cleanupMobileListener?;
54
+ connectedCallback(): void;
55
+ disconnectedCallback(): void;
49
56
  private dragIndex;
50
57
  private dropIndex;
51
58
  private get selectedTypeOpensLink();
@@ -60,10 +67,20 @@ export declare class ItineraryEditor extends LitElement {
60
67
  private endDrag;
61
68
  private renderCommunity;
62
69
  private renderTourTypes;
70
+ /** Today's date picker over `dates`, reporting a picked day other than `date`. */
63
71
  private renderDatePicker;
72
+ /** One stop's own day: moving it there makes it a separate tour. */
73
+ private renderStopDatePicker;
64
74
  private renderTimePicker;
65
75
  private renderLinkPrompt;
66
- private renderSingleDateAndTime;
76
+ /**
77
+ * The design's date field: the chosen day, which opens the calendar under
78
+ * it (in place on phones). Picking a day closes it, the day already chosen
79
+ * included, which the calendar reports without a date change.
80
+ */
81
+ private renderDateField;
82
+ /** "Time (CDT)": the one community's times, in its own time zone. */
83
+ private renderTimes;
67
84
  private renderStop;
68
85
  private renderRemove;
69
86
  private renderProblem;
@@ -1,6 +1,5 @@
1
1
  /**
2
2
  * The list of stops in an itinerary, shared by the schedule step and the
3
- * confirmation. Each stop is a fee calculator card (`.floorplan-image-card`);
4
- * this adds only the numbering and the distance between stops.
3
+ * confirmation: the design's numbered cards, joined by the leg between them.
5
4
  */
6
5
  export declare const itineraryStopStyles: import("lit").CSSResult;
@@ -0,0 +1,18 @@
1
+ import { SVGTemplateResult } from "lit";
2
+ export declare const BuildingLineIcon: (size?: number, strokeWidth?: number) => SVGTemplateResult;
3
+ export declare const CalendarLineIcon: (size?: number) => SVGTemplateResult;
4
+ export declare const ChevronLeftLineIcon: (size?: number) => SVGTemplateResult;
5
+ export declare const ChevronRightLineIcon: (size?: number) => SVGTemplateResult;
6
+ export declare const CloseLineIcon: (size?: number) => SVGTemplateResult;
7
+ export declare const PencilLineIcon: (size?: number) => SVGTemplateResult;
8
+ export declare const TrashLineIcon: (size?: number) => SVGTemplateResult;
9
+ export declare const GripLineIcon: (size?: number) => SVGTemplateResult;
10
+ export declare const PlusLineIcon: (size?: number) => SVGTemplateResult;
11
+ export declare const MapLineIcon: (size?: number) => SVGTemplateResult;
12
+ /** The design's booked mark: a check in a circle, in green. */
13
+ export declare const CheckCircleLineIcon: (size?: number, strokeWidth?: number) => SVGTemplateResult;
14
+ export declare const PersonPlusLineIcon: (size?: number) => SVGTemplateResult;
15
+ export declare const VideoLineIcon: (size?: number) => SVGTemplateResult;
16
+ export declare const MapPinLineIcon: (size?: number) => SVGTemplateResult;
17
+ export declare const StarFilledIcon: (size?: number) => SVGTemplateResult;
18
+ export declare const BadgeCheckFilledIcon: (size?: number) => SVGTemplateResult;
@@ -10,6 +10,8 @@ export interface ItineraryChoice {
10
10
  firstStart: string | null;
11
11
  /** ISO starts picked for later new stops, by building id. */
12
12
  laterStarts: Record<number, string>;
13
+ /** "YYYY-MM-DD" days new stops moved to on their own, away from `date`, by building id. */
14
+ stopDates: Record<number, string>;
13
15
  /** Booked events this itinerary extends, in order; the last one is fixed first. */
14
16
  existingEventIds: number[];
15
17
  }
@@ -0,0 +1,9 @@
1
+ /**
2
+ * The v2 scheduler's design (the "select one" mockup), shared by its parts.
3
+ * Today's scheduler keeps `tourSchedulerStyles`; nothing here reaches it.
4
+ *
5
+ * The mockup's sample purple is the building's brand colour (`--primary-color`,
6
+ * set by `tour-scheduler-v2`); its lavender fill and ring are tints of it.
7
+ */
8
+ export declare const schedulerV2Tokens: import("lit").CSSResult;
9
+ export declare const schedulerV2Styles: import("lit").CSSResult;
@@ -65,6 +65,8 @@ export declare class TourSchedulerV2 extends LitElement {
65
65
  private date;
66
66
  private firstStart;
67
67
  private laterStarts;
68
+ /** Stops the prospect moved to their own day, away from `date`. */
69
+ private stopDates;
68
70
  private plan;
69
71
  private planLoading;
70
72
  private planError;
@@ -93,6 +95,14 @@ export declare class TourSchedulerV2 extends LitElement {
93
95
  private planRequestId;
94
96
  private idempotency;
95
97
  private cleanupMobileListener?;
98
+ /**
99
+ * Below this width the modal can't fit the schedule step's three columns
100
+ * (the chat beside it, or a narrow window), so the step stacks.
101
+ */
102
+ private static readonly THREE_COLUMN_MIN_WIDTH;
103
+ private narrow;
104
+ private readonly modalResize;
105
+ private observeModal;
96
106
  connectedCallback(): void;
97
107
  disconnectedCallback(): void;
98
108
  private onKeydown;
@@ -130,6 +140,8 @@ export declare class TourSchedulerV2 extends LitElement {
130
140
  private get activeLinkType();
131
141
  private onTourType;
132
142
  private onDate;
143
+ private stopDatesWithout;
144
+ private onStopDate;
133
145
  private onStopTime;
134
146
  private onReorder;
135
147
  private onRemove;
@@ -185,7 +197,7 @@ export declare class TourSchedulerV2 extends LitElement {
185
197
  /** A preference can only be required where there is one to choose. */
186
198
  private get bedroomsRequired();
187
199
  private disclaimer;
188
- /** Today's scheduler's body area, which scrolls the whole sheet on phones. */
200
+ /** The body area, which scrolls the whole sheet on phones. */
189
201
  private container;
190
202
  /**
191
203
  * The design's first page: one community, which opens its schedule. More
@@ -196,6 +208,10 @@ export declare class TourSchedulerV2 extends LitElement {
196
208
  private renderItineraryHeading;
197
209
  /** "Add another stop": the nearby communities, under the itinerary. */
198
210
  private renderAddStop;
211
+ private renderEditor;
212
+ private renderContactForm;
213
+ /** The consent text and the submit button, under the form or the itinerary. */
214
+ private renderFooter;
199
215
  private renderSchedule;
200
216
  /** Today's reschedule prompt, with the server's reason. */
201
217
  private renderReschedulePrompt;
@@ -85,6 +85,8 @@ export interface PlanRequest {
85
85
  start_time: string | null;
86
86
  /** Times picked for later stops, by building id; empty when none are picked. */
87
87
  stop_starts: Record<string, string>;
88
+ /** A stop's own day when it isn't `date`, by building id; empty when none is moved. */
89
+ stop_dates: Record<string, string>;
88
90
  fixed_first: {
89
91
  calendar_event_id: number;
90
92
  } | null;
@@ -95,7 +97,17 @@ export interface PlanStop {
95
97
  end: string;
96
98
  timezone: string;
97
99
  distance_from_prev_mi: number | null;
100
+ /**
101
+ * Whole minutes to drive here from the stop before, already left free in the
102
+ * times. Missing from a server that predates the field.
103
+ */
104
+ travel_minutes_from_prev?: number | null;
98
105
  alternatives: string[];
106
+ /**
107
+ * The days this stop could move to on its own, within the next 30. Empty once
108
+ * a stop is booked, and missing from a server that predates the field.
109
+ */
110
+ dates?: string[];
99
111
  fixed: boolean;
100
112
  }
101
113
  export interface PlanResponse {
@@ -8,7 +8,7 @@ export declare const isoHourMinute: (iso: string) => string;
8
8
  export declare const formatHourMinute: (hourMinute: string) => string;
9
9
  /** ISO start -> "10:45am" */
10
10
  export declare const formatTime: (iso: string) => string;
11
- /** "10:00–10:30am", or "11:30am–12:00pm" across noon. */
11
+ /** "10:00–10:30 AM", or "11:30 AM–12:00 PM" across noon, as the design writes a stop's time. */
12
12
  export declare const formatTimeRange: (startIso: string, endIso: string) => string;
13
13
  /** A calendar date, read as that date wherever the visitor is. */
14
14
  export declare const dateFromIsoDate: (date: string) => Date;
@@ -18,6 +18,8 @@ export declare const formatShortDate: (date: string) => string;
18
18
  export declare const formatMonthDay: (date: string) => string;
19
19
  /** "2026-10-15" -> "Thu, Oct 15, 2026" */
20
20
  export declare const formatLongDate: (date: string) => string;
21
+ /** "1.8 mi · 12 min drive" between two stops, or "" when neither is known. */
22
+ export declare const formatLeg: (distanceMi: number | null, travelMinutes: number | null | undefined) => string;
21
23
  /** A Date as the "YYYY-MM-DD" the API uses. */
22
24
  export declare const toIsoDate: (date: Date) => string;
23
25
  /** The Central Agent design's names for each tour type, with today's icons. */
@@ -7,10 +7,17 @@ export declare type InternationalPhoneChangeDetail = {
7
7
  };
8
8
  export declare class InternationalPhoneInput extends LitElement {
9
9
  static styles: import("lit").CSSResult[];
10
+ /** The v2 scheduler's look: a white field with a thin border, as its other inputs. */
11
+ outlined: boolean;
10
12
  country: string | null;
11
13
  value: string;
12
14
  invalid: boolean;
13
15
  placeholder: string;
16
+ /**
17
+ * The number field's accessible name, for a form that labels it above
18
+ * rather than with the placeholder. Left empty, the placeholder names it.
19
+ */
20
+ label: string;
14
21
  private selectedCountry;
15
22
  protected willUpdate(changedProperties: PropertyValues<this>): void;
16
23
  get e164(): string | null;
@@ -7,6 +7,8 @@ export declare class MESelect extends LitElement {
7
7
  options: MeSelectOption[];
8
8
  placeholder?: string;
9
9
  value?: string;
10
+ /** The v2 scheduler's look: a white field with a thin border. */
11
+ outlined: boolean;
10
12
  private activeOption;
11
13
  private isOpen?;
12
14
  private activeOptionIndex;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@meetelise/chat",
3
- "version": "1.74.0",
3
+ "version": "1.76.0",
4
4
  "description": "",
5
5
  "keywords": [],
6
6
  "homepage": "https://github.com/MeetElise/chat-ui#readme",