import{n as e,l as t,m as r,E as n,t as o,C as i,W as a,R as l,O as s,j as c,r as u,k as f}from"./p-BxEPsDRj.js";import{c as d,r as w}from"./p-CrMmJdZ6.js";import"./p-YV_GhS6X.js";var p=e``;var y=undefined&&undefined.__decorate||function(e,t,r,n){var o=arguments.length,i=o<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,r):n,a;if(typeof Reflect==="object"&&typeof Reflect.decorate==="function")i=Reflect.decorate(e,t,r,n);else for(var l=e.length-1;l>=0;l--)if(a=e[l])i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i;return o>3&&i&&Object.defineProperty(t,r,i),i};let m=class e extends t{render(){const{termsConditionsUrl:e,privacyPolicyUrl:t}=s.state;if(!e&&!t){return null}return r`
      <wui-flex
        .padding=${["4","3","3","3"]}
        flexDirection="column"
        alignItems="center"
        justifyContent="center"
        gap="3"
      >
        <wui-text color="secondary" variant="md-regular" align="center">
          We work with the best providers to give you the lowest fees and best support. More options
          coming soon!
        </wui-text>

        ${this.howDoesItWorkTemplate()}
      </wui-flex>
    `}howDoesItWorkTemplate(){return r` <wui-link @click=${this.onWhatIsBuy.bind(this)}>
      <wui-icon size="xs" color="accent-primary" slot="iconLeft" name="helpCircle"></wui-icon>
      How does it work?
    </wui-link>`}onWhatIsBuy(){n.sendEvent({type:"track",event:"SELECT_WHAT_IS_A_BUY",properties:{isSmartAccount:o(i.state.activeChain)===a.ACCOUNT_TYPES.SMART_ACCOUNT}});l.push("WhatIsABuy")}};m.styles=[p];m=y([d("w3m-onramp-providers-footer")],m);const x="https://reown.com";var h=c`
  .reown-logo {
    height: 24px;
  }

  a {
    text-decoration: none;
    cursor: pointer;
    color: ${({tokens:e})=>e.theme.textSecondary};
  }

  a:hover {
    opacity: 0.9;
  }
`;var g=undefined&&undefined.__decorate||function(e,t,r,n){var o=arguments.length,i=o<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,r):n,a;if(typeof Reflect==="object"&&typeof Reflect.decorate==="function")i=Reflect.decorate(e,t,r,n);else for(var l=e.length-1;l>=0;l--)if(a=e[l])i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i;return o>3&&i&&Object.defineProperty(t,r,i),i};let v=class e extends t{render(){return r`
      <a
        data-testid="ux-branding-reown"
        href=${x}
        rel="noreferrer"
        target="_blank"
        style="text-decoration: none;"
      >
        <wui-flex
          justifyContent="center"
          alignItems="center"
          gap="1"
          .padding=${["01","0","3","0"]}
        >
          <wui-text variant="sm-regular" color="inherit"> UX by </wui-text>
          <wui-icon name="reown" size="inherit" class="reown-logo"></wui-icon>
        </wui-flex>
      </a>
    `}};v.styles=[u,f,h];v=g([d("wui-ux-by-reown")],v);var b=c`
  :host wui-ux-by-reown {
    padding-top: 0;
  }

  :host wui-ux-by-reown.branding-only {
    padding-top: ${({spacing:e})=>e["3"]};
  }

  a {
    text-decoration: none;
    color: ${({tokens:e})=>e.core.textAccentPrimary};
    font-weight: 500;
  }
`;var j=undefined&&undefined.__decorate||function(e,t,r,n){var o=arguments.length,i=o<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,r):n,a;if(typeof Reflect==="object"&&typeof Reflect.decorate==="function")i=Reflect.decorate(e,t,r,n);else for(var l=e.length-1;l>=0;l--)if(a=e[l])i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i;return o>3&&i&&Object.defineProperty(t,r,i),i};let $=class e extends t{constructor(){super();this.unsubscribe=[];this.remoteFeatures=s.state.remoteFeatures;this.unsubscribe.push(s.subscribeKey("remoteFeatures",(e=>this.remoteFeatures=e)))}disconnectedCallback(){this.unsubscribe.forEach((e=>e()))}render(){const{termsConditionsUrl:e,privacyPolicyUrl:t}=s.state;const n=s.state.features?.legalCheckbox;const o=!e&&!t||n;if(o){return r`
        <wui-flex flexDirection="column"> ${this.reownBrandingTemplate(true)} </wui-flex>
      `}return r`
      <wui-flex flexDirection="column">
        <wui-flex .padding=${["4","3","3","3"]} justifyContent="center">
          <wui-text color="secondary" variant="md-regular" align="center">
            By connecting your wallet, you agree to our <br />
            ${this.termsTemplate()} ${this.andTemplate()} ${this.privacyTemplate()}
          </wui-text>
        </wui-flex>
        ${this.reownBrandingTemplate()}
      </wui-flex>
    `}andTemplate(){const{termsConditionsUrl:e,privacyPolicyUrl:t}=s.state;return e&&t?"and":""}termsTemplate(){const{termsConditionsUrl:e}=s.state;if(!e){return null}return r`<a href=${e} target="_blank" rel="noopener noreferrer"
      >Terms of Service</a
    >`}privacyTemplate(){const{privacyPolicyUrl:e}=s.state;if(!e){return null}return r`<a href=${e} target="_blank" rel="noopener noreferrer"
      >Privacy Policy</a
    >`}reownBrandingTemplate(e=false){if(!this.remoteFeatures?.reownBranding){return null}if(e){return r`<wui-ux-by-reown class="branding-only"></wui-ux-by-reown>`}return r`<wui-ux-by-reown></wui-ux-by-reown>`}};$.styles=[b];j([w()],$.prototype,"remoteFeatures",void 0);$=j([d("w3m-legal-footer")],$);
//# sourceMappingURL=p-CsctQ88z.js.map