@mintlify/validation 0.1.31 → 0.1.33

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.
Files changed (32) hide show
  1. package/dist/index.d.ts +4 -4
  2. package/dist/index.js +1 -1
  3. package/dist/{schemas → mint-config/schemas}/anchorColors.d.ts +1 -1
  4. package/dist/{schemas → mint-config/schemas}/colors.d.ts +1 -1
  5. package/dist/mint-config/types/analytics.d.ts +3 -0
  6. package/dist/mint-config/types/anchors.d.ts +3 -0
  7. package/dist/mint-config/types/colors.d.ts +3 -0
  8. package/dist/mint-config/types/config.d.ts +3 -0
  9. package/dist/mint-config/types/versions.d.ts +3 -0
  10. package/dist/mint-config/validateAnchorsWarnings.d.ts +4 -0
  11. package/dist/{utils → mint-config}/validateVersionsInNavigation.d.ts +3 -3
  12. package/dist/{utils → openapi}/convertOpenApi.d.ts +1 -1
  13. package/dist/{types → openapi/types}/endpoint.d.ts +5 -2
  14. package/package.json +2 -2
  15. package/dist/types/analytics.d.ts +0 -3
  16. package/dist/types/anchors.d.ts +0 -3
  17. package/dist/types/colors.d.ts +0 -3
  18. package/dist/types/config.d.ts +0 -3
  19. package/dist/types/versions.d.ts +0 -3
  20. package/dist/utils/validateAnchorsWarnings.d.ts +0 -4
  21. /package/dist/{utils → mint-config}/common.d.ts +0 -0
  22. /package/dist/{utils → mint-config}/flattenUnionErrorMessages.d.ts +0 -0
  23. /package/dist/{utils → mint-config}/hexadecimalPattern.d.ts +0 -0
  24. /package/dist/{schemas → mint-config/schemas}/analytics.d.ts +0 -0
  25. /package/dist/{schemas → mint-config/schemas}/anchors.d.ts +0 -0
  26. /package/dist/{schemas → mint-config/schemas}/config.d.ts +0 -0
  27. /package/dist/{schemas → mint-config/schemas}/favicon.d.ts +0 -0
  28. /package/dist/{schemas → mint-config/schemas}/name.d.ts +0 -0
  29. /package/dist/{schemas → mint-config/schemas}/navigation.d.ts +0 -0
  30. /package/dist/{schemas → mint-config/schemas}/tabs.d.ts +0 -0
  31. /package/dist/{schemas → mint-config/schemas}/versions.d.ts +0 -0
  32. /package/dist/{types → mint-config/types}/navigation.d.ts +0 -0
@@ -1,4 +1,4 @@
1
- import { z } from "zod";
1
+ import { z } from 'zod';
2
2
  export declare const anchorColorSchema: z.ZodUnion<[z.ZodString, z.ZodObject<{
3
3
  from: z.ZodString;
4
4
  via: z.ZodOptional<z.ZodString>;
@@ -1,4 +1,4 @@
1
- import { z } from "zod";
1
+ import { z } from 'zod';
2
2
  export declare const colorsSchema: z.ZodObject<{
3
3
  primary: z.ZodString;
4
4
  light: z.ZodOptional<z.ZodString>;
@@ -0,0 +1,3 @@
1
+ import { z } from 'zod';
2
+ import { analyticsSchema } from '../schemas/analytics';
3
+ export type AnalyticsType = z.infer<typeof analyticsSchema>;
@@ -0,0 +1,3 @@
1
+ import { z } from 'zod';
2
+ import { anchorsSchema } from '../schemas/anchors';
3
+ export type AnchorsType = z.infer<typeof anchorsSchema>;
@@ -0,0 +1,3 @@
1
+ import { z } from 'zod';
2
+ import { colorsSchema } from '../schemas/colors';
3
+ export type ColorsType = z.infer<typeof colorsSchema>;
@@ -0,0 +1,3 @@
1
+ import { z } from 'zod';
2
+ import { configSchema } from '../schemas/config';
3
+ export type ConfigType = z.infer<typeof configSchema>;
@@ -0,0 +1,3 @@
1
+ import { z } from 'zod';
2
+ import { versionsSchema } from '../schemas/versions';
3
+ export type VersionsType = z.infer<typeof versionsSchema>;
@@ -0,0 +1,4 @@
1
+ import { MintValidationResults } from './common';
2
+ import { AnchorsType } from './types/anchors';
3
+ import { NavigationType } from './types/navigation';
4
+ export declare function validateAnchorsWarnings(anchors: AnchorsType | undefined, navigation: NavigationType[] | undefined): MintValidationResults;
@@ -1,5 +1,5 @@
1
- import { NavigationEntry, NavigationType } from "../types/navigation";
2
- import { VersionsType } from "../types/versions";
3
- import { MintValidationResults } from "./common";
1
+ import { MintValidationResults } from './common';
2
+ import { NavigationEntry, NavigationType } from './types/navigation';
3
+ import { VersionsType } from './types/versions';
4
4
  export declare function flattenNavigationVersions(nav: NavigationEntry[], versions?: string[]): string[];
5
5
  export declare function validateVersionsInNavigation(navigation: NavigationType[] | undefined, versions?: VersionsType | undefined): MintValidationResults;
@@ -1,5 +1,5 @@
1
1
  import { OpenAPIV3_1 } from 'openapi-types';
2
- import type { BodySchema, DataSchemaArray, Endpoint, HttpMethod, ParameterSections, ResponseSchema, SecurityOption, Server } from '../types/endpoint';
2
+ import type { BodySchema, DataSchemaArray, Endpoint, HttpMethod, ParameterSections, ResponseSchema, SecurityOption, Server } from './types/endpoint';
3
3
  export declare class InvalidSchemaError extends Error {
4
4
  constructor(message?: string);
5
5
  }
@@ -63,9 +63,9 @@ export type ResponseSchema = {
63
63
  [code: string]: BodySchema;
64
64
  };
65
65
  export type DataSchemaArray = [DataSchema, ...DataSchema[]];
66
- export declare const typeList: readonly ["boolean", "string", "number", "integer", "object", "array", "stringEnum", "numberEnum", "integerEnum", "null"];
66
+ export declare const typeList: readonly ["boolean", "string", "number", "integer", "object", "array", "stringEnum", "numberEnum", "integerEnum", "null", "any"];
67
67
  export type SchemaType = typeof typeList[number];
68
- export type DataSchema = BooleanSchema | StringSchema | NumberSchema | ObjectSchema | ArraySchema | StringEnumSchema | NumberEnumSchema | NullSchema;
68
+ export type DataSchema = BooleanSchema | StringSchema | NumberSchema | ObjectSchema | ArraySchema | StringEnumSchema | NumberEnumSchema | NullSchema | AnySchema;
69
69
  export type BaseSchema<T> = {
70
70
  type: SchemaType;
71
71
  title?: string;
@@ -122,4 +122,7 @@ export type NumberEnumSchema = {
122
122
  export type NullSchema = {
123
123
  type: 'null';
124
124
  } & BaseSchema<null>;
125
+ export type AnySchema = {
126
+ type: 'any';
127
+ } & BaseSchema<unknown>;
125
128
  export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mintlify/validation",
3
- "version": "0.1.31",
3
+ "version": "0.1.33",
4
4
  "description": "Validates mint.json files",
5
5
  "author": "Mintlify, Inc.",
6
6
  "repository": {
@@ -68,5 +68,5 @@
68
68
  "webpack": "^5.75.0",
69
69
  "webpack-cli": "^5.0.1"
70
70
  },
71
- "gitHead": "9a666a6dfb5214b9a2490ef11930354a3af3bb04"
71
+ "gitHead": "499c04a31113ecd31c5a72c1ad58f0cfdfeb25b7"
72
72
  }
@@ -1,3 +0,0 @@
1
- import { z } from "zod";
2
- import { analyticsSchema } from "../schemas/analytics";
3
- export type AnalyticsType = z.infer<typeof analyticsSchema>;
@@ -1,3 +0,0 @@
1
- import { z } from "zod";
2
- import { anchorsSchema } from "../schemas/anchors";
3
- export type AnchorsType = z.infer<typeof anchorsSchema>;
@@ -1,3 +0,0 @@
1
- import { z } from "zod";
2
- import { colorsSchema } from "../schemas/colors";
3
- export type ColorsType = z.infer<typeof colorsSchema>;
@@ -1,3 +0,0 @@
1
- import { z } from "zod";
2
- import { configSchema } from "../schemas/config";
3
- export type ConfigType = z.infer<typeof configSchema>;
@@ -1,3 +0,0 @@
1
- import { z } from "zod";
2
- import { versionsSchema } from "../schemas/versions";
3
- export type VersionsType = z.infer<typeof versionsSchema>;
@@ -1,4 +0,0 @@
1
- import { NavigationType } from "../types/navigation";
2
- import { AnchorsType } from "../types/anchors";
3
- import { MintValidationResults } from "./common";
4
- export declare function validateAnchorsWarnings(anchors: AnchorsType | undefined, navigation: NavigationType[] | undefined): MintValidationResults;
File without changes
File without changes
File without changes