Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@tcn/omni-chat-client

Package Overview
Dependencies
Maintainers
6
Versions
51
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@tcn/omni-chat-client

A react native component for TCN's omni chat client

  • 8.2.8
  • latest
  • npm
  • Socket score

Version published
Maintainers
6
Created
Source

@tcn/omni-chat-client

A react native component for TCN's omni chat client

Installation

Install the module in your project with:

yarn add @tcn/omni-chat-client

Also be sure to install the safe area context peer dependency (see package.json).

Configure and render the chat client component

Import the OmniChatClient component from the library.

In the config prop, pass an object with properties for an API key, url, and some CSS colors, as shown in the example snippet below.

Also be sure to place the OmniChatClient component somewhere within a SafeAreaProvider component from react-native-safe-area-context .

import { OmniChatClient } from "@tcn/omni-chat-client";
import {
  // ...
  KeyboardAvoidingView,
  // ...
} from "react-native";

export function YourComponent() {
  // ...
  return (
    // ...
    <SafeAreaProvider>
      {* ... *}
      <OmniChatClient
        config={{
          apiKey:
            "YOUR API KEY HERE - CAN BE FOUND IN OMNIBOSS CAMPAIGN OVERVIEW",
          url: "YOUR URL - CAN BE FOUND IN OMNIBOSS CAMPAIGN OVERVIEW",
          mainColor: "YOUR COLORS HERE",
          headingColor: "YOUR COLORS HERE",
          paragraphColor: "YOUR COLORS HERE",
        }}
      />
    </SafeAreaProvider>
    // ...
  );
}

Z Stack Positioning

You can optionally pass a zIndex prop to the OmniChatClient component to set the z-index of the chat client component. This is useful if the default value doesn't place the component in the correct z position for your app.

<OmniChatClient
  config={{
    // …
  }}
  zIndex={100}
/>

Deployment

Staging
  • Create feature branch with your version title release/7.5.x for example
  • Run pipeline, deploy-staging job will run
Production
  • Merge feature branch to master
  • Tag the new version, pipeline will deploy to production

FAQ

Why is the chat client component cut off when the keyboard is open?

Be sure to use adjustResize for the windowSoftInputMode in your Android Manifest file (or in app.json - expo.android.softwareKeyboardLayoutMode - if using Expo).

Contributing

There is currently no way for someone to contribute to this project, nor is there any issue tracking publicly.

FAQs

Package last updated on 11 Jun 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc