Yansen 5 лет назад
Родитель
Сommit
cd7c0778f6
2 измененных файлов: 4 добавлений и 3 удалений
  1. 2
    1
      src/components/ActionList/index.jsx
  2. 2
    2
      src/components/EditIcon/index.jsx

+ 2
- 1
src/components/ActionList/index.jsx Просмотреть файл

11
 
11
 
12
     const menus = (
12
     const menus = (
13
       <Menu className="actlist-menu">
13
       <Menu className="actlist-menu">
14
-        {(leftActs || []).concat(Act2).filter(Boolean).map((Act, index) => (<Menu.Item key={`dm-${index}`}>{Act}</Menu.Item>))}
14
+        {[Act2].concat(leftActs).filter(Boolean).map((Act, index) => (<Menu.Item key={`dm-${index}`}>{Act}</Menu.Item>))}
15
       </Menu>
15
       </Menu>
16
     );
16
     );
17
+    console.log('---------->', record, menus)
17
 
18
 
18
     return (
19
     return (
19
       <div className="action-list">
20
       <div className="action-list">

+ 2
- 2
src/components/EditIcon/index.jsx Просмотреть файл

89
     const color2 = color || icon.color || '#ff925c';
89
     const color2 = color || icon.color || '#ff925c';
90
     const position2 = position || icon.pos;
90
     const position2 = position || icon.pos;
91
 
91
 
92
-    const wrappedStyle = useMemo(() => ({ color: `${color2}`, display: 'flex', alignItems: 'center', cursor: 'pointer' }), [color]);
93
-    const iconStyle = useMemo(() => ({ display: 'inline-block', marginLeft: '6px', background: `url(${spriteImg}) 0 ${position2}px / 100% 1300% no-repeat`, width: '18px', height: '18px' }), [position])
92
+    const wrappedStyle = useMemo(() => ({ color: `${color2}`, display: 'flex', alignItems: 'center', cursor: 'pointer' }), [type, color]);
93
+    const iconStyle = useMemo(() => ({ display: 'inline-block', marginLeft: '6px', background: `url(${spriteImg}) 0 ${position2}px / 100% 1300% no-repeat`, width: '18px', height: '18px' }), [type, position])
94
 
94
 
95
     return (
95
     return (
96
         <span style={wrappedStyle} onClick={onClick || noop} >
96
         <span style={wrappedStyle} onClick={onClick || noop} >