nyc-taxi / _app /immutable /nodes /6.DJMPKfWz.js
archiesarrewood's picture
Upload folder using huggingface_hub
1879a1a verified
raw
history blame
5.54 kB
import{s as Y,e as S,a as v,d as R,H as te,c as D,g as B,f as h,j as C,k as y,l as Q,J as se,B as V,K as ne,L as le,r as re,b as L,t as A,i as N,m as ie,I as ae,u as Z,M as oe,N as ue}from"../chunks/scheduler.BZlHRu_0.js";import{S as $,i as x,t as k,g as M,b as E,d as O,c as I,a as H,m as P,e as z,f as T}from"../chunks/index.a_oafgNU.js";import{b as fe,c as j,d as ce,E as J,e as K,g as de,D as _e,h as W}from"../chunks/VennDiagram.svelte_svelte_type_style_lang.BbIdL-mm.js";import"../chunks/entry.ZK3zkBMq.js";import{B as F}from"../chunks/Button.ihrsuxI6.js";function G(r){let e,t,l,s,n;return t=new F({props:{size:"sm",outline:!0,icon:r[1]?J:K,$$slots:{default:[be]},$$scope:{ctx:r}}}),t.$on("click",r[10]),s=new F({props:{size:"sm",variant:"success",outline:!0,icon:de,$$slots:{default:[ge]},$$scope:{ctx:r}}}),s.$on("click",r[11]),{c(){e=S("div"),I(t.$$.fragment),l=v(),I(s.$$.fragment),this.h()},l(i){e=R(i,"DIV",{class:!0});var u=B(e);H(t.$$.fragment,u),l=D(u),H(s.$$.fragment,u),u.forEach(h),this.h()},h(){C(e,"class","absolute bottom-2 right-2 z-10 flex gap-2")},m(i,u){y(i,e,u),P(t,e,null),Q(e,l),P(s,e,null),n=!0},p(i,u){const b={};u&2&&(b.icon=i[1]?J:K),u&32770&&(b.$$scope={dirty:u,ctx:i}),t.$set(b);const g={};u&32768&&(g.$$scope={dirty:u,ctx:i}),s.$set(g)},i(i){n||(k(t.$$.fragment,i),k(s.$$.fragment,i),n=!0)},o(i){E(t.$$.fragment,i),E(s.$$.fragment,i),n=!1},d(i){i&&h(e),z(t),z(s)}}}function me(r){let e;return{c(){e=A("Show Results")},l(t){e=N(t,"Show Results")},m(t,l){y(t,e,l)},d(t){t&&h(e)}}}function he(r){let e;return{c(){e=A("Hide Results")},l(t){e=N(t,"Hide Results")},m(t,l){y(t,e,l)},d(t){t&&h(e)}}}function be(r){let e;function t(n,i){return n[1]?he:me}let l=t(r),s=l(r);return{c(){s.c(),e=L()},l(n){s.l(n),e=L()},m(n,i){s.m(n,i),y(n,e,i)},p(n,i){l!==(l=t(n))&&(s.d(1),s=l(n),s&&(s.c(),s.m(e.parentNode,e)))},d(n){n&&h(e),s.d(n)}}}function ge(r){let e;return{c(){e=A("Submit")},l(t){e=N(t,"Submit")},m(t,l){y(t,e,l)},d(t){t&&h(e)}}}function U(r){let e,t=r[8].error+"",l;return{c(){e=S("pre"),l=A(t),this.h()},l(s){e=R(s,"PRE",{class:!0});var n=B(e);l=N(n,t),n.forEach(h),this.h()},h(){C(e,"class","text-red-500 text-xs font-mono")},m(s,n){y(s,e,n),Q(e,l)},p(s,n){n&256&&t!==(t=s[8].error+"")&&ie(l,t)},d(s){s&&h(e)}}}function X(r){let e,t,l,s;return t=new _e({props:{data:r[8]}}),{c(){e=S("div"),I(t.$$.fragment)},l(n){e=R(n,"DIV",{});var i=B(e);H(t.$$.fragment,i),i.forEach(h)},m(n,i){y(n,e,i),P(t,e,null),s=!0},p(n,i){const u={};i&256&&(u.data=n[8]),t.$set(u)},i(n){s||(k(t.$$.fragment,n),n&&ae(()=>{s&&(l||(l=T(e,W,{},!0)),l.run(1))}),s=!0)},o(n){E(t.$$.fragment,n),n&&(l||(l=T(e,W,{},!1)),l.run(0)),s=!1},d(n){n&&h(e),z(t),n&&l&&l.end()}}}function pe(r){let e,t="SQL Console",l,s,n,i,u,b=r[8].error&&!r[2]&&!!r[4],g,m,w,p,a=!r[3]&&G(r),f=b&&U(r),c=r[1]&&X(r);return{c(){e=S("h1"),e.textContent=t,l=v(),s=S("section"),n=S("div"),a&&a.c(),u=v(),f&&f.c(),g=v(),c&&c.c(),this.h()},l(o){e=R(o,"H1",{class:!0,"data-svelte-h":!0}),te(e)!=="svelte-7ylf69"&&(e.textContent=t),l=D(o),s=R(o,"SECTION",{class:!0,role:!0});var _=B(s);n=R(_,"DIV",{class:!0});var q=B(n);a&&a.l(q),q.forEach(h),u=D(_),f&&f.l(_),g=D(_),c&&c.l(_),_.forEach(h),this.h()},h(){C(e,"class","markdown"),C(n,"class","w-full relative rounded border border-gray-300 min-h-[8rem] cursor-text"),C(s,"class","px-0 py-2 bg-white flex flex-col gap-2 min-h-[8rem] svelte-1bw0fbe"),C(s,"role","none")},m(o,_){y(o,e,_),y(o,l,_),y(o,s,_),Q(s,n),a&&a.m(n,null),r[12](n),Q(s,u),f&&f.m(s,null),Q(s,g),c&&c.m(s,null),m=!0,w||(p=[se(i=fe.call(null,n,r[5])),V(s,"click",r[13]),V(s,"keydown",r[14])],w=!0)},p(o,[_]){o[3]?a&&(M(),E(a,1,1,()=>{a=null}),O()):a?(a.p(o,_),_&8&&k(a,1)):(a=G(o),a.c(),k(a,1),a.m(n,null)),i&&ne(i.update)&&_&32&&i.update.call(null,o[5]),_&276&&(b=o[8].error&&!o[2]&&!!o[4]),b?f?f.p(o,_):(f=U(o),f.c(),f.m(s,g)):f&&(f.d(1),f=null),o[1]?c?(c.p(o,_),_&2&&k(c,1)):(c=X(o),c.c(),k(c,1),c.m(s,null)):c&&(M(),E(c,1,1,()=>{c=null}),O())},i(o){m||(k(a),k(c),m=!0)},o(o){E(a),E(c),m=!1},d(o){o&&(h(e),h(l),h(s)),a&&a.d(),r[12](null),f&&f.d(),c&&c.d(),w=!1,le(p)}}}function ke(r,e,t){let l,s=Z,n=()=>(s(),s=oe(p,d=>t(8,l=d)),p);r.$$.on_destroy.push(()=>s());let{hideErrors:i=!1}=e,{initialQuery:u="select 'ABC' as category, 123 as num, 26400000 as sales_usd"}=e,{showResults:b=!0}=e,{disabled:g=!1}=e,m=u,w=m,{data:p=j(m)}=e;n();let a,f;re(async()=>{p&&p.fetch(),t(5,f={initialState:u,disabled:g,schema:await ce(),onChange:d=>{d.docChanged&&w.trim()!==d.state.doc.toString().trim()&&t(6,w=d.state.doc.toString())},onSubmit:()=>(t(4,m=w.trim()),m.endsWith(";")&&t(4,m=m.substring(0,m.length-1)),t(1,b=!0),!0)})});const c=()=>t(1,b=!b),o=()=>{t(4,m=w),t(1,b=!0)};function _(d){ue[d?"unshift":"push"](()=>{a=d,t(7,a)})}const q=()=>a==null?void 0:a.focus(),ee=d=>d.key==="Enter"&&(a==null?void 0:a.focus());return r.$$set=d=>{"hideErrors"in d&&t(2,i=d.hideErrors),"initialQuery"in d&&t(9,u=d.initialQuery),"showResults"in d&&t(1,b=d.showResults),"disabled"in d&&t(3,g=d.disabled),"data"in d&&n(t(0,p=d.data))},r.$$.update=()=>{r.$$.dirty&17&&m&&(n(t(0,p=j(m))),p.fetch()),r.$$.dirty&40&&f&&t(5,f.disabled=g,f)},[p,b,i,g,m,f,w,a,l,u,c,o,_,q,ee]}class ye extends ${constructor(e){super(),x(this,e,ke,pe,Y,{hideErrors:2,initialQuery:9,showResults:1,disabled:3,data:0})}}function we(r){let e,t;return e=new ye({}),{c(){I(e.$$.fragment)},l(l){H(e.$$.fragment,l)},m(l,s){P(e,l,s),t=!0},p:Z,i(l){t||(k(e.$$.fragment,l),t=!0)},o(l){E(e.$$.fragment,l),t=!1},d(l){z(e,l)}}}class Be extends ${constructor(e){super(),x(this,e,null,we,Y,{})}}export{Be as component};