mirror of
https://github.com/MrXujiang/h5-Dooring.git
synced 2026-03-26 07:13:06 +00:00
change
This commit is contained in:
parent
68cdc5d5b7
commit
6e083ee824
@ -1,6 +1,6 @@
|
|||||||
import { memo } from 'react';
|
import { memo } from 'react';
|
||||||
import * as Icon from '@ant-design/icons';
|
import * as Icon from '@ant-design/icons';
|
||||||
import IconImg from 'assets/icon.png';
|
//import IconImg from 'assets/icon.png';
|
||||||
|
|
||||||
const XIcon = memo(props => {
|
const XIcon = memo(props => {
|
||||||
const { color, size, type, spin, isTpl } = props;
|
const { color, size, type, spin, isTpl } = props;
|
||||||
@ -8,10 +8,7 @@ const XIcon = memo(props => {
|
|||||||
const MyIcon = Icon[type];
|
const MyIcon = Icon[type];
|
||||||
|
|
||||||
return isTpl ? (
|
return isTpl ? (
|
||||||
<div style={{ textAlign: 'center' }}>
|
<div style={{ textAlign: 'center' }}>图标</div>
|
||||||
<img style={{ verticalAlign: '-20px', width: '82px' }} src={IconImg} alt={type} />
|
|
||||||
图标
|
|
||||||
</div>
|
|
||||||
) : (
|
) : (
|
||||||
<MyIcon twoToneColor={color} style={{ fontSize: size }} spin={spin} />
|
<MyIcon twoToneColor={color} style={{ fontSize: size }} spin={spin} />
|
||||||
);
|
);
|
||||||
|
|||||||
3
src/typings.d.ts
vendored
Normal file
3
src/typings.d.ts
vendored
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
declare module '*.css';
|
||||||
|
declare module '*.png';
|
||||||
|
declare module '*.less';
|
||||||
@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"compilerOptions": {
|
"compilerOptions": {
|
||||||
"target": "es6",
|
"target": "es6",
|
||||||
"module": "es6",
|
"module": "ESNext",
|
||||||
"moduleResolution": "node",
|
"moduleResolution": "node",
|
||||||
"jsx": "react",
|
"jsx": "react",
|
||||||
"baseUrl": ".",
|
"baseUrl": ".",
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user