@nocobase/plugin-environment-variables 1.7.0-beta.9 → 1.7.0
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/LICENSE.txt +4 -4
- package/dist/client/index.js +1 -1
- package/dist/externalVersion.js +5 -3
- package/dist/locale/nl-NL.json +17 -0
- package/package.json +2 -2
package/LICENSE.txt
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
Updated Date:
|
|
1
|
+
Updated Date: April 1, 2025
|
|
2
2
|
|
|
3
3
|
NocoBase License Agreement
|
|
4
4
|
|
|
@@ -88,7 +88,7 @@ Except for Third-Party Open Source Software, the Company owns all copyrights, tr
|
|
|
88
88
|
|
|
89
89
|
6.6 Can sell plugins developed for Software in the Marketplace.
|
|
90
90
|
|
|
91
|
-
6.7 The User with
|
|
91
|
+
6.7 The User with a Professional or Enterprise Edition License can sell Upper Layer Application to their clients.
|
|
92
92
|
|
|
93
93
|
6.8 Not restricted by the AGPL-3.0 agreement.
|
|
94
94
|
|
|
@@ -106,9 +106,9 @@ Except for Third-Party Open Source Software, the Company owns all copyrights, tr
|
|
|
106
106
|
|
|
107
107
|
7.4 It is not allowed to provide any form of no-code, zero-code, low-code platform SaaS products to the public using the original or modified Software.
|
|
108
108
|
|
|
109
|
-
7.5 It is not allowed for the User withot
|
|
109
|
+
7.5 It is not allowed for the User withot a Professional or Enterprise Edition license to sell Upper Layer Application to clients without a Commercial license.
|
|
110
110
|
|
|
111
|
-
7.6 It is not allowed for the User with
|
|
111
|
+
7.6 It is not allowed for the User with a Professional or Enterprise Edition license to sell Upper Layer Application to clients without a Commercial license with access to further development and configuration.
|
|
112
112
|
|
|
113
113
|
7.7 It is not allowed to publicly sell plugins developed for Software outside of the Marketplace.
|
|
114
114
|
|
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("@formily/core"),require("@nocobase/client"),require("antd"),require("@ant-design/icons"),require("@formily/react"),require("react"),require("@formily/antd-v5")):"function"==typeof define&&define.amd?define("@nocobase/plugin-environment-variables",["@formily/core","@nocobase/client","antd","@ant-design/icons","@formily/react","react","@formily/antd-v5"],t):"object"==typeof exports?exports["@nocobase/plugin-environment-variables"]=t(require("@formily/core"),require("@nocobase/client"),require("antd"),require("@ant-design/icons"),require("@formily/react"),require("react"),require("@formily/antd-v5")):e["@nocobase/plugin-environment-variables"]=t(e["@formily/core"],e["@nocobase/client"],e.antd,e["@ant-design/icons"],e["@formily/react"],e.react,e["@formily/antd-v5"])}(self,function(e,t,n,r,o,a,l){return function(){"use strict";var i={482:function(e){e.exports=r},632:function(e){e.exports=l},563:function(t){t.exports=e},505:function(e){e.exports=o},772:function(e){e.exports=t},721:function(e){e.exports=n},156:function(e){e.exports=a}},u={};function c(e){var t=u[e];if(void 0!==t)return t.exports;var n=u[e]={exports:{}};return i[e](n,n.exports,c),n.exports}c.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return c.d(t,{a:t}),t},c.d=function(e,t){for(var n in t)c.o(t,n)&&!c.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},c.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},c.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var s={};c.r(s),c.d(s,{PluginEnvironmentVariablesClient:function(){return W},default:function(){return X}});var f=c("772"),p=c("505"),m=c("156"),d=c.n(m),b=(0,m.createContext)({}),y=function(e){var t=(0,f.useRequest)({url:"environmentVariables?paginate=false"});return d().createElement(b.Provider,{value:{variablesRequest:t}},e.children)},v=(0,p.observer)(function(e){return(0,f.useIsLoggedIn)()?d().createElement(y,e):d().createElement(d().Fragment,null,e.children)},{displayName:"EnvironmentVariablesAndSecretsProvider"}),h=c("482"),g=c("632"),x=c("563"),w=c("721"),E=/^[A-Za-z][A-Za-z0-9_]*$/,S=JSON.parse('{"u2":"@nocobase/plugin-environment-variables"}');function O(){var e=(0,f.useApp)();return function(t){return e.i18n.t(t,{ns:[S.u2,"client"]})}}function k(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 A(e){if(Array.isArray(e))return e}function j(e,t,n,r,o,a,l){try{var i=e[a](l),u=i.value}catch(e){n(e);return}i.done?t(u):Promise.resolve(u).then(r,o)}function q(e){return function(){var t=this,n=arguments;return new Promise(function(r,o){var a=e.apply(t,n);function l(e){j(a,r,o,l,i,"next",e)}function i(e){j(a,r,o,l,i,"throw",e)}l(void 0)})}}function I(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function P(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,o,a;r=e,o=t,a=n[t],o in r?Object.defineProperty(r,o,{value:a,enumerable:!0,configurable:!0,writable:!0}):r[o]=a})}return e}function C(e,t){return A(e)||function(e,t){var n,r,o=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=o){var a=[],l=!0,i=!1;try{for(o=o.call(e);!(l=(n=o.next()).done)&&(a.push(n.value),!t||a.length!==t);l=!0);}catch(e){i=!0,r=e}finally{try{!l&&null!=o.return&&o.return()}finally{if(i)throw r}}return a}}(e,t)||F(e,t)||I()}function F(e,t){if(e){if("string"==typeof e)return k(e,t);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 k(e,t)}}function R(e,t){var n,r,o,a,l={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return a={next:i(0),throw:i(1),return:i(2)},"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function i(a){return function(i){return function(a){if(n)throw TypeError("Generator is already executing.");for(;l;)try{if(n=1,r&&(o=2&a[0]?r.return:a[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,a[1])).done)return o;switch(r=0,o&&(a=[2&a[0],o.value]),a[0]){case 0:case 1:o=a;break;case 4:return l.label++,{value:a[1],done:!1};case 5:l.label++,r=a[1],a=[0];continue;case 7:a=l.ops.pop(),l.trys.pop();continue;default:if(!(o=(o=l.trys).length>0&&o[o.length-1])&&(6===a[0]||2===a[0])){l=0;continue}if(3===a[0]&&(!o||a[1]>o[0]&&a[1]<o[3])){l.label=a[1];break}if(6===a[0]&&l.label<o[1]){l.label=o[1],o=a;break}if(o&&l.label<o[2]){l.label=o[2],l.ops.push(a);break}o[2]&&l.ops.pop(),l.trys.pop();continue}a=t.call(e,l)}catch(e){a=[6,e],r=0}finally{n=o=0}if(5&a[0])throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}([a,i])}}}(0,x.registerValidateRules)({env_name_rule:function(e){return e?E.test(e)?"":"Only letters, numbers and underscores are allowed, and it must start with a letter.":""}});var T=(0,p.createSchemaField)({components:{FormItem:g.FormItem,Input:g.Input,Checkbox:g.Checkbox,Radio:g.Radio}}),V={type:"object",properties:{variables:{type:"string",title:'{{ t("Plain text") }}',"x-decorator":"FormItem","x-component":"Input.TextArea","x-component-props":{autoSize:{minRows:10,maxRows:20},placeholder:"FOO=aaa\nBAR=bbb\n "}},secret:{type:"string",title:'{{ t("Encrypted") }}',"x-decorator":"FormItem","x-component":"Input.TextArea","x-component-props":{autoSize:{minRows:10,maxRows:20},placeholder:"FOO=aaa\nBAR=bbb\n "}}}},B={type:"object",properties:{name:{type:"string",title:'{{ t("Name") }}',required:!0,"x-validator":{env_name_rule:!0},"x-decorator":"FormItem","x-component":"Input","x-disabled":"{{ !createOnly }}"},type:{type:"string",title:'{{ t("Type") }}',required:!0,"x-decorator":"FormItem","x-component":"Radio.Group",default:"default",enum:[{value:"default",label:'{{t("Plain text")}}'},{value:"secret",label:'{{t("Encrypted")}}'}]},value:{type:"string",title:'{{ t("Value") }}',required:!0,"x-decorator":"FormItem","x-component":"Input.TextArea"}}};function $(e){var t,n=e.request,r=e.setSelectRowKeys,o=w.App.useApp().modal,a=O(),l=(0,f.useAPIClient)(),i=n||{},u=i.data,c=i.loading,s=i.refresh,p=(0,f.useGlobalTheme)().theme,m={default:{label:a("Plain text"),color:"green"},secret:{label:a("Encrypted"),color:"red"}},b=l.resource("environmentVariables"),y=function(e){o.confirm({title:a("Delete variable"),content:a("Are you sure you want to delete it?"),onOk:function(){return q(function(){return R(this,function(t){switch(t.label){case 0:return[4,b.destroy({filterByTk:e.name})];case 1:return t.sent(),s(),[2]}})})()}})};var v=(t=q(function(e){var t;return R(this,function(r){return(t=(0,f.FormDrawer)({title:a("Edit")},"edit",function(){var r;return d().createElement(g.FormLayout,{layout:"vertical"},d().createElement(f.SchemaComponentOptions,{scope:{createOnly:!1,t:a}},d().createElement(T,{schema:B})),d().createElement(f.FormDrawer.Footer,null,d().createElement(g.FormButtonGroup,{align:"right"},d().createElement(g.Reset,{onClick:function(){t.close()}},a("Cancel")),d().createElement(g.Submit,{onSubmit:(r=q(function(t){return R(this,function(r){switch(r.label){case 0:return[4,l.request({url:"environmentVariables:update?filterByTk=".concat(e.name),method:"post",data:P({},t)})];case 1:return r.sent(),n.refresh(),[2]}})}),function(e){return r.apply(this,arguments)})},a("Submit")))))},p)).open({initialValues:P({},e)}),[2]})}),function(e){return t.apply(this,arguments)});return d().createElement("div",null,d().createElement(w.Table,{loading:c,size:"middle",rowKey:"name",dataSource:null==u?void 0:u.data,pagination:!1,columns:[{title:a("Name"),dataIndex:"name",ellipsis:!0},{title:a("Type"),dataIndex:"type",render:function(e){return d().createElement(w.Tag,{color:m[e].color},m[e].label)}},{title:a("Value"),ellipsis:!0,render:function(e){return d().createElement("div",null,"default"===e.type?e.value:"******")}},{title:a("Actions"),width:200,render:function(e){return d().createElement(w.Space,null,d().createElement("a",{onClick:function(){return v(e)}},a("Edit")),d().createElement("a",{onClick:function(){return y(e)}},a("Delete")))}}],rowSelection:{type:"checkbox",onChange:function(e,t){r(e)}}}))}function _(){var e,t,n,r=(0,f.useAPIClient)(),o=O(),a=w.App.useApp().modal,l=(0,m.useContext)(b).variablesRequest,i=C((0,m.useState)([]),2),u=i[0],c=i[1],s=r.resource("environmentVariables"),y=(0,f.useGlobalTheme)().theme;var v=(e=q(function(e){var t;return R(this,function(n){switch(n.label){case 0:return t=Object.entries(e).map(function(e){var t,n,r=C(e,2),o=r[0];return(t=r[1],n=o,t.trim().split("\n").map(function(e){var t,r=A(t=e.split("="))||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||F(t)||I(),o=r[0],a=r.slice(1);return o&&{name:o.trim(),value:a.join("=").trim(),type:"secret"===n?"secret":"default"}})).filter(Boolean)}),[4,r.request({url:"environmentVariables:create",method:"post",data:t.flat()})];case 1:return n.sent(),[2]}})}),function(t){return e.apply(this,arguments)}),x=[{name:"name",title:o("Name"),operators:[{label:'{{t("contains")}}',value:"$includes",selected:!0},{label:'{{t("does not contain")}}',value:"$notIncludes"},{label:'{{t("is")}}',value:"$eq"},{label:'{{t("is not")}}',value:"$ne"}],schema:{type:"string",title:o("Name"),"x-component":"Input"}},{name:"type",title:o("Type"),operators:[{label:'{{t("is")}}',value:"$match",selected:!0,schema:{"x-component":"Select","x-component-props":{mode:"tags"}}},{label:'{{t("is not")}}',value:"$notMatch",schema:{"x-component":"Select","x-component-props":{mode:"tags"}}}],schema:{type:"string",title:o("Type"),"x-component":"Select",enum:[{value:"default",label:'{{t("Plain text")}}'},{value:"secret",label:'{{t("Encrypted")}}'}]}},{name:"value",title:o("Value"),operators:[{label:'{{t("contains")}}',value:"$includes",selected:!0},{label:'{{t("does not contain")}}',value:"$notIncludes"},{label:'{{t("is")}}',value:"$eq"},{label:'{{t("is not")}}',value:"$ne"}],schema:{type:"string",title:o("Value"),"x-component":"Input"}}];return d().createElement("div",null,(null==l?void 0:null===(n=l.data)||void 0===n?void 0:null===(t=n.meta)||void 0===t?void 0:t.updated)&&d().createElement(w.Alert,{type:"warning",style:{marginBottom:"1.2em",alignItems:"center"},description:d().createElement("div",null,o("Variables and secrets have been updated. A restart is required for the changes to take effect.")," "),action:d().createElement(w.Button,{size:"middle",type:"primary",onClick:q(function(){return R(this,function(e){switch(e.label){case 0:return[4,r.resource("app").refresh()];case 1:return e.sent(),[2]}})})},o("Restart now"))}),d().createElement(w.Card,null,d().createElement("div",{style:{float:"left"}},d().createElement(f.SchemaComponent,{schema:{name:"filter",type:"object",title:'{{ t("Filter") }}',default:{$and:[{name:{$includes:""}}]},"x-component":"Filter.Action",enum:x,"x-use-component-props":function(){var e,t=(0,p.useField)(),n=l.run;return{options:x,onSubmit:(e=q(function(e){return R(this,function(r){return n(e),t.setValue(e),[2]})}),function(t){return e.apply(this,arguments)}),onReset:function(e){t.setValue(e)}}}},scope:{t:o}})),d().createElement(w.Flex,{justify:"end",style:{marginBottom:16}},d().createElement(w.Space,null,d().createElement(w.Button,{icon:d().createElement(h.ReloadOutlined,null),onClick:function(){var e;null==l||null===(e=l.refresh)||void 0===e||e.call(l)}},o("Refresh")),d().createElement(w.Button,{icon:d().createElement(h.DeleteOutlined,null),onClick:function(){u.length>0&&a.confirm({title:o("Delete variable"),content:o("Are you sure you want to delete it?"),onOk:function(){return q(function(){var e;return R(this,function(t){switch(t.label){case 0:return[4,s.destroy({filterByTk:u})];case 1:return t.sent(),null==l||null===(e=l.refresh)||void 0===e||e.call(l),[2]}})})()}})}},o("Delete")),d().createElement(w.Dropdown,{menu:{onClick:function(e){var t=(0,f.FormDrawer)({variable:o("Add variable"),bulk:o("Bulk import")}[e.key],"add-new",function(){var n;return d().createElement(g.FormLayout,{layout:"vertical"},d().createElement(f.SchemaComponentOptions,{scope:{createOnly:!0,t:o}},d().createElement(T,{schema:"bulk"===e.key?V:B})),d().createElement(f.FormDrawer.Footer,null,d().createElement(g.FormButtonGroup,{align:"right"},d().createElement(g.Reset,{onClick:function(){t.close()}},o("Cancel")),d().createElement(g.Submit,{onSubmit:(n=q(function(t){return R(this,function(n){switch(n.label){case 0:if("bulk"!==e.key)return[3,2];return[4,v(t)];case 1:return n.sent(),l.refresh(),[3,4];case 2:return[4,r.request({url:"environmentVariables:create",method:"post",data:P({},t)})];case 3:n.sent(),l.refresh(),n.label=4;case 4:return[2]}})}),function(e){return n.apply(this,arguments)})},o("Submit")))))},y);t.open({initialValues:{}}).then(console.log).catch(console.log)},items:[{key:"variable",label:o("Add variable")},{type:"divider"},{key:"bulk",label:o("Bulk import")}]}},d().createElement(w.Button,{type:"primary",icon:d().createElement(h.PlusOutlined,null)},o("Add new")," ",d().createElement(h.DownOutlined,null))))),d().createElement($,{request:l,setSelectRowKeys:c})))}function D(){return d().createElement(_,null)}function M(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}var G=function(){var e,t=O(),n=(0,m.useContext)(b).variablesRequest||{},r=n.data;return!n.loading&&(null==r?void 0:null===(e=r.data)||void 0===e?void 0:e.length)?{name:"$env",title:t("Variables and secrets"),value:"$env",label:t("Variables and secrets"),children:null==r?void 0:r.data.map(function(e){return{title:e.name,name:e.name,value:e.name,label:e.name,type:e.type}}).filter(Boolean)}:null},z=function(){var e,t,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],r=n.map(function(e){var t,n,r;return t={},n=e.name,r=e.value,n in t?Object.defineProperty(t,n,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[n]=r,t});return{name:"$env",ctx:(t=Object).assign.apply(t,[{}].concat(function(e){if(Array.isArray(e))return M(e)}(e=r)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return M(e,t);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 M(e,t)}}(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()))}},N=function(){var e,t=(0,m.useContext)(b).variablesRequest,n=t.data,r=t.loading,o=z(null==n?void 0:n.data);return!r&&(null==n?void 0:null===(e=n.data)||void 0===e?void 0:e.length)?o:null};function K(e,t,n,r,o,a,l){try{var i=e[a](l),u=i.value}catch(e){n(e);return}i.done?t(u):Promise.resolve(u).then(r,o)}function L(e,t,n){return(L=Q()?Reflect.construct:function(e,t,n){var r=[null];r.push.apply(r,t);var o=new(Function.bind.apply(e,r));return n&&J(o,n.prototype),o}).apply(null,arguments)}function U(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)}}function Z(e){return(Z=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function J(e,t){return(J=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function H(e){var t="function"==typeof Map?new Map:void 0;return(H=function(e){var n;if(null===e||(n=e,-1===Function.toString.call(n).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,r)}function r(){return L(e,arguments,Z(this).constructor)}return r.prototype=Object.create(e.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),J(r,e)})(e)}function Q(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(Q=function(){return!!e})()}var W=function(e){var t,n,r;function o(){var e,t,n;return!function(e,t){if(!(e instanceof t))throw TypeError("Cannot call a class as a function")}(this,o),e=this,t=o,n=arguments,t=Z(t),function(e,t){return t&&("object"===function(e){return e&&"undefined"!=typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}(t)||"function"==typeof t)?t:function(e){if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,Q()?Reflect.construct(t,n||[],Z(e).constructor):t.apply(e,n))}return!function(e,t){if("function"!=typeof t&&null!==t)throw TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&J(e,t)}(o,e),t=o,n=[{key:"load",value:function(){var e,t=this;return(e=function(){return function(e,t){var n,r,o,a,l={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return a={next:i(0),throw:i(1),return:i(2)},"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function i(a){return function(i){return function(a){if(n)throw TypeError("Generator is already executing.");for(;l;)try{if(n=1,r&&(o=2&a[0]?r.return:a[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,a[1])).done)return o;switch(r=0,o&&(a=[2&a[0],o.value]),a[0]){case 0:case 1:o=a;break;case 4:return l.label++,{value:a[1],done:!1};case 5:l.label++,r=a[1],a=[0];continue;case 7:a=l.ops.pop(),l.trys.pop();continue;default:if(!(o=(o=l.trys).length>0&&o[o.length-1])&&(6===a[0]||2===a[0])){l=0;continue}if(3===a[0]&&(!o||a[1]>o[0]&&a[1]<o[3])){l.label=a[1];break}if(6===a[0]&&l.label<o[1]){l.label=o[1],o=a;break}if(o&&l.label<o[2]){l.label=o[2],l.ops.push(a);break}o[2]&&l.ops.pop(),l.trys.pop();continue}a=t.call(e,l)}catch(e){a=[6,e],r=0}finally{n=o=0}if(5&a[0])throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}([a,i])}}}(this,function(e){return t.app.pluginSettingsManager.add("environment",{title:t.t("Variables and secrets"),icon:"TableOutlined",Component:D}),t.app.addGlobalVar("$env",G,N),t.app.use(v),[2]})},function(){var t=this,n=arguments;return new Promise(function(r,o){var a=e.apply(t,n);function l(e){K(a,r,o,l,i,"next",e)}function i(e){K(a,r,o,l,i,"throw",e)}l(void 0)})})()}}],U(t.prototype,n),o}(H(f.Plugin)),X=W;return s}()});
|
|
10
|
+
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("@formily/core"),require("react-i18next"),require("@nocobase/client"),require("react-router-dom"),require("@formily/antd-v5"),require("react"),require("@formily/react"),require("@ant-design/icons"),require("antd")):"function"==typeof define&&define.amd?define("@nocobase/plugin-environment-variables",["@formily/core","react-i18next","@nocobase/client","react-router-dom","@formily/antd-v5","react","@formily/react","@ant-design/icons","antd"],t):"object"==typeof exports?exports["@nocobase/plugin-environment-variables"]=t(require("@formily/core"),require("react-i18next"),require("@nocobase/client"),require("react-router-dom"),require("@formily/antd-v5"),require("react"),require("@formily/react"),require("@ant-design/icons"),require("antd")):e["@nocobase/plugin-environment-variables"]=t(e["@formily/core"],e["react-i18next"],e["@nocobase/client"],e["react-router-dom"],e["@formily/antd-v5"],e.react,e["@formily/react"],e["@ant-design/icons"],e.antd)}(self,function(e,t,n,r,o,a,l,i,u){return function(){"use strict";var c={482:function(e){e.exports=i},632:function(e){e.exports=o},563:function(t){t.exports=e},505:function(e){e.exports=l},772:function(e){e.exports=n},721:function(e){e.exports=u},156:function(e){e.exports=a},238:function(e){e.exports=t},128:function(e){e.exports=r}},s={};function f(e){var t=s[e];if(void 0!==t)return t.exports;var n=s[e]={exports:{}};return c[e](n,n.exports,f),n.exports}f.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return f.d(t,{a:t}),t},f.d=function(e,t){for(var n in t)f.o(t,n)&&!f.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},f.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},f.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var p={};return!function(){f.r(p),f.d(p,{default:function(){return L},PluginEnvironmentVariablesClient:function(){return z}});var e=f(772),t=f(505),n=f(156),r=f.n(n),o=(0,n.createContext)({}),a=function(t){var n=(0,e.useRequest)({url:"environmentVariables?paginate=false"});return r().createElement(o.Provider,{value:{variablesRequest:n}},t.children)},l=(0,t.observer)(function(t){return(0,e.useIsLoggedIn)()?r().createElement(a,t):r().createElement(r().Fragment,null,t.children)},{displayName:"EnvironmentVariablesAndSecretsProvider"}),i=f(482),u=f(632),c=f(563),s=f(128),m=f(721),d=f(238),b=/^[A-Za-z][A-Za-z0-9_]*$/,y=JSON.parse('{"u2":"@nocobase/plugin-environment-variables"}');function v(){var t=(0,e.useApp)();return function(e){return t.i18n.t(e,{ns:[y.u2,"client"]})}}function h(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 g(e){if(Array.isArray(e))return e}function x(e,t,n,r,o,a,l){try{var i=e[a](l),u=i.value}catch(e){n(e);return}i.done?t(u):Promise.resolve(u).then(r,o)}function w(e){return function(){var t=this,n=arguments;return new Promise(function(r,o){var a=e.apply(t,n);function l(e){x(a,r,o,l,i,"next",e)}function i(e){x(a,r,o,l,i,"throw",e)}l(void 0)})}}function E(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function S(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}function O(e,t){return g(e)||function(e,t){var n,r,o=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=o){var a=[],l=!0,i=!1;try{for(o=o.call(e);!(l=(n=o.next()).done)&&(a.push(n.value),!t||a.length!==t);l=!0);}catch(e){i=!0,r=e}finally{try{l||null==o.return||o.return()}finally{if(i)throw r}}return a}}(e,t)||k(e,t)||E()}function k(e,t){if(e){if("string"==typeof e)return h(e,t);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 h(e,t)}}function A(e,t){var n,r,o,a,l={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return a={next:i(0),throw:i(1),return:i(2)},"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function i(a){return function(i){var u=[a,i];if(n)throw TypeError("Generator is already executing.");for(;l;)try{if(n=1,r&&(o=2&u[0]?r.return:u[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,u[1])).done)return o;switch(r=0,o&&(u=[2&u[0],o.value]),u[0]){case 0:case 1:o=u;break;case 4:return l.label++,{value:u[1],done:!1};case 5:l.label++,r=u[1],u=[0];continue;case 7:u=l.ops.pop(),l.trys.pop();continue;default:if(!(o=(o=l.trys).length>0&&o[o.length-1])&&(6===u[0]||2===u[0])){l=0;continue}if(3===u[0]&&(!o||u[1]>o[0]&&u[1]<o[3])){l.label=u[1];break}if(6===u[0]&&l.label<o[1]){l.label=o[1],o=u;break}if(o&&l.label<o[2]){l.label=o[2],l.ops.push(u);break}o[2]&&l.ops.pop(),l.trys.pop();continue}u=t.call(e,l)}catch(e){u=[6,e],r=0}finally{n=o=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}(0,c.registerValidateRules)({env_name_rule:function(e){return e?b.test(e)?"":"Only letters, numbers and underscores are allowed, and it must start with a letter.":""}});var j=(0,t.createSchemaField)({components:{FormItem:u.FormItem,Input:u.Input,Checkbox:u.Checkbox,Radio:u.Radio}}),q={type:"object",properties:{variables:{type:"string",title:'{{ t("Plain text") }}',"x-decorator":"FormItem","x-component":"Input.TextArea","x-component-props":{autoSize:{minRows:10,maxRows:20},placeholder:"FOO=aaa\nBAR=bbb\n "}},secret:{type:"string",title:'{{ t("Encrypted") }}',"x-decorator":"FormItem","x-component":"Input.TextArea","x-component-props":{autoSize:{minRows:10,maxRows:20},placeholder:"FOO=aaa\nBAR=bbb\n "}}}},I={type:"object",properties:{name:{type:"string",title:'{{ t("Name") }}',required:!0,"x-validator":{env_name_rule:!0},"x-decorator":"FormItem","x-component":"Input","x-disabled":"{{ !createOnly }}"},type:{type:"string",title:'{{ t("Type") }}',required:!0,"x-decorator":"FormItem","x-component":"Radio.Group",default:"default",enum:[{value:"default",label:'{{t("Plain text")}}'},{value:"secret",label:'{{t("Encrypted")}}'}]},value:{type:"string",title:'{{ t("Value") }}',required:!0,"x-decorator":"FormItem","x-component":"Input.TextArea"}}};function C(t){var n,o=t.request,a=t.setSelectRowKeys,l=m.App.useApp().modal,i=v(),c=(0,e.useAPIClient)(),s=o||{},f=s.data,p=s.loading,d=s.refresh,b=(0,e.useGlobalTheme)().theme,y={default:{label:i("Plain text"),color:"green"},secret:{label:i("Encrypted"),color:"red"}},h=c.resource("environmentVariables"),g=function(e){l.confirm({title:i("Delete variable"),content:i("Are you sure you want to delete it?"),onOk:function(){return w(function(){return A(this,function(t){switch(t.label){case 0:return[4,h.destroy({filterByTk:e.name})];case 1:return t.sent(),d(),[2]}})})()}})},x=(n=w(function(t){var n;return A(this,function(a){return(n=(0,e.FormDrawer)({title:i("Edit")},"edit",function(){var a;return r().createElement(u.FormLayout,{layout:"vertical"},r().createElement(e.SchemaComponentOptions,{scope:{createOnly:!1,t:i}},r().createElement(j,{schema:I})),r().createElement(e.FormDrawer.Footer,null,r().createElement(u.FormButtonGroup,{align:"right"},r().createElement(u.Reset,{onClick:function(){n.close()}},i("Cancel")),r().createElement(u.Submit,{onSubmit:(a=w(function(e){return A(this,function(n){switch(n.label){case 0:return[4,c.request({url:"environmentVariables:update?filterByTk=".concat(t.name),method:"post",data:S({},e)})];case 1:return n.sent(),o.refresh(),[2]}})}),function(e){return a.apply(this,arguments)})},i("Submit")))))},b)).open({initialValues:S({},t)}),[2]})}),function(e){return n.apply(this,arguments)});return r().createElement("div",null,r().createElement(m.Table,{loading:p,size:"middle",rowKey:"name",dataSource:null==f?void 0:f.data,pagination:!1,columns:[{title:i("Name"),dataIndex:"name",ellipsis:!0},{title:i("Type"),dataIndex:"type",render:function(e){return r().createElement(m.Tag,{color:y[e].color},y[e].label)}},{title:i("Value"),ellipsis:!0,render:function(e){return r().createElement("div",null,"default"===e.type?e.value:"******")}},{title:i("Actions"),width:200,render:function(e){return r().createElement(m.Space,null,r().createElement("a",{onClick:function(){return x(e)}},i("Edit")),r().createElement("a",{onClick:function(){return g(e)}},i("Delete")))}}],rowSelection:{type:"checkbox",onChange:function(e,t){a(e)}}}))}function F(){var a,l,c,f=(0,e.useAPIClient)(),p=v(),b=m.App.useApp().modal,y=(0,n.useContext)(o).variablesRequest,h=O((0,n.useState)([]),2),x=h[0],F=h[1],P=f.resource("environmentVariables"),R=(0,e.useGlobalTheme)().theme,T=(0,s.useLocation)();(0,n.useEffect)(function(){var e=y.run,t=y.params;(null==t?void 0:t.length)&&e()},[T.key]);var V=(a=w(function(e){var t;return A(this,function(n){switch(n.label){case 0:return t=Object.entries(e).map(function(e){var t,n=O(e,2),r=n[0];return(t=n[1],t.trim().split("\n").map(function(e){var t,n=g(t=e.split("="))||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||k(t)||E(),o=n[0],a=n.slice(1);return o&&{name:o.trim(),value:a.join("=").trim(),type:"secret"===r?"secret":"default"}})).filter(Boolean)}),[4,f.request({url:"environmentVariables:create",method:"post",data:t.flat()})];case 1:return n.sent(),[2]}})}),function(e){return a.apply(this,arguments)}),$=[{name:"name",title:p("Name"),operators:[{label:'{{t("contains")}}',value:"$includes",selected:!0},{label:'{{t("does not contain")}}',value:"$notIncludes"},{label:'{{t("is")}}',value:"$eq"},{label:'{{t("is not")}}',value:"$ne"}],schema:{type:"string",title:p("Name"),"x-component":"Input"}},{name:"type",title:p("Type"),operators:[{label:'{{t("is")}}',value:"$match",selected:!0,schema:{"x-component":"Select","x-component-props":{mode:"tags"}}},{label:'{{t("is not")}}',value:"$notMatch",schema:{"x-component":"Select","x-component-props":{mode:"tags"}}}],schema:{type:"string",title:p("Type"),"x-component":"Select",enum:[{value:"default",label:'{{t("Plain text")}}'},{value:"secret",label:'{{t("Encrypted")}}'}]}},{name:"value",title:p("Value"),operators:[{label:'{{t("contains")}}',value:"$includes",selected:!0},{label:'{{t("does not contain")}}',value:"$notIncludes"},{label:'{{t("is")}}',value:"$eq"},{label:'{{t("is not")}}',value:"$ne"}],schema:{type:"string",title:p("Value"),"x-component":"Input"}}];return r().createElement("div",null,(null==y||null==(c=y.data)||null==(l=c.meta)?void 0:l.updated)&&r().createElement(m.Alert,{type:"warning",style:{marginBottom:"1.2em",alignItems:"center"},description:r().createElement("div",null,p("Variables and secrets have been updated. A restart is required for the changes to take effect.")," "),action:r().createElement(m.Button,{size:"middle",type:"primary",onClick:w(function(){return A(this,function(e){switch(e.label){case 0:return[4,f.resource("app").refresh()];case 1:return e.sent(),[2]}})})},p("Restart now"))}),r().createElement(m.Card,null,r().createElement("div",{style:{float:"left"}},r().createElement(e.SchemaComponent,{schema:{name:"filter",type:"object",title:'{{ t("Filter") }}',default:{$and:[{name:{$includes:""}}]},"x-component":"Filter.Action","x-component-props":{icon:"FilterOutlined"},enum:$,"x-use-component-props":function(){var n,r=(0,t.useField)(),o=y.run,a=(0,d.useTranslation)().t;return{options:$,onSubmit:(n=w(function(t){var n,l;return A(this,function(i){return o(t),r.setValue(t),(null==(l=(null==(n=(0,e.removeNullCondition)(null==t?void 0:t.filter))?void 0:n.$and)||(null==n?void 0:n.$or))?void 0:l.length)?r.title=a("{{count}} filter items",{count:(null==l?void 0:l.length)||0}):r.title=a("Filter"),[2]})}),function(e){return n.apply(this,arguments)}),onReset:function(e){r.setValue(e)}}}},scope:{t:p}})),r().createElement(m.Flex,{justify:"end",style:{marginBottom:16}},r().createElement(m.Space,null,r().createElement(m.Button,{icon:r().createElement(i.ReloadOutlined,null),onClick:function(){var e;null==y||null==(e=y.refresh)||e.call(y)}},p("Refresh")),r().createElement(m.Button,{icon:r().createElement(i.DeleteOutlined,null),onClick:function(){x.length>0&&b.confirm({title:p("Delete variable"),content:p("Are you sure you want to delete it?"),onOk:function(){return w(function(){var e;return A(this,function(t){switch(t.label){case 0:return[4,P.destroy({filterByTk:x})];case 1:return t.sent(),null==y||null==(e=y.refresh)||e.call(y),[2]}})})()}})}},p("Delete")),r().createElement(m.Dropdown,{menu:{onClick:function(t){var n=(0,e.FormDrawer)({variable:p("Add variable"),bulk:p("Bulk import")}[t.key],"add-new",function(){var o;return r().createElement(u.FormLayout,{layout:"vertical"},r().createElement(e.SchemaComponentOptions,{scope:{createOnly:!0,t:p}},r().createElement(j,{schema:"bulk"===t.key?q:I})),r().createElement(e.FormDrawer.Footer,null,r().createElement(u.FormButtonGroup,{align:"right"},r().createElement(u.Reset,{onClick:function(){n.close()}},p("Cancel")),r().createElement(u.Submit,{onSubmit:(o=w(function(e){return A(this,function(n){switch(n.label){case 0:if("bulk"!==t.key)return[3,2];return[4,V(e)];case 1:return n.sent(),y.refresh(),[3,4];case 2:return[4,f.request({url:"environmentVariables:create",method:"post",data:S({},e)})];case 3:n.sent(),y.refresh(),n.label=4;case 4:return[2]}})}),function(e){return o.apply(this,arguments)})},p("Submit")))))},R);n.open({initialValues:{}}).then(console.log).catch(console.log)},items:[{key:"variable",label:p("Add variable")},{type:"divider"},{key:"bulk",label:p("Bulk import")}]}},r().createElement(m.Button,{type:"primary",icon:r().createElement(i.PlusOutlined,null)},p("Add new")," ",r().createElement(i.DownOutlined,null))))),r().createElement(C,{request:y,setSelectRowKeys:F})))}function P(){return r().createElement(F,null)}function R(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}var T=function(){var e,t=v(),r=(0,n.useContext)(o).variablesRequest||{},a=r.data;return!r.loading&&(null==a||null==(e=a.data)?void 0:e.length)?{name:"$env",title:t("Variables and secrets"),value:"$env",label:t("Variables and secrets"),children:null==a?void 0:a.data.map(function(e){return{title:e.name,name:e.name,value:e.name,label:e.name,type:e.type}}).filter(Boolean)}:null},V=function(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],n=t.map(function(e){var t,n,r;return t={},n=e.name,r=e.value,n in t?Object.defineProperty(t,n,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[n]=r,t});return{name:"$env",ctx:(e=Object).assign.apply(e,[{}].concat(function(e){if(Array.isArray(e))return R(e)}(n)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(n)||function(e,t){if(e){if("string"==typeof e)return R(e,void 0);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 R(e,t)}}(n)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()))}},$=function(){var e,t=(0,n.useContext)(o).variablesRequest,r=t.data,a=t.loading,l=V(null==r?void 0:r.data);return!a&&(null==r||null==(e=r.data)?void 0:e.length)?l:null};function B(e,t,n,r,o,a,l){try{var i=e[a](l),u=i.value}catch(e){n(e);return}i.done?t(u):Promise.resolve(u).then(r,o)}function _(e,t,n){return(_=N()?Reflect.construct:function(e,t,n){var r=[null];r.push.apply(r,t);var o=new(Function.bind.apply(e,r));return n&&M(o,n.prototype),o}).apply(null,arguments)}function D(e){return(D=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function M(e,t){return(M=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function G(e){var t="function"==typeof Map?new Map:void 0;return(G=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 _(e,arguments,D(this).constructor)}return n.prototype=Object.create(e.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),M(n,e)})(e)}function N(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(N=function(){return!!e})()}var z=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=D(e),function(e,t){var n;if(t&&("object"==((n=t)&&"undefined"!=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,N()?Reflect.construct(e,t||[],D(this).constructor):e.apply(this,t))}return n.prototype=Object.create(e&&e.prototype,{constructor:{value:n,writable:!0,configurable:!0}}),e&&M(n,e),t=[{key:"load",value:function(){var e,t=this;return(e=function(){return function(e,t){var n,r,o,a,l={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return a={next:i(0),throw:i(1),return:i(2)},"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function i(a){return function(i){var u=[a,i];if(n)throw TypeError("Generator is already executing.");for(;l;)try{if(n=1,r&&(o=2&u[0]?r.return:u[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,u[1])).done)return o;switch(r=0,o&&(u=[2&u[0],o.value]),u[0]){case 0:case 1:o=u;break;case 4:return l.label++,{value:u[1],done:!1};case 5:l.label++,r=u[1],u=[0];continue;case 7:u=l.ops.pop(),l.trys.pop();continue;default:if(!(o=(o=l.trys).length>0&&o[o.length-1])&&(6===u[0]||2===u[0])){l=0;continue}if(3===u[0]&&(!o||u[1]>o[0]&&u[1]<o[3])){l.label=u[1];break}if(6===u[0]&&l.label<o[1]){l.label=o[1],o=u;break}if(o&&l.label<o[2]){l.label=o[2],l.ops.push(u);break}o[2]&&l.ops.pop(),l.trys.pop();continue}u=t.call(e,l)}catch(e){u=[6,e],r=0}finally{n=o=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}(this,function(e){return t.app.pluginSettingsManager.add("environment",{title:t.t("Variables and secrets"),icon:"TableOutlined",Component:P}),t.app.addGlobalVar("$env",T,$),t.app.use(l),[2]})},function(){var t=this,n=arguments;return new Promise(function(r,o){var a=e.apply(t,n);function l(e){B(a,r,o,l,i,"next",e)}function i(e){B(a,r,o,l,i,"throw",e)}l(void 0)})})()}}],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}(G(e.Plugin)),L=z}(),p}()});
|
package/dist/externalVersion.js
CHANGED
|
@@ -9,12 +9,14 @@
|
|
|
9
9
|
|
|
10
10
|
module.exports = {
|
|
11
11
|
"@formily/react": "2.3.0",
|
|
12
|
-
"@nocobase/client": "1.7.0
|
|
12
|
+
"@nocobase/client": "1.7.0",
|
|
13
13
|
"react": "18.2.0",
|
|
14
|
-
"@nocobase/server": "1.7.0
|
|
14
|
+
"@nocobase/server": "1.7.0",
|
|
15
15
|
"@ant-design/icons": "5.6.1",
|
|
16
16
|
"@formily/antd-v5": "1.2.3",
|
|
17
17
|
"@formily/core": "2.3.0",
|
|
18
|
+
"react-router-dom": "6.28.1",
|
|
18
19
|
"antd": "5.24.2",
|
|
19
|
-
"
|
|
20
|
+
"react-i18next": "11.18.6",
|
|
21
|
+
"@nocobase/database": "1.7.0"
|
|
20
22
|
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
{
|
|
2
|
+
"Environment": "Omgeving",
|
|
3
|
+
"Variables and secrets": "Variabelen en geheimen",
|
|
4
|
+
"Variables": "Variabelen",
|
|
5
|
+
"Secrets": "Geheimen",
|
|
6
|
+
"Add variable": "Variabele toevoegen",
|
|
7
|
+
"Bulk import": "Bulk importeren",
|
|
8
|
+
"Name": "Naam",
|
|
9
|
+
"Value": "Waarde",
|
|
10
|
+
"Type": "Type",
|
|
11
|
+
"Plain text": "Tekst",
|
|
12
|
+
"Encrypted": "Versleuteld",
|
|
13
|
+
"Delete variable": "Variabele verwijderen",
|
|
14
|
+
"Restart now": "Nu herstarten",
|
|
15
|
+
"Variables and secrets have been updated. A restart is required for the changes to take effect.": "Variabelen en geheimen zijn bijgewerkt. Een herstart is vereist voor de wijzigingen om van kracht te worden."
|
|
16
|
+
}
|
|
17
|
+
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nocobase/plugin-environment-variables",
|
|
3
|
-
"version": "1.7.0
|
|
3
|
+
"version": "1.7.0",
|
|
4
4
|
"main": "dist/server/index.js",
|
|
5
5
|
"peerDependencies": {
|
|
6
6
|
"@nocobase/client": "1.x",
|
|
@@ -16,5 +16,5 @@
|
|
|
16
16
|
"keywords": [
|
|
17
17
|
"System management"
|
|
18
18
|
],
|
|
19
|
-
"gitHead": "
|
|
19
|
+
"gitHead": "767ae089e404a104d718962272289c0bec01803a"
|
|
20
20
|
}
|