Skip to content
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
5 changes: 3 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,16 @@ es
coverage
yarn.lock
package-lock.json
pnpm-lock.yaml

# umi
.umi
.umi-production
.umi-test
.env.local
.env.local

# dumi
.dumi/tmp
.dumi/tmp-production

bun.lockb
bun.lockb
16 changes: 8 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,26 +47,22 @@
"now-build": "npm run build",
"prepare": "husky install"
},
"peerDependencies": {
"react": ">=16.9.0",
"react-dom": ">=16.9.0"
},
"dependencies": {
"@rc-component/motion": "^1.1.4",
"@rc-component/util": "^1.2.1",
"classnames": "2.x"
"clsx": "^2.1.1"
},
"devDependencies": {
"@typescript-eslint/eslint-plugin": "^5.59.7",
"@typescript-eslint/parser": "^5.59.7",
"@rc-component/father-plugin": "^2.0.4",
"@rc-component/np": "^1.0.3",
"@testing-library/jest-dom": "^6.0.0",
"@testing-library/react": "^15.0.7",
"@types/classnames": "^2.2.10",
"@types/node": "^24.5.2",
"@types/react": "^18.0.0",
"@types/react-dom": "^18.0.0",
"@types/testing-library__jest-dom": "^6.0.0",
"@typescript-eslint/eslint-plugin": "^5.59.7",
"@typescript-eslint/parser": "^5.59.7",
"@umijs/fabric": "^2.0.0",
"@vitest/coverage-v8": "^0.34.2",
"cross-env": "^7.0.0",
Expand All @@ -84,6 +80,10 @@
"typescript": "^5.4.5",
"vitest": "^0.34.2"
},
"peerDependencies": {
"react": ">=16.9.0",
"react-dom": ">=16.9.0"
},
"lint-staged": {
"**/*.{js,jsx,tsx,ts,md,json}": [
"prettier --write",
Expand Down
6 changes: 2 additions & 4 deletions src/Notice.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import classNames from 'classnames';
import { clsx } from 'clsx';
import KeyCode from '@rc-component/util/lib/KeyCode';
import * as React from 'react';
import type { NoticeConfig } from './interface';
Expand Down Expand Up @@ -120,9 +120,7 @@ const Notify = React.forwardRef<HTMLDivElement, NoticeProps & { times?: number }
<div
{...divProps}
ref={ref}
className={classNames(noticePrefixCls, className, {
[`${noticePrefixCls}-closable`]: closable,
})}
className={clsx(noticePrefixCls, className, { [`${noticePrefixCls}-closable`]: closable })}
style={style}
onMouseEnter={(e) => {
setHovering(true);
Expand Down
2 changes: 1 addition & 1 deletion src/NoticeList.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import type { CSSProperties, FC } from 'react';
import React, { useContext, useEffect, useRef, useState } from 'react';
import clsx from 'classnames';
import { clsx } from 'clsx';
import type { CSSMotionProps } from '@rc-component/motion';
import { CSSMotionList } from '@rc-component/motion';
import type {
Expand Down