Skip to content

Commit

Permalink
Merge pull request #14900 from storybookjs/14579-remove-default-values
Browse files Browse the repository at this point in the history
Addon-docs: Remove all defaultValue eval-ing
  • Loading branch information
shilman authored May 18, 2021
2 parents ed75c56 + 9021343 commit e78a021
Show file tree
Hide file tree
Showing 39 changed files with 3,132 additions and 63 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`react component properties 10017-ts-union 1`] = `
Object {
"icon": Object {
"control": Object {
"type": "object",
},
"description": "specify icon=\\"search\\" or icon={IconComponent}",
"name": "icon",
"table": Object {
"defaultValue": null,
"jsDocTags": undefined,
"type": Object {
"detail": undefined,
"summary": "union",
},
},
"type": Object {
"name": "union",
"raw": "React.ReactNode | string",
"required": true,
"value": Array [
Object {
"name": "other",
"raw": "React.ReactNode",
"value": "ReactReactNode",
},
Object {
"name": "string",
},
],
},
},
}
`;
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`react component properties 10278-ts-multiple-components 1`] = `
Object {
"aProperty": Object {
"control": Object {
"type": "object",
},
"description": "",
"name": "aProperty",
"table": Object {
"defaultValue": null,
"jsDocTags": undefined,
"type": Object {
"detail": undefined,
"summary": "any",
},
},
"type": Object {
"name": "other",
"required": true,
"value": "any",
},
},
}
`;
Original file line number Diff line number Diff line change
@@ -0,0 +1,127 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`react component properties 8140-js-prop-types-oneof 1`] = `
Object {
"blank": Object {
"control": Object {
"type": "boolean",
},
"description": "No background or border if static alert",
"name": "blank",
"table": Object {
"defaultValue": null,
"jsDocTags": undefined,
"type": Object {
"detail": undefined,
"summary": "bool",
},
},
"type": Object {
"name": "boolean",
"required": false,
},
},
"icon": Object {
"control": Object {
"type": "text",
},
"description": "Allows icon override, accepts material icon name",
"name": "icon",
"table": Object {
"defaultValue": null,
"jsDocTags": undefined,
"type": Object {
"detail": undefined,
"summary": "string",
},
},
"type": Object {
"name": "string",
"required": false,
},
},
"message": Object {
"control": Object {
"type": "text",
},
"description": "",
"name": "message",
"table": Object {
"defaultValue": null,
"jsDocTags": undefined,
"type": Object {
"detail": undefined,
"summary": "string",
},
},
"type": Object {
"name": "string",
"required": true,
},
},
"mode": Object {
"control": Object {
"type": "radio",
},
"description": "",
"name": "mode",
"options": Array [
"static",
"timed",
],
"table": Object {
"defaultValue": Object {
"detail": undefined,
"summary": "'static'",
},
"jsDocTags": undefined,
"type": Object {
"detail": undefined,
"summary": "'static' | 'timed'",
},
},
"type": Object {
"name": "enum",
"required": false,
"value": Array [
"static",
"timed",
],
},
},
"type": Object {
"control": Object {
"type": "radio",
},
"description": "",
"name": "type",
"options": Array [
"success",
"warning",
"error",
"primary",
],
"table": Object {
"defaultValue": Object {
"detail": undefined,
"summary": "'warning'",
},
"jsDocTags": undefined,
"type": Object {
"detail": undefined,
"summary": "'success' | 'warning' | 'error' | 'primary'",
},
},
"type": Object {
"name": "enum",
"required": false,
"value": Array [
"success",
"warning",
"error",
"primary",
],
},
},
}
`;
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`react component properties 8143-ts-imported-types 1`] = `
Object {
"bar": Object {
"control": Object {
"type": "object",
},
"description": "",
"name": "bar",
"table": Object {
"defaultValue": null,
"jsDocTags": undefined,
"type": Object {
"detail": undefined,
"summary": "Foo['bar']",
},
},
"type": Object {
"name": "other",
"raw": "Foo['bar']",
"required": true,
"value": "Foo['bar']",
},
},
}
`;
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`react component properties 8143-ts-react-fc-generics 1`] = `
Object {
"padding": Object {
"control": Object {
"type": "object",
},
"description": undefined,
"name": "padding",
"table": Object {
"defaultValue": Object {
"detail": undefined,
"summary": "'0'",
},
"jsDocTags": undefined,
"type": Object {
"detail": undefined,
"summary": "unknown",
},
},
"type": Object {
"required": false,
},
},
}
`;
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`react component properties 8279-js-styled-docgen 1`] = `Object {}`;
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`react component properties 8428-js-static-prop-types 1`] = `
Object {
"test": Object {
"control": Object {
"type": "text",
},
"description": "Please work...",
"name": "test",
"table": Object {
"defaultValue": null,
"jsDocTags": undefined,
"type": Object {
"detail": undefined,
"summary": "string",
},
},
"type": Object {
"name": "string",
"required": false,
},
},
}
`;
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`react component properties 8663-js-styled-components 1`] = `
Object {
"bg": Object {
"control": Object {
"type": "text",
},
"description": "",
"name": "bg",
"table": Object {
"defaultValue": null,
"jsDocTags": undefined,
"type": Object {
"detail": undefined,
"summary": "string",
},
},
"type": Object {
"name": "string",
"required": false,
},
},
}
`;
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`react component properties 8740-ts-multi-props 1`] = `
Object {
"size": Object {
"control": Object {
"type": "object",
},
"description": undefined,
"name": "size",
"table": Object {
"defaultValue": Object {
"detail": undefined,
"summary": "'a'",
},
"jsDocTags": undefined,
"type": Object {
"detail": undefined,
"summary": "unknown",
},
},
"type": Object {
"required": false,
},
},
}
`;
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`react component properties 8894-9511-ts-forward-ref 1`] = `
Object {
"disabled": Object {
"control": Object {
"type": "object",
},
"description": undefined,
"name": "disabled",
"table": Object {
"defaultValue": Object {
"detail": undefined,
"summary": "false",
},
"jsDocTags": undefined,
"type": Object {
"detail": undefined,
"summary": "unknown",
},
},
"type": Object {
"required": false,
},
},
"variant": Object {
"control": Object {
"type": "object",
},
"description": undefined,
"name": "variant",
"table": Object {
"defaultValue": Object {
"detail": undefined,
"summary": "'small'",
},
"jsDocTags": undefined,
"type": Object {
"detail": undefined,
"summary": "unknown",
},
},
"type": Object {
"required": false,
},
},
}
`;
Loading

0 comments on commit e78a021

Please sign in to comment.