Skip to content

Commit 63e7b59

Browse files
authored
Merge pull request #88 from aeagle/hotfix/20210515-npm-audit-fix
Hotfix/20210515 npm audit fix
2 parents 93bf9dd + 7847cb8 commit 63e7b59

34 files changed

+10633
-6983
lines changed

.storybook/main.js

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,23 @@
11
const path = require("path");
22

33
module.exports = {
4-
stories: ["./../**/*.stories.@(mdx|tsx)"],
5-
addons: ["@storybook/addon-actions", "@storybook/addon-links", "@storybook/addon-docs/preset"],
4+
stories: ["../src/**/*.stories.@(mdx|tsx)"],
5+
addons: [
6+
"@storybook/addon-actions",
7+
"@storybook/addon-links",
8+
{
9+
name: "@storybook/addon-docs/preset",
10+
options: {
11+
configureJSX: true,
12+
inlineStories: false,
13+
},
14+
},
15+
],
16+
typescript: {
17+
check: true,
18+
checkOptions: {},
19+
reactDocgen: "react-docgen-typescript",
20+
},
621
webpackFinal: async (config, { configType }) => {
722
if (process.env.NODE === "production") {
823
config.output.publicPath = "/react-spaces/docs";

.storybook/preview-head.html

Lines changed: 10 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -5,33 +5,21 @@
55
font-family: "Ubuntu", sans-serif;
66
font-size: 12px;
77
}
8-
.sbdocs-wrapper {
9-
padding: 15px !important;
10-
}
11-
.sbdocs-wrapper h2 {
12-
font-weight: 300 !important;
13-
border-bottom: none !important;
14-
margin-bottom: 20px !important;
15-
}
16-
.sbdocs-wrapper h4 {
17-
margin-top: 20px !important;
18-
font-weight: 500 !important;
19-
}
20-
.sbdocs-wrapper p,
21-
.sbdocs-wrapper li {
22-
font-size: 16px !important;
23-
}
24-
.sbdocs-preview > div > div > div {
25-
margin-bottom: 15px;
8+
9+
.docblock-source {
10+
margin: 25px 0 !important;
2611
}
27-
.sbdocs-preview > div > div > div > div > div {
12+
13+
.docs-story > div > div > div > div > div > div {
2814
position: relative;
29-
height: 600px;
15+
height: 600px !important;
3016
outline: 1px solid black;
3117
}
32-
.docblock-source {
33-
margin: 25px 0 !important;
18+
19+
.container-container {
20+
outline: solid black 1px;
3421
}
22+
3523
.spaces-resize-handle {
3624
background-color: red !important;
3725
}

.storybook/preview.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
import { addParameters } from "@storybook/react";
2+
3+
addParameters({
4+
docs: {
5+
inlineStories: false,
6+
},
7+
});

package-lock.json

Lines changed: 10403 additions & 6773 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "react-spaces",
3-
"version": "0.2.0",
3+
"version": "0.2.1",
44
"main": "dist/index.js",
55
"module": "dist/es/index.js",
66
"types": "dist/index.d.ts",
@@ -32,12 +32,12 @@
3232
},
3333
"devDependencies": {
3434
"@babel/core": "^7.5.5",
35-
"@storybook/addon-actions": "^6.1.11",
36-
"@storybook/addon-docs": "^6.1.11",
37-
"@storybook/addon-knobs": "^6.1.11",
38-
"@storybook/addon-links": "^6.1.11",
39-
"@storybook/addons": "^6.1.11",
40-
"@storybook/react": "^6.1.11",
35+
"@storybook/addon-actions": "^6.2.9",
36+
"@storybook/addon-docs": "^6.2.9",
37+
"@storybook/addon-knobs": "^6.2.9",
38+
"@storybook/addon-links": "^6.2.9",
39+
"@storybook/addons": "^6.2.9",
40+
"@storybook/react": "^6.2.9",
4141
"@testing-library/jest-dom": "^5.5.0",
4242
"@testing-library/react": "^10.0.3",
4343
"@types/jest": "^24.0.15",
@@ -61,6 +61,7 @@
6161
"rollup": "^1.19.4",
6262
"rollup-plugin-babel": "^4.3.3",
6363
"rollup-plugin-commonjs": "^10.0.2",
64+
"rollup-plugin-fork-ts-checker": "0.0.6",
6465
"rollup-plugin-node-resolve": "^5.2.0",
6566
"rollup-plugin-postcss": "^2.0.3",
6667
"rollup-plugin-replace": "^2.2.0",
@@ -72,7 +73,7 @@
7273
"ts-jest": "^25.4.0",
7374
"ts-loader": "^6.2.1",
7475
"tslib": "^1.10.0",
75-
"typescript": "^3.5.3"
76+
"typescript": "^3.9.9"
7677
},
7778
"resolutions": {
7879
"cssstyle": "2.3.0"

rollup.config.js

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,15 @@ import postcss from "rollup-plugin-postcss";
77
import { uglify } from "rollup-plugin-uglify";
88
import pkg from "./package.json";
99

10-
const commonPlugins = [typescript({ typescript: require("typescript"), sourceMap: true }), resolve(), commonjs(), sourcemaps()];
10+
const commonPlugins = [
11+
typescript({
12+
typescript: require("typescript"),
13+
sourceMap: true,
14+
}),
15+
resolve(),
16+
commonjs(),
17+
sourcemaps(),
18+
];
1119

1220
const targets = [
1321
{

src/components/stories/00-docs/00-Intro.stories.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Meta, Story, Preview, Props } from "@storybook/addon-docs/blocks";
1+
import { Meta, Story, Canvas, Props } from "@storybook/addon-docs/blocks";
22
import { CommonHeader } from "../Utils";
33

44
<CommonHeader />

src/components/stories/00-docs/01-GettingStarted.stories.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Meta, Story, Preview, Props } from "@storybook/addon-docs/blocks";
1+
import { Meta, Story, Canvas, Props } from "@storybook/addon-docs/blocks";
22
import { CommonHeader, DemoUI } from "../Utils";
33
import { CenterType, ViewPort, Fixed, Top, Right, LeftResizable, BottomResizable, Fill, Options } from "../../";
44

@@ -48,7 +48,7 @@ have any visual element, padding or margins leaving it up to you to fill them or
4848
you want.*
4949

5050
<React.StrictMode>
51-
<Fixed style={{ outline: '1px solid black' }} height={400}>
51+
<Fixed style={{ outline: '1px solid black' }} className="container" height={400}>
5252
<LeftResizable style={{ borderRight: '1px dashed black' }} size="25%" centerContent={CenterType.HorizontalVertical}>
5353
Sidebar
5454
</LeftResizable>
@@ -88,7 +88,7 @@ const App = () => (
8888
Here we have added additional nested spaces inside the original `<Fill />` space to achieve this:
8989

9090
<React.StrictMode>
91-
<Fixed style={{ outline: '1px solid black' }} height={400}>
91+
<Fixed style={{ outline: '1px solid black' }} className="container" height={400}>
9292
<LeftResizable style={{ borderRight: '1px dashed black' }} size="25%" centerContent={CenterType.HorizontalVertical}>
9393
Sidebar
9494
</LeftResizable>
@@ -141,7 +141,7 @@ const App = () => (
141141
Now we have something like below:
142142

143143
<React.StrictMode>
144-
<Fixed style={{ outline: '1px solid black' }} height={400}>
144+
<Fixed style={{ outline: '1px solid black' }} className="container" height={400}>
145145
<Top style={{ borderBottom: '1px dashed black', padding: 5 }} order={1} size={25} centerContent={CenterType.Vertical}>
146146
Title
147147
</Top>

src/components/stories/00-docs/02-UsefulProperties.stories.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Meta, Story, Preview, Props } from "@storybook/addon-docs/blocks";
1+
import { Meta, Story, Canvas, Props } from "@storybook/addon-docs/blocks";
22
import { CommonHeader, PropsTable, StandardProps } from "../Utils";
33

44
<CommonHeader />

src/components/stories/00-docs/03-UsefulEvents.stories.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Meta, Story, Preview, Props } from "@storybook/addon-docs/blocks";
1+
import { Meta, Story, Canvas, Props } from "@storybook/addon-docs/blocks";
22
import { CommonHeader } from "../Utils";
33

44
<CommonHeader />

0 commit comments

Comments
 (0)