@stoplight/elements-core 7.15.1 → 7.15.2

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.
@@ -1,13 +1,13 @@
1
- declare const meta: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, {
1
+ declare const meta: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0fc72a6d").R, {
2
2
  data: any;
3
3
  } & import("@stoplight/react-error-boundary").ErrorBoundaryProps<{}>>;
4
4
  export default meta;
5
- export declare const Basic: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, {
5
+ export declare const Basic: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, {
6
6
  data: any;
7
7
  } & import("@stoplight/react-error-boundary").ErrorBoundaryProps<{}>>;
8
- export declare const KitchenSink: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, {
8
+ export declare const KitchenSink: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, {
9
9
  data: any;
10
10
  } & import("@stoplight/react-error-boundary").ErrorBoundaryProps<{}>>;
11
- export declare const MultipleTryIts: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, {
11
+ export declare const MultipleTryIts: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, {
12
12
  data: any;
13
13
  } & import("@stoplight/react-error-boundary").ErrorBoundaryProps<{}>>;
@@ -1,5 +1,6 @@
1
1
  import { IMarkdownViewerProps } from '@stoplight/markdown-viewer';
2
+ import * as React from 'react';
2
3
  import { DocsComponentProps } from '..';
3
4
  declare type ArticleProps = DocsComponentProps<IMarkdownViewerProps['markdown']>;
4
- export declare const Article: import("react").FunctionComponent<ArticleProps & import("@stoplight/react-error-boundary").ErrorBoundaryProps<{}>>;
5
+ export declare const Article: React.FunctionComponent<ArticleProps & import("@stoplight/react-error-boundary").ErrorBoundaryProps<{}>>;
5
6
  export {};
@@ -1,5 +1,5 @@
1
1
  import { Story } from '@storybook/react';
2
2
  import { DocsProps } from './Docs';
3
- declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, DocsProps>;
3
+ declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0fc72a6d").R, DocsProps>;
4
4
  export default _default;
5
5
  export declare const DocsStory: Story<DocsProps>;
@@ -1,4 +1,5 @@
1
1
  import { IHttpOperation } from '@stoplight/types';
2
+ import * as React from 'react';
2
3
  import { DocsComponentProps } from '..';
3
4
  export declare type HttpOperationProps = DocsComponentProps<IHttpOperation>;
4
- export declare const HttpOperation: import("react").FunctionComponent<HttpOperationProps & import("@stoplight/react-error-boundary").ErrorBoundaryProps<{}>>;
5
+ export declare const HttpOperation: React.FunctionComponent<HttpOperationProps & import("@stoplight/react-error-boundary").ErrorBoundaryProps<{}>>;
@@ -1,7 +1,7 @@
1
- declare const meta: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, {
1
+ declare const meta: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0fc72a6d").R, {
2
2
  data: any;
3
3
  } & import("@stoplight/react-error-boundary").ErrorBoundaryProps<{}>>;
4
4
  export default meta;
5
- export declare const Story: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, {
5
+ export declare const Story: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, {
6
6
  data: any;
7
7
  } & import("@stoplight/react-error-boundary").ErrorBoundaryProps<{}>>;
@@ -1,4 +1,5 @@
1
1
  import { IHttpService } from '@stoplight/types';
2
+ import * as React from 'react';
2
3
  import { DocsComponentProps } from '..';
3
4
  export declare type HttpServiceProps = DocsComponentProps<Partial<IHttpService>>;
4
- export declare const HttpService: import("react").FunctionComponent<HttpServiceProps & import("@stoplight/react-error-boundary").ErrorBoundaryProps<{}>>;
5
+ export declare const HttpService: React.FunctionComponent<HttpServiceProps & import("@stoplight/react-error-boundary").ErrorBoundaryProps<{}>>;
@@ -1,7 +1,7 @@
1
- declare const meta: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, {
1
+ declare const meta: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0fc72a6d").R, {
2
2
  data: any;
3
3
  } & import("@stoplight/react-error-boundary").ErrorBoundaryProps<{}>>;
4
4
  export default meta;
5
- export declare const Story: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, {
5
+ export declare const Story: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, {
6
6
  data: any;
7
7
  } & import("@stoplight/react-error-boundary").ErrorBoundaryProps<{}>>;
@@ -1,4 +1,5 @@
1
1
  import { JSONSchema7 } from 'json-schema';
2
+ import * as React from 'react';
2
3
  import { DocsComponentProps } from '..';
3
4
  export declare type ModelProps = DocsComponentProps<JSONSchema7>;
4
- export declare const Model: import("react").FunctionComponent<ModelProps & import("@stoplight/react-error-boundary").ErrorBoundaryProps<{}>>;
5
+ export declare const Model: React.FunctionComponent<ModelProps & import("@stoplight/react-error-boundary").ErrorBoundaryProps<{}>>;
@@ -1,7 +1,7 @@
1
- declare const meta: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, {
1
+ declare const meta: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0fc72a6d").R, {
2
2
  data: any;
3
3
  } & import("@stoplight/react-error-boundary").ErrorBoundaryProps<{}>>;
4
4
  export default meta;
5
- export declare const Story: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, {
5
+ export declare const Story: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, {
6
6
  data: any;
7
7
  } & import("@stoplight/react-error-boundary").ErrorBoundaryProps<{}>>;
@@ -1,4 +1,4 @@
1
1
  import { RequestSamplesProps } from './RequestSamples';
2
- declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, RequestSamplesProps>;
2
+ declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0fc72a6d").R, RequestSamplesProps>;
3
3
  export default _default;
4
- export declare const HoistedStory: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, RequestSamplesProps>;
4
+ export declare const HoistedStory: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, RequestSamplesProps>;
@@ -1,4 +1,4 @@
1
1
  import { ResponseExamplesProps } from './ResponseExamples';
2
- declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, ResponseExamplesProps>;
2
+ declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0fc72a6d").R, ResponseExamplesProps>;
3
3
  export default _default;
4
- export declare const HoistedStory: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, ResponseExamplesProps>;
4
+ export declare const HoistedStory: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, ResponseExamplesProps>;
@@ -1,13 +1,13 @@
1
1
  import { TryItProps } from './TryIt';
2
- declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, TryItProps>;
2
+ declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0fc72a6d").R, TryItProps>;
3
3
  export default _default;
4
- export declare const SimpleGET: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, TryItProps>;
5
- export declare const WithParameters: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, TryItProps>;
6
- export declare const WithVariables: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, TryItProps>;
7
- export declare const UrlEncoded: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, TryItProps>;
8
- export declare const UrlEncodedOneOf: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, TryItProps>;
9
- export declare const Multipart: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, TryItProps>;
10
- export declare const RequestBodySchema: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, TryItProps>;
11
- export declare const RequestBodyExamples: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, TryItProps>;
12
- export declare const TryItAuth: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, TryItProps>;
13
- export declare const TryItAuthDuplicated: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, TryItProps>;
4
+ export declare const SimpleGET: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, TryItProps>;
5
+ export declare const WithParameters: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, TryItProps>;
6
+ export declare const WithVariables: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, TryItProps>;
7
+ export declare const UrlEncoded: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, TryItProps>;
8
+ export declare const UrlEncodedOneOf: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, TryItProps>;
9
+ export declare const Multipart: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, TryItProps>;
10
+ export declare const RequestBodySchema: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, TryItProps>;
11
+ export declare const RequestBodyExamples: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, TryItProps>;
12
+ export declare const TryItAuth: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, TryItProps>;
13
+ export declare const TryItAuthDuplicated: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, TryItProps>;
@@ -1,5 +1,5 @@
1
1
  import { TryItWithRequestSamplesProps } from './TryItWithRequestSamples';
2
- declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0a347bb9").R, TryItWithRequestSamplesProps>;
2
+ declare const _default: import("@storybook/types").ComponentAnnotations<import("@storybook/react/dist/types-0fc72a6d").R, TryItWithRequestSamplesProps>;
3
3
  export default _default;
4
- export declare const WithParameters: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, TryItWithRequestSamplesProps>;
5
- export declare const WithVariables: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, TryItWithRequestSamplesProps>;
4
+ export declare const WithParameters: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, TryItWithRequestSamplesProps>;
5
+ export declare const WithVariables: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0fc72a6d").R, TryItWithRequestSamplesProps>;
package/index.esm.js CHANGED
@@ -2519,7 +2519,12 @@ const httpOperationParamsToSchema = ({ parameters, parameterType }) => {
2519
2519
  const schemaExamplesArray = Array.isArray(schemaExamples) ? schemaExamples : [];
2520
2520
  const paramDescription = description || paramSchema.description;
2521
2521
  const paramDeprecated = !!(deprecated || paramSchema.deprecated);
2522
- const paramStyle = style && defaultStyle[parameterType] !== style ? readableStyles[style] || style : undefined;
2522
+ const paramStyleUnspecified = style === HttpParamStyles.Unspecified;
2523
+ const paramStyle = paramStyleUnspecified
2524
+ ? undefined
2525
+ : style && defaultStyle[parameterType] !== style
2526
+ ? readableStyles[style] || style
2527
+ : undefined;
2523
2528
  if (isPlainObject$1(schema.properties)) {
2524
2529
  schema.properties[p.name] = Object.assign(Object.assign({}, paramSchema), { description: paramDescription, examples: [...paramExamples, ...schemaExamplesArray], deprecated: paramDeprecated, style: paramStyle, 'x-stoplight': Object.assign(Object.assign({}, (isPlainObject$1(paramSchema['x-stoplight']) ? paramSchema['x-stoplight'] : {})), { id: p.id }) });
2525
2530
  }
package/index.js CHANGED
@@ -2576,7 +2576,12 @@ const httpOperationParamsToSchema = ({ parameters, parameterType }) => {
2576
2576
  const schemaExamplesArray = Array.isArray(schemaExamples) ? schemaExamples : [];
2577
2577
  const paramDescription = description || paramSchema.description;
2578
2578
  const paramDeprecated = !!(deprecated || paramSchema.deprecated);
2579
- const paramStyle = style && defaultStyle[parameterType] !== style ? readableStyles[style] || style : undefined;
2579
+ const paramStyleUnspecified = style === types.HttpParamStyles.Unspecified;
2580
+ const paramStyle = paramStyleUnspecified
2581
+ ? undefined
2582
+ : style && defaultStyle[parameterType] !== style
2583
+ ? readableStyles[style] || style
2584
+ : undefined;
2580
2585
  if (json.isPlainObject(schema.properties)) {
2581
2586
  schema.properties[p.name] = Object.assign(Object.assign({}, paramSchema), { description: paramDescription, examples: [...paramExamples, ...schemaExamplesArray], deprecated: paramDeprecated, style: paramStyle, 'x-stoplight': Object.assign(Object.assign({}, (json.isPlainObject(paramSchema['x-stoplight']) ? paramSchema['x-stoplight'] : {})), { id: p.id }) });
2582
2587
  }
package/index.mjs CHANGED
@@ -2519,7 +2519,12 @@ const httpOperationParamsToSchema = ({ parameters, parameterType }) => {
2519
2519
  const schemaExamplesArray = Array.isArray(schemaExamples) ? schemaExamples : [];
2520
2520
  const paramDescription = description || paramSchema.description;
2521
2521
  const paramDeprecated = !!(deprecated || paramSchema.deprecated);
2522
- const paramStyle = style && defaultStyle[parameterType] !== style ? readableStyles[style] || style : undefined;
2522
+ const paramStyleUnspecified = style === HttpParamStyles.Unspecified;
2523
+ const paramStyle = paramStyleUnspecified
2524
+ ? undefined
2525
+ : style && defaultStyle[parameterType] !== style
2526
+ ? readableStyles[style] || style
2527
+ : undefined;
2523
2528
  if (isPlainObject$1(schema.properties)) {
2524
2529
  schema.properties[p.name] = Object.assign(Object.assign({}, paramSchema), { description: paramDescription, examples: [...paramExamples, ...schemaExamplesArray], deprecated: paramDeprecated, style: paramStyle, 'x-stoplight': Object.assign(Object.assign({}, (isPlainObject$1(paramSchema['x-stoplight']) ? paramSchema['x-stoplight'] : {})), { id: p.id }) });
2525
2530
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stoplight/elements-core",
3
- "version": "7.15.1",
3
+ "version": "7.15.2",
4
4
  "main": "./index.js",
5
5
  "sideEffects": [
6
6
  "web-components.min.js",
@@ -35,7 +35,7 @@
35
35
  "@stoplight/mosaic-code-editor": "^1.46.1",
36
36
  "@stoplight/mosaic-code-viewer": "^1.46.1",
37
37
  "@stoplight/path": "^1.3.2",
38
- "@stoplight/react-error-boundary": "^2.0.0",
38
+ "@stoplight/react-error-boundary": "^3.0.0",
39
39
  "@stoplight/types": "^14.0.0",
40
40
  "@stoplight/yaml": "^4.2.3",
41
41
  "classnames": "^2.2.6",