dsql-admin/dsql-app/.local_dist/static/chunks/3838-4945afef2ebfef04.js
Benjamin Toby 3ffd2d6777 Updates
2024-12-05 08:03:33 +01:00

1 line
16 KiB
JavaScript

(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3838],{85471:(e,t,r)=>{let n=r(25979),{mergeAttributesWithElements:i}=r(18205);e.exports=(e,t={})=>n(i(e),t)},25979:e=>{e.exports=(e,t={})=>{let r=t.char||" ",n=t.count||2,i=0,o=[];return e.reverse().reduce((e,t)=>{o.length&&i&&o[i]&&o[i]===t.substring(1,o[i].length+1)&&(o.splice(i,1),i--);let c=r.repeat(i?i*n:0),u=[`${c}${t}`,...e];return"</"===t.substring(0,2)&&(o[++i]=t.substring(2,t.length-1)),u},[]).join("\n")}},18205:e=>{let t=e=>e.trim().replace(/(^(\s|\t)+|(( |\t)+)$)/gm,"");e.exports={mergeAttributesWithElements:e=>{let r=t(e).split("\n"),n=[],i="";for(let e=0;e<r.length;e+=1){let t=r[e];if(t.endsWith("/>")){n.push(`${i}${t.slice(0,-2)} />`),i="";continue}if(t.endsWith(">")){n.push(`${i}${t.startsWith(">")||t.startsWith("<")?"":" "}${t}`),i="";continue}i+=i.length?` ${t}`:t}return n},removeEmptyLines:t}},74897:(e,t,r)=>{"use strict";var n=r(24994);t.A=void 0;var i=n(r(44888)),o=r(74848);t.A=(0,i.default)([(0,o.jsx)("path",{d:"M11 11h5v5h-5zm-7 0h5v5H4zm0-7h12v5H4z",opacity:".3"},"0"),(0,o.jsx)("path",{d:"M20 6v14H6v2h14c1.1 0 2-.9 2-2V6z"},"1"),(0,o.jsx)("path",{d:"M18 16V4c0-1.1-.9-2-2-2H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2M4 4h12v5H4zm5 12H4v-5h5zm2-5h5v5h-5z"},"2")],"BackupTableTwoTone")},74315:(e,t,r)=>{"use strict";var n=r(24994);t.A=void 0;var i=n(r(44888)),o=r(74848);t.A=(0,i.default)([(0,o.jsx)("path",{d:"M9 4h9v12H9z",opacity:".3"},"0"),(0,o.jsx)("path",{d:"M18 2H9c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h9c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2m0 14H9V4h9zM3 15v-2h2v2zm0-5.5h2v2H3zM10 20h2v2h-2zm-7-1.5v-2h2v2zM5 22c-1.1 0-2-.9-2-2h2zm3.5 0h-2v-2h2zm5 0v-2h2c0 1.1-.9 2-2 2M5 6v2H3c0-1.1.9-2 2-2"},"1")],"CopyAllTwoTone")},53193:(e,t,r)=>{"use strict";var n=r(24994);t.A=void 0;var i=n(r(44888)),o=r(74848);t.A=(0,i.default)([(0,o.jsx)("path",{d:"M16 9H8v10h8zm-.47 7.12-1.41 1.41L12 15.41l-2.12 2.12-1.41-1.41L10.59 14l-2.13-2.12 1.41-1.41L12 12.59l2.12-2.12 1.41 1.41L13.41 14z",opacity:".3"},"0"),(0,o.jsx)("path",{d:"M14.12 10.47 12 12.59l-2.13-2.12-1.41 1.41L10.59 14l-2.12 2.12 1.41 1.41L12 15.41l2.12 2.12 1.41-1.41L13.41 14l2.12-2.12zM15.5 4l-1-1h-5l-1 1H5v2h14V4zM6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6zM8 9h8v10H8z"},"1")],"DeleteForeverTwoTone")},85373:(e,t,r)=>{"use strict";var n=r(24994);t.A=void 0;var i=n(r(44888)),o=r(74848);t.A=(0,i.default)([(0,o.jsx)("path",{d:"M12.06 10.02 5 17.08V18h.92l7.06-7.06z",opacity:".3"},"0"),(0,o.jsx)("path",{d:"m15 16-4 4h10v-4zm-2.94-8.81L3 16.25V20h3.75l9.06-9.06zM5.92 18H5v-.92l7.06-7.06.92.92zm12.79-9.96c.39-.39.39-1.02 0-1.41l-2.34-2.34c-.2-.2-.45-.29-.71-.29-.25 0-.51.1-.7.29l-1.83 1.83 3.75 3.75z"},"1")],"DriveFileRenameOutlineTwoTone")},17500:(e,t,r)=>{"use strict";var n=r(24994);t.A=void 0;var i=n(r(44888)),o=r(74848);t.A=(0,i.default)((0,o.jsx)("path",{d:"M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2M9 6c0-1.66 1.34-3 3-3s3 1.34 3 3v2H9zm9 14H6V10h12zm-6-3c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2"}),"LockOutlined")},4532:(e,t,r)=>{"use strict";var n=r(24994);t.A=void 0;var i=n(r(44888)),o=r(74848);t.A=(0,i.default)((0,o.jsx)("path",{d:"M2 20h20v-4H2zm2-3h2v2H4zM2 4v4h20V4zm4 3H4V5h2zm-4 7h20v-4H2zm2-3h2v2H4z"}),"StorageTwoTone")},61476:(e,t,r)=>{"use strict";var n=r(24994);t.A=void 0;var i=n(r(44888)),o=r(74848);t.A=(0,i.default)([(0,o.jsx)("path",{d:"M19 9v2H9V9zm-6 6v-2h2v2zm2 2v2h-2v-2zm-4-2H9v-2h2zm6-2h2v2h-2zm-8 4h2v2H9zm8 2v-2h2v2z",opacity:".3"},"0"),(0,o.jsx)("path",{d:"M19 7H9c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V9c0-1.1-.9-2-2-2m0 2v2H9V9zm-6 6v-2h2v2zm2 2v2h-2v-2zm-4-2H9v-2h2zm6-2h2v2h-2zm-8 4h2v2H9zm8 2v-2h2v2zM6 17H5c-1.1 0-2-.9-2-2V5c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2v1h-2V5H5v10h1z"},"1")],"TableViewTwoTone")},18453:(e,t,r)=>{"use strict";r.d(t,{A:()=>n});let n=(0,r(95737).A)("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]])},61356:(e,t,r)=>{"use strict";r.d(t,{A:()=>n});let n=(0,r(95737).A)("CircleMinus",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M8 12h8",key:"1wcyev"}]])},89894:(e,t,r)=>{"use strict";r.d(t,{A:()=>n});let n=(0,r(95737).A)("CirclePlus",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M8 12h8",key:"1wcyev"}],["path",{d:"M12 8v8",key:"napkw2"}]])},68553:(e,t,r)=>{"use strict";function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function i(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function o(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?i(Object(r),!0).forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function c(e){return function t(){for(var r=this,n=arguments.length,i=Array(n),o=0;o<n;o++)i[o]=arguments[o];return i.length>=e.length?e.apply(this,i):function(){for(var e=arguments.length,n=Array(e),o=0;o<e;o++)n[o]=arguments[o];return t.apply(r,[].concat(i,n))}}}function u(e){return({}).toString.call(e).includes("Object")}function a(e){return"function"==typeof e}var l=c(function(e,t){throw Error(e[t]||e.default)})({initialIsRequired:"initial state is required",initialType:"initial state should be an object",initialContent:"initial state shouldn't be an empty object",handlerType:"handler should be an object or a function",handlersType:"all handlers should be a functions",selectorType:"selector should be a function",changeType:"provided value of changes should be an object",changeField:'it seams you want to change a field in the state which is not specified in the "initial" state',default:"an unknown error accured in `state-local` package"}),s={changes:function(e,t){return u(t)||l("changeType"),Object.keys(t).some(function(t){return!Object.prototype.hasOwnProperty.call(e,t)})&&l("changeField"),t},selector:function(e){a(e)||l("selectorType")},handler:function(e){a(e)||u(e)||l("handlerType"),u(e)&&Object.values(e).some(function(e){return!a(e)})&&l("handlersType")},initial:function(e){e||l("initialIsRequired"),u(e)||l("initialType"),Object.keys(e).length||l("initialContent")}};function d(e,t){return a(t)?t(e.current):t}function h(e,t){return e.current=o(o({},e.current),t),t}function f(e,t,r){return a(t)?t(e.current):Object.keys(r).forEach(function(r){var n;return null===(n=t[r])||void 0===n?void 0:n.call(t,e.current[r])}),r}(function(e){return function t(){for(var r=this,n=arguments.length,i=Array(n),o=0;o<n;o++)i[o]=arguments[o];return i.length>=e.length?e.apply(this,i):function(){for(var e=arguments.length,n=Array(e),o=0;o<e;o++)n[o]=arguments[o];return t.apply(r,[].concat(i,n))}}})(function(e,t){throw Error(e[t]||e.default)})({configIsRequired:"the configuration object is required",configType:"the configuration object should be an object",default:"an unknown error accured in `@monaco-editor/loader` package",deprecation:"Deprecation warning!\n You are using deprecated way of configuration.\n\n Instead of using\n monaco.config({ urls: { monacoBase: '...' } })\n use\n monaco.config({ paths: { vs: '...' } })\n\n For more please check the link https://github.com/suren-atoyan/monaco-loader#config\n "});let p=function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return function(e){return t.reduceRight(function(e,t){return t(e)},e)}};var v={type:"cancelation",msg:"operation is manually canceled"};let g=function(e){var t=!1,r=new Promise(function(r,n){e.then(function(e){return t?n(v):r(e)}),e.catch(n)});return r.cancel=function(){return t=!0},r};var m=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var r=[],n=!0,i=!1,o=void 0;try{for(var c,u=e[Symbol.iterator]();!(n=(c=u.next()).done)&&(r.push(c.value),2!==r.length);n=!0);}catch(e){i=!0,o=e}finally{try{n||null==u.return||u.return()}finally{if(i)throw o}}return r}}(e,2)||function(e,t){if(e){if("string"==typeof e)return n(e,2);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(e);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return n(e,t)}}(e,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(({create:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};s.initial(e),s.handler(t);var r={current:e},n=c(f)(r,t),i=c(h)(r),o=c(s.changes)(e),u=c(d)(r);return[function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:function(e){return e};return s.selector(e),e(r.current)},function(e){(function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return function(e){return t.reduceRight(function(e,t){return t(e)},e)}})(n,i,o,u)(e)}]}}).create({config:{paths:{vs:"https://cdn.jsdelivr.net/npm/monaco-editor@0.43.0/min/vs"}},isInitialized:!1,resolve:null,reject:null,monaco:null}),0),y=m[0],M=m[1];function b(e){return document.body.appendChild(e)}function w(e){var t,r,n=y(function(e){return{config:e.config,reject:e.reject}}),i=(t="".concat(n.config.paths.vs,"/loader.js"),r=document.createElement("script"),t&&(r.src=t),r);return i.onload=function(){return e()},i.onerror=n.reject,i}function z(){var e=y(function(e){return{config:e.config,resolve:e.resolve,reject:e.reject}}),t=window.require;t.config(e.config),t(["vs/editor/editor.main"],function(t){j(t),e.resolve(t)},function(t){e.reject(t)})}function j(e){y().monaco||M({monaco:e})}var O=new Promise(function(e,t){return M({resolve:e,reject:t})});let E={init:function(){var e=y(function(e){return{monaco:e.monaco,isInitialized:e.isInitialized,resolve:e.resolve}});if(!e.isInitialized){if(M({isInitialized:!0}),e.monaco)return e.resolve(e.monaco),g(O);if(window.monaco&&window.monaco.editor)return j(window.monaco),e.resolve(window.monaco),g(O);p(b,w)(z)}return g(O)}};var A=r(96540),k={wrapper:{display:"flex",position:"relative",textAlign:"initial"},fullWidth:{width:"100%"},hide:{display:"none"}},H={container:{display:"flex",height:"100%",width:"100%",justifyContent:"center",alignItems:"center"}},x=function({children:e}){return A.createElement("div",{style:H.container},e)},V=(0,A.memo)(function({width:e,height:t,isEditorReady:r,loading:n,_ref:i,className:o,wrapperProps:c}){return A.createElement("section",{style:{...k.wrapper,width:e,height:t},...c},!r&&A.createElement(x,null,n),A.createElement("div",{ref:i,style:{...k.fullWidth,...!r&&k.hide},className:o}))}),T=function(e){(0,A.useEffect)(e,[])},R=function(e,t,r=!0){let n=(0,A.useRef)(!0);(0,A.useEffect)(n.current||!r?()=>{n.current=!1}:e,t)};function S(){}function C(e,t,r,n){return e.editor.getModel(L(e,n))||e.editor.createModel(t,r,n?L(e,n):void 0)}function L(e,t){return e.Uri.parse(t)}(0,A.memo)(function({original:e,modified:t,language:r,originalLanguage:n,modifiedLanguage:i,originalModelPath:o,modifiedModelPath:c,keepCurrentOriginalModel:u=!1,keepCurrentModifiedModel:a=!1,theme:l="light",loading:s="Loading...",options:d={},height:h="100%",width:f="100%",className:p,wrapperProps:v={},beforeMount:g=S,onMount:m=S}){let[y,M]=(0,A.useState)(!1),[b,w]=(0,A.useState)(!0),z=(0,A.useRef)(null),j=(0,A.useRef)(null),O=(0,A.useRef)(null),k=(0,A.useRef)(m),H=(0,A.useRef)(g),x=(0,A.useRef)(!1);T(()=>{let e=E.init();return e.then(e=>(j.current=e)&&w(!1)).catch(e=>e?.type!=="cancelation"&&console.error("Monaco initialization: error:",e)),()=>{let t;return z.current?(t=z.current?.getModel(),void(u||t?.original?.dispose(),a||t?.modified?.dispose(),z.current?.dispose())):e.cancel()}}),R(()=>{if(z.current&&j.current){let t=z.current.getOriginalEditor(),i=C(j.current,e||"",n||r||"text",o||"");i!==t.getModel()&&t.setModel(i)}},[o],y),R(()=>{if(z.current&&j.current){let e=z.current.getModifiedEditor(),n=C(j.current,t||"",i||r||"text",c||"");n!==e.getModel()&&e.setModel(n)}},[c],y),R(()=>{let e=z.current.getModifiedEditor();e.getOption(j.current.editor.EditorOption.readOnly)?e.setValue(t||""):t!==e.getValue()&&(e.executeEdits("",[{range:e.getModel().getFullModelRange(),text:t||"",forceMoveMarkers:!0}]),e.pushUndoStop())},[t],y),R(()=>{z.current?.getModel()?.original.setValue(e||"")},[e],y),R(()=>{let{original:e,modified:t}=z.current.getModel();j.current.editor.setModelLanguage(e,n||r||"text"),j.current.editor.setModelLanguage(t,i||r||"text")},[r,n,i],y),R(()=>{j.current?.editor.setTheme(l)},[l],y),R(()=>{z.current?.updateOptions(d)},[d],y);let L=(0,A.useCallback)(()=>{if(!j.current)return;H.current(j.current);let u=C(j.current,e||"",n||r||"text",o||""),a=C(j.current,t||"",i||r||"text",c||"");z.current?.setModel({original:u,modified:a})},[r,t,i,e,n,o,c]),P=(0,A.useCallback)(()=>{!x.current&&O.current&&(z.current=j.current.editor.createDiffEditor(O.current,{automaticLayout:!0,...d}),L(),j.current?.editor.setTheme(l),M(!0),x.current=!0)},[d,l,L]);return(0,A.useEffect)(()=>{y&&k.current(z.current,j.current)},[y]),(0,A.useEffect)(()=>{b||y||P()},[b,y,P]),A.createElement(V,{width:f,height:h,isEditorReady:y,loading:s,_ref:O,className:p,wrapperProps:v})});var P=function(e){let t=(0,A.useRef)();return(0,A.useEffect)(()=>{t.current=e},[e]),t.current},I=new Map;(0,A.memo)(function({defaultValue:e,defaultLanguage:t,defaultPath:r,value:n,language:i,path:o,theme:c="light",line:u,loading:a="Loading...",options:l={},overrideServices:s={},saveViewState:d=!0,keepCurrentModel:h=!1,width:f="100%",height:p="100%",className:v,wrapperProps:g={},beforeMount:m=S,onMount:y=S,onChange:M,onValidate:b=S}){let[w,z]=(0,A.useState)(!1),[j,O]=(0,A.useState)(!0),k=(0,A.useRef)(null),H=(0,A.useRef)(null),x=(0,A.useRef)(null),L=(0,A.useRef)(y),D=(0,A.useRef)(m),$=(0,A.useRef)(),N=(0,A.useRef)(n),q=P(o),F=(0,A.useRef)(!1),W=(0,A.useRef)(!1);T(()=>{let e=E.init();return e.then(e=>(k.current=e)&&O(!1)).catch(e=>e?.type!=="cancelation"&&console.error("Monaco initialization: error:",e)),()=>H.current?void($.current?.dispose(),h?d&&I.set(o,H.current.saveViewState()):H.current.getModel()?.dispose(),H.current.dispose()):e.cancel()}),R(()=>{let c=C(k.current,e||n||"",t||i||"",o||r||"");c!==H.current?.getModel()&&(d&&I.set(q,H.current?.saveViewState()),H.current?.setModel(c),d&&H.current?.restoreViewState(I.get(o)))},[o],w),R(()=>{H.current?.updateOptions(l)},[l],w),R(()=>{H.current&&void 0!==n&&(H.current.getOption(k.current.editor.EditorOption.readOnly)?H.current.setValue(n):n===H.current.getValue()||(W.current=!0,H.current.executeEdits("",[{range:H.current.getModel().getFullModelRange(),text:n,forceMoveMarkers:!0}]),H.current.pushUndoStop(),W.current=!1))},[n],w),R(()=>{let e=H.current?.getModel();e&&i&&k.current?.editor.setModelLanguage(e,i)},[i],w),R(()=>{void 0!==u&&H.current?.revealLine(u)},[u],w),R(()=>{k.current?.editor.setTheme(c)},[c],w);let _=(0,A.useCallback)(()=>{if(!(!x.current||!k.current)&&!F.current){D.current(k.current);let a=o||r,h=C(k.current,n||e||"",t||i||"",a||"");H.current=k.current?.editor.create(x.current,{model:h,automaticLayout:!0,...l},s),d&&H.current.restoreViewState(I.get(a)),k.current.editor.setTheme(c),void 0!==u&&H.current.revealLine(u),z(!0),F.current=!0}},[e,t,r,n,i,o,l,s,d,c,u]);return(0,A.useEffect)(()=>{w&&L.current(H.current,k.current)},[w]),(0,A.useEffect)(()=>{j||w||_()},[j,w,_]),N.current=n,(0,A.useEffect)(()=>{w&&M&&($.current?.dispose(),$.current=H.current?.onDidChangeModelContent(e=>{W.current||M(H.current.getValue(),e)}))},[w,M]),(0,A.useEffect)(()=>{if(w){let e=k.current.editor.onDidChangeMarkers(e=>{let t=H.current.getModel()?.uri;if(t&&e.find(e=>e.path===t.path)){let e=k.current.editor.getModelMarkers({resource:t});b?.(e)}});return()=>{e?.dispose()}}return()=>{}},[w,b]),A.createElement(V,{width:f,height:p,isEditorReady:w,loading:a,_ref:x,className:v,wrapperProps:g})})}}]);