{"id":4260,"url":"https://github.com/martincik/react-native-actionsheet-native","last_synced_at":"2025-10-01T13:10:45.200Z","repository":{"id":57335030,"uuid":"53805118","full_name":"martincik/react-native-actionsheet-native","owner":"martincik","description":"React Native ActionSheet Android extension","archived":false,"fork":false,"pushed_at":"2017-10-10T06:01:18.000Z","size":60,"stargazers_count":25,"open_issues_count":5,"forks_count":12,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-07-22T03:21:11.802Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Java","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/martincik.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":"2016-03-13T20:08:05.000Z","updated_at":"2025-05-25T00:33:54.000Z","dependencies_parsed_at":"2022-08-24T20:21:20.451Z","dependency_job_id":null,"html_url":"https://github.com/martincik/react-native-actionsheet-native","commit_stats":null,"previous_names":["slowpath/react-native-actionsheet"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/martincik/react-native-actionsheet-native","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/martincik%2Freact-native-actionsheet-native","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/martincik%2Freact-native-actionsheet-native/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/martincik%2Freact-native-actionsheet-native/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/martincik%2Freact-native-actionsheet-native/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/martincik","download_url":"https://codeload.github.com/martincik/react-native-actionsheet-native/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/martincik%2Freact-native-actionsheet-native/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267527835,"owners_count":24102019,"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","status":"online","status_checked_at":"2025-07-28T02:00:09.689Z","response_time":68,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":[],"created_at":"2024-01-05T20:17:06.139Z","updated_at":"2025-10-01T13:10:40.111Z","avatar_url":"https://github.com/martincik.png","language":"Java","funding_links":[],"categories":["Components"],"sub_categories":["UI"],"readme":"# React Native ActionSheet\n\nReact Native ActionSheet is a JavaScript library for [React Native](https://facebook.github.io/react-native/) that implements AcionSheet for Android. Its equivalent of ActionSheetIOS which is part of React Native.\n\nFor implementation the Android version I used [android-ActionSheet](https://github.com/baoyongzhang/android-ActionSheet).\n\n## Requirements\n\n- React Native \u003e= 0.40.0\n- Android\n\n## Installing React Native ActionSheet\n\n```bash\nnpm install react-native-actionsheet-native --save\n# OR\nyarn add react-native-actionsheet-native\n```\n\n## Preparing\n\n### React native \u003e= 0.40.0\n\nYou can run inside of your project folder the next command:\n\n```bash\nreact-native link react-native-actionsheet-native\n```\n\n### React native \u003e= 0.33.0 AND \u003c 0.40.0\n\n- In `android/setting.gradle`\n\n```gradle\n...\ninclude ':react-native-actionsheet-native', ':app'\nproject(':react-native-actionsheet-native').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-actionsheet-native/android')\n```\n\n- In `android/app/build.gradle`\n\n```gradle\napply plugin: \"com.android.application\"\n...\ndependencies {\n  ...\n  compile project(\":react-native-actionsheet\") // \u003c--- add this\n  ...\n}\n```\n\n- Register Module (in MainActivity.java)\n\n```java\nimport com.slowpath.actionsheet.ActionSheetPackage;  // \u003c--- import and this\n\npublic class MyApplication extends Application implements ReactApplication {\n\n  ......\n\n  @Override\n  protected List\u003cReactPackage\u003e getPackages() {\n    return Arrays.asList(\n      new ActionSheetPackage(), // \u003c------ add this line to you application\n      new MainReactPackage());\n  }\n\n  ......\n\n}\n```\n\n### Updated your MainActivity\n\nNow, you need to update your MainActivity. The MainActivity should extends `ReactFragmentActivity` for working with this library.\n\n```java\npublic class MainActivity extends ReactFragmentActivity {\n  ...\n}\n```\n\n# Usage\n\nFrom your JS files for both iOS and Android:\n\n```javascript\nimport ActionSheet from 'react-native-actionsheet';\n\nActionSheet.showActionSheetWithOptions({\n  options: ['Disconnect', 'Cancel'],\n  cancelButtonIndex: 1\n},\n(buttonIndex) =\u003e {\n  const { dispatch } = this.props;\n  if (buttonIndex === 0) {\n    // Do something.\n  }\n});\n```\n\n# Customization of Android action sheet\n\nIf you want to customize view of Android ActionSheet, you will need to read [this article](https://github.com/baoyongzhang/android-ActionSheet#style)\n\n## License\n\nReact Native ActionSheet is BSD-licensed.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmartincik%2Freact-native-actionsheet-native","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmartincik%2Freact-native-actionsheet-native","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmartincik%2Freact-native-actionsheet-native/lists"}