8000 chore: bump father version by zombieJ · Pull Request #368 · react-component/notification · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

chore: bump father version #368

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 21, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .dumirc.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ import path from 'path';

export default defineConfig({
alias: {
'rc-notification$': path.resolve('src'),
'rc-notification/es': path.resolve('src'),
'@rc-component/notification$': path.resolve('src'),
'@rc-component/notification/es': path.resolve('src'),
},
favicons: ['https://avatars0.githubusercontent.com/u/9441414?s=200&v=4'],
themeConfig: {
Expand Down
33 changes: 18 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,41 +1,44 @@
# rc-notification
# @rc-component/notification

React Notification UI Component

[![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]

[npm-image]: http://img.shields.io/npm/v/rc-notification.svg?style=flat-square
[npm-url]: http://npmjs.org/package/rc-notification
[npm-image]: http://img.shields.io/npm/v/@rc-component/notification.svg?style=flat-square
[npm-url]: http://npmjs.org/package/@rc-component/notification
[github-actions-image]: https://github.com/react-component/notification/workflows/CI/badge.svg
[github-actions-url]: https://github.com/react-component/notification/actions
[coveralls-image]: https://img.shields.io/coveralls/react-component/notification.svg?style=flat-square
[coveralls-url]: https://coveralls.io/r/react-component/notification?branch=master
[download-image]: https://img.shields.io/npm/dm/rc-notification.svg?style=flat-square
[download-url]: https://npmjs.org/package/rc-notification
[bundlephobia-url]: https://bundlephobia.com/result?p=rc-notification
[bundlephobia-image]: https://badgen.net/bundlephobia/minzip/rc-notification
[download-image]: https://img.shields.io/npm/dm/@rc-component/notification.svg?style=flat-square
[download-url]: https://npmjs.org/package/@rc-component/notification
[bundlephobia-url]: https://bundlephobia.com/result?p=@rc-component/notification
[bundlephobia-image]: https://badgen.net/bundlephobia/minzip/@rc-component/notification

## Install

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

## Usage

```js
import Notification from 'rc-notification';
import Notification from '@rc-component/notification';

Notification.newInstance({}, notification => {
Notification.newInstance({}, (notification) => {
notification.notice({
content: 'content'
content: 'content',
});
});
```

## Compatibility

| [<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 |
| --- | --- | --- | --- | --- |
| IE11, Edge | last 2 versions | last 2 versions | last 2 versions | last 2 versions |
| Browser | Supported Version |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------- |
| [![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 |
| [![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 |
| [![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 |
| [![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 |

## Example

Expand Down Expand Up @@ -188,4 +191,4 @@ open coverage/ dir

## License

rc-notification is released under the MIT license.
@rc-component/notification is released under the MIT license.
2 changes: 1 addition & 1 deletion docs/examples/motion.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { CSSMotionProps } from 'rc-motion';
import type { CSSMotionProps } from '@rc-component/motion';

const motion: CSSMotionProps = {
motionName: 'rc-notification-fade',
Expand Down
17 changes: 8 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "rc-notification",
"version": "5.6.3",
"name": "@rc-component/notification",
"version": "1.0.0",
"description": "notification ui component for react",
"engines": {
"node": ">=8.x"
Expand Down Expand Up @@ -39,7 +39,7 @@
"build": "dumi build",
"docs:deploy": "gh-pages -d .doc",
"compile": "father build && lessc assets/index.less assets/index.css",
"prepublishOnly": "npm run compile && np --yolo --no-publish",
"prepublishOnly": "npm run compile && rc-np",
"lint": "eslint src/ docs/examples/ --ext .tsx,.ts,.jsx,.js",
"test": "vitest --watch=false",
"test:watch": "vitest",
Expand All @@ -52,7 +52,7 @@
"react-dom": ">=16.9.0"
},
"devDependencies": {
"@rc-component/father-plugin": "^1.0.2",
"@rc-component/father-plugin": "^2.0.4",
"@testing-library/jest-dom": "^6.0.0",
"@testing-library/react": "^15.0.7",
"@types/classnames": "^2.2.10",
Expand All @@ -70,18 +70,17 @@
"jsdom": "^24.0.0",
"less": "^4.2.0",
"lint-staged": "^14.0.1",
"np": "^10.0.5",
"prettier": "^3.0.2",
"react": "^18.0.0",
"react-dom": "^18.0.0",
"typescript": "^5.4.5",
"vitest": "^0.34.2"
},
"dependencies": {
"@babel/runtime": "^7.10.1",
"classnames": "2.x",
"rc-motion": "^2.9.0",
"rc-util": "^5.20.1"
"@rc-component/motion": "^1.1.4",
"@rc-component/np": "^1.0.3",
"@rc-component/util": "^1.2.1",
"classnames": "2.x"
},
"lint-staged": {
"**/*.{js,jsx,tsx,ts,md,json}": [
Expand Down
4 changes: 2 additions & 2 deletions src/Notice.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import classNames from 'classnames';
import KeyCode from 'rc-util/lib/KeyCode';
import KeyCode from '@rc-component/util/lib/KeyCode';
import * as React from 'react';
import type { NoticeConfig } from './interface';
import pickAttrs from 'rc-util/lib/pickAttrs';
import pickAttrs from '@rc-component/util/lib/pickAttrs';

export interface NoticeProps extends Omit<NoticeConfig, 'onClose'> {
prefixCls: string;
Expand Down
4 changes: 2 additions & 2 deletions src/NoticeList.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import type { CSSProperties, FC } from 'react';
import React, { useContext, useEffect, useRef, useState } from 'react';
import clsx from 'classnames';
import type { CSSMotionProps } from 'rc-motion';
import { CSSMotionList } from 'rc-motion';
import type { CSSMotionProps } from '@rc-component/motion';
import { CSSMotionList } from '@rc-component/motion';
import type {
InnerOpenConfig,
NoticeConfig,
Expand Down
2 changes: 1 addition & 1 deletion src/Notifications.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import * as React from 'react';
import type { ReactElement } from 'react';
import { createPortal } from 'react-dom';
import type { CSSMotionProps } from 'rc-motion';
import type { CSSMotionProps } from '@rc-component/motion';
import type { InnerOpenConfig, OpenConfig, Placement, Placements, StackConfig } from './interface';
import NoticeList from './NoticeList';

Expand Down
4 changes: 2 additions & 2 deletions src/hooks/useNotification.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import type { CSSMotionProps } from 'rc-motion';
import type { CSSMotionProps } from '@rc-component/motion';
import * as React from 'react';
import type { NotificationsProps, NotificationsRef } from '../Notifications';
import Notifications from '../Notifications';
import type { OpenConfig, Placement, StackConfig } from '../interface';
import { useEvent } from 'rc-util';
import { useEvent } from '@rc-component/util';

const defaultGetContainer = () => document.body;

Expand Down
0