@asyncapi/react-component 1.0.0-next.50 → 1.0.0-next.51
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/browser/index.js +6 -30
- package/browser/index.js.LICENSE.txt +1 -1
- package/browser/standalone/index.js +6 -30
- package/browser/standalone/index.js.LICENSE.txt +1 -1
- package/browser/standalone/without-parser.js +3 -9
- package/browser/standalone/without-parser.js.LICENSE.txt +1 -1
- package/browser/without-parser.js +3 -9
- package/browser/without-parser.js.LICENSE.txt +1 -1
- package/lib/cjs/components/Bindings.js +7 -6
- package/lib/cjs/components/Bindings.js.map +1 -1
- package/lib/cjs/components/Schema.js +2 -2
- package/lib/cjs/components/Schema.js.map +1 -1
- package/lib/cjs/components/Tags.js +1 -1
- package/lib/cjs/components/Tags.js.map +1 -1
- package/lib/cjs/containers/AsyncApi/AsyncApi.js +21 -11
- package/lib/cjs/containers/AsyncApi/AsyncApi.js.map +1 -1
- package/lib/cjs/containers/AsyncApi/Standalone.js +1 -1
- package/lib/cjs/containers/Messages/Messages.js +5 -1
- package/lib/cjs/containers/Messages/Messages.js.map +1 -1
- package/lib/cjs/containers/Operations/Operation.js +26 -12
- package/lib/cjs/containers/Operations/Operation.js.map +1 -1
- package/lib/cjs/containers/Operations/Operations.js +11 -7
- package/lib/cjs/containers/Operations/Operations.js.map +1 -1
- package/lib/cjs/containers/Schemas/Schemas.js +5 -1
- package/lib/cjs/containers/Schemas/Schemas.js.map +1 -1
- package/lib/cjs/containers/Servers/Servers.js +5 -3
- package/lib/cjs/containers/Servers/Servers.js.map +1 -1
- package/lib/cjs/helpers/parser.js +1 -1
- package/lib/cjs/helpers/parser.js.map +1 -1
- package/lib/cjs/helpers/schema.js +36 -21
- package/lib/cjs/helpers/schema.js.map +1 -1
- package/lib/esm/components/Bindings.js +7 -6
- package/lib/esm/components/Bindings.js.map +1 -1
- package/lib/esm/components/Schema.js +2 -2
- package/lib/esm/components/Schema.js.map +1 -1
- package/lib/esm/components/Tags.js +1 -1
- package/lib/esm/components/Tags.js.map +1 -1
- package/lib/esm/containers/AsyncApi/AsyncApi.js +21 -11
- package/lib/esm/containers/AsyncApi/AsyncApi.js.map +1 -1
- package/lib/esm/containers/AsyncApi/Standalone.js +1 -1
- package/lib/esm/containers/Messages/Messages.js +5 -1
- package/lib/esm/containers/Messages/Messages.js.map +1 -1
- package/lib/esm/containers/Operations/Operation.js +26 -12
- package/lib/esm/containers/Operations/Operation.js.map +1 -1
- package/lib/esm/containers/Operations/Operations.js +11 -7
- package/lib/esm/containers/Operations/Operations.js.map +1 -1
- package/lib/esm/containers/Schemas/Schemas.js +5 -1
- package/lib/esm/containers/Schemas/Schemas.js.map +1 -1
- package/lib/esm/containers/Servers/Servers.js +5 -3
- package/lib/esm/containers/Servers/Servers.js.map +1 -1
- package/lib/esm/helpers/parser.js +1 -1
- package/lib/esm/helpers/parser.js.map +1 -1
- package/lib/esm/helpers/schema.js +36 -21
- package/lib/esm/helpers/schema.js.map +1 -1
- package/lib/types/components/Bindings.d.ts +2 -1
- package/lib/types/components/Bindings.d.ts.map +1 -1
- package/lib/types/components/Tags.d.ts +2 -2
- package/lib/types/components/Tags.d.ts.map +1 -1
- package/lib/types/containers/AsyncApi/AsyncApi.d.ts +2 -2
- package/lib/types/containers/AsyncApi/AsyncApi.d.ts.map +1 -1
- package/lib/types/containers/AsyncApi/Standalone.d.ts +2 -2
- package/lib/types/containers/AsyncApi/Standalone.d.ts.map +1 -1
- package/lib/types/containers/Messages/Messages.d.ts.map +1 -1
- package/lib/types/containers/Operations/Operation.d.ts.map +1 -1
- package/lib/types/containers/Operations/Operations.d.ts.map +1 -1
- package/lib/types/containers/Schemas/Schemas.d.ts.map +1 -1
- package/lib/types/containers/Servers/Servers.d.ts.map +1 -1
- package/lib/types/helpers/parser.d.ts.map +1 -1
- package/lib/types/helpers/schema.d.ts.map +1 -1
- package/lib/types/types.d.ts +2 -2
- package/lib/types/types.d.ts.map +1 -1
- package/package.json +3 -3
- package/styles/default.css +60 -42
- package/styles/default.min.css +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../src/helpers/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAIL,QAAQ,IAAI,WAAW,GAGxB,MAAM,kBAAkB,CAAC;AAE1B,MAAM,CAAN,IAAY,iBASX;AATD,WAAY,iBAAiB;IAE3B,gCAAW,CAAA;IAEX,sDAAiC,CAAA;IAEjC,oCAAe,CAAA;IAEf,wCAAmB,CAAA;AACrB,CAAC,EATW,iBAAiB,KAAjB,iBAAiB,QAS5B;AAED,IAAM,eAAe,GAAG;IACtB,QAAQ;IACR,QAAQ;IACR,SAAS;IACT,SAAS;IACT,OAAO;IACP,QAAQ;IACR,MAAM;CACP,CAAC;AACF,IAAM,sBAAsB,GAA2B;IAErD,SAAS,EAAE,QAAQ;IACnB,SAAS,EAAE,QAAQ;IACnB,OAAO,EAAE,QAAQ;IACjB,gBAAgB,EAAE,QAAQ;IAC1B,eAAe,EAAE,QAAQ;IAEzB,UAAU,EAAE,QAAQ;IACpB,OAAO,EAAE,QAAQ;IACjB,gBAAgB,EAAE,QAAQ;IAC1B,OAAO,EAAE,QAAQ;IACjB,gBAAgB,EAAE,QAAQ;IAE1B,KAAK,EAAE,OAAO;IACd,QAAQ,EAAE,OAAO;IACjB,QAAQ,EAAE,OAAO;IACjB,WAAW,EAAE,OAAO;IACpB,QAAQ,EAAE,OAAO;IACjB,eAAe,EAAE,OAAO;IAExB,aAAa,EAAE,QAAQ;IACvB,aAAa,EAAE,QAAQ;IACvB,QAAQ,EAAE,QAAQ;IAClB,UAAU,EAAE,QAAQ;IACpB,iBAAiB,EAAE,QAAQ;IAC3B,aAAa,EAAE,QAAQ;IACvB,YAAY,EAAE,QAAQ;IACtB,oBAAoB,EAAE,QAAQ;CAC/B,CAAC;AACF,IAAM,kBAAkB,GAAG,MAAM,CAAC,IAAI,CAAC,sBAAsB,CAAC,CAAC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AC,EAAE,EAAE,CAAC;;YACN,GAAC,IAAI,CAAC,uBAAuB,IAAG,KAAK;eACrC;IACJ,CAAC;IAEc,0BAAY,GAA3B,UAA4B,KAAU;QACpC,IACE,KAAK;YACL,OAAO,KAAK,KAAK,QAAQ;YACzB,CAAC,eAAe,CAAC,QAAQ,CAAC,KAAK,CAAC,IAAI,CAAC;gBACnC,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,CAAC;oBACxB,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,UAAC,CAAS,IAAK,OAAA,CAAC,eAAe,CAAC,QAAQ,CAAC,CAAC,CAAC,EAA5B,CAA4B,CAAC,CAAC,CAAC,EAClE;YACA,OAAO,IAAI,CAAC;SACb;QACD,OAAO,KAAK,CAAC;IACf,CAAC;IA9dM,qCAAuB,GAAG,yCAAyC,CAAC;IACpE,yBAAW,GAAG,4BAA4B,CAAC;IAC3C,kCAAoB,GAAG,qCAAqC,CAAC;IA6dtE,oBAAC;CAAA,AAheD,IAgeC;SAheY,aAAa","sourcesContent":["import {\n SchemaInterface,\n ChannelParametersInterface,\n ServerVariablesInterface,\n SchemaV2 as SchemaClass,\n ExtensionInterface,\n ExtensionsInterface,\n} from '@asyncapi/parser';\n\nexport enum SchemaCustomTypes {\n // for `true` and `{}` schemas\n ANY = 'any',\n // for schemas without `type` keyword\n RESTRICTED_ANY = 'restricted any',\n // for `false` and `{ not: {}, ... }` schemas\n NEVER = 'never',\n // for types that we cannot infer\n UNKNOWN = 'unknown',\n}\n\nconst jsonSchemaTypes = [\n 'string',\n 'number',\n 'integer',\n 'boolean',\n 'array',\n 'object',\n 'null',\n];\nconst jsonSchemaKeywordTypes: Record<string, string> = {\n // string\n maxLength: 'string',\n minLength: 'string',\n pattern: 'string',\n contentMediaType: 'string',\n contentEncoding: 'string',\n // number\n multipleOf: 'number',\n maximum: 'number',\n exclusiveMaximum: 'number',\n minimum: 'number',\n exclusiveMinimum: 'number',\n // array\n items: 'array',\n maxItems: 'array',\n minItems: 'array',\n uniqueItems: 'array',\n contains: 'array',\n additionalItems: 'array',\n // object\n maxProperties: 'object',\n minProperties: 'object',\n required: 'object',\n properties: 'object',\n patternProperties: 'object',\n propertyNames: 'object',\n dependencies: 'object',\n additionalProperties: 'object',\n};\nconst jsonSchemaKeywords = Object.keys(jsonSchemaKeywordTypes);\n\nexport class SchemaHelpers {\n static extRenderAdditionalInfo = 'x-schema-private-render-additional-info';\n static extRawValue = 'x-schema-private-raw-value';\n static extParameterLocation = 'x-schema-private-parameter-location';\n\n static toSchemaType(schema: SchemaInterface): string {\n if (!schema || typeof schema.json !== 'function') {\n return SchemaCustomTypes.UNKNOWN;\n }\n if (schema.isBooleanSchema()) {\n if (schema.json() === true) {\n return SchemaCustomTypes.ANY;\n } else {\n return SchemaCustomTypes.NEVER;\n }\n }\n // handle case with `{}` schemas\n if (Object.keys(schema.json()).length === 0) {\n return SchemaCustomTypes.ANY;\n }\n // handle case with `{ not: {}, ... }` schemas\n const not = schema.not();\n if (not && this.inferType(not) === SchemaCustomTypes.ANY) {\n return SchemaCustomTypes.NEVER;\n }\n\n let type = this.inferType(schema);\n if (Array.isArray(type)) {\n return type.map(t => this.toType(t, schema)).join(' | ');\n }\n type = this.toType(type, schema);\n const combinedType = this.toCombinedType(schema);\n\n if (type && combinedType) {\n return `${type} ${combinedType}`;\n }\n if (combinedType) {\n return combinedType;\n }\n return type;\n }\n\n static prettifyValue(value: any, strict = true): string {\n const typeOf = typeof value;\n if (typeOf === 'string') {\n return strict ? `\"${value}\"` : value;\n }\n if (typeOf === 'number' || typeOf === 'bigint' || typeOf === 'boolean') {\n return `${value}`;\n }\n if (Array.isArray(value)) {\n return `[${value.toString()}]`;\n }\n return JSON.stringify(value);\n }\n\n static humanizeConstraints(schema: SchemaInterface): string[] {\n const constraints: string[] = [];\n\n // related to number/integer\n const numberRange = this.humanizeNumberRangeConstraint(\n schema.minimum(),\n schema.exclusiveMinimum(),\n schema.maximum(),\n schema.exclusiveMaximum(),\n );\n if (numberRange !== undefined) {\n constraints.push(numberRange);\n }\n const multipleOfConstraint = this.humanizeMultipleOfConstraint(\n schema.multipleOf(),\n );\n if (multipleOfConstraint !== undefined) {\n constraints.push(multipleOfConstraint);\n }\n\n // related to string\n const stringRange = this.humanizeRangeConstraint(\n 'characters',\n schema.minLength(),\n schema.maxLength(),\n );\n if (stringRange !== undefined) {\n constraints.push(stringRange);\n }\n\n // related to array\n const hasUniqueItems = schema.uniqueItems();\n const arrayRange = this.humanizeRangeConstraint(\n hasUniqueItems ? 'unique items' : 'items',\n schema.minItems(),\n schema.maxItems(),\n );\n if (arrayRange !== undefined) {\n constraints.push(arrayRange);\n }\n\n // related to object\n const objectRange = this.humanizeRangeConstraint(\n 'properties',\n schema.minProperties(),\n schema.maxProperties(),\n );\n if (objectRange !== undefined) {\n constraints.push(objectRange);\n }\n\n return constraints;\n }\n\n static isExpandable(schema: SchemaInterface): boolean {\n let type = this.inferType(schema);\n type = Array.isArray(type) ? type : [type];\n if (type.includes('object') || type.includes('array')) {\n return true;\n }\n\n if (\n schema.oneOf() ||\n schema.anyOf() ||\n schema.allOf() ||\n Object.keys(schema.properties() || {}).length > 0 ||\n schema.items() ||\n schema.not() ||\n schema.if() ||\n schema.then() ||\n schema.else()\n ) {\n return true;\n }\n\n const customExtensions = this.getCustomExtensions(schema);\n if (customExtensions && Object.keys(customExtensions).length) {\n return true;\n }\n\n return false;\n }\n\n static serverVariablesToSchema(\n urlVariables?: ServerVariablesInterface,\n ): SchemaInterface | undefined {\n if (!urlVariables || !Object.keys(urlVariables).length) {\n return undefined;\n }\n\n const json = {\n type: 'object',\n properties: Object.entries(urlVariables).reduce(\n (obj, [variableName, variable]) => {\n obj[variableName] = Object.assign({}, variable.json() || {});\n obj[variableName].type = 'string';\n return obj;\n },\n {},\n ),\n required: Object.keys(urlVariables),\n [this.extRenderAdditionalInfo]: false,\n };\n return new SchemaClass(json as any);\n }\n\n static parametersToSchema(\n parameters?: ChannelParametersInterface,\n ): SchemaInterface | undefined {\n if (!parameters || !Object.keys(parameters).length) {\n return undefined;\n }\n\n const json = {\n type: 'object',\n properties: Object.entries(parameters).reduce(\n (obj, [paramaterName, parameter]) => {\n const parameterSchema = parameter.schema();\n obj[paramaterName] = Object.assign(\n {},\n parameterSchema ? parameterSchema.json() : {},\n );\n obj[paramaterName].description =\n parameter.description() || obj[paramaterName].description;\n obj[paramaterName][this.extParameterLocation] = parameter.location();\n return obj;\n },\n {},\n ),\n required: Object.keys(parameters),\n [this.extRenderAdditionalInfo]: false,\n };\n return new SchemaClass(json as any);\n }\n\n static jsonToSchema(value: any): any {\n const json = this.jsonFieldToSchema(value);\n return new SchemaClass(json);\n }\n\n /**\n * Retrieves from given value all custom extensions (value with key started by `x-`).\n * However, it skips those private extensions that begin with `x-parser-` and `x-schema-private-`.\n *\n * @param value\n */\n static getCustomExtensions(value: any) {\n if (!value || typeof value.extensions !== 'function') {\n return;\n }\n const extensions = value.extensions() as ExtensionsInterface;\n const filteredExtensions = {};\n for (const ext of Object.values(extensions.all())) {\n const extType = ext as ExtensionInterface;\n if (\n !extType.id().startsWith('x-parser-') &&\n !extType.id().startsWith('x-schema-private-')\n ) {\n filteredExtensions[extType.id()] = extType.value();\n }\n }\n return filteredExtensions;\n }\n\n /**\n * Retrieves from given schema all dependent required requires by given propertyName from `dependencies` object.\n *\n * @param propertyName\n * @param schema\n */\n static getDependentRequired(\n propertyName: string,\n schema: SchemaInterface,\n ): string[] | undefined {\n const dependentRequired: string[] = [];\n const dependencies = schema.dependencies();\n if (!dependencies) {\n return;\n }\n\n for (const [prop, array] of Object.entries(dependencies)) {\n if (Array.isArray(array) && array.includes(propertyName)) {\n dependentRequired.push(prop);\n }\n }\n return dependentRequired.length ? dependentRequired : undefined;\n }\n\n /**\n * Retrieves from given schema all dependent schemas from `dependencies` object.\n *\n * @param schema\n */\n static getDependentSchemas(\n schema: SchemaInterface,\n ): SchemaInterface | undefined {\n const dependencies = schema.dependencies();\n if (!dependencies) {\n return;\n }\n\n const records: Record<string, SchemaInterface> = {};\n for (const [prop, propSchema] of Object.entries(dependencies)) {\n if (typeof propSchema === 'object' && !Array.isArray(propSchema)) {\n records[prop] = propSchema;\n }\n }\n if (!Object.keys(records).length) {\n return undefined;\n }\n\n const json = {\n type: 'object',\n properties: Object.entries(records).reduce(\n (obj, [propertyName, propertySchema]) => {\n obj[propertyName] = Object.assign({}, propertySchema.json());\n return obj;\n },\n {},\n ),\n [this.extRenderAdditionalInfo]: false,\n };\n return new SchemaClass(json as any);\n }\n\n private static toType(type: string, schema: SchemaInterface): string {\n if (schema.isCircular()) {\n return type;\n }\n if (type === 'array') {\n const items = schema.items();\n if (Array.isArray(items)) {\n return this.toItemsType(items, schema);\n }\n if (!items) {\n return `array<${SchemaCustomTypes.ANY}>`;\n }\n return `array<${this.toSchemaType(items) || SchemaCustomTypes.UNKNOWN}>`;\n }\n return type;\n }\n\n private static toItemsType(\n items: SchemaInterface[],\n schema: SchemaInterface,\n ): string {\n const types = items.map(item => this.toSchemaType(item)).join(', ');\n const additionalItems = schema.additionalItems();\n if (additionalItems !== undefined && additionalItems !== false) {\n const additionalType =\n additionalItems === true\n ? SchemaCustomTypes.ANY\n : this.toSchemaType(additionalItems);\n return `tuple<${types ||\n SchemaCustomTypes.UNKNOWN}, ...optional<${additionalType}>>`;\n }\n return `tuple<${types || SchemaCustomTypes.UNKNOWN}>`;\n }\n\n private static toCombinedType(schema: SchemaInterface): string | undefined {\n const oneOf = schema.oneOf();\n if (oneOf) {\n return 'oneOf';\n }\n if (schema.anyOf()) {\n return 'anyOf';\n }\n if (schema.allOf()) {\n return 'allOf';\n }\n return;\n }\n\n private static inferType(schema: SchemaInterface): string[] | string {\n let types = schema.type();\n\n if (types !== undefined) {\n if (Array.isArray(types)) {\n // if types have `integer` and `number` types, `integer` is unnecessary\n if (types.includes('integer') && types.includes('number')) {\n types = types.filter(t => t !== 'integer');\n }\n return types.length === 1 ? types[0] : types;\n }\n return types;\n }\n\n const constValue = schema.const();\n if (constValue !== undefined) {\n return typeof constValue;\n }\n const enumValue = schema.enum();\n if (Array.isArray(enumValue) && enumValue.length) {\n const inferredType = Array.from(new Set(enumValue.map(e => typeof e)));\n return inferredType.length === 1 ? inferredType[0] : inferredType;\n }\n\n const schemaKeys = Object.keys(schema.json() || {}) || [];\n const hasInferredTypes = jsonSchemaKeywords.some(key =>\n schemaKeys.includes(key),\n );\n if (hasInferredTypes === true) {\n return SchemaCustomTypes.RESTRICTED_ANY;\n }\n if (this.toCombinedType(schema)) {\n return '';\n }\n return SchemaCustomTypes.ANY;\n }\n\n private static humanizeNumberRangeConstraint(\n min: number | undefined,\n exclusiveMin: number | undefined,\n max: number | undefined,\n exclusiveMax: number | undefined,\n ): string | undefined {\n const hasExclusiveMin = exclusiveMin !== undefined;\n const hasMin = min !== undefined || hasExclusiveMin;\n const hasExclusiveMax = exclusiveMax !== undefined;\n const hasMax = max !== undefined || hasExclusiveMax;\n\n let numberRange;\n if (hasMin && hasMax) {\n numberRange = hasExclusiveMin ? '( ' : '[ ';\n numberRange += hasExclusiveMin ? exclusiveMin : min;\n numberRange += ' .. ';\n numberRange += hasExclusiveMax ? exclusiveMax : max;\n numberRange += hasExclusiveMax ? ' )' : ' ]';\n } else if (hasMin) {\n numberRange = hasExclusiveMin ? '> ' : '>= ';\n numberRange += hasExclusiveMin ? exclusiveMin : min;\n } else if (hasMax) {\n numberRange = hasExclusiveMax ? '< ' : '<= ';\n numberRange += hasExclusiveMax ? exclusiveMax : max;\n }\n return numberRange;\n }\n\n private static humanizeMultipleOfConstraint(\n multipleOf: number | undefined,\n ): string | undefined {\n if (multipleOf === undefined) {\n return;\n }\n const strigifiedMultipleOf = multipleOf.toString(10);\n if (!/^0\\.0*1$/.test(strigifiedMultipleOf)) {\n return `multiple of ${strigifiedMultipleOf}`;\n }\n return `decimal places <= ${strigifiedMultipleOf.split('.')[1].length}`;\n }\n\n private static humanizeRangeConstraint(\n description: string,\n min: number | undefined,\n max: number | undefined,\n ): string | undefined {\n let stringRange;\n if (min !== undefined && max !== undefined) {\n if (min === max) {\n stringRange = `${min} ${description}`;\n } else {\n stringRange = `[ ${min} .. ${max} ] ${description}`;\n }\n } else if (max !== undefined) {\n stringRange = `<= ${max} ${description}`;\n } else if (min !== undefined) {\n if (min === 1) {\n stringRange = 'non-empty';\n } else {\n stringRange = `>= ${min} ${description}`;\n }\n }\n return stringRange;\n }\n\n private static jsonFieldToSchema(value: any): any {\n if (value === undefined || value === null) {\n return {\n type: 'string',\n const: '',\n [this.extRawValue]: true,\n };\n }\n if (typeof value !== 'object') {\n const str =\n typeof value.toString === 'function' ? value.toString() : value;\n return {\n type: 'string',\n const: str,\n [this.extRawValue]: true,\n };\n }\n if (this.isJSONSchema(value)) {\n return value;\n }\n if (Array.isArray(value)) {\n return {\n type: 'array',\n items: value.map(v => this.jsonFieldToSchema(v)),\n [this.extRenderAdditionalInfo]: false,\n };\n }\n return {\n type: 'object',\n properties: Object.entries(value).reduce((obj, [k, v]) => {\n obj[k] = this.jsonFieldToSchema(v);\n return obj;\n }, {}),\n [this.extRenderAdditionalInfo]: false,\n };\n }\n\n private static isJSONSchema(value: any): boolean {\n if (\n value &&\n typeof value === 'object' &&\n (jsonSchemaTypes.includes(value.type) ||\n (Array.isArray(value.type) &&\n value.type.some((t: string) => !jsonSchemaTypes.includes(t))))\n ) {\n return true;\n }\n return false;\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../src/helpers/schema.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,OAAO,EAIL,QAAQ,IAAI,WAAW,GAGxB,MAAM,kBAAkB,CAAC;AAE1B,MAAM,CAAN,IAAY,iBASX;AATD,WAAY,iBAAiB;IAE3B,gCAAW,CAAA;IAEX,sDAAiC,CAAA;IAEjC,oCAAe,CAAA;IAEf,wCAAmB,CAAA;AACrB,CAAC,EATW,iBAAiB,KAAjB,iBAAiB,QAS5B;AAED,IAAM,eAAe,GAAG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ACD,OAAO,KAAK,CAAC;IACf,CAAC;IA1dM,qCAAuB,GAAG,yCAAyC,CAAC;IACpE,yBAAW,GAAG,4BAA4B,CAAC;IAC3C,kCAAoB,GAAG,qCAAqC,CAAC;IAydtE,oBAAC;CAAA,AA5dD,IA4dC;SA5dY,aAAa","sourcesContent":["import {\n SchemaInterface,\n ChannelParametersInterface,\n ServerVariablesInterface,\n SchemaV2 as SchemaClass,\n ExtensionInterface,\n ExtensionsInterface,\n} from '@asyncapi/parser';\n\nexport enum SchemaCustomTypes {\n // for `true` and `{}` schemas\n ANY = 'any',\n // for schemas without `type` keyword\n RESTRICTED_ANY = 'restricted any',\n // for `false` and `{ not: {}, ... }` schemas\n NEVER = 'never',\n // for types that we cannot infer\n UNKNOWN = 'unknown',\n}\n\nconst jsonSchemaTypes = [\n 'string',\n 'number',\n 'integer',\n 'boolean',\n 'array',\n 'object',\n 'null',\n];\nconst jsonSchemaKeywordTypes: Record<string, string> = {\n // string\n maxLength: 'string',\n minLength: 'string',\n pattern: 'string',\n contentMediaType: 'string',\n contentEncoding: 'string',\n // number\n multipleOf: 'number',\n maximum: 'number',\n exclusiveMaximum: 'number',\n minimum: 'number',\n exclusiveMinimum: 'number',\n // array\n items: 'array',\n maxItems: 'array',\n minItems: 'array',\n uniqueItems: 'array',\n contains: 'array',\n additionalItems: 'array',\n // object\n maxProperties: 'object',\n minProperties: 'object',\n required: 'object',\n properties: 'object',\n patternProperties: 'object',\n propertyNames: 'object',\n dependencies: 'object',\n additionalProperties: 'object',\n};\nconst jsonSchemaKeywords = Object.keys(jsonSchemaKeywordTypes);\n\nexport class SchemaHelpers {\n static extRenderAdditionalInfo = 'x-schema-private-render-additional-info';\n static extRawValue = 'x-schema-private-raw-value';\n static extParameterLocation = 'x-schema-private-parameter-location';\n\n static toSchemaType(schema: SchemaInterface): string {\n if (!schema || typeof schema.json !== 'function') {\n return SchemaCustomTypes.UNKNOWN;\n }\n if (schema.isBooleanSchema()) {\n if (schema.json() === true) {\n return SchemaCustomTypes.ANY;\n } else {\n return SchemaCustomTypes.NEVER;\n }\n }\n // handle case with `{}` schemas\n if (Object.keys(schema.json()).length === 0) {\n return SchemaCustomTypes.ANY;\n }\n // handle case with `{ not: {}, ... }` schemas\n const not = schema.not();\n if (not && this.inferType(not) === SchemaCustomTypes.ANY) {\n return SchemaCustomTypes.NEVER;\n }\n\n let type = this.inferType(schema);\n if (Array.isArray(type)) {\n return type.map(t => this.toType(t, schema)).join(' | ');\n }\n type = this.toType(type, schema);\n const combinedType = this.toCombinedType(schema);\n\n if (type && combinedType) {\n return `${type} ${combinedType}`;\n }\n if (combinedType) {\n return combinedType;\n }\n return type;\n }\n\n static prettifyValue(value: any, strict = true): string {\n const typeOf = typeof value;\n if (typeOf === 'string') {\n return strict ? `\"${value}\"` : value;\n }\n if (typeOf === 'number' || typeOf === 'bigint' || typeOf === 'boolean') {\n return `${value}`;\n }\n if (Array.isArray(value)) {\n return `[${value.toString()}]`;\n }\n return JSON.stringify(value);\n }\n\n static humanizeConstraints(schema: SchemaInterface): string[] {\n const constraints: string[] = [];\n\n // related to number/integer\n const numberRange = this.humanizeNumberRangeConstraint(\n schema.minimum(),\n schema.exclusiveMinimum(),\n schema.maximum(),\n schema.exclusiveMaximum(),\n );\n if (numberRange !== undefined) {\n constraints.push(numberRange);\n }\n const multipleOfConstraint = this.humanizeMultipleOfConstraint(\n schema.multipleOf(),\n );\n if (multipleOfConstraint !== undefined) {\n constraints.push(multipleOfConstraint);\n }\n\n // related to string\n const stringRange = this.humanizeRangeConstraint(\n 'characters',\n schema.minLength(),\n schema.maxLength(),\n );\n if (stringRange !== undefined) {\n constraints.push(stringRange);\n }\n\n // related to array\n const hasUniqueItems = schema.uniqueItems();\n const arrayRange = this.humanizeRangeConstraint(\n hasUniqueItems ? 'unique items' : 'items',\n schema.minItems(),\n schema.maxItems(),\n );\n if (arrayRange !== undefined) {\n constraints.push(arrayRange);\n }\n\n // related to object\n const objectRange = this.humanizeRangeConstraint(\n 'properties',\n schema.minProperties(),\n schema.maxProperties(),\n );\n if (objectRange !== undefined) {\n constraints.push(objectRange);\n }\n\n return constraints;\n }\n\n static isExpandable(schema: SchemaInterface): boolean {\n let type = this.inferType(schema);\n type = Array.isArray(type) ? type : [type];\n if (type.includes('object') || type.includes('array')) {\n return true;\n }\n\n if (\n schema.oneOf() ||\n schema.anyOf() ||\n schema.allOf() ||\n Object.keys(schema.properties() || {}).length > 0 ||\n schema.items() ||\n schema.not() ||\n schema.if() ||\n schema.then() ||\n schema.else()\n ) {\n return true;\n }\n\n const customExtensions = this.getCustomExtensions(schema);\n if (customExtensions && Object.keys(customExtensions).length) {\n return true;\n }\n\n return false;\n }\n\n static serverVariablesToSchema(\n urlVariables?: ServerVariablesInterface,\n ): SchemaInterface | undefined {\n if (!urlVariables || urlVariables.length === 0) {\n return undefined;\n }\n const obj = {};\n urlVariables.all().forEach(variable => {\n obj[variable.id()] = { ...(variable.json() || {}) };\n obj[variable.id()].type = 'string';\n });\n\n const json = {\n type: 'object',\n properties: obj,\n required: Object.keys(obj),\n [this.extRenderAdditionalInfo]: false,\n };\n return new SchemaClass(json as any);\n }\n\n static parametersToSchema(\n parameters?: ChannelParametersInterface,\n ): SchemaInterface | undefined {\n if (!parameters || parameters.isEmpty()) {\n return undefined;\n }\n const obj = {};\n parameters.all().forEach(parameter => {\n const parameterSchema = parameter.schema();\n obj[parameter.id()] = { ...(parameterSchema?.json() ?? {}) };\n obj[parameter.id()].description = parameter.hasDescription()\n ? parameter.description()\n : undefined;\n obj[parameter.id()][this.extParameterLocation] = parameter.hasLocation()\n ? parameter.location()\n : undefined;\n });\n\n const json = {\n type: 'object',\n properties: obj,\n required: Object.keys(obj),\n [this.extRenderAdditionalInfo]: false,\n };\n return new SchemaClass(json as any);\n }\n\n static jsonToSchema(value: any): any {\n const json = this.jsonFieldToSchema(value);\n return new SchemaClass(json);\n }\n\n /**\n * Retrieves from given value all custom extensions (value with key started by `x-`).\n * However, it skips those private extensions that begin with `x-parser-` and `x-schema-private-`.\n *\n * @param value\n */\n static getCustomExtensions(value: any) {\n if (!value || typeof value.extensions !== 'function') {\n return;\n }\n const extensions = value.extensions() as ExtensionsInterface;\n const filteredExtensions = {};\n for (const ext of extensions.all()) {\n const extType = ext as ExtensionInterface;\n if (\n !extType.id().startsWith('x-parser-') &&\n !extType.id().startsWith('x-schema-private-')\n ) {\n filteredExtensions[extType.id()] = extType.value();\n }\n }\n return filteredExtensions;\n }\n\n /**\n * Retrieves from given schema all dependent required requires by given propertyName from `dependencies` object.\n *\n * @param propertyName\n * @param schema\n */\n static getDependentRequired(\n propertyName: string,\n schema: SchemaInterface,\n ): string[] | undefined {\n const dependentRequired: string[] = [];\n const dependencies = schema.dependencies();\n if (!dependencies) {\n return;\n }\n\n for (const [prop, array] of Object.entries(dependencies)) {\n if (Array.isArray(array) && array.includes(propertyName)) {\n dependentRequired.push(prop);\n }\n }\n return dependentRequired.length ? dependentRequired : undefined;\n }\n\n /**\n * Retrieves from given schema all dependent schemas from `dependencies` object.\n *\n * @param schema\n */\n static getDependentSchemas(\n schema: SchemaInterface,\n ): SchemaInterface | undefined {\n const dependencies = schema.dependencies();\n if (!dependencies) {\n return;\n }\n\n const records: Record<string, SchemaInterface> = {};\n for (const [prop, propSchema] of Object.entries(dependencies)) {\n if (typeof propSchema === 'object' && !Array.isArray(propSchema)) {\n records[prop] = propSchema;\n }\n }\n if (!Object.keys(records).length) {\n return undefined;\n }\n\n const json = {\n type: 'object',\n properties: Object.entries(records).reduce(\n (obj, [propertyName, propertySchema]) => {\n obj[propertyName] = { ...(propertySchema.json() || {}) };\n return obj;\n },\n {},\n ),\n [this.extRenderAdditionalInfo]: false,\n };\n return new SchemaClass(json as any);\n }\n\n private static toType(type: string, schema: SchemaInterface): string {\n if (schema.isCircular()) {\n return type;\n }\n if (type === 'array') {\n const items = schema.items();\n if (Array.isArray(items)) {\n return this.toItemsType(items, schema);\n }\n if (!items) {\n return `array<${SchemaCustomTypes.ANY}>`;\n }\n return `array<${this.toSchemaType(items) || SchemaCustomTypes.UNKNOWN}>`;\n }\n return type;\n }\n\n private static toItemsType(\n items: SchemaInterface[],\n schema: SchemaInterface,\n ): string {\n const types = items.map(item => this.toSchemaType(item)).join(', ');\n const additionalItems = schema.additionalItems();\n if (additionalItems !== undefined && additionalItems !== false) {\n const additionalType =\n additionalItems === true\n ? SchemaCustomTypes.ANY\n : this.toSchemaType(additionalItems);\n return `tuple<${types ||\n SchemaCustomTypes.UNKNOWN}, ...optional<${additionalType}>>`;\n }\n return `tuple<${types || SchemaCustomTypes.UNKNOWN}>`;\n }\n\n private static toCombinedType(schema: SchemaInterface): string | undefined {\n const oneOf = schema.oneOf();\n if (oneOf) {\n return 'oneOf';\n }\n if (schema.anyOf()) {\n return 'anyOf';\n }\n if (schema.allOf()) {\n return 'allOf';\n }\n return;\n }\n\n private static inferType(schema: SchemaInterface): string[] | string {\n let types = schema.type();\n\n if (types !== undefined) {\n if (Array.isArray(types)) {\n // if types have `integer` and `number` types, `integer` is unnecessary\n if (types.includes('integer') && types.includes('number')) {\n types = types.filter(t => t !== 'integer');\n }\n return types.length === 1 ? types[0] : types;\n }\n return types;\n }\n\n const constValue = schema.const();\n if (constValue !== undefined) {\n return typeof constValue;\n }\n const enumValue = schema.enum();\n if (Array.isArray(enumValue) && enumValue.length) {\n const inferredType = Array.from(new Set(enumValue.map(e => typeof e)));\n return inferredType.length === 1 ? inferredType[0] : inferredType;\n }\n\n const schemaKeys = Object.keys(schema.json() || {}) || [];\n const hasInferredTypes = jsonSchemaKeywords.some(key =>\n schemaKeys.includes(key),\n );\n if (hasInferredTypes === true) {\n return SchemaCustomTypes.RESTRICTED_ANY;\n }\n if (this.toCombinedType(schema)) {\n return '';\n }\n return SchemaCustomTypes.ANY;\n }\n\n private static humanizeNumberRangeConstraint(\n min: number | undefined,\n exclusiveMin: number | undefined,\n max: number | undefined,\n exclusiveMax: number | undefined,\n ): string | undefined {\n const hasExclusiveMin = exclusiveMin !== undefined;\n const hasMin = min !== undefined || hasExclusiveMin;\n const hasExclusiveMax = exclusiveMax !== undefined;\n const hasMax = max !== undefined || hasExclusiveMax;\n\n let numberRange;\n if (hasMin && hasMax) {\n numberRange = hasExclusiveMin ? '( ' : '[ ';\n numberRange += hasExclusiveMin ? exclusiveMin : min;\n numberRange += ' .. ';\n numberRange += hasExclusiveMax ? exclusiveMax : max;\n numberRange += hasExclusiveMax ? ' )' : ' ]';\n } else if (hasMin) {\n numberRange = hasExclusiveMin ? '> ' : '>= ';\n numberRange += hasExclusiveMin ? exclusiveMin : min;\n } else if (hasMax) {\n numberRange = hasExclusiveMax ? '< ' : '<= ';\n numberRange += hasExclusiveMax ? exclusiveMax : max;\n }\n return numberRange;\n }\n\n private static humanizeMultipleOfConstraint(\n multipleOf: number | undefined,\n ): string | undefined {\n if (multipleOf === undefined) {\n return;\n }\n const strigifiedMultipleOf = multipleOf.toString(10);\n if (!/^0\\.0*1$/.test(strigifiedMultipleOf)) {\n return `multiple of ${strigifiedMultipleOf}`;\n }\n return `decimal places <= ${strigifiedMultipleOf.split('.')[1].length}`;\n }\n\n private static humanizeRangeConstraint(\n description: string,\n min: number | undefined,\n max: number | undefined,\n ): string | undefined {\n let stringRange;\n if (min !== undefined && max !== undefined) {\n if (min === max) {\n stringRange = `${min} ${description}`;\n } else {\n stringRange = `[ ${min} .. ${max} ] ${description}`;\n }\n } else if (max !== undefined) {\n stringRange = `<= ${max} ${description}`;\n } else if (min !== undefined) {\n if (min === 1) {\n stringRange = 'non-empty';\n } else {\n stringRange = `>= ${min} ${description}`;\n }\n }\n return stringRange;\n }\n\n private static jsonFieldToSchema(value: any): any {\n if (value === undefined || value === null) {\n return {\n type: 'string',\n const: '',\n [this.extRawValue]: true,\n };\n }\n if (typeof value !== 'object') {\n const str =\n typeof value.toString === 'function' ? value.toString() : value;\n return {\n type: 'string',\n const: str,\n [this.extRawValue]: true,\n };\n }\n if (this.isJSONSchema(value)) {\n return value;\n }\n if (Array.isArray(value)) {\n return {\n type: 'array',\n items: value.map(v => this.jsonFieldToSchema(v)),\n [this.extRenderAdditionalInfo]: false,\n };\n }\n return {\n type: 'object',\n properties: Object.entries(value).reduce((obj, [k, v]) => {\n obj[k] = this.jsonFieldToSchema(v);\n return obj;\n }, {}),\n [this.extRenderAdditionalInfo]: false,\n };\n }\n\n private static isJSONSchema(value: any): boolean {\n if (\n value &&\n typeof value === 'object' &&\n (jsonSchemaTypes.includes(value.type) ||\n (Array.isArray(value.type) &&\n value.type.some((t: string) => !jsonSchemaTypes.includes(t))))\n ) {\n return true;\n }\n return false;\n }\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Bindings.d.ts","sourceRoot":"","sources":["../../../src/components/Bindings.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"Bindings.d.ts","sourceRoot":"","sources":["../../../src/components/Bindings.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AAErD,UAAU,KAAK;IACb,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,iBAAiB,CAAC;CAC7B;AAED,eAAO,MAAM,QAAQ,EAAE,KAAK,CAAC,iBAAiB,CAAC,KAAK,CAiCnD,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { TagsInterface } from '@asyncapi/parser';
|
|
3
3
|
interface Props {
|
|
4
|
-
tags?:
|
|
4
|
+
tags?: TagsInterface;
|
|
5
5
|
}
|
|
6
6
|
export declare const Tags: React.FunctionComponent<Props>;
|
|
7
7
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tags.d.ts","sourceRoot":"","sources":["../../../src/components/Tags.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"Tags.d.ts","sourceRoot":"","sources":["../../../src/components/Tags.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAIjD,UAAU,KAAK;IACb,IAAI,CAAC,EAAE,aAAa,CAAC;CACtB;AAED,eAAO,MAAM,IAAI,EAAE,KAAK,CAAC,iBAAiB,CAAC,KAAK,CAc/C,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Component } from 'react';
|
|
1
|
+
import React, { Component } from 'react';
|
|
2
2
|
import { AsyncAPIDocumentInterface } from '@asyncapi/parser';
|
|
3
3
|
import { ErrorObject, PropsSchema } from '../../types';
|
|
4
4
|
import { ConfigInterface } from '../../config';
|
|
@@ -15,7 +15,7 @@ declare class AsyncApiComponent extends Component<AsyncApiProps, AsyncAPIState>
|
|
|
15
15
|
constructor(props: AsyncApiProps);
|
|
16
16
|
componentDidMount(): Promise<void>;
|
|
17
17
|
componentDidUpdate(prevProps: AsyncApiProps): Promise<void>;
|
|
18
|
-
render(): JSX.Element;
|
|
18
|
+
render(): React.JSX.Element;
|
|
19
19
|
private parseSchema;
|
|
20
20
|
}
|
|
21
21
|
export default AsyncApiComponent;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AsyncApi.d.ts","sourceRoot":"","sources":["../../../../src/containers/AsyncApi/AsyncApi.tsx"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"AsyncApi.d.ts","sourceRoot":"","sources":["../../../../src/containers/AsyncApi/AsyncApi.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AACzC,OAAO,EAAE,yBAAyB,EAAE,MAAM,kBAAkB,CAAC;AAI7D,OAAO,EAEL,WAAW,EACX,WAAW,EACZ,MAAM,aAAa,CAAC;AACrB,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAG/C,MAAM,WAAW,aAAa;IAC5B,MAAM,EAAE,WAAW,CAAC;IACpB,MAAM,CAAC,EAAE,OAAO,CAAC,eAAe,CAAC,CAAC;CACnC;AAED,UAAU,aAAa;IACrB,QAAQ,CAAC,EAAE,yBAAyB,CAAC;IACrC,KAAK,CAAC,EAAE,WAAW,CAAC;CACrB;AAED,cAAM,iBAAkB,SAAQ,SAAS,CAAC,aAAa,EAAE,aAAa,CAAC;IACrE,KAAK,EAAE,aAAa,CAGlB;gBAEU,KAAK,EAAE,aAAa;IAI1B,iBAAiB;IAOjB,kBAAkB,CAAC,SAAS,EAAE,aAAa;IAUjD,MAAM;YAaQ,WAAW;CAwB1B;AAED,eAAe,iBAAiB,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Component } from 'react';
|
|
1
|
+
import React, { Component } from 'react';
|
|
2
2
|
import { AsyncAPIDocumentInterface } from '@asyncapi/parser';
|
|
3
3
|
import { ErrorObject, PropsSchema } from '../../types';
|
|
4
4
|
import { ConfigInterface } from '../../config';
|
|
@@ -16,7 +16,7 @@ declare class AsyncApiComponent extends Component<AsyncApiProps, AsyncAPIState>
|
|
|
16
16
|
constructor(props: AsyncApiProps);
|
|
17
17
|
componentDidMount(): Promise<void>;
|
|
18
18
|
componentDidUpdate(prevProps: AsyncApiProps): Promise<void>;
|
|
19
|
-
render(): false | JSX.Element | null | undefined;
|
|
19
|
+
render(): false | React.JSX.Element | null | undefined;
|
|
20
20
|
private updateState;
|
|
21
21
|
}
|
|
22
22
|
export default AsyncApiComponent;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Standalone.d.ts","sourceRoot":"","sources":["../../../../src/containers/AsyncApi/Standalone.tsx"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"Standalone.d.ts","sourceRoot":"","sources":["../../../../src/containers/AsyncApi/Standalone.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AACzC,OAAO,EAAE,yBAAyB,EAAE,MAAM,kBAAkB,CAAC;AAG7D,OAAO,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AACvD,OAAO,EAAE,eAAe,EAAiB,MAAM,cAAc,CAAC;AAK9D,MAAM,WAAW,aAAa;IAC5B,MAAM,EAAE,WAAW,CAAC;IACpB,MAAM,CAAC,EAAE,OAAO,CAAC,eAAe,CAAC,CAAC;IAClC,KAAK,CAAC,EAAE,WAAW,CAAC;CACrB;AAED,UAAU,aAAa;IACrB,QAAQ,CAAC,EAAE,yBAAyB,CAAC;IACrC,KAAK,CAAC,EAAE,WAAW,CAAC;CACrB;AAED,cAAM,iBAAkB,SAAQ,SAAS,CAAC,aAAa,EAAE,aAAa,CAAC;IACrE,KAAK,EAAE,aAAa,CAGlB;gBAEU,KAAK,EAAE,aAAa;IAU1B,iBAAiB;IAMjB,kBAAkB,CAAC,SAAS,EAAE,aAAa;IASjD,MAAM;IAsCN,OAAO,CAAC,WAAW;CAQpB;AAED,eAAe,iBAAiB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Messages.d.ts","sourceRoot":"","sources":["../../../../src/containers/Messages/Messages.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAQ1B,eAAO,MAAM,QAAQ,EAAE,KAAK,CAAC,
|
|
1
|
+
{"version":3,"file":"Messages.d.ts","sourceRoot":"","sources":["../../../../src/containers/Messages/Messages.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAQ1B,eAAO,MAAM,QAAQ,EAAE,KAAK,CAAC,iBAwC5B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Operation.d.ts","sourceRoot":"","sources":["../../../../src/containers/Operations/Operation.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,gBAAgB,EAAE,kBAAkB,EAAE,MAAM,kBAAkB,CAAC;AAoBxE,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAE1C,UAAU,KAAK;IACb,IAAI,EAAE,WAAW,CAAC;IAClB,SAAS,EAAE,kBAAkB,CAAC;IAC9B,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,gBAAgB,CAAC;CAC3B;AAED,eAAO,MAAM,SAAS,EAAE,KAAK,CAAC,iBAAiB,CAAC,KAAK,
|
|
1
|
+
{"version":3,"file":"Operation.d.ts","sourceRoot":"","sources":["../../../../src/containers/Operations/Operation.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,gBAAgB,EAAE,kBAAkB,EAAE,MAAM,kBAAkB,CAAC;AAoBxE,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAE1C,UAAU,KAAK;IACb,IAAI,EAAE,WAAW,CAAC;IAClB,SAAS,EAAE,kBAAkB,CAAC;IAC9B,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,gBAAgB,CAAC;CAC3B;AAED,eAAO,MAAM,SAAS,EAAE,KAAK,CAAC,iBAAiB,CAAC,KAAK,CA8IpD,CAAC;AAsBF,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,iBAAiB,CAAC,KAAK,CA+DxD,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Operations.d.ts","sourceRoot":"","sources":["../../../../src/containers/Operations/Operations.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAQ1B,eAAO,MAAM,UAAU,EAAE,KAAK,CAAC,
|
|
1
|
+
{"version":3,"file":"Operations.d.ts","sourceRoot":"","sources":["../../../../src/containers/Operations/Operations.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAQ1B,eAAO,MAAM,UAAU,EAAE,KAAK,CAAC,iBAiE9B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Schemas.d.ts","sourceRoot":"","sources":["../../../../src/containers/Schemas/Schemas.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAQ1B,eAAO,MAAM,OAAO,EAAE,KAAK,CAAC,
|
|
1
|
+
{"version":3,"file":"Schemas.d.ts","sourceRoot":"","sources":["../../../../src/containers/Schemas/Schemas.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAQ1B,eAAO,MAAM,OAAO,EAAE,KAAK,CAAC,iBAmC3B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Servers.d.ts","sourceRoot":"","sources":["../../../../src/containers/Servers/Servers.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAQ1B,eAAO,MAAM,OAAO,EAAE,KAAK,CAAC,
|
|
1
|
+
{"version":3,"file":"Servers.d.ts","sourceRoot":"","sources":["../../../../src/containers/Servers/Servers.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAQ1B,eAAO,MAAM,OAAO,EAAE,KAAK,CAAC,iBAyC3B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"parser.d.ts","sourceRoot":"","sources":["../../../src/helpers/parser.ts"],"names":[],"mappings":"AAMA,OAAO,EAAe,YAAY,EAAE,uBAAuB,EAAE,MAAM,UAAU,CAAC;AAU9E,qBAAa,MAAM;WACJ,KAAK,CAChB,OAAO,EAAE,MAAM,GAAG,GAAG,EACrB,aAAa,CAAC,EAAE,GAAG,GAClB,OAAO,CAAC,YAAY,CAAC;WASX,YAAY,CACvB,GAAG,EAAE,uBAAuB,EAC5B,aAAa,CAAC,EAAE,GAAG,GAClB,OAAO,CAAC,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"parser.d.ts","sourceRoot":"","sources":["../../../src/helpers/parser.ts"],"names":[],"mappings":"AAMA,OAAO,EAAe,YAAY,EAAE,uBAAuB,EAAE,MAAM,UAAU,CAAC;AAU9E,qBAAa,MAAM;WACJ,KAAK,CAChB,OAAO,EAAE,MAAM,GAAG,GAAG,EACrB,aAAa,CAAC,EAAE,GAAG,GAClB,OAAO,CAAC,YAAY,CAAC;WASX,YAAY,CACvB,GAAG,EAAE,uBAAuB,EAC5B,aAAa,CAAC,EAAE,GAAG,GAClB,OAAO,CAAC,YAAY,CAAC;IAcxB,OAAO,CAAC,MAAM,CAAC,WAAW,CAOxB;CACH"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../src/helpers/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,eAAe,EACf,0BAA0B,EAC1B,wBAAwB,EAIzB,MAAM,kBAAkB,CAAC;AAE1B,oBAAY,iBAAiB;IAE3B,GAAG,QAAQ;IAEX,cAAc,mBAAmB;IAEjC,KAAK,UAAU;IAEf,OAAO,YAAY;CACpB;AA2CD,qBAAa,aAAa;IACxB,MAAM,CAAC,uBAAuB,SAA6C;IAC3E,MAAM,CAAC,WAAW,SAAgC;IAClD,MAAM,CAAC,oBAAoB,SAAyC;IAEpE,MAAM,CAAC,YAAY,CAAC,MAAM,EAAE,eAAe,GAAG,MAAM;IAqCpD,MAAM,CAAC,aAAa,CAAC,KAAK,EAAE,GAAG,EAAE,MAAM,UAAO,GAAG,MAAM;IAcvD,MAAM,CAAC,mBAAmB,CAAC,MAAM,EAAE,eAAe,GAAG,MAAM,EAAE;IAsD7D,MAAM,CAAC,YAAY,CAAC,MAAM,EAAE,eAAe,GAAG,OAAO;IA6BrD,MAAM,CAAC,uBAAuB,CAC5B,YAAY,CAAC,EAAE,wBAAwB,GACtC,eAAe,GAAG,SAAS;
|
|
1
|
+
{"version":3,"file":"schema.d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,CAAC,MAAM,CAAC,SAAS;IAqCxB,OAAO,CAAC,MAAM,CAAC,6BAA6B;IA4B5C,OAAO,CAAC,MAAM,CAAC,4BAA4B;IAa3C,OAAO,CAAC,MAAM,CAAC,uBAAuB;IAwBtC,OAAO,CAAC,MAAM,CAAC,iBAAiB;IAqChC,OAAO,CAAC,MAAM,CAAC,YAAY;CAY5B"}
|
package/lib/types/types.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { AsyncAPIDocumentInterface } from '@asyncapi/parser';
|
|
2
|
-
export
|
|
3
|
-
export
|
|
2
|
+
export type PropsSchema = string | FetchingSchemaInterface | AsyncAPIDocumentInterface | object;
|
|
3
|
+
export type NullableAsyncApi = AsyncAPIDocumentInterface | null;
|
|
4
4
|
export interface AsyncApiState {
|
|
5
5
|
validatedSchema: NullableAsyncApi;
|
|
6
6
|
error?: ErrorObject;
|
package/lib/types/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,yBAAyB,EAAE,MAAM,kBAAkB,CAAC;AAE7D,
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,yBAAyB,EAAE,MAAM,kBAAkB,CAAC;AAE7D,MAAM,MAAM,WAAW,GACnB,MAAM,GACN,uBAAuB,GACvB,yBAAyB,GACzB,MAAM,CAAC;AAEX,MAAM,MAAM,gBAAgB,GAAG,yBAAyB,GAAG,IAAI,CAAC;AAEhE,MAAM,WAAW,aAAa;IAC5B,eAAe,EAAE,gBAAgB,CAAC;IAClC,KAAK,CAAC,EAAE,WAAW,CAAC;CACrB;AAED,wBAAgB,yBAAyB,CACvC,MAAM,EAAE,WAAW,GAClB,MAAM,IAAI,uBAAuB,CAEnC;AAED,MAAM,WAAW,uBAAuB;IACtC,GAAG,EAAE,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AE,MAAM,CAAC;KACnB,CAAC,CAAC;CACJ"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@asyncapi/react-component",
|
|
3
|
-
"version": "1.0.0-next.
|
|
3
|
+
"version": "1.0.0-next.51",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "A React component for AsyncAPI specification.",
|
|
6
6
|
"repository": {
|
|
@@ -85,8 +85,8 @@
|
|
|
85
85
|
"devDependencies": {
|
|
86
86
|
"@cypress/webpack-preprocessor": "^5.9.0",
|
|
87
87
|
"@tailwindcss/typography": "^0.4.0",
|
|
88
|
-
"@testing-library/jest-dom": "^5.
|
|
89
|
-
"@testing-library/react": "^
|
|
88
|
+
"@testing-library/jest-dom": "^5.17.0",
|
|
89
|
+
"@testing-library/react": "^12.1.5",
|
|
90
90
|
"@testing-library/user-event": "^12.8.3",
|
|
91
91
|
"@types/dompurify": "^2.0.4",
|
|
92
92
|
"@types/highlight.js": "^10.1.0",
|
package/styles/default.css
CHANGED
|
@@ -428,6 +428,11 @@ Correct the inability to style clickable types in iOS and Safari.
|
|
|
428
428
|
Remove the inner border and padding in Firefox.
|
|
429
429
|
*/
|
|
430
430
|
|
|
431
|
+
.aui-root ::-moz-focus-inner {
|
|
432
|
+
border-style: none;
|
|
433
|
+
padding: 0;
|
|
434
|
+
}
|
|
435
|
+
|
|
431
436
|
/**
|
|
432
437
|
Restore the focus styles unset by the previous rule.
|
|
433
438
|
*/
|
|
@@ -457,20 +462,39 @@ Add the correct vertical alignment in Chrome and Firefox.
|
|
|
457
462
|
Correct the cursor style of increment and decrement buttons in Safari.
|
|
458
463
|
*/
|
|
459
464
|
|
|
465
|
+
.aui-root ::-webkit-inner-spin-button,
|
|
466
|
+
.aui-root ::-webkit-outer-spin-button {
|
|
467
|
+
height: auto;
|
|
468
|
+
}
|
|
469
|
+
|
|
460
470
|
/**
|
|
461
471
|
1. Correct the odd appearance in Chrome and Safari.
|
|
462
472
|
2. Correct the outline style in Safari.
|
|
463
473
|
*/
|
|
464
474
|
|
|
475
|
+
.aui-root [type='search'] {
|
|
476
|
+
-webkit-appearance: textfield; /* 1 */
|
|
477
|
+
outline-offset: -2px; /* 2 */
|
|
478
|
+
}
|
|
479
|
+
|
|
465
480
|
/**
|
|
466
481
|
Remove the inner padding in Chrome and Safari on macOS.
|
|
467
482
|
*/
|
|
468
483
|
|
|
484
|
+
.aui-root ::-webkit-search-decoration {
|
|
485
|
+
-webkit-appearance: none;
|
|
486
|
+
}
|
|
487
|
+
|
|
469
488
|
/**
|
|
470
489
|
1. Correct the inability to style clickable types in iOS and Safari.
|
|
471
490
|
2. Change font properties to 'inherit' in Safari.
|
|
472
491
|
*/
|
|
473
492
|
|
|
493
|
+
.aui-root ::-webkit-file-upload-button {
|
|
494
|
+
-webkit-appearance: button; /* 1 */
|
|
495
|
+
font: inherit; /* 2 */
|
|
496
|
+
}
|
|
497
|
+
|
|
474
498
|
/*
|
|
475
499
|
Interactive
|
|
476
500
|
===========
|
|
@@ -619,11 +643,6 @@ Add the correct display in Chrome and Safari.
|
|
|
619
643
|
color: #cbd5e0;
|
|
620
644
|
}
|
|
621
645
|
|
|
622
|
-
.aui-root input:-ms-input-placeholder, .aui-root textarea:-ms-input-placeholder {
|
|
623
|
-
opacity: 1;
|
|
624
|
-
color: #cbd5e0;
|
|
625
|
-
}
|
|
626
|
-
|
|
627
646
|
.aui-root input::placeholder,
|
|
628
647
|
.aui-root textarea::placeholder {
|
|
629
648
|
opacity: 1;
|
|
@@ -753,6 +772,40 @@ Add the correct display in Chrome and Safari.
|
|
|
753
772
|
border-color: rgba(203, 213, 224, var(--tw-border-opacity));
|
|
754
773
|
}
|
|
755
774
|
|
|
775
|
+
.aui-root .container{
|
|
776
|
+
width: 100%;
|
|
777
|
+
}
|
|
778
|
+
|
|
779
|
+
@media (min-width: 640px){
|
|
780
|
+
.aui-root .container{
|
|
781
|
+
max-width: 640px;
|
|
782
|
+
}
|
|
783
|
+
}
|
|
784
|
+
|
|
785
|
+
@media (min-width: 768px){
|
|
786
|
+
.aui-root .container{
|
|
787
|
+
max-width: 768px;
|
|
788
|
+
}
|
|
789
|
+
}
|
|
790
|
+
|
|
791
|
+
@media (min-width: 1024px){
|
|
792
|
+
.aui-root .container{
|
|
793
|
+
max-width: 1024px;
|
|
794
|
+
}
|
|
795
|
+
}
|
|
796
|
+
|
|
797
|
+
@media (min-width: 1280px){
|
|
798
|
+
.aui-root .container{
|
|
799
|
+
max-width: 1280px;
|
|
800
|
+
}
|
|
801
|
+
}
|
|
802
|
+
|
|
803
|
+
@media (min-width: 1536px){
|
|
804
|
+
.aui-root .container{
|
|
805
|
+
max-width: 1536px;
|
|
806
|
+
}
|
|
807
|
+
}
|
|
808
|
+
|
|
756
809
|
.aui-root .prose{
|
|
757
810
|
color: #4a5568;
|
|
758
811
|
max-width: 65ch;
|
|
@@ -1414,25 +1467,12 @@ Add the correct display in Chrome and Safari.
|
|
|
1414
1467
|
--tw-rotate: -90deg;
|
|
1415
1468
|
}
|
|
1416
1469
|
|
|
1417
|
-
@-webkit-keyframes spin{
|
|
1418
|
-
to{
|
|
1419
|
-
transform: rotate(360deg);
|
|
1420
|
-
}
|
|
1421
|
-
}
|
|
1422
|
-
|
|
1423
1470
|
@keyframes spin{
|
|
1424
1471
|
to{
|
|
1425
1472
|
transform: rotate(360deg);
|
|
1426
1473
|
}
|
|
1427
1474
|
}
|
|
1428
1475
|
|
|
1429
|
-
@-webkit-keyframes ping{
|
|
1430
|
-
75%, 100%{
|
|
1431
|
-
transform: scale(2);
|
|
1432
|
-
opacity: 0;
|
|
1433
|
-
}
|
|
1434
|
-
}
|
|
1435
|
-
|
|
1436
1476
|
@keyframes ping{
|
|
1437
1477
|
75%, 100%{
|
|
1438
1478
|
transform: scale(2);
|
|
@@ -1440,43 +1480,21 @@ Add the correct display in Chrome and Safari.
|
|
|
1440
1480
|
}
|
|
1441
1481
|
}
|
|
1442
1482
|
|
|
1443
|
-
@-webkit-keyframes pulse{
|
|
1444
|
-
50%{
|
|
1445
|
-
opacity: .5;
|
|
1446
|
-
}
|
|
1447
|
-
}
|
|
1448
|
-
|
|
1449
1483
|
@keyframes pulse{
|
|
1450
1484
|
50%{
|
|
1451
1485
|
opacity: .5;
|
|
1452
1486
|
}
|
|
1453
1487
|
}
|
|
1454
1488
|
|
|
1455
|
-
@-webkit-keyframes bounce{
|
|
1456
|
-
0%, 100%{
|
|
1457
|
-
transform: translateY(-25%);
|
|
1458
|
-
-webkit-animation-timing-function: cubic-bezier(0.8,0,1,1);
|
|
1459
|
-
animation-timing-function: cubic-bezier(0.8,0,1,1);
|
|
1460
|
-
}
|
|
1461
|
-
|
|
1462
|
-
50%{
|
|
1463
|
-
transform: none;
|
|
1464
|
-
-webkit-animation-timing-function: cubic-bezier(0,0,0.2,1);
|
|
1465
|
-
animation-timing-function: cubic-bezier(0,0,0.2,1);
|
|
1466
|
-
}
|
|
1467
|
-
}
|
|
1468
|
-
|
|
1469
1489
|
@keyframes bounce{
|
|
1470
1490
|
0%, 100%{
|
|
1471
1491
|
transform: translateY(-25%);
|
|
1472
|
-
|
|
1473
|
-
animation-timing-function: cubic-bezier(0.8,0,1,1);
|
|
1492
|
+
animation-timing-function: cubic-bezier(0.8,0,1,1);
|
|
1474
1493
|
}
|
|
1475
1494
|
|
|
1476
1495
|
50%{
|
|
1477
1496
|
transform: none;
|
|
1478
|
-
|
|
1479
|
-
animation-timing-function: cubic-bezier(0,0,0.2,1);
|
|
1497
|
+
animation-timing-function: cubic-bezier(0,0,0.2,1);
|
|
1480
1498
|
}
|
|
1481
1499
|
}
|
|
1482
1500
|
|
package/styles/default.min.css
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
|
|
3
3
|
/*! tailwindcss v2.2.19 | MIT License | https://tailwindcss.com*/
|
|
4
4
|
|
|
5
|
-
/*! modern-normalize v1.1.0 | MIT License | https://github.com/sindresorhus/modern-normalize */.aui-root html{-moz-tab-size:4;-o-tab-size:4;tab-size:4;line-height:1.15;-webkit-text-size-adjust:100%}.aui-root body{margin:0;font-family:system-ui,-apple-system,Segoe UI,Roboto,Helvetica,Arial,sans-serif,Apple Color Emoji,Segoe UI Emoji}.aui-root hr{height:0;color:inherit}.aui-root abbr[title]{-webkit-text-decoration:underline dotted;text-decoration:underline dotted}.aui-root b,.aui-root strong{font-weight:bolder}.aui-root code,.aui-root kbd,.aui-root pre,.aui-root samp{font-family:ui-monospace,SFMono-Regular,Consolas,Liberation Mono,Menlo,monospace;font-size:1em}.aui-root small{font-size:80%}.aui-root sub,.aui-root sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}.aui-root sub{bottom:-.25em}.aui-root sup{top:-.5em}.aui-root table{text-indent:0;border-color:inherit}.aui-root button,.aui-root input,.aui-root optgroup,.aui-root select,.aui-root textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0}.aui-root button,.aui-root select{text-transform:none}.aui-root [type=button],.aui-root button{-webkit-appearance:button}.aui-root legend{padding:0}.aui-root progress{vertical-align:baseline}.aui-root summary{display:list-item}.aui-root blockquote,.aui-root dd,.aui-root dl,.aui-root figure,.aui-root h1,.aui-root h2,.aui-root h3,.aui-root h4,.aui-root h5,.aui-root h6,.aui-root hr,.aui-root p,.aui-root pre{margin:0}.aui-root button{background-color:transparent;background-image:none}.aui-root fieldset{margin:0;padding:0}.aui-root ol,.aui-root ul{list-style:none;margin:0;padding:0}.aui-root html{font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5}.aui-root body{font-family:inherit;line-height:inherit}.aui-root *,.aui-root :after,.aui-root :before{box-sizing:border-box;border:0 solid}.aui-root hr{border-top-width:1px}.aui-root img{border-style:solid}.aui-root textarea{resize:vertical}.aui-root input::-moz-placeholder, .aui-root textarea::-moz-placeholder{opacity:1;color:#cbd5e0}.aui-root input:-ms-input-placeholder, .aui-root textarea:-ms-input-placeholder{opacity:1;color:#cbd5e0}.aui-root input::placeholder,.aui-root textarea::placeholder{opacity:1;color:#cbd5e0}.aui-root button{cursor:pointer}.aui-root table{border-collapse:collapse}.aui-root h1,.aui-root h2,.aui-root h3,.aui-root h4,.aui-root h5,.aui-root h6{font-size:inherit;font-weight:inherit}.aui-root a{color:inherit;text-decoration:inherit}.aui-root button,.aui-root input,.aui-root optgroup,.aui-root select,.aui-root textarea{padding:0;line-height:inherit;color:inherit}.aui-root code,.aui-root kbd,.aui-root pre,.aui-root samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.aui-root audio,.aui-root canvas,.aui-root embed,.aui-root iframe,.aui-root img,.aui-root object,.aui-root svg,.aui-root video{display:block;vertical-align:middle}.aui-root img,.aui-root video{max-width:100%;height:auto}.aui-root [hidden]{display:none}.aui-root *,.aui-root :after,.aui-root :before{--tw-border-opacity:1;border-color:rgba(203,213,224,var(--tw-border-opacity))}.aui-root .prose{color:#4a5568;max-width:65ch}.aui-root .prose [class~=lead]{color:#718096;font-size:1.25em;line-height:1.6;margin-top:1.2em;margin-bottom:1.2em}.aui-root .prose a{color:#1a202c;text-decoration:underline;font-weight:500}.aui-root .prose strong{color:#1a202c;font-weight:600}.aui-root .prose ol[type=a]{--list-counter-style:lower-alpha}.aui-root .prose ol[type=i]{--list-counter-style:lower-roman}.aui-root .prose ol[type="1"]{--list-counter-style:decimal}.aui-root .prose ol>li{position:relative;padding-left:1.75em}.aui-root .prose ol>li:before{content:counter(list-item,var(--list-counter-style,decimal)) ".";position:absolute;font-weight:400;color:#a0aec0;left:0}.aui-root .prose ul>li{position:relative;padding-left:1.75em}.aui-root .prose ul>li:before{content:"";position:absolute;background-color:#e2e8f0;border-radius:50%;width:.375em;height:.375em;top:.6875em;left:.25em}.aui-root .prose hr{border-color:#edf2f7;border-top-width:1px;margin-top:3em;margin-bottom:3em}.aui-root .prose blockquote{font-weight:500;font-style:italic;color:#1a202c;border-left-width:.25rem;border-left-color:#edf2f7;quotes:"\201C""\201D""\2018""\2019";margin-top:1.6em;margin-bottom:1.6em;padding-left:1em}.aui-root .prose blockquote p:first-of-type:before{content:open-quote}.aui-root .prose blockquote p:last-of-type:after{content:close-quote}.aui-root .prose h1{color:#1a202c;font-weight:800;font-size:2.25em;margin-top:0;margin-bottom:.8888889em;line-height:1.1111111}.aui-root .prose h2{color:#1a202c;font-weight:700;font-size:1.5em;margin-top:2em;margin-bottom:1em;line-height:1.3333333}.aui-root .prose h3{color:#1a202c;font-weight:600;font-size:1.25em;margin-top:1.6em;margin-bottom:.6em;line-height:1.6}.aui-root .prose h4{color:#1a202c;font-weight:600;margin-top:1.5em;margin-bottom:.5em;line-height:1.5}.aui-root .prose figure figcaption{color:#a0aec0;font-size:.875em;line-height:1.4285714;margin-top:.8571429em}.aui-root .prose code{color:#1a202c;font-weight:600;font-size:.875em}.aui-root .prose code:after,.aui-root .prose code:before{content:"`"}.aui-root .prose a code{color:#1a202c}.aui-root .prose pre{color:#edf2f7;background-color:#1a202c;overflow-x:auto;font-size:.875em;line-height:1.7142857;margin-top:1.7142857em;margin-bottom:1.7142857em;border-radius:.375rem;padding:.8571429em 1.1428571em}.aui-root .prose pre code{background-color:transparent;border-width:0;border-radius:0;padding:0;font-weight:400;color:inherit;font-size:inherit;font-family:inherit;line-height:inherit}.aui-root .prose pre code:after,.aui-root .prose pre code:before{content:none}.aui-root .prose table{width:100%;table-layout:auto;text-align:left;margin-top:2em;margin-bottom:2em;font-size:.875em;line-height:1.7142857}.aui-root .prose thead{color:#1a202c;font-weight:600;border-bottom-width:1px;border-bottom-color:#e2e8f0}.aui-root .prose thead th{vertical-align:bottom;padding-right:.5714286em;padding-bottom:.5714286em;padding-left:.5714286em}.aui-root .prose tbody tr{border-bottom-width:1px;border-bottom-color:#edf2f7}.aui-root .prose tbody tr:last-child{border-bottom-width:0}.aui-root .prose tbody td{vertical-align:top;padding:.5714286em}.aui-root .prose{font-size:1rem;line-height:1.75}.aui-root .prose p{margin-top:1.25em;margin-bottom:1.25em}.aui-root .prose figure,.aui-root .prose img,.aui-root .prose video{margin-top:2em;margin-bottom:2em}.aui-root .prose figure>*{margin-top:0;margin-bottom:0}.aui-root .prose h2 code{font-size:.875em}.aui-root .prose h3 code{font-size:.9em}.aui-root .prose ol,.aui-root .prose ul{margin-top:1.25em;margin-bottom:1.25em}.aui-root .prose li{margin-top:.5em;margin-bottom:.5em}.aui-root .prose>ul>li p{margin-top:.75em;margin-bottom:.75em}.aui-root .prose>ul>li>:first-child{margin-top:1.25em}.aui-root .prose>ul>li>:last-child{margin-bottom:1.25em}.aui-root .prose>ol>li>:first-child{margin-top:1.25em}.aui-root .prose>ol>li>:last-child{margin-bottom:1.25em}.aui-root .prose ol ol,.aui-root .prose ol ul,.aui-root .prose ul ol,.aui-root .prose ul ul{margin-top:.75em;margin-bottom:.75em}.aui-root .prose h2+*,.aui-root .prose h3+*,.aui-root .prose h4+*,.aui-root .prose hr+*{margin-top:0}.aui-root .prose thead th:first-child{padding-left:0}.aui-root .prose thead th:last-child{padding-right:0}.aui-root .prose tbody td:first-child{padding-left:0}.aui-root .prose tbody td:last-child{padding-right:0}.aui-root .prose>:first-child{margin-top:0}.aui-root .prose>:last-child{margin-bottom:0}@media (min-width:1024px){.aui-root .container\:base .burger-menu{display:none}}@media (min-width:1024px){.aui-root .container\:base .sidebar{position:relative;display:block;height:auto;width:16rem}}@media (min-width:1024px){.aui-root .container\:base .sidebar--content{width:14rem}}.aui-root .container\:xl .sidebar--content{position:absolute;left:50%;transform:translate(-50%)}@media (min-width:1536px){.aui-root .container\:base .panel-item{display:flex}}.aui-root .container\:xl .panel-item{display:block}@media (min-width:1536px){.aui-root .container\:base .panel--center .panel-item--center{width:58.333333%}}@media (min-width:1536px){.aui-root .container\:base .panel--center .panel-item--right{width:41.666667%}}.aui-root .container\:xl .panel--center .panel-item--center,.aui-root .container\:xl .panel--center .panel-item--right{width:100%}@media (min-width:1536px){.aui-root .container\:base .examples{margin-top:0;padding:0}}.aui-root .container\:base .panel--right{display:none}@media (min-width:1536px){.aui-root .container\:base .panel--right{display:block;width:41.666667%}}.aui-root .container\:xl .panel--right{display:none}.aui-root .prose pre{white-space:pre-wrap}.aui-root .fixed{position:fixed}.aui-root .absolute{position:absolute}.aui-root .relative{position:relative}.aui-root .top-0{top:0}.aui-root .right-0{right:0}.aui-root .right-8{right:2rem}.aui-root .bottom-16{bottom:4rem}.aui-root .z-10{z-index:10}.aui-root .z-20{z-index:20}.aui-root .z-30{z-index:30}.aui-root .mx-2{margin-left:.5rem;margin-right:.5rem}.aui-root .-mx-8{margin-left:-2rem;margin-right:-2rem}.aui-root .my-2{margin-top:.5rem;margin-bottom:.5rem}.aui-root .mt-1{margin-top:.25rem}.aui-root .mt-2{margin-top:.5rem}.aui-root .mt-4{margin-top:1rem}.aui-root .mt-9{margin-top:2.25rem}.aui-root .mt-10{margin-top:2.5rem}.aui-root .mt-16{margin-top:4rem}.aui-root .mr-1{margin-right:.25rem}.aui-root .mr-2{margin-right:.5rem}.aui-root .mb-2{margin-bottom:.5rem}.aui-root .mb-3{margin-bottom:.75rem}.aui-root .mb-4{margin-bottom:1rem}.aui-root .mb-12{margin-bottom:3rem}.aui-root .-mb-1{margin-bottom:-.25rem}.aui-root .ml-0{margin-left:0}.aui-root .ml-1{margin-left:.25rem}.aui-root .ml-2{margin-left:.5rem}.aui-root .ml-0\.5{margin-left:.125rem}.aui-root .block{display:block}.aui-root .inline-block{display:inline-block}.aui-root .flex{display:flex}.aui-root .table{display:table}.aui-root .hidden{display:none}.aui-root .h-5{height:1.25rem}.aui-root .h-6{height:1.5rem}.aui-root .h-16{height:4rem}.aui-root .h-full{height:100%}.aui-root .max-h-screen{max-height:100vh}.aui-root .w-5{width:1.25rem}.aui-root .w-16{width:4rem}.aui-root .w-20{width:5rem}.aui-root .w-64{width:16rem}.aui-root .w-full{width:100%}.aui-root .min-w-1\/4{min-width:25%}.aui-root .max-w-none{max-width:none}.aui-root .flex-1{flex:1 1 0%}.aui-root .transform{--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;transform:translateX(var(--tw-translate-x)) translateY(var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.aui-root .-rotate-180{--tw-rotate:-180deg}.aui-root .-rotate-90{--tw-rotate:-90deg}@-webkit-keyframes spin{to{transform:rotate(1turn)}}@keyframes spin{to{transform:rotate(1turn)}}@-webkit-keyframes ping{75%,to{transform:scale(2);opacity:0}}@keyframes ping{75%,to{transform:scale(2);opacity:0}}@-webkit-keyframes pulse{50%{opacity:.5}}@keyframes pulse{50%{opacity:.5}}@-webkit-keyframes bounce{0%,to{transform:translateY(-25%);-webkit-animation-timing-function:cubic-bezier(.8,0,1,1);animation-timing-function:cubic-bezier(.8,0,1,1)}50%{transform:none;-webkit-animation-timing-function:cubic-bezier(0,0,.2,1);animation-timing-function:cubic-bezier(0,0,.2,1)}}@keyframes bounce{0%,to{transform:translateY(-25%);-webkit-animation-timing-function:cubic-bezier(.8,0,1,1);animation-timing-function:cubic-bezier(.8,0,1,1)}50%{transform:none;-webkit-animation-timing-function:cubic-bezier(0,0,.2,1);animation-timing-function:cubic-bezier(0,0,.2,1)}}.aui-root .cursor-pointer{cursor:pointer}.aui-root .flex-wrap{flex-wrap:wrap}.aui-root .items-center{align-items:center}.aui-root .justify-center{justify-content:center}.aui-root .space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-right:calc(0.5rem*var(--tw-space-x-reverse));margin-left:calc(0.5rem*(1 - var(--tw-space-x-reverse)))}.aui-root .space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-top:calc(0.5rem*(1 - var(--tw-space-y-reverse)));margin-bottom:calc(0.5rem*var(--tw-space-y-reverse))}.aui-root .overflow-auto{overflow:auto}.aui-root .overflow-y-auto{overflow-y:auto}.aui-root .whitespace-pre-wrap{white-space:pre-wrap}.aui-root .break-words{overflow-wrap:break-word}.aui-root .break-all{word-break:break-all}.aui-root .rounded{border-radius:.25rem}.aui-root .rounded-full{border-radius:9999px}.aui-root .border{border-width:1px}.aui-root .border-l-8{border-left-width:8px}.aui-root .border-solid{border-style:solid}.aui-root .border-gray-400{--tw-border-opacity:1;border-color:rgba(203,213,224,var(--tw-border-opacity))}.aui-root .border-red-500{--tw-border-opacity:1;border-color:rgba(245,101,101,var(--tw-border-opacity))}.aui-root .border-orange-300{--tw-border-opacity:1;border-color:rgba(251,211,141,var(--tw-border-opacity))}.aui-root .border-green-600{--tw-border-opacity:1;border-color:rgba(56,161,105,var(--tw-border-opacity))}.aui-root .border-blue-300{--tw-border-opacity:1;border-color:rgba(144,205,244,var(--tw-border-opacity))}.aui-root .border-blue-600{--tw-border-opacity:1;border-color:rgba(49,130,206,var(--tw-border-opacity))}.aui-root .border-purple-300{--tw-border-opacity:1;border-color:rgba(214,188,250,var(--tw-border-opacity))}.aui-root .bg-white{--tw-bg-opacity:1;background-color:rgba(255,255,255,var(--tw-bg-opacity))}.aui-root .bg-gray-100{--tw-bg-opacity:1;background-color:rgba(247,250,252,var(--tw-bg-opacity))}.aui-root .bg-gray-200{--tw-bg-opacity:1;background-color:rgba(237,242,247,var(--tw-bg-opacity))}.aui-root .bg-gray-800{--tw-bg-opacity:1;background-color:rgba(45,55,72,var(--tw-bg-opacity))}.aui-root .bg-yellow-600{--tw-bg-opacity:1;background-color:rgba(214,158,46,var(--tw-bg-opacity))}.aui-root .bg-green-600{--tw-bg-opacity:1;background-color:rgba(56,161,105,var(--tw-bg-opacity))}.aui-root .bg-teal-500{--tw-bg-opacity:1;background-color:rgba(56,178,172,var(--tw-bg-opacity))}.aui-root .bg-blue-400{--tw-bg-opacity:1;background-color:rgba(99,179,237,var(--tw-bg-opacity))}.aui-root .bg-blue-500{--tw-bg-opacity:1;background-color:rgba(66,153,225,var(--tw-bg-opacity))}.aui-root .bg-blue-600{--tw-bg-opacity:1;background-color:rgba(49,130,206,var(--tw-bg-opacity))}.aui-root .bg-indigo-400{--tw-bg-opacity:1;background-color:rgba(127,156,245,var(--tw-bg-opacity))}.aui-root .bg-purple-600{--tw-bg-opacity:1;background-color:rgba(128,90,213,var(--tw-bg-opacity))}.aui-root .hover\:bg-orange-300:hover{--tw-bg-opacity:1;background-color:rgba(251,211,141,var(--tw-bg-opacity))}.aui-root .hover\:bg-blue-300:hover{--tw-bg-opacity:1;background-color:rgba(144,205,244,var(--tw-bg-opacity))}.aui-root .hover\:bg-purple-300:hover{--tw-bg-opacity:1;background-color:rgba(214,188,250,var(--tw-bg-opacity))}.aui-root .fill-current{fill:currentColor}.aui-root .p-1{padding:.25rem}.aui-root .p-2{padding:.5rem}.aui-root .p-4{padding:1rem}.aui-root .p-8{padding:2rem}.aui-root .px-1{padding-left:.25rem;padding-right:.25rem}.aui-root .px-2{padding-left:.5rem;padding-right:.5rem}.aui-root .px-3{padding-left:.75rem;padding-right:.75rem}.aui-root .px-4{padding-left:1rem;padding-right:1rem}.aui-root .px-8{padding-left:2rem;padding-right:2rem}.aui-root .py-0{padding-top:0;padding-bottom:0}.aui-root .py-1{padding-top:.25rem;padding-bottom:.25rem}.aui-root .py-2{padding-top:.5rem;padding-bottom:.5rem}.aui-root .py-4{padding-top:1rem;padding-bottom:1rem}.aui-root .py-8{padding-top:2rem;padding-bottom:2rem}.aui-root .py-0\.5{padding-top:.125rem;padding-bottom:.125rem}.aui-root .pt-8{padding-top:2rem}.aui-root .pb-16{padding-bottom:4rem}.aui-root .text-left{text-align:left}.aui-root .text-center{text-align:center}.aui-root .align-baseline{vertical-align:baseline}.aui-root .font-sans{font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji}.aui-root .font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.aui-root .text-xs{font-size:.75rem}.aui-root .text-sm{font-size:.875rem}.aui-root .text-base{font-size:1rem}.aui-root .text-lg{font-size:1.125rem}.aui-root .text-2xl{font-size:1.5rem}.aui-root .text-3xl{font-size:1.875rem}.aui-root .text-4xl{font-size:2.25rem}.aui-root .font-thin{font-weight:100}.aui-root .font-extralight{font-weight:200}.aui-root .font-light{font-weight:300}.aui-root .font-bold{font-weight:700}.aui-root .uppercase{text-transform:uppercase}.aui-root .lowercase{text-transform:lowercase}.aui-root .capitalize{text-transform:capitalize}.aui-root .italic{font-style:italic}.aui-root .leading-normal{line-height:1.5}.aui-root .text-white{--tw-text-opacity:1;color:rgba(255,255,255,var(--tw-text-opacity))}.aui-root .text-gray-200{--tw-text-opacity:1;color:rgba(237,242,247,var(--tw-text-opacity))}.aui-root .text-gray-500{--tw-text-opacity:1;color:rgba(160,174,192,var(--tw-text-opacity))}.aui-root .text-gray-600{--tw-text-opacity:1;color:rgba(113,128,150,var(--tw-text-opacity))}.aui-root .text-gray-700{--tw-text-opacity:1;color:rgba(74,85,104,var(--tw-text-opacity))}.aui-root .text-gray-800{--tw-text-opacity:1;color:rgba(45,55,72,var(--tw-text-opacity))}.aui-root .text-red-600{--tw-text-opacity:1;color:rgba(229,62,62,var(--tw-text-opacity))}.aui-root .text-orange-500{--tw-text-opacity:1;color:rgba(237,137,54,var(--tw-text-opacity))}.aui-root .text-orange-600{--tw-text-opacity:1;color:rgba(221,107,32,var(--tw-text-opacity))}.aui-root .text-green-600{--tw-text-opacity:1;color:rgba(56,161,105,var(--tw-text-opacity))}.aui-root .text-teal-500{--tw-text-opacity:1;color:rgba(56,178,172,var(--tw-text-opacity))}.aui-root .text-blue-500{--tw-text-opacity:1;color:rgba(66,153,225,var(--tw-text-opacity))}.aui-root .text-purple-500{--tw-text-opacity:1;color:rgba(159,122,234,var(--tw-text-opacity))}.aui-root .hover\:text-gray-900:hover{--tw-text-opacity:1;color:rgba(26,32,44,var(--tw-text-opacity))}.aui-root .hover\:text-orange-600:hover{--tw-text-opacity:1;color:rgba(221,107,32,var(--tw-text-opacity))}.aui-root .hover\:text-blue-600:hover{--tw-text-opacity:1;color:rgba(49,130,206,var(--tw-text-opacity))}.aui-root .hover\:text-purple-600:hover{--tw-text-opacity:1;color:rgba(128,90,213,var(--tw-text-opacity))}.aui-root .underline{text-decoration:underline}.aui-root .no-underline{text-decoration:none}.aui-root *,.aui-root :after,.aui-root :before{--tw-shadow:0 0 transparent}.aui-root .shadow{--tw-shadow:0 1px 3px 0 rgba(0,0,0,0.1),0 1px 2px 0 rgba(0,0,0,0.06)}.aui-root .shadow,.aui-root .shadow-md{box-shadow:var(--tw-ring-offset-shadow,0 0 transparent),var(--tw-ring-shadow,0 0 transparent),var(--tw-shadow)}.aui-root .shadow-md{--tw-shadow:0 4px 6px -1px rgba(0,0,0,0.1),0 2px 4px -1px rgba(0,0,0,0.06)}.aui-root .focus\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.aui-root *,.aui-root :after,.aui-root :before{--tw-ring-inset:var(--tw-empty,/*!*/ /*!*/);--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(66,153,225,0.5);--tw-ring-offset-shadow:0 0 transparent;--tw-ring-shadow:0 0 transparent}.aui-root .filter{--tw-blur:var(--tw-empty,/*!*/ /*!*/);--tw-brightness:var(--tw-empty,/*!*/ /*!*/);--tw-contrast:var(--tw-empty,/*!*/ /*!*/);--tw-grayscale:var(--tw-empty,/*!*/ /*!*/);--tw-hue-rotate:var(--tw-empty,/*!*/ /*!*/);--tw-invert:var(--tw-empty,/*!*/ /*!*/);--tw-saturate:var(--tw-empty,/*!*/ /*!*/);--tw-sepia:var(--tw-empty,/*!*/ /*!*/);--tw-drop-shadow:var(--tw-empty,/*!*/ /*!*/);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.aui-root .transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.aui-root .duration-150{transition-duration:.15s}.aui-root .ease-linear{transition-timing-function:linear}.aui-root .break-anywhere{overflow-wrap:anywhere}@media (min-width:768px){.aui-root .md\:flex{display:flex}}@media (min-width:1536px){.aui-root .\32xl\:mx-0{margin-left:0;margin-right:0}.aui-root .\32xl\:w-7\/12{width:58.333333%}.aui-root .\32xl\:rounded{border-radius:.25rem}.aui-root .\32xl\:px-4{padding-left:1rem;padding-right:1rem}}
|
|
5
|
+
/*! modern-normalize v1.1.0 | MIT License | https://github.com/sindresorhus/modern-normalize */.aui-root html{-moz-tab-size:4;-o-tab-size:4;tab-size:4;line-height:1.15;-webkit-text-size-adjust:100%}.aui-root body{margin:0;font-family:system-ui,-apple-system,Segoe UI,Roboto,Helvetica,Arial,sans-serif,Apple Color Emoji,Segoe UI Emoji}.aui-root hr{height:0;color:inherit}.aui-root abbr[title]{-webkit-text-decoration:underline dotted;text-decoration:underline dotted}.aui-root b,.aui-root strong{font-weight:bolder}.aui-root code,.aui-root kbd,.aui-root pre,.aui-root samp{font-family:ui-monospace,SFMono-Regular,Consolas,Liberation Mono,Menlo,monospace;font-size:1em}.aui-root small{font-size:80%}.aui-root sub,.aui-root sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}.aui-root sub{bottom:-.25em}.aui-root sup{top:-.5em}.aui-root table{text-indent:0;border-color:inherit}.aui-root button,.aui-root input,.aui-root optgroup,.aui-root select,.aui-root textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0}.aui-root button,.aui-root select{text-transform:none}.aui-root [type=button],.aui-root button{-webkit-appearance:button}.aui-root ::-moz-focus-inner{border-style:none;padding:0}.aui-root legend{padding:0}.aui-root progress{vertical-align:baseline}.aui-root ::-webkit-inner-spin-button,.aui-root ::-webkit-outer-spin-button{height:auto}.aui-root [type=search]{-webkit-appearance:textfield;outline-offset:-2px}.aui-root ::-webkit-search-decoration{-webkit-appearance:none}.aui-root ::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}.aui-root summary{display:list-item}.aui-root blockquote,.aui-root dd,.aui-root dl,.aui-root figure,.aui-root h1,.aui-root h2,.aui-root h3,.aui-root h4,.aui-root h5,.aui-root h6,.aui-root hr,.aui-root p,.aui-root pre{margin:0}.aui-root button{background-color:transparent;background-image:none}.aui-root fieldset{margin:0;padding:0}.aui-root ol,.aui-root ul{list-style:none;margin:0;padding:0}.aui-root html{font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5}.aui-root body{font-family:inherit;line-height:inherit}.aui-root *,.aui-root :after,.aui-root :before{box-sizing:border-box;border:0 solid}.aui-root hr{border-top-width:1px}.aui-root img{border-style:solid}.aui-root textarea{resize:vertical}.aui-root input::-moz-placeholder, .aui-root textarea::-moz-placeholder{opacity:1;color:#cbd5e0}.aui-root input::placeholder,.aui-root textarea::placeholder{opacity:1;color:#cbd5e0}.aui-root button{cursor:pointer}.aui-root table{border-collapse:collapse}.aui-root h1,.aui-root h2,.aui-root h3,.aui-root h4,.aui-root h5,.aui-root h6{font-size:inherit;font-weight:inherit}.aui-root a{color:inherit;text-decoration:inherit}.aui-root button,.aui-root input,.aui-root optgroup,.aui-root select,.aui-root textarea{padding:0;line-height:inherit;color:inherit}.aui-root code,.aui-root kbd,.aui-root pre,.aui-root samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.aui-root audio,.aui-root canvas,.aui-root embed,.aui-root iframe,.aui-root img,.aui-root object,.aui-root svg,.aui-root video{display:block;vertical-align:middle}.aui-root img,.aui-root video{max-width:100%;height:auto}.aui-root [hidden]{display:none}.aui-root *,.aui-root :after,.aui-root :before{--tw-border-opacity:1;border-color:rgba(203,213,224,var(--tw-border-opacity))}.aui-root .container{width:100%}@media (min-width:640px){.aui-root .container{max-width:640px}}@media (min-width:768px){.aui-root .container{max-width:768px}}@media (min-width:1024px){.aui-root .container{max-width:1024px}}@media (min-width:1280px){.aui-root .container{max-width:1280px}}@media (min-width:1536px){.aui-root .container{max-width:1536px}}.aui-root .prose{color:#4a5568;max-width:65ch}.aui-root .prose [class~=lead]{color:#718096;font-size:1.25em;line-height:1.6;margin-top:1.2em;margin-bottom:1.2em}.aui-root .prose a{color:#1a202c;text-decoration:underline;font-weight:500}.aui-root .prose strong{color:#1a202c;font-weight:600}.aui-root .prose ol[type=a]{--list-counter-style:lower-alpha}.aui-root .prose ol[type=i]{--list-counter-style:lower-roman}.aui-root .prose ol[type="1"]{--list-counter-style:decimal}.aui-root .prose ol>li{position:relative;padding-left:1.75em}.aui-root .prose ol>li:before{content:counter(list-item,var(--list-counter-style,decimal)) ".";position:absolute;font-weight:400;color:#a0aec0;left:0}.aui-root .prose ul>li{position:relative;padding-left:1.75em}.aui-root .prose ul>li:before{content:"";position:absolute;background-color:#e2e8f0;border-radius:50%;width:.375em;height:.375em;top:.6875em;left:.25em}.aui-root .prose hr{border-color:#edf2f7;border-top-width:1px;margin-top:3em;margin-bottom:3em}.aui-root .prose blockquote{font-weight:500;font-style:italic;color:#1a202c;border-left-width:.25rem;border-left-color:#edf2f7;quotes:"\201C""\201D""\2018""\2019";margin-top:1.6em;margin-bottom:1.6em;padding-left:1em}.aui-root .prose blockquote p:first-of-type:before{content:open-quote}.aui-root .prose blockquote p:last-of-type:after{content:close-quote}.aui-root .prose h1{color:#1a202c;font-weight:800;font-size:2.25em;margin-top:0;margin-bottom:.8888889em;line-height:1.1111111}.aui-root .prose h2{color:#1a202c;font-weight:700;font-size:1.5em;margin-top:2em;margin-bottom:1em;line-height:1.3333333}.aui-root .prose h3{color:#1a202c;font-weight:600;font-size:1.25em;margin-top:1.6em;margin-bottom:.6em;line-height:1.6}.aui-root .prose h4{color:#1a202c;font-weight:600;margin-top:1.5em;margin-bottom:.5em;line-height:1.5}.aui-root .prose figure figcaption{color:#a0aec0;font-size:.875em;line-height:1.4285714;margin-top:.8571429em}.aui-root .prose code{color:#1a202c;font-weight:600;font-size:.875em}.aui-root .prose code:after,.aui-root .prose code:before{content:"`"}.aui-root .prose a code{color:#1a202c}.aui-root .prose pre{color:#edf2f7;background-color:#1a202c;overflow-x:auto;font-size:.875em;line-height:1.7142857;margin-top:1.7142857em;margin-bottom:1.7142857em;border-radius:.375rem;padding:.8571429em 1.1428571em}.aui-root .prose pre code{background-color:transparent;border-width:0;border-radius:0;padding:0;font-weight:400;color:inherit;font-size:inherit;font-family:inherit;line-height:inherit}.aui-root .prose pre code:after,.aui-root .prose pre code:before{content:none}.aui-root .prose table{width:100%;table-layout:auto;text-align:left;margin-top:2em;margin-bottom:2em;font-size:.875em;line-height:1.7142857}.aui-root .prose thead{color:#1a202c;font-weight:600;border-bottom-width:1px;border-bottom-color:#e2e8f0}.aui-root .prose thead th{vertical-align:bottom;padding-right:.5714286em;padding-bottom:.5714286em;padding-left:.5714286em}.aui-root .prose tbody tr{border-bottom-width:1px;border-bottom-color:#edf2f7}.aui-root .prose tbody tr:last-child{border-bottom-width:0}.aui-root .prose tbody td{vertical-align:top;padding:.5714286em}.aui-root .prose{font-size:1rem;line-height:1.75}.aui-root .prose p{margin-top:1.25em;margin-bottom:1.25em}.aui-root .prose figure,.aui-root .prose img,.aui-root .prose video{margin-top:2em;margin-bottom:2em}.aui-root .prose figure>*{margin-top:0;margin-bottom:0}.aui-root .prose h2 code{font-size:.875em}.aui-root .prose h3 code{font-size:.9em}.aui-root .prose ol,.aui-root .prose ul{margin-top:1.25em;margin-bottom:1.25em}.aui-root .prose li{margin-top:.5em;margin-bottom:.5em}.aui-root .prose>ul>li p{margin-top:.75em;margin-bottom:.75em}.aui-root .prose>ul>li>:first-child{margin-top:1.25em}.aui-root .prose>ul>li>:last-child{margin-bottom:1.25em}.aui-root .prose>ol>li>:first-child{margin-top:1.25em}.aui-root .prose>ol>li>:last-child{margin-bottom:1.25em}.aui-root .prose ol ol,.aui-root .prose ol ul,.aui-root .prose ul ol,.aui-root .prose ul ul{margin-top:.75em;margin-bottom:.75em}.aui-root .prose h2+*,.aui-root .prose h3+*,.aui-root .prose h4+*,.aui-root .prose hr+*{margin-top:0}.aui-root .prose thead th:first-child{padding-left:0}.aui-root .prose thead th:last-child{padding-right:0}.aui-root .prose tbody td:first-child{padding-left:0}.aui-root .prose tbody td:last-child{padding-right:0}.aui-root .prose>:first-child{margin-top:0}.aui-root .prose>:last-child{margin-bottom:0}@media (min-width:1024px){.aui-root .container\:base .burger-menu{display:none}}@media (min-width:1024px){.aui-root .container\:base .sidebar{position:relative;display:block;height:auto;width:16rem}}@media (min-width:1024px){.aui-root .container\:base .sidebar--content{width:14rem}}.aui-root .container\:xl .sidebar--content{position:absolute;left:50%;transform:translate(-50%)}@media (min-width:1536px){.aui-root .container\:base .panel-item{display:flex}}.aui-root .container\:xl .panel-item{display:block}@media (min-width:1536px){.aui-root .container\:base .panel--center .panel-item--center{width:58.333333%}}@media (min-width:1536px){.aui-root .container\:base .panel--center .panel-item--right{width:41.666667%}}.aui-root .container\:xl .panel--center .panel-item--center,.aui-root .container\:xl .panel--center .panel-item--right{width:100%}@media (min-width:1536px){.aui-root .container\:base .examples{margin-top:0;padding:0}}.aui-root .container\:base .panel--right{display:none}@media (min-width:1536px){.aui-root .container\:base .panel--right{display:block;width:41.666667%}}.aui-root .container\:xl .panel--right{display:none}.aui-root .prose pre{white-space:pre-wrap}.aui-root .fixed{position:fixed}.aui-root .absolute{position:absolute}.aui-root .relative{position:relative}.aui-root .top-0{top:0}.aui-root .right-0{right:0}.aui-root .right-8{right:2rem}.aui-root .bottom-16{bottom:4rem}.aui-root .z-10{z-index:10}.aui-root .z-20{z-index:20}.aui-root .z-30{z-index:30}.aui-root .mx-2{margin-left:.5rem;margin-right:.5rem}.aui-root .-mx-8{margin-left:-2rem;margin-right:-2rem}.aui-root .my-2{margin-top:.5rem;margin-bottom:.5rem}.aui-root .mt-1{margin-top:.25rem}.aui-root .mt-2{margin-top:.5rem}.aui-root .mt-4{margin-top:1rem}.aui-root .mt-9{margin-top:2.25rem}.aui-root .mt-10{margin-top:2.5rem}.aui-root .mt-16{margin-top:4rem}.aui-root .mr-1{margin-right:.25rem}.aui-root .mr-2{margin-right:.5rem}.aui-root .mb-2{margin-bottom:.5rem}.aui-root .mb-3{margin-bottom:.75rem}.aui-root .mb-4{margin-bottom:1rem}.aui-root .mb-12{margin-bottom:3rem}.aui-root .-mb-1{margin-bottom:-.25rem}.aui-root .ml-0{margin-left:0}.aui-root .ml-1{margin-left:.25rem}.aui-root .ml-2{margin-left:.5rem}.aui-root .ml-0\.5{margin-left:.125rem}.aui-root .block{display:block}.aui-root .inline-block{display:inline-block}.aui-root .flex{display:flex}.aui-root .table{display:table}.aui-root .hidden{display:none}.aui-root .h-5{height:1.25rem}.aui-root .h-6{height:1.5rem}.aui-root .h-16{height:4rem}.aui-root .h-full{height:100%}.aui-root .max-h-screen{max-height:100vh}.aui-root .w-5{width:1.25rem}.aui-root .w-16{width:4rem}.aui-root .w-20{width:5rem}.aui-root .w-64{width:16rem}.aui-root .w-full{width:100%}.aui-root .min-w-1\/4{min-width:25%}.aui-root .max-w-none{max-width:none}.aui-root .flex-1{flex:1 1 0%}.aui-root .transform{--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;transform:translateX(var(--tw-translate-x)) translateY(var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.aui-root .-rotate-180{--tw-rotate:-180deg}.aui-root .-rotate-90{--tw-rotate:-90deg}@keyframes spin{to{transform:rotate(1turn)}}@keyframes ping{75%,to{transform:scale(2);opacity:0}}@keyframes pulse{50%{opacity:.5}}@keyframes bounce{0%,to{transform:translateY(-25%);animation-timing-function:cubic-bezier(.8,0,1,1)}50%{transform:none;animation-timing-function:cubic-bezier(0,0,.2,1)}}.aui-root .cursor-pointer{cursor:pointer}.aui-root .flex-wrap{flex-wrap:wrap}.aui-root .items-center{align-items:center}.aui-root .justify-center{justify-content:center}.aui-root .space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-right:calc(0.5rem*var(--tw-space-x-reverse));margin-left:calc(0.5rem*(1 - var(--tw-space-x-reverse)))}.aui-root .space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-top:calc(0.5rem*(1 - var(--tw-space-y-reverse)));margin-bottom:calc(0.5rem*var(--tw-space-y-reverse))}.aui-root .overflow-auto{overflow:auto}.aui-root .overflow-y-auto{overflow-y:auto}.aui-root .whitespace-pre-wrap{white-space:pre-wrap}.aui-root .break-words{overflow-wrap:break-word}.aui-root .break-all{word-break:break-all}.aui-root .rounded{border-radius:.25rem}.aui-root .rounded-full{border-radius:9999px}.aui-root .border{border-width:1px}.aui-root .border-l-8{border-left-width:8px}.aui-root .border-solid{border-style:solid}.aui-root .border-gray-400{--tw-border-opacity:1;border-color:rgba(203,213,224,var(--tw-border-opacity))}.aui-root .border-red-500{--tw-border-opacity:1;border-color:rgba(245,101,101,var(--tw-border-opacity))}.aui-root .border-orange-300{--tw-border-opacity:1;border-color:rgba(251,211,141,var(--tw-border-opacity))}.aui-root .border-green-600{--tw-border-opacity:1;border-color:rgba(56,161,105,var(--tw-border-opacity))}.aui-root .border-blue-300{--tw-border-opacity:1;border-color:rgba(144,205,244,var(--tw-border-opacity))}.aui-root .border-blue-600{--tw-border-opacity:1;border-color:rgba(49,130,206,var(--tw-border-opacity))}.aui-root .border-purple-300{--tw-border-opacity:1;border-color:rgba(214,188,250,var(--tw-border-opacity))}.aui-root .bg-white{--tw-bg-opacity:1;background-color:rgba(255,255,255,var(--tw-bg-opacity))}.aui-root .bg-gray-100{--tw-bg-opacity:1;background-color:rgba(247,250,252,var(--tw-bg-opacity))}.aui-root .bg-gray-200{--tw-bg-opacity:1;background-color:rgba(237,242,247,var(--tw-bg-opacity))}.aui-root .bg-gray-800{--tw-bg-opacity:1;background-color:rgba(45,55,72,var(--tw-bg-opacity))}.aui-root .bg-yellow-600{--tw-bg-opacity:1;background-color:rgba(214,158,46,var(--tw-bg-opacity))}.aui-root .bg-green-600{--tw-bg-opacity:1;background-color:rgba(56,161,105,var(--tw-bg-opacity))}.aui-root .bg-teal-500{--tw-bg-opacity:1;background-color:rgba(56,178,172,var(--tw-bg-opacity))}.aui-root .bg-blue-400{--tw-bg-opacity:1;background-color:rgba(99,179,237,var(--tw-bg-opacity))}.aui-root .bg-blue-500{--tw-bg-opacity:1;background-color:rgba(66,153,225,var(--tw-bg-opacity))}.aui-root .bg-blue-600{--tw-bg-opacity:1;background-color:rgba(49,130,206,var(--tw-bg-opacity))}.aui-root .bg-indigo-400{--tw-bg-opacity:1;background-color:rgba(127,156,245,var(--tw-bg-opacity))}.aui-root .bg-purple-600{--tw-bg-opacity:1;background-color:rgba(128,90,213,var(--tw-bg-opacity))}.aui-root .hover\:bg-orange-300:hover{--tw-bg-opacity:1;background-color:rgba(251,211,141,var(--tw-bg-opacity))}.aui-root .hover\:bg-blue-300:hover{--tw-bg-opacity:1;background-color:rgba(144,205,244,var(--tw-bg-opacity))}.aui-root .hover\:bg-purple-300:hover{--tw-bg-opacity:1;background-color:rgba(214,188,250,var(--tw-bg-opacity))}.aui-root .fill-current{fill:currentColor}.aui-root .p-1{padding:.25rem}.aui-root .p-2{padding:.5rem}.aui-root .p-4{padding:1rem}.aui-root .p-8{padding:2rem}.aui-root .px-1{padding-left:.25rem;padding-right:.25rem}.aui-root .px-2{padding-left:.5rem;padding-right:.5rem}.aui-root .px-3{padding-left:.75rem;padding-right:.75rem}.aui-root .px-4{padding-left:1rem;padding-right:1rem}.aui-root .px-8{padding-left:2rem;padding-right:2rem}.aui-root .py-0{padding-top:0;padding-bottom:0}.aui-root .py-1{padding-top:.25rem;padding-bottom:.25rem}.aui-root .py-2{padding-top:.5rem;padding-bottom:.5rem}.aui-root .py-4{padding-top:1rem;padding-bottom:1rem}.aui-root .py-8{padding-top:2rem;padding-bottom:2rem}.aui-root .py-0\.5{padding-top:.125rem;padding-bottom:.125rem}.aui-root .pt-8{padding-top:2rem}.aui-root .pb-16{padding-bottom:4rem}.aui-root .text-left{text-align:left}.aui-root .text-center{text-align:center}.aui-root .align-baseline{vertical-align:baseline}.aui-root .font-sans{font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji}.aui-root .font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.aui-root .text-xs{font-size:.75rem}.aui-root .text-sm{font-size:.875rem}.aui-root .text-base{font-size:1rem}.aui-root .text-lg{font-size:1.125rem}.aui-root .text-2xl{font-size:1.5rem}.aui-root .text-3xl{font-size:1.875rem}.aui-root .text-4xl{font-size:2.25rem}.aui-root .font-thin{font-weight:100}.aui-root .font-extralight{font-weight:200}.aui-root .font-light{font-weight:300}.aui-root .font-bold{font-weight:700}.aui-root .uppercase{text-transform:uppercase}.aui-root .lowercase{text-transform:lowercase}.aui-root .capitalize{text-transform:capitalize}.aui-root .italic{font-style:italic}.aui-root .leading-normal{line-height:1.5}.aui-root .text-white{--tw-text-opacity:1;color:rgba(255,255,255,var(--tw-text-opacity))}.aui-root .text-gray-200{--tw-text-opacity:1;color:rgba(237,242,247,var(--tw-text-opacity))}.aui-root .text-gray-500{--tw-text-opacity:1;color:rgba(160,174,192,var(--tw-text-opacity))}.aui-root .text-gray-600{--tw-text-opacity:1;color:rgba(113,128,150,var(--tw-text-opacity))}.aui-root .text-gray-700{--tw-text-opacity:1;color:rgba(74,85,104,var(--tw-text-opacity))}.aui-root .text-gray-800{--tw-text-opacity:1;color:rgba(45,55,72,var(--tw-text-opacity))}.aui-root .text-red-600{--tw-text-opacity:1;color:rgba(229,62,62,var(--tw-text-opacity))}.aui-root .text-orange-500{--tw-text-opacity:1;color:rgba(237,137,54,var(--tw-text-opacity))}.aui-root .text-orange-600{--tw-text-opacity:1;color:rgba(221,107,32,var(--tw-text-opacity))}.aui-root .text-green-600{--tw-text-opacity:1;color:rgba(56,161,105,var(--tw-text-opacity))}.aui-root .text-teal-500{--tw-text-opacity:1;color:rgba(56,178,172,var(--tw-text-opacity))}.aui-root .text-blue-500{--tw-text-opacity:1;color:rgba(66,153,225,var(--tw-text-opacity))}.aui-root .text-purple-500{--tw-text-opacity:1;color:rgba(159,122,234,var(--tw-text-opacity))}.aui-root .hover\:text-gray-900:hover{--tw-text-opacity:1;color:rgba(26,32,44,var(--tw-text-opacity))}.aui-root .hover\:text-orange-600:hover{--tw-text-opacity:1;color:rgba(221,107,32,var(--tw-text-opacity))}.aui-root .hover\:text-blue-600:hover{--tw-text-opacity:1;color:rgba(49,130,206,var(--tw-text-opacity))}.aui-root .hover\:text-purple-600:hover{--tw-text-opacity:1;color:rgba(128,90,213,var(--tw-text-opacity))}.aui-root .underline{text-decoration:underline}.aui-root .no-underline{text-decoration:none}.aui-root *,.aui-root :after,.aui-root :before{--tw-shadow:0 0 transparent}.aui-root .shadow{--tw-shadow:0 1px 3px 0 rgba(0,0,0,0.1),0 1px 2px 0 rgba(0,0,0,0.06)}.aui-root .shadow,.aui-root .shadow-md{box-shadow:var(--tw-ring-offset-shadow,0 0 transparent),var(--tw-ring-shadow,0 0 transparent),var(--tw-shadow)}.aui-root .shadow-md{--tw-shadow:0 4px 6px -1px rgba(0,0,0,0.1),0 2px 4px -1px rgba(0,0,0,0.06)}.aui-root .focus\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.aui-root *,.aui-root :after,.aui-root :before{--tw-ring-inset:var(--tw-empty,/*!*/ /*!*/);--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(66,153,225,0.5);--tw-ring-offset-shadow:0 0 transparent;--tw-ring-shadow:0 0 transparent}.aui-root .filter{--tw-blur:var(--tw-empty,/*!*/ /*!*/);--tw-brightness:var(--tw-empty,/*!*/ /*!*/);--tw-contrast:var(--tw-empty,/*!*/ /*!*/);--tw-grayscale:var(--tw-empty,/*!*/ /*!*/);--tw-hue-rotate:var(--tw-empty,/*!*/ /*!*/);--tw-invert:var(--tw-empty,/*!*/ /*!*/);--tw-saturate:var(--tw-empty,/*!*/ /*!*/);--tw-sepia:var(--tw-empty,/*!*/ /*!*/);--tw-drop-shadow:var(--tw-empty,/*!*/ /*!*/);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.aui-root .transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.aui-root .duration-150{transition-duration:.15s}.aui-root .ease-linear{transition-timing-function:linear}.aui-root .break-anywhere{overflow-wrap:anywhere}@media (min-width:768px){.aui-root .md\:flex{display:flex}}@media (min-width:1536px){.aui-root .\32xl\:mx-0{margin-left:0;margin-right:0}.aui-root .\32xl\:w-7\/12{width:58.333333%}.aui-root .\32xl\:rounded{border-radius:.25rem}.aui-root .\32xl\:px-4{padding-left:1rem;padding-right:1rem}}
|