@digi-frontend/dgate-api-documentation 1.0.33 → 1.0.34
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/_virtual/index3.js +1 -1
- package/dist/_virtual/index4.js +1 -1
- package/dist/_virtual/index5.js +1 -1
- package/dist/_virtual/index6.js +1 -1
- package/dist/node_modules/toposort/index.js +1 -1
- package/dist/node_modules/yup/index.esm.js +1 -1
- package/dist/src/components/LivePreview/LivePreview.js +1 -1
- package/dist/src/components/LivePreview/LivePreview.js.map +1 -1
- package/dist/styles.css +403 -403
- package/package.json +1 -1
- package/src/components/LivePreview/LivePreview.tsx +11 -4
package/dist/_virtual/index3.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{__require as r}from"../node_modules/property-expr/index.js";var e=r();export{e as p};
|
|
2
2
|
//# sourceMappingURL=index3.js.map
|
package/dist/_virtual/index4.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
import{__require as e}from"../node_modules/tiny-case/index.js";var r=e();export{r as t};
|
|
2
2
|
//# sourceMappingURL=index4.js.map
|
package/dist/_virtual/index5.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__require as
|
|
1
|
+
import{getDefaultExportFromCjs as o}from"./_commonjsHelpers.js";import{__require as r}from"../node_modules/toposort/index.js";var e=o(r());export{e as default};
|
|
2
2
|
//# sourceMappingURL=index5.js.map
|
package/dist/_virtual/index6.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
var e={exports:{}};export{e as __module};
|
|
2
2
|
//# sourceMappingURL=index6.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__module as r}from"../../_virtual/
|
|
1
|
+
import{__module as r}from"../../_virtual/index6.js";var e;function n(){if(e)return r.exports;function n(r,e){var n=r.length,t=new Array(n),o={},a=n,i=function(r){for(var e=new Map,n=0,t=r.length;n<t;n++){var o=r[n];e.has(o[0])||e.set(o[0],new Set),e.has(o[1])||e.set(o[1],new Set),e.get(o[0]).add(o[1])}return e}(e),d=function(r){for(var e=new Map,n=0,t=r.length;n<t;n++)e.set(r[n],n);return e}(r);for(e.forEach((function(r){if(!d.has(r[0])||!d.has(r[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")}));a--;)o[a]||f(r[a],a,new Set);return t;function f(r,e,a){if(a.has(r)){var s;try{s=", node was:"+JSON.stringify(r)}catch(r){s=""}throw new Error("Cyclic dependency"+s)}if(!d.has(r))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(r));if(!o[e]){o[e]=!0;var u=i.get(r)||new Set;if(e=(u=Array.from(u)).length){a.add(r);do{var w=u[--e];f(w,d.get(w),a)}while(e);a.delete(r)}t[--n]=r}}}return e=1,r.exports=function(r){return n(function(r){for(var e=new Set,n=0,t=r.length;n<t;n++){var o=r[n];e.add(o[0]),e.add(o[1])}return Array.from(e)}(r),r)},r.exports.array=n,r.exports}export{n as __require};
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{p as e}from"../../_virtual/index6.js";import{t}from"../../_virtual/index5.js";import s from"../../_virtual/index3.js";const r=Object.prototype.toString,n=Error.prototype.toString,i=RegExp.prototype.toString,a="undefined"!=typeof Symbol?Symbol.prototype.toString:()=>"",o=/^Symbol\((.*)\)(.*)$/;function l(e,t=!1){if(null==e||!0===e||!1===e)return""+e;const s=typeof e;if("number"===s)return function(e){return e!=+e?"NaN":0===e&&1/e<0?"-0":""+e}(e);if("string"===s)return t?`"${e}"`:e;if("function"===s)return"[Function "+(e.name||"anonymous")+"]";if("symbol"===s)return a.call(e).replace(o,"Symbol($1)");const l=r.call(e).slice(8,-1);return"Date"===l?isNaN(e.getTime())?""+e:e.toISOString(e):"Error"===l||e instanceof Error?"["+n.call(e)+"]":"RegExp"===l?i.call(e):null}function u(e,t){let s=l(e,t);return null!==s?s:JSON.stringify(e,(function(e,s){let r=l(this[e],t);return null!==r?r:s}),2)}function c(e){return null==e?[]:[].concat(e)}let h,p,d,f=/\$\{\s*(\w+)\s*\}/g;h=Symbol.toStringTag;class m{constructor(e,t,s,r){this.name=void 0,this.message=void 0,this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=void 0,this.inner=void 0,this[h]="Error",this.name="ValidationError",this.value=t,this.path=s,this.type=r,this.errors=[],this.inner=[],c(e).forEach((e=>{if(y.isError(e)){this.errors.push(...e.errors);const t=e.inner.length?e.inner:[e];this.inner.push(...t)}else this.errors.push(e)})),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0]}}p=Symbol.hasInstance,d=Symbol.toStringTag;class y extends Error{static formatError(e,t){const s=t.label||t.path||"this";return t=Object.assign({},t,{path:s,originalPath:t.path}),"string"==typeof e?e.replace(f,((e,s)=>u(t[s]))):"function"==typeof e?e(t):e}static isError(e){return e&&"ValidationError"===e.name}constructor(e,t,s,r,n){const i=new m(e,t,s,r);if(n)return i;super(),this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=[],this.inner=[],this[d]="Error",this.name=i.name,this.message=i.message,this.type=i.type,this.value=i.value,this.path=i.path,this.errors=i.errors,this.inner=i.inner,Error.captureStackTrace&&Error.captureStackTrace(this,y)}static[p](e){return m[Symbol.hasInstance](e)||super[Symbol.hasInstance](e)}}let v={default:"${path} is invalid",required:"${path} is a required field",defined:"${path} must be defined",notNull:"${path} cannot be null",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:e,type:t,value:s,originalValue:r})=>{const n=null!=r&&r!==s?` (cast from the value \`${u(r,!0)}\`).`:".";return"mixed"!==t?`${e} must be a \`${t}\` type, but the final value was: \`${u(s,!0)}\``+n:`${e} must match the configured type. The validated value was: \`${u(s,!0)}\``+n}},g={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",datetime:"${path} must be a valid ISO date-time",datetime_precision:"${path} must be a valid ISO date-time with a sub-second precision of exactly ${precision} digits",datetime_offset:'${path} must be a valid ISO date-time with UTC "Z" timezone',trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},b={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},F={isValue:"${path} field must be ${value}"},_={noUnknown:"${path} field has unspecified keys: ${unknown}",exact:"${path} object contains unknown properties: ${properties}"},w={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"},x={notType:e=>{const{path:t,value:s,spec:r}=e,n=r.types.length;if(Array.isArray(s)){if(s.length<n)return`${t} tuple value has too few items, expected a length of ${n} but got ${s.length} for value: \`${u(s,!0)}\``;if(s.length>n)return`${t} tuple value has too many items, expected a length of ${n} but got ${s.length} for value: \`${u(s,!0)}\``}return y.formatError(v.notType,e)}};Object.assign(Object.create(null),{mixed:v,string:g,number:{min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},date:b,object:_,array:w,boolean:F,tuple:x});const T=e=>e&&e.__isYupSchema__;class ${static fromOptions(e,t){if(!t.then&&!t.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:s,then:r,otherwise:n}=t,i="function"==typeof s?s:(...e)=>e.every((e=>e===s));return new $(e,((e,t)=>{var s;let a=i(...e)?r:n;return null!=(s=null==a?void 0:a(t))?s:t}))}constructor(e,t){this.fn=void 0,this.refs=e,this.refs=e,this.fn=t}resolve(e,t){let s=this.refs.map((e=>e.getValue(null==t?void 0:t.value,null==t?void 0:t.parent,null==t?void 0:t.context))),r=this.fn(s,e,t);if(void 0===r||r===e)return e;if(!T(r))throw new TypeError("conditions must return a schema object");return r.resolve(t)}}const O="$",k=".";class E{constructor(t,s={}){if(this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,"string"!=typeof t)throw new TypeError("ref must be a string, got: "+t);if(this.key=t.trim(),""===t)throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===O,this.isValue=this.key[0]===k,this.isSibling=!this.isContext&&!this.isValue;let r=this.isContext?O:this.isValue?k:"";this.path=this.key.slice(r.length),this.getter=this.path&&e.getter(this.path,!0),this.map=s.map}getValue(e,t,s){let r=this.isContext?s:this.isValue?e:t;return this.getter&&(r=this.getter(r||{})),this.map&&(r=this.map(r)),r}cast(e,t){return this.getValue(e,null==t?void 0:t.parent,null==t?void 0:t.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(e){return e&&e.__isYupRef}}E.prototype.__isYupRef=!0;const S=e=>null==e;function j(e){function t({value:t,path:s="",options:r,originalValue:n,schema:i},a,o){const{name:l,test:u,params:c,message:h,skipAbsent:p}=e;let{parent:d,context:f,abortEarly:m=i.spec.abortEarly,disableStackTrace:v=i.spec.disableStackTrace}=r;function g(e){return E.isRef(e)?e.getValue(t,d,f):e}function b(e={}){const r=Object.assign({value:t,originalValue:n,label:i.spec.label,path:e.path||s,spec:i.spec,disableStackTrace:e.disableStackTrace||v},c,e.params);for(const e of Object.keys(r))r[e]=g(r[e]);const a=new y(y.formatError(e.message||h,r),t,r.path,e.type||l,r.disableStackTrace);return a.params=r,a}const F=m?a:o;let _={path:s,parent:d,type:l,from:r.from,createError:b,resolve:g,options:r,originalValue:n,schema:i};const w=e=>{y.isError(e)?F(e):e?o(null):F(b())},x=e=>{y.isError(e)?F(e):a(e)};if(p&&S(t))return w(!0);let T;try{var $;if(T=u.call(_,t,_),"function"==typeof(null==($=T)?void 0:$.then)){if(r.sync)throw new Error(`Validation test of type: "${_.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`);return Promise.resolve(T).then(w,x)}}catch(e){return void x(e)}w(T)}return t.OPTIONS=e,t}function A(t,s,r,n=r){let i,a,o;return s?(e.forEach(s,((e,l,u)=>{let c=l?e.slice(1,e.length-1):e,h="tuple"===(t=t.resolve({context:n,parent:i,value:r})).type,p=u?parseInt(c,10):0;if(t.innerType||h){if(h&&!u)throw new Error(`Yup.reach cannot implicitly index into a tuple type. the path part "${o}" must contain an index to the tuple element, e.g. "${o}[0]"`);if(r&&p>=r.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${e}, in the path: ${s}. because there is no value at that index. `);i=r,r=r&&r[p],t=h?t.spec.types[p]:t.innerType}if(!u){if(!t.fields||!t.fields[c])throw new Error(`The schema does not contain the path: ${s}. (failed at: ${o} which is a type: "${t.type}")`);i=r,r=r&&r[c],t=t.fields[c]}a=c,o=l?"["+e+"]":"."+e})),{schema:t,parent:i,parentPath:a}):{parent:i,parentPath:s,schema:t}}class D extends Set{describe(){const e=[];for(const t of this.values())e.push(E.isRef(t)?t.describe():t);return e}resolveAll(e){let t=[];for(const s of this.values())t.push(e(s));return t}clone(){return new D(this.values())}merge(e,t){const s=this.clone();return e.forEach((e=>s.add(e))),t.forEach((e=>s.delete(e))),s}}function C(e,t=new Map){if(T(e)||!e||"object"!=typeof e)return e;if(t.has(e))return t.get(e);let s;if(e instanceof Date)s=new Date(e.getTime()),t.set(e,s);else if(e instanceof RegExp)s=new RegExp(e),t.set(e,s);else if(Array.isArray(e)){s=new Array(e.length),t.set(e,s);for(let r=0;r<e.length;r++)s[r]=C(e[r],t)}else if(e instanceof Map){s=new Map,t.set(e,s);for(const[r,n]of e.entries())s.set(r,C(n,t))}else if(e instanceof Set){s=new Set,t.set(e,s);for(const r of e)s.add(C(r,t))}else{if(!(e instanceof Object))throw Error(`Unable to clone ${e}`);s={},t.set(e,s);for(const[r,n]of Object.entries(e))s[r]=C(n,t)}return s}class V{constructor(e){this.type=void 0,this.deps=[],this.tests=void 0,this.transforms=void 0,this.conditions=[],this._mutate=void 0,this.internalTests={},this._whitelist=new D,this._blacklist=new D,this.exclusiveTests=Object.create(null),this._typeCheck=void 0,this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation((()=>{this.typeError(v.notType)})),this.type=e.type,this._typeCheck=e.check,this.spec=Object.assign({strip:!1,strict:!1,abortEarly:!0,recursive:!0,disableStackTrace:!1,nullable:!1,optional:!0,coerce:!0},null==e?void 0:e.spec),this.withMutation((e=>{e.nonNullable()}))}get _type(){return this.type}clone(e){if(this._mutate)return e&&Object.assign(this.spec,e),this;const t=Object.create(Object.getPrototypeOf(this));return t.type=this.type,t._typeCheck=this._typeCheck,t._whitelist=this._whitelist.clone(),t._blacklist=this._blacklist.clone(),t.internalTests=Object.assign({},this.internalTests),t.exclusiveTests=Object.assign({},this.exclusiveTests),t.deps=[...this.deps],t.conditions=[...this.conditions],t.tests=[...this.tests],t.transforms=[...this.transforms],t.spec=C(Object.assign({},this.spec,e)),t}label(e){let t=this.clone();return t.spec.label=e,t}meta(...e){if(0===e.length)return this.spec.meta;let t=this.clone();return t.spec.meta=Object.assign(t.spec.meta||{},e[0]),t}withMutation(e){let t=this._mutate;this._mutate=!0;let s=e(this);return this._mutate=t,s}concat(e){if(!e||e===this)return this;if(e.type!==this.type&&"mixed"!==this.type)throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${e.type}`);let t=this,s=e.clone();const r=Object.assign({},t.spec,s.spec);return s.spec=r,s.internalTests=Object.assign({},t.internalTests,s.internalTests),s._whitelist=t._whitelist.merge(e._whitelist,e._blacklist),s._blacklist=t._blacklist.merge(e._blacklist,e._whitelist),s.tests=t.tests,s.exclusiveTests=t.exclusiveTests,s.withMutation((t=>{e.tests.forEach((e=>{t.test(e.OPTIONS)}))})),s.transforms=[...t.transforms,...s.transforms],s}isType(e){return null==e?!(!this.spec.nullable||null!==e)||!(!this.spec.optional||void 0!==e):this._typeCheck(e)}resolve(e){let t=this;if(t.conditions.length){let s=t.conditions;t=t.clone(),t.conditions=[],t=s.reduce(((t,s)=>s.resolve(t,e)),t),t=t.resolve(e)}return t}resolveOptions(e){var t,s,r,n;return Object.assign({},e,{from:e.from||[],strict:null!=(t=e.strict)?t:this.spec.strict,abortEarly:null!=(s=e.abortEarly)?s:this.spec.abortEarly,recursive:null!=(r=e.recursive)?r:this.spec.recursive,disableStackTrace:null!=(n=e.disableStackTrace)?n:this.spec.disableStackTrace})}cast(e,t={}){let s=this.resolve(Object.assign({value:e},t)),r="ignore-optionality"===t.assert,n=s._cast(e,t);if(!1!==t.assert&&!s.isType(n)){if(r&&S(n))return n;let i=u(e),a=u(n);throw new TypeError(`The value of ${t.path||"field"} could not be cast to a value that satisfies the schema type: "${s.type}". \n\nattempted value: ${i} \n`+(a!==i?`result of cast: ${a}`:""))}return n}_cast(e,t){let s=void 0===e?e:this.transforms.reduce(((t,s)=>s.call(this,t,e,this)),e);return void 0===s&&(s=this.getDefault(t)),s}_validate(e,t={},s,r){let{path:n,originalValue:i=e,strict:a=this.spec.strict}=t,o=e;a||(o=this._cast(o,Object.assign({assert:!1},t)));let l=[];for(let e of Object.values(this.internalTests))e&&l.push(e);this.runTests({path:n,value:o,originalValue:i,options:t,tests:l},s,(e=>{if(e.length)return r(e,o);this.runTests({path:n,value:o,originalValue:i,options:t,tests:this.tests},s,r)}))}runTests(e,t,s){let r=!1,{tests:n,value:i,originalValue:a,path:o,options:l}=e,u=e=>{r||(r=!0,t(e,i))},c=e=>{r||(r=!0,s(e,i))},h=n.length,p=[];if(!h)return c([]);let d={value:i,originalValue:a,path:o,options:l,schema:this};for(let e=0;e<n.length;e++){(0,n[e])(d,u,(function(e){e&&(Array.isArray(e)?p.push(...e):p.push(e)),--h<=0&&c(p)}))}}asNestedTest({key:e,index:t,parent:s,parentPath:r,originalParent:n,options:i}){const a=null!=e?e:t;if(null==a)throw TypeError("Must include `key` or `index` for nested validations");const o="number"==typeof a;let l=s[a];const u=Object.assign({},i,{strict:!0,parent:s,value:l,originalValue:n[a],key:void 0,[o?"index":"key"]:a,path:o||a.includes(".")?`${r||""}[${o?a:`"${a}"`}]`:(r?`${r}.`:"")+e});return(e,t,s)=>this.resolve(u)._validate(l,u,t,s)}validate(e,t){var s;let r=this.resolve(Object.assign({},t,{value:e})),n=null!=(s=null==t?void 0:t.disableStackTrace)?s:r.spec.disableStackTrace;return new Promise(((s,i)=>r._validate(e,t,((e,t)=>{y.isError(e)&&(e.value=t),i(e)}),((e,t)=>{e.length?i(new y(e,t,void 0,void 0,n)):s(t)}))))}validateSync(e,t){var s;let r,n=this.resolve(Object.assign({},t,{value:e})),i=null!=(s=null==t?void 0:t.disableStackTrace)?s:n.spec.disableStackTrace;return n._validate(e,Object.assign({},t,{sync:!0}),((e,t)=>{throw y.isError(e)&&(e.value=t),e}),((t,s)=>{if(t.length)throw new y(t,e,void 0,void 0,i);r=s})),r}isValid(e,t){return this.validate(e,t).then((()=>!0),(e=>{if(y.isError(e))return!1;throw e}))}isValidSync(e,t){try{return this.validateSync(e,t),!0}catch(e){if(y.isError(e))return!1;throw e}}_getDefault(e){let t=this.spec.default;return null==t?t:"function"==typeof t?t.call(this,e):C(t)}getDefault(e){return this.resolve(e||{})._getDefault(e)}default(e){if(0===arguments.length)return this._getDefault();return this.clone({default:e})}strict(e=!0){return this.clone({strict:e})}nullability(e,t){const s=this.clone({nullable:e});return s.internalTests.nullable=j({message:t,name:"nullable",test(e){return null!==e||this.schema.spec.nullable}}),s}optionality(e,t){const s=this.clone({optional:e});return s.internalTests.optionality=j({message:t,name:"optionality",test(e){return void 0!==e||this.schema.spec.optional}}),s}optional(){return this.optionality(!0)}defined(e=v.defined){return this.optionality(!1,e)}nullable(){return this.nullability(!0)}nonNullable(e=v.notNull){return this.nullability(!1,e)}required(e=v.required){return this.clone().withMutation((t=>t.nonNullable(e).defined(e)))}notRequired(){return this.clone().withMutation((e=>e.nullable().optional()))}transform(e){let t=this.clone();return t.transforms.push(e),t}test(...e){let t;if(t=1===e.length?"function"==typeof e[0]?{test:e[0]}:e[0]:2===e.length?{name:e[0],test:e[1]}:{name:e[0],message:e[1],test:e[2]},void 0===t.message&&(t.message=v.default),"function"!=typeof t.test)throw new TypeError("`test` is a required parameters");let s=this.clone(),r=j(t),n=t.exclusive||t.name&&!0===s.exclusiveTests[t.name];if(t.exclusive&&!t.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return t.name&&(s.exclusiveTests[t.name]=!!t.exclusive),s.tests=s.tests.filter((e=>{if(e.OPTIONS.name===t.name){if(n)return!1;if(e.OPTIONS.test===r.OPTIONS.test)return!1}return!0})),s.tests.push(r),s}when(e,t){Array.isArray(e)||"string"==typeof e||(t=e,e=".");let s=this.clone(),r=c(e).map((e=>new E(e)));return r.forEach((e=>{e.isSibling&&s.deps.push(e.key)})),s.conditions.push("function"==typeof t?new $(r,t):$.fromOptions(r,t)),s}typeError(e){let t=this.clone();return t.internalTests.typeError=j({message:e,name:"typeError",skipAbsent:!0,test(e){return!!this.schema._typeCheck(e)||this.createError({params:{type:this.schema.type}})}}),t}oneOf(e,t=v.oneOf){let s=this.clone();return e.forEach((e=>{s._whitelist.add(e),s._blacklist.delete(e)})),s.internalTests.whiteList=j({message:t,name:"oneOf",skipAbsent:!0,test(e){let t=this.schema._whitelist,s=t.resolveAll(this.resolve);return!!s.includes(e)||this.createError({params:{values:Array.from(t).join(", "),resolved:s}})}}),s}notOneOf(e,t=v.notOneOf){let s=this.clone();return e.forEach((e=>{s._blacklist.add(e),s._whitelist.delete(e)})),s.internalTests.blacklist=j({message:t,name:"notOneOf",test(e){let t=this.schema._blacklist,s=t.resolveAll(this.resolve);return!s.includes(e)||this.createError({params:{values:Array.from(t).join(", "),resolved:s}})}}),s}strip(e=!0){let t=this.clone();return t.spec.strip=e,t}describe(e){const t=(e?this.resolve(e):this).clone(),{label:s,meta:r,optional:n,nullable:i}=t.spec;return{meta:r,label:s,optional:n,nullable:i,default:t.getDefault(e),type:t.type,oneOf:t._whitelist.describe(),notOneOf:t._blacklist.describe(),tests:t.tests.map((e=>({name:e.OPTIONS.name,params:e.OPTIONS.params}))).filter(((e,t,s)=>s.findIndex((t=>t.name===e.name))===t))}}}V.prototype.__isYupSchema__=!0;for(const e of["validate","validateSync"])V.prototype[`${e}At`]=function(t,s,r={}){const{parent:n,parentPath:i,schema:a}=A(this,t,s,r.context);return a[e](n&&n[i],Object.assign({},r,{parent:n,path:t}))};for(const e of["equals","is"])V.prototype[e]=V.prototype.oneOf;for(const e of["not","nope"])V.prototype[e]=V.prototype.notOneOf;const N=()=>!0;function z(e){return new P(e)}class P extends V{constructor(e){super("function"==typeof e?{type:"mixed",check:e}:Object.assign({type:"mixed",check:N},e))}}function q(){return new I}z.prototype=P.prototype;class I extends V{constructor(){super({type:"boolean",check:e=>(e instanceof Boolean&&(e=e.valueOf()),"boolean"==typeof e)}),this.withMutation((()=>{this.transform(((e,t,s)=>{if(s.spec.coerce&&!s.isType(e)){if(/^(true|1)$/i.test(String(e)))return!0;if(/^(false|0)$/i.test(String(e)))return!1}return e}))}))}isTrue(e=F.isValue){return this.test({message:e,name:"is-value",exclusive:!0,params:{value:"true"},test:e=>S(e)||!0===e})}isFalse(e=F.isValue){return this.test({message:e,name:"is-value",exclusive:!0,params:{value:"false"},test:e=>S(e)||!1===e})}default(e){return super.default(e)}defined(e){return super.defined(e)}optional(){return super.optional()}required(e){return super.required(e)}notRequired(){return super.notRequired()}nullable(){return super.nullable()}nonNullable(e){return super.nonNullable(e)}strip(e){return super.strip(e)}}q.prototype=I.prototype;const M=/^(\d{4}|[+-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,.](\d{1,}))?)?(?:(Z)|([+-])(\d{2})(?::?(\d{2}))?)?)?$/;function R(e){var t,s;const r=M.exec(e);return r?{year:U(r[1]),month:U(r[2],1)-1,day:U(r[3],1),hour:U(r[4]),minute:U(r[5]),second:U(r[6]),millisecond:r[7]?U(r[7].substring(0,3)):0,precision:null!=(t=null==(s=r[7])?void 0:s.length)?t:void 0,z:r[8]||void 0,plusMinus:r[9]||void 0,hourOffset:U(r[10]),minuteOffset:U(r[11])}:null}function U(e,t=0){return Number(e)||t}let Z=/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,Y=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,L=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,K=new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(\\.\\d+)?(([+-]\\d{2}(:?\\d{2})?)|Z)$"),J=e=>S(e)||e===e.trim(),B={}.toString();function G(){return new H}class H extends V{constructor(){super({type:"string",check:e=>(e instanceof String&&(e=e.valueOf()),"string"==typeof e)}),this.withMutation((()=>{this.transform(((e,t,s)=>{if(!s.spec.coerce||s.isType(e))return e;if(Array.isArray(e))return e;const r=null!=e&&e.toString?e.toString():e;return r===B?e:r}))}))}required(e){return super.required(e).withMutation((t=>t.test({message:e||v.required,name:"required",skipAbsent:!0,test:e=>!!e.length})))}notRequired(){return super.notRequired().withMutation((e=>(e.tests=e.tests.filter((e=>"required"!==e.OPTIONS.name)),e)))}length(e,t=g.length){return this.test({message:t,name:"length",exclusive:!0,params:{length:e},skipAbsent:!0,test(t){return t.length===this.resolve(e)}})}min(e,t=g.min){return this.test({message:t,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(t){return t.length>=this.resolve(e)}})}max(e,t=g.max){return this.test({name:"max",exclusive:!0,message:t,params:{max:e},skipAbsent:!0,test(t){return t.length<=this.resolve(e)}})}matches(e,t){let s,r,n=!1;return t&&("object"==typeof t?({excludeEmptyString:n=!1,message:s,name:r}=t):s=t),this.test({name:r||"matches",message:s||g.matches,params:{regex:e},skipAbsent:!0,test:t=>""===t&&n||-1!==t.search(e)})}email(e=g.email){return this.matches(Z,{name:"email",message:e,excludeEmptyString:!0})}url(e=g.url){return this.matches(Y,{name:"url",message:e,excludeEmptyString:!0})}uuid(e=g.uuid){return this.matches(L,{name:"uuid",message:e,excludeEmptyString:!1})}datetime(e){let t,s,r="";return e&&("object"==typeof e?({message:r="",allowOffset:t=!1,precision:s}=e):r=e),this.matches(K,{name:"datetime",message:r||g.datetime,excludeEmptyString:!0}).test({name:"datetime_offset",message:r||g.datetime_offset,params:{allowOffset:t},skipAbsent:!0,test:e=>{if(!e||t)return!0;const s=R(e);return!!s&&!!s.z}}).test({name:"datetime_precision",message:r||g.datetime_precision,params:{precision:s},skipAbsent:!0,test:e=>{if(!e||null==s)return!0;const t=R(e);return!!t&&t.precision===s}})}ensure(){return this.default("").transform((e=>null===e?"":e))}trim(e=g.trim){return this.transform((e=>null!=e?e.trim():e)).test({message:e,name:"trim",test:J})}lowercase(e=g.lowercase){return this.transform((e=>S(e)?e:e.toLowerCase())).test({message:e,name:"string_case",exclusive:!0,skipAbsent:!0,test:e=>S(e)||e===e.toLowerCase()})}uppercase(e=g.uppercase){return this.transform((e=>S(e)?e:e.toUpperCase())).test({message:e,name:"string_case",exclusive:!0,skipAbsent:!0,test:e=>S(e)||e===e.toUpperCase()})}}G.prototype=H.prototype;let Q=new Date("");class W extends V{constructor(){super({type:"date",check(e){return t=e,"[object Date]"===Object.prototype.toString.call(t)&&!isNaN(e.getTime());var t}}),this.withMutation((()=>{this.transform(((e,t,s)=>!s.spec.coerce||s.isType(e)||null===e?e:(e=function(e){const t=R(e);if(!t)return Date.parse?Date.parse(e):Number.NaN;if(void 0===t.z&&void 0===t.plusMinus)return new Date(t.year,t.month,t.day,t.hour,t.minute,t.second,t.millisecond).valueOf();let s=0;return"Z"!==t.z&&void 0!==t.plusMinus&&(s=60*t.hourOffset+t.minuteOffset,"+"===t.plusMinus&&(s=0-s)),Date.UTC(t.year,t.month,t.day,t.hour,t.minute+s,t.second,t.millisecond)}(e),isNaN(e)?W.INVALID_DATE:new Date(e))))}))}prepareParam(e,t){let s;if(E.isRef(e))s=e;else{let r=this.cast(e);if(!this._typeCheck(r))throw new TypeError(`\`${t}\` must be a Date or a value that can be \`cast()\` to a Date`);s=r}return s}min(e,t=b.min){let s=this.prepareParam(e,"min");return this.test({message:t,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(e){return e>=this.resolve(s)}})}max(e,t=b.max){let s=this.prepareParam(e,"max");return this.test({message:t,name:"max",exclusive:!0,params:{max:e},skipAbsent:!0,test(e){return e<=this.resolve(s)}})}}function X(e,t){let s=1/0;return e.some(((e,r)=>{var n;if(null!=(n=t.path)&&n.includes(e))return s=r,!0})),s}function ee(e){return(t,s)=>X(e,t)-X(e,s)}W.INVALID_DATE=Q,W.prototype;const te=(e,t,s)=>{if("string"!=typeof e)return e;let r=e;try{r=JSON.parse(e)}catch(e){}return s.isType(r)?r:e};function se(e){if("fields"in e){const t={};for(const[s,r]of Object.entries(e.fields))t[s]=se(r);return e.setFields(t)}if("array"===e.type){const t=e.optional();return t.innerType&&(t.innerType=se(t.innerType)),t}return"tuple"===e.type?e.optional().clone({types:e.spec.types.map(se)}):"optional"in e?e.optional():e}let re=e=>"[object Object]"===Object.prototype.toString.call(e);function ne(e,t){let s=Object.keys(e.fields);return Object.keys(t).filter((e=>-1===s.indexOf(e)))}const ie=ee([]);function ae(e){return new oe(e)}class oe extends V{constructor(e){super({type:"object",check:e=>re(e)||"function"==typeof e}),this.fields=Object.create(null),this._sortErrors=ie,this._nodes=[],this._excludedEdges=[],this.withMutation((()=>{e&&this.shape(e)}))}_cast(e,t={}){var s;let r=super._cast(e,t);if(void 0===r)return this.getDefault(t);if(!this._typeCheck(r))return r;let n=this.fields,i=null!=(s=t.stripUnknown)?s:this.spec.noUnknown,a=[].concat(this._nodes,Object.keys(r).filter((e=>!this._nodes.includes(e)))),o={},l=Object.assign({},t,{parent:o,__validating:t.__validating||!1}),u=!1;for(const e of a){let s=n[e],a=e in r;if(s){let n,i=r[e];l.path=(t.path?`${t.path}.`:"")+e,s=s.resolve({value:i,context:t.context,parent:o});let a=s instanceof V?s.spec:void 0,c=null==a?void 0:a.strict;if(null!=a&&a.strip){u=u||e in r;continue}n=t.__validating&&c?r[e]:s.cast(r[e],l),void 0!==n&&(o[e]=n)}else a&&!i&&(o[e]=r[e]);a===e in o&&o[e]===r[e]||(u=!0)}return u?o:r}_validate(e,t={},s,r){let{from:n=[],originalValue:i=e,recursive:a=this.spec.recursive}=t;t.from=[{schema:this,value:i},...n],t.__validating=!0,t.originalValue=i,super._validate(e,t,s,((e,n)=>{if(!a||!re(n))return void r(e,n);i=i||n;let o=[];for(let e of this._nodes){let s=this.fields[e];s&&!E.isRef(s)&&o.push(s.asNestedTest({options:t,key:e,parent:n,parentPath:t.path,originalParent:i}))}this.runTests({tests:o,value:n,originalValue:i,options:t},s,(t=>{r(t.sort(this._sortErrors).concat(e),n)}))}))}clone(e){const t=super.clone(e);return t.fields=Object.assign({},this.fields),t._nodes=this._nodes,t._excludedEdges=this._excludedEdges,t._sortErrors=this._sortErrors,t}concat(e){let t=super.concat(e),s=t.fields;for(let[e,t]of Object.entries(this.fields)){const r=s[e];s[e]=void 0===r?t:r}return t.withMutation((t=>t.setFields(s,[...this._excludedEdges,...e._excludedEdges])))}_getDefault(e){if("default"in this.spec)return super._getDefault(e);if(!this._nodes.length)return;let t={};return this._nodes.forEach((s=>{var r;const n=this.fields[s];let i=e;null!=(r=i)&&r.value&&(i=Object.assign({},i,{parent:i.value,value:i.value[s]})),t[s]=n&&"getDefault"in n?n.getDefault(i):void 0})),t}setFields(t,r){let n=this.clone();return n.fields=t,n._nodes=function(t,r=[]){let n=[],i=new Set,a=new Set(r.map((([e,t])=>`${e}-${t}`)));function o(t,s){let r=e.split(t)[0];i.add(r),a.has(`${s}-${r}`)||n.push([s,r])}for(const e of Object.keys(t)){let s=t[e];i.add(e),E.isRef(s)&&s.isSibling?o(s.path,e):T(s)&&"deps"in s&&s.deps.forEach((t=>o(t,e)))}return s.array(Array.from(i),n).reverse()}(t,r),n._sortErrors=ee(Object.keys(t)),r&&(n._excludedEdges=r),n}shape(e,t=[]){return this.clone().withMutation((s=>{let r=s._excludedEdges;return t.length&&(Array.isArray(t[0])||(t=[t]),r=[...s._excludedEdges,...t]),s.setFields(Object.assign(s.fields,e),r)}))}partial(){const e={};for(const[t,s]of Object.entries(this.fields))e[t]="optional"in s&&s.optional instanceof Function?s.optional():s;return this.setFields(e)}deepPartial(){return se(this)}pick(e){const t={};for(const s of e)this.fields[s]&&(t[s]=this.fields[s]);return this.setFields(t,this._excludedEdges.filter((([t,s])=>e.includes(t)&&e.includes(s))))}omit(e){const t=[];for(const s of Object.keys(this.fields))e.includes(s)||t.push(s);return this.pick(t)}from(t,s,r){let n=e.getter(t,!0);return this.transform((i=>{if(!i)return i;let a=i;return((t,s)=>{const r=[...e.normalizePath(s)];if(1===r.length)return r[0]in t;let n=r.pop(),i=e.getter(e.join(r),!0)(t);return!(!i||!(n in i))})(i,t)&&(a=Object.assign({},i),r||delete a[t],a[s]=n(i)),a}))}json(){return this.transform(te)}exact(e){return this.test({name:"exact",exclusive:!0,message:e||_.exact,test(e){if(null==e)return!0;const t=ne(this.schema,e);return 0===t.length||this.createError({params:{properties:t.join(", ")}})}})}stripUnknown(){return this.clone({noUnknown:!0})}noUnknown(e=!0,t=_.noUnknown){"boolean"!=typeof e&&(t=e,e=!0);let s=this.test({name:"noUnknown",exclusive:!0,message:t,test(t){if(null==t)return!0;const s=ne(this.schema,t);return!e||0===s.length||this.createError({params:{unknown:s.join(", ")}})}});return s.spec.noUnknown=e,s}unknown(e=!0,t=_.noUnknown){return this.noUnknown(!e,t)}transformKeys(e){return this.transform((t=>{if(!t)return t;const s={};for(const r of Object.keys(t))s[e(r)]=t[r];return s}))}camelCase(){return this.transformKeys(t.camelCase)}snakeCase(){return this.transformKeys(t.snakeCase)}constantCase(){return this.transformKeys((e=>t.snakeCase(e).toUpperCase()))}describe(e){const t=(e?this.resolve(e):this).clone(),s=super.describe(e);s.fields={};for(const[n,i]of Object.entries(t.fields)){var r;let t=e;null!=(r=t)&&r.value&&(t=Object.assign({},t,{parent:t.value,value:t.value[n]})),s.fields[n]=i.describe(t)}return s}}function le(e){return new ue(e)}ae.prototype=oe.prototype;class ue extends V{constructor(e){super({type:"array",spec:{types:e},check:e=>Array.isArray(e)}),this.innerType=void 0,this.innerType=e}_cast(e,t){const s=super._cast(e,t);if(!this._typeCheck(s)||!this.innerType)return s;let r=!1;const n=s.map(((e,s)=>{const n=this.innerType.cast(e,Object.assign({},t,{path:`${t.path||""}[${s}]`}));return n!==e&&(r=!0),n}));return r?n:s}_validate(e,t={},s,r){var n;let i=this.innerType,a=null!=(n=t.recursive)?n:this.spec.recursive;null!=t.originalValue&&t.originalValue,super._validate(e,t,s,((n,o)=>{var l;if(!a||!i||!this._typeCheck(o))return void r(n,o);let u=new Array(o.length);for(let s=0;s<o.length;s++){var c;u[s]=i.asNestedTest({options:t,index:s,parent:o,parentPath:t.path,originalParent:null!=(c=t.originalValue)?c:e})}this.runTests({value:o,tests:u,originalValue:null!=(l=t.originalValue)?l:e,options:t},s,(e=>r(e.concat(n),o)))}))}clone(e){const t=super.clone(e);return t.innerType=this.innerType,t}json(){return this.transform(te)}concat(e){let t=super.concat(e);return t.innerType=this.innerType,e.innerType&&(t.innerType=t.innerType?t.innerType.concat(e.innerType):e.innerType),t}of(e){let t=this.clone();if(!T(e))throw new TypeError("`array.of()` sub-schema must be a valid yup schema not: "+u(e));return t.innerType=e,t.spec=Object.assign({},t.spec,{types:e}),t}length(e,t=w.length){return this.test({message:t,name:"length",exclusive:!0,params:{length:e},skipAbsent:!0,test(t){return t.length===this.resolve(e)}})}min(e,t){return t=t||w.min,this.test({message:t,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(t){return t.length>=this.resolve(e)}})}max(e,t){return t=t||w.max,this.test({message:t,name:"max",exclusive:!0,params:{max:e},skipAbsent:!0,test(t){return t.length<=this.resolve(e)}})}ensure(){return this.default((()=>[])).transform(((e,t)=>this._typeCheck(e)?e:null==t?[]:[].concat(t)))}compact(e){let t=e?(t,s,r)=>!e(t,s,r):e=>!!e;return this.transform((e=>null!=e?e.filter(t):e))}describe(e){const t=(e?this.resolve(e):this).clone(),s=super.describe(e);if(t.innerType){var r;let n=e;null!=(r=n)&&r.value&&(n=Object.assign({},n,{parent:n.value,value:n.value[0]})),s.innerType=t.innerType.describe(n)}return s}}function ce(e){return new pe(e)}function he(e){try{return e()}catch(e){if(y.isError(e))return Promise.reject(e);throw e}}le.prototype=ue.prototype;class pe{constructor(e){this.type="lazy",this.__isYupSchema__=!0,this.spec=void 0,this._resolve=(e,t={})=>{let s=this.builder(e,t);if(!T(s))throw new TypeError("lazy() functions must return a valid schema");return this.spec.optional&&(s=s.optional()),s.resolve(t)},this.builder=e,this.spec={meta:void 0,optional:!1}}clone(e){const t=new pe(this.builder);return t.spec=Object.assign({},this.spec,e),t}optionality(e){return this.clone({optional:e})}optional(){return this.optionality(!0)}resolve(e){return this._resolve(e.value,e)}cast(e,t){return this._resolve(e,t).cast(e,t)}asNestedTest(e){let{key:t,index:s,parent:r,options:n}=e,i=r[null!=s?s:t];return this._resolve(i,Object.assign({},n,{value:i,parent:r})).asNestedTest(e)}validate(e,t){return he((()=>this._resolve(e,t).validate(e,t)))}validateSync(e,t){return this._resolve(e,t).validateSync(e,t)}validateAt(e,t,s){return he((()=>this._resolve(t,s).validateAt(e,t,s)))}validateSyncAt(e,t,s){return this._resolve(t,s).validateSyncAt(e,t,s)}isValid(e,t){try{return this._resolve(e,t).isValid(e,t)}catch(e){if(y.isError(e))return Promise.resolve(!1);throw e}}isValidSync(e,t){return this._resolve(e,t).isValidSync(e,t)}describe(e){return e?this.resolve(e).describe(e):{type:"lazy",meta:this.spec.meta,label:void 0}}meta(...e){if(0===e.length)return this.spec.meta;let t=this.clone();return t.spec.meta=Object.assign(t.spec.meta||{},e[0]),t}}export{ue as ArraySchema,I as BooleanSchema,W as DateSchema,pe as LazySchema,P as MixedSchema,oe as ObjectSchema,V as Schema,H as StringSchema,y as ValidationError,le as array,q as bool,q as boolean,A as getIn,T as isSchema,ce as lazy,z as mixed,ae as object,u as printValue,G as string};
|
|
1
|
+
import{p as e}from"../../_virtual/index3.js";import{t}from"../../_virtual/index4.js";import s from"../../_virtual/index5.js";const r=Object.prototype.toString,n=Error.prototype.toString,i=RegExp.prototype.toString,a="undefined"!=typeof Symbol?Symbol.prototype.toString:()=>"",o=/^Symbol\((.*)\)(.*)$/;function l(e,t=!1){if(null==e||!0===e||!1===e)return""+e;const s=typeof e;if("number"===s)return function(e){return e!=+e?"NaN":0===e&&1/e<0?"-0":""+e}(e);if("string"===s)return t?`"${e}"`:e;if("function"===s)return"[Function "+(e.name||"anonymous")+"]";if("symbol"===s)return a.call(e).replace(o,"Symbol($1)");const l=r.call(e).slice(8,-1);return"Date"===l?isNaN(e.getTime())?""+e:e.toISOString(e):"Error"===l||e instanceof Error?"["+n.call(e)+"]":"RegExp"===l?i.call(e):null}function u(e,t){let s=l(e,t);return null!==s?s:JSON.stringify(e,(function(e,s){let r=l(this[e],t);return null!==r?r:s}),2)}function c(e){return null==e?[]:[].concat(e)}let h,p,d,f=/\$\{\s*(\w+)\s*\}/g;h=Symbol.toStringTag;class m{constructor(e,t,s,r){this.name=void 0,this.message=void 0,this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=void 0,this.inner=void 0,this[h]="Error",this.name="ValidationError",this.value=t,this.path=s,this.type=r,this.errors=[],this.inner=[],c(e).forEach((e=>{if(y.isError(e)){this.errors.push(...e.errors);const t=e.inner.length?e.inner:[e];this.inner.push(...t)}else this.errors.push(e)})),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0]}}p=Symbol.hasInstance,d=Symbol.toStringTag;class y extends Error{static formatError(e,t){const s=t.label||t.path||"this";return t=Object.assign({},t,{path:s,originalPath:t.path}),"string"==typeof e?e.replace(f,((e,s)=>u(t[s]))):"function"==typeof e?e(t):e}static isError(e){return e&&"ValidationError"===e.name}constructor(e,t,s,r,n){const i=new m(e,t,s,r);if(n)return i;super(),this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=[],this.inner=[],this[d]="Error",this.name=i.name,this.message=i.message,this.type=i.type,this.value=i.value,this.path=i.path,this.errors=i.errors,this.inner=i.inner,Error.captureStackTrace&&Error.captureStackTrace(this,y)}static[p](e){return m[Symbol.hasInstance](e)||super[Symbol.hasInstance](e)}}let v={default:"${path} is invalid",required:"${path} is a required field",defined:"${path} must be defined",notNull:"${path} cannot be null",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:e,type:t,value:s,originalValue:r})=>{const n=null!=r&&r!==s?` (cast from the value \`${u(r,!0)}\`).`:".";return"mixed"!==t?`${e} must be a \`${t}\` type, but the final value was: \`${u(s,!0)}\``+n:`${e} must match the configured type. The validated value was: \`${u(s,!0)}\``+n}},g={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",datetime:"${path} must be a valid ISO date-time",datetime_precision:"${path} must be a valid ISO date-time with a sub-second precision of exactly ${precision} digits",datetime_offset:'${path} must be a valid ISO date-time with UTC "Z" timezone',trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},b={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},F={isValue:"${path} field must be ${value}"},_={noUnknown:"${path} field has unspecified keys: ${unknown}",exact:"${path} object contains unknown properties: ${properties}"},w={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"},x={notType:e=>{const{path:t,value:s,spec:r}=e,n=r.types.length;if(Array.isArray(s)){if(s.length<n)return`${t} tuple value has too few items, expected a length of ${n} but got ${s.length} for value: \`${u(s,!0)}\``;if(s.length>n)return`${t} tuple value has too many items, expected a length of ${n} but got ${s.length} for value: \`${u(s,!0)}\``}return y.formatError(v.notType,e)}};Object.assign(Object.create(null),{mixed:v,string:g,number:{min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},date:b,object:_,array:w,boolean:F,tuple:x});const T=e=>e&&e.__isYupSchema__;class ${static fromOptions(e,t){if(!t.then&&!t.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:s,then:r,otherwise:n}=t,i="function"==typeof s?s:(...e)=>e.every((e=>e===s));return new $(e,((e,t)=>{var s;let a=i(...e)?r:n;return null!=(s=null==a?void 0:a(t))?s:t}))}constructor(e,t){this.fn=void 0,this.refs=e,this.refs=e,this.fn=t}resolve(e,t){let s=this.refs.map((e=>e.getValue(null==t?void 0:t.value,null==t?void 0:t.parent,null==t?void 0:t.context))),r=this.fn(s,e,t);if(void 0===r||r===e)return e;if(!T(r))throw new TypeError("conditions must return a schema object");return r.resolve(t)}}const O="$",k=".";class E{constructor(t,s={}){if(this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,"string"!=typeof t)throw new TypeError("ref must be a string, got: "+t);if(this.key=t.trim(),""===t)throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===O,this.isValue=this.key[0]===k,this.isSibling=!this.isContext&&!this.isValue;let r=this.isContext?O:this.isValue?k:"";this.path=this.key.slice(r.length),this.getter=this.path&&e.getter(this.path,!0),this.map=s.map}getValue(e,t,s){let r=this.isContext?s:this.isValue?e:t;return this.getter&&(r=this.getter(r||{})),this.map&&(r=this.map(r)),r}cast(e,t){return this.getValue(e,null==t?void 0:t.parent,null==t?void 0:t.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(e){return e&&e.__isYupRef}}E.prototype.__isYupRef=!0;const S=e=>null==e;function j(e){function t({value:t,path:s="",options:r,originalValue:n,schema:i},a,o){const{name:l,test:u,params:c,message:h,skipAbsent:p}=e;let{parent:d,context:f,abortEarly:m=i.spec.abortEarly,disableStackTrace:v=i.spec.disableStackTrace}=r;function g(e){return E.isRef(e)?e.getValue(t,d,f):e}function b(e={}){const r=Object.assign({value:t,originalValue:n,label:i.spec.label,path:e.path||s,spec:i.spec,disableStackTrace:e.disableStackTrace||v},c,e.params);for(const e of Object.keys(r))r[e]=g(r[e]);const a=new y(y.formatError(e.message||h,r),t,r.path,e.type||l,r.disableStackTrace);return a.params=r,a}const F=m?a:o;let _={path:s,parent:d,type:l,from:r.from,createError:b,resolve:g,options:r,originalValue:n,schema:i};const w=e=>{y.isError(e)?F(e):e?o(null):F(b())},x=e=>{y.isError(e)?F(e):a(e)};if(p&&S(t))return w(!0);let T;try{var $;if(T=u.call(_,t,_),"function"==typeof(null==($=T)?void 0:$.then)){if(r.sync)throw new Error(`Validation test of type: "${_.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`);return Promise.resolve(T).then(w,x)}}catch(e){return void x(e)}w(T)}return t.OPTIONS=e,t}function A(t,s,r,n=r){let i,a,o;return s?(e.forEach(s,((e,l,u)=>{let c=l?e.slice(1,e.length-1):e,h="tuple"===(t=t.resolve({context:n,parent:i,value:r})).type,p=u?parseInt(c,10):0;if(t.innerType||h){if(h&&!u)throw new Error(`Yup.reach cannot implicitly index into a tuple type. the path part "${o}" must contain an index to the tuple element, e.g. "${o}[0]"`);if(r&&p>=r.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${e}, in the path: ${s}. because there is no value at that index. `);i=r,r=r&&r[p],t=h?t.spec.types[p]:t.innerType}if(!u){if(!t.fields||!t.fields[c])throw new Error(`The schema does not contain the path: ${s}. (failed at: ${o} which is a type: "${t.type}")`);i=r,r=r&&r[c],t=t.fields[c]}a=c,o=l?"["+e+"]":"."+e})),{schema:t,parent:i,parentPath:a}):{parent:i,parentPath:s,schema:t}}class D extends Set{describe(){const e=[];for(const t of this.values())e.push(E.isRef(t)?t.describe():t);return e}resolveAll(e){let t=[];for(const s of this.values())t.push(e(s));return t}clone(){return new D(this.values())}merge(e,t){const s=this.clone();return e.forEach((e=>s.add(e))),t.forEach((e=>s.delete(e))),s}}function C(e,t=new Map){if(T(e)||!e||"object"!=typeof e)return e;if(t.has(e))return t.get(e);let s;if(e instanceof Date)s=new Date(e.getTime()),t.set(e,s);else if(e instanceof RegExp)s=new RegExp(e),t.set(e,s);else if(Array.isArray(e)){s=new Array(e.length),t.set(e,s);for(let r=0;r<e.length;r++)s[r]=C(e[r],t)}else if(e instanceof Map){s=new Map,t.set(e,s);for(const[r,n]of e.entries())s.set(r,C(n,t))}else if(e instanceof Set){s=new Set,t.set(e,s);for(const r of e)s.add(C(r,t))}else{if(!(e instanceof Object))throw Error(`Unable to clone ${e}`);s={},t.set(e,s);for(const[r,n]of Object.entries(e))s[r]=C(n,t)}return s}class V{constructor(e){this.type=void 0,this.deps=[],this.tests=void 0,this.transforms=void 0,this.conditions=[],this._mutate=void 0,this.internalTests={},this._whitelist=new D,this._blacklist=new D,this.exclusiveTests=Object.create(null),this._typeCheck=void 0,this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation((()=>{this.typeError(v.notType)})),this.type=e.type,this._typeCheck=e.check,this.spec=Object.assign({strip:!1,strict:!1,abortEarly:!0,recursive:!0,disableStackTrace:!1,nullable:!1,optional:!0,coerce:!0},null==e?void 0:e.spec),this.withMutation((e=>{e.nonNullable()}))}get _type(){return this.type}clone(e){if(this._mutate)return e&&Object.assign(this.spec,e),this;const t=Object.create(Object.getPrototypeOf(this));return t.type=this.type,t._typeCheck=this._typeCheck,t._whitelist=this._whitelist.clone(),t._blacklist=this._blacklist.clone(),t.internalTests=Object.assign({},this.internalTests),t.exclusiveTests=Object.assign({},this.exclusiveTests),t.deps=[...this.deps],t.conditions=[...this.conditions],t.tests=[...this.tests],t.transforms=[...this.transforms],t.spec=C(Object.assign({},this.spec,e)),t}label(e){let t=this.clone();return t.spec.label=e,t}meta(...e){if(0===e.length)return this.spec.meta;let t=this.clone();return t.spec.meta=Object.assign(t.spec.meta||{},e[0]),t}withMutation(e){let t=this._mutate;this._mutate=!0;let s=e(this);return this._mutate=t,s}concat(e){if(!e||e===this)return this;if(e.type!==this.type&&"mixed"!==this.type)throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${e.type}`);let t=this,s=e.clone();const r=Object.assign({},t.spec,s.spec);return s.spec=r,s.internalTests=Object.assign({},t.internalTests,s.internalTests),s._whitelist=t._whitelist.merge(e._whitelist,e._blacklist),s._blacklist=t._blacklist.merge(e._blacklist,e._whitelist),s.tests=t.tests,s.exclusiveTests=t.exclusiveTests,s.withMutation((t=>{e.tests.forEach((e=>{t.test(e.OPTIONS)}))})),s.transforms=[...t.transforms,...s.transforms],s}isType(e){return null==e?!(!this.spec.nullable||null!==e)||!(!this.spec.optional||void 0!==e):this._typeCheck(e)}resolve(e){let t=this;if(t.conditions.length){let s=t.conditions;t=t.clone(),t.conditions=[],t=s.reduce(((t,s)=>s.resolve(t,e)),t),t=t.resolve(e)}return t}resolveOptions(e){var t,s,r,n;return Object.assign({},e,{from:e.from||[],strict:null!=(t=e.strict)?t:this.spec.strict,abortEarly:null!=(s=e.abortEarly)?s:this.spec.abortEarly,recursive:null!=(r=e.recursive)?r:this.spec.recursive,disableStackTrace:null!=(n=e.disableStackTrace)?n:this.spec.disableStackTrace})}cast(e,t={}){let s=this.resolve(Object.assign({value:e},t)),r="ignore-optionality"===t.assert,n=s._cast(e,t);if(!1!==t.assert&&!s.isType(n)){if(r&&S(n))return n;let i=u(e),a=u(n);throw new TypeError(`The value of ${t.path||"field"} could not be cast to a value that satisfies the schema type: "${s.type}". \n\nattempted value: ${i} \n`+(a!==i?`result of cast: ${a}`:""))}return n}_cast(e,t){let s=void 0===e?e:this.transforms.reduce(((t,s)=>s.call(this,t,e,this)),e);return void 0===s&&(s=this.getDefault(t)),s}_validate(e,t={},s,r){let{path:n,originalValue:i=e,strict:a=this.spec.strict}=t,o=e;a||(o=this._cast(o,Object.assign({assert:!1},t)));let l=[];for(let e of Object.values(this.internalTests))e&&l.push(e);this.runTests({path:n,value:o,originalValue:i,options:t,tests:l},s,(e=>{if(e.length)return r(e,o);this.runTests({path:n,value:o,originalValue:i,options:t,tests:this.tests},s,r)}))}runTests(e,t,s){let r=!1,{tests:n,value:i,originalValue:a,path:o,options:l}=e,u=e=>{r||(r=!0,t(e,i))},c=e=>{r||(r=!0,s(e,i))},h=n.length,p=[];if(!h)return c([]);let d={value:i,originalValue:a,path:o,options:l,schema:this};for(let e=0;e<n.length;e++){(0,n[e])(d,u,(function(e){e&&(Array.isArray(e)?p.push(...e):p.push(e)),--h<=0&&c(p)}))}}asNestedTest({key:e,index:t,parent:s,parentPath:r,originalParent:n,options:i}){const a=null!=e?e:t;if(null==a)throw TypeError("Must include `key` or `index` for nested validations");const o="number"==typeof a;let l=s[a];const u=Object.assign({},i,{strict:!0,parent:s,value:l,originalValue:n[a],key:void 0,[o?"index":"key"]:a,path:o||a.includes(".")?`${r||""}[${o?a:`"${a}"`}]`:(r?`${r}.`:"")+e});return(e,t,s)=>this.resolve(u)._validate(l,u,t,s)}validate(e,t){var s;let r=this.resolve(Object.assign({},t,{value:e})),n=null!=(s=null==t?void 0:t.disableStackTrace)?s:r.spec.disableStackTrace;return new Promise(((s,i)=>r._validate(e,t,((e,t)=>{y.isError(e)&&(e.value=t),i(e)}),((e,t)=>{e.length?i(new y(e,t,void 0,void 0,n)):s(t)}))))}validateSync(e,t){var s;let r,n=this.resolve(Object.assign({},t,{value:e})),i=null!=(s=null==t?void 0:t.disableStackTrace)?s:n.spec.disableStackTrace;return n._validate(e,Object.assign({},t,{sync:!0}),((e,t)=>{throw y.isError(e)&&(e.value=t),e}),((t,s)=>{if(t.length)throw new y(t,e,void 0,void 0,i);r=s})),r}isValid(e,t){return this.validate(e,t).then((()=>!0),(e=>{if(y.isError(e))return!1;throw e}))}isValidSync(e,t){try{return this.validateSync(e,t),!0}catch(e){if(y.isError(e))return!1;throw e}}_getDefault(e){let t=this.spec.default;return null==t?t:"function"==typeof t?t.call(this,e):C(t)}getDefault(e){return this.resolve(e||{})._getDefault(e)}default(e){if(0===arguments.length)return this._getDefault();return this.clone({default:e})}strict(e=!0){return this.clone({strict:e})}nullability(e,t){const s=this.clone({nullable:e});return s.internalTests.nullable=j({message:t,name:"nullable",test(e){return null!==e||this.schema.spec.nullable}}),s}optionality(e,t){const s=this.clone({optional:e});return s.internalTests.optionality=j({message:t,name:"optionality",test(e){return void 0!==e||this.schema.spec.optional}}),s}optional(){return this.optionality(!0)}defined(e=v.defined){return this.optionality(!1,e)}nullable(){return this.nullability(!0)}nonNullable(e=v.notNull){return this.nullability(!1,e)}required(e=v.required){return this.clone().withMutation((t=>t.nonNullable(e).defined(e)))}notRequired(){return this.clone().withMutation((e=>e.nullable().optional()))}transform(e){let t=this.clone();return t.transforms.push(e),t}test(...e){let t;if(t=1===e.length?"function"==typeof e[0]?{test:e[0]}:e[0]:2===e.length?{name:e[0],test:e[1]}:{name:e[0],message:e[1],test:e[2]},void 0===t.message&&(t.message=v.default),"function"!=typeof t.test)throw new TypeError("`test` is a required parameters");let s=this.clone(),r=j(t),n=t.exclusive||t.name&&!0===s.exclusiveTests[t.name];if(t.exclusive&&!t.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return t.name&&(s.exclusiveTests[t.name]=!!t.exclusive),s.tests=s.tests.filter((e=>{if(e.OPTIONS.name===t.name){if(n)return!1;if(e.OPTIONS.test===r.OPTIONS.test)return!1}return!0})),s.tests.push(r),s}when(e,t){Array.isArray(e)||"string"==typeof e||(t=e,e=".");let s=this.clone(),r=c(e).map((e=>new E(e)));return r.forEach((e=>{e.isSibling&&s.deps.push(e.key)})),s.conditions.push("function"==typeof t?new $(r,t):$.fromOptions(r,t)),s}typeError(e){let t=this.clone();return t.internalTests.typeError=j({message:e,name:"typeError",skipAbsent:!0,test(e){return!!this.schema._typeCheck(e)||this.createError({params:{type:this.schema.type}})}}),t}oneOf(e,t=v.oneOf){let s=this.clone();return e.forEach((e=>{s._whitelist.add(e),s._blacklist.delete(e)})),s.internalTests.whiteList=j({message:t,name:"oneOf",skipAbsent:!0,test(e){let t=this.schema._whitelist,s=t.resolveAll(this.resolve);return!!s.includes(e)||this.createError({params:{values:Array.from(t).join(", "),resolved:s}})}}),s}notOneOf(e,t=v.notOneOf){let s=this.clone();return e.forEach((e=>{s._blacklist.add(e),s._whitelist.delete(e)})),s.internalTests.blacklist=j({message:t,name:"notOneOf",test(e){let t=this.schema._blacklist,s=t.resolveAll(this.resolve);return!s.includes(e)||this.createError({params:{values:Array.from(t).join(", "),resolved:s}})}}),s}strip(e=!0){let t=this.clone();return t.spec.strip=e,t}describe(e){const t=(e?this.resolve(e):this).clone(),{label:s,meta:r,optional:n,nullable:i}=t.spec;return{meta:r,label:s,optional:n,nullable:i,default:t.getDefault(e),type:t.type,oneOf:t._whitelist.describe(),notOneOf:t._blacklist.describe(),tests:t.tests.map((e=>({name:e.OPTIONS.name,params:e.OPTIONS.params}))).filter(((e,t,s)=>s.findIndex((t=>t.name===e.name))===t))}}}V.prototype.__isYupSchema__=!0;for(const e of["validate","validateSync"])V.prototype[`${e}At`]=function(t,s,r={}){const{parent:n,parentPath:i,schema:a}=A(this,t,s,r.context);return a[e](n&&n[i],Object.assign({},r,{parent:n,path:t}))};for(const e of["equals","is"])V.prototype[e]=V.prototype.oneOf;for(const e of["not","nope"])V.prototype[e]=V.prototype.notOneOf;const N=()=>!0;function z(e){return new P(e)}class P extends V{constructor(e){super("function"==typeof e?{type:"mixed",check:e}:Object.assign({type:"mixed",check:N},e))}}function q(){return new I}z.prototype=P.prototype;class I extends V{constructor(){super({type:"boolean",check:e=>(e instanceof Boolean&&(e=e.valueOf()),"boolean"==typeof e)}),this.withMutation((()=>{this.transform(((e,t,s)=>{if(s.spec.coerce&&!s.isType(e)){if(/^(true|1)$/i.test(String(e)))return!0;if(/^(false|0)$/i.test(String(e)))return!1}return e}))}))}isTrue(e=F.isValue){return this.test({message:e,name:"is-value",exclusive:!0,params:{value:"true"},test:e=>S(e)||!0===e})}isFalse(e=F.isValue){return this.test({message:e,name:"is-value",exclusive:!0,params:{value:"false"},test:e=>S(e)||!1===e})}default(e){return super.default(e)}defined(e){return super.defined(e)}optional(){return super.optional()}required(e){return super.required(e)}notRequired(){return super.notRequired()}nullable(){return super.nullable()}nonNullable(e){return super.nonNullable(e)}strip(e){return super.strip(e)}}q.prototype=I.prototype;const M=/^(\d{4}|[+-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,.](\d{1,}))?)?(?:(Z)|([+-])(\d{2})(?::?(\d{2}))?)?)?$/;function R(e){var t,s;const r=M.exec(e);return r?{year:U(r[1]),month:U(r[2],1)-1,day:U(r[3],1),hour:U(r[4]),minute:U(r[5]),second:U(r[6]),millisecond:r[7]?U(r[7].substring(0,3)):0,precision:null!=(t=null==(s=r[7])?void 0:s.length)?t:void 0,z:r[8]||void 0,plusMinus:r[9]||void 0,hourOffset:U(r[10]),minuteOffset:U(r[11])}:null}function U(e,t=0){return Number(e)||t}let Z=/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,Y=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,L=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,K=new RegExp("^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(\\.\\d+)?(([+-]\\d{2}(:?\\d{2})?)|Z)$"),J=e=>S(e)||e===e.trim(),B={}.toString();function G(){return new H}class H extends V{constructor(){super({type:"string",check:e=>(e instanceof String&&(e=e.valueOf()),"string"==typeof e)}),this.withMutation((()=>{this.transform(((e,t,s)=>{if(!s.spec.coerce||s.isType(e))return e;if(Array.isArray(e))return e;const r=null!=e&&e.toString?e.toString():e;return r===B?e:r}))}))}required(e){return super.required(e).withMutation((t=>t.test({message:e||v.required,name:"required",skipAbsent:!0,test:e=>!!e.length})))}notRequired(){return super.notRequired().withMutation((e=>(e.tests=e.tests.filter((e=>"required"!==e.OPTIONS.name)),e)))}length(e,t=g.length){return this.test({message:t,name:"length",exclusive:!0,params:{length:e},skipAbsent:!0,test(t){return t.length===this.resolve(e)}})}min(e,t=g.min){return this.test({message:t,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(t){return t.length>=this.resolve(e)}})}max(e,t=g.max){return this.test({name:"max",exclusive:!0,message:t,params:{max:e},skipAbsent:!0,test(t){return t.length<=this.resolve(e)}})}matches(e,t){let s,r,n=!1;return t&&("object"==typeof t?({excludeEmptyString:n=!1,message:s,name:r}=t):s=t),this.test({name:r||"matches",message:s||g.matches,params:{regex:e},skipAbsent:!0,test:t=>""===t&&n||-1!==t.search(e)})}email(e=g.email){return this.matches(Z,{name:"email",message:e,excludeEmptyString:!0})}url(e=g.url){return this.matches(Y,{name:"url",message:e,excludeEmptyString:!0})}uuid(e=g.uuid){return this.matches(L,{name:"uuid",message:e,excludeEmptyString:!1})}datetime(e){let t,s,r="";return e&&("object"==typeof e?({message:r="",allowOffset:t=!1,precision:s}=e):r=e),this.matches(K,{name:"datetime",message:r||g.datetime,excludeEmptyString:!0}).test({name:"datetime_offset",message:r||g.datetime_offset,params:{allowOffset:t},skipAbsent:!0,test:e=>{if(!e||t)return!0;const s=R(e);return!!s&&!!s.z}}).test({name:"datetime_precision",message:r||g.datetime_precision,params:{precision:s},skipAbsent:!0,test:e=>{if(!e||null==s)return!0;const t=R(e);return!!t&&t.precision===s}})}ensure(){return this.default("").transform((e=>null===e?"":e))}trim(e=g.trim){return this.transform((e=>null!=e?e.trim():e)).test({message:e,name:"trim",test:J})}lowercase(e=g.lowercase){return this.transform((e=>S(e)?e:e.toLowerCase())).test({message:e,name:"string_case",exclusive:!0,skipAbsent:!0,test:e=>S(e)||e===e.toLowerCase()})}uppercase(e=g.uppercase){return this.transform((e=>S(e)?e:e.toUpperCase())).test({message:e,name:"string_case",exclusive:!0,skipAbsent:!0,test:e=>S(e)||e===e.toUpperCase()})}}G.prototype=H.prototype;let Q=new Date("");class W extends V{constructor(){super({type:"date",check(e){return t=e,"[object Date]"===Object.prototype.toString.call(t)&&!isNaN(e.getTime());var t}}),this.withMutation((()=>{this.transform(((e,t,s)=>!s.spec.coerce||s.isType(e)||null===e?e:(e=function(e){const t=R(e);if(!t)return Date.parse?Date.parse(e):Number.NaN;if(void 0===t.z&&void 0===t.plusMinus)return new Date(t.year,t.month,t.day,t.hour,t.minute,t.second,t.millisecond).valueOf();let s=0;return"Z"!==t.z&&void 0!==t.plusMinus&&(s=60*t.hourOffset+t.minuteOffset,"+"===t.plusMinus&&(s=0-s)),Date.UTC(t.year,t.month,t.day,t.hour,t.minute+s,t.second,t.millisecond)}(e),isNaN(e)?W.INVALID_DATE:new Date(e))))}))}prepareParam(e,t){let s;if(E.isRef(e))s=e;else{let r=this.cast(e);if(!this._typeCheck(r))throw new TypeError(`\`${t}\` must be a Date or a value that can be \`cast()\` to a Date`);s=r}return s}min(e,t=b.min){let s=this.prepareParam(e,"min");return this.test({message:t,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(e){return e>=this.resolve(s)}})}max(e,t=b.max){let s=this.prepareParam(e,"max");return this.test({message:t,name:"max",exclusive:!0,params:{max:e},skipAbsent:!0,test(e){return e<=this.resolve(s)}})}}function X(e,t){let s=1/0;return e.some(((e,r)=>{var n;if(null!=(n=t.path)&&n.includes(e))return s=r,!0})),s}function ee(e){return(t,s)=>X(e,t)-X(e,s)}W.INVALID_DATE=Q,W.prototype;const te=(e,t,s)=>{if("string"!=typeof e)return e;let r=e;try{r=JSON.parse(e)}catch(e){}return s.isType(r)?r:e};function se(e){if("fields"in e){const t={};for(const[s,r]of Object.entries(e.fields))t[s]=se(r);return e.setFields(t)}if("array"===e.type){const t=e.optional();return t.innerType&&(t.innerType=se(t.innerType)),t}return"tuple"===e.type?e.optional().clone({types:e.spec.types.map(se)}):"optional"in e?e.optional():e}let re=e=>"[object Object]"===Object.prototype.toString.call(e);function ne(e,t){let s=Object.keys(e.fields);return Object.keys(t).filter((e=>-1===s.indexOf(e)))}const ie=ee([]);function ae(e){return new oe(e)}class oe extends V{constructor(e){super({type:"object",check:e=>re(e)||"function"==typeof e}),this.fields=Object.create(null),this._sortErrors=ie,this._nodes=[],this._excludedEdges=[],this.withMutation((()=>{e&&this.shape(e)}))}_cast(e,t={}){var s;let r=super._cast(e,t);if(void 0===r)return this.getDefault(t);if(!this._typeCheck(r))return r;let n=this.fields,i=null!=(s=t.stripUnknown)?s:this.spec.noUnknown,a=[].concat(this._nodes,Object.keys(r).filter((e=>!this._nodes.includes(e)))),o={},l=Object.assign({},t,{parent:o,__validating:t.__validating||!1}),u=!1;for(const e of a){let s=n[e],a=e in r;if(s){let n,i=r[e];l.path=(t.path?`${t.path}.`:"")+e,s=s.resolve({value:i,context:t.context,parent:o});let a=s instanceof V?s.spec:void 0,c=null==a?void 0:a.strict;if(null!=a&&a.strip){u=u||e in r;continue}n=t.__validating&&c?r[e]:s.cast(r[e],l),void 0!==n&&(o[e]=n)}else a&&!i&&(o[e]=r[e]);a===e in o&&o[e]===r[e]||(u=!0)}return u?o:r}_validate(e,t={},s,r){let{from:n=[],originalValue:i=e,recursive:a=this.spec.recursive}=t;t.from=[{schema:this,value:i},...n],t.__validating=!0,t.originalValue=i,super._validate(e,t,s,((e,n)=>{if(!a||!re(n))return void r(e,n);i=i||n;let o=[];for(let e of this._nodes){let s=this.fields[e];s&&!E.isRef(s)&&o.push(s.asNestedTest({options:t,key:e,parent:n,parentPath:t.path,originalParent:i}))}this.runTests({tests:o,value:n,originalValue:i,options:t},s,(t=>{r(t.sort(this._sortErrors).concat(e),n)}))}))}clone(e){const t=super.clone(e);return t.fields=Object.assign({},this.fields),t._nodes=this._nodes,t._excludedEdges=this._excludedEdges,t._sortErrors=this._sortErrors,t}concat(e){let t=super.concat(e),s=t.fields;for(let[e,t]of Object.entries(this.fields)){const r=s[e];s[e]=void 0===r?t:r}return t.withMutation((t=>t.setFields(s,[...this._excludedEdges,...e._excludedEdges])))}_getDefault(e){if("default"in this.spec)return super._getDefault(e);if(!this._nodes.length)return;let t={};return this._nodes.forEach((s=>{var r;const n=this.fields[s];let i=e;null!=(r=i)&&r.value&&(i=Object.assign({},i,{parent:i.value,value:i.value[s]})),t[s]=n&&"getDefault"in n?n.getDefault(i):void 0})),t}setFields(t,r){let n=this.clone();return n.fields=t,n._nodes=function(t,r=[]){let n=[],i=new Set,a=new Set(r.map((([e,t])=>`${e}-${t}`)));function o(t,s){let r=e.split(t)[0];i.add(r),a.has(`${s}-${r}`)||n.push([s,r])}for(const e of Object.keys(t)){let s=t[e];i.add(e),E.isRef(s)&&s.isSibling?o(s.path,e):T(s)&&"deps"in s&&s.deps.forEach((t=>o(t,e)))}return s.array(Array.from(i),n).reverse()}(t,r),n._sortErrors=ee(Object.keys(t)),r&&(n._excludedEdges=r),n}shape(e,t=[]){return this.clone().withMutation((s=>{let r=s._excludedEdges;return t.length&&(Array.isArray(t[0])||(t=[t]),r=[...s._excludedEdges,...t]),s.setFields(Object.assign(s.fields,e),r)}))}partial(){const e={};for(const[t,s]of Object.entries(this.fields))e[t]="optional"in s&&s.optional instanceof Function?s.optional():s;return this.setFields(e)}deepPartial(){return se(this)}pick(e){const t={};for(const s of e)this.fields[s]&&(t[s]=this.fields[s]);return this.setFields(t,this._excludedEdges.filter((([t,s])=>e.includes(t)&&e.includes(s))))}omit(e){const t=[];for(const s of Object.keys(this.fields))e.includes(s)||t.push(s);return this.pick(t)}from(t,s,r){let n=e.getter(t,!0);return this.transform((i=>{if(!i)return i;let a=i;return((t,s)=>{const r=[...e.normalizePath(s)];if(1===r.length)return r[0]in t;let n=r.pop(),i=e.getter(e.join(r),!0)(t);return!(!i||!(n in i))})(i,t)&&(a=Object.assign({},i),r||delete a[t],a[s]=n(i)),a}))}json(){return this.transform(te)}exact(e){return this.test({name:"exact",exclusive:!0,message:e||_.exact,test(e){if(null==e)return!0;const t=ne(this.schema,e);return 0===t.length||this.createError({params:{properties:t.join(", ")}})}})}stripUnknown(){return this.clone({noUnknown:!0})}noUnknown(e=!0,t=_.noUnknown){"boolean"!=typeof e&&(t=e,e=!0);let s=this.test({name:"noUnknown",exclusive:!0,message:t,test(t){if(null==t)return!0;const s=ne(this.schema,t);return!e||0===s.length||this.createError({params:{unknown:s.join(", ")}})}});return s.spec.noUnknown=e,s}unknown(e=!0,t=_.noUnknown){return this.noUnknown(!e,t)}transformKeys(e){return this.transform((t=>{if(!t)return t;const s={};for(const r of Object.keys(t))s[e(r)]=t[r];return s}))}camelCase(){return this.transformKeys(t.camelCase)}snakeCase(){return this.transformKeys(t.snakeCase)}constantCase(){return this.transformKeys((e=>t.snakeCase(e).toUpperCase()))}describe(e){const t=(e?this.resolve(e):this).clone(),s=super.describe(e);s.fields={};for(const[n,i]of Object.entries(t.fields)){var r;let t=e;null!=(r=t)&&r.value&&(t=Object.assign({},t,{parent:t.value,value:t.value[n]})),s.fields[n]=i.describe(t)}return s}}function le(e){return new ue(e)}ae.prototype=oe.prototype;class ue extends V{constructor(e){super({type:"array",spec:{types:e},check:e=>Array.isArray(e)}),this.innerType=void 0,this.innerType=e}_cast(e,t){const s=super._cast(e,t);if(!this._typeCheck(s)||!this.innerType)return s;let r=!1;const n=s.map(((e,s)=>{const n=this.innerType.cast(e,Object.assign({},t,{path:`${t.path||""}[${s}]`}));return n!==e&&(r=!0),n}));return r?n:s}_validate(e,t={},s,r){var n;let i=this.innerType,a=null!=(n=t.recursive)?n:this.spec.recursive;null!=t.originalValue&&t.originalValue,super._validate(e,t,s,((n,o)=>{var l;if(!a||!i||!this._typeCheck(o))return void r(n,o);let u=new Array(o.length);for(let s=0;s<o.length;s++){var c;u[s]=i.asNestedTest({options:t,index:s,parent:o,parentPath:t.path,originalParent:null!=(c=t.originalValue)?c:e})}this.runTests({value:o,tests:u,originalValue:null!=(l=t.originalValue)?l:e,options:t},s,(e=>r(e.concat(n),o)))}))}clone(e){const t=super.clone(e);return t.innerType=this.innerType,t}json(){return this.transform(te)}concat(e){let t=super.concat(e);return t.innerType=this.innerType,e.innerType&&(t.innerType=t.innerType?t.innerType.concat(e.innerType):e.innerType),t}of(e){let t=this.clone();if(!T(e))throw new TypeError("`array.of()` sub-schema must be a valid yup schema not: "+u(e));return t.innerType=e,t.spec=Object.assign({},t.spec,{types:e}),t}length(e,t=w.length){return this.test({message:t,name:"length",exclusive:!0,params:{length:e},skipAbsent:!0,test(t){return t.length===this.resolve(e)}})}min(e,t){return t=t||w.min,this.test({message:t,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(t){return t.length>=this.resolve(e)}})}max(e,t){return t=t||w.max,this.test({message:t,name:"max",exclusive:!0,params:{max:e},skipAbsent:!0,test(t){return t.length<=this.resolve(e)}})}ensure(){return this.default((()=>[])).transform(((e,t)=>this._typeCheck(e)?e:null==t?[]:[].concat(t)))}compact(e){let t=e?(t,s,r)=>!e(t,s,r):e=>!!e;return this.transform((e=>null!=e?e.filter(t):e))}describe(e){const t=(e?this.resolve(e):this).clone(),s=super.describe(e);if(t.innerType){var r;let n=e;null!=(r=n)&&r.value&&(n=Object.assign({},n,{parent:n.value,value:n.value[0]})),s.innerType=t.innerType.describe(n)}return s}}function ce(e){return new pe(e)}function he(e){try{return e()}catch(e){if(y.isError(e))return Promise.reject(e);throw e}}le.prototype=ue.prototype;class pe{constructor(e){this.type="lazy",this.__isYupSchema__=!0,this.spec=void 0,this._resolve=(e,t={})=>{let s=this.builder(e,t);if(!T(s))throw new TypeError("lazy() functions must return a valid schema");return this.spec.optional&&(s=s.optional()),s.resolve(t)},this.builder=e,this.spec={meta:void 0,optional:!1}}clone(e){const t=new pe(this.builder);return t.spec=Object.assign({},this.spec,e),t}optionality(e){return this.clone({optional:e})}optional(){return this.optionality(!0)}resolve(e){return this._resolve(e.value,e)}cast(e,t){return this._resolve(e,t).cast(e,t)}asNestedTest(e){let{key:t,index:s,parent:r,options:n}=e,i=r[null!=s?s:t];return this._resolve(i,Object.assign({},n,{value:i,parent:r})).asNestedTest(e)}validate(e,t){return he((()=>this._resolve(e,t).validate(e,t)))}validateSync(e,t){return this._resolve(e,t).validateSync(e,t)}validateAt(e,t,s){return he((()=>this._resolve(t,s).validateAt(e,t,s)))}validateSyncAt(e,t,s){return this._resolve(t,s).validateSyncAt(e,t,s)}isValid(e,t){try{return this._resolve(e,t).isValid(e,t)}catch(e){if(y.isError(e))return Promise.resolve(!1);throw e}}isValidSync(e,t){return this._resolve(e,t).isValidSync(e,t)}describe(e){return e?this.resolve(e).describe(e):{type:"lazy",meta:this.spec.meta,label:void 0}}meta(...e){if(0===e.length)return this.spec.meta;let t=this.clone();return t.spec.meta=Object.assign(t.spec.meta||{},e[0]),t}}export{ue as ArraySchema,I as BooleanSchema,W as DateSchema,pe as LazySchema,P as MixedSchema,oe as ObjectSchema,V as Schema,H as StringSchema,y as ValidationError,le as array,q as bool,q as boolean,A as getIn,T as isSchema,ce as lazy,z as mixed,ae as object,u as printValue,G as string};
|
|
2
2
|
//# sourceMappingURL=index.esm.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{j as e}from"../../../_virtual/jsx-runtime.js";import{useState as
|
|
1
|
+
import{j as e}from"../../../_virtual/jsx-runtime.js";import{useState as l,useEffect as i}from"react";import o from"./LivePreview.module.scss.js";import s from"../SimpleLabelValue/SimpleLabelValue.js";import n from"../MethodAccordion/MethodAccordion.js";import{useFormikContext as t}from"../../../node_modules/formik/dist/formik.esm.js";import{tagsTableHeaders as r,methodColorMapping as a}from"../../constants/index.js";import d from"../table/tags-table.js";import{d as c}from"../../../_virtual/index.js";import v from"../Tooltip/Tooltip.js";const u=({transformedData:u})=>{var p,m;const[x,h]=l();l({});const[j,D]=l([]);l({});const{values:g}=t(),{info:f,components:b,tags:N}=g,{securitySchemes:y}=b,C=y&&"object"==typeof y&&Object.keys(y).length?Object.keys(y)[0]:null;i((()=>{g.tags&&(h(w(g.tags,!0)),D(g.tags))}),[g.tags]);const w=(l,i)=>l.map(((l,s)=>{var n,t,r,a,d,u,p,m,x,h,j,D,g,f,b,N,y,C,w;return{id:s,tagName:l.name,description:e.jsx(v,{allowHTML:!0,disabled:(null===(n=l.description)||void 0===n?void 0:n.length)<=12,content:e.jsx("div",{style:{padding:"0.625rem"},children:l.description}),arrowWithBorder:!0,placement:"bottom-end",type:"function",delay:[0,0],children:e.jsx("div",{className:o.paramDescContainer,children:e.jsxs("p",{className:o.editDescBtn,children:[l.description?l.description.substring(0,12):"-",l.description&&l.description.length>12?"...":""]})})},`${s}-description`),externalDocs:e.jsxs("div",{className:o.paramDescContainer,children:[l.externalDocs&&l.externalDocs.url&&"-"!=l.externalDocs.url?e.jsxs("a",{className:o.editDescBtn,href:(null===(t=l.externalDocs)||void 0===t?void 0:t.url)&&(null===(r=l.externalDocs)||void 0===r?void 0:r.url.indexOf("http"))>-1?null===(a=l.externalDocs)||void 0===a?void 0:a.url:`https://${null===(d=l.externalDocs)||void 0===d?void 0:d.url}`,rel:"noopener noreferrer",target:"_blank",children:[(null===(u=null==l?void 0:l.externalDocs)||void 0===u?void 0:u.url)&&!(null===(p=null==l?void 0:l.externalDocs)||void 0===p?void 0:p.description)?null===(m=null==l?void 0:l.externalDocs)||void 0===m?void 0:m.url:null,(null===(x=null==l?void 0:l.externalDocs)||void 0===x?void 0:x.description)?null===(j=null===(h=null==l?void 0:l.externalDocs)||void 0===h?void 0:h.description)||void 0===j?void 0:j.substring(0,12):(null===(D=null==l?void 0:l.externalDocs)||void 0===D?void 0:D.url)?null:"-",(null===(g=null==l?void 0:l.externalDocs)||void 0===g?void 0:g.description)&&(null===(b=null===(f=null==l?void 0:l.externalDocs)||void 0===f?void 0:f.description)||void 0===b?void 0:b.length)>12?"...":""]}):e.jsxs(c.Button,{className:o.editDescBtn,variant:"link",color:"action",children:[(null===(N=l.externalDocs)||void 0===N?void 0:N.description)?null===(y=l.externalDocs)||void 0===y?void 0:y.description.substring(0,12):"-",(null===(C=l.externalDocs)||void 0===C?void 0:C.description)&&(null===(w=l.externalDocs)||void 0===w?void 0:w.description.length)>12?"...":""]}),!i&&e.jsx("div",{className:o.paramDescContainer_separator}),!i&&e.jsx(c.Button,{className:o.deleteParamBtn,variant:"link",color:"error",onClick:()=>null})]})}})),k=C?y[C].scheme||y[C].type:"-";return e.jsx("div",{className:o.livePreviewContainer,children:e.jsx("div",{className:"row",children:e.jsxs("div",{className:"col-md-12",children:[e.jsxs("div",{className:o.titleContainer,children:[e.jsx("p",{className:o.apiName,children:(null===(p=null==f?void 0:f.title)||void 0===p?void 0:p.trim())||"-"}),e.jsx(c.Chip,{className:o.livePreviewChip,children:"Live Preview"})]}),e.jsx(s,{label:"API authentication type: ",value:k&&"public"===k.toLowerCase()?"Keyless":k},"APIAuthenticationType"),e.jsx(s,{label:"Version: ",value:(null==f?void 0:f.version)||"-"},"version"),e.jsx(s,{label:"Description: ",value:(null===(m=null==f?void 0:f.description)||void 0===m?void 0:m.trim())||"-"},"description"),e.jsx(s,{label:"Tags: "},"tags"),e.jsx(d,{id:"tags-table",data:x,headCells:r,isFormOpen:!1,setIsFormOpen:()=>null,saveNewRow:()=>null,readOnly:!0}),e.jsx(s,{label:"Endpoints "},"endpoints"),g.paths.map((l=>e.jsx("div",{className:o.methodsContainer,children:Object.entries(l.methods.sort(((e,l)=>a[e.type].order+a[l.type].order)).reduce(((e,l)=>{var i;return((null===(i=l.tags)||void 0===i?void 0:i.length)?null==l?void 0:l.tags:["default"]).forEach((i=>{e[i]||(e[i]=[]),e[i].push(l)})),e}),{})).map((([i,o])=>e.jsxs("div",{children:[e.jsx("h3",{children:i}),null==o?void 0:o.map(((i,o)=>e.jsx(n,{readOnly:!0,method:i,path:l.path,tags:g.tags})))]},i)))},l.path)))]})})})};export{u as default};
|
|
2
2
|
//# sourceMappingURL=LivePreview.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LivePreview.js","sources":["../../../../src/components/LivePreview/LivePreview.tsx"],"sourcesContent":["import React, { useEffect, useState } from 'react'\r\nimport styles from './LivePreview.module.scss'\r\nimport SimpleLabelValue from '../../components/SimpleLabelValue'\r\nimport MethodsAccordion from '../../components/MethodAccordion/MethodAccordion'\r\nimport { TransformedOpenApi } from '../../types/transformedOpenApi'\r\nimport { useFormikContext } from 'formik'\r\nimport { methodColorMapping, tagsTableHeaders } from '../../constants/index'\r\nimport TagsTable from '../table/tags-table'\r\nimport { Button, Chip } from 'digitinary-ui'\r\nimport Tooltip from '../../components/Tooltip/Tooltip'\r\n\r\ninterface LivePreviewProps {\r\n transformedData?: TransformedOpenApi\r\n}\r\n\r\nconst LivePreview: React.FC<LivePreviewProps> = ({ transformedData }) => {\r\n const [tableRecords, setTableRecords] = useState()\r\n const [tooltipRefs, setTooltipRefs] = useState<{ [key: number]: any }>({})\r\n const [tableData, setTableData] = useState([])\r\n const [externalTooltipRefs, setExternalTooltipRefs] = useState<{ [key: number]: any }>({})\r\n const { values } = useFormikContext<TransformedOpenApi>()\r\n const { info, components, tags } = values\r\n const { securitySchemes } = components\r\n const securityKey =\r\n securitySchemes && typeof securitySchemes == 'object' && Object.keys(securitySchemes).length\r\n ? Object.keys(securitySchemes)[0]\r\n : null\r\n\r\n useEffect(() => {\r\n if (values.tags) {\r\n setTableRecords(generateTableData(values.tags, true))\r\n setTableData(values.tags)\r\n }\r\n }, [values.tags])\r\n\r\n const generateTableData = (items, readOnly) => {\r\n return items.map((item, index) => ({\r\n id: index,\r\n tagName: item.name,\r\n description: (\r\n <Tooltip\r\n key={`${index}-description`}\r\n allowHTML\r\n disabled={item.description?.length <= 12}\r\n content={<div style={{ padding: '0.625rem' }}>{item.description}</div>}\r\n arrowWithBorder\r\n placement=\"bottom-end\"\r\n type=\"function\"\r\n delay={[0, 0]}\r\n >\r\n <div className={styles.paramDescContainer}>\r\n <p className={styles.editDescBtn}>\r\n {item.description ? item.description.substring(0, 12) : '-'}\r\n {item.description && item.description.length > 12 ? '...' : ''}\r\n </p>\r\n </div>\r\n </Tooltip>\r\n ),\r\n externalDocs: (\r\n <div className={styles.paramDescContainer}>\r\n {item.externalDocs && item.externalDocs.url && item.externalDocs.url != '-' ? (\r\n <a\r\n className={styles.editDescBtn}\r\n href={\r\n item.externalDocs?.url && item.externalDocs?.url.indexOf('http') > -1\r\n ? item.externalDocs?.url\r\n : `https://${item.externalDocs?.url}`\r\n }\r\n rel=\"noopener noreferrer\"\r\n target=\"_blank\"\r\n >\r\n {item?.externalDocs?.description\r\n ? item?.externalDocs?.description?.substring(0, 12)\r\n : '-'}\r\n {item?.externalDocs?.description && item?.externalDocs?.description?.length > 12\r\n ? '...'\r\n : ''}\r\n </a>\r\n ) : (\r\n <Button className={styles.editDescBtn} variant=\"link\" color=\"action\">\r\n {item.externalDocs?.description\r\n ? item.externalDocs?.description.substring(0, 12)\r\n : '-'}\r\n {item.externalDocs?.description && item.externalDocs?.description.length > 12\r\n ? '...'\r\n : ''}\r\n </Button>\r\n )}\r\n\r\n {/* </Tooltip> */}\r\n\r\n {!readOnly && <div className={styles.paramDescContainer_separator}></div>}\r\n\r\n {!readOnly && (\r\n <Button\r\n className={styles.deleteParamBtn}\r\n variant=\"link\"\r\n color=\"error\"\r\n onClick={() => null}\r\n ></Button>\r\n )}\r\n </div>\r\n ),\r\n }))\r\n }\r\n\r\n return (\r\n <div className={styles.livePreviewContainer}>\r\n <div className=\"row\">\r\n <div className=\"col-md-12\">\r\n <div className={styles.titleContainer}>\r\n <p className={styles.apiName}>{info?.title?.trim() || '-'}</p>\r\n <Chip className={styles.livePreviewChip}>Live Preview</Chip>\r\n </div>\r\n <SimpleLabelValue\r\n key={'APIAuthenticationType'}\r\n label={'API authentication type: '}\r\n value={\r\n !!securityKey\r\n ? securitySchemes[securityKey].scheme || securitySchemes[securityKey].type\r\n : '-'\r\n }\r\n />\r\n <SimpleLabelValue key={'version'} label={'Version: '} value={info?.version || '-'} />\r\n <SimpleLabelValue\r\n key={'description'}\r\n label={'Description: '}\r\n value={info?.description?.trim() || '-'}\r\n />\r\n\r\n <SimpleLabelValue key={'tags'} label={'Tags: '} />\r\n <TagsTable\r\n id=\"tags-table\"\r\n data={tableRecords}\r\n headCells={tagsTableHeaders}\r\n isFormOpen={false}\r\n setIsFormOpen={() => null}\r\n saveNewRow={() => null}\r\n readOnly={true}\r\n />\r\n\r\n <SimpleLabelValue key={'endpoints'} label={'Endpoints '} />\r\n {values.paths.map((path) => (\r\n <div className={styles.methodsContainer} key={path.path}>\r\n {Object.entries(\r\n path.methods\r\n .sort(\r\n (a, b) => methodColorMapping[a.type].order + methodColorMapping[b.type].order\r\n )\r\n .reduce((groupedMethods, method) => {\r\n // Handle methods without tags\r\n const tags = method.tags?.length ? method?.tags : ['default']\r\n\r\n tags.forEach((tag) => {\r\n if (!groupedMethods[tag]) {\r\n groupedMethods[tag] = []\r\n }\r\n groupedMethods[tag].push(method)\r\n })\r\n\r\n return groupedMethods\r\n }, {})\r\n ).map(([tag, methods]) => (\r\n <div key={tag}>\r\n <h3>{tag}</h3>\r\n {methods?.map((method, methodIndex) => (\r\n <MethodsAccordion\r\n readOnly\r\n method={method}\r\n path={path.path}\r\n tags={values.tags}\r\n />\r\n ))}\r\n </div>\r\n ))}\r\n </div>\r\n ))}\r\n </div>\r\n </div>\r\n </div>\r\n )\r\n}\r\n\r\nexport default LivePreview\r\n"],"names":["LivePreview","transformedData","tableRecords","setTableRecords","useState","tableData","setTableData","values","useFormikContext","info","components","tags","securitySchemes","securityKey","Object","keys","length","useEffect","generateTableData","items","readOnly","map","item","index","id","tagName","name","description","_jsx","jsx","Tooltip","allowHTML","disabled","_a","content","style","padding","children","arrowWithBorder","placement","type","delay","className","styles","paramDescContainer","_jsxs","jsxs","editDescBtn","substring","externalDocs","url","href","_b","_c","indexOf","_d","_e","rel","target","_f","_h","_g","_j","_l","_k","Button","variant","color","_m","_o","_p","_q","paramDescContainer_separator","deleteParamBtn","onClick","livePreviewContainer","titleContainer","apiName","title","trim","Chip","livePreviewChip","SimpleLabelValue","label","value","scheme","version","TagsTable","data","headCells","tagsTableHeaders","isFormOpen","setIsFormOpen","saveNewRow","paths","path","methodsContainer","entries","methods","sort","a","b","methodColorMapping","order","reduce","groupedMethods","method","forEach","tag","push","methodIndex","MethodsAccordion"],"mappings":"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"}
|
|
1
|
+
{"version":3,"file":"LivePreview.js","sources":["../../../../src/components/LivePreview/LivePreview.tsx"],"sourcesContent":["import React, { useEffect, useState } from 'react'\r\nimport styles from './LivePreview.module.scss'\r\nimport SimpleLabelValue from '../../components/SimpleLabelValue'\r\nimport MethodsAccordion from '../../components/MethodAccordion/MethodAccordion'\r\nimport { TransformedOpenApi } from '../../types/transformedOpenApi'\r\nimport { useFormikContext } from 'formik'\r\nimport { methodColorMapping, tagsTableHeaders } from '../../constants/index'\r\nimport TagsTable from '../table/tags-table'\r\nimport { Button, Chip } from 'digitinary-ui'\r\nimport Tooltip from '../../components/Tooltip/Tooltip'\r\n\r\ninterface LivePreviewProps {\r\n transformedData?: TransformedOpenApi\r\n}\r\n\r\nconst LivePreview: React.FC<LivePreviewProps> = ({ transformedData }) => {\r\n const [tableRecords, setTableRecords] = useState()\r\n const [tooltipRefs, setTooltipRefs] = useState<{ [key: number]: any }>({})\r\n const [tableData, setTableData] = useState([])\r\n const [externalTooltipRefs, setExternalTooltipRefs] = useState<{ [key: number]: any }>({})\r\n const { values } = useFormikContext<TransformedOpenApi>()\r\n const { info, components, tags } = values\r\n const { securitySchemes } = components\r\n const securityKey =\r\n securitySchemes && typeof securitySchemes == 'object' && Object.keys(securitySchemes).length\r\n ? Object.keys(securitySchemes)[0]\r\n : null\r\n\r\n useEffect(() => {\r\n if (values.tags) {\r\n setTableRecords(generateTableData(values.tags, true))\r\n setTableData(values.tags)\r\n }\r\n }, [values.tags])\r\n\r\n const generateTableData = (items, readOnly) => {\r\n return items.map((item, index) => ({\r\n id: index,\r\n tagName: item.name,\r\n description: (\r\n <Tooltip\r\n key={`${index}-description`}\r\n allowHTML\r\n disabled={item.description?.length <= 12}\r\n content={<div style={{ padding: '0.625rem' }}>{item.description}</div>}\r\n arrowWithBorder\r\n placement=\"bottom-end\"\r\n type=\"function\"\r\n delay={[0, 0]}\r\n >\r\n <div className={styles.paramDescContainer}>\r\n <p className={styles.editDescBtn}>\r\n {item.description ? item.description.substring(0, 12) : '-'}\r\n {item.description && item.description.length > 12 ? '...' : ''}\r\n </p>\r\n </div>\r\n </Tooltip>\r\n ),\r\n externalDocs: (\r\n <div className={styles.paramDescContainer}>\r\n {item.externalDocs && item.externalDocs.url && item.externalDocs.url != '-' ? (\r\n <a\r\n className={styles.editDescBtn}\r\n href={\r\n item.externalDocs?.url && item.externalDocs?.url.indexOf('http') > -1\r\n ? item.externalDocs?.url\r\n : `https://${item.externalDocs?.url}`\r\n }\r\n rel=\"noopener noreferrer\"\r\n target=\"_blank\"\r\n >\r\n {item?.externalDocs?.url && !item?.externalDocs?.description\r\n ? item?.externalDocs?.url\r\n : null}\r\n {item?.externalDocs?.description\r\n ? item?.externalDocs?.description?.substring(0, 12)\r\n : !item?.externalDocs?.url ? '-': null}\r\n {item?.externalDocs?.description && item?.externalDocs?.description?.length > 12\r\n ? '...'\r\n : ''}\r\n </a>\r\n ) : (\r\n <Button className={styles.editDescBtn} variant=\"link\" color=\"action\">\r\n {item.externalDocs?.description\r\n ? item.externalDocs?.description.substring(0, 12)\r\n : '-'}\r\n {item.externalDocs?.description && item.externalDocs?.description.length > 12\r\n ? '...'\r\n : ''}\r\n </Button>\r\n )}\r\n\r\n {/* </Tooltip> */}\r\n\r\n {!readOnly && <div className={styles.paramDescContainer_separator}></div>}\r\n\r\n {!readOnly && (\r\n <Button\r\n className={styles.deleteParamBtn}\r\n variant=\"link\"\r\n color=\"error\"\r\n onClick={() => null}\r\n ></Button>\r\n )}\r\n </div>\r\n ),\r\n }))\r\n }\r\n\r\n const securityScheme = !!securityKey\r\n ? securitySchemes[securityKey].scheme || securitySchemes[securityKey].type\r\n : '-'\r\n\r\n return (\r\n <div className={styles.livePreviewContainer}>\r\n <div className=\"row\">\r\n <div className=\"col-md-12\">\r\n <div className={styles.titleContainer}>\r\n <p className={styles.apiName}>{info?.title?.trim() || '-'}</p>\r\n <Chip className={styles.livePreviewChip}>Live Preview</Chip>\r\n </div>\r\n <SimpleLabelValue\r\n key={'APIAuthenticationType'}\r\n label={'API authentication type: '}\r\n value={\r\n !!securityScheme && securityScheme.toLowerCase() === 'public'\r\n ? 'Keyless'\r\n : securityScheme\r\n }\r\n />\r\n <SimpleLabelValue key={'version'} label={'Version: '} value={info?.version || '-'} />\r\n <SimpleLabelValue\r\n key={'description'}\r\n label={'Description: '}\r\n value={info?.description?.trim() || '-'}\r\n />\r\n\r\n <SimpleLabelValue key={'tags'} label={'Tags: '} />\r\n <TagsTable\r\n id=\"tags-table\"\r\n data={tableRecords}\r\n headCells={tagsTableHeaders}\r\n isFormOpen={false}\r\n setIsFormOpen={() => null}\r\n saveNewRow={() => null}\r\n readOnly={true}\r\n />\r\n\r\n <SimpleLabelValue key={'endpoints'} label={'Endpoints '} />\r\n {values.paths.map((path) => (\r\n <div className={styles.methodsContainer} key={path.path}>\r\n {Object.entries(\r\n path.methods\r\n .sort(\r\n (a, b) => methodColorMapping[a.type].order + methodColorMapping[b.type].order\r\n )\r\n .reduce((groupedMethods, method) => {\r\n // Handle methods without tags\r\n const tags = method.tags?.length ? method?.tags : ['default']\r\n\r\n tags.forEach((tag) => {\r\n if (!groupedMethods[tag]) {\r\n groupedMethods[tag] = []\r\n }\r\n groupedMethods[tag].push(method)\r\n })\r\n\r\n return groupedMethods\r\n }, {})\r\n ).map(([tag, methods]) => (\r\n <div key={tag}>\r\n <h3>{tag}</h3>\r\n {methods?.map((method, methodIndex) => (\r\n <MethodsAccordion\r\n readOnly\r\n method={method}\r\n path={path.path}\r\n tags={values.tags}\r\n />\r\n ))}\r\n </div>\r\n ))}\r\n </div>\r\n ))}\r\n </div>\r\n </div>\r\n </div>\r\n )\r\n}\r\n\r\nexport default LivePreview\r\n"],"names":["LivePreview","transformedData","tableRecords","setTableRecords","useState","tableData","setTableData","values","useFormikContext","info","components","tags","securitySchemes","securityKey","Object","keys","length","useEffect","generateTableData","items","readOnly","map","item","index","id","tagName","name","description","_jsx","jsx","Tooltip","allowHTML","disabled","_a","content","style","padding","children","arrowWithBorder","placement","type","delay","className","styles","paramDescContainer","_jsxs","jsxs","editDescBtn","substring","externalDocs","url","href","_b","_c","indexOf","_d","_e","rel","target","_f","_g","_h","_j","_l","_k","_m","_o","_q","_p","Button","variant","color","_r","_s","_t","_u","paramDescContainer_separator","deleteParamBtn","onClick","securityScheme","scheme","livePreviewContainer","titleContainer","apiName","title","trim","Chip","livePreviewChip","SimpleLabelValue","label","value","toLowerCase","version","TagsTable","data","headCells","tagsTableHeaders","isFormOpen","setIsFormOpen","saveNewRow","paths","path","methodsContainer","entries","methods","sort","a","b","methodColorMapping","order","reduce","groupedMethods","method","forEach","tag","push","methodIndex","MethodsAccordion"],"mappings":"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"}
|
package/dist/styles.css
CHANGED
|
@@ -1,26 +1,121 @@
|
|
|
1
|
-
.
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
.apiInfoForm {
|
|
2
|
+
display: grid;
|
|
3
|
+
padding: 1.25rem 1.875rem;
|
|
4
|
+
gap: 1.25rem;
|
|
5
|
+
}
|
|
6
|
+
.apiInfoForm .paramsTable .paramDescContainer {
|
|
7
|
+
display: flex;
|
|
8
|
+
}
|
|
9
|
+
.apiInfoForm .paramsTable .paramDescContainer .paramDescContainer_separator {
|
|
10
|
+
height: inherit;
|
|
11
|
+
width: 1px;
|
|
12
|
+
background-color: #d8dae5;
|
|
13
|
+
}
|
|
14
|
+
.apiInfoForm .paramsTable .paramDescContainer :global(.customBtn) svg path {
|
|
15
|
+
stroke-width: 0.1;
|
|
16
|
+
}
|
|
17
|
+
.apiInfoForm .paramsTable .paramDescContainer :global(.customBtn).editDescBtn {
|
|
18
|
+
padding: 0;
|
|
19
|
+
margin-right: 1.25rem;
|
|
20
|
+
}
|
|
21
|
+
.apiInfoForm .paramsTable .paramDescContainer :global(.customBtn).editDescBtn :global(.btnContentWrapper) {
|
|
4
22
|
display: flex;
|
|
5
|
-
flex-direction: row;
|
|
6
|
-
justify-content: space-between;
|
|
7
23
|
align-items: center;
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
width: 100%;
|
|
24
|
+
padding: 0;
|
|
25
|
+
font-size: 0.875rem;
|
|
11
26
|
}
|
|
12
|
-
.
|
|
13
|
-
|
|
14
|
-
font-weight: 600;
|
|
15
|
-
font-size: 18px;
|
|
16
|
-
line-height: 25px;
|
|
17
|
-
letter-spacing: 0em;
|
|
27
|
+
.apiInfoForm .paramsTable .paramDescContainer :global(.customBtn).editDescBtn :global(.btnContentWrapper) :global(.endBtnIcon) {
|
|
28
|
+
margin-block: auto;
|
|
18
29
|
}
|
|
19
|
-
.
|
|
20
|
-
|
|
30
|
+
.apiInfoForm .paramsTable .paramDescContainer :global(.customBtn).editDescBtn :global(.btnContentWrapper) :global(.endBtnIcon) svg path {
|
|
31
|
+
fill: #12131a;
|
|
21
32
|
}
|
|
22
|
-
.
|
|
33
|
+
.apiInfoForm .paramsTable .paramDescContainer :global(.customBtn).deleteParamBtn {
|
|
34
|
+
padding: 0;
|
|
35
|
+
border-width: 0 !important;
|
|
36
|
+
}
|
|
37
|
+
.apiInfoForm .paramsTable .paramDescContainer :global(.customBtn).deleteParamBtn :global(.btnContentWrapper) :global(.endBtnIcon) {
|
|
38
|
+
margin-block: auto;
|
|
39
|
+
}
|
|
40
|
+
.apiInfoForm .paramsTable .paramDescContainer :global(.customBtn).deleteParamBtn :global(.btnContentWrapper) :global(.endBtnIcon) svg {
|
|
41
|
+
width: 1.125rem;
|
|
42
|
+
}
|
|
43
|
+
.apiInfoForm .paramsTable .paramDescContainer :global(.customBtn):not(:global(.disabled)):global(.success) :global(.endBtnIcon) {
|
|
44
|
+
margin-block: auto;
|
|
45
|
+
}
|
|
46
|
+
.apiInfoForm .paramsTable .paramDescContainer :global(.customBtn):not(:global(.disabled)):global(.success) :global(.endBtnIcon) svg {
|
|
47
|
+
width: 1.125rem;
|
|
48
|
+
}
|
|
49
|
+
.apiInfoForm .paramsTable .paramDescContainer :global(.customBtn):not(:global(.disabled)):global(.success) :global(.endBtnIcon) svg path {
|
|
50
|
+
fill: #3aaa35;
|
|
51
|
+
}
|
|
52
|
+
.apiInfoForm .paramsTable .externalDocsLink {
|
|
53
|
+
font-size: 0.875rem;
|
|
54
|
+
line-height: 1.25rem;
|
|
23
55
|
cursor: pointer;
|
|
56
|
+
align-self: center;
|
|
57
|
+
margin-right: 2rem;
|
|
58
|
+
}
|
|
59
|
+
.apiInfoForm .paramsTable .editExternalDocs {
|
|
60
|
+
display: flex;
|
|
61
|
+
align-items: center;
|
|
62
|
+
padding-right: 0.625rem;
|
|
63
|
+
}
|
|
64
|
+
.apiInfoForm .paramsTable .editExternalDocs svg {
|
|
65
|
+
cursor: pointer;
|
|
66
|
+
}
|
|
67
|
+
.apiInfoForm .paramsTable .editExternalDocs svg path {
|
|
68
|
+
fill: #12131a;
|
|
69
|
+
}
|
|
70
|
+
.apiInfoForm .paramsTable .editDescTooltipContent {
|
|
71
|
+
display: flex;
|
|
72
|
+
flex-direction: column;
|
|
73
|
+
gap: 0.625rem;
|
|
74
|
+
padding-bottom: 0.625rem;
|
|
75
|
+
}
|
|
76
|
+
.apiInfoForm .paramsTable .editDescTooltipContent > *:not(.editDescTooltipContent_header) {
|
|
77
|
+
margin-inline: 0.625rem;
|
|
78
|
+
}
|
|
79
|
+
.apiInfoForm .paramsTable .editDescTooltipContent .editDescTooltipContent_header {
|
|
80
|
+
font-weight: 600;
|
|
81
|
+
font-size: 0.875rem;
|
|
82
|
+
line-height: 1.25rem;
|
|
83
|
+
padding: 0.75rem 1.25rem;
|
|
84
|
+
border-bottom: 1px solid #d8dae5;
|
|
85
|
+
}
|
|
86
|
+
.apiInfoForm .paramsTable :global(.requiredParam) :global(.headContainer)::after {
|
|
87
|
+
content: "*";
|
|
88
|
+
color: red;
|
|
89
|
+
transform: translateX(0.125rem);
|
|
90
|
+
}
|
|
91
|
+
.apiInfoForm .apiDocRow {
|
|
92
|
+
display: grid;
|
|
93
|
+
grid-template-columns: 1fr 1fr;
|
|
94
|
+
gap: 1.25rem;
|
|
95
|
+
}
|
|
96
|
+
.apiInfoForm .apiInfoForm_tagsChips {
|
|
97
|
+
margin-top: -1.25rem;
|
|
98
|
+
}
|
|
99
|
+
.apiInfoForm .editDescTooltipContent {
|
|
100
|
+
display: flex;
|
|
101
|
+
flex-direction: column;
|
|
102
|
+
gap: 0.625rem;
|
|
103
|
+
padding-bottom: 0.625rem;
|
|
104
|
+
}
|
|
105
|
+
.apiInfoForm .editDescTooltipContent > *:not(.editDescTooltipContent_header) {
|
|
106
|
+
margin-inline: 0.625rem;
|
|
107
|
+
}
|
|
108
|
+
.apiInfoForm .editDescTooltipContent .editDescTooltipContent_header {
|
|
109
|
+
font-weight: 600;
|
|
110
|
+
font-size: 0.875rem;
|
|
111
|
+
line-height: 1.25rem;
|
|
112
|
+
padding: 0.75rem 1.25rem;
|
|
113
|
+
border-bottom: 1px solid #d8dae5;
|
|
114
|
+
}
|
|
115
|
+
.apiInfoForm :global(.requiredParam) :global(.headContainer)::after {
|
|
116
|
+
content: "*";
|
|
117
|
+
color: red;
|
|
118
|
+
transform: translateX(0.125rem);
|
|
24
119
|
}.methodAccordion {
|
|
25
120
|
border: none !important;
|
|
26
121
|
box-shadow: none !important;
|
|
@@ -294,201 +389,117 @@
|
|
|
294
389
|
}
|
|
295
390
|
.methodAccordion.readOnly .methodSummaryContainer .methodExpandArrowContainer {
|
|
296
391
|
background-color: #ebecf2;
|
|
297
|
-
}.
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
}
|
|
302
|
-
.apiInfoForm .paramsTable .paramDescContainer {
|
|
303
|
-
display: flex;
|
|
304
|
-
}
|
|
305
|
-
.apiInfoForm .paramsTable .paramDescContainer .paramDescContainer_separator {
|
|
306
|
-
height: inherit;
|
|
307
|
-
width: 1px;
|
|
308
|
-
background-color: #d8dae5;
|
|
392
|
+
}.json-editor-container {
|
|
393
|
+
overflow: hidden;
|
|
394
|
+
border-bottom-right-radius: 0.3125rem;
|
|
395
|
+
border-bottom-left-radius: 0.3125rem;
|
|
309
396
|
}
|
|
310
|
-
.
|
|
311
|
-
|
|
397
|
+
.json-editor-container .json-editor-label {
|
|
398
|
+
font-size: 0.875rem;
|
|
399
|
+
font-weight: 600;
|
|
400
|
+
line-height: 1.25rem;
|
|
401
|
+
margin-bottom: 0.3125rem;
|
|
312
402
|
}
|
|
313
|
-
.
|
|
314
|
-
|
|
315
|
-
|
|
403
|
+
.json-editor-container .json-editor {
|
|
404
|
+
display: flex;
|
|
405
|
+
flex-direction: column;
|
|
406
|
+
background-color: #142452;
|
|
407
|
+
width: 100%;
|
|
408
|
+
outline: 1px solid transparent;
|
|
409
|
+
position: relative;
|
|
410
|
+
overflow: hidden;
|
|
316
411
|
}
|
|
317
|
-
.
|
|
412
|
+
.json-editor-container .json-editor .actions-container {
|
|
413
|
+
width: 100%;
|
|
414
|
+
height: 5rem;
|
|
415
|
+
padding: 1.25rem;
|
|
416
|
+
border-radius: 0 0 0.3125rem 0.3125rem;
|
|
417
|
+
background: #101e47;
|
|
318
418
|
display: flex;
|
|
419
|
+
flex-direction: row;
|
|
420
|
+
gap: 1.25rem;
|
|
319
421
|
align-items: center;
|
|
320
|
-
padding: 0;
|
|
321
|
-
font-size: 0.875rem;
|
|
322
|
-
}
|
|
323
|
-
.apiInfoForm .paramsTable .paramDescContainer :global(.customBtn).editDescBtn :global(.btnContentWrapper) :global(.endBtnIcon) {
|
|
324
|
-
margin-block: auto;
|
|
325
|
-
}
|
|
326
|
-
.apiInfoForm .paramsTable .paramDescContainer :global(.customBtn).editDescBtn :global(.btnContentWrapper) :global(.endBtnIcon) svg path {
|
|
327
|
-
fill: #12131a;
|
|
328
|
-
}
|
|
329
|
-
.apiInfoForm .paramsTable .paramDescContainer :global(.customBtn).deleteParamBtn {
|
|
330
|
-
padding: 0;
|
|
331
|
-
border-width: 0 !important;
|
|
332
|
-
}
|
|
333
|
-
.apiInfoForm .paramsTable .paramDescContainer :global(.customBtn).deleteParamBtn :global(.btnContentWrapper) :global(.endBtnIcon) {
|
|
334
|
-
margin-block: auto;
|
|
335
422
|
}
|
|
336
|
-
.
|
|
337
|
-
|
|
423
|
+
.json-editor-container .json-editor .actions-container .validate {
|
|
424
|
+
color: #fff;
|
|
425
|
+
text-align: center;
|
|
426
|
+
font-size: 1rem;
|
|
427
|
+
font-style: normal;
|
|
428
|
+
font-weight: 600;
|
|
429
|
+
line-height: 1.25rem;
|
|
430
|
+
width: 8.75rem;
|
|
431
|
+
padding: 0.625rem 2.25rem;
|
|
432
|
+
background-color: rgba(240, 248, 255, 0);
|
|
433
|
+
border-radius: 0.3125rem;
|
|
434
|
+
border: 0.0625rem solid #4d75d8;
|
|
435
|
+
cursor: pointer;
|
|
338
436
|
}
|
|
339
|
-
.
|
|
340
|
-
|
|
437
|
+
.json-editor-container .json-editor .actions-container .validate:disabled {
|
|
438
|
+
color: #babdcc;
|
|
439
|
+
border-color: #a2a5b6;
|
|
341
440
|
}
|
|
342
|
-
.
|
|
343
|
-
|
|
441
|
+
.json-editor-container .json-editor .actions-container .beautify {
|
|
442
|
+
color: #fff;
|
|
443
|
+
text-align: center;
|
|
444
|
+
font-size: 1rem;
|
|
445
|
+
font-style: normal;
|
|
446
|
+
font-weight: 600;
|
|
447
|
+
line-height: 1.25rem;
|
|
448
|
+
width: 8.75rem;
|
|
449
|
+
padding: 0.625rem 2.25rem;
|
|
450
|
+
background-color: rgba(240, 248, 255, 0);
|
|
451
|
+
border-radius: 0.3125rem;
|
|
452
|
+
border: 1px solid #babdcc;
|
|
453
|
+
cursor: pointer;
|
|
344
454
|
}
|
|
345
|
-
.
|
|
346
|
-
|
|
455
|
+
.json-editor-container .json-editor .actions-container .beautify:disabled {
|
|
456
|
+
color: #a2a5b6;
|
|
457
|
+
border-color: #a2a5b6;
|
|
347
458
|
}
|
|
348
|
-
.
|
|
459
|
+
.json-editor-container .json-editor textarea {
|
|
460
|
+
width: 100%;
|
|
461
|
+
padding: 1.25rem;
|
|
349
462
|
font-size: 0.875rem;
|
|
463
|
+
font-style: normal;
|
|
464
|
+
font-weight: 400;
|
|
350
465
|
line-height: 1.25rem;
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
466
|
+
color: white;
|
|
467
|
+
height: 25rem;
|
|
468
|
+
background-color: #142452;
|
|
469
|
+
border: none;
|
|
470
|
+
resize: none;
|
|
354
471
|
}
|
|
355
|
-
.
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
padding-right: 0.625rem;
|
|
472
|
+
.json-editor-container .json-editor textarea:focus, .json-editor-container .json-editor textarea:focus-within, .json-editor-container .json-editor textarea:focus-visible .json-editor-container .json-editor textarea:active {
|
|
473
|
+
outline: none;
|
|
474
|
+
border: none;
|
|
359
475
|
}
|
|
360
|
-
.
|
|
361
|
-
|
|
476
|
+
.json-editor-container .json-editor textarea::-webkit-scrollbar {
|
|
477
|
+
width: 0.5rem;
|
|
362
478
|
}
|
|
363
|
-
.
|
|
364
|
-
|
|
479
|
+
.json-editor-container .json-editor textarea::-webkit-scrollbar-track {
|
|
480
|
+
background-color: #828699;
|
|
481
|
+
border: none;
|
|
482
|
+
border-color: transparent;
|
|
483
|
+
border-top-left-radius: 0;
|
|
365
484
|
}
|
|
366
|
-
.
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
}
|
|
372
|
-
.apiInfoForm .paramsTable .editDescTooltipContent > *:not(.editDescTooltipContent_header) {
|
|
373
|
-
margin-inline: 0.625rem;
|
|
374
|
-
}
|
|
375
|
-
.apiInfoForm .paramsTable .editDescTooltipContent .editDescTooltipContent_header {
|
|
376
|
-
font-weight: 600;
|
|
377
|
-
font-size: 0.875rem;
|
|
378
|
-
line-height: 1.25rem;
|
|
379
|
-
padding: 0.75rem 1.25rem;
|
|
380
|
-
border-bottom: 1px solid #d8dae5;
|
|
381
|
-
}
|
|
382
|
-
.apiInfoForm .paramsTable :global(.requiredParam) :global(.headContainer)::after {
|
|
383
|
-
content: "*";
|
|
384
|
-
color: red;
|
|
385
|
-
transform: translateX(0.125rem);
|
|
386
|
-
}
|
|
387
|
-
.apiInfoForm .apiDocRow {
|
|
388
|
-
display: grid;
|
|
389
|
-
grid-template-columns: 1fr 1fr;
|
|
390
|
-
gap: 1.25rem;
|
|
391
|
-
}
|
|
392
|
-
.apiInfoForm .apiInfoForm_tagsChips {
|
|
393
|
-
margin-top: -1.25rem;
|
|
394
|
-
}
|
|
395
|
-
.apiInfoForm .editDescTooltipContent {
|
|
396
|
-
display: flex;
|
|
397
|
-
flex-direction: column;
|
|
398
|
-
gap: 0.625rem;
|
|
399
|
-
padding-bottom: 0.625rem;
|
|
485
|
+
.json-editor-container .json-editor textarea::-webkit-scrollbar-thumb {
|
|
486
|
+
background-color: #d8dae5;
|
|
487
|
+
border: none;
|
|
488
|
+
border-color: transparent;
|
|
489
|
+
border-radius: 0;
|
|
400
490
|
}
|
|
401
|
-
.
|
|
402
|
-
|
|
491
|
+
.json-editor-container .json-editor.invalid {
|
|
492
|
+
outline: 1px solid #ce2828 !important;
|
|
403
493
|
}
|
|
404
|
-
.
|
|
405
|
-
|
|
406
|
-
font-size: 0.
|
|
494
|
+
.json-editor-container .error-message {
|
|
495
|
+
color: #ce2828;
|
|
496
|
+
font-size: 0.75rem;
|
|
407
497
|
line-height: 1.25rem;
|
|
408
|
-
|
|
409
|
-
border-bottom: 1px solid #d8dae5;
|
|
410
|
-
}
|
|
411
|
-
.apiInfoForm :global(.requiredParam) :global(.headContainer)::after {
|
|
412
|
-
content: "*";
|
|
413
|
-
color: red;
|
|
414
|
-
transform: translateX(0.125rem);
|
|
415
|
-
}#common-dialog.dialog-content-wrapper {
|
|
416
|
-
overflow: visible !important;
|
|
417
|
-
max-height: 100%;
|
|
418
|
-
width: 22.1875rem;
|
|
419
|
-
}
|
|
420
|
-
#common-dialog.dialog-content-wrapper .dialog-content-root {
|
|
421
|
-
overflow: visible !important;
|
|
422
|
-
border-radius: 0.625rem;
|
|
423
|
-
max-height: 100%;
|
|
424
|
-
}
|
|
425
|
-
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content {
|
|
426
|
-
padding: 0 1.875rem !important;
|
|
427
|
-
overflow: visible !important;
|
|
428
|
-
max-height: 100%;
|
|
429
|
-
}
|
|
430
|
-
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog {
|
|
431
|
-
position: relative;
|
|
432
|
-
}
|
|
433
|
-
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .close-icon {
|
|
434
|
-
position: absolute;
|
|
435
|
-
z-index: 1;
|
|
436
|
-
top: 1.5rem;
|
|
437
|
-
right: 0;
|
|
438
|
-
transform: translate(0.625rem, -0.625rem);
|
|
439
|
-
cursor: pointer;
|
|
440
|
-
}
|
|
441
|
-
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header {
|
|
442
|
-
display: flex;
|
|
443
|
-
padding-top: 0.5rem;
|
|
444
|
-
position: relative;
|
|
445
|
-
}
|
|
446
|
-
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header .icon {
|
|
447
|
-
margin-top: 1rem;
|
|
448
|
-
margin-bottom: 1.5rem;
|
|
449
|
-
margin-inline: auto;
|
|
450
|
-
}
|
|
451
|
-
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header .icon.info path {
|
|
452
|
-
stroke: #12131a;
|
|
453
|
-
}
|
|
454
|
-
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header .icon.info line {
|
|
455
|
-
stroke: #12131a;
|
|
456
|
-
}
|
|
457
|
-
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header .icon.info line + path {
|
|
458
|
-
fill: #12131a;
|
|
459
|
-
}
|
|
460
|
-
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header .icon.warning path {
|
|
461
|
-
stroke: #faad14;
|
|
462
|
-
}
|
|
463
|
-
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header .icon.warning line {
|
|
464
|
-
stroke: #faad14;
|
|
465
|
-
}
|
|
466
|
-
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header .icon.error path {
|
|
467
|
-
stroke: #da3f3f;
|
|
468
|
-
}
|
|
469
|
-
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header .icon.error line {
|
|
470
|
-
stroke: #da3f3f;
|
|
471
|
-
}
|
|
472
|
-
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header .icon.error line + path {
|
|
473
|
-
fill: #da3f3f;
|
|
474
|
-
}
|
|
475
|
-
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-title {
|
|
476
|
-
font-size: 1.5rem;
|
|
477
|
-
font-weight: 500;
|
|
478
|
-
line-height: 1.875rem;
|
|
479
|
-
text-align: center;
|
|
480
|
-
margin-bottom: 0.625rem;
|
|
481
|
-
}
|
|
482
|
-
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-title.error-title {
|
|
483
|
-
color: #da3f3f;
|
|
484
|
-
}
|
|
485
|
-
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-title.warning-title {
|
|
486
|
-
color: #faad14;
|
|
498
|
+
margin-top: 0.625rem;
|
|
487
499
|
}
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
margin-top: 1.875rem;
|
|
500
|
+
.json-editor-container.disabled .json-editor textarea {
|
|
501
|
+
background-color: white;
|
|
502
|
+
color: #12131a;
|
|
492
503
|
}.livePreviewContainer .titleContainer {
|
|
493
504
|
display: flex;
|
|
494
505
|
justify-content: space-between;
|
|
@@ -590,111 +601,6 @@
|
|
|
590
601
|
--alert-natural: #c4d3f1;
|
|
591
602
|
}
|
|
592
603
|
|
|
593
|
-
.drawerItemContainer {
|
|
594
|
-
display: flex;
|
|
595
|
-
flex-direction: column;
|
|
596
|
-
}
|
|
597
|
-
.drawerItemContainer .title {
|
|
598
|
-
color: #000;
|
|
599
|
-
font-weight: 600;
|
|
600
|
-
font-size: 24px;
|
|
601
|
-
line-height: 35px;
|
|
602
|
-
margin-bottom: 3px;
|
|
603
|
-
margin-top: 1.5rem;
|
|
604
|
-
}
|
|
605
|
-
.drawerItemContainer .text {
|
|
606
|
-
color: #000;
|
|
607
|
-
font-weight: 400;
|
|
608
|
-
font-size: 24px;
|
|
609
|
-
line-height: 25px;
|
|
610
|
-
}
|
|
611
|
-
.drawerItemContainer .color-green {
|
|
612
|
-
color: var(--color-success);
|
|
613
|
-
}
|
|
614
|
-
.drawerItemContainer .color-red {
|
|
615
|
-
color: var(--color-error);
|
|
616
|
-
}:root {
|
|
617
|
-
--white: #fff;
|
|
618
|
-
--Gray-5: #f1f2f6;
|
|
619
|
-
--Gray-10: #ebecf2;
|
|
620
|
-
--Gray-20: #d8dae5;
|
|
621
|
-
--Gray-30: #babdcc;
|
|
622
|
-
--Gray-40: #9a9eb2;
|
|
623
|
-
--Gray-50: #828699;
|
|
624
|
-
--Gray-60: #696c80;
|
|
625
|
-
--Gray-100: #12131a;
|
|
626
|
-
--black: #000;
|
|
627
|
-
--primary-static: #4d75d8;
|
|
628
|
-
--primary-hover: #7c9bea;
|
|
629
|
-
--primary-active: #2c4fa4;
|
|
630
|
-
--primary-disabled: #9a9eb2;
|
|
631
|
-
--secondary-static: #40e0d0;
|
|
632
|
-
--secondary-hover: #9efcf2;
|
|
633
|
-
--secondary-active: #2fa599;
|
|
634
|
-
--error-static: #da3f3f;
|
|
635
|
-
--error-hover: #e75d5d;
|
|
636
|
-
--error-active: #bb3232;
|
|
637
|
-
--success-static: #3aaa35;
|
|
638
|
-
--success-hover: #5cda56;
|
|
639
|
-
--success-active: #2a8a25;
|
|
640
|
-
--info-static: #c6c6c6;
|
|
641
|
-
--info-hover: #e4e4e4;
|
|
642
|
-
--info-active: #979797;
|
|
643
|
-
--warning-static: #faad14;
|
|
644
|
-
--warning-hover: #f9be4a;
|
|
645
|
-
--warning-active: #db9711;
|
|
646
|
-
--action-static: #142452;
|
|
647
|
-
--action-hover: #21387d;
|
|
648
|
-
--action-active: #000000;
|
|
649
|
-
--color-info-primary: #3a6cd1;
|
|
650
|
-
--primary-font-color: #142452;
|
|
651
|
-
--placeholder-font-color: #babdcc;
|
|
652
|
-
--warning-font-color: #ce2828;
|
|
653
|
-
--alert-error: #da3f3f;
|
|
654
|
-
--alert-light-error: #f4c5c5;
|
|
655
|
-
--alert-success: #3aaa35;
|
|
656
|
-
--alert-light-success: #c4e5c2;
|
|
657
|
-
--alert-info: #8eaaf1;
|
|
658
|
-
--alert-light-info: #c4d3f1;
|
|
659
|
-
--alert-warning: #faad14;
|
|
660
|
-
--alert-light-warning: #fde6b8;
|
|
661
|
-
--border-focus: #3a6cd1;
|
|
662
|
-
--tooltip-background-color: #202f5b;
|
|
663
|
-
--text-color-primary: #142452;
|
|
664
|
-
--text-color-secondary: #ffff;
|
|
665
|
-
--text-color-neutral: #828699;
|
|
666
|
-
--text-color-tertiary: #808080;
|
|
667
|
-
--text-color-note: #242424;
|
|
668
|
-
--text-color-quaternary: #142452;
|
|
669
|
-
--text-color-disabled: #ffff;
|
|
670
|
-
--background-color-white-primary: #fff;
|
|
671
|
-
--background-color-light-primary: #8eaaf1;
|
|
672
|
-
--background-color-white-secondary: #fff;
|
|
673
|
-
--background-color-primary-dark: #142452;
|
|
674
|
-
--background-color-gray-5: #f1f2f6;
|
|
675
|
-
--background-color-gray-30: #ebecf2;
|
|
676
|
-
--background-color-tertiary-light: #2c4fa4;
|
|
677
|
-
--background-color-gray-10: #f1f2f6;
|
|
678
|
-
--background-color-gray-40: #ebecf2;
|
|
679
|
-
--background-color-light-blue: #dfe7f8;
|
|
680
|
-
--border-color-primary: #babdcc;
|
|
681
|
-
--border-color-secondary: #d8dae5;
|
|
682
|
-
--border-color-neutral: #ebecf2;
|
|
683
|
-
--border-color-tertiary: #ebecf2;
|
|
684
|
-
--border-color-gray: #ebecf2;
|
|
685
|
-
--border-color-hover: #142452;
|
|
686
|
-
--border-color-active: #3a6cd1;
|
|
687
|
-
--icon-color-main: #142452;
|
|
688
|
-
--icon-color-secondary: #000;
|
|
689
|
-
--icon-color-quaternary: #babdcc;
|
|
690
|
-
--icon-color-disabled: #9a9eb2;
|
|
691
|
-
--link-btn-primary-color: #3a6cd1;
|
|
692
|
-
--button-color-static: #4d75d8;
|
|
693
|
-
--button-color-hover: #7c9bea;
|
|
694
|
-
--button-color-active: #2c4fa4;
|
|
695
|
-
--alert-natural: #c4d3f1;
|
|
696
|
-
}
|
|
697
|
-
|
|
698
604
|
.tableSectionContainer .tableContainer {
|
|
699
605
|
max-width: 100%;
|
|
700
606
|
overflow-x: overlay;
|
|
@@ -848,15 +754,92 @@
|
|
|
848
754
|
.tableSectionContainer .descArrow path,
|
|
849
755
|
.tableSectionContainer .defaultSortArrow path {
|
|
850
756
|
fill: var(--Gray-50);
|
|
851
|
-
}.
|
|
852
|
-
|
|
757
|
+
}#common-dialog.dialog-content-wrapper {
|
|
758
|
+
overflow: visible !important;
|
|
759
|
+
max-height: 100%;
|
|
760
|
+
width: 22.1875rem;
|
|
853
761
|
}
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
762
|
+
#common-dialog.dialog-content-wrapper .dialog-content-root {
|
|
763
|
+
overflow: visible !important;
|
|
764
|
+
border-radius: 0.625rem;
|
|
765
|
+
max-height: 100%;
|
|
857
766
|
}
|
|
858
|
-
|
|
859
|
-
.
|
|
767
|
+
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content {
|
|
768
|
+
padding: 0 1.875rem !important;
|
|
769
|
+
overflow: visible !important;
|
|
770
|
+
max-height: 100%;
|
|
771
|
+
}
|
|
772
|
+
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog {
|
|
773
|
+
position: relative;
|
|
774
|
+
}
|
|
775
|
+
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .close-icon {
|
|
776
|
+
position: absolute;
|
|
777
|
+
z-index: 1;
|
|
778
|
+
top: 1.5rem;
|
|
779
|
+
right: 0;
|
|
780
|
+
transform: translate(0.625rem, -0.625rem);
|
|
781
|
+
cursor: pointer;
|
|
782
|
+
}
|
|
783
|
+
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header {
|
|
784
|
+
display: flex;
|
|
785
|
+
padding-top: 0.5rem;
|
|
786
|
+
position: relative;
|
|
787
|
+
}
|
|
788
|
+
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header .icon {
|
|
789
|
+
margin-top: 1rem;
|
|
790
|
+
margin-bottom: 1.5rem;
|
|
791
|
+
margin-inline: auto;
|
|
792
|
+
}
|
|
793
|
+
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header .icon.info path {
|
|
794
|
+
stroke: #12131a;
|
|
795
|
+
}
|
|
796
|
+
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header .icon.info line {
|
|
797
|
+
stroke: #12131a;
|
|
798
|
+
}
|
|
799
|
+
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header .icon.info line + path {
|
|
800
|
+
fill: #12131a;
|
|
801
|
+
}
|
|
802
|
+
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header .icon.warning path {
|
|
803
|
+
stroke: #faad14;
|
|
804
|
+
}
|
|
805
|
+
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header .icon.warning line {
|
|
806
|
+
stroke: #faad14;
|
|
807
|
+
}
|
|
808
|
+
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header .icon.error path {
|
|
809
|
+
stroke: #da3f3f;
|
|
810
|
+
}
|
|
811
|
+
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header .icon.error line {
|
|
812
|
+
stroke: #da3f3f;
|
|
813
|
+
}
|
|
814
|
+
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-header .icon.error line + path {
|
|
815
|
+
fill: #da3f3f;
|
|
816
|
+
}
|
|
817
|
+
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-title {
|
|
818
|
+
font-size: 1.5rem;
|
|
819
|
+
font-weight: 500;
|
|
820
|
+
line-height: 1.875rem;
|
|
821
|
+
text-align: center;
|
|
822
|
+
margin-bottom: 0.625rem;
|
|
823
|
+
}
|
|
824
|
+
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-title.error-title {
|
|
825
|
+
color: #da3f3f;
|
|
826
|
+
}
|
|
827
|
+
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-title.warning-title {
|
|
828
|
+
color: #faad14;
|
|
829
|
+
}
|
|
830
|
+
#common-dialog.dialog-content-wrapper .dialog-content-root .dialog-content .common-dialog .confirmation-dialog-footer {
|
|
831
|
+
display: flex;
|
|
832
|
+
gap: 1.25rem;
|
|
833
|
+
margin-top: 1.875rem;
|
|
834
|
+
}.tooltip-custom-wrapper {
|
|
835
|
+
display: flex;
|
|
836
|
+
}
|
|
837
|
+
|
|
838
|
+
[data-tippy-root] {
|
|
839
|
+
z-index: 2 !important;
|
|
840
|
+
}
|
|
841
|
+
|
|
842
|
+
.tippy-box {
|
|
860
843
|
background-color: #202f5b;
|
|
861
844
|
font-size: 0.875rem;
|
|
862
845
|
border-radius: 0.3125rem;
|
|
@@ -943,115 +926,132 @@
|
|
|
943
926
|
z-index: 2;
|
|
944
927
|
top: -0.45rem;
|
|
945
928
|
transform-origin: center !important;
|
|
946
|
-
}
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
929
|
+
}:root {
|
|
930
|
+
--white: #fff;
|
|
931
|
+
--Gray-5: #f1f2f6;
|
|
932
|
+
--Gray-10: #ebecf2;
|
|
933
|
+
--Gray-20: #d8dae5;
|
|
934
|
+
--Gray-30: #babdcc;
|
|
935
|
+
--Gray-40: #9a9eb2;
|
|
936
|
+
--Gray-50: #828699;
|
|
937
|
+
--Gray-60: #696c80;
|
|
938
|
+
--Gray-100: #12131a;
|
|
939
|
+
--black: #000;
|
|
940
|
+
--primary-static: #4d75d8;
|
|
941
|
+
--primary-hover: #7c9bea;
|
|
942
|
+
--primary-active: #2c4fa4;
|
|
943
|
+
--primary-disabled: #9a9eb2;
|
|
944
|
+
--secondary-static: #40e0d0;
|
|
945
|
+
--secondary-hover: #9efcf2;
|
|
946
|
+
--secondary-active: #2fa599;
|
|
947
|
+
--error-static: #da3f3f;
|
|
948
|
+
--error-hover: #e75d5d;
|
|
949
|
+
--error-active: #bb3232;
|
|
950
|
+
--success-static: #3aaa35;
|
|
951
|
+
--success-hover: #5cda56;
|
|
952
|
+
--success-active: #2a8a25;
|
|
953
|
+
--info-static: #c6c6c6;
|
|
954
|
+
--info-hover: #e4e4e4;
|
|
955
|
+
--info-active: #979797;
|
|
956
|
+
--warning-static: #faad14;
|
|
957
|
+
--warning-hover: #f9be4a;
|
|
958
|
+
--warning-active: #db9711;
|
|
959
|
+
--action-static: #142452;
|
|
960
|
+
--action-hover: #21387d;
|
|
961
|
+
--action-active: #000000;
|
|
962
|
+
--color-info-primary: #3a6cd1;
|
|
963
|
+
--primary-font-color: #142452;
|
|
964
|
+
--placeholder-font-color: #babdcc;
|
|
965
|
+
--warning-font-color: #ce2828;
|
|
966
|
+
--alert-error: #da3f3f;
|
|
967
|
+
--alert-light-error: #f4c5c5;
|
|
968
|
+
--alert-success: #3aaa35;
|
|
969
|
+
--alert-light-success: #c4e5c2;
|
|
970
|
+
--alert-info: #8eaaf1;
|
|
971
|
+
--alert-light-info: #c4d3f1;
|
|
972
|
+
--alert-warning: #faad14;
|
|
973
|
+
--alert-light-warning: #fde6b8;
|
|
974
|
+
--border-focus: #3a6cd1;
|
|
975
|
+
--tooltip-background-color: #202f5b;
|
|
976
|
+
--text-color-primary: #142452;
|
|
977
|
+
--text-color-secondary: #ffff;
|
|
978
|
+
--text-color-neutral: #828699;
|
|
979
|
+
--text-color-tertiary: #808080;
|
|
980
|
+
--text-color-note: #242424;
|
|
981
|
+
--text-color-quaternary: #142452;
|
|
982
|
+
--text-color-disabled: #ffff;
|
|
983
|
+
--background-color-white-primary: #fff;
|
|
984
|
+
--background-color-light-primary: #8eaaf1;
|
|
985
|
+
--background-color-white-secondary: #fff;
|
|
986
|
+
--background-color-primary-dark: #142452;
|
|
987
|
+
--background-color-gray-5: #f1f2f6;
|
|
988
|
+
--background-color-gray-30: #ebecf2;
|
|
989
|
+
--background-color-tertiary-light: #2c4fa4;
|
|
990
|
+
--background-color-gray-10: #f1f2f6;
|
|
991
|
+
--background-color-gray-40: #ebecf2;
|
|
992
|
+
--background-color-light-blue: #dfe7f8;
|
|
993
|
+
--border-color-primary: #babdcc;
|
|
994
|
+
--border-color-secondary: #d8dae5;
|
|
995
|
+
--border-color-neutral: #ebecf2;
|
|
996
|
+
--border-color-tertiary: #ebecf2;
|
|
997
|
+
--border-color-gray: #ebecf2;
|
|
998
|
+
--border-color-hover: #142452;
|
|
999
|
+
--border-color-active: #3a6cd1;
|
|
1000
|
+
--icon-color-main: #142452;
|
|
1001
|
+
--icon-color-secondary: #000;
|
|
1002
|
+
--icon-color-quaternary: #babdcc;
|
|
1003
|
+
--icon-color-disabled: #9a9eb2;
|
|
1004
|
+
--link-btn-primary-color: #3a6cd1;
|
|
1005
|
+
--button-color-static: #4d75d8;
|
|
1006
|
+
--button-color-hover: #7c9bea;
|
|
1007
|
+
--button-color-active: #2c4fa4;
|
|
1008
|
+
--alert-natural: #c4d3f1;
|
|
956
1009
|
}
|
|
957
|
-
|
|
1010
|
+
|
|
1011
|
+
.drawerItemContainer {
|
|
958
1012
|
display: flex;
|
|
959
1013
|
flex-direction: column;
|
|
960
|
-
background-color: #142452;
|
|
961
|
-
width: 100%;
|
|
962
|
-
outline: 1px solid transparent;
|
|
963
|
-
position: relative;
|
|
964
|
-
overflow: hidden;
|
|
965
1014
|
}
|
|
966
|
-
.
|
|
967
|
-
|
|
968
|
-
height: 5rem;
|
|
969
|
-
padding: 1.25rem;
|
|
970
|
-
border-radius: 0 0 0.3125rem 0.3125rem;
|
|
971
|
-
background: #101e47;
|
|
972
|
-
display: flex;
|
|
973
|
-
flex-direction: row;
|
|
974
|
-
gap: 1.25rem;
|
|
975
|
-
align-items: center;
|
|
976
|
-
}
|
|
977
|
-
.json-editor-container .json-editor .actions-container .validate {
|
|
978
|
-
color: #fff;
|
|
979
|
-
text-align: center;
|
|
980
|
-
font-size: 1rem;
|
|
981
|
-
font-style: normal;
|
|
982
|
-
font-weight: 600;
|
|
983
|
-
line-height: 1.25rem;
|
|
984
|
-
width: 8.75rem;
|
|
985
|
-
padding: 0.625rem 2.25rem;
|
|
986
|
-
background-color: rgba(240, 248, 255, 0);
|
|
987
|
-
border-radius: 0.3125rem;
|
|
988
|
-
border: 0.0625rem solid #4d75d8;
|
|
989
|
-
cursor: pointer;
|
|
990
|
-
}
|
|
991
|
-
.json-editor-container .json-editor .actions-container .validate:disabled {
|
|
992
|
-
color: #babdcc;
|
|
993
|
-
border-color: #a2a5b6;
|
|
994
|
-
}
|
|
995
|
-
.json-editor-container .json-editor .actions-container .beautify {
|
|
996
|
-
color: #fff;
|
|
997
|
-
text-align: center;
|
|
998
|
-
font-size: 1rem;
|
|
999
|
-
font-style: normal;
|
|
1015
|
+
.drawerItemContainer .title {
|
|
1016
|
+
color: #000;
|
|
1000
1017
|
font-weight: 600;
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
border-radius: 0.3125rem;
|
|
1006
|
-
border: 1px solid #babdcc;
|
|
1007
|
-
cursor: pointer;
|
|
1008
|
-
}
|
|
1009
|
-
.json-editor-container .json-editor .actions-container .beautify:disabled {
|
|
1010
|
-
color: #a2a5b6;
|
|
1011
|
-
border-color: #a2a5b6;
|
|
1018
|
+
font-size: 24px;
|
|
1019
|
+
line-height: 35px;
|
|
1020
|
+
margin-bottom: 3px;
|
|
1021
|
+
margin-top: 1.5rem;
|
|
1012
1022
|
}
|
|
1013
|
-
.
|
|
1014
|
-
|
|
1015
|
-
padding: 1.25rem;
|
|
1016
|
-
font-size: 0.875rem;
|
|
1017
|
-
font-style: normal;
|
|
1023
|
+
.drawerItemContainer .text {
|
|
1024
|
+
color: #000;
|
|
1018
1025
|
font-weight: 400;
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
height: 25rem;
|
|
1022
|
-
background-color: #142452;
|
|
1023
|
-
border: none;
|
|
1024
|
-
resize: none;
|
|
1025
|
-
}
|
|
1026
|
-
.json-editor-container .json-editor textarea:focus, .json-editor-container .json-editor textarea:focus-within, .json-editor-container .json-editor textarea:focus-visible .json-editor-container .json-editor textarea:active {
|
|
1027
|
-
outline: none;
|
|
1028
|
-
border: none;
|
|
1029
|
-
}
|
|
1030
|
-
.json-editor-container .json-editor textarea::-webkit-scrollbar {
|
|
1031
|
-
width: 0.5rem;
|
|
1026
|
+
font-size: 24px;
|
|
1027
|
+
line-height: 25px;
|
|
1032
1028
|
}
|
|
1033
|
-
.
|
|
1034
|
-
|
|
1035
|
-
border: none;
|
|
1036
|
-
border-color: transparent;
|
|
1037
|
-
border-top-left-radius: 0;
|
|
1029
|
+
.drawerItemContainer .color-green {
|
|
1030
|
+
color: var(--color-success);
|
|
1038
1031
|
}
|
|
1039
|
-
.
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1032
|
+
.drawerItemContainer .color-red {
|
|
1033
|
+
color: var(--color-error);
|
|
1034
|
+
}.containerTitleDrawer {
|
|
1035
|
+
height: 64px;
|
|
1036
|
+
min-height: 64px;
|
|
1037
|
+
display: flex;
|
|
1038
|
+
flex-direction: row;
|
|
1039
|
+
justify-content: space-between;
|
|
1040
|
+
align-items: center;
|
|
1041
|
+
background-color: #f1f2f6;
|
|
1042
|
+
padding: 0 30px 0 30px;
|
|
1043
|
+
width: 100%;
|
|
1044
1044
|
}
|
|
1045
|
-
.
|
|
1046
|
-
|
|
1045
|
+
.containerTitleDrawer span {
|
|
1046
|
+
color: #12131a;
|
|
1047
|
+
font-weight: 600;
|
|
1048
|
+
font-size: 18px;
|
|
1049
|
+
line-height: 25px;
|
|
1050
|
+
letter-spacing: 0em;
|
|
1047
1051
|
}
|
|
1048
|
-
.
|
|
1049
|
-
|
|
1050
|
-
font-size: 0.75rem;
|
|
1051
|
-
line-height: 1.25rem;
|
|
1052
|
-
margin-top: 0.625rem;
|
|
1052
|
+
.containerTitleDrawer svg path {
|
|
1053
|
+
stroke: #000 !important;
|
|
1053
1054
|
}
|
|
1054
|
-
.
|
|
1055
|
-
|
|
1056
|
-
color: #12131a;
|
|
1055
|
+
.containerTitleDrawer .closeIcon {
|
|
1056
|
+
cursor: pointer;
|
|
1057
1057
|
}
|
package/package.json
CHANGED
|
@@ -69,9 +69,12 @@ const LivePreview: React.FC<LivePreviewProps> = ({ transformedData }) => {
|
|
|
69
69
|
rel="noopener noreferrer"
|
|
70
70
|
target="_blank"
|
|
71
71
|
>
|
|
72
|
+
{item?.externalDocs?.url && !item?.externalDocs?.description
|
|
73
|
+
? item?.externalDocs?.url
|
|
74
|
+
: null}
|
|
72
75
|
{item?.externalDocs?.description
|
|
73
76
|
? item?.externalDocs?.description?.substring(0, 12)
|
|
74
|
-
: '-'}
|
|
77
|
+
: !item?.externalDocs?.url ? '-': null}
|
|
75
78
|
{item?.externalDocs?.description && item?.externalDocs?.description?.length > 12
|
|
76
79
|
? '...'
|
|
77
80
|
: ''}
|
|
@@ -104,6 +107,10 @@ const LivePreview: React.FC<LivePreviewProps> = ({ transformedData }) => {
|
|
|
104
107
|
}))
|
|
105
108
|
}
|
|
106
109
|
|
|
110
|
+
const securityScheme = !!securityKey
|
|
111
|
+
? securitySchemes[securityKey].scheme || securitySchemes[securityKey].type
|
|
112
|
+
: '-'
|
|
113
|
+
|
|
107
114
|
return (
|
|
108
115
|
<div className={styles.livePreviewContainer}>
|
|
109
116
|
<div className="row">
|
|
@@ -116,9 +123,9 @@ const LivePreview: React.FC<LivePreviewProps> = ({ transformedData }) => {
|
|
|
116
123
|
key={'APIAuthenticationType'}
|
|
117
124
|
label={'API authentication type: '}
|
|
118
125
|
value={
|
|
119
|
-
!!
|
|
120
|
-
?
|
|
121
|
-
:
|
|
126
|
+
!!securityScheme && securityScheme.toLowerCase() === 'public'
|
|
127
|
+
? 'Keyless'
|
|
128
|
+
: securityScheme
|
|
122
129
|
}
|
|
123
130
|
/>
|
|
124
131
|
<SimpleLabelValue key={'version'} label={'Version: '} value={info?.version || '-'} />
|