@hintergrund/ui 0.2.1 → 0.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Builder-H8tY8V9I.js +14172 -0
- package/dist/admin.js +11160 -9739
- package/dist/{anthropic-UhrJpH25.js → anthropic-messages-C3hIUlsA.js} +1134 -1055
- package/dist/azure-openai-responses-t7u41KMr.js +222 -0
- package/dist/builder.js +2 -2
- package/dist/client-Cd7yMX39.js +7860 -0
- package/dist/deferred-tools-BZWMWBYN.js +28 -0
- package/dist/error-body-BUPcH4GF.js +71 -0
- package/dist/github-copilot-headers-B1RBGoZi.js +21 -0
- package/dist/{global-CFcrkAa3.js → global-Bk9T4Af5.js} +17896 -16508
- package/dist/google-generative-ai-6ZG79NDC.js +264 -0
- package/dist/{google-shared-BmdaIInh.js → google-shared-C6y4fA42.js} +1135 -1104
- package/dist/google-vertex-f2myaAmm.js +305 -0
- package/dist/headers-D4iLzGaS.js +21 -0
- package/dist/json-parse-LZdWp-Nd.js +232 -0
- package/dist/login.js +79 -75
- package/dist/mistral-conversations-D16H8Mgq.js +513 -0
- package/dist/openai-codex-responses-DIHPbnIS.js +947 -0
- package/dist/openai-completions-vDHGFsWV.js +741 -0
- package/dist/{headers-u7rXGJ9f.js → openai-prompt-cache-BJwqbEDx.js} +7 -6
- package/dist/openai-responses-B0rjAJxx.js +184 -0
- package/dist/openai-responses-shared-DqdzMfa_.js +477 -0
- package/dist/pi-messages-DB2BtH-g.js +251 -0
- package/dist/pi-user-agent-CUqx-qiX.js +13 -0
- package/dist/provider-env-D2VjEV3S.js +26 -0
- package/dist/provider-retry-BsigVlMg.js +67 -0
- package/dist/setup.js +275 -188
- package/dist/transform-messages-CsKsy6b4.js +398 -0
- package/package.json +4 -5
- package/dist/Builder-B0XYsyXe.js +0 -163449
- package/dist/azure-openai-responses-DAC03Qw1.js +0 -203
- package/dist/client-Sh7wNjbG.js +0 -5277
- package/dist/github-copilot-headers-DWh_6bE3.js +0 -35
- package/dist/google-CVz_TaG6.js +0 -248
- package/dist/google-vertex-C6GE41DE.js +0 -285
- package/dist/json-parse-DmJ6NiZE.js +0 -93
- package/dist/mistral-DqYbzWvv.js +0 -22932
- package/dist/openai-codex-responses-ZWuD9ryk.js +0 -700
- package/dist/openai-completions-B6B2OwYj.js +0 -535
- package/dist/openai-responses-D9Ip2Wgd.js +0 -142
- package/dist/openai-responses-shared-eUUJSL4D.js +0 -324
- package/dist/transform-messages-CkpQp6fJ.js +0 -132
package/dist/setup.js
CHANGED
|
@@ -1,226 +1,313 @@
|
|
|
1
|
-
import {
|
|
2
|
-
typeof globalThis.process > "u" && (globalThis.process = { env: {}, platform: "browser", version: "", versions: {}, browser: !0, nextTick: function(
|
|
3
|
-
return Promise.resolve().then(
|
|
1
|
+
import { _ as es, $ as ss, a0 as as, a1 as ts, a2 as rs, N as e, S as o, a4 as s, a5 as t, aa as I, a8 as c, ad as os, U as v, ae as _, ag as a, ab as U, aj as J, ai as f, ah as B, a6 as pe, a7 as F, al as Q, ao as Pe, aL as $e, a3 as Be, ak as ls, au as Ae, aB as is, af as ue, ac as k, bi as De, an as ns } from "./global-Bk9T4Af5.js";
|
|
2
|
+
typeof globalThis.process > "u" && (globalThis.process = { env: {}, platform: "browser", version: "", versions: {}, browser: !0, nextTick: function(X) {
|
|
3
|
+
return Promise.resolve().then(X);
|
|
4
4
|
} });
|
|
5
|
-
var
|
|
6
|
-
|
|
7
|
-
and their order number as the payment reference; you confirm that the money arrived in your
|
|
8
|
-
dashboard. If you prefer card payments, connect Stripe and run both side by side — the processing
|
|
9
|
-
fee is Stripe’s, never ours.</div> <div class="form-group"><label for="account-holder">Account holder</label> <input id="account-holder" class="form-control" autocomplete="organization"/></div> <div class="form-group"><label for="iban">IBAN</label> <input id="iban" class="form-control" autocomplete="off" placeholder="DE…"/></div> <div class="form-row svelte-1sk6wwy"><div class="form-group"><label for="bic">BIC <span class="optional svelte-1sk6wwy">optional</span></label> <input id="bic" class="form-control" autocomplete="off"/></div> <div class="form-group"><label for="bank-name">Bank name <span class="optional svelte-1sk6wwy">optional</span></label> <input id="bank-name" class="form-control" autocomplete="organization"/></div></div> <div class="form-group"><label for="instructions">Payment instructions <span class="optional svelte-1sk6wwy">optional</span></label> <textarea id="instructions" class="form-control" placeholder="Please use your order number as the payment reference."></textarea></div> <fieldset class="choices svelte-1sk6wwy"><legend class="svelte-1sk6wwy">Payment methods</legend> <label class="choice svelte-1sk6wwy"><input type="radio" class="svelte-1sk6wwy"/> <span class="choice-text svelte-1sk6wwy"><strong class="svelte-1sk6wwy">Bank transfer only</strong> <small class="svelte-1sk6wwy">No processing fee; confirm incoming payments yourself.</small></span></label> <label class="choice svelte-1sk6wwy"><input type="radio" class="svelte-1sk6wwy"/> <span class="choice-text svelte-1sk6wwy"><strong class="svelte-1sk6wwy">Add Stripe for card payments</strong> <small class="svelte-1sk6wwy">Use card payments alongside bank transfer.</small></span></label></fieldset> <!></div></div>`), Oe = z(`<div class="Box"><div class="Box-header"><h2>Set up email</h2> <p>Plunk sends order, subscriber, and administrator emails. You can skip this for now.</p></div> <div class="Box-body"><div class="notice svelte-1sk6wwy">Create a Plunk account, verify the domain you will send from, then create an API key.
|
|
10
|
-
The sender email must use that verified domain.</div> <div class="form-group"><label for="plunk-key">Plunk API key <span class="optional svelte-1sk6wwy">optional</span></label> <input id="plunk-key" class="form-control" type="password" autocomplete="off" placeholder="plunk_…"/></div> <div class="form-row svelte-1sk6wwy"><div class="form-group"><label for="from-email">Sender email</label> <input id="from-email" class="form-control" type="email" autocomplete="email" placeholder="hello@yourdomain.com"/></div> <div class="form-group"><label for="from-name">Sender name <span class="optional svelte-1sk6wwy">optional</span></label> <input id="from-name" class="form-control" autocomplete="organization"/></div></div> <div class="form-group"><label for="reply-to">Reply-to email <span class="optional svelte-1sk6wwy">optional</span></label> <input id="reply-to" class="form-control" type="email" autocomplete="email"/></div> <div class="links svelte-1sk6wwy"><a href="https://app.useplunk.com" target="_blank" rel="noreferrer" class="svelte-1sk6wwy">Create or open your Plunk account ↗</a> <a href="https://docs.useplunk.com/guides/verifying-domains" target="_blank" rel="noreferrer" class="svelte-1sk6wwy">Verify your sending domain ↗</a> <a href="https://docs.useplunk.com/guides/api-keys" target="_blank" rel="noreferrer" class="svelte-1sk6wwy">Create a Plunk API key ↗</a></div></div></div>`), Qe = z("<span></span>"), Ge = z('<main class="setup-wrapper svelte-1sk6wwy"><div class="setup-container svelte-1sk6wwy"><div class="setup-header svelte-1sk6wwy"><svg class="setup-logo svelte-1sk6wwy" viewBox="0 0 90 90" width="48" height="48" fill="currentColor"><rect x="12" y="12" width="66" height="66" fill="currentColor"></rect></svg> <h1 class="svelte-1sk6wwy">Set up Hintergrund</h1> <p class="setup-subtitle svelte-1sk6wwy">Three short steps and your site is live.</p></div> <ol class="steps svelte-1sk6wwy" aria-label="Setup progress"></ol> <!> <form autocomplete="off"><!> <div class="actions svelte-1sk6wwy"><!> <!></div></form></div></main>');
|
|
11
|
-
const Xe = {
|
|
5
|
+
var ds = _('<div class="flash flash-error" role="alert"><svg class="octicon" xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16"><path d="M2.343 13.657A8 8 0 1 1 13.658 2.343 8 8 0 0 1 2.343 13.657ZM6.03 4.97a.751.751 0 0 0-1.042.018.751.751 0 0 0-.018 1.042L6.94 8 4.97 9.97a.749.749 0 0 0 .326 1.275.749.749 0 0 0 .734-.215L8 9.06l1.97 1.97a.749.749 0 0 0 1.275-.326.749.749 0 0 0-.215-.734L9.06 8l1.97-1.97a.749.749 0 0 0-.326-1.275.749.749 0 0 0-.734.215L8 6.94Z"></path></svg> </div>'), vs = _('<small class="note-inline svelte-1sk6wwy">Required by the shop for order confirmations and invoices.</small>'), cs = _('<small class="note-inline svelte-1sk6wwy">Lets you sign in with a one-time email code.</small>'), ps = _('<section class="Box provider-selection" aria-labelledby="modules-title"><div class="Box-header"><h2 id="modules-title">What should your site do?</h2> <p>Everything is included. Choose what you need now — you can turn these on or off later in Settings.</p></div> <div class="Box-body"><fieldset class="provider-choices svelte-1sk6wwy"><legend class="svelte-1sk6wwy">Site features</legend> <label><input type="checkbox" class="svelte-1sk6wwy"/> <span class="svelte-1sk6wwy"><strong class="svelte-1sk6wwy">Shop</strong> <small class="svelte-1sk6wwy">Sell products, take orders, and issue invoices.</small> <small class="svelte-1sk6wwy">Needs a payment method, and sends order confirmations by email.</small></span></label> <label><input type="checkbox" class="svelte-1sk6wwy"/> <span class="svelte-1sk6wwy"><strong class="svelte-1sk6wwy">Emails</strong> <small class="svelte-1sk6wwy">Newsletter signup, campaigns, and transactional email.</small> <!></span></label></fieldset> <p class="note svelte-1sk6wwy">Turning a feature off only hides it. Nothing is deleted, so you can enable it again at any time.</p> <div class="actions selection-actions svelte-1sk6wwy"><span></span> <!></div></div></section>'), us = _('<li><button type="button"><span class="step-index svelte-1sk6wwy"> </span> <span class="step-label svelte-1sk6wwy"> </span></button></li>'), ws = _('<div class="Box"><div class="Box-header"><h2>Create your administrator account</h2> <p>Your site title is already set. Choose the credentials for its first administrator.</p></div> <div class="Box-body"><div class="form-group"><label for="admin-email">Email address</label> <input id="admin-email" class="form-control" type="email" required="" autocomplete="email" placeholder="you@example.com"/> <p class="note svelte-1sk6wwy">You sign in with this address. Admin notices go here too.</p></div> <div class="form-group"><label for="admin-password">Password</label> <div class="input-group svelte-1sk6wwy"><input id="admin-password" class="form-control" required="" autocomplete="new-password"/> <button class="password-toggle svelte-1sk6wwy" type="button"> </button></div> <p class="note svelte-1sk6wwy"> <!></p></div></div></div>'), ms = _('<div class="form-group"><label for="account-holder">Account holder</label> <input id="account-holder" class="form-control" required="" autocomplete="organization"/></div> <div class="form-group"><label for="iban">IBAN</label> <input id="iban" class="form-control" required="" autocomplete="off" placeholder="DE…"/></div> <div class="form-row svelte-1sk6wwy"><div class="form-group"><label for="bic">BIC <span class="optional svelte-1sk6wwy">optional</span></label><input id="bic" class="form-control" autocomplete="off"/></div> <div class="form-group"><label for="bank-name">Bank name <span class="optional svelte-1sk6wwy">optional</span></label><input id="bank-name" class="form-control" autocomplete="organization"/></div></div> <div class="form-group"><label for="instructions">Payment instructions <span class="optional svelte-1sk6wwy">optional</span></label> <textarea id="instructions" class="form-control" placeholder="Please use your order number as the payment reference."></textarea></div>', 1), fs = _('<div class="form-group"><label for="stripe-secret">Stripe secret key</label> <input id="stripe-secret" class="form-control" type="password" required="" autocomplete="off" placeholder="sk_live_…"/></div> <div class="form-group"><label for="stripe-webhook">Stripe webhook secret <span class="optional svelte-1sk6wwy">optional</span></label> <input id="stripe-webhook" class="form-control" type="password" autocomplete="off" placeholder="whsec_…"/> <p class="note svelte-1sk6wwy">Leave blank and we create the webhook for you.</p></div> <div class="links svelte-1sk6wwy"><a href="https://dashboard.stripe.com/register" target="_blank" rel="noreferrer" class="svelte-1sk6wwy">Create a Stripe account ↗</a> <a href="https://docs.stripe.com/keys" target="_blank" rel="noreferrer" class="svelte-1sk6wwy">Find your API keys ↗</a> <a href="https://docs.stripe.com/webhooks" target="_blank" rel="noreferrer" class="svelte-1sk6wwy">Learn about webhooks ↗</a></div>', 1), bs = _('<div class="Box"><div class="Box-header"><h2>Set up payments</h2> <p>Choose how your customers pay, then add the details for that method.</p></div> <div class="Box-body"><fieldset class="provider-choices svelte-1sk6wwy"><legend class="svelte-1sk6wwy">How would you like to accept payments?</legend> <label><input type="radio" class="svelte-1sk6wwy"/> <span class="svelte-1sk6wwy"><strong class="svelte-1sk6wwy">SEPA bank transfer</strong> <small class="svelte-1sk6wwy"><b>Best for:</b> businesses with an EU bank account that are happy to confirm payments manually.</small> <small class="svelte-1sk6wwy"><b>Pros:</b> no processing fee. <b>Trade-off:</b> customers transfer the money and you confirm its arrival in your dashboard.</small></span></label> <label><input type="radio" class="svelte-1sk6wwy"/> <span class="svelte-1sk6wwy"><strong class="svelte-1sk6wwy">Stripe card payments</strong> <small class="svelte-1sk6wwy"><b>Best for:</b> accepting cards and wallet payments automatically.</small> <small class="svelte-1sk6wwy"><b>Pros:</b> automatic payment confirmation. <b>Trade-off:</b> Stripe requires supported ID and business verification and charges its own processing fee.</small></span></label></fieldset> <p class="note svelte-1sk6wwy">Payment-provider accounts and fees are always between you and the provider. Hintergrund never takes a cut of a sale.</p> <!></div></div>'), ys = _('<div class="Box"><div class="Box-header"><h2>Set up email</h2> <p>Plunk will send order, subscriber, and administrator sign-in codes.</p></div> <div class="Box-body"><div class="notice svelte-1sk6wwy">Create a Plunk account, verify the domain you will send from, then create an API key. The sender email must use that verified domain.</div> <div class="form-group"><label for="plunk-key">Plunk API key</label> <input id="plunk-key" class="form-control" type="password" required="" autocomplete="off" placeholder="plunk_…"/></div> <div class="form-row svelte-1sk6wwy"><div class="form-group"><label for="from-email">Sender email</label> <input id="from-email" class="form-control" type="email" required="" autocomplete="email" placeholder="hello@yourdomain.com"/></div> <div class="form-group"><label for="from-name">Sender name <span class="optional svelte-1sk6wwy">optional</span></label><input id="from-name" class="form-control" autocomplete="organization"/></div></div> <div class="form-group"><label for="reply-to">Reply-to email <span class="optional svelte-1sk6wwy">optional</span></label><input id="reply-to" class="form-control" type="email" autocomplete="email"/></div> <div class="links svelte-1sk6wwy"><a href="https://app.useplunk.com" target="_blank" rel="noreferrer" class="svelte-1sk6wwy">Create or open your Plunk account ↗</a> <a href="https://docs.useplunk.com/guides/verifying-domains" target="_blank" rel="noreferrer" class="svelte-1sk6wwy">Verify your sending domain ↗</a> <a href="https://docs.useplunk.com/guides/api-keys" target="_blank" rel="noreferrer" class="svelte-1sk6wwy">Create a Plunk API key ↗</a></div></div></div>'), hs = _("<span></span>"), gs = _('<ol class="steps svelte-1sk6wwy" aria-label="Setup progress"></ol> <form autocomplete="off"><!> <div class="actions svelte-1sk6wwy"><!> <!></div></form>', 1), ks = _('<main class="setup-wrapper svelte-1sk6wwy"><div class="setup-container svelte-1sk6wwy"><div class="setup-header svelte-1sk6wwy"><svg class="setup-logo svelte-1sk6wwy" viewBox="0 0 90 90" width="48" height="48" fill="currentColor"><rect x="12" y="12" width="66" height="66" fill="currentColor"></rect></svg> <h1 class="svelte-1sk6wwy">Set up Hintergrund</h1> <p class="setup-subtitle svelte-1sk6wwy">A few short steps and your site is live.</p></div> <!> <!></div></main>');
|
|
6
|
+
const _s = {
|
|
12
7
|
hash: "svelte-1sk6wwy",
|
|
13
|
-
code: `.setup-wrapper.svelte-1sk6wwy {min-height:100vh;padding:var(--base-size-48) var(--base-size-24);background-color:var(--bgColor-muted);color:var(--fgColor-default);}.setup-container.svelte-1sk6wwy {width:100%;max-width:var(--base-size-600);margin:0 auto;}.setup-header.svelte-1sk6wwy {text-align:center;margin-bottom:var(--base-size-24);}.setup-logo.svelte-1sk6wwy {color:var(--fgColor-default);margin-bottom:var(--base-size-16);}.setup-header.svelte-1sk6wwy h1:where(.svelte-1sk6wwy) {margin:0;font-size:var(--text-title-size-medium);font-weight:var(--base-text-weight-light);color:var(--fgColor-default);}.setup-subtitle.svelte-1sk6wwy {margin:var(--base-size-4) 0 0;font-size:var(--text-body-size-medium);color:var(--fgColor-muted);}
|
|
14
|
-
|
|
15
|
-
/* Progress */.steps.svelte-1sk6wwy {display:grid;grid-template-columns:repeat(3, 1fr);gap:var(--base-size-8);margin:0 0 var(--base-size-16);padding:0;list-style:none;}.step-item.svelte-1sk6wwy {display:flex;align-items:center;justify-content:center;gap:var(--base-size-8);padding:var(--base-size-8) var(--base-size-12);background-color:var(--bgColor-default);border:var(--borderWidth-thin) solid var(--borderColor-default);border-radius:var(--borderRadius-medium);font-size:var(--text-body-size-small);color:var(--fgColor-muted);}.step-item.active.svelte-1sk6wwy {border-color:var(--borderColor-accent-emphasis);color:var(--fgColor-default);font-weight:var(--base-text-weight-medium);}.step-index.svelte-1sk6wwy {display:inline-flex;align-items:center;justify-content:center;width:var(--base-size-20);height:var(--base-size-20);flex-shrink:0;border-radius:50%;background-color:var(--bgColor-muted);font-size:var(--text-body-size-small);line-height:1;}.step-item.active.svelte-1sk6wwy .step-index:where(.svelte-1sk6wwy) {background-color:var(--button-primary-bgColor-rest);color:var(--button-primary-fgColor-rest);}.step-item.done.svelte-1sk6wwy .step-index:where(.svelte-1sk6wwy) {background-color:var(--bgColor-success-muted, #dafbe1);color:var(--fgColor-success, #1a7f37);}.step-label.svelte-1sk6wwy {white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}.form-row.svelte-1sk6wwy {display:grid;grid-template-columns:1fr 1fr;gap:var(--base-size-16);}.optional.svelte-1sk6wwy {font-weight:var(--base-text-weight-normal);color:var(--fgColor-muted);}.input-group.svelte-1sk6wwy {display:flex;}.input-group.svelte-1sk6wwy .form-control {border-top-right-radius:0;border-bottom-right-radius:0;}.input-group.svelte-1sk6wwy .input-group-btn {flex-shrink:0;margin-left:-1px;border-top-left-radius:0;border-bottom-left-radius:0;}.note.svelte-1sk6wwy {margin:var(--base-size-8) 0 0;font-size:var(--text-body-size-small);line-height:var(--text-body-lineHeight-small);color:var(--fgColor-muted);}.notice.svelte-1sk6wwy {padding:var(--base-size-12);margin-bottom:var(--base-size-16);background-color:var(--bgColor-accent-muted);border:var(--borderWidth-thin) solid var(--borderColor-accent-muted);border-radius:var(--borderRadius-medium);font-size:var(--text-body-size-small);line-height:var(--text-body-lineHeight-small);color:var(--fgColor-default);}
|
|
16
|
-
|
|
17
|
-
/* Choices */.choices.svelte-1sk6wwy {margin:0 0 var(--base-size-16);padding:0;border:0;}.choices.svelte-1sk6wwy legend:where(.svelte-1sk6wwy) {padding:0;margin-bottom:var(--base-size-8);font-weight:var(--base-text-weight-semibold);font-size:var(--text-body-size-medium);}.choice.svelte-1sk6wwy {display:flex;align-items:flex-start;gap:var(--base-size-8);padding:var(--base-size-12);border:var(--borderWidth-thin) solid var(--borderColor-default);border-radius:var(--borderRadius-medium);cursor:pointer;}.choice.svelte-1sk6wwy + .choice:where(.svelte-1sk6wwy) {margin-top:var(--base-size-8);}.choice.svelte-1sk6wwy:has(input:where(.svelte-1sk6wwy):checked) {border-color:var(--borderColor-accent-emphasis);background-color:var(--bgColor-accent-muted);}.choice.svelte-1sk6wwy input:where(.svelte-1sk6wwy) {margin:3px 0 0;flex-shrink:0;}.choice-text.svelte-1sk6wwy {display:block;font-size:var(--text-body-size-medium);}.choice-text.svelte-1sk6wwy strong:where(.svelte-1sk6wwy) {display:block;font-weight:var(--base-text-weight-semibold);}.choice-text.svelte-1sk6wwy small:where(.svelte-1sk6wwy) {display:block;margin-top:2px;font-size:var(--text-body-size-small);line-height:var(--text-body-lineHeight-small);color:var(--fgColor-muted);}.subsection.svelte-1sk6wwy {padding-top:var(--base-size-16);border-top:var(--borderWidth-thin) solid var(--borderColor-default);}.links.svelte-1sk6wwy {display:flex;flex-wrap:wrap;gap:var(--base-size-4) var(--base-size-16);margin-top:var(--base-size-16);font-size:var(--text-body-size-small);}.links.svelte-1sk6wwy a:where(.svelte-1sk6wwy) {color:var(--fgColor-accent);}
|
|
18
|
-
|
|
19
|
-
/* Actions */.actions.svelte-1sk6wwy {display:flex;align-items:center;justify-content:space-between;gap:var(--base-size-8);margin-top:var(--base-size-16);}
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
8
|
+
code: `.setup-wrapper.svelte-1sk6wwy {min-height:100vh;padding:var(--base-size-48) var(--base-size-24);background-color:var(--bgColor-muted);color:var(--fgColor-default);}.setup-container.svelte-1sk6wwy {width:100%;max-width:var(--base-size-600);margin:0 auto;}.setup-header.svelte-1sk6wwy {text-align:center;margin-bottom:var(--base-size-24);}.setup-logo.svelte-1sk6wwy {color:var(--fgColor-default);margin-bottom:var(--base-size-16);}.setup-header.svelte-1sk6wwy h1:where(.svelte-1sk6wwy) {margin:0;font-size:var(--text-title-size-medium);font-weight:var(--base-text-weight-light);color:var(--fgColor-default);}.setup-subtitle.svelte-1sk6wwy {margin:var(--base-size-4) 0 0;font-size:var(--text-body-size-medium);color:var(--fgColor-muted);}.steps.svelte-1sk6wwy {display:grid;grid-template-columns:repeat(3, 1fr);gap:var(--base-size-8);margin:0 0 var(--base-size-16);padding:0;list-style:none;}.step-item.svelte-1sk6wwy {display:flex;width:100%;align-items:center;justify-content:center;gap:var(--base-size-8);padding:var(--base-size-8) var(--base-size-12);background-color:var(--bgColor-default);border:var(--borderWidth-thin) solid var(--borderColor-default);border-radius:var(--borderRadius-medium);color:var(--fgColor-muted);cursor:pointer;font:inherit;font-size:var(--text-body-size-small);}.step-item.svelte-1sk6wwy:disabled {cursor:default;}.step-item.svelte-1sk6wwy:not(:disabled):hover {border-color:var(--borderColor-accent-emphasis);}.step-item.active.svelte-1sk6wwy {border-color:var(--borderColor-accent-emphasis);color:var(--fgColor-default);font-weight:var(--base-text-weight-medium);}.step-index.svelte-1sk6wwy {display:inline-flex;align-items:center;justify-content:center;width:var(--base-size-20);height:var(--base-size-20);flex-shrink:0;border-radius:50%;background-color:var(--bgColor-muted);font-size:var(--text-body-size-small);line-height:1;}.step-item.active.svelte-1sk6wwy .step-index:where(.svelte-1sk6wwy) {background-color:var(--button-primary-bgColor-rest);color:var(--button-primary-fgColor-rest);}.step-item.done.svelte-1sk6wwy .step-index:where(.svelte-1sk6wwy) {background-color:var(--bgColor-success-muted, #dafbe1);color:var(--fgColor-success, #1a7f37);}.step-label.svelte-1sk6wwy {white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}.form-row.svelte-1sk6wwy {display:grid;grid-template-columns:1fr 1fr;gap:var(--base-size-16);}.optional.svelte-1sk6wwy {font-weight:var(--base-text-weight-normal);color:var(--fgColor-muted);}.note.svelte-1sk6wwy {margin:var(--base-size-8) 0 0;font-size:var(--text-body-size-small);line-height:var(--text-body-lineHeight-small);color:var(--fgColor-muted);}.notice.svelte-1sk6wwy {padding:var(--base-size-12);margin-bottom:var(--base-size-16);background-color:var(--bgColor-accent-muted);border:var(--borderWidth-thin) solid var(--borderColor-accent-muted);border-radius:var(--borderRadius-medium);font-size:var(--text-body-size-small);line-height:var(--text-body-lineHeight-small);color:var(--fgColor-default);}.provider-choices.svelte-1sk6wwy {margin:0;padding:0;border:0;}.provider-choices.svelte-1sk6wwy legend:where(.svelte-1sk6wwy) {padding:0;margin-bottom:var(--base-size-8);font-weight:var(--base-text-weight-semibold);font-size:var(--text-body-size-medium);}.provider-choice.svelte-1sk6wwy {display:flex;align-items:flex-start;gap:var(--base-size-8);padding:var(--base-size-12);border:var(--borderWidth-thin) solid var(--borderColor-default);border-radius:var(--borderRadius-medium);cursor:pointer;}.provider-choice.svelte-1sk6wwy + .provider-choice:where(.svelte-1sk6wwy) {margin-top:var(--base-size-8);}.provider-choice.selected.svelte-1sk6wwy {border-color:var(--borderColor-accent-emphasis);background-color:var(--bgColor-accent-muted);}.provider-choice.svelte-1sk6wwy input:where(.svelte-1sk6wwy) {margin:3px 0 0;flex-shrink:0;}.provider-choice.svelte-1sk6wwy span:where(.svelte-1sk6wwy) {display:grid;gap:2px;}.provider-choice.svelte-1sk6wwy strong:where(.svelte-1sk6wwy) {font-weight:var(--base-text-weight-semibold);}.provider-choice.svelte-1sk6wwy small:where(.svelte-1sk6wwy) {color:var(--fgColor-muted);font-size:var(--text-body-size-small);line-height:var(--text-body-lineHeight-small);}.provider-choice.svelte-1sk6wwy small:where(.svelte-1sk6wwy) + small:where(.svelte-1sk6wwy) {margin-top:var(--base-size-4);}.input-group.svelte-1sk6wwy {display:flex;align-items:stretch;}.input-group.svelte-1sk6wwy .form-control {border-top-right-radius:0;border-bottom-right-radius:0;}.password-toggle.svelte-1sk6wwy {flex-shrink:0;margin-left:-1px;padding:var(--base-size-8) var(--base-size-16);border:var(--borderWidth-thin) solid var(--button-default-borderColor-rest, var(--borderColor-default));border-radius:0 var(--borderRadius-medium) var(--borderRadius-medium) 0;background:var(--button-default-bgColor-rest, var(--bgColor-muted));color:var(--button-default-fgColor-rest, var(--fgColor-default));font:inherit;cursor:pointer;}.password-toggle.svelte-1sk6wwy:hover {background:var(--button-default-bgColor-hover, var(--bgColor-muted));}.links.svelte-1sk6wwy {display:flex;flex-wrap:wrap;gap:var(--base-size-4) var(--base-size-16);margin-top:var(--base-size-16);font-size:var(--text-body-size-small);}.links.svelte-1sk6wwy a:where(.svelte-1sk6wwy) {color:var(--fgColor-accent);}.actions.svelte-1sk6wwy {display:flex;align-items:center;justify-content:space-between;gap:var(--base-size-8);margin-top:var(--base-size-16);}.selection-actions.svelte-1sk6wwy {margin-top:var(--base-size-16);}
|
|
27
9
|
@media (max-width: 560px) {.setup-wrapper.svelte-1sk6wwy {padding:var(--base-size-24) var(--base-size-16);}.form-row.svelte-1sk6wwy {grid-template-columns:1fr;gap:0;}.step-label.svelte-1sk6wwy {display:none;}.steps.svelte-1sk6wwy {grid-template-columns:repeat(3, 1fr);}
|
|
28
10
|
}`
|
|
29
11
|
};
|
|
30
|
-
function
|
|
31
|
-
|
|
32
|
-
const
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
12
|
+
function xs(X, Ke) {
|
|
13
|
+
as(Ke, !0), ts(X, _s);
|
|
14
|
+
const Ee = [];
|
|
15
|
+
let y = v(1);
|
|
16
|
+
const we = new URLSearchParams(window.location.search).get("token") ?? "";
|
|
17
|
+
let A = v(!0), q = v(!0), Te = v(!1), h = v(null), D = v("");
|
|
18
|
+
const Ue = ue(() => e(q) ? "otp" : "password"), me = 12;
|
|
19
|
+
let ee = v(""), se = v(!1), ae = v(""), te = v(""), fe = v(""), be = v(""), ye = v(""), re = v(""), he = v(""), oe = v(""), le = v(""), ge = v(""), ke = v(""), E = v(""), O = v(!1);
|
|
20
|
+
rs(() => {
|
|
21
|
+
we && fetch(`/api/admin/setup?token=${encodeURIComponent(we)}`).then(async (l) => l.ok ? await l.json() : null).then((l) => {
|
|
22
|
+
l?.suggestedEmail && !e(D) && o(D, l.suggestedEmail, !0);
|
|
23
|
+
}).catch(() => {
|
|
24
|
+
});
|
|
25
|
+
});
|
|
26
|
+
const ie = ue(() => [
|
|
27
|
+
"Admin",
|
|
28
|
+
...e(A) ? ["Payment details"] : [],
|
|
29
|
+
...e(q) ? ["Email"] : []
|
|
30
|
+
]), ne = ue(() => e(ie)[e(y) - 1]), Fe = ue(() => e(y) >= e(ie).length);
|
|
31
|
+
function Oe() {
|
|
32
|
+
o(E, ""), e(A) || o(h, null), o(Te, !0), window.scrollTo({ top: 0, behavior: "smooth" });
|
|
36
33
|
}
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
34
|
+
function Ne(l) {
|
|
35
|
+
if (l === "Admin") {
|
|
36
|
+
if (!e(D).trim()) return "An email address is required.";
|
|
37
|
+
if (e(ee).length < me)
|
|
38
|
+
return `Choose a password of at least ${me} characters.`;
|
|
39
|
+
}
|
|
40
|
+
if (l === "Payment details") {
|
|
41
|
+
if (!e(h)) return "Choose how you want to accept payments.";
|
|
42
|
+
if (e(h) === "bank_transfer" && (!e(ae).trim() || !e(te).trim()))
|
|
43
|
+
return "An account holder and IBAN are required for bank transfers.";
|
|
44
|
+
if (e(h) === "stripe" && !e(re).trim())
|
|
45
|
+
return "Your Stripe secret key is required for card payments.";
|
|
46
|
+
}
|
|
47
|
+
return l === "Email" && (!e(oe).trim() || !e(le).trim()) ? "An email provider API key and sender address are required." : null;
|
|
48
|
+
}
|
|
49
|
+
function Ye() {
|
|
50
|
+
const l = Ne(e(ne));
|
|
51
|
+
if (l) {
|
|
52
|
+
o(E, l, !0);
|
|
43
53
|
return;
|
|
44
54
|
}
|
|
45
|
-
|
|
55
|
+
o(E, ""), o(y, e(y) + 1), window.scrollTo({ top: 0, behavior: "smooth" });
|
|
56
|
+
}
|
|
57
|
+
function Ve() {
|
|
58
|
+
qe(e(y) - 1);
|
|
46
59
|
}
|
|
47
|
-
function
|
|
48
|
-
l(
|
|
60
|
+
function qe(l) {
|
|
61
|
+
l < 1 || l > e(y) || (o(E, ""), o(y, l, !0), window.scrollTo({ top: 0, behavior: "smooth" }));
|
|
49
62
|
}
|
|
50
|
-
async function
|
|
51
|
-
|
|
63
|
+
async function Ze(l) {
|
|
64
|
+
l.preventDefault();
|
|
65
|
+
for (const p of e(ie)) {
|
|
66
|
+
const g = Ne(p);
|
|
67
|
+
if (g) {
|
|
68
|
+
o(E, g, !0);
|
|
69
|
+
return;
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
o(O, !0), o(E, "");
|
|
52
73
|
try {
|
|
53
|
-
const
|
|
74
|
+
const p = await fetch("/api/admin/setup", {
|
|
54
75
|
method: "POST",
|
|
55
76
|
headers: { "Content-Type": "application/json" },
|
|
56
77
|
body: JSON.stringify({
|
|
57
|
-
setupToken:
|
|
58
|
-
email: e(
|
|
59
|
-
password: e(
|
|
60
|
-
|
|
78
|
+
setupToken: we,
|
|
79
|
+
email: e(D),
|
|
80
|
+
password: e(ee),
|
|
81
|
+
modules: { shop: e(A), emails: e(q) },
|
|
82
|
+
paymentProvider: e(h),
|
|
61
83
|
bankTransfer: {
|
|
62
|
-
accountHolder: e(
|
|
63
|
-
iban: e(
|
|
64
|
-
bic: e(
|
|
65
|
-
bankName: e(
|
|
66
|
-
instructions: e(
|
|
84
|
+
accountHolder: e(ae),
|
|
85
|
+
iban: e(te),
|
|
86
|
+
bic: e(fe),
|
|
87
|
+
bankName: e(be),
|
|
88
|
+
instructions: e(ye)
|
|
67
89
|
},
|
|
68
|
-
stripeSecretKey: e(
|
|
69
|
-
stripeWebhookSecret: e(
|
|
70
|
-
plunkApiKey: e(
|
|
71
|
-
fromEmail: e(
|
|
72
|
-
fromName: e(
|
|
73
|
-
replyTo: e(
|
|
90
|
+
stripeSecretKey: e(re),
|
|
91
|
+
stripeWebhookSecret: e(he),
|
|
92
|
+
plunkApiKey: e(oe),
|
|
93
|
+
fromEmail: e(le),
|
|
94
|
+
fromName: e(ge),
|
|
95
|
+
replyTo: e(ke)
|
|
74
96
|
})
|
|
75
|
-
}),
|
|
76
|
-
if (!
|
|
97
|
+
}), g = await p.json();
|
|
98
|
+
if (!p.ok) throw new Error(g.error || "Setup failed");
|
|
77
99
|
window.location.href = "/admin";
|
|
78
|
-
} catch (
|
|
79
|
-
|
|
100
|
+
} catch (p) {
|
|
101
|
+
o(E, p instanceof Error ? p.message : "Setup failed", !0), o(O, !1);
|
|
80
102
|
}
|
|
81
103
|
}
|
|
82
|
-
var
|
|
83
|
-
Ke(G, 22, () => le, (a) => a, (a, o, n) => {
|
|
84
|
-
var i = Ze();
|
|
85
|
-
let b;
|
|
86
|
-
var c = r(i), y = r(c, !0);
|
|
87
|
-
t(c);
|
|
88
|
-
var p = s(c, 2), _ = r(p, !0);
|
|
89
|
-
t(p), t(i), T(() => {
|
|
90
|
-
b = Fe(i, 1, "step-item svelte-1sk6wwy", null, b, {
|
|
91
|
-
active: e(u) === e(n) + 1,
|
|
92
|
-
done: e(u) > e(n) + 1
|
|
93
|
-
}), be(i, "aria-current", e(u) === e(n) + 1 ? "step" : void 0), $(y, e(u) > e(n) + 1 ? "✓" : e(n) + 1), $(_, o);
|
|
94
|
-
}), f(a, i);
|
|
95
|
-
}), t(G);
|
|
96
|
-
var ne = s(G, 2);
|
|
104
|
+
var _e = ks(), Ie = t(_e), Le = s(t(Ie), 2);
|
|
97
105
|
{
|
|
98
|
-
var
|
|
99
|
-
var
|
|
100
|
-
|
|
106
|
+
var Ge = (l) => {
|
|
107
|
+
var p = ds(), g = s(t(p));
|
|
108
|
+
a(p), U(() => J(g, ` ${e(E) ?? ""}`)), c(l, p);
|
|
101
109
|
};
|
|
102
|
-
|
|
103
|
-
e(
|
|
110
|
+
I(Le, (l) => {
|
|
111
|
+
e(E) && l(Ge);
|
|
104
112
|
});
|
|
105
113
|
}
|
|
106
|
-
var
|
|
114
|
+
var Je = s(Le, 2);
|
|
107
115
|
{
|
|
108
|
-
var
|
|
109
|
-
var
|
|
110
|
-
|
|
111
|
-
var
|
|
112
|
-
|
|
113
|
-
var
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
k();
|
|
119
|
-
var x = W();
|
|
120
|
-
T(() => $(x, e(L) ? "Hide" : "Show")), f(h, x);
|
|
121
|
-
},
|
|
122
|
-
$$slots: { default: !0 }
|
|
123
|
-
}), t(y), k(2), t(c), t(n), t(o), T(() => be(p, "type", e(L) ? "text" : "password")), m(b, () => e(N), (h) => l(N, h)), m(p, () => e(H), (h) => l(H, h)), f(a, o);
|
|
124
|
-
}, Se = (a) => {
|
|
125
|
-
var o = Je(), n = s(r(o), 2), i = s(r(n), 2), b = s(r(i), 2);
|
|
126
|
-
w(b), t(i);
|
|
127
|
-
var c = s(i, 2), y = s(r(c), 2);
|
|
128
|
-
w(y), t(c);
|
|
129
|
-
var p = s(c, 2), _ = r(p), h = s(r(_), 2);
|
|
130
|
-
w(h), t(_);
|
|
131
|
-
var S = s(_, 2), x = s(r(S), 2);
|
|
132
|
-
w(x), t(S), t(p);
|
|
133
|
-
var g = s(p, 2), pe = s(r(g), 2);
|
|
134
|
-
Ue(pe), t(g);
|
|
135
|
-
var ee = s(g, 2), se = s(r(ee), 2), j = r(se);
|
|
136
|
-
w(j), j.value = j.__value = "bank_transfer", k(2), t(se);
|
|
137
|
-
var we = s(se, 2), I = r(we);
|
|
138
|
-
w(I), I.value = I.__value = "stripe", k(2), t(we), t(ee);
|
|
139
|
-
var He = s(ee, 2);
|
|
116
|
+
var Qe = (l) => {
|
|
117
|
+
var p = ps(), g = s(t(p), 2), L = t(g), H = s(t(L), 2);
|
|
118
|
+
let de;
|
|
119
|
+
var Y = t(H);
|
|
120
|
+
f(Y), B(2), a(H);
|
|
121
|
+
var V = s(H, 2);
|
|
122
|
+
let Z;
|
|
123
|
+
var R = t(V);
|
|
124
|
+
f(R);
|
|
125
|
+
var ve = s(R, 2), xe = s(t(ve), 4);
|
|
140
126
|
{
|
|
141
|
-
var
|
|
142
|
-
var
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
127
|
+
var ze = (r) => {
|
|
128
|
+
var n = vs();
|
|
129
|
+
c(r, n);
|
|
130
|
+
}, Ce = (r) => {
|
|
131
|
+
var n = cs();
|
|
132
|
+
c(r, n);
|
|
146
133
|
};
|
|
147
|
-
|
|
148
|
-
e(
|
|
134
|
+
I(xe, (r) => {
|
|
135
|
+
e(A) ? r(ze) : e(q) && r(Ce, 1);
|
|
149
136
|
});
|
|
150
137
|
}
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
w(b), t(i);
|
|
155
|
-
var c = s(i, 2), y = r(c), p = s(r(y), 2);
|
|
156
|
-
w(p), t(y);
|
|
157
|
-
var _ = s(y, 2), h = s(r(_), 2);
|
|
158
|
-
w(h), t(_), t(c);
|
|
159
|
-
var S = s(c, 2), x = s(r(S), 2);
|
|
160
|
-
w(x), t(S), k(2), t(n), t(o), m(b, () => e(M), (g) => l(M, g)), m(p, () => e(V), (g) => l(V, g)), m(h, () => e(J), (g) => l(J, g)), m(x, () => e(O), (g) => l(O, g)), f(a, o);
|
|
161
|
-
};
|
|
162
|
-
A(de, (a) => {
|
|
163
|
-
e(u) === 1 ? a(Pe) : e(u) === 2 ? a(Se, 1) : a(Be, -1);
|
|
164
|
-
});
|
|
165
|
-
}
|
|
166
|
-
var ve = s(de, 2), ce = r(ve);
|
|
167
|
-
{
|
|
168
|
-
var Ae = (a) => {
|
|
169
|
-
R(a, {
|
|
170
|
-
onclick: xe,
|
|
171
|
-
get disabled() {
|
|
172
|
-
return e(B);
|
|
173
|
-
},
|
|
174
|
-
children: (o, n) => {
|
|
175
|
-
k();
|
|
176
|
-
var i = W("Back");
|
|
177
|
-
f(o, i);
|
|
178
|
-
},
|
|
179
|
-
$$slots: { default: !0 }
|
|
180
|
-
});
|
|
181
|
-
}, Te = (a) => {
|
|
182
|
-
var o = Qe();
|
|
183
|
-
f(a, o);
|
|
184
|
-
};
|
|
185
|
-
A(ce, (a) => {
|
|
186
|
-
e(u) > 1 ? a(Ae) : a(Te, -1);
|
|
187
|
-
});
|
|
188
|
-
}
|
|
189
|
-
var $e = s(ce, 2);
|
|
190
|
-
{
|
|
191
|
-
var Ee = (a) => {
|
|
192
|
-
R(a, {
|
|
138
|
+
a(ve), a(V), a(L);
|
|
139
|
+
var ce = s(L, 4), i = s(t(ce), 2);
|
|
140
|
+
pe(i, {
|
|
193
141
|
variant: "primary",
|
|
194
|
-
onclick:
|
|
195
|
-
children: (
|
|
196
|
-
|
|
197
|
-
var
|
|
198
|
-
|
|
142
|
+
onclick: Oe,
|
|
143
|
+
children: (r, n) => {
|
|
144
|
+
B();
|
|
145
|
+
var d = F("Continue");
|
|
146
|
+
c(r, d);
|
|
199
147
|
},
|
|
200
148
|
$$slots: { default: !0 }
|
|
201
|
-
})
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
149
|
+
}), a(ce), a(g), a(p), U(() => {
|
|
150
|
+
de = Q(H, 1, "provider-choice svelte-1sk6wwy", null, de, { selected: e(A) }), Z = Q(V, 1, "provider-choice svelte-1sk6wwy", null, Z, { selected: e(q) }), R.disabled = e(A);
|
|
151
|
+
}), Pe("change", Y, () => {
|
|
152
|
+
e(A) && o(q, !0);
|
|
153
|
+
}), $e(Y, () => e(A), (r) => o(A, r)), $e(R, () => e(q), (r) => o(q, r)), c(l, p);
|
|
154
|
+
}, Xe = (l) => {
|
|
155
|
+
var p = gs(), g = Be(p);
|
|
156
|
+
ls(g, 22, () => e(ie), (i) => i, (i, r, n) => {
|
|
157
|
+
var d = us(), w = t(d);
|
|
158
|
+
let x;
|
|
159
|
+
var m = t(w), b = t(m, !0);
|
|
160
|
+
a(m);
|
|
161
|
+
var z = s(m, 2), S = t(z, !0);
|
|
162
|
+
a(z), a(w), a(d), U(() => {
|
|
163
|
+
x = Q(w, 1, "step-item svelte-1sk6wwy", null, x, {
|
|
164
|
+
active: e(y) === e(n) + 1,
|
|
165
|
+
done: e(y) > e(n) + 1
|
|
166
|
+
}), Ae(w, "aria-current", e(y) === e(n) + 1 ? "step" : void 0), w.disabled = e(n) + 1 > e(y), J(b, e(y) > e(n) + 1 ? "✓" : e(n) + 1), J(S, r);
|
|
167
|
+
}), Pe("click", w, () => qe(e(n) + 1)), c(i, d);
|
|
168
|
+
}), a(g);
|
|
169
|
+
var L = s(g, 2), H = t(L);
|
|
170
|
+
{
|
|
171
|
+
var de = (i) => {
|
|
172
|
+
var r = ws(), n = s(t(r), 2), d = t(n), w = s(t(d), 2);
|
|
173
|
+
f(w), B(2), a(d);
|
|
174
|
+
var x = s(d, 2), m = s(t(x), 2), b = t(m);
|
|
175
|
+
f(b), Ae(b, "minlength", me);
|
|
176
|
+
var z = s(b, 2), S = t(z, !0);
|
|
177
|
+
a(z), a(m);
|
|
178
|
+
var W = s(m, 2), j = t(W);
|
|
179
|
+
j.nodeValue = "At least 12 characters. Save it in your password manager: ";
|
|
180
|
+
var P = s(j);
|
|
181
|
+
{
|
|
182
|
+
var C = (u) => {
|
|
183
|
+
var T = F(`you normally sign in with a code sent to your email, and this password is how
|
|
184
|
+
you get back in if email delivery ever fails.`);
|
|
185
|
+
c(u, T);
|
|
186
|
+
}, M = (u) => {
|
|
187
|
+
var T = F("this is how you sign in.");
|
|
188
|
+
c(u, T);
|
|
189
|
+
};
|
|
190
|
+
I(P, (u) => {
|
|
191
|
+
e(Ue) === "otp" ? u(C) : u(M, -1);
|
|
192
|
+
});
|
|
193
|
+
}
|
|
194
|
+
a(W), a(x), a(n), a(r), U(() => {
|
|
195
|
+
Ae(b, "type", e(se) ? "text" : "password"), J(S, e(se) ? "Hide" : "Show");
|
|
196
|
+
}), k(w, () => e(D), (u) => o(D, u)), k(b, () => e(ee), (u) => o(ee, u)), Pe("click", z, () => o(se, !e(se))), c(i, r);
|
|
197
|
+
}, Y = (i) => {
|
|
198
|
+
var r = bs(), n = s(t(r), 2), d = t(n), w = s(t(d), 2);
|
|
199
|
+
let x;
|
|
200
|
+
var m = t(w);
|
|
201
|
+
f(m), m.value = m.__value = "bank_transfer", B(2), a(w);
|
|
202
|
+
var b = s(w, 2);
|
|
203
|
+
let z;
|
|
204
|
+
var S = t(b);
|
|
205
|
+
f(S), S.value = S.__value = "stripe", B(2), a(b), a(d);
|
|
206
|
+
var W = s(d, 4);
|
|
207
|
+
{
|
|
208
|
+
var j = (C) => {
|
|
209
|
+
var M = ms(), u = Be(M), T = s(t(u), 2);
|
|
210
|
+
f(T), a(u);
|
|
211
|
+
var K = s(u, 2), G = s(t(K), 2);
|
|
212
|
+
f(G), a(K);
|
|
213
|
+
var $ = s(K, 2), Se = t($), He = s(t(Se));
|
|
214
|
+
f(He), a(Se);
|
|
215
|
+
var Re = s(Se, 2), We = s(t(Re));
|
|
216
|
+
f(We), a(Re), a($);
|
|
217
|
+
var je = s($, 2), Me = s(t(je), 2);
|
|
218
|
+
ns(Me), a(je), k(T, () => e(ae), (N) => o(ae, N)), k(G, () => e(te), (N) => o(te, N)), k(He, () => e(fe), (N) => o(fe, N)), k(We, () => e(be), (N) => o(be, N)), k(Me, () => e(ye), (N) => o(ye, N)), c(C, M);
|
|
219
|
+
}, P = (C) => {
|
|
220
|
+
var M = fs(), u = Be(M), T = s(t(u), 2);
|
|
221
|
+
f(T), a(u);
|
|
222
|
+
var K = s(u, 2), G = s(t(K), 2);
|
|
223
|
+
f(G), B(2), a(K), B(2), k(T, () => e(re), ($) => o(re, $)), k(G, () => e(he), ($) => o(he, $)), c(C, M);
|
|
224
|
+
};
|
|
225
|
+
I(W, (C) => {
|
|
226
|
+
e(h) === "bank_transfer" ? C(j) : e(h) === "stripe" && C(P, 1);
|
|
227
|
+
});
|
|
228
|
+
}
|
|
229
|
+
a(n), a(r), U(() => {
|
|
230
|
+
x = Q(w, 1, "provider-choice svelte-1sk6wwy", null, x, { selected: e(h) === "bank_transfer" }), z = Q(b, 1, "provider-choice svelte-1sk6wwy", null, z, { selected: e(h) === "stripe" });
|
|
231
|
+
}), De(Ee, [], m, () => e(h), (C) => o(h, C)), De(Ee, [], S, () => e(h), (C) => o(h, C)), c(i, r);
|
|
232
|
+
}, V = (i) => {
|
|
233
|
+
var r = ys(), n = s(t(r), 2), d = s(t(n), 2), w = s(t(d), 2);
|
|
234
|
+
f(w), a(d);
|
|
235
|
+
var x = s(d, 2), m = t(x), b = s(t(m), 2);
|
|
236
|
+
f(b), a(m);
|
|
237
|
+
var z = s(m, 2), S = s(t(z));
|
|
238
|
+
f(S), a(z), a(x);
|
|
239
|
+
var W = s(x, 2), j = s(t(W));
|
|
240
|
+
f(j), a(W), B(2), a(n), a(r), k(w, () => e(oe), (P) => o(oe, P)), k(b, () => e(le), (P) => o(le, P)), k(S, () => e(ge), (P) => o(ge, P)), k(j, () => e(ke), (P) => o(ke, P)), c(i, r);
|
|
241
|
+
};
|
|
242
|
+
I(H, (i) => {
|
|
243
|
+
e(ne) === "Admin" ? i(de) : e(ne) === "Payment details" ? i(Y, 1) : e(ne) === "Email" && i(V, 2);
|
|
244
|
+
});
|
|
245
|
+
}
|
|
246
|
+
var Z = s(H, 2), R = t(Z);
|
|
247
|
+
{
|
|
248
|
+
var ve = (i) => {
|
|
249
|
+
pe(i, {
|
|
250
|
+
onclick: Ve,
|
|
251
|
+
get disabled() {
|
|
252
|
+
return e(O);
|
|
253
|
+
},
|
|
254
|
+
children: (r, n) => {
|
|
255
|
+
B();
|
|
256
|
+
var d = F("Back");
|
|
257
|
+
c(r, d);
|
|
258
|
+
},
|
|
259
|
+
$$slots: { default: !0 }
|
|
260
|
+
});
|
|
261
|
+
}, xe = (i) => {
|
|
262
|
+
var r = hs();
|
|
263
|
+
c(i, r);
|
|
264
|
+
};
|
|
265
|
+
I(R, (i) => {
|
|
266
|
+
e(y) > 1 ? i(ve) : i(xe, -1);
|
|
267
|
+
});
|
|
268
|
+
}
|
|
269
|
+
var ze = s(R, 2);
|
|
270
|
+
{
|
|
271
|
+
var Ce = (i) => {
|
|
272
|
+
pe(i, {
|
|
273
|
+
variant: "primary",
|
|
274
|
+
onclick: Ye,
|
|
275
|
+
children: (r, n) => {
|
|
276
|
+
B();
|
|
277
|
+
var d = F("Continue");
|
|
278
|
+
c(r, d);
|
|
279
|
+
},
|
|
280
|
+
$$slots: { default: !0 }
|
|
281
|
+
});
|
|
282
|
+
}, ce = (i) => {
|
|
283
|
+
pe(i, {
|
|
284
|
+
variant: "primary",
|
|
285
|
+
type: "submit",
|
|
286
|
+
get disabled() {
|
|
287
|
+
return e(O);
|
|
288
|
+
},
|
|
289
|
+
children: (r, n) => {
|
|
290
|
+
B();
|
|
291
|
+
var d = F();
|
|
292
|
+
U(() => J(d, e(O) ? "Finishing setup…" : "Finish setup")), c(r, d);
|
|
293
|
+
},
|
|
294
|
+
$$slots: { default: !0 }
|
|
295
|
+
});
|
|
296
|
+
};
|
|
297
|
+
I(ze, (i) => {
|
|
298
|
+
e(Fe) ? i(ce, -1) : i(Ce);
|
|
299
|
+
});
|
|
300
|
+
}
|
|
301
|
+
a(Z), a(L), is("submit", L, Ze), c(l, p);
|
|
216
302
|
};
|
|
217
|
-
|
|
218
|
-
e(
|
|
303
|
+
I(Je, (l) => {
|
|
304
|
+
e(Te) ? l(Xe, -1) : l(Qe);
|
|
219
305
|
});
|
|
220
306
|
}
|
|
221
|
-
|
|
307
|
+
a(Ie), a(_e), c(X, _e), os();
|
|
222
308
|
}
|
|
223
|
-
|
|
309
|
+
es(["change", "click"]);
|
|
310
|
+
customElements.define("hintergrund-setup", ss(xs, {}, [], []));
|
|
224
311
|
export {
|
|
225
|
-
|
|
312
|
+
xs as default
|
|
226
313
|
};
|