diff --git a/src/pages/System/Menu/IconPreview/IconData.js b/src/components/IconPreview/IconData.js
similarity index 94%
rename from src/pages/System/Menu/IconPreview/IconData.js
rename to src/components/IconPreview/IconData.js
index 98c76a8..388ab04 100644
--- a/src/pages/System/Menu/IconPreview/IconData.js
+++ b/src/components/IconPreview/IconData.js
@@ -1,371 +1,371 @@
-export const iconData = [
- {
- category: 'direction',
- description: '方向性图标',
- icons: [
- 'step-backward',
- 'step-forward',
- 'fast-backward',
- 'fast-forward',
- 'shrink',
- 'arrows-alt',
- 'down',
- 'up',
- 'left',
- 'right',
- 'caret-up',
- 'caret-down',
- 'caret-left',
- 'caret-right',
- 'up-circle',
- 'down-circle',
- 'left-circle',
- 'right-circle',
- 'double-right',
- 'double-left',
- 'vertical-left',
- 'vertical-right',
- 'forward',
- 'backward',
- 'rollback',
- 'enter',
- 'retweet',
- 'swap',
- 'swap-left',
- 'swap-right',
- 'arrow-up',
- 'arrow-down',
- 'arrow-left',
- 'arrow-right',
- 'play-circle',
- 'up-square',
- 'down-square',
- 'left-square',
- 'right-square',
- 'login',
- 'logout',
- 'menu-fold',
- 'menu-unfold',
- 'border-bottom',
- 'border-horizontal',
- 'border-inner',
- 'border-left',
- 'border-right',
- 'border-top',
- 'border-verticle',
- 'pic-center',
- 'pic-left',
- 'pic-right',
- 'radius-bottomleft',
- 'radius-bottomright',
- 'radius-upleft',
- 'fullscreen',
- 'fullscreen-exit',
- ],
- },
- {
- category: 'suggestion',
- description: '提示建议性图标',
- icons: [
- 'question',
- 'question-circle',
- 'plus',
- 'plus-circle',
- 'pause',
- 'pause-circle',
- 'minus',
- 'minus-circle',
- 'plus-square',
- 'minus-square',
- 'info',
- 'info-circle',
- 'exclamation',
- 'exclamation-circle',
- 'close',
- 'close-circle',
- 'close-square',
- 'check',
- 'check-circle',
- 'check-square',
- 'clock-circle',
- 'warning',
- 'issues-close',
- 'stop',
- ],
- },
- {
- category: 'edit',
- description: '编辑类图标',
- icons: [
- 'edit',
- 'form',
- 'copy',
- 'scissor',
- 'delete',
- 'snippets',
- 'diff',
- 'highlight',
- 'align-center',
- 'align-left',
- 'align-right',
- 'bg-colors',
- 'bold',
- 'italic',
- 'underline',
- 'strikethrough',
- 'redo',
- 'undo',
- 'zoom-in',
- 'zoom-out',
- 'font-colors',
- 'font-size',
- 'line-height',
- 'colum-height',
- 'dash',
- 'small-dash',
- 'sort-ascending',
- 'sort-descending',
- 'drag',
- 'ordered-list',
- 'radius-setting',
- ],
- },
- {
- category: 'data:',
- description: '数据类图标',
- icons: [
- 'area-chart',
- 'pie-chart',
- 'bar-chart',
- 'dot-chart',
- 'line-chart',
- 'radar-chart',
- 'heat-map',
- 'fall',
- 'rise',
- 'stock',
- 'box-plot',
- 'fund',
- 'sliders',
- ],
- },
- {
- category: 'other',
- description: '网站通用图标',
- icons: [
- 'lock',
- 'unlock',
- 'bars',
- 'book',
- 'calendar',
- 'cloud',
- 'cloud-download',
- 'code',
- 'copy',
- 'credit-card',
- 'delete',
- 'desktop',
- 'download',
- 'ellipsis',
- 'file',
- 'file-text',
- 'file-unknown',
- 'file-pdf',
- 'file-word',
- 'file-excel',
- 'file-jpg',
- 'file-ppt',
- 'file-markdown',
- 'file-add',
- 'folder',
- 'folder-open',
- 'folder-add',
- 'hdd',
- 'frown',
- 'meh',
- 'smile',
- 'inbox',
- 'laptop',
- 'appstore',
- 'link',
- 'mail',
- 'mobile',
- 'notification',
- 'paper-clip',
- 'picture',
- 'poweroff',
- 'reload',
- 'search',
- 'setting',
- 'share-alt',
- 'shopping-cart',
- 'tablet',
- 'tag',
- 'tags',
- 'to-top',
- 'upload',
- 'user',
- 'video-camera',
- 'home',
- 'loading',
- 'loading-3-quarters',
- 'cloud-upload',
- 'star',
- 'heart',
- 'environment',
- 'eye',
- 'eye-invisible',
- 'camera',
- 'save',
- 'team',
- 'solution',
- 'phone',
- 'filter',
- 'exception',
- 'export',
- 'customer-service',
- 'qrcode',
- 'scan',
- 'like',
- 'dislike',
- 'message',
- 'pay-circle',
- 'calculator',
- 'pushpin',
- 'bulb',
- 'select',
- 'switcher',
- 'rocket',
- 'bell',
- 'disconnect',
- 'database',
- 'compass',
- 'barcode',
- 'hourglass',
- 'key',
- 'flag',
- 'layout',
- 'printer',
- 'sound',
- 'usb',
- 'skin',
- 'tool',
- 'sync',
- 'wifi',
- 'car',
- 'schedule',
- 'user-add',
- 'user-delete',
- 'usergroup-add',
- 'usergroup-delete',
- 'man',
- 'woman',
- 'shop',
- 'gift',
- 'idcard',
- 'medicine-box',
- 'red-envelope',
- 'coffee',
- 'copyright',
- 'trademark',
- 'safety',
- 'wallet',
- 'bank',
- 'trophy',
- 'contacts',
- 'global',
- 'shake',
- 'api',
- 'fork',
- 'dashboard',
- 'table',
- 'profile',
- 'alert',
- 'audit',
- 'branches',
- 'build',
- 'border',
- 'crown',
- 'experiment',
- 'fire',
- 'money-collect',
- 'property-safety',
- 'read',
- 'reconciliation',
- 'rest',
- 'security-scan',
- 'insurance',
- 'interation',
- 'safety-certificate',
- 'project',
- 'thunderbolt',
- 'block',
- 'cluster',
- 'deployment-unit',
- 'dollar',
- 'euro',
- 'pound',
- 'file-done',
- 'file-exclamation',
- 'file-protect',
- 'file-search',
- 'file-sync',
- 'gateway',
- 'gold',
- 'robot',
- 'shopping',
- ],
- },
- {
- category: 'logo',
- description: '品牌和标识图标',
- icons: [
- 'android',
- 'apple',
- 'windows',
- 'ie',
- 'chrome',
- 'github',
- 'aliwangwang',
- 'dingding',
- 'weibo-square',
- 'weibo-circle',
- 'taobao-circle',
- 'html5',
- 'weibo',
- 'twitter',
- 'wechat',
- 'youtube',
- 'alipay-circle',
- 'taobao',
- 'skype',
- 'qq',
- 'medium-workmark',
- 'gitlab',
- 'medium',
- 'linkedin',
- 'google-plus',
- 'dropbox',
- 'facebook',
- 'codepen',
- 'code-sandbox',
- 'amazon',
- 'google',
- 'codepen-circle',
- 'alipay',
- 'ant-design',
- 'aliyun',
- 'zhihu',
- 'slack',
- 'slack-square',
- 'behance',
- 'behance-square',
- 'dribbble',
- 'dribbble-square',
- 'instagram',
- 'yuque',
- 'alibaba',
- 'yahoo',
- ],
- },
-];
+export const iconData = [
+ {
+ category: 'direction',
+ description: '方向性图标',
+ icons: [
+ 'step-backward',
+ 'step-forward',
+ 'fast-backward',
+ 'fast-forward',
+ 'shrink',
+ 'arrows-alt',
+ 'down',
+ 'up',
+ 'left',
+ 'right',
+ 'caret-up',
+ 'caret-down',
+ 'caret-left',
+ 'caret-right',
+ 'up-circle',
+ 'down-circle',
+ 'left-circle',
+ 'right-circle',
+ 'double-right',
+ 'double-left',
+ 'vertical-left',
+ 'vertical-right',
+ 'forward',
+ 'backward',
+ 'rollback',
+ 'enter',
+ 'retweet',
+ 'swap',
+ 'swap-left',
+ 'swap-right',
+ 'arrow-up',
+ 'arrow-down',
+ 'arrow-left',
+ 'arrow-right',
+ 'play-circle',
+ 'up-square',
+ 'down-square',
+ 'left-square',
+ 'right-square',
+ 'login',
+ 'logout',
+ 'menu-fold',
+ 'menu-unfold',
+ 'border-bottom',
+ 'border-horizontal',
+ 'border-inner',
+ 'border-left',
+ 'border-right',
+ 'border-top',
+ 'border-verticle',
+ 'pic-center',
+ 'pic-left',
+ 'pic-right',
+ 'radius-bottomleft',
+ 'radius-bottomright',
+ 'radius-upleft',
+ 'fullscreen',
+ 'fullscreen-exit',
+ ],
+ },
+ {
+ category: 'suggestion',
+ description: '提示建议性图标',
+ icons: [
+ 'question',
+ 'question-circle',
+ 'plus',
+ 'plus-circle',
+ 'pause',
+ 'pause-circle',
+ 'minus',
+ 'minus-circle',
+ 'plus-square',
+ 'minus-square',
+ 'info',
+ 'info-circle',
+ 'exclamation',
+ 'exclamation-circle',
+ 'close',
+ 'close-circle',
+ 'close-square',
+ 'check',
+ 'check-circle',
+ 'check-square',
+ 'clock-circle',
+ 'warning',
+ 'issues-close',
+ 'stop',
+ ],
+ },
+ {
+ category: 'edit',
+ description: '编辑类图标',
+ icons: [
+ 'edit',
+ 'form',
+ 'copy',
+ 'scissor',
+ 'delete',
+ 'snippets',
+ 'diff',
+ 'highlight',
+ 'align-center',
+ 'align-left',
+ 'align-right',
+ 'bg-colors',
+ 'bold',
+ 'italic',
+ 'underline',
+ 'strikethrough',
+ 'redo',
+ 'undo',
+ 'zoom-in',
+ 'zoom-out',
+ 'font-colors',
+ 'font-size',
+ 'line-height',
+ 'colum-height',
+ 'dash',
+ 'small-dash',
+ 'sort-ascending',
+ 'sort-descending',
+ 'drag',
+ 'ordered-list',
+ 'radius-setting',
+ ],
+ },
+ {
+ category: 'data:',
+ description: '数据类图标',
+ icons: [
+ 'area-chart',
+ 'pie-chart',
+ 'bar-chart',
+ 'dot-chart',
+ 'line-chart',
+ 'radar-chart',
+ 'heat-map',
+ 'fall',
+ 'rise',
+ 'stock',
+ 'box-plot',
+ 'fund',
+ 'sliders',
+ ],
+ },
+ {
+ category: 'other',
+ description: '网站通用图标',
+ icons: [
+ 'lock',
+ 'unlock',
+ 'bars',
+ 'book',
+ 'calendar',
+ 'cloud',
+ 'cloud-download',
+ 'code',
+ 'copy',
+ 'credit-card',
+ 'delete',
+ 'desktop',
+ 'download',
+ 'ellipsis',
+ 'file',
+ 'file-text',
+ 'file-unknown',
+ 'file-pdf',
+ 'file-word',
+ 'file-excel',
+ 'file-jpg',
+ 'file-ppt',
+ 'file-markdown',
+ 'file-add',
+ 'folder',
+ 'folder-open',
+ 'folder-add',
+ 'hdd',
+ 'frown',
+ 'meh',
+ 'smile',
+ 'inbox',
+ 'laptop',
+ 'appstore',
+ 'link',
+ 'mail',
+ 'mobile',
+ 'notification',
+ 'paper-clip',
+ 'picture',
+ 'poweroff',
+ 'reload',
+ 'search',
+ 'setting',
+ 'share-alt',
+ 'shopping-cart',
+ 'tablet',
+ 'tag',
+ 'tags',
+ 'to-top',
+ 'upload',
+ 'user',
+ 'video-camera',
+ 'home',
+ 'loading',
+ 'loading-3-quarters',
+ 'cloud-upload',
+ 'star',
+ 'heart',
+ 'environment',
+ 'eye',
+ 'eye-invisible',
+ 'camera',
+ 'save',
+ 'team',
+ 'solution',
+ 'phone',
+ 'filter',
+ 'exception',
+ 'export',
+ 'customer-service',
+ 'qrcode',
+ 'scan',
+ 'like',
+ 'dislike',
+ 'message',
+ 'pay-circle',
+ 'calculator',
+ 'pushpin',
+ 'bulb',
+ 'select',
+ 'switcher',
+ 'rocket',
+ 'bell',
+ 'disconnect',
+ 'database',
+ 'compass',
+ 'barcode',
+ 'hourglass',
+ 'key',
+ 'flag',
+ 'layout',
+ 'printer',
+ 'sound',
+ 'usb',
+ 'skin',
+ 'tool',
+ 'sync',
+ 'wifi',
+ 'car',
+ 'schedule',
+ 'user-add',
+ 'user-delete',
+ 'usergroup-add',
+ 'usergroup-delete',
+ 'man',
+ 'woman',
+ 'shop',
+ 'gift',
+ 'idcard',
+ 'medicine-box',
+ 'red-envelope',
+ 'coffee',
+ 'copyright',
+ 'trademark',
+ 'safety',
+ 'wallet',
+ 'bank',
+ 'trophy',
+ 'contacts',
+ 'global',
+ 'shake',
+ 'api',
+ 'fork',
+ 'dashboard',
+ 'table',
+ 'profile',
+ 'alert',
+ 'audit',
+ 'branches',
+ 'build',
+ 'border',
+ 'crown',
+ 'experiment',
+ 'fire',
+ 'money-collect',
+ 'property-safety',
+ 'read',
+ 'reconciliation',
+ 'rest',
+ 'security-scan',
+ 'insurance',
+ 'interation',
+ 'safety-certificate',
+ 'project',
+ 'thunderbolt',
+ 'block',
+ 'cluster',
+ 'deployment-unit',
+ 'dollar',
+ 'euro',
+ 'pound',
+ 'file-done',
+ 'file-exclamation',
+ 'file-protect',
+ 'file-search',
+ 'file-sync',
+ 'gateway',
+ 'gold',
+ 'robot',
+ 'shopping',
+ ],
+ },
+ {
+ category: 'logo',
+ description: '品牌和标识图标',
+ icons: [
+ 'android',
+ 'apple',
+ 'windows',
+ 'ie',
+ 'chrome',
+ 'github',
+ 'aliwangwang',
+ 'dingding',
+ 'weibo-square',
+ 'weibo-circle',
+ 'taobao-circle',
+ 'html5',
+ 'weibo',
+ 'twitter',
+ 'wechat',
+ 'youtube',
+ 'alipay-circle',
+ 'taobao',
+ 'skype',
+ 'qq',
+ 'medium-workmark',
+ 'gitlab',
+ 'medium',
+ 'linkedin',
+ 'google-plus',
+ 'dropbox',
+ 'facebook',
+ 'codepen',
+ 'code-sandbox',
+ 'amazon',
+ 'google',
+ 'codepen-circle',
+ 'alipay',
+ 'ant-design',
+ 'aliyun',
+ 'zhihu',
+ 'slack',
+ 'slack-square',
+ 'behance',
+ 'behance-square',
+ 'dribbble',
+ 'dribbble-square',
+ 'instagram',
+ 'yuque',
+ 'alibaba',
+ 'yahoo',
+ ],
+ },
+];
diff --git a/src/pages/System/Menu/IconPreview/IconCategory.js b/src/components/IconPreview/index.js
similarity index 85%
rename from src/pages/System/Menu/IconPreview/IconCategory.js
rename to src/components/IconPreview/index.js
index a911b2f..19190ea 100644
--- a/src/pages/System/Menu/IconPreview/IconCategory.js
+++ b/src/components/IconPreview/index.js
@@ -1,16 +1,16 @@
import { connect } from 'dva';
import { Card, Col, Icon, Row, Tabs } from 'antd';
import React, { PureComponent } from 'react';
-import styles from '../../../../layouts/Sword.less';
+import styles from '../../layouts/Sword.less';
import { iconData } from './IconData';
-import { MENU_SELECT_ICON } from '../../../../actions/menu';
+import { MENU_SELECT_ICON } from '../../actions/menu';
const { TabPane } = Tabs;
@connect(({ menu }) => ({
menu,
}))
-class IconCategory extends PureComponent {
+class Index extends PureComponent {
handelClick = type => {
const { onCancel, dispatch } = this.props;
dispatch(MENU_SELECT_ICON(type.icon));
@@ -42,4 +42,4 @@ class IconCategory extends PureComponent {
);
}
}
-export default IconCategory;
+export default Index;
diff --git a/src/pages/System/Menu/MenuAdd.js b/src/pages/System/Menu/MenuAdd.js
index d692168..d166395 100644
--- a/src/pages/System/Menu/MenuAdd.js
+++ b/src/pages/System/Menu/MenuAdd.js
@@ -17,7 +17,7 @@ import Panel from '../../../components/Panel';
import styles from '../../../layouts/Sword.less';
import func from '../../../utils/Func';
import { MENU_INIT, MENU_SUBMIT, MENU_DETAIL, MENU_CLEAR_DETAIL } from '../../../actions/menu';
-import IconCategory from './IconPreview/IconCategory';
+import IconPreview from '../../../components/IconPreview';
const FormItem = Form.Item;
const { TextArea, Search } = Input;
@@ -288,7 +288,7 @@ class MenuAdd extends PureComponent {
-
+
);
diff --git a/src/pages/System/Menu/MenuEdit.js b/src/pages/System/Menu/MenuEdit.js
index 5329fe6..330d49c 100644
--- a/src/pages/System/Menu/MenuEdit.js
+++ b/src/pages/System/Menu/MenuEdit.js
@@ -17,7 +17,7 @@ import Panel from '../../../components/Panel';
import styles from '../../../layouts/Sword.less';
import { MENU_DETAIL, MENU_INIT, MENU_SUBMIT } from '../../../actions/menu';
import func from '../../../utils/Func';
-import IconCategory from './IconPreview/IconCategory';
+import IconPreview from '../../../components/IconPreview';
const FormItem = Form.Item;
const { TextArea, Search } = Input;
@@ -306,7 +306,7 @@ class MenuEdit extends PureComponent {
-
+
);