Skip to content
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

chore: update deps #12151

Merged
merged 2 commits into from
Mar 5, 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
2 changes: 1 addition & 1 deletion .github/workflows/linters.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ jobs:
with:
ref: ${{ github.event.pull_request.head.ref }}
- uses: actions/setup-node@v4
- run: npx prettier@3.4.1 --write .
- run: npx prettier@3.5.3 --write .
- uses: EndBug/add-and-commit@v9
with:
message: 'fix: prettier'
Expand Down
5 changes: 4 additions & 1 deletion eslint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ const avoidMistakeRules = {
'valid-typeof': 'error', // typeof expr === undefined
'unicorn/no-invalid-remove-event-listener': 'error', // removeEventListener('click', f.bind(...))
'unicorn/no-negation-in-equality-check': 'error', // !foo === bar
'react/dom/no-children-in-void-dom-elements': 'warn', // <img>children</img>
'react/dom/no-void-elements-with-children': 'warn', // <img>children</img>
'react/web-api/no-leaked-event-listener': 'warn', // addEventListener in hooks without removeEventListener
'react/web-api/no-leaked-interval': 'warn', // setInterval in hooks without clearInterval
'react/web-api/no-leaked-resize-observer': 'warn', // new ResizeObserver in hooks without disconnect
Expand Down Expand Up @@ -246,6 +246,8 @@ const codeStyleRules = {
'no-var': 'error', // var x
'unicorn/no-new-buffer': 'error', // NodeJS
'react/no-class-component': 'error',
'react/no-context-provider': 'error',
'react/no-forward-ref': 'error',
// Let's wait for https://github.com/typescript-eslint/typescript-eslint/issues/6572
// '@typescript-eslint/no-namespace': 'error', // namespace T {}
'@typescript-eslint/prefer-namespace-keyword': 'error', // but if you really need to, don't use `module T {}`
Expand All @@ -264,6 +266,7 @@ const codeStyleRules = {
'no-useless-concat': 'warn', // "a" + "b"
'no-useless-escape': 'warn', // "hol\a"
// 'no-lone-blocks': 'warn', // no block that not introducing a new scope
'react/no-missing-context-display-name': 'warn',
'react/no-useless-fragment': 'warn',
'unicorn/no-console-spaces': 'warn', // console.log('id: ', id)
'unicorn/no-empty-file': 'warn',
Expand Down
49 changes: 24 additions & 25 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
"packageManager": "pnpm@9.12.1",
"engines": {
"node": ">=22.2.0",
"pnpm": ">=9.9.0",
"yarn": ">=999.0.0",
"npm": ">=999.0.0"
},
Expand Down Expand Up @@ -59,44 +58,44 @@
"ts-results-es": "^4.2.0"
},
"devDependencies": {
"@changesets/cli": "^2.27.10",
"@commitlint/cli": "^19.6.0",
"@commitlint/config-conventional": "^19.6.0",
"@eslint-react/eslint-plugin": "^1.17.1",
"@eslint/compat": "^1.2.3",
"@lingui/cli": "^5.1.2",
"@lingui/swc-plugin": "^5.0.2",
"@changesets/cli": "^2.28.1",
"@commitlint/cli": "^19.7.1",
"@commitlint/config-conventional": "^19.7.1",
"@eslint-react/eslint-plugin": "^1.30.2",
"@eslint/compat": "^1.2.7",
"@lingui/cli": "^5.2.0",
"@lingui/swc-plugin": "^5.4.0",
"@masknet/cli": "workspace:^",
"@masknet/config": "workspace:^",
"@masknet/eslint-plugin": "^0.3.0",
"@masknet/typescript-plugin": "workspace:^",
"@nice-labs/git-rev": "^3.5.1",
"@swc-node/register": "^1.10.9",
"@swc/core": "1.9.3",
"@tanstack/eslint-plugin-query": "^5.61.4",
"@swc/core": "1.11.7",
"@tanstack/eslint-plugin-query": "^5.66.1",
"@types/lodash-es": "^4.17.12",
"@vitest/ui": "^2.1.6",
"cspell": "^8.16.1",
"eslint": "9.19.0",
"@vitest/ui": "^3.0.7",
"cspell": "^8.17.5",
"eslint": "9.21.0",
"eslint-formatter-junit": "^8.40.0",
"eslint-import-resolver-typescript": "^3.7.0",
"eslint-import-resolver-typescript": "^3.8.3",
"eslint-plugin-i": "^2.29.1",
"eslint-plugin-lingui": "^0.10.0",
"eslint-plugin-react-compiler": "19.0.0-beta-714736e-20250131",
"eslint-plugin-react-hooks": "^5.1.0",
"eslint-plugin-react-hooks": "^5.2.0",
"eslint-plugin-tss-unused-classes": "^1.0.3",
"eslint-plugin-unicorn": "^56.0.1",
"eslint-plugin-unicorn": "^57.0.0",
"eslint-plugin-unused-imports": "^4.1.4",
"gulp": "^5.0.0",
"husky": "^9.0.11",
"knip": "^5.38.1",
"lint-staged": "^15.2.10",
"prettier": "^3.4.1",
"husky": "^9.1.7",
"knip": "^5.45.0",
"lint-staged": "^15.4.3",
"prettier": "^3.5.3",
"svgo": "^3.3.2",
"typescript": "5.7.2",
"typescript-eslint": "^8.23.0",
"vite": "^5.1.8",
"vitest": "^2.1.6"
"typescript": "5.8.2",
"typescript-eslint": "^8.26.0",
"vite": "^6.2.0",
"vitest": "^3.0.7"
},
"pnpm": {
"overrides": {
Expand All @@ -109,7 +108,7 @@
"@protobufjs/inquire": "1.1.0",
"@splinetool/runtime": "0.9.342",
"@tanstack/react-query": "^5.49.2",
"@types/node": "22.7.5",
"@types/node": "22.13.9",
"@types/react": "$@types/react",
"@types/react-dom": "$@types/react-dom",
"elliptic": "6.6.1",
Expand Down
2 changes: 1 addition & 1 deletion packages/flags/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,6 @@
"dependencies": {
"@dimensiondev/holoflows-kit": "0.9.0-20240322092738-f9180f3",
"urlcat": "^3.1.0",
"zod": "^3.23.8"
"zod": "^3.24.2"
}
}
2 changes: 1 addition & 1 deletion packages/injected-script/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"start": "rollup -c -w"
},
"devDependencies": {
"rollup": "^4.27.4",
"rollup": "^4.34.9",
"rollup-plugin-swc3": "^0.12.1"
}
}
4 changes: 2 additions & 2 deletions packages/mask-sdk/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@
},
"devDependencies": {
"@rollup/plugin-image": "^3.0.3",
"@rollup/plugin-node-resolve": "^15.3.0",
"@rollup/plugin-node-resolve": "^16.0.0",
"async-call-rpc": "^6.4.2",
"rollup": "^4.27.4",
"rollup": "^4.34.9",
"rollup-plugin-swc3": "^0.12.1"
}
}
24 changes: 12 additions & 12 deletions packages/mask/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -142,33 +142,33 @@
"web3-utils": "1.10.2",
"webextension-polyfill": "^0.12.0",
"zlib-browserify": "^0.0.3",
"zod": "^3.23.8"
"zod": "^3.24.2"
},
"devDependencies": {
"@lavamoat/webpack": "0.7.0-beta.0",
"@lavamoat/webpack": "0.8.1-beta.0",
"@nice-labs/emit-file-webpack-plugin": "^1.1.4",
"@pmmmwh/react-refresh-webpack-plugin": "^0.5.15",
"@rspack/cli": "^1.1.4",
"@rspack/core": "^1.1.4",
"@rspack/plugin-react-refresh": "^1.0.0",
"@types/color": "^3.0.6",
"@rspack/cli": "^1.2.7",
"@rspack/core": "^1.2.7",
"@rspack/plugin-react-refresh": "^1.0.1",
"@types/color": "^4.2.0",
"@types/react-devtools-inline": "^4.24.8",
"@types/react-window": "^1.8.8",
"babel-plugin-react-compiler": "19.0.0-beta-df7b47d-20241124",
"copy-webpack-plugin": "^12.0.2",
"copy-webpack-plugin": "^13.0.0",
"devtools-ignore-webpack-plugin": "^0.2.0",
"html-webpack-plugin": "^5.6.3",
"react-compiler-webpack": "^0.1.2",
"react-devtools-inline": "5.3.0",
"react-refresh": "^0.14.2",
"rimraf": "^5.0.7",
"react-refresh": "^0.16.0",
"rimraf": "^6.0.1",
"source-map-loader": "^5.0.0",
"svgo-loader": "^4.0.0",
"swc-loader": "^0.2.6",
"terser-webpack-plugin": "^5.3.10",
"terser-webpack-plugin": "^5.3.12",
"webpack": "Jack-Works/webpack#lazy-import",
"webpack-cli": "^5.1.4",
"webpack-dev-server": "^5.1.0",
"webpack-cli": "^6.0.1",
"webpack-dev-server": "^5.2.0",
"webpack-target-webextension": "^2.1.3"
},
"peerDependencies": {
Expand Down
1 change: 1 addition & 0 deletions packages/mask/popups/hooks/useHasNavigator.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { createContext, useContext } from 'react'

export const HasNavigatorContext = createContext(false)
HasNavigatorContext.displayName = 'HasNavigatorContext'
export function useHasNavigator() {
return useContext(HasNavigatorContext)
}
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ export function TransactionRequest(props: InteractionItemProps) {
const payload = createJsonRpcPayload(0, request.request.arguments)
const computedPayload = PayloadEditor.fromPayload(payload).config
const formattedTransaction = await TransactionFormatter?.formatTransaction(chainId, computedPayload)
// eslint-disable-next-line react/no-missing-context-display-name
const transactionContext = await TransactionFormatter?.createContext(chainId, computedPayload)

return {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ export const useUnconfirmedRequest = () => {

const computedPayload = PayloadEditor.fromPayload(payload).config
const formatterTransaction = await TransactionFormatter?.formatTransaction(chainId, computedPayload)
// eslint-disable-next-line react/no-missing-context-display-name
const transactionContext = await TransactionFormatter?.createContext(chainId, computedPayload)
return {
owner: payload.owner,
Expand Down
1 change: 1 addition & 0 deletions packages/plugin-infra/src/manager/manage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@ export function createManager<
controller: abort,
context: {
...getManagedContext(id, abort.signal),
// eslint-disable-next-line react/no-missing-context-display-name
..._host.createContext(id, definition, abort.signal),
} as any,
minimalModeEnabled: new ValueRefWithReady(),
Expand Down
8 changes: 4 additions & 4 deletions packages/plugin-infra/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -450,7 +450,7 @@ export namespace Plugin.SiteAdaptor {
export interface SearchResultContent {
ID: string
UI?: {
Content?: React.ForwardRefExoticComponent<{ keyword: string } & React.RefAttributes<unknown>>
Content?: React.ComponentType<{ keyword: string } & React.RefAttributes<unknown>>
}
}

Expand Down Expand Up @@ -934,7 +934,7 @@ export namespace Plugin.GeneralUI {
*
* 3. Actions
*
* The render component MUST BE a ForwardRefExotic React Component
* The render component MUST BE accept a ref.
* that support operations defined in `Plugin.ContextFree.MetadataRender.RenderActions`
*/
metadataRender?: MetadataRender.StaticRender | MetadataRender.DynamicRender
Expand All @@ -945,14 +945,14 @@ export namespace Plugin.GeneralUI {
// #region Static render
// new Map([ [reader, react component] ])
export type StaticRender<T = any> = ReadonlyMap<MetadataReader<T>, StaticRenderComponent<T>>
export type StaticRenderComponent<T> = Omit<React.ForwardRefExoticComponent<StaticRenderProps<T>>, 'propTypes'>
export type StaticRenderComponent<T> = Omit<React.ComponentType<StaticRenderProps<T>>, 'propTypes'>
export type StaticRenderProps<T> = Context<T> &
React.RefAttributes<RenderActions<T>> & {
metadata: T
}
// #endregion
// #region DynamicRender
export type DynamicRender = Omit<React.ForwardRefExoticComponent<DynamicRenderProps>, 'propTypes'>
export type DynamicRender = Omit<React.ComponentType<DynamicRenderProps>, 'propTypes'>
export type DynamicRenderProps = Context<unknown> &
React.RefAttributes<RenderActions<unknown>> & {
metadata: TypedMessage['meta']
Expand Down
1 change: 1 addition & 0 deletions packages/plugins/Avatar/src/contexts/AvatarManagement.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ const AvatarManagementContext = createContext<AvatarManagementContextOptions>({
selectedTokenInfo: undefined,
setSelectedTokenInfo: noop,
})
AvatarManagementContext.displayName = 'AvatarManagementContext'

interface Props extends PropsWithChildren<{ socialIdentity?: SocialIdentity }> {}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@ export const OfferCard = memo(function OfferCard({ offer, ...rest }: OfferCardPr
if (offer.priceInToken?.token.logoURL)
return <img width={20} height={20} src={offer.priceInToken?.token.logoURL} alt="" />

// eslint-disable-next-line react/naming-convention/component-name
if (offer.priceInToken?.token.symbol.toUpperCase() === 'WETH') return <Icons.WETH size={18} />

return offer.priceInToken?.token.address ?
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,6 @@ export function PriceCard({ topListing }: PriceCardProps) {
const { symbol, logoURL } = topListing?.priceInToken?.token ?? {}
if (symbol?.toUpperCase() === 'ETH') return <Icons.ETH size={18} />
if (logoURL) return <img width={18} height={18} src={logoURL} alt="" />
// eslint-disable-next-line react/naming-convention/component-name
if (symbol?.toUpperCase() === 'WETH') return <Icons.WETH size={18} />

return (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ const FileManagementContext = createContext<FileManagementContextOptions>({
uploadFile: null!,
attachToPost: noop,
})
FileManagementContext.displayName = 'FileManagementContext'

function openCompositionWithFiles(type: CompositionType, files: FileInfo[]) {
CrossIsolationMessages.events.compositionDialogEvent.sendToLocal({
Expand Down
2 changes: 1 addition & 1 deletion packages/plugins/FileService/src/Worker/arweave.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { isEmpty } from 'lodash-es'
import Arweave from 'arweave/web'
import Arweave from 'arweave/web/index.js'
import { Attachment } from '@dimensiondev/common-protocols'
import { encodeText } from '@masknet/kit'
import type Transaction from 'arweave/web/lib/transaction.js'
Expand Down
2 changes: 1 addition & 1 deletion packages/plugins/NextID/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"@masknet/web3-shared-base": "workspace:^",
"@masknet/web3-shared-evm": "workspace:^",
"react-use": "^17.5.0",
"zod": "^3.23.8"
"zod": "^3.24.2"
},
"lingui": {
"compileNamespace": "json",
Expand Down
Loading