@storybook/components 6.5.0-alpha.3 → 6.5.0-alpha.30
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/dist/cjs/ActionBar/ActionBar.js +4 -2
- package/dist/cjs/ActionBar/ActionBar.stories.js +1 -1
- package/dist/cjs/Button/Button.js +8 -6
- package/dist/cjs/Loader/Loader.js +12 -8
- package/dist/cjs/Loader/Loader.stories.js +1 -1
- package/dist/cjs/ScrollArea/GlobalScrollAreaStyles.js +1 -1
- package/dist/cjs/ScrollArea/OverlayScrollbars.js +33 -14
- package/dist/cjs/ScrollArea/ScrollArea.js +12 -11
- package/dist/cjs/ScrollArea/ScrollArea.stories.js +6 -6
- package/dist/cjs/Zoom/Zoom.js +1 -1
- package/dist/cjs/Zoom/Zoom.stories.js +9 -7
- package/dist/cjs/Zoom/ZoomElement.js +9 -8
- package/dist/cjs/Zoom/ZoomIFrame.js +8 -8
- package/dist/cjs/addon-panel/addon-panel.js +5 -5
- package/dist/cjs/bar/bar.js +16 -10
- package/dist/cjs/bar/button.js +6 -4
- package/dist/cjs/bar/button.stories.js +1 -1
- package/dist/cjs/bar/separator.js +7 -7
- package/dist/cjs/blocks/ArgsTable/ArgControl.js +8 -6
- package/dist/cjs/blocks/ArgsTable/ArgJsDoc.js +5 -3
- package/dist/cjs/blocks/ArgsTable/ArgRow.js +2 -2
- package/dist/cjs/blocks/ArgsTable/ArgRow.stories.js +3 -3
- package/dist/cjs/blocks/ArgsTable/ArgValue.js +12 -12
- package/dist/cjs/blocks/ArgsTable/ArgsTable.js +12 -8
- package/dist/cjs/blocks/ArgsTable/ArgsTable.stories.js +6 -6
- package/dist/cjs/blocks/ArgsTable/SectionRow.js +8 -6
- package/dist/cjs/blocks/ArgsTable/SectionRow.stories.js +3 -3
- package/dist/cjs/blocks/ArgsTable/TabbedArgsTable.js +10 -6
- package/dist/cjs/blocks/ArgsTable/TabbedArgsTable.stories.js +1 -1
- package/dist/cjs/blocks/ArgsTable/index.js +2 -0
- package/dist/cjs/blocks/ColorPalette.js +5 -3
- package/dist/cjs/blocks/ColorPalette.stories.js +1 -1
- package/dist/cjs/blocks/Description.js +4 -4
- package/dist/cjs/blocks/Description.stories.js +1 -1
- package/dist/cjs/blocks/DocsPage.js +4 -4
- package/dist/cjs/blocks/DocsPage.stories.js +6 -6
- package/dist/cjs/blocks/EmptyBlock.js +2 -2
- package/dist/cjs/blocks/EmptyBlock.stories.js +1 -1
- package/dist/cjs/blocks/IFrame.js +13 -11
- package/dist/cjs/blocks/IconGallery.js +6 -4
- package/dist/cjs/blocks/IconGallery.stories.js +1 -1
- package/dist/cjs/blocks/Preview.js +16 -12
- package/dist/cjs/blocks/Preview.stories.js +6 -6
- package/dist/cjs/blocks/Source.js +6 -4
- package/dist/cjs/blocks/Source.stories.js +1 -1
- package/dist/cjs/blocks/Story.js +16 -10
- package/dist/cjs/blocks/Story.stories.js +9 -7
- package/dist/cjs/blocks/Toolbar.js +11 -9
- package/dist/cjs/blocks/Typeset.js +5 -3
- package/dist/cjs/blocks/Typeset.stories.js +1 -1
- package/dist/cjs/blocks/index.js +2 -0
- package/dist/cjs/brand/StorybookLogo.js +5 -3
- package/dist/cjs/brand/StorybookLogo.stories.js +1 -1
- package/dist/cjs/controls/Boolean.js +5 -5
- package/dist/cjs/controls/Boolean.stories.js +9 -7
- package/dist/cjs/controls/Color.js +13 -11
- package/dist/cjs/controls/Color.stories.js +9 -7
- package/dist/cjs/controls/Date.js +8 -8
- package/dist/cjs/controls/Date.stories.js +9 -7
- package/dist/cjs/controls/Files.js +7 -5
- package/dist/cjs/controls/Number.js +17 -8
- package/dist/cjs/controls/Number.stories.js +9 -7
- package/dist/cjs/controls/Object.js +8 -6
- package/dist/cjs/controls/Object.stories.js +9 -7
- package/dist/cjs/controls/Range.js +7 -7
- package/dist/cjs/controls/Range.stories.js +9 -7
- package/dist/cjs/controls/Text.js +8 -6
- package/dist/cjs/controls/Text.stories.js +9 -7
- package/dist/cjs/controls/helpers.js +2 -2
- package/dist/cjs/controls/index.js +8 -8
- package/dist/cjs/controls/options/Checkbox.js +9 -7
- package/dist/cjs/controls/options/Options.js +2 -0
- package/dist/cjs/controls/options/Options.stories.js +9 -7
- package/dist/cjs/controls/options/Select.js +2 -0
- package/dist/cjs/controls/options/helpers.js +7 -5
- package/dist/cjs/controls/options/index.js +2 -0
- package/dist/cjs/controls/react-editable-json-tree/JsonNodes.js +1748 -0
- package/dist/cjs/controls/react-editable-json-tree/index.js +36 -83
- package/dist/cjs/controls/react-editable-json-tree/types/dataTypes.js +12 -15
- package/dist/cjs/controls/react-editable-json-tree/types/inputUsageTypes.js +3 -6
- package/dist/cjs/controls/react-editable-json-tree/utils/objectTypes.js +3 -3
- package/dist/cjs/controls/react-editable-json-tree/utils/parse.js +2 -5
- package/dist/cjs/controls/react-editable-json-tree/utils/styles.js +1 -1
- package/dist/cjs/controls/types.js +5 -1
- package/dist/cjs/form/field/field.js +3 -1
- package/dist/cjs/form/form.stories.js +5 -3
- package/dist/cjs/form/input/input.js +15 -10
- package/dist/cjs/html.js +2 -0
- package/dist/cjs/icon/icon.js +28 -7
- package/dist/cjs/icon/icon.stories.js +2 -0
- package/dist/cjs/icon/icons.js +1 -1
- package/dist/cjs/index.js +296 -73
- package/dist/cjs/placeholder/placeholder.js +15 -9
- package/dist/cjs/placeholder/placeholder.stories.js +6 -6
- package/dist/cjs/spaced/Spaced.js +3 -1
- package/dist/cjs/syntaxhighlighter/lazy-syntaxhighlighter.js +8 -8
- package/dist/cjs/syntaxhighlighter/syntaxhighlighter-types.js +5 -1
- package/dist/cjs/syntaxhighlighter/syntaxhighlighter.js +15 -10
- package/dist/cjs/syntaxhighlighter/syntaxhighlighter.stories.js +5 -5
- package/dist/cjs/tabs/tabs.js +13 -11
- package/dist/cjs/tabs/tabs.stories.js +6 -4
- package/dist/cjs/tooltip/ListItem.js +7 -4
- package/dist/cjs/tooltip/Tooltip.js +5 -3
- package/dist/cjs/tooltip/TooltipLinkList.js +12 -9
- package/dist/cjs/tooltip/TooltipLinkList.stories.js +5 -5
- package/dist/cjs/tooltip/TooltipMessage.js +3 -1
- package/dist/cjs/tooltip/TooltipNote.js +3 -1
- package/dist/cjs/tooltip/WithTooltip.js +14 -9
- package/dist/cjs/tooltip/lazy-WithTooltip.js +9 -10
- package/dist/cjs/typography/DocumentFormatting.js +6 -555
- package/dist/cjs/typography/DocumentWrapper.stories.js +1 -1
- package/dist/cjs/typography/ResetWrapper.js +21 -0
- package/dist/cjs/typography/components.js +126 -0
- package/dist/cjs/typography/elements/A.js +36 -0
- package/dist/cjs/typography/elements/Blockquote.js +27 -0
- package/dist/cjs/typography/elements/Code.js +109 -0
- package/dist/cjs/typography/elements/DL.js +44 -0
- package/dist/cjs/typography/elements/Div.js +14 -0
- package/dist/cjs/typography/elements/H1.js +20 -0
- package/dist/cjs/typography/elements/H2.js +21 -0
- package/dist/cjs/typography/elements/H3.js +19 -0
- package/dist/cjs/typography/elements/H4.js +19 -0
- package/dist/cjs/typography/elements/H5.js +19 -0
- package/dist/cjs/typography/elements/H6.js +20 -0
- package/dist/cjs/typography/elements/HR.js +20 -0
- package/dist/cjs/typography/elements/Img.js +14 -0
- package/dist/cjs/typography/elements/LI.js +31 -0
- package/dist/cjs/typography/elements/Link.js +44 -0
- package/dist/cjs/typography/elements/OL.js +28 -0
- package/dist/cjs/typography/elements/P.js +24 -0
- package/dist/cjs/typography/elements/Pre.js +53 -0
- package/dist/cjs/typography/elements/Span.js +92 -0
- package/dist/cjs/typography/elements/TT.js +14 -0
- package/dist/cjs/typography/elements/Table.js +50 -0
- package/dist/cjs/typography/elements/UL.js +28 -0
- package/dist/cjs/typography/{shared.js → lib/common.js} +1 -1
- package/dist/cjs/typography/lib/isReactChildString.js +12 -0
- package/dist/cjs/typography/link/link.js +5 -3
- package/dist/cjs/utils/getStoryHref.js +71 -0
- package/dist/esm/ActionBar/ActionBar.js +5 -3
- package/dist/esm/Button/Button.js +3 -1
- package/dist/esm/Loader/Loader.js +5 -3
- package/dist/esm/ScrollArea/OverlayScrollbars.js +12 -10
- package/dist/esm/ScrollArea/ScrollArea.js +7 -5
- package/dist/esm/Zoom/Zoom.js +4 -4
- package/dist/esm/Zoom/Zoom.stories.js +3 -2
- package/dist/esm/Zoom/ZoomElement.js +5 -4
- package/dist/esm/Zoom/ZoomIFrame.js +6 -6
- package/dist/esm/bar/bar.js +7 -4
- package/dist/esm/bar/button.js +2 -1
- package/dist/esm/bar/separator.js +1 -0
- package/dist/esm/blocks/ArgsTable/ArgControl.js +3 -2
- package/dist/esm/blocks/ArgsTable/ArgJsDoc.js +2 -1
- package/dist/esm/blocks/ArgsTable/ArgRow.js +1 -1
- package/dist/esm/blocks/ArgsTable/ArgRow.stories.js +1 -1
- package/dist/esm/blocks/ArgsTable/ArgValue.js +5 -5
- package/dist/esm/blocks/ArgsTable/ArgsTable.js +6 -4
- package/dist/esm/blocks/ArgsTable/SectionRow.js +3 -2
- package/dist/esm/blocks/ArgsTable/SectionRow.stories.js +1 -1
- package/dist/esm/blocks/ArgsTable/TabbedArgsTable.js +17 -14
- package/dist/esm/blocks/ColorPalette.js +4 -2
- package/dist/esm/blocks/Description.js +2 -2
- package/dist/esm/blocks/DocsPage.js +1 -1
- package/dist/esm/blocks/EmptyBlock.js +1 -1
- package/dist/esm/blocks/IFrame.js +16 -14
- package/dist/esm/blocks/IconGallery.js +4 -2
- package/dist/esm/blocks/Preview.js +17 -15
- package/dist/esm/blocks/Source.js +2 -1
- package/dist/esm/blocks/Story.js +10 -5
- package/dist/esm/blocks/Story.stories.js +3 -2
- package/dist/esm/blocks/Toolbar.js +8 -6
- package/dist/esm/blocks/Typeset.js +6 -4
- package/dist/esm/brand/StorybookLogo.js +2 -1
- package/dist/esm/controls/Boolean.stories.js +3 -2
- package/dist/esm/controls/Color.js +7 -5
- package/dist/esm/controls/Color.stories.js +3 -2
- package/dist/esm/controls/Date.js +3 -3
- package/dist/esm/controls/Date.stories.js +3 -2
- package/dist/esm/controls/Files.js +4 -3
- package/dist/esm/controls/Number.js +11 -3
- package/dist/esm/controls/Number.stories.js +3 -2
- package/dist/esm/controls/Object.js +4 -4
- package/dist/esm/controls/Object.stories.js +3 -2
- package/dist/esm/controls/Range.js +1 -1
- package/dist/esm/controls/Range.stories.js +3 -2
- package/dist/esm/controls/Text.js +3 -2
- package/dist/esm/controls/Text.stories.js +3 -2
- package/dist/esm/controls/helpers.js +1 -1
- package/dist/esm/controls/index.js +3 -3
- package/dist/esm/controls/options/Checkbox.js +4 -3
- package/dist/esm/controls/options/Options.js +1 -0
- package/dist/esm/controls/options/Options.stories.js +3 -2
- package/dist/esm/controls/options/Select.js +1 -0
- package/dist/esm/controls/options/helpers.js +4 -3
- package/dist/esm/controls/react-editable-json-tree/JsonNodes.js +1703 -0
- package/dist/esm/controls/react-editable-json-tree/index.js +29 -73
- package/dist/esm/controls/react-editable-json-tree/types/dataTypes.js +1 -13
- package/dist/esm/controls/react-editable-json-tree/types/deltaTypes.js +1 -3
- package/dist/esm/controls/react-editable-json-tree/types/inputUsageTypes.js +1 -4
- package/dist/esm/controls/react-editable-json-tree/utils/objectTypes.js +5 -9
- package/dist/esm/controls/react-editable-json-tree/utils/parse.js +2 -4
- package/dist/esm/controls/react-editable-json-tree/utils/styles.js +4 -7
- package/dist/esm/controls/types.js +1 -0
- package/dist/esm/form/field/field.js +5 -3
- package/dist/esm/form/form.stories.js +3 -2
- package/dist/esm/form/input/input.js +11 -6
- package/dist/esm/icon/icon.js +7 -6
- package/dist/esm/icon/icon.stories.js +1 -0
- package/dist/esm/index.js +30 -5
- package/dist/esm/placeholder/placeholder.js +16 -12
- package/dist/esm/spaced/Spaced.js +6 -4
- package/dist/esm/syntaxhighlighter/lazy-syntaxhighlighter.js +3 -3
- package/dist/esm/syntaxhighlighter/syntaxhighlighter-types.js +1 -0
- package/dist/esm/syntaxhighlighter/syntaxhighlighter.js +17 -14
- package/dist/esm/tabs/tabs.js +7 -6
- package/dist/esm/tabs/tabs.stories.js +2 -1
- package/dist/esm/tooltip/ListItem.js +7 -4
- package/dist/esm/tooltip/Tooltip.js +4 -2
- package/dist/esm/tooltip/TooltipLinkList.js +5 -3
- package/dist/esm/tooltip/TooltipMessage.js +6 -4
- package/dist/esm/tooltip/TooltipNote.js +5 -3
- package/dist/esm/tooltip/WithTooltip.js +7 -4
- package/dist/esm/tooltip/lazy-WithTooltip.js +4 -4
- package/dist/esm/typography/DocumentFormatting.js +4 -480
- package/dist/esm/typography/ResetWrapper.js +11 -0
- package/dist/esm/typography/components.js +92 -0
- package/dist/esm/typography/elements/A.js +25 -0
- package/dist/esm/typography/elements/Blockquote.js +16 -0
- package/dist/esm/typography/elements/Code.js +64 -0
- package/dist/esm/typography/elements/DL.js +32 -0
- package/dist/esm/typography/elements/Div.js +3 -0
- package/dist/esm/typography/elements/H1.js +9 -0
- package/dist/esm/typography/elements/H2.js +10 -0
- package/dist/esm/typography/elements/H3.js +8 -0
- package/dist/esm/typography/elements/H4.js +8 -0
- package/dist/esm/typography/elements/H5.js +8 -0
- package/dist/esm/typography/elements/H6.js +9 -0
- package/dist/esm/typography/elements/HR.js +10 -0
- package/dist/esm/typography/elements/Img.js +4 -0
- package/dist/esm/typography/elements/LI.js +20 -0
- package/dist/esm/typography/elements/Link.js +29 -0
- package/dist/esm/typography/elements/OL.js +15 -0
- package/dist/esm/typography/elements/P.js +13 -0
- package/dist/esm/typography/elements/Pre.js +42 -0
- package/dist/esm/typography/elements/Span.js +81 -0
- package/dist/esm/typography/elements/TT.js +3 -0
- package/dist/esm/typography/elements/Table.js +39 -0
- package/dist/esm/typography/elements/UL.js +15 -0
- package/dist/esm/typography/{shared.js → lib/common.js} +0 -0
- package/dist/esm/typography/lib/isReactChildString.js +3 -0
- package/dist/esm/typography/link/link.js +2 -1
- package/dist/esm/utils/getStoryHref.js +46 -0
- package/dist/modern/ActionBar/ActionBar.js +4 -2
- package/dist/modern/Badge/Badge.js +1 -1
- package/dist/modern/Button/Button.js +3 -1
- package/dist/modern/Loader/Loader.js +4 -2
- package/dist/modern/ScrollArea/OverlayScrollbars.js +10 -8
- package/dist/modern/ScrollArea/ScrollArea.js +7 -5
- package/dist/modern/Zoom/Zoom.js +4 -4
- package/dist/modern/Zoom/ZoomElement.js +2 -2
- package/dist/modern/bar/bar.js +4 -2
- package/dist/modern/bar/button.js +4 -2
- package/dist/modern/blocks/ArgsTable/ArgJsDoc.js +1 -1
- package/dist/modern/blocks/ArgsTable/ArgRow.js +1 -1
- package/dist/modern/blocks/ArgsTable/ArgRow.stories.js +1 -1
- package/dist/modern/blocks/ArgsTable/ArgValue.js +1 -1
- package/dist/modern/blocks/ArgsTable/ArgsTable.js +1 -1
- package/dist/modern/blocks/ArgsTable/SectionRow.stories.js +1 -1
- package/dist/modern/blocks/ArgsTable/TabbedArgsTable.js +4 -2
- package/dist/modern/blocks/ColorPalette.js +5 -3
- package/dist/modern/blocks/Description.js +2 -2
- package/dist/modern/blocks/DocsPage.js +1 -1
- package/dist/modern/blocks/EmptyBlock.js +1 -1
- package/dist/modern/blocks/IFrame.js +3 -1
- package/dist/modern/blocks/IconGallery.js +5 -3
- package/dist/modern/blocks/Preview.js +5 -3
- package/dist/modern/blocks/Source.js +3 -1
- package/dist/modern/blocks/Story.js +9 -4
- package/dist/modern/blocks/Toolbar.js +6 -3
- package/dist/modern/blocks/Typeset.js +5 -3
- package/dist/modern/brand/StorybookIcon.js +1 -1
- package/dist/modern/brand/StorybookLogo.js +4 -2
- package/dist/modern/controls/Color.js +4 -2
- package/dist/modern/controls/Number.js +7 -0
- package/dist/modern/controls/Object.js +1 -2
- package/dist/modern/controls/index.js +2 -2
- package/dist/modern/controls/react-editable-json-tree/JsonNodes.js +1539 -0
- package/dist/modern/controls/react-editable-json-tree/index.js +18 -57
- package/dist/modern/controls/react-editable-json-tree/types/dataTypes.js +1 -13
- package/dist/modern/controls/react-editable-json-tree/types/deltaTypes.js +1 -3
- package/dist/modern/controls/react-editable-json-tree/types/inputUsageTypes.js +1 -4
- package/dist/modern/controls/react-editable-json-tree/utils/objectTypes.js +3 -7
- package/dist/modern/controls/react-editable-json-tree/utils/parse.js +2 -4
- package/dist/modern/controls/react-editable-json-tree/utils/styles.js +4 -7
- package/dist/modern/controls/types.js +1 -0
- package/dist/modern/form/field/field.js +4 -2
- package/dist/modern/form/input/input.js +9 -4
- package/dist/modern/icon/icon.js +6 -4
- package/dist/modern/index.js +29 -5
- package/dist/modern/placeholder/placeholder.js +4 -2
- package/dist/modern/spaced/Spaced.js +4 -2
- package/dist/modern/syntaxhighlighter/lazy-syntaxhighlighter.js +2 -2
- package/dist/modern/syntaxhighlighter/syntaxhighlighter-types.js +1 -0
- package/dist/modern/syntaxhighlighter/syntaxhighlighter.js +4 -2
- package/dist/modern/tooltip/ListItem.js +7 -4
- package/dist/modern/tooltip/Tooltip.js +4 -2
- package/dist/modern/tooltip/TooltipLinkList.js +6 -3
- package/dist/modern/tooltip/TooltipMessage.js +4 -2
- package/dist/modern/tooltip/TooltipNote.js +4 -2
- package/dist/modern/tooltip/WithTooltip.js +7 -4
- package/dist/modern/tooltip/lazy-WithTooltip.js +3 -3
- package/dist/modern/typography/DocumentFormatting.js +2 -413
- package/dist/modern/typography/ResetWrapper.js +11 -0
- package/dist/modern/typography/components.js +48 -0
- package/dist/modern/typography/elements/A.js +24 -0
- package/dist/modern/typography/elements/Blockquote.js +15 -0
- package/dist/modern/typography/elements/Code.js +52 -0
- package/dist/modern/typography/elements/DL.js +31 -0
- package/dist/modern/typography/elements/Div.js +3 -0
- package/dist/modern/typography/elements/H1.js +8 -0
- package/dist/modern/typography/elements/H2.js +9 -0
- package/dist/modern/typography/elements/H3.js +7 -0
- package/dist/modern/typography/elements/H4.js +7 -0
- package/dist/modern/typography/elements/H5.js +7 -0
- package/dist/modern/typography/elements/H6.js +8 -0
- package/dist/modern/typography/elements/HR.js +9 -0
- package/dist/modern/typography/elements/Img.js +4 -0
- package/dist/modern/typography/elements/LI.js +19 -0
- package/dist/modern/typography/elements/Link.js +24 -0
- package/dist/modern/typography/elements/OL.js +14 -0
- package/dist/modern/typography/elements/P.js +12 -0
- package/dist/modern/typography/elements/Pre.js +41 -0
- package/dist/modern/typography/elements/Span.js +80 -0
- package/dist/modern/typography/elements/TT.js +3 -0
- package/dist/modern/typography/elements/Table.js +38 -0
- package/dist/modern/typography/elements/UL.js +14 -0
- package/dist/modern/typography/{shared.js → lib/common.js} +0 -0
- package/dist/modern/typography/lib/isReactChildString.js +1 -0
- package/dist/modern/typography/link/link.js +4 -2
- package/dist/modern/utils/getStoryHref.js +13 -0
- package/dist/ts3.4/Button/Button.d.ts +2 -2
- package/dist/ts3.4/Colors/SideBySide.d.ts +1 -1
- package/dist/ts3.4/Loader/Loader.d.ts +1 -1
- package/dist/ts3.4/ScrollArea/OverlayScrollbars.d.ts +3 -3
- package/dist/ts3.4/Zoom/Zoom.d.ts +4 -4
- package/dist/ts3.4/Zoom/ZoomIFrame.d.ts +2 -2
- package/dist/ts3.4/bar/button.d.ts +6 -6
- package/dist/ts3.4/blocks/ArgsTable/ArgJsDoc.d.ts +1 -1
- package/dist/ts3.4/blocks/ColorPalette.d.ts +2 -2
- package/dist/ts3.4/blocks/DocsPage.d.ts +1 -1
- package/dist/ts3.4/blocks/Story.d.ts +1 -1
- package/dist/ts3.4/controls/Color.d.ts +2 -2
- package/dist/ts3.4/controls/Object.d.ts +2 -2
- package/dist/ts3.4/controls/index.d.ts +5 -4
- package/dist/ts3.4/controls/react-editable-json-tree/JsonNodes.d.ts +247 -0
- package/dist/ts3.4/controls/react-editable-json-tree/index.d.ts +42 -0
- package/dist/ts3.4/controls/react-editable-json-tree/types/dataTypes.d.ts +12 -0
- package/dist/ts3.4/controls/react-editable-json-tree/types/deltaTypes.d.ts +4 -0
- package/dist/ts3.4/controls/react-editable-json-tree/types/inputUsageTypes.d.ts +3 -0
- package/dist/ts3.4/controls/react-editable-json-tree/utils/objectTypes.d.ts +13 -0
- package/dist/ts3.4/controls/react-editable-json-tree/utils/parse.d.ts +6 -0
- package/dist/ts3.4/controls/react-editable-json-tree/utils/styles.d.ts +59 -0
- package/dist/ts3.4/form/index.d.ts +4 -4
- package/dist/ts3.4/form/input/input.d.ts +3 -3
- package/dist/ts3.4/index.d.ts +46 -2
- package/dist/ts3.4/syntaxhighlighter/lazy-syntaxhighlighter.d.ts +2 -2
- package/dist/ts3.4/syntaxhighlighter/syntaxhighlighter-types.d.ts +2 -2
- package/dist/ts3.4/tabs/tabs.d.ts +1 -1
- package/dist/ts3.4/tooltip/ListItem.d.ts +1 -1
- package/dist/ts3.4/tooltip/lazy-WithTooltip.d.ts +3 -3
- package/dist/ts3.4/typography/DocumentFormatting.d.ts +4 -55
- package/dist/ts3.4/typography/ResetWrapper.d.ts +9 -0
- package/dist/ts3.4/typography/components.d.ts +25 -0
- package/dist/ts3.4/typography/elements/A.d.ts +6 -0
- package/dist/ts3.4/typography/elements/Blockquote.d.ts +6 -0
- package/dist/ts3.4/typography/elements/Code.d.ts +6 -0
- package/dist/ts3.4/typography/elements/DL.d.ts +4 -0
- package/dist/ts3.4/typography/elements/Div.d.ts +4 -0
- package/dist/ts3.4/typography/elements/H1.d.ts +6 -0
- package/dist/ts3.4/typography/elements/H2.d.ts +6 -0
- package/dist/ts3.4/typography/elements/H3.d.ts +6 -0
- package/dist/ts3.4/typography/elements/H4.d.ts +6 -0
- package/dist/ts3.4/typography/elements/H5.d.ts +6 -0
- package/dist/ts3.4/typography/elements/H6.d.ts +6 -0
- package/dist/ts3.4/typography/elements/HR.d.ts +2 -0
- package/dist/ts3.4/typography/elements/Img.d.ts +2 -0
- package/dist/ts3.4/typography/elements/LI.d.ts +6 -0
- package/dist/ts3.4/typography/elements/Link.d.ts +2 -0
- package/dist/ts3.4/typography/elements/OL.d.ts +4 -0
- package/dist/ts3.4/typography/elements/P.d.ts +6 -0
- package/dist/ts3.4/typography/elements/Pre.d.ts +6 -0
- package/dist/ts3.4/typography/elements/Span.d.ts +6 -0
- package/dist/ts3.4/typography/elements/TT.d.ts +4 -0
- package/dist/ts3.4/typography/elements/Table.d.ts +6 -0
- package/dist/ts3.4/typography/elements/UL.d.ts +4 -0
- package/dist/ts3.4/typography/{shared.d.ts → lib/common.d.ts} +0 -0
- package/dist/ts3.4/typography/lib/isReactChildString.d.ts +2 -0
- package/dist/ts3.4/utils/getStoryHref.d.ts +1 -0
- package/dist/ts3.9/Button/Button.d.ts +2 -2
- package/dist/ts3.9/Colors/SideBySide.d.ts +1 -1
- package/dist/ts3.9/Loader/Loader.d.ts +1 -1
- package/dist/ts3.9/ScrollArea/OverlayScrollbars.d.ts +3 -3
- package/dist/ts3.9/Zoom/Zoom.d.ts +4 -4
- package/dist/ts3.9/Zoom/ZoomIFrame.d.ts +2 -2
- package/dist/ts3.9/bar/button.d.ts +6 -6
- package/dist/ts3.9/blocks/ArgsTable/ArgJsDoc.d.ts +1 -1
- package/dist/ts3.9/blocks/ColorPalette.d.ts +2 -2
- package/dist/ts3.9/blocks/DocsPage.d.ts +1 -1
- package/dist/ts3.9/blocks/Story.d.ts +1 -1
- package/dist/ts3.9/controls/Color.d.ts +2 -2
- package/dist/ts3.9/controls/Object.d.ts +2 -2
- package/dist/ts3.9/controls/index.d.ts +5 -4
- package/dist/ts3.9/controls/react-editable-json-tree/JsonNodes.d.ts +247 -0
- package/dist/ts3.9/controls/react-editable-json-tree/index.d.ts +42 -0
- package/dist/ts3.9/controls/react-editable-json-tree/types/dataTypes.d.ts +12 -0
- package/dist/ts3.9/controls/react-editable-json-tree/types/deltaTypes.d.ts +4 -0
- package/dist/ts3.9/controls/react-editable-json-tree/types/inputUsageTypes.d.ts +3 -0
- package/dist/ts3.9/controls/react-editable-json-tree/utils/objectTypes.d.ts +13 -0
- package/dist/ts3.9/controls/react-editable-json-tree/utils/parse.d.ts +6 -0
- package/dist/ts3.9/controls/react-editable-json-tree/utils/styles.d.ts +59 -0
- package/dist/ts3.9/form/index.d.ts +4 -4
- package/dist/ts3.9/form/input/input.d.ts +3 -3
- package/dist/ts3.9/index.d.ts +46 -2
- package/dist/ts3.9/syntaxhighlighter/lazy-syntaxhighlighter.d.ts +2 -2
- package/dist/ts3.9/syntaxhighlighter/syntaxhighlighter-types.d.ts +2 -2
- package/dist/ts3.9/tabs/tabs.d.ts +1 -1
- package/dist/ts3.9/tooltip/ListItem.d.ts +1 -1
- package/dist/ts3.9/tooltip/lazy-WithTooltip.d.ts +3 -3
- package/dist/ts3.9/typography/DocumentFormatting.d.ts +4 -55
- package/dist/ts3.9/typography/ResetWrapper.d.ts +9 -0
- package/dist/ts3.9/typography/components.d.ts +25 -0
- package/dist/ts3.9/typography/elements/A.d.ts +6 -0
- package/dist/ts3.9/typography/elements/Blockquote.d.ts +6 -0
- package/dist/ts3.9/typography/elements/Code.d.ts +6 -0
- package/dist/ts3.9/typography/elements/DL.d.ts +4 -0
- package/dist/ts3.9/typography/elements/Div.d.ts +4 -0
- package/dist/ts3.9/typography/elements/H1.d.ts +6 -0
- package/dist/ts3.9/typography/elements/H2.d.ts +6 -0
- package/dist/ts3.9/typography/elements/H3.d.ts +6 -0
- package/dist/ts3.9/typography/elements/H4.d.ts +6 -0
- package/dist/ts3.9/typography/elements/H5.d.ts +6 -0
- package/dist/ts3.9/typography/elements/H6.d.ts +6 -0
- package/dist/ts3.9/typography/elements/HR.d.ts +2 -0
- package/dist/ts3.9/typography/elements/Img.d.ts +2 -0
- package/dist/ts3.9/typography/elements/LI.d.ts +6 -0
- package/dist/ts3.9/typography/elements/Link.d.ts +2 -0
- package/dist/ts3.9/typography/elements/OL.d.ts +4 -0
- package/dist/ts3.9/typography/elements/P.d.ts +6 -0
- package/dist/ts3.9/typography/elements/Pre.d.ts +6 -0
- package/dist/ts3.9/typography/elements/Span.d.ts +6 -0
- package/dist/ts3.9/typography/elements/TT.d.ts +4 -0
- package/dist/ts3.9/typography/elements/Table.d.ts +6 -0
- package/dist/ts3.9/typography/elements/UL.d.ts +4 -0
- package/dist/ts3.9/typography/{shared.d.ts → lib/common.d.ts} +1 -1
- package/dist/ts3.9/typography/lib/isReactChildString.d.ts +2 -0
- package/dist/ts3.9/utils/getStoryHref.d.ts +1 -0
- package/package.json +6 -5
- package/dist/cjs/Colors/colorpalette.stories.mdx +0 -125
- package/dist/cjs/blocks/DocsPageExampleCaption.md +0 -92
- package/dist/cjs/blocks/DocsPageExampleCaption.mdx +0 -92
- package/dist/cjs/controls/react-editable-json-tree/LICENSE.md +0 -14
- package/dist/cjs/controls/react-editable-json-tree/components/JsonAddValue.js +0 -228
- package/dist/cjs/controls/react-editable-json-tree/components/JsonArray.js +0 -507
- package/dist/cjs/controls/react-editable-json-tree/components/JsonFunctionValue.js +0 -321
- package/dist/cjs/controls/react-editable-json-tree/components/JsonNode.js +0 -422
- package/dist/cjs/controls/react-editable-json-tree/components/JsonObject.js +0 -509
- package/dist/cjs/controls/react-editable-json-tree/components/JsonValue.js +0 -312
- package/dist/cjs/typings.d.js +0 -1
- package/dist/cjs/typography/DocumentFormattingSample.md +0 -141
- package/dist/cjs/typography/typography.stories.mdx +0 -75
- package/dist/esm/Colors/colorpalette.stories.mdx +0 -125
- package/dist/esm/blocks/DocsPageExampleCaption.md +0 -92
- package/dist/esm/blocks/DocsPageExampleCaption.mdx +0 -92
- package/dist/esm/controls/react-editable-json-tree/LICENSE.md +0 -14
- package/dist/esm/controls/react-editable-json-tree/components/JsonAddValue.js +0 -194
- package/dist/esm/controls/react-editable-json-tree/components/JsonArray.js +0 -465
- package/dist/esm/controls/react-editable-json-tree/components/JsonFunctionValue.js +0 -282
- package/dist/esm/controls/react-editable-json-tree/components/JsonNode.js +0 -387
- package/dist/esm/controls/react-editable-json-tree/components/JsonObject.js +0 -467
- package/dist/esm/controls/react-editable-json-tree/components/JsonValue.js +0 -272
- package/dist/esm/typings.d.js +0 -0
- package/dist/esm/typography/DocumentFormattingSample.md +0 -141
- package/dist/esm/typography/typography.stories.mdx +0 -75
- package/dist/modern/Colors/colorpalette.stories.mdx +0 -125
- package/dist/modern/blocks/DocsPageExampleCaption.md +0 -92
- package/dist/modern/blocks/DocsPageExampleCaption.mdx +0 -92
- package/dist/modern/controls/react-editable-json-tree/LICENSE.md +0 -14
- package/dist/modern/controls/react-editable-json-tree/components/JsonAddValue.js +0 -148
- package/dist/modern/controls/react-editable-json-tree/components/JsonArray.js +0 -392
- package/dist/modern/controls/react-editable-json-tree/components/JsonFunctionValue.js +0 -215
- package/dist/modern/controls/react-editable-json-tree/components/JsonNode.js +0 -339
- package/dist/modern/controls/react-editable-json-tree/components/JsonObject.js +0 -394
- package/dist/modern/controls/react-editable-json-tree/components/JsonValue.js +0 -202
- package/dist/modern/typings.d.js +0 -0
- package/dist/modern/typography/DocumentFormattingSample.md +0 -141
- package/dist/modern/typography/typography.stories.mdx +0 -75
|
@@ -1,490 +1,14 @@
|
|
|
1
1
|
import "core-js/modules/es.object.assign.js";
|
|
2
|
-
import "core-js/modules/es.string.match.js";
|
|
3
|
-
import "core-js/modules/es.regexp.exec.js";
|
|
4
|
-
import "core-js/modules/es.array.filter.js";
|
|
5
2
|
import "core-js/modules/es.array.join.js";
|
|
3
|
+
import "core-js/modules/es.array.filter.js";
|
|
4
|
+
import "core-js/modules/es.object.to-string.js";
|
|
6
5
|
import "core-js/modules/es.array.concat.js";
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
11
|
-
|
|
12
|
-
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
13
|
-
|
|
14
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
15
|
-
|
|
16
|
-
import React from 'react';
|
|
17
|
-
import { styled } from '@storybook/theming';
|
|
18
|
-
import { withReset, withMargin, headerCommon, codeCommon } from './shared';
|
|
19
|
-
import { StyledSyntaxHighlighter } from '../blocks/Source';
|
|
20
|
-
export var H1 = styled.h1(withReset, headerCommon, function (_ref) {
|
|
21
|
-
var theme = _ref.theme;
|
|
22
|
-
return {
|
|
23
|
-
fontSize: "".concat(theme.typography.size.l1, "px"),
|
|
24
|
-
fontWeight: theme.typography.weight.black
|
|
25
|
-
};
|
|
26
|
-
});
|
|
27
|
-
export var H2 = styled.h2(withReset, headerCommon, function (_ref2) {
|
|
28
|
-
var theme = _ref2.theme;
|
|
29
|
-
return {
|
|
30
|
-
fontSize: "".concat(theme.typography.size.m2, "px"),
|
|
31
|
-
paddingBottom: 4,
|
|
32
|
-
borderBottom: "1px solid ".concat(theme.appBorderColor)
|
|
33
|
-
};
|
|
34
|
-
});
|
|
35
|
-
export var H3 = styled.h3(withReset, headerCommon, function (_ref3) {
|
|
36
|
-
var theme = _ref3.theme;
|
|
37
|
-
return {
|
|
38
|
-
fontSize: "".concat(theme.typography.size.m1, "px")
|
|
39
|
-
};
|
|
40
|
-
});
|
|
41
|
-
export var H4 = styled.h4(withReset, headerCommon, function (_ref4) {
|
|
42
|
-
var theme = _ref4.theme;
|
|
43
|
-
return {
|
|
44
|
-
fontSize: "".concat(theme.typography.size.s3, "px")
|
|
45
|
-
};
|
|
46
|
-
});
|
|
47
|
-
export var H5 = styled.h5(withReset, headerCommon, function (_ref5) {
|
|
48
|
-
var theme = _ref5.theme;
|
|
49
|
-
return {
|
|
50
|
-
fontSize: "".concat(theme.typography.size.s2, "px")
|
|
51
|
-
};
|
|
52
|
-
});
|
|
53
|
-
export var H6 = styled.h6(withReset, headerCommon, function (_ref6) {
|
|
54
|
-
var theme = _ref6.theme;
|
|
55
|
-
return {
|
|
56
|
-
fontSize: "".concat(theme.typography.size.s2, "px"),
|
|
57
|
-
color: theme.color.dark
|
|
58
|
-
};
|
|
59
|
-
});
|
|
60
|
-
export var Pre = styled.pre(withReset, withMargin, function (_ref7) {
|
|
61
|
-
var theme = _ref7.theme;
|
|
62
|
-
return {
|
|
63
|
-
// reset
|
|
64
|
-
fontFamily: theme.typography.fonts.mono,
|
|
65
|
-
WebkitFontSmoothing: 'antialiased',
|
|
66
|
-
MozOsxFontSmoothing: 'grayscale',
|
|
67
|
-
lineHeight: '18px',
|
|
68
|
-
padding: '11px 1rem',
|
|
69
|
-
whiteSpace: 'pre-wrap',
|
|
70
|
-
color: 'inherit',
|
|
71
|
-
borderRadius: 3,
|
|
72
|
-
margin: '1rem 0',
|
|
73
|
-
'&:not(.prismjs)': {
|
|
74
|
-
background: 'transparent',
|
|
75
|
-
border: 'none',
|
|
76
|
-
borderRadius: 0,
|
|
77
|
-
padding: 0,
|
|
78
|
-
margin: 0
|
|
79
|
-
},
|
|
80
|
-
'& pre, &.prismjs': {
|
|
81
|
-
padding: 15,
|
|
82
|
-
margin: 0,
|
|
83
|
-
whiteSpace: 'pre-wrap',
|
|
84
|
-
color: 'inherit',
|
|
85
|
-
fontSize: '13px',
|
|
86
|
-
lineHeight: '19px',
|
|
87
|
-
code: {
|
|
88
|
-
color: 'inherit',
|
|
89
|
-
fontSize: 'inherit'
|
|
90
|
-
}
|
|
91
|
-
},
|
|
92
|
-
'& code': {
|
|
93
|
-
whiteSpace: 'pre'
|
|
94
|
-
},
|
|
95
|
-
'& code, & tt': {
|
|
96
|
-
border: 'none'
|
|
97
|
-
}
|
|
98
|
-
};
|
|
99
|
-
});
|
|
100
|
-
|
|
101
|
-
var Link = function Link(_ref8) {
|
|
102
|
-
var input = _ref8.href,
|
|
103
|
-
children = _ref8.children,
|
|
104
|
-
props = _objectWithoutProperties(_ref8, ["href", "children"]);
|
|
105
|
-
|
|
106
|
-
var isStorybookPath = /^\//.test(input);
|
|
107
|
-
var isAnchorUrl = /^#.*/.test(input);
|
|
108
|
-
var href = isStorybookPath ? "?path=".concat(input) : input;
|
|
109
|
-
var target = isAnchorUrl ? '_self' : '_top';
|
|
110
|
-
return /*#__PURE__*/React.createElement("a", _extends({
|
|
111
|
-
href: href,
|
|
112
|
-
target: target
|
|
113
|
-
}, props), children);
|
|
114
|
-
};
|
|
115
|
-
|
|
116
|
-
Link.displayName = "Link";
|
|
117
|
-
export var A = styled(Link)(withReset, function (_ref9) {
|
|
118
|
-
var theme = _ref9.theme;
|
|
119
|
-
return {
|
|
120
|
-
fontSize: 'inherit',
|
|
121
|
-
lineHeight: '24px',
|
|
122
|
-
color: theme.color.secondary,
|
|
123
|
-
textDecoration: 'none',
|
|
124
|
-
'&.absent': {
|
|
125
|
-
color: '#cc0000'
|
|
126
|
-
},
|
|
127
|
-
'&.anchor': {
|
|
128
|
-
display: 'block',
|
|
129
|
-
paddingLeft: 30,
|
|
130
|
-
marginLeft: -30,
|
|
131
|
-
cursor: 'pointer',
|
|
132
|
-
position: 'absolute',
|
|
133
|
-
top: 0,
|
|
134
|
-
left: 0,
|
|
135
|
-
bottom: 0
|
|
136
|
-
}
|
|
137
|
-
};
|
|
138
|
-
});
|
|
139
|
-
export var HR = styled.hr(function (_ref10) {
|
|
140
|
-
var theme = _ref10.theme;
|
|
141
|
-
return {
|
|
142
|
-
border: '0 none',
|
|
143
|
-
borderTop: "1px solid ".concat(theme.appBorderColor),
|
|
144
|
-
height: 4,
|
|
145
|
-
padding: 0
|
|
146
|
-
};
|
|
147
|
-
});
|
|
148
|
-
export var DL = styled.dl(withReset, Object.assign({}, withMargin, {
|
|
149
|
-
padding: 0,
|
|
150
|
-
'& dt': {
|
|
151
|
-
fontSize: '14px',
|
|
152
|
-
fontWeight: 'bold',
|
|
153
|
-
fontStyle: 'italic',
|
|
154
|
-
padding: 0,
|
|
155
|
-
margin: '16px 0 4px'
|
|
156
|
-
},
|
|
157
|
-
'& dt:first-of-type': {
|
|
158
|
-
padding: 0
|
|
159
|
-
},
|
|
160
|
-
'& dt > :first-of-type': {
|
|
161
|
-
marginTop: 0
|
|
162
|
-
},
|
|
163
|
-
'& dt > :last-child': {
|
|
164
|
-
marginBottom: 0
|
|
165
|
-
},
|
|
166
|
-
'& dd': {
|
|
167
|
-
margin: '0 0 16px',
|
|
168
|
-
padding: '0 15px'
|
|
169
|
-
},
|
|
170
|
-
'& dd > :first-of-type': {
|
|
171
|
-
marginTop: 0
|
|
172
|
-
},
|
|
173
|
-
'& dd > :last-child': {
|
|
174
|
-
marginBottom: 0
|
|
175
|
-
}
|
|
176
|
-
}));
|
|
177
|
-
export var Blockquote = styled.blockquote(withReset, withMargin, function (_ref11) {
|
|
178
|
-
var theme = _ref11.theme;
|
|
179
|
-
return {
|
|
180
|
-
borderLeft: "4px solid ".concat(theme.color.medium),
|
|
181
|
-
padding: '0 15px',
|
|
182
|
-
color: theme.color.dark,
|
|
183
|
-
'& > :first-of-type': {
|
|
184
|
-
marginTop: 0
|
|
185
|
-
},
|
|
186
|
-
'& > :last-child': {
|
|
187
|
-
marginBottom: 0
|
|
188
|
-
}
|
|
189
|
-
};
|
|
190
|
-
});
|
|
191
|
-
export var Table = styled.table(withReset, withMargin, function (_ref12) {
|
|
192
|
-
var theme = _ref12.theme;
|
|
193
|
-
return {
|
|
194
|
-
fontSize: theme.typography.size.s2,
|
|
195
|
-
lineHeight: '24px',
|
|
196
|
-
padding: 0,
|
|
197
|
-
borderCollapse: 'collapse',
|
|
198
|
-
'& tr': {
|
|
199
|
-
borderTop: "1px solid ".concat(theme.appBorderColor),
|
|
200
|
-
backgroundColor: theme.appContentBg,
|
|
201
|
-
margin: 0,
|
|
202
|
-
padding: 0
|
|
203
|
-
},
|
|
204
|
-
'& tr:nth-of-type(2n)': {
|
|
205
|
-
backgroundColor: theme.base === 'dark' ? theme.color.darker : theme.color.lighter
|
|
206
|
-
},
|
|
207
|
-
'& tr th': {
|
|
208
|
-
fontWeight: 'bold',
|
|
209
|
-
color: theme.color.defaultText,
|
|
210
|
-
border: "1px solid ".concat(theme.appBorderColor),
|
|
211
|
-
margin: 0,
|
|
212
|
-
padding: '6px 13px'
|
|
213
|
-
},
|
|
214
|
-
'& tr td': {
|
|
215
|
-
border: "1px solid ".concat(theme.appBorderColor),
|
|
216
|
-
color: theme.color.defaultText,
|
|
217
|
-
margin: 0,
|
|
218
|
-
padding: '6px 13px'
|
|
219
|
-
},
|
|
220
|
-
'& tr th :first-of-type, & tr td :first-of-type': {
|
|
221
|
-
marginTop: 0
|
|
222
|
-
},
|
|
223
|
-
'& tr th :last-child, & tr td :last-child': {
|
|
224
|
-
marginBottom: 0
|
|
225
|
-
}
|
|
226
|
-
};
|
|
227
|
-
});
|
|
228
|
-
export var Img = styled.img({
|
|
229
|
-
maxWidth: '100%'
|
|
230
|
-
});
|
|
231
|
-
export var Div = styled.div(withReset);
|
|
232
|
-
export var Span = styled.span(withReset, function (_ref13) {
|
|
233
|
-
var theme = _ref13.theme;
|
|
234
|
-
return {
|
|
235
|
-
'&.frame': {
|
|
236
|
-
display: 'block',
|
|
237
|
-
overflow: 'hidden',
|
|
238
|
-
'& > span': {
|
|
239
|
-
border: "1px solid ".concat(theme.color.medium),
|
|
240
|
-
display: 'block',
|
|
241
|
-
float: 'left',
|
|
242
|
-
overflow: 'hidden',
|
|
243
|
-
margin: '13px 0 0',
|
|
244
|
-
padding: 7,
|
|
245
|
-
width: 'auto'
|
|
246
|
-
},
|
|
247
|
-
'& span img': {
|
|
248
|
-
display: 'block',
|
|
249
|
-
float: 'left'
|
|
250
|
-
},
|
|
251
|
-
'& span span': {
|
|
252
|
-
clear: 'both',
|
|
253
|
-
color: theme.color.darkest,
|
|
254
|
-
display: 'block',
|
|
255
|
-
padding: '5px 0 0'
|
|
256
|
-
}
|
|
257
|
-
},
|
|
258
|
-
'&.align-center': {
|
|
259
|
-
display: 'block',
|
|
260
|
-
overflow: 'hidden',
|
|
261
|
-
clear: 'both',
|
|
262
|
-
'& > span': {
|
|
263
|
-
display: 'block',
|
|
264
|
-
overflow: 'hidden',
|
|
265
|
-
margin: '13px auto 0',
|
|
266
|
-
textAlign: 'center'
|
|
267
|
-
},
|
|
268
|
-
'& span img': {
|
|
269
|
-
margin: '0 auto',
|
|
270
|
-
textAlign: 'center'
|
|
271
|
-
}
|
|
272
|
-
},
|
|
273
|
-
'&.align-right': {
|
|
274
|
-
display: 'block',
|
|
275
|
-
overflow: 'hidden',
|
|
276
|
-
clear: 'both',
|
|
277
|
-
'& > span': {
|
|
278
|
-
display: 'block',
|
|
279
|
-
overflow: 'hidden',
|
|
280
|
-
margin: '13px 0 0',
|
|
281
|
-
textAlign: 'right'
|
|
282
|
-
},
|
|
283
|
-
'& span img': {
|
|
284
|
-
margin: 0,
|
|
285
|
-
textAlign: 'right'
|
|
286
|
-
}
|
|
287
|
-
},
|
|
288
|
-
'&.float-left': {
|
|
289
|
-
display: 'block',
|
|
290
|
-
marginRight: 13,
|
|
291
|
-
overflow: 'hidden',
|
|
292
|
-
float: 'left',
|
|
293
|
-
'& span': {
|
|
294
|
-
margin: '13px 0 0'
|
|
295
|
-
}
|
|
296
|
-
},
|
|
297
|
-
'&.float-right': {
|
|
298
|
-
display: 'block',
|
|
299
|
-
marginLeft: 13,
|
|
300
|
-
overflow: 'hidden',
|
|
301
|
-
float: 'right',
|
|
302
|
-
'& > span': {
|
|
303
|
-
display: 'block',
|
|
304
|
-
overflow: 'hidden',
|
|
305
|
-
margin: '13px auto 0',
|
|
306
|
-
textAlign: 'right'
|
|
307
|
-
}
|
|
308
|
-
}
|
|
309
|
-
};
|
|
310
|
-
});
|
|
311
|
-
var listCommon = {
|
|
312
|
-
paddingLeft: 30,
|
|
313
|
-
'& :first-of-type': {
|
|
314
|
-
marginTop: 0
|
|
315
|
-
},
|
|
316
|
-
'& :last-child': {
|
|
317
|
-
marginBottom: 0
|
|
318
|
-
}
|
|
319
|
-
};
|
|
320
|
-
export var LI = styled.li(withReset, function (_ref14) {
|
|
321
|
-
var theme = _ref14.theme;
|
|
322
|
-
return {
|
|
323
|
-
fontSize: theme.typography.size.s2,
|
|
324
|
-
color: theme.color.defaultText,
|
|
325
|
-
lineHeight: '24px',
|
|
326
|
-
'& + li': {
|
|
327
|
-
marginTop: '.25em'
|
|
328
|
-
},
|
|
329
|
-
'& ul, & ol': {
|
|
330
|
-
marginTop: '.25em',
|
|
331
|
-
marginBottom: 0
|
|
332
|
-
},
|
|
333
|
-
'& code': codeCommon({
|
|
334
|
-
theme: theme
|
|
335
|
-
})
|
|
336
|
-
};
|
|
337
|
-
});
|
|
338
|
-
export var UL = styled.ul(withReset, withMargin, Object.assign({}, listCommon, {
|
|
339
|
-
listStyle: 'disc'
|
|
340
|
-
}));
|
|
341
|
-
export var OL = styled.ol(withReset, withMargin, Object.assign({}, listCommon, {
|
|
342
|
-
listStyle: 'decimal'
|
|
343
|
-
}));
|
|
344
|
-
export var P = styled.p(withReset, withMargin, function (_ref15) {
|
|
345
|
-
var theme = _ref15.theme;
|
|
346
|
-
return {
|
|
347
|
-
fontSize: theme.typography.size.s2,
|
|
348
|
-
lineHeight: '24px',
|
|
349
|
-
color: theme.color.defaultText,
|
|
350
|
-
'& code': codeCommon({
|
|
351
|
-
theme: theme
|
|
352
|
-
})
|
|
353
|
-
};
|
|
354
|
-
});
|
|
355
|
-
var DefaultCodeBlock = styled.code(function (_ref16) {
|
|
356
|
-
var theme = _ref16.theme;
|
|
357
|
-
return {
|
|
358
|
-
// from reset
|
|
359
|
-
fontFamily: theme.typography.fonts.mono,
|
|
360
|
-
WebkitFontSmoothing: 'antialiased',
|
|
361
|
-
MozOsxFontSmoothing: 'grayscale',
|
|
362
|
-
display: 'inline-block',
|
|
363
|
-
paddingLeft: 2,
|
|
364
|
-
paddingRight: 2,
|
|
365
|
-
verticalAlign: 'baseline',
|
|
366
|
-
color: 'inherit'
|
|
367
|
-
};
|
|
368
|
-
}, codeCommon);
|
|
369
|
-
var isInlineCodeRegex = /[\n\r]/g;
|
|
370
|
-
|
|
371
|
-
var isReactChildString = function isReactChildString(child) {
|
|
372
|
-
return typeof child === 'string';
|
|
373
|
-
};
|
|
374
|
-
|
|
375
|
-
export var Code = function Code(_ref17) {
|
|
376
|
-
var _language$;
|
|
377
|
-
|
|
378
|
-
var className = _ref17.className,
|
|
379
|
-
children = _ref17.children,
|
|
380
|
-
props = _objectWithoutProperties(_ref17, ["className", "children"]);
|
|
381
|
-
|
|
382
|
-
var language = (className || '').match(/lang-(\S+)/);
|
|
383
|
-
var childrenArray = React.Children.toArray(children);
|
|
384
|
-
var isInlineCode = !childrenArray.filter(isReactChildString).some(function (child) {
|
|
385
|
-
return child.match(isInlineCodeRegex);
|
|
386
|
-
});
|
|
387
|
-
|
|
388
|
-
if (isInlineCode) {
|
|
389
|
-
return /*#__PURE__*/React.createElement(DefaultCodeBlock, _extends({}, props, {
|
|
390
|
-
className: className
|
|
391
|
-
}), childrenArray);
|
|
392
|
-
}
|
|
393
|
-
|
|
394
|
-
return /*#__PURE__*/React.createElement(StyledSyntaxHighlighter, _extends({
|
|
395
|
-
bordered: true,
|
|
396
|
-
copyable: true,
|
|
397
|
-
language: (_language$ = language === null || language === void 0 ? void 0 : language[1]) !== null && _language$ !== void 0 ? _language$ : 'plaintext',
|
|
398
|
-
format: false
|
|
399
|
-
}, props), children);
|
|
400
|
-
};
|
|
401
|
-
Code.displayName = "Code";
|
|
402
|
-
export var TT = styled.title(codeCommon);
|
|
403
|
-
/**
|
|
404
|
-
* This is a "local" reset to style subtrees with Storybook styles
|
|
405
|
-
*
|
|
406
|
-
* We can't style individual elements (e.g. h1, h2, etc.) in here
|
|
407
|
-
* because the CSS specificity is too high, so those styles can too
|
|
408
|
-
* easily override child elements that are not expecting it.
|
|
409
|
-
*/
|
|
410
|
-
|
|
411
|
-
export var ResetWrapper = styled.div(withReset);
|
|
412
|
-
|
|
413
|
-
var nameSpaceClassNames = function nameSpaceClassNames(_ref18, key) {
|
|
414
|
-
var props = Object.assign({}, _ref18);
|
|
6
|
+
export var nameSpaceClassNames = function nameSpaceClassNames(_ref, key) {
|
|
7
|
+
var props = Object.assign({}, _ref);
|
|
415
8
|
var classes = [props.class, props.className]; // eslint-disable-next-line no-param-reassign
|
|
416
9
|
|
|
417
10
|
delete props.class; // eslint-disable-next-line no-param-reassign
|
|
418
11
|
|
|
419
12
|
props.className = ['sbdocs', "sbdocs-".concat(key)].concat(classes).filter(Boolean).join(' ');
|
|
420
13
|
return props;
|
|
421
|
-
};
|
|
422
|
-
|
|
423
|
-
export var components = {
|
|
424
|
-
h1: function (props) {
|
|
425
|
-
return /*#__PURE__*/React.createElement(H1, nameSpaceClassNames(props, 'h1'));
|
|
426
|
-
},
|
|
427
|
-
h2: function (props) {
|
|
428
|
-
return /*#__PURE__*/React.createElement(H2, nameSpaceClassNames(props, 'h2'));
|
|
429
|
-
},
|
|
430
|
-
h3: function (props) {
|
|
431
|
-
return /*#__PURE__*/React.createElement(H3, nameSpaceClassNames(props, 'h3'));
|
|
432
|
-
},
|
|
433
|
-
h4: function (props) {
|
|
434
|
-
return /*#__PURE__*/React.createElement(H4, nameSpaceClassNames(props, 'h4'));
|
|
435
|
-
},
|
|
436
|
-
h5: function (props) {
|
|
437
|
-
return /*#__PURE__*/React.createElement(H5, nameSpaceClassNames(props, 'h5'));
|
|
438
|
-
},
|
|
439
|
-
h6: function (props) {
|
|
440
|
-
return /*#__PURE__*/React.createElement(H6, nameSpaceClassNames(props, 'h6'));
|
|
441
|
-
},
|
|
442
|
-
pre: function (props) {
|
|
443
|
-
return /*#__PURE__*/React.createElement(Pre, nameSpaceClassNames(props, 'pre'));
|
|
444
|
-
},
|
|
445
|
-
a: function (props) {
|
|
446
|
-
return /*#__PURE__*/React.createElement(A, nameSpaceClassNames(props, 'a'));
|
|
447
|
-
},
|
|
448
|
-
hr: function (props) {
|
|
449
|
-
return /*#__PURE__*/React.createElement(HR, nameSpaceClassNames(props, 'hr'));
|
|
450
|
-
},
|
|
451
|
-
dl: function (props) {
|
|
452
|
-
return /*#__PURE__*/React.createElement(DL, nameSpaceClassNames(props, 'dl'));
|
|
453
|
-
},
|
|
454
|
-
blockquote: function (props) {
|
|
455
|
-
return /*#__PURE__*/React.createElement(Blockquote, nameSpaceClassNames(props, 'blockquote'));
|
|
456
|
-
},
|
|
457
|
-
table: function (props) {
|
|
458
|
-
return /*#__PURE__*/React.createElement(Table, nameSpaceClassNames(props, 'table'));
|
|
459
|
-
},
|
|
460
|
-
img: function (props) {
|
|
461
|
-
return /*#__PURE__*/React.createElement(Img, nameSpaceClassNames(props, 'img'));
|
|
462
|
-
},
|
|
463
|
-
div: function (props) {
|
|
464
|
-
return /*#__PURE__*/React.createElement(Div, nameSpaceClassNames(props, 'div'));
|
|
465
|
-
},
|
|
466
|
-
span: function (props) {
|
|
467
|
-
return /*#__PURE__*/React.createElement(Span, nameSpaceClassNames(props, 'span'));
|
|
468
|
-
},
|
|
469
|
-
li: function (props) {
|
|
470
|
-
return /*#__PURE__*/React.createElement(LI, nameSpaceClassNames(props, 'li'));
|
|
471
|
-
},
|
|
472
|
-
ul: function (props) {
|
|
473
|
-
return /*#__PURE__*/React.createElement(UL, nameSpaceClassNames(props, 'ul'));
|
|
474
|
-
},
|
|
475
|
-
ol: function (props) {
|
|
476
|
-
return /*#__PURE__*/React.createElement(OL, nameSpaceClassNames(props, 'ol'));
|
|
477
|
-
},
|
|
478
|
-
p: function (props) {
|
|
479
|
-
return /*#__PURE__*/React.createElement(P, nameSpaceClassNames(props, 'p'));
|
|
480
|
-
},
|
|
481
|
-
code: function (props) {
|
|
482
|
-
return /*#__PURE__*/React.createElement(Code, nameSpaceClassNames(props, 'code'));
|
|
483
|
-
},
|
|
484
|
-
tt: function (props) {
|
|
485
|
-
return /*#__PURE__*/React.createElement(TT, nameSpaceClassNames(props, 'tt'));
|
|
486
|
-
},
|
|
487
|
-
resetwrapper: function (props) {
|
|
488
|
-
return /*#__PURE__*/React.createElement(ResetWrapper, nameSpaceClassNames(props, 'resetwrapper'));
|
|
489
|
-
}
|
|
490
14
|
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { styled } from '@storybook/theming';
|
|
2
|
+
import { withReset } from './lib/common';
|
|
3
|
+
/**
|
|
4
|
+
* This is a "local" reset to style subtrees with Storybook styles
|
|
5
|
+
*
|
|
6
|
+
* We can't style individual elements (e.g. h1, h2, etc.) in here
|
|
7
|
+
* because the CSS specificity is too high, so those styles can too
|
|
8
|
+
* easily override child elements that are not expecting it.
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
export var ResetWrapper = styled.div(withReset);
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { nameSpaceClassNames } from './DocumentFormatting';
|
|
3
|
+
import { A } from './elements/A';
|
|
4
|
+
import { Blockquote } from './elements/Blockquote';
|
|
5
|
+
import { Code } from './elements/Code';
|
|
6
|
+
import { Div } from './elements/Div';
|
|
7
|
+
import { DL } from './elements/DL';
|
|
8
|
+
import { H1 } from './elements/H1';
|
|
9
|
+
import { H2 } from './elements/H2';
|
|
10
|
+
import { H3 } from './elements/H3';
|
|
11
|
+
import { H4 } from './elements/H4';
|
|
12
|
+
import { H5 } from './elements/H5';
|
|
13
|
+
import { H6 } from './elements/H6';
|
|
14
|
+
import { HR } from './elements/HR';
|
|
15
|
+
import { Img } from './elements/Img';
|
|
16
|
+
import { LI } from './elements/LI';
|
|
17
|
+
import { OL } from './elements/OL';
|
|
18
|
+
import { P } from './elements/P';
|
|
19
|
+
import { Pre } from './elements/Pre';
|
|
20
|
+
import { Span } from './elements/Span';
|
|
21
|
+
import { Table } from './elements/Table';
|
|
22
|
+
import { TT } from './elements/TT';
|
|
23
|
+
import { UL } from './elements/UL';
|
|
24
|
+
import { ResetWrapper } from './ResetWrapper';
|
|
25
|
+
export var components = {
|
|
26
|
+
h1: function h1(props) {
|
|
27
|
+
return /*#__PURE__*/React.createElement(H1, nameSpaceClassNames(props, 'h1'));
|
|
28
|
+
},
|
|
29
|
+
h2: function h2(props) {
|
|
30
|
+
return /*#__PURE__*/React.createElement(H2, nameSpaceClassNames(props, 'h2'));
|
|
31
|
+
},
|
|
32
|
+
h3: function h3(props) {
|
|
33
|
+
return /*#__PURE__*/React.createElement(H3, nameSpaceClassNames(props, 'h3'));
|
|
34
|
+
},
|
|
35
|
+
h4: function h4(props) {
|
|
36
|
+
return /*#__PURE__*/React.createElement(H4, nameSpaceClassNames(props, 'h4'));
|
|
37
|
+
},
|
|
38
|
+
h5: function h5(props) {
|
|
39
|
+
return /*#__PURE__*/React.createElement(H5, nameSpaceClassNames(props, 'h5'));
|
|
40
|
+
},
|
|
41
|
+
h6: function h6(props) {
|
|
42
|
+
return /*#__PURE__*/React.createElement(H6, nameSpaceClassNames(props, 'h6'));
|
|
43
|
+
},
|
|
44
|
+
pre: function pre(props) {
|
|
45
|
+
return /*#__PURE__*/React.createElement(Pre, nameSpaceClassNames(props, 'pre'));
|
|
46
|
+
},
|
|
47
|
+
a: function a(props) {
|
|
48
|
+
return /*#__PURE__*/React.createElement(A, nameSpaceClassNames(props, 'a'));
|
|
49
|
+
},
|
|
50
|
+
hr: function hr(props) {
|
|
51
|
+
return /*#__PURE__*/React.createElement(HR, nameSpaceClassNames(props, 'hr'));
|
|
52
|
+
},
|
|
53
|
+
dl: function dl(props) {
|
|
54
|
+
return /*#__PURE__*/React.createElement(DL, nameSpaceClassNames(props, 'dl'));
|
|
55
|
+
},
|
|
56
|
+
blockquote: function blockquote(props) {
|
|
57
|
+
return /*#__PURE__*/React.createElement(Blockquote, nameSpaceClassNames(props, 'blockquote'));
|
|
58
|
+
},
|
|
59
|
+
table: function table(props) {
|
|
60
|
+
return /*#__PURE__*/React.createElement(Table, nameSpaceClassNames(props, 'table'));
|
|
61
|
+
},
|
|
62
|
+
img: function img(props) {
|
|
63
|
+
return /*#__PURE__*/React.createElement(Img, nameSpaceClassNames(props, 'img'));
|
|
64
|
+
},
|
|
65
|
+
div: function div(props) {
|
|
66
|
+
return /*#__PURE__*/React.createElement(Div, nameSpaceClassNames(props, 'div'));
|
|
67
|
+
},
|
|
68
|
+
span: function span(props) {
|
|
69
|
+
return /*#__PURE__*/React.createElement(Span, nameSpaceClassNames(props, 'span'));
|
|
70
|
+
},
|
|
71
|
+
li: function li(props) {
|
|
72
|
+
return /*#__PURE__*/React.createElement(LI, nameSpaceClassNames(props, 'li'));
|
|
73
|
+
},
|
|
74
|
+
ul: function ul(props) {
|
|
75
|
+
return /*#__PURE__*/React.createElement(UL, nameSpaceClassNames(props, 'ul'));
|
|
76
|
+
},
|
|
77
|
+
ol: function ol(props) {
|
|
78
|
+
return /*#__PURE__*/React.createElement(OL, nameSpaceClassNames(props, 'ol'));
|
|
79
|
+
},
|
|
80
|
+
p: function p(props) {
|
|
81
|
+
return /*#__PURE__*/React.createElement(P, nameSpaceClassNames(props, 'p'));
|
|
82
|
+
},
|
|
83
|
+
code: function code(props) {
|
|
84
|
+
return /*#__PURE__*/React.createElement(Code, nameSpaceClassNames(props, 'code'));
|
|
85
|
+
},
|
|
86
|
+
tt: function tt(props) {
|
|
87
|
+
return /*#__PURE__*/React.createElement(TT, nameSpaceClassNames(props, 'tt'));
|
|
88
|
+
},
|
|
89
|
+
resetwrapper: function resetwrapper(props) {
|
|
90
|
+
return /*#__PURE__*/React.createElement(ResetWrapper, nameSpaceClassNames(props, 'resetwrapper'));
|
|
91
|
+
}
|
|
92
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { styled } from '@storybook/theming';
|
|
2
|
+
import { withReset } from '../lib/common';
|
|
3
|
+
import { Link } from './Link';
|
|
4
|
+
export var A = styled(Link)(withReset, function (_ref) {
|
|
5
|
+
var theme = _ref.theme;
|
|
6
|
+
return {
|
|
7
|
+
fontSize: 'inherit',
|
|
8
|
+
lineHeight: '24px',
|
|
9
|
+
color: theme.color.secondary,
|
|
10
|
+
textDecoration: 'none',
|
|
11
|
+
'&.absent': {
|
|
12
|
+
color: '#cc0000'
|
|
13
|
+
},
|
|
14
|
+
'&.anchor': {
|
|
15
|
+
display: 'block',
|
|
16
|
+
paddingLeft: 30,
|
|
17
|
+
marginLeft: -30,
|
|
18
|
+
cursor: 'pointer',
|
|
19
|
+
position: 'absolute',
|
|
20
|
+
top: 0,
|
|
21
|
+
left: 0,
|
|
22
|
+
bottom: 0
|
|
23
|
+
}
|
|
24
|
+
};
|
|
25
|
+
});
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { styled } from '@storybook/theming';
|
|
2
|
+
import { withReset, withMargin } from '../lib/common';
|
|
3
|
+
export var Blockquote = styled.blockquote(withReset, withMargin, function (_ref) {
|
|
4
|
+
var theme = _ref.theme;
|
|
5
|
+
return {
|
|
6
|
+
borderLeft: "4px solid ".concat(theme.color.medium),
|
|
7
|
+
padding: '0 15px',
|
|
8
|
+
color: theme.color.dark,
|
|
9
|
+
'& > :first-of-type': {
|
|
10
|
+
marginTop: 0
|
|
11
|
+
},
|
|
12
|
+
'& > :last-child': {
|
|
13
|
+
marginBottom: 0
|
|
14
|
+
}
|
|
15
|
+
};
|
|
16
|
+
});
|