mirror of
https://github.com/ragestudio/comty.git
synced 2025-06-09 10:34:17 +00:00
0.1.10
This commit is contained in:
parent
ab57216f8b
commit
5f27d3999a
@ -6,6 +6,8 @@
|
|||||||
"author": "",
|
"author": "",
|
||||||
"license": "ISC",
|
"license": "ISC",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
"@ant-design/compatible": "0.0.1-rc.1",
|
||||||
|
"@ant-design/icons": "^2.1.1",
|
||||||
"@ant-design/pro-layout": "^4.9.11",
|
"@ant-design/pro-layout": "^4.9.11",
|
||||||
"@lingui/react": "^2.9.0",
|
"@lingui/react": "^2.9.0",
|
||||||
"ant-design-pro": "^2.3.2",
|
"ant-design-pro": "^2.3.2",
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import React from 'react'
|
import React from 'react'
|
||||||
import PropTypes from 'prop-types'
|
import PropTypes from 'prop-types'
|
||||||
import { Icon as LegacyIcon } from '@ant-design/compatible';
|
import * as icon from '@ant-design/icons';
|
||||||
import { Dropdown, Button, Menu } from 'antd';
|
import { Dropdown, Button, Menu } from 'antd';
|
||||||
|
|
||||||
const DropOption = ({
|
const DropOption = ({
|
||||||
@ -18,8 +18,8 @@ const DropOption = ({
|
|||||||
} {...dropdownProps}>
|
} {...dropdownProps}>
|
||||||
|
|
||||||
<Button style={{ border: 'none', ...buttonStyle }}>
|
<Button style={{ border: 'none', ...buttonStyle }}>
|
||||||
<LegacyIcon style={{ marginRight: 2 }} type="bars" />
|
<icon.BarsOutline style={{ marginRight: 2 }} />
|
||||||
<LegacyIcon type="down" />
|
<icon.DownOutline />
|
||||||
</Button>
|
</Button>
|
||||||
</Dropdown>
|
</Dropdown>
|
||||||
);
|
);
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import React, { PureComponent, Fragment } from 'react'
|
import React, { PureComponent, Fragment } from 'react'
|
||||||
import { Icon as LegacyIcon } from '@ant-design/compatible';
|
import * as icon from '@ant-design/icons';
|
||||||
import {
|
import {
|
||||||
Menu,
|
Menu,
|
||||||
Layout,
|
Layout,
|
||||||
@ -44,7 +44,7 @@ class Header extends PureComponent {
|
|||||||
handleOpenMenu() {
|
handleOpenMenu() {
|
||||||
let ListControls = [
|
let ListControls = [
|
||||||
(<div>
|
(<div>
|
||||||
<Button type="dashed" icon={<LegacyIcon type="close" />} shape="circle" onClick={() => ycore.ControlBar.close()}></Button>
|
<Button type="dashed" icon={<icon.CloseOutline />} shape="circle" onClick={() => ycore.ControlBar.close()}></Button>
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
]
|
]
|
||||||
@ -90,10 +90,7 @@ class Header extends PureComponent {
|
|||||||
}
|
}
|
||||||
description={moment(item.date).fromNow()}
|
description={moment(item.date).fromNow()}
|
||||||
/>
|
/>
|
||||||
<LegacyIcon
|
<icon.RightOutlined />
|
||||||
style={{ fontSize: '15px', color: '#ccc' }}
|
|
||||||
type="right"
|
|
||||||
/>
|
|
||||||
</List.Item>
|
</List.Item>
|
||||||
)}
|
)}
|
||||||
/>
|
/>
|
||||||
@ -114,7 +111,7 @@ class Header extends PureComponent {
|
|||||||
offset={[-10, 10]}
|
offset={[-10, 10]}
|
||||||
className={styles.iconButton}
|
className={styles.iconButton}
|
||||||
>
|
>
|
||||||
<LegacyIcon className={styles.iconFont} type="bell" />
|
<icon.BellOutlined />
|
||||||
</Badge>
|
</Badge>
|
||||||
</Popover>
|
</Popover>
|
||||||
)
|
)
|
||||||
@ -123,11 +120,11 @@ class Header extends PureComponent {
|
|||||||
<Layout.Header id='layoutHeader' className={classnames(styles.header, {[styles.fixed]: fixed})} >
|
<Layout.Header id='layoutHeader' className={classnames(styles.header, {[styles.fixed]: fixed})} >
|
||||||
<div className={styles.leftContainer}>
|
<div className={styles.leftContainer}>
|
||||||
<img className={styles.brand} src={config.FullLogoPath} />
|
<img className={styles.brand} src={config.FullLogoPath} />
|
||||||
<Tooltip title={'Main'}><a target="_blank" href="" rel="noopener noreferrer"><LegacyIcon type="home" className={styles.iconButton} style={{ fontSize: '15px' }} /></a></Tooltip>
|
<Tooltip title={'Main'}><a target="_blank" href="" rel="noopener noreferrer"><icon.HomeOutline className={styles.iconButton} style={{ fontSize: '15px' }} /></a></Tooltip>
|
||||||
<Tooltip title={'Search'}><a target="_blank" href="" rel="noopener noreferrer"><LegacyIcon type="search" className={styles.iconButton} style={{ fontSize: '15px' }} /></a></Tooltip>
|
<Tooltip title={'Search'}><a target="_blank" href="" rel="noopener noreferrer"><icon.SearchOutline className={styles.iconButton} style={{ fontSize: '15px' }} /></a></Tooltip>
|
||||||
</div>
|
</div>
|
||||||
<div className={styles.rightContainer}>
|
<div className={styles.rightContainer}>
|
||||||
<Tooltip title={'Create'}><LegacyIcon type="plus" onClick={() => this.handleOpenMenu()} className={styles.iconButton} style={{ fontSize: '15px' }} /></Tooltip>
|
<Tooltip title={'Create'}><icon.PlusCircleOutline onClick={() => this.handleOpenMenu()} className={styles.iconButton} style={{ fontSize: '15px' }} /></Tooltip>
|
||||||
{notificationIcon}
|
{notificationIcon}
|
||||||
</div>
|
</div>
|
||||||
</Layout.Header>
|
</Layout.Header>
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import React, { PureComponent, Fragment } from 'react'
|
import React, { PureComponent, Fragment } from 'react'
|
||||||
import PropTypes from 'prop-types'
|
import PropTypes from 'prop-types'
|
||||||
import { Icon as LegacyIcon } from '@ant-design/compatible';
|
import * as icon from '@ant-design/icons';
|
||||||
import { Menu } from 'antd';
|
import { Menu } from 'antd';
|
||||||
import Navlink from 'umi/navlink'
|
import Navlink from 'umi/navlink'
|
||||||
import withRouter from 'umi/withRouter'
|
import withRouter from 'umi/withRouter'
|
||||||
@ -13,6 +13,7 @@ import {
|
|||||||
} from 'utils'
|
} from 'utils'
|
||||||
import store from 'store'
|
import store from 'store'
|
||||||
import styles from './Menu.less'
|
import styles from './Menu.less'
|
||||||
|
import { isTypeNode } from 'typescript';
|
||||||
|
|
||||||
|
|
||||||
const { SubMenu } = Menu
|
const { SubMenu } = Menu
|
||||||
@ -52,7 +53,7 @@ class SiderMenu extends PureComponent {
|
|||||||
className={styles.SubMenuItems}
|
className={styles.SubMenuItems}
|
||||||
title={
|
title={
|
||||||
<Fragment>
|
<Fragment>
|
||||||
{item.icon && <LegacyIcon type={item.icon} />}
|
{item.icon && <item.icon />}
|
||||||
<span className={styles.SubItemTitle}>{item.name}</span>
|
<span className={styles.SubItemTitle}>{item.name}</span>
|
||||||
</Fragment>
|
</Fragment>
|
||||||
}
|
}
|
||||||
@ -64,7 +65,7 @@ class SiderMenu extends PureComponent {
|
|||||||
return (
|
return (
|
||||||
<Menu.Item key={item.id} >
|
<Menu.Item key={item.id} >
|
||||||
<Navlink to={addLangPrefix(item.route) || '#'}>
|
<Navlink to={addLangPrefix(item.route) || '#'}>
|
||||||
{item.icon && <LegacyIcon type={item.icon} />}
|
{item.icon && <item.icon />}
|
||||||
<span>{item.name}</span>
|
<span>{item.name}</span>
|
||||||
</Navlink>
|
</Navlink>
|
||||||
</Menu.Item>
|
</Menu.Item>
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
import React, { PureComponent, StrictMode } from 'react'
|
import React, { PureComponent, StrictMode } from 'react'
|
||||||
import PropTypes from 'prop-types'
|
import PropTypes from 'prop-types'
|
||||||
import { Icon as LegacyIcon } from '@ant-design/compatible';
|
import { Icons as LegacyIcon } from '@ant-design/compatible';
|
||||||
|
import * as icon from '@ant-design/icons';
|
||||||
import { Switch, Layout, Tag, Divider, Drawer, Avatar, Menu } from 'antd';
|
import { Switch, Layout, Tag, Divider, Drawer, Avatar, Menu } from 'antd';
|
||||||
import { withI18n, Trans } from '@lingui/react'
|
import { withI18n, Trans } from '@lingui/react'
|
||||||
import classNames from 'classnames'
|
import classNames from 'classnames'
|
||||||
|
Loading…
x
Reference in New Issue
Block a user