@redocly/config
Advanced tools
Comparing version 0.11.0 to 0.12.0
@@ -80,3 +80,20 @@ import { redocConfigSchema } from './redoc-config-schema'; | ||
}; | ||
const suggestedPageSchema = { | ||
export const searchFacetsConfigSchema = { | ||
type: 'array', | ||
items: { | ||
type: 'object', | ||
required: ['name', 'field', 'type'], | ||
properties: { | ||
name: { type: 'string' }, | ||
field: { type: 'string' }, | ||
type: { | ||
type: 'string', | ||
enum: ['multi-select', 'select', 'tags'], | ||
}, | ||
isTop: { type: 'boolean' }, | ||
}, | ||
additionalProperties: false, | ||
}, | ||
}; | ||
const searchSuggestedPageSchema = { | ||
type: 'object', | ||
@@ -159,4 +176,8 @@ properties: { | ||
type: 'object', | ||
properties: Object.assign({ placement: { | ||
properties: Object.assign({ engine: { | ||
type: 'string', | ||
enum: ['flexsearch', 'typesense'], | ||
default: 'flexsearch', | ||
}, facets: searchFacetsConfigSchema, placement: { | ||
type: 'string', | ||
default: 'navbar', | ||
@@ -169,6 +190,3 @@ }, shortcuts: { | ||
type: 'array', | ||
items: suggestedPageSchema, | ||
}, fuzzy: { | ||
type: 'boolean', | ||
default: false, | ||
items: searchSuggestedPageSchema, | ||
} }, hideConfigSchema.properties), | ||
@@ -175,0 +193,0 @@ additionalProperties: false, |
@@ -7,3 +7,3 @@ import type { FromSchema } from 'json-schema-to-ts'; | ||
import type { GraphQLConfigTypes } from './graphql-types'; | ||
import type { productConfigSchema, productGoogleAnalyticsConfigSchema, markdownConfigSchema, amplitudeAnalyticsConfigSchema, rudderstackAnalyticsConfigSchema, segmentAnalyticsConfigSchema, gtmAnalyticsConfigSchema, googleAnalyticsConfigSchema, scorecardConfigSchema, catalogFilterSchema, catalogSchema } from './ex-theme-config-schemas'; | ||
import type { productConfigSchema, productGoogleAnalyticsConfigSchema, markdownConfigSchema, amplitudeAnalyticsConfigSchema, rudderstackAnalyticsConfigSchema, segmentAnalyticsConfigSchema, gtmAnalyticsConfigSchema, googleAnalyticsConfigSchema, scorecardConfigSchema, catalogFilterSchema, catalogSchema, searchFacetsConfigSchema } from './ex-theme-config-schemas'; | ||
/** | ||
@@ -28,2 +28,3 @@ * @deprecated left for backwards compatibility. To be removed in Realm 1.0 | ||
export type ScorecardConfig = FromSchema<typeof scorecardConfigSchema>; | ||
export type SearchFacetsConfig = FromSchema<typeof searchFacetsConfigSchema>; | ||
export type RedoclyConfig = Omit<FromSchema<typeof rootRedoclyConfigSchema>, 'theme' | 'apis'> & { | ||
@@ -30,0 +31,0 @@ /** |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.scorecardConfigSchema = exports.catalogsConfigSchema = exports.catalogSchema = exports.catalogFilterSchema = exports.breadcrumbsConfigSchema = exports.versionPickerConfigSchema = exports.userMenuConfigSchema = exports.analyticsConfigSchema = exports.googleAnalyticsConfigSchema = exports.productGoogleAnalyticsConfigSchema = exports.gtmAnalyticsConfigSchema = exports.segmentAnalyticsConfigSchema = exports.rudderstackAnalyticsConfigSchema = exports.heapAnalyticsConfigSchema = exports.fullstoryAnalyticsConfigSchema = exports.amplitudeAnalyticsConfigSchema = exports.openapiConfigSchema = exports.markdownConfigSchema = exports.codeSnippetConfigSchema = exports.navigationConfigSchema = exports.colorModeConfigSchema = exports.searchConfigSchema = exports.linksConfigSchema = exports.scriptsConfigSchema = exports.sidebarConfigSchema = exports.footerConfigSchema = exports.productsConfigSchema = exports.navbarConfigSchema = exports.logoConfigSchema = exports.productConfigSchema = exports.navItemsSchema = void 0; | ||
exports.scorecardConfigSchema = exports.catalogsConfigSchema = exports.catalogSchema = exports.catalogFilterSchema = exports.breadcrumbsConfigSchema = exports.versionPickerConfigSchema = exports.userMenuConfigSchema = exports.analyticsConfigSchema = exports.googleAnalyticsConfigSchema = exports.productGoogleAnalyticsConfigSchema = exports.gtmAnalyticsConfigSchema = exports.segmentAnalyticsConfigSchema = exports.rudderstackAnalyticsConfigSchema = exports.heapAnalyticsConfigSchema = exports.fullstoryAnalyticsConfigSchema = exports.amplitudeAnalyticsConfigSchema = exports.openapiConfigSchema = exports.markdownConfigSchema = exports.codeSnippetConfigSchema = exports.navigationConfigSchema = exports.colorModeConfigSchema = exports.searchConfigSchema = exports.linksConfigSchema = exports.scriptsConfigSchema = exports.sidebarConfigSchema = exports.footerConfigSchema = exports.productsConfigSchema = exports.navbarConfigSchema = exports.logoConfigSchema = exports.searchFacetsConfigSchema = exports.productConfigSchema = exports.navItemsSchema = void 0; | ||
const redoc_config_schema_1 = require("./redoc-config-schema"); | ||
@@ -83,3 +83,20 @@ const reference_docs_config_schema_1 = require("./reference-docs-config-schema"); | ||
}; | ||
const suggestedPageSchema = { | ||
exports.searchFacetsConfigSchema = { | ||
type: 'array', | ||
items: { | ||
type: 'object', | ||
required: ['name', 'field', 'type'], | ||
properties: { | ||
name: { type: 'string' }, | ||
field: { type: 'string' }, | ||
type: { | ||
type: 'string', | ||
enum: ['multi-select', 'select', 'tags'], | ||
}, | ||
isTop: { type: 'boolean' }, | ||
}, | ||
additionalProperties: false, | ||
}, | ||
}; | ||
const searchSuggestedPageSchema = { | ||
type: 'object', | ||
@@ -162,4 +179,8 @@ properties: { | ||
type: 'object', | ||
properties: Object.assign({ placement: { | ||
properties: Object.assign({ engine: { | ||
type: 'string', | ||
enum: ['flexsearch', 'typesense'], | ||
default: 'flexsearch', | ||
}, facets: exports.searchFacetsConfigSchema, placement: { | ||
type: 'string', | ||
default: 'navbar', | ||
@@ -172,6 +193,3 @@ }, shortcuts: { | ||
type: 'array', | ||
items: suggestedPageSchema, | ||
}, fuzzy: { | ||
type: 'boolean', | ||
default: false, | ||
items: searchSuggestedPageSchema, | ||
} }, hideConfigSchema.properties), | ||
@@ -178,0 +196,0 @@ additionalProperties: false, |
@@ -7,3 +7,3 @@ import type { FromSchema } from 'json-schema-to-ts'; | ||
import type { GraphQLConfigTypes } from './graphql-types'; | ||
import type { productConfigSchema, productGoogleAnalyticsConfigSchema, markdownConfigSchema, amplitudeAnalyticsConfigSchema, rudderstackAnalyticsConfigSchema, segmentAnalyticsConfigSchema, gtmAnalyticsConfigSchema, googleAnalyticsConfigSchema, scorecardConfigSchema, catalogFilterSchema, catalogSchema } from './ex-theme-config-schemas'; | ||
import type { productConfigSchema, productGoogleAnalyticsConfigSchema, markdownConfigSchema, amplitudeAnalyticsConfigSchema, rudderstackAnalyticsConfigSchema, segmentAnalyticsConfigSchema, gtmAnalyticsConfigSchema, googleAnalyticsConfigSchema, scorecardConfigSchema, catalogFilterSchema, catalogSchema, searchFacetsConfigSchema } from './ex-theme-config-schemas'; | ||
/** | ||
@@ -28,2 +28,3 @@ * @deprecated left for backwards compatibility. To be removed in Realm 1.0 | ||
export type ScorecardConfig = FromSchema<typeof scorecardConfigSchema>; | ||
export type SearchFacetsConfig = FromSchema<typeof searchFacetsConfigSchema>; | ||
export type RedoclyConfig = Omit<FromSchema<typeof rootRedoclyConfigSchema>, 'theme' | 'apis'> & { | ||
@@ -30,0 +31,0 @@ /** |
{ | ||
"name": "@redocly/config", | ||
"version": "0.11.0", | ||
"version": "0.12.0", | ||
"license": "MIT", | ||
@@ -5,0 +5,0 @@ "main": "./lib/index.js", |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
6975107
129063