refactor: removes un-necessary 'src' from webui path
Before Width: | Height: | Size: 3.4 KiB After Width: | Height: | Size: 3.4 KiB |
Before Width: | Height: | Size: 2.8 KiB After Width: | Height: | Size: 2.8 KiB |
Before Width: | Height: | Size: 2.4 KiB After Width: | Height: | Size: 2.4 KiB |
Before Width: | Height: | Size: 2.8 KiB After Width: | Height: | Size: 2.8 KiB |
Before Width: | Height: | Size: 6.4 KiB After Width: | Height: | Size: 6.4 KiB |
Before Width: | Height: | Size: 2.2 KiB After Width: | Height: | Size: 2.2 KiB |
Before Width: | Height: | Size: 2.8 KiB After Width: | Height: | Size: 2.8 KiB |
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.7 KiB |
|
@ -5,10 +5,10 @@ import isNumber from 'lodash/isNumber';
|
|||
import capitalize from 'lodash/capitalize';
|
||||
import {Link} from 'react-router-dom';
|
||||
|
||||
import API from '../../../utils/api';
|
||||
import storage from '../../../utils/storage';
|
||||
import {getRegistryURL} from '../../../utils/url';
|
||||
import {HEADERS} from '../../../../lib/constants';
|
||||
import API from '../../utils/api';
|
||||
import storage from '../../utils/storage';
|
||||
import {getRegistryURL} from '../../utils/url';
|
||||
import {HEADERS} from '../../../lib/constants';
|
||||
|
||||
import classes from './header.scss';
|
||||
import './logo.png';
|
Before Width: | Height: | Size: 13 KiB After Width: | Height: | Size: 13 KiB |
|
@ -4,7 +4,7 @@ import sunburst from 'react-syntax-highlighter/src/styles/sunburst';
|
|||
import js from 'react-syntax-highlighter/dist/languages/javascript';
|
||||
|
||||
import classes from './help.scss';
|
||||
import {getRegistryURL} from '../../../utils/url';
|
||||
import {getRegistryURL} from '../../utils/url';
|
||||
|
||||
registerLanguage('javascript', js);
|
||||
|
|
@ -5,7 +5,7 @@ import Maintainers from './modules/Maintainers';
|
|||
import Dependencies from './modules/Dependencies';
|
||||
import Infos from './modules/Infos';
|
||||
|
||||
import API from '../../../utils/api';
|
||||
import API from '../../utils/api';
|
||||
|
||||
export default class PackageSidebar extends React.Component {
|
||||
state = {};
|
|
@ -4,7 +4,7 @@ import get from 'lodash/get';
|
|||
import Module from '../../Module';
|
||||
|
||||
import classes from './style.scss';
|
||||
import {getDetailPageURL} from '../../../../../utils/url';
|
||||
import {getDetailPageURL} from '../../../../utils/url';
|
||||
import ModuleContentPlaceholder from '../../ModuleContentPlaceholder';
|
||||
|
||||
export default class Dependencies extends React.Component {
|
|
@ -1,4 +1,4 @@
|
|||
import '../utils/__setPublicPath__';
|
||||
import './utils/__setPublicPath__';
|
||||
|
||||
import React from 'react';
|
||||
import ReactDOM from 'react-dom';
|
|
@ -5,7 +5,7 @@ import isEmpty from 'lodash/isEmpty';
|
|||
|
||||
import PackageDetail from '../../components/PackageDetail';
|
||||
import NotFound from '../../components/NotFound';
|
||||
import API from '../../../utils/api';
|
||||
import API from '../../utils/api';
|
||||
|
||||
import classes from './detail.scss';
|
||||
import PackageSidebar from '../../components/PackageSidebar/index';
|
|
@ -4,7 +4,7 @@ import {Loading, MessageBox} from 'element-react';
|
|||
import isEmpty from 'lodash/isEmpty';
|
||||
import debounce from 'lodash/debounce';
|
||||
|
||||
import API from '../../../utils/api';
|
||||
import API from '../../utils/api';
|
||||
|
||||
import PackageList from '../../components/PackageList';
|
||||
import Search from '../../components/Search';
|
|
@ -2,7 +2,7 @@
|
|||
import assert from 'assert';
|
||||
import {generateGravatarUrl, GRAVATAR_DEFAULT} from '../../../src/utils/user';
|
||||
import {spliceURL} from '../../../src/utils/string';
|
||||
import Package from "../../../src/webui/src/components/Package/index";
|
||||
import Package from "../../../src/webui/components/Package/index";
|
||||
import {validateName as validate, convertDistRemoteToLocalTarballUrls, parseReadme} from '../../../src/lib/utils';
|
||||
import Logger, {setup} from '../../../src/lib/logger';
|
||||
import { readFile } from '../../functional/lib/test.utils';
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
|
||||
import React from 'react';
|
||||
import { mount, shallow } from 'enzyme';
|
||||
import Dependencies from '../../../../../src/webui/src/components/PackageSidebar/modules/Dependencies/index';
|
||||
import Dependencies from '../../../../../src/webui/components/PackageSidebar/modules/Dependencies/index';
|
||||
import { packageMeta } from '../store/packageMeta';
|
||||
|
||||
console.error = jest.fn();
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
|
||||
import React from 'react';
|
||||
import { mount, shallow } from 'enzyme';
|
||||
import Infos from '../../../../../src/webui/src/components/PackageSidebar/modules/Infos/index';
|
||||
import Infos from '../../../../../src/webui/components/PackageSidebar/modules/Infos/index';
|
||||
import { packageMeta } from '../store/packageMeta';
|
||||
|
||||
console.error = jest.fn();
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
|
||||
import React from 'react';
|
||||
import { mount, shallow } from 'enzyme';
|
||||
import LastSync from '../../../../../src/webui/src/components/PackageSidebar/modules/LastSync/index';
|
||||
import LastSync from '../../../../../src/webui/components/PackageSidebar/modules/LastSync/index';
|
||||
import { packageMeta } from '../store/packageMeta';
|
||||
|
||||
console.error = jest.fn();
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
|
||||
import React from 'react';
|
||||
import { shallow } from 'enzyme';
|
||||
import MaintainerInfo from '../../../../../src/webui/src/components/PackageSidebar/modules/Maintainers/MaintainerInfo/index';
|
||||
import MaintainerInfo from '../../../../../src/webui/components/PackageSidebar/modules/Maintainers/MaintainerInfo/index';
|
||||
|
||||
console.error = jest.fn();
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
|
||||
import React from 'react';
|
||||
import { mount } from 'enzyme';
|
||||
import Maintainers from '../../../../../src/webui/src/components/PackageSidebar/modules/Maintainers/index';
|
||||
import Maintainers from '../../../../../src/webui/components/PackageSidebar/modules/Maintainers/index';
|
||||
import { packageMeta } from '../store/packageMeta';
|
||||
|
||||
console.error = jest.fn();
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
|
||||
import React from 'react';
|
||||
import { shallow } from 'enzyme';
|
||||
import Module from '../../../../../src/webui/src/components/PackageSidebar/Module/index';
|
||||
import Module from '../../../../../src/webui/components/PackageSidebar/Module/index';
|
||||
|
||||
console.error = jest.fn();
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
|
||||
import React from 'react';
|
||||
import { shallow } from 'enzyme';
|
||||
import ModuleContentPlaceholder from '../../../../../src/webui/src/components/PackageSidebar/ModuleContentPlaceholder/index';
|
||||
import ModuleContentPlaceholder from '../../../../../src/webui/components/PackageSidebar/ModuleContentPlaceholder/index';
|
||||
|
||||
console.error = jest.fn();
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
|
||||
import React from 'react';
|
||||
import { mount } from 'enzyme';
|
||||
import PackageSidebar from '../../../../../src/webui/src/components/PackageSidebar/index';
|
||||
import PackageSidebar from '../../../../../src/webui/components/PackageSidebar/index';
|
||||
import { packageMeta } from '../store/packageMeta';
|
||||
|
||||
jest.mock('../../../../../src/webui/utils/api', () => ({
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
*/
|
||||
import React from 'react';
|
||||
import { shallow, mount } from 'enzyme';
|
||||
import Header from '../../../../src/webui/src/components/Header';
|
||||
import Header from '../../../../src/webui/components/Header';
|
||||
import { BrowserRouter } from 'react-router-dom';
|
||||
import storage from '../../../../src/webui/utils/storage';
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
import React from 'react';
|
||||
import { shallow } from 'enzyme';
|
||||
import SyntaxHighlighter from 'react-syntax-highlighter/dist/light';
|
||||
import Help from '../../../../src/webui/src/components/Help/index';
|
||||
import Help from '../../../../src/webui/components/Help/index';
|
||||
|
||||
describe('<Help /> component', () => {
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
|
||||
import React from 'react';
|
||||
import { shallow } from 'enzyme';
|
||||
import NoItems from '../../../../src/webui/src/components/NoItems/index';
|
||||
import NoItems from '../../../../src/webui/components/NoItems/index';
|
||||
|
||||
console.error = jest.fn();
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
|
||||
import React from 'react';
|
||||
import { shallow } from 'enzyme';
|
||||
import NotFound from '../../../../src/webui/src/components/NotFound/index';
|
||||
import NotFound from '../../../../src/webui/components/NotFound/index';
|
||||
|
||||
console.error = jest.fn();
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
|
||||
import React from 'react';
|
||||
import { mount } from 'enzyme';
|
||||
import Package from '../../../../src/webui/src/components/Package/index';
|
||||
import Package from '../../../../src/webui/components/Package/index';
|
||||
import { BrowserRouter } from 'react-router-dom';
|
||||
|
||||
/**
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
*/
|
||||
import React from 'react';
|
||||
import { shallow } from 'enzyme';
|
||||
import PackageDetail from '../../../../src/webui/src/components/PackageDetail/index';
|
||||
import Readme from '../../../../src/webui/src/components/Readme/index';
|
||||
import PackageDetail from '../../../../src/webui/components/PackageDetail/index';
|
||||
import Readme from '../../../../src/webui/components/Readme/index';
|
||||
import {WEB_TITLE} from '../../../../src/lib/constants';
|
||||
|
||||
console.error = jest.fn();
|
||||
|
|
|
@ -4,9 +4,9 @@
|
|||
|
||||
import React from 'react';
|
||||
import { mount } from 'enzyme';
|
||||
import PackageList from '../../../../src/webui/src/components/PackageList/index';
|
||||
import Help from '../../../../src/webui/src/components/Help/index';
|
||||
import NoItems from '../../../../src/webui/src/components/NoItems/index';
|
||||
import PackageList from '../../../../src/webui/components/PackageList/index';
|
||||
import Help from '../../../../src/webui/components/Help/index';
|
||||
import NoItems from '../../../../src/webui/components/NoItems/index';
|
||||
import { BrowserRouter } from 'react-router-dom';
|
||||
|
||||
describe('<PackageList /> component', () => {
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
|
||||
import React from 'react';
|
||||
import { shallow } from 'enzyme';
|
||||
import Readme from '../../../../src/webui/src/components/Readme/index';
|
||||
import Readme from '../../../../src/webui/components/Readme/index';
|
||||
|
||||
console.error = jest.fn();
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
|
||||
import React from 'react';
|
||||
import { shallow } from 'enzyme';
|
||||
import Search from '../../../../src/webui/src/components/Search/index';
|
||||
import Search from '../../../../src/webui/components/Search/index';
|
||||
console.error = jest.fn();
|
||||
|
||||
describe('<Search /> component', () => {
|
||||
|
|
|
@ -17,7 +17,7 @@ export default {
|
|||
'react-hot-loader/patch',
|
||||
'webpack-dev-server/client?http://localhost:4872',
|
||||
'webpack/hot/only-dev-server',
|
||||
`${env.SRC_ROOT}/webui/src/index.js`,
|
||||
`${env.SRC_ROOT}/webui/index.js`,
|
||||
],
|
||||
},
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@ const prodConf = {
|
|||
mode: 'production',
|
||||
|
||||
entry: {
|
||||
main: ['babel-polyfill', 'whatwg-fetch', `${env.SRC_ROOT}/webui/src/index.js`],
|
||||
main: ['babel-polyfill', 'whatwg-fetch', `${env.SRC_ROOT}/webui/index.js`],
|
||||
},
|
||||
|
||||
module: {
|
||||
|
|