{"_id":"@sanar/react-native-highlight-text","_rev":"3-7635b5d21a2a5b9af61de13d2f4f28b4","name":"@sanar/react-native-highlight-text","dist-tags":{"latest":"1.0.2"},"versions":{"1.0.0":{"name":"@sanar/react-native-highlight-text","version":"1.0.0","description":"A React Native port of react-native-highlight-words. This component is used to highlight words within a larger body of text.","main":"lib/commonjs/index.js","react-native":"lib/module/index.js","module":"lib/module/index.js","types":"lib/typescript/src/index.d.ts","scripts":{"prepare":"bob build","release":"dotenv release-it","lint":"eslint src/index.tsx","prettier":"prettier --write **/*.{js,tsx,json}","test":"jest --verbose","test:coverage":"jest --coverage","test:watch":"jest --verbose --watch"},"keywords":["react-native","react","reactjs","react-component","highlighter","highlight","text","words","matches","substring","occurrences","search"],"author":{"name":"Sanar Tech"},"license":"MIT","homepage":"https://github.com/sanar/react-native-highlight-text","bugs":{"url":"https://github.com/sanar/react-native-highlight-text/issues"},"publishConfig":{"access":"public","registry":"https://registry.npmjs.org/"},"repository":{"type":"git","url":"git+https://github.com/sanar/react-native-highlight-text.git"},"dependencies":{"highlight-words-core":"^1.2.0","prop-types":"^15.7.2"},"devDependencies":{"@babel/core":"^7.6.2","@babel/runtime":"^7.6.2","@commitlint/cli":"^8.3.5","@commitlint/config-conventional":"^8.3.4","@react-native-community/bob":"^0.16.0","@react-native-community/eslint-config":"^1.1.0","@react-native-community/eslint-plugin":"^1.1.0","@release-it/conventional-changelog":"^1.1.4","@testing-library/jest-native":"^3.1.0","@types/highlight-words-core":"^1.2.0","@types/jest":"^25.2.3","@types/react-native":"^0.62.12","@types/react-test-renderer":"16.9.2","@typescript-eslint/eslint-plugin":"^3.1.0","@typescript-eslint/parser":"^3.1.0","babel-jest":"^26.0.1","dotenv-cli":"^3.2.0","eslint":"^7.1.0","eslint-plugin-prettier":"^3.1.3","husky":"^4.2.5","jest":"^26.0.1","lint-staged":"^10.2.7","metro-react-native-babel-preset":"^0.59.0","prettier":"^2.0.5","react":"16.9.0","react-native":"0.61.5","react-test-renderer":"16.9.0","release-it":"^13.6.3","typescript":"3.8.3"},"peerDependencies":{"react":"*","react-native":"*"},"husky":{"hooks":{"pre-commit":"lint-staged","commit-msg":"commitlint -E HUSKY_GIT_PARAMS"}},"lint-staged":{"*.{js,ts,tsx}":["yarn prettier","yarn lint"]},"@react-native-community/bob":{"source":"src","output":"lib","targets":["commonjs","module","typescript"]},"gitHead":"0d2331a75c071a5213ab2e4fd9ece68753b2d273","_id":"@sanar/react-native-highlight-text@1.0.0","_nodeVersion":"12.19.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-6d0ylTB579keG65clZkWJxogCjTZJqbl3BQqU3DhKxcfugmVIYwRJGS5xV1UNVKS4eQ15gYFl9tWZSJqeoaMBQ==","shasum":"d5933fa9aa2407b180406e97dbc4c3ec070e871f","tarball":"https://registry.npmjs.org/@sanar/react-native-highlight-text/-/react-native-highlight-text-1.0.0.tgz","fileCount":11,"unpackedSize":16958,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfkmucCRA9TVsSAnZWagAAIdYP/0VJ37omyhDru0vsm7Uf\n5dxrbAu9C+N45Alk2CDgiytM4QCAh2pFGuoFV9bT9L7FJ/bEIpx4WwvV+UmC\nQi7nMgmhk3skVnHVEj43cqKp1LTuZX9kLPdZisUcvT0iiJghQiDUnOOQr3A0\nuH3ag/OHwIS/dh51nJUjKgsZesYRLRpfXvJ3l9cJqRgKrVuGvbomO10zwSvg\nMBLmpi/zsihdNt0wrEhxGXR8CvcpyBGKfv0yvfbTIJ6R9T5YDuHh449Li938\nVJuduwCM/2SDP9OO8yrUV5weFON6il6RroqZLQowiCOLFAm3z55mKDfDfied\nN8upYLhLd2BwAArTGhctSdb+h/n/Bn6fegQ9qY+KcJNjI8ePCSG74G5yb6e5\nSgVD3ZrVKZVqxWUpA8KjXiAXI7W7XB6T6mpXNwhOcW6B24cnpXQE+AYUMZPK\nHYQUdrERagXVPOUXxDFgc0CHsysOyIMPlpknaxk6ClZFYpoF4dzycDWfFo4Q\nJ2su67FcMY6EkK6rVrEy9uv5oX4CtQPrec4LCFZcICrPsh/AOjFxmpFifQxr\nhX06jnh8wnUUWSD+Bs1L9mSG4djilpMW0C2AgAMqg/UGDCIW76AkJvkV2sJj\no6BDllgRhECFHBqliLSVDGVVEAEV9Q5QydbDEbrleYzIfkF+SsTXxQGIx0zi\nEvsR\r\n=JLfB\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCT381bIX5UjVGSGIx54D2Fr3b2tA4oE51DZ7pqGW+hFwIhANVlJh6jb9x+l07trKdcNJxkFKum3jaKSthPRQxrrxZq"}]},"maintainers":[{"name":"sanar","email":"ti@editorasanar.com.br"}],"_npmUser":{"name":"sanar","email":"ti@editorasanar.com.br"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/react-native-highlight-text_1.0.0_1603431324015_0.7189481746558655"},"_hasShrinkwrap":false},"1.0.1":{"name":"@sanar/react-native-highlight-text","version":"1.0.1","description":"A React Native port of react-native-highlight-words. This component is used to highlight words within a larger body of text.","main":"lib/commonjs/index.js","react-native":"lib/module/index.js","module":"lib/module/index.js","types":"lib/typescript/src/index.d.ts","scripts":{"prepare":"bob build","release":"dotenv release-it","lint":"eslint src/index.tsx","prettier":"prettier --write **/*.{js,tsx,json}","test":"jest --verbose","test:coverage":"jest --coverage","test:watch":"jest --verbose --watch"},"keywords":["react-native","react","reactjs","react-component","highlighter","highlight","text","words","matches","substring","occurrences","search"],"author":{"name":"Sanar Tech"},"license":"MIT","homepage":"https://github.com/sanar/react-native-highlight-text","bugs":{"url":"https://github.com/sanar/react-native-highlight-text/issues"},"publishConfig":{"access":"public","registry":"https://registry.npmjs.org/"},"repository":{"type":"git","url":"git+https://github.com/sanar/react-native-highlight-text.git"},"dependencies":{"highlight-words-core":"^1.2.0","prop-types":"^15.7.2"},"devDependencies":{"@babel/core":"^7.6.2","@babel/runtime":"^7.6.2","@commitlint/cli":"^8.3.5","@commitlint/config-conventional":"^8.3.4","@react-native-community/bob":"^0.16.0","@react-native-community/eslint-config":"^1.1.0","@react-native-community/eslint-plugin":"^1.1.0","@release-it/conventional-changelog":"^1.1.4","@testing-library/jest-native":"^3.1.0","@types/highlight-words-core":"^1.2.0","@types/jest":"^25.2.3","@types/react-native":"^0.62.12","@types/react-test-renderer":"16.9.2","@typescript-eslint/eslint-plugin":"^3.1.0","@typescript-eslint/parser":"^3.1.0","babel-jest":"^26.0.1","dotenv-cli":"^3.2.0","eslint":"^7.1.0","eslint-plugin-prettier":"^3.1.3","husky":"^4.2.5","jest":"^26.0.1","lint-staged":"^10.2.7","metro-react-native-babel-preset":"^0.59.0","prettier":"^2.0.5","react":"16.9.0","react-native":"0.61.5","react-test-renderer":"16.9.0","release-it":"^13.6.3","typescript":"3.8.3"},"peerDependencies":{"react":"*","react-native":"*"},"husky":{"hooks":{"pre-commit":"lint-staged","commit-msg":"commitlint -E HUSKY_GIT_PARAMS"}},"lint-staged":{"*.{js,ts,tsx}":["yarn prettier","yarn lint"]},"@react-native-community/bob":{"source":"src","output":"lib","targets":["commonjs","module","typescript"]},"gitHead":"f310998f32a9c95ac69fbf5d5b92054a81a86473","_id":"@sanar/react-native-highlight-text@1.0.1","_nodeVersion":"12.19.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-IFOaazDKJlNAVfuiWHwKFtwuFOADA3Xeyj0y7rg5+fdU3RsIdfA1gVk/c1wT9zAod3Dc7UIv5ikjJbEwexPtQg==","shasum":"5b2b39a5c88b4cc5afb7c1cf10676d35d7b6b4d0","tarball":"https://registry.npmjs.org/@sanar/react-native-highlight-text/-/react-native-highlight-text-1.0.1.tgz","fileCount":11,"unpackedSize":20361,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJflI4JCRA9TVsSAnZWagAAdKEP/j9dXD74QxoagnXBni3U\nN7HkJe6+bEt/7V09tPaVyz2NcxHf/K2gLymIMlZ8xVL68wuLwsXHEnTmiLCk\nyOnDpPQGTpOLlFh2gZylZd31HdPKiZvhztrVc0Lf1/vzgOzgeg7JLB2rfVKJ\ndRDNRA6STyY4OLjDopEjnXV3Re1FaAfIIydXGEQ9prMpOEmNYU3ZXP2AtQ1O\n7YaSKuY7aA9lJS6pzWpQBHi7HBWwttPWtnIz8BEcv/Ea+bWsg0rg+9faTG/0\nrrnVQgI/1NMbiWNklLUL+NWJsq2LbaGWgOK9MDaGkgMjV5vTxtag0liN9m8z\nbE1gXHrom+ZH0O5a+B/8+NjdVPztRDrzrGr6dGfH/M9cARzdtJ1QJ9KFGh9S\nL5RSknELD/Asn7a+MjyTV85LH7mWuuog+o3LavdhXNHiGa9X0GEGz4IlBdsV\ntNYyTx3cUh/U7j3B1e+jO0b2HHhC+7e764QYSmxfoLiGofFxEAEKPEoHjHhr\nlg8c9htmo3+f9Jvvf+aYYH9cVlopeKXmUVEHLMSiqChG32nXuSxb1wX52s5K\no2+hsFshscGnWfpJ5bPKZzQ6UuqwmGH58dlTG+wVHdJ4JZG1B8zUSrbOLI7T\n0d5YQ+t1NRuAtVUZ7Llgmc0CCzzs4GMh11NjimiIsOjXB0zFhifGzTSABGAu\nQHq2\r\n=Vz9a\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCopXVQZ97+l5T8x8eO/ssbQVQW8/Z8PrZ00qM+06+4aQIhAIa0zam6NluWZzE3rIcNDXf/EpGTmbeNJwaNamFhy2GY"}]},"maintainers":[{"name":"sanar","email":"ti@editorasanar.com.br"}],"_npmUser":{"name":"sanar","email":"ti@editorasanar.com.br"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/react-native-highlight-text_1.0.1_1603571209346_0.44780209843487295"},"_hasShrinkwrap":false},"1.0.2":{"name":"@sanar/react-native-highlight-text","version":"1.0.2","description":"A React Native port of react-native-highlight-words. This component is used to highlight words within a larger body of text.","main":"lib/commonjs/index.js","react-native":"lib/module/index.js","module":"lib/module/index.js","types":"lib/typescript/index.d.ts","scripts":{"prepare":"bob build","release":"dotenv release-it","check-code":"yarn prettier && yarn lint && yarn tsc --noEmit","lint":"eslint src/index.tsx","prettier":"prettier --write **/*.{js,tsx,json}","test":"jest --verbose","test:coverage":"jest --coverage","test:watch":"jest --verbose --watch"},"keywords":["react-native","react","reactjs","react-component","highlighter","highlight","text","words","matches","substring","occurrences","search"],"author":{"name":"Sanar Tech"},"license":"MIT","homepage":"https://github.com/sanar/react-native-highlight-text","bugs":{"url":"https://github.com/sanar/react-native-highlight-text/issues"},"publishConfig":{"access":"public","registry":"https://registry.npmjs.org/"},"repository":{"type":"git","url":"git+https://github.com/sanar/react-native-highlight-text.git"},"dependencies":{"highlight-words-core":"^1.2.0","prop-types":"^15.7.2"},"devDependencies":{"@babel/core":"^7.6.2","@babel/runtime":"^7.6.2","@commitlint/cli":"^8.3.5","@commitlint/config-conventional":"^8.3.4","@react-native-community/bob":"^0.16.0","@react-native-community/eslint-config":"^1.1.0","@react-native-community/eslint-plugin":"^1.1.0","@release-it/conventional-changelog":"^1.1.4","@testing-library/jest-native":"^3.1.0","@types/highlight-words-core":"^1.2.0","@types/jest":"^25.2.3","@types/react-native":"^0.62.12","@types/react-test-renderer":"16.9.2","@typescript-eslint/eslint-plugin":"^3.1.0","@typescript-eslint/parser":"^3.1.0","babel-jest":"^26.0.1","dotenv-cli":"^3.2.0","eslint":"^7.1.0","eslint-plugin-prettier":"^3.1.3","husky":"^4.2.5","jest":"^26.0.1","lint-staged":"^10.2.7","metro-react-native-babel-preset":"^0.59.0","prettier":"^2.0.5","react":"16.9.0","react-native":"0.61.5","react-test-renderer":"16.9.0","release-it":"^13.6.3","typescript":"3.8.3"},"peerDependencies":{"react":"*","react-native":"*"},"husky":{"hooks":{"pre-commit":"lint-staged","commit-msg":"commitlint -E HUSKY_GIT_PARAMS"}},"lint-staged":{"*.{js,ts,tsx}":["yarn prettier","yarn lint","yarn tsc --noEmit"]},"@react-native-community/bob":{"source":"src","output":"lib","targets":["commonjs","module","typescript"]},"gitHead":"d5bc2198dcc653471818b4957c534341324a149f","_id":"@sanar/react-native-highlight-text@1.0.2","_nodeVersion":"12.20.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-+mhWujE0YcagtTWHIipSSTAz4ROCmDTLl5MwIL1WtO9ohnMVWPRuZTeqwrJ5kQbSjHZ+/sdZfg1gGU7enNPB4g==","shasum":"3109442e610095efa647ef49a094d6e143d4b30a","tarball":"https://registry.npmjs.org/@sanar/react-native-highlight-text/-/react-native-highlight-text-1.0.2.tgz","fileCount":11,"unpackedSize":20453,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgLpYNCRA9TVsSAnZWagAAt6cP/18qrrygFSd6oxOmGvmx\nylSV0RrPfQXnGCvDVKYvV1h1Kz0aNmJACirQUE4nPSvD5FBRBR3pPSRz4GyM\ndgySAUGnP8LqKpRt2yoNmoDrSkLUsaSixQM5tb4RnYQkIevuonl00Fvfjifv\n2D7axJwhzUdCeciD86d8zxxKlX6uarzOasBX5ycY8V10JDGmiQuW1v+qEZ8H\nkxuNe5ejFymraKA5xGMIRxLpRX4EToNxL5mD+9PhB2srqisG4KsnNsLLCkMg\nDIxJJK89m6dZO8K0vPRmGG7YH5U181mQiOop430H0pj+0w5ABkLDdgnpu4VY\n/nyUyRtdLHRTMWfmDh5XVAg6Pq+qlVOP+1HnZuQCqg3oWpq5qa4l+5XmditS\nQVNgRhHk2r4cx5ilXDP2cip3rIsnGC5cM3oVtP5NFhxzhXX+T2GtwT8Kwdv4\n4pch3+dF4635HB0VIJtGOF5m5/w8m+O4KppMEAC+/B9cmLPiPJvFKzKR8jwY\nmolgYKaj6bRKESSyWX1VU6ocOGvp+Wwevvw2aQLW9tQgs+1QWigbXPA6frzX\nwzPe45Q3y9iiw5PtWRXuyoxoTjF56/DKR5CHt8WtDpu4A3vCWveAdY092JbD\nkCcs1ws9ro2kGi7f3q8QRfuMww1FEmeUhuS75qxvYPiDeeVCcAaAK/Bch5pv\n/zH5\r\n=DtfA\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIEMK8lInOc99acxJGWTnDKLjP2/i76x0oxkQWbXZThwpAiAQc6hvFrZduqSQZ36OYNp1ONxgGtkZ2fwlH1FUc+ZVWQ=="}]},"_npmUser":{"name":"sanar","email":"ti@editorasanar.com.br"},"directories":{},"maintainers":[{"name":"sanar","email":"ti@editorasanar.com.br"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/react-native-highlight-text_1.0.2_1613665804381_0.29386918246381444"},"_hasShrinkwrap":false}},"time":{"created":"2020-10-23T05:35:23.967Z","1.0.0":"2020-10-23T05:35:24.123Z","modified":"2022-04-06T21:31:04.636Z","1.0.1":"2020-10-24T20:26:49.487Z","1.0.2":"2021-02-18T16:30:04.564Z"},"maintainers":[{"name":"sanar","email":"ti@editorasanar.com.br"}],"description":"A React Native port of react-native-highlight-words. This component is used to highlight words within a larger body of text.","homepage":"https://github.com/sanar/react-native-highlight-text","keywords":["react-native","react","reactjs","react-component","highlighter","highlight","text","words","matches","substring","occurrences","search"],"repository":{"type":"git","url":"git+https://github.com/sanar/react-native-highlight-text.git"},"author":{"name":"Sanar Tech"},"bugs":{"url":"https://github.com/sanar/react-native-highlight-text/issues"},"license":"MIT","readme":"# React Native Highlight Text\n\nReact Native component used to highlight words within a larger body of text. This is a port of [react-native-highlight-words](https://github.com/clauderic/react-native-highlight-words).\n\n## Installation\n\nWith npm:\n\n```\nnpm i --save @sanar/react-native-highlight-text\n```\n\nWith yarn:\n\n```\nyarn add @sanar/react-native-highlight-text\n```\n\n## Usage\n\nTo use it, just provide it with an array of search terms and a body of text to highlight:\n\n```jsx\nimport HighlightText from '@sanar/react-native-highlight-text';\n\n<HighlightText\n  highlightStyle={{ backgroundColor: 'yellow' }}\n  searchWords={['and', 'or', 'the']}\n  textToHighlight=\"The dog is chasing the cat. Or perhaps they're just playing?\"\n/>;\n```\n\nAnd the `HighlightText` component will highlight all occurrences of search terms within the text:\n\n<img width=\"368\" alt=\"screen shot 2015-12-19 at 8 23 43 am\" src=\"https://cloud.githubusercontent.com/assets/29597/11914033/e3c319f6-a629-11e5-896d-1a5ce22c9ea2.png\">\n\n## Props\n\nYou can pass all Text style props like `style` to the Text component that is used as a wrapper.\n\n| Property           | Type          | Required? | Description                                                                                                                                         |\n| :----------------- | :------------ | :-------: | :-------------------------------------------------------------------------------------------------------------------------------------------------- |\n| searchWords        | Array<String> |     ✓     | Array of search words                                                                                                                               |\n| textToHighlight    | String        |     ✓     | Text to highlight matches in                                                                                                                        |\n| autoEscape         | Boolean       |           | Escape characters which are meaningful in regular expressions; defaults to false                                                                    |\n| caseSensitive      | Boolean       |           | Search should be case sensitive; defaults to false                                                                                                  |\n| sanitize           | Function      |           | Process each search word and text to highlight before comparing (eg remove accents); signature `(text: string): string`; defaults to undefined      |\n| highlightStyle     | Object        |           | Styles applied to highlighted text; defaults to undefined                                                                                           |\n| textComponent      | Component     |           | Custom Text component to use instead of the default Text from React Native for the text. Should be TextProps compatible; defaults to undefined      |\n| highlightComponent | Component     |           | Custom Text component to use instead of the default Text from React Native for the highlight. Should be TextProps compatible; defaults to undefined |\n\n## License\n\n[MIT License](LICENSE)\n","readmeFilename":"README.md"}