gov-ui-core 0.2.6-beta.9 → 0.2.6

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.
Files changed (114) hide show
  1. package/.storybook/main.ts +36 -37
  2. package/.storybook/preview.tsx +27 -27
  3. package/@types/custom.d.ts +43 -43
  4. package/@types/styles.d.ts +3 -86
  5. package/README.md +46 -46
  6. package/build/App.d.ts +3 -3
  7. package/build/Main.d.ts +5 -5
  8. package/build/components/Button/DropdownButton.d.ts +15 -15
  9. package/build/components/Button/SwitchButton.d.ts +7 -7
  10. package/build/components/Button/index.d.ts +11 -11
  11. package/build/components/Button/styled.d.ts +10 -11
  12. package/build/components/Calendar/CalendarNavigation.d.ts +9 -9
  13. package/build/components/Calendar/constants.d.ts +2 -2
  14. package/build/components/Calendar/index.d.ts +11 -11
  15. package/build/components/Calendar/styled.d.ts +2 -2
  16. package/build/components/Carousel/ArrowButton.d.ts +7 -7
  17. package/build/components/Carousel/index.d.ts +14 -14
  18. package/build/components/Carousel/styled.d.ts +2 -2
  19. package/build/components/Directory/index.d.ts +32 -32
  20. package/build/components/Directory/styled.d.ts +6 -6
  21. package/build/components/EmptyBox/index.d.ts +8 -8
  22. package/build/components/EmptyBox/styled.d.ts +4 -4
  23. package/build/components/Form/Form.d.ts +21 -21
  24. package/build/components/Form/Group.d.ts +6 -6
  25. package/build/components/Form/Item.d.ts +22 -22
  26. package/build/components/Form/index.d.ts +14 -14
  27. package/build/components/Form/styled.d.ts +7 -7
  28. package/build/components/Header/ContentHeader.d.ts +15 -15
  29. package/build/components/Header/styled.d.ts +5 -5
  30. package/build/components/Icons/index.d.ts +14 -14
  31. package/build/components/Input/Checkbox.d.ts +19 -19
  32. package/build/components/Input/ErrorMessage.d.ts +8 -8
  33. package/build/components/Input/Input.d.ts +23 -23
  34. package/build/components/Input/InputNumber.d.ts +8 -8
  35. package/build/components/Input/Radio.d.ts +16 -16
  36. package/build/components/Input/Search.d.ts +13 -13
  37. package/build/components/Input/Select.d.ts +39 -40
  38. package/build/components/Input/TextArea.d.ts +15 -15
  39. package/build/components/Input/index.d.ts +19 -19
  40. package/build/components/Input/styled.d.ts +25 -25
  41. package/build/components/IntlText/index.d.ts +5 -5
  42. package/build/components/Loading/OverlayLoading.d.ts +10 -10
  43. package/build/components/Loading/Spinner.d.ts +9 -9
  44. package/build/components/Loading/styled.d.ts +10 -10
  45. package/build/components/Styled/mixins.d.ts +13 -13
  46. package/build/components/Styled/variable.d.ts +6 -6
  47. package/build/components/Table/AppendTable.d.ts +26 -26
  48. package/build/components/Table/AutoTooltip.d.ts +8 -8
  49. package/build/components/Table/TableBase.d.ts +16 -16
  50. package/build/components/Table/TableLoading.d.ts +9 -9
  51. package/build/components/Table/components/Pagination.d.ts +18 -18
  52. package/build/components/Table/components/PaginationItem.d.ts +9 -9
  53. package/build/components/Table/index.d.ts +27 -27
  54. package/build/components/Table/styled.d.ts +25 -25
  55. package/build/components/ThemeProvider.d.ts +16 -16
  56. package/build/globalStyle.d.ts +5 -5
  57. package/build/index.d.ts +1 -1
  58. package/build/index.js +1 -1
  59. package/build/modules.d.ts +23 -24
  60. package/build/pages/CreateTable.d.ts +20 -20
  61. package/build/pages/FormSample.d.ts +5 -5
  62. package/build/pages/Sample.d.ts +5 -5
  63. package/build/pages/Sample2.d.ts +5 -5
  64. package/build/pages/Sample3.d.ts +5 -5
  65. package/build/pages/Sample4.d.ts +5 -5
  66. package/build/pages/TableSample.d.ts +5 -5
  67. package/build/pages/sampleData.d.ts +59 -59
  68. package/build/reportWebVitals.d.ts +3 -3
  69. package/build/theme.d.ts +45 -3
  70. package/build/utils/customState.d.ts +28 -28
  71. package/build/utils/hookUtils.d.ts +16 -16
  72. package/build/utils/index.d.ts +35 -35
  73. package/config/env.js +104 -104
  74. package/config/getHttpsConfig.js +66 -66
  75. package/config/jest/babelTransform.js +29 -29
  76. package/config/jest/cssTransform.js +14 -14
  77. package/config/jest/fileTransform.js +40 -40
  78. package/config/modules.js +134 -134
  79. package/config/paths.js +77 -77
  80. package/config/webpack/persistentCache/createEnvironmentHash.js +9 -9
  81. package/config/webpack.config.js +756 -756
  82. package/config/webpack.prod.config.js +91 -91
  83. package/config/webpackDevServer.config.js +127 -127
  84. package/doctor-storybook.log +18 -0
  85. package/migration-storybook.log +98 -0
  86. package/package.json +215 -247
  87. package/public/index.html +43 -43
  88. package/public/manifest.json +25 -25
  89. package/public/robots.txt +3 -3
  90. package/scripts/build.js +217 -217
  91. package/scripts/start.js +154 -154
  92. package/scripts/test.js +52 -52
  93. package/tsconfig.json +34 -34
  94. package/.eslintrc.json +0 -54
  95. package/.husky/pre-commit +0 -4
  96. package/.prettierrc +0 -12
  97. package/.stylelintrc.json +0 -16
  98. package/build/20d0d451f31ed3b5c15f.woff +0 -1
  99. package/build/39285e8af490890e2df4.otf +0 -0
  100. package/build/3965b6176d1ce958b445.woff +0 -1
  101. package/build/508d69efb37042551458.woff +0 -1
  102. package/build/72ba455576ce8174ffa8.otf +0 -0
  103. package/build/a9ba4978d441af03cd27.woff +0 -1
  104. package/build/components/Button/constants.d.ts +0 -19
  105. package/build/components/Chip/constants.d.ts +0 -9
  106. package/build/components/Chip/index.d.ts +0 -12
  107. package/build/e65c7edcd47e3e9f5c99.otf +0 -0
  108. package/build/f7a8dce8dfc249d7e12b.otf +0 -0
  109. package/build/pages/ButtonSample.d.ts +0 -6
  110. package/build/pages/ChipSample.d.ts +0 -6
  111. package/build/pages/InputSample.d.ts +0 -6
  112. package/build/pages/TailwindSample.d.ts +0 -1
  113. package/postcss.config.js +0 -8
  114. package/tailwind.config.js +0 -185
@@ -1,91 +1,91 @@
1
- const path = require('path');
2
- const { CleanWebpackPlugin } = require('clean-webpack-plugin')
3
- const MiniCssExtractPlugin = require('mini-css-extract-plugin');
4
- const paths = require('./paths');
5
-
6
- module.exports = function () {
7
- return {
8
- mode: 'production',
9
-
10
- entry: './src/modules.ts',
11
-
12
- resolve: {
13
- modules: ['node_modules'],
14
- extensions: ['.ts', '.tsx', '.js', '.json'],
15
- alias: {
16
- '@': paths.appSrc,
17
- react: path.resolve('./node_modules/react'),
18
- },
19
- },
20
- output: {
21
- filename: 'index.js',
22
- libraryTarget: 'umd',
23
- path: paths.appBuild,
24
- },
25
-
26
- module: {
27
- rules: [
28
- // {
29
- // test: /\.(js|jsx|ts|tsx)?$/,
30
- // loader: 'esbuild-loader',
31
- // options: {
32
- // loader: 'tsx',
33
- // target: 'es2015',
34
- // },
35
- // },
36
- {
37
- test: /\.(js|ts)$/,
38
- exclude: /(node_modules)/,
39
- use: {
40
- loader: 'babel-loader',
41
- options: {
42
- presets: [
43
- '@babel/preset-env',
44
- '@babel/preset-typescript',
45
- '@babel/preset-react',
46
- ],
47
- // plugins: [
48
- // ['@babel/plugin-proposal-class-properties', { loose: true }],
49
- // '@babel/plugin-proposal-object-rest-spread',
50
- // ],
51
- },
52
- },
53
- },
54
- {
55
- test: /\.tsx?$/,
56
- use: 'ts-loader',
57
- exclude: /node_modules/,
58
- },
59
- {
60
- test: /\.(sa|sc|c)ss$/,
61
- use: ['style-loader', 'css-loader', 'sass-loader']
62
- },
63
- {
64
- test: /\.(png|jpe?g|gif|eot|woff|woff2|ttf|svg)$/,
65
- use: {
66
- loader: 'url-loader'
67
- }
68
- },
69
- ],
70
- },
71
-
72
- plugins: [
73
- new CleanWebpackPlugin(),
74
- new MiniCssExtractPlugin(),
75
- ],
76
- externals: {
77
- react: {
78
- commonjs: 'react',
79
- commonjs2: 'react',
80
- amd: 'react',
81
- root: 'React',
82
- },
83
- 'react-dom': {
84
- commonjs: 'react-dom',
85
- commonjs2: 'react-dom',
86
- amd: 'react-dom',
87
- root: 'ReactDOM',
88
- },
89
- },
90
- }
91
- };
1
+ const path = require('path');
2
+ const { CleanWebpackPlugin } = require('clean-webpack-plugin')
3
+ const MiniCssExtractPlugin = require('mini-css-extract-plugin');
4
+ const paths = require('./paths');
5
+
6
+ module.exports = function () {
7
+ return {
8
+ mode: 'production',
9
+
10
+ entry: './src/modules.ts',
11
+
12
+ resolve: {
13
+ modules: ['node_modules'],
14
+ extensions: ['.ts', '.tsx', '.js', '.json'],
15
+ alias: {
16
+ '@': paths.appSrc,
17
+ react: path.resolve('./node_modules/react'),
18
+ },
19
+ },
20
+ output: {
21
+ filename: 'index.js',
22
+ libraryTarget: 'umd',
23
+ path: paths.appBuild,
24
+ },
25
+
26
+ module: {
27
+ rules: [
28
+ // {
29
+ // test: /\.(js|jsx|ts|tsx)?$/,
30
+ // loader: 'esbuild-loader',
31
+ // options: {
32
+ // loader: 'tsx',
33
+ // target: 'es2015',
34
+ // },
35
+ // },
36
+ {
37
+ test: /\.(js|ts)$/,
38
+ exclude: /(node_modules)/,
39
+ use: {
40
+ loader: 'babel-loader',
41
+ options: {
42
+ presets: [
43
+ '@babel/preset-env',
44
+ '@babel/preset-typescript',
45
+ '@babel/preset-react',
46
+ ],
47
+ // plugins: [
48
+ // ['@babel/plugin-proposal-class-properties', { loose: true }],
49
+ // '@babel/plugin-proposal-object-rest-spread',
50
+ // ],
51
+ },
52
+ },
53
+ },
54
+ {
55
+ test: /\.tsx?$/,
56
+ use: 'ts-loader',
57
+ exclude: /node_modules/,
58
+ },
59
+ {
60
+ test: /\.(sa|sc|c)ss$/,
61
+ use: ['style-loader', 'css-loader', 'sass-loader']
62
+ },
63
+ {
64
+ test: /\.(png|jpe?g|gif|eot|woff|woff2|ttf|svg)$/,
65
+ use: {
66
+ loader: 'url-loader'
67
+ }
68
+ },
69
+ ],
70
+ },
71
+
72
+ plugins: [
73
+ new CleanWebpackPlugin(),
74
+ new MiniCssExtractPlugin(),
75
+ ],
76
+ externals: {
77
+ react: {
78
+ commonjs: 'react',
79
+ commonjs2: 'react',
80
+ amd: 'react',
81
+ root: 'React',
82
+ },
83
+ 'react-dom': {
84
+ commonjs: 'react-dom',
85
+ commonjs2: 'react-dom',
86
+ amd: 'react-dom',
87
+ root: 'ReactDOM',
88
+ },
89
+ },
90
+ }
91
+ };
@@ -1,127 +1,127 @@
1
- 'use strict';
2
-
3
- const fs = require('fs');
4
- const evalSourceMapMiddleware = require('react-dev-utils/evalSourceMapMiddleware');
5
- const noopServiceWorkerMiddleware = require('react-dev-utils/noopServiceWorkerMiddleware');
6
- const ignoredFiles = require('react-dev-utils/ignoredFiles');
7
- const redirectServedPath = require('react-dev-utils/redirectServedPathMiddleware');
8
- const paths = require('./paths');
9
- const getHttpsConfig = require('./getHttpsConfig');
10
-
11
- const host = process.env.HOST || '0.0.0.0';
12
- const sockHost = process.env.WDS_SOCKET_HOST;
13
- const sockPath = process.env.WDS_SOCKET_PATH; // default: '/ws'
14
- const sockPort = process.env.WDS_SOCKET_PORT;
15
-
16
- module.exports = function (proxy, allowedHost) {
17
- const disableFirewall =
18
- !proxy || process.env.DANGEROUSLY_DISABLE_HOST_CHECK === 'true';
19
- return {
20
- // WebpackDevServer 2.4.3 introduced a security fix that prevents remote
21
- // websites from potentially accessing local content through DNS rebinding:
22
- // https://github.com/webpack/webpack-dev-server/issues/887
23
- // https://medium.com/webpack/webpack-dev-server-middleware-security-issues-1489d950874a
24
- // However, it made several existing use cases such as development in cloud
25
- // environment or subdomains in development significantly more complicated:
26
- // https://github.com/facebook/create-react-app/issues/2271
27
- // https://github.com/facebook/create-react-app/issues/2233
28
- // While we're investigating better solutions, for now we will take a
29
- // compromise. Since our WDS configuration only serves files in the `public`
30
- // folder we won't consider accessing them a vulnerability. However, if you
31
- // use the `proxy` feature, it gets more dangerous because it can expose
32
- // remote code execution vulnerabilities in backends like Django and Rails.
33
- // So we will disable the host check normally, but enable it if you have
34
- // specified the `proxy` setting. Finally, we let you override it if you
35
- // really know what you're doing with a special environment variable.
36
- // Note: ["localhost", ".localhost"] will support subdomains - but we might
37
- // want to allow setting the allowedHosts manually for more complex setups
38
- allowedHosts: disableFirewall ? 'all' : [allowedHost],
39
- headers: {
40
- 'Access-Control-Allow-Origin': '*',
41
- 'Access-Control-Allow-Methods': '*',
42
- 'Access-Control-Allow-Headers': '*',
43
- },
44
- // Enable gzip compression of generated files.
45
- compress: true,
46
- static: {
47
- // By default WebpackDevServer serves physical files from current directory
48
- // in addition to all the virtual build products that it serves from memory.
49
- // This is confusing because those files won’t automatically be available in
50
- // production build folder unless we copy them. However, copying the whole
51
- // project directory is dangerous because we may expose sensitive files.
52
- // Instead, we establish a convention that only files in `public` directory
53
- // get served. Our build script will copy `public` into the `build` folder.
54
- // In `index.html`, you can get URL of `public` folder with %PUBLIC_URL%:
55
- // <link rel="icon" href="%PUBLIC_URL%/favicon.ico">
56
- // In JavaScript code, you can access it with `process.env.PUBLIC_URL`.
57
- // Note that we only recommend to use `public` folder as an escape hatch
58
- // for files like `favicon.ico`, `manifest.json`, and libraries that are
59
- // for some reason broken when imported through webpack. If you just want to
60
- // use an image, put it in `src` and `import` it from JavaScript instead.
61
- directory: paths.appPublic,
62
- publicPath: [paths.publicUrlOrPath],
63
- // By default files from `contentBase` will not trigger a page reload.
64
- watch: {
65
- // Reportedly, this avoids CPU overload on some systems.
66
- // https://github.com/facebook/create-react-app/issues/293
67
- // src/node_modules is not ignored to support absolute imports
68
- // https://github.com/facebook/create-react-app/issues/1065
69
- ignored: ignoredFiles(paths.appSrc),
70
- },
71
- },
72
- client: {
73
- webSocketURL: {
74
- // Enable custom sockjs pathname for websocket connection to hot reloading server.
75
- // Enable custom sockjs hostname, pathname and port for websocket connection
76
- // to hot reloading server.
77
- hostname: sockHost,
78
- pathname: sockPath,
79
- port: sockPort,
80
- },
81
- overlay: {
82
- errors: true,
83
- warnings: false,
84
- },
85
- },
86
- devMiddleware: {
87
- // It is important to tell WebpackDevServer to use the same "publicPath" path as
88
- // we specified in the webpack config. When homepage is '.', default to serving
89
- // from the root.
90
- // remove last slash so user can land on `/test` instead of `/test/`
91
- publicPath: paths.publicUrlOrPath.slice(0, -1),
92
- },
93
-
94
- https: getHttpsConfig(),
95
- host,
96
- historyApiFallback: {
97
- // Paths with dots should still use the history fallback.
98
- // See https://github.com/facebook/create-react-app/issues/387.
99
- disableDotRule: true,
100
- index: paths.publicUrlOrPath,
101
- },
102
- // `proxy` is run between `before` and `after` `webpack-dev-server` hooks
103
- proxy,
104
- onBeforeSetupMiddleware(devServer) {
105
- // Keep `evalSourceMapMiddleware`
106
- // middlewares before `redirectServedPath` otherwise will not have any effect
107
- // This lets us fetch source contents from webpack for the error overlay
108
- devServer.app.use(evalSourceMapMiddleware(devServer));
109
-
110
- if (fs.existsSync(paths.proxySetup)) {
111
- // This registers user provided middleware for proxy reasons
112
- require(paths.proxySetup)(devServer.app);
113
- }
114
- },
115
- onAfterSetupMiddleware(devServer) {
116
- // Redirect to `PUBLIC_URL` or `homepage` from `package.json` if url not match
117
- devServer.app.use(redirectServedPath(paths.publicUrlOrPath));
118
-
119
- // This service worker file is effectively a 'no-op' that will reset any
120
- // previous service worker registered for the same host:port combination.
121
- // We do this in development to avoid hitting the production cache if
122
- // it used the same host and port.
123
- // https://github.com/facebook/create-react-app/issues/2272#issuecomment-302832432
124
- devServer.app.use(noopServiceWorkerMiddleware(paths.publicUrlOrPath));
125
- },
126
- };
127
- };
1
+ 'use strict';
2
+
3
+ const fs = require('fs');
4
+ const evalSourceMapMiddleware = require('react-dev-utils/evalSourceMapMiddleware');
5
+ const noopServiceWorkerMiddleware = require('react-dev-utils/noopServiceWorkerMiddleware');
6
+ const ignoredFiles = require('react-dev-utils/ignoredFiles');
7
+ const redirectServedPath = require('react-dev-utils/redirectServedPathMiddleware');
8
+ const paths = require('./paths');
9
+ const getHttpsConfig = require('./getHttpsConfig');
10
+
11
+ const host = process.env.HOST || '0.0.0.0';
12
+ const sockHost = process.env.WDS_SOCKET_HOST;
13
+ const sockPath = process.env.WDS_SOCKET_PATH; // default: '/ws'
14
+ const sockPort = process.env.WDS_SOCKET_PORT;
15
+
16
+ module.exports = function (proxy, allowedHost) {
17
+ const disableFirewall =
18
+ !proxy || process.env.DANGEROUSLY_DISABLE_HOST_CHECK === 'true';
19
+ return {
20
+ // WebpackDevServer 2.4.3 introduced a security fix that prevents remote
21
+ // websites from potentially accessing local content through DNS rebinding:
22
+ // https://github.com/webpack/webpack-dev-server/issues/887
23
+ // https://medium.com/webpack/webpack-dev-server-middleware-security-issues-1489d950874a
24
+ // However, it made several existing use cases such as development in cloud
25
+ // environment or subdomains in development significantly more complicated:
26
+ // https://github.com/facebook/create-react-app/issues/2271
27
+ // https://github.com/facebook/create-react-app/issues/2233
28
+ // While we're investigating better solutions, for now we will take a
29
+ // compromise. Since our WDS configuration only serves files in the `public`
30
+ // folder we won't consider accessing them a vulnerability. However, if you
31
+ // use the `proxy` feature, it gets more dangerous because it can expose
32
+ // remote code execution vulnerabilities in backends like Django and Rails.
33
+ // So we will disable the host check normally, but enable it if you have
34
+ // specified the `proxy` setting. Finally, we let you override it if you
35
+ // really know what you're doing with a special environment variable.
36
+ // Note: ["localhost", ".localhost"] will support subdomains - but we might
37
+ // want to allow setting the allowedHosts manually for more complex setups
38
+ allowedHosts: disableFirewall ? 'all' : [allowedHost],
39
+ headers: {
40
+ 'Access-Control-Allow-Origin': '*',
41
+ 'Access-Control-Allow-Methods': '*',
42
+ 'Access-Control-Allow-Headers': '*',
43
+ },
44
+ // Enable gzip compression of generated files.
45
+ compress: true,
46
+ static: {
47
+ // By default WebpackDevServer serves physical files from current directory
48
+ // in addition to all the virtual build products that it serves from memory.
49
+ // This is confusing because those files won’t automatically be available in
50
+ // production build folder unless we copy them. However, copying the whole
51
+ // project directory is dangerous because we may expose sensitive files.
52
+ // Instead, we establish a convention that only files in `public` directory
53
+ // get served. Our build script will copy `public` into the `build` folder.
54
+ // In `index.html`, you can get URL of `public` folder with %PUBLIC_URL%:
55
+ // <link rel="icon" href="%PUBLIC_URL%/favicon.ico">
56
+ // In JavaScript code, you can access it with `process.env.PUBLIC_URL`.
57
+ // Note that we only recommend to use `public` folder as an escape hatch
58
+ // for files like `favicon.ico`, `manifest.json`, and libraries that are
59
+ // for some reason broken when imported through webpack. If you just want to
60
+ // use an image, put it in `src` and `import` it from JavaScript instead.
61
+ directory: paths.appPublic,
62
+ publicPath: [paths.publicUrlOrPath],
63
+ // By default files from `contentBase` will not trigger a page reload.
64
+ watch: {
65
+ // Reportedly, this avoids CPU overload on some systems.
66
+ // https://github.com/facebook/create-react-app/issues/293
67
+ // src/node_modules is not ignored to support absolute imports
68
+ // https://github.com/facebook/create-react-app/issues/1065
69
+ ignored: ignoredFiles(paths.appSrc),
70
+ },
71
+ },
72
+ client: {
73
+ webSocketURL: {
74
+ // Enable custom sockjs pathname for websocket connection to hot reloading server.
75
+ // Enable custom sockjs hostname, pathname and port for websocket connection
76
+ // to hot reloading server.
77
+ hostname: sockHost,
78
+ pathname: sockPath,
79
+ port: sockPort,
80
+ },
81
+ overlay: {
82
+ errors: true,
83
+ warnings: false,
84
+ },
85
+ },
86
+ devMiddleware: {
87
+ // It is important to tell WebpackDevServer to use the same "publicPath" path as
88
+ // we specified in the webpack config. When homepage is '.', default to serving
89
+ // from the root.
90
+ // remove last slash so user can land on `/test` instead of `/test/`
91
+ publicPath: paths.publicUrlOrPath.slice(0, -1),
92
+ },
93
+
94
+ https: getHttpsConfig(),
95
+ host,
96
+ historyApiFallback: {
97
+ // Paths with dots should still use the history fallback.
98
+ // See https://github.com/facebook/create-react-app/issues/387.
99
+ disableDotRule: true,
100
+ index: paths.publicUrlOrPath,
101
+ },
102
+ // `proxy` is run between `before` and `after` `webpack-dev-server` hooks
103
+ proxy,
104
+ onBeforeSetupMiddleware(devServer) {
105
+ // Keep `evalSourceMapMiddleware`
106
+ // middlewares before `redirectServedPath` otherwise will not have any effect
107
+ // This lets us fetch source contents from webpack for the error overlay
108
+ devServer.app.use(evalSourceMapMiddleware(devServer));
109
+
110
+ if (fs.existsSync(paths.proxySetup)) {
111
+ // This registers user provided middleware for proxy reasons
112
+ require(paths.proxySetup)(devServer.app);
113
+ }
114
+ },
115
+ onAfterSetupMiddleware(devServer) {
116
+ // Redirect to `PUBLIC_URL` or `homepage` from `package.json` if url not match
117
+ devServer.app.use(redirectServedPath(paths.publicUrlOrPath));
118
+
119
+ // This service worker file is effectively a 'no-op' that will reset any
120
+ // previous service worker registered for the same host:port combination.
121
+ // We do this in development to avoid hitting the production cache if
122
+ // it used the same host and port.
123
+ // https://github.com/facebook/create-react-app/issues/2272#issuecomment-302832432
124
+ devServer.app.use(noopServiceWorkerMiddleware(paths.publicUrlOrPath));
125
+ },
126
+ };
127
+ };
@@ -0,0 +1,18 @@
1
+ 🩺 The doctor is checking the health of your Storybook..
2
+ ╭ Incompatible packages found ───────────────────────────────────────────────────────────────────────────────────────────────────────╮
3
+ │ │
4
+ │ The following packages are incompatible with Storybook 8.0.4 as they depend on different major versions of Storybook packages: │
5
+ │ - @storybook/addon-knobs@7.0.2 │
6
+ │ │
7
+ │ │
8
+ │ Please consider updating your packages or contacting the maintainers for compatibility details. │
9
+ │ For more on Storybook 8 compatibility, see the linked GitHub issue: │
10
+ │ https://github.com/storybookjs/storybook/issues/26031 │
11
+ │ │
12
+ ╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
13
+
14
+ You can always recheck the health of your project by running:
15
+ npx storybook doctor
16
+
17
+ Full logs are available in /Users/yoon/WebstormProjects/nexr/neb-ui-new/doctor-storybook.log
18
+
@@ -0,0 +1,98 @@
1
+ 🔎 checking possible migrations..
2
+
3
+ 🔎 found a 'upgradeStorybookRelatedDependencies' migration:
4
+ ╭ Automigration detected ────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
5
+ │ │
6
+ │ You're upgrading to the latest version of Storybook. We recommend upgrading the following packages: │
7
+ │ - @chromatic-com/storybook: 1.2.25 => 3.2.2 │
8
+ │ - @storybook/addon-knobs: 7.0.2 => 8.0.1 │
9
+ │ - eslint-plugin-storybook: 0.8.0 => 0.11.1 │
10
+ │ │
11
+ │ After upgrading, we will run the dedupe command, which could possibly have effects on dependencies that are not Storybook related. │
12
+ │ see: https://docs.npmjs.com/cli/commands/npm-dedupe │
13
+ │ │
14
+ │ Do you want to proceed (upgrade the detected packages)? │
15
+ │ │
16
+ ╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
17
+ ? Do you want to run the 'upgradeStorybookRelatedDependencies' migration on your project? › (y/N)✔ Do you want to run the 'upgradeStorybookRelatedDependencies' migration on your project? … yes
18
+ Installing dependencies...
19
+
20
+ An error occurred while installing dependencies.
21
+ ❌ error when running upgradeStorybookRelatedDependencies migration
22
+ HandledError: Error: Command failed with exit code 1: npm install
23
+ at Ar.installDependencies (/Users/yoon/.npm/_npx/7122ab1f221a777a/node_modules/@storybook/core/dist/common/index.cjs:18947:75)
24
+ at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
25
+ at async Object.run (/Users/yoon/.npm/_npx/7122ab1f221a777a/node_modules/@storybook/cli/dist/bin/index.cjs:448:541)
26
+ ... 2 lines matching cause stack trace ...
27
+ at async doUpgrade (/Users/yoon/.npm/_npx/7122ab1f221a777a/node_modules/@storybook/cli/dist/bin/index.cjs:600:1612)
28
+ at async withTelemetry (/Users/yoon/.npm/_npx/7122ab1f221a777a/node_modules/@storybook/core/dist/core-server/index.cjs:35757:12)
29
+ at async upgrade (/Users/yoon/.npm/_npx/7122ab1f221a777a/node_modules/@storybook/cli/dist/bin/index.cjs:600:2078) {
30
+ handled: true,
31
+ cause: Error: Command failed with exit code 1: npm install
32
+ at makeError (/Users/yoon/.npm/_npx/7122ab1f221a777a/node_modules/@storybook/core/dist/common/index.cjs:18141:67)
33
+ at handlePromise (/Users/yoon/.npm/_npx/7122ab1f221a777a/node_modules/@storybook/core/dist/common/index.cjs:18759:16)
34
+ at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
35
+ at async Ar.executeCommand (/Users/yoon/.npm/_npx/7122ab1f221a777a/node_modules/@storybook/core/dist/common/index.cjs:19205:15)
36
+ at async Ar.runInstall (/Users/yoon/.npm/_npx/7122ab1f221a777a/node_modules/@storybook/core/dist/common/index.cjs:19339:5)
37
+ at async Ar.installDependencies (/Users/yoon/.npm/_npx/7122ab1f221a777a/node_modules/@storybook/core/dist/common/index.cjs:18945:7)
38
+ at async Object.run (/Users/yoon/.npm/_npx/7122ab1f221a777a/node_modules/@storybook/cli/dist/bin/index.cjs:448:541)
39
+ at async runFixes (/Users/yoon/.npm/_npx/7122ab1f221a777a/node_modules/@storybook/cli/dist/bin/index.cjs:533:1801)
40
+ at async automigrate (/Users/yoon/.npm/_npx/7122ab1f221a777a/node_modules/@storybook/cli/dist/bin/index.cjs:531:1625)
41
+ at async doUpgrade (/Users/yoon/.npm/_npx/7122ab1f221a777a/node_modules/@storybook/cli/dist/bin/index.cjs:600:1612) {
42
+ shortMessage: 'Command failed with exit code 1: npm install',
43
+ command: 'npm install',
44
+ escapedCommand: 'npm install',
45
+ exitCode: 1,
46
+ signal: undefined,
47
+ signalDescription: undefined,
48
+ stdout: undefined,
49
+ stderr: undefined,
50
+ cwd: '/Users/yoon/WebstormProjects/nexr/gov-ui-core',
51
+ failed: true,
52
+ timedOut: false,
53
+ isCanceled: false,
54
+ killed: false
55
+ }
56
+ }
57
+
58
+
59
+ 🔎 found a 'autodocs-tags' migration:
60
+ ╭ Automigration detected ───────────────────────────────────────────────────────────────────────────────────────────╮
61
+ │ │
62
+ │ The docs.autodocs setting in .storybook/main.ts is deprecated. │
63
+ │ │
64
+ │ Learn more: https://github.com/storybookjs/storybook/blob/next/MIGRATION.md#mainjs-docsautodocs-is-deprecated │
65
+ │ │
66
+ │ Remove docs.autodocs and update .storybook/preview.tsx? │
67
+ │ │
68
+ ╰───────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
69
+ ? Do you want to run the 'autodocs-tags' migration on your project? › (Y/n)✔ Do you want to run the 'autodocs-tags' migration on your project? … yes
70
+ ✅ Adding "autodocs" tag to .storybook/preview.tsx
71
+ ✅ Removing "docs.autodocs" from .storybook/main.ts
72
+ ✅ ran autodocs-tags migration
73
+ WARN An issue occurred while trying to find dependencies metadata using npm.
74
+
75
+ ╭ Migration check ran with failures ────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
76
+ │ │
77
+ │ Successful migrations: │
78
+ │ │
79
+ │ autodocs-tags │
80
+ │ │
81
+ │ Failed migrations: │
82
+ │ │
83
+ │ upgradeStorybookRelatedDependencies: │
84
+ │ Error: Command failed with exit code 1: npm install │
85
+ │ │
86
+ │ You can find the full logs in /Users/yoon/WebstormProjects/nexr/gov-ui-core/migration-storybook.log │
87
+ │ │
88
+ │ ───────────────────────────────────────────────── │
89
+ │ │
90
+ │ If you'd like to run the migrations again, you can do so by running 'npx storybook automigrate' │
91
+ │ │
92
+ │ The automigrations try to migrate common patterns in your project, but might not contain everything needed to migrate to the latest version of Storybook. │
93
+ │ │
94
+ │ Please check the changelog and migration guide for manual migrations and more information: https://storybook.js.org/docs/migration-guide │
95
+ │ And reach out on Discord if you need help: https://discord.gg/storybook │
96
+ │ │
97
+ ╰───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
98
+