├── .dockerignore ├── .editorconfig ├── .eslintignore ├── .eslintrc.js ├── .firebaserc ├── .gitignore ├── .prettierignore ├── .prettierrc ├── .stylelintrc.json ├── Dockerfile ├── Dockerfile.dev ├── Dockerfile.hub ├── LICENSE ├── README.md ├── README.ru-RU.md ├── README.zh-CN.md ├── appveyor.yml ├── config ├── config.js ├── plugin.config.js └── router.config.js ├── docker ├── docker-compose.dev.yml ├── docker-compose.yml └── nginx.conf ├── firebase.json ├── functions ├── index.js ├── matchMock.js └── package.json ├── jest-puppeteer.config.js ├── jest.config.js ├── jsconfig.json ├── mock ├── api.js ├── chart.js ├── geographic.js ├── geographic │ ├── city.json │ └── province.json ├── notices.js ├── profile.js ├── rule.js └── user.js ├── netlify.toml ├── package.json ├── public ├── ant.jpeg ├── ant1.jpeg ├── favicon.png ├── icons │ ├── icon-128x128.png │ ├── icon-192x192.png │ └── icon-512x512.png └── image │ ├── braft-editor.png │ ├── center.png │ ├── drag.png │ ├── react-color.png │ ├── scroll.png │ ├── select-tree.png │ ├── star.png │ └── table.png ├── scripts ├── generateMock.js ├── getPrettierFiles.js ├── lint-prettier.js └── prettier.js ├── src ├── assets │ └── logo.svg ├── components │ ├── ActiveChart │ │ ├── index.js │ │ └── index.less │ ├── AntTableFinder │ │ ├── AntTableFinder.js │ │ ├── AntTableFinder.less │ │ └── AntTableFinder.md │ ├── ArticleListContent │ │ ├── index.js │ │ └── index.less │ ├── Authorized │ │ ├── Authorized.js │ │ ├── AuthorizedRoute.d.ts │ │ ├── AuthorizedRoute.js │ │ ├── CheckPermissions.js │ │ ├── CheckPermissions.test.js │ │ ├── PromiseRender.js │ │ ├── Secured.js │ │ ├── demo │ │ │ ├── AuthorizedArray.md │ │ │ ├── AuthorizedFunction.md │ │ │ ├── basic.md │ │ │ └── secured.md │ │ ├── index.d.ts │ │ ├── index.js │ │ ├── index.md │ │ └── renderAuthorize.js │ ├── AvatarList │ │ ├── AvatarItem.d.ts │ │ ├── demo │ │ │ ├── maxLength.md │ │ │ └── simple.md │ │ ├── index.d.ts │ │ ├── index.en-US.md │ │ ├── index.js │ │ ├── index.less │ │ ├── index.test.js │ │ └── index.zh-CN.md │ ├── Charts │ │ ├── Bar │ │ │ ├── index.d.ts │ │ │ └── index.js │ │ ├── ChartCard │ │ │ ├── index.d.ts │ │ │ ├── index.js │ │ │ └── index.less │ │ ├── Field │ │ │ ├── index.d.ts │ │ │ ├── index.js │ │ │ └── index.less │ │ ├── Gauge │ │ │ ├── index.d.ts │ │ │ └── index.js │ │ ├── MiniArea │ │ │ ├── index.d.ts │ │ │ └── index.js │ │ ├── MiniBar │ │ │ ├── index.d.ts │ │ │ └── index.js │ │ ├── MiniProgress │ │ │ ├── index.d.ts │ │ │ ├── index.js │ │ │ └── index.less │ │ ├── Pie │ │ │ ├── index.d.ts │ │ │ ├── index.js │ │ │ └── index.less │ │ ├── Radar │ │ │ ├── index.d.ts │ │ │ ├── index.js │ │ │ └── index.less │ │ ├── TagCloud │ │ │ ├── index.d.ts │ │ │ ├── index.js │ │ │ └── index.less │ │ ├── TimelineChart │ │ │ ├── index.d.ts │ │ │ ├── index.js │ │ │ └── index.less │ │ ├── WaterWave │ │ │ ├── index.d.ts │ │ │ ├── index.js │ │ │ └── index.less │ │ ├── autoHeight.js │ │ ├── bizcharts.d.ts │ │ ├── bizcharts.js │ │ ├── demo │ │ │ ├── bar.md │ │ │ ├── chart-card.md │ │ │ ├── gauge.md │ │ │ ├── mini-area.md │ │ │ ├── mini-bar.md │ │ │ ├── mini-pie.md │ │ │ ├── mini-progress.md │ │ │ ├── mix.md │ │ │ ├── pie.md │ │ │ ├── radar.md │ │ │ ├── tag-cloud.md │ │ │ ├── timeline-chart.md │ │ │ └── waterwave.md │ │ ├── g2.js │ │ ├── index.d.ts │ │ ├── index.js │ │ ├── index.less │ │ └── index.md │ ├── CountDown │ │ ├── demo │ │ │ └── simple.md │ │ ├── index.d.ts │ │ ├── index.en-US.md │ │ ├── index.js │ │ └── index.zh-CN.md │ ├── DescriptionList │ │ ├── Description.d.ts │ │ ├── Description.js │ │ ├── DescriptionList.js │ │ ├── demo │ │ │ ├── basic.md │ │ │ └── vertical.md │ │ ├── index.d.ts │ │ ├── index.en-US.md │ │ ├── index.js │ │ ├── index.less │ │ ├── index.zh-CN.md │ │ └── responsive.js │ ├── EditableItem │ │ ├── index.js │ │ └── index.less │ ├── EditableLinkGroup │ │ ├── index.js │ │ └── index.less │ ├── Ellipsis │ │ ├── demo │ │ │ ├── line.md │ │ │ └── number.md │ │ ├── index.d.ts │ │ ├── index.en-US.md │ │ ├── index.js │ │ ├── index.less │ │ ├── index.test.js │ │ └── index.zh-CN.md │ ├── Exception │ │ ├── demo │ │ │ ├── 403.md │ │ │ ├── 404.md │ │ │ └── 500.md │ │ ├── index.d.ts │ │ ├── index.en-US.md │ │ ├── index.js │ │ ├── index.less │ │ ├── index.zh-CN.md │ │ └── typeConfig.js │ ├── FooterToolbar │ │ ├── demo │ │ │ └── basic.md │ │ ├── index.d.ts │ │ ├── index.en-US.md │ │ ├── index.js │ │ ├── index.less │ │ └── index.zh-CN.md │ ├── GlobalFooter │ │ ├── demo │ │ │ └── basic.md │ │ ├── index.d.ts │ │ ├── index.js │ │ ├── index.less │ │ └── index.md │ ├── GlobalHeader │ │ ├── RightContent.js │ │ ├── index.js │ │ └── index.less │ ├── HeaderDropdown │ │ ├── index.js │ │ └── index.less │ ├── HeaderSearch │ │ ├── demo │ │ │ └── basic.md │ │ ├── index.d.ts │ │ ├── index.en-US.md │ │ ├── index.js │ │ ├── index.less │ │ └── index.zh-CN.md │ ├── Login │ │ ├── LoginItem.d.ts │ │ ├── LoginItem.js │ │ ├── LoginSubmit.js │ │ ├── LoginTab.d.ts │ │ ├── LoginTab.js │ │ ├── demo │ │ │ └── basic.md │ │ ├── index.d.ts │ │ ├── index.en-US.md │ │ ├── index.js │ │ ├── index.less │ │ ├── index.zh-CN.md │ │ ├── loginContext.js │ │ └── map.js │ ├── NoticeIcon │ │ ├── NoticeIconTab.d.ts │ │ ├── NoticeList.js │ │ ├── NoticeList.less │ │ ├── demo │ │ │ ├── basic.md │ │ │ └── popover.md │ │ ├── index.d.ts │ │ ├── index.en-US.md │ │ ├── index.js │ │ ├── index.less │ │ └── index.zh-CN.md │ ├── NumberInfo │ │ ├── demo │ │ │ └── basic.md │ │ ├── index.d.ts │ │ ├── index.en-US.md │ │ ├── index.js │ │ ├── index.less │ │ └── index.zh-CN.md │ ├── PageHeader │ │ ├── breadcrumb.d.ts │ │ ├── breadcrumb.js │ │ ├── demo │ │ │ ├── image.md │ │ │ ├── simple.md │ │ │ ├── standard.md │ │ │ └── structure.md │ │ ├── index.d.ts │ │ ├── index.js │ │ ├── index.less │ │ ├── index.md │ │ └── index.test.js │ ├── PageHeaderWrapper │ │ ├── GridContent.js │ │ ├── GridContent.less │ │ ├── index.js │ │ └── index.less │ ├── PageLoading │ │ └── index.js │ ├── Result │ │ ├── demo │ │ │ ├── classic.md │ │ │ ├── error.md │ │ │ └── structure.md │ │ ├── index.d.ts │ │ ├── index.js │ │ ├── index.less │ │ └── index.md │ ├── SelectLang │ │ ├── index.js │ │ └── index.less │ ├── SettingDrawer │ │ ├── BlockCheckbox.js │ │ ├── ThemeColor.js │ │ ├── ThemeColor.less │ │ ├── index.js │ │ └── index.less │ ├── SiderMenu │ │ ├── BaseMenu.js │ │ ├── SiderMenu.js │ │ ├── SiderMenu.test.js │ │ ├── SiderMenuUtils.js │ │ ├── index.js │ │ └── index.less │ ├── StandardFormRow │ │ ├── index.js │ │ └── index.less │ ├── StandardTable │ │ ├── index.js │ │ └── index.less │ ├── TagSelect │ │ ├── TagSelectOption.d.ts │ │ ├── demo │ │ │ ├── controlled.md │ │ │ ├── expandable.md │ │ │ └── simple.md │ │ ├── index.d.ts │ │ ├── index.js │ │ ├── index.less │ │ └── index.md │ ├── TopNavHeader │ │ ├── index.js │ │ └── index.less │ ├── TreeCheck │ │ └── index.js │ ├── Trend │ │ ├── demo │ │ │ ├── basic.md │ │ │ └── reverse.md │ │ ├── index.d.ts │ │ ├── index.js │ │ ├── index.less │ │ └── index.md │ └── _utils │ │ ├── pathTools.js │ │ └── pathTools.test.js ├── defaultSettings.js ├── e2e │ ├── baseLayout.e2e.js │ ├── home.e2e.js │ ├── login.e2e.js │ ├── topMenu.e2e.js │ └── userLayout.e2e.js ├── global.js ├── global.less ├── layouts │ ├── BasicLayout.js │ ├── BasicLayout.less │ ├── BlankLayout.js │ ├── Footer.js │ ├── Header.js │ ├── Header.less │ ├── MenuContext.js │ ├── UserLayout.js │ └── UserLayout.less ├── locales │ ├── en-US.js │ ├── en-US │ │ ├── analysis.js │ │ ├── exception.js │ │ ├── form.js │ │ ├── globalHeader.js │ │ ├── login.js │ │ ├── menu.js │ │ ├── monitor.js │ │ ├── pwa.js │ │ ├── result.js │ │ ├── settingDrawer.js │ │ └── settings.js │ ├── pt-BR.js │ ├── pt-BR │ │ ├── analysis.js │ │ ├── exception.js │ │ ├── form.js │ │ ├── globalHeader.js │ │ ├── login.js │ │ ├── menu.js │ │ ├── monitor.js │ │ ├── pwa.js │ │ ├── result.js │ │ ├── settingDrawer.js │ │ └── settings.js │ ├── zh-CN.js │ ├── zh-CN │ │ ├── analysis.js │ │ ├── exception.js │ │ ├── form.js │ │ ├── globalHeader.js │ │ ├── login.js │ │ ├── menu.js │ │ ├── monitor.js │ │ ├── pwa.js │ │ ├── result.js │ │ ├── settingDrawer.js │ │ └── settings.js │ ├── zh-TW.js │ └── zh-TW │ │ ├── analysis.js │ │ ├── exception.js │ │ ├── form.js │ │ ├── globalHeader.js │ │ ├── login.js │ │ ├── menu.js │ │ ├── monitor.js │ │ ├── pwa.js │ │ ├── result.js │ │ ├── settingDrawer.js │ │ └── settings.js ├── manifest.json ├── models │ ├── global.js │ ├── list.js │ ├── login.js │ ├── menu.js │ ├── project.js │ ├── setting.js │ └── user.js ├── pages │ ├── 404.js │ ├── Account │ │ ├── Center │ │ │ ├── Applications.js │ │ │ ├── Articles.js │ │ │ ├── Articles.less │ │ │ ├── Center.js │ │ │ ├── Center.less │ │ │ └── Projects.js │ │ └── Settings │ │ │ ├── BaseView.js │ │ │ ├── BaseView.less │ │ │ ├── BindingView.js │ │ │ ├── GeographicView.js │ │ │ ├── GeographicView.less │ │ │ ├── Info.js │ │ │ ├── Info.less │ │ │ ├── NotificationView.js │ │ │ ├── PhoneView.js │ │ │ ├── PhoneView.less │ │ │ ├── SecurityView.js │ │ │ └── models │ │ │ └── geographic.js │ ├── Authorized.js │ ├── Component │ │ ├── Edit.js │ │ ├── SelectTree.js │ │ ├── Table.js │ │ ├── Table.less │ │ └── TableData.json │ ├── Dashboard │ │ ├── Analysis.js │ │ ├── Analysis.less │ │ ├── IntroduceRow.js │ │ ├── Monitor.js │ │ ├── Monitor.less │ │ ├── OfflineData.js │ │ ├── ProportionSales.js │ │ ├── SalesCard.js │ │ ├── TopSearch.js │ │ ├── Workplace.js │ │ ├── Workplace.less │ │ └── models │ │ │ ├── activities.js │ │ │ ├── chart.js │ │ │ └── monitor.js │ ├── Exception │ │ ├── 403.js │ │ ├── 404.js │ │ ├── 500.js │ │ ├── TriggerException.js │ │ ├── models │ │ │ └── error.js │ │ └── style.less │ ├── Forms │ │ ├── AdvancedForm.js │ │ ├── BasicForm.js │ │ ├── StepForm │ │ │ ├── Step1.js │ │ │ ├── Step2.js │ │ │ ├── Step3.js │ │ │ ├── index.js │ │ │ └── style.less │ │ ├── TableForm.js │ │ ├── models │ │ │ └── form.js │ │ └── style.less │ ├── Home │ │ ├── Home.js │ │ └── home.json │ ├── Libraries │ │ ├── BraftEditor.js │ │ ├── Drag │ │ │ ├── Basic.js │ │ │ ├── Collections.js │ │ │ ├── DragHandle.js │ │ │ └── index.js │ │ ├── ReactColor.js │ │ ├── ReactDataGrid │ │ │ ├── Editable │ │ │ │ └── index.js │ │ │ ├── ReactDataGrid.md │ │ │ └── index.js │ │ └── ScrollBars │ │ │ ├── ColoredScrollbars.js │ │ │ └── index.js │ ├── List │ │ ├── Applications.js │ │ ├── Applications.less │ │ ├── Articles.js │ │ ├── Articles.less │ │ ├── BasicList.js │ │ ├── BasicList.less │ │ ├── CardList.js │ │ ├── CardList.less │ │ ├── List.js │ │ ├── Projects.js │ │ ├── Projects.less │ │ ├── TableList.js │ │ ├── TableList.less │ │ └── models │ │ │ └── rule.js │ ├── Profile │ │ ├── AdvancedProfile.js │ │ ├── AdvancedProfile.less │ │ ├── BasicProfile.js │ │ ├── BasicProfile.less │ │ └── models │ │ │ └── profile.js │ ├── Result │ │ ├── Error.js │ │ ├── Success.js │ │ └── Success.test.js │ ├── User │ │ ├── Login.js │ │ ├── Login.less │ │ ├── Register.js │ │ ├── Register.less │ │ ├── RegisterResult.js │ │ ├── RegisterResult.less │ │ └── models │ │ │ └── register.js │ └── document.ejs ├── service-worker.js ├── services │ ├── api.js │ ├── error.js │ ├── geographic.js │ └── user.js ├── style │ ├── img │ │ └── ant.jpeg │ └── less │ │ └── common.less └── utils │ ├── Authorized.js │ ├── Yuan.js │ ├── authority.js │ ├── authority.test.js │ ├── request.js │ ├── utils.js │ ├── utils.less │ └── utils.test.js ├── tests └── run-tests.js ├── tsconfig.json └── tslint.json /.dockerignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | **/node_modules 5 | /src/utils/request-temp.js 6 | 7 | # production 8 | /.vscode 9 | 10 | # misc 11 | .DS_Store 12 | npm-debug.log* 13 | yarn-error.log 14 | 15 | /coverage 16 | .idea 17 | yarn.lock 18 | package-lock.json 19 | *bak 20 | .vscode 21 | 22 | # visual studio code 23 | .history 24 | *.log 25 | 26 | functions/mock 27 | .temp/** 28 | 29 | # umi 30 | .umi 31 | .umi-production 32 | 33 | # screenshot 34 | screenshot 35 | .firebase -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | # http://editorconfig.org 2 | root = true 3 | 4 | [*] 5 | indent_style = space 6 | indent_size = 2 7 | end_of_line = lf 8 | charset = utf-8 9 | trim_trailing_whitespace = true 10 | insert_final_newline = true 11 | 12 | [*.md] 13 | trim_trailing_whitespace = false 14 | 15 | [Makefile] 16 | indent_style = tab 17 | -------------------------------------------------------------------------------- /.eslintignore: -------------------------------------------------------------------------------- 1 | /functions/mock/** 2 | /scripts 3 | /config 4 | /src -------------------------------------------------------------------------------- /.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | parser: 'babel-eslint', 3 | extends: ['airbnb', 'prettier', 'plugin:compat/recommended'], 4 | env: { 5 | browser: true, 6 | node: true, 7 | es6: true, 8 | mocha: true, 9 | jest: true, 10 | jasmine: true, 11 | }, 12 | globals: { 13 | APP_TYPE: true, 14 | page: true, 15 | }, 16 | rules: { 17 | 'react/jsx-filename-extension': [1, { extensions: ['.js'] }], 18 | 'react/jsx-wrap-multilines': 0, 19 | 'react/prop-types': 0, 20 | 'react/forbid-prop-types': 0, 21 | 'react/jsx-one-expression-per-line': 0, 22 | 'import/no-unresolved': [2, { ignore: ['^@/', '^umi/'] }], 23 | 'import/no-extraneous-dependencies': [ 24 | 2, 25 | { 26 | optionalDependencies: true, 27 | devDependencies: ['**/tests/**.js', '/mock/**.js', '**/**.test.js'], 28 | }, 29 | ], 30 | 'jsx-a11y/no-noninteractive-element-interactions': 0, 31 | 'jsx-a11y/click-events-have-key-events': 0, 32 | 'jsx-a11y/no-static-element-interactions': 0, 33 | 'jsx-a11y/anchor-is-valid': 0, 34 | 'linebreak-style': 0, 35 | }, 36 | settings: { 37 | polyfills: ['fetch', 'promises', 'url'], 38 | }, 39 | }; 40 | -------------------------------------------------------------------------------- /.firebaserc: -------------------------------------------------------------------------------- 1 | { 2 | "projects": { 3 | "default": "antd-pro" 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | **/node_modules 5 | # roadhog-api-doc ignore 6 | /src/utils/request-temp.js 7 | _roadhog-api-doc 8 | 9 | # production 10 | 11 | /dist 12 | /.vscode 13 | /.circleci 14 | 15 | # misc 16 | .DS_Store 17 | npm-debug.log* 18 | yarn-error.log 19 | 20 | /coverage 21 | .idea 22 | yarn.lock 23 | package-lock.json 24 | *bak 25 | .vscode 26 | 27 | # visual studio code 28 | .history 29 | *.log 30 | 31 | functions/mock 32 | .temp/** 33 | 34 | # umi 35 | .umi 36 | .umi-production 37 | 38 | # screenshot 39 | screenshot 40 | .firebase -------------------------------------------------------------------------------- /.prettierignore: -------------------------------------------------------------------------------- 1 | **/*.md 2 | **/*.svg 3 | **/*.ejs 4 | **/*.html 5 | package.json 6 | .umi 7 | .umi-production 8 | -------------------------------------------------------------------------------- /.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "singleQuote": true, 3 | "trailingComma": "es5", 4 | "printWidth": 100, 5 | "overrides": [ 6 | { 7 | "files": ".prettierrc", 8 | "options": { "parser": "json" } 9 | } 10 | ] 11 | } 12 | -------------------------------------------------------------------------------- /.stylelintrc.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": ["stylelint-config-standard", "stylelint-config-prettier"], 3 | "rules": { 4 | "declaration-empty-line-before": null, 5 | "no-descending-specificity": null, 6 | "selector-pseudo-class-no-unknown": null, 7 | "selector-pseudo-element-colon-notation": null 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | FROM circleci/node:latest-browsers 2 | 3 | WORKDIR /usr/src/app/ 4 | USER root 5 | COPY package.json ./ 6 | RUN yarn 7 | 8 | COPY ./ ./ 9 | 10 | RUN npm run test:all 11 | 12 | CMD ["npm", "run", "build"] 13 | -------------------------------------------------------------------------------- /Dockerfile.dev: -------------------------------------------------------------------------------- 1 | FROM node:latest 2 | 3 | WORKDIR /usr/src/app/ 4 | 5 | COPY package.json ./ 6 | RUN npm install --silent --no-cache 7 | 8 | COPY ./ ./ 9 | 10 | 11 | CMD ["npm", "run", "start"] 12 | -------------------------------------------------------------------------------- /Dockerfile.hub: -------------------------------------------------------------------------------- 1 | FROM nginx 2 | 3 | WORKDIR /usr/src/app/ 4 | 5 | COPY ./docker/nginx.conf /etc/nginx/conf.d/default.conf 6 | 7 | COPY ./dist /usr/share/nginx/html/ 8 | 9 | EXPOSE 80 10 | 11 | CMD ["nginx", "-g", "daemon off;"] -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2019 776248185@qq.com 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /appveyor.yml: -------------------------------------------------------------------------------- 1 | # Test against the latest version of this Node.js version 2 | environment: 3 | nodejs_version: '10' 4 | 5 | # this is how to allow failing jobs in the matrix 6 | matrix: 7 | fast_finish: true # set this flag to immediately finish build once one of the jobs fails. 8 | 9 | # Install scripts. (runs after repo cloning) 10 | install: 11 | # Get the latest stable version of Node.js or io.js 12 | - ps: Install-Product node $env:nodejs_version 13 | # install modules 14 | - npm install 15 | # Output useful info for debugging. 16 | - node --version 17 | - npm --version 18 | 19 | # Post-install test scripts. 20 | test_script: 21 | - npm run lint 22 | - npm run test:all 23 | - npm run build 24 | 25 | # Don't actually build. 26 | build: off 27 | -------------------------------------------------------------------------------- /config/plugin.config.js: -------------------------------------------------------------------------------- 1 | // Change theme plugin 2 | 3 | import MergeLessPlugin from 'antd-pro-merge-less'; 4 | import AntDesignThemePlugin from 'antd-theme-webpack-plugin'; 5 | import path from 'path'; 6 | 7 | export default config => { 8 | // pro 和 开发环境再添加这个插件 9 | if (process.env.APP_TYPE === 'site' || process.env.NODE_ENV !== 'production') { 10 | // 将所有 less 合并为一个供 themePlugin使用 11 | const outFile = path.join(__dirname, '../.temp/ant-design-pro.less'); 12 | const stylesDir = path.join(__dirname, '../src/'); 13 | 14 | config.plugin('merge-less').use(MergeLessPlugin, [ 15 | { 16 | stylesDir, 17 | outFile, 18 | }, 19 | ]); 20 | 21 | config.plugin('ant-design-theme').use(AntDesignThemePlugin, [ 22 | { 23 | antDir: path.join(__dirname, '../node_modules/antd'), 24 | stylesDir, 25 | varFile: path.join(__dirname, '../node_modules/antd/lib/style/themes/default.less'), 26 | mainLessFile: outFile, // themeVariables: ['@primary-color'], 27 | indexFileName: 'index.html', 28 | generateOne: true, 29 | lessUrl: 'https://gw.alipayobjects.com/os/lib/less.js/3.8.1/less.min.js', 30 | }, 31 | ]); 32 | } 33 | }; 34 | -------------------------------------------------------------------------------- /docker/docker-compose.dev.yml: -------------------------------------------------------------------------------- 1 | version: "3.5" 2 | 3 | services: 4 | ant-design-pro_dev: 5 | ports: 6 | - 8000:8000 7 | build: 8 | context: ../ 9 | dockerfile: Dockerfile.dev 10 | container_name: "ant-design-pro_dev" 11 | volumes: 12 | - ../src:/usr/src/app/src 13 | - ../config:/usr/src/app/config 14 | - ../mock:/usr/src/app/mock 15 | -------------------------------------------------------------------------------- /docker/docker-compose.yml: -------------------------------------------------------------------------------- 1 | version: "3.5" 2 | 3 | services: 4 | ant-design-pro_build: 5 | build: ../ 6 | container_name: "ant-design-pro_build" 7 | volumes: 8 | - dist:/usr/src/app/dist 9 | 10 | ant-design-pro_web: 11 | image: nginx 12 | ports: 13 | - 80:80 14 | container_name: "ant-design-pro_web" 15 | restart: unless-stopped 16 | volumes: 17 | - dist:/usr/share/nginx/html:ro 18 | - ./nginx.conf:/etc/nginx/conf.d/default.conf 19 | 20 | volumes: 21 | dist: 22 | -------------------------------------------------------------------------------- /docker/nginx.conf: -------------------------------------------------------------------------------- 1 | server { 2 | listen 80; 3 | # gzip config 4 | gzip on; 5 | gzip_min_length 1k; 6 | gzip_comp_level 9; 7 | gzip_types text/plain text/css text/javascript application/json application/javascript application/x-javascript application/xml; 8 | gzip_vary on; 9 | gzip_disable "MSIE [1-6]\."; 10 | 11 | root /usr/share/nginx/html; 12 | 13 | location / { 14 | try_files $uri $uri/ /index.html; 15 | } 16 | location /api { 17 | proxy_pass https://preview.pro.ant.design; 18 | proxy_set_header X-Forwarded-Proto $scheme; 19 | proxy_set_header Host $http_host; 20 | proxy_set_header X-Real-IP $remote_addr; 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /firebase.json: -------------------------------------------------------------------------------- 1 | { 2 | "hosting": { 3 | "public": "dist", 4 | "rewrites": [ 5 | { "source": "/api/**", "function": "api" }, 6 | { 7 | "source": "**", 8 | "destination": "/index.html" 9 | } 10 | ], 11 | "ignore": ["firebase.json", "**/.*", "**/node_modules/**"] 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /functions/index.js: -------------------------------------------------------------------------------- 1 | // [START functionsimport] 2 | const functions = require('firebase-functions'); 3 | const express = require('express'); 4 | const matchMock = require('./matchMock'); 5 | const app = express(); 6 | 7 | app.use(matchMock); 8 | 9 | exports.api = functions.https.onRequest(app); 10 | -------------------------------------------------------------------------------- /functions/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "functions", 3 | "description": "Cloud Functions for Firebase", 4 | "scripts": { 5 | "serve": "npm run mock && firebase serve --only functions", 6 | "shell": "firebase functions:shell", 7 | "start": "npm run shell", 8 | "deploy": "firebase deploy --only functions", 9 | "logs": "firebase functions:log", 10 | "mock": "node ../scripts/generateMock.js" 11 | }, 12 | "dependencies": { 13 | "@babel/runtime": "^7.0.0", 14 | "body-parser": "^1.18.3", 15 | "express": "^4.16.3", 16 | "firebase-admin": "^5.12.1", 17 | "firebase-functions": "^2.0.5", 18 | "mockjs": "^1.0.1-beta3", 19 | "moment": "^2.22.2", 20 | "path-to-regexp": "^2.2.1" 21 | }, 22 | "private": true 23 | } 24 | -------------------------------------------------------------------------------- /jest-puppeteer.config.js: -------------------------------------------------------------------------------- 1 | // ps https://github.com/GoogleChrome/puppeteer/issues/3120 2 | module.exports = { 3 | launch: { 4 | headless: true, 5 | args: [ 6 | '--disable-gpu', 7 | '--disable-dev-shm-usage', 8 | '--disable-setuid-sandbox', 9 | '--no-first-run', 10 | '--no-sandbox', 11 | '--no-zygote', 12 | '--single-process', 13 | ], 14 | }, 15 | }; 16 | -------------------------------------------------------------------------------- /jest.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | testURL: 'http://localhost:8000', 3 | preset: 'jest-puppeteer', 4 | }; 5 | -------------------------------------------------------------------------------- /jsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "emitDecoratorMetadata": true, 4 | "experimentalDecorators": true, 5 | "baseUrl": ".", 6 | "paths": { 7 | "@/*": ["./src/*"] 8 | } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /mock/geographic.js: -------------------------------------------------------------------------------- 1 | import city from './geographic/city.json'; 2 | import province from './geographic/province.json'; 3 | 4 | function getProvince(req, res) { 5 | return res.json(province); 6 | } 7 | 8 | function getCity(req, res) { 9 | return res.json(city[req.params.province]); 10 | } 11 | 12 | export default { 13 | 'GET /api/geographic/province': getProvince, 14 | 'GET /api/geographic/city/:province': getCity, 15 | }; 16 | -------------------------------------------------------------------------------- /netlify.toml: -------------------------------------------------------------------------------- 1 | [[redirects]] 2 | from = "/api/*" 3 | to = "https://us-central1-antd-pro.cloudfunctions.net/api/api/:splat" 4 | status = 200 5 | force = true 6 | [redirects.headers] 7 | X-From = "Netlify" 8 | X-Api-Key = "some-api-key-string" 9 | 10 | [[redirects]] 11 | from = "/*" 12 | to = "/index.html" 13 | status = 200 -------------------------------------------------------------------------------- /public/ant.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kuhami/react-ant/717f325a74c1da98343665a8004b5474326ec442/public/ant.jpeg -------------------------------------------------------------------------------- /public/ant1.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kuhami/react-ant/717f325a74c1da98343665a8004b5474326ec442/public/ant1.jpeg -------------------------------------------------------------------------------- /public/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kuhami/react-ant/717f325a74c1da98343665a8004b5474326ec442/public/favicon.png -------------------------------------------------------------------------------- /public/icons/icon-128x128.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kuhami/react-ant/717f325a74c1da98343665a8004b5474326ec442/public/icons/icon-128x128.png -------------------------------------------------------------------------------- /public/icons/icon-192x192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kuhami/react-ant/717f325a74c1da98343665a8004b5474326ec442/public/icons/icon-192x192.png -------------------------------------------------------------------------------- /public/icons/icon-512x512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kuhami/react-ant/717f325a74c1da98343665a8004b5474326ec442/public/icons/icon-512x512.png -------------------------------------------------------------------------------- /public/image/braft-editor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kuhami/react-ant/717f325a74c1da98343665a8004b5474326ec442/public/image/braft-editor.png -------------------------------------------------------------------------------- /public/image/center.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kuhami/react-ant/717f325a74c1da98343665a8004b5474326ec442/public/image/center.png -------------------------------------------------------------------------------- /public/image/drag.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kuhami/react-ant/717f325a74c1da98343665a8004b5474326ec442/public/image/drag.png -------------------------------------------------------------------------------- /public/image/react-color.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kuhami/react-ant/717f325a74c1da98343665a8004b5474326ec442/public/image/react-color.png -------------------------------------------------------------------------------- /public/image/scroll.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kuhami/react-ant/717f325a74c1da98343665a8004b5474326ec442/public/image/scroll.png -------------------------------------------------------------------------------- /public/image/select-tree.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kuhami/react-ant/717f325a74c1da98343665a8004b5474326ec442/public/image/select-tree.png -------------------------------------------------------------------------------- /public/image/star.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kuhami/react-ant/717f325a74c1da98343665a8004b5474326ec442/public/image/star.png -------------------------------------------------------------------------------- /public/image/table.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kuhami/react-ant/717f325a74c1da98343665a8004b5474326ec442/public/image/table.png -------------------------------------------------------------------------------- /scripts/generateMock.js: -------------------------------------------------------------------------------- 1 | const generateMock = require('merge-umi-mock-data'); 2 | const path = require('path'); 3 | generateMock(path.join(__dirname, '../mock'), path.join(__dirname, '../functions/mock/index.js')); 4 | -------------------------------------------------------------------------------- /scripts/getPrettierFiles.js: -------------------------------------------------------------------------------- 1 | const glob = require('glob'); 2 | 3 | const getPrettierFiles = () => { 4 | let files = []; 5 | const jsFiles = glob.sync('src/**/*.js*', { ignore: ['**/node_modules/**', 'build/**'] }); 6 | const tsFiles = glob.sync('src/**/*.ts*', { ignore: ['**/node_modules/**', 'build/**'] }); 7 | const configFiles = glob.sync('config/**/*.js*', { ignore: ['**/node_modules/**', 'build/**'] }); 8 | const scriptFiles = glob.sync('scripts/**/*.js'); 9 | const lessFiles = glob.sync('src/**/*.less*', { ignore: ['**/node_modules/**', 'build/**'] }); 10 | files = files.concat(jsFiles); 11 | files = files.concat(tsFiles); 12 | files = files.concat(configFiles); 13 | files = files.concat(scriptFiles); 14 | files = files.concat(lessFiles); 15 | if (!files.length) { 16 | return; 17 | } 18 | return files; 19 | }; 20 | 21 | module.exports = getPrettierFiles; 22 | -------------------------------------------------------------------------------- /scripts/prettier.js: -------------------------------------------------------------------------------- 1 | /** 2 | * copy to https://github.com/facebook/react/blob/master/scripts/prettier/index.js 3 | * prettier api doc https://prettier.io/docs/en/api.html 4 | *----------*****-------------- 5 | * prettier all js and all ts. 6 | *----------*****-------------- 7 | */ 8 | 9 | const glob = require('glob'); 10 | const prettier = require('prettier'); 11 | const fs = require('fs'); 12 | const getPrettierFiles = require('./getPrettierFiles'); 13 | const prettierConfigPath = require.resolve('../.prettierrc'); 14 | 15 | let didError = false; 16 | 17 | const files = getPrettierFiles(); 18 | 19 | files.forEach(file => { 20 | const options = prettier.resolveConfig.sync(file, { 21 | config: prettierConfigPath, 22 | }); 23 | const fileInfo = prettier.getFileInfo.sync(file); 24 | if (fileInfo.ignored) { 25 | return; 26 | } 27 | try { 28 | const input = fs.readFileSync(file, 'utf8'); 29 | const withParserOptions = { 30 | ...options, 31 | parser: fileInfo.inferredParser, 32 | }; 33 | const output = prettier.format(input, withParserOptions); 34 | if (output !== input) { 35 | fs.writeFileSync(file, output, 'utf8'); 36 | console.log(`\x1b[34m ${file} is prettier`); 37 | } 38 | } catch (e) { 39 | didError = true; 40 | } 41 | }); 42 | 43 | if (didError) { 44 | process.exit(1); 45 | } 46 | console.log('\x1b[32m prettier success!'); 47 | -------------------------------------------------------------------------------- /src/components/ActiveChart/index.less: -------------------------------------------------------------------------------- 1 | .activeChart { 2 | position: relative; 3 | } 4 | .activeChartGrid { 5 | p { 6 | position: absolute; 7 | top: 80px; 8 | } 9 | p:last-child { 10 | top: 115px; 11 | } 12 | } 13 | .activeChartLegend { 14 | position: relative; 15 | font-size: 0; 16 | margin-top: 8px; 17 | height: 20px; 18 | line-height: 20px; 19 | span { 20 | display: inline-block; 21 | font-size: 12px; 22 | text-align: center; 23 | width: 33.33%; 24 | } 25 | span:first-child { 26 | text-align: left; 27 | } 28 | span:last-child { 29 | text-align: right; 30 | } 31 | } 32 | .dashedLine { 33 | position: relative; 34 | height: 1px; 35 | top: -70px; 36 | left: -3px; 37 | 38 | .line { 39 | position: absolute; 40 | top: 0; 41 | left: 0; 42 | width: 100%; 43 | height: 100%; 44 | background-image: linear-gradient(to right, transparent 50%, #e9e9e9 50%); 45 | background-size: 6px; 46 | } 47 | } 48 | 49 | .dashedLine:last-child { 50 | top: -36px; 51 | } 52 | -------------------------------------------------------------------------------- /src/components/AntTableFinder/AntTableFinder.less: -------------------------------------------------------------------------------- 1 | @import '~antd/lib/style/themes/default.less'; 2 | 3 | .tableList { 4 | .tableListOperator { 5 | margin-bottom: 16px; 6 | button { 7 | margin-right: 8px; 8 | } 9 | } 10 | } 11 | .rowBackground{ 12 | background: #f0f0f0; 13 | } 14 | .tableListForm { 15 | :global { 16 | .ant-form-item { 17 | margin-bottom: 14px; 18 | margin-right: 0; 19 | display: flex; 20 | > .ant-form-item-label { 21 | width: auto; 22 | line-height: 32px; 23 | padding-right: 8px; 24 | } 25 | .ant-form-item-control { 26 | line-height: 32px; 27 | } 28 | } 29 | .ant-form-item-control-wrapper { 30 | flex: 1; 31 | } 32 | } 33 | .submitButtons { 34 | display: block; 35 | white-space: nowrap; 36 | margin-bottom: 14px; 37 | } 38 | } 39 | 40 | .td_ellipsis{ 41 | text-overflow: ellipsis; 42 | overflow: hidden; 43 | white-space: nowrap; 44 | } 45 | 46 | @media screen and (max-width: @screen-lg) { 47 | .tableListForm :global(.ant-form-item) { 48 | margin-right: 24px; 49 | } 50 | } 51 | 52 | @media screen and (max-width: @screen-md) { 53 | .tableListForm :global(.ant-form-item) { 54 | margin-right: 8px; 55 | } 56 | } 57 | -------------------------------------------------------------------------------- /src/components/AntTableFinder/AntTableFinder.md: -------------------------------------------------------------------------------- 1 | #Table 2 | 3 | 基于 `ant-design` 封装的多功能 `table` 4 | 5 | ##功能列表 6 | 7 | - -------------------------------------------------------------------------------- /src/components/ArticleListContent/index.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import moment from 'moment'; 3 | import { Avatar } from 'antd'; 4 | import styles from './index.less'; 5 | 6 | const ArticleListContent = ({ data: { content, updatedAt, avatar, owner, href } }) => ( 7 |
= 4 | | React.StatelessComponent
5 | | React.ComponentClass
6 | | React.ClassicComponentClass
;
7 |
8 | type Secured = (
9 | authority: authority,
10 | error?: React.ReactNode
11 | ) => There were injuries alleged in three cases in 2015, and a fourth incident in September, according to the safety recall report. After meeting with US regulators in October, the firm decided to issue a voluntary recall. Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content Content ContentShow Tooltip
25 |
32 |
33 | )}
34 |
35 |
11 |
Ant Design Pro
');
33 | });
34 | });
35 |
--------------------------------------------------------------------------------
/src/e2e/topMenu.e2e.js:
--------------------------------------------------------------------------------
1 | const BASE_URL = `http://localhost:${process.env.PORT || 8000}`;
2 |
3 | describe('Homepage', () => {
4 | beforeAll(async () => {
5 | jest.setTimeout(1000000);
6 | });
7 | it('topmenu should have footer', async () => {
8 | const params = '/form/basic-form?navTheme=light&layout=topmenu';
9 | await page.goto(`${BASE_URL}${params}`);
10 | await page.waitForSelector('footer', {
11 | timeout: 2000,
12 | });
13 | const haveFooter = await page.evaluate(
14 | () => document.getElementsByTagName('footer').length > 0
15 | );
16 | expect(haveFooter).toBeTruthy();
17 | });
18 | });
19 |
--------------------------------------------------------------------------------
/src/e2e/userLayout.e2e.js:
--------------------------------------------------------------------------------
1 | import RouterConfig from '../../config/router.config';
2 |
3 | const BASE_URL = `http://localhost:${process.env.PORT || 8000}`;
4 |
5 | function formatter(data) {
6 | return data
7 | .reduce((pre, item) => {
8 | pre.push(item.path);
9 | return pre;
10 | }, [])
11 | .filter(item => item);
12 | }
13 |
14 | describe('Homepage', () => {
15 | const testPage = path => async () => {
16 | await page.goto(`${BASE_URL}${path}`);
17 | await page.waitForSelector('footer', {
18 | timeout: 2000,
19 | });
20 | const haveFooter = await page.evaluate(
21 | () => document.getElementsByTagName('footer').length > 0
22 | );
23 | expect(haveFooter).toBeTruthy();
24 | };
25 |
26 | beforeAll(async () => {
27 | jest.setTimeout(1000000);
28 | });
29 | formatter(RouterConfig[0].routes).forEach(route => {
30 | fit(`test pages ${route}`, testPage(route));
31 | });
32 | });
33 |
--------------------------------------------------------------------------------
/src/layouts/BasicLayout.less:
--------------------------------------------------------------------------------
1 | @import '~antd/lib/style/themes/default.less';
2 |
3 | .content {
4 | margin: 24px 2px;
5 | // padding-top: @layout-header-height;
6 | padding-top: 42px;
7 | }
8 |
--------------------------------------------------------------------------------
/src/layouts/BlankLayout.js:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 |
3 | export default props => ;
4 |
--------------------------------------------------------------------------------
/src/layouts/Footer.js:
--------------------------------------------------------------------------------
1 | import React, { Fragment } from 'react';
2 | import { Layout, Icon } from 'antd';
3 | import GlobalFooter from '@/components/GlobalFooter';
4 |
5 | const { Footer } = Layout;
6 | const FooterView = () => (
7 |
36 | );
37 | export default FooterView;
38 |
--------------------------------------------------------------------------------
/src/layouts/Header.less:
--------------------------------------------------------------------------------
1 | .fixedHeader {
2 | position: fixed;
3 | top: 0;
4 | right: 0;
5 | width: 100%;
6 | z-index: 9;
7 | transition: width 0.2s;
8 | }
9 |
--------------------------------------------------------------------------------
/src/layouts/MenuContext.js:
--------------------------------------------------------------------------------
1 | import { createContext } from 'react';
2 |
3 | export default createContext();
4 |
--------------------------------------------------------------------------------
/src/locales/en-US.js:
--------------------------------------------------------------------------------
1 | import analysis from './en-US/analysis';
2 | import exception from './en-US/exception';
3 | import form from './en-US/form';
4 | import globalHeader from './en-US/globalHeader';
5 | import login from './en-US/login';
6 | import menu from './en-US/menu';
7 | import monitor from './en-US/monitor';
8 | import result from './en-US/result';
9 | import settingDrawer from './en-US/settingDrawer';
10 | import settings from './en-US/settings';
11 | import pwa from './en-US/pwa';
12 |
13 | export default {
14 | 'navBar.lang': 'Languages',
15 | 'layout.user.link.help': 'Help',
16 | 'layout.user.link.privacy': 'Privacy',
17 | 'layout.user.link.terms': 'Terms',
18 | 'app.home.introduce': 'introduce',
19 | 'app.forms.basic.title': 'Basic form',
20 | 'app.forms.basic.description':
21 | 'Form pages are used to collect or verify information to users, and basic forms are common in scenarios where there are fewer data items.',
22 | ...analysis,
23 | ...exception,
24 | ...form,
25 | ...globalHeader,
26 | ...login,
27 | ...menu,
28 | ...monitor,
29 | ...result,
30 | ...settingDrawer,
31 | ...settings,
32 | ...pwa,
33 | };
34 |
--------------------------------------------------------------------------------
/src/locales/en-US/exception.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'app.exception.back': 'Back to home',
3 | 'app.exception.description.403': "Sorry, you don't have access to this page",
4 | 'app.exception.description.404': 'Sorry, the page you visited does not exist',
5 | 'app.exception.description.500': 'Sorry, the server is reporting an error',
6 | };
7 |
--------------------------------------------------------------------------------
/src/locales/en-US/globalHeader.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'component.globalHeader.search': 'Search',
3 | 'component.globalHeader.search.example1': 'Search example 1',
4 | 'component.globalHeader.search.example2': 'Search example 2',
5 | 'component.globalHeader.search.example3': 'Search example 3',
6 | 'component.globalHeader.help': 'Help',
7 | 'component.globalHeader.notification': 'Notification',
8 | 'component.globalHeader.notification.empty': 'You have viewed all notifications.',
9 | 'component.globalHeader.message': 'Message',
10 | 'component.globalHeader.message.empty': 'You have viewed all messsages.',
11 | 'component.globalHeader.event': 'Event',
12 | 'component.globalHeader.event.empty': 'You have viewed all events.',
13 | 'component.noticeIcon.clear': 'Clear',
14 | 'component.noticeIcon.cleared': 'Cleared',
15 | 'component.noticeIcon.empty': 'No notifications',
16 | 'component.noticeIcon.loaded': 'Loaded',
17 | 'component.noticeIcon.loading-more': 'Loading more',
18 | };
19 |
--------------------------------------------------------------------------------
/src/locales/en-US/monitor.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'app.monitor.trading-activity': 'Real-Time Trading Activity',
3 | 'app.monitor.total-transactions': 'Total transactions today',
4 | 'app.monitor.sales-target': 'Sales target completion rate',
5 | 'app.monitor.remaining-time': 'Remaining time of activity',
6 | 'app.monitor.total-transactions-per-second': 'Total transactions per second',
7 | 'app.monitor.activity-forecast': 'Activity forecast',
8 | 'app.monitor.efficiency': 'Efficiency',
9 | 'app.monitor.ratio': 'Ratio',
10 | 'app.monitor.proportion-per-category': 'Proportion Per Category',
11 | 'app.monitor.fast-food': 'Fast food',
12 | 'app.monitor.western-food': 'Western food',
13 | 'app.monitor.hot-pot': 'Hot pot',
14 | 'app.monitor.waiting-for-implementation': 'Waiting for implementation',
15 | 'app.monitor.popular-searches': 'Popular Searches',
16 | 'app.monitor.resource-surplus': 'Resource Surplus',
17 | 'app.monitor.fund-surplus': 'Fund Surplus',
18 | };
19 |
--------------------------------------------------------------------------------
/src/locales/en-US/pwa.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'app.pwa.offline': 'You are offline now',
3 | 'app.pwa.serviceworker.updated': 'New content is available',
4 | 'app.pwa.serviceworker.updated.hint': 'Please press the "Refresh" button to reload current page',
5 | 'app.pwa.serviceworker.updated.ok': 'Refresh',
6 | };
7 |
--------------------------------------------------------------------------------
/src/locales/pt-BR.js:
--------------------------------------------------------------------------------
1 | import analysis from './pt-BR/analysis';
2 | import exception from './pt-BR/exception';
3 | import form from './pt-BR/form';
4 | import globalHeader from './pt-BR/globalHeader';
5 | import login from './pt-BR/login';
6 | import menu from './pt-BR/menu';
7 | import monitor from './pt-BR/monitor';
8 | import result from './pt-BR/result';
9 | import settingDrawer from './pt-BR/settingDrawer';
10 | import settings from './pt-BR/settings';
11 | import pwa from './pt-BR/pwa';
12 |
13 | export default {
14 | 'navBar.lang': 'Idiomas',
15 | 'layout.user.link.help': 'ajuda',
16 | 'layout.user.link.privacy': 'política de privacidade',
17 | 'layout.user.link.terms': 'termos de serviços',
18 | 'app.home.introduce': 'introduzir',
19 | 'app.forms.basic.title': 'Basic form',
20 | 'app.forms.basic.description':
21 | 'Páginas de formulário são usadas para coletar e verificar as informações dos usuários e formulários básicos são comuns nos cenários onde existem alguns formatos de informações.',
22 | ...analysis,
23 | ...exception,
24 | ...form,
25 | ...globalHeader,
26 | ...login,
27 | ...menu,
28 | ...monitor,
29 | ...result,
30 | ...settingDrawer,
31 | ...settings,
32 | ...pwa,
33 | };
34 |
--------------------------------------------------------------------------------
/src/locales/pt-BR/exception.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'app.exception.back': 'Voltar para Início',
3 | 'app.exception.description.403': 'Desculpe, você não tem acesso a esta página',
4 | 'app.exception.description.404': 'Desculpe, a página que você visitou não existe',
5 | 'app.exception.description.500': 'Desculpe, o servidor está reportando um erro',
6 | };
7 |
--------------------------------------------------------------------------------
/src/locales/pt-BR/globalHeader.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'component.globalHeader.search': 'Busca',
3 | 'component.globalHeader.search.example1': 'Exemplo de busca 1',
4 | 'component.globalHeader.search.example2': 'Exemplo de busca 2',
5 | 'component.globalHeader.search.example3': 'Exemplo de busca 3',
6 | 'component.globalHeader.help': 'Ajuda',
7 | 'component.globalHeader.notification': 'Notificação',
8 | 'component.globalHeader.notification.empty': 'Você visualizou todas as notificações.',
9 | 'component.globalHeader.message': 'Mensagem',
10 | 'component.globalHeader.message.empty': 'Você visualizou todas as mensagens.',
11 | 'component.globalHeader.event': 'Evento',
12 | 'component.globalHeader.event.empty': 'Você visualizou todos os eventos.',
13 | 'component.noticeIcon.clear': 'Limpar',
14 | 'component.noticeIcon.cleared': 'Limpo',
15 | 'component.noticeIcon.empty': 'Sem notificações',
16 | 'component.noticeIcon.loaded': 'Carregado',
17 | 'component.noticeIcon.loading-more': 'Carregar mais',
18 | };
19 |
--------------------------------------------------------------------------------
/src/locales/pt-BR/monitor.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'app.monitor.trading-activity': 'Atividade de Trading Real-time',
3 | 'app.monitor.total-transactions': 'Total de transações hoje',
4 | 'app.monitor.sales-target': 'Taxa de conclusão da meta de vendas',
5 | 'app.monitor.remaining-time': 'Tempo restante da atividade',
6 | 'app.monitor.total-transactions-per-second': 'Total de transações por segundo',
7 | 'app.monitor.activity-forecast': 'Previsão atual',
8 | 'app.monitor.efficiency': 'Eficiência',
9 | 'app.monitor.ratio': 'Relação',
10 | 'app.monitor.proportion-per-category': 'Proporção por categoria',
11 | 'app.monitor.fast-food': 'Fast food',
12 | 'app.monitor.western-food': 'Comida Ocidental',
13 | 'app.monitor.hot-pot': 'Hot pot',
14 | 'app.monitor.waiting-for-implementation': 'Aguardando implementação',
15 | 'app.monitor.popular-searches': 'Buscas populares',
16 | 'app.monitor.resource-surplus': 'Excedente de recursos',
17 | 'app.monitor.fund-surplus': 'Excedente do fundo',
18 | 'app.exception.back': 'Voltar a home',
19 | };
20 |
--------------------------------------------------------------------------------
/src/locales/pt-BR/pwa.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'app.pwa.offline': 'Você está offline agora',
3 | 'app.pwa.serviceworker.updated': 'Novo conteúdo está disponível',
4 | 'app.pwa.serviceworker.updated.hint':
5 | 'Por favor, pressione o botão "Atualizar" para recarregar a página atual',
6 | 'app.pwa.serviceworker.updated.ok': 'Atualizar',
7 | };
8 |
--------------------------------------------------------------------------------
/src/locales/zh-CN.js:
--------------------------------------------------------------------------------
1 | import analysis from './zh-CN/analysis';
2 | import exception from './zh-CN/exception';
3 | import form from './zh-CN/form';
4 | import globalHeader from './zh-CN/globalHeader';
5 | import login from './zh-CN/login';
6 | import menu from './zh-CN/menu';
7 | import monitor from './zh-CN/monitor';
8 | import result from './zh-CN/result';
9 | import settingDrawer from './zh-CN/settingDrawer';
10 | import settings from './zh-CN/settings';
11 | import pwa from './zh-CN/pwa';
12 |
13 | export default {
14 | 'navBar.lang': '语言',
15 | 'layout.user.link.help': '帮助',
16 | 'layout.user.link.privacy': '隐私',
17 | 'layout.user.link.terms': '条款',
18 | 'app.home.introduce': '介绍',
19 | 'app.forms.basic.title': '基础表单',
20 | 'app.forms.basic.description':
21 | '表单页用于向用户收集或验证信息,基础表单常见于数据项较少的表单场景。',
22 | ...analysis,
23 | ...exception,
24 | ...form,
25 | ...globalHeader,
26 | ...login,
27 | ...menu,
28 | ...monitor,
29 | ...result,
30 | ...settingDrawer,
31 | ...settings,
32 | ...pwa,
33 | };
34 |
--------------------------------------------------------------------------------
/src/locales/zh-CN/analysis.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'app.analysis.test': '工专路 {no} 号店',
3 | 'app.analysis.introduce': '指标说明',
4 | 'app.analysis.total-sales': '总销售额',
5 | 'app.analysis.day-sales': '日销售额',
6 | 'app.analysis.visits': '访问量',
7 | 'app.analysis.visits-trend': '访问量趋势',
8 | 'app.analysis.visits-ranking': '门店访问量排名',
9 | 'app.analysis.day-visits': '日访问量',
10 | 'app.analysis.week': '周同比',
11 | 'app.analysis.day': '日同比',
12 | 'app.analysis.payments': '支付笔数',
13 | 'app.analysis.conversion-rate': '转化率',
14 | 'app.analysis.operational-effect': '运营活动效果',
15 | 'app.analysis.sales-trend': '销售趋势',
16 | 'app.analysis.sales-ranking': '门店销售额排名',
17 | 'app.analysis.all-year': '全年',
18 | 'app.analysis.all-month': '本月',
19 | 'app.analysis.all-week': '本周',
20 | 'app.analysis.all-day': '今日',
21 | 'app.analysis.search-users': '搜索用户数',
22 | 'app.analysis.per-capita-search': '人均搜索次数',
23 | 'app.analysis.online-top-search': '线上热门搜索',
24 | 'app.analysis.the-proportion-of-sales': '销售额类别占比',
25 | 'app.analysis.channel.all': '全部渠道',
26 | 'app.analysis.channel.online': '线上',
27 | 'app.analysis.channel.stores': '门店',
28 | 'app.analysis.sales': '销售额',
29 | 'app.analysis.traffic': '客流量',
30 | 'app.analysis.table.rank': '排名',
31 | 'app.analysis.table.search-keyword': '搜索关键词',
32 | 'app.analysis.table.users': '用户数',
33 | 'app.analysis.table.weekly-range': '周涨幅',
34 | };
35 |
--------------------------------------------------------------------------------
/src/locales/zh-CN/exception.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'app.exception.back': '返回首页',
3 | 'app.exception.description.403': '抱歉,你无权访问该页面',
4 | 'app.exception.description.404': '抱歉,你访问的页面不存在',
5 | 'app.exception.description.500': '抱歉,服务器出错了',
6 | };
7 |
--------------------------------------------------------------------------------
/src/locales/zh-CN/globalHeader.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'component.globalHeader.search': '站内搜索',
3 | 'component.globalHeader.search.example1': '搜索提示一',
4 | 'component.globalHeader.search.example2': '搜索提示二',
5 | 'component.globalHeader.search.example3': '搜索提示三',
6 | 'component.globalHeader.help': '使用文档',
7 | 'component.globalHeader.notification': '通知',
8 | 'component.globalHeader.notification.empty': '你已查看所有通知',
9 | 'component.globalHeader.message': '消息',
10 | 'component.globalHeader.message.empty': '您已读完所有消息',
11 | 'component.globalHeader.event': '待办',
12 | 'component.globalHeader.event.empty': '你已完成所有待办',
13 | 'component.noticeIcon.clear': '清空',
14 | 'component.noticeIcon.cleared': '清空了',
15 | 'component.noticeIcon.empty': '暂无数据',
16 | 'component.noticeIcon.loaded': '加载完毕',
17 | 'component.noticeIcon.loading-more': '加载更多',
18 | };
19 |
--------------------------------------------------------------------------------
/src/locales/zh-CN/monitor.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'app.monitor.trading-activity': '活动实时交易情况',
3 | 'app.monitor.total-transactions': '今日交易总额',
4 | 'app.monitor.sales-target': '销售目标完成率',
5 | 'app.monitor.remaining-time': '活动剩余时间',
6 | 'app.monitor.total-transactions-per-second': '每秒交易总额',
7 | 'app.monitor.activity-forecast': '活动情况预测',
8 | 'app.monitor.efficiency': '券核效率',
9 | 'app.monitor.ratio': '跳出率',
10 | 'app.monitor.proportion-per-category': '各品类占比',
11 | 'app.monitor.fast-food': '中式快餐',
12 | 'app.monitor.western-food': '西餐',
13 | 'app.monitor.hot-pot': '火锅',
14 | 'app.monitor.waiting-for-implementation': 'Waiting for implementation',
15 | 'app.monitor.popular-searches': '热门搜索',
16 | 'app.monitor.resource-surplus': '资源剩余',
17 | 'app.monitor.fund-surplus': '补贴资金剩余',
18 | };
19 |
--------------------------------------------------------------------------------
/src/locales/zh-CN/pwa.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'app.pwa.offline': '当前处于离线状态',
3 | 'app.pwa.serviceworker.updated': '有新内容',
4 | 'app.pwa.serviceworker.updated.hint': '请点击“刷新”按钮或者手动刷新页面',
5 | 'app.pwa.serviceworker.updated.ok': '刷新',
6 | };
7 |
--------------------------------------------------------------------------------
/src/locales/zh-CN/result.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'app.result.error.title': '提交失败',
3 | 'app.result.error.description': '请核对并修改以下信息后,再重新提交。',
4 | 'app.result.error.hint-title': '您提交的内容有如下错误:',
5 | 'app.result.error.hint-text1': '您的账户已被冻结',
6 | 'app.result.error.hint-btn1': '立即解冻',
7 | 'app.result.error.hint-text2': '您的账户还不具备申请资格',
8 | 'app.result.error.hint-btn2': '立即升级',
9 | 'app.result.error.btn-text': '返回修改',
10 | 'app.result.success.title': '提交成功',
11 | 'app.result.success.description':
12 | '提交结果页用于反馈一系列操作任务的处理结果, 如果仅是简单操作,使用 Message 全局提示反馈即可。 本文字区域可以展示简单的补充说明,如果有类似展示 “单据”的需求,下面这个灰色区域可以呈现比较复杂的内容。',
13 | 'app.result.success.operate-title': '项目名称',
14 | 'app.result.success.operate-id': '项目 ID:',
15 | 'app.result.success.principal': '负责人:',
16 | 'app.result.success.operate-time': '生效时间:',
17 | 'app.result.success.step1-title': '创建项目',
18 | 'app.result.success.step1-operator': '曲丽丽',
19 | 'app.result.success.step2-title': '部门初审',
20 | 'app.result.success.step2-operator': '周毛毛',
21 | 'app.result.success.step2-extra': '催一下',
22 | 'app.result.success.step3-title': '财务复核',
23 | 'app.result.success.step4-title': '完成',
24 | 'app.result.success.btn-return': '返回列表',
25 | 'app.result.success.btn-project': '查看项目',
26 | 'app.result.success.btn-print': '打印',
27 | };
28 |
--------------------------------------------------------------------------------
/src/locales/zh-CN/settingDrawer.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'app.setting.pagestyle': '整体风格设置',
3 | 'app.setting.pagestyle.dark': '暗色菜单风格',
4 | 'app.setting.pagestyle.light': '亮色菜单风格',
5 | 'app.setting.content-width': '内容区域宽度',
6 | 'app.setting.content-width.fixed': '定宽',
7 | 'app.setting.content-width.fluid': '流式',
8 | 'app.setting.themecolor': '主题色',
9 | 'app.setting.themecolor.dust': '薄暮',
10 | 'app.setting.themecolor.volcano': '火山',
11 | 'app.setting.themecolor.sunset': '日暮',
12 | 'app.setting.themecolor.cyan': '明青',
13 | 'app.setting.themecolor.green': '极光绿',
14 | 'app.setting.themecolor.daybreak': '拂晓蓝(默认)',
15 | 'app.setting.themecolor.geekblue': '极客蓝',
16 | 'app.setting.themecolor.purple': '酱紫',
17 | 'app.setting.navigationmode': '导航模式',
18 | 'app.setting.sidemenu': '侧边菜单布局',
19 | 'app.setting.topmenu': '顶部菜单布局',
20 | 'app.setting.fixedheader': '固定 Header',
21 | 'app.setting.fixedsidebar': '固定侧边菜单',
22 | 'app.setting.hidenAntTabs': '隐藏 Ant-Tabs',
23 | 'app.setting.fixedsidebar.hint': '侧边菜单布局时可配置',
24 | 'app.setting.hideheader': '下滑时隐藏 Header',
25 | 'app.setting.hideheader.hint': '固定 Header 时可配置',
26 | 'app.setting.othersettings': '其他设置',
27 | 'app.setting.weakmode': '色弱模式',
28 | 'app.setting.copy': '拷贝设置',
29 | 'app.setting.copyinfo': '拷贝成功,请到 src/defaultSettings.js 中替换默认配置',
30 | 'app.setting.production.hint':
31 | '配置栏只在开发环境用于预览,生产环境不会展现,请拷贝后手动修改配置文件',
32 | };
33 |
--------------------------------------------------------------------------------
/src/locales/zh-TW.js:
--------------------------------------------------------------------------------
1 | import analysis from './zh-TW/analysis';
2 | import exception from './zh-TW/exception';
3 | import form from './zh-TW/form';
4 | import globalHeader from './zh-TW/globalHeader';
5 | import login from './zh-TW/login';
6 | import menu from './zh-TW/menu';
7 | import monitor from './zh-TW/monitor';
8 | import result from './zh-TW/result';
9 | import settingDrawer from './zh-TW/settingDrawer';
10 | import settings from './zh-TW/settings';
11 | import pwa from './zh-TW/pwa';
12 |
13 | export default {
14 | 'navBar.lang': '語言',
15 | 'layout.user.link.help': '幫助',
16 | 'layout.user.link.privacy': '隱私',
17 | 'layout.user.link.terms': '條款',
18 | 'app.home.introduce': '介紹',
19 | 'app.forms.basic.title': '基礎表單',
20 | 'app.forms.basic.description':
21 | '表單頁用於向用戶收集或驗證信息,基礎表單常見於數據項較少的表單場景。',
22 | ...analysis,
23 | ...exception,
24 | ...form,
25 | ...globalHeader,
26 | ...login,
27 | ...menu,
28 | ...monitor,
29 | ...result,
30 | ...settingDrawer,
31 | ...settings,
32 | ...pwa,
33 | };
34 |
--------------------------------------------------------------------------------
/src/locales/zh-TW/analysis.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'app.analysis.test': '工專路 {no} 號店',
3 | 'app.analysis.introduce': '指標說明',
4 | 'app.analysis.total-sales': '總銷售額',
5 | 'app.analysis.day-sales': '日銷售額',
6 | 'app.analysis.visits': '訪問量',
7 | 'app.analysis.visits-trend': '訪問量趨勢',
8 | 'app.analysis.visits-ranking': '門店訪問量排名',
9 | 'app.analysis.day-visits': '日訪問量',
10 | 'app.analysis.week': '周同比',
11 | 'app.analysis.day': '日同比',
12 | 'app.analysis.payments': '支付筆數',
13 | 'app.analysis.conversion-rate': '轉化率',
14 | 'app.analysis.operational-effect': '運營活動效果',
15 | 'app.analysis.sales-trend': '銷售趨勢',
16 | 'app.analysis.sales-ranking': '門店銷售額排名',
17 | 'app.analysis.all-year': '全年',
18 | 'app.analysis.all-month': '本月',
19 | 'app.analysis.all-week': '本周',
20 | 'app.analysis.all-day': '今日',
21 | 'app.analysis.search-users': '搜索用戶數',
22 | 'app.analysis.per-capita-search': '人均搜索次數',
23 | 'app.analysis.online-top-search': '線上熱門搜索',
24 | 'app.analysis.the-proportion-of-sales': '銷售額類別占比',
25 | 'app.analysis.channel.all': '全部渠道',
26 | 'app.analysis.channel.online': '線上',
27 | 'app.analysis.channel.stores': '門店',
28 | 'app.analysis.sales': '銷售額',
29 | 'app.analysis.traffic': '客流量',
30 | 'app.analysis.table.rank': '排名',
31 | 'app.analysis.table.search-keyword': '搜索關鍵詞',
32 | 'app.analysis.table.users': '用戶數',
33 | 'app.analysis.table.weekly-range': '周漲幅',
34 | };
35 |
--------------------------------------------------------------------------------
/src/locales/zh-TW/exception.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'app.exception.back': '返回首頁',
3 | 'app.exception.description.403': '抱歉,妳無權訪問該頁面',
4 | 'app.exception.description.404': '抱歉,妳訪問的頁面不存在',
5 | 'app.exception.description.500': '抱歉,服務器出錯了',
6 | };
7 |
--------------------------------------------------------------------------------
/src/locales/zh-TW/globalHeader.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'component.globalHeader.search': '站內搜索',
3 | 'component.globalHeader.search.example1': '搜索提示壹',
4 | 'component.globalHeader.search.example2': '搜索提示二',
5 | 'component.globalHeader.search.example3': '搜索提示三',
6 | 'component.globalHeader.help': '使用文檔',
7 | 'component.globalHeader.notification': '通知',
8 | 'component.globalHeader.notification.empty': '妳已查看所有通知',
9 | 'component.globalHeader.message': '消息',
10 | 'component.globalHeader.message.empty': '您已讀完所有消息',
11 | 'component.globalHeader.event': '待辦',
12 | 'component.globalHeader.event.empty': '妳已完成所有待辦',
13 | 'component.noticeIcon.clear': '清空',
14 | 'component.noticeIcon.cleared': '清空了',
15 | 'component.noticeIcon.empty': '暫無數據',
16 | 'component.noticeIcon.loaded': '加載完畢',
17 | 'component.noticeIcon.loading-more': '加載更多',
18 | };
19 |
--------------------------------------------------------------------------------
/src/locales/zh-TW/monitor.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'app.monitor.trading-activity': '活動實時交易情況',
3 | 'app.monitor.total-transactions': '今日交易總額',
4 | 'app.monitor.sales-target': '銷售目標完成率',
5 | 'app.monitor.remaining-time': '活動剩余時間',
6 | 'app.monitor.total-transactions-per-second': '每秒交易總額',
7 | 'app.monitor.activity-forecast': '活動情況預測',
8 | 'app.monitor.efficiency': '券核效率',
9 | 'app.monitor.ratio': '跳出率',
10 | 'app.monitor.proportion-per-category': '各品類占比',
11 | 'app.monitor.fast-food': '中式快餐',
12 | 'app.monitor.western-food': '西餐',
13 | 'app.monitor.hot-pot': '火鍋',
14 | 'app.monitor.waiting-for-implementation': 'Waiting for implementation',
15 | 'app.monitor.popular-searches': '熱門搜索',
16 | 'app.monitor.resource-surplus': '資源剩余',
17 | 'app.monitor.fund-surplus': '補貼資金剩余',
18 | };
19 |
--------------------------------------------------------------------------------
/src/locales/zh-TW/pwa.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'app.pwa.offline': '當前處於離線狀態',
3 | 'app.pwa.serviceworker.updated': '有新內容',
4 | 'app.pwa.serviceworker.updated.hint': '請點擊“刷新”按鈕或者手動刷新頁面',
5 | 'app.pwa.serviceworker.updated.ok': '刷新',
6 | };
7 |
--------------------------------------------------------------------------------
/src/locales/zh-TW/result.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'app.result.error.title': '提交失敗',
3 | 'app.result.error.description': '請核對並修改以下信息後,再重新提交。',
4 | 'app.result.error.hint-title': '您提交的內容有如下錯誤:',
5 | 'app.result.error.hint-text1': '您的賬戶已被凍結',
6 | 'app.result.error.hint-btn1': '立即解凍',
7 | 'app.result.error.hint-text2': '您的賬戶還不具備申請資格',
8 | 'app.result.error.hint-btn2': '立即升級',
9 | 'app.result.error.btn-text': '返回修改',
10 | 'app.result.success.title': '提交成功',
11 | 'app.result.success.description':
12 | '提交結果頁用於反饋壹系列操作任務的處理結果, 如果僅是簡單操作,使用 Message 全局提示反饋即可。 本文字區域可以展示簡單的補充說明,如果有類似展示 “單據”的需求,下面這個灰色區域可以呈現比較復雜的內容。',
13 | 'app.result.success.operate-title': '項目名稱',
14 | 'app.result.success.operate-id': '項目 ID:',
15 | 'app.result.success.principal': '負責人:',
16 | 'app.result.success.operate-time': '生效時間:',
17 | 'app.result.success.step1-title': '創建項目',
18 | 'app.result.success.step1-operator': '曲麗麗',
19 | 'app.result.success.step2-title': '部門初審',
20 | 'app.result.success.step2-operator': '周毛毛',
21 | 'app.result.success.step2-extra': '催壹下',
22 | 'app.result.success.step3-title': '財務復核',
23 | 'app.result.success.step4-title': '完成',
24 | 'app.result.success.btn-return': '返回列表',
25 | 'app.result.success.btn-project': '查看項目',
26 | 'app.result.success.btn-print': '打印',
27 | };
28 |
--------------------------------------------------------------------------------
/src/locales/zh-TW/settingDrawer.js:
--------------------------------------------------------------------------------
1 | export default {
2 | 'app.setting.pagestyle': '整體風格設置',
3 | 'app.setting.pagestyle.dark': '暗色菜單風格',
4 | 'app.setting.pagestyle.light': '亮色菜單風格',
5 | 'app.setting.content-width': '內容區域寬度',
6 | 'app.setting.content-width.fixed': '定寬',
7 | 'app.setting.content-width.fluid': '流式',
8 | 'app.setting.themecolor': '主題色',
9 | 'app.setting.themecolor.dust': '薄暮',
10 | 'app.setting.themecolor.volcano': '火山',
11 | 'app.setting.themecolor.sunset': '日暮',
12 | 'app.setting.themecolor.cyan': '明青',
13 | 'app.setting.themecolor.green': '極光綠',
14 | 'app.setting.themecolor.daybreak': '拂曉藍(默認)',
15 | 'app.setting.themecolor.geekblue': '極客藍',
16 | 'app.setting.themecolor.purple': '醬紫',
17 | 'app.setting.navigationmode': '導航模式',
18 | 'app.setting.sidemenu': '側邊菜單布局',
19 | 'app.setting.topmenu': '頂部菜單布局',
20 | 'app.setting.fixedheader': '固定 Header',
21 | 'app.setting.fixedsidebar': '固定側邊菜單',
22 | 'app.setting.fixedsidebar.hint': '側邊菜單布局時可配置',
23 | 'app.setting.hideheader': '下滑時隱藏 Header',
24 | 'app.setting.hideheader.hint': '固定 Header 時可配置',
25 | 'app.setting.othersettings': '其他設置',
26 | 'app.setting.weakmode': '色弱模式',
27 | 'app.setting.copy': '拷貝設置',
28 | 'app.setting.copyinfo': '拷貝成功,請到 src/defaultSettings.js 中替換默認配置',
29 | 'app.setting.production.hint':
30 | '配置欄只在開發環境用於預覽,生產環境不會展現,請拷貝後手動修改配置文件',
31 | 'app.setting.hidenAntTabs': '隐藏 Ant-Tabs',
32 | };
33 |
--------------------------------------------------------------------------------
/src/manifest.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "Ant Tabs",
3 | "short_name": "Ant Tabs",
4 | "display": "standalone",
5 | "start_url": "./?utm_source=homescreen",
6 | "theme_color": "#002140",
7 | "background_color": "#001529",
8 | "icons": [
9 | {
10 | "src": "icons/icon-192x192.png",
11 | "sizes": "192x192"
12 | },
13 | {
14 | "src": "icons/icon-128x128.png",
15 | "sizes": "128x128"
16 | },
17 | {
18 | "src": "icons/icon-512x512.png",
19 | "sizes": "512x512"
20 | }
21 | ]
22 | }
23 |
--------------------------------------------------------------------------------
/src/models/project.js:
--------------------------------------------------------------------------------
1 | import { queryProjectNotice } from '@/services/api';
2 |
3 | export default {
4 | namespace: 'project',
5 |
6 | state: {
7 | notice: [],
8 | },
9 |
10 | effects: {
11 | *fetchNotice(_, { call, put }) {
12 | const response = yield call(queryProjectNotice);
13 | yield put({
14 | type: 'saveNotice',
15 | payload: Array.isArray(response) ? response : [],
16 | });
17 | },
18 | },
19 |
20 | reducers: {
21 | saveNotice(state, action) {
22 | return {
23 | ...state,
24 | notice: action.payload,
25 | };
26 | },
27 | },
28 | };
29 |
--------------------------------------------------------------------------------
/src/models/user.js:
--------------------------------------------------------------------------------
1 | import { query as queryUsers, queryCurrent } from '@/services/user';
2 |
3 | export default {
4 | namespace: 'user',
5 |
6 | state: {
7 | list: [],
8 | currentUser: {},
9 | },
10 |
11 | effects: {
12 | *fetch(_, { call, put }) {
13 | const response = yield call(queryUsers);
14 | yield put({
15 | type: 'save',
16 | payload: response,
17 | });
18 | },
19 | *fetchCurrent(_, { call, put }) {
20 | const response = yield call(queryCurrent);
21 | yield put({
22 | type: 'saveCurrentUser',
23 | payload: response,
24 | });
25 | },
26 | },
27 |
28 | reducers: {
29 | save(state, action) {
30 | return {
31 | ...state,
32 | list: action.payload,
33 | };
34 | },
35 | saveCurrentUser(state, action) {
36 | return {
37 | ...state,
38 | currentUser: action.payload || {},
39 | };
40 | },
41 | changeNotifyCount(state, action) {
42 | return {
43 | ...state,
44 | currentUser: {
45 | ...state.currentUser,
46 | notifyCount: action.payload.totalCount,
47 | unreadCount: action.payload.unreadCount,
48 | },
49 | };
50 | },
51 | },
52 | };
53 |
--------------------------------------------------------------------------------
/src/pages/404.js:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import Link from 'umi/link';
3 | import { formatMessage } from 'umi/locale';
4 | import Exception from '@/components/Exception';
5 |
6 | export default () => (
7 |
11 | {items.map((value, index) => (
12 |
15 | );
16 | });
17 | export default class Basic extends Component {
18 | constructor(props){
19 | super(props);
20 | this.state = {
21 | items: ['Item 1', 'Item 2', 'Item 3', 'Item 4', 'Item 5', 'Item 6'],
22 | }
23 | }
24 | componentDidMount() {
25 |
26 | }
27 | onSortEnd = ({oldIndex, newIndex}) => {
28 | this.setState(({items}) => ({
29 | items: arrayMove(items, oldIndex, newIndex),
30 | }));
31 | };
32 | render() {
33 | const title = 拖拽(react-sortable-hoc)
34 | return ({children}
;
21 | });
22 | export default class DragHandle extends Component {
23 | constructor(props){
24 | super(props);
25 | this.state = {
26 | items: ['Item 1', 'Item 2', 'Item 3', 'Item 4', 'Item 5', 'Item 6'],
27 | }
28 | }
29 |
30 | onSortEnd = ({oldIndex, newIndex}) => {
31 | this.setState(({items}) => ({
32 | items: arrayMove(items, oldIndex, newIndex),
33 | }));
34 | };
35 | render() {
36 | const {items} = this.state;
37 | return (