import{h}from"@stencil/core";import{isRtl}from"../../../functions/page-align";export class ScLineItem{constructor(){this.price=void 0,this.currency=void 0,this.hasImageSlot=void 0,this.hasTitleSlot=void 0,this.hasDescriptionSlot=void 0,this.hasPriceSlot=void 0,this.hasPriceDescriptionSlot=void 0,this.hasCurrencySlot=void 0}componentWillLoad(){this.hasImageSlot=!!this.hostElement.querySelector('[slot="image"]'),this.hasTitleSlot=!!this.hostElement.querySelector('[slot="title"]'),this.hasDescriptionSlot=!!this.hostElement.querySelector('[slot="description"]'),this.hasPriceSlot=!!this.hostElement.querySelector('[slot="price"]'),this.hasPriceDescriptionSlot=!!this.hostElement.querySelector('[slot="price-description"]'),this.hasCurrencySlot=!!this.hostElement.querySelector('[slot="currency"]')}render(){return h("div",{key:"eb779fdabfb8e7b574c3498f18bf61da0fccd15c",part:"base",class:{item:!0,"item--has-image":this.hasImageSlot,"item--has-title":this.hasTitleSlot,"item--has-description":this.hasDescriptionSlot,"item--has-price":this.hasPriceSlot,"item--has-price-description":this.hasPriceDescriptionSlot,"item--has-price-currency":this.hasCurrencySlot,"item--is-rtl":isRtl()}},h("div",{key:"18fc5cb86fc42bd327b84f5d8e4fe5d72c7332ee",class:"item__image",part:"image"},h("slot",{key:"75ea227a9f3346d15b81863bca5adec355a77240",name:"image"})),h("div",{key:"224b09648ec562e551d3f631d2082425b796bf97",class:"item__text",part:"text"},h("div",{key:"dc73bfa9f8606ba547c3ea213763414f379428e7",class:"item__title",part:"title"},h("slot",{key:"d457093d784e3db2a4b52cd96080483278a7211b",name:"title"})),h("div",{key:"5389fdc871db15411ece3abd75291178bfa093ac",class:"item__description",part:"description"},h("slot",{key:"9db9c5a0de16257e9870cd49e7d363b0ac8bc475",name:"description"}))),h("div",{key:"dc268af361360718f637b4d4ba65e42d75a2b7c6",class:"item__end",part:"price"},h("div",{key:"526361c6956f56458395d99d6415db1cbbfd10da",class:"item__price-currency",part:"currency"},h("slot",{key:"405e5ae1d0b0c18d8aac14761fe9ddb4b8dde115",name:"currency"})),h("div",{key:"aeb4a8bf5e6db065f17c68be9e8cb38e0fa6ec42",class:"item__price-text",part:"price-text"},h("div",{key:"1dbd5313812dfe8e1abb389b74799676609c53f3",class:"item__price",part:"price"},h("slot",{key:"9aafba491c1dac375d47c116f663d7006695c45e",name:"price"})),h("div",{key:"ecc3b906c22c6091e77b462a580cf08f80e070e6",class:"item__price-description",part:"price-description"},h("slot",{key:"876483735ba8d990f84ce51c7f59abcbe7f1a9d9",name:"price-description"})))))}static get is(){return"sc-line-item"}static get encapsulation(){return"shadow"}static get originalStyleUrls(){return{$:["sc-line-item.scss"]}}static get styleUrls(){return{$:["sc-line-item.css"]}}static get properties(){return{price:{type:"string",mutable:!1,complexType:{original:"string",resolved:"string",references:{}},required:!1,optional:!1,docs:{tags:[],text:"Price of the item"},attribute:"price",reflect:!1},currency:{type:"string",mutable:!1,complexType:{original:"string",resolved:"string",references:{}},required:!1,optional:!1,docs:{tags:[],text:"Currency symbol"},attribute:"currency",reflect:!1}}}static get states(){return{hasImageSlot:{},hasTitleSlot:{},hasDescriptionSlot:{},hasPriceSlot:{},hasPriceDescriptionSlot:{},hasCurrencySlot:{}}}static get elementRef(){return"hostElement"}}