@meetelise/chat 1.31.0 → 1.32.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/dist/src/WebComponent/FeeCalculator/components/{addon-item → addons/addon-item}/addon-item.d.ts +2 -2
- package/dist/src/WebComponent/FeeCalculator/components/addons/rentable-item/rentable-item-styles.d.ts +2 -0
- package/dist/src/WebComponent/FeeCalculator/components/addons/rentable-item/rentable-item.d.ts +25 -0
- package/dist/src/WebComponent/FeeCalculator/components/fee-calculator-layout/fee-calculator-layout.d.ts +13 -5
- package/dist/src/WebComponent/FeeCalculator/components/fee-item/fee-item.d.ts +1 -1
- package/dist/src/WebComponent/FeeCalculator/components/floor-plan-selector/floor-plan-selector.d.ts +8 -8
- package/dist/src/WebComponent/FeeCalculator/components/floorplan-image-card/floorplan-image-card.d.ts +3 -3
- package/dist/src/WebComponent/FeeCalculator/components/index.d.ts +1 -1
- package/dist/src/WebComponent/FeeCalculator/constants.d.ts +1 -0
- package/dist/src/WebComponent/FeeCalculator/fee-calculator.d.ts +4 -3
- package/dist/src/globals.d.ts +1 -0
- package/dist/src/services/fees/calculateQuote.d.ts +0 -1
- package/dist/src/services/fees/fetchBuildingUnits.d.ts +29 -0
- package/dist/src/utils/queryParamBuilder.d.ts +8 -0
- package/package.json +1 -1
- package/public/dist/index.js +302 -241
- package/src/WebComponent/FeeCalculator/components/{addon-item → addons/addon-item}/addon-item.ts +33 -35
- package/src/WebComponent/FeeCalculator/components/addons/rentable-item/rentable-item-styles.ts +9 -0
- package/src/WebComponent/FeeCalculator/components/addons/rentable-item/rentable-item.ts +138 -0
- package/src/WebComponent/FeeCalculator/components/fee-calculator-layout/fee-calculator-layout.ts +42 -17
- package/src/WebComponent/FeeCalculator/components/fee-item/fee-item.ts +1 -1
- package/src/WebComponent/FeeCalculator/components/floor-plan-selector/floor-plan-selector-styles.ts +0 -1
- package/src/WebComponent/FeeCalculator/components/floor-plan-selector/floor-plan-selector.ts +31 -35
- package/src/WebComponent/FeeCalculator/components/floorplan-image-card/floorplan-image-card.ts +13 -13
- package/src/WebComponent/FeeCalculator/components/index.ts +1 -1
- package/src/WebComponent/FeeCalculator/constants.ts +2 -0
- package/src/WebComponent/FeeCalculator/fee-calculator.ts +48 -25
- package/src/WebComponent/actions/call-us-window.ts +32 -10
- package/src/WebComponent/launcher/Launcher.ts +0 -1
- package/src/WebComponent/me-chat.ts +4 -7
- package/src/globals.ts +2 -0
- package/src/services/fees/calculateQuote.ts +0 -1
- package/src/services/fees/fetchBuildingUnits.ts +84 -0
- package/src/utils/queryParamBuilder.ts +28 -0
- package/dist/src/WebComponent/FeeCalculator/components/addon-item/index.d.ts +0 -1
- package/dist/src/services/fees/fetchBuildingFloorplans.d.ts +0 -21
- package/src/WebComponent/FeeCalculator/components/addon-item/index.ts +0 -1
- /package/dist/src/WebComponent/FeeCalculator/components/{addon-item/addon-item-styles.d.ts → addons/common-addon-styles.d.ts} +0 -0
- /package/src/WebComponent/FeeCalculator/components/{addon-item/addon-item-styles.ts → addons/common-addon-styles.ts} +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { LitElement, TemplateResult } from "lit";
|
|
2
|
-
import { BuildingFee } from "
|
|
3
|
-
import { DesiredAddon } from "
|
|
2
|
+
import { BuildingFee } from "../../../model/building-fee";
|
|
3
|
+
import { DesiredAddon } from "../../../../../services/fees/calculateQuote";
|
|
4
4
|
export declare class AddonItem extends LitElement {
|
|
5
5
|
static styles: import("lit").CSSResult;
|
|
6
6
|
feeItem: BuildingFee | null;
|
package/dist/src/WebComponent/FeeCalculator/components/addons/rentable-item/rentable-item.d.ts
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { LitElement, TemplateResult } from "lit";
|
|
2
|
+
import { RentableItemSummary } from "../../../../../services/fees/fetchBuildingFees";
|
|
3
|
+
import { DesiredRentableItem } from "../../../../../services/fees/calculateQuote";
|
|
4
|
+
export declare class RentableItem extends LitElement {
|
|
5
|
+
static styles: import("lit").CSSResult;
|
|
6
|
+
rentableItem: RentableItemSummary | null;
|
|
7
|
+
onSelect: ((rentableItem: DesiredRentableItem) => void) | null;
|
|
8
|
+
private isChecked;
|
|
9
|
+
private quantity;
|
|
10
|
+
selectedItemIds: Set<string>;
|
|
11
|
+
get totalAvailableItems(): number;
|
|
12
|
+
get quantityLeft(): number;
|
|
13
|
+
get atMaxUnits(): boolean;
|
|
14
|
+
get atMinUnits(): boolean;
|
|
15
|
+
private handleCheckboxClick;
|
|
16
|
+
private handleIncrement;
|
|
17
|
+
private handleDecrement;
|
|
18
|
+
private emitChange;
|
|
19
|
+
render(): TemplateResult;
|
|
20
|
+
}
|
|
21
|
+
declare global {
|
|
22
|
+
interface HTMLElementTagNameMap {
|
|
23
|
+
"rentable-item": RentableItem;
|
|
24
|
+
}
|
|
25
|
+
}
|
|
@@ -1,27 +1,35 @@
|
|
|
1
1
|
import { LitElement, TemplateResult } from "lit";
|
|
2
2
|
import { BuildingFee, RecurrenceFrequency } from "../../model/building-fee";
|
|
3
3
|
import { LayoutOption } from "../../../../fetchBuildingWebchatView";
|
|
4
|
-
import { CalculateQuoteResponse, DesiredAddon, FeeEstimate } from "../../../../services/fees/calculateQuote";
|
|
4
|
+
import { CalculateQuoteResponse, DesiredAddon, DesiredRentableItem, FeeEstimate } from "../../../../services/fees/calculateQuote";
|
|
5
|
+
import { RentableItemSummary } from "../../../../services/fees/fetchBuildingFees";
|
|
6
|
+
import { Unit } from "../../../../services/fees/fetchBuildingUnits";
|
|
5
7
|
import "../floor-plan-selector/floor-plan-selector";
|
|
6
8
|
import "../fee-card/fee-card";
|
|
7
|
-
import "../addon-item/addon-item";
|
|
9
|
+
import "../addons/addon-item/addon-item";
|
|
10
|
+
import "../addons/rentable-item/rentable-item";
|
|
8
11
|
import "../../../loaders/skeleton-loader";
|
|
9
12
|
export declare class FeeCalculatorLayout extends LitElement {
|
|
10
13
|
static styles: import("lit").CSSResult;
|
|
11
14
|
buildingSlug: string;
|
|
12
15
|
isLoading: boolean;
|
|
13
|
-
|
|
16
|
+
selectedUnit: Unit | null;
|
|
14
17
|
quote: CalculateQuoteResponse | null;
|
|
15
18
|
layoutOptions: LayoutOption[];
|
|
16
19
|
selectedLayoutIds: number[];
|
|
17
20
|
groupedFees: Record<RecurrenceFrequency, BuildingFee[]>;
|
|
21
|
+
rentableItems: RentableItemSummary[];
|
|
18
22
|
onSelectLayout: ((layoutIds: number[]) => void) | null;
|
|
19
|
-
onUnitSelect: ((
|
|
23
|
+
onUnitSelect: ((unit: Unit) => void) | null;
|
|
20
24
|
onMoveInDateChange: ((moveInDate: Date) => void) | null;
|
|
21
25
|
onLeaseTermChange: ((leaseTerm: number) => void) | null;
|
|
22
26
|
onAddonSelect: ((addon: DesiredAddon) => void) | null;
|
|
27
|
+
onRentableItemSelect: ((rentableItem: DesiredRentableItem) => void) | null;
|
|
23
28
|
get standardFees(): Record<RecurrenceFrequency, BuildingFee[]>;
|
|
24
|
-
|
|
29
|
+
/**
|
|
30
|
+
* A "rentable item" is simply a fee which has inventory attached to it.
|
|
31
|
+
*/
|
|
32
|
+
get addOns(): (BuildingFee | RentableItemSummary)[];
|
|
25
33
|
renderRecurrenceFeeSection(title: string, fees: FeeEstimate[]): TemplateResult | null;
|
|
26
34
|
renderFeeSections(): TemplateResult[];
|
|
27
35
|
renderFeesContent(): TemplateResult;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { LitElement, TemplateResult } from "lit";
|
|
2
2
|
import { FeeEstimate } from "../../../../services/fees/calculateQuote";
|
|
3
|
-
import "../addon-item/addon-item";
|
|
3
|
+
import "../addons/addon-item/addon-item";
|
|
4
4
|
export declare class FeeItemComponent extends LitElement {
|
|
5
5
|
static styles: import("lit").CSSResult;
|
|
6
6
|
feeItem: FeeEstimate | null;
|
package/dist/src/WebComponent/FeeCalculator/components/floor-plan-selector/floor-plan-selector.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { LitElement, TemplateResult } from "lit";
|
|
2
2
|
import { LayoutOption } from "../../../../fetchBuildingWebchatView";
|
|
3
|
-
import {
|
|
3
|
+
import { Unit } from "../../../../services/fees/fetchBuildingUnits";
|
|
4
4
|
import "../floorplan-image-card/floorplan-image-card";
|
|
5
5
|
import "../../../loaders/mega-loader";
|
|
6
6
|
export declare class FloorPlanSelector extends LitElement {
|
|
@@ -9,21 +9,21 @@ export declare class FloorPlanSelector extends LitElement {
|
|
|
9
9
|
layoutOptions: LayoutOption[];
|
|
10
10
|
selectedLayoutIds: number[];
|
|
11
11
|
onSelectLayout: ((layoutIds: number[]) => void) | null;
|
|
12
|
-
onUnitSelect: ((
|
|
12
|
+
onUnitSelect: ((unit: Unit) => void) | null;
|
|
13
13
|
onMoveInDateChange: ((moveInDate: Date) => void) | null;
|
|
14
14
|
onLeaseTermChange: ((leaseTerm: number) => void) | null;
|
|
15
15
|
moveInDate: Date | null;
|
|
16
|
-
leaseTerm:
|
|
17
|
-
|
|
18
|
-
|
|
16
|
+
leaseTerm: number;
|
|
17
|
+
units: Unit[];
|
|
18
|
+
selectedUnit: Unit | null;
|
|
19
19
|
isLoading: boolean;
|
|
20
20
|
private get displayOptions();
|
|
21
|
-
private
|
|
21
|
+
private fetchUnits;
|
|
22
22
|
firstUpdated: () => Promise<void>;
|
|
23
|
-
handleUnitSelect: (
|
|
23
|
+
handleUnitSelect: (unit: Unit) => void;
|
|
24
24
|
handleLayoutChange: (ids: number[]) => Promise<void>;
|
|
25
25
|
handleMoveInDateChange: (e: Event) => Promise<void>;
|
|
26
|
-
handleLeaseTermChange: (e: Event) => void
|
|
26
|
+
handleLeaseTermChange: (e: Event) => Promise<void>;
|
|
27
27
|
render(): TemplateResult;
|
|
28
28
|
}
|
|
29
29
|
declare global {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { LitElement, TemplateResult } from "lit";
|
|
2
|
-
import {
|
|
2
|
+
import { Unit } from "../../../../services/fees/fetchBuildingUnits";
|
|
3
3
|
export declare class FloorplanImageCard extends LitElement {
|
|
4
4
|
static styles: import("lit").CSSResult;
|
|
5
|
-
|
|
6
|
-
onUnitSelect: ((
|
|
5
|
+
unit: Unit;
|
|
6
|
+
onUnitSelect: ((unit: Unit) => void) | null;
|
|
7
7
|
selected: boolean;
|
|
8
8
|
get bedAndBathText(): string;
|
|
9
9
|
get priceRange(): string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export * from "./promo-card/promo-card";
|
|
2
2
|
export * from "./floor-plan-selector/floor-plan-selector";
|
|
3
3
|
export * from "./fee-card/fee-card";
|
|
4
|
-
export * from "./addon-item/addon-item";
|
|
4
|
+
export * from "./addons/addon-item/addon-item";
|
|
5
5
|
export * from "./fee-calculator-layout/fee-calculator-layout";
|
|
@@ -2,6 +2,7 @@ import { LitElement, TemplateResult } from "lit";
|
|
|
2
2
|
import { LayoutOption } from "../../fetchBuildingWebchatView";
|
|
3
3
|
import { BuildingFee, RecurrenceFrequency } from "./model/building-fee";
|
|
4
4
|
import { CalculateQuoteResponse, DesiredAddon, DesiredRentableItem } from "../../services/fees/calculateQuote";
|
|
5
|
+
import { Unit } from "../../services/fees/fetchBuildingUnits";
|
|
5
6
|
import "./components";
|
|
6
7
|
import "./components/fee-calculator-layout/fee-calculator-layout";
|
|
7
8
|
import "../chat-additional-actions";
|
|
@@ -12,7 +13,6 @@ export declare class FeeCalculator extends LitElement {
|
|
|
12
13
|
orgSlug: string;
|
|
13
14
|
private primaryColor;
|
|
14
15
|
private backgroundColor;
|
|
15
|
-
compactDesign: boolean;
|
|
16
16
|
onCloseClicked: (() => void) | null;
|
|
17
17
|
onClickEmailOption: ((e: MouseEvent) => void) | null;
|
|
18
18
|
onClickPhoneOption: ((e: MouseEvent) => void) | null;
|
|
@@ -20,7 +20,7 @@ export declare class FeeCalculator extends LitElement {
|
|
|
20
20
|
onClickTextUsOption: ((e: MouseEvent) => void) | null;
|
|
21
21
|
private isLoading;
|
|
22
22
|
private selectedLayoutIds;
|
|
23
|
-
private
|
|
23
|
+
private selectedUnit;
|
|
24
24
|
private desiredAddons;
|
|
25
25
|
private desiredRentableItems;
|
|
26
26
|
private leaseTerm;
|
|
@@ -36,13 +36,14 @@ export declare class FeeCalculator extends LitElement {
|
|
|
36
36
|
};
|
|
37
37
|
quote: CalculateQuoteResponse | null;
|
|
38
38
|
private groupedFees;
|
|
39
|
+
private rentableItems;
|
|
39
40
|
private debouncedCalculateQuote;
|
|
40
41
|
get layouts(): LayoutOption[];
|
|
41
42
|
firstUpdated: () => Promise<void>;
|
|
42
43
|
setupCalculator: () => Promise<void>;
|
|
43
44
|
updated(changedProperties: Map<string, unknown>): void;
|
|
44
45
|
calculateQuote: () => Promise<void>;
|
|
45
|
-
handleUnitSelect: (
|
|
46
|
+
handleUnitSelect: (unit: Unit) => void;
|
|
46
47
|
handleMoveInDateChange: (date: Date) => void;
|
|
47
48
|
handleLeaseTermChange: (leaseTerm: number) => void;
|
|
48
49
|
handleAddonSelect: (addon: DesiredAddon) => void;
|
package/dist/src/globals.d.ts
CHANGED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
export declare type Unit = {
|
|
2
|
+
/**
|
|
3
|
+
* ID comes back in the format "u1234567890" - we strip the "u"
|
|
4
|
+
*/
|
|
5
|
+
id: number;
|
|
6
|
+
unitNumber: string;
|
|
7
|
+
layout: number;
|
|
8
|
+
externalFloorPlanDescriptionId: string;
|
|
9
|
+
numberOfBedrooms: number;
|
|
10
|
+
numberOfBathrooms: number;
|
|
11
|
+
squareFootage: number;
|
|
12
|
+
floor: number;
|
|
13
|
+
floorplanName: string;
|
|
14
|
+
floorplanUrl: string;
|
|
15
|
+
availabilityStage: string;
|
|
16
|
+
earliestAvailable: string;
|
|
17
|
+
latestAvailable: string;
|
|
18
|
+
startingPrice: number;
|
|
19
|
+
maxPrice: number;
|
|
20
|
+
};
|
|
21
|
+
declare type FetchPropertyUnitsParams = {
|
|
22
|
+
buildingSlug: string;
|
|
23
|
+
numBedrooms?: number;
|
|
24
|
+
moveInDateEarliest?: Date;
|
|
25
|
+
moveInDateLatest?: Date;
|
|
26
|
+
leaseTermMin?: number;
|
|
27
|
+
};
|
|
28
|
+
declare const fetchBuildingUnits: ({ buildingSlug, numBedrooms, moveInDateEarliest, moveInDateLatest, leaseTermMin, }: FetchPropertyUnitsParams) => Promise<Unit[]>;
|
|
29
|
+
export default fetchBuildingUnits;
|