{"id":20078111,"url":"https://github.com/quickblox/react-ui-kit","last_synced_at":"2025-07-05T03:01:56.582Z","repository":{"id":165902588,"uuid":"637749620","full_name":"QuickBlox/react-ui-kit","owner":"QuickBlox","description":null,"archived":false,"fork":false,"pushed_at":"2024-06-13T15:26:01.000Z","size":8317,"stargazers_count":6,"open_issues_count":15,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-06-13T18:16:30.427Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://quickblox.github.io/react-ui-kit/","language":"JavaScript","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/QuickBlox.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-05-08T10:29:44.000Z","updated_at":"2024-06-13T15:21:49.000Z","dependencies_parsed_at":"2023-10-11T11:37:04.050Z","dependency_job_id":"e47afa91-caef-462b-a196-7e7c5b9e2aea","html_url":"https://github.com/QuickBlox/react-ui-kit","commit_stats":null,"previous_names":[],"tags_count":32,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/QuickBlox%2Freact-ui-kit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/QuickBlox%2Freact-ui-kit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/QuickBlox%2Freact-ui-kit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/QuickBlox%2Freact-ui-kit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/QuickBlox","download_url":"https://codeload.github.com/QuickBlox/react-ui-kit/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":224470923,"owners_count":17316710,"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":[],"created_at":"2024-11-13T15:12:53.269Z","updated_at":"2024-11-13T15:12:53.832Z","avatar_url":"https://github.com/QuickBlox.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n\n\u003cp\u003e\n\t\t\u003ca href=\"https://discord.gg/c6bxq9BC\"\u003e\u003cimg src=\"https://img.shields.io/discord/1042743094833065985?color=5865F2\u0026logo=discord\u0026logoColor=white\u0026label=QuickBlox%20Discord%20server\u0026style=for-the-badge\" alt=\"Discord server\" /\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n\u003c/div\u003e\n\n# Overview\n\nThe QuickBlox UIKit for React is a comprehensive user interface kit specifically designed for building chat applications. It provides a collection of pre-built components, modules, and utilities that simplify the process of creating chat applications.\n\nThe main goal of the QuickBlox UIKit for React is to offer developers a streamlined and efficient way to implement chat functionality within their React applications.\n\nThe QuickBlox UIKit for React offers modules that encapsulate complex chat functionalities, such as dialogs and chat management and real-time updates. These modules provide a simplified interface for integrating chat features into applications without the need for extensive knowledge of the underlying protocols or server-side infrastructure.\n\nYou can view and interact with the interface components of the UI Kit using Storybook. In fact, this provides an interactive environment showcasing different scenarios that UI components might encounter in a live application. To view these, visit our [documentation](https://quickblox.github.io/react-ui-kit/).\n\n# Screenshots\n\nChat dashboard with list of dialogs and create new chat dialog;\n\n   ![dashboard!](./src/Presentation/assets/img/web-doc.png \"chats dashboard\")\n\n## Features\n\nQuickBlox UIKit for React provides next functionality:\n- List of dialogs\n- Create dialog(Private or Group)\n- Dialog screen\n- Send text, image, video, audio, file messages\n- Dialog info screen\n- List, invite, remove members\n\n# Send your first message\n\nThe QuickBlox UIKit for React comprises a collection of pre-assembled UI components that enable effortless creation of an in-app chat equipped with all the necessary messaging functionalities. Our development kit encompasses light and dark themes, colors, and various other features. These components can be personalized to fashion an engaging messaging interface that reflects your brand's distinct identity.\n\nThe QuickBlox UIKit fully supports both private and group dialogs. To initiate the process of sending a message from the ground up using Java or Kotlin, please refer to the instructions provided in the guide below.\n[Additional information with sample](https://docs.quickblox.com/docs/react-uikit-send-your-first-message)\n## Requirements\n\nThe minimum requirements for QuickBlox UIKit for React are:\n- JS QuickBlox SDK v2.16.4\n- React v.18.0\n- TypeScript v.4.9.3\n\n# Before you begin\n\nRegister a new account following [this link](https://admin.quickblox.com/signup). Type in your email and password to sign in. You can also sign in with your Google or Github accounts.\nCreate the app clicking New app button.\nConfigure the app. Type in the information about your organization into corresponding fields and click Add button.\nGo to Dashboard =\u003e YOUR_APP =\u003e Overview section and copy your Application ID, Authorization Key, Authorization Secret, and Account Key .\n\n## Install QuickBlox SDK\n\n```\nnpm install quickblox\n```\n\n## Install QuickBlox UIKit\n\n```\nnpm install quickblox-react-ui-kit\n```\n\n## Init QuickBlox SDK\n\nTo init QuickBlox SDK you need to pass Application ID, Authorization Key, Authorization Secret, and Account Key to the init() method.\n\n```\nvar APPLICATION_ID = 41;\nvar AUTH_KEY = \"lkjdueksu7392kj\";\nvar AUTH_SECRET = \"iiohfdija792hj\";\nvar ACCOUNT_KEY = \"sdjfnksnlk2bk1k34kb\";\nvar CONFIG = { debug: true };\n\nQB.init(APPLICATION_ID, AUTH_KEY, AUTH_SECRET, ACCOUNT_KEY, CONFIG);\n```\n\n## Authentication\n\nBefore sending your first message you need to authenticate users in the QuickBlox system. You can read more about different ways of authentication by [this link](https://docs.quickblox.com/docs/js-authentication).\nIn our example we show how to authenticate user with login and password.\n\n```\nimport * as QB from \"quickblox/quickblox\";\nimport {\n  QuickBloxUIKitProvider,\n  qbDataContext,\n  QuickBloxUIKitDesktopLayout, \n  LoginData,\n  AuthorizationData,\n  QBDataContextType,\n} from 'quickblox-ui-kit-react/dist/index-ui';\n\nvar params = { login: \"garry\", password: \"garry5santos\" };\n\nQB.login(params, function(error, result) {\n  if(error){\n  } else {\n    // Navigate User to the UIKit\n});\n\nconst qbUIKitContext: QBDataContextType = React.useContext(qbDataContext);\n```\nTo order to config quickblox ui kit provider if you use SDK without session token:\n```\n \u003cQuickBloxUIKitProvider\n            maxFileSize={100 * 1000000} //set max size for attachments\n            accountData={{ ...QBConfig.credentials }}\n            loginData={{\n              login: params.login,\n              password: params.password,\n            }}\n        \u003e\n  \u003cQuickBloxUIKitDesktopLayout /\u003e // container for DesktopLayout\n\u003c/QuickBloxUIKitProvider\u003e\n```\nTo order to config quickblox ui kit provider if you use SDK with session token:\n```\n \u003cQuickBloxUIKitProvider\n            maxFileSize={100 * 1000000} //set max size for attachments\n            accountData={{ ...QBConfig.credentials }} // sessionToken was used in QBConfig\n        \u003e\n  \u003cQuickBloxUIKitDesktopLayout /\u003e // container for DesktopLayout\n\u003c/QuickBloxUIKitProvider\u003e\n```\n\n# Customization\n\nThe QuickBlox UIKit for React allows you to create your own unique view of the UIKit.\n\n## Default themes\nThe QuickBlox UIKit for React has 2 built in themes: Dark and Light.\nDefault theme for UIKit is Light.\nTo set theme you need to set value 'dark' to key data-theme in global styles (html[data-theme=\"dark”]).\nFor example, you can use pure JavaScript:\n\n```\ndocument.documentElement.setAttribute('data-theme', 'dark');\n```\n\n## Use your own theme\n\nThere are two options how you can create your own theme:\n- Customize current theme using css\n- Create your own theme to customize selected components\n\nTo customize the current theme you just need to set the new colors in css variables.\n\nOr you can create your own theme. To do this you need to create a new class that implements the UiKitTheme interface.\n\nTo use your own theme using css you need to create _theme_colors_scheme.scss and set colors\n```\n$background-overlay-light: rgba(19, 29, 40, .80);\n$background-overlay-dark: rgba(144, 151, 159, .80);\n$primary-50: #E7EFFF;\n$primary-100: #C4D7FE;\n$primary-200: #9CBCFE;\n$primary-300: #74A1FD;\n$primary-400: #578CFC;\n$primary-500: #3978FC;\n$primary-600: #3370FC;\n$primary-700: #2C65FB;\n$primary-800: #245BFB;\n$primary-900: #1748FA;\n$primary-a-100: #FFFFFF;\n$primary-a-200: #F7F9FF;\n$primary-a-400: #C4CFFF;\n$primary-a-700: #ABBAFF;\n$secondary-50: #E4E6E8;\n$secondary-100: #BCC1C5;\n$secondary-200: #90979F;\n$secondary-300: #636D78;\n$secondary-400: #414E5B;\n$secondary-500: #202F3E;\n$secondary-600: #1C2A38;\n$secondary-700: #182330;\n$secondary-800: #131D28;\n$secondary-900: #0B121B;\n$secondary-a-100: #74A1FD;\n$secondary-a-200: #3978FC;\n$secondary-a-400: #245BFB;\n$secondary-a-700: #0050DC;\n$system-green-100: #C8F1D6;\n$system-green-200: #A4E7BB;\n$system-green-300: #80DDA0;\n$system-green-400: #64D68B;\n$system-green-500: #49CF77;\n$error-100: #FFC4C1;\n$error-200: #FF9D98;\n$error-300: #FF766E;\n$error-400: #FF584F;\n$error-500: #FF3B30;\n$information: #FDB0FF;\n$highlight: #FFFDC1;\n\n```\nTo use your own new theme colors create _theme_dark.scss and _theme_light.scss files and set color variable.\n```\n// _theme_dark.scss:\n\nhtml[data-theme=\"dark\"]{\n  --color-background-info: #{$primary-500};\n  --tertiary-elements: #{$background-overlay-dark};\n  --main-elements: #{$primary-300};\n  --secondary-elements: #{$primary-a-100};\n  --input-elements: #{$secondary-200};\n  --disabled-elements: #{$secondary-300};\n  --field-border: #{$secondary-200};\n  --main-text: #{$primary-a-100};\n  --secondary-text: #{$secondary-200};\n  --caption: #{$secondary-100};\n  --main-background: #{$secondary-500};\n  --secondary-background: #{$secondary-800};\n  --incoming-background: #{$secondary-400};\n  --outgoing-background: #{$primary-500};\n  --dropdown-background: #{$secondary-400};\n  --chat-input: #{$secondary-800};\n  --divider: #{$secondary-400};\n  --error: #{$error-300};\n  --hightlight: #{$highlight};\n}\n\n// _theme_light.scss:\n:root{\n  --color-background-info:#{$primary-100};\n  --tertiary-elements: #{$secondary-300};\n  --main-elements: #{$primary-500};\n  --secondary-elements: #{$secondary-500};\n  --input-elements: #{$secondary-500};\n  --disabled-elements: #{$secondary-100};\n  --field-border: #{$secondary-200};\n  --main-text: #{$secondary-900};\n  --secondary-text: #{$secondary-300};\n  --caption: #{$secondary-200};\n  --main-background: #{$primary-a-100};\n  --secondary-background: #{$primary-a-100};\n  --secondary-background-modal: #{$background-overlay-light};\n  --incoming-background: #{$secondary-50};\n  --outgoing-background: #{$primary-50};\n  --dropdown-background: #{$primary-a-100};\n  --chat-input: #{$primary-a-200};\n  --divider: #{$primary-50};\n  --error: #{$error-500};\n  --hightlight: #{$highlight};\n}\n```\nTo create your own theme to customize selected components you need to create a new class that implements the UiKitTheme interface.\n```\n//DefaultTheme implements UiKitTheme\nexport default class CustomTheme extends DefaultTheme {\n  divider = (): string =\u003e 'var(--divider)';\n  mainText = (): string =\u003e '#FFFFFF';\n  fontFamily = (): string =\u003e 'Roboto';\n  /*\n  The DefaultTheme contains other theme methods :\n  caption = (): string =\u003e 'var(--caption)';\n  chatInput = (): string =\u003e 'var(--chat-input)';\n  disabledElements = (): string =\u003e 'var(--disabled-elements)';\n  dropdownBackground = (): string =\u003e 'var(--dropdown-background)';\n  error = (): string =\u003e 'var(--error)';\n  fieldBorder = (): string =\u003e 'var(--field-border)';\n  hightlight = (): string =\u003e 'var(--hightlight)';\n  incomingBackground = (): string =\u003e 'var(--incoming-background)';\n  inputElements = (): string =\u003e 'var(--input-elements)';\n  mainBackground = (): string =\u003e 'var(--main-background)';\n  mainElements = (): string =\u003e 'var(--main-elements)';\n  outgoingBackground = (): string =\u003e 'var(--outgoing-background)';\n  secondaryBackground = (): string =\u003e 'var(--secondary-background)';\n  secondaryElements = (): string =\u003e 'var(--secondary-elements)';\n  secondaryText = (): string =\u003e 'var(--secondary-text)';\n  */\n}\n```\nand specify selected components:\n- desktop layout container\n```\n\u003cQuickBloxUIKitDesktopLayout theme={new CustomTheme()}\u003e\n```\n- header of dialogs\n```\n\u003cHeaderDialogs title=\"Dialog 2\" theme={new CustomTheme()} /\u003e\n```\n- item of dialogs\n```\n\u003cPreviewDialog\n  theme={{ selected: true, muted: true, colorTheme={new CustomTheme()} }}\n  title=\"Dialog with states\"\n  unreadMessageCount={9}\n  message_date_time_sent=\"5 min ago\"\n/\u003e\n```\n# Sample\nThe source code of the sample is available on GitHub:\nhttps://github.com/QuickBlox/quickblox-javascript-sdk/tree/gh-pages/samples/react-chat-ui-kit-init-sample\nYou can view and interact with the interface components of the UI Kit using Storybook. In fact, this provides an interactive environment showcasing different scenarios that UI components might encounter in a live application. To view these, visit our [documentation](https://quickblox.github.io/react-ui-kit/).\n\n## Video guide \"How to use AI Feature\"\n[Youtube video about AI Assistant](https://youtu.be/BneMtDagOy4)\n# License\n[](#license)\nMIT License [here](https://github.com/QuickBlox/react-ui-kit/blob/main/LICENSE.md).\n\nCopyright © 2023 QuickBlox.\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fquickblox%2Freact-ui-kit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fquickblox%2Freact-ui-kit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fquickblox%2Freact-ui-kit/lists"}