@svgrid/enterprise 3.1.6 → 3.1.7

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.
@@ -1,8 +1,8 @@
1
1
  const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./jszip.min-CX2fPs3O.js","./rolldown-runtime-Dd_uD5pT.js","./pdfmake-BpIYFHoG.js","./vfs_fonts-BV-Ul9v2.js","./src-CITpcm6b.js","./chart-export-B6bkQ3X8.js"])))=>i.map(i=>d[i]);
2
2
  import{i as e,n as t}from"./rolldown-runtime-Dd_uD5pT.js";import{a as n,c as r,d as i,i as a,l as o,n as s,o as c,s as l,t as u,u as d}from"./export-format-DGscOjS9.js";import{t as f}from"./preload-helper-HclGiUj8.js";var p={arrows:[`↓`,`→`,`↑`],traffic:[`🔴`,`🟡`,`🟢`],triangles:[`▼`,`◆`,`▲`]};function m(e){let t=1/0,n=-1/0,r=!1;for(let i of e){if(i==null||i===``)continue;let e=Number(i);Number.isFinite(e)&&(r=!0,e<t&&(t=e),e>n&&(n=e))}return r?{min:t,max:n}:null}function h(e,t,n){let r=0;for(let e=0;e<t.length;e+=1)n>=t[e]&&(r=e+1);return e[Math.min(e.length-1,Math.max(0,r))]??e[e.length-1]}function g(e){return e<0?0:e>1?1:e}function _(e){let t=/^#?([0-9a-f]{6})$/i.exec(e.trim());if(!t)return null;let n=parseInt(t[1],16);return[n>>16&255,n>>8&255,n&255]}function v(e){return`#`+e.map(e=>Math.round(g(e/255)*255).toString(16).padStart(2,`0`)).join(``)}function y(e){let t=_(e);if(!t)return null;let n=t.map(e=>{let t=e/255;return t<=.03928?t/12.92:((t+.055)/1.055)**2.4});return .2126*n[0]+.7152*n[1]+.0722*n[2]>.45?`#1e293b`:`#ffffff`}function b(e,t,n){let r=_(e),i=_(t);if(!r||!i)return e;let a=g(n);return v([r[0]+(i[0]-r[0])*a,r[1]+(i[1]-r[1])*a,r[2]+(i[2]-r[2])*a])}function x(e,t){let n=_(e);return n?`rgba(${n[0]}, ${n[1]}, ${n[2]}, ${g(t).toFixed(3)})`:e}function ee(e,t){let n=[...e].sort((e,t)=>e.offset-t.offset);if(n.length===0)return`#000000`;if(t<=n[0].offset)return n[0].color;let r=n[n.length-1];if(t>=r.offset)return r.color;for(let e=0;e<n.length-1;e+=1){let r=n[e],i=n[e+1];if(t>=r.offset&&t<=i.offset){let e=i.offset-r.offset||1;return b(r.color,i.color,(t-r.offset)/e)}}return r.color}function te(e,t){if(e.stops&&e.stops.length>=2)return ee(e.stops,t);let n=e.min??`#ffffff`,r=e.max??`#000000`;return e.mid?t<=.5?b(n,e.mid,t/.5):b(e.mid,r,(t-.5)/.5):b(n,r,t)}function S(e,t,n,r){let i;if(e.compareColumn){let r=Number(n?.[e.compareColumn]);if(!Number.isFinite(r)||r===0)return null;i=g(t/r)}else if(e.type===`colorScale`&&e.zeroCentred){let n=e.minValue??r?.min??t,a=e.maxValue??r?.max??t;i=g(.5+t/(Math.max(Math.abs(n),Math.abs(a))||1)/2)}else{let n=r?.min??t,a=r?.max??t,o,s;if(e.bounds===`percent`){let t=a-n;o=n+(e.minValue??0)/100*t,s=n+(e.maxValue??100)/100*t}else o=e.minValue??n,s=e.maxValue??a;i=s===o?.5:g((t-o)/(s-o))}return e.type===`colorScale`&&e.reverse&&(i=1-i),i}function C(e,t,n,r,i){let a={};for(let o of r){if(o.columns&&!o.columns.includes(n))continue;let r=Number(e);if(o.type===`rule`){if(o.when({value:e,row:t})){if(o.background&&(a.background=o.background,!o.color)){let e=y(o.background);e&&(a.color=e)}o.color&&(a.color=o.color),o.fontWeight!=null&&(a.fontWeight=o.fontWeight),o.icon&&(a.icon=o.icon)}continue}if(!(e==null||e===``||!Number.isFinite(r))){if(o.type===`colorScale`){let n=S(o,r,t,i);if(n==null)continue;if(o.mode===`alpha`){let[e,t]=o.alphaBounds??[.05,.85];a.background=x(o.base??`#2563eb`,e+(t-e)*n)}else{a.background=te(o,n);let e=y(a.background);e&&(a.color=e)}o.tooltip===`value`?a.title=String(e):o.tooltip===`percent`&&(a.title=`${Math.round(n*100)}%`)}else if(o.type===`dataBar`){let e;if(o.compareColumn){let n=S(o,r,t,i);if(n==null)continue;e=n*100}else if(o.bounds===`percent`){let n=S(o,r,t,i);if(n==null)continue;e=n*100}else{let t=o.minValue??Math.min(0,i?.min??0),n=(o.maxValue??i?.max??r)-t||1;e=g((r-t)/n)*100}a.dataBar={percent:e,color:r<0?o.negativeColor??`#ef4444`:o.color,fromRight:!1,gradient:o.gradient},o.showValue===!1&&(a.color=`transparent`)}else if(o.type===`iconSet`){let e=p[o.set??`arrows`];a.icon=h(e,o.thresholds,r),o.iconOnly&&(a.iconOnly=!0)}}}return a}function ne(e){return!(e.type!==`colorScale`&&e.type!==`dataBar`||`compareColumn`in e&&e.compareColumn||e.minValue!=null&&e.maxValue!=null&&(e.bounds??`absolute`)===`absolute`)}function re(e){return e.some(ne)}var w=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),T=(e,t)=>e>>>t|e<<32-t;function ie(e){let t=new TextEncoder().encode(e),n=t.length*8,r=Math.ceil((t.length+9)/64)*64,i=new Uint8Array(r);i.set(t),i[t.length]=128;let a=new DataView(i.buffer);a.setUint32(r-8,Math.floor(n/4294967296)),a.setUint32(r-4,n>>>0);let o=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),s=new Uint32Array(64);for(let e=0;e<r;e+=64){for(let t=0;t<16;t++)s[t]=a.getUint32(e+t*4);for(let e=16;e<64;e++){let t=T(s[e-15],7)^T(s[e-15],18)^s[e-15]>>>3,n=T(s[e-2],17)^T(s[e-2],19)^s[e-2]>>>10;s[e]=s[e-16]+t+s[e-7]+n>>>0}let t=o[0],n=o[1],r=o[2],i=o[3],c=o[4],l=o[5],u=o[6],d=o[7];for(let e=0;e<64;e++){let a=T(c,6)^T(c,11)^T(c,25),o=c&l^~c&u,f=d+a+o+w[e]+s[e]>>>0,p=(T(t,2)^T(t,13)^T(t,22))+(t&n^t&r^n&r)>>>0;d=u,u=l,l=c,c=i+f>>>0,i=r,r=n,n=t,t=f+p>>>0}o[0]=o[0]+t>>>0,o[1]=o[1]+n>>>0,o[2]=o[2]+r>>>0,o[3]=o[3]+i>>>0,o[4]=o[4]+c>>>0,o[5]=o[5]+l>>>0,o[6]=o[6]+u>>>0,o[7]=o[7]+d>>>0}let c=``;for(let e of o)c+=e.toString(16).padStart(8,`0`);return c}function ae(e,t){return e===`suite`||t===`grid`}function E(e,t=new Date){return e==null||e.trim()===``?{status:`unset`,valid:!1,edition:`suite`}:ie(e.trim().toLowerCase())===`dabe98638cdc5760637bb2a741e65680a6ff0fb590d8b1018c9597650486cb10`?{status:`licensed`,valid:!0,edition:`suite`}:{status:`invalid`,valid:!1,edition:`suite`}}var D=new Set([`svgrid.com`,`www.svgrid.com`]);function O(){let e=globalThis.location?.hostname;return typeof e==`string`&&D.has(e.toLowerCase())}var k=`data-svgrid-enterprise-watermark`,A=`data-svgrid-enterprise-nudged`,j=`https://svgrid.com/pricing/?utm_source=svgrid-enterprise&utm_medium=watermark`,M=`www.svgrid.com`,oe=5e3,se=700,ce=!1,N=null;function P(){O()||(de(),!(typeof document>`u`||typeof window>`u`)&&(queueMicrotask(()=>fe()),N||(N=new MutationObserver(le),N.observe(document.body,{childList:!0,subtree:!0}))))}var F=!1;function le(e){for(let t of e){let e=t.target;if(!(e.nodeType===1&&e.closest?.(`.sv-grid-root[${A}]`))){ue();return}}}function ue(){if(F)return;F=!0;let e=()=>{F=!1,fe()};typeof requestAnimationFrame==`function`?requestAnimationFrame(e):setTimeout(e,16)}function de(){ce||(ce=!0,!(typeof console>`u`)&&console.log(`%c @svgrid/enterprise %c User is using a Commercial version which requires a license.
3
- Contact sales@jqwidgets.com for details or visit the license page: https://svgrid.com/pricing/?utm_source=svgrid-enterprise&utm_medium=console`,`background:#4f46e5;color:#fff;padding:2px 6px;border-radius:3px;font-weight:600`,`color:inherit`))}function fe(){if(typeof document>`u`)return;let e=document.querySelectorAll(`.sv-grid-root, [role="grid"]`);if(e.length===0){he();return}document.querySelectorAll(`[${k}="fixed"]`).forEach(e=>e.remove());let t=new Set;e.forEach(e=>{let n=pe(e);n&&t.add(n)}),t.forEach(me)}function pe(e){let t=e.closest(`.sv-grid-root`);if(t)return t;let n=e;for(;n&&/^(TABLE|THEAD|TBODY|TFOOT|TR|COLGROUP)$/.test(n.tagName);)n=n.parentElement;return n}function me(e){if(e.hasAttribute(A))return;e.setAttribute(A,`1`),getComputedStyle(e).position===`static`&&(e.style.position=`relative`);let t=ge(`grid`);ve(t,!1),e.appendChild(t),_e(t)}function he(){if(typeof document>`u`||document.querySelector(`[${k}="fixed"]`))return;let e=ge(`fixed`);ve(e,!0),document.body.appendChild(e),_e(e)}function ge(e){let t=document.createElement(`a`);return t.setAttribute(k,e),t.href=j,t.target=`_blank`,t.rel=`noopener noreferrer`,t.textContent=M,t.title=`Unlicensed @svgrid/enterprise. Contact sales@jqwidgets.com or visit www.svgrid.com.`,t}function _e(e){if(typeof window>`u`){e.remove();return}window.setTimeout(()=>{if(typeof window>`u`){e.remove();return}e.style.opacity=`0`,window.setTimeout(()=>e.remove(),se)},oe)}function ve(e,t){Object.assign(e.style,{position:t?`fixed`:`absolute`,bottom:t?`12px`:`6px`,right:t?`12px`:`8px`,zIndex:`2147483647`,background:`rgba(15,23,42,0.85)`,color:`#fff`,padding:t?`6px 10px`:`4px 8px`,borderRadius:t?`4px`:`3px`,fontFamily:`-apple-system, "Segoe UI", Roboto, sans-serif`,fontSize:t?`11px`:`10px`,lineHeight:`1.2`,textDecoration:`none`,boxShadow:t?`0 2px 12px rgba(0,0,0,0.35)`:`0 1px 4px rgba(0,0,0,0.3)`,border:`1px solid rgba(255,255,255,0.18)`,pointerEvents:`auto`,letterSpacing:`0.02em`,opacity:`1`,transition:`opacity ${se}ms ease`})}var ye=`data-svgrid-enterprise-upgrade`,be=`https://svgrid.com/pricing`,xe=`https://svgrid.com/pricing?ref=in-app&utm_source=svgrid-enterprise&utm_medium=upgrade-prompt`,Se=!1;function I(e,t){if(Se||typeof document>`u`||typeof window>`u`||O()||document.querySelector(`[${ye}]`))return;Se=!0;let n=Ce(e,t?.expired===!0);document.body.appendChild(n),requestAnimationFrame(()=>{n.style.opacity=`1`,n.style.transform=`translateY(0)`})}function L(e){e.style.opacity=`0`,e.style.transform=`translateY(8px)`,window.setTimeout(()=>e.remove(),220)}function Ce(e,t=!1){let n=document.createElement(`div`);n.setAttribute(ye,`1`),n.setAttribute(`role`,`dialog`),n.setAttribute(`aria-label`,t?`Your trial has ended`:`Unlock SvGrid Pro`),Object.assign(n.style,{position:`fixed`,bottom:`16px`,right:`16px`,zIndex:`2147483646`,width:`320px`,maxWidth:`calc(100vw - 32px)`,boxSizing:`border-box`,padding:`16px 16px 14px`,background:`#0f172a`,color:`#e2e8f0`,borderRadius:`12px`,border:`1px solid rgba(99,102,241,0.4)`,boxShadow:`0 12px 40px rgba(0,0,0,0.45)`,fontFamily:`-apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif`,fontSize:`13px`,lineHeight:`1.45`,opacity:`0`,transform:`translateY(8px)`,transition:`opacity 220ms ease, transform 220ms ease`});let r=e?`<strong style="color:#fff">${we(e?String(e):`This`)}</strong> is a Pro feature.`:`You just used a <strong style="color:#fff">Pro</strong> feature.`,i=t?`TRIAL ENDED`:`PRO`,a=t?`Your trial has ended`:`Unlock SvGrid Pro`,o=t?`${r} Your evaluation period is over - everything still works,
4
- but this notice stays until a licence key is set.`:`${r} It runs in evaluation with a watermark - start a free trial
5
- to remove it and ship to production.`;return n.innerHTML=`
3
+ Contact sales@jqwidgets.com for details or visit the license page: https://svgrid.com/pricing/?utm_source=svgrid-enterprise&utm_medium=console`,`background:#4f46e5;color:#fff;padding:2px 6px;border-radius:3px;font-weight:600`,`color:inherit`))}function fe(){if(typeof document>`u`)return;let e=document.querySelectorAll(`.sv-grid-root, [role="grid"]`);if(e.length===0){he();return}document.querySelectorAll(`[${k}="fixed"]`).forEach(e=>e.remove());let t=new Set;e.forEach(e=>{let n=pe(e);n&&t.add(n)}),t.forEach(me)}function pe(e){let t=e.closest(`.sv-grid-root`);if(t)return t;let n=e;for(;n&&/^(TABLE|THEAD|TBODY|TFOOT|TR|COLGROUP)$/.test(n.tagName);)n=n.parentElement;return n}function me(e){if(e.hasAttribute(A))return;e.setAttribute(A,`1`),getComputedStyle(e).position===`static`&&(e.style.position=`relative`);let t=ge(`grid`);ve(t,!1),e.appendChild(t),_e(t)}function he(){if(typeof document>`u`||document.querySelector(`[${k}="fixed"]`))return;let e=ge(`fixed`);ve(e,!0),document.body.appendChild(e),_e(e)}function ge(e){let t=document.createElement(`a`);return t.setAttribute(k,e),t.href=j,t.target=`_blank`,t.rel=`noopener noreferrer`,t.textContent=M,t.title=`Unlicensed @svgrid/enterprise. Contact sales@jqwidgets.com or visit www.svgrid.com.`,t}function _e(e){if(typeof window>`u`){e.remove();return}window.setTimeout(()=>{if(typeof window>`u`){e.remove();return}e.style.opacity=`0`,window.setTimeout(()=>e.remove(),se)},oe)}function ve(e,t){Object.assign(e.style,{position:t?`fixed`:`absolute`,bottom:t?`12px`:`6px`,right:t?`12px`:`8px`,zIndex:`2147483647`,background:`rgba(15,23,42,0.85)`,color:`#fff`,padding:t?`6px 10px`:`4px 8px`,borderRadius:t?`4px`:`3px`,fontFamily:`-apple-system, "Segoe UI", Roboto, sans-serif`,fontSize:t?`11px`:`10px`,lineHeight:`1.2`,textDecoration:`none`,boxShadow:t?`0 2px 12px rgba(0,0,0,0.35)`:`0 1px 4px rgba(0,0,0,0.3)`,border:`1px solid rgba(255,255,255,0.18)`,pointerEvents:`auto`,letterSpacing:`0.02em`,opacity:`1`,transition:`opacity ${se}ms ease`})}var ye=`data-svgrid-enterprise-upgrade`,be=`https://svgrid.com/pricing?ref=in-app&utm_source=svgrid-enterprise&utm_medium=upgrade-prompt`,xe=`https://svgrid.com/docs/enterprise/evaluation/?utm_source=svgrid-enterprise&utm_medium=upgrade-prompt`,Se=!1;function I(e,t){if(Se||typeof document>`u`||typeof window>`u`||O()||document.querySelector(`[${ye}]`))return;Se=!0;let n=Ce(e,t?.expired===!0);document.body.appendChild(n),requestAnimationFrame(()=>{n.style.opacity=`1`,n.style.transform=`translateY(0)`})}function L(e){e.style.opacity=`0`,e.style.transform=`translateY(8px)`,window.setTimeout(()=>e.remove(),220)}function Ce(e,t=!1){let n=document.createElement(`div`);n.setAttribute(ye,`1`),n.setAttribute(`role`,`dialog`),n.setAttribute(`aria-label`,t?`Your evaluation has ended`:`SvGrid Enterprise`),Object.assign(n.style,{position:`fixed`,bottom:`16px`,right:`16px`,zIndex:`2147483646`,width:`320px`,maxWidth:`calc(100vw - 32px)`,boxSizing:`border-box`,padding:`16px 16px 14px`,background:`#0f172a`,color:`#e2e8f0`,borderRadius:`12px`,border:`1px solid rgba(99,102,241,0.4)`,boxShadow:`0 12px 40px rgba(0,0,0,0.45)`,fontFamily:`-apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif`,fontSize:`13px`,lineHeight:`1.45`,opacity:`0`,transform:`translateY(8px)`,transition:`opacity 220ms ease, transform 220ms ease`});let r=e?`<strong style="color:#fff">${we(e?String(e):`This`)}</strong> is part of SvGrid Enterprise.`:`You just used a <strong style="color:#fff">SvGrid Enterprise</strong> feature.`,i=t?`EVALUATION ENDED`:`ENTERPRISE`,a=t?`Your evaluation has ended`:`SvGrid Enterprise`,o=t?`${r} Everything still works, but this notice stays until a
4
+ license key is set.`:`${r} It keeps working as it is, here and in production. A
5
+ license key removes the watermark and this notice.`;return n.innerHTML=`
6
6
  <button type="button" data-act="x" aria-label="Dismiss"
7
7
  style="position:absolute;top:8px;right:8px;width:24px;height:24px;display:flex;
8
8
  align-items:center;justify-content:center;background:transparent;border:0;
@@ -16,16 +16,16 @@ Contact sales@jqwidgets.com for details or visit the license page: https://svgri
16
16
  ${o}
17
17
  </p>
18
18
  <div style="display:flex;gap:8px;align-items:center;">
19
- <a data-act="trial" href="${xe}" target="_blank" rel="noopener noreferrer"
19
+ <a data-act="plans" href="${be}" target="_blank" rel="noopener noreferrer"
20
20
  style="flex:1;text-align:center;background:#6366f1;color:#fff;font-weight:600;
21
- text-decoration:none;padding:8px 12px;border-radius:8px;">${t?`Buy a licence`:`Start free trial`}</a>
22
- <a data-act="pricing" href="${be}" target="_blank" rel="noopener noreferrer"
23
- style="color:#a5b4fc;text-decoration:none;padding:8px 6px;font-weight:600;">Pricing</a>
21
+ text-decoration:none;padding:8px 12px;border-radius:8px;">${t?`Buy a license`:`See plans`}</a>
22
+ <a data-act="evaluation" href="${xe}" target="_blank" rel="noopener noreferrer"
23
+ style="color:#a5b4fc;text-decoration:none;padding:8px 6px;font-weight:600;">How evaluation works</a>
24
24
  </div>
25
25
  <p style="margin:10px 0 0;font-size:11px;color:#64748b;">
26
26
  Already licensed? Call <code style="color:#94a3b8;">setLicenseKey()</code> at startup to hide this.
27
27
  </p>
28
- `,n.querySelector(`[data-act="x"]`)?.addEventListener(`click`,()=>L(n)),n.querySelector(`[data-act="trial"]`)?.addEventListener(`click`,()=>L(n)),n.querySelector(`[data-act="pricing"]`)?.addEventListener(`click`,()=>L(n)),n}function we(e){return e.replace(/&/g,`&amp;`).replace(/</g,`&lt;`).replace(/>/g,`&gt;`).replace(/"/g,`&quot;`)}var R=null,Te=!1,Ee=!1,De=new Set;function z(e){if(Ee)return;Ee=!0;let t=e.expiresAt?` on ${e.expiresAt.toISOString().slice(0,10)}`:``;console.info(`@svgrid/enterprise: your evaluation license expired${t}. Everything still works, but the watermark and upgrade notice stay until a license key is set. Contact sales@jqwidgets.com or see https://svgrid.com/pricing/?utm_source=svgrid-enterprise&utm_medium=console`)}function Oe(e){return e.status===`dev`||e.status===`eval`}var ke=!1;function B(e){ke||e.status!==`invalid`&&e.status!==`revoked`||O()||(ke=!0,console.warn(`@svgrid/enterprise: the license key passed to setLicenseKey() is not valid, so the watermark stays. Copy the key from your order email, or contact sales@jqwidgets.com.`))}function Ae(){return E(R).valid}function je(e){let t=E(R),n=Oe(t)&&t.expired===!0;t.valid&&!n||(B(t),P(),n&&z(t),I(e,{expired:n}))}var Me={grid:`the enterprise grid`,spreadsheet:`the spreadsheet`,studio:`the Studio`};function Ne(e){De.has(e)||(De.add(e),console.info(`@svgrid/enterprise: your Grid license does not cover ${Me[e]}. Everything still works, but the watermark and upgrade notice stay until the license is upgraded to Suite. Contact sales@jqwidgets.com or see https://svgrid.com/pricing/?utm_source=svgrid-enterprise&utm_medium=console`))}function Pe(e,t){let n=E(R),r=n.valid&&ae(n.edition,e),i=Oe(n)&&n.expired===!0;if(r&&!i)return;B(n);let a=n.valid&&!i&&!r;P(),a?Ne(e):i&&z(n),I(t,{expired:i})}function Fe(e){let t=E(R);switch(t.status){case`unset`:P(),I(e);return;case`invalid`:case`revoked`:B(t),P(),I(e);return;case`dev`:case`eval`:if(t.expired){P(),z(t),I(e,{expired:!0});return}Te||=(console.info(`@svgrid/enterprise: using a development / evaluation license. Not for production use.`),!0);return;case`licensed`:return}}var Ie=!1;function Le(){if(Ie)return;if(typeof window>`u`)throw Error(`@svgrid/enterprise: installSmartShim() requires a browser environment`);let e=window.Smart??{Utilities:{}};e.Utilities=e.Utilities??{},typeof e.Utilities.Assign!=`function`&&(e.Utilities.Assign=(t,n)=>{e.Utilities[t]=n}),(!e.Utilities.Core||typeof e.Utilities.Core.toDash!=`function`)&&(e.Utilities.Core={toDash:e=>e.replace(/[A-Z]/g,e=>`-`+e.toLowerCase())}),window.Smart=e,Ie=!0}var Re=/[\x00-\x08\x0B\x0C\x0E-\x1F]/g;function V(e){return e.replace(Re,``).replace(/&/g,`&amp;`).replace(/</g,`&lt;`).replace(/>/g,`&gt;`).replace(/"/g,`&quot;`)}function ze(e){let t=(e,t=2)=>String(e).padStart(t,`0`);return`${e.getFullYear()}-${t(e.getMonth()+1)}-${t(e.getDate())}T${t(e.getHours())}:${t(e.getMinutes())}:${t(e.getSeconds())}.000`}async function Be(e,t,n,r={}){let o=Math.max(1,r.chunkRows??5e3),s=n.length,c=r.rawValues===!0,l=r.cellVisual,u=r.precisionSafe===!0,f=new Map,p=[`<Style ss:ID="sHeader"><Font ss:Bold="1"/><Interior ss:Color="#F2F2F2" ss:Pattern="Solid"/></Style>`],m=e=>e===`right`?`Right`:e===`center`?`Center`:`Left`,h=e=>{let t=e.align&&e.align!==`left`;if(!e.numFmt&&!e.fill&&!e.color&&!e.bold&&!t)return;let n=`${e.numFmt??``}|${e.fill??``}|${e.color??``}|${e.bold?`b`:``}|${e.align??``}`,r=f.get(n);if(r)return r;let i=`s${f.size+1}`,a=[];return t&&a.push(`<Alignment ss:Horizontal="${m(e.align)}"/>`),(e.color||e.bold)&&a.push(`<Font${e.color?` ss:Color="${e.color}"`:``}${e.bold?` ss:Bold="1"`:``}/>`),e.fill&&a.push(`<Interior ss:Color="${e.fill}" ss:Pattern="Solid"/>`),e.numFmt&&a.push(`<NumberFormat ss:Format="${V(e.numFmt)}"/>`),p.push(`<Style ss:ID="${i}">${a.join(``)}</Style>`),f.set(n,i),i};function g(e,t,n,r){let o=e.link?.(t)||void 0,s=l?.(n,r),f=t=>h({numFmt:t,fill:s?.fill,color:s?.color,bold:s?.bold,align:e.align});if(e.exportValue){let n=e.exportValue(t),r=n==null?``:String(n);return{type:`String`,value:s?.icon?`${s.icon} ${r}`:r,styleId:f(),href:o}}let p=t[e.field];if(s?.icon){let t=c?String(p??``):a(p,e.format);return{type:`String`,value:`${s.icon} ${t}`,styleId:f(),href:o}}let m=e=>u&&Math.abs(e)>=0x38d7ea4c68000;if(c){let e=p==null?``:String(p);return typeof p==`number`&&Number.isFinite(p)&&!m(p)?{type:`Number`,value:e,styleId:f(),href:o}:{type:`String`,value:e,styleId:f(),href:o}}let g=i(p,e.format);if(g.ok){let t=d(e.format);return g.value instanceof Date?{type:`DateTime`,value:ze(g.value),styleId:f(t),href:o}:m(g.value)?{type:`String`,value:String(g.value),styleId:f(),href:o}:{type:`Number`,value:String(g.value),styleId:f(t),href:o}}return{type:`String`,value:a(p,e.format),styleId:f(),href:o}}let _=e=>`<Cell${e.styleId?` ss:StyleID="${e.styleId}"`:``}${e.href?` ss:HRef="${V(e.href)}"`:``}><Data ss:Type="${e.type}">${V(e.value)}</Data></Cell>`,v=r.widths?r.widths.map(e=>`<Column ss:Width="${Math.round(e*.75)}"/>`).join(``):``,y=Math.max(0,Math.floor(r.freezeColumns??0)),b=r.freezeHeader||y>0?`<WorksheetOptions xmlns="urn:schemas-microsoft-com:office:excel"><FreezePanes/><FrozenNoSplit/>`+(r.freezeHeader?`<SplitHorizontal>1</SplitHorizontal><TopRowBottomPane>1</TopRowBottomPane>`:``)+(y>0?`<SplitVertical>${y}</SplitVertical><LeftColumnRightPane>${y}</LeftColumnRightPane>`:``)+`<ActivePane>2</ActivePane></WorksheetOptions>`:``,x=[`<Row>${t.map(e=>`<Cell ss:StyleID="sHeader"><Data ss:Type="String">${V(e.header??e.field)}</Data></Cell>`).join(``)}</Row>`];for(let e=0;e<s;e++){if(r.signal?.aborted)throw new DOMException(`Export aborted`,`AbortError`);let i=n[e],a=t.map((t,n)=>_(g(t,i,e,n))).join(``);x.push(`<Row>${a}</Row>`),e>0&&e%o===0&&(r.onProgress?.({phase:`serialize`,ratio:e/s,row:e,total:s}),await new Promise(e=>setTimeout(e,0)))}return r.onProgress?.({phase:`serialize`,ratio:1,row:s,total:s}),`<?xml version="1.0"?>
28
+ `,n.querySelector(`[data-act="x"]`)?.addEventListener(`click`,()=>L(n)),n.querySelector(`[data-act="plans"]`)?.addEventListener(`click`,()=>L(n)),n.querySelector(`[data-act="evaluation"]`)?.addEventListener(`click`,()=>L(n)),n}function we(e){return e.replace(/&/g,`&amp;`).replace(/</g,`&lt;`).replace(/>/g,`&gt;`).replace(/"/g,`&quot;`)}var R=null,Te=!1,Ee=!1,De=new Set;function z(e){if(Ee)return;Ee=!0;let t=e.expiresAt?` on ${e.expiresAt.toISOString().slice(0,10)}`:``;console.info(`@svgrid/enterprise: your evaluation license expired${t}. Everything still works, but the watermark and upgrade notice stay until a license key is set. Contact sales@jqwidgets.com or see https://svgrid.com/pricing/?utm_source=svgrid-enterprise&utm_medium=console`)}function Oe(e){return e.status===`dev`||e.status===`eval`}var ke=!1;function B(e){ke||e.status!==`invalid`&&e.status!==`revoked`||O()||(ke=!0,console.warn(`@svgrid/enterprise: the license key passed to setLicenseKey() is not valid, so the watermark stays. Copy the key from your order email, or contact sales@jqwidgets.com.`))}function Ae(){return E(R).valid}function je(e){let t=E(R),n=Oe(t)&&t.expired===!0;t.valid&&!n||(B(t),P(),n&&z(t),I(e,{expired:n}))}var Me={grid:`the enterprise grid`,spreadsheet:`the spreadsheet`,studio:`the Studio`};function Ne(e){De.has(e)||(De.add(e),console.info(`@svgrid/enterprise: your Grid license does not cover ${Me[e]}. Everything still works, but the watermark and upgrade notice stay until the license is upgraded to Suite. Contact sales@jqwidgets.com or see https://svgrid.com/pricing/?utm_source=svgrid-enterprise&utm_medium=console`))}function Pe(e,t){let n=E(R),r=n.valid&&ae(n.edition,e),i=Oe(n)&&n.expired===!0;if(r&&!i)return;B(n);let a=n.valid&&!i&&!r;P(),a?Ne(e):i&&z(n),I(t,{expired:i})}function Fe(e){let t=E(R);switch(t.status){case`unset`:P(),I(e);return;case`invalid`:case`revoked`:B(t),P(),I(e);return;case`dev`:case`eval`:if(t.expired){P(),z(t),I(e,{expired:!0});return}Te||=(console.info(`@svgrid/enterprise: using a development / evaluation license. Not for production use.`),!0);return;case`licensed`:return}}var Ie=!1;function Le(){if(Ie)return;if(typeof window>`u`)throw Error(`@svgrid/enterprise: installSmartShim() requires a browser environment`);let e=window.Smart??{Utilities:{}};e.Utilities=e.Utilities??{},typeof e.Utilities.Assign!=`function`&&(e.Utilities.Assign=(t,n)=>{e.Utilities[t]=n}),(!e.Utilities.Core||typeof e.Utilities.Core.toDash!=`function`)&&(e.Utilities.Core={toDash:e=>e.replace(/[A-Z]/g,e=>`-`+e.toLowerCase())}),window.Smart=e,Ie=!0}var Re=/[\x00-\x08\x0B\x0C\x0E-\x1F]/g;function V(e){return e.replace(Re,``).replace(/&/g,`&amp;`).replace(/</g,`&lt;`).replace(/>/g,`&gt;`).replace(/"/g,`&quot;`)}function ze(e){let t=(e,t=2)=>String(e).padStart(t,`0`);return`${e.getFullYear()}-${t(e.getMonth()+1)}-${t(e.getDate())}T${t(e.getHours())}:${t(e.getMinutes())}:${t(e.getSeconds())}.000`}async function Be(e,t,n,r={}){let o=Math.max(1,r.chunkRows??5e3),s=n.length,c=r.rawValues===!0,l=r.cellVisual,u=r.precisionSafe===!0,f=new Map,p=[`<Style ss:ID="sHeader"><Font ss:Bold="1"/><Interior ss:Color="#F2F2F2" ss:Pattern="Solid"/></Style>`],m=e=>e===`right`?`Right`:e===`center`?`Center`:`Left`,h=e=>{let t=e.align&&e.align!==`left`;if(!e.numFmt&&!e.fill&&!e.color&&!e.bold&&!t)return;let n=`${e.numFmt??``}|${e.fill??``}|${e.color??``}|${e.bold?`b`:``}|${e.align??``}`,r=f.get(n);if(r)return r;let i=`s${f.size+1}`,a=[];return t&&a.push(`<Alignment ss:Horizontal="${m(e.align)}"/>`),(e.color||e.bold)&&a.push(`<Font${e.color?` ss:Color="${e.color}"`:``}${e.bold?` ss:Bold="1"`:``}/>`),e.fill&&a.push(`<Interior ss:Color="${e.fill}" ss:Pattern="Solid"/>`),e.numFmt&&a.push(`<NumberFormat ss:Format="${V(e.numFmt)}"/>`),p.push(`<Style ss:ID="${i}">${a.join(``)}</Style>`),f.set(n,i),i};function g(e,t,n,r){let o=e.link?.(t)||void 0,s=l?.(n,r),f=t=>h({numFmt:t,fill:s?.fill,color:s?.color,bold:s?.bold,align:e.align});if(e.exportValue){let n=e.exportValue(t),r=n==null?``:String(n);return{type:`String`,value:s?.icon?`${s.icon} ${r}`:r,styleId:f(),href:o}}let p=t[e.field];if(s?.icon){let t=c?String(p??``):a(p,e.format);return{type:`String`,value:`${s.icon} ${t}`,styleId:f(),href:o}}let m=e=>u&&Math.abs(e)>=0x38d7ea4c68000;if(c){let e=p==null?``:String(p);return typeof p==`number`&&Number.isFinite(p)&&!m(p)?{type:`Number`,value:e,styleId:f(),href:o}:{type:`String`,value:e,styleId:f(),href:o}}let g=i(p,e.format);if(g.ok){let t=d(e.format);return g.value instanceof Date?{type:`DateTime`,value:ze(g.value),styleId:f(t),href:o}:m(g.value)?{type:`String`,value:String(g.value),styleId:f(),href:o}:{type:`Number`,value:String(g.value),styleId:f(t),href:o}}return{type:`String`,value:a(p,e.format),styleId:f(),href:o}}let _=e=>`<Cell${e.styleId?` ss:StyleID="${e.styleId}"`:``}${e.href?` ss:HRef="${V(e.href)}"`:``}><Data ss:Type="${e.type}">${V(e.value)}</Data></Cell>`,v=r.widths?r.widths.map(e=>`<Column ss:Width="${Math.round(e*.75)}"/>`).join(``):``,y=Math.max(0,Math.floor(r.freezeColumns??0)),b=r.freezeHeader||y>0?`<WorksheetOptions xmlns="urn:schemas-microsoft-com:office:excel"><FreezePanes/><FrozenNoSplit/>`+(r.freezeHeader?`<SplitHorizontal>1</SplitHorizontal><TopRowBottomPane>1</TopRowBottomPane>`:``)+(y>0?`<SplitVertical>${y}</SplitVertical><LeftColumnRightPane>${y}</LeftColumnRightPane>`:``)+`<ActivePane>2</ActivePane></WorksheetOptions>`:``,x=[`<Row>${t.map(e=>`<Cell ss:StyleID="sHeader"><Data ss:Type="String">${V(e.header??e.field)}</Data></Cell>`).join(``)}</Row>`];for(let e=0;e<s;e++){if(r.signal?.aborted)throw new DOMException(`Export aborted`,`AbortError`);let i=n[e],a=t.map((t,n)=>_(g(t,i,e,n))).join(``);x.push(`<Row>${a}</Row>`),e>0&&e%o===0&&(r.onProgress?.({phase:`serialize`,ratio:e/s,row:e,total:s}),await new Promise(e=>setTimeout(e,0)))}return r.onProgress?.({phase:`serialize`,ratio:1,row:s,total:s}),`<?xml version="1.0"?>
29
29
  <?mso-application progid="Excel.Sheet"?>
30
30
  <Workbook xmlns="urn:schemas-microsoft-com:office:spreadsheet" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet" xmlns:html="http://www.w3.org/TR/REC-html40"><Styles>${p.join(``)}</Styles><Worksheet ss:Name="${V(e.slice(0,31)||`Sheet1`)}"><Table>${v}${x.join(``)}</Table>`+b+`</Worksheet></Workbook>`}var Ve={"&":`&amp;`,"<":`&lt;`,">":`&gt;`,'"':`&quot;`,"'":`&apos;`},He=/[\x00-\x08\x0B\x0C\x0E-\x1F]/g;function H(e){return e.replace(He,``).replace(/[&<>"']/g,e=>Ve[e])}function U(e){let t=e,n=``;do n=String.fromCharCode(65+t%26)+n,t=Math.floor(t/26)-1;while(t>=0);return n}function W(e){if(!e)return null;let t=/^#?([0-9a-f]{6})$/i.exec(e.trim());return t?`FF`+t[1].toUpperCase():null}function Ue(e){return(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())-Date.UTC(1899,11,30))/864e5}function We(e){if(e instanceof Date)return e;let t=String(e).trim(),n=/^(\d{4})-(\d{2})-(\d{2})$/.exec(t);return n?new Date(Number(n[1]),Number(n[2])-1,Number(n[3])):new Date(t)}var Ge=`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
31
31
  <Types xmlns="http://schemas.openxmlformats.org/package/2006/content-types"><Default Extension="rels" ContentType="application/vnd.openxmlformats-package.relationships+xml"/><Default Extension="xml" ContentType="application/xml"/><Override PartName="/xl/workbook.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml"/><Override PartName="/xl/worksheets/sheet1.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml"/><Override PartName="/xl/styles.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml"/></Types>`,Ke=`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
@@ -4,13 +4,13 @@
4
4
  <meta charset="UTF-8" />
5
5
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
6
6
  <title>SvGrid Studio - Designer</title>
7
- <script type="module" crossorigin src="./assets/index-Dknv-Eu8.js"></script>
7
+ <script type="module" crossorigin src="./assets/index-DtBIaQno.js"></script>
8
8
  <link rel="modulepreload" crossorigin href="./assets/rolldown-runtime-Dd_uD5pT.js">
9
9
  <link rel="modulepreload" crossorigin href="./assets/disclose-version-CIm4S9xS.js">
10
10
  <link rel="modulepreload" crossorigin href="./assets/cell-formatting-BWrW_O0n.js">
11
11
  <link rel="modulepreload" crossorigin href="./assets/export-format-DGscOjS9.js">
12
12
  <link rel="modulepreload" crossorigin href="./assets/preload-helper-HclGiUj8.js">
13
- <link rel="modulepreload" crossorigin href="./assets/src-D4PRZJYA.js">
13
+ <link rel="modulepreload" crossorigin href="./assets/src-DqHCqori.js">
14
14
  <link rel="modulepreload" crossorigin href="./assets/editor-contract-Bpoa7A5g.js">
15
15
  <link rel="modulepreload" crossorigin href="./assets/date-format-B8JbEtIG.js">
16
16
  <link rel="modulepreload" crossorigin href="./assets/list-option-BP_dWS66.js">
@@ -43,6 +43,7 @@
43
43
  type SchedulerDependency,
44
44
  } from "../scheduler-dependencies";
45
45
  import { criticalPath, slackDays } from "./gantt-critical-path";
46
+ import { keepOnScreen } from "../keep-on-screen";
46
47
  import { arrowHeadPath, dependencyArrows, nearestArrow, type BarRect } from "./timeline-arrows";
47
48
  import {
48
49
  ganttAxis,
@@ -1786,6 +1787,13 @@
1786
1787
  menuPos = { x: e.clientX, y: e.clientY };
1787
1788
  menuOpen = true;
1788
1789
  }
1790
+ // Opened at the pointer: keep the whole menu on screen (keep-on-screen.ts).
1791
+ $effect(() => {
1792
+ if (!menuOpen || !menuPanel || typeof window === "undefined") return;
1793
+ const r = menuPanel.getBoundingClientRect();
1794
+ const fit = keepOnScreen(menuPos, r, { width: window.innerWidth, height: window.innerHeight });
1795
+ if (fit.x !== menuPos.x || fit.y !== menuPos.y) menuPos = fit;
1796
+ });
1789
1797
  $effect(() => {
1790
1798
  if (!menuOpen) return;
1791
1799
  const layer = createDismissableLayer({
@@ -0,0 +1,26 @@
1
+ /**
2
+ * Where a pointer-anchored panel (a context menu, the "+N more" list) should
3
+ * sit so all of it is on screen.
4
+ *
5
+ * The scheduler and Gantt menus open at the pointer. A right-click near the
6
+ * bottom or right edge put their lower items outside the viewport, where they
7
+ * could not be clicked. The panel goes above the pointer when it does not fit
8
+ * below it, and is pulled back from the right edge when it does not fit there.
9
+ * The result for a position it returns is that same position, so an effect
10
+ * that writes it back settles after one pass.
11
+ *
12
+ * Internal: not exported from the package index.
13
+ */
14
+ export declare function keepOnScreen(pos: {
15
+ x: number;
16
+ y: number;
17
+ }, size: {
18
+ width: number;
19
+ height: number;
20
+ }, viewport: {
21
+ width: number;
22
+ height: number;
23
+ }, pad?: number): {
24
+ x: number;
25
+ y: number;
26
+ };
@@ -0,0 +1,24 @@
1
+ /**
2
+ * Where a pointer-anchored panel (a context menu, the "+N more" list) should
3
+ * sit so all of it is on screen.
4
+ *
5
+ * The scheduler and Gantt menus open at the pointer. A right-click near the
6
+ * bottom or right edge put their lower items outside the viewport, where they
7
+ * could not be clicked. The panel goes above the pointer when it does not fit
8
+ * below it, and is pulled back from the right edge when it does not fit there.
9
+ * The result for a position it returns is that same position, so an effect
10
+ * that writes it back settles after one pass.
11
+ *
12
+ * Internal: not exported from the package index.
13
+ */
14
+ export function keepOnScreen(pos, size, viewport, pad = 8) {
15
+ let { x, y } = pos;
16
+ // Above the pointer, but never lower than "bottom edge minus padding": a
17
+ // plain flip of a point within `pad` of the bottom would still overflow by
18
+ // a few pixels and flip again on the next pass.
19
+ if (y + size.height > viewport.height - pad)
20
+ y = Math.max(pad, Math.min(y - size.height, viewport.height - size.height - pad));
21
+ if (x + size.width > viewport.width - pad)
22
+ x = Math.max(pad, viewport.width - size.width - pad);
23
+ return { x, y };
24
+ }
@@ -16341,7 +16341,7 @@ function hasFieldConditions(schema) {
16341
16341
  *
16342
16342
  * `version.test.ts` asserts this matches `package.json`, so the two cannot drift.
16343
16343
  */
16344
- var SVGRID_VERSION = "3.1.6";
16344
+ var SVGRID_VERSION = "3.1.7";
16345
16345
  /**
16346
16346
  * The version of `@svgrid/grid`, which releases on its own line: enterprise is
16347
16347
  * on 3.1.x while the grid is on 3.0.x.
@@ -1,9 +1,9 @@
1
- /** Human-readable labels for the Pro surfaces that gate behind a license. */
1
+ /** Human-readable labels for the Enterprise surfaces that gate behind a license. */
2
2
  export type EnterpriseFeatureLabel = 'Export' | 'Import' | 'Print' | 'AI assistant' | 'Pivot' | 'Server-side row model' | 'Spreadsheet' | 'Studio';
3
3
  /**
4
4
  * Show the contextual upgrade prompt for `feature`. No-ops if one has already
5
5
  * been shown this session, a card is already up, or we're on the server. Safe
6
- * to call on every Pro feature invocation - it self-throttles.
6
+ * to call on every Enterprise feature invocation - it self-throttles.
7
7
  */
8
8
  export declare function showUpgradePrompt(feature?: EnterpriseFeatureLabel | string, opts?: {
9
9
  expired?: boolean;
@@ -1,8 +1,13 @@
1
1
  // Product-led-growth (PLG) upgrade nudge, shown at the *moment of intent*: the
2
- // instant a developer actually calls a Pro feature (export / import / print /
3
- // AI) without a license key set. Unlike the passive corner watermark
2
+ // instant a developer actually calls an Enterprise feature (export / import /
3
+ // print / pivot) without a license key set. Unlike the passive corner watermark
4
4
  // (watermark.ts), this is a one-click contextual card that names the feature
5
- // they just used and links straight to a free trial.
5
+ // they just used and links to the plans.
6
+ //
7
+ // The copy follows the one-key license (2026-10-07): there are no trial keys,
8
+ // unlicensed use simply runs with a watermark, and the product is "SvGrid
9
+ // Enterprise". The card used to say "Unlock SvGrid Pro" and "Start free trial",
10
+ // which promised a trial that does not exist.
6
11
  //
7
12
  // Rules of the road:
8
13
  // - Soft, never blocking. The feature already ran; this only nudges.
@@ -18,15 +23,15 @@
18
23
  // bundle, works in any host app regardless of its styling.
19
24
  import { isFirstPartySite } from './first-party.js';
20
25
  const CARD_ATTR = 'data-svgrid-enterprise-upgrade';
21
- const PRICING_URL = 'https://svgrid.com/pricing';
22
- // ?ref=in-app lets us measure how many trials start from this exact prompt
26
+ // ?ref=in-app lets us measure how many purchases start from this exact prompt
23
27
  // vs. the pricing page itself - the whole point of a moment-of-intent CTA.
24
- const TRIAL_URL = 'https://svgrid.com/pricing?ref=in-app&utm_source=svgrid-enterprise&utm_medium=upgrade-prompt';
28
+ const PLANS_URL = 'https://svgrid.com/pricing?ref=in-app&utm_source=svgrid-enterprise&utm_medium=upgrade-prompt';
29
+ const EVALUATION_URL = 'https://svgrid.com/docs/enterprise/evaluation/?utm_source=svgrid-enterprise&utm_medium=upgrade-prompt';
25
30
  let shownThisSession = false;
26
31
  /**
27
32
  * Show the contextual upgrade prompt for `feature`. No-ops if one has already
28
33
  * been shown this session, a card is already up, or we're on the server. Safe
29
- * to call on every Pro feature invocation - it self-throttles.
34
+ * to call on every Enterprise feature invocation - it self-throttles.
30
35
  */
31
36
  export function showUpgradePrompt(feature, opts) {
32
37
  if (shownThisSession)
@@ -68,7 +73,7 @@ function buildCard(feature, expired = false) {
68
73
  const card = document.createElement('div');
69
74
  card.setAttribute(CARD_ATTR, '1');
70
75
  card.setAttribute('role', 'dialog');
71
- card.setAttribute('aria-label', expired ? 'Your trial has ended' : 'Unlock SvGrid Pro');
76
+ card.setAttribute('aria-label', expired ? 'Your evaluation has ended' : 'SvGrid Enterprise');
72
77
  Object.assign(card.style, {
73
78
  position: 'fixed',
74
79
  bottom: '16px',
@@ -92,18 +97,18 @@ function buildCard(feature, expired = false) {
92
97
  });
93
98
  const featureName = feature ? String(feature) : 'This';
94
99
  const featurePhrase = feature
95
- ? `<strong style="color:#fff">${escapeHtml(featureName)}</strong> is a Pro feature.`
96
- : `You just used a <strong style="color:#fff">Pro</strong> feature.`;
97
- // An expired trial is a different message from "you never had a licence":
98
- // they already evaluated, so the ask is to convert, not to start over.
99
- const badge = expired ? 'TRIAL ENDED' : 'PRO';
100
- const heading = expired ? 'Your trial has ended' : 'Unlock SvGrid Pro';
100
+ ? `<strong style="color:#fff">${escapeHtml(featureName)}</strong> is part of SvGrid Enterprise.`
101
+ : `You just used a <strong style="color:#fff">SvGrid Enterprise</strong> feature.`;
102
+ // An expired evaluation is a different message from "you never had a
103
+ // license": they already evaluated, so the ask is to convert.
104
+ const badge = expired ? 'EVALUATION ENDED' : 'ENTERPRISE';
105
+ const heading = expired ? 'Your evaluation has ended' : 'SvGrid Enterprise';
101
106
  const body = expired
102
- ? `${featurePhrase} Your evaluation period is over - everything still works,
103
- but this notice stays until a licence key is set.`
104
- : `${featurePhrase} It runs in evaluation with a watermark - start a free trial
105
- to remove it and ship to production.`;
106
- const cta = expired ? 'Buy a licence' : 'Start free trial';
107
+ ? `${featurePhrase} Everything still works, but this notice stays until a
108
+ license key is set.`
109
+ : `${featurePhrase} It keeps working as it is, here and in production. A
110
+ license key removes the watermark and this notice.`;
111
+ const cta = expired ? 'Buy a license' : 'See plans';
107
112
  card.innerHTML = `
108
113
  <button type="button" data-act="x" aria-label="Dismiss"
109
114
  style="position:absolute;top:8px;right:8px;width:24px;height:24px;display:flex;
@@ -118,21 +123,21 @@ function buildCard(feature, expired = false) {
118
123
  ${body}
119
124
  </p>
120
125
  <div style="display:flex;gap:8px;align-items:center;">
121
- <a data-act="trial" href="${TRIAL_URL}" target="_blank" rel="noopener noreferrer"
126
+ <a data-act="plans" href="${PLANS_URL}" target="_blank" rel="noopener noreferrer"
122
127
  style="flex:1;text-align:center;background:#6366f1;color:#fff;font-weight:600;
123
128
  text-decoration:none;padding:8px 12px;border-radius:8px;">${cta}</a>
124
- <a data-act="pricing" href="${PRICING_URL}" target="_blank" rel="noopener noreferrer"
125
- style="color:#a5b4fc;text-decoration:none;padding:8px 6px;font-weight:600;">Pricing</a>
129
+ <a data-act="evaluation" href="${EVALUATION_URL}" target="_blank" rel="noopener noreferrer"
130
+ style="color:#a5b4fc;text-decoration:none;padding:8px 6px;font-weight:600;">How evaluation works</a>
126
131
  </div>
127
132
  <p style="margin:10px 0 0;font-size:11px;color:#64748b;">
128
133
  Already licensed? Call <code style="color:#94a3b8;">setLicenseKey()</code> at startup to hide this.
129
134
  </p>
130
135
  `;
131
136
  card.querySelector('[data-act="x"]')?.addEventListener('click', () => close(card));
132
- // Clicking through to a trial / pricing also counts as "handled" - close the
133
- // card, but let the link open in its new tab first.
134
- card.querySelector('[data-act="trial"]')?.addEventListener('click', () => close(card));
135
- card.querySelector('[data-act="pricing"]')?.addEventListener('click', () => close(card));
137
+ // Clicking through to the plans or the evaluation page also counts as
138
+ // "handled" - close the card, but let the link open in its new tab first.
139
+ card.querySelector('[data-act="plans"]')?.addEventListener('click', () => close(card));
140
+ card.querySelector('[data-act="evaluation"]')?.addEventListener('click', () => close(card));
136
141
  return card;
137
142
  }
138
143
  function escapeHtml(s) {
package/dist/version.d.ts CHANGED
@@ -10,7 +10,7 @@
10
10
  *
11
11
  * `version.test.ts` asserts this matches `package.json`, so the two cannot drift.
12
12
  */
13
- export declare const SVGRID_VERSION = "3.1.6";
13
+ export declare const SVGRID_VERSION = "3.1.7";
14
14
  /**
15
15
  * The version of `@svgrid/grid`, which releases on its own line: enterprise is
16
16
  * on 3.1.x while the grid is on 3.0.x.
package/dist/version.js CHANGED
@@ -10,7 +10,7 @@
10
10
  *
11
11
  * `version.test.ts` asserts this matches `package.json`, so the two cannot drift.
12
12
  */
13
- export const SVGRID_VERSION = '3.1.6';
13
+ export const SVGRID_VERSION = '3.1.7';
14
14
  /**
15
15
  * The version of `@svgrid/grid`, which releases on its own line: enterprise is
16
16
  * on 3.1.x while the grid is on 3.0.x.
@@ -34521,7 +34521,7 @@ function ij(e, t) {
34521
34521
  }
34522
34522
  //#endregion
34523
34523
  //#region src/upgrade-prompt.ts
34524
- var aj = "data-svgrid-enterprise-upgrade", oj = "https://svgrid.com/pricing", sj = "https://svgrid.com/pricing?ref=in-app&utm_source=svgrid-enterprise&utm_medium=upgrade-prompt", cj = !1;
34524
+ var aj = "data-svgrid-enterprise-upgrade", oj = "https://svgrid.com/pricing?ref=in-app&utm_source=svgrid-enterprise&utm_medium=upgrade-prompt", sj = "https://svgrid.com/docs/enterprise/evaluation/?utm_source=svgrid-enterprise&utm_medium=upgrade-prompt", cj = !1;
34525
34525
  function lj(e, t) {
34526
34526
  if (cj || typeof document > "u" || typeof window > "u" || RA() || document.querySelector(`[${aj}]`)) return;
34527
34527
  cj = !0;
@@ -34535,7 +34535,7 @@ function uj(e) {
34535
34535
  }
34536
34536
  function dj(e, t = !1) {
34537
34537
  let n = document.createElement("div");
34538
- n.setAttribute(aj, "1"), n.setAttribute("role", "dialog"), n.setAttribute("aria-label", t ? "Your trial has ended" : "Unlock SvGrid Pro"), Object.assign(n.style, {
34538
+ n.setAttribute(aj, "1"), n.setAttribute("role", "dialog"), n.setAttribute("aria-label", t ? "Your evaluation has ended" : "SvGrid Enterprise"), Object.assign(n.style, {
34539
34539
  position: "fixed",
34540
34540
  bottom: "16px",
34541
34541
  right: "16px",
@@ -34556,9 +34556,9 @@ function dj(e, t = !1) {
34556
34556
  transform: "translateY(8px)",
34557
34557
  transition: "opacity 220ms ease, transform 220ms ease"
34558
34558
  });
34559
- let r = e ? `<strong style="color:#fff">${fj(e ? String(e) : "This")}</strong> is a Pro feature.` : "You just used a <strong style=\"color:#fff\">Pro</strong> feature.", i = t ? "TRIAL ENDED" : "PRO", a = t ? "Your trial has ended" : "Unlock SvGrid Pro", o = t ? `${r} Your evaluation period is over - everything still works,
34560
- but this notice stays until a licence key is set.` : `${r} It runs in evaluation with a watermark - start a free trial
34561
- to remove it and ship to production.`;
34559
+ let r = e ? `<strong style="color:#fff">${fj(e ? String(e) : "This")}</strong> is part of SvGrid Enterprise.` : "You just used a <strong style=\"color:#fff\">SvGrid Enterprise</strong> feature.", i = t ? "EVALUATION ENDED" : "ENTERPRISE", a = t ? "Your evaluation has ended" : "SvGrid Enterprise", o = t ? `${r} Everything still works, but this notice stays until a
34560
+ license key is set.` : `${r} It keeps working as it is, here and in production. A
34561
+ license key removes the watermark and this notice.`;
34562
34562
  return n.innerHTML = `
34563
34563
  <button type="button" data-act="x" aria-label="Dismiss"
34564
34564
  style="position:absolute;top:8px;right:8px;width:24px;height:24px;display:flex;
@@ -34573,16 +34573,16 @@ function dj(e, t = !1) {
34573
34573
  ${o}
34574
34574
  </p>
34575
34575
  <div style="display:flex;gap:8px;align-items:center;">
34576
- <a data-act="trial" href="${sj}" target="_blank" rel="noopener noreferrer"
34576
+ <a data-act="plans" href="${oj}" target="_blank" rel="noopener noreferrer"
34577
34577
  style="flex:1;text-align:center;background:#6366f1;color:#fff;font-weight:600;
34578
- text-decoration:none;padding:8px 12px;border-radius:8px;">${t ? "Buy a licence" : "Start free trial"}</a>
34579
- <a data-act="pricing" href="${oj}" target="_blank" rel="noopener noreferrer"
34580
- style="color:#a5b4fc;text-decoration:none;padding:8px 6px;font-weight:600;">Pricing</a>
34578
+ text-decoration:none;padding:8px 12px;border-radius:8px;">${t ? "Buy a license" : "See plans"}</a>
34579
+ <a data-act="evaluation" href="${sj}" target="_blank" rel="noopener noreferrer"
34580
+ style="color:#a5b4fc;text-decoration:none;padding:8px 6px;font-weight:600;">How evaluation works</a>
34581
34581
  </div>
34582
34582
  <p style="margin:10px 0 0;font-size:11px;color:#64748b;">
34583
34583
  Already licensed? Call <code style="color:#94a3b8;">setLicenseKey()</code> at startup to hide this.
34584
34584
  </p>
34585
- `, n.querySelector("[data-act=\"x\"]")?.addEventListener("click", () => uj(n)), n.querySelector("[data-act=\"trial\"]")?.addEventListener("click", () => uj(n)), n.querySelector("[data-act=\"pricing\"]")?.addEventListener("click", () => uj(n)), n;
34585
+ `, n.querySelector("[data-act=\"x\"]")?.addEventListener("click", () => uj(n)), n.querySelector("[data-act=\"plans\"]")?.addEventListener("click", () => uj(n)), n.querySelector("[data-act=\"evaluation\"]")?.addEventListener("click", () => uj(n)), n;
34586
34586
  }
34587
34587
  function fj(e) {
34588
34588
  return e.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;");
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "type": "commercial",
5
5
  "url": "https://svgrid.com/pricing"
6
6
  },
7
- "version": "3.1.6",
7
+ "version": "3.1.7",
8
8
  "description": "Enterprise feature pack for SvGrid: the server-side row model (lazy grouping, tree, pivot, transactions, selection across unloaded rows), Excel (xlsx) and PDF export, Excel/CSV/JSON import, pivot tables with a drag-and-drop designer, paginated print, Kanban board and scheduler renderers, no-code alerts and batch editing. CSV, TSV and JSON export are already free in @svgrid/grid. Requires a paid license key.",
9
9
  "license": "SEE LICENSE IN LICENSE",
10
10
  "author": "jQWidgets <sales@jqwidgets.com>",