react-magic-portal 1.1.9 → 1.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +19 -0
- package/README.md +8 -7
- package/__tests__/eslint.config.ts +5 -6
- package/__tests__/package.json +11 -12
- package/__tests__/src/magic-portal.test.tsx +26 -9
- package/package.json +2 -2
- package/packages/component/dist/index.d.ts +2 -0
- package/packages/component/dist/index.d.ts.map +1 -1
- package/packages/component/dist/index.js +1 -1
- package/packages/component/dist/index.js.map +1 -1
- package/packages/component/eslint.config.ts +11 -7
- package/packages/component/package.json +11 -12
- package/packages/component/src/index.ts +78 -16
- package/packages/example/dist/assets/index-jJ0JbhKk.js +49 -0
- package/packages/example/dist/index.html +1 -1
- package/packages/example/eslint.config.ts +4 -6
- package/packages/example/package.json +10 -11
- package/packages/example/src/App.tsx +3 -1
- package/packages/example/dist/assets/index-BeXVndGe.js +0 -49
|
@@ -3,8 +3,7 @@ import pluginJs from '@eslint/js'
|
|
|
3
3
|
import { defineConfig } from 'eslint/config'
|
|
4
4
|
import tseslint from 'typescript-eslint'
|
|
5
5
|
import prettierPlugin from 'eslint-plugin-prettier/recommended'
|
|
6
|
-
import
|
|
7
|
-
import reactRefresh from 'eslint-plugin-react-refresh'
|
|
6
|
+
import eslintReact from '@eslint-react/eslint-plugin'
|
|
8
7
|
|
|
9
8
|
export default defineConfig([
|
|
10
9
|
{
|
|
@@ -18,8 +17,7 @@ export default defineConfig([
|
|
|
18
17
|
}
|
|
19
18
|
},
|
|
20
19
|
pluginJs.configs.recommended,
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
reactRefresh.configs.vite
|
|
20
|
+
tseslint.configs.recommended,
|
|
21
|
+
eslintReact.configs['recommended-typescript'],
|
|
22
|
+
prettierPlugin
|
|
25
23
|
])
|
|
@@ -11,22 +11,21 @@
|
|
|
11
11
|
"check": "tsc --noEmit"
|
|
12
12
|
},
|
|
13
13
|
"dependencies": {
|
|
14
|
-
"react": "^19.
|
|
15
|
-
"react-dom": "^19.
|
|
14
|
+
"react": "^19.2.0",
|
|
15
|
+
"react-dom": "^19.2.0",
|
|
16
16
|
"react-magic-portal": "workspace:*"
|
|
17
17
|
},
|
|
18
18
|
"devDependencies": {
|
|
19
|
-
"@eslint/
|
|
20
|
-
"@
|
|
21
|
-
"@types/react
|
|
19
|
+
"@eslint-react/eslint-plugin": "^2.0.6",
|
|
20
|
+
"@eslint/js": "^9.37.0",
|
|
21
|
+
"@types/react": "^19.2.2",
|
|
22
|
+
"@types/react-dom": "^19.2.1",
|
|
22
23
|
"@vitejs/plugin-react": "^5.0.4",
|
|
23
|
-
"eslint": "^9.
|
|
24
|
+
"eslint": "^9.37.0",
|
|
24
25
|
"eslint-plugin-prettier": "^5.5.4",
|
|
25
|
-
"eslint-plugin-react-hooks": "^5.2.0",
|
|
26
|
-
"eslint-plugin-react-refresh": "^0.4.22",
|
|
27
26
|
"globals": "^16.4.0",
|
|
28
|
-
"typescript": "~5.9.
|
|
29
|
-
"typescript-eslint": "^8.
|
|
30
|
-
"vite": "^7.1.
|
|
27
|
+
"typescript": "~5.9.3",
|
|
28
|
+
"typescript-eslint": "^8.46.0",
|
|
29
|
+
"vite": "^7.1.9"
|
|
31
30
|
}
|
|
32
31
|
}
|
|
@@ -27,7 +27,9 @@ function App() {
|
|
|
27
27
|
)}
|
|
28
28
|
</div>
|
|
29
29
|
<div className="controls">
|
|
30
|
-
<button onClick={() => setShowAnchor(!showAnchor)}>
|
|
30
|
+
<button type="button" onClick={() => setShowAnchor(!showAnchor)}>
|
|
31
|
+
{showAnchor ? 'Hide Anchor' : 'Show Anchor'}
|
|
32
|
+
</button>
|
|
31
33
|
</div>
|
|
32
34
|
|
|
33
35
|
{/* Target anchor examples */}
|