cardoctor-call-chat 1.0.6 → 1.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -1,5 +1,4 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import React from 'react';
3
2
 
4
3
  interface ChatInitState {
5
4
  user: any | null;
@@ -12,23 +11,11 @@ interface IPros {
12
11
  }
13
12
  declare function useCallChatInit(props: IPros): ChatInitState;
14
13
 
15
- declare const CometChatCompose: ({ group }: {
16
- group: any;
17
- }) => react_jsx_runtime.JSX.Element;
18
-
19
- declare const CometChatHeader: ({ group }: {
20
- group: any;
21
- }) => react_jsx_runtime.JSX.Element;
22
-
23
14
  interface IListGroup {
24
15
  tag?: string[];
25
16
  limit?: number;
26
17
  setSelectGroup: any;
27
18
  }
28
- declare const ListGroup: React.MemoExoticComponent<({ tag, limit, setSelectGroup }: IListGroup) => react_jsx_runtime.JSX.Element>;
29
-
30
- declare const CometChatMessage: ({ group }: {
31
- group: any;
32
- }) => react_jsx_runtime.JSX.Element;
19
+ declare const ListGroup: ({ tag, limit, setSelectGroup }: IListGroup) => react_jsx_runtime.JSX.Element;
33
20
 
34
- export { CometChatCompose, CometChatHeader, CometChatMessage, ListGroup, useCallChatInit };
21
+ export { ListGroup, useCallChatInit };
package/dist/index.d.ts CHANGED
@@ -1,5 +1,4 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import React from 'react';
3
2
 
4
3
  interface ChatInitState {
5
4
  user: any | null;
@@ -12,23 +11,11 @@ interface IPros {
12
11
  }
13
12
  declare function useCallChatInit(props: IPros): ChatInitState;
14
13
 
15
- declare const CometChatCompose: ({ group }: {
16
- group: any;
17
- }) => react_jsx_runtime.JSX.Element;
18
-
19
- declare const CometChatHeader: ({ group }: {
20
- group: any;
21
- }) => react_jsx_runtime.JSX.Element;
22
-
23
14
  interface IListGroup {
24
15
  tag?: string[];
25
16
  limit?: number;
26
17
  setSelectGroup: any;
27
18
  }
28
- declare const ListGroup: React.MemoExoticComponent<({ tag, limit, setSelectGroup }: IListGroup) => react_jsx_runtime.JSX.Element>;
29
-
30
- declare const CometChatMessage: ({ group }: {
31
- group: any;
32
- }) => react_jsx_runtime.JSX.Element;
19
+ declare const ListGroup: ({ tag, limit, setSelectGroup }: IListGroup) => react_jsx_runtime.JSX.Element;
33
20
 
34
- export { CometChatCompose, CometChatHeader, CometChatMessage, ListGroup, useCallChatInit };
21
+ export { ListGroup, useCallChatInit };
package/dist/index.js CHANGED
@@ -9554,9 +9554,6 @@ var require_CometChat = __commonJS({
9554
9554
  // src/index.ts
9555
9555
  var index_exports = {};
9556
9556
  __export(index_exports, {
9557
- CometChatCompose: () => CometChatCompose,
9558
- CometChatHeader: () => CometChatHeader,
9559
- CometChatMessage: () => CometChatMessage,
9560
9557
  ListGroup: () => ListGroup,
9561
9558
  useCallChatInit: () => useCallChatInit
9562
9559
  });
@@ -9640,50 +9637,25 @@ function useCallChatInit(props) {
9640
9637
  return { user, loading };
9641
9638
  }
9642
9639
 
9643
- // src/cometchat/components/compose.tsx
9644
- var import_chat_uikit_react3 = require("@cometchat/chat-uikit-react");
9645
- var import_jsx_runtime = require("react/jsx-runtime");
9646
- var CometChatCompose = ({ group }) => {
9647
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_jsx_runtime.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_chat_uikit_react3.CometChatMessageComposer, { group }) });
9648
- };
9649
-
9650
- // src/cometchat/components/header.tsx
9651
- var import_chat_uikit_react4 = require("@cometchat/chat-uikit-react");
9652
- var import_jsx_runtime2 = require("react/jsx-runtime");
9653
- var CometChatHeader = ({ group }) => {
9654
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_chat_uikit_react4.CometChatMessageHeader, { group });
9655
- };
9656
-
9657
9640
  // src/cometchat/components/list.tsx
9658
- var import_chat_uikit_react5 = require("@cometchat/chat-uikit-react");
9641
+ var import_chat_uikit_react3 = require("@cometchat/chat-uikit-react");
9659
9642
  var import_chat_sdk_javascript = __toESM(require_CometChat());
9660
- var import_react2 = __toESM(require("react"));
9661
- var import_jsx_runtime3 = require("react/jsx-runtime");
9662
- var ListGroup = import_react2.default.memo(({
9643
+ var import_jsx_runtime = require("react/jsx-runtime");
9644
+ var ListGroup = ({
9663
9645
  tag = [],
9664
9646
  limit = 20,
9665
9647
  setSelectGroup
9666
9648
  }) => {
9667
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
9668
- import_chat_uikit_react5.CometChatGroups,
9649
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
9650
+ import_chat_uikit_react3.CometChatGroups,
9669
9651
  {
9670
9652
  groupsRequestBuilder: new import_chat_sdk_javascript.CometChat.GroupsRequestBuilder().setLimit(limit).setTags(tag),
9671
9653
  onItemClick: (e) => setSelectGroup(e)
9672
9654
  }
9673
9655
  );
9674
- });
9675
-
9676
- // src/cometchat/components/message.tsx
9677
- var import_chat_uikit_react6 = require("@cometchat/chat-uikit-react");
9678
- var import_jsx_runtime4 = require("react/jsx-runtime");
9679
- var CometChatMessage = ({ group }) => {
9680
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { className: "h-[800px] scroll-auto overflow-scroll", children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_chat_uikit_react6.CometChatMessageList, { group }) });
9681
9656
  };
9682
9657
  // Annotate the CommonJS export names for ESM import in node:
9683
9658
  0 && (module.exports = {
9684
- CometChatCompose,
9685
- CometChatHeader,
9686
- CometChatMessage,
9687
9659
  ListGroup,
9688
9660
  useCallChatInit
9689
9661
  });
package/dist/index.mjs CHANGED
@@ -9623,49 +9623,24 @@ function useCallChatInit(props) {
9623
9623
  return { user, loading };
9624
9624
  }
9625
9625
 
9626
- // src/cometchat/components/compose.tsx
9627
- import { CometChatMessageComposer } from "@cometchat/chat-uikit-react";
9628
- import { Fragment, jsx } from "react/jsx-runtime";
9629
- var CometChatCompose = ({ group }) => {
9630
- return /* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsx(CometChatMessageComposer, { group }) });
9631
- };
9632
-
9633
- // src/cometchat/components/header.tsx
9634
- import { CometChatMessageHeader } from "@cometchat/chat-uikit-react";
9635
- import { jsx as jsx2 } from "react/jsx-runtime";
9636
- var CometChatHeader = ({ group }) => {
9637
- return /* @__PURE__ */ jsx2(CometChatMessageHeader, { group });
9638
- };
9639
-
9640
9626
  // src/cometchat/components/list.tsx
9641
9627
  var import_chat_sdk_javascript = __toESM(require_CometChat());
9642
9628
  import { CometChatGroups } from "@cometchat/chat-uikit-react";
9643
- import React from "react";
9644
- import { jsx as jsx3 } from "react/jsx-runtime";
9645
- var ListGroup = React.memo(({
9629
+ import { jsx } from "react/jsx-runtime";
9630
+ var ListGroup = ({
9646
9631
  tag = [],
9647
9632
  limit = 20,
9648
9633
  setSelectGroup
9649
9634
  }) => {
9650
- return /* @__PURE__ */ jsx3(
9635
+ return /* @__PURE__ */ jsx(
9651
9636
  CometChatGroups,
9652
9637
  {
9653
9638
  groupsRequestBuilder: new import_chat_sdk_javascript.CometChat.GroupsRequestBuilder().setLimit(limit).setTags(tag),
9654
9639
  onItemClick: (e) => setSelectGroup(e)
9655
9640
  }
9656
9641
  );
9657
- });
9658
-
9659
- // src/cometchat/components/message.tsx
9660
- import { CometChatMessageList } from "@cometchat/chat-uikit-react";
9661
- import { jsx as jsx4 } from "react/jsx-runtime";
9662
- var CometChatMessage = ({ group }) => {
9663
- return /* @__PURE__ */ jsx4("div", { className: "h-[800px] scroll-auto overflow-scroll", children: /* @__PURE__ */ jsx4(CometChatMessageList, { group }) });
9664
9642
  };
9665
9643
  export {
9666
- CometChatCompose,
9667
- CometChatHeader,
9668
- CometChatMessage,
9669
9644
  ListGroup,
9670
9645
  useCallChatInit
9671
9646
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cardoctor-call-chat",
3
- "version": "1.0.6",
3
+ "version": "1.0.8",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "scripts": {
@@ -8,7 +8,7 @@ interface IListGroup {
8
8
  setSelectGroup: any
9
9
  }
10
10
 
11
- export const ListGroup = React.memo(({
11
+ export const ListGroup = ({
12
12
  tag = [],
13
13
  limit = 20,
14
14
  setSelectGroup
@@ -20,4 +20,4 @@ export const ListGroup = React.memo(({
20
20
  }
21
21
  onItemClick={e => setSelectGroup(e)}
22
22
  />
23
- });
23
+ };
package/src/index.ts CHANGED
@@ -1,2 +1,2 @@
1
1
  export * from "./cometchat/use-call-chat-init";
2
- export * from "./cometchat/components"
2
+ export * from "./cometchat/components/list"