@nocobase/plugin-api-doc 3.0.0-alpha.3 → 3.0.0-alpha.4
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/dist/client/146.e01b00d1777d29e1.js +10 -0
- package/dist/client/index.js +1 -1
- package/dist/client-v2/472.238dca03d6a3a4d7.js +10 -0
- package/dist/client-v2/743.03b9a72094bc4677.js +10 -0
- package/dist/client-v2/index.js +1 -1
- package/dist/client-v2/pages/DocumentationPreviewShell.d.ts +1 -3
- package/dist/client-v2/pages/swaggerTheme.d.ts +28 -0
- package/dist/externalVersion.js +7 -8
- package/package.json +2 -2
- package/dist/client/110.4b25e49a077f0d16.js +0 -10
- package/dist/client-v2/552.442e30a57deeabe5.js +0 -10
- package/dist/client-v2/743.69f0077a0937baa4.js +0 -10
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file is part of the NocoBase (R) project.
|
|
3
|
+
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
+
* Authors: NocoBase Team.
|
|
5
|
+
*
|
|
6
|
+
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
+
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
+
*/
|
|
9
|
+
|
|
10
|
+
"use strict";(self.webpackChunk_nocobase_plugin_api_doc=self.webpackChunk_nocobase_plugin_api_doc||[]).push([["146"],{712:function(e){e.exports="data:image/jpeg;base64,/9j/4QAYRXhpZgAASUkqAAgAAAAAAAAAAAAAAP/sABFEdWNreQABAAQAAAAAAAD/4QMxaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wLwA8P3hwYWNrZXQgYmVnaW49Iu+7vyIgaWQ9Ilc1TTBNcENlaGlIenJlU3pOVGN6a2M5ZCI/PiA8eDp4bXBtZXRhIHhtbG5zOng9ImFkb2JlOm5zOm1ldGEvIiB4OnhtcHRrPSJBZG9iZSBYTVAgQ29yZSA1LjYtYzExM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org/2000/svg" viewBox="0 0 20 20"><path d="M13.418 7.859a.695.695 0 0 1 .978 0 .68.68 0 0 1 0 .969l-3.908 3.83a.697.697 0 0 1-.979 0l-3.908-3.83a.68.68 0 0 1 0-.969.695.695 0 0 1 .978 0L10 11l3.418-3.141z"/></svg>'},779:function(e){e.exports='data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="10" height="8" viewBox="3 7 10 8"><path fill="%2341474E" fill-rule="evenodd" d="M6.333 15 3 11.667l1.333-1.334 2 2L11.667 7 13 8.333z"/></svg>'},153:function(e){e.exports='data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="16" height="15" aria-hidden="true"><path fill="%23fff" fill-rule="evenodd" d="M4 12h4v1H4v-1zm5-6H4v1h5V6zm2 3V7l-3 3 3 3v-2h5V9h-5zM6.5 8H4v1h2.5V8zM4 11h2.5v-1H4v1zm9 1h1v2c-.02.28-.11.52-.3.7-.19.18-.42.28-.7.3H3c-.55 0-1-.45-1-1V3c0-.55.45-1 1-1h3c0-1.11.89-2 2-2 1.11 0 2 .89 2 2h3c.55 0 1 .45 1 1v5h-1V5H3v9h10v-2zM4 4h8c0-.55-.45-1-1-1h-1c-.55 0-1-.45-1-1s-.45-1-1-1-1 .45-1 1-.45 1-1 1H5c-.55 0-1 .45-1 1z"/></svg>'},294:function(e){e.exports='data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg>'},484:function(e,n,t){t.r(n),t.d(n,{default:function(){return y}});var r=t(342),a=t(155),o=t.n(a),i=t(625),c=t(59),l=t(716),g=t.n(l);t(89);var A=t(401);function u(e,n){(null==n||n>e.length)&&(n=e.length);for(var t=0,r=Array(n);t<n;t++)r[t]=e[t];return r}function s(e,n){return null!=n&&"u">typeof Symbol&&n[Symbol.hasInstance]?!!n[Symbol.hasInstance](e):e instanceof n}function b(e){var n=e.closest("tr[data-param-name][data-param-in]"),t=null==n?void 0:n.getAttribute("data-param-name"),r=null==n?void 0:n.getAttribute("data-param-in");return t&&r?{paramName:t,paramIn:r}:null}function d(e){return null==e?"":String(e)}function p(e,n){(null==n||n>e.length)&&(n=e.length);for(var t=0,r=Array(n);t<n;t++)r[t]=e[t];return r}function h(e,n,t,r,a,o,i){try{var c=e[o](i),l=c.value}catch(e){t(e);return}c.done?n(l):Promise.resolve(l).then(r,a)}var w=function(){return localStorage.getItem(A.Fg)},m=function(e){var n,t=e.apiClient,r=e.appName,l=e.t,m=c.theme.useToken().token,v=(0,a.useRef)(null),y=(0,i.useRequest)(function(){var e;return(e=function(){return function(e,n){var t,r,a,o={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},i=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),c=Object.defineProperty;return c(i,"next",{value:l(0)}),c(i,"throw",{value:l(1)}),c(i,"return",{value:l(2)}),"function"==typeof Symbol&&c(i,Symbol.iterator,{value:function(){return this}}),i;function l(c){return function(l){var g=[c,l];if(t)throw TypeError("Generator is already executing.");for(;i&&(i=0,g[0]&&(o=0)),o;)try{if(t=1,r&&(a=2&g[0]?r.return:g[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,g[1])).done)return a;switch(r=0,a&&(g=[2&g[0],a.value]),g[0]){case 0:case 1:a=g;break;case 4:return o.label++,{value:g[1],done:!1};case 5:o.label++,r=g[1],g=[0];continue;case 7:g=o.ops.pop(),o.trys.pop();continue;default:if(!(a=(a=o.trys).length>0&&a[a.length-1])&&(6===g[0]||2===g[0])){o=0;continue}if(3===g[0]&&(!a||g[1]>a[0]&&g[1]<a[3])){o.label=g[1];break}if(6===g[0]&&o.label<a[1]){o.label=a[1],a=g;break}if(a&&o.label<a[2]){o.label=a[2],o.ops.push(g);break}a[2]&&o.ops.pop(),o.trys.pop();continue}g=n.call(e,o)}catch(e){g=[6,e],r=0}finally{t=a=0}if(5&g[0])throw g[1];return{value:g[0]?g[1]:void 0,done:!0}}}}(this,function(e){switch(e.label){case 0:return[4,t.request({url:"swagger:getUrls"})];case 1:return[2,e.sent().data]}})},function(){var n=this,t=arguments;return new Promise(function(r,a){var o=e.apply(n,t);function i(e){h(o,r,a,i,c,"next",e)}function c(e){h(o,r,a,i,c,"throw",e)}i(void 0)})})()}).data,I=(0,a.useCallback)(function(e){var n=e.headers||{};return e.headers=n,n.Authorization||(Object.assign(n,t.getHeaders()),r&&(n["X-App"]=r),n.Authorization="Bearer ".concat(t.auth.getToken())),e},[t,r]),M=function(e){if(Array.isArray(e))return e}(n=(0,a.useState)(w()))||function(e){var n,t,r=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var a=[],o=!0,i=!1;try{for(r=r.call(e);!(o=(n=r.next()).done)&&(a.push(n.value),2!==a.length);o=!0);}catch(e){i=!0,t=e}finally{try{o||null==r.return||r.return()}finally{if(i)throw t}}return a}}(n)||function(e){if(e){if("string"==typeof e)return p(e,2);var n=Object.prototype.toString.call(e).slice(8,-1);if("Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return p(e,2)}}(n)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),f=M[0],R=M[1],G=(0,a.useMemo)(function(){var e;return e=Object.entries({get:"#3b73c4",post:"#3f9070",put:"#b5822e",patch:"#b5822e",delete:"#bf4d45",head:m.colorTextTertiary,options:m.colorTextTertiary}).map(function(e){var n=function(e){if(Array.isArray(e))return e}(e)||function(e){var n,t,r=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var a=[],o=!0,i=!1;try{for(r=r.call(e);!(o=(n=r.next()).done)&&(a.push(n.value),2!==a.length);o=!0);}catch(e){i=!0,t=e}finally{try{o||null==r.return||r.return()}finally{if(i)throw t}}return a}}(e)||function(e){if(e){if("string"==typeof e)return u(e,2);var n=Object.prototype.toString.call(e).slice(8,-1);if("Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return u(e,2)}}(e)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),t=n[0],r=n[1];return"\n.nb-swagger .swagger-ui .opblock.opblock-".concat(t," .opblock-summary-method {\n background: ").concat(r,";\n}")}).join("\n"),"\n.nb-swagger .swagger-ui,\n.nb-swagger .swagger-ui .info,\n.nb-swagger .swagger-ui .opblock-tag,\n.nb-swagger .swagger-ui .opblock .opblock-summary-description,\n.nb-swagger .swagger-ui .btn,\n.nb-swagger .swagger-ui select,\n.nb-swagger .swagger-ui label,\n.nb-swagger .swagger-ui table thead tr th {\n color: ".concat(m.colorText,";\n font-family: inherit;\n}\n\n.nb-swagger .swagger-ui .wrapper {\n max-width: none;\n padding: 0;\n}\n\n/* The page header already carries the title, so Swagger's info block is a repeat. */\n.nb-swagger .swagger-ui .information-container {\n display: none;\n}\n\n/* The servers + Authorize bar: drop its grey background and shadow so it blends in. */\n.nb-swagger .swagger-ui .scheme-container {\n background: transparent;\n box-shadow: none;\n margin: 0;\n padding: 0 0 ").concat(m.paddingLG,"px;\n}\n\n.nb-swagger .swagger-ui .opblock-tag {\n border-bottom: ").concat(m.lineWidth,"px solid ").concat(m.colorSplit,";\n font-size: ").concat(m.fontSizeLG,"px;\n font-weight: 600;\n margin-bottom: ").concat(m.marginXS,"px;\n}\n.nb-swagger .swagger-ui .opblock-tag small {\n color: ").concat(m.colorTextDescription,";\n font-size: ").concat(m.fontSizeSM,"px;\n}\n\n/* Plain background for the whole row; the method keeps its color on the badge. */\n.nb-swagger .swagger-ui .opblock {\n background: ").concat(m.colorBgContainer,";\n border: ").concat(m.lineWidth,"px solid ").concat(m.colorBorderSecondary,";\n border-radius: ").concat(m.borderRadiusLG,"px;\n box-shadow: none;\n margin-bottom: ").concat(m.marginXS,"px;\n}\n.nb-swagger .swagger-ui .opblock .opblock-summary {\n border-color: ").concat(m.colorBorderSecondary,";\n}\n.nb-swagger .swagger-ui .opblock .opblock-summary-method {\n border-radius: ").concat(m.borderRadiusSM,"px;\n box-shadow: none;\n font-family: inherit;\n font-size: ").concat(m.fontSizeSM,"px;\n font-weight: 600;\n min-width: 72px;\n text-shadow: none;\n}\n").concat(e,"\n\n.nb-swagger .swagger-ui .opblock-body,\n.nb-swagger .swagger-ui .opblock-section-header {\n background: ").concat(m.colorBgContainer,";\n box-shadow: none;\n}\n.nb-swagger .swagger-ui .opblock-section-header {\n border-top: ").concat(m.lineWidth,"px solid ").concat(m.colorBorderSecondary,";\n}\n\n.nb-swagger .swagger-ui .btn {\n border-radius: ").concat(m.borderRadius,"px;\n box-shadow: none;\n font-weight: 400;\n}\n.nb-swagger .swagger-ui .btn.authorize {\n background: ").concat(m.colorBgContainer,";\n border-color: ").concat(m.colorBorder,";\n color: ").concat(m.colorText,";\n}\n.nb-swagger .swagger-ui .btn.authorize svg {\n fill: ").concat(m.colorText,";\n}\n.nb-swagger .swagger-ui .btn.execute {\n background: ").concat(m.colorPrimary,";\n border-color: ").concat(m.colorPrimary,";\n color: ").concat(m.colorTextLightSolid,";\n}\n\n.nb-swagger .swagger-ui input[type='text'],\n.nb-swagger .swagger-ui input[type='password'],\n.nb-swagger .swagger-ui input[type='search'],\n.nb-swagger .swagger-ui input[type='email'],\n.nb-swagger .swagger-ui textarea,\n.nb-swagger .swagger-ui select {\n border: ").concat(m.lineWidth,"px solid ").concat(m.colorBorder,";\n border-radius: ").concat(m.borderRadius,"px;\n box-shadow: none;\n}\n\n.nb-swagger .swagger-ui a,\n.nb-swagger .swagger-ui .opblock-summary-path a {\n color: ").concat(m.colorLink,";\n}\n\n.nb-swagger .swagger-ui section.models {\n border: ").concat(m.lineWidth,"px solid ").concat(m.colorBorderSecondary,";\n border-radius: ").concat(m.borderRadiusLG,"px;\n}\n.nb-swagger .swagger-ui section.models .model-container {\n background: ").concat(m.colorFillQuaternary,";\n border-radius: ").concat(m.borderRadius,"px;\n}\n")},[m]),j=(0,a.useMemo)(function(){return{minHeight:m.controlHeightLG,width:"100%"}},[m.controlHeightLG]);return((0,a.useEffect)(function(){f&&localStorage.setItem(A.Fg,f)},[f]),(0,a.useEffect)(function(){var e;(null==y||null==(e=y.data)?void 0:e.length)&&(f&&y.data.find(function(e){return e.url===w()})||R(y.data[0].url))},[f,y]),(0,a.useEffect)(function(){if(v.current&&f){var e,n,t,r=document.createElement("div");v.current.appendChild(r);var a=(e=null,n=function(n){var t,r,a=n.target;if(s(a,HTMLInputElement)||s(a,HTMLTextAreaElement)){var o=b(a);o&&(t=function(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{},r=Object.keys(t);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(t).filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.forEach(function(n){var r;r=t[n],n in e?Object.defineProperty(e,n,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[n]=r})}return e}({},o),r=r={value:a.value,updatedAt:Date.now()},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);n.push.apply(n,t)}return n})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),e=t)}},t=function(e){var n=document.activeElement;return(s(n,HTMLInputElement)||s(n,HTMLTextAreaElement))&&r.contains(n)&&n.value===d(e)?b(n):null},r.addEventListener("input",n,!0),r.addEventListener("change",n,!0),{plugin:function(){return{statePlugins:{spec:{wrapActions:{changeParamByIdentity:function(n,r){return function(a,o,i,c){var l,g,A,u,s,b=t(i)||(!e||Date.now()-e.updatedAt>2e3||e.value!==d(i)?null:{paramName:e.paramName,paramIn:e.paramIn})||(A=null==o||null==(l=o.get)?void 0:l.call(o,"name"),u=null==o||null==(g=o.get)?void 0:g.call(o,"in"),"string"!=typeof A||"string"!=typeof u?null:{paramName:A,paramIn:u});return b&&(null==r||null==(s=r.specActions)?void 0:s.changeParam)?r.specActions.changeParam(a,b.paramName,b.paramIn,i,c):n(a,o,i,c)}}}}}}},dispose:function(){r.removeEventListener("input",n,!0),r.removeEventListener("change",n,!0)}});return g()({requestInterceptor:I,url:f,domNode:r,plugins:[a.plugin]}),function(){a.dispose(),r.remove()}}},[f,I]),f)?o().createElement("div",{style:{height:"100%",overflowY:"auto",width:"100%"}},o().createElement("style",null,G),o().createElement(c.Flex,{align:"center",gap:m.marginXS,style:{marginBottom:m.marginLG}},o().createElement(c.Typography.Text,{style:{whiteSpace:"nowrap"}},l("Select a definition")),o().createElement(c.Select,{showSearch:!0,value:f,options:null==y?void 0:y.data,style:{maxWidth:420,width:"100%"},fieldNames:{label:"name",value:"url"},onChange:R})),o().createElement("div",{className:"nb-swagger",ref:v})):o().createElement(c.Flex,{align:"center",justify:"center",style:j},o().createElement(c.Spin,null))},v=t(944),y=function(){var e,n=(0,r.useAPIClient)(),t=(0,r.useCurrentAppInfo)(),a=(0,v.Bd)().t;return o().createElement(m,{apiClient:n,appName:null==t||null==(e=t.data)?void 0:e.name,t:a})}}}]);
|
package/dist/client/index.js
CHANGED
|
@@ -7,4 +7,4 @@
|
|
|
7
7
|
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
|
-
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("ahooks"),require("react-i18next"),require("react"),require("antd"),require("@nocobase/client")
|
|
10
|
+
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("ahooks"),require("react-i18next"),require("react"),require("antd"),require("@nocobase/client")):"function"==typeof define&&define.amd?define("@nocobase/plugin-api-doc",["ahooks","react-i18next","react","antd","@nocobase/client"],t):"object"==typeof exports?exports["@nocobase/plugin-api-doc"]=t(require("ahooks"),require("react-i18next"),require("react"),require("antd"),require("@nocobase/client")):e["@nocobase/plugin-api-doc"]=t(e.ahooks,e["react-i18next"],e.react,e.antd,e["@nocobase/client"])}(self,function(e,t,n,r,o){return function(){"use strict";var i,u,c,a={401:function(e,t,n){n.d(t,{D9:function(){return o},Fg:function(){return i},zh:function(){return r}});var r="pm.api-doc.documentation",o="/api-documentation",i="API_DOC:DESTINATION_URL_KEY"},944:function(e,t,n){n.d(t,{Bd:function(){return i},CU:function(){return o}}),n(342);var r=n(953),o="api-doc";function i(){return(0,r.useTranslation)(o)}},342:function(e){e.exports=o},625:function(t){t.exports=e},59:function(e){e.exports=r},155:function(e){e.exports=n},953:function(e){e.exports=t}},l={};function p(e){var t=l[e];if(void 0!==t)return t.exports;var n=l[e]={id:e,exports:{}};return a[e].call(n.exports,n,n.exports,p),n.exports}p.m=a,p.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return p.d(t,{a:t}),t},p.d=function(e,t){for(var n in t)p.o(t,n)&&!p.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},p.f={},p.e=function(e){return Promise.all(Object.keys(p.f).reduce(function(t,n){return p.f[n](e,t),t},[]))},p.u=function(e){return""+e+"."+({146:"e01b00d1777d29e1",645:"078fa352fe15069a"})[e]+".js"},p.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||Function("return this")()}catch(e){if("object"==typeof window)return window}}(),p.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},f={},p.l=function(e,t,n,r){if(f[e])return void f[e].push(t);if(void 0!==n)for(var o,i,u=document.getElementsByTagName("script"),c=0;c<u.length;c++){var a=u[c];if(a.getAttribute("src")==e||a.getAttribute("data-rspack")=="@nocobase/plugin-api-doc:"+n){o=a;break}}o||(i=!0,(o=document.createElement("script")).timeout=120,p.nc&&o.setAttribute("nonce",p.nc),o.setAttribute("data-rspack","@nocobase/plugin-api-doc:"+n),o.src=e),f[e]=[t];var l=function(t,n){o.onerror=o.onload=null,clearTimeout(s);var r=f[e];if(delete f[e],o.parentNode&&o.parentNode.removeChild(o),r&&r.forEach(function(e){return e(n)}),t)return t(n)},s=setTimeout(l.bind(null,void 0,{type:"timeout",target:o}),12e4);o.onerror=l.bind(null,o.onerror),o.onload=l.bind(null,o.onload),i&&document.head.appendChild(o)},p.r=function(e){"u">typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},p.nc=void 0,p.g.importScripts&&(s=p.g.location+"");var f,s,d=p.g.document;if(!s&&d&&(d.currentScript&&"SCRIPT"===d.currentScript.tagName.toUpperCase()&&(s=d.currentScript.src),!s)){var b=d.getElementsByTagName("script");if(b.length)for(var h=b.length-1;h>-1&&(!s||!/^http(s?):/.test(s));)s=b[h--].src}if(!s)throw Error("Automatic publicPath is not supported in this browser");p.p=s.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),p.b=document.baseURI||self.location.href,i={889:0},p.f.j=function(e,t){var n=p.o(i,e)?i[e]:void 0;if(0!==n)if(n)t.push(n[2]);else{var r=new Promise(function(t,r){n=i[e]=[t,r]});t.push(n[2]=r);var o=p.p+p.u(e),u=Error();p.l(o,function(t){if(p.o(i,e)&&(0!==(n=i[e])&&(i[e]=void 0),n)){var r=t&&("load"===t.type?"missing":t.type),o=t&&t.target&&t.target.src;u.message="Loading chunk "+e+" failed.\n("+r+": "+o+")",u.name="ChunkLoadError",u.type=r,u.request=o,n[1](u)}},"chunk-"+e,e)}},u=function(e,t){var n,r,o=t[0],u=t[1],c=t[2],a=0;if(o.some(function(e){return 0!==i[e]})){for(n in u)p.o(u,n)&&(p.m[n]=u[n]);c&&c(p)}for(e&&e(t);a<o.length;a++)r=o[a],p.o(i,r)&&i[r]&&i[r][0](),i[r]=0},(c=self.webpackChunk_nocobase_plugin_api_doc=self.webpackChunk_nocobase_plugin_api_doc||[]).forEach(u.bind(null,0)),c.push=u.bind(null,c.push.bind(c));var v={};return!function(){var e="",t="u">typeof document?document.currentScript:null;if(t&&t.src){var n=t.src.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"");n.indexOf("/static/plugins/@nocobase/plugin-api-doc/dist/client/")>=0&&(e=n.replace(/\/[^\/]+$/,"/"))}if(!e){var r=window.__webpack_public_path__||"";r&&("/"!==r.charAt(r.length-1)&&(r+="/"),e=r+"static/plugins/@nocobase/plugin-api-doc/dist/client/")}if(!e){var o=window.__nocobase_modern_client_prefix__||"v",i="/"+(o=String(o).replace(/^\/+|\/+$/g,"")||"v")+"/";if(!(e=window.__nocobase_public_path__||"")&&window.location&&window.location.pathname){var u=window.location.pathname||"/",c=u.indexOf(i);e=c>=0?u.slice(0,c+1):"/"}e&&(e=e.replace(RegExp("/"+o+"/?$"),"/")),e||(e="/"),"/"!==e.charAt(e.length-1)&&(e+="/"),e+="static/plugins/@nocobase/plugin-api-doc/dist/client/"}p.p=e}(),!function(){p.r(v),p.d(v,{default:function(){return g},PluginAPIDocClient:function(){return y}});var e=p(342),t=p(155),n=p.n(t),r=p(401),o=p(59),i=function(e){var r=e.children,i=o.theme.useToken().token,u=(0,t.useMemo)(function(){return{background:i.colorBgContainer,borderRadius:i.borderRadiusLG,padding:i.paddingLG}},[i.borderRadiusLG,i.colorBgContainer,i.paddingLG]);return n().createElement("div",{style:u},r)},u=p(944);function c(e,t,n,r,o,i,u){try{var c=e[i](u),a=c.value}catch(e){n(e);return}c.done?t(a):Promise.resolve(a).then(r,o)}function a(e,t,n){return(a=d()?Reflect.construct:function(e,t,n){var r=[null];r.push.apply(r,t);var o=new(Function.bind.apply(e,r));return n&&f(o,n.prototype),o}).apply(null,arguments)}function l(e){return(l=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function f(e,t){return(f=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function s(e){var t="function"==typeof Map?new Map:void 0;return(s=function(e){if(null===e||-1===Function.toString.call(e).indexOf("[native code]"))return e;if("function"!=typeof e)throw TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,n)}function n(){return a(e,arguments,l(this).constructor)}return n.prototype=Object.create(e.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),f(n,e)})(e)}function d(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(d=function(){return!!e})()}var b=(0,t.lazy)(function(){return Promise.all([p.e("645"),p.e("146")]).then(p.bind(p,484))}),h=function(){return n().createElement(i,null,n().createElement(b,null))},y=function(e){var t;if("function"!=typeof e&&null!==e)throw TypeError("Super expression must either be null or a function");function n(){var e,t;if(!(this instanceof n))throw TypeError("Cannot call a class as a function");return e=n,t=arguments,e=l(e),function(e,t){var n;if(t&&("object"==((n=t)&&"u">typeof Symbol&&n.constructor===Symbol?"symbol":typeof n)||"function"==typeof t))return t;if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(this,d()?Reflect.construct(e,t||[],l(this).constructor):e.apply(this,t))}return n.prototype=Object.create(e&&e.prototype,{constructor:{value:n,writable:!0,configurable:!0}}),e&&f(n,e),t=[{key:"load",value:function(){var e;return(e=function(){return function(e,t){var n,r,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},u=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),c=Object.defineProperty;return c(u,"next",{value:a(0)}),c(u,"throw",{value:a(1)}),c(u,"return",{value:a(2)}),"function"==typeof Symbol&&c(u,Symbol.iterator,{value:function(){return this}}),u;function a(c){return function(a){var l=[c,a];if(n)throw TypeError("Generator is already executing.");for(;u&&(u=0,l[0]&&(i=0)),i;)try{if(n=1,r&&(o=2&l[0]?r.return:l[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,l[1])).done)return o;switch(r=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,r=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],r=0}finally{n=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}(this,function(e){return this.app.pluginSettingsManager.add(u.CU,{title:'{{t("API documentation", { ns: "'.concat(u.CU,'" })}}'),icon:"BookOutlined",Component:h,aclSnippet:r.zh}),this.app.router.add("api-documentation",{path:r.D9,Component:b}),[2]})},function(){var t=this,n=arguments;return new Promise(function(r,o){var i=e.apply(t,n);function u(e){c(i,r,o,u,a,"next",e)}function a(e){c(i,r,o,u,a,"throw",e)}u(void 0)})}).call(this)}}],function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(n.prototype,t),n}(s(e.Plugin)),g=y}(),v}()});
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file is part of the NocoBase (R) project.
|
|
3
|
+
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
+
* Authors: NocoBase Team.
|
|
5
|
+
*
|
|
6
|
+
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
+
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
+
*/
|
|
9
|
+
|
|
10
|
+
"use strict";(self.webpackChunk_nocobase_plugin_api_doc_client_v2=self.webpackChunk_nocobase_plugin_api_doc_client_v2||[]).push([["472"],{712:function(e){e.exports="data:image/jpeg;base64,/9j/4QAYRXhpZgAASUkqAAgAAAAAAAAAAAAAAP/sABFEdWNreQABAAQAAAAAAAD/4QMxaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wLwA8P3hwYWNrZXQgYmVnaW49Iu+7vyIgaWQ9Ilc1TTBNcENlaGlIenJlU3pOVGN6a2M5ZCI/PiA8eDp4bXBtZXRhIHhtbG5zOng9ImFkb2JlOm5zOm1ldGEvIiB4OnhtcHRrPSJBZG9iZSBYTVAgQ29yZSA1LjYtYzExMSA3OS4xNTgzMjUsIDIwMTUvMDkvMTAtMDE6MTA6MjAgICAgICAgICI+IDxyZGY6UkRGIHhtbG5zOnJkZj0iaHR0cDovL3d3dy53My5vcmcvMTk5OS8wMi8yMi1yZGYtc3ludGF4LW5zIyI+IDxyZGY6RGVzY3JpcHRpb24gcmRmOmFib3V0PSIiIHhtbG5zOnhtcD0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wLyIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bXA6Q3JlYXRvclRvb2w9IkFkb2JlIFBob3Rvc2hvcCBDQyAyMDE1IChNYWNpbnRvc2gpIiB4bXBNTTpJbnN0YW5jZUlEPSJ4bXAuaWlkOkIxMjI0OTczNjdCMzExRTZCMkJDRTI0MDgxMDAyMTcxIiB4bXBNTTpEb2N1bWVudElEPSJ4bXAuZGlkOkIxMjI0OTc0NjdCMzExRTZCMkJDRTI0MDgxMDAyMTcxIj4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6QjE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U2QjJCQ0UyNDA4MTAwMjE3MSIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDo3NjcyQkQ3QjY3QzUxMUU2QjJCQ0UyNDA4MTAwMjE3MSIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PvCS01IAAABMSURBVHjaYmR4/5+BFPBfAMFm/MBgx8RAGWCn1AAmSg34Q6kBDKMGMDCwICeMIemF/5QawEipAWwUhwEjMDvbAWlWkvVBwu8vQIABAEwBCph8U6c0AAAAAElFTkSuQmCC"},234:function(e){e.exports='data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20"><path d="M13.418 7.859a.695.695 0 0 1 .978 0 .68.68 0 0 1 0 .969l-3.908 3.83a.697.697 0 0 1-.979 0l-3.908-3.83a.68.68 0 0 1 0-.969.695.695 0 0 1 .978 0L10 11l3.418-3.141z"/></svg>'},779:function(e){e.exports='data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="10" height="8" viewBox="3 7 10 8"><path fill="%2341474E" fill-rule="evenodd" d="M6.333 15 3 11.667l1.333-1.334 2 2L11.667 7 13 8.333z"/></svg>'},153:function(e){e.exports='data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="16" height="15" aria-hidden="true"><path fill="%23fff" fill-rule="evenodd" d="M4 12h4v1H4v-1zm5-6H4v1h5V6zm2 3V7l-3 3 3 3v-2h5V9h-5zM6.5 8H4v1h2.5V8zM4 11h2.5v-1H4v1zm9 1h1v2c-.02.28-.11.52-.3.7-.19.18-.42.28-.7.3H3c-.55 0-1-.45-1-1V3c0-.55.45-1 1-1h3c0-1.11.89-2 2-2 1.11 0 2 .89 2 2h3c.55 0 1 .45 1 1v5h-1V5H3v9h10v-2zM4 4h8c0-.55-.45-1-1-1h-1c-.55 0-1-.45-1-1s-.45-1-1-1-1 .45-1 1-.45 1-1 1H5c-.55 0-1 .45-1 1z"/></svg>'},294:function(e){e.exports='data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg>'},316:function(e,n,t){t.r(n),t.d(n,{default:function(){return v}});var r=t(485),a=t(694),o=t(155),i=t.n(o),c=t(401),l=t(625),u=t(59),g=t(716),A=t.n(g);function s(e,n){(null==n||n>e.length)&&(n=e.length);for(var t=0,r=Array(n);t<n;t++)r[t]=e[t];return r}function b(e,n){return null!=n&&"u">typeof Symbol&&n[Symbol.hasInstance]?!!n[Symbol.hasInstance](e):e instanceof n}function d(e){var n=e.closest("tr[data-param-name][data-param-in]"),t=null==n?void 0:n.getAttribute("data-param-name"),r=null==n?void 0:n.getAttribute("data-param-in");return t&&r?{paramName:t,paramIn:r}:null}function p(e){return null==e?"":String(e)}function w(e,n){(null==n||n>e.length)&&(n=e.length);for(var t=0,r=Array(n);t<n;t++)r[t]=e[t];return r}function h(e,n,t,r,a,o,i){try{var c=e[o](i),l=c.value}catch(e){t(e);return}c.done?n(l):Promise.resolve(l).then(r,a)}t(89);var m=function(){return localStorage.getItem(c.Fg)},y=function(e){var n,t=e.apiClient,r=e.appName,a=e.t,g=u.theme.useToken().token,y=(0,o.useRef)(null),v=(0,l.useRequest)(function(){var e;return(e=function(){return function(e,n){var t,r,a,o={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},i=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),c=Object.defineProperty;return c(i,"next",{value:l(0)}),c(i,"throw",{value:l(1)}),c(i,"return",{value:l(2)}),"function"==typeof Symbol&&c(i,Symbol.iterator,{value:function(){return this}}),i;function l(c){return function(l){var u=[c,l];if(t)throw TypeError("Generator is already executing.");for(;i&&(i=0,u[0]&&(o=0)),o;)try{if(t=1,r&&(a=2&u[0]?r.return:u[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,u[1])).done)return a;switch(r=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,r=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(!(a=(a=o.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){o=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){o.label=u[1];break}if(6===u[0]&&o.label<a[1]){o.label=a[1],a=u;break}if(a&&o.label<a[2]){o.label=a[2],o.ops.push(u);break}a[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(e,o)}catch(e){u=[6,e],r=0}finally{t=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}(this,function(e){switch(e.label){case 0:return[4,t.request({url:"swagger:getUrls"})];case 1:return[2,e.sent().data]}})},function(){var n=this,t=arguments;return new Promise(function(r,a){var o=e.apply(n,t);function i(e){h(o,r,a,i,c,"next",e)}function c(e){h(o,r,a,i,c,"throw",e)}i(void 0)})})()}).data,I=(0,o.useCallback)(function(e){var n=e.headers||{};return e.headers=n,n.Authorization||(Object.assign(n,t.getHeaders()),r&&(n["X-App"]=r),n.Authorization="Bearer ".concat(t.auth.getToken())),e},[t,r]),f=function(e){if(Array.isArray(e))return e}(n=(0,o.useState)(m()))||function(e){var n,t,r=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var a=[],o=!0,i=!1;try{for(r=r.call(e);!(o=(n=r.next()).done)&&(a.push(n.value),2!==a.length);o=!0);}catch(e){i=!0,t=e}finally{try{o||null==r.return||r.return()}finally{if(i)throw t}}return a}}(n)||function(e){if(e){if("string"==typeof e)return w(e,2);var n=Object.prototype.toString.call(e).slice(8,-1);if("Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return w(e,2)}}(n)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),M=f[0],R=f[1],j=(0,o.useMemo)(function(){var e;return e=Object.entries({get:"#3b73c4",post:"#3f9070",put:"#b5822e",patch:"#b5822e",delete:"#bf4d45",head:g.colorTextTertiary,options:g.colorTextTertiary}).map(function(e){var n=function(e){if(Array.isArray(e))return e}(e)||function(e){var n,t,r=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var a=[],o=!0,i=!1;try{for(r=r.call(e);!(o=(n=r.next()).done)&&(a.push(n.value),2!==a.length);o=!0);}catch(e){i=!0,t=e}finally{try{o||null==r.return||r.return()}finally{if(i)throw t}}return a}}(e)||function(e){if(e){if("string"==typeof e)return s(e,2);var n=Object.prototype.toString.call(e).slice(8,-1);if("Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return s(e,2)}}(e)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),t=n[0],r=n[1];return"\n.nb-swagger .swagger-ui .opblock.opblock-".concat(t," .opblock-summary-method {\n background: ").concat(r,";\n}")}).join("\n"),"\n.nb-swagger .swagger-ui,\n.nb-swagger .swagger-ui .info,\n.nb-swagger .swagger-ui .opblock-tag,\n.nb-swagger .swagger-ui .opblock .opblock-summary-description,\n.nb-swagger .swagger-ui .btn,\n.nb-swagger .swagger-ui select,\n.nb-swagger .swagger-ui label,\n.nb-swagger .swagger-ui table thead tr th {\n color: ".concat(g.colorText,";\n font-family: inherit;\n}\n\n.nb-swagger .swagger-ui .wrapper {\n max-width: none;\n padding: 0;\n}\n\n/* The page header already carries the title, so Swagger's info block is a repeat. */\n.nb-swagger .swagger-ui .information-container {\n display: none;\n}\n\n/* The servers + Authorize bar: drop its grey background and shadow so it blends in. */\n.nb-swagger .swagger-ui .scheme-container {\n background: transparent;\n box-shadow: none;\n margin: 0;\n padding: 0 0 ").concat(g.paddingLG,"px;\n}\n\n.nb-swagger .swagger-ui .opblock-tag {\n border-bottom: ").concat(g.lineWidth,"px solid ").concat(g.colorSplit,";\n font-size: ").concat(g.fontSizeLG,"px;\n font-weight: 600;\n margin-bottom: ").concat(g.marginXS,"px;\n}\n.nb-swagger .swagger-ui .opblock-tag small {\n color: ").concat(g.colorTextDescription,";\n font-size: ").concat(g.fontSizeSM,"px;\n}\n\n/* Plain background for the whole row; the method keeps its color on the badge. */\n.nb-swagger .swagger-ui .opblock {\n background: ").concat(g.colorBgContainer,";\n border: ").concat(g.lineWidth,"px solid ").concat(g.colorBorderSecondary,";\n border-radius: ").concat(g.borderRadiusLG,"px;\n box-shadow: none;\n margin-bottom: ").concat(g.marginXS,"px;\n}\n.nb-swagger .swagger-ui .opblock .opblock-summary {\n border-color: ").concat(g.colorBorderSecondary,";\n}\n.nb-swagger .swagger-ui .opblock .opblock-summary-method {\n border-radius: ").concat(g.borderRadiusSM,"px;\n box-shadow: none;\n font-family: inherit;\n font-size: ").concat(g.fontSizeSM,"px;\n font-weight: 600;\n min-width: 72px;\n text-shadow: none;\n}\n").concat(e,"\n\n.nb-swagger .swagger-ui .opblock-body,\n.nb-swagger .swagger-ui .opblock-section-header {\n background: ").concat(g.colorBgContainer,";\n box-shadow: none;\n}\n.nb-swagger .swagger-ui .opblock-section-header {\n border-top: ").concat(g.lineWidth,"px solid ").concat(g.colorBorderSecondary,";\n}\n\n.nb-swagger .swagger-ui .btn {\n border-radius: ").concat(g.borderRadius,"px;\n box-shadow: none;\n font-weight: 400;\n}\n.nb-swagger .swagger-ui .btn.authorize {\n background: ").concat(g.colorBgContainer,";\n border-color: ").concat(g.colorBorder,";\n color: ").concat(g.colorText,";\n}\n.nb-swagger .swagger-ui .btn.authorize svg {\n fill: ").concat(g.colorText,";\n}\n.nb-swagger .swagger-ui .btn.execute {\n background: ").concat(g.colorPrimary,";\n border-color: ").concat(g.colorPrimary,";\n color: ").concat(g.colorTextLightSolid,";\n}\n\n.nb-swagger .swagger-ui input[type='text'],\n.nb-swagger .swagger-ui input[type='password'],\n.nb-swagger .swagger-ui input[type='search'],\n.nb-swagger .swagger-ui input[type='email'],\n.nb-swagger .swagger-ui textarea,\n.nb-swagger .swagger-ui select {\n border: ").concat(g.lineWidth,"px solid ").concat(g.colorBorder,";\n border-radius: ").concat(g.borderRadius,"px;\n box-shadow: none;\n}\n\n.nb-swagger .swagger-ui a,\n.nb-swagger .swagger-ui .opblock-summary-path a {\n color: ").concat(g.colorLink,";\n}\n\n.nb-swagger .swagger-ui section.models {\n border: ").concat(g.lineWidth,"px solid ").concat(g.colorBorderSecondary,";\n border-radius: ").concat(g.borderRadiusLG,"px;\n}\n.nb-swagger .swagger-ui section.models .model-container {\n background: ").concat(g.colorFillQuaternary,";\n border-radius: ").concat(g.borderRadius,"px;\n}\n")},[g]),G=(0,o.useMemo)(function(){return{minHeight:g.controlHeightLG,width:"100%"}},[g.controlHeightLG]);return((0,o.useEffect)(function(){M&&localStorage.setItem(c.Fg,M)},[M]),(0,o.useEffect)(function(){var e;(null==v||null==(e=v.data)?void 0:e.length)&&(M&&v.data.find(function(e){return e.url===m()})||R(v.data[0].url))},[M,v]),(0,o.useEffect)(function(){if(y.current&&M){var e,n,t,r=document.createElement("div");y.current.appendChild(r);var a=(e=null,n=function(n){var t,r,a=n.target;if(b(a,HTMLInputElement)||b(a,HTMLTextAreaElement)){var o=d(a);o&&(t=function(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{},r=Object.keys(t);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(t).filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.forEach(function(n){var r;r=t[n],n in e?Object.defineProperty(e,n,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[n]=r})}return e}({},o),r=r={value:a.value,updatedAt:Date.now()},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);n.push.apply(n,t)}return n})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),e=t)}},t=function(e){var n=document.activeElement;return(b(n,HTMLInputElement)||b(n,HTMLTextAreaElement))&&r.contains(n)&&n.value===p(e)?d(n):null},r.addEventListener("input",n,!0),r.addEventListener("change",n,!0),{plugin:function(){return{statePlugins:{spec:{wrapActions:{changeParamByIdentity:function(n,r){return function(a,o,i,c){var l,u,g,A,s,b=t(i)||(!e||Date.now()-e.updatedAt>2e3||e.value!==p(i)?null:{paramName:e.paramName,paramIn:e.paramIn})||(g=null==o||null==(l=o.get)?void 0:l.call(o,"name"),A=null==o||null==(u=o.get)?void 0:u.call(o,"in"),"string"!=typeof g||"string"!=typeof A?null:{paramName:g,paramIn:A});return b&&(null==r||null==(s=r.specActions)?void 0:s.changeParam)?r.specActions.changeParam(a,b.paramName,b.paramIn,i,c):n(a,o,i,c)}}}}}}},dispose:function(){r.removeEventListener("input",n,!0),r.removeEventListener("change",n,!0)}});return A()({requestInterceptor:I,url:M,domNode:r,plugins:[a.plugin]}),function(){a.dispose(),r.remove()}}},[M,I]),M)?i().createElement("div",{style:{height:"100%",overflowY:"auto",width:"100%"}},i().createElement("style",null,j),i().createElement(u.Flex,{align:"center",gap:g.marginXS,style:{marginBottom:g.marginLG}},i().createElement(u.Typography.Text,{style:{whiteSpace:"nowrap"}},a("Select a definition")),i().createElement(u.Select,{showSearch:!0,value:M,options:null==v?void 0:v.data,style:{maxWidth:420,width:"100%"},fieldNames:{label:"name",value:"url"},onChange:R})),i().createElement("div",{className:"nb-swagger",ref:y})):i().createElement(u.Flex,{align:"center",justify:"center",style:G},i().createElement(u.Spin,null))},v=function(){var e,n,t=(0,a.useFlowContext)().api,o=(0,r.useCurrentAppInfo)(),l=(e=(0,a.useFlowEngine)(),function(n,t){return e.context.t(n,function(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{},r=Object.keys(t);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(t).filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.forEach(function(n){var r;r=t[n],n in e?Object.defineProperty(e,n,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[n]=r})}return e}({ns:[c.CU,"client"]},t))});return i().createElement(y,{apiClient:t,appName:null==o||null==(n=o.data)?void 0:n.name,t:l})}}}]);
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file is part of the NocoBase (R) project.
|
|
3
|
+
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
+
* Authors: NocoBase Team.
|
|
5
|
+
*
|
|
6
|
+
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
+
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
+
*/
|
|
9
|
+
|
|
10
|
+
"use strict";(self.webpackChunk_nocobase_plugin_api_doc_client_v2=self.webpackChunk_nocobase_plugin_api_doc_client_v2||[]).push([["743"],{50:function(e,n,r){r.r(n),r.d(n,{default:function(){return c}});var t=r(155),u=r.n(t),o=r(316),a=r(59),i=function(e){var n=e.children,r=a.theme.useToken().token,o=(0,t.useMemo)(function(){return{background:r.colorBgContainer,borderRadius:r.borderRadiusLG,padding:r.paddingLG}},[r.borderRadiusLG,r.colorBgContainer,r.paddingLG]);return u().createElement("div",{style:o},n)},c=function(){return u().createElement(i,null,u().createElement(o.default,null))}}}]);
|
package/dist/client-v2/index.js
CHANGED
|
@@ -7,4 +7,4 @@
|
|
|
7
7
|
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
|
-
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("ahooks"),require("@nocobase/client-v2"),require("react"),require("antd"),require("@
|
|
10
|
+
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("ahooks"),require("@nocobase/client-v2"),require("react"),require("antd"),require("@nocobase/flow-engine")):"function"==typeof define&&define.amd?define("@nocobase/plugin-api-doc/client-v2",["ahooks","@nocobase/client-v2","react","antd","@nocobase/flow-engine"],t):"object"==typeof exports?exports["@nocobase/plugin-api-doc/client-v2"]=t(require("ahooks"),require("@nocobase/client-v2"),require("react"),require("antd"),require("@nocobase/flow-engine")):e["@nocobase/plugin-api-doc/client-v2"]=t(e.ahooks,e["@nocobase/client-v2"],e.react,e.antd,e["@nocobase/flow-engine"])}(self,function(e,t,n,r,o){return function(){"use strict";var i,c,a,u={401:function(e,t,n){n.d(t,{CU:function(){return r},D9:function(){return i},Fg:function(){return c},zh:function(){return o}});var r="api-doc",o="pm.api-doc.documentation",i="/api-documentation",c="API_DOC:DESTINATION_URL_KEY"},485:function(e){e.exports=t},694:function(e){e.exports=o},625:function(t){t.exports=e},59:function(e){e.exports=r},155:function(e){e.exports=n}},l={};function p(e){var t=l[e];if(void 0!==t)return t.exports;var n=l[e]={id:e,exports:{}};return u[e].call(n.exports,n,n.exports,p),n.exports}p.m=u,p.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return p.d(t,{a:t}),t},p.d=function(e,t){for(var n in t)p.o(t,n)&&!p.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},p.f={},p.e=function(e){return Promise.all(Object.keys(p.f).reduce(function(t,n){return p.f[n](e,t),t},[]))},p.u=function(e){return""+e+"."+({472:"238dca03d6a3a4d7",645:"f3fe2cb789ceac77",743:"03b9a72094bc4677"})[e]+".js"},p.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||Function("return this")()}catch(e){if("object"==typeof window)return window}}(),p.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},f={},p.l=function(e,t,n,r){if(f[e])return void f[e].push(t);if(void 0!==n)for(var o,i,c=document.getElementsByTagName("script"),a=0;a<c.length;a++){var u=c[a];if(u.getAttribute("src")==e||u.getAttribute("data-rspack")=="@nocobase/plugin-api-doc/client-v2:"+n){o=u;break}}o||(i=!0,(o=document.createElement("script")).timeout=120,p.nc&&o.setAttribute("nonce",p.nc),o.setAttribute("data-rspack","@nocobase/plugin-api-doc/client-v2:"+n),o.src=e),f[e]=[t];var l=function(t,n){o.onerror=o.onload=null,clearTimeout(s);var r=f[e];if(delete f[e],o.parentNode&&o.parentNode.removeChild(o),r&&r.forEach(function(e){return e(n)}),t)return t(n)},s=setTimeout(l.bind(null,void 0,{type:"timeout",target:o}),12e4);o.onerror=l.bind(null,o.onerror),o.onload=l.bind(null,o.onload),i&&document.head.appendChild(o)},p.r=function(e){"u">typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},p.nc=void 0,p.g.importScripts&&(s=p.g.location+"");var f,s,d=p.g.document;if(!s&&d&&(d.currentScript&&"SCRIPT"===d.currentScript.tagName.toUpperCase()&&(s=d.currentScript.src),!s)){var b=d.getElementsByTagName("script");if(b.length)for(var v=b.length-1;v>-1&&(!s||!/^http(s?):/.test(s));)s=b[v--].src}if(!s)throw Error("Automatic publicPath is not supported in this browser");p.p=s.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),p.b=document.baseURI||self.location.href,i={889:0},p.f.j=function(e,t){var n=p.o(i,e)?i[e]:void 0;if(0!==n)if(n)t.push(n[2]);else{var r=new Promise(function(t,r){n=i[e]=[t,r]});t.push(n[2]=r);var o=p.p+p.u(e),c=Error();p.l(o,function(t){if(p.o(i,e)&&(0!==(n=i[e])&&(i[e]=void 0),n)){var r=t&&("load"===t.type?"missing":t.type),o=t&&t.target&&t.target.src;c.message="Loading chunk "+e+" failed.\n("+r+": "+o+")",c.name="ChunkLoadError",c.type=r,c.request=o,n[1](c)}},"chunk-"+e,e)}},c=function(e,t){var n,r,o=t[0],c=t[1],a=t[2],u=0;if(o.some(function(e){return 0!==i[e]})){for(n in c)p.o(c,n)&&(p.m[n]=c[n]);a&&a(p)}for(e&&e(t);u<o.length;u++)r=o[u],p.o(i,r)&&i[r]&&i[r][0](),i[r]=0},(a=self.webpackChunk_nocobase_plugin_api_doc_client_v2=self.webpackChunk_nocobase_plugin_api_doc_client_v2||[]).forEach(c.bind(null,0)),a.push=c.bind(null,a.push.bind(a));var h={};return!function(){var e="",t="u">typeof document?document.currentScript:null;if(t&&t.src){var n=t.src.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"");n.indexOf("/static/plugins/@nocobase/plugin-api-doc/dist/client-v2/")>=0&&(e=n.replace(/\/[^\/]+$/,"/"))}if(!e){var r=window.__webpack_public_path__||"";r&&("/"!==r.charAt(r.length-1)&&(r+="/"),e=r+"static/plugins/@nocobase/plugin-api-doc/dist/client-v2/")}if(!e){var o=window.__nocobase_modern_client_prefix__||"v",i="/"+(o=String(o).replace(/^\/+|\/+$/g,"")||"v")+"/";if(!(e=window.__nocobase_public_path__||"")&&window.location&&window.location.pathname){var c=window.location.pathname||"/",a=c.indexOf(i);e=a>=0?c.slice(0,a+1):"/"}e&&(e=e.replace(RegExp("/"+o+"/?$"),"/")),e||(e="/"),"/"!==e.charAt(e.length-1)&&(e+="/"),e+="static/plugins/@nocobase/plugin-api-doc/dist/client-v2/"}p.p=e}(),!function(){p.r(h),p.d(h,{default:function(){return u}});var e=p(485),t=p(401);function n(e,t,n,r,o,i,c){try{var a=e[i](c),u=a.value}catch(e){n(e);return}a.done?t(u):Promise.resolve(u).then(r,o)}function r(e,t,n){return(r=a()?Reflect.construct:function(e,t,n){var r=[null];r.push.apply(r,t);var o=new(Function.bind.apply(e,r));return n&&i(o,n.prototype),o}).apply(null,arguments)}function o(e){return(o=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function i(e,t){return(i=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function c(e){var t="function"==typeof Map?new Map:void 0;return(c=function(e){if(null===e||-1===Function.toString.call(e).indexOf("[native code]"))return e;if("function"!=typeof e)throw TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,n)}function n(){return r(e,arguments,o(this).constructor)}return n.prototype=Object.create(e.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),i(n,e)})(e)}function a(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(a=function(){return!!e})()}var u=function(e){var r;if("function"!=typeof e&&null!==e)throw TypeError("Super expression must either be null or a function");function c(){var e,t;if(!(this instanceof c))throw TypeError("Cannot call a class as a function");return e=c,t=arguments,e=o(e),function(e,t){var n;if(t&&("object"==((n=t)&&"u">typeof Symbol&&n.constructor===Symbol?"symbol":typeof n)||"function"==typeof t))return t;if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(this,a()?Reflect.construct(e,t||[],o(this).constructor):e.apply(this,t))}return c.prototype=Object.create(e&&e.prototype,{constructor:{value:c,writable:!0,configurable:!0}}),e&&i(c,e),r=[{key:"load",value:function(){var e;return(e=function(){var e;return function(e,t){var n,r,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},c=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),a=Object.defineProperty;return a(c,"next",{value:u(0)}),a(c,"throw",{value:u(1)}),a(c,"return",{value:u(2)}),"function"==typeof Symbol&&a(c,Symbol.iterator,{value:function(){return this}}),c;function u(a){return function(u){var l=[a,u];if(n)throw TypeError("Generator is already executing.");for(;c&&(c=0,l[0]&&(i=0)),i;)try{if(n=1,r&&(o=2&l[0]?r.return:l[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,l[1])).done)return o;switch(r=0,o&&(l=[2&l[0],o.value]),l[0]){case 0:case 1:o=l;break;case 4:return i.label++,{value:l[1],done:!1};case 5:i.label++,r=l[1],l=[0];continue;case 7:l=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===l[0]||2===l[0])){i=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]<o[3])){i.label=l[1];break}if(6===l[0]&&i.label<o[1]){i.label=o[1],o=l;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(l);break}o[2]&&i.ops.pop(),i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e],r=0}finally{n=o=0}if(5&l[0])throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}}(this,function(n){return e=this.app.i18n.t("API documentation",{ns:t.CU}),this.pluginSettingsManager.addMenuItem({key:t.CU,title:e,icon:"BookOutlined",aclSnippet:t.zh}),this.pluginSettingsManager.addPageTabItem({menuKey:t.CU,key:"index",title:e,componentLoader:function(){return Promise.all([p.e("645"),p.e("472"),p.e("743")]).then(p.bind(p,50))},aclSnippet:t.zh}),this.router.add("api-documentation",{path:t.D9,componentLoader:function(){return Promise.all([p.e("645"),p.e("472")]).then(p.bind(p,316))}}),[2]})},function(){var t=this,r=arguments;return new Promise(function(o,i){var c=e.apply(t,r);function a(e){n(c,o,i,a,u,"next",e)}function u(e){n(c,o,i,a,u,"throw",e)}a(void 0)})}).call(this)}}],function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}(c.prototype,r),c}(c(e.Plugin))}(),h}()});
|
|
@@ -10,8 +10,6 @@ import type { ReactNode } from 'react';
|
|
|
10
10
|
import React from 'react';
|
|
11
11
|
export type DocumentationPreviewShellProps = {
|
|
12
12
|
children: ReactNode;
|
|
13
|
-
href?: string;
|
|
14
|
-
previewTitle: string;
|
|
15
13
|
};
|
|
16
|
-
declare const DocumentationPreviewShell: ({ children
|
|
14
|
+
declare const DocumentationPreviewShell: ({ children }: DocumentationPreviewShellProps) => React.JSX.Element;
|
|
17
15
|
export default DocumentationPreviewShell;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file is part of the NocoBase (R) project.
|
|
3
|
+
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
+
* Authors: NocoBase Team.
|
|
5
|
+
*
|
|
6
|
+
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
+
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
+
*/
|
|
9
|
+
import type { GlobalToken } from 'antd';
|
|
10
|
+
/**
|
|
11
|
+
* Map Swagger UI's built-in skin onto the current theme.
|
|
12
|
+
*
|
|
13
|
+
* Swagger UI ships a full stylesheet of its own (typography, radii, shadows, a
|
|
14
|
+
* blue-and-green palette) that reads like a second website next to the neutral
|
|
15
|
+
* settings center. This leaves its DOM alone and only overrides the surface:
|
|
16
|
+
*
|
|
17
|
+
* - typography and controls follow the theme, so radii, borders and inputs match
|
|
18
|
+
* the rest of the pages;
|
|
19
|
+
* - method colors are **kept** — GET / POST / DELETE are told apart by color, and
|
|
20
|
+
* greying them out would force reading every verb; only the tinted row
|
|
21
|
+
* backgrounds go away, leaving the color on the method badge;
|
|
22
|
+
* - its own title block is hidden, since the page header already says
|
|
23
|
+
* "API documentation".
|
|
24
|
+
*
|
|
25
|
+
* @param {GlobalToken} token current theme token
|
|
26
|
+
* @returns {string} scoped stylesheet
|
|
27
|
+
*/
|
|
28
|
+
export declare function buildSwaggerCss(token: GlobalToken): string;
|
package/dist/externalVersion.js
CHANGED
|
@@ -8,16 +8,15 @@
|
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
module.exports = {
|
|
11
|
-
"@nocobase/client": "3.0.0-alpha.
|
|
11
|
+
"@nocobase/client": "3.0.0-alpha.4",
|
|
12
12
|
"react": "18.2.0",
|
|
13
|
-
"@nocobase/flow-engine": "3.0.0-alpha.
|
|
14
|
-
"@nocobase/client-v2": "3.0.0-alpha.
|
|
13
|
+
"@nocobase/flow-engine": "3.0.0-alpha.4",
|
|
14
|
+
"@nocobase/client-v2": "3.0.0-alpha.4",
|
|
15
15
|
"react-i18next": "11.18.6",
|
|
16
|
-
"@nocobase/actions": "3.0.0-alpha.
|
|
17
|
-
"@nocobase/server": "3.0.0-alpha.
|
|
16
|
+
"@nocobase/actions": "3.0.0-alpha.4",
|
|
17
|
+
"@nocobase/server": "3.0.0-alpha.4",
|
|
18
18
|
"ahooks": "3.7.8",
|
|
19
19
|
"antd": "5.24.2",
|
|
20
|
-
"@
|
|
21
|
-
"@nocobase/
|
|
22
|
-
"@nocobase/database": "3.0.0-alpha.3"
|
|
20
|
+
"@nocobase/utils": "3.0.0-alpha.4",
|
|
21
|
+
"@nocobase/database": "3.0.0-alpha.4"
|
|
23
22
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nocobase/plugin-api-doc",
|
|
3
|
-
"version": "3.0.0-alpha.
|
|
3
|
+
"version": "3.0.0-alpha.4",
|
|
4
4
|
"displayName": "API documentation",
|
|
5
5
|
"displayName.ru-RU": "Документация API",
|
|
6
6
|
"displayName.zh-CN": "API 文档",
|
|
@@ -28,5 +28,5 @@
|
|
|
28
28
|
"url": "git+https://github.com/nocobase/nocobase.git",
|
|
29
29
|
"directory": "packages/plugins/api-doc"
|
|
30
30
|
},
|
|
31
|
-
"gitHead": "
|
|
31
|
+
"gitHead": "6658768567378382de758c4e814ac510d688400c"
|
|
32
32
|
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
"use strict";(self.webpackChunk_nocobase_plugin_api_doc=self.webpackChunk_nocobase_plugin_api_doc||[]).push([["110"],{712:function(e){e.exports="data:image/jpeg;base64,/9j/4QAYRXhpZgAASUkqAAgAAAAAAAAAAAAAAP/sABFEdWNreQABAAQAAAAAAAD/4QMxaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wLwA8P3hwYWNrZXQgYmVnaW49Iu+7vyIgaWQ9Ilc1TTBNcENlaGlIenJlU3pOVGN6a2M5ZCI/PiA8eDp4bXBtZXRhIHhtbG5zOng9ImFkb2JlOm5zOm1ldGEvIiB4OnhtcHRrPSJBZG9iZSBYTVAgQ29yZSA1LjYtYzExMSA3OS4xNTgzMjUsIDIwMTUvMDkvMTAtMDE6MTA6MjAgICAgICAgICI+IDxyZGY6UkRGIHhtbG5zOnJkZj0iaHR0cDovL3d3dy53My5vcmcvMTk5OS8wMi8yMi1yZGYtc3ludGF4LW5zIyI+IDxyZGY6RGVzY3JpcHRpb24gcmRmOmFib3V0PSIiIHhtbG5zOnhtcD0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wLyIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bXA6Q3JlYXRvclRvb2w9IkFkb2JlIFBob3Rvc2hvcCBDQyAyMDE1IChNYWNpbnRvc2gpIiB4bXBNTTpJbnN0YW5jZUlEPSJ4bXAuaWlkOkIxMjI0OTczNjdCMzExRTZCMkJDRTI0MDgxMDAyMTcxIiB4bXBNTTpEb2N1bWVudElEPSJ4bXAuZGlkOkIxMjI0OTc0NjdCMzExRTZCMkJDRTI0MDgxMDAyMTcxIj4gPHhtcE1NOkRlcml2ZWRG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GFuY2VJRD0ieG1wLmlpZDo3NjcyQkQ3QTY3QzUxMUU2QjJCQ0UyNDA4MTAwMjE3MSIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDo3NjcyQkQ3QjY3QzUxMUU2QjJCQ0UyNDA4MTAwMjE3MSIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PvCS01IAAABMSURBVHjaYmR4/5+BFPBfAMFm/MBgx8RAGWCn1AAmSg34Q6kBDKMGMDCwICeMIemF/5QawEipAWwUhwEjMDvbAWlWkvVBwu8vQIABAEwBCph8U6c0AAAAAElFTkSuQmCC"},234:function(e){e.exports='data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20"><path d="M13.418 7.859a.695.695 0 0 1 .978 0 .68.68 0 0 1 0 .969l-3.908 3.83a.697.697 0 0 1-.979 0l-3.908-3.83a.68.68 0 0 1 0-.969.695.695 0 0 1 .978 0L10 11l3.418-3.141z"/></svg>'},779:function(e){e.exports='data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="10" height="8" viewBox="3 7 10 8"><path fill="%2341474E" fill-rule="evenodd" d="M6.333 15 3 11.667l1.333-1.334 2 2L11.667 7 13 8.333z"/></svg>'},153:function(e){e.exports='data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="16" height="15" aria-hidden="true"><path fill="%23fff" fill-rule="evenodd" d="M4 12h4v1H4v-1zm5-6H4v1h5V6zm2 3V7l-3 3 3 3v-2h5V9h-5zM6.5 8H4v1h2.5V8zM4 11h2.5v-1H4v1zm9 1h1v2c-.02.28-.11.52-.3.7-.19.18-.42.28-.7.3H3c-.55 0-1-.45-1-1V3c0-.55.45-1 1-1h3c0-1.11.89-2 2-2 1.11 0 2 .89 2 2h3c.55 0 1 .45 1 1v5h-1V5H3v9h10v-2zM4 4h8c0-.55-.45-1-1-1h-1c-.55 0-1-.45-1-1s-.45-1-1-1-1 .45-1 1-.45 1-1 1H5c-.55 0-1 .45-1 1z"/></svg>'},294:function(e){e.exports='data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg>'},296:function(e,t,n){n.r(t),n.d(t,{default:function(){return s}});var A=n(342),r=n(155),a=n.n(r),i=n(625),l=n(59),c=n(716),o=n.n(c);n(89);var u=n(401);function d(e,t){return null!=t&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t}function g(e){var t=e.closest("tr[data-param-name][data-param-in]"),n=null==t?void 0:t.getAttribute("data-param-name"),A=null==t?void 0:t.getAttribute("data-param-in");return n&&A?{paramName:n,paramIn:A}:null}function h(e){return null==e?"":String(e)}function m(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,A=Array(t);n<t;n++)A[n]=e[n];return A}function v(e,t,n,A,r,a,i){try{var l=e[a](i),c=l.value}catch(e){n(e);return}l.done?t(c):Promise.resolve(c).then(A,r)}var p=function(){return localStorage.getItem(u.Fg)},I=function(e){var t,n=e.apiClient,A=e.appName,c=e.t,I=l.theme.useToken().token,b=(0,r.useRef)(null),s=(0,i.useRequest)(function(){var e;return(e=function(){return function(e,t){var n,A,r,a={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]},i=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),l=Object.defineProperty;return l(i,"next",{value:c(0)}),l(i,"throw",{value:c(1)}),l(i,"return",{value:c(2)}),"function"==typeof Symbol&&l(i,Symbol.iterator,{value:function(){return this}}),i;function c(l){return function(c){var o=[l,c];if(n)throw TypeError("Generator is already executing.");for(;i&&(i=0,o[0]&&(a=0)),a;)try{if(n=1,A&&(r=2&o[0]?A.return:o[0]?A.throw||((r=A.return)&&r.call(A),0):A.next)&&!(r=r.call(A,o[1])).done)return r;switch(A=0,r&&(o=[2&o[0],r.value]),o[0]){case 0:case 1:r=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,A=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!(r=(r=a.trys).length>0&&r[r.length-1])&&(6===o[0]||2===o[0])){a=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]<r[3])){a.label=o[1];break}if(6===o[0]&&a.label<r[1]){a.label=r[1],r=o;break}if(r&&a.label<r[2]){a.label=r[2],a.ops.push(o);break}r[2]&&a.ops.pop(),a.trys.pop();continue}o=t.call(e,a)}catch(e){o=[6,e],A=0}finally{n=r=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}}}(this,function(e){switch(e.label){case 0:return[4,n.request({url:"swagger:getUrls"})];case 1:return[2,e.sent().data]}})},function(){var t=this,n=arguments;return new Promise(function(A,r){var a=e.apply(t,n);function i(e){v(a,A,r,i,l,"next",e)}function l(e){v(a,A,r,i,l,"throw",e)}i(void 0)})})()}).data,M=(0,r.useCallback)(function(e){var t=e.headers||{};return e.headers=t,t.Authorization||(Object.assign(t,n.getHeaders()),A&&(t["X-App"]=A),t.Authorization="Bearer ".concat(n.auth.getToken())),e},[n,A]),w=function(e){if(Array.isArray(e))return e}(t=(0,r.useState)(p()))||function(e){var t,n,A=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=A){var r=[],a=!0,i=!1;try{for(A=A.call(e);!(a=(t=A.next()).done)&&(r.push(t.value),2!==r.length);a=!0);}catch(e){i=!0,n=e}finally{try{a||null==A.return||A.return()}finally{if(i)throw n}}return r}}(t)||function(e){if(e){if("string"==typeof e)return m(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return m(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),y=w[0],R=w[1],G=(0,r.useMemo)(function(){return{alignItems:"center",display:"flex",gap:I.marginXS,paddingBlock:I.padding,paddingInline:I.paddingLG,width:"100%"}},[I.marginXS,I.padding,I.paddingLG]),j=(0,r.useMemo)(function(){return{minHeight:I.controlHeightLG,width:"100%"}},[I.controlHeightLG]);return((0,r.useEffect)(function(){y&&localStorage.setItem(u.Fg,y)},[y]),(0,r.useEffect)(function(){var e;(null==s||null==(e=s.data)?void 0:e.length)&&(y&&s.data.find(function(e){return e.url===p()})||R(s.data[0].url))},[y,s]),(0,r.useEffect)(function(){if(b.current&&y){var e,t,n,A=document.createElement("div");b.current.appendChild(A);var r=(e=null,t=function(t){var n,A,r=t.target;if(d(r,HTMLInputElement)||d(r,HTMLTextAreaElement)){var a=g(r);a&&(n=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},A=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(A=A.concat(Object.getOwnPropertySymbols(n).filter(function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),A.forEach(function(t){var A;A=n[t],t in e?Object.defineProperty(e,t,{value:A,enumerable:!0,configurable:!0,writable:!0}):e[t]=A})}return e}({},a),A=A={value:r.value,updatedAt:Date.now()},Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(A)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t.push.apply(t,n)}return t})(Object(A)).forEach(function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(A,e))}),e=n)}},n=function(e){var t=document.activeElement;return(d(t,HTMLInputElement)||d(t,HTMLTextAreaElement))&&A.contains(t)&&t.value===h(e)?g(t):null},A.addEventListener("input",t,!0),A.addEventListener("change",t,!0),{plugin:function(){return{statePlugins:{spec:{wrapActions:{changeParamByIdentity:function(t,A){return function(r,a,i,l){var c,o,u,d,g,m=n(i)||(!e||Date.now()-e.updatedAt>2e3||e.value!==h(i)?null:{paramName:e.paramName,paramIn:e.paramIn})||(u=null==a||null==(c=a.get)?void 0:c.call(a,"name"),d=null==a||null==(o=a.get)?void 0:o.call(a,"in"),"string"!=typeof u||"string"!=typeof d?null:{paramName:u,paramIn:d});return m&&(null==A||null==(g=A.specActions)?void 0:g.changeParam)?A.specActions.changeParam(r,m.paramName,m.paramIn,i,l):t(r,a,i,l)}}}}}}},dispose:function(){A.removeEventListener("input",t,!0),A.removeEventListener("change",t,!0)}});return o()({requestInterceptor:M,url:y,domNode:A,plugins:[r.plugin]}),function(){r.dispose(),A.remove()}}},[y,M]),y)?a().createElement(l.Space,{direction:"vertical",style:{height:"100%",overflowY:"auto",width:"100%"}},a().createElement(l.Flex,{justify:"center",style:{width:"100%"}},a().createElement("div",{style:G},a().createElement(l.Typography.Text,{style:{whiteSpace:"nowrap"},strong:!0},c("Select a definition")),a().createElement(l.Select,{showSearch:!0,value:y,options:null==s?void 0:s.data,style:{width:"100%"},fieldNames:{label:"name",value:"url"},onChange:R}))),a().createElement("div",{ref:b})):a().createElement(l.Flex,{align:"center",justify:"center",style:j},a().createElement(l.Spin,null))},b=n(944),s=function(){var e,t=(0,A.useAPIClient)(),n=(0,A.useCurrentAppInfo)(),r=(0,b.Bd)().t;return a().createElement(I,{apiClient:t,appName:null==n||null==(e=n.data)?void 0:e.name,t:r})}}}]);
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
"use strict";(self.webpackChunk_nocobase_plugin_api_doc_client_v2=self.webpackChunk_nocobase_plugin_api_doc_client_v2||[]).push([["552"],{712:function(e){e.exports="data:image/jpeg;base64,/9j/4QAYRXhpZgAASUkqAAgAAAAAAAAAAAAAAP/sABFEdWNreQABAAQAAAAAAAD/4QMxaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wLwA8P3hwYWNrZXQgYmVnaW49Iu+7vyIgaWQ9Ilc1TTBNcENlaGlIenJlU3pOVGN6a2M5ZCI/PiA8eDp4bXBtZXRhIHhtbG5zOng9ImFkb2JlOm5zOm1ldGEvIiB4OnhtcHRrPSJBZG9iZSBYTVAgQ29yZSA1LjYtYzExMSA3OS4xNTgzMjUsIDIwMTUvMDkvMTAtMDE6MTA6MjAgICAgICAgICI+IDxyZGY6UkRGIHhtbG5zOnJkZj0iaHR0cDovL3d3dy53My5vcmcvMTk5OS8wMi8yMi1yZGYtc3ludGF4LW5zIyI+IDxyZGY6RGVzY3JpcHRpb24gcmRmOmFib3V0PSIiIHhtbG5zOnhtcD0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wLyIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bXA6Q3JlYXRvclRvb2w9IkFkb2JlIFBob3Rvc2hvcCBDQyAyMDE1IChNYWNpbnRvc2gpIiB4bXBNTTpJbnN0YW5jZUlEPSJ4bXAuaWlkOkIxMjI0OTczNjdCMzExRTZCMkJDRTI0MDgxMDAyMTcxIiB4bXBNTTpEb2N1bWVudElEPSJ4bXAuZGlkOkIxMjI0OTc0NjdCMzExRTZCMkJDRTI0MDgxMDAyMTcxIj4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6QjEyMjQ5NzE2N0IzMTFFNkIyQ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MSIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDo3NjcyQkQ3QjY3QzUxMUU2QjJCQ0UyNDA4MTAwMjE3MSIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PvCS01IAAABMSURBVHjaYmR4/5+BFPBfAMFm/MBgx8RAGWCn1AAmSg34Q6kBDKMGMDCwICeMIemF/5QawEipAWwUhwEjMDvbAWlWkvVBwu8vQIABAEwBCph8U6c0AAAAAElFTkSuQmCC"},234:function(e){e.exports='data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20"><path d="M13.418 7.859a.695.695 0 0 1 .978 0 .68.68 0 0 1 0 .969l-3.908 3.83a.697.697 0 0 1-.979 0l-3.908-3.83a.68.68 0 0 1 0-.969.695.695 0 0 1 .978 0L10 11l3.418-3.141z"/></svg>'},779:function(e){e.exports='data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="10" height="8" viewBox="3 7 10 8"><path fill="%2341474E" fill-rule="evenodd" d="M6.333 15 3 11.667l1.333-1.334 2 2L11.667 7 13 8.333z"/></svg>'},153:function(e){e.exports='data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="16" height="15" aria-hidden="true"><path fill="%23fff" fill-rule="evenodd" d="M4 12h4v1H4v-1zm5-6H4v1h5V6zm2 3V7l-3 3 3 3v-2h5V9h-5zM6.5 8H4v1h2.5V8zM4 11h2.5v-1H4v1zm9 1h1v2c-.02.28-.11.52-.3.7-.19.18-.42.28-.7.3H3c-.55 0-1-.45-1-1V3c0-.55.45-1 1-1h3c0-1.11.89-2 2-2 1.11 0 2 .89 2 2h3c.55 0 1 .45 1 1v5h-1V5H3v9h10v-2zM4 4h8c0-.55-.45-1-1-1h-1c-.55 0-1-.45-1-1s-.45-1-1-1-1 .45-1 1-.45 1-1 1H5c-.55 0-1 .45-1 1z"/></svg>'},294:function(e){e.exports='data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg>'},240:function(e,t,n){n.r(t),n.d(t,{default:function(){return M}});var r=n(485),a=n(694),i=n(155),A=n.n(i),c=n(488),l=n(625),o=n(59),u=n(716),d=n.n(u);n(89);var g=n(401);function h(e,t){return null!=t&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t}function v(e){var t=e.closest("tr[data-param-name][data-param-in]"),n=null==t?void 0:t.getAttribute("data-param-name"),r=null==t?void 0:t.getAttribute("data-param-in");return n&&r?{paramName:n,paramIn:r}:null}function m(e){return null==e?"":String(e)}function p(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function b(e,t,n,r,a,i,A){try{var c=e[i](A),l=c.value}catch(e){n(e);return}c.done?t(l):Promise.resolve(l).then(r,a)}var s=function(){return localStorage.getItem(g.Fg)},I=function(e){var t,n=e.apiClient,r=e.appName,a=e.t,c=o.theme.useToken().token,u=(0,i.useRef)(null),I=(0,l.useRequest)(function(){var e;return(e=function(){return function(e,t){var n,r,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},A=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),c=Object.defineProperty;return c(A,"next",{value:l(0)}),c(A,"throw",{value:l(1)}),c(A,"return",{value:l(2)}),"function"==typeof Symbol&&c(A,Symbol.iterator,{value:function(){return this}}),A;function l(c){return function(l){var o=[c,l];if(n)throw TypeError("Generator is already executing.");for(;A&&(A=0,o[0]&&(i=0)),i;)try{if(n=1,r&&(a=2&o[0]?r.return:o[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,o[1])).done)return a;switch(r=0,a&&(o=[2&o[0],a.value]),o[0]){case 0:case 1:a=o;break;case 4:return i.label++,{value:o[1],done:!1};case 5:i.label++,r=o[1],o=[0];continue;case 7:o=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===o[0]||2===o[0])){i=0;continue}if(3===o[0]&&(!a||o[1]>a[0]&&o[1]<a[3])){i.label=o[1];break}if(6===o[0]&&i.label<a[1]){i.label=a[1],a=o;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(o);break}a[2]&&i.ops.pop(),i.trys.pop();continue}o=t.call(e,i)}catch(e){o=[6,e],r=0}finally{n=a=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}}}(this,function(e){switch(e.label){case 0:return[4,n.request({url:"swagger:getUrls"})];case 1:return[2,e.sent().data]}})},function(){var t=this,n=arguments;return new Promise(function(r,a){var i=e.apply(t,n);function A(e){b(i,r,a,A,c,"next",e)}function c(e){b(i,r,a,A,c,"throw",e)}A(void 0)})})()}).data,M=(0,i.useCallback)(function(e){var t=e.headers||{};return e.headers=t,t.Authorization||(Object.assign(t,n.getHeaders()),r&&(t["X-App"]=r),t.Authorization="Bearer ".concat(n.auth.getToken())),e},[n,r]),y=function(e){if(Array.isArray(e))return e}(t=(0,i.useState)(s()))||function(e){var t,n,r=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var a=[],i=!0,A=!1;try{for(r=r.call(e);!(i=(t=r.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){A=!0,n=e}finally{try{i||null==r.return||r.return()}finally{if(A)throw n}}return a}}(t)||function(e){if(e){if("string"==typeof e)return p(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return p(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),w=y[0],j=y[1],R=(0,i.useMemo)(function(){return{alignItems:"center",display:"flex",gap:c.marginXS,paddingBlock:c.padding,paddingInline:c.paddingLG,width:"100%"}},[c.marginXS,c.padding,c.paddingLG]),G=(0,i.useMemo)(function(){return{minHeight:c.controlHeightLG,width:"100%"}},[c.controlHeightLG]);return((0,i.useEffect)(function(){w&&localStorage.setItem(g.Fg,w)},[w]),(0,i.useEffect)(function(){var e;(null==I||null==(e=I.data)?void 0:e.length)&&(w&&I.data.find(function(e){return e.url===s()})||j(I.data[0].url))},[w,I]),(0,i.useEffect)(function(){if(u.current&&w){var e,t,n,r=document.createElement("div");u.current.appendChild(r);var a=(e=null,t=function(t){var n,r,a=t.target;if(h(a,HTMLInputElement)||h(a,HTMLTextAreaElement)){var i=v(a);i&&(n=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),r.forEach(function(t){var r;r=n[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}({},i),r=r={value:a.value,updatedAt:Date.now()},Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t.push.apply(t,n)}return t})(Object(r)).forEach(function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(r,e))}),e=n)}},n=function(e){var t=document.activeElement;return(h(t,HTMLInputElement)||h(t,HTMLTextAreaElement))&&r.contains(t)&&t.value===m(e)?v(t):null},r.addEventListener("input",t,!0),r.addEventListener("change",t,!0),{plugin:function(){return{statePlugins:{spec:{wrapActions:{changeParamByIdentity:function(t,r){return function(a,i,A,c){var l,o,u,d,g,h=n(A)||(!e||Date.now()-e.updatedAt>2e3||e.value!==m(A)?null:{paramName:e.paramName,paramIn:e.paramIn})||(u=null==i||null==(l=i.get)?void 0:l.call(i,"name"),d=null==i||null==(o=i.get)?void 0:o.call(i,"in"),"string"!=typeof u||"string"!=typeof d?null:{paramName:u,paramIn:d});return h&&(null==r||null==(g=r.specActions)?void 0:g.changeParam)?r.specActions.changeParam(a,h.paramName,h.paramIn,A,c):t(a,i,A,c)}}}}}}},dispose:function(){r.removeEventListener("input",t,!0),r.removeEventListener("change",t,!0)}});return d()({requestInterceptor:M,url:w,domNode:r,plugins:[a.plugin]}),function(){a.dispose(),r.remove()}}},[w,M]),w)?A().createElement(o.Space,{direction:"vertical",style:{height:"100%",overflowY:"auto",width:"100%"}},A().createElement(o.Flex,{justify:"center",style:{width:"100%"}},A().createElement("div",{style:R},A().createElement(o.Typography.Text,{style:{whiteSpace:"nowrap"},strong:!0},a("Select a definition")),A().createElement(o.Select,{showSearch:!0,value:w,options:null==I?void 0:I.data,style:{width:"100%"},fieldNames:{label:"name",value:"url"},onChange:j}))),A().createElement("div",{ref:u})):A().createElement(o.Flex,{align:"center",justify:"center",style:G},A().createElement(o.Spin,null))},M=function(){var e,t=(0,a.useFlowContext)().api,n=(0,r.useCurrentAppInfo)(),i=(0,c.kj)();return A().createElement(I,{apiClient:t,appName:null==n||null==(e=n.data)?void 0:e.name,t:i})}},488:function(e,t,n){n.d(t,{kj:function(){return i}});var r=n(694),a=n(401);function i(){var e=(0,r.useFlowEngine)();return function(t,n){return e.context.t(t,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),r.forEach(function(t){var r;r=n[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}({ns:[a.CU,"client"]},n))}}}}]);
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file is part of the NocoBase (R) project.
|
|
3
|
-
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
-
* Authors: NocoBase Team.
|
|
5
|
-
*
|
|
6
|
-
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
-
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
"use strict";(self.webpackChunk_nocobase_plugin_api_doc_client_v2=self.webpackChunk_nocobase_plugin_api_doc_client_v2||[]).push([["743"],{50:function(e,t,n){n.r(t),n.d(t,{default:function(){return p}});var r=n(694),i=n(155),l=n.n(i),o=n(401),a=n(488),u=n(240),c=n(375),s=n(59),d=function(e){var t=e.children,n=e.href,r=void 0===n?o.D9:n,a=e.previewTitle,u=s.theme.useToken().token,d=(0,i.useMemo)(function(){return{background:u.colorBgContainer,padding:u.paddingMD,position:"relative"}},[u.colorBgContainer,u.paddingMD]),p=(0,i.useMemo)(function(){return{insetBlockStart:0,insetInlineEnd:0,position:"absolute"}},[]);return l().createElement("div",{style:d},l().createElement("div",{style:p},l().createElement(s.Tooltip,{title:a},l().createElement("a",{href:r,target:"_blank",rel:"noreferrer","aria-label":a},l().createElement(s.Button,{size:"small",icon:l().createElement(c.RightOutlined,null)})))),t)},p=function(){var e=(0,r.useFlowContext)(),t=(0,a.kj)(),n=e.app.getRouteUrl(o.D9);return l().createElement(d,{href:n,previewTitle:t("Preview")},l().createElement(u.default,null))}}}]);
|