Skip to content

Commit f8d829d

Browse files
authored
chore: bump father version (#368)
* chore: bump father version * docs: fix markdown
1 parent bdc9763 commit f8d829d

File tree

8 files changed

+36
-34
lines changed

8 files changed

+36
-34
lines changed

.dumirc.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ import path from 'path';
33

44
export default defineConfig({
55
alias: {
6-
'rc-notification$': path.resolve('src'),
7-
'rc-notification/es': path.resolve('src'),
6+
'@rc-component/notification$': path.resolve('src'),
7+
'@rc-component/notification/es': path.resolve('src'),
88
},
99
favicons: ['https://avatars0.githubusercontent.com/u/9441414?s=200&v=4'],
1010
themeConfig: {

README.md

+18-15
Original file line numberDiff line numberDiff line change
@@ -1,41 +1,44 @@
1-
# rc-notification
1+
# @rc-component/notification
22

33
React Notification UI Component
44

55
[![NPM version][npm-image]][npm-url] [![dumi](https://img.shields.io/badge/docs%20by-dumi-blue?style=flat-square)](https://github.com/umijs/dumi) [![build status][github-actions-image]][github-actions-url] [![Test coverage][coveralls-image]][coveralls-url] [![npm download][download-image]][download-url] [![bundle size][bundlephobia-image]][bundlephobia-url]
66

7-
[npm-image]: http://img.shields.io/npm/v/rc-notification.svg?style=flat-square
8-
[npm-url]: http://npmjs.org/package/rc-notification
7+
[npm-image]: http://img.shields.io/npm/v/@rc-component/notification.svg?style=flat-square
8+
[npm-url]: http://npmjs.org/package/@rc-component/notification
99
[github-actions-image]: https://github.com/react-component/notification/workflows/CI/badge.svg
1010
[github-actions-url]: https://github.com/react-component/notification/actions
1111
[coveralls-image]: https://img.shields.io/coveralls/react-component/notification.svg?style=flat-square
1212
[coveralls-url]: https://coveralls.io/r/react-component/notification?branch=master
13-
[download-image]: https://img.shields.io/npm/dm/rc-notification.svg?style=flat-square
14-
[download-url]: https://npmjs.org/package/rc-notification
15-
[bundlephobia-url]: https://bundlephobia.com/result?p=rc-notification
16-
[bundlephobia-image]: https://badgen.net/bundlephobia/minzip/rc-notification
13+
[download-image]: https://img.shields.io/npm/dm/@rc-component/notification.svg?style=flat-square
14+
[download-url]: https://npmjs.org/package/@rc-component/notification
15+
[bundlephobia-url]: https://bundlephobia.com/result?p=@rc-component/notification
16+
[bundlephobia-image]: https://badgen.net/bundlephobia/minzip/@rc-component/notification
1717

1818
## Install
1919

20-
[![rc-notification](https://nodei.co/npm/rc-notification.png)](https://npmjs.org/package/rc-notification)
20+
[![@rc-component/notification](https://nodei.co/npm/@rc-component/notification.png)](https://npmjs.org/package/@rc-component/notification)
2121

2222
## Usage
2323

2424
```js
25-
import Notification from 'rc-notification';
25+
import Notification from '@rc-component/notification';
2626

27-
Notification.newInstance({}, notification => {
27+
Notification.newInstance({}, (notification) => {
2828
notification.notice({
29-
content: 'content'
29+
content: 'content',
3030
});
3131
});
3232
```
3333

3434
## Compatibility
3535

36-
| [<img src="https://raw.githubusercontent.com/alrra/browser-logos/master/src/edge/edge_48x48.png" alt="IE / Edge" width="24px" height="24px" />](http://godban.github.io/browsers-support-badges/)<br>IE / Edge | [<img src="https://raw.githubusercontent.com/alrra/browser-logos/master/src/firefox/firefox_48x48.png" alt="Firefox" width="24px" height="24px" />](http://godban.github.io/browsers-support-badges/)<br>Firefox | [<img src="https://raw.githubusercontent.com/alrra/browser-logos/master/src/chrome/chrome_48x48.png" alt="Chrome" width="24px" height="24px" />](http://godban.github.io/browsers-support-badges/)<br>Chrome | [<img src="https://raw.githubusercontent.com/alrra/browser-logos/master/src/safari/safari_48x48.png" alt="Safari" width="24px" height="24px" />](http://godban.github.io/browsers-support-badges/)<br>Safari | [<img src="https://raw.githubusercontent.com/alrra/browser-logos/master/src/electron/electron_48x48.png" alt="Electron" width="24px" height="24px" />](http://godban.github.io/browsers-support-badges/)<br>Electron |
37-
| --- | --- | --- | --- | --- |
38-
| IE11, Edge | last 2 versions | last 2 versions | last 2 versions | last 2 versions |
36+
| Browser | Supported Version |
37+
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------- |
38+
| [![Firefox](https://raw.githubusercontent.com/alrra/browser-logos/master/src/firefox/firefox_48x48.png)<br>Firefox](http://godban.github.io/browsers-support-badges/) | last 2 versions |
39+
| [![Chrome](https://raw.githubusercontent.com/alrra/browser-logos/master/src/chrome/chrome_48x48.png)<br>Chrome](http://godban.github.io/browsers-support-badges/) | last 2 versions |
40+
| [![Safari](https://raw.githubusercontent.com/alrra/browser-logos/master/src/safari/safari_48x48.png)<br>Safari](http://godban.github.io/browsers-support-badges/) | last 2 versions |
41+
| [![Electron](https://raw.githubusercontent.com/alrra/browser-logos/master/src/electron/electron_48x48.png)<br>Electron](http://godban.github.io/browsers-support-badges/) | last 2 versions |
3942

4043
## Example
4144

@@ -188,4 +191,4 @@ open coverage/ dir
188191

189192
## License
190193

191-
rc-notification is released under the MIT license.
194+
@rc-component/notification is released under the MIT license.

docs/examples/motion.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import type { CSSMotionProps } from 'rc-motion';
1+
import type { CSSMotionProps } from '@rc-component/motion';
22

33
const motion: CSSMotionProps = {
44
motionName: 'rc-notification-fade',

package.json

+8-9
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
2-
"name": "rc-notification",
3-
"version": "5.6.3",
2+
"name": "@rc-component/notification",
3+
"version": "1.0.0",
44
"description": "notification ui component for react",
55
"engines": {
66
"node": ">=8.x"
@@ -39,7 +39,7 @@
3939
"build": "dumi build",
4040
"docs:deploy": "gh-pages -d .doc",
4141
"compile": "father build && lessc assets/index.less assets/index.css",
42-
"prepublishOnly": "npm run compile && np --yolo --no-publish",
42+
"prepublishOnly": "npm run compile && rc-np",
4343
"lint": "eslint src/ docs/examples/ --ext .tsx,.ts,.jsx,.js",
4444
"test": "vitest --watch=false",
4545
"test:watch": "vitest",
@@ -52,7 +52,7 @@
5252
"react-dom": ">=16.9.0"
5353
},
5454
"devDependencies": {
55-
"@rc-component/father-plugin": "^1.0.2",
55+
"@rc-component/father-plugin": "^2.0.4",
5656
"@testing-library/jest-dom": "^6.0.0",
5757
"@testing-library/react": "^15.0.7",
5858
"@types/classnames": "^2.2.10",
@@ -70,18 +70,17 @@
7070
"jsdom": "^24.0.0",
7171
"less": "^4.2.0",
7272
"lint-staged": "^14.0.1",
73-
"np": "^10.0.5",
7473
"prettier": "^3.0.2",
7574
"react": "^18.0.0",
7675
"react-dom": "^18.0.0",
7776
"typescript": "^5.4.5",
7877
"vitest": "^0.34.2"
7978
},
8079
"dependencies": {
81-
"@babel/runtime": "^7.10.1",
82-
"classnames": "2.x",
83-
"rc-motion": "^2.9.0",
84-
"rc-util": "^5.20.1"
80+
"@rc-component/motion": "^1.1.4",
81+
"@rc-component/np": "^1.0.3",
82+
"@rc-component/util": "^1.2.1",
83+
"classnames": "2.x"
8584
},
8685
"lint-staged": {
8786
"**/*.{js,jsx,tsx,ts,md,json}": [

src/Notice.tsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
import classNames from 'classnames';
2-
import KeyCode from 'rc-util/lib/KeyCode';
2+
import KeyCode from '@rc-component/util/lib/KeyCode';
33
import * as React from 'react';
44
import type { NoticeConfig } from './interface';
5-
import pickAttrs from 'rc-util/lib/pickAttrs';
5+
import pickAttrs from '@rc-component/util/lib/pickAttrs';
66

77
export interface NoticeProps extends Omit<NoticeConfig, 'onClose'> {
88
prefixCls: string;

src/NoticeList.tsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
import type { CSSProperties, FC } from 'react';
22
import React, { useContext, useEffect, useRef, useState } from 'react';
33
import clsx from 'classnames';
4-
import type { CSSMotionProps } from 'rc-motion';
5-
import { CSSMotionList } from 'rc-motion';
4+
import type { CSSMotionProps } from '@rc-component/motion';
5+
import { CSSMotionList } from '@rc-component/motion';
66
import type {
77
InnerOpenConfig,
88
NoticeConfig,

src/Notifications.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import * as React from 'react';
22
import type { ReactElement } from 'react';
33
import { createPortal } from 'react-dom';
4-
import type { CSSMotionProps } from 'rc-motion';
4+
import type { CSSMotionProps } from '@rc-component/motion';
55
import type { InnerOpenConfig, OpenConfig, Placement, Placements, StackConfig } from './interface';
66
import NoticeList from './NoticeList';
77

src/hooks/useNotification.tsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
import type { CSSMotionProps } from 'rc-motion';
1+
import type { CSSMotionProps } from '@rc-component/motion';
22
import * as React from 'react';
33
import type { NotificationsProps, NotificationsRef } from '../Notifications';
44
import Notifications from '../Notifications';
55
import type { OpenConfig, Placement, StackConfig } from '../interface';
6-
import { useEvent } from 'rc-util';
6+
import { useEvent } from '@rc-component/util';
77

88
const defaultGetContainer = () => document.body;
99

0 commit comments

Comments
 (0)