@layers-app/editor 0.7.47 → 0.7.48
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/README.md +840 -830
- package/dist/index.cjs +2 -2
- package/dist/index.d.ts +8 -14
- package/dist/index.js +4 -4
- package/dist/layers.-XXFcZ-Q.js +33 -0
- package/dist/layers.3jBLdifJ.js +38 -0
- package/dist/layers.48nWXuMb.js +504 -0
- package/dist/layers.4NkfZAG8.js +39 -0
- package/dist/layers.52famHy6.js +1 -0
- package/dist/layers.6JZIYhnG.js +21941 -0
- package/dist/layers.7JqFgE4-.js +15 -0
- package/dist/layers.8I_XubBt.js +1 -0
- package/dist/layers.8L97LNWM.js +116 -0
- package/dist/layers.9Ei77wJG.js +40 -0
- package/dist/layers.9pNaFvaX.js +1 -0
- package/dist/layers.9vsoRdca.js +7 -0
- package/dist/layers.B19hGmey.js +1 -0
- package/dist/layers.B2hK-O3y.js +40 -0
- package/dist/layers.B3D4g2HH.js +1 -0
- package/dist/layers.B3ebXuRR.js +22 -0
- package/dist/layers.B4eocW2U.js +1 -0
- package/dist/layers.B7K7JjK6.js +1510 -0
- package/dist/layers.B9jC1uEF.js +9 -0
- package/dist/layers.B9vco1Tm.js +42 -0
- package/dist/layers.BAdbzzKU.js +11 -0
- package/dist/layers.BAtv1CM7.js +1 -0
- package/dist/layers.BAxiKghG.js +65 -0
- package/dist/layers.BCmyFF5n.js +8 -0
- package/dist/layers.BDlIrLZ6.js +40 -0
- package/dist/layers.BE1X7OZN.js +9 -0
- package/dist/layers.BE5c8LWk.js +4 -0
- package/dist/layers.BEXIxuBF.js +10 -0
- package/dist/layers.BFRwalLF.js +39 -0
- package/dist/layers.BFl0k28S.js +6 -0
- package/dist/layers.BGNKNfpx.js +1225 -0
- package/dist/layers.BHGjfW2R.js +907 -0
- package/dist/layers.BHstW68e.js +2238 -0
- package/dist/layers.BIeVwYKL.js +1 -0
- package/dist/layers.BJDrjORS.js +244 -0
- package/dist/layers.BKqs5g_B.js +51 -0
- package/dist/layers.BKutBTDw.js +41 -0
- package/dist/layers.BLa-XNid.js +84 -0
- package/dist/layers.BLd2spTm.js +1 -0
- package/dist/layers.BLqn32Nb.js +41 -0
- package/dist/layers.BM2O77Wh.js +425 -0
- package/dist/layers.BOm3l9Y2.js +8 -0
- package/dist/layers.BPwJ27pe.js +1268 -0
- package/dist/layers.BRWktvhi.js +7 -0
- package/dist/layers.BRbQRhez.js +9 -0
- package/dist/layers.BSTBZrFn.js +1 -0
- package/dist/{layers.NW1lST7i.js → layers.BSgSDW2J.js} +1 -1
- package/dist/layers.BTYE7zXl.js +32 -0
- package/dist/layers.BW7u2_1T.js +772 -0
- package/dist/layers.BXVqLjUh.js +1126 -0
- package/dist/layers.BXwHF1c0.js +1 -0
- package/dist/layers.BYA27mAA.js +10 -0
- package/dist/layers.BZO72u-D.js +1 -0
- package/dist/layers.BZbUfGYp.js +6 -0
- package/dist/layers.BbCfEXyj.js +55 -0
- package/dist/layers.BdBmAIrs.js +76 -0
- package/dist/layers.BeIBKBJG.js +11 -0
- package/dist/layers.BjauJJl_.js +42 -0
- package/dist/layers.Bkv-oShk.js +39 -0
- package/dist/layers.Bl4j3Wpr.js +10 -0
- package/dist/layers.Bm3vF-Ge.js +10 -0
- package/dist/layers.Bp-6Ampr.js +7 -0
- package/dist/layers.Bp180gHt.js +2966 -0
- package/dist/layers.Bp2T5L9r.js +21620 -0
- package/dist/layers.BpilXLfW.js +6 -0
- package/dist/{layers.Cfvta__C.js → layers.BrFRnEbi.js} +1 -1
- package/dist/layers.BsoRVzDP.js +806 -0
- package/dist/layers.BtPwy6-y.js +10 -0
- package/dist/layers.BtYjjZLM.js +38 -0
- package/dist/layers.BvhD2Hex.js +41 -0
- package/dist/layers.By9AhVvm.js +42 -0
- package/dist/layers.Bz2bAm_o.js +32 -0
- package/dist/layers.C-9tvKsH.js +2 -0
- package/dist/layers.C239vlHa.js +1583 -0
- package/dist/layers.C4DDZaZs.js +36 -0
- package/dist/layers.C5kfbdNQ.js +796 -0
- package/dist/layers.C8_lu5UH.js +23 -0
- package/dist/layers.CAo4nRSe.js +37 -0
- package/dist/layers.CCNu5Rkf.js +1 -0
- package/dist/layers.CCqA6oPh.js +5 -0
- package/dist/layers.CFKLwcKm.js +5 -0
- package/dist/layers.CFSawE7c.js +8 -0
- package/dist/layers.CFs5s8T3.js +52 -0
- package/dist/layers.CGoSj1av.js +1286 -0
- package/dist/layers.CH7sIJoO.js +37 -0
- package/dist/layers.CHZsXQcr.js +1 -0
- package/dist/layers.CI9mIisM.js +257 -0
- package/dist/layers.CJFGEsgQ.js +40 -0
- package/dist/layers.CJb1-QAi.js +7 -0
- package/dist/layers.CKTftm3f.js +2 -0
- package/dist/layers.CM9U_WY6.js +304 -0
- package/dist/layers.CMiTJnad.js +8 -0
- package/dist/layers.CNfAcY6Y.js +1 -0
- package/dist/layers.COeBHfJh.js +1 -0
- package/dist/layers.CPkIaDFg.js +39 -0
- package/dist/layers.CRYQyJW8.js +39 -0
- package/dist/layers.CRxZsox1.js +1 -0
- package/dist/layers.CTAkgg4R.js +1619 -0
- package/dist/layers.CU6rRFWz.js +1 -0
- package/dist/layers.CUuGcjpi.js +32 -0
- package/dist/layers.CVuk5gp9.js +84 -0
- package/dist/layers.CW3RPoeB.js +1089 -0
- package/dist/layers.CX1TPIiJ.js +805 -0
- package/dist/layers.CXmM9Bvj.js +10 -0
- package/dist/layers.CYHiWIYN.js +373 -0
- package/dist/layers.CZpHZoB0.js +9 -0
- package/dist/layers.C_8cg569.js +8 -0
- package/dist/layers.C_H8CF1f.js +44 -0
- package/dist/layers.C_IvrzZ3.js +7 -0
- package/dist/layers.C_Z4dR-0.js +39 -0
- package/dist/layers.C_poBEYa.js +10 -0
- package/dist/layers.CaPMI1KH.js +139 -0
- package/dist/layers.CbWg4Qj_.js +1 -0
- package/dist/layers.CcZMrh49.js +41 -0
- package/dist/layers.CefLOoC8.js +10 -0
- package/dist/layers.CfGk77zR.js +1 -0
- package/dist/layers.CitJ-LcP.js +1 -0
- package/dist/layers.Ckdux2po.js +48149 -0
- package/dist/layers.Cl2CJFNx.js +35 -0
- package/dist/layers.ClLKdjmI.js +39 -0
- package/dist/layers.ClVfKZ9h.js +1 -0
- package/dist/layers.CmF7I89w.js +32 -0
- package/dist/layers.Cn30_EV4.js +14 -0
- package/dist/layers.CnmwOTKT.js +295 -0
- package/dist/layers.CqHFUbCh.js +122 -0
- package/dist/layers.CqVTtuYm.js +6 -0
- package/dist/layers.Ct7Z5o-U.js +7 -0
- package/dist/layers.CtAhktPZ.js +1 -0
- package/dist/layers.Ctocb96g.js +1 -0
- package/dist/layers.Cu_3bkpd.js +207 -0
- package/dist/layers.CvFNr8Uu.js +61 -0
- package/dist/layers.Cye7d0Ye.js +35 -0
- package/dist/layers.Cyzu9PKQ.js +1 -0
- package/dist/layers.CzBOl45X.js +5 -0
- package/dist/layers.CzP0RBWK.js +139 -0
- package/dist/layers.D0dYIayl.js +1 -0
- package/dist/layers.D0zn4_Mx.js +1 -0
- package/dist/layers.D4T8fTcj.js +1223 -0
- package/dist/layers.D5T2vOzx.js +223 -0
- package/dist/layers.D5n5uB-V.js +35 -0
- package/dist/layers.D6CzgZCn.js +6 -0
- package/dist/layers.D7jGxypv.js +8 -0
- package/dist/layers.D8gdqeYc.js +213 -0
- package/dist/layers.D9Q1WK3D.js +32 -0
- package/dist/layers.DBYWjvtj.js +8 -0
- package/dist/layers.DBmtL6ZZ.js +41 -0
- package/dist/layers.DEjh8HqA.js +32 -0
- package/dist/layers.DHWPE8JP.js +37 -0
- package/dist/layers.DHoGHrwb.js +437 -0
- package/dist/layers.DIa1shbs.js +9 -0
- package/dist/{layers.Hq0pIRX3.js → layers.DIhuprWj.js} +21 -21
- package/dist/layers.DJ64BwjI.js +5 -0
- package/dist/layers.DJYCnlhb.js +40 -0
- package/dist/layers.DJuBjYUv.js +1 -0
- package/dist/layers.DL2VBsfE.js +2 -0
- package/dist/layers.DL3G4Rrb.js +41 -0
- package/dist/layers.DLwuMfdd.js +84 -0
- package/dist/layers.DMQHD7SZ.js +1 -0
- package/dist/layers.DMkBISW1.js +1 -0
- package/dist/layers.DN9HoVxI.js +18 -0
- package/dist/layers.DOq-L3gG.js +40 -0
- package/dist/layers.DOrgOHBr.js +1 -0
- package/dist/layers.DQ3x1v0k.js +934 -0
- package/dist/layers.DQD1IQ6W.js +1034 -0
- package/dist/layers.DR3nuNQY.js +271 -0
- package/dist/layers.DSMzl4c7.js +160 -0
- package/dist/layers.DSXwzG0l.js +7 -0
- package/dist/layers.DUGRqDUB.js +8583 -0
- package/dist/layers.DUWcbGsB.js +2482 -0
- package/dist/layers.DXWOVogE.js +40 -0
- package/dist/layers.DbRchKwe.js +8 -0
- package/dist/layers.DbaKVP5e.js +1 -0
- package/dist/layers.DcGOrQq5.js +39 -0
- package/dist/layers.Df7-26ey.js +189 -0
- package/dist/layers.Dfl1_GY-.js +40 -0
- package/dist/layers.DhkSgCGH.js +36 -0
- package/dist/layers.DhlqqsI-.js +9 -0
- package/dist/layers.DiHUvl0o.js +423 -0
- package/dist/layers.Dj-z0EfD.js +5 -0
- package/dist/layers.DjUOC4st.js +16 -0
- package/dist/layers.DjzsPlhY.js +70 -0
- package/dist/layers.DnNdcruU.js +9 -0
- package/dist/layers.DnRoER-T.js +11 -0
- package/dist/layers.DngDRzM2.js +10 -0
- package/dist/layers.Dop4IJqp.js +7 -0
- package/dist/layers.Dpw_9ymJ.js +34 -0
- package/dist/layers.DqkMTScX.js +40 -0
- package/dist/layers.Ds-YCD3f.js +38 -0
- package/dist/layers.DsQYlSSa.js +40 -0
- package/dist/layers.DsjBnsF_.js +42 -0
- package/dist/layers.Dsyqs-lC.js +11 -0
- package/dist/layers.DtEAEu5Y.js +1 -0
- package/dist/layers.DvEpZu0k.js +794 -0
- package/dist/layers.DwKuuHvW.js +4 -0
- package/dist/layers.DwrUaEvN.js +13 -0
- package/dist/layers.DxA6ocdw.js +70 -0
- package/dist/layers.Dy1naDTQ.js +14 -0
- package/dist/layers.E-_P3Hgt.js +4 -0
- package/dist/layers.E2Pg6Xkc.js +3 -0
- package/dist/{layers.B88sQYuh.js → layers.G1XGzBxR.js} +1 -1
- package/dist/layers.JWCLFILJ.js +1 -0
- package/dist/layers.KFn2whtk.js +9 -0
- package/dist/layers.LiJvf-Xh.js +11 -0
- package/dist/layers.OxWb2lcf.js +9 -0
- package/dist/layers.QOZfLJOU.js +205 -0
- package/dist/layers.R3a4GOcm.js +39 -0
- package/dist/layers.R8OXBVYp.js +1 -0
- package/dist/layers.R8mPlCA0.js +261 -0
- package/dist/layers.RZvZoVxE.js +9 -0
- package/dist/layers.SdU27KL4.js +42 -0
- package/dist/layers.Umldr18w.js +198 -0
- package/dist/layers.Upsmcdyi.js +33 -0
- package/dist/layers._beiaL7T.js +1 -0
- package/dist/layers._d6q9aen.js +10 -0
- package/dist/layers.a_6-TFT0.js +6 -0
- package/dist/layers.b0h5ZBmD.js +61 -0
- package/dist/{layers.CsQlovyR.js → layers.b9B2NY7n.js} +1950 -2191
- package/dist/layers.bdZaUQNB.js +41 -0
- package/dist/layers.fCcqSwty.js +8 -0
- package/dist/layers.fldW-Ogr.js +30328 -0
- package/dist/layers.i2bcEL4B.js +41 -0
- package/dist/layers.iSx5HVBW.js +37 -0
- package/dist/layers.lCpg7dOn.js +21 -0
- package/dist/layers.lY3SrA49.js +6 -0
- package/dist/layers.lgAtpBQI.js +7 -0
- package/dist/layers.my0yWZmR.js +8 -0
- package/dist/layers.n5OStkpA.js +1088 -0
- package/dist/layers.orP2yP91.js +96 -0
- package/dist/layers.ovEMwqYP.js +36 -0
- package/dist/layers.q8HcJw1z.js +8 -0
- package/dist/layers.qaJdLFHI.js +118 -0
- package/dist/layers.rUzSMgAT.js +6 -0
- package/dist/layers.rddzpnjy.js +323 -0
- package/dist/layers.sHJHq9SR.js +1 -0
- package/dist/layers.tjc2yfO8.js +36 -0
- package/dist/layers.vO27jqdn.js +4 -0
- package/dist/layers.yZYCg_En.js +960 -0
- package/dist/layers.zF6RU9h5.js +1 -0
- package/package.json +13 -7
- package/dist/layers.BgMykHnn.js +0 -154
- package/dist/layers.BtvuN20E.js +0 -27618
- package/dist/layers.Ct1ojjl3.js +0 -1
- package/dist/layers.JT_kEFH5.js +0 -129
- package/dist/layers.pwc3O6Es.js +0 -261
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const D=require("./layers.DOrgOHBr.js"),n=require("./layers.orP2yP91.js");function b(o){return o.innerRadius}function k(o){return o.outerRadius}function _(o){return o.startAngle}function nn(o){return o.endAngle}function en(o){return o&&o.padAngle}function an(o,x,E,P,h,v,j,i){var I=E-o,t=P-x,e=j-h,y=i-v,s=y*I-e*t;if(!(s*s<n.epsilon))return s=(e*(x-v)-y*(o-h))/s,[o+s*I,x+s*t]}function M(o,x,E,P,h,v,j){var i=o-E,I=x-P,t=(j?v:-v)/n.sqrt(i*i+I*I),e=t*I,y=-t*i,s=o+e,u=x+y,c=E+e,f=P+y,z=(s+c)/2,l=(u+f)/2,g=c-s,p=f-u,A=g*g+p*p,R=h-v,T=s*f-c*u,O=(p<0?-1:1)*n.sqrt(n.max(0,R*R*A-T*T)),S=(T*p-g*O)/A,$=(-T*g-p*O)/A,q=(T*p+g*O)/A,m=(-T*g+p*O)/A,d=S-z,a=$-l,r=q-z,B=m-l;return d*d+a*a>r*r+B*B&&(S=q,$=m),{cx:S,cy:$,x01:-e,y01:-y,x11:S*(h/R-1),y11:$*(h/R-1)}}function sn(){var o=b,x=k,E=D.constant(0),P=null,h=_,v=nn,j=en,i=null,I=D.withPath(t);function t(){var e,y,s=+o.apply(this,arguments),u=+x.apply(this,arguments),c=h.apply(this,arguments)-n.halfPi,f=v.apply(this,arguments)-n.halfPi,z=n.abs(f-c),l=f>c;if(i||(i=e=I()),u<s&&(y=u,u=s,s=y),!(u>n.epsilon))i.moveTo(0,0);else if(z>n.tau-n.epsilon)i.moveTo(u*n.cos(c),u*n.sin(c)),i.arc(0,0,u,c,f,!l),s>n.epsilon&&(i.moveTo(s*n.cos(f),s*n.sin(f)),i.arc(0,0,s,f,c,l));else{var g=c,p=f,A=c,R=f,T=z,O=z,S=j.apply(this,arguments)/2,$=S>n.epsilon&&(P?+P.apply(this,arguments):n.sqrt(s*s+u*u)),q=n.min(n.abs(u-s)/2,+E.apply(this,arguments)),m=q,d=q,a,r;if($>n.epsilon){var B=n.asin($/s*n.sin(S)),G=n.asin($/u*n.sin(S));(T-=B*2)>n.epsilon?(B*=l?1:-1,A+=B,R-=B):(T=0,A=R=(c+f)/2),(O-=G*2)>n.epsilon?(G*=l?1:-1,g+=G,p-=G):(O=0,g=p=(c+f)/2)}var C=u*n.cos(g),F=u*n.sin(g),H=s*n.cos(R),J=s*n.sin(R);if(q>n.epsilon){var K=u*n.cos(p),L=u*n.sin(p),N=s*n.cos(A),Q=s*n.sin(A),w;if(z<n.pi)if(w=an(C,F,N,Q,K,L,H,J)){var U=C-w[0],V=F-w[1],W=K-w[0],X=L-w[1],Y=1/n.sin(n.acos((U*W+V*X)/(n.sqrt(U*U+V*V)*n.sqrt(W*W+X*X)))/2),Z=n.sqrt(w[0]*w[0]+w[1]*w[1]);m=n.min(q,(s-Z)/(Y-1)),d=n.min(q,(u-Z)/(Y+1))}else m=d=0}O>n.epsilon?d>n.epsilon?(a=M(N,Q,C,F,u,d,l),r=M(K,L,H,J,u,d,l),i.moveTo(a.cx+a.x01,a.cy+a.y01),d<q?i.arc(a.cx,a.cy,d,n.atan2(a.y01,a.x01),n.atan2(r.y01,r.x01),!l):(i.arc(a.cx,a.cy,d,n.atan2(a.y01,a.x01),n.atan2(a.y11,a.x11),!l),i.arc(0,0,u,n.atan2(a.cy+a.y11,a.cx+a.x11),n.atan2(r.cy+r.y11,r.cx+r.x11),!l),i.arc(r.cx,r.cy,d,n.atan2(r.y11,r.x11),n.atan2(r.y01,r.x01),!l))):(i.moveTo(C,F),i.arc(0,0,u,g,p,!l)):i.moveTo(C,F),!(s>n.epsilon)||!(T>n.epsilon)?i.lineTo(H,J):m>n.epsilon?(a=M(H,J,K,L,s,-m,l),r=M(C,F,N,Q,s,-m,l),i.lineTo(a.cx+a.x01,a.cy+a.y01),m<q?i.arc(a.cx,a.cy,m,n.atan2(a.y01,a.x01),n.atan2(r.y01,r.x01),!l):(i.arc(a.cx,a.cy,m,n.atan2(a.y01,a.x01),n.atan2(a.y11,a.x11),!l),i.arc(0,0,s,n.atan2(a.cy+a.y11,a.cx+a.x11),n.atan2(r.cy+r.y11,r.cx+r.x11),l),i.arc(r.cx,r.cy,m,n.atan2(r.y11,r.x11),n.atan2(r.y01,r.x01),!l))):i.arc(0,0,s,R,A,l)}if(i.closePath(),e)return i=null,e+""||null}return t.centroid=function(){var e=(+o.apply(this,arguments)+ +x.apply(this,arguments))/2,y=(+h.apply(this,arguments)+ +v.apply(this,arguments))/2-n.pi/2;return[n.cos(y)*e,n.sin(y)*e]},t.innerRadius=function(e){return arguments.length?(o=typeof e=="function"?e:D.constant(+e),t):o},t.outerRadius=function(e){return arguments.length?(x=typeof e=="function"?e:D.constant(+e),t):x},t.cornerRadius=function(e){return arguments.length?(E=typeof e=="function"?e:D.constant(+e),t):E},t.padRadius=function(e){return arguments.length?(P=e==null?null:typeof e=="function"?e:D.constant(+e),t):P},t.startAngle=function(e){return arguments.length?(h=typeof e=="function"?e:D.constant(+e),t):h},t.endAngle=function(e){return arguments.length?(v=typeof e=="function"?e:D.constant(+e),t):v},t.padAngle=function(e){return arguments.length?(j=typeof e=="function"?e:D.constant(+e),t):j},t.context=function(e){return arguments.length?(i=e??null,t):i},t}exports.arc=sn;
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@layers-app/editor",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "0.7.
|
|
4
|
+
"version": "0.7.48",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"scripts": {
|
|
7
|
-
"start": "
|
|
7
|
+
"start": "VITE_LAYERS=true vite --mode full ",
|
|
8
8
|
"start:specific": "VITE_LAYERS=false vite --mode full ",
|
|
9
|
-
"build": "
|
|
9
|
+
"build": "VITE_LAYERS=true vite build",
|
|
10
10
|
"build:specific": "VITE_LAYERS=false vite build",
|
|
11
11
|
"lint": "eslint . --ext .ts,.tsx",
|
|
12
12
|
"lint:fix": "eslint . --ext .ts,.tsx --fix",
|
|
@@ -14,13 +14,18 @@
|
|
|
14
14
|
"generate-dts": "tsc --project tsconfig.lib.json",
|
|
15
15
|
"dev:local": "cross-env NODE_ENV=development concurrently \"npm:server:ws\" \"vite --host\"",
|
|
16
16
|
"server:ws": "concurrently \"cd server && npm start\"",
|
|
17
|
+
"server:smart-paste": "cd server && npm start",
|
|
18
|
+
"dev:full": "concurrently \"npm run start\" \"npm run server:smart-paste\"",
|
|
17
19
|
"format": "prettier --write .",
|
|
18
20
|
"format:check": "prettier --check .",
|
|
19
21
|
"test:e2e": "playwright test",
|
|
20
22
|
"test:e2e:ui": "playwright test --ui",
|
|
21
23
|
"test:e2e:debug": "playwright test --debug",
|
|
22
24
|
"test:e2e:headed": "playwright test --headed",
|
|
23
|
-
"start-test-server": "VITE_LAYERS=true vite --mode full --port 3000 --strictPort --host localhost"
|
|
25
|
+
"start-test-server": "VITE_LAYERS=true vite --mode full --port 3000 --strictPort --host localhost",
|
|
26
|
+
"test": "vitest run",
|
|
27
|
+
"test:watch": "vitest",
|
|
28
|
+
"test:coverage": "vitest run --coverage"
|
|
24
29
|
},
|
|
25
30
|
"publishConfig": {
|
|
26
31
|
"access": "public"
|
|
@@ -33,7 +38,7 @@
|
|
|
33
38
|
"dependencies": {
|
|
34
39
|
"@excalidraw/excalidraw": "^0.18.0",
|
|
35
40
|
"@floating-ui/react": "^0.27.16",
|
|
36
|
-
"@layers-app/editor-video": "^0.1.
|
|
41
|
+
"@layers-app/editor-video": "^0.1.5",
|
|
37
42
|
"@lexical/file": "^0.38.2",
|
|
38
43
|
"@lexical/headless": "^0.38.2",
|
|
39
44
|
"@lexical/markdown": "^0.38.2",
|
|
@@ -48,7 +53,7 @@
|
|
|
48
53
|
"@eslint/js": "^9.9.0",
|
|
49
54
|
"@hugeicons/core-free-icons": "^2.0.0",
|
|
50
55
|
"@hugeicons/react": "^1.1.1",
|
|
51
|
-
"@layers-app/shared": "^0.2.
|
|
56
|
+
"@layers-app/shared": "^0.2.7",
|
|
52
57
|
"@mantine/core": "8.3.5",
|
|
53
58
|
"@mantine/dropzone": "8.3.5",
|
|
54
59
|
"@mantine/form": "8.3.5",
|
|
@@ -99,7 +104,8 @@
|
|
|
99
104
|
"vite-plugin-css-injected-by-js": "^3.5.0",
|
|
100
105
|
"vite-plugin-dts": "^4.0.0-beta.1",
|
|
101
106
|
"vite-plugin-static-copy": "^2.3.2",
|
|
102
|
-
"vite-plugin-svgr": "^4.2.0"
|
|
107
|
+
"vite-plugin-svgr": "^4.2.0",
|
|
108
|
+
"vitest": "^4.0.18"
|
|
103
109
|
},
|
|
104
110
|
"overrides": {
|
|
105
111
|
"nanoid": "^5.0.9",
|
package/dist/layers.BgMykHnn.js
DELETED
|
@@ -1,154 +0,0 @@
|
|
|
1
|
-
import { jsxs as h, jsx as e } from "react/jsx-runtime";
|
|
2
|
-
import { useState as i, useEffect as O, useMemo as U, Component as B } from "react";
|
|
3
|
-
import { useTranslation as J } from "react-i18next";
|
|
4
|
-
import { BlockWithAlignableContents as T } from "@lexical/react/LexicalBlockWithAlignableContents";
|
|
5
|
-
import { Popover as v, Flex as j, Stack as z, Box as S, TextInput as x, Center as D, Button as M, LoadingOverlay as R } from "@mantine/core";
|
|
6
|
-
import { $getNodeByKey as b } from "lexical";
|
|
7
|
-
import { showErrorNotification as $ } from "@layers-app/shared";
|
|
8
|
-
import { f as A, g as F, E as W, h as y } from "./layers.BtvuN20E.js";
|
|
9
|
-
const q = {};
|
|
10
|
-
class G extends B {
|
|
11
|
-
render() {
|
|
12
|
-
const { getComponent: s } = this.props, l = s("operations", !0);
|
|
13
|
-
return /* @__PURE__ */ e("div", { className: "swagger-ui", children: /* @__PURE__ */ e(l, {}) });
|
|
14
|
-
}
|
|
15
|
-
}
|
|
16
|
-
const H = () => ({
|
|
17
|
-
components: {
|
|
18
|
-
OperationsLayout: G
|
|
19
|
-
}
|
|
20
|
-
}), Q = (o) => ({
|
|
21
|
-
statePlugins: {
|
|
22
|
-
spec: {
|
|
23
|
-
wrapSelectors: {
|
|
24
|
-
taggedOperations: (s) => (l, ...m) => {
|
|
25
|
-
const a = s(l, ...m);
|
|
26
|
-
return o.operation ? a.map(
|
|
27
|
-
(r) => r.update(
|
|
28
|
-
"operations",
|
|
29
|
-
(g) => g.filter((p) => p.get("operation").get("operationId") === o.operation)
|
|
30
|
-
)
|
|
31
|
-
).filter((r) => r.get("operations").size > 0) : a;
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
}), ne = ({
|
|
37
|
-
inputUrl: o,
|
|
38
|
-
inputJSON: s,
|
|
39
|
-
className: l,
|
|
40
|
-
format: m,
|
|
41
|
-
nodeKey: a,
|
|
42
|
-
editor: r,
|
|
43
|
-
create: g
|
|
44
|
-
}) => {
|
|
45
|
-
const { t: p } = J(), [w, C] = i(""), [c, N] = i(""), [V, I] = i(!1), [X, L] = i(!1), [d, u] = i(!1), [P, f] = i(!0);
|
|
46
|
-
O(() => {
|
|
47
|
-
g && u(!0);
|
|
48
|
-
}, [g]), O(() => {
|
|
49
|
-
const t = r.getRootElement();
|
|
50
|
-
d ? A(t) : F(t);
|
|
51
|
-
}, [d, r]);
|
|
52
|
-
const k = (t) => {
|
|
53
|
-
t.preventDefault(), r.update(() => {
|
|
54
|
-
const n = b(a);
|
|
55
|
-
y(n) && (u(!1), n.setSrc(w || c), n.setJSON(c));
|
|
56
|
-
});
|
|
57
|
-
}, { operation: E } = U(() => o ? {
|
|
58
|
-
operation: new URL(o).hash.split("/").pop() || ""
|
|
59
|
-
} : { operation: "" }, [o, s]);
|
|
60
|
-
return o ? /* @__PURE__ */ h(S, { pos: "relative", mih: 45, children: [
|
|
61
|
-
/* @__PURE__ */ e(
|
|
62
|
-
R,
|
|
63
|
-
{
|
|
64
|
-
visible: P,
|
|
65
|
-
zIndex: 1e3,
|
|
66
|
-
overlayProps: { blur: 4 },
|
|
67
|
-
loaderProps: { size: "xs" }
|
|
68
|
-
}
|
|
69
|
-
),
|
|
70
|
-
/* @__PURE__ */ e(
|
|
71
|
-
q,
|
|
72
|
-
{
|
|
73
|
-
url: s,
|
|
74
|
-
onComplete: () => {
|
|
75
|
-
f(!1);
|
|
76
|
-
},
|
|
77
|
-
responseInterceptor: (t) => (t.ok || (f(!1), r.update(() => {
|
|
78
|
-
const n = b(a);
|
|
79
|
-
y(n) && (u(!1), n.setSrc(""), n.setJSON(""));
|
|
80
|
-
}), $({
|
|
81
|
-
message: p("editor.validation.swaggerUnavailable")
|
|
82
|
-
}), f(!0)), t),
|
|
83
|
-
plugins: [
|
|
84
|
-
Q({ operation: E }),
|
|
85
|
-
H
|
|
86
|
-
],
|
|
87
|
-
layout: "OperationsLayout"
|
|
88
|
-
}
|
|
89
|
-
)
|
|
90
|
-
] }) : /* @__PURE__ */ h(
|
|
91
|
-
v,
|
|
92
|
-
{
|
|
93
|
-
width: 400,
|
|
94
|
-
position: "bottom",
|
|
95
|
-
shadow: "md",
|
|
96
|
-
opened: d,
|
|
97
|
-
onChange: u,
|
|
98
|
-
defaultOpened: !0,
|
|
99
|
-
withinPortal: !0,
|
|
100
|
-
children: [
|
|
101
|
-
/* @__PURE__ */ e(v.Target, { children: /* @__PURE__ */ e(j, { w: "100%", children: /* @__PURE__ */ e(
|
|
102
|
-
T,
|
|
103
|
-
{
|
|
104
|
-
className: l,
|
|
105
|
-
format: m,
|
|
106
|
-
nodeKey: a,
|
|
107
|
-
children: /* @__PURE__ */ e(
|
|
108
|
-
W,
|
|
109
|
-
{
|
|
110
|
-
title: p("editor.swagger.add"),
|
|
111
|
-
icon: "api",
|
|
112
|
-
onClick: () => u((t) => !t),
|
|
113
|
-
nodeKey: a
|
|
114
|
-
}
|
|
115
|
-
)
|
|
116
|
-
}
|
|
117
|
-
) }) }),
|
|
118
|
-
/* @__PURE__ */ e(v.Dropdown, { "aria-hidden": !d, tabIndex: d ? 0 : -1, children: /* @__PURE__ */ e("form", { onSubmit: k, children: /* @__PURE__ */ h(z, { gap: 16, children: [
|
|
119
|
-
/* @__PURE__ */ e(S, { children: /* @__PURE__ */ e(
|
|
120
|
-
x,
|
|
121
|
-
{
|
|
122
|
-
maxLength: 500,
|
|
123
|
-
placeholder: "https://api.example.com/v3/swagger.json",
|
|
124
|
-
"data-autofocus": !0,
|
|
125
|
-
type: "url",
|
|
126
|
-
value: c,
|
|
127
|
-
rightSection: c ? null : /* @__PURE__ */ e("span", { style: { color: "red" }, children: "*" }),
|
|
128
|
-
onChange: (t) => {
|
|
129
|
-
N(t.currentTarget.value), L(!1);
|
|
130
|
-
}
|
|
131
|
-
}
|
|
132
|
-
) }),
|
|
133
|
-
/* @__PURE__ */ e(S, { children: /* @__PURE__ */ e(
|
|
134
|
-
x,
|
|
135
|
-
{
|
|
136
|
-
maxLength: 500,
|
|
137
|
-
placeholder: "https://api.swagger.io/#/user/getUser",
|
|
138
|
-
"data-autofocus": !0,
|
|
139
|
-
type: "url",
|
|
140
|
-
value: w,
|
|
141
|
-
onChange: (t) => {
|
|
142
|
-
C(t.currentTarget.value), I(!1);
|
|
143
|
-
}
|
|
144
|
-
}
|
|
145
|
-
) }),
|
|
146
|
-
/* @__PURE__ */ e(D, { children: /* @__PURE__ */ e(M, { w: "100%", type: "submit", disabled: !c, children: p("editor.video.apply") }) })
|
|
147
|
-
] }) }) })
|
|
148
|
-
]
|
|
149
|
-
}
|
|
150
|
-
);
|
|
151
|
-
};
|
|
152
|
-
export {
|
|
153
|
-
ne as default
|
|
154
|
-
};
|