Skip to content

Commit

Permalink
添加图片控制属性
Browse files Browse the repository at this point in the history
  • Loading branch information
lgf196 committed Mar 15, 2022
1 parent 24cddde commit bd3d27f
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 2 deletions.
19 changes: 18 additions & 1 deletion src/core/componentTemplate/picture/Image/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,23 @@ export const ImageConfig = (
width: w,
height: h,
},
editableEl: [],
editableEl: [
{
type: 'BorderRadius',
name: '圆角',
title: '高级样式',
key: 'borderRadius',
},
{
type: 'BoxShadow',
name: '阴影',
key: 'boxShadow',
},
{
type: 'Slider',
name: '透明度',
key: 'opacity',
},
],
};
};
2 changes: 1 addition & 1 deletion src/core/componentTemplate/picture/Image/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const Index: FC<templateDataType> = memo(function Index(props) {
src={props.icon}
alt=""
// pointerEvents: 'none' 阻止默认行为
style={{ width: '100%', height: '100%', pointerEvents: 'none' }}
style={{ width: '100%', height: '100%', pointerEvents: 'none', ...resultStyle }}
onClick={(e) => e.preventDefault()}
/>
</div>
Expand Down

0 comments on commit bd3d27f

Please sign in to comment.