PageSourceSearch

https://cdn.vialibri.net/static/assets/EditSubscription-DhrdI0fF.js

js vialibri.net collected 2026-09-24 09:37:40 UTC 5,765 bytes, 2 lines download raw bytes

1!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},s=(new e.Error).stack;s&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[s]="cc7fd1e5-63f9-4058-b2e0-d67ff9180be6",e._sentryDebugIdIdentifier="sentry-dbid-cc7fd1e5-63f9-4058-b2e0-d67ff9180be6")}catch(e){}}();import"./_sentry-release-injection-file-SYOkQ1Km.js";import{a as e}from"./rolldown-runtime-BBzOAo5_.js";import{t as s}from"./react-DuV36FPs.js";import{s as t}from"./_baseUnset-D3G1PSyW.js";import{t as n}from"./_baseIteratee-eVLGECgX.js";import{n as o}from"./_baseEach-tH7yOdeo.js";import{t as r}from"./formatClasses-DEp3Ml96.js";import{K as a,R as i,at as l,h as c,r as u,ut as m}from"./index-CRc22cjs.js";import{c as d,l as b,t as j}from"./FinalControlGroup-Cmc21xKd.js";import{t as x}from"./commonValidators-Bv9l42OX.js";import{t as h}from"./FormField-DM_MQnEG.js";import{t as f}from"./Submit-CHUFd811.js";import{t as p}from"./CountrySelect-bQR_zE9k.js";import{t as y}from"./FinalSelect-mq7-Evlf.js";import{t as g}from"./TermsOfServiceCheckbox-JvgKfHCS.js";import{t as v}from"./serversideValidators-Kq9vCrTh.js";var k=l(),_=(s(),a()),T=()=>{const{input:{onChange:e,value:s}}=b("term");return(0,_.jsxs)("div",{className:"subscription__buttons",children:[(0,_.jsx)("button",{type:"button",onClick:()=>e("quarterly"),className:"quarterly"===s?"selected":void 0,children:(0,_.jsx)(k.T,{message:"Quarterly"})}),(0,_.jsx)("button",{type:"button",onClick:()=>e("annual"),className:"annual"===s?"selected":void 0,children:(0,_.jsx)(k.T,{message:"Annual (2 Months Free)"})})]})},w=(0,k.withTranslators)((({levels:e,isLinkedAccount:s,t:t})=>{const{input:{onChange:n,value:o}}=b("level");return(0,_.jsx)("div",{className:"subscription__pricing",children:Object.values(e).map(((a,i)=>{const l=Object.keys(e)[i];return(0,_.jsxs)("div",{className:r("subscription__item",{selected:o===l}),children:[(0,_.jsxs)("div",{className:"subscription__header",children:[(0,_.jsx)("h2",{children:a.name}),(0,_.jsxs)("div",{className:"subscription__price",children:[(0,_.jsx)("span",{children:a.price.formatted}),"/mo"]}),s&&(0,_.jsx)("div",{className:"subscription__note",children:(0,_.jsx)(k.T,{message:"(Includes discount for linked account)"})}),(0,_.jsx)("button",{type:"button",className:"button",onClick:()=>n(l),disabled:o===l,children:t(o===l?"Selected":"Choose plan")})]}),(0,_.jsx)("ul",{children:a.benefits.map(((e,s)=>(0,_.jsx)("li",{children:e},s)))})]},a.name)}))})})),C=(0,k.withTranslators)((({formValues:e,formOptions:s,isLinkedAccount:a,t:l})=>{const b=u();return(0,_.jsxs)(_.Fragment,{children:[a&&(0,_.jsx)("div",{className:"box box--errors",children:(0,_.jsx)(k.T,{message:"Your account is linked to that of another user. This means that you receive a discount on your subscription, but it also limits your subscription options. If you would like to sign up at a different subscription level then please {{ contactLink:contact us }}.",contactLink:(0,_.jsx)("a",{href:"/contact-us"})})}),(0,_.jsx)(d,{onSubmit:c("/account/subscription/edit",b),initialValues:e,render:e=>{const c=s.subscriptionLevels[e.values.level],u=c.books>0,d=u?m(c.extras_options,(e=>e.books_allowed>=s.currentBookCount)):c.extras_options,b=(C=d,N={},L=n(L=e=>e.name,3),o(C,(function(e,s,n){t(N,s,L(e,s,n))})),N);var C,L,N;const I=parseInt(Object.keys(d)[0],10);return e.values.extras<I&&e.form.change("extras",I),(0,_.jsx)("div",{className:r("box",{errors:!Object.keys(d).length}),children:Object.keys(d).length?(0,_.jsxs)("form",{onSubmit:e.handleSubmit,className:"subscription",children:[(0,_.jsx)(T,{}),(0,_.jsx)(w,{levels:s.subscriptionLevels,isLinkedAccount:a}),(0,_.jsx)(j,{name:"extras",label:u?(0,_.jsx)(k.T,{message:"Extras:"}):(0,_.jsx)(k.T,{message:"Extra wants:"}),notes:(0,_.jsx)(_.Fragment,{children:u&&s.currentBookCount>0?(0,_.jsx)(k.T,{message:"You currently have {{ total }} books listed.",total:i(s.currentBookCount)}):null}),children:(0,_.jsx)(y,{name:"extras",options:b})}),(0,_.jsx)(j,{name:"term",label:(0,_.jsx)(k.T,{message:"Billing period:"}),children:(0,_.jsx)(y,{name:"term",options:s.billingPeriods})}),(0,_.jsx)(j,{name:"country",label:(0,_.jsx)(k.T,{message:"Country:"}),children:(0,_.jsx)(p,{name:"country",single:!0,options:s.countries,alternativeCountries:s.alternativeCountries})}),u&&(0,_.jsxs)(_.Fragment,{children:[(0,_.jsx)(h,{name:"business_name",label:(0,_.jsx)(k.T,{message:"Business name:"}),required:!0,notes:l("This will appear next to search results for your books.")}
1),(0,_.jsx)(h,{name:"harvest_home_url",label:(0,_.jsx)(k.T,{message:"Website URL:"}),required:!0,validate:[x.url()],notes:(0,_.jsx)(k.T,{message:"Please give the complete URL address of your website. Note that Harvest is only suitable for single-dealer websites. If you run a multi-dealer website or auction house then please {{ contactLink: contact us }} for details of how to add your items.",contactLink:(0,_.jsx)("a",{href:"/contact-us"})})})]}),s.europeanCountries.includes(e.values.country)&&"GB"!==e.values.country?(0,_.jsx)(h,{name:"vat_id",label:(0,_.jsx)(k.T,{message:"VAT ID:"}),validate:[v],notes:(0,_.jsx)(k.T,{message:"Please provide this if you are registered for VAT within the EU."})}):null,s.showReferralField?(0,_.jsx)(h,{name:"referred_by",label:(0,_.jsx)(k.T,{message:"Referred by:"})}):null,(0,_.jsx)(g,{}),(0,_.jsx)(f,{label:l("Subscribe")})]}):(0,_.jsx)(k.T,{message:"Due to the large number of books listed on your website this transaction cannot be processed in the normal way. Please {{ contactLink:get in touch with us }} to proceed.",contactLink:(0,_.jsx)("a",{href:"/contact-us"})})})}})]})}));export{C as default};
2//# sourceMappingURL=EditSubscription-DhrdI0fF.js.map

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.