import { Component, Element, h, Prop, State } from "@stencil/core";
import * as translation from "./translation";
export class MerchantTerms {
  componentWillLoad() {
    this.t = translation.create(this.element);
  }
  render() {
    const t = this.t;
    return [
      h("p", null, !this.merchant
        ? ""
        : this.merchant.terms
          ? t("By clicking the $0 button I accept the terms and conditions ($1).", this.buttonName, this.merchant.terms)
          : ""),
    ];
  }
  static get is() { return "merchant-terms"; }
  static get encapsulation() { return "scoped"; }
  static get originalStyleUrls() { return {
    "$": ["style.css"]
  }; }
  static get styleUrls() { return {
    "$": ["style.css"]
  }; }
  static get properties() { return {
    "merchant": {
      "type": "unknown",
      "mutable": false,
      "complexType": {
        "original": "MerchantKeyInfo",
        "resolved": "Key | undefined",
        "references": {
          "MerchantKeyInfo": {
            "location": "import",
            "path": "../model"
          }
        }
      },
      "required": false,
      "optional": true,
      "docs": {
        "tags": [],
        "text": ""
      }
    },
    "buttonName": {
      "type": "string",
      "mutable": false,
      "complexType": {
        "original": "string",
        "resolved": "string | undefined",
        "references": {}
      },
      "required": false,
      "optional": true,
      "docs": {
        "tags": [],
        "text": ""
      },
      "attribute": "button-name",
      "reflect": false
    }
  }; }
  static get states() { return {
    "t": {}
  }; }
  static get elementRef() { return "element"; }
}
