@bikdotai/bik-component-library 0.0.742-beta.82 → 0.0.742-beta.9
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/cjs/components/BikGiftedChat/Bubble/Bubble.js +1 -1
- package/dist/cjs/components/BikGiftedChat/Bubble/types.d.ts +0 -2
- package/dist/cjs/components/BikGiftedChat/GiftedChat/Day.d.ts +0 -1
- package/dist/cjs/components/BikGiftedChat/GiftedChat/Day.js +1 -1
- package/dist/cjs/components/BikGiftedChat/GiftedChat/GiftedChat.js +1 -1
- package/dist/cjs/components/BikGiftedChat/GiftedChat/types.d.ts +1 -1
- package/dist/cjs/components/QueryBuilder/helpers/MetaCustomProcessor.d.ts +1 -1
- package/dist/esm/components/BikGiftedChat/Bubble/Bubble.js +1 -1
- package/dist/esm/components/BikGiftedChat/Bubble/types.d.ts +0 -2
- package/dist/esm/components/BikGiftedChat/GiftedChat/Day.d.ts +0 -1
- package/dist/esm/components/BikGiftedChat/GiftedChat/Day.js +1 -1
- package/dist/esm/components/BikGiftedChat/GiftedChat/GiftedChat.js +1 -1
- package/dist/esm/components/BikGiftedChat/GiftedChat/types.d.ts +1 -1
- package/dist/esm/components/QueryBuilder/helpers/MetaCustomProcessor.d.ts +1 -1
- package/package.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),i=require("react"),n=require("../../../constants/Theme.js"),s=require("../../../hooks/useWindowSize.js"),t=require("../GiftedChat/types.js"),a=require("../GiftedChat/utils.js");function l(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}const r=l=>{var r,o,d,u;const{currentMessage:c,position:v,renderMessageText:g,renderTicks:f,renderTime:m,renderCustomView:
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),i=require("react"),n=require("../../../constants/Theme.js"),s=require("../../../hooks/useWindowSize.js"),t=require("../GiftedChat/types.js"),a=require("../GiftedChat/utils.js");function l(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}const r=l=>{var r,o,d,u;const{currentMessage:c,position:v,renderMessageText:g,renderTicks:f,renderTime:m,renderCustomView:h,isCustomViewBottom:b,isUnsatisfactoryMessageFn:y,messagesGroupedByAiTraceId:j}=l;console.log("sample");const C=s.useWindowSize(),O=c,S=i.useMemo((()=>O.category===a.Constants.ChatActivity.Category.ACTIVITY&&O.activityType===a.Constants.ChatActivity.Type.PRIVATE_NOTE),[O.category,O.activityType]),p=i.useMemo((()=>{const[e,i]=a.isStringifiedArray(null==O?void 0:O.message);return e&&i&&Array.isArray(i)}),[null==O?void 0:O.message]),x=i.useMemo((()=>{var e,i,s;const a={borderRadius:8,minHeight:20,margin:0,flexGrow:C?1:0},l=(null==O?void 0:O.channelId)===t.MESSAGE_CHANNELS.GMAIL||(null==O?void 0:O.channelName)===t.MESSAGE_CHANNELS.GMAIL,r=(null==O?void 0:O.channelId)===t.MESSAGE_CHANNELS.SMTP||(null==O?void 0:O.channelName)===t.MESSAGE_CHANNELS.SMTP;let o={};if("left"===v)o=Object.assign(Object.assign({},C||l||r?{maxWidth:"100%"}:{}),S?{background:(null===(e=null==O?void 0:O.meta)||void 0===e?void 0:e.aiUsed)?"linear-gradient(90deg, #ffe6ee 0%, #fff0e7 100%)":n.COLORS.background.warning.light}:{backgroundColor:(null==O?void 0:O.isPrivateMail)?n.COLORS.background.blue.light:n.COLORS.surface.hovered});else if("right"===v){const e=y&&y({aiTraceId:null===(i=O.eventProperties)||void 0===i?void 0:i.aiTraceId,messagesGroupedByAiTraceId:j});o=Object.assign(Object.assign({backgroundColor:"failed"===O.status||e?n.COLORS.background.negative.light:n.COLORS.background.brandVeryLight},S?{background:(null===(s=null==O?void 0:O.meta)||void 0===s?void 0:s.aiUsed)?"linear-gradient(90deg, #ffe6ee 0%, #fff0e7 100%)":n.COLORS.background.warning.light}:{}),!C&&p?{maxWidth:500}:{})}return Object.assign(Object.assign({},a),o)}),[null==O?void 0:O.channelId,null==O?void 0:O.channelName,null===(r=null==O?void 0:O.meta)||void 0===r?void 0:r.aiUsed,null==O?void 0:O.status,null===(o=null==O?void 0:O.eventProperties)||void 0===o?void 0:o.aiTraceId,v,C,S,p,y,j,null==O?void 0:O.isPrivateMail]),A=i.useCallback((()=>e.jsxs("div",{children:[!b&&(null==h?void 0:h(l)),null==g?void 0:g(l),b&&(null==h?void 0:h(l))]})),[b,h,g,l]);return e.jsx("div",Object.assign({style:{display:"flex",marginTop:6,marginBottom:(null===(u=null===(d=null==c?void 0:c.messageInformation)||void 0===d?void 0:d.reactions)||void 0===u?void 0:u.length)>0?24:6,flexGrow:C?1:0}},{children:e.jsx("div",Object.assign({style:x},{children:e.jsxs("div",{children:[e.jsx("div",Object.assign({id:c.chatActivityId||`message-${c.psqlId}`},{children:A()})),e.jsxs("div",Object.assign({style:{display:"flex",flexDirection:"row",justifyContent:"flex-end",marginLeft:"32px"}},{children:[null==m?void 0:m(l),null==f?void 0:f(c)]}))]})}))}))},o=l(i).default.memo(r);exports.Bubble=o,exports.default=o;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("date-fns"),r=require("react"),a=require("../../../constants/Theme.js"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("date-fns"),r=require("react"),a=require("../../../constants/Theme.js"),s=require("../../TypographyStyle.js");function n(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}const o=n=>{let{createdAt:o,dateFormat:i="D MMMM YY",dateFormatCalendar:l}=n;const d=r.useMemo((()=>{if(null==o)return null;const e=t.startOfDay(new Date);let r;if("number"==typeof o)r=t.startOfDay(new Date(o));else if(o instanceof Date)r=t.startOfDay(o);else{if("string"!=typeof o)return null;r=t.startOfDay(new Date(o))}if(!t.isSameYear(e,r))return t.format(r,"EEEE, d MMMM yy");const a=t.differenceInDays(e,r);return a<1?(null==l?void 0:l.sameDay)?l.sameDay.replace(/\[|\]/g,""):"Today":1===a?"Yesterday":t.format(r,"EEEE, d MMMM yy")}),[o,i,l]);return d?e.jsxs("div",Object.assign({style:{display:"flex",alignItems:"center",justifyContent:"center",margin:"12px 0px 12px 8px"}},{children:[e.jsx("div",{style:{flex:1,height:"1px",backgroundColor:a.COLORS.stroke.primary}}),e.jsx("div",Object.assign({style:{border:`1px solid ${a.COLORS.stroke.primary}`,borderRadius:"16px",padding:"4px 12px"}},{children:e.jsx(s.BodyCaption,Object.assign({style:{color:a.COLORS.content.secondary}},{children:d}))})),e.jsx("div",{style:{flex:1,height:"1px",backgroundColor:a.COLORS.stroke.primary}})]})):null},i=n(r).default.memo(o);exports.Day=i,exports.default=i;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../../../_virtual/_tslib.js"),r=require("react/jsx-runtime"),s=require("react"),t=require("../../../constants/Theme.js"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../../../_virtual/_tslib.js"),r=require("react/jsx-runtime"),s=require("react"),t=require("../../../constants/Theme.js"),n=require("../../../hooks/useWindowSize.js"),i=require("../../TypographyStyle.js"),a=require("./Day.js"),l=require("./messageHelpers.js"),o=require("./scrollHooks.js"),d=require("./types.js"),u=require("./utils.js");function c(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var g=c(s);const v=(c,v)=>{var h;const p=c||{},{messages:b=[],user:f,renderBubble:m,renderAvatar:y,renderDay:j,renderLoading:x,renderChatEmpty:O,listViewProps:S={},renderAvatarOnTop:A=!1,showUserAvatar:C=!1,showAvatarForEveryMessage:M=!1,inverted:T=!1,messageIdGenerator:w,topThreshold:R=u.TOP_THRESHOLD,apptype:_}=p,E=e.__rest(p,["messages","user","renderBubble","renderAvatar","renderDay","renderLoading","renderChatEmpty","listViewProps","renderAvatarOnTop","showUserAvatar","showAvatarForEveryMessage","inverted","messageIdGenerator","topThreshold","apptype"]);console.log(" ---- GiftedChat apptype:",_);const L=n.useWindowSize(),k=s.useRef(null),q=u.normalizeRef(S.ref||v,k),H=s.useRef({isInitialMount:!0,isUserScrolling:!1,isLoadingOldMessages:!1,isAtBottom:!0,hasTriggeredEndReached:!1,lastMessagesLength:null!==(h=null==b?void 0:b.length)&&void 0!==h?h:0,previousScrollHeight:0,previousScrollTop:0,scrollTimeout:null}),I=s.useMemo((()=>b&&0!==b.length?[...b].reverse():[]),[b]),P=o.useScrollToBottom(q,H);s.useImperativeHandle(v,(()=>q.current)),o.useInitialMountScroll(q,H,I.length,P),o.useScrollCleanup(H),o.useRestoreScrollPosition(q,H,I.length),o.useAutoScrollOnNewMessages(q,H,b.length,P),o.useResizeObserverForFirstMessage(null==b?void 0:b[0],H,P,w);const B=o.useScrollHandler(H,S.onEndReached,S.onScroll,R),D=s.useCallback((e=>{var r;return Boolean(e&&f&&(null===(r=e.user)||void 0===r?void 0:r._id)===f._id)}),[f]),F=s.useCallback(((e,r)=>!!C&&(!!M||(!r||r.user._id!==e.user._id))),[C,M]),N=s.useCallback(((e,s,n)=>{const a=D(e)?"right":"left",l=Object.assign({currentMessage:e,previousMessage:s,nextMessage:n,position:a,user:f},E);return console.log("manifest"===_),m?(console.log("inside render bubble"),m(l)):(console.log("outside render bubble"),r.jsx("div",Object.assign({style:Object.assign(Object.assign({maxWidth:"manifest"===_?"50%":"70%",width:"fit-content"},"manifest"===_?{minWidth:"130px"}:{}),{padding:"8px 12px",borderRadius:"manifest"===_?16:4,border:"left"===a&&"manifest"===_?"1px solid rgb(224, 224, 224)":"none",backgroundColor:"right"===a?"manifest"===_?t.COLORS.background.lightbrand:t.COLORS.background.brandLight:"manifest"===_?t.COLORS.background.white:t.COLORS.background.inactive,color:t.COLORS.content.primary,wordBreak:"break-word"})},{children:r.jsx(i.BodySecondary,{children:e.text})})))}),[D,f,m,E]),G=s.useCallback(((e,r,s)=>{if(!F(e,s))return null;const t=D(e)?"right":"left";return y?y({currentMessage:e,previousMessage:r,nextMessage:s,position:t,user:f,renderAvatarOnTop:A,showUserAvatar:C,showAvatarForEveryMessage:M}):null}),[F,D,f,A,C,M,y]);return b&&0!==b.length?r.jsxs("div",Object.assign({ref:q,style:Object.assign({flex:1,overflowY:"auto",overflowX:"hidden",display:"flex",flexDirection:"column"},S.style),onScroll:B},{children:[r.jsx("div",{style:{flex:"1 0 auto"}}),r.jsx("div",Object.assign({style:{display:"flex",flexDirection:"column",flex:"0 0 auto"}},{children:I.map(((e,s)=>{var t,n,i,o,c;const v=D(e)?"right":"left",h=I[s-1],p=I[s+1],b=!u.isSameDay(e,h),f=l.getMessagePlacement(e,v),m=l.shouldCenterAlign(e),y=(null==e?void 0:e.channelId)===d.MESSAGE_CHANNELS.SMTP||(null==e?void 0:e.channelName)===d.MESSAGE_CHANNELS.SMTP,x=e.category===u.Constants.ChatActivity.Category.ACTIVITY&&e.activityType===u.Constants.ChatActivity.Type.PRIVATE_NOTE;return r.jsxs(g.default.Fragment,{children:[b&&(j?j({createdAt:e.createdAt}):r.jsx(a.Day,{createdAt:e.createdAt})),r.jsxs("div",Object.assign({style:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},L?{margin:"0 4px"}:{}),m?{}:{display:"flex"}),L||2!==(null===(t=null==e?void 0:e.user)||void 0===t?void 0:t._id)?{marginRight:8}:{marginLeft:8}),y&&!x&&L?{marginLeft:8,marginRight:8}:{}),{justifyContent:f,marginBottom:8})},{children:[!L&&"left"===v&&r.jsx("div",Object.assign({style:{margin:"0 8px"}},{children:G(e,h,p)})),r.jsx("div",Object.assign({id:`message-bubble-${null!==(n=e._id)&&void 0!==n?n:`${s}-${null!==(i=null==w?void 0:w())&&void 0!==i?i:"id"}`}`,style:L&&y?{display:"flex",flexGrow:1}:{}},{children:N(e,h,p)})),!L&&"right"===v&&r.jsx("div",Object.assign({style:{margin:"0 8px"}},{children:G(e,h,p)}))]}))]},null!==(o=e._id)&&void 0!==o?o:`${s}-${null!==(c=null==w?void 0:w())&&void 0!==c?c:"id"}`)}))}))]})):O?r.jsx(r.Fragment,{children:O()}):null};var h=s.forwardRef(v);exports.default=h;
|
|
@@ -50,7 +50,7 @@ export interface GiftedChatProps<TMessage extends IMessage = IMessage> {
|
|
|
50
50
|
onLongPress?: (context?: any, message?: TMessage) => void;
|
|
51
51
|
onPress?: (context?: any, message?: TMessage) => void;
|
|
52
52
|
messageIdGenerator?: (message?: TMessage) => string;
|
|
53
|
-
|
|
53
|
+
apptype?: string;
|
|
54
54
|
[key: string]: any;
|
|
55
55
|
}
|
|
56
56
|
export interface ScrollState {
|
|
@@ -36,7 +36,7 @@ export declare class MetaCustomProcessor {
|
|
|
36
36
|
value: {
|
|
37
37
|
operator: string;
|
|
38
38
|
dataType: import("../types").QueryBuilderConnectorType;
|
|
39
|
-
value?: string | number |
|
|
39
|
+
value?: string | number | string[] | number[] | Date | Date[] | undefined;
|
|
40
40
|
};
|
|
41
41
|
key: string;
|
|
42
42
|
refresh?: boolean | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsxs as e,jsx as i}from"react/jsx-runtime";import n,{useMemo as t,useCallback as
|
|
1
|
+
import{jsxs as e,jsx as i}from"react/jsx-runtime";import n,{useMemo as t,useCallback as o}from"react";import{COLORS as l}from"../../../constants/Theme.js";import{useWindowSize as a}from"../../../hooks/useWindowSize.js";import{MESSAGE_CHANNELS as r}from"../GiftedChat/types.js";import{Constants as d,isStringifiedArray as s}from"../GiftedChat/utils.js";const c=n=>{var c,u,v,g;const{currentMessage:m,position:f,renderMessageText:h,renderTicks:y,renderTime:b,renderCustomView:p,isCustomViewBottom:T,isUnsatisfactoryMessageFn:j,messagesGroupedByAiTraceId:I}=n;console.log("sample");const x=a(),k=m,A=t((()=>k.category===d.ChatActivity.Category.ACTIVITY&&k.activityType===d.ChatActivity.Type.PRIVATE_NOTE),[k.category,k.activityType]),C=t((()=>{const[e,i]=s(null==k?void 0:k.message);return e&&i&&Array.isArray(i)}),[null==k?void 0:k.message]),O=t((()=>{var e,i,n;const t={borderRadius:8,minHeight:20,margin:0,flexGrow:x?1:0},o=(null==k?void 0:k.channelId)===r.GMAIL||(null==k?void 0:k.channelName)===r.GMAIL,a=(null==k?void 0:k.channelId)===r.SMTP||(null==k?void 0:k.channelName)===r.SMTP;let d={};if("left"===f)d=Object.assign(Object.assign({},x||o||a?{maxWidth:"100%"}:{}),A?{background:(null===(e=null==k?void 0:k.meta)||void 0===e?void 0:e.aiUsed)?"linear-gradient(90deg, #ffe6ee 0%, #fff0e7 100%)":l.background.warning.light}:{backgroundColor:(null==k?void 0:k.isPrivateMail)?l.background.blue.light:l.surface.hovered});else if("right"===f){const e=j&&j({aiTraceId:null===(i=k.eventProperties)||void 0===i?void 0:i.aiTraceId,messagesGroupedByAiTraceId:I});d=Object.assign(Object.assign({backgroundColor:"failed"===k.status||e?l.background.negative.light:l.background.brandVeryLight},A?{background:(null===(n=null==k?void 0:k.meta)||void 0===n?void 0:n.aiUsed)?"linear-gradient(90deg, #ffe6ee 0%, #fff0e7 100%)":l.background.warning.light}:{}),!x&&C?{maxWidth:500}:{})}return Object.assign(Object.assign({},t),d)}),[null==k?void 0:k.channelId,null==k?void 0:k.channelName,null===(c=null==k?void 0:k.meta)||void 0===c?void 0:c.aiUsed,null==k?void 0:k.status,null===(u=null==k?void 0:k.eventProperties)||void 0===u?void 0:u.aiTraceId,f,x,A,C,j,I,null==k?void 0:k.isPrivateMail]),M=o((()=>e("div",{children:[!T&&(null==p?void 0:p(n)),null==h?void 0:h(n),T&&(null==p?void 0:p(n))]})),[T,p,h,n]);return i("div",Object.assign({style:{display:"flex",marginTop:6,marginBottom:(null===(g=null===(v=null==m?void 0:m.messageInformation)||void 0===v?void 0:v.reactions)||void 0===g?void 0:g.length)>0?24:6,flexGrow:x?1:0}},{children:i("div",Object.assign({style:O},{children:e("div",{children:[i("div",Object.assign({id:m.chatActivityId||`message-${m.psqlId}`},{children:M()})),e("div",Object.assign({style:{display:"flex",flexDirection:"row",justifyContent:"flex-end",marginLeft:"32px"}},{children:[null==b?void 0:b(n),null==y?void 0:y(m)]}))]})}))}))},u=n.memo(c);export{u as Bubble,u as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{jsxs as e,jsx as t}from"react/jsx-runtime";import{startOfDay as r,isSameYear as n,format as o,differenceInDays as a}from"date-fns";import s,{useMemo as i}from"react";import{COLORS as l}from"../../../constants/Theme.js";import{BodyCaption as d}from"../../TypographyStyle.js";const p=s=>{let{createdAt:p,dateFormat:m="D MMMM YY",dateFormatCalendar:y}=s;const c=i((()=>{if(null==p)return null;const e=r(new Date);let t;if("number"==typeof p)t=r(new Date(p));else if(p instanceof Date)t=r(p);else{if("string"!=typeof p)return null;t=r(new Date(p))}if(!n(e,t))return o(t,"EEEE, d MMMM yy");const s=a(e,t);return s<1?(null==y?void 0:y.sameDay)?y.sameDay.replace(/\[|\]/g,""):"Today":1===s?"Yesterday":o(t,"EEEE, d MMMM yy")}),[p,m,y]);return c?e("div",Object.assign({style:{display:"flex",alignItems:"center",justifyContent:"center",margin:"12px 0px 12px 8px"}},{children:[t("div",{style:{flex:1,height:"1px",backgroundColor:l.stroke.primary}}),t("div",Object.assign({style:{border:`1px solid ${l.stroke.primary}`,borderRadius:"16px",padding:"4px 12px"}},{children:t(d,Object.assign({style:{color:l.content.secondary}},{children:c}))})),t("div",{style:{flex:1,height:"1px",backgroundColor:l.stroke.primary}})]})):null},m=s.memo(p);export{m as Day,m as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{__rest as e}from"../../../_virtual/_tslib.js";import{jsx as r,Fragment as t,jsxs as
|
|
1
|
+
import{__rest as e}from"../../../_virtual/_tslib.js";import{jsx as r,Fragment as t,jsxs as s}from"react/jsx-runtime";import i,{forwardRef as n,useRef as o,useMemo as a,useImperativeHandle as l,useCallback as d}from"react";import{COLORS as g}from"../../../constants/Theme.js";import{useWindowSize as c}from"../../../hooks/useWindowSize.js";import{BodySecondary as u}from"../../TypographyStyle.js";import{Day as m}from"./Day.js";import{getMessagePlacement as p,shouldCenterAlign as v}from"./messageHelpers.js";import{useScrollToBottom as h,useInitialMountScroll as f,useScrollCleanup as b,useRestoreScrollPosition as y,useAutoScrollOnNewMessages as j,useResizeObserverForFirstMessage as x,useScrollHandler as O}from"./scrollHooks.js";import{MESSAGE_CHANNELS as A}from"./types.js";import{normalizeRef as T,isSameDay as w,Constants as M,TOP_THRESHOLD as _}from"./utils.js";var k=n(((n,k)=>{var C;const E=n||{},{messages:S=[],user:I,renderBubble:L,renderAvatar:B,renderDay:R,renderLoading:D,renderChatEmpty:P,listViewProps:$={},renderAvatarOnTop:F=!1,showUserAvatar:G=!1,showAvatarForEveryMessage:U=!1,inverted:V=!1,messageIdGenerator:H,topThreshold:W=_,apptype:N}=E,Y=e(E,["messages","user","renderBubble","renderAvatar","renderDay","renderLoading","renderChatEmpty","listViewProps","renderAvatarOnTop","showUserAvatar","showAvatarForEveryMessage","inverted","messageIdGenerator","topThreshold","apptype"]);console.log(" ---- GiftedChat apptype:",N);const z=c(),X=o(null),q=T($.ref||k,X),J=o({isInitialMount:!0,isUserScrolling:!1,isLoadingOldMessages:!1,isAtBottom:!0,hasTriggeredEndReached:!1,lastMessagesLength:null!==(C=null==S?void 0:S.length)&&void 0!==C?C:0,previousScrollHeight:0,previousScrollTop:0,scrollTimeout:null}),K=a((()=>S&&0!==S.length?[...S].reverse():[]),[S]),Q=h(q,J);l(k,(()=>q.current)),f(q,J,K.length,Q),b(J),y(q,J,K.length),j(q,J,S.length,Q),x(null==S?void 0:S[0],J,Q,H);const Z=O(J,$.onEndReached,$.onScroll,W),ee=d((e=>{var r;return Boolean(e&&I&&(null===(r=e.user)||void 0===r?void 0:r._id)===I._id)}),[I]),re=d(((e,r)=>!!G&&(!!U||(!r||r.user._id!==e.user._id))),[G,U]),te=d(((e,t,s)=>{const i=ee(e)?"right":"left",n=Object.assign({currentMessage:e,previousMessage:t,nextMessage:s,position:i,user:I},Y);return console.log("manifest"===N),L?(console.log("inside render bubble"),L(n)):(console.log("outside render bubble"),r("div",Object.assign({style:Object.assign(Object.assign({maxWidth:"manifest"===N?"50%":"70%",width:"fit-content"},"manifest"===N?{minWidth:"130px"}:{}),{padding:"8px 12px",borderRadius:"manifest"===N?16:4,border:"left"===i&&"manifest"===N?"1px solid rgb(224, 224, 224)":"none",backgroundColor:"right"===i?"manifest"===N?g.background.lightbrand:g.background.brandLight:"manifest"===N?g.background.white:g.background.inactive,color:g.content.primary,wordBreak:"break-word"})},{children:r(u,{children:e.text})})))}),[ee,I,L,Y]),se=d(((e,r,t)=>{if(!re(e,t))return null;const s=ee(e)?"right":"left";return B?B({currentMessage:e,previousMessage:r,nextMessage:t,position:s,user:I,renderAvatarOnTop:F,showUserAvatar:G,showAvatarForEveryMessage:U}):null}),[re,ee,I,F,G,U,B]);return S&&0!==S.length?s("div",Object.assign({ref:q,style:Object.assign({flex:1,overflowY:"auto",overflowX:"hidden",display:"flex",flexDirection:"column"},$.style),onScroll:Z},{children:[r("div",{style:{flex:"1 0 auto"}}),r("div",Object.assign({style:{display:"flex",flexDirection:"column",flex:"0 0 auto"}},{children:K.map(((e,t)=>{var n,o,a,l,d;const g=ee(e)?"right":"left",c=K[t-1],u=K[t+1],h=!w(e,c),f=p(e,g),b=v(e),y=(null==e?void 0:e.channelId)===A.SMTP||(null==e?void 0:e.channelName)===A.SMTP,j=e.category===M.ChatActivity.Category.ACTIVITY&&e.activityType===M.ChatActivity.Type.PRIVATE_NOTE;return s(i.Fragment,{children:[h&&(R?R({createdAt:e.createdAt}):r(m,{createdAt:e.createdAt})),s("div",Object.assign({style:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},z?{margin:"0 4px"}:{}),b?{}:{display:"flex"}),z||2!==(null===(n=null==e?void 0:e.user)||void 0===n?void 0:n._id)?{marginRight:8}:{marginLeft:8}),y&&!j&&z?{marginLeft:8,marginRight:8}:{}),{justifyContent:f,marginBottom:8})},{children:[!z&&"left"===g&&r("div",Object.assign({style:{margin:"0 8px"}},{children:se(e,c,u)})),r("div",Object.assign({id:`message-bubble-${null!==(o=e._id)&&void 0!==o?o:`${t}-${null!==(a=null==H?void 0:H())&&void 0!==a?a:"id"}`}`,style:z&&y?{display:"flex",flexGrow:1}:{}},{children:te(e,c,u)})),!z&&"right"===g&&r("div",Object.assign({style:{margin:"0 8px"}},{children:se(e,c,u)}))]}))]},null!==(l=e._id)&&void 0!==l?l:`${t}-${null!==(d=null==H?void 0:H())&&void 0!==d?d:"id"}`)}))}))]})):P?r(t,{children:P()}):null}));export{k as default};
|
|
@@ -50,7 +50,7 @@ export interface GiftedChatProps<TMessage extends IMessage = IMessage> {
|
|
|
50
50
|
onLongPress?: (context?: any, message?: TMessage) => void;
|
|
51
51
|
onPress?: (context?: any, message?: TMessage) => void;
|
|
52
52
|
messageIdGenerator?: (message?: TMessage) => string;
|
|
53
|
-
|
|
53
|
+
apptype?: string;
|
|
54
54
|
[key: string]: any;
|
|
55
55
|
}
|
|
56
56
|
export interface ScrollState {
|
|
@@ -36,7 +36,7 @@ export declare class MetaCustomProcessor {
|
|
|
36
36
|
value: {
|
|
37
37
|
operator: string;
|
|
38
38
|
dataType: import("../types").QueryBuilderConnectorType;
|
|
39
|
-
value?: string | number |
|
|
39
|
+
value?: string | number | string[] | number[] | Date | Date[] | undefined;
|
|
40
40
|
};
|
|
41
41
|
key: string;
|
|
42
42
|
refresh?: boolean | undefined;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bikdotai/bik-component-library",
|
|
3
|
-
"version": "0.0.742-beta.
|
|
3
|
+
"version": "0.0.742-beta.9",
|
|
4
4
|
"description": "Bik Component Library",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -159,10 +159,10 @@
|
|
|
159
159
|
"@emotion/react": "^11.0.0",
|
|
160
160
|
"@emotion/styled": "^11.0.0",
|
|
161
161
|
"date-fns": "^2.29.3",
|
|
162
|
-
"react": "^16.8.0 || ^17 || ^18
|
|
162
|
+
"react": "^16.8.0 || ^17 || ^18",
|
|
163
163
|
"react-calendar": "^3.7.0",
|
|
164
164
|
"react-chips": "^0.8.0",
|
|
165
|
-
"react-dom": "^16.8.0 || ^17 || ^18
|
|
165
|
+
"react-dom": "^16.8.0 || ^17 || ^18",
|
|
166
166
|
"react-redux": "^7.2.6",
|
|
167
167
|
"redux": "^4.1.2",
|
|
168
168
|
"styled-components": "^5.3.3"
|