'use strict';

Object.defineProperty(exports, '__esModule', { value: true });

const index = require('./index-ceff47a0.js');
const index_esm_min = require('./index.esm.min-f57d151c.js');
const index_esm_min$1 = require('./index.esm.min-1101deb1.js');
const reduxStore_service = require('./redux-store.service-10b7725a.js');
const index_esm_min$2 = require('./index.esm.min-2e158fd8.js');

const bpSdkQuoteRequestBindContainerCss = "";
const BpSdkQuoteRequestBindContainerStyle0 = bpSdkQuoteRequestBindContainerCss;

const BpSdkQuoteRequestBindContainer = class {
    constructor(hostRef) {
        index.registerInstance(this, hostRef);
        this.appFormId = '';
        this.carrier = undefined;
        this.isBindable = undefined;
        this.isPermittedToBind = undefined;
        this.quoteId = '';
        this.quoteInfo = undefined;
        this.handleBind = undefined;
        this.useExternal = false;
        this.annualPrice = undefined;
        this.carrierName = undefined;
    }
    resetState() { }
    componentWillLoad() {
        this.useExternal = !!customElements.get('bp-sdk-external-quote-request-bind-container');
        customElements.whenDefined('bp-sdk-external-quote-request-bind-container').then(() => {
            this.useExternal = true;
        });
        this.onQuoteInfoChange(this.quoteInfo);
        this.onCarrierChange(this.carrier);
    }
    onQuoteInfoChange(quoteInfo) {
        var _a;
        this.annualPrice = (_a = quoteInfo === null || quoteInfo === void 0 ? void 0 : quoteInfo.annual_price) !== null && _a !== void 0 ? _a : '0';
    }
    onCarrierChange(carrier) {
        var _a;
        this.carrierName = (_a = carrier === null || carrier === void 0 ? void 0 : carrier.name) !== null && _a !== void 0 ? _a : '';
    }
    render() {
        return [this.useExternal && this.renderExternal(), !this.useExternal && this.renderInternal()];
    }
    renderExternal() {
        return (index.h("bp-sdk-external-quote-request-bind-container", { appFormId: this.appFormId, carrier: this.carrier, isBindable: this.isBindable, isPermittedToBind: this.isPermittedToBind, quoteId: this.quoteId, quoteInfo: this.quoteInfo, handleBind: this.handleBind }));
    }
    renderInternal() {
        return (index.h("div", { class: "bp-sdk-quote-request-bind-container__container" }, this.isBindable && (index.h("bp-sdk-quote-request-button-container", { annualPrice: this.annualPrice, appFormId: this.appFormId, carrierName: this.carrierName, quoteId: this.quoteId, handleBind: this.handleBind }))));
    }
    static get watchers() { return {
        "quoteInfo": ["onQuoteInfoChange"],
        "carrier": ["onCarrierChange"]
    }; }
};
BpSdkQuoteRequestBindContainer.style = BpSdkQuoteRequestBindContainerStyle0;

const bpSdkQuoteRequestButtonContainerCss = "";
const BpSdkQuoteRequestButtonContainerStyle0 = bpSdkQuoteRequestButtonContainerCss;

const BpSdkQuoteRequestButtonContainer = class {
    constructor(hostRef) {
        index.registerInstance(this, hostRef);
        this.bpAnalyticsTrack = index.createEvent(this, "bpAnalyticsTrack", 7);
        this.handleSubscriptions = () => {
            this.storeUnsubscribe && this.storeUnsubscribe();
            this.storeUnsubscribe = reduxStore_service.store.mapStateToProps(this, this.mapStateToProps);
        };
        this.mapStateToProps = (state) => {
            const quote = index_esm_min.UN(state, this.quoteId);
            return {
                isQuoteExpired: index_esm_min$1.et.includes(quote === null || quote === void 0 ? void 0 : quote.carrier.code) && (quote === null || quote === void 0 ? void 0 : quote.expired),
                quote,
            };
        };
        this.handleAfterBindResponse = (quoteWindow) => (response) => {
            quoteWindow.location.href = response;
        };
        this.onBind = () => {
            const quoteWindow = window.open('about:blank', '_blank');
            this.quoteWindow = quoteWindow;
            const quoteId = this.quote.parentQuoteRequestId || this.quote.id;
            this.handleBind(quoteId, this.appFormId, this.handleAfterBindResponse(quoteWindow));
            this.bpAnalyticsTrack.emit({
                eventName: 'ButtonClick',
                eventPayload: {
                    label: 'Update Selection',
                    value: this.annualPrice,
                    dataValue: `${this.carrierName}_${this.annualPrice}`,
                },
            });
        };
        this.annualPrice = '0';
        this.appFormId = '';
        this.carrierName = undefined;
        this.handleBind = undefined;
        this.quoteId = '';
        this.isQuoteExpired = false;
        this.quote = undefined;
        this.useExternal = false;
        this.quoteWindow = undefined;
    }
    resetState() {
        this.quoteWindow = undefined;
        this.quote = undefined;
    }
    connectedCallback() {
        this.resetState();
        this.handleSubscriptions();
    }
    disconnectedCallback() {
        this.storeUnsubscribe && this.storeUnsubscribe();
    }
    componentWillLoad() {
        this.useExternal = !!customElements.get('bp-sdk-external-quote-request-button-container');
        customElements.whenDefined('bp-sdk-external-quote-request-button-container').then(() => {
            this.useExternal = true;
        });
    }
    render() {
        return [this.useExternal && this.renderExternal(), !this.useExternal && this.renderInternal()];
    }
    renderExternal() {
        return (index.h("bp-sdk-external-quote-request-button-container", { annualPrice: this.annualPrice, appFormId: this.appFormId, carrierName: this.carrierName, handleBind: this.handleBind, quoteId: this.quoteId }));
    }
    renderInternal() {
        return (index.h("div", { class: "bp-sdk-quote-request-button-container__container bp-sdk-online-quote__bind bp-sdk-quote__bind" }, index.h("bp-sdk-quote-request-button", { onClick: !this.isQuoteExpired && this.onBind, text: "Bind", buttonDisabled: this.isQuoteExpired })));
    }
};
BpSdkQuoteRequestButtonContainer.style = BpSdkQuoteRequestButtonContainerStyle0;

const bpSdkQuoteRequestHeaderCss = "";
const BpSdkQuoteRequestHeaderStyle0 = bpSdkQuoteRequestHeaderCss;

const BpSdkQuoteRequestHeader = class {
    constructor(hostRef) {
        index.registerInstance(this, hostRef);
        this.carrier = undefined;
        this.customLogoBaseUrl = undefined;
        this.name = undefined;
        this.showCustomLogo = undefined;
        this.showLogo = undefined;
        this.quoteId = undefined;
        this.useExternal = false;
    }
    resetState() { }
    componentWillLoad() {
        this.useExternal = !!customElements.get('bp-sdk-external-quote-request-header');
        customElements.whenDefined('bp-sdk-external-quote-request-header').then(() => {
            this.useExternal = true;
        });
    }
    render() {
        return [this.useExternal && this.renderExternal(), !this.useExternal && this.renderInternal()];
    }
    renderExternal() {
        return (index.h("bp-sdk-external-quote-request-header", { carrier: this.carrier, customLogoBaseUrl: this.customLogoBaseUrl, name: this.name, showCustomLogo: this.showCustomLogo, showLogo: this.showLogo, quoteId: this.quoteId }));
    }
    renderInternal() {
        return (index.h("div", { class: "bp-sdk-quote-request-header__container bp-sdk-online-quote__header bp-sdk-quote__header" }, index.h("div", { class: "bp-sdk-online-quote__carrier bp-sdk-quote__carrier" }, index.h("h1", { class: "bp-sdk-online-quote__carrier-name bp-sdk-quote__carrier-name" }, this.name), index.h("bp-sdk-quote-request-logo-container", { carrier: this.carrier, customLogoBaseUrl: this.customLogoBaseUrl, showCustomLogo: this.showCustomLogo, showLogo: this.showLogo, quoteId: this.quoteId }))));
    }
};
BpSdkQuoteRequestHeader.style = BpSdkQuoteRequestHeaderStyle0;

const bpSdkQuoteRequestHeaderContainerCss = "";
const BpSdkQuoteRequestHeaderContainerStyle0 = bpSdkQuoteRequestHeaderContainerCss;

const BpSdkQuoteRequestHeaderContainer = class {
    constructor(hostRef) {
        index.registerInstance(this, hostRef);
        this.carrier = undefined;
        this.customLogoBaseUrl = undefined;
        this.showCustomLogo = undefined;
        this.showLogo = undefined;
        this.quoteId = undefined;
        this.useExternal = false;
        this.name = undefined;
    }
    resetState() { }
    connectedCallback() {
        this.resetState();
    }
    componentWillLoad() {
        this.useExternal = !!customElements.get('bp-sdk-external-quote-request-header-container');
        customElements.whenDefined('bp-sdk-external-quote-request-header-container').then(() => {
            this.useExternal = true;
        });
        this.onCarrierChange(this.carrier);
    }
    onCarrierChange(carrier) {
        this.name = carrier === null || carrier === void 0 ? void 0 : carrier.name;
    }
    render() {
        return [this.useExternal && this.renderExternal(), !this.useExternal && this.renderInternal()];
    }
    renderExternal() {
        return (index.h("bp-sdk-external-quote-request-header-container", { carrier: this.carrier, customLogoBaseUrl: this.customLogoBaseUrl, showCustomLogo: this.showCustomLogo, showLogo: this.showLogo, quoteId: this.quoteId }));
    }
    renderInternal() {
        return (index.h("bp-sdk-quote-request-header", { carrier: this.carrier, customLogoBaseUrl: this.customLogoBaseUrl, name: this.name, showCustomLogo: this.showCustomLogo, showLogo: this.showLogo, quoteId: this.quoteId }));
    }
    static get watchers() { return {
        "carrier": ["onCarrierChange"]
    }; }
};
BpSdkQuoteRequestHeaderContainer.style = BpSdkQuoteRequestHeaderContainerStyle0;

const bpSdkQuoteRequestPremiumCss = "";
const BpSdkQuoteRequestPremiumStyle0 = bpSdkQuoteRequestPremiumCss;

const BpSdkQuoteRequestPremium = class {
    constructor(hostRef) {
        index.registerInstance(this, hostRef);
        this.annualPrice = undefined;
        this.downpayment = undefined;
        this.installments = undefined;
        this.monthlyPrice = undefined;
        this.price = undefined;
        this.showTotalPremium = undefined;
        this.termLength = undefined;
        this.totalPremium = undefined;
        this.useExternal = false;
    }
    resetState() { }
    componentWillLoad() {
        this.useExternal = !!customElements.get('bp-sdk-external-quote-request-premium');
        customElements.whenDefined('bp-sdk-external-quote-request-premium').then(() => {
            this.useExternal = true;
        });
    }
    render() {
        return [this.useExternal && this.renderExternal(), !this.useExternal && this.renderInternal()];
    }
    renderExternal() {
        return (index.h("bp-sdk-external-quote-request-premium", { annualPrice: this.annualPrice, downpayment: this.downpayment, installments: this.installments, monthlyPrice: this.monthlyPrice, price: this.price, showTotalPremium: this.showTotalPremium, termLength: this.termLength, totalPremium: this.totalPremium }));
    }
    renderInternal() {
        return (index.h("div", { class: "bp-sdk-quote-request-premium__container bp-sdk-online-quote__price-container bp-sdk-quote__price-container" }, index.h("div", { class: "bp-sdk-online-quote__price-body bp-sdk-quote__price-body" }, index.h("bp-sdk-quote-request-premium-term", { price: this.price, showTotalPremium: this.showTotalPremium, termLength: this.termLength, totalPremium: this.totalPremium }), !!this.monthlyPrice && (index.h("bp-sdk-quote-request-premium-monthly", { annualPrice: this.annualPrice, downpayment: this.downpayment, installments: this.installments, monthlyPrice: this.monthlyPrice })))));
    }
};
BpSdkQuoteRequestPremium.style = BpSdkQuoteRequestPremiumStyle0;

const bpSdkQuoteRequestPremiumContainerCss = "";
const BpSdkQuoteRequestPremiumContainerStyle0 = bpSdkQuoteRequestPremiumContainerCss;

const BpSdkQuoteRequestPremiumContainer = class {
    constructor(hostRef) {
        index.registerInstance(this, hostRef);
        this.quoteInfo = undefined;
        this.annualPrice = undefined;
        this.downpayment = undefined;
        this.installments = undefined;
        this.monthlyPrice = undefined;
        this.price = undefined;
        this.showTotalPremium = undefined;
        this.termLength = undefined;
        this.totalPremium = undefined;
        this.useExternal = false;
    }
    resetState() { }
    componentWillLoad() {
        this.useExternal = !!customElements.get('bp-sdk-external-quote-request-premium-container');
        customElements.whenDefined('bp-sdk-external-quote-request-premium-container').then(() => {
            this.useExternal = true;
        });
        this.onQuoteInfoChange(this.quoteInfo);
    }
    onQuoteInfoChange(quoteInfo) {
        var _a;
        this.annualPrice = quoteInfo === null || quoteInfo === void 0 ? void 0 : quoteInfo.annual_price;
        this.monthlyPrice = quoteInfo === null || quoteInfo === void 0 ? void 0 : quoteInfo.monthly_price;
        this.downpayment = quoteInfo === null || quoteInfo === void 0 ? void 0 : quoteInfo.downpayment;
        this.installments = quoteInfo === null || quoteInfo === void 0 ? void 0 : quoteInfo.number_of_installments;
        this.showTotalPremium = !!((_a = quoteInfo === null || quoteInfo === void 0 ? void 0 : quoteInfo.price_details) === null || _a === void 0 ? void 0 : _a.new_total_premium);
        if (!!(quoteInfo === null || quoteInfo === void 0 ? void 0 : quoteInfo.annual_price)) {
            this.setAnnual(quoteInfo);
        }
        else if (!!(quoteInfo === null || quoteInfo === void 0 ? void 0 : quoteInfo.semiannual_price)) {
            this.setSemiAnnual(quoteInfo);
        }
        this.updateTotalPremium(quoteInfo);
    }
    setAnnual(quoteInfo) {
        this.price = quoteInfo.annual_price;
        this.termLength = 'year';
    }
    setSemiAnnual(quoteInfo) {
        this.price = quoteInfo.semiannual_price;
        this.termLength = '6-month policy term';
    }
    updateTotalPremium(quoteInfo) {
        var _a;
        if (!!((_a = quoteInfo === null || quoteInfo === void 0 ? void 0 : quoteInfo.price_details) === null || _a === void 0 ? void 0 : _a.new_total_premium)) {
            this.totalPremium =
                typeof quoteInfo.price_details.new_total_premium === 'number'
                    ? index_esm_min$2.Yh(quoteInfo.price_details.new_total_premium)
                    : quoteInfo.price_details.new_total_premium.replace(/\B(?=(\d{3})+(?!\d))/g, ',');
        }
        else {
            this.totalPremium = this.price;
        }
    }
    render() {
        return [this.useExternal && this.renderExternal(), !this.useExternal && this.renderInternal()];
    }
    renderExternal() {
        return index.h("bp-sdk-external-quote-request-premium-container", { quoteInfo: this.quoteInfo });
    }
    renderInternal() {
        return (index.h("bp-sdk-quote-request-premium", { annualPrice: this.annualPrice, downpayment: this.downpayment, installments: this.installments, monthlyPrice: this.monthlyPrice, price: this.price, showTotalPremium: this.showTotalPremium, termLength: this.termLength, totalPremium: this.totalPremium }));
    }
    static get watchers() { return {
        "quoteInfo": ["onQuoteInfoChange"]
    }; }
};
BpSdkQuoteRequestPremiumContainer.style = BpSdkQuoteRequestPremiumContainerStyle0;

const bpSdkQuoteRequestProductListCss = "";
const BpSdkQuoteRequestProductListStyle0 = bpSdkQuoteRequestProductListCss;

const BpSdkQuoteRequestProductList = class {
    constructor(hostRef) {
        index.registerInstance(this, hostRef);
        this.products = [];
        this.useExternal = false;
    }
    resetState() { }
    componentWillLoad() {
        this.useExternal = !!customElements.get('bp-sdk-external-quote-request-product-list');
        customElements.whenDefined('bp-sdk-external-quote-request-product-list').then(() => {
            this.useExternal = true;
        });
    }
    render() {
        return [this.useExternal && this.renderExternal(), !this.useExternal && this.renderInternal()];
    }
    renderExternal() {
        return index.h("bp-sdk-external-quote-request-product-list", { products: this.products });
    }
    renderInternal() {
        return (index.h("div", { class: "bp-sdk-quote-request-product-list__container bp-sdk-online-quote__products bp-sdk-quote__products" }, this.products.map((product) => (index.h("bp-sdk-quote-request-product-container", { product: product })))));
    }
};
BpSdkQuoteRequestProductList.style = BpSdkQuoteRequestProductListStyle0;

const bpSdkQuoteRequestProductListContainerCss = "";
const BpSdkQuoteRequestProductListContainerStyle0 = bpSdkQuoteRequestProductListContainerCss;

const BpSdkQuoteRequestProductListContainer = class {
    constructor(hostRef) {
        index.registerInstance(this, hostRef);
        this.products = [];
        this.useExternal = false;
    }
    resetState() { }
    componentWillLoad() {
        this.useExternal = !!customElements.get('bp-sdk-external-quote-request-product-list-container');
        customElements.whenDefined('bp-sdk-external-quote-request-product-list-container').then(() => {
            this.useExternal = true;
        });
    }
    render() {
        return [this.useExternal && this.renderExternal(), !this.useExternal && this.renderInternal()];
    }
    renderExternal() {
        return index.h("bp-sdk-external-quote-request-product-list-container", { products: this.products });
    }
    renderInternal() {
        return index.h("bp-sdk-quote-request-product-list", { products: this.products });
    }
};
BpSdkQuoteRequestProductListContainer.style = BpSdkQuoteRequestProductListContainerStyle0;

const bpSdkQuoteRequestStatusListCss = "";
const BpSdkQuoteRequestStatusListStyle0 = bpSdkQuoteRequestStatusListCss;

const BpSdkQuoteRequestStatusList = class {
    constructor(hostRef) {
        index.registerInstance(this, hostRef);
        this.isConsumerSelected = undefined;
        this.isExpired = undefined;
        this.isFocused = undefined;
        this.isRecommended = undefined;
        this.isSelected = undefined;
        this.useExternal = false;
    }
    resetState() { }
    componentWillLoad() {
        this.useExternal = !!customElements.get('bp-sdk-external-quote-request-status-list');
        customElements.whenDefined('bp-sdk-external-quote-request-status-list').then(() => {
            this.useExternal = true;
        });
    }
    render() {
        return [this.useExternal && this.renderExternal(), !this.useExternal && this.renderInternal()];
    }
    renderExternal() {
        return (index.h("bp-sdk-external-quote-request-status-list", { isConsumerSelected: this.isConsumerSelected, isExpired: this.isExpired, isFocused: this.isFocused, isRecommended: this.isRecommended, isSelected: this.isSelected }));
    }
    renderInternal() {
        return (index.h("div", { class: "bp-sdk-quote-request-status-list__container bp-sdk-online-quote-statuses-container bp-sdk-quote-statuses-container" }, this.isRecommended && index.h("bp-sdk-chip", { type: "recommended", text: "Recommended" }), this.isSelected && index.h("bp-sdk-chip", { type: "selected", text: "Selected" }), this.isConsumerSelected && index.h("bp-sdk-chip", { type: "consumer_selected", text: "Consumer Selected" }), this.isFocused && index.h("bp-sdk-chip", { type: "focused", text: "Last Viewed" }), this.isExpired && index.h("bp-sdk-chip", { type: "expired", text: "Expired" })));
    }
};
BpSdkQuoteRequestStatusList.style = BpSdkQuoteRequestStatusListStyle0;

const bpSdkQuoteRequestStatusListContainerCss = "";
const BpSdkQuoteRequestStatusListContainerStyle0 = bpSdkQuoteRequestStatusListContainerCss;

const BpSdkQuoteRequestStatusListContainer = class {
    constructor(hostRef) {
        index.registerInstance(this, hostRef);
        this.quoteStatus = undefined;
        this.useExternal = false;
        this.isConsumerSelected = false;
        this.isExpired = false;
        this.isFocused = false;
        this.isRecommended = false;
        this.isSelected = false;
    }
    resetState() { }
    componentWillLoad() {
        this.useExternal = !!customElements.get('bp-sdk-external-quote-request-status-list-container');
        customElements.whenDefined('bp-sdk-external-quote-request-status-list-container').then(() => {
            this.useExternal = true;
        });
        this.onQuoteStatusChange(this.quoteStatus);
    }
    onQuoteStatusChange(quoteStatus) {
        this.isConsumerSelected = !!(quoteStatus === null || quoteStatus === void 0 ? void 0 : quoteStatus.consumer_selected);
        this.isExpired = !!(quoteStatus === null || quoteStatus === void 0 ? void 0 : quoteStatus.expired);
        this.isFocused = !!(quoteStatus === null || quoteStatus === void 0 ? void 0 : quoteStatus.focused);
        this.isRecommended = !!(quoteStatus === null || quoteStatus === void 0 ? void 0 : quoteStatus.recommended);
        this.isSelected = !!(quoteStatus === null || quoteStatus === void 0 ? void 0 : quoteStatus.selected);
    }
    render() {
        return [this.useExternal && this.renderExternal(), !this.useExternal && this.renderInternal()];
    }
    renderExternal() {
        return index.h("bp-sdk-external-quote-request-status-list-container", { quoteStatus: this.quoteStatus });
    }
    renderInternal() {
        return (index.h("div", { class: "bp-sdk-quote-request-status-list-container__container" }, index.h("bp-sdk-quote-request-status-list", { isConsumerSelected: this.isConsumerSelected, isExpired: this.isExpired, isFocused: this.isFocused, isRecommended: this.isRecommended, isSelected: this.isSelected })));
    }
    static get watchers() { return {
        "quoteStatus": ["onQuoteStatusChange"]
    }; }
};
BpSdkQuoteRequestStatusListContainer.style = BpSdkQuoteRequestStatusListContainerStyle0;

const bpSdkQuoteRequestTaxesAndFeesCss = "";
const BpSdkQuoteRequestTaxesAndFeesStyle0 = bpSdkQuoteRequestTaxesAndFeesCss;

const BpSdkQuoteRequestTaxesAndFees = class {
    constructor(hostRef) {
        index.registerInstance(this, hostRef);
        this.disclaimerHtml = undefined;
        this.fees = [];
        this.taxes = [];
        this.useExternal = false;
    }
    resetState() { }
    componentWillLoad() {
        this.useExternal = !!customElements.get('bp-sdk-external-quote-request-taxes-and-fees');
        customElements.whenDefined('bp-sdk-external-quote-request-taxes-and-fees').then(() => {
            this.useExternal = true;
        });
    }
    render() {
        return [this.useExternal && this.renderExternal(), !this.useExternal && this.renderInternal()];
    }
    renderExternal() {
        return index.h("bp-sdk-external-quote-request-taxes-and-fees", { "disclaimer-html": this.disclaimerHtml, fees: this.fees, taxes: this.taxes });
    }
    renderInternal() {
        return (index.h("div", { class: "bp-sdk-quote-request-taxes-and-fees__container" }, index.h("div", { class: "bp-sdk-quote-request-taxes-and-fees--subtotal" }, index.h("div", null, "Taxes and fees included in your premium"), index.h("bp-sdk-quote-request-fees", { fees: this.taxes, description: 'taxes' }), index.h("bp-sdk-quote-request-fees", { fees: this.fees, description: 'fees' })), !!this.disclaimerHtml && (index.h("div", { class: "bp-sdk-quote-request-taxes-and-fees--disclaimer-container" }, index.h("div", { class: "bp-sdk-quote-request-taxes-and-fees--disclaimer bp-sdk-quote-request--disclaimer", innerHTML: this.disclaimerHtml })))));
    }
};
BpSdkQuoteRequestTaxesAndFees.style = BpSdkQuoteRequestTaxesAndFeesStyle0;

const bpSdkQuoteRequestTaxesAndFeesContainerCss = "";
const BpSdkQuoteRequestTaxesAndFeesContainerStyle0 = bpSdkQuoteRequestTaxesAndFeesContainerCss;

const BpSdkQuoteRequestTaxesAndFeesContainer = class {
    constructor(hostRef) {
        index.registerInstance(this, hostRef);
        this.quoteInfo = undefined;
        this.useExternal = false;
        this.disclaimerHtml = undefined;
        this.fees = [];
        this.taxes = [];
    }
    resetState() { }
    componentWillLoad() {
        this.useExternal = !!customElements.get('bp-sdk-external-quote-request-taxes-and-fees-container');
        customElements.whenDefined('bp-sdk-external-quote-request-taxes-and-fees-container').then(() => {
            this.useExternal = true;
        });
        this.onQuoteInfoChange(this.quoteInfo);
    }
    onQuoteInfoChange(quoteInfo) {
        var _a, _b, _c, _d, _e;
        this.disclaimerHtml = (_a = quoteInfo === null || quoteInfo === void 0 ? void 0 : quoteInfo.price_details) === null || _a === void 0 ? void 0 : _a.disclaimer_html;
        this.taxes = (_c = (_b = quoteInfo === null || quoteInfo === void 0 ? void 0 : quoteInfo.price_details) === null || _b === void 0 ? void 0 : _b.taxes) !== null && _c !== void 0 ? _c : [];
        this.fees = (_e = (_d = quoteInfo === null || quoteInfo === void 0 ? void 0 : quoteInfo.price_details) === null || _d === void 0 ? void 0 : _d.fees) !== null && _e !== void 0 ? _e : [];
    }
    render() {
        return [this.useExternal && this.renderExternal(), !this.useExternal && this.renderInternal()];
    }
    renderExternal() {
        return index.h("bp-sdk-external-quote-request-taxes-and-fees-container", { quoteInfo: this.quoteInfo });
    }
    renderInternal() {
        return index.h("bp-sdk-quote-request-taxes-and-fees", { disclaimerHtml: this.disclaimerHtml, fees: this.fees, taxes: this.taxes });
    }
    static get watchers() { return {
        "quoteInfo": ["onQuoteInfoChange"]
    }; }
};
BpSdkQuoteRequestTaxesAndFeesContainer.style = BpSdkQuoteRequestTaxesAndFeesContainerStyle0;

exports.bp_sdk_quote_request_bind_container = BpSdkQuoteRequestBindContainer;
exports.bp_sdk_quote_request_button_container = BpSdkQuoteRequestButtonContainer;
exports.bp_sdk_quote_request_header = BpSdkQuoteRequestHeader;
exports.bp_sdk_quote_request_header_container = BpSdkQuoteRequestHeaderContainer;
exports.bp_sdk_quote_request_premium = BpSdkQuoteRequestPremium;
exports.bp_sdk_quote_request_premium_container = BpSdkQuoteRequestPremiumContainer;
exports.bp_sdk_quote_request_product_list = BpSdkQuoteRequestProductList;
exports.bp_sdk_quote_request_product_list_container = BpSdkQuoteRequestProductListContainer;
exports.bp_sdk_quote_request_status_list = BpSdkQuoteRequestStatusList;
exports.bp_sdk_quote_request_status_list_container = BpSdkQuoteRequestStatusListContainer;
exports.bp_sdk_quote_request_taxes_and_fees = BpSdkQuoteRequestTaxesAndFees;
exports.bp_sdk_quote_request_taxes_and_fees_container = BpSdkQuoteRequestTaxesAndFeesContainer;
