import{state as checkoutState}from"../../../../store/checkout/index";const ORDER_KEYS={total:"total_display_amount",subtotal:"subtotal_display_amount",amount_due:"amount_due_display_amount"};export class ScTotal{constructor(){this.order_key={total:"total_display_amount",subtotal:"subtotal_display_amount",amount_due:"amount_due_display_amount"},this.total="amount_due",this.checkout=void 0}render(){var t,o;const e=this.checkout||(null==checkoutState?void 0:checkoutState.checkout);if((null==e?void 0:e.currency)&&(null===(o=null===(t=null==e?void 0:e.line_items)||void 0===t?void 0:t.data)||void 0===o?void 0:o.length))return(null==e?void 0:e[ORDER_KEYS[this.total]])||""}static get is(){return"sc-total"}static get originalStyleUrls(){return{$:["sc-total.css"]}}static get styleUrls(){return{$:["sc-total.css"]}}static get properties(){return{total:{type:"string",mutable:!1,complexType:{original:"'total' | 'subtotal' | 'amount_due'",resolved:'"amount_due" | "subtotal" | "total"',references:{}},required:!1,optional:!1,docs:{tags:[],text:""},attribute:"total",reflect:!1,defaultValue:"'amount_due'"},checkout:{type:"unknown",mutable:!1,complexType:{original:"Checkout",resolved:"Checkout",references:{Checkout:{location:"import",path:"../../../../types",id:"src/types.ts::Checkout"}}},required:!1,optional:!0,docs:{tags:[],text:""}}}}}