8000 V1 by wangxingkang · Pull Request #140 · pansyjs/react-admin · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

V1 #140

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 11 commits into from
Jun 2, 2019
Merged

V1 #140

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
< 10000 label for="whitespace-cb" class="ml-1">Hide whitespace
27 changes: 0 additions & 27 deletions .stylelintrc

This file was deleted.

15 changes: 15 additions & 0 deletions .stylelintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"extends": [
"stylelint-config-standard",
"stylelint-config-rational-order",
"stylelint-config-prettier"
],
"plugins": [
"stylelint-order",
"stylelint-declaration-block-no-ignored-properties"
],
"rules": {
"no-descending-specificity": null,
"plugin/declaration-block-no-ignored-properties": true
}
}
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@
<h1 align="center">React Admin Template</h1>

<p align="center">
<a href="http://umijs.org">
<img src="https://img.shields.io/badge/build%20with-umi-028fe4.svg" alt="react">
</a>
<a href="https://github.com/facebook/react">
<img src="https://img.shields.io/badge/react-16.8.1-brightgreen.svg" alt="react">
</a>
<a href="https://github.com/ant-design/ant-design">
<img src="https://img.shields.io/badge/ant--design-3.17.0-brightgreen.svg" alt="antd">
</a>
<a href="https://github.com/umijs/umi">
<img src="https://img.shields.io/badge/umi-2.6.17-brightgreen.svg" alt="umi">
<img src="https://img.shields.io/badge/ant--design-3.19.2-brightgreen.svg" alt="antd">
</a>
<a href="https://github.com/Microsoft/TypeScript">
<img src="https://img.shields.io/badge/typescript-3.4.2-brightgreen.svg" alt="typescript">
Expand Down
2 changes: 1 addition & 1 deletion config/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export default {
},
treeShaking: true,
define: {
BASE_URL: serverConfig[SERVER_ENV] || serverConfig.production
BASE_URL: serverConfig[SERVER_ENV] || serverConfig.localhost
},
// 路由配置
routes,
Expand Down
20 changes: 9 additions & 11 deletions config/router.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -84,15 +84,13 @@ export default [
path: '/permission/policies',
name: 'policies',
component: './permission/policies/policies',
authority: ['permission/policyList'],
hideChildrenInMenu: true,
routes: [
{
path: '/permission/policies/create',
name: 'create',
component: './permission/policies/create',
},
]
authority: ['permission/policyList']
},
{
path: '/permission/policies/create',
name: 'policy-create',
hideInMenu: true,
component: './permission/policies/create',
}
],
},
Expand All @@ -104,13 +102,13 @@ export default [
{
path: '/system/user',
name: 'user',
authority: ['system/action1'],
authority: '*',
component: './system/users'
},
{
path: '/system/group',
name: 'group',
authority: ['system/action2'],
authority: '*',
component: './system/groups'
}
],
Expand Down
6 changes: 4 additions & 2 deletions config/server.config.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
// 后端接口配置
export default {
// 本地开发使用
localhost: '',
dev: '',
test: '',
production: '',
development: '',
test: ''
}
21 changes: 12 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,21 +6,21 @@
"bootstrap": "yarn || npm i",
"clean": "rimraf dist",
"start": "cross-env PORT=8080 umi dev",
"build": "cross-env SERVER_ENV=development umi build",
"build": "umi build",
"build:dev": "cross-env SERVER_ENV=dev umi build",
"build:test": "cross-env SERVER_ENV=test umi build",
"build:prod": "cross-env SERVER_ENV=production umi build",
"build:web": "yarn build && cd ./dist && anywhere -h localhost -p 8080",
"gh-pages": "yarn build:prod && gh-pages -d dist",
"lint-staged": "lint-staged",
"lint-staged:ts": "npm run tsc",
"lint:ts": "tslint --project tsconfig.json --format codeFrame",
"lint:style": "stylelint \"src/**/*.less\" --syntax less",
"lint:style": "stylelint --fix 'src/**/*.less' --syntax less",
"docker:build": "./scripts/docker-build.sh",
"tsc": "tsc",
"test": "umi test",
"test:component": "umi test ./src/components",
"deploy": "rm -rf node_modules/gh-pages/.cache && gh-pages -d dist",
"build:view": "npm run build && cd ./dist && anywhere -p 8080",
"deploy": "yarn build && rm -rf node_modules/gh-pages/.cache && gh-pages -d dist",
"prettier": "prettier --write ./src/**/**/**/*"
},
"repository": "https://github.com/ts-react/react-admin-template.git",
Expand All @@ -30,7 +30,7 @@
"@antv/data-set": "^0.10.1",
"@jiumao/dharma": "^0.0.5",
"@jiumao/policy": "^1.0.5",
"antd": "^3.19.1",
"antd": "^3.19.2",
"axios": "^0.18.0",
"bizcharts": "^3.5.2",
"braft-editor": "^2.2.9",
Expand Down Expand Up @@ -93,10 +93,13 @@
"mockjs": "^1.0.1-beta3",
"prettier": "^1.17.0",
"rimraf": "^2.6.2",
"stylelint": "^9.4.0",
"stylelint-config-prettier": "^3.3.0",
"stylelint-config-standard": "^18.2.0",
"typescript": "^3.4.2",
"stylelint": "^10.0.1",
"stylelint-config-prettier": "^5.2.0",
"stylelint-config-rational-order": "^0.1.2",
"stylelint-config-standard": "^18.3.0",
"stylelint-declaration-block-no-ignored-properties": "^2.1.0",
"stylelint-order": "^3.0.0",
"typescript": "^3.5.1",
"umi": "^2.6.17",
"umi-plugin-react": "^1.7.5",
"umi-types": "^0.3.2"
Expand Down
24 changes: 12 additions & 12 deletions src/components/drawer-wrapper/drawer-wrapper.less
Original file line number Diff line number Diff line change
Expand Up @@ -5,25 +5,25 @@
.@{prefix-cls} {
.ant-drawer-body {
height: 100%;
padding: 0;
min-height: 300px;
padding: 0;
}

&__title {
height: @layout-header-height;
margin: 0;
color: rgba(0, 0, 0, 0.85);
font-weight: 500;
font-size: 16px;
height: @layout-header-height;
line-height: @layout-header-height;
}

&__header {
position: relative;
padding: 0 24px;
height: @layout-header-height;
line-height: @layout-header-height;
padding: 0 24px;
color: rgba(0,0,0,0.65);
line-height: @layout-header-height;
background: @white;
border-bottom: 1px solid #e8e8e8;
border-radius: 4px 4px 0 0;
Expand Down Expand Up @@ -61,16 +61,16 @@
padding: 16px 24px;
}

&__footer {
background: #fff;
width: 100%;
border-top: 1px solid #efefef;
overflow: hidden;
padding: 0 24px;
height: @layout-header-height;;
line-height: @layout-header-height;;
&__footer {;
position: absolute;
bottom: 0;
width: 100%;
height: @layout-header-height;
padding: 0 24px;
overflow: hidden;;
line-height: @layout-header-height;
background: #fff;
border-top: 1px solid #efefef;

button + button {
margin-left: 10px;
Expand Down
2 changes: 1 addition & 1 deletion src/components/exception/exception.less
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@

&::before,
&::after {
content: ' ';
display: table;
content: ' ';
}

&::after {
Expand Down
8 changes: 4 additions & 4 deletions src/components/global-header/global-header.less
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@
box-shadow: 0 1px 4px rgba(0, 21, 41, 0.08);

&__right {
z-index: 9;
max-width: 410px;
position: absolute;
right: 15px;
top: 0;
height: @layout-header-height;
right: 15px;
z-index: 9;
display: flex;
align-items: center;
justify-content: flex-end;
max-width: 410px;
height: @layout-header-height;
}

&__action {
Expand Down
Empty file.
7 changes: 0 additions & 7 deletions src/components/notice-icon/notice-icon.less

This file was deleted.

68 changes: 0 additions & 68 deletions src/components/notice-icon/notice-icon.tsx

This file was deleted.

8 changes: 0 additions & 8 deletions src/components/notice-icon/notice-list.less

This file was deleted.

5 changes: 0 additions & 5 deletions src/components/notice-icon/notice-list.tsx

This file was deleted.

7 changes: 7 additions & 0 deletions src/components/pattern-lock/pattern-lock.less
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
@import '~antd/lib/style/themes/default.less';

@prefix-cls: ~'lotus-pattern-lock';

.@{prefix-cls} {
position: relative;
}
1 change: 1 addition & 0 deletions src/components/pattern-lock/pattern-lock.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import React from 'react';
import classNames from 'classnames';
import './pattern-lock.less';

interface IProps {
prefixCls: string;
Expand Down
7 changes: 7 additions & 0 deletions src/components/screen-lock/screen-lock.less
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
@import '~antd/lib/style/themes/default.less';

@prefix-cls: ~'lotus-screen-lock';

.@{prefix-cls} {
position: relative;
}
Loading
0