{"name":"@rc-component/portal","version":"2.2.1","description":"React Portal Component","keywords":["react","react-component","react-portal"],"homepage":"https://github.com/react-component/portal","bugs":{"url":"https://github.com/react-component/portal/issues"},"repository":{"type":"git","url":"git+https://github.com/react-component/portal.git"},"license":"MIT","author":{"name":"smith3816@gmail.com"},"main":"./lib/index","module":"./es/index","typings":"es/index.d.ts","scripts":{"compile":"father build","deploy":"npm run docs:build && npm run docs:deploy","docs:build":"dumi build","docs:deploy":"gh-pages -d docs-dist","lint":"eslint src/ --ext .tsx,.ts","lint:tsc":"tsc -p tsconfig.json --noEmit","now-build":"npm run docs:build","prepare":"dumi setup","prepublishOnly":"npm run compile && rc-np","prettier":"prettier --write \"**/*.{js,jsx,tsx,ts,less,md,json}\"","start":"dumi dev","test":"npm run test:server && npm run test:coverage","test:client":"rc-test --testPathIgnorePatterns=ssr.test.tsx --testPathIgnorePatterns=ssr.test.tsx","test:coverage":"npm run test:client -- --coverage","test:server":"rc-test --env=node -- tests/ssr.test.tsx","watch":"father dev"},"dependencies":{"@rc-component/util":"^1.11.0","clsx":"^2.1.1"},"devDependencies":{"@rc-component/father-plugin":"^2.2.0","@rc-component/np":"^1.0.3","@testing-library/dom":"^10.4.1","@testing-library/jest-dom":"^6.9.0","@testing-library/react":"^16.3.2","@types/jest":"^26.0.20","@types/node":"^20.9.0","@types/react":"^18.0.0","@types/react-dom":"^18.0.0","@umijs/fabric":"^4.0.0","dumi":"^2.0.0","eslint":"^8.0.0","father":"^4.0.0","gh-pages":"^6.1.1","glob":"^10.0.0","prettier":"^2.1.2","rc-test":"^7.1.2","react":"^19.0.0","react-dom":"^19.0.0","typescript":"^5.0.0"},"peerDependencies":{"react":">=18.0.0","react-dom":">=18.0.0"},"engines":{"node":">=12.x"},"gitHead":"e6e5bc0a7ed167f35fc7cddb2618390f73062e5d","_id":"@rc-component/portal@2.2.1","_nodeVersion":"22.15.1","_npmVersion":"11.7.0","dist":{"integrity":"sha512-ck+r1kW/JSv0wxPji3KN2ss9K6Z0qqwusw/mf/0JobXhZ8hC2ejZwCJObW/SvDi0uhA0VzmCnx0CaCci95tcmA==","shasum":"37c34b4c8cd73f53cc7072c96dd0e9ac332669ec","tarball":"http://registry-npm.ywwl.com/@rc-component/portal/download/@rc-component/portal-2.2.1.tgz","fileCount":35,"unpackedSize":31752,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQDElQdrIiERcw05Nn079sAvcZmmj1T0bq97NKLWNmDXLQIhAPNv3RaiIhnq2EGa28i3wPtkeFPSIZ3077Hnip2RKEgs"}],"size":7439,"noattachment":false,"key":"/@rc-component/portal/-/@rc-component/portal-2.2.1.tgz"},"_npmUser":{"name":"zombiej","email":"smith3816@gmail.com"},"directories":{},"maintainers":[{"name":"zombiej","email":"smith3816@gmail.com"},{"name":"afc163","email":"afc163@gmail.com"},{"name":"madccc","email":"1075746765@qq.com"},{"name":"peachscript","email":"scdzwyxst@gmail.com"},{"name":"chenshuai2144","email":"wasd2144@hotmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/portal_2.2.1_1780676304739_0.42035042319952476"},"_hasShrinkwrap":false,"readme":"# rc-portal\n\nReact 18 supported Portal Component.\n\n[![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] [![Codecov][codecov-image]][codecov-url] [![npm download][download-image]][download-url]\n\n[npm-image]: http://img.shields.io/npm/v/rc-portal.svg?style=flat-square\n[npm-url]: http://npmjs.org/package/rc-portal\n[github-actions-image]: https://github.com/react-component/portal/workflows/CI/badge.svg\n[github-actions-url]: https://github.com/react-component/portal/actions\n[codecov-image]: https://img.shields.io/codecov/c/github/react-component/portal/master.svg?style=flat-square\n[codecov-url]: https://app.codecov.io/gh/react-component/portal\n[download-image]: https://img.shields.io/npm/dm/rc-portal.svg?style=flat-square\n[download-url]: https://npmjs.org/package/rc-portal\n\n## Development\n\n```bash\nnpm install\nnpm start\nopen http://localhost:8000\n```\n\n## Feature\n\n- React life cycle support portal component\n\n## Install\n\n[![rc-portal](https://nodei.co/npm/rc-portal.png)](https://npmjs.org/package/rc-portal)\n\n## Usage\n\n```js | pure\nimport Portal from '@rc-component/portal';\n\nconst Demo = () => {\n  return <Portal open>Hello World</Portal>;\n};\n\nexport default Demo;\n```\n\n## 🔥 API\n\nWe use typescript to create the Type definition. You can view directly in IDE. But you can still check the type definition [here](https://github.com/react-component/portal/blob/master/src/interface.ts).\n\n### Portal\n\n| Prop         | Description                        | Type                     | Default       |\n| ------------ | ---------------------------------- | ------------------------ | ------------- |\n| getContainer | Customize portal container element | Element \\| () => Element | document.body |\n| open         | Show the portal                    | boolean                  | false         |\n| autoLock     | Lock screen scroll when open       | boolean                  | false         |\n","publish_time":1780676304879,"_cnpm_publish_time":1780676304879,"dist-tags":{"latest":"2.2.1"}}