{"id":22579309,"url":"https://github.com/chr314/react-native-lookup-modal","last_synced_at":"2025-04-10T18:16:03.918Z","repository":{"id":34740505,"uuid":"183185371","full_name":"chr314/react-native-lookup-modal","owner":"chr314","description":"React Native Lookup Modal","archived":false,"fork":false,"pushed_at":"2023-07-20T10:41:56.000Z","size":1901,"stargazers_count":2,"open_issues_count":6,"forks_count":3,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-24T15:52:38.636Z","etag":null,"topics":["filter","lookup","modal","popup","react-native","react-native-component","react-native-library","search"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/react-native-lookup-modal","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/chr314.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-04-24T08:34:34.000Z","updated_at":"2023-04-19T17:07:58.000Z","dependencies_parsed_at":"2023-01-15T09:01:25.187Z","dependency_job_id":null,"html_url":"https://github.com/chr314/react-native-lookup-modal","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chr314%2Freact-native-lookup-modal","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chr314%2Freact-native-lookup-modal/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chr314%2Freact-native-lookup-modal/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chr314%2Freact-native-lookup-modal/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/chr314","download_url":"https://codeload.github.com/chr314/react-native-lookup-modal/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248008627,"owners_count":21032556,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["filter","lookup","modal","popup","react-native","react-native-component","react-native-library","search"],"created_at":"2024-12-08T05:06:57.739Z","updated_at":"2025-04-10T18:16:03.888Z","avatar_url":"https://github.com/chr314.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# React Native Lookup Modal\n\nReact Native Lookup Modal\n\n![example gif](https://i.giphy.com/media/YH1etAKUsCplyiMwcr/giphy.webp)\n\n## Install\n\n`yarn add react-native-lookup-modal`\n\nOR\n\n`npm install react-native-lookup-modal --save`\n\n## Usage\n\n```javascript\nimport LookupModal from 'react-native-lookup-modal';\n\nconst users = [\n  {\n    id: 1,\n    name: 'Brit Renfield',\n    tel: '542-866-4301',\n    email: 'brenfield0@gmail.com',\n    country: 'Russia'\n  },\n  {\n    id: 2,\n    name: 'Alfonse Tesche',\n    tel: '436-643-1234',\n    email: 'atesche1@hotmail.com',\n    country: 'Indonesia'\n  },\n  {\n    id: 3,\n    name: 'Chandler Follett',\n    tel: '682-740-8794',\n    email: 'cfollett2@boston.com',\n    country: 'Greece'\n  }\n];\n\nconst [user, setUser] = useState();\n\n\u003cLookupModal\n  data={users}\n  value={user}\n  onSelect={item =\u003e setUser(item)}\n  displayKey={\"name\"}\n/\u003e\n```\n\n## Props\n\n| Prop                    | Description                                             | Type       | Required/Default                         |\n|-------------------------|---------------------------------------------------------|------------|------------------------------------------|\n| `data`                  | Array of Objects                                        | `array`    | Default: `[]`                            |\n| `value`                 | Selected item                                           | `object`   | Optional                                 |\n| `onSelect`              | Fired when an result is selected                        | `function` | `(item) =\u003e {}`                           |\n| `onCancel`              | Fired when modal is closed without selecting any result | `function` | `() =\u003e {}`                               |\n| `displayKey`            | Which property is shown in results                      | `string`   | Default: `title`                         |\n| `selectText`            | Text of select button                                   | `string`   | Default: `Select...`                     |\n| `placeholder`           | Placeholder of TextInput                                | `string`   | Default: `Search...`                     |\n| `searchFunc`            | Custom search function                                  | `function` | Default: `defaultSearchFunc(text, data)` |\n| `selectButtonStyle`     | Custom select button style                              | `object`   | Optional                                 |\n| `selectButtonTextStyle` | Custom select button text style                         | `object`   | Optional                                 |\n| `hideSelectButton`      | Hide select button                                      | `bool`     | Default: `false`                         |\n| `children`              | Custom select button                                    | `element`  | Optional                                 |\n| `contentStyle`          | Custom modal content style                              | `object`   | Optional                                 |\n| `itemStyle`             | Custom item style                                       | `object`   | Optional                                 |\n| `itemTextStyle`         | Custom item text style                                  | `object`   | Optional                                 |\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchr314%2Freact-native-lookup-modal","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fchr314%2Freact-native-lookup-modal","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchr314%2Freact-native-lookup-modal/lists"}