pcm-agents 1.0.0 → 1.0.2

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 (164) hide show
  1. package/dist/cjs/components-chat-message_33.cjs.entry.js +28 -7
  2. package/dist/cjs/components-chat-message_33.cjs.entry.js.map +1 -1
  3. package/dist/cjs/{conversation-utils-BfkOMf_-.js → conversation-utils-B4jUfmtU.js} +4 -4
  4. package/dist/cjs/{conversation-utils-BfkOMf_-.js.map → conversation-utils-B4jUfmtU.js.map} +1 -1
  5. package/dist/cjs/{index-BnRvF-cO.js → index-Dghp_NL6.js} +3 -3
  6. package/dist/cjs/{index-BnRvF-cO.js.map → index-Dghp_NL6.js.map} +1 -1
  7. package/dist/cjs/index.cjs.js +1 -1
  8. package/dist/cjs/oem-htws-modal.cjs.entry.js +1 -1
  9. package/dist/cjs/oem-jd-modal.cjs.entry.js +2 -2
  10. package/dist/cjs/oem-jlpp-modal.cjs.entry.js +1 -1
  11. package/dist/cjs/oem-jlzz-modal.cjs.entry.js +23 -2
  12. package/dist/cjs/oem-jlzz-modal.cjs.entry.js.map +1 -1
  13. package/dist/cjs/oem-jlzz-modal.entry.cjs.js.map +1 -1
  14. package/dist/cjs/oem-mnct-modal.cjs.entry.js +1 -1
  15. package/dist/cjs/oem-mnms-modal.cjs.entry.js +1 -1
  16. package/dist/cjs/oem-qgqjl-modal.cjs.entry.js +3 -3
  17. package/dist/cjs/pcm-hr-chat-modal.cjs.entry.js +2 -2
  18. package/dist/cjs/pcm-jlsx-modal.cjs.entry.js +174 -6
  19. package/dist/cjs/pcm-jlsx-modal.cjs.entry.js.map +1 -1
  20. package/dist/cjs/pcm-jlsx-modal.entry.cjs.js.map +1 -1
  21. package/dist/cjs/{sentry-reporter-CAeLEFLc.js → sentry-reporter-CgJowDyu.js} +3 -3
  22. package/dist/cjs/{sentry-reporter-CAeLEFLc.js.map → sentry-reporter-CgJowDyu.js.map} +1 -1
  23. package/dist/collection/components/oem-jlzz-modal/oem-jlzz-modal.css +8 -2
  24. package/dist/collection/components/oem-jlzz-modal/oem-jlzz-modal.js +35 -0
  25. package/dist/collection/components/oem-jlzz-modal/oem-jlzz-modal.js.map +1 -1
  26. package/dist/collection/components/pcm-app-chat-modal/pcm-app-chat-modal.css +1 -1
  27. package/dist/collection/components/pcm-jlsx-modal/pcm-jlsx-modal.css +14 -0
  28. package/dist/collection/components/pcm-jlsx-modal/pcm-jlsx-modal.js +173 -5
  29. package/dist/collection/components/pcm-jlsx-modal/pcm-jlsx-modal.js.map +1 -1
  30. package/dist/collection/components/pcm-jlzz-modal/pcm-jlzz-modal.css +8 -2
  31. package/dist/collection/components/pcm-jlzz-modal/pcm-jlzz-modal.js +35 -0
  32. package/dist/collection/components/pcm-jlzz-modal/pcm-jlzz-modal.js.map +1 -1
  33. package/dist/collection/components/pcm-virtual-chat-modal/pcm-virtual-chat-modal.css +1 -1
  34. package/dist/collection/components/pcm-zsk-chat-modal/pcm-zsk-chat-modal.css +1 -1
  35. package/dist/components/components-chat-message.js +1 -1
  36. package/dist/components/components-digital-human.js +1 -1
  37. package/dist/components/components-export-records-modal.js +1 -1
  38. package/dist/components/components-mobile-input-btn.js +1 -1
  39. package/dist/components/components-mobile-upload-btn.js +1 -1
  40. package/dist/components/components-position-selector.js +1 -1
  41. package/dist/components/components-thousand-resume-wrapper.js +1 -1
  42. package/dist/components/components-upload.js +1 -1
  43. package/dist/components/components-voice-input-btn.js +1 -1
  44. package/dist/components/index.js +1 -1
  45. package/dist/components/oem-htws-modal.js +5 -5
  46. package/dist/components/oem-jd-modal.js +5 -5
  47. package/dist/components/oem-jlpp-modal.js +7 -7
  48. package/dist/components/oem-jlsx-modal.js +5 -5
  49. package/dist/components/oem-jlzz-modal.js +27 -6
  50. package/dist/components/oem-jlzz-modal.js.map +1 -1
  51. package/dist/components/oem-mnct-modal.js +7 -7
  52. package/dist/components/oem-mnms-modal.js +8 -8
  53. package/dist/components/oem-qgqjl-modal.js +9 -9
  54. package/dist/components/oem-zygh-modal.js +5 -5
  55. package/dist/components/{p-Bab9bYff.js → p-BDEiyYVl.js} +4 -4
  56. package/dist/components/{p-Bab9bYff.js.map → p-BDEiyYVl.js.map} +1 -1
  57. package/dist/components/{p-DkJ7RM7j.js → p-Bg0KKnpU.js} +3 -3
  58. package/dist/components/{p-DkJ7RM7j.js.map → p-Bg0KKnpU.js.map} +1 -1
  59. package/dist/components/{p-CR7hzwAG.js → p-BhdGTSLg.js} +6 -6
  60. package/dist/components/p-BhdGTSLg.js.map +1 -0
  61. package/dist/components/{p-CUpl5cwz.js → p-C-lvK9NX.js} +3 -3
  62. package/dist/components/{p-CUpl5cwz.js.map → p-C-lvK9NX.js.map} +1 -1
  63. package/dist/components/{p-Bn48g_o5.js → p-C7ubjB1x.js} +3 -3
  64. package/dist/components/{p-Bn48g_o5.js.map → p-C7ubjB1x.js.map} +1 -1
  65. package/dist/components/{p-Cp6_0jsj.js → p-CB7myOe_.js} +3 -3
  66. package/dist/components/{p-Cp6_0jsj.js.map → p-CB7myOe_.js.map} +1 -1
  67. package/dist/components/{p-DNPkGKCS.js → p-CEu-bFot.js} +3 -3
  68. package/dist/components/{p-DNPkGKCS.js.map → p-CEu-bFot.js.map} +1 -1
  69. package/dist/components/{p-BH3zMcBy.js → p-CPq5-i_-.js} +4 -4
  70. package/dist/components/{p-BH3zMcBy.js.map → p-CPq5-i_-.js.map} +1 -1
  71. package/dist/components/{p-Cy_hQiQs.js → p-CzFKth7J.js} +3 -3
  72. package/dist/components/{p-Cy_hQiQs.js.map → p-CzFKth7J.js.map} +1 -1
  73. package/dist/components/{p-CCTgkbh7.js → p-D4RnNrxx.js} +3 -3
  74. package/dist/components/{p-CCTgkbh7.js.map → p-D4RnNrxx.js.map} +1 -1
  75. package/dist/components/{p-DrIjQbpV.js → p-DJDJfWq9.js} +3 -3
  76. package/dist/components/{p-DrIjQbpV.js.map → p-DJDJfWq9.js.map} +1 -1
  77. package/dist/components/{p-DuRuN7gY.js → p-i4wY2JnB.js} +3 -3
  78. package/dist/components/{p-DuRuN7gY.js.map → p-i4wY2JnB.js.map} +1 -1
  79. package/dist/components/{p-BBxWf8DW.js → p-oVAdweom.js} +3 -3
  80. package/dist/components/{p-BBxWf8DW.js.map → p-oVAdweom.js.map} +1 -1
  81. package/dist/components/pcm-1zhanshi-mnms-modal.js +5 -5
  82. package/dist/components/pcm-app-chat-modal.js +1 -1
  83. package/dist/components/pcm-ats-mnms-modal.js +5 -5
  84. package/dist/components/pcm-card.js +1 -1
  85. package/dist/components/pcm-hr-chat-modal.js +2 -2
  86. package/dist/components/pcm-htws-modal.js +8 -8
  87. package/dist/components/pcm-hyzj-modal.js +5 -5
  88. package/dist/components/pcm-jd-modal.js +6 -6
  89. package/dist/components/pcm-jlpp-modal.js +8 -8
  90. package/dist/components/pcm-jlsx-modal.js +177 -9
  91. package/dist/components/pcm-jlsx-modal.js.map +1 -1
  92. package/dist/components/pcm-jlzz-modal.js +28 -7
  93. package/dist/components/pcm-jlzz-modal.js.map +1 -1
  94. package/dist/components/pcm-mnct-modal.js +7 -7
  95. package/dist/components/pcm-mnms-modal.js +8 -8
  96. package/dist/components/pcm-mnms-zp-modal.js +8 -8
  97. package/dist/components/pcm-msbg-modal.js +5 -5
  98. package/dist/components/pcm-qgqjl-modal.js +9 -9
  99. package/dist/components/pcm-virtual-chat-modal.js +1 -1
  100. package/dist/components/pcm-zsk-chat-modal.js +3 -3
  101. package/dist/components/pcm-zsk-chat-modal.js.map +1 -1
  102. package/dist/components/pcm-zygh-modal.js +7 -7
  103. package/dist/components/pcm-zygh-v2-modal.js +7 -7
  104. package/dist/esm/components-chat-message_33.entry.js +28 -7
  105. package/dist/esm/components-chat-message_33.entry.js.map +1 -1
  106. package/dist/esm/{conversation-utils-Ck8snHlu.js → conversation-utils-CLO35DHR.js} +4 -4
  107. package/dist/esm/{conversation-utils-Ck8snHlu.js.map → conversation-utils-CLO35DHR.js.map} +1 -1
  108. package/dist/esm/{index-BR_BEmyI.js → index-KVnu9w-h.js} +4 -4
  109. package/dist/esm/{index-BR_BEmyI.js.map → index-KVnu9w-h.js.map} +1 -1
  110. package/dist/esm/index.js +1 -1
  111. package/dist/esm/oem-htws-modal.entry.js +1 -1
  112. package/dist/esm/oem-jd-modal.entry.js +2 -2
  113. package/dist/esm/oem-jlpp-modal.entry.js +1 -1
  114. package/dist/esm/oem-jlzz-modal.entry.js +23 -2
  115. package/dist/esm/oem-jlzz-modal.entry.js.map +1 -1
  116. package/dist/esm/oem-mnct-modal.entry.js +1 -1
  117. package/dist/esm/oem-mnms-modal.entry.js +1 -1
  118. package/dist/esm/oem-qgqjl-modal.entry.js +3 -3
  119. package/dist/esm/pcm-hr-chat-modal.entry.js +2 -2
  120. package/dist/esm/pcm-jlsx-modal.entry.js +174 -6
  121. package/dist/esm/pcm-jlsx-modal.entry.js.map +1 -1
  122. package/dist/esm/{sentry-reporter-BZPRD4nE.js → sentry-reporter-B4aHQq-A.js} +3 -3
  123. package/dist/esm/{sentry-reporter-BZPRD4nE.js.map → sentry-reporter-B4aHQq-A.js.map} +1 -1
  124. package/dist/pcm-agents/index.esm.js +1 -1
  125. package/dist/pcm-agents/oem-jlzz-modal.entry.esm.js.map +1 -1
  126. package/dist/pcm-agents/{p-4427d0b4.entry.js → p-4d7511e0.entry.js} +2 -2
  127. package/dist/pcm-agents/{p-66459556.entry.js → p-7e8bdfa6.entry.js} +2 -2
  128. package/dist/pcm-agents/{p-7000140e.entry.js → p-8144f0d4.entry.js} +2 -2
  129. package/dist/pcm-agents/{p-4f35fe24.entry.js → p-8256890d.entry.js} +2 -2
  130. package/dist/pcm-agents/p-B4ClCdh9.js +2 -0
  131. package/dist/pcm-agents/{p-CDLRm6tb.js.map → p-B4ClCdh9.js.map} +1 -1
  132. package/dist/pcm-agents/{p-C5UfA3VN.js → p-Bktjt_YJ.js} +2 -2
  133. package/dist/pcm-agents/{p-C5UfA3VN.js.map → p-Bktjt_YJ.js.map} +1 -1
  134. package/dist/pcm-agents/{p-CC_AWE7Q.js → p-CMfzTNOk.js} +2 -2
  135. package/dist/pcm-agents/{p-CC_AWE7Q.js.map → p-CMfzTNOk.js.map} +1 -1
  136. package/dist/pcm-agents/p-aa606968.entry.js +2 -0
  137. package/dist/pcm-agents/p-aa606968.entry.js.map +1 -0
  138. package/dist/pcm-agents/p-dd6362f0.entry.js +2 -0
  139. package/dist/pcm-agents/p-dd6362f0.entry.js.map +1 -0
  140. package/dist/pcm-agents/{p-174577d5.entry.js → p-e2b9a9f2.entry.js} +2 -2
  141. package/dist/pcm-agents/{p-6419b0bb.entry.js → p-eb9b355e.entry.js} +2 -2
  142. package/dist/pcm-agents/{p-8b6019b7.entry.js → p-efb4e819.entry.js} +2 -2
  143. package/dist/pcm-agents/{p-4a767489.entry.js → p-f6683f29.entry.js} +3 -3
  144. package/dist/pcm-agents/{p-4a767489.entry.js.map → p-f6683f29.entry.js.map} +1 -1
  145. package/dist/pcm-agents/pcm-agents.esm.js +1 -1
  146. package/dist/pcm-agents/pcm-jlsx-modal.entry.esm.js.map +1 -1
  147. package/dist/types/components/oem-jlzz-modal/oem-jlzz-modal.d.ts +11 -0
  148. package/dist/types/components/pcm-jlsx-modal/pcm-jlsx-modal.d.ts +7 -2
  149. package/dist/types/components/pcm-jlzz-modal/pcm-jlzz-modal.d.ts +11 -0
  150. package/dist/types/components.d.ts +24 -2
  151. package/package.json +1 -1
  152. package/dist/components/p-CR7hzwAG.js.map +0 -1
  153. package/dist/pcm-agents/p-0abb8e18.entry.js +0 -2
  154. package/dist/pcm-agents/p-0abb8e18.entry.js.map +0 -1
  155. package/dist/pcm-agents/p-99bf652c.entry.js +0 -2
  156. package/dist/pcm-agents/p-99bf652c.entry.js.map +0 -1
  157. package/dist/pcm-agents/p-CDLRm6tb.js +0 -2
  158. /package/dist/pcm-agents/{p-4427d0b4.entry.js.map → p-4d7511e0.entry.js.map} +0 -0
  159. /package/dist/pcm-agents/{p-66459556.entry.js.map → p-7e8bdfa6.entry.js.map} +0 -0
  160. /package/dist/pcm-agents/{p-7000140e.entry.js.map → p-8144f0d4.entry.js.map} +0 -0
  161. /package/dist/pcm-agents/{p-4f35fe24.entry.js.map → p-8256890d.entry.js.map} +0 -0
  162. /package/dist/pcm-agents/{p-174577d5.entry.js.map → p-e2b9a9f2.entry.js.map} +0 -0
  163. /package/dist/pcm-agents/{p-6419b0bb.entry.js.map → p-eb9b355e.entry.js.map} +0 -0
  164. /package/dist/pcm-agents/{p-8b6019b7.entry.js.map → p-efb4e819.entry.js.map} +0 -0
@@ -1 +1 @@
1
- {"file":"p-CUpl5cwz.js","mappings":";;;AAAA,MAAM,0BAA0B,GAAG,u8BAAu8B;;MCe79B,uBAAuB,iBAAAA,kBAAA,CAAA,MAAA,uBAAA,SAAAC,CAAA,CAAA;;;;;;;;;AAClC;;AAEG;IACK,QAAQ,GAAY,KAAK;AAEjC;;AAEG;IACK,gBAAgB,GAAW,EAAE;AAErC;;AAEG;IACK,MAAM,GAAgB,IAAI;AAElC;;AAEG;AACM,IAAA,eAAe;AAExB;;AAEG;AACM,IAAA,iBAAiB;AAE1B;;AAEG;AACM,IAAA,cAAc;IAEN,OAAO,GAAqB,MAAM;IAClC,kBAAkB,GAAW,EAAE;IAExC,cAAc,GAAyB,IAAI;IAC3C,YAAY,GAAuB,IAAI;IACvC,YAAY,GAAe,EAAE;IAC7B,cAAc,GAAW,EAAE;IAC3B,mBAAmB,GAAW,CAAC;IAC/B,eAAe,GAA0C,IAAI;IAErE,oBAAoB,GAAA;QAClB,IAAI,CAAC,0BAA0B,EAAE;;IAG3B,QAAQ,CAAC,MAAc,EAAE,MAAc,EAAA;AAC7C,QAAA,OAAO,IAAI,CAAC,MAAM,KAAK,IAAI,GAAG,MAAM,GAAG,MAAM;;AAGvC,IAAA,UAAU,CAAC,MAAwB,EAAA;AACzC,QAAA,IAAI,CAAC,OAAO,GAAG,MAAM;AACrB,QAAA,IAAI,CAAC,iBAAiB,CAAC,IAAI,CAAC,MAAM,CAAC;;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A,QACE,CACE,CAAA,QAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,IAAI,EAAC,QAAQ,EACb,KAAK,EAAE;AACL,gBAAA,oBAAoB,EAAE,IAAI;AAC1B,gBAAA,WAAW,EAAE,WAAW;AACxB,gBAAA,YAAY,EAAE,YAAY;AAC3B,aAAA,EACD,KAAK,EAAE,KAAK,EACA,YAAA,EAAA,KAAK,EACH,cAAA,EAAA,WAAW,GAAG,MAAM,GAAG,OAAO,EAC5C,QAAQ,EAAE,IAAI,CAAC,QAAQ,IAAI,YAAY,EACvC,OAAO,EAAE,IAAI,CAAC,YAAY,EAEzB,EAAA,YAAY,IACX,CAAK,CAAA,KAAA,EAAA,EAAA,KAAK,EAAC,iBAAiB,EAAC,OAAO,EAAC,WAAW,EAAC,KAAK,EAAC,IAAI,EAAC,MAAM,EAAC,IAAI,EAAC,IAAI,EAAC,cAAc,EAAA,aAAA,EAAa,MAAM,EAAA,EAC5G,CAAM,CAAA,MAAA,EAAA,EAAA,CAAC,EAAC,iOAAiO,EAAG,CAAA,CACxO,KAEN,CAAA,CAAA,KAAA,EAAA,EAAK,OAAO,EAAC,WAAW,EAAC,KAAK,EAAC,IAAI,EAAC,MAAM,EAAC,IAAI,EAAC,IAAI,EAAC,cAAc,EAAA,aAAA,EAAa,MAAM,EAAA,EACpF,CAAM,CAAA,MAAA,EAAA,EAAA,CAAC,EAAC,8EAA8E,EAAG,CAAA,EACzF,CAAM,CAAA,MAAA,EAAA,EAAA,CAAC,EAAC,sGAAsG,EAAG,CAAA,EAChH,WAAW,IAAI,cAAQ,EAAE,EAAC,IAAI,EAAC,EAAE,EAAC,IAAI,EAAC,CAAC,EAAC,GAAG,EAAC,IAAI,EAAC,KAAK,GAAG,CACvD,CACP,CACM;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/components-voice-input-btn/components-voice-input-btn.css?tag=components-voice-input-btn&encapsulation=shadow","src/components/components-voice-input-btn/components-voice-input-btn.tsx"],"sourcesContent":[":host {\n display: inline-flex;\n}\n\n.voice-input-button {\n width: 32px;\n height: 32px;\n display: inline-flex;\n align-items: center;\n justify-content: center;\n padding: 0;\n margin: 0;\n border: 1px solid #d9d9d9;\n border-radius: 6px;\n background: #fff;\n color: #666;\n cursor: pointer;\n transition: background-color 0.2s, color 0.2s, border-color 0.2s;\n}\n\n.voice-input-button:hover:not(:disabled) {\n background-color: #f0f0f0;\n border-color: #bfbfbf;\n}\n\n.voice-input-button:focus-visible {\n outline: 2px solid rgba(46, 110, 223, 0.35);\n outline-offset: 2px;\n}\n\n.voice-input-button:disabled {\n cursor: not-allowed;\n opacity: 0.55;\n}\n\n.voice-input-button.recording {\n background-color: rgba(255, 0, 0, 0.1);\n border-color: rgba(255, 59, 48, 0.45);\n color: #ff3b30;\n animation: pulse 1.5s infinite;\n}\n\n.voice-input-button.converting {\n background-color: rgba(0, 122, 255, 0.1);\n border-color: rgba(0, 122, 255, 0.35);\n color: #007aff;\n}\n\n.converting-icon {\n animation: spin 1.5s linear infinite;\n}\n\n@keyframes pulse {\n 0%, 100% {\n opacity: 1;\n }\n\n 50% {\n opacity: 0.65;\n }\n}\n\n@keyframes spin {\n to {\n transform: rotate(360deg);\n }\n}\n","import { Component, Event, EventEmitter, h, Prop, State } from '@stencil/core';\nimport { convertAudioToText, getSupportedAudioMimeType, uploadFileToBackend } from '../../utils/utils';\nimport { ErrorEventDetail } from '../../utils/error-event';\n\nexport type VoiceInputStatus = 'idle' | 'recording' | 'converting';\n\n/**\n * 通用语音输入按钮\n * 负责录音、上传音频并将语音转换为文字\n */\n@Component({\n tag: 'components-voice-input-btn',\n styleUrls: ['components-voice-input-btn.css'],\n shadow: true,\n})\nexport class ComponentsVoiceInputBtn {\n /**\n * 是否禁用语音输入\n */\n @Prop() disabled: boolean = false;\n\n /**\n * 最大录音时长,单位为秒\n */\n @Prop() maxRecordingTime: number = 60;\n\n /**\n * 组件语言\n */\n @Prop() locale: 'zh' | 'en' = 'zh';\n\n /**\n * 语音识别完成事件,返回识别后的文字\n */\n @Event() voiceRecognized: EventEmitter<string>;\n\n /**\n * 语音输入状态变化事件\n */\n @Event() voiceStatusChange: EventEmitter<VoiceInputStatus>;\n\n /**\n * 语音输入错误事件\n */\n @Event() someErrorEvent: EventEmitter<ErrorEventDetail>;\n\n @State() private _status: VoiceInputStatus = 'idle';\n @State() private _recordingTimeLeft: number = 60;\n\n private _audioRecorder: MediaRecorder | null = null;\n private _audioStream: MediaStream | null = null;\n private _audioChunks: BlobPart[] = [];\n private _audioMimeType: string = '';\n private _recordingStartTime: number = 0;\n private _recordingTimer: ReturnType<typeof setInterval> | null = null;\n\n disconnectedCallback(): void {\n this._releaseRecordingResources();\n }\n\n private _getText(zhText: string, enText: string): string {\n return this.locale === 'en' ? enText : zhText;\n }\n\n private _setStatus(status: VoiceInputStatus): void {\n this._status = status;\n this.voiceStatusChange.emit(status);\n }\n\n private _emitError(error: unknown, message: string): void {\n console.error(message, error);\n this.someErrorEvent.emit({ error, message });\n }\n\n private _handleClick = (): void => {\n if (this.disabled || this._status === 'converting') {\n return;\n }\n\n if (this._status === 'recording') {\n this._stopRecording();\n return;\n }\n\n if (!navigator.mediaDevices?.getUserMedia || !window.MediaRecorder) {\n this._emitError(new Error('MediaRecorder API is unavailable'), this._getText('当前浏览器不支持语音输入', 'Voice input is not supported by this browser'));\n return;\n }\n\n navigator.mediaDevices\n .getUserMedia({ audio: true })\n .then((stream: MediaStream) => this._startRecording(stream))\n .catch((error: unknown) => {\n this._emitError(error, this._getText('无法访问麦克风,请检查麦克风权限', 'Unable to access the microphone. Please check microphone permissions'));\n });\n };\n\n private _startRecording(stream: MediaStream): void {\n this._audioStream = stream;\n\n try {\n const supportedMimeType = getSupportedAudioMimeType();\n this._audioRecorder = supportedMimeType\n ? new MediaRecorder(stream, { mimeType: supportedMimeType })\n : new MediaRecorder(stream);\n this._audioMimeType = this._audioRecorder.mimeType || supportedMimeType || 'audio/webm';\n } catch (error) {\n this._releaseRecordingResources();\n this._emitError(error, this._getText('无法启动录音,请检查麦克风设备', 'Unable to start recording. Please check the microphone'));\n return;\n }\n\n this._audioChunks = [];\n this._recordingStartTime = Date.now();\n this._recordingTimeLeft = this.maxRecordingTime;\n\n this._audioRecorder.ondataavailable = (event: BlobEvent): void => {\n if (event.data.size > 0) {\n this._audioChunks.push(event.data);\n }\n };\n\n this._audioRecorder.onerror = (event: Event): void => {\n this._emitError(event, this._getText('录音失败,请重试', 'Recording failed. Please try again'));\n this._releaseRecordingResources();\n this._setStatus('idle');\n };\n\n this._audioRecorder.onstop = (): void => {\n this._stopMediaStream();\n void this._processAudioRecording();\n };\n\n try {\n this._audioRecorder.start(100);\n this._setStatus('recording');\n this._recordingTimer = setInterval((): void => {\n const elapsedTime = Math.floor((Date.now() - this._recordingStartTime) / 1000);\n this._recordingTimeLeft = Math.max(0, this.maxRecordingTime - elapsedTime);\n if (this._recordingTimeLeft <= 0) {\n this._stopRecording();\n }\n }, 1000);\n } catch (error) {\n this._releaseRecordingResources();\n this._setStatus('idle');\n this._emitError(error, this._getText('开始录音失败,请重试', 'Failed to start recording. Please try again'));\n }\n }\n\n private _stopRecording(): void {\n if (!this._audioRecorder || this._audioRecorder.state === 'inactive') {\n return;\n }\n\n this._clearRecordingTimer();\n this._audioRecorder.stop();\n }\n\n private async _processAudioRecording(): Promise<void> {\n if (this._audioChunks.length === 0) {\n this._setStatus('idle');\n this._emitError(new Error('Recorded audio is empty'), this._getText('未录制到语音内容,请重试', 'No audio was recorded. Please try again'));\n return;\n }\n\n this._setStatus('converting');\n\n try {\n const audioBlob = new Blob(this._audioChunks, { type: this._audioMimeType });\n if (audioBlob.size === 0) {\n throw new Error('Recorded audio is empty');\n }\n\n const extension = this._getFileExtension(this._audioMimeType);\n const audioFile = new File([audioBlob], `audio_input.${extension}`, { type: this._audioMimeType });\n const fileInfo = await uploadFileToBackend(audioFile, {}, { tags: ['audio'] });\n const transcriptionText = await convertAudioToText(fileInfo.cos_key);\n\n if (!transcriptionText) {\n throw new Error('No transcription text returned');\n }\n\n this.voiceRecognized.emit(transcriptionText);\n } catch (error) {\n this._emitError(error, this._getText('语音识别失败,请重试', 'Speech recognition failed. Please try again'));\n } finally {\n this._audioChunks = [];\n this._audioRecorder = null;\n this._setStatus('idle');\n }\n }\n\n private _getFileExtension(mimeType: string): string {\n if (mimeType.includes('mp4')) return 'm4a';\n if (mimeType.includes('ogg')) return 'ogg';\n return 'webm';\n }\n\n private _clearRecordingTimer(): void {\n if (this._recordingTimer) {\n clearInterval(this._recordingTimer);\n this._recordingTimer = null;\n }\n }\n\n private _stopMediaStream(): void {\n this._audioStream?.getTracks().forEach((track: MediaStreamTrack): void => track.stop());\n this._audioStream = null;\n }\n\n private _releaseRecordingResources(): void {\n this._clearRecordingTimer();\n\n if (this._audioRecorder) {\n this._audioRecorder.ondataavailable = null;\n this._audioRecorder.onerror = null;\n this._audioRecorder.onstop = null;\n if (this._audioRecorder.state !== 'inactive') {\n this._audioRecorder.stop();\n }\n }\n\n this._stopMediaStream();\n this._audioRecorder = null;\n this._audioChunks = [];\n }\n\n render() {\n const isRecording = this._status === 'recording';\n const isConverting = this._status === 'converting';\n const title = isRecording\n ? this._getText(`点击停止录音(剩余${this._recordingTimeLeft}秒)`, `Stop recording (${this._recordingTimeLeft}s remaining)`)\n : isConverting\n ? this._getText('正在识别语音...', 'Recognizing speech...')\n : this._getText('语音输入', 'Voice input');\n\n return (\n <button\n type=\"button\"\n class={{\n 'voice-input-button': true,\n 'recording': isRecording,\n 'converting': isConverting,\n }}\n title={title}\n aria-label={title}\n aria-pressed={isRecording ? 'true' : 'false'}\n disabled={this.disabled || isConverting}\n onClick={this._handleClick}\n >\n {isConverting ? (\n <svg class=\"converting-icon\" viewBox=\"0 0 24 24\" width=\"20\" height=\"20\" fill=\"currentColor\" aria-hidden=\"true\">\n <path d=\"M12 4V1L8 5l4 4V6c3.31 0 6 2.69 6 6 0 1.01-.25 1.97-.7 2.8l1.46 1.46C19.54 15.03 20 13.57 20 12c0-4.42-3.58-8-8-8zm0 14c-3.31 0-6-2.69-6-6 0-1.01.25-1.97.7-2.8L5.24 7.74C4.46 8.97 4 10.43 4 12c0 4.42 3.58 8 8 8v3l4-4-4-4v3z\" />\n </svg>\n ) : (\n <svg viewBox=\"0 0 24 24\" width=\"20\" height=\"20\" fill=\"currentColor\" aria-hidden=\"true\">\n <path d=\"M12 14c1.66 0 3-1.34 3-3V5c0-1.66-1.34-3-3-3S9 3.34 9 5v6c0 1.66 1.34 3 3 3z\" />\n <path d=\"M17 11c0 2.76-2.24 5-5 5s-5-2.24-5-5H5c0 3.53 2.61 6.43 6 6.92V21h2v-3.08c3.39-.49 6-3.39 6-6.92h-2z\" />\n {isRecording && <circle cx=\"12\" cy=\"11\" r=\"4\" fill=\"red\" />}\n </svg>\n )}\n </button>\n );\n }\n}\n"],"version":3}
1
+ {"file":"p-C-lvK9NX.js","mappings":";;;AAAA,MAAM,0BAA0B,GAAG,u8BAAu8B;;MCe79B,uBAAuB,iBAAAA,kBAAA,CAAA,MAAA,uBAAA,SAAAC,CAAA,CAAA;;;;;;;;;AAClC;;AAEG;IACK,QAAQ,GAAY,KAAK;AAEjC;;AAEG;IACK,gBAAgB,GAAW,EAAE;AAErC;;AAEG;IACK,MAAM,GAAgB,IAAI;AAElC;;AAEG;AACM,IAAA,eAAe;AAExB;;AAEG;AACM,IAAA,iBAAiB;AAE1B;;AAEG;AACM,IAAA,cAAc;IAEN,OAAO,GAAqB,MAAM;IAClC,kBAAkB,GAAW,EAAE;IAExC,cAAc,GAAyB,IAAI;IAC3C,YAAY,GAAuB,IAAI;IACvC,YAAY,GAAe,EAAE;IAC7B,cAAc,GAAW,EAAE;IAC3B,mBAAmB,GAAW,CAAC;IAC/B,eAAe,GAA0C,IAAI;IAErE,oBAAoB,GAAA;QAClB,IAAI,CAAC,0BAA0B,EAAE;;IAG3B,QAAQ,CAAC,MAAc,EAAE,MAAc,EAAA;AAC7C,QAAA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EAAC,CAAC,EAAC,GAAG,EAAC,IAAI,EAAC,KAAK,GAAG,CACvD,CACP,CACM;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/components-voice-input-btn/components-voice-input-btn.css?tag=components-voice-input-btn&encapsulation=shadow","src/components/components-voice-input-btn/components-voice-input-btn.tsx"],"sourcesContent":[":host {\n display: inline-flex;\n}\n\n.voice-input-button {\n width: 32px;\n height: 32px;\n display: inline-flex;\n align-items: center;\n justify-content: center;\n padding: 0;\n margin: 0;\n border: 1px solid #d9d9d9;\n border-radius: 6px;\n background: #fff;\n color: #666;\n cursor: pointer;\n transition: background-color 0.2s, color 0.2s, border-color 0.2s;\n}\n\n.voice-input-button:hover:not(:disabled) {\n background-color: #f0f0f0;\n border-color: #bfbfbf;\n}\n\n.voice-input-button:focus-visible {\n outline: 2px solid rgba(46, 110, 223, 0.35);\n outline-offset: 2px;\n}\n\n.voice-input-button:disabled {\n cursor: not-allowed;\n opacity: 0.55;\n}\n\n.voice-input-button.recording {\n background-color: rgba(255, 0, 0, 0.1);\n border-color: rgba(255, 59, 48, 0.45);\n color: #ff3b30;\n animation: pulse 1.5s infinite;\n}\n\n.voice-input-button.converting {\n background-color: rgba(0, 122, 255, 0.1);\n border-color: rgba(0, 122, 255, 0.35);\n color: #007aff;\n}\n\n.converting-icon {\n animation: spin 1.5s linear infinite;\n}\n\n@keyframes pulse {\n 0%, 100% {\n opacity: 1;\n }\n\n 50% {\n opacity: 0.65;\n }\n}\n\n@keyframes spin {\n to {\n transform: rotate(360deg);\n }\n}\n","import { Component, Event, EventEmitter, h, Prop, State } from '@stencil/core';\nimport { convertAudioToText, getSupportedAudioMimeType, uploadFileToBackend } from '../../utils/utils';\nimport { ErrorEventDetail } from '../../utils/error-event';\n\nexport type VoiceInputStatus = 'idle' | 'recording' | 'converting';\n\n/**\n * 通用语音输入按钮\n * 负责录音、上传音频并将语音转换为文字\n */\n@Component({\n tag: 'components-voice-input-btn',\n styleUrls: ['components-voice-input-btn.css'],\n shadow: true,\n})\nexport class ComponentsVoiceInputBtn {\n /**\n * 是否禁用语音输入\n */\n @Prop() disabled: boolean = false;\n\n /**\n * 最大录音时长,单位为秒\n */\n @Prop() maxRecordingTime: number = 60;\n\n /**\n * 组件语言\n */\n @Prop() locale: 'zh' | 'en' = 'zh';\n\n /**\n * 语音识别完成事件,返回识别后的文字\n */\n @Event() voiceRecognized: EventEmitter<string>;\n\n /**\n * 语音输入状态变化事件\n */\n @Event() voiceStatusChange: EventEmitter<VoiceInputStatus>;\n\n /**\n * 语音输入错误事件\n */\n @Event() someErrorEvent: EventEmitter<ErrorEventDetail>;\n\n @State() private _status: VoiceInputStatus = 'idle';\n @State() private _recordingTimeLeft: number = 60;\n\n private _audioRecorder: MediaRecorder | null = null;\n private _audioStream: MediaStream | null = null;\n private _audioChunks: BlobPart[] = [];\n private _audioMimeType: string = '';\n private _recordingStartTime: number = 0;\n private _recordingTimer: ReturnType<typeof setInterval> | null = null;\n\n disconnectedCallback(): void {\n this._releaseRecordingResources();\n }\n\n private _getText(zhText: string, enText: string): string {\n return this.locale === 'en' ? enText : zhText;\n }\n\n private _setStatus(status: VoiceInputStatus): void {\n this._status = status;\n this.voiceStatusChange.emit(status);\n }\n\n private _emitError(error: unknown, message: string): void {\n console.error(message, error);\n this.someErrorEvent.emit({ error, message });\n }\n\n private _handleClick = (): void => {\n if (this.disabled || this._status === 'converting') {\n return;\n }\n\n if (this._status === 'recording') {\n this._stopRecording();\n return;\n }\n\n if (!navigator.mediaDevices?.getUserMedia || !window.MediaRecorder) {\n this._emitError(new Error('MediaRecorder API is unavailable'), this._getText('当前浏览器不支持语音输入', 'Voice input is not supported by this browser'));\n return;\n }\n\n navigator.mediaDevices\n .getUserMedia({ audio: true })\n .then((stream: MediaStream) => this._startRecording(stream))\n .catch((error: unknown) => {\n this._emitError(error, this._getText('无法访问麦克风,请检查麦克风权限', 'Unable to access the microphone. Please check microphone permissions'));\n });\n };\n\n private _startRecording(stream: MediaStream): void {\n this._audioStream = stream;\n\n try {\n const supportedMimeType = getSupportedAudioMimeType();\n this._audioRecorder = supportedMimeType\n ? new MediaRecorder(stream, { mimeType: supportedMimeType })\n : new MediaRecorder(stream);\n this._audioMimeType = this._audioRecorder.mimeType || supportedMimeType || 'audio/webm';\n } catch (error) {\n this._releaseRecordingResources();\n this._emitError(error, this._getText('无法启动录音,请检查麦克风设备', 'Unable to start recording. Please check the microphone'));\n return;\n }\n\n this._audioChunks = [];\n this._recordingStartTime = Date.now();\n this._recordingTimeLeft = this.maxRecordingTime;\n\n this._audioRecorder.ondataavailable = (event: BlobEvent): void => {\n if (event.data.size > 0) {\n this._audioChunks.push(event.data);\n }\n };\n\n this._audioRecorder.onerror = (event: Event): void => {\n this._emitError(event, this._getText('录音失败,请重试', 'Recording failed. Please try again'));\n this._releaseRecordingResources();\n this._setStatus('idle');\n };\n\n this._audioRecorder.onstop = (): void => {\n this._stopMediaStream();\n void this._processAudioRecording();\n };\n\n try {\n this._audioRecorder.start(100);\n this._setStatus('recording');\n this._recordingTimer = setInterval((): void => {\n const elapsedTime = Math.floor((Date.now() - this._recordingStartTime) / 1000);\n this._recordingTimeLeft = Math.max(0, this.maxRecordingTime - elapsedTime);\n if (this._recordingTimeLeft <= 0) {\n this._stopRecording();\n }\n }, 1000);\n } catch (error) {\n this._releaseRecordingResources();\n this._setStatus('idle');\n this._emitError(error, this._getText('开始录音失败,请重试', 'Failed to start recording. Please try again'));\n }\n }\n\n private _stopRecording(): void {\n if (!this._audioRecorder || this._audioRecorder.state === 'inactive') {\n return;\n }\n\n this._clearRecordingTimer();\n this._audioRecorder.stop();\n }\n\n private async _processAudioRecording(): Promise<void> {\n if (this._audioChunks.length === 0) {\n this._setStatus('idle');\n this._emitError(new Error('Recorded audio is empty'), this._getText('未录制到语音内容,请重试', 'No audio was recorded. Please try again'));\n return;\n }\n\n this._setStatus('converting');\n\n try {\n const audioBlob = new Blob(this._audioChunks, { type: this._audioMimeType });\n if (audioBlob.size === 0) {\n throw new Error('Recorded audio is empty');\n }\n\n const extension = this._getFileExtension(this._audioMimeType);\n const audioFile = new File([audioBlob], `audio_input.${extension}`, { type: this._audioMimeType });\n const fileInfo = await uploadFileToBackend(audioFile, {}, { tags: ['audio'] });\n const transcriptionText = await convertAudioToText(fileInfo.cos_key);\n\n if (!transcriptionText) {\n throw new Error('No transcription text returned');\n }\n\n this.voiceRecognized.emit(transcriptionText);\n } catch (error) {\n this._emitError(error, this._getText('语音识别失败,请重试', 'Speech recognition failed. Please try again'));\n } finally {\n this._audioChunks = [];\n this._audioRecorder = null;\n this._setStatus('idle');\n }\n }\n\n private _getFileExtension(mimeType: string): string {\n if (mimeType.includes('mp4')) return 'm4a';\n if (mimeType.includes('ogg')) return 'ogg';\n return 'webm';\n }\n\n private _clearRecordingTimer(): void {\n if (this._recordingTimer) {\n clearInterval(this._recordingTimer);\n this._recordingTimer = null;\n }\n }\n\n private _stopMediaStream(): void {\n this._audioStream?.getTracks().forEach((track: MediaStreamTrack): void => track.stop());\n this._audioStream = null;\n }\n\n private _releaseRecordingResources(): void {\n this._clearRecordingTimer();\n\n if (this._audioRecorder) {\n this._audioRecorder.ondataavailable = null;\n this._audioRecorder.onerror = null;\n this._audioRecorder.onstop = null;\n if (this._audioRecorder.state !== 'inactive') {\n this._audioRecorder.stop();\n }\n }\n\n this._stopMediaStream();\n this._audioRecorder = null;\n this._audioChunks = [];\n }\n\n render() {\n const isRecording = this._status === 'recording';\n const isConverting = this._status === 'converting';\n const title = isRecording\n ? this._getText(`点击停止录音(剩余${this._recordingTimeLeft}秒)`, `Stop recording (${this._recordingTimeLeft}s remaining)`)\n : isConverting\n ? this._getText('正在识别语音...', 'Recognizing speech...')\n : this._getText('语音输入', 'Voice input');\n\n return (\n <button\n type=\"button\"\n class={{\n 'voice-input-button': true,\n 'recording': isRecording,\n 'converting': isConverting,\n }}\n title={title}\n aria-label={title}\n aria-pressed={isRecording ? 'true' : 'false'}\n disabled={this.disabled || isConverting}\n onClick={this._handleClick}\n >\n {isConverting ? (\n <svg class=\"converting-icon\" viewBox=\"0 0 24 24\" width=\"20\" height=\"20\" fill=\"currentColor\" aria-hidden=\"true\">\n <path d=\"M12 4V1L8 5l4 4V6c3.31 0 6 2.69 6 6 0 1.01-.25 1.97-.7 2.8l1.46 1.46C19.54 15.03 20 13.57 20 12c0-4.42-3.58-8-8-8zm0 14c-3.31 0-6-2.69-6-6 0-1.01.25-1.97.7-2.8L5.24 7.74C4.46 8.97 4 10.43 4 12c0 4.42 3.58 8 8 8v3l4-4-4-4v3z\" />\n </svg>\n ) : (\n <svg viewBox=\"0 0 24 24\" width=\"20\" height=\"20\" fill=\"currentColor\" aria-hidden=\"true\">\n <path d=\"M12 14c1.66 0 3-1.34 3-3V5c0-1.66-1.34-3-3-3S9 3.34 9 5v6c0 1.66 1.34 3 3 3z\" />\n <path d=\"M17 11c0 2.76-2.24 5-5 5s-5-2.24-5-5H5c0 3.53 2.61 6.43 6 6.92V21h2v-3.08c3.39-.49 6-3.39 6-6.92h-2z\" />\n {isRecording && <circle cx=\"12\" cy=\"11\" r=\"4\" fill=\"red\" />}\n </svg>\n )}\n </button>\n );\n }\n}\n"],"version":3}
@@ -1,6 +1,6 @@
1
1
  import { p as proxyCustomElement, H, c as createEvent, h } from './p-CR7WLzmM.js';
2
2
  import { q as qrcode } from './p-D483moFs.js';
3
- import { s as sendHttpRequest, P as PCM_DOMAIN } from './p-DuRuN7gY.js';
3
+ import { s as sendHttpRequest, P as PCM_DOMAIN } from './p-i4wY2JnB.js';
4
4
  import { M as Message } from './p-D39f_W8k.js';
5
5
 
6
6
  // 文件上传流水号SDK
@@ -216,6 +216,6 @@ function defineCustomElement() {
216
216
  defineCustomElement();
217
217
 
218
218
  export { ComponentsMobileInputBtn as C, defineCustomElement as d };
219
- //# sourceMappingURL=p-Bn48g_o5.js.map
219
+ //# sourceMappingURL=p-C7ubjB1x.js.map
220
220
 
221
- //# sourceMappingURL=p-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I,CAAC,KAAK,CAAC;gBACxB,IAAI,CAAC,kBAAkB,EAAE;aAC5B,mBAAU,CACT,CACJ,CACJ,CAER;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/components-mobile-input-btn/uploadNumberSDK.ts","src/components/components-mobile-input-btn/components-mobile-input-btn.css?tag=components-mobile-input-btn&encapsulation=shadow","src/global/global.css?tag=components-mobile-input-btn&encapsulation=shadow","src/global/host.css?tag=components-mobile-input-btn&encapsulation=shadow","src/components/components-mobile-input-btn/components-mobile-input-btn.tsx"],"sourcesContent":["import { sendHttpRequest } from \"../../utils/utils\";\r\n\r\n// 文件上传流水号SDK\r\nconst uploadNumberSDK = {\r\n number: '',\r\n isWorking: false,\r\n close: async function (params?: {\r\n onOk?: () => void;\r\n onError?: () => void;\r\n }) {\r\n const { onOk, onError } = params ?? {};\r\n const { number } = this;\r\n if (number) {\r\n const result = await sendHttpRequest({\r\n url: `/resource/update_id/${number}`,\r\n method: 'delete',\r\n });\r\n if (result.success) {\r\n this.number = '';\r\n onOk?.();\r\n } else {\r\n onError?.();\r\n }\r\n }\r\n }\r\n}\r\n\r\nexport default uploadNumberSDK;",".mobile-upload {\r\n display: flex;\r\n justify-content: flex-end;\r\n margin-bottom: 4px;\r\n}\r\n\r\n.btn {\r\n position: relative;\r\n padding: 4px 8px;\r\n border-radius: 4px;\r\n cursor: pointer;\r\n overflow: hidden;\r\n display: flex;\r\n justify-content: center;\r\n align-items: center;\r\n white-space: nowrap;\r\n}\r\n\r\n.btn::after {\r\n content: '';\r\n position: absolute;\r\n top: 0;\r\n left: 0;\r\n width: 100%;\r\n height: 100%;\r\n}\r\n\r\n.btn:hover::after {\r\n background-color: rgba(0,0,0,0.04);\r\n}\r\n\r\n.btn-link {\r\n color: #0D75FB;\r\n}\r\n\r\n.btn-default {\r\n background-color: #ffffff;\r\n color: #0D75FB;\r\n border: 1px solid #0D75FB;\r\n}\r\n\r\n.btn-primary {\r\n background-color: #0D75FB;\r\n color: #ffffff;\r\n}\r\n\r\n\r\n.loading {\r\n font-size: 12px;\r\n color: #999999;\r\n}\r\n\r\n.mask {\r\n position: fixed;\r\n top: 0;\r\n left: 0;\r\n width: 100%;\r\n height: 100%;\r\n background-color: rgba(0,0,0,0.5);\r\n display: flex;\r\n justify-content: center;\r\n align-items: center;\r\n z-index: 10000;\r\n}\r\n\r\n.mask .upload-wrapper {\r\n width: 540px;\r\n max-width: 80%;\r\n max-height: 80%;\r\n background-color: #ffffff;\r\n padding: 32px 24px;\r\n border-radius: 16px;\r\n overflow-y: auto;\r\n}\r\n\r\n.mask .upload-wrapper .upload-box {\r\n display: flex;\r\n flex-direction: column;\r\n align-items: center;\r\n}\r\n\r\n.time-expire {\r\n margin: 8px 0;\r\n text-align: center;\r\n font-size: 12px;\r\n color: #555555;\r\n}\r\n\r\n.time-count-down {\r\n margin-left: 8px;\r\n color: #0D75FB;\r\n}\r\n\r\n.alert-tip {\r\n margin-top: 8px;\r\n text-align: center;\r\n font-size: 12px;\r\n color: #999999;\r\n}\r\n\r\n.qrcode-wrapper {\r\n width: 160px;\r\n height: 160px;\r\n display: flex;\r\n justify-content: center;\r\n align-items: center;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 4px;\r\n padding: 1px;\r\n}\r\n\r\n.qrcode-wrapper .qrcode {\r\n width: 100%;\r\n height: 100%;\r\n}\r\n\r\n.modal-footer {\r\n margin-top: 32px;\r\n display: flex;\r\n justify-content: center;\r\n align-items: center;\r\n gap: 8px;\r\n}\r\n\r\n.modal-footer .btn {\r\n min-width: 100px;\r\n}\r\n\r\n.qrcode-textarea {\r\n width: calc(100% - 16px);\r\n min-height: 120px;\r\n border: 1px solid #ddd;\r\n border-radius: 4px;\r\n resize: vertical;\r\n font-family: inherit;\r\n font-size: 14px;\r\n line-height: 1.5;\r\n transition: border-color 0.3s;\r\n padding: 8px;\r\n}","/* 模态框基础样式 */\r\n.modal-overlay {\r\n position: fixed;\r\n top: 0;\r\n left: 0;\r\n right: 0;\r\n bottom: 0;\r\n background-color: rgba(0, 0, 0, 0.5);\r\n display: flex;\r\n z-index: 1000;\r\n overflow-y: auto;\r\n}\r\n\r\n/* 全屏模式下的overlay样式 - 改为基于父组件 */\r\n.fullscreen-overlay {\r\n padding: 0;\r\n background-color: rgba(0, 0, 0, 0.7);\r\n /* 改为基于父组件的全屏 */\r\n position: absolute;\r\n width: 100%;\r\n height: auto;\r\n}\r\n\r\n.modal-container {\r\n background-color: #fff;\r\n border-radius: 8px;\r\n width: 100%;\r\n display: flex;\r\n flex-direction: column;\r\n position: relative;\r\n margin: 5vh auto auto auto;\r\n transition: all 0.3s ease-out;\r\n overflow: hidden;\r\n}\r\n\r\n/* 全屏模式样式 - 改为基于父组件 */\r\n.modal-container.fullscreen {\r\n width: 100%;\r\n max-width: none;\r\n height: 100%;\r\n border-radius: 0;\r\n margin: 0;\r\n display: flex;\r\n flex-direction: column;\r\n max-height: 100%;\r\n}\r\n\r\n/* PC端布局 */\r\n.pc-layout {\r\n width: 80%;\r\n max-width: 600px;\r\n min-width: 320px;\r\n}\r\n\r\n/* 响应式布局 */\r\n@media screen and (max-width: 768px) {\r\n .pc-layout {\r\n width: 95%;\r\n }\r\n\r\n .modal-overlay {\r\n padding: 10px 0px 0px 0px;\r\n }\r\n\r\n .modal-container.fullscreen {\r\n /* 移动端也基于父组件尺寸 */\r\n width: 100%;\r\n height: 100%;\r\n max-height: 100%;\r\n border-radius: 16px 16px 0 0;\r\n /* 保留安全区域支持 */\r\n padding: env(safe-area-inset-top) 0 env(safe-area-inset-bottom);\r\n }\r\n}\r\n\r\n/* 模态框头部样式 */\r\n.modal-header {\r\n display: flex;\r\n justify-content: space-between;\r\n align-items: center;\r\n padding: 4px 16px;\r\n height: 50px;\r\n border-bottom: 1px solid #e8e8e8;\r\n flex-shrink: 0;\r\n}\r\n\r\n.header-left {\r\n display: flex;\r\n align-items: center;\r\n gap: 8px;\r\n font-size: 16px;\r\n font-weight: 600;\r\n color: #333;\r\n}\r\n\r\n.header-icon {\r\n width: 24px;\r\n height: 24px;\r\n}\r\n\r\n.close-button {\r\n background: transparent;\r\n border: none;\r\n cursor: pointer;\r\n padding: 8px;\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n width: 32px;\r\n height: 32px;\r\n border-radius: 4px;\r\n}\r\n\r\n.close-button:hover {\r\n background-color: rgba(0, 0, 0, 0.04);\r\n}\r\n\r\n.close-button span {\r\n font-size: 24px;\r\n line-height: 1;\r\n color: #999;\r\n}\r\n\r\n.close-button:hover span {\r\n color: #666;\r\n}\r\n\r\n\r\n/* 文件上传区域通用样式 */\r\n.upload-area {\r\n cursor: pointer;\r\n width: 100%;\r\n}\r\n\r\n\r\n.upload-placeholder {\r\n transition: all 0.3s ease;\r\n display: flex;\r\n flex-direction: column;\r\n align-items: center;\r\n background: rgba(0, 0, 0, 0.02);\r\n border: 1px dashed #d9d9d9;\r\n border-radius: 8px;\r\n cursor: pointer;\r\n}\r\n\r\n.upload-placeholder:hover {\r\n border: 1px dashed #1890ff;\r\n}\r\n\r\n.upload-placeholder img {\r\n margin-top: 8px;\r\n width: 50px;\r\n height: 50px;\r\n}\r\n\r\n.upload-placeholder .upload-text {\r\n margin: 4px 0;\r\n color: #332F39;\r\n font-size: 14px;\r\n}\r\n\r\n.upload-placeholder .upload-hint {\r\n font-size: 14px;\r\n color: #949AA5;\r\n margin-top: 8px;\r\n padding: 0px 10px;\r\n text-align: center;\r\n white-space: normal;\r\n word-wrap: break-word;\r\n word-break: break-all;\r\n line-height: 1.4;\r\n}\r\n\r\n\r\n/* 文件项样式 */\r\n.file-item {\r\n position: relative;\r\n padding: 16px;\r\n border: 1px solid #e2e8f0;\r\n border-radius: 8px;\r\n transition: border-color 0.3s;\r\n cursor: pointer;\r\n margin-bottom: 16px;\r\n display: flex;\r\n justify-content: space-between;\r\n align-items: center;\r\n}\r\n\r\n.file-item:hover {\r\n border-color: #0D75FB;\r\n}\r\n\r\n.file-item-content {\r\n display: flex;\r\n align-items: center;\r\n gap: 8px;\r\n flex: 1;\r\n min-width: 0;\r\n overflow: hidden;\r\n}\r\n\r\n.file-icon {\r\n color: #0D75FB;\r\n flex-shrink: 0;\r\n}\r\n\r\n.file-name {\r\n font-weight: 500;\r\n white-space: nowrap;\r\n overflow: hidden;\r\n text-overflow: ellipsis;\r\n max-width: calc(100% - 50px);\r\n}\r\n\r\n.remove-file {\r\n background: transparent;\r\n border: none;\r\n color: #94a3b8;\r\n cursor: pointer;\r\n font-size: 18px;\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n padding: 4px;\r\n margin-left: 8px;\r\n border-radius: 4px;\r\n transition: all 0.2s;\r\n min-width: 30px;\r\n min-height: 30px;\r\n}\r\n\r\n.remove-file:hover {\r\n background-color: #f1f5f9;\r\n color: #475569;\r\n}\r\n\r\n.file-input {\r\n display: none;\r\n}\r\n\r\n\r\n\r\n/* 输入容器样式 */\r\n.input-container {\r\n padding: 20px;\r\n display: flex;\r\n flex-direction: column;\r\n height: calc(100% - 50px);\r\n background: linear-gradient(150deg, #2a6ee933, #0000 50%) 0 0 / 400px 200px no-repeat, #fff;\r\n /* 减去header高度 */\r\n overflow-y: auto;\r\n}\r\n\r\n.input-container h3 {\r\n margin-top: 0;\r\n margin-bottom: 20px;\r\n font-size: 18px;\r\n color: #333;\r\n text-align: center;\r\n}\r\n\r\n/* JD输入区域样式 */\r\n.jd-input-section {\r\n margin-bottom: 20px;\r\n}\r\n\r\n.jd-input-section label {\r\n display: block;\r\n margin-bottom: 8px;\r\n font-weight: 500;\r\n color: #333;\r\n}\r\n\r\n.job-description-textarea {\r\n width: calc(100% - 16px);\r\n border: 1px solid #ddd;\r\n border-radius: 4px;\r\n resize: vertical;\r\n font-family: inherit;\r\n font-size: 14px;\r\n line-height: 1.5;\r\n transition: border-color 0.3s;\r\n padding: 8px;\r\n}\r\n\r\n.job-description-textarea:focus {\r\n outline: none;\r\n border-color: #1890ff;\r\n box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.2);\r\n}\r\n\r\n/* 简历上传区域样式 */\r\n.resume-upload-section {\r\n margin-bottom: 20px;\r\n width: 100%;\r\n display: flex;\r\n flex-direction: column;\r\n}\r\n\r\n.resume-upload-section label {\r\n display: block;\r\n margin-bottom: 8px;\r\n font-weight: 500;\r\n color: #333;\r\n}\r\n\r\n/* 面试设置区域 */\r\n.interview-settings-section {\r\n margin-bottom: 24px;\r\n padding: 20px;\r\n background-color: #f8f9fa;\r\n border-radius: 8px;\r\n border: 1px solid #e9ecef;\r\n}\r\n\r\n.settings-row {\r\n margin-bottom: 20px;\r\n}\r\n\r\n.settings-row:last-child {\r\n margin-bottom: 0;\r\n}\r\n\r\n.settings-label {\r\n display: block;\r\n font-weight: 500;\r\n color: #333;\r\n margin-bottom: 12px;\r\n font-size: 14px;\r\n}\r\n\r\n/* 题目数量滑块样式 */\r\n.question-number-section {\r\n width: 100%;\r\n}\r\n\r\n.slider-container {\r\n display: flex;\r\n align-items: center;\r\n gap: 12px;\r\n}\r\n\r\n.question-slider {\r\n flex: 1;\r\n height: 6px;\r\n background: #ddd;\r\n outline: none;\r\n border-radius: 3px;\r\n -webkit-appearance: none;\r\n appearance: none;\r\n}\r\n\r\n.question-slider::-webkit-slider-thumb {\r\n -webkit-appearance: none;\r\n appearance: none;\r\n width: 20px;\r\n height: 20px;\r\n background: #0D75FB;\r\n cursor: pointer;\r\n border-radius: 50%;\r\n box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);\r\n}\r\n\r\n.question-slider::-moz-range-thumb {\r\n width: 20px;\r\n height: 20px;\r\n background: #0D75FB;\r\n cursor: pointer;\r\n border-radius: 50%;\r\n border: none;\r\n box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);\r\n}\r\n\r\n.slider-value {\r\n font-weight: 600;\r\n color: #0D75FB;\r\n font-size: 14px;\r\n min-width: 30px;\r\n text-align: center;\r\n}\r\n\r\n/* 开关样式 */\r\n.analysis-toggle-section {\r\n width: 100%;\r\n}\r\n\r\n.toggle-container {\r\n display: flex;\r\n align-items: center;\r\n gap: 12px;\r\n}\r\n\r\n.toggle-switch {\r\n position: relative;\r\n display: inline-block;\r\n width: 44px;\r\n height: 24px;\r\n}\r\n\r\n.toggle-switch input {\r\n opacity: 0;\r\n width: 0;\r\n height: 0;\r\n}\r\n\r\n.toggle-slider {\r\n position: absolute;\r\n cursor: pointer;\r\n top: 0;\r\n left: 0;\r\n right: 0;\r\n bottom: 0;\r\n background-color: #ccc;\r\n transition: 0.3s;\r\n border-radius: 24px;\r\n}\r\n\r\n.toggle-slider:before {\r\n position: absolute;\r\n content: \"\";\r\n height: 18px;\r\n width: 18px;\r\n left: 3px;\r\n bottom: 3px;\r\n background-color: white;\r\n transition: 0.3s;\r\n border-radius: 50%;\r\n box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);\r\n}\r\n\r\ninput:checked + .toggle-slider {\r\n background-color: #0D75FB;\r\n}\r\n\r\ninput:checked + .toggle-slider:before {\r\n transform: translateX(20px);\r\n}\r\n\r\n.toggle-text {\r\n font-size: 14px;\r\n color: #666;\r\n font-weight: 500;\r\n}\r\n\r\n/* 提交按钮通用样式 */\r\n.submit-button {\r\n margin-top: 10px;\r\n padding: 10px 30px;\r\n background: #0D75FB;\r\n color: white;\r\n border: none;\r\n border-radius: 4px;\r\n font-size: 16px;\r\n cursor: pointer;\r\n transition: all 0.3s ease;\r\n width: 100%;\r\n max-width: 400px;\r\n align-self: center;\r\n}\r\n\r\n.submit-button:hover {\r\n background-color: #40a9ff;\r\n}\r\n\r\n.submit-button:disabled {\r\n background-color: rgba(0,0,0,0.04);\r\n color: rgba(0,0,0,0.25);\r\n cursor: not-allowed;\r\n}\r\n\r\n\r\n\r\n/* AI免责声明和备案信息样式 */\r\n.ai-disclaimer {\r\n margin-top: 16px;\r\n text-align: center;\r\n font-size: 12px;\r\n color: #999;\r\n line-height: 1.5;\r\n}\r\n\r\n.ai-disclaimer p {\r\n margin: 4px 0;\r\n}\r\n\r\n.beian-info {\r\n display: flex;\r\n justify-content: center;\r\n flex-wrap: wrap;\r\n gap: 4px;\r\n}\r\n\r\n.ai-disclaimer a {\r\n color: #666;\r\n text-decoration: none;\r\n transition: color 0.2s ease;\r\n}\r\n\r\n.ai-disclaimer a:hover {\r\n color: #1890ff;\r\n text-decoration: underline;\r\n}\r\n\r\n/* 添加加载状态的样式 */\r\n.loading-container {\r\n display: flex;\r\n flex-direction: column;\r\n align-items: center;\r\n justify-content: center;\r\n height: 100%;\r\n padding: 24px;\r\n }\r\n \r\n .loading-spinner {\r\n width: 40px;\r\n height: 40px;\r\n border: 4px solid rgba(0, 0, 0, 0.1);\r\n border-radius: 50%;\r\n border-top-color: var(--pcm-primary-color, #1890ff);\r\n animation: spin 1s linear infinite;\r\n margin-bottom: 16px;\r\n }\r\n \r\n .loading-text {\r\n font-size: 16px;\r\n color: var(--pcm-text-color, #333);\r\n }\r\n \r\n @keyframes spin {\r\n 0% { transform: rotate(0deg); }\r\n 100% { transform: rotate(360deg); }\r\n }\r\n\r\n/* 历史会话按钮 */\r\n.header-history-button {\r\n display: inline-flex;\r\n align-items: center;\r\n justify-content: center;\r\n gap: 4px;\r\n padding: 4px 8px;\r\n border: none;\r\n border-radius: 4px;\r\n background: transparent;\r\n color: #bbb;\r\n cursor: pointer;\r\n font-size: 13px;\r\n font-family: inherit;\r\n line-height: 1;\r\n transition: all 0.2s ease;\r\n flex-shrink: 0;\r\n white-space: nowrap;\r\n}\r\n\r\n.header-history-button svg {\r\n width: 16px;\r\n height: 16px;\r\n display: block;\r\n flex-shrink: 0;\r\n}\r\n\r\n.header-history-button:hover {\r\n background-color: rgba(0, 0, 0, 0.04);\r\n color: #666;\r\n}\r\n\r\n.header-history-button:focus-visible {\r\n outline: 2px solid rgba(13, 117, 251, 0.35);\r\n outline-offset: 2px;\r\n}\r\n\r\n/* 历史会话抽屉内容 */\r\n.history-drawer-content {\r\n height: 100%;\r\n display: flex;\r\n flex-direction: column;\r\n}\r\n\r\n.conversation-list {\r\n flex: 1;\r\n overflow-y: auto;\r\n padding: 8px 0;\r\n}\r\n\r\n.loading-conversations,\r\n.empty-conversations {\r\n display: flex;\r\n flex-direction: column;\r\n align-items: center;\r\n justify-content: center;\r\n padding: 40px 20px;\r\n color: #999;\r\n}\r\n\r\n.loading-conversations .loading-spinner-small {\r\n margin-bottom: 12px;\r\n}\r\n\r\n.conversation-item {\r\n display: flex;\r\n align-items: center;\r\n justify-content: space-between;\r\n padding: 12px 16px;\r\n margin: 0 8px 4px 8px;\r\n border-radius: 8px;\r\n cursor: pointer;\r\n transition: all 0.2s ease;\r\n border: 1px solid transparent;\r\n}\r\n\r\n.conversation-item:hover {\r\n background: #f5f5f5;\r\n}\r\n\r\n.conversation-info {\r\n flex: 1;\r\n min-width: 0;\r\n}\r\n\r\n.conversation-title {\r\n font-size: 14px;\r\n font-weight: 500;\r\n color: #262626;\r\n margin-bottom: 4px;\r\n overflow: hidden;\r\n text-overflow: ellipsis;\r\n white-space: nowrap;\r\n}\r\n\r\n.conversation-meta {\r\n display: flex;\r\n align-items: center;\r\n gap: 8px;\r\n font-size: 12px;\r\n color: #8c8c8c;\r\n}\r\n\r\n.conversation-time {\r\n flex-shrink: 0;\r\n}\r\n\r\n.message-count {\r\n flex-shrink: 0;\r\n}\r\n\r\n.conversation-status {\r\n padding: 2px 6px;\r\n border-radius: 4px;\r\n font-size: 11px;\r\n font-weight: 500;\r\n}\r\n\r\n.conversation-status.completed {\r\n background: #f6ffed;\r\n color: #52c41a;\r\n}\r\n\r\n.conversation-status.running {\r\n background: #fff7e6;\r\n color: #fa8c16;\r\n}\r\n\r\n.header-history-entry {\r\n display: inline-flex;\r\n align-items: center;\r\n justify-content: center;\r\n margin-left: 8px;\r\n padding: 4px 8px;\r\n border: none;\r\n border-radius: 4px;\r\n background: #e6f7ff;\r\n color: #1890ff;\r\n cursor: pointer;\r\n font-size: 12px;\r\n font-family: inherit;\r\n line-height: 1;\r\n white-space: nowrap;\r\n transition: all 0.2s ease;\r\n}\r\n\r\n.header-history-entry:hover {\r\n background: #bae7ff;\r\n color: #0958d9;\r\n transform: translateY(-1px);\r\n}\r\n\r\n.header-history-entry:focus-visible {\r\n outline: 2px solid rgba(13, 117, 251, 0.35);\r\n outline-offset: 2px;\r\n}\r\n\r\n.history-pagination {\r\n display: flex;\r\n align-items: center;\r\n justify-content: space-between;\r\n gap: 12px;\r\n padding: 12px 16px 16px;\r\n border-top: 1px solid #f0f0f0;\r\n}\r\n\r\n.history-pagination-button {\r\n min-width: 72px;\r\n padding: 6px 12px;\r\n border: 1px solid #d9d9d9;\r\n border-radius: 6px;\r\n background: #fff;\r\n color: #595959;\r\n cursor: pointer;\r\n font-size: 12px;\r\n transition: all 0.2s ease;\r\n}\r\n\r\n.history-pagination-button:hover:not(:disabled) {\r\n border-color: #1890ff;\r\n color: #1890ff;\r\n background: #e6f7ff;\r\n}\r\n\r\n.history-pagination-button:disabled {\r\n border-color: #f0f0f0;\r\n color: #bfbfbf;\r\n background: #fafafa;\r\n cursor: not-allowed;\r\n}\r\n\r\n.history-pagination-info {\r\n flex: 1;\r\n text-align: center;\r\n color: #8c8c8c;\r\n font-size: 12px;\r\n}\r\n \r\n",":host {\r\n /* 字体相关属性 */\r\n font-size: 16px;\r\n font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;\r\n font-weight: normal;\r\n font-style: normal;\r\n font-variant: normal;\r\n line-height: 1.5;\r\n letter-spacing: normal;\r\n word-spacing: normal;\r\n \r\n /* 文本相关属性 */\r\n color: #333; /* 重置文字颜色,避免继承外部的red */\r\n text-align: left;\r\n text-indent: 0;\r\n text-transform: none;\r\n white-space: normal;\r\n word-wrap: normal;\r\n word-break: normal;\r\n \r\n /* 可见性 */\r\n visibility: visible;\r\n \r\n /* 列表相关 */\r\n list-style: none;\r\n list-style-image: none;\r\n list-style-position: outside;\r\n list-style-type: disc;\r\n \r\n /* 表格相关 */\r\n border-collapse: separate;\r\n border-spacing: 0;\r\n caption-side: top;\r\n empty-cells: show;\r\n table-layout: auto;\r\n \r\n /* 引用 */\r\n quotes: auto;\r\n \r\n /* 光标 */\r\n cursor: auto;\r\n \r\n /* 文本方向 */\r\n direction: ltr;\r\n \r\n /* 打印相关 */\r\n orphans: 2;\r\n widows: 2;\r\n page-break-inside: auto;\r\n \r\n /* 其他可能被继承的属性 */\r\n text-decoration: none;\r\n text-shadow: none;\r\n \r\n /* 确保组件有独立的盒模型 */\r\n box-sizing: border-box;\r\n \r\n /* 重置一些可能影响布局的继承属性 */\r\n writing-mode: horizontal-tb;\r\n text-orientation: mixed;\r\n}","import { Component, Prop, State, Event, h, EventEmitter } from \"@stencil/core\";\r\nimport qrcode from 'qrcode-generator'\r\nimport { sendHttpRequest, PCM_DOMAIN } from \"../../utils/utils\";\r\nimport { Message } from \"../../services/message.service\";\r\nimport uploadNumberSDK from \"./uploadNumberSDK\";\r\n\r\n@Component({\r\n tag: 'components-mobile-input-btn',\r\n styleUrls: ['components-mobile-input-btn.css', '../../global/global.css', '../../global/host.css'],\r\n shadow: true,\r\n})\r\nexport class ComponentsMobileInputBtn {\r\n // 标题\r\n @Prop() name: string = '';\r\n /**\r\n * 最大文件数\r\n */\r\n @Prop() rows: number = 8;\r\n /**\r\n * 最大文件大小\r\n */\r\n @Prop() maxLength: number = undefined;\r\n /**\r\n * 填写请求头\r\n */\r\n @Prop() uploadHeaders?: Record<string, any>;\r\n /**\r\n * 填写请求参数\r\n */\r\n @Prop() uploadParams?: Record<string, any>;\r\n\r\n @State() QR_CODE_VALID_TIME: number = 0;\r\n @State() open: boolean = false;\r\n @State() mobileUrl: string = '';\r\n @State() setStartMobileUpload: boolean = false;\r\n @State() startMobileUploadLoading: boolean = false;\r\n @State() qrcodeStatus: 'active' | 'expired' | 'loading' | undefined = 'loading';\r\n @State() value: string = '';\r\n @State() expireTime: string = ''; // 过期时间\r\n\r\n @Event() ok: EventEmitter<string>;\r\n\r\n private setStartMobileUploadWrapper = (e: boolean) => {\r\n uploadNumberSDK.isWorking = e;\r\n this.setStartMobileUpload = e;\r\n }\r\n\r\n @State() qrcodeUrl: string = '';\r\n private setMobileUrlWrapper = (e: string) => {\r\n this.mobileUrl = e;\r\n if (e) {\r\n const qr = qrcode(0, 'M');\r\n qr.addData(e);\r\n qr.make();\r\n this.qrcodeUrl = qr.createDataURL(4, 0);\r\n } else {\r\n this.qrcodeUrl = '';\r\n }\r\n }\r\n\r\n // 轮询流水号数据\r\n private pollingQueryNumberInfo = async (num: any) => {\r\n const res = await sendHttpRequest({\r\n url: `/sdk/v1/update_id/${num}/status`,\r\n method: 'get',\r\n });\r\n if (res?.success) {\r\n const resData: {\r\n update_id?: any;\r\n tags?: any;\r\n status?: any;\r\n file_list?: any;\r\n user_id?: any;\r\n cfg?: any;\r\n iat?: any;\r\n exp?: any;\r\n custom_data?: any;\r\n } = res.data ?? {};\r\n const { custom_data } = resData;\r\n this.value = custom_data ?? '';\r\n }\r\n if (uploadNumberSDK.isWorking) {\r\n setTimeout(() => {\r\n this.pollingQueryNumberInfo(num);\r\n }, 3000);\r\n }\r\n }\r\n\r\n private handleStartMobileUpload = async () => {\r\n const that = this;\r\n this.qrcodeStatus = 'loading';\r\n this.startMobileUploadLoading = true;\r\n const params = this.uploadParams ?? {};\r\n const reqData: {\r\n cfg?: Record<string, any>;\r\n } = {\r\n cfg: {\r\n fromUserName: '',\r\n fromUserId: '',\r\n upload: that.uploadParams,\r\n name: that.name,\r\n rows: that.rows,\r\n maxLength: that.maxLength,\r\n params,\r\n },\r\n }\r\n const res = await sendHttpRequest({\r\n url: `/sdk/v1/update_id`,\r\n method: 'post',\r\n data: reqData,\r\n });\r\n if (res?.success) {\r\n const resData: {\r\n update_id?: any;\r\n tags?: any;\r\n status?: any;\r\n file_list?: any;\r\n user_id?: any;\r\n cfg?: any;\r\n iat?: any;\r\n exp?: any;\r\n now?: any;\r\n } = res.data ?? {};\r\n uploadNumberSDK.number = resData.update_id;\r\n // 计算过期时间:创建后+1小时\r\n const expireDate = new Date(Date.now() + 3600 * 1000);\r\n this.expireTime = `${expireDate.getHours().toString().padStart(2, '0')}:${expireDate.getMinutes().toString().padStart(2, '0')}`;\r\n const theMobileUrl = `${PCM_DOMAIN}/agents/inputByCode?num=${uploadNumberSDK.number}`;\r\n this.setMobileUrlWrapper(theMobileUrl)\r\n this.setStartMobileUploadWrapper(true);\r\n this.qrcodeStatus = 'active';\r\n // 开启轮询\r\n this.pollingQueryNumberInfo(uploadNumberSDK.number);\r\n }\r\n this.startMobileUploadLoading = false;\r\n }\r\n\r\n // 取消手机填写\r\n @State() cancelLoading = false;\r\n private cancelMobileUpload = async () => {\r\n this.cancelLoading = true;\r\n await uploadNumberSDK.close({\r\n onError() {\r\n Message.info('取消失败');\r\n }\r\n })\r\n this.cancelLoading = false;\r\n this.QR_CODE_VALID_TIME = 0;\r\n this.expireTime = '';\r\n this.setStartMobileUploadWrapper(false);\r\n this.setMobileUrlWrapper('');\r\n this.qrcodeStatus = 'expired';\r\n this.value = '';\r\n this.open = false;\r\n }\r\n\r\n\r\n render() {\r\n return (\r\n <div>\r\n <div class=\"mobile-upload\">\r\n <div\r\n class=\"btn btn-link\"\r\n onClick={() => {\r\n this.open = true;\r\n this.handleStartMobileUpload();\r\n }}\r\n >扫码填写</div>\r\n </div>\r\n {\r\n this.open && <div class=\"mask\">\r\n <div class=\"upload-wrapper\">\r\n {\r\n this.setStartMobileUpload ? <div class=\"upload-box\">\r\n <div class=\"qrcode-wrapper\">\r\n {\r\n this.qrcodeStatus === 'active' && <img class=\"qrcode\" src={this.qrcodeUrl} />\r\n }\r\n {\r\n this.qrcodeStatus === 'loading' && <span class=\"loading\">加载中...</span>\r\n }\r\n {\r\n this.qrcodeStatus === 'expired' && <div\r\n class=\"btn btn-link\"\r\n onClick={this.handleStartMobileUpload}\r\n >重新获取</div>\r\n }\r\n </div>\r\n <div class=\"time-expire\">\r\n 二维码有效期至 {this.expireTime}\r\n </div>\r\n <div class=\"alert-tip\">\r\n 填写过程中请不要关闭此弹窗\r\n </div>\r\n {\r\n this.qrcodeStatus === 'active' && <div\r\n style={{ marginTop: '12px', fontSize: '12px' }}\r\n class=\"btn btn-link\"\r\n onClick={() => {\r\n navigator.clipboard\r\n .writeText(this.mobileUrl)\r\n .then(() => {\r\n Message.success(\"已复制到剪贴板\");\r\n })\r\n .catch(() => {\r\n Message.error(\"复制失败\");\r\n });\r\n }}\r\n >复制二维码地址</div>\r\n }\r\n </div> : (this.startMobileUploadLoading && <span class=\"loading\">加载中...</span>)\r\n }\r\n {/* 填写文件列表 */}\r\n <div style={{ marginTop: '12px' }}>\r\n {\r\n !!this.value?.length && <textarea\r\n readOnly\r\n class=\"qrcode-textarea\"\r\n value={this.value}\r\n onChange={(e: any) => {\r\n this.value = e.target.value;\r\n }}\r\n />\r\n }\r\n </div>\r\n <div class=\"modal-footer\">\r\n <div class=\"btn btn-default\" onClick={this.cancelMobileUpload}>取消</div>\r\n <div class=\"btn btn-primary\" onClick={() => {\r\n if (!this.value) {\r\n Message.info(`请输入内容`);\r\n return;\r\n }\r\n if (this.value.length > this.maxLength) {\r\n Message.info(`输入内容不能超过${this.maxLength}个字符`);\r\n return;\r\n }\r\n this.ok.emit(this.value);\r\n this.cancelMobileUpload();\r\n }}>完成</div>\r\n </div>\r\n </div>\r\n </div>\r\n }\r\n </div>\r\n )\r\n }\r\n}"],"version":3}
1
+ {"file":"p-C7ubjB1x.js","mappings":";;;;;AAEA;AACA,MAAM,eAAe,GAAG;AACpB,IAAA,MAAM,EAAE,EAAE;AACV,IAAA,SAAS,EAAE,KAAK;IAChB,KAAK,EAAE,gBAAgB,MAGtB,EAAA;QACG,MAAM,EAAE,IAAI,EAAE,OAAO,EAAE,GAAG,MAAM,IAAI,EAAE;AACtC,QAAA,MAAM,EAAE,MAAM,EAAE,GAAG,IAAI;QACvB,IAAI,MAAM,EAAE;AACR,YAAA,MAAM,MAAM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AAC,iBAAiB,EACvB,KAAK,EAAE,IAAI,CAAC,KAAK,EACjB,QAAQ,EAAE,CAAC,CAAM,KAAI;gBACjB,IAAI,CAAC,KAAK,GAAG,CAAC,CAAC,MAAM,CAAC,KAAK;aAC9B,GACH,CAEJ,EACN,CAAK,CAAA,KAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,KAAK,EAAC,cAAc,EAAA,EACrB,CAAK,CAAA,KAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,KAAK,EAAC,iBAAiB,EAAC,OAAO,EAAE,IAAI,CAAC,kBAAkB,EAAU,EAAA,cAAA,CAAA,EACvE,CAAA,CAAA,KAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAK,KAAK,EAAC,iBAAiB,EAAC,OAAO,EAAE,MAAK;AACvC,gBAAA,IAAI,CAAC,IAAI,CAAC,KAAK,EAAE;AACb,oBAAA,OAAO,CAAC,IAAI,CAAC,CAAA,KAAA,CAAO,CAAC;oBACrB;;gBAEJ,IAAI,IAAI,CAAC,KAAK,CAAC,MAAM,GAAG,IAAI,CAAC,SAAS,EAAE;oBACpC,OAAO,CAAC,IAAI,CAAC,CAAA,QAAA,EAAW,IAAI,CAAC,SAAS,CAAK,GAAA,CAAA,CAAC;oBAC5C;;gBAEJ,IAAI,CAAC,EAAE,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC;gBACxB,IAAI,CAAC,kBAAkB,EAAE;aAC5B,mBAAU,CACT,CACJ,CACJ,CAER;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/components-mobile-input-btn/uploadNumberSDK.ts","src/components/components-mobile-input-btn/components-mobile-input-btn.css?tag=components-mobile-input-btn&encapsulation=shadow","src/global/global.css?tag=components-mobile-input-btn&encapsulation=shadow","src/global/host.css?tag=components-mobile-input-btn&encapsulation=shadow","src/components/components-mobile-input-btn/components-mobile-input-btn.tsx"],"sourcesContent":["import { sendHttpRequest } from \"../../utils/utils\";\r\n\r\n// 文件上传流水号SDK\r\nconst uploadNumberSDK = {\r\n number: '',\r\n isWorking: false,\r\n close: async function (params?: {\r\n onOk?: () => void;\r\n onError?: () => void;\r\n }) {\r\n const { onOk, onError } = params ?? {};\r\n const { number } = this;\r\n if (number) {\r\n const result = await sendHttpRequest({\r\n url: `/resource/update_id/${number}`,\r\n method: 'delete',\r\n });\r\n if (result.success) {\r\n this.number = '';\r\n onOk?.();\r\n } else {\r\n onError?.();\r\n }\r\n }\r\n }\r\n}\r\n\r\nexport default uploadNumberSDK;",".mobile-upload {\r\n display: flex;\r\n justify-content: flex-end;\r\n margin-bottom: 4px;\r\n}\r\n\r\n.btn {\r\n position: relative;\r\n padding: 4px 8px;\r\n border-radius: 4px;\r\n cursor: pointer;\r\n overflow: hidden;\r\n display: flex;\r\n justify-content: center;\r\n align-items: center;\r\n white-space: nowrap;\r\n}\r\n\r\n.btn::after {\r\n content: '';\r\n position: absolute;\r\n top: 0;\r\n left: 0;\r\n width: 100%;\r\n height: 100%;\r\n}\r\n\r\n.btn:hover::after {\r\n background-color: rgba(0,0,0,0.04);\r\n}\r\n\r\n.btn-link {\r\n color: #0D75FB;\r\n}\r\n\r\n.btn-default {\r\n background-color: #ffffff;\r\n color: #0D75FB;\r\n border: 1px solid #0D75FB;\r\n}\r\n\r\n.btn-primary {\r\n background-color: #0D75FB;\r\n color: #ffffff;\r\n}\r\n\r\n\r\n.loading {\r\n font-size: 12px;\r\n color: #999999;\r\n}\r\n\r\n.mask {\r\n position: fixed;\r\n top: 0;\r\n left: 0;\r\n width: 100%;\r\n height: 100%;\r\n background-color: rgba(0,0,0,0.5);\r\n display: flex;\r\n justify-content: center;\r\n align-items: center;\r\n z-index: 10000;\r\n}\r\n\r\n.mask .upload-wrapper {\r\n width: 540px;\r\n max-width: 80%;\r\n max-height: 80%;\r\n background-color: #ffffff;\r\n padding: 32px 24px;\r\n border-radius: 16px;\r\n overflow-y: auto;\r\n}\r\n\r\n.mask .upload-wrapper .upload-box {\r\n display: flex;\r\n flex-direction: column;\r\n align-items: center;\r\n}\r\n\r\n.time-expire {\r\n margin: 8px 0;\r\n text-align: center;\r\n font-size: 12px;\r\n color: #555555;\r\n}\r\n\r\n.time-count-down {\r\n margin-left: 8px;\r\n color: #0D75FB;\r\n}\r\n\r\n.alert-tip {\r\n margin-top: 8px;\r\n text-align: center;\r\n font-size: 12px;\r\n color: #999999;\r\n}\r\n\r\n.qrcode-wrapper {\r\n width: 160px;\r\n height: 160px;\r\n display: flex;\r\n justify-content: center;\r\n align-items: center;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 4px;\r\n padding: 1px;\r\n}\r\n\r\n.qrcode-wrapper .qrcode {\r\n width: 100%;\r\n height: 100%;\r\n}\r\n\r\n.modal-footer {\r\n margin-top: 32px;\r\n display: flex;\r\n justify-content: center;\r\n align-items: center;\r\n gap: 8px;\r\n}\r\n\r\n.modal-footer .btn {\r\n min-width: 100px;\r\n}\r\n\r\n.qrcode-textarea {\r\n width: calc(100% - 16px);\r\n min-height: 120px;\r\n border: 1px solid #ddd;\r\n border-radius: 4px;\r\n resize: vertical;\r\n font-family: inherit;\r\n font-size: 14px;\r\n line-height: 1.5;\r\n transition: border-color 0.3s;\r\n padding: 8px;\r\n}","/* 模态框基础样式 */\r\n.modal-overlay {\r\n position: fixed;\r\n top: 0;\r\n left: 0;\r\n right: 0;\r\n bottom: 0;\r\n background-color: rgba(0, 0, 0, 0.5);\r\n display: flex;\r\n z-index: 1000;\r\n overflow-y: auto;\r\n}\r\n\r\n/* 全屏模式下的overlay样式 - 改为基于父组件 */\r\n.fullscreen-overlay {\r\n padding: 0;\r\n background-color: rgba(0, 0, 0, 0.7);\r\n /* 改为基于父组件的全屏 */\r\n position: absolute;\r\n width: 100%;\r\n height: auto;\r\n}\r\n\r\n.modal-container {\r\n background-color: #fff;\r\n border-radius: 8px;\r\n width: 100%;\r\n display: flex;\r\n flex-direction: column;\r\n position: relative;\r\n margin: 5vh auto auto auto;\r\n transition: all 0.3s ease-out;\r\n overflow: hidden;\r\n}\r\n\r\n/* 全屏模式样式 - 改为基于父组件 */\r\n.modal-container.fullscreen {\r\n width: 100%;\r\n max-width: none;\r\n height: 100%;\r\n border-radius: 0;\r\n margin: 0;\r\n display: flex;\r\n flex-direction: column;\r\n max-height: 100%;\r\n}\r\n\r\n/* PC端布局 */\r\n.pc-layout {\r\n width: 80%;\r\n max-width: 600px;\r\n min-width: 320px;\r\n}\r\n\r\n/* 响应式布局 */\r\n@media screen and (max-width: 768px) {\r\n .pc-layout {\r\n width: 95%;\r\n }\r\n\r\n .modal-overlay {\r\n padding: 10px 0px 0px 0px;\r\n }\r\n\r\n .modal-container.fullscreen {\r\n /* 移动端也基于父组件尺寸 */\r\n width: 100%;\r\n height: 100%;\r\n max-height: 100%;\r\n border-radius: 16px 16px 0 0;\r\n /* 保留安全区域支持 */\r\n padding: env(safe-area-inset-top) 0 env(safe-area-inset-bottom);\r\n }\r\n}\r\n\r\n/* 模态框头部样式 */\r\n.modal-header {\r\n display: flex;\r\n justify-content: space-between;\r\n align-items: center;\r\n padding: 4px 16px;\r\n height: 50px;\r\n border-bottom: 1px solid #e8e8e8;\r\n flex-shrink: 0;\r\n}\r\n\r\n.header-left {\r\n display: flex;\r\n align-items: center;\r\n gap: 8px;\r\n font-size: 16px;\r\n font-weight: 600;\r\n color: #333;\r\n}\r\n\r\n.header-icon {\r\n width: 24px;\r\n height: 24px;\r\n}\r\n\r\n.close-button {\r\n background: transparent;\r\n border: none;\r\n cursor: pointer;\r\n padding: 8px;\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n width: 32px;\r\n height: 32px;\r\n border-radius: 4px;\r\n}\r\n\r\n.close-button:hover {\r\n background-color: rgba(0, 0, 0, 0.04);\r\n}\r\n\r\n.close-button span {\r\n font-size: 24px;\r\n line-height: 1;\r\n color: #999;\r\n}\r\n\r\n.close-button:hover span {\r\n color: #666;\r\n}\r\n\r\n\r\n/* 文件上传区域通用样式 */\r\n.upload-area {\r\n cursor: pointer;\r\n width: 100%;\r\n}\r\n\r\n\r\n.upload-placeholder {\r\n transition: all 0.3s ease;\r\n display: flex;\r\n flex-direction: column;\r\n align-items: center;\r\n background: rgba(0, 0, 0, 0.02);\r\n border: 1px dashed #d9d9d9;\r\n border-radius: 8px;\r\n cursor: pointer;\r\n}\r\n\r\n.upload-placeholder:hover {\r\n border: 1px dashed #1890ff;\r\n}\r\n\r\n.upload-placeholder img {\r\n margin-top: 8px;\r\n width: 50px;\r\n height: 50px;\r\n}\r\n\r\n.upload-placeholder .upload-text {\r\n margin: 4px 0;\r\n color: #332F39;\r\n font-size: 14px;\r\n}\r\n\r\n.upload-placeholder .upload-hint {\r\n font-size: 14px;\r\n color: #949AA5;\r\n margin-top: 8px;\r\n padding: 0px 10px;\r\n text-align: center;\r\n white-space: normal;\r\n word-wrap: break-word;\r\n word-break: break-all;\r\n line-height: 1.4;\r\n}\r\n\r\n\r\n/* 文件项样式 */\r\n.file-item {\r\n position: relative;\r\n padding: 16px;\r\n border: 1px solid #e2e8f0;\r\n border-radius: 8px;\r\n transition: border-color 0.3s;\r\n cursor: pointer;\r\n margin-bottom: 16px;\r\n display: flex;\r\n justify-content: space-between;\r\n align-items: center;\r\n}\r\n\r\n.file-item:hover {\r\n border-color: #0D75FB;\r\n}\r\n\r\n.file-item-content {\r\n display: flex;\r\n align-items: center;\r\n gap: 8px;\r\n flex: 1;\r\n min-width: 0;\r\n overflow: hidden;\r\n}\r\n\r\n.file-icon {\r\n color: #0D75FB;\r\n flex-shrink: 0;\r\n}\r\n\r\n.file-name {\r\n font-weight: 500;\r\n white-space: nowrap;\r\n overflow: hidden;\r\n text-overflow: ellipsis;\r\n max-width: calc(100% - 50px);\r\n}\r\n\r\n.remove-file {\r\n background: transparent;\r\n border: none;\r\n color: #94a3b8;\r\n cursor: pointer;\r\n font-size: 18px;\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n padding: 4px;\r\n margin-left: 8px;\r\n border-radius: 4px;\r\n transition: all 0.2s;\r\n min-width: 30px;\r\n min-height: 30px;\r\n}\r\n\r\n.remove-file:hover {\r\n background-color: #f1f5f9;\r\n color: #475569;\r\n}\r\n\r\n.file-input {\r\n display: none;\r\n}\r\n\r\n\r\n\r\n/* 输入容器样式 */\r\n.input-container {\r\n padding: 20px;\r\n display: flex;\r\n flex-direction: column;\r\n height: calc(100% - 50px);\r\n background: linear-gradient(150deg, #2a6ee933, #0000 50%) 0 0 / 400px 200px no-repeat, #fff;\r\n /* 减去header高度 */\r\n overflow-y: auto;\r\n}\r\n\r\n.input-container h3 {\r\n margin-top: 0;\r\n margin-bottom: 20px;\r\n font-size: 18px;\r\n color: #333;\r\n text-align: center;\r\n}\r\n\r\n/* JD输入区域样式 */\r\n.jd-input-section {\r\n margin-bottom: 20px;\r\n}\r\n\r\n.jd-input-section label {\r\n display: block;\r\n margin-bottom: 8px;\r\n font-weight: 500;\r\n color: #333;\r\n}\r\n\r\n.job-description-textarea {\r\n width: calc(100% - 16px);\r\n border: 1px solid #ddd;\r\n border-radius: 4px;\r\n resize: vertical;\r\n font-family: inherit;\r\n font-size: 14px;\r\n line-height: 1.5;\r\n transition: border-color 0.3s;\r\n padding: 8px;\r\n}\r\n\r\n.job-description-textarea:focus {\r\n outline: none;\r\n border-color: #1890ff;\r\n box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.2);\r\n}\r\n\r\n/* 简历上传区域样式 */\r\n.resume-upload-section {\r\n margin-bottom: 20px;\r\n width: 100%;\r\n display: flex;\r\n flex-direction: column;\r\n}\r\n\r\n.resume-upload-section label {\r\n display: block;\r\n margin-bottom: 8px;\r\n font-weight: 500;\r\n color: #333;\r\n}\r\n\r\n/* 面试设置区域 */\r\n.interview-settings-section {\r\n margin-bottom: 24px;\r\n padding: 20px;\r\n background-color: #f8f9fa;\r\n border-radius: 8px;\r\n border: 1px solid #e9ecef;\r\n}\r\n\r\n.settings-row {\r\n margin-bottom: 20px;\r\n}\r\n\r\n.settings-row:last-child {\r\n margin-bottom: 0;\r\n}\r\n\r\n.settings-label {\r\n display: block;\r\n font-weight: 500;\r\n color: #333;\r\n margin-bottom: 12px;\r\n font-size: 14px;\r\n}\r\n\r\n/* 题目数量滑块样式 */\r\n.question-number-section {\r\n width: 100%;\r\n}\r\n\r\n.slider-container {\r\n display: flex;\r\n align-items: center;\r\n gap: 12px;\r\n}\r\n\r\n.question-slider {\r\n flex: 1;\r\n height: 6px;\r\n background: #ddd;\r\n outline: none;\r\n border-radius: 3px;\r\n -webkit-appearance: none;\r\n appearance: none;\r\n}\r\n\r\n.question-slider::-webkit-slider-thumb {\r\n -webkit-appearance: none;\r\n appearance: none;\r\n width: 20px;\r\n height: 20px;\r\n background: #0D75FB;\r\n cursor: pointer;\r\n border-radius: 50%;\r\n box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);\r\n}\r\n\r\n.question-slider::-moz-range-thumb {\r\n width: 20px;\r\n height: 20px;\r\n background: #0D75FB;\r\n cursor: pointer;\r\n border-radius: 50%;\r\n border: none;\r\n box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);\r\n}\r\n\r\n.slider-value {\r\n font-weight: 600;\r\n color: #0D75FB;\r\n font-size: 14px;\r\n min-width: 30px;\r\n text-align: center;\r\n}\r\n\r\n/* 开关样式 */\r\n.analysis-toggle-section {\r\n width: 100%;\r\n}\r\n\r\n.toggle-container {\r\n display: flex;\r\n align-items: center;\r\n gap: 12px;\r\n}\r\n\r\n.toggle-switch {\r\n position: relative;\r\n display: inline-block;\r\n width: 44px;\r\n height: 24px;\r\n}\r\n\r\n.toggle-switch input {\r\n opacity: 0;\r\n width: 0;\r\n height: 0;\r\n}\r\n\r\n.toggle-slider {\r\n position: absolute;\r\n cursor: pointer;\r\n top: 0;\r\n left: 0;\r\n right: 0;\r\n bottom: 0;\r\n background-color: #ccc;\r\n transition: 0.3s;\r\n border-radius: 24px;\r\n}\r\n\r\n.toggle-slider:before {\r\n position: absolute;\r\n content: \"\";\r\n height: 18px;\r\n width: 18px;\r\n left: 3px;\r\n bottom: 3px;\r\n background-color: white;\r\n transition: 0.3s;\r\n border-radius: 50%;\r\n box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);\r\n}\r\n\r\ninput:checked + .toggle-slider {\r\n background-color: #0D75FB;\r\n}\r\n\r\ninput:checked + .toggle-slider:before {\r\n transform: translateX(20px);\r\n}\r\n\r\n.toggle-text {\r\n font-size: 14px;\r\n color: #666;\r\n font-weight: 500;\r\n}\r\n\r\n/* 提交按钮通用样式 */\r\n.submit-button {\r\n margin-top: 10px;\r\n padding: 10px 30px;\r\n background: #0D75FB;\r\n color: white;\r\n border: none;\r\n border-radius: 4px;\r\n font-size: 16px;\r\n cursor: pointer;\r\n transition: all 0.3s ease;\r\n width: 100%;\r\n max-width: 400px;\r\n align-self: center;\r\n}\r\n\r\n.submit-button:hover {\r\n background-color: #40a9ff;\r\n}\r\n\r\n.submit-button:disabled {\r\n background-color: rgba(0,0,0,0.04);\r\n color: rgba(0,0,0,0.25);\r\n cursor: not-allowed;\r\n}\r\n\r\n\r\n\r\n/* AI免责声明和备案信息样式 */\r\n.ai-disclaimer {\r\n margin-top: 16px;\r\n text-align: center;\r\n font-size: 12px;\r\n color: #999;\r\n line-height: 1.5;\r\n}\r\n\r\n.ai-disclaimer p {\r\n margin: 4px 0;\r\n}\r\n\r\n.beian-info {\r\n display: flex;\r\n justify-content: center;\r\n flex-wrap: wrap;\r\n gap: 4px;\r\n}\r\n\r\n.ai-disclaimer a {\r\n color: #666;\r\n text-decoration: none;\r\n transition: color 0.2s ease;\r\n}\r\n\r\n.ai-disclaimer a:hover {\r\n color: #1890ff;\r\n text-decoration: underline;\r\n}\r\n\r\n/* 添加加载状态的样式 */\r\n.loading-container {\r\n display: flex;\r\n flex-direction: column;\r\n align-items: center;\r\n justify-content: center;\r\n height: 100%;\r\n padding: 24px;\r\n }\r\n \r\n .loading-spinner {\r\n width: 40px;\r\n height: 40px;\r\n border: 4px solid rgba(0, 0, 0, 0.1);\r\n border-radius: 50%;\r\n border-top-color: var(--pcm-primary-color, #1890ff);\r\n animation: spin 1s linear infinite;\r\n margin-bottom: 16px;\r\n }\r\n \r\n .loading-text {\r\n font-size: 16px;\r\n color: var(--pcm-text-color, #333);\r\n }\r\n \r\n @keyframes spin {\r\n 0% { transform: rotate(0deg); }\r\n 100% { transform: rotate(360deg); }\r\n }\r\n\r\n/* 历史会话按钮 */\r\n.header-history-button {\r\n display: inline-flex;\r\n align-items: center;\r\n justify-content: center;\r\n gap: 4px;\r\n padding: 4px 8px;\r\n border: none;\r\n border-radius: 4px;\r\n background: transparent;\r\n color: #bbb;\r\n cursor: pointer;\r\n font-size: 13px;\r\n font-family: inherit;\r\n line-height: 1;\r\n transition: all 0.2s ease;\r\n flex-shrink: 0;\r\n white-space: nowrap;\r\n}\r\n\r\n.header-history-button svg {\r\n width: 16px;\r\n height: 16px;\r\n display: block;\r\n flex-shrink: 0;\r\n}\r\n\r\n.header-history-button:hover {\r\n background-color: rgba(0, 0, 0, 0.04);\r\n color: #666;\r\n}\r\n\r\n.header-history-button:focus-visible {\r\n outline: 2px solid rgba(13, 117, 251, 0.35);\r\n outline-offset: 2px;\r\n}\r\n\r\n/* 历史会话抽屉内容 */\r\n.history-drawer-content {\r\n height: 100%;\r\n display: flex;\r\n flex-direction: column;\r\n}\r\n\r\n.conversation-list {\r\n flex: 1;\r\n overflow-y: auto;\r\n padding: 8px 0;\r\n}\r\n\r\n.loading-conversations,\r\n.empty-conversations {\r\n display: flex;\r\n flex-direction: column;\r\n align-items: center;\r\n justify-content: center;\r\n padding: 40px 20px;\r\n color: #999;\r\n}\r\n\r\n.loading-conversations .loading-spinner-small {\r\n margin-bottom: 12px;\r\n}\r\n\r\n.conversation-item {\r\n display: flex;\r\n align-items: center;\r\n justify-content: space-between;\r\n padding: 12px 16px;\r\n margin: 0 8px 4px 8px;\r\n border-radius: 8px;\r\n cursor: pointer;\r\n transition: all 0.2s ease;\r\n border: 1px solid transparent;\r\n}\r\n\r\n.conversation-item:hover {\r\n background: #f5f5f5;\r\n}\r\n\r\n.conversation-info {\r\n flex: 1;\r\n min-width: 0;\r\n}\r\n\r\n.conversation-title {\r\n font-size: 14px;\r\n font-weight: 500;\r\n color: #262626;\r\n margin-bottom: 4px;\r\n overflow: hidden;\r\n text-overflow: ellipsis;\r\n white-space: nowrap;\r\n}\r\n\r\n.conversation-meta {\r\n display: flex;\r\n align-items: center;\r\n gap: 8px;\r\n font-size: 12px;\r\n color: #8c8c8c;\r\n}\r\n\r\n.conversation-time {\r\n flex-shrink: 0;\r\n}\r\n\r\n.message-count {\r\n flex-shrink: 0;\r\n}\r\n\r\n.conversation-status {\r\n padding: 2px 6px;\r\n border-radius: 4px;\r\n font-size: 11px;\r\n font-weight: 500;\r\n}\r\n\r\n.conversation-status.completed {\r\n background: #f6ffed;\r\n color: #52c41a;\r\n}\r\n\r\n.conversation-status.running {\r\n background: #fff7e6;\r\n color: #fa8c16;\r\n}\r\n\r\n.header-history-entry {\r\n display: inline-flex;\r\n align-items: center;\r\n justify-content: center;\r\n margin-left: 8px;\r\n padding: 4px 8px;\r\n border: none;\r\n border-radius: 4px;\r\n background: #e6f7ff;\r\n color: #1890ff;\r\n cursor: pointer;\r\n font-size: 12px;\r\n font-family: inherit;\r\n line-height: 1;\r\n white-space: nowrap;\r\n transition: all 0.2s ease;\r\n}\r\n\r\n.header-history-entry:hover {\r\n background: #bae7ff;\r\n color: #0958d9;\r\n transform: translateY(-1px);\r\n}\r\n\r\n.header-history-entry:focus-visible {\r\n outline: 2px solid rgba(13, 117, 251, 0.35);\r\n outline-offset: 2px;\r\n}\r\n\r\n.history-pagination {\r\n display: flex;\r\n align-items: center;\r\n justify-content: space-between;\r\n gap: 12px;\r\n padding: 12px 16px 16px;\r\n border-top: 1px solid #f0f0f0;\r\n}\r\n\r\n.history-pagination-button {\r\n min-width: 72px;\r\n padding: 6px 12px;\r\n border: 1px solid #d9d9d9;\r\n border-radius: 6px;\r\n background: #fff;\r\n color: #595959;\r\n cursor: pointer;\r\n font-size: 12px;\r\n transition: all 0.2s ease;\r\n}\r\n\r\n.history-pagination-button:hover:not(:disabled) {\r\n border-color: #1890ff;\r\n color: #1890ff;\r\n background: #e6f7ff;\r\n}\r\n\r\n.history-pagination-button:disabled {\r\n border-color: #f0f0f0;\r\n color: #bfbfbf;\r\n background: #fafafa;\r\n cursor: not-allowed;\r\n}\r\n\r\n.history-pagination-info {\r\n flex: 1;\r\n text-align: center;\r\n color: #8c8c8c;\r\n font-size: 12px;\r\n}\r\n \r\n",":host {\r\n /* 字体相关属性 */\r\n font-size: 16px;\r\n font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;\r\n font-weight: normal;\r\n font-style: normal;\r\n font-variant: normal;\r\n line-height: 1.5;\r\n letter-spacing: normal;\r\n word-spacing: normal;\r\n \r\n /* 文本相关属性 */\r\n color: #333; /* 重置文字颜色,避免继承外部的red */\r\n text-align: left;\r\n text-indent: 0;\r\n text-transform: none;\r\n white-space: normal;\r\n word-wrap: normal;\r\n word-break: normal;\r\n \r\n /* 可见性 */\r\n visibility: visible;\r\n \r\n /* 列表相关 */\r\n list-style: none;\r\n list-style-image: none;\r\n list-style-position: outside;\r\n list-style-type: disc;\r\n \r\n /* 表格相关 */\r\n border-collapse: separate;\r\n border-spacing: 0;\r\n caption-side: top;\r\n empty-cells: show;\r\n table-layout: auto;\r\n \r\n /* 引用 */\r\n quotes: auto;\r\n \r\n /* 光标 */\r\n cursor: auto;\r\n \r\n /* 文本方向 */\r\n direction: ltr;\r\n \r\n /* 打印相关 */\r\n orphans: 2;\r\n widows: 2;\r\n page-break-inside: auto;\r\n \r\n /* 其他可能被继承的属性 */\r\n text-decoration: none;\r\n text-shadow: none;\r\n \r\n /* 确保组件有独立的盒模型 */\r\n box-sizing: border-box;\r\n \r\n /* 重置一些可能影响布局的继承属性 */\r\n writing-mode: horizontal-tb;\r\n text-orientation: mixed;\r\n}","import { Component, Prop, State, Event, h, EventEmitter } from \"@stencil/core\";\r\nimport qrcode from 'qrcode-generator'\r\nimport { sendHttpRequest, PCM_DOMAIN } from \"../../utils/utils\";\r\nimport { Message } from \"../../services/message.service\";\r\nimport uploadNumberSDK from \"./uploadNumberSDK\";\r\n\r\n@Component({\r\n tag: 'components-mobile-input-btn',\r\n styleUrls: ['components-mobile-input-btn.css', '../../global/global.css', '../../global/host.css'],\r\n shadow: true,\r\n})\r\nexport class ComponentsMobileInputBtn {\r\n // 标题\r\n @Prop() name: string = '';\r\n /**\r\n * 最大文件数\r\n */\r\n @Prop() rows: number = 8;\r\n /**\r\n * 最大文件大小\r\n */\r\n @Prop() maxLength: number = undefined;\r\n /**\r\n * 填写请求头\r\n */\r\n @Prop() uploadHeaders?: Record<string, any>;\r\n /**\r\n * 填写请求参数\r\n */\r\n @Prop() uploadParams?: Record<string, any>;\r\n\r\n @State() QR_CODE_VALID_TIME: number = 0;\r\n @State() open: boolean = false;\r\n @State() mobileUrl: string = '';\r\n @State() setStartMobileUpload: boolean = false;\r\n @State() startMobileUploadLoading: boolean = false;\r\n @State() qrcodeStatus: 'active' | 'expired' | 'loading' | undefined = 'loading';\r\n @State() value: string = '';\r\n @State() expireTime: string = ''; // 过期时间\r\n\r\n @Event() ok: EventEmitter<string>;\r\n\r\n private setStartMobileUploadWrapper = (e: boolean) => {\r\n uploadNumberSDK.isWorking = e;\r\n this.setStartMobileUpload = e;\r\n }\r\n\r\n @State() qrcodeUrl: string = '';\r\n private setMobileUrlWrapper = (e: string) => {\r\n this.mobileUrl = e;\r\n if (e) {\r\n const qr = qrcode(0, 'M');\r\n qr.addData(e);\r\n qr.make();\r\n this.qrcodeUrl = qr.createDataURL(4, 0);\r\n } else {\r\n this.qrcodeUrl = '';\r\n }\r\n }\r\n\r\n // 轮询流水号数据\r\n private pollingQueryNumberInfo = async (num: any) => {\r\n const res = await sendHttpRequest({\r\n url: `/sdk/v1/update_id/${num}/status`,\r\n method: 'get',\r\n });\r\n if (res?.success) {\r\n const resData: {\r\n update_id?: any;\r\n tags?: any;\r\n status?: any;\r\n file_list?: any;\r\n user_id?: any;\r\n cfg?: any;\r\n iat?: any;\r\n exp?: any;\r\n custom_data?: any;\r\n } = res.data ?? {};\r\n const { custom_data } = resData;\r\n this.value = custom_data ?? '';\r\n }\r\n if (uploadNumberSDK.isWorking) {\r\n setTimeout(() => {\r\n this.pollingQueryNumberInfo(num);\r\n }, 3000);\r\n }\r\n }\r\n\r\n private handleStartMobileUpload = async () => {\r\n const that = this;\r\n this.qrcodeStatus = 'loading';\r\n this.startMobileUploadLoading = true;\r\n const params = this.uploadParams ?? {};\r\n const reqData: {\r\n cfg?: Record<string, any>;\r\n } = {\r\n cfg: {\r\n fromUserName: '',\r\n fromUserId: '',\r\n upload: that.uploadParams,\r\n name: that.name,\r\n rows: that.rows,\r\n maxLength: that.maxLength,\r\n params,\r\n },\r\n }\r\n const res = await sendHttpRequest({\r\n url: `/sdk/v1/update_id`,\r\n method: 'post',\r\n data: reqData,\r\n });\r\n if (res?.success) {\r\n const resData: {\r\n update_id?: any;\r\n tags?: any;\r\n status?: any;\r\n file_list?: any;\r\n user_id?: any;\r\n cfg?: any;\r\n iat?: any;\r\n exp?: any;\r\n now?: any;\r\n } = res.data ?? {};\r\n uploadNumberSDK.number = resData.update_id;\r\n // 计算过期时间:创建后+1小时\r\n const expireDate = new Date(Date.now() + 3600 * 1000);\r\n this.expireTime = `${expireDate.getHours().toString().padStart(2, '0')}:${expireDate.getMinutes().toString().padStart(2, '0')}`;\r\n const theMobileUrl = `${PCM_DOMAIN}/agents/inputByCode?num=${uploadNumberSDK.number}`;\r\n this.setMobileUrlWrapper(theMobileUrl)\r\n this.setStartMobileUploadWrapper(true);\r\n this.qrcodeStatus = 'active';\r\n // 开启轮询\r\n this.pollingQueryNumberInfo(uploadNumberSDK.number);\r\n }\r\n this.startMobileUploadLoading = false;\r\n }\r\n\r\n // 取消手机填写\r\n @State() cancelLoading = false;\r\n private cancelMobileUpload = async () => {\r\n this.cancelLoading = true;\r\n await uploadNumberSDK.close({\r\n onError() {\r\n Message.info('取消失败');\r\n }\r\n })\r\n this.cancelLoading = false;\r\n this.QR_CODE_VALID_TIME = 0;\r\n this.expireTime = '';\r\n this.setStartMobileUploadWrapper(false);\r\n this.setMobileUrlWrapper('');\r\n this.qrcodeStatus = 'expired';\r\n this.value = '';\r\n this.open = false;\r\n }\r\n\r\n\r\n render() {\r\n return (\r\n <div>\r\n <div class=\"mobile-upload\">\r\n <div\r\n class=\"btn btn-link\"\r\n onClick={() => {\r\n this.open = true;\r\n this.handleStartMobileUpload();\r\n }}\r\n >扫码填写</div>\r\n </div>\r\n {\r\n this.open && <div class=\"mask\">\r\n <div class=\"upload-wrapper\">\r\n {\r\n this.setStartMobileUpload ? <div class=\"upload-box\">\r\n <div class=\"qrcode-wrapper\">\r\n {\r\n this.qrcodeStatus === 'active' && <img class=\"qrcode\" src={this.qrcodeUrl} />\r\n }\r\n {\r\n this.qrcodeStatus === 'loading' && <span class=\"loading\">加载中...</span>\r\n }\r\n {\r\n this.qrcodeStatus === 'expired' && <div\r\n class=\"btn btn-link\"\r\n onClick={this.handleStartMobileUpload}\r\n >重新获取</div>\r\n }\r\n </div>\r\n <div class=\"time-expire\">\r\n 二维码有效期至 {this.expireTime}\r\n </div>\r\n <div class=\"alert-tip\">\r\n 填写过程中请不要关闭此弹窗\r\n </div>\r\n {\r\n this.qrcodeStatus === 'active' && <div\r\n style={{ marginTop: '12px', fontSize: '12px' }}\r\n class=\"btn btn-link\"\r\n onClick={() => {\r\n navigator.clipboard\r\n .writeText(this.mobileUrl)\r\n .then(() => {\r\n Message.success(\"已复制到剪贴板\");\r\n })\r\n .catch(() => {\r\n Message.error(\"复制失败\");\r\n });\r\n }}\r\n >复制二维码地址</div>\r\n }\r\n </div> : (this.startMobileUploadLoading && <span class=\"loading\">加载中...</span>)\r\n }\r\n {/* 填写文件列表 */}\r\n <div style={{ marginTop: '12px' }}>\r\n {\r\n !!this.value?.length && <textarea\r\n readOnly\r\n class=\"qrcode-textarea\"\r\n value={this.value}\r\n onChange={(e: any) => {\r\n this.value = e.target.value;\r\n }}\r\n />\r\n }\r\n </div>\r\n <div class=\"modal-footer\">\r\n <div class=\"btn btn-default\" onClick={this.cancelMobileUpload}>取消</div>\r\n <div class=\"btn btn-primary\" onClick={() => {\r\n if (!this.value) {\r\n Message.info(`请输入内容`);\r\n return;\r\n }\r\n if (this.value.length > this.maxLength) {\r\n Message.info(`输入内容不能超过${this.maxLength}个字符`);\r\n return;\r\n }\r\n this.ok.emit(this.value);\r\n this.cancelMobileUpload();\r\n }}>完成</div>\r\n </div>\r\n </div>\r\n </div>\r\n }\r\n </div>\r\n )\r\n }\r\n}"],"version":3}
@@ -1,5 +1,5 @@
1
1
  import { p as proxyCustomElement, H, c as createEvent, h } from './p-CR7WLzmM.js';
2
- import { s as sendHttpRequest, k as getCosPresignedUrl } from './p-DuRuN7gY.js';
2
+ import { s as sendHttpRequest, k as getCosPresignedUrl } from './p-i4wY2JnB.js';
3
3
 
4
4
  const componentsExportRecordsModalCss = ".modal-overlay{position:fixed;top:0;left:0;right:0;bottom:0;background-color:rgba(0, 0, 0, 0.45);display:flex;align-items:flex-start;justify-content:center;z-index:1000;backdrop-filter:blur(4px)}.modal-container{background:white;border-radius:8px;box-shadow:0 4px 12px rgba(0, 0, 0, 0.15);max-width:min(1000px, calc(100vw - 40px));max-height:calc(100vh - 40px);width:100%;display:flex;flex-direction:column;overflow:hidden}.modal-header{padding:16px 24px;border-bottom:1px solid #f0f0f0;display:flex;align-items:center;justify-content:space-between;background:#fafafa}.modal-title{display:flex;align-items:center;gap:16px;font-size:16px;font-weight:600;color:#262626}.modal-close{background:none;border:none;font-size:18px;color:#8c8c8c;cursor:pointer;padding:4px;border-radius:4px;transition:all 0.2s}.modal-close:hover{background-color:#f5f5f5;color:#262626}.modal-body{padding:24px;flex:1;overflow:auto}.btn{border:none;border-radius:6px;cursor:pointer;font-size:14px;font-weight:400;transition:all 0.2s;display:inline-flex;align-items:center;justify-content:center;gap:4px}.btn-small{padding:4px 8px;font-size:12px}.btn-medium{padding:8px 16px}.btn-primary{background-color:#1890ff;color:white;border:1px solid #1890ff}.btn-primary:hover{background-color:#40a9ff;border-color:#40a9ff}.btn-default{background-color:white;color:#595959;border:1px solid #d9d9d9}.btn-default:hover{background-color:#f5f5f5;border-color:#40a9ff;color:#40a9ff}.btn-danger{background-color:#f5222d;color:white;border:1px solid #f5222d}.btn-danger:hover{background-color:#cf1322;border-color:#cf1322}.table-container{border:1px solid #f0f0f0;border-radius:6px;overflow:hidden;margin-bottom:16px}.table{width:100%;border-collapse:collapse;background:white}.table th{background-color:#fafafa;padding:12px 16px;font-weight:600;color:#262626;border-bottom:1px solid #f0f0f0;font-size:14px}.table td{padding:12px 16px;border-bottom:1px solid #f0f0f0;color:#595959;font-size:14px}.table tbody tr:hover{background-color:#f5f5f5}.table tbody tr:last-child td{border-bottom:none}.tag{display:inline-block;padding:2px 8px;border-radius:4px;font-size:12px;font-weight:400;color:white;text-align:center;min-width:60px}.action-buttons{display:flex;gap:8px}.loading-container{display:flex;flex-direction:column;align-items:center;justify-content:center;padding:60px 20px;color:#8c8c8c}.loading-spinner{width:32px;height:32px;border:3px solid #f0f0f0;border-top:3px solid #1890ff;border-radius:50%;animation:spin 1s linear infinite;margin-bottom:16px}@keyframes spin{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}.empty-container{display:flex;flex-direction:column;align-items:center;justify-content:center;padding:60px 20px;color:#8c8c8c}.empty-icon{font-size:48px;margin-bottom:16px;opacity:0.6}.empty-text{font-size:14px;color:#8c8c8c}.pagination-container{display:flex;align-items:center;justify-content:space-between;padding:16px 0;border-top:1px solid #f0f0f0}.pagination-info{color:#8c8c8c;font-size:14px}.pagination-controls{display:flex;align-items:center;gap:12px}.pagination-btn{padding:6px 12px;border:1px solid #d9d9d9;background:white;color:#595959;border-radius:4px;cursor:pointer;font-size:14px;transition:all 0.2s}.pagination-btn:hover:not(:disabled){border-color:#40a9ff;color:#40a9ff}.pagination-btn:disabled{background-color:#f5f5f5;color:#bfbfbf;cursor:not-allowed;border-color:#f0f0f0}.pagination-current{color:#262626;font-size:14px;font-weight:500;padding:0 8px}.pagination-size-select{padding:6px 8px;border:1px solid #d9d9d9;border-radius:4px;background:white;color:#595959;font-size:14px;cursor:pointer;transition:all 0.2s}.pagination-size-select:hover{border-color:#40a9ff}.pagination-size-select:focus{outline:none;border-color:#40a9ff;box-shadow:0 0 0 2px rgba(24, 144, 255, 0.2)}.message{position:fixed;top:24px;left:50%;transform:translateX(-50%);padding:12px 24px;border-radius:6px;font-size:14px;font-weight:500;z-index:1100;box-shadow:0 4px 12px rgba(0, 0, 0, 0.15);animation:messageSlideIn 0.3s ease-out}.message-success{background-color:#f6ffed;color:#52c41a;border:1px solid #b7eb8f}.message-error{background-color:#fff2f0;color:#ff4d4f;border:1px solid #ffccc7}@keyframes messageSlideIn{from{opacity:0;transform:translateX(-50%) translateY(-20px)}to{opacity:1;transform:translateX(-50%) translateY(0)}}@media (max-width: 768px){.modal-container{margin:20px;max-width:calc(100vw - 40px)}.modal-header{padding:12px 16px}.modal-body{padding:16px}.table th,.table td{padding:8px 12px;font-size:13px}.pagination-container{flex-direction:column;gap:12px;align-items:stretch}.pagination-controls{justify-content:center}.modal-title{font-size:14px;gap:8px}}@media (max-width: 480px){.table-container{overflow-x:auto}.table{min-width:600px}.action-buttons{flex-direction:column;gap:4px}}";
5
5
 
@@ -203,6 +203,6 @@ function defineCustomElement() {
203
203
  defineCustomElement();
204
204
 
205
205
  export { ComponentsExportRecordsModal as C, defineCustomElement as d };
206
- //# sourceMappingURL=p-Cp6_0jsj.js.map
206
+ //# sourceMappingURL=p-CB7myOe_.js.map
207
207
 
208
- //# sourceMappingURL=p-Cp6_0jsj.js.map
208
+ //# sourceMappingURL=p-CB7myOe_.js.map
@@ -1 +1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;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/components-export-records-modal/components-export-records-modal.css?tag=components-export-records-modal&encapsulation=shadow","src/components/components-export-records-modal/components-export-records-modal.tsx"],"sourcesContent":["/* 模态框遮罩层 */\r\n.modal-overlay {\r\n position: fixed;\r\n top: 0;\r\n left: 0;\r\n right: 0;\r\n bottom: 0;\r\n background-color: rgba(0, 0, 0, 0.45);\r\n display: flex;\r\n align-items: flex-start;\r\n justify-content: center;\r\n z-index: 1000;\r\n backdrop-filter: blur(4px);\r\n}\r\n\r\n/* 模态框容器 */\r\n.modal-container {\r\n background: white;\r\n border-radius: 8px;\r\n box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);\r\n max-width: min(1000px, calc(100vw - 40px));\r\n max-height: calc(100vh - 40px);\r\n width: 100%;\r\n display: flex;\r\n flex-direction: column;\r\n overflow: hidden;\r\n}\r\n\r\n/* 模态框头部 */\r\n.modal-header {\r\n padding: 16px 24px;\r\n border-bottom: 1px solid #f0f0f0;\r\n display: flex;\r\n align-items: center;\r\n justify-content: space-between;\r\n background: #fafafa;\r\n}\r\n\r\n.modal-title {\r\n display: flex;\r\n align-items: center;\r\n gap: 16px;\r\n font-size: 16px;\r\n font-weight: 600;\r\n color: #262626;\r\n}\r\n\r\n.modal-close {\r\n background: none;\r\n border: none;\r\n font-size: 18px;\r\n color: #8c8c8c;\r\n cursor: pointer;\r\n padding: 4px;\r\n border-radius: 4px;\r\n transition: all 0.2s;\r\n}\r\n\r\n.modal-close:hover {\r\n background-color: #f5f5f5;\r\n color: #262626;\r\n}\r\n\r\n/* 模态框主体 */\r\n.modal-body {\r\n padding: 24px;\r\n flex: 1;\r\n overflow: auto;\r\n}\r\n\r\n/* 按钮样式 */\r\n.btn {\r\n border: none;\r\n border-radius: 6px;\r\n cursor: pointer;\r\n font-size: 14px;\r\n font-weight: 400;\r\n transition: all 0.2s;\r\n display: inline-flex;\r\n align-items: center;\r\n justify-content: center;\r\n gap: 4px;\r\n}\r\n\r\n.btn-small {\r\n padding: 4px 8px;\r\n font-size: 12px;\r\n}\r\n\r\n.btn-medium {\r\n padding: 8px 16px;\r\n}\r\n\r\n.btn-primary {\r\n background-color: #1890ff;\r\n color: white;\r\n border: 1px solid #1890ff;\r\n}\r\n\r\n.btn-primary:hover {\r\n background-color: #40a9ff;\r\n border-color: #40a9ff;\r\n}\r\n\r\n.btn-default {\r\n background-color: white;\r\n color: #595959;\r\n border: 1px solid #d9d9d9;\r\n}\r\n\r\n.btn-default:hover {\r\n background-color: #f5f5f5;\r\n border-color: #40a9ff;\r\n color: #40a9ff;\r\n}\r\n\r\n.btn-danger {\r\n background-color: #f5222d;\r\n color: white;\r\n border: 1px solid #f5222d;\r\n}\r\n\r\n.btn-danger:hover {\r\n background-color: #cf1322;\r\n border-color: #cf1322;\r\n}\r\n\r\n/* 表格容器 */\r\n.table-container {\r\n border: 1px solid #f0f0f0;\r\n border-radius: 6px;\r\n overflow: hidden;\r\n margin-bottom: 16px;\r\n}\r\n\r\n/* 表格样式 */\r\n.table {\r\n width: 100%;\r\n border-collapse: collapse;\r\n background: white;\r\n}\r\n\r\n.table th {\r\n background-color: #fafafa;\r\n padding: 12px 16px;\r\n font-weight: 600;\r\n color: #262626;\r\n border-bottom: 1px solid #f0f0f0;\r\n font-size: 14px;\r\n}\r\n\r\n.table td {\r\n padding: 12px 16px;\r\n border-bottom: 1px solid #f0f0f0;\r\n color: #595959;\r\n font-size: 14px;\r\n}\r\n\r\n.table tbody tr:hover {\r\n background-color: #f5f5f5;\r\n}\r\n\r\n.table tbody tr:last-child td {\r\n border-bottom: none;\r\n}\r\n\r\n/* 标签样式 */\r\n.tag {\r\n display: inline-block;\r\n padding: 2px 8px;\r\n border-radius: 4px;\r\n font-size: 12px;\r\n font-weight: 400;\r\n color: white;\r\n text-align: center;\r\n min-width: 60px;\r\n}\r\n\r\n/* 操作按钮容器 */\r\n.action-buttons {\r\n display: flex;\r\n gap: 8px;\r\n}\r\n\r\n/* 加载状态 */\r\n.loading-container {\r\n display: flex;\r\n flex-direction: column;\r\n align-items: center;\r\n justify-content: center;\r\n padding: 60px 20px;\r\n color: #8c8c8c;\r\n}\r\n\r\n.loading-spinner {\r\n width: 32px;\r\n height: 32px;\r\n border: 3px solid #f0f0f0;\r\n border-top: 3px solid #1890ff;\r\n border-radius: 50%;\r\n animation: spin 1s linear infinite;\r\n margin-bottom: 16px;\r\n}\r\n\r\n@keyframes spin {\r\n 0% { transform: rotate(0deg); }\r\n 100% { transform: rotate(360deg); }\r\n}\r\n\r\n/* 空状态 */\r\n.empty-container {\r\n display: flex;\r\n flex-direction: column;\r\n align-items: center;\r\n justify-content: center;\r\n padding: 60px 20px;\r\n color: #8c8c8c;\r\n}\r\n\r\n.empty-icon {\r\n font-size: 48px;\r\n margin-bottom: 16px;\r\n opacity: 0.6;\r\n}\r\n\r\n.empty-text {\r\n font-size: 14px;\r\n color: #8c8c8c;\r\n}\r\n\r\n/* 分页容器 */\r\n.pagination-container {\r\n display: flex;\r\n align-items: center;\r\n justify-content: space-between;\r\n padding: 16px 0;\r\n border-top: 1px solid #f0f0f0;\r\n}\r\n\r\n.pagination-info {\r\n color: #8c8c8c;\r\n font-size: 14px;\r\n}\r\n\r\n.pagination-controls {\r\n display: flex;\r\n align-items: center;\r\n gap: 12px;\r\n}\r\n\r\n.pagination-btn {\r\n padding: 6px 12px;\r\n border: 1px solid #d9d9d9;\r\n background: white;\r\n color: #595959;\r\n border-radius: 4px;\r\n cursor: pointer;\r\n font-size: 14px;\r\n transition: all 0.2s;\r\n}\r\n\r\n.pagination-btn:hover:not(:disabled) {\r\n border-color: #40a9ff;\r\n color: #40a9ff;\r\n}\r\n\r\n.pagination-btn:disabled {\r\n background-color: #f5f5f5;\r\n color: #bfbfbf;\r\n cursor: not-allowed;\r\n border-color: #f0f0f0;\r\n}\r\n\r\n.pagination-current {\r\n color: #262626;\r\n font-size: 14px;\r\n font-weight: 500;\r\n padding: 0 8px;\r\n}\r\n\r\n.pagination-size-select {\r\n padding: 6px 8px;\r\n border: 1px solid #d9d9d9;\r\n border-radius: 4px;\r\n background: white;\r\n color: #595959;\r\n font-size: 14px;\r\n cursor: pointer;\r\n transition: all 0.2s;\r\n}\r\n\r\n.pagination-size-select:hover {\r\n border-color: #40a9ff;\r\n}\r\n\r\n.pagination-size-select:focus {\r\n outline: none;\r\n border-color: #40a9ff;\r\n box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.2);\r\n}\r\n\r\n/* 消息提示 */\r\n.message {\r\n position: fixed;\r\n top: 24px;\r\n left: 50%;\r\n transform: translateX(-50%);\r\n padding: 12px 24px;\r\n border-radius: 6px;\r\n font-size: 14px;\r\n font-weight: 500;\r\n z-index: 1100;\r\n box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);\r\n animation: messageSlideIn 0.3s ease-out;\r\n}\r\n\r\n.message-success {\r\n background-color: #f6ffed;\r\n color: #52c41a;\r\n border: 1px solid #b7eb8f;\r\n}\r\n\r\n.message-error {\r\n background-color: #fff2f0;\r\n color: #ff4d4f;\r\n border: 1px solid #ffccc7;\r\n}\r\n\r\n@keyframes messageSlideIn {\r\n from {\r\n opacity: 0;\r\n transform: translateX(-50%) translateY(-20px);\r\n }\r\n to {\r\n opacity: 1;\r\n transform: translateX(-50%) translateY(0);\r\n }\r\n}\r\n\r\n/* 响应式设计 */\r\n@media (max-width: 768px) {\r\n .modal-container {\r\n margin: 20px;\r\n max-width: calc(100vw - 40px);\r\n }\r\n \r\n .modal-header {\r\n padding: 12px 16px;\r\n }\r\n \r\n .modal-body {\r\n padding: 16px;\r\n }\r\n \r\n .table th,\r\n .table td {\r\n padding: 8px 12px;\r\n font-size: 13px;\r\n }\r\n \r\n .pagination-container {\r\n flex-direction: column;\r\n gap: 12px;\r\n align-items: stretch;\r\n }\r\n \r\n .pagination-controls {\r\n justify-content: center;\r\n }\r\n \r\n .modal-title {\r\n font-size: 14px;\r\n gap: 8px;\r\n }\r\n}\r\n\r\n@media (max-width: 480px) {\r\n .table-container {\r\n overflow-x: auto;\r\n }\r\n \r\n .table {\r\n min-width: 600px;\r\n }\r\n \r\n .action-buttons {\r\n flex-direction: column;\r\n gap: 4px;\r\n }\r\n}","import { Component, Prop, State, h, Watch, Event, EventEmitter } from '@stencil/core';\r\nimport { getCosPresignedUrl, sendHttpRequest } from '../../utils/utils';\r\n\r\ninterface ExportRecord {\r\n id: string;\r\n file_name: string;\r\n status: number;\r\n created_at: string;\r\n cos_key?: string;\r\n}\r\n\r\ninterface PaginationType {\r\n page: number;\r\n size: number;\r\n total?: number;\r\n}\r\n\r\nconst DEFAULT_PAGINATION = {\r\n page: 1,\r\n size: 10,\r\n};\r\n\r\nconst EXPORT_BATCH_STATUS_MAP: Record<string, { text: string; color: string }> = {\r\n '0': { text: '处理中', color: '#1890ff' },\r\n '1': { text: '已完成', color: '#52c41a' },\r\n '-1': { text: '失败', color: '#ff4d4f' },\r\n};\r\n\r\n@Component({\r\n tag: 'components-export-records-modal',\r\n styleUrl: 'components-export-records-modal.css',\r\n shadow: true,\r\n})\r\nexport class ComponentsExportRecordsModal {\r\n @Prop() botId?: string;\r\n @Prop() sourceId?: string;\r\n @Prop() open: boolean = false;\r\n @Event() cancel: EventEmitter<void>;\r\n\r\n @State() loading: boolean = true;\r\n @State() pagination: PaginationType = DEFAULT_PAGINATION;\r\n @State() data: ExportRecord[] = [];\r\n @State() showMessage: boolean = false;\r\n @State() messageText: string = '';\r\n @State() messageType: 'success' | 'error' = 'success';\r\n\r\n @Watch('open')\r\n watchOpen(newValue: boolean) {\r\n if (newValue) {\r\n this.fetchData(this.pagination);\r\n }\r\n }\r\n\r\n private async fetchData(p: PaginationType) {\r\n this.loading = true;\r\n try {\r\n // 模拟API调用\r\n const response = await sendHttpRequest({\r\n url: '/sdk/v1/export_batch/page',\r\n method: 'GET',\r\n params: {\r\n page: p.page,\r\n size: p.size,\r\n bot_id: this.botId,\r\n source_id: this.sourceId,\r\n },\r\n });\r\n if (response.success && response.data) {\r\n const records = response?.data?.records ?? [];\r\n this.data = records;\r\n this.pagination = {\r\n ...p,\r\n total: response?.data?.total ?? 0,\r\n };\r\n }\r\n } catch (error) {\r\n console.error('Failed to fetch data:', error);\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n private async handleDownload(record: ExportRecord) {\r\n try {\r\n const downloadUrl = await getCosPresignedUrl(record.cos_key);\r\n const fileName = record.file_name;\r\n if (downloadUrl) {\r\n const link = document.createElement(\"a\");\r\n link.href = downloadUrl;\r\n link.setAttribute(\"download\", fileName);\r\n document.body.appendChild(link);\r\n link.click();\r\n link.remove();\r\n this.showMessageToast('下载成功', 'success');\r\n } else {\r\n this.showMessageToast('获取下载链接失败', 'error');\r\n }\r\n \r\n } catch (error) {\r\n this.showMessageToast('下载失败', 'error');\r\n }\r\n }\r\n\r\n private async handleDelete(record: ExportRecord) {\r\n try {\r\n const response = await sendHttpRequest({\r\n url: `/sdk/v1/export_batch/delete/${record.id}`,\r\n method: \"DELETE\",\r\n });\r\n if (response?.success) {\r\n this.showMessageToast('删除成功', 'success');\r\n setTimeout(() => {\r\n this.fetchData(this.pagination);\r\n }, 100);\r\n }\r\n } catch (error) {\r\n this.showMessageToast(`删除失败: ${error.message}`, 'error');\r\n }\r\n }\r\n\r\n private showMessageToast(text: string, type: 'success' | 'error') {\r\n this.messageText = text;\r\n this.messageType = type;\r\n this.showMessage = true;\r\n setTimeout(() => {\r\n this.showMessage = false;\r\n }, 3000);\r\n }\r\n\r\n private handleRefresh = () => {\r\n this.fetchData(this.pagination);\r\n };\r\n\r\n private handlePageChange = (page: number, size: number) => {\r\n const newPagination = {\r\n ...this.pagination,\r\n page,\r\n size,\r\n };\r\n this.fetchData(newPagination);\r\n };\r\n\r\n private formatDate(dateString: string): string {\r\n const date = new Date(dateString);\r\n return date.toLocaleString('zh-CN', {\r\n year: 'numeric',\r\n month: '2-digit',\r\n day: '2-digit',\r\n hour: '2-digit',\r\n minute: '2-digit',\r\n second: '2-digit',\r\n });\r\n }\r\n\r\n private renderEmpty() {\r\n return (\r\n <div class=\"empty-container\">\r\n <div class=\"empty-icon\">📄</div>\r\n <div class=\"empty-text\">暂无任务</div>\r\n </div>\r\n );\r\n }\r\n\r\n private renderTag(status: number) {\r\n const statusInfo = EXPORT_BATCH_STATUS_MAP[status.toString()] || { text: '未知', color: '#d9d9d9' };\r\n return (\r\n <span class=\"tag\" style={{ backgroundColor: statusInfo.color }}>\r\n {statusInfo.text}\r\n </span>\r\n );\r\n }\r\n\r\n private renderButton(text: string, onClick: () => void, variant: 'primary' | 'default' | 'danger' = 'default', size: 'small' | 'medium' = 'medium') {\r\n return (\r\n <button\r\n class={`btn btn-${variant} btn-${size}`}\r\n onClick={onClick}\r\n >\r\n {text}\r\n </button>\r\n );\r\n }\r\n\r\n private renderTable() {\r\n if (this.loading) {\r\n return (\r\n <div class=\"loading-container\">\r\n <div class=\"loading-spinner\"></div>\r\n <div>加载中...</div>\r\n </div>\r\n );\r\n }\r\n\r\n if (!this.data || this.data.length === 0) {\r\n return this.renderEmpty();\r\n }\r\n\r\n return (\r\n <div class=\"table-container\">\r\n <table class=\"table\">\r\n <thead>\r\n <tr>\r\n <th style={{ width: '300px', textAlign: 'center' }}>文件名</th>\r\n <th style={{ width: '100px', textAlign: 'center' }}>状态</th>\r\n <th style={{ width: '180px', textAlign: 'center' }}>创建时间</th>\r\n <th style={{ width: '100px', textAlign: 'left' }}>操作</th>\r\n </tr>\r\n </thead>\r\n <tbody>\r\n {this.data.map((record) => (\r\n <tr key={record.id}>\r\n <td style={{ textAlign: 'center' }}>{record.file_name}</td>\r\n <td style={{ textAlign: 'center' }}>\r\n {this.renderTag(record.status)}\r\n </td>\r\n <td style={{ textAlign: 'center' }}>\r\n {this.formatDate(record.created_at)}\r\n </td>\r\n <td style={{ textAlign: 'left' }}>\r\n <div class=\"action-buttons\">\r\n {record.status !== 0 && this.renderButton(\r\n '删除',\r\n () => this.handleDelete(record),\r\n 'danger',\r\n 'small'\r\n )}\r\n {record.cos_key && this.renderButton(\r\n '下载',\r\n () => this.handleDownload(record),\r\n 'primary',\r\n 'small'\r\n )}\r\n </div>\r\n </td>\r\n </tr>\r\n ))}\r\n </tbody>\r\n </table>\r\n </div>\r\n );\r\n }\r\n\r\n private renderPagination() {\r\n if (!this.pagination.total || this.pagination.total === 0) {\r\n return null;\r\n }\r\n\r\n const totalPages = Math.ceil(this.pagination.total / this.pagination.size);\r\n const currentPage = this.pagination.page;\r\n\r\n return (\r\n <div class=\"pagination-container\">\r\n <div class=\"pagination-info\">\r\n 共{this.pagination.total}条\r\n </div>\r\n <div class=\"pagination-controls\">\r\n <button\r\n class=\"pagination-btn\"\r\n disabled={currentPage <= 1}\r\n onClick={() => this.handlePageChange(currentPage - 1, this.pagination.size)}\r\n >\r\n 上一页\r\n </button>\r\n <span class=\"pagination-current\">\r\n {currentPage} / {totalPages}\r\n </span>\r\n <button\r\n class=\"pagination-btn\"\r\n disabled={currentPage >= totalPages}\r\n onClick={() => this.handlePageChange(currentPage + 1, this.pagination.size)}\r\n >\r\n 下一页\r\n </button>\r\n <select\r\n class=\"pagination-size-select\"\r\n onChange={(e) => this.handlePageChange(1, parseInt((e.target as HTMLSelectElement).value))}\r\n >\r\n <option value=\"10\" selected={this.pagination.size === 10}>10条/页</option>\r\n <option value=\"20\" selected={this.pagination.size === 20}>20条/页</option>\r\n <option value=\"50\" selected={this.pagination.size === 50}>50条/页</option>\r\n </select>\r\n </div>\r\n </div>\r\n );\r\n }\r\n\r\n private renderMessage() {\r\n if (!this.showMessage) return null;\r\n\r\n return (\r\n <div class={`message message-${this.messageType}`}>\r\n {this.messageText}\r\n </div>\r\n );\r\n }\r\n\r\n render() {\r\n if (!this.open) {\r\n return null;\r\n }\r\n\r\n return (\r\n <div class=\"modal-overlay\" onClick={() => this.cancel.emit()}>\r\n <div class=\"modal-container\" onClick={(e) => e.stopPropagation()}>\r\n <div class=\"modal-header\">\r\n <div class=\"modal-title\">\r\n <span>导出任务列表</span>\r\n {this.renderButton(\r\n '🔄 刷新',\r\n this.handleRefresh,\r\n 'default',\r\n 'small'\r\n )}\r\n </div>\r\n <button class=\"modal-close\" onClick={() => this.cancel.emit()}>\r\n ✕\r\n </button>\r\n </div>\r\n <div class=\"modal-body\">\r\n {this.renderTable()}\r\n {this.renderPagination()}\r\n </div>\r\n {this.renderMessage()}\r\n </div>\r\n </div>\r\n );\r\n }\r\n}"],"version":3}
1
+ {"file":"p-CB7myOe_.js","mappings":";;;AAAA,MAAM,+BAA+B,GAAG,2rJAA2rJ;;ACiBnuJ,MAAM,kBAAkB,GAAG;AACzB,IAAA,IAAI,EAAE,CAAC;AACP,IAAA,IAAI,EAAE,EAAE;CACT;AAED,MAAM,uBAAuB,GAAoD;IAC/E,GAAG,EAAE,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,SAAS,EAAE;IACtC,GAAG,EAAE,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,SAAS,EAAE;IACtC,IAAI,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,SAAS,EAAE;CACvC;MAOY,4BAA4B,iBAAAA,kBAAA,CAAA,MAAA,4BAAA,SAAAC,CAAA,CAAA;;;;;;;AAC/B,IAAA,KAAK;AACL,IAAA,QAAQ;IACR,IAAI,GAAY,KAAK;AACpB,IAAA,MAAM;IAEN,OAAO,GAAY,IAAI;IACvB,UAAU,GAAmB,kBAAkB;IAC/C,IAAI,GAAmB,EAAE;IACzB,WAAW,GAAY,KAAK;IAC5B,WAAW,GAAW,EAAE;IACxB,WAAW,GAAwB,SAAS;AAGrD,IAAA,SAAS,CAAC,QAAiB,EAAA;QACzB,IAAI,QAAQ,EAAE;AACZ,YAAA,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,UAAU,CAAC;;;IAI3B,MAAM,SAAS,CAAC,CAAiB,EAAA;AACvC,QAAA,IAAI,CAAC,OAAO,GAAG,IAAI;AACnB,QAAA,IAAI;;AAEF,YAAA,M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AC,OAAO,EAAE,MAAM,IAAI,CAAC,MAAM,CAAC,IAAI,EAAE,aAEpD,CACL,EACN,CAAK,CAAA,KAAA,EAAA,EAAA,KAAK,EAAC,YAAY,EAAA,EACpB,IAAI,CAAC,WAAW,EAAE,EAClB,IAAI,CAAC,gBAAgB,EAAE,CACpB,EACL,IAAI,CAAC,aAAa,EAAE,CACjB,CACF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/components-export-records-modal/components-export-records-modal.css?tag=components-export-records-modal&encapsulation=shadow","src/components/components-export-records-modal/components-export-records-modal.tsx"],"sourcesContent":["/* 模态框遮罩层 */\r\n.modal-overlay {\r\n position: fixed;\r\n top: 0;\r\n left: 0;\r\n right: 0;\r\n bottom: 0;\r\n background-color: rgba(0, 0, 0, 0.45);\r\n display: flex;\r\n align-items: flex-start;\r\n justify-content: center;\r\n z-index: 1000;\r\n backdrop-filter: blur(4px);\r\n}\r\n\r\n/* 模态框容器 */\r\n.modal-container {\r\n background: white;\r\n border-radius: 8px;\r\n box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);\r\n max-width: min(1000px, calc(100vw - 40px));\r\n max-height: calc(100vh - 40px);\r\n width: 100%;\r\n display: flex;\r\n flex-direction: column;\r\n overflow: hidden;\r\n}\r\n\r\n/* 模态框头部 */\r\n.modal-header {\r\n padding: 16px 24px;\r\n border-bottom: 1px solid #f0f0f0;\r\n display: flex;\r\n align-items: center;\r\n justify-content: space-between;\r\n background: #fafafa;\r\n}\r\n\r\n.modal-title {\r\n display: flex;\r\n align-items: center;\r\n gap: 16px;\r\n font-size: 16px;\r\n font-weight: 600;\r\n color: #262626;\r\n}\r\n\r\n.modal-close {\r\n background: none;\r\n border: none;\r\n font-size: 18px;\r\n color: #8c8c8c;\r\n cursor: pointer;\r\n padding: 4px;\r\n border-radius: 4px;\r\n transition: all 0.2s;\r\n}\r\n\r\n.modal-close:hover {\r\n background-color: #f5f5f5;\r\n color: #262626;\r\n}\r\n\r\n/* 模态框主体 */\r\n.modal-body {\r\n padding: 24px;\r\n flex: 1;\r\n overflow: auto;\r\n}\r\n\r\n/* 按钮样式 */\r\n.btn {\r\n border: none;\r\n border-radius: 6px;\r\n cursor: pointer;\r\n font-size: 14px;\r\n font-weight: 400;\r\n transition: all 0.2s;\r\n display: inline-flex;\r\n align-items: center;\r\n justify-content: center;\r\n gap: 4px;\r\n}\r\n\r\n.btn-small {\r\n padding: 4px 8px;\r\n font-size: 12px;\r\n}\r\n\r\n.btn-medium {\r\n padding: 8px 16px;\r\n}\r\n\r\n.btn-primary {\r\n background-color: #1890ff;\r\n color: white;\r\n border: 1px solid #1890ff;\r\n}\r\n\r\n.btn-primary:hover {\r\n background-color: #40a9ff;\r\n border-color: #40a9ff;\r\n}\r\n\r\n.btn-default {\r\n background-color: white;\r\n color: #595959;\r\n border: 1px solid #d9d9d9;\r\n}\r\n\r\n.btn-default:hover {\r\n background-color: #f5f5f5;\r\n border-color: #40a9ff;\r\n color: #40a9ff;\r\n}\r\n\r\n.btn-danger {\r\n background-color: #f5222d;\r\n color: white;\r\n border: 1px solid #f5222d;\r\n}\r\n\r\n.btn-danger:hover {\r\n background-color: #cf1322;\r\n border-color: #cf1322;\r\n}\r\n\r\n/* 表格容器 */\r\n.table-container {\r\n border: 1px solid #f0f0f0;\r\n border-radius: 6px;\r\n overflow: hidden;\r\n margin-bottom: 16px;\r\n}\r\n\r\n/* 表格样式 */\r\n.table {\r\n width: 100%;\r\n border-collapse: collapse;\r\n background: white;\r\n}\r\n\r\n.table th {\r\n background-color: #fafafa;\r\n padding: 12px 16px;\r\n font-weight: 600;\r\n color: #262626;\r\n border-bottom: 1px solid #f0f0f0;\r\n font-size: 14px;\r\n}\r\n\r\n.table td {\r\n padding: 12px 16px;\r\n border-bottom: 1px solid #f0f0f0;\r\n color: #595959;\r\n font-size: 14px;\r\n}\r\n\r\n.table tbody tr:hover {\r\n background-color: #f5f5f5;\r\n}\r\n\r\n.table tbody tr:last-child td {\r\n border-bottom: none;\r\n}\r\n\r\n/* 标签样式 */\r\n.tag {\r\n display: inline-block;\r\n padding: 2px 8px;\r\n border-radius: 4px;\r\n font-size: 12px;\r\n font-weight: 400;\r\n color: white;\r\n text-align: center;\r\n min-width: 60px;\r\n}\r\n\r\n/* 操作按钮容器 */\r\n.action-buttons {\r\n display: flex;\r\n gap: 8px;\r\n}\r\n\r\n/* 加载状态 */\r\n.loading-container {\r\n display: flex;\r\n flex-direction: column;\r\n align-items: center;\r\n justify-content: center;\r\n padding: 60px 20px;\r\n color: #8c8c8c;\r\n}\r\n\r\n.loading-spinner {\r\n width: 32px;\r\n height: 32px;\r\n border: 3px solid #f0f0f0;\r\n border-top: 3px solid #1890ff;\r\n border-radius: 50%;\r\n animation: spin 1s linear infinite;\r\n margin-bottom: 16px;\r\n}\r\n\r\n@keyframes spin {\r\n 0% { transform: rotate(0deg); }\r\n 100% { transform: rotate(360deg); }\r\n}\r\n\r\n/* 空状态 */\r\n.empty-container {\r\n display: flex;\r\n flex-direction: column;\r\n align-items: center;\r\n justify-content: center;\r\n padding: 60px 20px;\r\n color: #8c8c8c;\r\n}\r\n\r\n.empty-icon {\r\n font-size: 48px;\r\n margin-bottom: 16px;\r\n opacity: 0.6;\r\n}\r\n\r\n.empty-text {\r\n font-size: 14px;\r\n color: #8c8c8c;\r\n}\r\n\r\n/* 分页容器 */\r\n.pagination-container {\r\n display: flex;\r\n align-items: center;\r\n justify-content: space-between;\r\n padding: 16px 0;\r\n border-top: 1px solid #f0f0f0;\r\n}\r\n\r\n.pagination-info {\r\n color: #8c8c8c;\r\n font-size: 14px;\r\n}\r\n\r\n.pagination-controls {\r\n display: flex;\r\n align-items: center;\r\n gap: 12px;\r\n}\r\n\r\n.pagination-btn {\r\n padding: 6px 12px;\r\n border: 1px solid #d9d9d9;\r\n background: white;\r\n color: #595959;\r\n border-radius: 4px;\r\n cursor: pointer;\r\n font-size: 14px;\r\n transition: all 0.2s;\r\n}\r\n\r\n.pagination-btn:hover:not(:disabled) {\r\n border-color: #40a9ff;\r\n color: #40a9ff;\r\n}\r\n\r\n.pagination-btn:disabled {\r\n background-color: #f5f5f5;\r\n color: #bfbfbf;\r\n cursor: not-allowed;\r\n border-color: #f0f0f0;\r\n}\r\n\r\n.pagination-current {\r\n color: #262626;\r\n font-size: 14px;\r\n font-weight: 500;\r\n padding: 0 8px;\r\n}\r\n\r\n.pagination-size-select {\r\n padding: 6px 8px;\r\n border: 1px solid #d9d9d9;\r\n border-radius: 4px;\r\n background: white;\r\n color: #595959;\r\n font-size: 14px;\r\n cursor: pointer;\r\n transition: all 0.2s;\r\n}\r\n\r\n.pagination-size-select:hover {\r\n border-color: #40a9ff;\r\n}\r\n\r\n.pagination-size-select:focus {\r\n outline: none;\r\n border-color: #40a9ff;\r\n box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.2);\r\n}\r\n\r\n/* 消息提示 */\r\n.message {\r\n position: fixed;\r\n top: 24px;\r\n left: 50%;\r\n transform: translateX(-50%);\r\n padding: 12px 24px;\r\n border-radius: 6px;\r\n font-size: 14px;\r\n font-weight: 500;\r\n z-index: 1100;\r\n box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);\r\n animation: messageSlideIn 0.3s ease-out;\r\n}\r\n\r\n.message-success {\r\n background-color: #f6ffed;\r\n color: #52c41a;\r\n border: 1px solid #b7eb8f;\r\n}\r\n\r\n.message-error {\r\n background-color: #fff2f0;\r\n color: #ff4d4f;\r\n border: 1px solid #ffccc7;\r\n}\r\n\r\n@keyframes messageSlideIn {\r\n from {\r\n opacity: 0;\r\n transform: translateX(-50%) translateY(-20px);\r\n }\r\n to {\r\n opacity: 1;\r\n transform: translateX(-50%) translateY(0);\r\n }\r\n}\r\n\r\n/* 响应式设计 */\r\n@media (max-width: 768px) {\r\n .modal-container {\r\n margin: 20px;\r\n max-width: calc(100vw - 40px);\r\n }\r\n \r\n .modal-header {\r\n padding: 12px 16px;\r\n }\r\n \r\n .modal-body {\r\n padding: 16px;\r\n }\r\n \r\n .table th,\r\n .table td {\r\n padding: 8px 12px;\r\n font-size: 13px;\r\n }\r\n \r\n .pagination-container {\r\n flex-direction: column;\r\n gap: 12px;\r\n align-items: stretch;\r\n }\r\n \r\n .pagination-controls {\r\n justify-content: center;\r\n }\r\n \r\n .modal-title {\r\n font-size: 14px;\r\n gap: 8px;\r\n }\r\n}\r\n\r\n@media (max-width: 480px) {\r\n .table-container {\r\n overflow-x: auto;\r\n }\r\n \r\n .table {\r\n min-width: 600px;\r\n }\r\n \r\n .action-buttons {\r\n flex-direction: column;\r\n gap: 4px;\r\n }\r\n}","import { Component, Prop, State, h, Watch, Event, EventEmitter } from '@stencil/core';\r\nimport { getCosPresignedUrl, sendHttpRequest } from '../../utils/utils';\r\n\r\ninterface ExportRecord {\r\n id: string;\r\n file_name: string;\r\n status: number;\r\n created_at: string;\r\n cos_key?: string;\r\n}\r\n\r\ninterface PaginationType {\r\n page: number;\r\n size: number;\r\n total?: number;\r\n}\r\n\r\nconst DEFAULT_PAGINATION = {\r\n page: 1,\r\n size: 10,\r\n};\r\n\r\nconst EXPORT_BATCH_STATUS_MAP: Record<string, { text: string; color: string }> = {\r\n '0': { text: '处理中', color: '#1890ff' },\r\n '1': { text: '已完成', color: '#52c41a' },\r\n '-1': { text: '失败', color: '#ff4d4f' },\r\n};\r\n\r\n@Component({\r\n tag: 'components-export-records-modal',\r\n styleUrl: 'components-export-records-modal.css',\r\n shadow: true,\r\n})\r\nexport class ComponentsExportRecordsModal {\r\n @Prop() botId?: string;\r\n @Prop() sourceId?: string;\r\n @Prop() open: boolean = false;\r\n @Event() cancel: EventEmitter<void>;\r\n\r\n @State() loading: boolean = true;\r\n @State() pagination: PaginationType = DEFAULT_PAGINATION;\r\n @State() data: ExportRecord[] = [];\r\n @State() showMessage: boolean = false;\r\n @State() messageText: string = '';\r\n @State() messageType: 'success' | 'error' = 'success';\r\n\r\n @Watch('open')\r\n watchOpen(newValue: boolean) {\r\n if (newValue) {\r\n this.fetchData(this.pagination);\r\n }\r\n }\r\n\r\n private async fetchData(p: PaginationType) {\r\n this.loading = true;\r\n try {\r\n // 模拟API调用\r\n const response = await sendHttpRequest({\r\n url: '/sdk/v1/export_batch/page',\r\n method: 'GET',\r\n params: {\r\n page: p.page,\r\n size: p.size,\r\n bot_id: this.botId,\r\n source_id: this.sourceId,\r\n },\r\n });\r\n if (response.success && response.data) {\r\n const records = response?.data?.records ?? [];\r\n this.data = records;\r\n this.pagination = {\r\n ...p,\r\n total: response?.data?.total ?? 0,\r\n };\r\n }\r\n } catch (error) {\r\n console.error('Failed to fetch data:', error);\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n private async handleDownload(record: ExportRecord) {\r\n try {\r\n const downloadUrl = await getCosPresignedUrl(record.cos_key);\r\n const fileName = record.file_name;\r\n if (downloadUrl) {\r\n const link = document.createElement(\"a\");\r\n link.href = downloadUrl;\r\n link.setAttribute(\"download\", fileName);\r\n document.body.appendChild(link);\r\n link.click();\r\n link.remove();\r\n this.showMessageToast('下载成功', 'success');\r\n } else {\r\n this.showMessageToast('获取下载链接失败', 'error');\r\n }\r\n \r\n } catch (error) {\r\n this.showMessageToast('下载失败', 'error');\r\n }\r\n }\r\n\r\n private async handleDelete(record: ExportRecord) {\r\n try {\r\n const response = await sendHttpRequest({\r\n url: `/sdk/v1/export_batch/delete/${record.id}`,\r\n method: \"DELETE\",\r\n });\r\n if (response?.success) {\r\n this.showMessageToast('删除成功', 'success');\r\n setTimeout(() => {\r\n this.fetchData(this.pagination);\r\n }, 100);\r\n }\r\n } catch (error) {\r\n this.showMessageToast(`删除失败: ${error.message}`, 'error');\r\n }\r\n }\r\n\r\n private showMessageToast(text: string, type: 'success' | 'error') {\r\n this.messageText = text;\r\n this.messageType = type;\r\n this.showMessage = true;\r\n setTimeout(() => {\r\n this.showMessage = false;\r\n }, 3000);\r\n }\r\n\r\n private handleRefresh = () => {\r\n this.fetchData(this.pagination);\r\n };\r\n\r\n private handlePageChange = (page: number, size: number) => {\r\n const newPagination = {\r\n ...this.pagination,\r\n page,\r\n size,\r\n };\r\n this.fetchData(newPagination);\r\n };\r\n\r\n private formatDate(dateString: string): string {\r\n const date = new Date(dateString);\r\n return date.toLocaleString('zh-CN', {\r\n year: 'numeric',\r\n month: '2-digit',\r\n day: '2-digit',\r\n hour: '2-digit',\r\n minute: '2-digit',\r\n second: '2-digit',\r\n });\r\n }\r\n\r\n private renderEmpty() {\r\n return (\r\n <div class=\"empty-container\">\r\n <div class=\"empty-icon\">📄</div>\r\n <div class=\"empty-text\">暂无任务</div>\r\n </div>\r\n );\r\n }\r\n\r\n private renderTag(status: number) {\r\n const statusInfo = EXPORT_BATCH_STATUS_MAP[status.toString()] || { text: '未知', color: '#d9d9d9' };\r\n return (\r\n <span class=\"tag\" style={{ backgroundColor: statusInfo.color }}>\r\n {statusInfo.text}\r\n </span>\r\n );\r\n }\r\n\r\n private renderButton(text: string, onClick: () => void, variant: 'primary' | 'default' | 'danger' = 'default', size: 'small' | 'medium' = 'medium') {\r\n return (\r\n <button\r\n class={`btn btn-${variant} btn-${size}`}\r\n onClick={onClick}\r\n >\r\n {text}\r\n </button>\r\n );\r\n }\r\n\r\n private renderTable() {\r\n if (this.loading) {\r\n return (\r\n <div class=\"loading-container\">\r\n <div class=\"loading-spinner\"></div>\r\n <div>加载中...</div>\r\n </div>\r\n );\r\n }\r\n\r\n if (!this.data || this.data.length === 0) {\r\n return this.renderEmpty();\r\n }\r\n\r\n return (\r\n <div class=\"table-container\">\r\n <table class=\"table\">\r\n <thead>\r\n <tr>\r\n <th style={{ width: '300px', textAlign: 'center' }}>文件名</th>\r\n <th style={{ width: '100px', textAlign: 'center' }}>状态</th>\r\n <th style={{ width: '180px', textAlign: 'center' }}>创建时间</th>\r\n <th style={{ width: '100px', textAlign: 'left' }}>操作</th>\r\n </tr>\r\n </thead>\r\n <tbody>\r\n {this.data.map((record) => (\r\n <tr key={record.id}>\r\n <td style={{ textAlign: 'center' }}>{record.file_name}</td>\r\n <td style={{ textAlign: 'center' }}>\r\n {this.renderTag(record.status)}\r\n </td>\r\n <td style={{ textAlign: 'center' }}>\r\n {this.formatDate(record.created_at)}\r\n </td>\r\n <td style={{ textAlign: 'left' }}>\r\n <div class=\"action-buttons\">\r\n {record.status !== 0 && this.renderButton(\r\n '删除',\r\n () => this.handleDelete(record),\r\n 'danger',\r\n 'small'\r\n )}\r\n {record.cos_key && this.renderButton(\r\n '下载',\r\n () => this.handleDownload(record),\r\n 'primary',\r\n 'small'\r\n )}\r\n </div>\r\n </td>\r\n </tr>\r\n ))}\r\n </tbody>\r\n </table>\r\n </div>\r\n );\r\n }\r\n\r\n private renderPagination() {\r\n if (!this.pagination.total || this.pagination.total === 0) {\r\n return null;\r\n }\r\n\r\n const totalPages = Math.ceil(this.pagination.total / this.pagination.size);\r\n const currentPage = this.pagination.page;\r\n\r\n return (\r\n <div class=\"pagination-container\">\r\n <div class=\"pagination-info\">\r\n 共{this.pagination.total}条\r\n </div>\r\n <div class=\"pagination-controls\">\r\n <button\r\n class=\"pagination-btn\"\r\n disabled={currentPage <= 1}\r\n onClick={() => this.handlePageChange(currentPage - 1, this.pagination.size)}\r\n >\r\n 上一页\r\n </button>\r\n <span class=\"pagination-current\">\r\n {currentPage} / {totalPages}\r\n </span>\r\n <button\r\n class=\"pagination-btn\"\r\n disabled={currentPage >= totalPages}\r\n onClick={() => this.handlePageChange(currentPage + 1, this.pagination.size)}\r\n >\r\n 下一页\r\n </button>\r\n <select\r\n class=\"pagination-size-select\"\r\n onChange={(e) => this.handlePageChange(1, parseInt((e.target as HTMLSelectElement).value))}\r\n >\r\n <option value=\"10\" selected={this.pagination.size === 10}>10条/页</option>\r\n <option value=\"20\" selected={this.pagination.size === 20}>20条/页</option>\r\n <option value=\"50\" selected={this.pagination.size === 50}>50条/页</option>\r\n </select>\r\n </div>\r\n </div>\r\n );\r\n }\r\n\r\n private renderMessage() {\r\n if (!this.showMessage) return null;\r\n\r\n return (\r\n <div class={`message message-${this.messageType}`}>\r\n {this.messageText}\r\n </div>\r\n );\r\n }\r\n\r\n render() {\r\n if (!this.open) {\r\n return null;\r\n }\r\n\r\n return (\r\n <div class=\"modal-overlay\" onClick={() => this.cancel.emit()}>\r\n <div class=\"modal-container\" onClick={(e) => e.stopPropagation()}>\r\n <div class=\"modal-header\">\r\n <div class=\"modal-title\">\r\n <span>导出任务列表</span>\r\n {this.renderButton(\r\n '🔄 刷新',\r\n this.handleRefresh,\r\n 'default',\r\n 'small'\r\n )}\r\n </div>\r\n <button class=\"modal-close\" onClick={() => this.cancel.emit()}>\r\n ✕\r\n </button>\r\n </div>\r\n <div class=\"modal-body\">\r\n {this.renderTable()}\r\n {this.renderPagination()}\r\n </div>\r\n {this.renderMessage()}\r\n </div>\r\n </div>\r\n );\r\n }\r\n}"],"version":3}
@@ -1,7 +1,7 @@
1
1
  import { p as proxyCustomElement, H, c as createEvent, h } from './p-CR7WLzmM.js';
2
2
  import { m as marked, e as extendedTables } from './p-CiuTLfbq.js';
3
3
  import { g as getDefaultExportFromCjs } from './p-B85MJLTf.js';
4
- import { s as sendHttpRequest, k as getCosPresignedUrl, g as getCosPreviewUrl } from './p-DuRuN7gY.js';
4
+ import { s as sendHttpRequest, k as getCosPresignedUrl, g as getCosPreviewUrl } from './p-i4wY2JnB.js';
5
5
  import { E as ErrorEventBus } from './p-C0FYX2-Z.js';
6
6
  import { S as SentryReporter } from './p-DC-AWTHS.js';
7
7
 
@@ -1461,6 +1461,6 @@ function defineCustomElement() {
1461
1461
  defineCustomElement();
1462
1462
 
1463
1463
  export { ComponentsChatMessage as C, defineCustomElement as d };
1464
- //# sourceMappingURL=p-DNPkGKCS.js.map
1464
+ //# sourceMappingURL=p-CEu-bFot.js.map
1465
1465
 
1466
- //# sourceMappingURL=p-DNPkGKCS.js.map
1466
+ //# sourceMappingURL=p-CEu-bFot.js.map