@daeryun/dr_components 1.2.17 → 1.2.19

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.
Files changed (241) hide show
  1. package/dist/components/Daeryuntalk/ChatButton.jsx +1 -1
  2. package/dist/components/Daeryuntalk/ChatButton.tsx +1 -1
  3. package/dist/components/Daeryuntalk/ChatWidget.d.ts +1 -0
  4. package/dist/components/Daeryuntalk/ChatWidget.jsx +114 -31
  5. package/dist/components/Daeryuntalk/ChatWidget.tsx +120 -37
  6. package/dist/components/Daeryuntalk/Viewer/TbPcViewer.tsx +0 -9
  7. package/dist/components/Daeryuntalk/index.jsx +17 -1
  8. package/dist/components/Daeryuntalk/index.tsx +26 -2
  9. package/dist/components/DaeryuntalkBackup/ChatButton.d.ts +11 -0
  10. package/dist/components/DaeryuntalkBackup/ChatButton.jsx +123 -0
  11. package/dist/components/DaeryuntalkBackup/ChatButton.tsx +157 -0
  12. package/dist/components/DaeryuntalkBackup/ChatConversation.d.ts +21 -0
  13. package/dist/components/DaeryuntalkBackup/ChatConversation.jsx +259 -0
  14. package/dist/components/DaeryuntalkBackup/ChatConversation.tsx +390 -0
  15. package/dist/components/DaeryuntalkBackup/ChatConversationItem/ChatConversationHeader.d.ts +16 -0
  16. package/dist/components/DaeryuntalkBackup/ChatConversationItem/ChatConversationHeader.jsx +50 -0
  17. package/dist/components/DaeryuntalkBackup/ChatConversationItem/ChatConversationHeader.tsx +108 -0
  18. package/dist/components/DaeryuntalkBackup/ChatHomeView.d.ts +14 -0
  19. package/dist/components/DaeryuntalkBackup/ChatHomeView.jsx +147 -0
  20. package/dist/components/DaeryuntalkBackup/ChatHomeView.tsx +262 -0
  21. package/dist/components/DaeryuntalkBackup/ChatInput.d.ts +8 -0
  22. package/dist/components/DaeryuntalkBackup/ChatInput.jsx +64 -0
  23. package/dist/components/DaeryuntalkBackup/ChatInput.tsx +98 -0
  24. package/dist/components/DaeryuntalkBackup/ChatItem/AgeCheckBox.d.ts +6 -0
  25. package/dist/components/DaeryuntalkBackup/ChatItem/AgeCheckBox.jsx +19 -0
  26. package/dist/components/DaeryuntalkBackup/ChatItem/AgeCheckBox.tsx +27 -0
  27. package/dist/components/DaeryuntalkBackup/ChatItem/ChatFile.d.ts +10 -0
  28. package/dist/components/DaeryuntalkBackup/ChatItem/ChatFile.jsx +165 -0
  29. package/dist/components/DaeryuntalkBackup/ChatItem/ChatFile.tsx +244 -0
  30. package/dist/components/DaeryuntalkBackup/ChatItem/ChatLoading.d.ts +6 -0
  31. package/dist/components/DaeryuntalkBackup/ChatItem/ChatLoading.jsx +12 -0
  32. package/dist/components/DaeryuntalkBackup/ChatItem/ChatLoading.tsx +25 -0
  33. package/dist/components/DaeryuntalkBackup/ChatItem/ChatPrivacyAuth.d.ts +8 -0
  34. package/dist/components/DaeryuntalkBackup/ChatItem/ChatPrivacyAuth.jsx +100 -0
  35. package/dist/components/DaeryuntalkBackup/ChatItem/ChatPrivacyAuth.tsx +135 -0
  36. package/dist/components/DaeryuntalkBackup/ChatItem/ChatWrapper.d.ts +8 -0
  37. package/dist/components/DaeryuntalkBackup/ChatItem/ChatWrapper.jsx +14 -0
  38. package/dist/components/DaeryuntalkBackup/ChatItem/ChatWrapper.tsx +26 -0
  39. package/dist/components/DaeryuntalkBackup/ChatItem/RichText.d.ts +7 -0
  40. package/dist/components/DaeryuntalkBackup/ChatItem/RichText.jsx +37 -0
  41. package/dist/components/DaeryuntalkBackup/ChatItem/RichText.tsx +45 -0
  42. package/dist/components/DaeryuntalkBackup/ChatItem/TimeWrapper.d.ts +9 -0
  43. package/dist/components/DaeryuntalkBackup/ChatItem/TimeWrapper.jsx +10 -0
  44. package/dist/components/DaeryuntalkBackup/ChatItem/TimeWrapper.tsx +21 -0
  45. package/dist/components/DaeryuntalkBackup/ChatItem/TypingComp.d.ts +3 -0
  46. package/dist/components/DaeryuntalkBackup/ChatItem/TypingComp.jsx +34 -0
  47. package/dist/components/DaeryuntalkBackup/ChatItem/TypingComp.tsx +43 -0
  48. package/dist/components/DaeryuntalkBackup/ChatItem/WorkFlowAuthForm.d.ts +8 -0
  49. package/dist/components/DaeryuntalkBackup/ChatItem/WorkFlowAuthForm.jsx +20 -0
  50. package/dist/components/DaeryuntalkBackup/ChatItem/WorkFlowAuthForm.tsx +32 -0
  51. package/dist/components/DaeryuntalkBackup/ChatItem/WorkFlowClickData.d.ts +7 -0
  52. package/dist/components/DaeryuntalkBackup/ChatItem/WorkFlowClickData.jsx +21 -0
  53. package/dist/components/DaeryuntalkBackup/ChatItem/WorkFlowClickData.tsx +37 -0
  54. package/dist/components/DaeryuntalkBackup/ChatItem/WorkFlowImg.d.ts +9 -0
  55. package/dist/components/DaeryuntalkBackup/ChatItem/WorkFlowImg.jsx +178 -0
  56. package/dist/components/DaeryuntalkBackup/ChatItem/WorkFlowImg.tsx +233 -0
  57. package/dist/components/DaeryuntalkBackup/ChatMessage.d.ts +20 -0
  58. package/dist/components/DaeryuntalkBackup/ChatMessage.jsx +198 -0
  59. package/dist/components/DaeryuntalkBackup/ChatMessage.tsx +295 -0
  60. package/dist/components/DaeryuntalkBackup/ChatObject/FieldWorkObject.d.ts +9 -0
  61. package/dist/components/DaeryuntalkBackup/ChatObject/FieldWorkObject.jsx +39 -0
  62. package/dist/components/DaeryuntalkBackup/ChatObject/FieldWorkObject.tsx +75 -0
  63. package/dist/components/DaeryuntalkBackup/ChatObject/ObjectBack.d.ts +7 -0
  64. package/dist/components/DaeryuntalkBackup/ChatObject/ObjectBack.jsx +20 -0
  65. package/dist/components/DaeryuntalkBackup/ChatObject/ObjectBack.tsx +39 -0
  66. package/dist/components/DaeryuntalkBackup/ChatObject/ObjectButton.d.ts +10 -0
  67. package/dist/components/DaeryuntalkBackup/ChatObject/ObjectButton.jsx +138 -0
  68. package/dist/components/DaeryuntalkBackup/ChatObject/ObjectButton.tsx +177 -0
  69. package/dist/components/DaeryuntalkBackup/ChatWidget.d.ts +13 -0
  70. package/dist/components/DaeryuntalkBackup/ChatWidget.jsx +154 -0
  71. package/dist/components/DaeryuntalkBackup/ChatWidget.tsx +221 -0
  72. package/dist/components/DaeryuntalkBackup/DaeryuntalkContext.d.ts +103 -0
  73. package/dist/components/DaeryuntalkBackup/DaeryuntalkContext.jsx +207 -0
  74. package/dist/components/DaeryuntalkBackup/DaeryuntalkContext.tsx +350 -0
  75. package/dist/components/DaeryuntalkBackup/DateSeparator.d.ts +6 -0
  76. package/dist/components/DaeryuntalkBackup/DateSeparator.jsx +14 -0
  77. package/dist/components/DaeryuntalkBackup/DateSeparator.tsx +24 -0
  78. package/dist/components/DaeryuntalkBackup/FixedErrorBox.d.ts +7 -0
  79. package/dist/components/DaeryuntalkBackup/FixedErrorBox.jsx +34 -0
  80. package/dist/components/DaeryuntalkBackup/FixedErrorBox.tsx +73 -0
  81. package/dist/components/DaeryuntalkBackup/History/AuthForm.d.ts +10 -0
  82. package/dist/components/DaeryuntalkBackup/History/AuthForm.jsx +157 -0
  83. package/dist/components/DaeryuntalkBackup/History/AuthForm.tsx +206 -0
  84. package/dist/components/DaeryuntalkBackup/HistoryView.d.ts +19 -0
  85. package/dist/components/DaeryuntalkBackup/HistoryView.jsx +94 -0
  86. package/dist/components/DaeryuntalkBackup/HistoryView.tsx +182 -0
  87. package/dist/components/DaeryuntalkBackup/HomeView.d.ts +12 -0
  88. package/dist/components/DaeryuntalkBackup/HomeView.jsx +178 -0
  89. package/dist/components/DaeryuntalkBackup/HomeView.tsx +261 -0
  90. package/dist/components/DaeryuntalkBackup/NavigationFooter.d.ts +11 -0
  91. package/dist/components/DaeryuntalkBackup/NavigationFooter.jsx +44 -0
  92. package/dist/components/DaeryuntalkBackup/NavigationFooter.tsx +98 -0
  93. package/dist/components/DaeryuntalkBackup/NoticeMessage.d.ts +7 -0
  94. package/dist/components/DaeryuntalkBackup/NoticeMessage.jsx +40 -0
  95. package/dist/components/DaeryuntalkBackup/NoticeMessage.tsx +60 -0
  96. package/dist/components/DaeryuntalkBackup/Tiptap/DisabledInput.d.ts +6 -0
  97. package/dist/components/DaeryuntalkBackup/Tiptap/DisabledInput.jsx +17 -0
  98. package/dist/components/DaeryuntalkBackup/Tiptap/DisabledInput.tsx +28 -0
  99. package/dist/components/DaeryuntalkBackup/Tiptap/Tiptap.d.ts +20 -0
  100. package/dist/components/DaeryuntalkBackup/Tiptap/Tiptap.jsx +130 -0
  101. package/dist/components/DaeryuntalkBackup/Tiptap/Tiptap.tsx +181 -0
  102. package/dist/components/DaeryuntalkBackup/Toast/DaeryuntalkToastProvider.d.ts +23 -0
  103. package/dist/components/DaeryuntalkBackup/Toast/DaeryuntalkToastProvider.jsx +40 -0
  104. package/dist/components/DaeryuntalkBackup/Toast/DaeryuntalkToastProvider.tsx +70 -0
  105. package/dist/components/DaeryuntalkBackup/Toast/Toast.d.ts +11 -0
  106. package/dist/components/DaeryuntalkBackup/Toast/Toast.jsx +64 -0
  107. package/dist/components/DaeryuntalkBackup/Toast/Toast.tsx +98 -0
  108. package/dist/components/DaeryuntalkBackup/Toast/ToastRender.d.ts +1 -0
  109. package/dist/components/DaeryuntalkBackup/Toast/ToastRender.jsx +22 -0
  110. package/dist/components/DaeryuntalkBackup/Toast/ToastRender.tsx +30 -0
  111. package/dist/components/DaeryuntalkBackup/Viewer/ImageViewer.d.ts +9 -0
  112. package/dist/components/DaeryuntalkBackup/Viewer/ImageViewer.jsx +98 -0
  113. package/dist/components/DaeryuntalkBackup/Viewer/ImageViewer.tsx +138 -0
  114. package/dist/components/DaeryuntalkBackup/Viewer/MobileViewer.d.ts +18 -0
  115. package/dist/components/DaeryuntalkBackup/Viewer/MobileViewer.jsx +104 -0
  116. package/dist/components/DaeryuntalkBackup/Viewer/MobileViewer.tsx +182 -0
  117. package/dist/components/DaeryuntalkBackup/Viewer/TbPcViewer.d.ts +24 -0
  118. package/dist/components/DaeryuntalkBackup/Viewer/TbPcViewer.jsx +141 -0
  119. package/dist/components/DaeryuntalkBackup/Viewer/TbPcViewer.tsx +278 -0
  120. package/dist/components/DaeryuntalkBackup/ViewportHandler.d.ts +6 -0
  121. package/dist/components/DaeryuntalkBackup/ViewportHandler.jsx +25 -0
  122. package/dist/components/DaeryuntalkBackup/ViewportHandler.tsx +32 -0
  123. package/dist/components/DaeryuntalkBackup/_api/daeryuntalk/index.d.ts +177 -0
  124. package/dist/components/DaeryuntalkBackup/_api/daeryuntalk/index.js +801 -0
  125. package/dist/components/DaeryuntalkBackup/_api/daeryuntalk/index.ts +1097 -0
  126. package/dist/components/DaeryuntalkBackup/_api/daeryuntalk/type/response.d.ts +131 -0
  127. package/dist/components/DaeryuntalkBackup/_api/daeryuntalk/type/response.js +1 -0
  128. package/dist/components/DaeryuntalkBackup/_api/daeryuntalk/type/response.ts +159 -0
  129. package/dist/components/DaeryuntalkBackup/_api/index.d.ts +6 -0
  130. package/dist/components/DaeryuntalkBackup/_api/index.js +6 -0
  131. package/dist/components/DaeryuntalkBackup/_api/index.ts +7 -0
  132. package/dist/components/DaeryuntalkBackup/_enums/ags_check_status.d.ts +5 -0
  133. package/dist/components/DaeryuntalkBackup/_enums/ags_check_status.js +9 -0
  134. package/dist/components/DaeryuntalkBackup/_enums/ags_check_status.ts +9 -0
  135. package/dist/components/DaeryuntalkBackup/_enums/ask-status.d.ts +13 -0
  136. package/dist/components/DaeryuntalkBackup/_enums/ask-status.js +25 -0
  137. package/dist/components/DaeryuntalkBackup/_enums/ask-status.ts +26 -0
  138. package/dist/components/DaeryuntalkBackup/_enums/error.d.ts +109 -0
  139. package/dist/components/DaeryuntalkBackup/_enums/error.js +254 -0
  140. package/dist/components/DaeryuntalkBackup/_enums/error.ts +289 -0
  141. package/dist/components/DaeryuntalkBackup/_enums/message_type.d.ts +6 -0
  142. package/dist/components/DaeryuntalkBackup/_enums/message_type.js +13 -0
  143. package/dist/components/DaeryuntalkBackup/_enums/message_type.ts +13 -0
  144. package/dist/components/DaeryuntalkBackup/_enums/sender_type.d.ts +8 -0
  145. package/dist/components/DaeryuntalkBackup/_enums/sender_type.js +16 -0
  146. package/dist/components/DaeryuntalkBackup/_enums/sender_type.ts +16 -0
  147. package/dist/components/DaeryuntalkBackup/_enums/socket_type.d.ts +34 -0
  148. package/dist/components/DaeryuntalkBackup/_enums/socket_type.js +46 -0
  149. package/dist/components/DaeryuntalkBackup/_enums/socket_type.ts +56 -0
  150. package/dist/components/DaeryuntalkBackup/_enums/template.d.ts +32 -0
  151. package/dist/components/DaeryuntalkBackup/_enums/template.js +76 -0
  152. package/dist/components/DaeryuntalkBackup/_enums/template.ts +81 -0
  153. package/dist/components/DaeryuntalkBackup/_enums/work_flow_object_expose.d.ts +33 -0
  154. package/dist/components/DaeryuntalkBackup/_enums/work_flow_object_expose.js +66 -0
  155. package/dist/components/DaeryuntalkBackup/_enums/work_flow_object_expose.ts +71 -0
  156. package/dist/components/DaeryuntalkBackup/_hooks/talkprovider/useChatHandler.d.ts +48 -0
  157. package/dist/components/DaeryuntalkBackup/_hooks/talkprovider/useChatHandler.js +465 -0
  158. package/dist/components/DaeryuntalkBackup/_hooks/talkprovider/useChatHandler.ts +595 -0
  159. package/dist/components/DaeryuntalkBackup/_hooks/talkprovider/useFullURL.d.ts +1 -0
  160. package/dist/components/DaeryuntalkBackup/_hooks/talkprovider/useFullURL.jsx +15 -0
  161. package/dist/components/DaeryuntalkBackup/_hooks/talkprovider/useFullURL.tsx +17 -0
  162. package/dist/components/DaeryuntalkBackup/_hooks/talkprovider/useHistoryHandler.d.ts +24 -0
  163. package/dist/components/DaeryuntalkBackup/_hooks/talkprovider/useHistoryHandler.js +112 -0
  164. package/dist/components/DaeryuntalkBackup/_hooks/talkprovider/useHistoryHandler.ts +144 -0
  165. package/dist/components/DaeryuntalkBackup/_hooks/talkprovider/useSocketEventHandler.d.ts +44 -0
  166. package/dist/components/DaeryuntalkBackup/_hooks/talkprovider/useSocketEventHandler.js +534 -0
  167. package/dist/components/DaeryuntalkBackup/_hooks/talkprovider/useSocketEventHandler.ts +706 -0
  168. package/dist/components/DaeryuntalkBackup/_hooks/talkprovider/useViewerHook.d.ts +8 -0
  169. package/dist/components/DaeryuntalkBackup/_hooks/talkprovider/useViewerHook.js +18 -0
  170. package/dist/components/DaeryuntalkBackup/_hooks/talkprovider/useViewerHook.ts +23 -0
  171. package/dist/components/DaeryuntalkBackup/_hooks/talkprovider/useWorkFlow.d.ts +9 -0
  172. package/dist/components/DaeryuntalkBackup/_hooks/talkprovider/useWorkFlow.js +109 -0
  173. package/dist/components/DaeryuntalkBackup/_hooks/talkprovider/useWorkFlow.ts +121 -0
  174. package/dist/components/DaeryuntalkBackup/_hooks/useHoverScrollbar.d.ts +12 -0
  175. package/dist/components/DaeryuntalkBackup/_hooks/useHoverScrollbar.js +48 -0
  176. package/dist/components/DaeryuntalkBackup/_hooks/useHoverScrollbar.ts +73 -0
  177. package/dist/components/DaeryuntalkBackup/_hooks/useScrollShadow.d.ts +7 -0
  178. package/dist/components/DaeryuntalkBackup/_hooks/useScrollShadow.js +42 -0
  179. package/dist/components/DaeryuntalkBackup/_hooks/useScrollShadow.ts +52 -0
  180. package/dist/components/DaeryuntalkBackup/_hooks/useWindowSize.d.ts +6 -0
  181. package/dist/components/DaeryuntalkBackup/_hooks/useWindowSize.js +20 -0
  182. package/dist/components/DaeryuntalkBackup/_hooks/useWindowSize.ts +30 -0
  183. package/dist/components/DaeryuntalkBackup/_hooks/view/useChatSocketState.d.ts +2 -0
  184. package/dist/components/DaeryuntalkBackup/_hooks/view/useChatSocketState.js +26 -0
  185. package/dist/components/DaeryuntalkBackup/_hooks/view/useChatSocketState.ts +43 -0
  186. package/dist/components/DaeryuntalkBackup/_hooks/view/useHistoryView.d.ts +27 -0
  187. package/dist/components/DaeryuntalkBackup/_hooks/view/useHistoryView.js +80 -0
  188. package/dist/components/DaeryuntalkBackup/_hooks/view/useHistoryView.ts +101 -0
  189. package/dist/components/DaeryuntalkBackup/_hooks/view/useHomeView.d.ts +18 -0
  190. package/dist/components/DaeryuntalkBackup/_hooks/view/useHomeView.js +66 -0
  191. package/dist/components/DaeryuntalkBackup/_hooks/view/useHomeView.ts +75 -0
  192. package/dist/components/DaeryuntalkBackup/_lib/index.d.ts +7 -0
  193. package/dist/components/DaeryuntalkBackup/_lib/index.js +103 -0
  194. package/dist/components/DaeryuntalkBackup/_lib/index.ts +136 -0
  195. package/dist/components/DaeryuntalkBackup/_lib/utils.d.ts +17 -0
  196. package/dist/components/DaeryuntalkBackup/_lib/utils.js +94 -0
  197. package/dist/components/DaeryuntalkBackup/_lib/utils.ts +119 -0
  198. package/dist/components/DaeryuntalkBackup/_types/message.d.ts +92 -0
  199. package/dist/components/DaeryuntalkBackup/_types/message.js +25 -0
  200. package/dist/components/DaeryuntalkBackup/_types/message.ts +156 -0
  201. package/dist/components/DaeryuntalkBackup/_types/message_object.d.ts +17 -0
  202. package/dist/components/DaeryuntalkBackup/_types/message_object.js +1 -0
  203. package/dist/components/DaeryuntalkBackup/_types/message_object.ts +18 -0
  204. package/dist/components/DaeryuntalkBackup/_types/socket/workflow.d.ts +15 -0
  205. package/dist/components/DaeryuntalkBackup/_types/socket/workflow.js +1 -0
  206. package/dist/components/DaeryuntalkBackup/_types/socket/workflow.ts +15 -0
  207. package/dist/components/DaeryuntalkBackup/_ui/ShadowBox.d.ts +6 -0
  208. package/dist/components/DaeryuntalkBackup/_ui/ShadowBox.jsx +5 -0
  209. package/dist/components/DaeryuntalkBackup/_ui/ShadowBox.tsx +15 -0
  210. package/dist/components/DaeryuntalkBackup/_ui/buttons/Button1.d.ts +10 -0
  211. package/dist/components/DaeryuntalkBackup/_ui/buttons/Button1.jsx +12 -0
  212. package/dist/components/DaeryuntalkBackup/_ui/buttons/Button1.tsx +29 -0
  213. package/dist/components/DaeryuntalkBackup/_ui/buttons/Button2.d.ts +10 -0
  214. package/dist/components/DaeryuntalkBackup/_ui/buttons/Button2.jsx +12 -0
  215. package/dist/components/DaeryuntalkBackup/_ui/buttons/Button2.tsx +29 -0
  216. package/dist/components/DaeryuntalkBackup/_ui/buttons/Button3.d.ts +10 -0
  217. package/dist/components/DaeryuntalkBackup/_ui/buttons/Button3.jsx +12 -0
  218. package/dist/components/DaeryuntalkBackup/_ui/buttons/Button3.tsx +29 -0
  219. package/dist/components/DaeryuntalkBackup/_ui/buttons/Button4.d.ts +10 -0
  220. package/dist/components/DaeryuntalkBackup/_ui/buttons/Button4.jsx +12 -0
  221. package/dist/components/DaeryuntalkBackup/_ui/buttons/Button4.tsx +29 -0
  222. package/dist/components/DaeryuntalkBackup/_ui/checkboxs/CheckBox1.d.ts +8 -0
  223. package/dist/components/DaeryuntalkBackup/_ui/checkboxs/CheckBox1.jsx +15 -0
  224. package/dist/components/DaeryuntalkBackup/_ui/checkboxs/CheckBox1.tsx +38 -0
  225. package/dist/components/DaeryuntalkBackup/_ui/checkboxs/CheckBox2.d.ts +8 -0
  226. package/dist/components/DaeryuntalkBackup/_ui/checkboxs/CheckBox2.jsx +21 -0
  227. package/dist/components/DaeryuntalkBackup/_ui/checkboxs/CheckBox2.tsx +50 -0
  228. package/dist/components/DaeryuntalkBackup/_ui/inputs/Input1.d.ts +12 -0
  229. package/dist/components/DaeryuntalkBackup/_ui/inputs/Input1.jsx +9 -0
  230. package/dist/components/DaeryuntalkBackup/_ui/inputs/Input1.tsx +39 -0
  231. package/dist/components/DaeryuntalkBackup/_ui/inputs/Input2.d.ts +13 -0
  232. package/dist/components/DaeryuntalkBackup/_ui/inputs/Input2.jsx +10 -0
  233. package/dist/components/DaeryuntalkBackup/_ui/inputs/Input2.tsx +43 -0
  234. package/dist/components/DaeryuntalkBackup/index.d.ts +8 -0
  235. package/dist/components/DaeryuntalkBackup/index.jsx +190 -0
  236. package/dist/components/DaeryuntalkBackup/index.tsx +261 -0
  237. package/dist/components/banner/TopBanner.jsx +2 -2
  238. package/dist/components/banner/TopBanner.tsx +4 -2
  239. package/dist/styles/globals.css +5 -0
  240. package/dist/tsconfig.tsbuildinfo +1 -1
  241. package/package.json +1 -1
@@ -10,7 +10,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
10
10
  };
11
11
  import React, { useCallback, useEffect, useState } from 'react';
12
12
  import { useDaeryuntalk } from './DaeryuntalkContext';
13
- import useBrowser from '../common/hook/useBrowser';
13
+ import useBrowser from '../hook/useBrowser';
14
14
  const ChatButton = ({ isOpen, onClick, apiVersion, isMobile = false, hashValue = null, bannerHeight = 0 }) => {
15
15
  const { initializeDaeryuntalk, centerCode } = useDaeryuntalk();
16
16
  const { width } = useBrowser();
@@ -1,7 +1,7 @@
1
1
  'use client';
2
2
  import React, { useCallback, useEffect, useState } from 'react';
3
3
  import { useDaeryuntalk } from './DaeryuntalkContext';
4
- import useBrowser from '../common/hook/useBrowser';
4
+ import useBrowser from '../hook/useBrowser';
5
5
 
6
6
  interface ChatButtonProps {
7
7
  isOpen: boolean;
@@ -8,6 +8,7 @@ interface ChatWidgetProps {
8
8
  animationState: string;
9
9
  isMobileSafari?: boolean;
10
10
  androidViewportHeight?: number;
11
+ isMobileAndroid?: boolean;
11
12
  }
12
13
  declare const ChatWidget: React.FC<ChatWidgetProps>;
13
14
  export default ChatWidget;
@@ -1,18 +1,23 @@
1
1
  'use client';
2
- import React, { useEffect, useRef, useState } from 'react';
2
+ import React, { useEffect, useMemo, useRef, useState } from 'react';
3
3
  import ChatHomeView from './ChatHomeView';
4
4
  import ImageViewer from './Viewer/ImageViewer';
5
5
  import { useScrollShadow } from './_hooks/useScrollShadow';
6
- const ChatWidget = ({ isOpen, isMobile, onClose, hashValue, setHashValue, animationState, isMobileSafari = false, androidViewportHeight = 0 }) => {
7
- const { containerRef, isScroll, isBottom } = useScrollShadow();
8
- const isHash = !!hashValue; // 해쉬 있을 경우
6
+ const ChatWidget = ({ isOpen, isMobile, onClose, hashValue, setHashValue, animationState, isMobileSafari = false, androidViewportHeight = 0, isMobileAndroid = false }) => {
7
+ const { containerRef } = useScrollShadow();
8
+ const isHash = !!hashValue;
9
9
  const chatWidgetRef = useRef(null);
10
10
  // iOS Safari viewport 계산
11
11
  const [viewportOffset, setViewportOffset] = useState(0);
12
12
  const [viewportHeight, setViewportHeight] = useState(0);
13
13
  const [viewState, setViewState] = useState('conversation');
14
+ const isConversationView = useMemo(() => {
15
+ return viewState === 'conversation';
16
+ }, [viewState]);
14
17
  useEffect(() => {
15
18
  var _a, _b;
19
+ if (!isConversationView)
20
+ return;
16
21
  if (!isMobileSafari)
17
22
  return;
18
23
  const updateViewport = () => {
@@ -34,13 +39,12 @@ const ChatWidget = ({ isOpen, isMobile, onClose, hashValue, setHashValue, animat
34
39
  (_a = window.visualViewport) === null || _a === void 0 ? void 0 : _a.removeEventListener('resize', onResize);
35
40
  (_b = window.visualViewport) === null || _b === void 0 ? void 0 : _b.removeEventListener('scroll', onScroll);
36
41
  };
37
- }, [isMobileSafari]);
42
+ }, [isMobileSafari, isConversationView]);
38
43
  useEffect(() => {
39
44
  const isScrollableElement = (element) => {
40
45
  const style = window.getComputedStyle(element);
41
46
  const hasScrollableY = style.overflowY === 'auto' || style.overflowY === 'scroll';
42
47
  const hasScrollable = style.overflow === 'auto' || style.overflow === 'scroll';
43
- // 실제로 스크롤이 가능한지 확인 (내용이 컨테이너보다 큰지)
44
48
  if (hasScrollableY || hasScrollable) {
45
49
  return element.scrollHeight > element.clientHeight;
46
50
  }
@@ -48,43 +52,132 @@ const ChatWidget = ({ isOpen, isMobile, onClose, hashValue, setHashValue, animat
48
52
  };
49
53
  const handleWheel = (e) => {
50
54
  let target = e.target;
51
- // 타겟부터 시작하여 부모 요소들을 확인
52
55
  while (target && target !== chatWidgetRef.current) {
53
56
  if (isScrollableElement(target)) {
54
- // 스크롤 가능한 요소라면 이벤트를 허용
55
57
  return;
56
58
  }
57
59
  target = target.parentElement;
58
60
  }
59
- // 스크롤 가능한 요소가 아니라면 이벤트 차단
60
61
  e.preventDefault();
61
62
  e.stopPropagation();
62
63
  };
63
64
  const element = chatWidgetRef.current;
64
65
  if (element && isOpen) {
65
- // passive: false로 설정하여 preventDefault()가 작동하도록 함
66
66
  element.addEventListener('wheel', handleWheel, { passive: false });
67
67
  }
68
68
  return () => {
69
- if (element) {
69
+ if (element)
70
70
  element.removeEventListener('wheel', handleWheel);
71
- }
72
71
  };
73
72
  }, [isOpen]);
74
- // 모바일 웹
73
+ // Safari 뒤 스크롤 방지 -> 뒷 스크롤시 스크롤 원래대로 되돌리기
74
+ useEffect(() => {
75
+ var _a;
76
+ if (!isConversationView)
77
+ return;
78
+ if (!(isMobileSafari && isMobile && isOpen))
79
+ return;
80
+ let initialScrollY = 0;
81
+ const handleScrollLock = () => {
82
+ const currentScrollY = window.scrollY;
83
+ const active = document.activeElement;
84
+ // 현재 포커스된 요소가 "입력 중인 요소"인지 판단하는 조건
85
+ const isTyping = active &&
86
+ (active.tagName === 'INPUT' || // 일반 input 요소
87
+ active.tagName === 'TEXTAREA' || // textarea
88
+ active.getAttribute('contenteditable') === 'true'); // contenteditable 요소 (채팅 입력창 등)
89
+ if (isTyping) {
90
+ // 키보드가 올라온 '첫 순간'에 scrollY 값을 저장
91
+ // Safari는 키보드가 뜨면 화면을 밀어내며 scrollY가 증가하므로
92
+ // 최초 scrollY 위치를 기억했다가 계속 유지해야 함
93
+ if (!initialScrollY)
94
+ initialScrollY = currentScrollY;
95
+ // Safari가 화면 전체를 아래로 밀려고 하면 scrollY 값이 증가함
96
+ // → 즉시 원래 위치(initialScrollY)로 되돌려서 "뷰포트 스크롤"을 차단
97
+ if (currentScrollY > initialScrollY) {
98
+ window.scrollTo(0, initialScrollY); // Safari의 아래로 끌림(검은 화면)을 무력화
99
+ }
100
+ }
101
+ else {
102
+ initialScrollY = 0;
103
+ }
104
+ };
105
+ window.addEventListener('scroll', handleScrollLock, { passive: false });
106
+ (_a = window.visualViewport) === null || _a === void 0 ? void 0 : _a.addEventListener('resize', handleScrollLock);
107
+ return () => {
108
+ var _a;
109
+ window.removeEventListener('scroll', handleScrollLock);
110
+ (_a = window.visualViewport) === null || _a === void 0 ? void 0 : _a.removeEventListener('resize', handleScrollLock);
111
+ };
112
+ }, [isMobileSafari, isMobile, isOpen, isConversationView]);
113
+ // 크롬같은 모바일 사파리 외 키보드 열림 감지 및 blur 방지
114
+ useEffect(() => {
115
+ var _a;
116
+ if (!isConversationView)
117
+ return;
118
+ if (!isOpen)
119
+ return;
120
+ if (!isMobile)
121
+ return;
122
+ if (isMobileSafari)
123
+ return;
124
+ let keyboardOpened = false;
125
+ let blurLock = false;
126
+ const detectKeyboard = () => {
127
+ const vv = window.visualViewport;
128
+ if (!vv)
129
+ return;
130
+ const heightDiff = window.innerHeight - vv.height;
131
+ if (heightDiff > 150) {
132
+ keyboardOpened = true;
133
+ }
134
+ else {
135
+ keyboardOpened = false;
136
+ // 키보드 내려간 직후 blur 방지 lock
137
+ blurLock = true;
138
+ setTimeout(() => {
139
+ blurLock = false;
140
+ }, 250);
141
+ }
142
+ };
143
+ const handleWrapperTouch = (e) => {
144
+ if (!keyboardOpened)
145
+ return;
146
+ if (blurLock)
147
+ return;
148
+ const active = document.activeElement;
149
+ if (!active)
150
+ return;
151
+ const wrapper = document.querySelector('.daeryuntalk-wrapper');
152
+ if (!wrapper)
153
+ return;
154
+ // wrapper 터치면 blur
155
+ if (wrapper.contains(e.target)) {
156
+ blurLock = true;
157
+ active.blur();
158
+ setTimeout(() => (blurLock = false), 250);
159
+ }
160
+ };
161
+ (_a = window.visualViewport) === null || _a === void 0 ? void 0 : _a.addEventListener('resize', detectKeyboard);
162
+ const wrapper = document.querySelector('.daeryuntalk-wrapper');
163
+ wrapper === null || wrapper === void 0 ? void 0 : wrapper.addEventListener('touchstart', handleWrapperTouch, { passive: true });
164
+ return () => {
165
+ var _a;
166
+ (_a = window.visualViewport) === null || _a === void 0 ? void 0 : _a.removeEventListener('resize', detectKeyboard);
167
+ wrapper === null || wrapper === void 0 ? void 0 : wrapper.removeEventListener('touchstart', handleWrapperTouch);
168
+ };
169
+ }, [isOpen, isConversationView, isMobileSafari, isMobile]);
75
170
  const mobileWrapperCss = `
76
171
  fixed inset-0 h-full w-full bg-white z-[999998] rounded-none flex flex-col
77
172
  duration-500 ease-in-out
78
173
  ${isOpen ? 'translate-y-0 opacity-100' : 'translate-y-full opacity-0 pointer-events-none'}
79
174
  `;
80
- // 웹 모바일 ~480px
81
175
  const webSmallWrapperCss = `
82
176
  ${isHash ? `duration-300 ease-in-out` : `duration-300 ease-in-out`}
83
177
  ${isHash ? `${isOpen ? ' translate-y-0 opacity-100' : 'translate-y-full opacity-0 pointer-events-none'} ` : isOpen ? 'translate-y-0 opacity-100' : 'translate-y-full opacity-0 pointer-events-none'}
84
178
  fixed w-full max-w-[100vw] z-[999998] rounded-none flex flex-col
85
179
  bottom-0 right-0 h-[100dvh]
86
180
  `;
87
- // 해쉬 있을 경우는 여기서 중앙배치 css로
88
181
  const webTbPCWrapperCss = `
89
182
  ${isHash ? `` : 'xs:duration-300 ease-in-out'}
90
183
  ${isHash
@@ -104,31 +197,21 @@ const ChatWidget = ({ isOpen, isMobile, onClose, hashValue, setHashValue, animat
104
197
  lg:bottom-[120px] xs:rounded-[30px]
105
198
  `}
106
199
  `;
107
- //
108
200
  const innerMobileWrapperCss = `
109
201
  rounded-none sm:max-w-[640px] sm:m-auto
110
202
  `;
111
- const innerWebSmallWrapperCss = `
112
- rounded-none
113
- `;
114
- // 웹 480~1023px , pc 1024px~
115
- const innerWebTbPCWrapperCss = `
116
- xs:rounded-[30px]
117
- `;
118
- // 웹 모바일
119
- // 태블릿 크기 이상 2
203
+ const innerWebSmallWrapperCss = `rounded-none`;
204
+ const innerWebTbPCWrapperCss = `xs:rounded-[30px]`;
120
205
  return (<>
121
206
  <ImageViewer />
122
207
 
123
208
  <div className="relative">
124
- <div ref={chatWidgetRef} className={`
125
-
126
- ${isMobile ? `${mobileWrapperCss}` : `${webSmallWrapperCss} ${webTbPCWrapperCss} `}
127
- `}>
209
+ <div ref={chatWidgetRef} className={`${isMobile ? mobileWrapperCss : `${webSmallWrapperCss} ${webTbPCWrapperCss}`}`}>
128
210
  <div ref={containerRef} className={`
129
211
  relative z-[999998]
130
- flex h-full flex-col items-center ${isHash ? 'justify-center' : 'justify-end'}
131
- ${isMobile ? `${innerMobileWrapperCss}` : `${innerWebSmallWrapperCss} ${innerWebTbPCWrapperCss}`}
212
+ flex h-full flex-col items-center
213
+ ${isHash ? 'justify-center' : 'justify-end'}
214
+ ${isMobile ? innerMobileWrapperCss : `${innerWebSmallWrapperCss} ${innerWebTbPCWrapperCss}`}
132
215
  `} style={viewState !== 'conversation' || !isMobile
133
216
  ? undefined
134
217
  : isMobileSafari
@@ -1,5 +1,5 @@
1
1
  'use client';
2
- import React, { Dispatch, SetStateAction, useEffect, useRef, useState } from 'react';
2
+ import React, { Dispatch, SetStateAction, useEffect, useMemo, useRef, useState } from 'react';
3
3
  import ChatHomeView, { ViewState } from './ChatHomeView';
4
4
  import ImageViewer from './Viewer/ImageViewer';
5
5
  import { useScrollShadow } from './_hooks/useScrollShadow';
@@ -13,6 +13,7 @@ interface ChatWidgetProps {
13
13
  animationState: string;
14
14
  isMobileSafari?: boolean;
15
15
  androidViewportHeight?: number;
16
+ isMobileAndroid?: boolean;
16
17
  }
17
18
 
18
19
  const ChatWidget: React.FC<ChatWidgetProps> = ({
@@ -23,10 +24,11 @@ const ChatWidget: React.FC<ChatWidgetProps> = ({
23
24
  setHashValue,
24
25
  animationState,
25
26
  isMobileSafari = false,
26
- androidViewportHeight = 0
27
+ androidViewportHeight = 0,
28
+ isMobileAndroid = false
27
29
  }) => {
28
- const { containerRef, isScroll, isBottom } = useScrollShadow<HTMLDivElement>();
29
- const isHash = !!hashValue; // 해쉬 있을 경우
30
+ const { containerRef } = useScrollShadow<HTMLDivElement>();
31
+ const isHash = !!hashValue;
30
32
  const chatWidgetRef = useRef<HTMLDivElement>(null);
31
33
 
32
34
  // iOS Safari viewport 계산
@@ -35,9 +37,13 @@ const ChatWidget: React.FC<ChatWidgetProps> = ({
35
37
 
36
38
  const [viewState, setViewState] = useState<ViewState>('conversation');
37
39
 
40
+ const isConversationView = useMemo(() => {
41
+ return viewState === 'conversation';
42
+ }, [viewState]);
43
+
38
44
  useEffect(() => {
45
+ if (!isConversationView) return;
39
46
  if (!isMobileSafari) return;
40
-
41
47
  const updateViewport = () => {
42
48
  if (!window.visualViewport) return;
43
49
 
@@ -60,7 +66,7 @@ const ChatWidget: React.FC<ChatWidgetProps> = ({
60
66
  window.visualViewport?.removeEventListener('resize', onResize);
61
67
  window.visualViewport?.removeEventListener('scroll', onScroll);
62
68
  };
63
- }, [isMobileSafari]);
69
+ }, [isMobileSafari, isConversationView]);
64
70
 
65
71
  useEffect(() => {
66
72
  const isScrollableElement = (element: Element): boolean => {
@@ -68,7 +74,6 @@ const ChatWidget: React.FC<ChatWidgetProps> = ({
68
74
  const hasScrollableY = style.overflowY === 'auto' || style.overflowY === 'scroll';
69
75
  const hasScrollable = style.overflow === 'auto' || style.overflow === 'scroll';
70
76
 
71
- // 실제로 스크롤이 가능한지 확인 (내용이 컨테이너보다 큰지)
72
77
  if (hasScrollableY || hasScrollable) {
73
78
  return element.scrollHeight > element.clientHeight;
74
79
  }
@@ -78,41 +83,134 @@ const ChatWidget: React.FC<ChatWidgetProps> = ({
78
83
  const handleWheel = (e: WheelEvent) => {
79
84
  let target = e.target as Element;
80
85
 
81
- // 타겟부터 시작하여 부모 요소들을 확인
82
86
  while (target && target !== chatWidgetRef.current) {
83
87
  if (isScrollableElement(target)) {
84
- // 스크롤 가능한 요소라면 이벤트를 허용
85
88
  return;
86
89
  }
87
90
  target = target.parentElement as Element;
88
91
  }
89
92
 
90
- // 스크롤 가능한 요소가 아니라면 이벤트 차단
91
93
  e.preventDefault();
92
94
  e.stopPropagation();
93
95
  };
94
96
 
95
97
  const element = chatWidgetRef.current;
96
98
  if (element && isOpen) {
97
- // passive: false로 설정하여 preventDefault()가 작동하도록 함
98
99
  element.addEventListener('wheel', handleWheel, { passive: false });
99
100
  }
100
101
 
101
102
  return () => {
102
- if (element) {
103
- element.removeEventListener('wheel', handleWheel);
104
- }
103
+ if (element) element.removeEventListener('wheel', handleWheel);
105
104
  };
106
105
  }, [isOpen]);
107
106
 
108
- // 모바일 웹
107
+ // Safari 뒤 스크롤 방지 -> 뒷 스크롤시 스크롤 원래대로 되돌리기
108
+ useEffect(() => {
109
+ if (!isConversationView) return;
110
+ if (!(isMobileSafari && isMobile && isOpen)) return;
111
+
112
+ let initialScrollY = 0;
113
+
114
+ const handleScrollLock = () => {
115
+ const currentScrollY = window.scrollY;
116
+
117
+ const active = document.activeElement;
118
+ // 현재 포커스된 요소가 "입력 중인 요소"인지 판단하는 조건
119
+ const isTyping =
120
+ active &&
121
+ (active.tagName === 'INPUT' || // 일반 input 요소
122
+ active.tagName === 'TEXTAREA' || // textarea
123
+ active.getAttribute('contenteditable') === 'true'); // contenteditable 요소 (채팅 입력창 등)
124
+
125
+ if (isTyping) {
126
+ // 키보드가 올라온 '첫 순간'에 scrollY 값을 저장
127
+ // Safari는 키보드가 뜨면 화면을 밀어내며 scrollY가 증가하므로
128
+ // 최초 scrollY 위치를 기억했다가 계속 유지해야 함
129
+ if (!initialScrollY) initialScrollY = currentScrollY;
130
+
131
+ // Safari가 화면 전체를 아래로 밀려고 하면 scrollY 값이 증가함
132
+ // → 즉시 원래 위치(initialScrollY)로 되돌려서 "뷰포트 스크롤"을 차단
133
+ if (currentScrollY > initialScrollY) {
134
+ window.scrollTo(0, initialScrollY); // Safari의 아래로 끌림(검은 화면)을 무력화
135
+ }
136
+ } else {
137
+ initialScrollY = 0;
138
+ }
139
+ };
140
+
141
+ window.addEventListener('scroll', handleScrollLock, { passive: false });
142
+ window.visualViewport?.addEventListener('resize', handleScrollLock);
143
+
144
+ return () => {
145
+ window.removeEventListener('scroll', handleScrollLock);
146
+ window.visualViewport?.removeEventListener('resize', handleScrollLock);
147
+ };
148
+ }, [isMobileSafari, isMobile, isOpen, isConversationView]);
149
+
150
+ // 크롬같은 모바일 사파리 외 키보드 열림 감지 및 blur 방지
151
+ useEffect(() => {
152
+ if (!isConversationView) return;
153
+ if (!isOpen) return;
154
+ if (!isMobile) return;
155
+ if (isMobileSafari) return;
156
+
157
+ let keyboardOpened = false;
158
+ let blurLock = false;
159
+
160
+ const detectKeyboard = () => {
161
+ const vv = window.visualViewport;
162
+ if (!vv) return;
163
+
164
+ const heightDiff = window.innerHeight - vv.height;
165
+
166
+ if (heightDiff > 150) {
167
+ keyboardOpened = true;
168
+ } else {
169
+ keyboardOpened = false;
170
+
171
+ // 키보드 내려간 직후 blur 방지 lock
172
+ blurLock = true;
173
+ setTimeout(() => {
174
+ blurLock = false;
175
+ }, 250);
176
+ }
177
+ };
178
+
179
+ const handleWrapperTouch = (e: TouchEvent) => {
180
+ if (!keyboardOpened) return;
181
+ if (blurLock) return;
182
+
183
+ const active = document.activeElement as HTMLElement | null;
184
+ if (!active) return;
185
+
186
+ const wrapper = document.querySelector('.daeryuntalk-wrapper');
187
+ if (!wrapper) return;
188
+
189
+ // wrapper 터치면 blur
190
+ if (wrapper.contains(e.target as HTMLElement)) {
191
+ blurLock = true;
192
+ active.blur();
193
+ setTimeout(() => (blurLock = false), 250);
194
+ }
195
+ };
196
+
197
+ window.visualViewport?.addEventListener('resize', detectKeyboard);
198
+
199
+ const wrapper = document.querySelector('.daeryuntalk-wrapper');
200
+ wrapper?.addEventListener('touchstart', handleWrapperTouch as EventListener, { passive: true });
201
+
202
+ return () => {
203
+ window.visualViewport?.removeEventListener('resize', detectKeyboard);
204
+ wrapper?.removeEventListener('touchstart', handleWrapperTouch as EventListener);
205
+ };
206
+ }, [isOpen, isConversationView, isMobileSafari, isMobile]);
207
+
109
208
  const mobileWrapperCss = `
110
209
  fixed inset-0 h-full w-full bg-white z-[999998] rounded-none flex flex-col
111
210
  duration-500 ease-in-out
112
211
  ${isOpen ? 'translate-y-0 opacity-100' : 'translate-y-full opacity-0 pointer-events-none'}
113
212
  `;
114
213
 
115
- // 웹 모바일 ~480px
116
214
  const webSmallWrapperCss = `
117
215
  ${isHash ? `duration-300 ease-in-out` : `duration-300 ease-in-out`}
118
216
  ${isHash ? `${isOpen ? ' translate-y-0 opacity-100' : 'translate-y-full opacity-0 pointer-events-none'} ` : isOpen ? 'translate-y-0 opacity-100' : 'translate-y-full opacity-0 pointer-events-none'}
@@ -120,7 +218,6 @@ const ChatWidget: React.FC<ChatWidgetProps> = ({
120
218
  bottom-0 right-0 h-[100dvh]
121
219
  `;
122
220
 
123
- // 해쉬 있을 경우는 여기서 중앙배치 css로
124
221
  const webTbPCWrapperCss = `
125
222
  ${isHash ? `` : 'xs:duration-300 ease-in-out'}
126
223
  ${
@@ -145,23 +242,11 @@ const ChatWidget: React.FC<ChatWidgetProps> = ({
145
242
  }
146
243
  `;
147
244
 
148
- //
149
245
  const innerMobileWrapperCss = `
150
246
  rounded-none sm:max-w-[640px] sm:m-auto
151
247
  `;
152
-
153
- const innerWebSmallWrapperCss = `
154
- rounded-none
155
- `;
156
-
157
- // 웹 480~1023px , pc 1024px~
158
- const innerWebTbPCWrapperCss = `
159
- xs:rounded-[30px]
160
- `;
161
-
162
- // 웹 모바일
163
-
164
- // 태블릿 크기 이상 2
248
+ const innerWebSmallWrapperCss = `rounded-none`;
249
+ const innerWebTbPCWrapperCss = `xs:rounded-[30px]`;
165
250
 
166
251
  return (
167
252
  <>
@@ -170,17 +255,15 @@ const ChatWidget: React.FC<ChatWidgetProps> = ({
170
255
  <div className="relative">
171
256
  <div
172
257
  ref={chatWidgetRef}
173
- className={`
174
-
175
- ${isMobile ? `${mobileWrapperCss}` : `${webSmallWrapperCss} ${webTbPCWrapperCss} `}
176
- `}
258
+ className={`${isMobile ? mobileWrapperCss : `${webSmallWrapperCss} ${webTbPCWrapperCss}`}`}
177
259
  >
178
260
  <div
179
261
  ref={containerRef}
180
262
  className={`
181
263
  relative z-[999998]
182
- flex h-full flex-col items-center ${isHash ? 'justify-center' : 'justify-end'}
183
- ${isMobile ? `${innerMobileWrapperCss}` : `${innerWebSmallWrapperCss} ${innerWebTbPCWrapperCss}`}
264
+ flex h-full flex-col items-center
265
+ ${isHash ? 'justify-center' : 'justify-end'}
266
+ ${isMobile ? innerMobileWrapperCss : `${innerWebSmallWrapperCss} ${innerWebTbPCWrapperCss}`}
184
267
  `}
185
268
  style={
186
269
  viewState !== 'conversation' || !isMobile
@@ -8,15 +8,6 @@ import { Swiper, SwiperSlide } from 'swiper/react';
8
8
  import 'swiper/css';
9
9
  import 'swiper/css/navigation';
10
10
 
11
- // 이미지
12
- // import RotateCCWIcon from '../../../asset/images/daeryuntalk/viewer/rotate.svg';
13
- // import ZoomOutIcon from '../../../asset/images/daeryuntalk/viewer/zoom-out.svg';
14
- // import ZoomInIcon from '../../../asset/images/daeryuntalk/viewer/zoom-in.svg';
15
- // import DownloadIcon from '../../../asset/images/daeryuntalk/download.svg';
16
- // import CloseIcon from '../../../asset/images/daeryuntalk/viewer/close.svg';
17
- // import MoveSwipingIcon from '../../../asset/images/daeryuntalk/viewer/move-button.svg';
18
- // import DaeryunLogoIcon from '../../../asset/images/daeryuntalk/daeryun-logo.svg';
19
-
20
11
  interface ITbPcViewerProps {
21
12
  imageViewerMessage?: Message | null;
22
13
  handleDownload: () => void;
@@ -13,6 +13,7 @@ const Daeryuntalk = ({ tel = '1800-7905', centerCode = 'CT0000', bannerHeight =
13
13
  const [isOpen, setIsOpen] = useState(false);
14
14
  const [isMobile, setIsMobile] = useState(false);
15
15
  const [isMobileSafari, setIsMobileSafari] = useState(false); // ios + 모바일
16
+ const [isMobileAndroid, setIsMobileAndroid] = useState(false); // android + 모바일
16
17
  const [androidViewportHeight, setAndroidViewportHeight] = useState(0); //
17
18
  const pathName = usePathname();
18
19
  const windowSize = useWindowSize();
@@ -55,6 +56,21 @@ const Daeryuntalk = ({ tel = '1800-7905', centerCode = 'CT0000', bannerHeight =
55
56
  openModal();
56
57
  }
57
58
  };
59
+ useEffect(() => {
60
+ if (typeof window === 'undefined')
61
+ return;
62
+ const ua = navigator.userAgent;
63
+ const isAndroid = /Android/i.test(ua);
64
+ const isMobileDevice = /Mobile/i.test(ua);
65
+ // Safari(iOS) 제외
66
+ const isSafari = /Safari/i.test(ua) && !/Chrome/i.test(ua);
67
+ if (isAndroid && isMobileDevice && !isSafari) {
68
+ setIsMobileAndroid(true);
69
+ }
70
+ else {
71
+ setIsMobileAndroid(false);
72
+ }
73
+ }, []);
58
74
  useEffect(() => {
59
75
  var _a;
60
76
  if (!isMobile) {
@@ -182,7 +198,7 @@ const Daeryuntalk = ({ tel = '1800-7905', centerCode = 'CT0000', bannerHeight =
182
198
  <ViewportHandler isMobile={isMobile} isDisable={!isOpen || !isMobile}/>
183
199
  <DaeryuntalkProvider propsTel={tel} isMobile={isMobile} onClose={closeModal} centerCode={currentCenterCode || ''} isOpen={isOpen}>
184
200
  {isMobile ? (isOpen || !currentCenterCode ? null : (<ChatButton isOpen={isOpen} isMobile={isMobile} hashValue={hashValue} onClick={toggleChat}/>)) : !currentCenterCode ? null : (<ChatButton isOpen={isOpen} isMobile={isMobile} hashValue={hashValue} onClick={toggleChat} bannerHeight={bannerHeight}/>)}
185
- <ChatWidget isOpen={hashValue ? true : isOpen} isMobile={isMobile} onClose={closeModal} hashValue={hashValue} setHashValue={setHashValue} animationState={animationState} isMobileSafari={isMobileSafari} androidViewportHeight={androidViewportHeight}/>
201
+ <ChatWidget isOpen={hashValue ? true : isOpen} isMobile={isMobile} onClose={closeModal} hashValue={hashValue} setHashValue={setHashValue} animationState={animationState} isMobileSafari={isMobileSafari} androidViewportHeight={androidViewportHeight} isMobileAndroid={isMobileAndroid}/>
186
202
  </DaeryuntalkProvider>
187
203
  </DaeryuntalkToastProvider>
188
204
  </div>);
@@ -1,6 +1,6 @@
1
1
  'use client';
2
2
 
3
- import React, { useEffect, useState } from 'react';
3
+ import React, { use, useEffect, useState } from 'react';
4
4
  import ChatButton from './ChatButton';
5
5
  import ChatWidget from './ChatWidget';
6
6
  import { DaeryuntalkProvider } from './DaeryuntalkContext';
@@ -17,10 +17,15 @@ type DaeryuntalkProps = {
17
17
  bannerHeight?: number;
18
18
  };
19
19
 
20
- const Daeryuntalk: React.FC<DaeryuntalkProps> = ({ tel = '1800-7905', centerCode = 'CT0000', bannerHeight = 0 }) => {
20
+ const Daeryuntalk: React.FC<DaeryuntalkProps> = ({
21
+ tel = '1800-7905',
22
+ centerCode = 'CT0000',
23
+ bannerHeight = 0
24
+ }) => {
21
25
  const [isOpen, setIsOpen] = useState(false);
22
26
  const [isMobile, setIsMobile] = useState(false);
23
27
  const [isMobileSafari, setIsMobileSafari] = useState(false); // ios + 모바일
28
+ const [isMobileAndroid, setIsMobileAndroid] = useState(false); // android + 모바일
24
29
  const [androidViewportHeight, setAndroidViewportHeight] = useState(0); //
25
30
 
26
31
  const pathName = usePathname();
@@ -70,6 +75,24 @@ const Daeryuntalk: React.FC<DaeryuntalkProps> = ({ tel = '1800-7905', centerCode
70
75
  }
71
76
  };
72
77
 
78
+ useEffect(() => {
79
+ if (typeof window === 'undefined') return;
80
+
81
+ const ua = navigator.userAgent;
82
+
83
+ const isAndroid = /Android/i.test(ua);
84
+ const isMobileDevice = /Mobile/i.test(ua);
85
+
86
+ // Safari(iOS) 제외
87
+ const isSafari = /Safari/i.test(ua) && !/Chrome/i.test(ua);
88
+
89
+ if (isAndroid && isMobileDevice && !isSafari) {
90
+ setIsMobileAndroid(true);
91
+ } else {
92
+ setIsMobileAndroid(false);
93
+ }
94
+ }, []);
95
+
73
96
  useEffect(() => {
74
97
  if (!isMobile) {
75
98
  return;
@@ -247,6 +270,7 @@ const Daeryuntalk: React.FC<DaeryuntalkProps> = ({ tel = '1800-7905', centerCode
247
270
  animationState={animationState}
248
271
  isMobileSafari={isMobileSafari}
249
272
  androidViewportHeight={androidViewportHeight}
273
+ isMobileAndroid={isMobileAndroid}
250
274
  />
251
275
  </DaeryuntalkProvider>
252
276
  </DaeryuntalkToastProvider>
@@ -0,0 +1,11 @@
1
+ import React from 'react';
2
+ interface ChatButtonProps {
3
+ isOpen: boolean;
4
+ onClick: () => void;
5
+ apiVersion?: string;
6
+ isMobile?: boolean;
7
+ hashValue?: string | null;
8
+ bannerHeight?: number;
9
+ }
10
+ declare const ChatButton: React.FC<ChatButtonProps>;
11
+ export default ChatButton;