/*!
 * Crafted with ❤ by Salla
 */
import { h, Host } from "@stencil/core";
export class SallaLoyaltyPrizeItem {
    onPrizeItemClick() {
        this.prizeItemSelected.emit(this.item);
    }
    render() {
        return (h(Host, { key: 'd3b79cbf7e67281d4c42c83084b2d1f0f59fd77d' }, h("div", { key: '11d71896f19eef94434fa8d9d074c98ce3e6de5b', onClick: this.onPrizeItemClick.bind(this) }, h("img", { key: 'c8d254e77a7af0559c5336aca9d7d57593814d0a', class: "s-loyalty-prize-item-image", src: this.item.image, alt: this.item.name }), h("div", { key: '5946e1d5ce94ef8bfcbab95ab2f2e8733145b7f2', class: "s-loyalty-prize-item-title" }, this.item.name), h("div", { key: 'c565935591c84ce475767b8a863323023fabae31', class: "s-loyalty-prize-item-subtitle" }, this.item.description), h("div", { key: '225c7c594cb1942a56a6966ab8289a4dfb7f0d71', class: "s-loyalty-prize-item-points" }, this.item.cost_points, " ", salla.lang.get('pages.loyalty_program.point')))));
    }
    static get is() { return "salla-loyalty-prize-item"; }
    static get originalStyleUrls() {
        return {
            "$": ["salla-loyalty-prize-item.scss"]
        };
    }
    static get styleUrls() {
        return {
            "$": ["salla-loyalty-prize-item.css"]
        };
    }
    static get properties() {
        return {
            "item": {
                "type": "unknown",
                "attribute": "item",
                "mutable": false,
                "complexType": {
                    "original": "Item",
                    "resolved": "Item",
                    "references": {
                        "Item": {
                            "location": "import",
                            "path": "./loyalty-schema",
                            "id": "src/components/salla-loyalty/loyalty-schema.ts::Item"
                        }
                    }
                },
                "required": false,
                "optional": false,
                "docs": {
                    "tags": [],
                    "text": "Prize item to be displayed in this component."
                },
                "getter": false,
                "setter": false
            }
        };
    }
    static get events() {
        return [{
                "method": "prizeItemSelected",
                "name": "prizeItemSelected",
                "bubbles": true,
                "cancelable": true,
                "composed": true,
                "docs": {
                    "tags": [],
                    "text": "Event emmited when the user select this item."
                },
                "complexType": {
                    "original": "Item",
                    "resolved": "Item",
                    "references": {
                        "Item": {
                            "location": "import",
                            "path": "./loyalty-schema",
                            "id": "src/components/salla-loyalty/loyalty-schema.ts::Item"
                        }
                    }
                }
            }];
    }
}
