Browse Source

use rc-notification@3.2.0, use svg close icon in Notification component.

pull/11322/head
HeskeyBaozi 6 years ago
parent
commit
34e658d70b
  1. 1
      components/notification/index.tsx
  2. 12
      components/notification/style/index.less
  3. 2
      package.json

1
components/notification/index.tsx

@ -85,6 +85,7 @@ function getNotificationInstance(prefixCls: string, placement: NotificationPlace
className: `${prefixCls}-${placement}`,
style: getPlacementStyle(placement),
getContainer: defaultGetContainer,
closeIcon: <Icon className={`${prefixCls}-close-icon`} type={'close'}/>,
}, (notification: any) => {
notificationInstance[cacheKey] = notification;
callback(notification);

12
components/notification/style/index.less

@ -28,6 +28,11 @@
}
}
&-close-icon {
font-size: @font-size-base;
cursor: pointer;
}
&-notice {
padding: @notification-padding;
border-radius: @border-radius-base;
@ -99,13 +104,6 @@
}
}
&-close-x:after {
font-size: @font-size-base;
content: "\e633";
font-family: "anticon";
cursor: pointer;
}
&-close {
position: absolute;
right: 22px;

2
package.json

@ -67,7 +67,7 @@
"rc-form": "^2.1.0",
"rc-input-number": "~4.0.0",
"rc-menu": "~7.0.2",
"rc-notification": "~3.1.1",
"rc-notification": "~3.2.0",
"rc-pagination": "~1.16.1",
"rc-progress": "~2.2.2",
"rc-rate": "~2.4.0",

Loading…
Cancel
Save