{"_id":"@alirehman7141/chatwoot-react-native-widget","_rev":"4-e4a6d57c107105fc20d884f91bf96144","name":"@alirehman7141/chatwoot-react-native-widget","dist-tags":{"latest":"0.1.3"},"versions":{"0.1.0":{"name":"@alirehman7141/chatwoot-react-native-widget","version":"0.1.0","keywords":["react-native","chatwoot","mobile","ios","android"],"license":"MIT","_id":"@alirehman7141/chatwoot-react-native-widget@0.1.0","maintainers":[{"name":"alirehman7141","email":"ali.rehman7141@gmail.com"}],"homepage":"https://github.com/chatwoot/chatwoot-react-native-widget#readme","bugs":{"url":"https://github.com/chatwoot/chatwoot-react-native-widget/issues"},"dist":{"shasum":"0b8b447ce53074a79c1b4252a1a414325f241a7b","tarball":"https://registry.npmjs.org/@alirehman7141/chatwoot-react-native-widget/-/chatwoot-react-native-widget-0.1.0.tgz","fileCount":12,"integrity":"sha512-bd5FV8vZyAkzOAmzFPp/BpouW24Q36eLcpTBb6nFI9MmRX2eIAbJ/4MmeYesy7++nxm+p5kouYytKAYC6h6Lkw==","signatures":[{"sig":"MEQCICGPkK/YP+AE2dVK2aSZ6mlzNdwPlO1/yLPnXVnYPpUuAiAhEl1iCo3gC5qNP9HYF/bxXvbe/G2lQSMlldybrfenMQ==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":18487},"main":"index.js","husky":{"hooks":{"pre-commit":"lint-staged"}},"types":"./index.d.ts","gitHead":"6a9c0fc2b166ba11cc78a90c83aa4e8fa93b624e","scripts":{"lint":"eslint .","test":"echo \"Error: no test specified\" && exit 1"},"_npmUser":{"name":"alirehman7141","email":"ali.rehman7141@gmail.com"},"repository":{"url":"git+https://github.com/chatwoot/chatwoot-react-native-widget.git","type":"git"},"_npmVersion":"10.1.0","description":"React Native widget for Chatwoot","directories":{},"lint-staged":{"*.js":["prettier --write","eslint --fix","git add"]},"_nodeVersion":"20.9.0","dependencies":{"react-native-modal":"^13.0.1"},"_hasShrinkwrap":false,"devDependencies":{"husky":"^5.1.3","eslint":"^7.21.0","prettier":"^2.2.1","lint-staged":"^10.5.4","eslint-plugin-prettier":"^3.3.1","metro-react-native-babel-preset":"^0.65.2","@react-native-community/eslint-config":"^2.0.0","@react-native-community/eslint-plugin":"^1.1.0"},"peerDependencies":{"react":"*","react-native":"*","react-native-webview":"^11.2.3","@react-native-async-storage/async-storage":"^1.14.1"},"_npmOperationalInternal":{"tmp":"tmp/chatwoot-react-native-widget_0.1.0_1722515533734_0.9831196357449647","host":"s3://npm-registry-packages"}},"0.1.1":{"name":"@alirehman7141/chatwoot-react-native-widget","version":"0.1.1","keywords":["react-native","chatwoot","mobile","ios","android"],"license":"MIT","_id":"@alirehman7141/chatwoot-react-native-widget@0.1.1","maintainers":[{"name":"alirehman7141","email":"ali.rehman7141@gmail.com"}],"homepage":"https://github.com/AliRehman7141/chatwoot-react-native-widget#readme","bugs":{"url":"https://github.com/AliRehman7141/chatwoot-react-native-widget/issues"},"dist":{"shasum":"ccf4ab3baff5b24ea8e7b319dd291f48f24c11fd","tarball":"https://registry.npmjs.org/@alirehman7141/chatwoot-react-native-widget/-/chatwoot-react-native-widget-0.1.1.tgz","fileCount":12,"integrity":"sha512-ZW1UwO0HKP1uTXy2ugGCPPphXt7C4/hUwT8+tKxzjZaafCltajwEElrB6ZBAXVeW5bEZqrdIQTdnpGP7OZ231A==","signatures":[{"sig":"MEQCIC3VmBpB0AdpSFHW0QBKqle2kcfwpYKyzBHH7NnNpp++AiAUVkM3v9EUDdf23nHLt2kLCrWajpPinkjL8WmU6LGapA==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":18488},"main":"index.js","husky":{"hooks":{"pre-commit":"lint-staged"}},"types":"./index.d.ts","gitHead":"85f9dedc994165b7f2e19a7300c3c99e517548bd","scripts":{"lint":"eslint .","test":"echo \"Error: no test specified\" && exit 1"},"_npmUser":{"name":"alirehman7141","email":"ali.rehman7141@gmail.com"},"repository":{"url":"git+https://github.com/AliRehman7141/chatwoot-react-native-widget.git","type":"git"},"_npmVersion":"10.1.0","description":"React Native widget for Chatwoot","directories":{},"lint-staged":{"*.js":["prettier --write","eslint --fix","git add"]},"_nodeVersion":"20.9.0","dependencies":{"react-native-modal":"^13.0.1"},"_hasShrinkwrap":false,"devDependencies":{"husky":"^5.1.3","eslint":"^7.21.0","prettier":"^2.2.1","lint-staged":"^10.5.4","eslint-plugin-prettier":"^3.3.1","metro-react-native-babel-preset":"^0.65.2","@react-native-community/eslint-config":"^2.0.0","@react-native-community/eslint-plugin":"^1.1.0"},"peerDependencies":{"react":"*","react-native":"*","react-native-webview":"^11.2.3","@react-native-async-storage/async-storage":"^1.14.1"},"_npmOperationalInternal":{"tmp":"tmp/chatwoot-react-native-widget_0.1.1_1722515938117_0.1572930013853504","host":"s3://npm-registry-packages"}},"0.1.2":{"name":"@alirehman7141/chatwoot-react-native-widget","version":"0.1.2","keywords":["react-native","chatwoot","mobile","ios","android"],"license":"MIT","_id":"@alirehman7141/chatwoot-react-native-widget@0.1.2","maintainers":[{"name":"alirehman7141","email":"ali.rehman7141@gmail.com"}],"homepage":"https://github.com/AliRehman7141/chatwoot-react-native-widget#readme","bugs":{"url":"https://github.com/AliRehman7141/chatwoot-react-native-widget/issues"},"dist":{"shasum":"18080266be8254d07bd8b7d133d67655518e8f9e","tarball":"https://registry.npmjs.org/@alirehman7141/chatwoot-react-native-widget/-/chatwoot-react-native-widget-0.1.2.tgz","fileCount":12,"integrity":"sha512-kLLG4i2vDS3nJE4rv/pjwYUSXPnPtxUcnfk+rI5ayDmFEUXb+Sb2ArumUuqH9dpbEanpTDJ23Z8qIibeoKKoCw==","signatures":[{"sig":"MEUCIQCiYiY55PXc/oiWbOh6sCJhV+mG2ymKdPNrsFBcX3SYggIgc7Gj7qaa9KWo3VQ96zxnDxh7oldM94y9VaM1+x897Y8=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":18494},"main":"index.js","husky":{"hooks":{"pre-commit":"lint-staged"}},"types":"./index.d.ts","gitHead":"719cdc564e704e65e58ff13dae8a0eea0f7b5469","scripts":{"lint":"eslint .","test":"echo \"Error: no test specified\" && exit 1"},"_npmUser":{"name":"alirehman7141","email":"ali.rehman7141@gmail.com"},"repository":{"url":"git+https://github.com/AliRehman7141/chatwoot-react-native-widget.git","type":"git"},"_npmVersion":"10.1.0","description":"React Native widget for Chatwoot","directories":{},"lint-staged":{"*.js":["prettier --write","eslint --fix","git add"]},"_nodeVersion":"20.9.0","dependencies":{"react-native-modal":"^13.0.1"},"_hasShrinkwrap":false,"devDependencies":{"husky":"^5.1.3","eslint":"^7.21.0","prettier":"^2.2.1","lint-staged":"^10.5.4","eslint-plugin-prettier":"^3.3.1","metro-react-native-babel-preset":"^0.65.2","@react-native-community/eslint-config":"^2.0.0","@react-native-community/eslint-plugin":"^1.1.0"},"peerDependencies":{"react":"*","react-native":"*","react-native-webview":"^11.2.3","@react-native-async-storage/async-storage":"^1.14.1"},"_npmOperationalInternal":{"tmp":"tmp/chatwoot-react-native-widget_0.1.2_1722609715251_0.15528962472363883","host":"s3://npm-registry-packages"}},"0.1.3":{"name":"@alirehman7141/chatwoot-react-native-widget","version":"0.1.3","description":"React Native widget for Chatwoot","main":"index.js","scripts":{"lint":"eslint .","test":"echo \"Error: no test specified\" && exit 1"},"dependencies":{"react-native-modal":"^13.0.1"},"peerDependencies":{"@react-native-async-storage/async-storage":"^1.14.1","react":"*","react-native":"*","react-native-webview":"^11.2.3"},"devDependencies":{"@react-native-community/eslint-config":"^2.0.0","@react-native-community/eslint-plugin":"^1.1.0","eslint":"^7.21.0","eslint-plugin-prettier":"^3.3.1","husky":"^5.1.3","lint-staged":"^10.5.4","metro-react-native-babel-preset":"^0.65.2","prettier":"^2.2.1"},"husky":{"hooks":{"pre-commit":"lint-staged"}},"lint-staged":{"*.js":["prettier --write","eslint --fix","git add"]},"repository":{"type":"git","url":"git+https://github.com/AliRehman7141/chatwoot-react-native-widget.git"},"keywords":["react-native","chatwoot","mobile","ios","android"],"bugs":{"url":"https://github.com/AliRehman7141/chatwoot-react-native-widget/issues"},"homepage":"https://github.com/AliRehman7141/chatwoot-react-native-widget#readme","license":"MIT","_id":"@alirehman7141/chatwoot-react-native-widget@0.1.3","gitHead":"719cdc564e704e65e58ff13dae8a0eea0f7b5469","types":"./index.d.ts","_nodeVersion":"22.12.0","_npmVersion":"10.9.0","dist":{"integrity":"sha512-f/spIIvf6UdnuNptyYY2UmumFolretzpcgpL6TsHqyHBKvYtOcDT1EUqSzAlOB38yDi9a4YWoL+AZyZ3xLY9pQ==","shasum":"9ff93a388956fc727a03aaadfaf8a1821916ab87","tarball":"https://registry.npmjs.org/@alirehman7141/chatwoot-react-native-widget/-/chatwoot-react-native-widget-0.1.3.tgz","fileCount":13,"unpackedSize":24978,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQDyPVaz09Mcosnsm968r/MHTY8JOm5IYE0kEtFUGgIdHAIhAP2H7ccucPy3tYNOl8ANP/GxYrnhG5vRIGOpl+p6FuMF"}]},"_npmUser":{"name":"alirehman7141","email":"ali.rehman7141@gmail.com"},"directories":{},"maintainers":[{"name":"alirehman7141","email":"ali.rehman7141@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/chatwoot-react-native-widget_0.1.3_1768308089327_0.47729310988809126"},"_hasShrinkwrap":false}},"time":{"created":"2024-08-01T12:32:13.629Z","modified":"2026-01-13T12:41:29.714Z","0.1.0":"2024-08-01T12:32:13.869Z","0.1.1":"2024-08-01T12:38:58.305Z","0.1.2":"2024-08-02T14:41:55.425Z","0.1.3":"2026-01-13T12:41:29.479Z"},"bugs":{"url":"https://github.com/AliRehman7141/chatwoot-react-native-widget/issues"},"license":"MIT","homepage":"https://github.com/AliRehman7141/chatwoot-react-native-widget#readme","keywords":["react-native","chatwoot","mobile","ios","android"],"repository":{"type":"git","url":"git+https://github.com/AliRehman7141/chatwoot-react-native-widget.git"},"description":"React Native widget for Chatwoot","maintainers":[{"name":"alirehman7141","email":"ali.rehman7141@gmail.com"}],"readme":"<h1>\nchatwoot-react-native-widget\n</h1>\n\n![](https://img.shields.io/npm/v/@alirehman7141/chatwoot-react-native-widget?style=flat)\n![](https://img.shields.io/npm/dt/@alirehman7141/chatwoot-react-native-widget.svg)\n[![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg)](http://makeapullrequest.com)\n![](https://img.shields.io/npm/l/@alirehman7141/chatwoot-react-native-widget)\n\n- **Supported Chatwoot version:** 2.16.0+\n\n<img src=\"https://user-images.githubusercontent.com/12408980/203909820-938136a6-bf5b-433e-9f68-d7f28a1303be.png\" alt=\"screenshot\" width=\"350\">\n\n### Installation\n\nInstall the library using either yarn or npm like so:\n\n```sh\nyarn add @alirehman7141/chatwoot-react-native-widget\n```\n\nOR\n\n```sh\nnpm install --save @alirehman7141/chatwoot-react-native-widget\n```\n\nThis library depends on [react-native-webview](https://www.npmjs.com/package/react-native-webview) and [async-storage](https://github.com/react-native-async-storage/async-storage). Please follow the instructions provided in the docs.\n\n### iOS Installation\n\nIf you're using React Native versions > 60.0, it's relatively straightforward.\n\n```sh\ncd ios && pod install\n```\n\n### How to use\n\n1. Create a website channel in chatwoot server by following the steps described here https://www.chatwoot.com/docs/channels/website\n2. Replace `websiteToken` prop and `baseUrl`\n\n```\n\nimport React, { useState } from 'react';\n\nimport { StyleSheet, View, SafeAreaView, TouchableOpacity, Text } from 'react-native';\n\nimport ChatWootWidget from '@alirehman7141/chatwoot-react-native-widget';\n\nconst App = () => {\n  const [showWidget, toggleWidget] = useState(false);\n  const user = {\n    identifier: 'john@gmail.com',\n    name: 'John Samuel',\n    avatar_url: '',\n    email: 'john@gmail.com',\n    identifier_hash: '',\n  };\n  const customAttributes = { accountId: 1, pricingPlan: 'paid', status: 'active' };\n  const websiteToken = 'WEBSITE_TOKEN';\n  const baseUrl = 'CHATWOOT_INSTALLATION_URL';\n  const locale = 'en';\n  const colorScheme='dark'\n\n  return (\n    <SafeAreaView style={styles.container}>\n      <View>\n        <TouchableOpacity style={styles.button} onPress={() => toggleWidget(true)}>\n          <Text style={styles.buttonText}>Open widget</Text>\n        </TouchableOpacity>\n      </View>\n      {\n        showWidget&&\n          <ChatWootWidget\n            websiteToken={websiteToken}\n            locale={locale}\n            baseUrl={baseUrl}\n            closeModal={() => toggleWidget(false)}\n            isModalVisible={showWidget}\n            user={user}\n            customAttributes={customAttributes}\n            colorScheme={colorScheme}\n          />\n      }\n\n    </SafeAreaView>\n  );\n};\n\nconst styles = StyleSheet.create({\n  container: {\n    flex: 1,\n    justifyContent: 'center',\n    alignItems: 'center',\n  },\n\n  button: {\n    height: 48,\n    marginTop: 32,\n    paddingTop: 8,\n    paddingBottom: 8,\n    backgroundColor: '#1F93FF',\n    borderRadius: 8,\n    borderWidth: 1,\n    borderColor: '#fff',\n    justifyContent: 'center',\n  },\n  buttonText: {\n    color: '#fff',\n    textAlign: 'center',\n    paddingLeft: 10,\n    fontWeight: '600',\n    fontSize: 16,\n    paddingRight: 10,\n  },\n});\n\nexport default App;\n\n```\n\nYou're done!\n\nThe whole example is in the `/example` folder.\n\n### Props\n\n<table class=\"table\">\n<thead><tr>\n  <th>Name</th><th>Default</th><th>Type</th><th>Description</th>\n</tr></thead>\n<tbody>\n  <tr>\n    <td>baseUrl</td>\n    <td> - </td>\n    <td> String </td>\n    <td>Chatwoot installation URL</td>\n  </tr>\n <tr>\n    <td>websiteToken</td>\n    <td> - </td>\n    <td> String </td>\n    <td>Website channel token</td>\n  </tr>\n  <tr>\n    <td>colorScheme</td>\n    <td> light </td>\n    <td> String </td>\n    <td>Widget color scheme (light/dark/auto)</td>\n  </tr>\n   <tr>\n    <td>locale</td>\n    <td> en </td>\n    <td> String </td>\n    <td>Locale</td>\n  </tr>\n  <tr>\n    <td>isModalVisible</td>\n    <td> false </td>\n    <td> Boolean </td>\n    <td>Widget is visible or not</td>\n  </tr>\n    <tr>\n    <td>closeModal</td>\n    <td> - </td>\n    <td> Function </td>\n    <td>Close event</td>\n  </tr>\n  <tr>\n\t  <td>user</td>\n    <td> {} </td>\n    <td> Object </td>\n    <td>User information about the user like email, username and avatar_url</td>\n  </tr>\n  <tr>\n   <td>customAttributes</td>\n    <td> {} </td>\n    <td> Object </td>\n    <td>Additional information about the customer</td>\n  </tr>\n </tbody>\n</table>\n\n## Feedback & Contributing\n\nFeel free to send us feedback on [Twitter](https://twitter.com/chatwootapp) or [file an issue](https://github.com/chatwoot/chatwoot-mobile-app/issues).\n\nIf there's anything you'd like to chat about, please feel free to join our [Discord](https://discord.gg/cJXdrwS) chat!\n\n_Chatwoot_ &copy; 2017-2023, Chatwoot Inc - Released under the MIT License.\n","readmeFilename":"README.md"}