@botonic/react 0.56.0-alpha.0 → 0.57.0-rslib-esm.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/esm/app.js +4 -5
- package/lib/esm/app.js.map +1 -1
- package/lib/esm/assets/types.d.ts +4 -0
- package/lib/esm/botonic-tester.js +79 -33
- package/lib/esm/botonic-tester.js.map +1 -1
- package/lib/esm/components/audio.d.ts +1 -1
- package/lib/esm/components/audio.js +52 -20
- package/lib/esm/components/audio.js.map +1 -1
- package/lib/esm/components/button/index.d.ts +1 -1
- package/lib/esm/components/button/index.js +113 -69
- package/lib/esm/components/button/index.js.map +1 -1
- package/lib/esm/components/button/styles.js +27 -25
- package/lib/esm/components/button/styles.js.map +1 -1
- package/lib/esm/components/buttons-disabler.d.ts +1 -1
- package/lib/esm/components/buttons-disabler.js +37 -34
- package/lib/esm/components/buttons-disabler.js.map +1 -1
- package/lib/esm/components/carousel.d.ts +1 -1
- package/lib/esm/components/carousel.js +143 -66
- package/lib/esm/components/carousel.js.map +1 -1
- package/lib/esm/components/components.js +5 -8
- package/lib/esm/components/components.js.map +1 -1
- package/lib/esm/components/constants.js +5 -5
- package/lib/esm/components/constants.js.map +1 -1
- package/lib/esm/components/custom-message.d.ts +1 -1
- package/lib/esm/components/custom-message.js +84 -35
- package/lib/esm/components/custom-message.js.map +1 -1
- package/lib/esm/components/document.d.ts +1 -1
- package/lib/esm/components/document.js +58 -26
- package/lib/esm/components/document.js.map +1 -1
- package/lib/esm/components/element.js +41 -29
- package/lib/esm/components/element.js.map +1 -1
- package/lib/esm/components/handoff.js +51 -29
- package/lib/esm/components/handoff.js.map +1 -1
- package/lib/esm/components/image.d.ts +1 -1
- package/lib/esm/components/image.js +71 -30
- package/lib/esm/components/image.js.map +1 -1
- package/lib/esm/components/index-types.d.ts +1 -1
- package/lib/esm/components/index-types.js +3 -2
- package/lib/esm/components/index-types.js.map +1 -1
- package/lib/esm/components/index.d.ts +33 -33
- package/lib/esm/components/index.js +98 -70
- package/lib/esm/components/index.js.map +1 -1
- package/lib/esm/components/location.js +57 -20
- package/lib/esm/components/location.js.map +1 -1
- package/lib/esm/components/markdown.js +53 -60
- package/lib/esm/components/markdown.js.map +1 -1
- package/lib/esm/components/message/index.js +205 -102
- package/lib/esm/components/message/index.js.map +1 -1
- package/lib/esm/components/message/message-footer.d.ts +1 -1
- package/lib/esm/components/message/message-footer.js +36 -18
- package/lib/esm/components/message/message-footer.js.map +1 -1
- package/lib/esm/components/message/message-image.d.ts +1 -1
- package/lib/esm/components/message/message-image.js +44 -24
- package/lib/esm/components/message/message-image.js.map +1 -1
- package/lib/esm/components/message/styles.js +34 -34
- package/lib/esm/components/message/styles.js.map +1 -1
- package/lib/esm/components/message/timestamps.d.ts +1 -1
- package/lib/esm/components/message/timestamps.js +54 -32
- package/lib/esm/components/message/timestamps.js.map +1 -1
- package/lib/esm/components/message-template.js +24 -11
- package/lib/esm/components/message-template.js.map +1 -1
- package/lib/esm/components/multichannel/facebook/facebook.js +33 -20
- package/lib/esm/components/multichannel/facebook/facebook.js.map +1 -1
- package/lib/esm/components/multichannel/index-types.js +4 -2
- package/lib/esm/components/multichannel/index-types.js.map +1 -1
- package/lib/esm/components/multichannel/index.d.ts +6 -6
- package/lib/esm/components/multichannel/index.js +24 -15
- package/lib/esm/components/multichannel/index.js.map +1 -1
- package/lib/esm/components/multichannel/multichannel-button.js +63 -42
- package/lib/esm/components/multichannel/multichannel-button.js.map +1 -1
- package/lib/esm/components/multichannel/multichannel-carousel.js +84 -41
- package/lib/esm/components/multichannel/multichannel-carousel.js.map +1 -1
- package/lib/esm/components/multichannel/multichannel-context.js +10 -8
- package/lib/esm/components/multichannel/multichannel-context.js.map +1 -1
- package/lib/esm/components/multichannel/multichannel-reply.js +34 -20
- package/lib/esm/components/multichannel/multichannel-reply.js.map +1 -1
- package/lib/esm/components/multichannel/multichannel-text.js +196 -94
- package/lib/esm/components/multichannel/multichannel-text.js.map +1 -1
- package/lib/esm/components/multichannel/multichannel-utils.js +22 -35
- package/lib/esm/components/multichannel/multichannel-utils.js.map +1 -1
- package/lib/esm/components/multichannel/multichannel.js +91 -43
- package/lib/esm/components/multichannel/multichannel.js.map +1 -1
- package/lib/esm/components/multichannel/whatsapp/constants.js +15 -13
- package/lib/esm/components/multichannel/whatsapp/constants.js.map +1 -1
- package/lib/esm/components/multichannel/whatsapp/markdown-meta.js +3 -3
- package/lib/esm/components/multichannel/whatsapp/markdown-meta.js.map +1 -1
- package/lib/esm/components/pic.js +46 -23
- package/lib/esm/components/pic.js.map +1 -1
- package/lib/esm/components/raw.js +65 -24
- package/lib/esm/components/raw.js.map +1 -1
- package/lib/esm/components/reply.d.ts +1 -1
- package/lib/esm/components/reply.js +68 -32
- package/lib/esm/components/reply.js.map +1 -1
- package/lib/esm/components/share-button.js +24 -11
- package/lib/esm/components/share-button.js.map +1 -1
- package/lib/esm/components/subtitle.js +37 -19
- package/lib/esm/components/subtitle.js.map +1 -1
- package/lib/esm/components/system-debug-trace/debug-message.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/debug-message.js +104 -54
- package/lib/esm/components/system-debug-trace/debug-message.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/ai-agent/ai-agent.d.ts +2 -2
- package/lib/esm/components/system-debug-trace/events/ai-agent/ai-agent.js +121 -34
- package/lib/esm/components/system-debug-trace/events/ai-agent/ai-agent.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/ai-agent/executed-tools.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/events/ai-agent/executed-tools.js +38 -13
- package/lib/esm/components/system-debug-trace/events/ai-agent/executed-tools.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/ai-agent/index.d.ts +2 -2
- package/lib/esm/components/system-debug-trace/events/ai-agent/index.js +6 -5
- package/lib/esm/components/system-debug-trace/events/ai-agent/index.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/ai-agent/parse-tools.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/events/ai-agent/parse-tools.js +10 -12
- package/lib/esm/components/system-debug-trace/events/ai-agent/parse-tools.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/ai-agent/rehydrate-ai-agent-event.d.ts +2 -2
- package/lib/esm/components/system-debug-trace/events/ai-agent/rehydrate-ai-agent-event.js +11 -17
- package/lib/esm/components/system-debug-trace/events/ai-agent/rehydrate-ai-agent-event.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/ai-agent/types.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/events/ai-agent/types.js +3 -2
- package/lib/esm/components/system-debug-trace/events/ai-agent/types.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/ai-agent/use-rehydrated-ai-agent-event.d.ts +2 -2
- package/lib/esm/components/system-debug-trace/events/ai-agent/use-rehydrated-ai-agent-event.js +23 -23
- package/lib/esm/components/system-debug-trace/events/ai-agent/use-rehydrated-ai-agent-event.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/ai-agent-router/ai-agent-router.d.ts +2 -2
- package/lib/esm/components/system-debug-trace/events/ai-agent-router/ai-agent-router.js +88 -18
- package/lib/esm/components/system-debug-trace/events/ai-agent-router/ai-agent-router.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/ai-agent-router/index.d.ts +2 -2
- package/lib/esm/components/system-debug-trace/events/ai-agent-router/index.js +6 -5
- package/lib/esm/components/system-debug-trace/events/ai-agent-router/index.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/ai-agent-router/types.d.ts +2 -2
- package/lib/esm/components/system-debug-trace/events/ai-agent-router/types.js +3 -2
- package/lib/esm/components/system-debug-trace/events/ai-agent-router/types.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/bot-action.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/events/bot-action.js +28 -12
- package/lib/esm/components/system-debug-trace/events/bot-action.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/components/guardrail-item.js +38 -11
- package/lib/esm/components/system-debug-trace/events/components/guardrail-item.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/components/index.d.ts +2 -2
- package/lib/esm/components/system-debug-trace/events/components/index.js +6 -5
- package/lib/esm/components/system-debug-trace/events/components/index.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/components/sources-section.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/events/components/sources-section.js +46 -17
- package/lib/esm/components/system-debug-trace/events/components/sources-section.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/conditional-channel.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/events/conditional-channel.js +28 -12
- package/lib/esm/components/system-debug-trace/events/conditional-channel.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/conditional-country.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/events/conditional-country.js +28 -12
- package/lib/esm/components/system-debug-trace/events/conditional-country.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/conditional-custom.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/events/conditional-custom.js +59 -17
- package/lib/esm/components/system-debug-trace/events/conditional-custom.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/conditional-queue-status.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/events/conditional-queue-status.js +72 -20
- package/lib/esm/components/system-debug-trace/events/conditional-queue-status.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/constants.js +5 -5
- package/lib/esm/components/system-debug-trace/events/constants.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/fallback.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/events/fallback.js +29 -12
- package/lib/esm/components/system-debug-trace/events/fallback.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/handoff-success.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/events/handoff-success.js +84 -27
- package/lib/esm/components/system-debug-trace/events/handoff-success.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/index.d.ts +14 -14
- package/lib/esm/components/system-debug-trace/events/index.js +30 -17
- package/lib/esm/components/system-debug-trace/events/index.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/keyword.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/events/keyword.js +29 -12
- package/lib/esm/components/system-debug-trace/events/keyword.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/knowledge-bases-types.js +3 -2
- package/lib/esm/components/system-debug-trace/events/knowledge-bases-types.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/redirect-flow.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/events/redirect-flow.js +28 -12
- package/lib/esm/components/system-debug-trace/events/redirect-flow.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/smart-intent.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/events/smart-intent.js +28 -11
- package/lib/esm/components/system-debug-trace/events/smart-intent.js.map +1 -1
- package/lib/esm/components/system-debug-trace/events/webview-action-triggered.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/events/webview-action-triggered.js +45 -19
- package/lib/esm/components/system-debug-trace/events/webview-action-triggered.js.map +1 -1
- package/lib/esm/components/system-debug-trace/hooks/use-knowledge-base-info.d.ts +2 -2
- package/lib/esm/components/system-debug-trace/hooks/use-knowledge-base-info.js +45 -38
- package/lib/esm/components/system-debug-trace/hooks/use-knowledge-base-info.js.map +1 -1
- package/lib/esm/components/system-debug-trace/hooks/use-last-label-position.js +22 -19
- package/lib/esm/components/system-debug-trace/hooks/use-last-label-position.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/ai-router.js +69 -12
- package/lib/esm/components/system-debug-trace/icons/ai-router.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/ai-specialist.js +83 -13
- package/lib/esm/components/system-debug-trace/icons/ai-specialist.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/arrow-progress.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/icons/arrow-progress.js +21 -10
- package/lib/esm/components/system-debug-trace/icons/arrow-progress.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/brain.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/icons/brain.js +21 -10
- package/lib/esm/components/system-debug-trace/icons/brain.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/caret-down.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/icons/caret-down.js +21 -10
- package/lib/esm/components/system-debug-trace/icons/caret-down.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/caret-up.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/icons/caret-up.js +21 -10
- package/lib/esm/components/system-debug-trace/icons/caret-up.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/circle-check.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/icons/circle-check.js +20 -9
- package/lib/esm/components/system-debug-trace/icons/circle-check.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/code.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/icons/code.js +20 -9
- package/lib/esm/components/system-debug-trace/icons/code.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/file-pdf.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/icons/file-pdf.js +21 -10
- package/lib/esm/components/system-debug-trace/icons/file-pdf.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/file-word.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/icons/file-word.js +21 -10
- package/lib/esm/components/system-debug-trace/icons/file-word.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/hand.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/icons/hand.js +21 -10
- package/lib/esm/components/system-debug-trace/icons/hand.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/head-set.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/icons/head-set.js +21 -10
- package/lib/esm/components/system-debug-trace/icons/head-set.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/index.d.ts +16 -16
- package/lib/esm/components/system-debug-trace/icons/index.js +34 -19
- package/lib/esm/components/system-debug-trace/icons/index.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/life-ring.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/icons/life-ring.js +21 -10
- package/lib/esm/components/system-debug-trace/icons/life-ring.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/link.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/icons/link.js +21 -10
- package/lib/esm/components/system-debug-trace/icons/link.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/quote-right.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/icons/quote-right.js +21 -10
- package/lib/esm/components/system-debug-trace/icons/quote-right.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/screwdriver-wrench.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/icons/screwdriver-wrench.js +21 -10
- package/lib/esm/components/system-debug-trace/icons/screwdriver-wrench.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/split.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/icons/split.js +21 -10
- package/lib/esm/components/system-debug-trace/icons/split.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/wand.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/icons/wand.js +21 -10
- package/lib/esm/components/system-debug-trace/icons/wand.js.map +1 -1
- package/lib/esm/components/system-debug-trace/icons/window-restore.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/icons/window-restore.js +21 -10
- package/lib/esm/components/system-debug-trace/icons/window-restore.js.map +1 -1
- package/lib/esm/components/system-debug-trace/index.js +35 -15
- package/lib/esm/components/system-debug-trace/index.js.map +1 -1
- package/lib/esm/components/system-debug-trace/styles.js +49 -45
- package/lib/esm/components/system-debug-trace/styles.js.map +1 -1
- package/lib/esm/components/system-debug-trace/types.d.ts +1 -1
- package/lib/esm/components/system-debug-trace/types.js +3 -2
- package/lib/esm/components/system-debug-trace/types.js.map +1 -1
- package/lib/esm/components/text.d.ts +1 -1
- package/lib/esm/components/text.js +57 -31
- package/lib/esm/components/text.js.map +1 -1
- package/lib/esm/components/title.js +33 -17
- package/lib/esm/components/title.js.map +1 -1
- package/lib/esm/components/video.d.ts +1 -1
- package/lib/esm/components/video.js +48 -21
- package/lib/esm/components/video.js.map +1 -1
- package/lib/esm/components/webchat-settings.d.ts +2 -2
- package/lib/esm/components/webchat-settings.js +43 -24
- package/lib/esm/components/webchat-settings.js.map +1 -1
- package/lib/esm/components/whatsapp-button-list.js +65 -38
- package/lib/esm/components/whatsapp-button-list.js.map +1 -1
- package/lib/esm/components/whatsapp-catalog.js +41 -18
- package/lib/esm/components/whatsapp-catalog.js.map +1 -1
- package/lib/esm/components/whatsapp-cta-url-button.js +58 -44
- package/lib/esm/components/whatsapp-cta-url-button.js.map +1 -1
- package/lib/esm/components/whatsapp-interactive-media-carousel.js +53 -19
- package/lib/esm/components/whatsapp-interactive-media-carousel.js.map +1 -1
- package/lib/esm/components/whatsapp-media-carousel.js +49 -24
- package/lib/esm/components/whatsapp-media-carousel.js.map +1 -1
- package/lib/esm/components/whatsapp-product-carousel.js +48 -22
- package/lib/esm/components/whatsapp-product-carousel.js.map +1 -1
- package/lib/esm/components/whatsapp-product-list.js +46 -19
- package/lib/esm/components/whatsapp-product-list.js.map +1 -1
- package/lib/esm/components/whatsapp-product.js +42 -18
- package/lib/esm/components/whatsapp-product.js.map +1 -1
- package/lib/esm/components/whatsapp-request-contact-info.js +40 -21
- package/lib/esm/components/whatsapp-request-contact-info.js.map +1 -1
- package/lib/esm/components/whatsapp-template/index.d.ts +1 -1
- package/lib/esm/components/whatsapp-template/index.js +45 -18
- package/lib/esm/components/whatsapp-template/index.js.map +1 -1
- package/lib/esm/components/whatsapp-template/types.js +12 -12
- package/lib/esm/components/whatsapp-template/types.js.map +1 -1
- package/lib/esm/constants.js +39 -24
- package/lib/esm/constants.js.map +1 -1
- package/lib/esm/contexts.d.ts +1 -1
- package/lib/esm/contexts.js +20 -17
- package/lib/esm/contexts.js.map +1 -1
- package/lib/esm/debug-system-messages.d.ts +1 -1
- package/lib/esm/debug-system-messages.js +80 -65
- package/lib/esm/debug-system-messages.js.map +1 -1
- package/lib/esm/dev-app.d.ts +4 -4
- package/lib/esm/dev-app.js +104 -67
- package/lib/esm/dev-app.js.map +1 -1
- package/lib/esm/index-types.d.ts +8 -8
- package/lib/esm/index-types.js +9 -9
- package/lib/esm/index-types.js.map +1 -1
- package/lib/esm/index.d.ts +12 -12
- package/lib/esm/index.js +33 -25
- package/lib/esm/index.js.map +1 -1
- package/lib/esm/message-utils.js +40 -55
- package/lib/esm/message-utils.js.map +1 -1
- package/lib/esm/msg-to-botonic.js +166 -76
- package/lib/esm/msg-to-botonic.js.map +1 -1
- package/lib/esm/node-app.d.ts +1 -1
- package/lib/esm/node-app.js +17 -15
- package/lib/esm/node-app.js.map +1 -1
- package/lib/esm/package.json +3 -0
- package/lib/esm/react-bot.d.ts +2 -2
- package/lib/esm/react-bot.js +39 -26
- package/lib/esm/react-bot.js.map +1 -1
- package/lib/esm/shared/styles.js +12 -10
- package/lib/esm/shared/styles.js.map +1 -1
- package/lib/esm/util/dom.js +13 -16
- package/lib/esm/util/dom.js.map +1 -1
- package/lib/esm/util/environment.js +15 -24
- package/lib/esm/util/environment.js.map +1 -1
- package/lib/esm/util/error-boundary.js +29 -18
- package/lib/esm/util/error-boundary.js.map +1 -1
- package/lib/esm/util/functional.js +7 -14
- package/lib/esm/util/functional.js.map +1 -1
- package/lib/esm/util/i18n.js +12 -21
- package/lib/esm/util/i18n.js.map +1 -1
- package/lib/esm/util/index.d.ts +10 -10
- package/lib/esm/util/index.js +22 -13
- package/lib/esm/util/index.js.map +1 -1
- package/lib/esm/util/logs.js +17 -9
- package/lib/esm/util/logs.js.map +1 -1
- package/lib/esm/util/objects.js +14 -19
- package/lib/esm/util/objects.js.map +1 -1
- package/lib/esm/util/react.js +33 -27
- package/lib/esm/util/react.js.map +1 -1
- package/lib/esm/util/regexs.js +8 -11
- package/lib/esm/util/regexs.js.map +1 -1
- package/lib/esm/util/strings.js +4 -5
- package/lib/esm/util/strings.js.map +1 -1
- package/lib/esm/util/webchat.d.ts +2 -2
- package/lib/esm/util/webchat.js +48 -47
- package/lib/esm/util/webchat.js.map +1 -1
- package/lib/esm/util/webviews.d.ts +1 -1
- package/lib/esm/util/webviews.js +3 -3
- package/lib/esm/util/webviews.js.map +1 -1
- package/lib/esm/webchat/chat-area/index.js +42 -18
- package/lib/esm/webchat/chat-area/index.js.map +1 -1
- package/lib/esm/webchat/chat-area/styles.js +9 -7
- package/lib/esm/webchat/chat-area/styles.js.map +1 -1
- package/lib/esm/webchat/components/common.js +17 -10
- package/lib/esm/webchat/components/common.js.map +1 -1
- package/lib/esm/webchat/components/conditional-animation.js +32 -14
- package/lib/esm/webchat/components/conditional-animation.js.map +1 -1
- package/lib/esm/webchat/components/opened-persistent-menu.js +61 -26
- package/lib/esm/webchat/components/opened-persistent-menu.js.map +1 -1
- package/lib/esm/webchat/constants.js +5 -5
- package/lib/esm/webchat/constants.js.map +1 -1
- package/lib/esm/webchat/context/actions.js +6 -7
- package/lib/esm/webchat/context/actions.js.map +1 -1
- package/lib/esm/webchat/context/index.d.ts +3 -3
- package/lib/esm/webchat/context/index.js +59 -43
- package/lib/esm/webchat/context/index.js.map +1 -1
- package/lib/esm/webchat/context/messages-reducer.d.ts +2 -2
- package/lib/esm/webchat/context/messages-reducer.js +78 -66
- package/lib/esm/webchat/context/messages-reducer.js.map +1 -1
- package/lib/esm/webchat/context/types.d.ts +4 -4
- package/lib/esm/webchat/context/types.js +3 -2
- package/lib/esm/webchat/context/types.js.map +1 -1
- package/lib/esm/webchat/context/use-webchat.d.ts +5 -5
- package/lib/esm/webchat/context/use-webchat.js +144 -102
- package/lib/esm/webchat/context/use-webchat.js.map +1 -1
- package/lib/esm/webchat/context/webchat-reducer.d.ts +2 -2
- package/lib/esm/webchat/context/webchat-reducer.js +110 -51
- package/lib/esm/webchat/context/webchat-reducer.js.map +1 -1
- package/lib/esm/webchat/cover-component/index.js +24 -13
- package/lib/esm/webchat/cover-component/index.js.map +1 -1
- package/lib/esm/webchat/custom-messages/index.d.ts +1 -1
- package/lib/esm/webchat/custom-messages/index.js +5 -6
- package/lib/esm/webchat/custom-messages/index.js.map +1 -1
- package/lib/esm/webchat/custom-messages/rating/icons/face-angry.d.ts +1 -1
- package/lib/esm/webchat/custom-messages/rating/icons/face-angry.js +25 -7
- package/lib/esm/webchat/custom-messages/rating/icons/face-angry.js.map +1 -1
- package/lib/esm/webchat/custom-messages/rating/icons/face-frown.d.ts +1 -1
- package/lib/esm/webchat/custom-messages/rating/icons/face-frown.js +25 -7
- package/lib/esm/webchat/custom-messages/rating/icons/face-frown.js.map +1 -1
- package/lib/esm/webchat/custom-messages/rating/icons/face-grin-beam.d.ts +1 -1
- package/lib/esm/webchat/custom-messages/rating/icons/face-grin-beam.js +25 -7
- package/lib/esm/webchat/custom-messages/rating/icons/face-grin-beam.js.map +1 -1
- package/lib/esm/webchat/custom-messages/rating/icons/face-meh.d.ts +1 -1
- package/lib/esm/webchat/custom-messages/rating/icons/face-meh.js +25 -7
- package/lib/esm/webchat/custom-messages/rating/icons/face-meh.js.map +1 -1
- package/lib/esm/webchat/custom-messages/rating/icons/face-smile.d.ts +1 -1
- package/lib/esm/webchat/custom-messages/rating/icons/face-smile.js +25 -7
- package/lib/esm/webchat/custom-messages/rating/icons/face-smile.js.map +1 -1
- package/lib/esm/webchat/custom-messages/rating/icons/index.d.ts +6 -6
- package/lib/esm/webchat/custom-messages/rating/icons/index.js +14 -9
- package/lib/esm/webchat/custom-messages/rating/icons/index.js.map +1 -1
- package/lib/esm/webchat/custom-messages/rating/icons/star.d.ts +1 -1
- package/lib/esm/webchat/custom-messages/rating/icons/star.js +25 -7
- package/lib/esm/webchat/custom-messages/rating/icons/star.js.map +1 -1
- package/lib/esm/webchat/custom-messages/rating/index.d.ts +1 -1
- package/lib/esm/webchat/custom-messages/rating/index.js +77 -28
- package/lib/esm/webchat/custom-messages/rating/index.js.map +1 -1
- package/lib/esm/webchat/custom-messages/rating/rating-selector.d.ts +1 -1
- package/lib/esm/webchat/custom-messages/rating/rating-selector.js +49 -18
- package/lib/esm/webchat/custom-messages/rating/rating-selector.js.map +1 -1
- package/lib/esm/webchat/custom-messages/rating/smileys.d.ts +1 -1
- package/lib/esm/webchat/custom-messages/rating/smileys.js +20 -13
- package/lib/esm/webchat/custom-messages/rating/smileys.js.map +1 -1
- package/lib/esm/webchat/custom-messages/rating/stars.d.ts +1 -1
- package/lib/esm/webchat/custom-messages/rating/stars.js +15 -8
- package/lib/esm/webchat/custom-messages/rating/stars.js.map +1 -1
- package/lib/esm/webchat/custom-messages/rating/styles.js +10 -8
- package/lib/esm/webchat/custom-messages/rating/styles.js.map +1 -1
- package/lib/esm/webchat/custom-messages/rating/types.js +6 -6
- package/lib/esm/webchat/custom-messages/rating/types.js.map +1 -1
- package/lib/esm/webchat/devices/index.js +10 -13
- package/lib/esm/webchat/devices/index.js.map +1 -1
- package/lib/esm/webchat/global.d.ts +3 -0
- package/lib/esm/webchat/header/default-header.js +71 -21
- package/lib/esm/webchat/header/default-header.js.map +1 -1
- package/lib/esm/webchat/header/index.js +42 -17
- package/lib/esm/webchat/header/index.js.map +1 -1
- package/lib/esm/webchat/header/styles.js +26 -22
- package/lib/esm/webchat/header/styles.js.map +1 -1
- package/lib/esm/webchat/hooks/index.d.ts +10 -10
- package/lib/esm/webchat/hooks/index.js +32 -23
- package/lib/esm/webchat/hooks/index.js.map +1 -1
- package/lib/esm/webchat/hooks/use-component-visible.js +17 -10
- package/lib/esm/webchat/hooks/use-component-visible.js.map +1 -1
- package/lib/esm/webchat/hooks/use-component-will-mount.js +9 -7
- package/lib/esm/webchat/hooks/use-component-will-mount.js.map +1 -1
- package/lib/esm/webchat/hooks/use-device-adapter.js +43 -24
- package/lib/esm/webchat/hooks/use-device-adapter.js.map +1 -1
- package/lib/esm/webchat/hooks/use-previous.js +9 -6
- package/lib/esm/webchat/hooks/use-previous.js.map +1 -1
- package/lib/esm/webchat/hooks/use-scroll-to-bottom.js +16 -12
- package/lib/esm/webchat/hooks/use-scroll-to-bottom.js.map +1 -1
- package/lib/esm/webchat/hooks/use-scrollbar-controller.js +48 -43
- package/lib/esm/webchat/hooks/use-scrollbar-controller.js.map +1 -1
- package/lib/esm/webchat/hooks/use-typing.d.ts +2 -2
- package/lib/esm/webchat/hooks/use-typing.js +24 -18
- package/lib/esm/webchat/hooks/use-typing.js.map +1 -1
- package/lib/esm/webchat/hooks/use-virtual-keyboard-detection.js +18 -12
- package/lib/esm/webchat/hooks/use-virtual-keyboard-detection.js.map +1 -1
- package/lib/esm/webchat/hooks/use-webchat-dimensions.js +24 -21
- package/lib/esm/webchat/hooks/use-webchat-dimensions.js.map +1 -1
- package/lib/esm/webchat/hooks/use-webchat-resizer.js +21 -21
- package/lib/esm/webchat/hooks/use-webchat-resizer.js.map +1 -1
- package/lib/esm/webchat/index-types.d.ts +1 -1
- package/lib/esm/webchat/index-types.js +3 -2
- package/lib/esm/webchat/index-types.js.map +1 -1
- package/lib/esm/webchat/index.d.ts +5 -5
- package/lib/esm/webchat/index.js +16 -13
- package/lib/esm/webchat/index.js.map +1 -1
- package/lib/esm/webchat/input-panel/attachment.js +60 -19
- package/lib/esm/webchat/input-panel/attachment.js.map +1 -1
- package/lib/esm/webchat/input-panel/emoji-picker.js +41 -20
- package/lib/esm/webchat/input-panel/emoji-picker.js.map +1 -1
- package/lib/esm/webchat/input-panel/index.js +87 -29
- package/lib/esm/webchat/input-panel/index.js.map +1 -1
- package/lib/esm/webchat/input-panel/opened-emoji-picker.js +37 -13
- package/lib/esm/webchat/input-panel/opened-emoji-picker.js.map +1 -1
- package/lib/esm/webchat/input-panel/persistent-menu.js +38 -17
- package/lib/esm/webchat/input-panel/persistent-menu.js.map +1 -1
- package/lib/esm/webchat/input-panel/send-button.js +40 -19
- package/lib/esm/webchat/input-panel/send-button.js.map +1 -1
- package/lib/esm/webchat/input-panel/styles.js +14 -10
- package/lib/esm/webchat/input-panel/styles.js.map +1 -1
- package/lib/esm/webchat/input-panel/textarea.d.ts +2 -2
- package/lib/esm/webchat/input-panel/textarea.js +56 -26
- package/lib/esm/webchat/input-panel/textarea.js.map +1 -1
- package/lib/esm/webchat/input-panel/typing-network-sender.d.ts +1 -1
- package/lib/esm/webchat/input-panel/typing-network-sender.js +57 -38
- package/lib/esm/webchat/input-panel/typing-network-sender.js.map +1 -1
- package/lib/esm/webchat/input-panel/use-typing-chat-event-sender.d.ts +1 -1
- package/lib/esm/webchat/input-panel/use-typing-chat-event-sender.js +32 -21
- package/lib/esm/webchat/input-panel/use-typing-chat-event-sender.js.map +1 -1
- package/lib/esm/webchat/input-panel/use-typing-session.d.ts +1 -1
- package/lib/esm/webchat/input-panel/use-typing-session.js +44 -33
- package/lib/esm/webchat/input-panel/use-typing-session.js.map +1 -1
- package/lib/esm/webchat/message-list/index.js +118 -58
- package/lib/esm/webchat/message-list/index.js.map +1 -1
- package/lib/esm/webchat/message-list/intro-message.js +47 -22
- package/lib/esm/webchat/message-list/intro-message.js.map +1 -1
- package/lib/esm/webchat/message-list/scroll-button.js +35 -16
- package/lib/esm/webchat/message-list/scroll-button.js.map +1 -1
- package/lib/esm/webchat/message-list/styles.js +13 -11
- package/lib/esm/webchat/message-list/styles.js.map +1 -1
- package/lib/esm/webchat/message-list/unread-messages-banner.js +43 -16
- package/lib/esm/webchat/message-list/unread-messages-banner.js.map +1 -1
- package/lib/esm/webchat/message-list/use-debounce.js +11 -8
- package/lib/esm/webchat/message-list/use-debounce.js.map +1 -1
- package/lib/esm/webchat/message-list/use-notifications.js +21 -14
- package/lib/esm/webchat/message-list/use-notifications.js.map +1 -1
- package/lib/esm/webchat/replies/index.js +41 -21
- package/lib/esm/webchat/replies/index.js.map +1 -1
- package/lib/esm/webchat/replies/styles.js +12 -10
- package/lib/esm/webchat/replies/styles.js.map +1 -1
- package/lib/esm/webchat/session-view.js +106 -41
- package/lib/esm/webchat/session-view.js.map +1 -1
- package/lib/esm/webchat/styles.js +33 -29
- package/lib/esm/webchat/styles.js.map +1 -1
- package/lib/esm/webchat/theme/default-theme.d.ts +1 -1
- package/lib/esm/webchat/theme/default-theme.js +52 -37
- package/lib/esm/webchat/theme/default-theme.js.map +1 -1
- package/lib/esm/webchat/theme/theme.d.ts +8 -0
- package/lib/esm/webchat/theme/types.d.ts +1 -1
- package/lib/esm/webchat/theme/types.js +3 -2
- package/lib/esm/webchat/theme/types.js.map +1 -1
- package/lib/esm/webchat/tracking.js +23 -15
- package/lib/esm/webchat/tracking.js.map +1 -1
- package/lib/esm/webchat/trigger-button/index.js +48 -23
- package/lib/esm/webchat/trigger-button/index.js.map +1 -1
- package/lib/esm/webchat/trigger-button/styles.js +15 -11
- package/lib/esm/webchat/trigger-button/styles.js.map +1 -1
- package/lib/esm/webchat/typing-indicator/index.js +30 -8
- package/lib/esm/webchat/typing-indicator/index.js.map +1 -1
- package/lib/esm/webchat/typing-indicator/styles.js +13 -11
- package/lib/esm/webchat/typing-indicator/styles.js.map +1 -1
- package/lib/esm/webchat/use-storage-state-hook.js +31 -18
- package/lib/esm/webchat/use-storage-state-hook.js.map +1 -1
- package/lib/esm/webchat/utils.js +9 -7
- package/lib/esm/webchat/utils.js.map +1 -1
- package/lib/esm/webchat/webchat-dev.js +74 -32
- package/lib/esm/webchat/webchat-dev.js.map +1 -1
- package/lib/esm/webchat/webchat.d.ts +1 -1
- package/lib/esm/webchat/webchat.js +455 -286
- package/lib/esm/webchat/webchat.js.map +1 -1
- package/lib/esm/webchat/webview/header.js +35 -16
- package/lib/esm/webchat/webview/header.js.map +1 -1
- package/lib/esm/webchat/webview/index.d.ts +1 -1
- package/lib/esm/webchat/webview/index.js +76 -42
- package/lib/esm/webchat/webview/index.js.map +1 -1
- package/lib/esm/webchat/webview/styles.js +35 -31
- package/lib/esm/webchat/webview/styles.js.map +1 -1
- package/lib/esm/webchat-app.d.ts +5 -5
- package/lib/esm/webchat-app.js +197 -134
- package/lib/esm/webchat-app.js.map +1 -1
- package/lib/esm/webview-app.js +103 -80
- package/lib/esm/webview-app.js.map +1 -1
- package/package.json +8 -10
- package/src/components/index.ts +14 -14
- package/src/dev-app.jsx +1 -1
- package/src/index-types.ts +6 -6
- package/src/webchat/context/index.tsx +1 -1
- package/src/webchat/index.ts +1 -1
- package/lib/cjs/app.d.ts +0 -2
- package/lib/cjs/app.js +0 -10
- package/lib/cjs/app.js.map +0 -1
- package/lib/cjs/assets/arrow-down.svg +0 -3
- package/lib/cjs/assets/arrow-scroll-down.svg +0 -3
- package/lib/cjs/assets/attachment-icon.svg +0 -7
- package/lib/cjs/assets/audio.svg +0 -4
- package/lib/cjs/assets/botonic_react_logo100x100.png +0 -0
- package/lib/cjs/assets/document.svg +0 -3
- package/lib/cjs/assets/emojiButton.svg +0 -6
- package/lib/cjs/assets/image.svg +0 -4
- package/lib/cjs/assets/leftArrow.svg +0 -3
- package/lib/cjs/assets/menuButton.svg +0 -3
- package/lib/cjs/assets/rightArrow.svg +0 -3
- package/lib/cjs/assets/send-button.svg +0 -1
- package/lib/cjs/assets/thumbs-down.svg +0 -3
- package/lib/cjs/assets/thumbs-up.svg +0 -3
- package/lib/cjs/assets/url-icon.png +0 -0
- package/lib/cjs/assets/video.svg +0 -3
- package/lib/cjs/botonic-tester.d.ts +0 -30
- package/lib/cjs/botonic-tester.js +0 -76
- package/lib/cjs/botonic-tester.js.map +0 -1
- package/lib/cjs/components/audio.d.ts +0 -9
- package/lib/cjs/components/audio.js +0 -27
- package/lib/cjs/components/audio.js.map +0 -1
- package/lib/cjs/components/button/index.d.ts +0 -17
- package/lib/cjs/components/button/index.js +0 -139
- package/lib/cjs/components/button/index.js.map +0 -1
- package/lib/cjs/components/button/styles.d.ts +0 -2
- package/lib/cjs/components/button/styles.js +0 -40
- package/lib/cjs/components/button/styles.js.map +0 -1
- package/lib/cjs/components/buttons-disabler.d.ts +0 -21
- package/lib/cjs/components/buttons-disabler.js +0 -94
- package/lib/cjs/components/buttons-disabler.js.map +0 -1
- package/lib/cjs/components/carousel.d.ts +0 -10
- package/lib/cjs/components/carousel.js +0 -119
- package/lib/cjs/components/carousel.js.map +0 -1
- package/lib/cjs/components/components.d.ts +0 -12
- package/lib/cjs/components/components.js +0 -21
- package/lib/cjs/components/components.js.map +0 -1
- package/lib/cjs/components/constants.d.ts +0 -11
- package/lib/cjs/components/constants.js +0 -15
- package/lib/cjs/components/constants.js.map +0 -1
- package/lib/cjs/components/custom-message.d.ts +0 -16
- package/lib/cjs/components/custom-message.js +0 -60
- package/lib/cjs/components/custom-message.js.map +0 -1
- package/lib/cjs/components/document.d.ts +0 -9
- package/lib/cjs/components/document.js +0 -50
- package/lib/cjs/components/document.js.map +0 -1
- package/lib/cjs/components/element.d.ts +0 -8
- package/lib/cjs/components/element.js +0 -56
- package/lib/cjs/components/element.js.map +0 -1
- package/lib/cjs/components/handoff.d.ts +0 -1
- package/lib/cjs/components/handoff.js +0 -54
- package/lib/cjs/components/handoff.js.map +0 -1
- package/lib/cjs/components/image.d.ts +0 -9
- package/lib/cjs/components/image.js +0 -40
- package/lib/cjs/components/image.js.map +0 -1
- package/lib/cjs/components/index-types.d.ts +0 -83
- package/lib/cjs/components/index-types.js +0 -3
- package/lib/cjs/components/index-types.js.map +0 -1
- package/lib/cjs/components/index.d.ts +0 -33
- package/lib/cjs/components/index.js +0 -71
- package/lib/cjs/components/index.js.map +0 -1
- package/lib/cjs/components/location.d.ts +0 -11
- package/lib/cjs/components/location.js +0 -31
- package/lib/cjs/components/location.js.map +0 -1
- package/lib/cjs/components/markdown.d.ts +0 -7
- package/lib/cjs/components/markdown.js +0 -172
- package/lib/cjs/components/markdown.js.map +0 -1
- package/lib/cjs/components/message/index.d.ts +0 -1
- package/lib/cjs/components/message/index.js +0 -174
- package/lib/cjs/components/message/index.js.map +0 -1
- package/lib/cjs/components/message/message-footer.d.ts +0 -8
- package/lib/cjs/components/message/message-footer.js +0 -20
- package/lib/cjs/components/message/message-footer.js.map +0 -1
- package/lib/cjs/components/message/message-image.d.ts +0 -7
- package/lib/cjs/components/message/message-image.js +0 -26
- package/lib/cjs/components/message/message-image.js.map +0 -1
- package/lib/cjs/components/message/styles.d.ts +0 -35
- package/lib/cjs/components/message/styles.js +0 -123
- package/lib/cjs/components/message/styles.js.map +0 -1
- package/lib/cjs/components/message/timestamps.d.ts +0 -13
- package/lib/cjs/components/message/timestamps.js +0 -45
- package/lib/cjs/components/message/timestamps.js.map +0 -1
- package/lib/cjs/components/message-template.d.ts +0 -1
- package/lib/cjs/components/message-template.js +0 -13
- package/lib/cjs/components/message-template.js.map +0 -1
- package/lib/cjs/components/multichannel/facebook/facebook.d.ts +0 -17
- package/lib/cjs/components/multichannel/facebook/facebook.js +0 -48
- package/lib/cjs/components/multichannel/facebook/facebook.js.map +0 -1
- package/lib/cjs/components/multichannel/index-types.d.ts +0 -42
- package/lib/cjs/components/multichannel/index-types.js +0 -3
- package/lib/cjs/components/multichannel/index-types.js.map +0 -1
- package/lib/cjs/components/multichannel/index.d.ts +0 -11
- package/lib/cjs/components/multichannel/index.js +0 -16
- package/lib/cjs/components/multichannel/index.js.map +0 -1
- package/lib/cjs/components/multichannel/multichannel-button.d.ts +0 -4
- package/lib/cjs/components/multichannel/multichannel-button.js +0 -72
- package/lib/cjs/components/multichannel/multichannel-button.js.map +0 -1
- package/lib/cjs/components/multichannel/multichannel-carousel.d.ts +0 -1
- package/lib/cjs/components/multichannel/multichannel-carousel.js +0 -80
- package/lib/cjs/components/multichannel/multichannel-carousel.js.map +0 -1
- package/lib/cjs/components/multichannel/multichannel-context.d.ts +0 -8
- package/lib/cjs/components/multichannel/multichannel-context.js +0 -13
- package/lib/cjs/components/multichannel/multichannel-context.js.map +0 -1
- package/lib/cjs/components/multichannel/multichannel-reply.d.ts +0 -4
- package/lib/cjs/components/multichannel/multichannel-reply.js +0 -27
- package/lib/cjs/components/multichannel/multichannel-reply.js.map +0 -1
- package/lib/cjs/components/multichannel/multichannel-text.d.ts +0 -1
- package/lib/cjs/components/multichannel/multichannel-text.js +0 -184
- package/lib/cjs/components/multichannel/multichannel-text.js.map +0 -1
- package/lib/cjs/components/multichannel/multichannel-utils.d.ts +0 -36
- package/lib/cjs/components/multichannel/multichannel-utils.js +0 -89
- package/lib/cjs/components/multichannel/multichannel-utils.js.map +0 -1
- package/lib/cjs/components/multichannel/multichannel.d.ts +0 -1
- package/lib/cjs/components/multichannel/multichannel.js +0 -63
- package/lib/cjs/components/multichannel/multichannel.js.map +0 -1
- package/lib/cjs/components/multichannel/whatsapp/constants.d.ts +0 -12
- package/lib/cjs/components/multichannel/whatsapp/constants.js +0 -14
- package/lib/cjs/components/multichannel/whatsapp/constants.js.map +0 -1
- package/lib/cjs/components/multichannel/whatsapp/markdown-meta.d.ts +0 -1
- package/lib/cjs/components/multichannel/whatsapp/markdown-meta.js +0 -41
- package/lib/cjs/components/multichannel/whatsapp/markdown-meta.js.map +0 -1
- package/lib/cjs/components/pic.d.ts +0 -10
- package/lib/cjs/components/pic.js +0 -32
- package/lib/cjs/components/pic.js.map +0 -1
- package/lib/cjs/components/raw.d.ts +0 -9
- package/lib/cjs/components/raw.js +0 -45
- package/lib/cjs/components/raw.js.map +0 -1
- package/lib/cjs/components/reply.d.ts +0 -11
- package/lib/cjs/components/reply.js +0 -66
- package/lib/cjs/components/reply.js.map +0 -1
- package/lib/cjs/components/share-button.d.ts +0 -1
- package/lib/cjs/components/share-button.js +0 -13
- package/lib/cjs/components/share-button.js.map +0 -1
- package/lib/cjs/components/subtitle.d.ts +0 -11
- package/lib/cjs/components/subtitle.js +0 -25
- package/lib/cjs/components/subtitle.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/debug-message.d.ts +0 -7
- package/lib/cjs/components/system-debug-trace/debug-message.js +0 -82
- package/lib/cjs/components/system-debug-trace/debug-message.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/ai-agent/ai-agent.d.ts +0 -4
- package/lib/cjs/components/system-debug-trace/events/ai-agent/ai-agent.js +0 -53
- package/lib/cjs/components/system-debug-trace/events/ai-agent/ai-agent.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/ai-agent/executed-tools.d.ts +0 -7
- package/lib/cjs/components/system-debug-trace/events/ai-agent/executed-tools.js +0 -21
- package/lib/cjs/components/system-debug-trace/events/ai-agent/executed-tools.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/ai-agent/index.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/events/ai-agent/index.js +0 -6
- package/lib/cjs/components/system-debug-trace/events/ai-agent/index.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/ai-agent/parse-tools.d.ts +0 -9
- package/lib/cjs/components/system-debug-trace/events/ai-agent/parse-tools.js +0 -32
- package/lib/cjs/components/system-debug-trace/events/ai-agent/parse-tools.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/ai-agent/rehydrate-ai-agent-event.d.ts +0 -6
- package/lib/cjs/components/system-debug-trace/events/ai-agent/rehydrate-ai-agent-event.js +0 -55
- package/lib/cjs/components/system-debug-trace/events/ai-agent/rehydrate-ai-agent-event.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/ai-agent/types.d.ts +0 -23
- package/lib/cjs/components/system-debug-trace/events/ai-agent/types.js +0 -3
- package/lib/cjs/components/system-debug-trace/events/ai-agent/types.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/ai-agent/use-rehydrated-ai-agent-event.d.ts +0 -8
- package/lib/cjs/components/system-debug-trace/events/ai-agent/use-rehydrated-ai-agent-event.js +0 -41
- package/lib/cjs/components/system-debug-trace/events/ai-agent/use-rehydrated-ai-agent-event.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/ai-agent-router/ai-agent-router.d.ts +0 -4
- package/lib/cjs/components/system-debug-trace/events/ai-agent-router/ai-agent-router.js +0 -23
- package/lib/cjs/components/system-debug-trace/events/ai-agent-router/ai-agent-router.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/ai-agent-router/index.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/events/ai-agent-router/index.js +0 -6
- package/lib/cjs/components/system-debug-trace/events/ai-agent-router/index.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/ai-agent-router/types.d.ts +0 -23
- package/lib/cjs/components/system-debug-trace/events/ai-agent-router/types.js +0 -3
- package/lib/cjs/components/system-debug-trace/events/ai-agent-router/types.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/bot-action.d.ts +0 -7
- package/lib/cjs/components/system-debug-trace/events/bot-action.js +0 -18
- package/lib/cjs/components/system-debug-trace/events/bot-action.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/components/guardrail-item.d.ts +0 -14
- package/lib/cjs/components/system-debug-trace/events/components/guardrail-item.js +0 -12
- package/lib/cjs/components/system-debug-trace/events/components/guardrail-item.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/components/index.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/events/components/index.js +0 -6
- package/lib/cjs/components/system-debug-trace/events/components/index.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/components/sources-section.d.ts +0 -11
- package/lib/cjs/components/system-debug-trace/events/components/sources-section.js +0 -27
- package/lib/cjs/components/system-debug-trace/events/components/sources-section.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/conditional-channel.d.ts +0 -7
- package/lib/cjs/components/system-debug-trace/events/conditional-channel.js +0 -18
- package/lib/cjs/components/system-debug-trace/events/conditional-channel.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/conditional-country.d.ts +0 -7
- package/lib/cjs/components/system-debug-trace/events/conditional-country.js +0 -18
- package/lib/cjs/components/system-debug-trace/events/conditional-country.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/conditional-custom.d.ts +0 -10
- package/lib/cjs/components/system-debug-trace/events/conditional-custom.js +0 -24
- package/lib/cjs/components/system-debug-trace/events/conditional-custom.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/conditional-queue-status.d.ts +0 -11
- package/lib/cjs/components/system-debug-trace/events/conditional-queue-status.js +0 -26
- package/lib/cjs/components/system-debug-trace/events/conditional-queue-status.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/constants.d.ts +0 -33
- package/lib/cjs/components/system-debug-trace/events/constants.js +0 -37
- package/lib/cjs/components/system-debug-trace/events/constants.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/fallback.d.ts +0 -9
- package/lib/cjs/components/system-debug-trace/events/fallback.js +0 -19
- package/lib/cjs/components/system-debug-trace/events/fallback.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/handoff-success.d.ts +0 -11
- package/lib/cjs/components/system-debug-trace/events/handoff-success.js +0 -42
- package/lib/cjs/components/system-debug-trace/events/handoff-success.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/index.d.ts +0 -14
- package/lib/cjs/components/system-debug-trace/events/index.js +0 -18
- package/lib/cjs/components/system-debug-trace/events/index.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/keyword.d.ts +0 -10
- package/lib/cjs/components/system-debug-trace/events/keyword.js +0 -18
- package/lib/cjs/components/system-debug-trace/events/keyword.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/knowledge-bases-types.d.ts +0 -31
- package/lib/cjs/components/system-debug-trace/events/knowledge-bases-types.js +0 -3
- package/lib/cjs/components/system-debug-trace/events/knowledge-bases-types.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/redirect-flow.d.ts +0 -10
- package/lib/cjs/components/system-debug-trace/events/redirect-flow.js +0 -18
- package/lib/cjs/components/system-debug-trace/events/redirect-flow.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/smart-intent.d.ts +0 -7
- package/lib/cjs/components/system-debug-trace/events/smart-intent.js +0 -17
- package/lib/cjs/components/system-debug-trace/events/smart-intent.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/events/webview-action-triggered.d.ts +0 -10
- package/lib/cjs/components/system-debug-trace/events/webview-action-triggered.js +0 -25
- package/lib/cjs/components/system-debug-trace/events/webview-action-triggered.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/hooks/use-knowledge-base-info.d.ts +0 -16
- package/lib/cjs/components/system-debug-trace/hooks/use-knowledge-base-info.js +0 -111
- package/lib/cjs/components/system-debug-trace/hooks/use-knowledge-base-info.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/hooks/use-last-label-position.d.ts +0 -9
- package/lib/cjs/components/system-debug-trace/hooks/use-last-label-position.js +0 -81
- package/lib/cjs/components/system-debug-trace/hooks/use-last-label-position.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/ai-router.d.ts +0 -1
- package/lib/cjs/components/system-debug-trace/icons/ai-router.js +0 -14
- package/lib/cjs/components/system-debug-trace/icons/ai-router.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/ai-specialist.d.ts +0 -1
- package/lib/cjs/components/system-debug-trace/icons/ai-specialist.js +0 -15
- package/lib/cjs/components/system-debug-trace/icons/ai-specialist.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/arrow-progress.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/icons/arrow-progress.js +0 -12
- package/lib/cjs/components/system-debug-trace/icons/arrow-progress.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/brain.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/icons/brain.js +0 -12
- package/lib/cjs/components/system-debug-trace/icons/brain.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/caret-down.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/icons/caret-down.js +0 -12
- package/lib/cjs/components/system-debug-trace/icons/caret-down.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/caret-up.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/icons/caret-up.js +0 -12
- package/lib/cjs/components/system-debug-trace/icons/caret-up.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/circle-check.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/icons/circle-check.js +0 -11
- package/lib/cjs/components/system-debug-trace/icons/circle-check.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/code.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/icons/code.js +0 -11
- package/lib/cjs/components/system-debug-trace/icons/code.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/file-pdf.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/icons/file-pdf.js +0 -12
- package/lib/cjs/components/system-debug-trace/icons/file-pdf.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/file-word.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/icons/file-word.js +0 -12
- package/lib/cjs/components/system-debug-trace/icons/file-word.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/hand.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/icons/hand.js +0 -12
- package/lib/cjs/components/system-debug-trace/icons/hand.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/head-set.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/icons/head-set.js +0 -12
- package/lib/cjs/components/system-debug-trace/icons/head-set.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/index.d.ts +0 -16
- package/lib/cjs/components/system-debug-trace/icons/index.js +0 -20
- package/lib/cjs/components/system-debug-trace/icons/index.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/life-ring.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/icons/life-ring.js +0 -12
- package/lib/cjs/components/system-debug-trace/icons/life-ring.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/link.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/icons/link.js +0 -12
- package/lib/cjs/components/system-debug-trace/icons/link.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/quote-right.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/icons/quote-right.js +0 -12
- package/lib/cjs/components/system-debug-trace/icons/quote-right.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/screwdriver-wrench.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/icons/screwdriver-wrench.js +0 -12
- package/lib/cjs/components/system-debug-trace/icons/screwdriver-wrench.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/split.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/icons/split.js +0 -12
- package/lib/cjs/components/system-debug-trace/icons/split.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/wand.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/icons/wand.js +0 -12
- package/lib/cjs/components/system-debug-trace/icons/wand.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/icons/window-restore.d.ts +0 -2
- package/lib/cjs/components/system-debug-trace/icons/window-restore.js +0 -12
- package/lib/cjs/components/system-debug-trace/icons/window-restore.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/index.d.ts +0 -10
- package/lib/cjs/components/system-debug-trace/index.js +0 -28
- package/lib/cjs/components/system-debug-trace/index.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/styles.d.ts +0 -23
- package/lib/cjs/components/system-debug-trace/styles.js +0 -286
- package/lib/cjs/components/system-debug-trace/styles.js.map +0 -1
- package/lib/cjs/components/system-debug-trace/types.d.ts +0 -13
- package/lib/cjs/components/system-debug-trace/types.js +0 -3
- package/lib/cjs/components/system-debug-trace/types.js.map +0 -1
- package/lib/cjs/components/text.d.ts +0 -8
- package/lib/cjs/components/text.js +0 -52
- package/lib/cjs/components/text.js.map +0 -1
- package/lib/cjs/components/title.d.ts +0 -11
- package/lib/cjs/components/title.js +0 -23
- package/lib/cjs/components/title.js.map +0 -1
- package/lib/cjs/components/video.d.ts +0 -9
- package/lib/cjs/components/video.js +0 -31
- package/lib/cjs/components/video.js.map +0 -1
- package/lib/cjs/components/webchat-settings.d.ts +0 -19
- package/lib/cjs/components/webchat-settings.js +0 -79
- package/lib/cjs/components/webchat-settings.js.map +0 -1
- package/lib/cjs/components/whatsapp-button-list.d.ts +0 -20
- package/lib/cjs/components/whatsapp-button-list.js +0 -51
- package/lib/cjs/components/whatsapp-button-list.js.map +0 -1
- package/lib/cjs/components/whatsapp-catalog.d.ts +0 -6
- package/lib/cjs/components/whatsapp-catalog.js +0 -25
- package/lib/cjs/components/whatsapp-catalog.js.map +0 -1
- package/lib/cjs/components/whatsapp-cta-url-button.d.ts +0 -40
- package/lib/cjs/components/whatsapp-cta-url-button.js +0 -61
- package/lib/cjs/components/whatsapp-cta-url-button.js.map +0 -1
- package/lib/cjs/components/whatsapp-interactive-media-carousel.d.ts +0 -31
- package/lib/cjs/components/whatsapp-interactive-media-carousel.js +0 -25
- package/lib/cjs/components/whatsapp-interactive-media-carousel.js.map +0 -1
- package/lib/cjs/components/whatsapp-media-carousel.d.ts +0 -46
- package/lib/cjs/components/whatsapp-media-carousel.js +0 -42
- package/lib/cjs/components/whatsapp-media-carousel.js.map +0 -1
- package/lib/cjs/components/whatsapp-product-carousel.d.ts +0 -32
- package/lib/cjs/components/whatsapp-product-carousel.js +0 -34
- package/lib/cjs/components/whatsapp-product-carousel.js.map +0 -1
- package/lib/cjs/components/whatsapp-product-list.d.ts +0 -15
- package/lib/cjs/components/whatsapp-product-list.js +0 -26
- package/lib/cjs/components/whatsapp-product-list.js.map +0 -1
- package/lib/cjs/components/whatsapp-product.d.ts +0 -7
- package/lib/cjs/components/whatsapp-product.js +0 -25
- package/lib/cjs/components/whatsapp-product.js.map +0 -1
- package/lib/cjs/components/whatsapp-request-contact-info.d.ts +0 -4
- package/lib/cjs/components/whatsapp-request-contact-info.js +0 -30
- package/lib/cjs/components/whatsapp-request-contact-info.js.map +0 -1
- package/lib/cjs/components/whatsapp-template/index.d.ts +0 -11
- package/lib/cjs/components/whatsapp-template/index.js +0 -25
- package/lib/cjs/components/whatsapp-template/index.js.map +0 -1
- package/lib/cjs/components/whatsapp-template/types.d.ts +0 -114
- package/lib/cjs/components/whatsapp-template/types.js +0 -30
- package/lib/cjs/components/whatsapp-template/types.js.map +0 -1
- package/lib/cjs/constants.d.ts +0 -163
- package/lib/cjs/constants.js +0 -189
- package/lib/cjs/constants.js.map +0 -1
- package/lib/cjs/contexts.d.ts +0 -17
- package/lib/cjs/contexts.js +0 -30
- package/lib/cjs/contexts.js.map +0 -1
- package/lib/cjs/debug-system-messages.d.ts +0 -177
- package/lib/cjs/debug-system-messages.js +0 -219
- package/lib/cjs/debug-system-messages.js.map +0 -1
- package/lib/cjs/dev-app.d.ts +0 -213
- package/lib/cjs/dev-app.js +0 -98
- package/lib/cjs/dev-app.js.map +0 -1
- package/lib/cjs/index-types.d.ts +0 -187
- package/lib/cjs/index-types.js +0 -16
- package/lib/cjs/index-types.js.map +0 -1
- package/lib/cjs/index.d.ts +0 -12
- package/lib/cjs/index.js +0 -26
- package/lib/cjs/index.js.map +0 -1
- package/lib/cjs/message-utils.d.ts +0 -20
- package/lib/cjs/message-utils.js +0 -64
- package/lib/cjs/message-utils.js.map +0 -1
- package/lib/cjs/msg-to-botonic.d.ts +0 -17
- package/lib/cjs/msg-to-botonic.js +0 -142
- package/lib/cjs/msg-to-botonic.js.map +0 -1
- package/lib/cjs/node-app.d.ts +0 -7
- package/lib/cjs/node-app.js +0 -23
- package/lib/cjs/node-app.js.map +0 -1
- package/lib/cjs/react-bot.d.ts +0 -18
- package/lib/cjs/react-bot.js +0 -36
- package/lib/cjs/react-bot.js.map +0 -1
- package/lib/cjs/shared/styles.d.ts +0 -2
- package/lib/cjs/shared/styles.js +0 -32
- package/lib/cjs/shared/styles.js.map +0 -1
- package/lib/cjs/util/dom.d.ts +0 -4
- package/lib/cjs/util/dom.js +0 -31
- package/lib/cjs/util/dom.js.map +0 -1
- package/lib/cjs/util/environment.d.ts +0 -7
- package/lib/cjs/util/environment.js +0 -85
- package/lib/cjs/util/environment.js.map +0 -1
- package/lib/cjs/util/error-boundary.d.ts +0 -7
- package/lib/cjs/util/error-boundary.js +0 -32
- package/lib/cjs/util/error-boundary.js.map +0 -1
- package/lib/cjs/util/functional.d.ts +0 -3
- package/lib/cjs/util/functional.js +0 -29
- package/lib/cjs/util/functional.js.map +0 -1
- package/lib/cjs/util/i18n.d.ts +0 -26
- package/lib/cjs/util/i18n.js +0 -165
- package/lib/cjs/util/i18n.js.map +0 -1
- package/lib/cjs/util/index.d.ts +0 -10
- package/lib/cjs/util/index.js +0 -14
- package/lib/cjs/util/index.js.map +0 -1
- package/lib/cjs/util/logs.d.ts +0 -2
- package/lib/cjs/util/logs.js +0 -20
- package/lib/cjs/util/logs.js.map +0 -1
- package/lib/cjs/util/objects.d.ts +0 -3
- package/lib/cjs/util/objects.js +0 -45
- package/lib/cjs/util/objects.js.map +0 -1
- package/lib/cjs/util/react.d.ts +0 -12
- package/lib/cjs/util/react.js +0 -45
- package/lib/cjs/util/react.js.map +0 -1
- package/lib/cjs/util/regexs.d.ts +0 -2
- package/lib/cjs/util/regexs.js +0 -24
- package/lib/cjs/util/regexs.js.map +0 -1
- package/lib/cjs/util/strings.d.ts +0 -1
- package/lib/cjs/util/strings.js +0 -11
- package/lib/cjs/util/strings.js.map +0 -1
- package/lib/cjs/util/webchat.d.ts +0 -24
- package/lib/cjs/util/webchat.js +0 -100
- package/lib/cjs/util/webchat.js.map +0 -1
- package/lib/cjs/util/webviews.d.ts +0 -2
- package/lib/cjs/util/webviews.js +0 -8
- package/lib/cjs/util/webviews.js.map +0 -1
- package/lib/cjs/webchat/chat-area/index.d.ts +0 -1
- package/lib/cjs/webchat/chat-area/index.js +0 -22
- package/lib/cjs/webchat/chat-area/index.js.map +0 -1
- package/lib/cjs/webchat/chat-area/styles.d.ts +0 -3
- package/lib/cjs/webchat/chat-area/styles.js +0 -13
- package/lib/cjs/webchat/chat-area/styles.js.map +0 -1
- package/lib/cjs/webchat/components/common.d.ts +0 -1
- package/lib/cjs/webchat/components/common.js +0 -13
- package/lib/cjs/webchat/components/common.js.map +0 -1
- package/lib/cjs/webchat/components/conditional-animation.d.ts +0 -1
- package/lib/cjs/webchat/components/conditional-animation.js +0 -16
- package/lib/cjs/webchat/components/conditional-animation.js.map +0 -1
- package/lib/cjs/webchat/components/opened-persistent-menu.d.ts +0 -6
- package/lib/cjs/webchat/components/opened-persistent-menu.js +0 -37
- package/lib/cjs/webchat/components/opened-persistent-menu.js.map +0 -1
- package/lib/cjs/webchat/constants.d.ts +0 -8
- package/lib/cjs/webchat/constants.js +0 -13
- package/lib/cjs/webchat/constants.js.map +0 -1
- package/lib/cjs/webchat/context/actions.d.ts +0 -30
- package/lib/cjs/webchat/context/actions.js +0 -36
- package/lib/cjs/webchat/context/actions.js.map +0 -1
- package/lib/cjs/webchat/context/index.d.ts +0 -4
- package/lib/cjs/webchat/context/index.js +0 -102
- package/lib/cjs/webchat/context/index.js.map +0 -1
- package/lib/cjs/webchat/context/messages-reducer.d.ts +0 -6
- package/lib/cjs/webchat/context/messages-reducer.js +0 -175
- package/lib/cjs/webchat/context/messages-reducer.js.map +0 -1
- package/lib/cjs/webchat/context/types.d.ts +0 -84
- package/lib/cjs/webchat/context/types.js +0 -3
- package/lib/cjs/webchat/context/types.js.map +0 -1
- package/lib/cjs/webchat/context/use-webchat.d.ts +0 -46
- package/lib/cjs/webchat/context/use-webchat.js +0 -195
- package/lib/cjs/webchat/context/use-webchat.js.map +0 -1
- package/lib/cjs/webchat/context/webchat-reducer.d.ts +0 -6
- package/lib/cjs/webchat/context/webchat-reducer.js +0 -57
- package/lib/cjs/webchat/context/webchat-reducer.js.map +0 -1
- package/lib/cjs/webchat/cover-component/index.d.ts +0 -6
- package/lib/cjs/webchat/cover-component/index.js +0 -21
- package/lib/cjs/webchat/cover-component/index.js.map +0 -1
- package/lib/cjs/webchat/custom-messages/index.d.ts +0 -1
- package/lib/cjs/webchat/custom-messages/index.js +0 -7
- package/lib/cjs/webchat/custom-messages/index.js.map +0 -1
- package/lib/cjs/webchat/custom-messages/rating/icons/face-angry.d.ts +0 -3
- package/lib/cjs/webchat/custom-messages/rating/icons/face-angry.js +0 -9
- package/lib/cjs/webchat/custom-messages/rating/icons/face-angry.js.map +0 -1
- package/lib/cjs/webchat/custom-messages/rating/icons/face-frown.d.ts +0 -3
- package/lib/cjs/webchat/custom-messages/rating/icons/face-frown.js +0 -9
- package/lib/cjs/webchat/custom-messages/rating/icons/face-frown.js.map +0 -1
- package/lib/cjs/webchat/custom-messages/rating/icons/face-grin-beam.d.ts +0 -3
- package/lib/cjs/webchat/custom-messages/rating/icons/face-grin-beam.js +0 -9
- package/lib/cjs/webchat/custom-messages/rating/icons/face-grin-beam.js.map +0 -1
- package/lib/cjs/webchat/custom-messages/rating/icons/face-meh.d.ts +0 -3
- package/lib/cjs/webchat/custom-messages/rating/icons/face-meh.js +0 -9
- package/lib/cjs/webchat/custom-messages/rating/icons/face-meh.js.map +0 -1
- package/lib/cjs/webchat/custom-messages/rating/icons/face-smile.d.ts +0 -3
- package/lib/cjs/webchat/custom-messages/rating/icons/face-smile.js +0 -9
- package/lib/cjs/webchat/custom-messages/rating/icons/face-smile.js.map +0 -1
- package/lib/cjs/webchat/custom-messages/rating/icons/index.d.ts +0 -6
- package/lib/cjs/webchat/custom-messages/rating/icons/index.js +0 -10
- package/lib/cjs/webchat/custom-messages/rating/icons/index.js.map +0 -1
- package/lib/cjs/webchat/custom-messages/rating/icons/star.d.ts +0 -3
- package/lib/cjs/webchat/custom-messages/rating/icons/star.js +0 -9
- package/lib/cjs/webchat/custom-messages/rating/icons/star.js.map +0 -1
- package/lib/cjs/webchat/custom-messages/rating/index.d.ts +0 -2
- package/lib/cjs/webchat/custom-messages/rating/index.js +0 -56
- package/lib/cjs/webchat/custom-messages/rating/index.js.map +0 -1
- package/lib/cjs/webchat/custom-messages/rating/rating-selector.d.ts +0 -11
- package/lib/cjs/webchat/custom-messages/rating/rating-selector.js +0 -26
- package/lib/cjs/webchat/custom-messages/rating/rating-selector.js.map +0 -1
- package/lib/cjs/webchat/custom-messages/rating/smileys.d.ts +0 -2
- package/lib/cjs/webchat/custom-messages/rating/smileys.js +0 -19
- package/lib/cjs/webchat/custom-messages/rating/smileys.js.map +0 -1
- package/lib/cjs/webchat/custom-messages/rating/stars.d.ts +0 -2
- package/lib/cjs/webchat/custom-messages/rating/stars.js +0 -11
- package/lib/cjs/webchat/custom-messages/rating/stars.js.map +0 -1
- package/lib/cjs/webchat/custom-messages/rating/styles.d.ts +0 -6
- package/lib/cjs/webchat/custom-messages/rating/styles.js +0 -25
- package/lib/cjs/webchat/custom-messages/rating/styles.js.map +0 -1
- package/lib/cjs/webchat/custom-messages/rating/types.d.ts +0 -13
- package/lib/cjs/webchat/custom-messages/rating/types.js +0 -9
- package/lib/cjs/webchat/custom-messages/rating/types.js.map +0 -1
- package/lib/cjs/webchat/devices/index.d.ts +0 -11
- package/lib/cjs/webchat/devices/index.js +0 -23
- package/lib/cjs/webchat/devices/index.js.map +0 -1
- package/lib/cjs/webchat/header/default-header.d.ts +0 -1
- package/lib/cjs/webchat/header/default-header.js +0 -25
- package/lib/cjs/webchat/header/default-header.js.map +0 -1
- package/lib/cjs/webchat/header/index.d.ts +0 -1
- package/lib/cjs/webchat/header/index.js +0 -23
- package/lib/cjs/webchat/header/index.js.map +0 -1
- package/lib/cjs/webchat/header/styles.d.ts +0 -7
- package/lib/cjs/webchat/header/styles.js +0 -63
- package/lib/cjs/webchat/header/styles.js.map +0 -1
- package/lib/cjs/webchat/hooks/index.d.ts +0 -10
- package/lib/cjs/webchat/hooks/index.js +0 -24
- package/lib/cjs/webchat/hooks/index.js.map +0 -1
- package/lib/cjs/webchat/hooks/use-component-visible.d.ts +0 -7
- package/lib/cjs/webchat/hooks/use-component-visible.js +0 -23
- package/lib/cjs/webchat/hooks/use-component-visible.js.map +0 -1
- package/lib/cjs/webchat/hooks/use-component-will-mount.d.ts +0 -1
- package/lib/cjs/webchat/hooks/use-component-will-mount.js +0 -9
- package/lib/cjs/webchat/hooks/use-component-will-mount.js.map +0 -1
- package/lib/cjs/webchat/hooks/use-device-adapter.d.ts +0 -3
- package/lib/cjs/webchat/hooks/use-device-adapter.js +0 -49
- package/lib/cjs/webchat/hooks/use-device-adapter.js.map +0 -1
- package/lib/cjs/webchat/hooks/use-previous.d.ts +0 -1
- package/lib/cjs/webchat/hooks/use-previous.js +0 -12
- package/lib/cjs/webchat/hooks/use-previous.js.map +0 -1
- package/lib/cjs/webchat/hooks/use-scroll-to-bottom.d.ts +0 -9
- package/lib/cjs/webchat/hooks/use-scroll-to-bottom.js +0 -25
- package/lib/cjs/webchat/hooks/use-scroll-to-bottom.js.map +0 -1
- package/lib/cjs/webchat/hooks/use-scrollbar-controller.d.ts +0 -6
- package/lib/cjs/webchat/hooks/use-scrollbar-controller.js +0 -143
- package/lib/cjs/webchat/hooks/use-scrollbar-controller.js.map +0 -1
- package/lib/cjs/webchat/hooks/use-typing.d.ts +0 -10
- package/lib/cjs/webchat/hooks/use-typing.js +0 -36
- package/lib/cjs/webchat/hooks/use-typing.js.map +0 -1
- package/lib/cjs/webchat/hooks/use-virtual-keyboard-detection.d.ts +0 -3
- package/lib/cjs/webchat/hooks/use-virtual-keyboard-detection.js +0 -26
- package/lib/cjs/webchat/hooks/use-virtual-keyboard-detection.js.map +0 -1
- package/lib/cjs/webchat/hooks/use-webchat-dimensions.d.ts +0 -4
- package/lib/cjs/webchat/hooks/use-webchat-dimensions.js +0 -41
- package/lib/cjs/webchat/hooks/use-webchat-dimensions.js.map +0 -1
- package/lib/cjs/webchat/hooks/use-webchat-resizer.d.ts +0 -4
- package/lib/cjs/webchat/hooks/use-webchat-resizer.js +0 -34
- package/lib/cjs/webchat/hooks/use-webchat-resizer.js.map +0 -1
- package/lib/cjs/webchat/index-types.d.ts +0 -7
- package/lib/cjs/webchat/index-types.js +0 -3
- package/lib/cjs/webchat/index-types.js.map +0 -1
- package/lib/cjs/webchat/index.d.ts +0 -6
- package/lib/cjs/webchat/index.js +0 -20
- package/lib/cjs/webchat/index.js.map +0 -1
- package/lib/cjs/webchat/input-panel/attachment.d.ts +0 -6
- package/lib/cjs/webchat/input-panel/attachment.js +0 -30
- package/lib/cjs/webchat/input-panel/attachment.js.map +0 -1
- package/lib/cjs/webchat/input-panel/emoji-picker.d.ts +0 -5
- package/lib/cjs/webchat/input-panel/emoji-picker.js +0 -29
- package/lib/cjs/webchat/input-panel/emoji-picker.js.map +0 -1
- package/lib/cjs/webchat/input-panel/index.d.ts +0 -9
- package/lib/cjs/webchat/input-panel/index.js +0 -51
- package/lib/cjs/webchat/input-panel/index.js.map +0 -1
- package/lib/cjs/webchat/input-panel/opened-emoji-picker.d.ts +0 -6
- package/lib/cjs/webchat/input-panel/opened-emoji-picker.js +0 -15
- package/lib/cjs/webchat/input-panel/opened-emoji-picker.js.map +0 -1
- package/lib/cjs/webchat/input-panel/persistent-menu.d.ts +0 -5
- package/lib/cjs/webchat/input-panel/persistent-menu.js +0 -21
- package/lib/cjs/webchat/input-panel/persistent-menu.js.map +0 -1
- package/lib/cjs/webchat/input-panel/send-button.d.ts +0 -5
- package/lib/cjs/webchat/input-panel/send-button.js +0 -25
- package/lib/cjs/webchat/input-panel/send-button.js.map +0 -1
- package/lib/cjs/webchat/input-panel/styles.d.ts +0 -3
- package/lib/cjs/webchat/input-panel/styles.js +0 -31
- package/lib/cjs/webchat/input-panel/styles.js.map +0 -1
- package/lib/cjs/webchat/input-panel/textarea.d.ts +0 -10
- package/lib/cjs/webchat/input-panel/textarea.js +0 -52
- package/lib/cjs/webchat/input-panel/textarea.js.map +0 -1
- package/lib/cjs/webchat/input-panel/typing-network-sender.d.ts +0 -52
- package/lib/cjs/webchat/input-panel/typing-network-sender.js +0 -122
- package/lib/cjs/webchat/input-panel/typing-network-sender.js.map +0 -1
- package/lib/cjs/webchat/input-panel/use-typing-chat-event-sender.d.ts +0 -16
- package/lib/cjs/webchat/input-panel/use-typing-chat-event-sender.js +0 -45
- package/lib/cjs/webchat/input-panel/use-typing-chat-event-sender.js.map +0 -1
- package/lib/cjs/webchat/input-panel/use-typing-session.d.ts +0 -15
- package/lib/cjs/webchat/input-panel/use-typing-session.js +0 -98
- package/lib/cjs/webchat/input-panel/use-typing-session.js.map +0 -1
- package/lib/cjs/webchat/message-list/index.d.ts +0 -1
- package/lib/cjs/webchat/message-list/index.js +0 -116
- package/lib/cjs/webchat/message-list/index.js.map +0 -1
- package/lib/cjs/webchat/message-list/intro-message.d.ts +0 -1
- package/lib/cjs/webchat/message-list/intro-message.js +0 -24
- package/lib/cjs/webchat/message-list/intro-message.js.map +0 -1
- package/lib/cjs/webchat/message-list/scroll-button.d.ts +0 -5
- package/lib/cjs/webchat/message-list/scroll-button.js +0 -18
- package/lib/cjs/webchat/message-list/scroll-button.js.map +0 -1
- package/lib/cjs/webchat/message-list/styles.d.ts +0 -9
- package/lib/cjs/webchat/message-list/styles.js +0 -61
- package/lib/cjs/webchat/message-list/styles.js.map +0 -1
- package/lib/cjs/webchat/message-list/unread-messages-banner.d.ts +0 -7
- package/lib/cjs/webchat/message-list/unread-messages-banner.js +0 -18
- package/lib/cjs/webchat/message-list/unread-messages-banner.js.map +0 -1
- package/lib/cjs/webchat/message-list/use-debounce.d.ts +0 -1
- package/lib/cjs/webchat/message-list/use-debounce.js +0 -17
- package/lib/cjs/webchat/message-list/use-debounce.js.map +0 -1
- package/lib/cjs/webchat/message-list/use-notifications.d.ts +0 -7
- package/lib/cjs/webchat/message-list/use-notifications.js +0 -23
- package/lib/cjs/webchat/message-list/use-notifications.js.map +0 -1
- package/lib/cjs/webchat/replies/index.d.ts +0 -1
- package/lib/cjs/webchat/replies/index.js +0 -31
- package/lib/cjs/webchat/replies/index.js.map +0 -1
- package/lib/cjs/webchat/replies/styles.d.ts +0 -8
- package/lib/cjs/webchat/replies/styles.js +0 -25
- package/lib/cjs/webchat/replies/styles.js.map +0 -1
- package/lib/cjs/webchat/session-view.d.ts +0 -1
- package/lib/cjs/webchat/session-view.js +0 -103
- package/lib/cjs/webchat/session-view.js.map +0 -1
- package/lib/cjs/webchat/styles.d.ts +0 -4
- package/lib/cjs/webchat/styles.js +0 -65
- package/lib/cjs/webchat/styles.js.map +0 -1
- package/lib/cjs/webchat/theme/default-theme.d.ts +0 -2
- package/lib/cjs/webchat/theme/default-theme.js +0 -104
- package/lib/cjs/webchat/theme/default-theme.js.map +0 -1
- package/lib/cjs/webchat/theme/types.d.ts +0 -213
- package/lib/cjs/webchat/theme/types.js +0 -3
- package/lib/cjs/webchat/theme/types.js.map +0 -1
- package/lib/cjs/webchat/tracking.d.ts +0 -7
- package/lib/cjs/webchat/tracking.js +0 -39
- package/lib/cjs/webchat/tracking.js.map +0 -1
- package/lib/cjs/webchat/trigger-button/index.d.ts +0 -1
- package/lib/cjs/webchat/trigger-button/index.js +0 -34
- package/lib/cjs/webchat/trigger-button/index.js.map +0 -1
- package/lib/cjs/webchat/trigger-button/styles.d.ts +0 -3
- package/lib/cjs/webchat/trigger-button/styles.js +0 -40
- package/lib/cjs/webchat/trigger-button/styles.js.map +0 -1
- package/lib/cjs/webchat/typing-indicator/index.d.ts +0 -2
- package/lib/cjs/webchat/typing-indicator/index.js +0 -10
- package/lib/cjs/webchat/typing-indicator/index.js.map +0 -1
- package/lib/cjs/webchat/typing-indicator/styles.d.ts +0 -7
- package/lib/cjs/webchat/typing-indicator/styles.js +0 -50
- package/lib/cjs/webchat/typing-indicator/styles.js.map +0 -1
- package/lib/cjs/webchat/use-storage-state-hook.d.ts +0 -1
- package/lib/cjs/webchat/use-storage-state-hook.js +0 -40
- package/lib/cjs/webchat/use-storage-state-hook.js.map +0 -1
- package/lib/cjs/webchat/utils.d.ts +0 -2
- package/lib/cjs/webchat/utils.js +0 -13
- package/lib/cjs/webchat/utils.js.map +0 -1
- package/lib/cjs/webchat/webchat-dev.d.ts +0 -6
- package/lib/cjs/webchat/webchat-dev.js +0 -56
- package/lib/cjs/webchat/webchat-dev.js.map +0 -1
- package/lib/cjs/webchat/webchat.d.ts +0 -3
- package/lib/cjs/webchat/webchat.js +0 -560
- package/lib/cjs/webchat/webchat.js.map +0 -1
- package/lib/cjs/webchat/webview/header.d.ts +0 -1
- package/lib/cjs/webchat/webview/header.js +0 -18
- package/lib/cjs/webchat/webview/header.js.map +0 -1
- package/lib/cjs/webchat/webview/index.d.ts +0 -6
- package/lib/cjs/webchat/webview/index.js +0 -82
- package/lib/cjs/webchat/webview/index.js.map +0 -1
- package/lib/cjs/webchat/webview/styles.d.ts +0 -7
- package/lib/cjs/webchat/webview/styles.js +0 -60
- package/lib/cjs/webchat/webview/styles.js.map +0 -1
- package/lib/cjs/webchat-app.d.ts +0 -114
- package/lib/cjs/webchat-app.js +0 -407
- package/lib/cjs/webchat-app.js.map +0 -1
- package/lib/cjs/webchat.template.html +0 -37
- package/lib/cjs/webview-app.d.ts +0 -7
- package/lib/cjs/webview-app.js +0 -192
- package/lib/cjs/webview-app.js.map +0 -1
- package/lib/cjs/webview.template.html +0 -39
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"use-webchat-resizer.js","
|
|
1
|
+
{"version":3,"file":"webchat/hooks/use-webchat-resizer.js","sources":["../../../../src/webchat/hooks/use-webchat-resizer.ts"],"sourcesContent":["import { useContext } from 'react'\n\nimport { WebchatContext } from '../../webchat/context'\nimport { useWebchatDimensions } from './use-webchat-dimensions'\n\nexport const useWebchatResizer = () => {\n const { webchatContainerRef, chatAreaRef, inputPanelRef, headerRef } =\n useContext(WebchatContext)\n\n const {\n calculateResizedPercentualWebchatHeight,\n calculateResizedPxChatAreaHeight,\n } = useWebchatDimensions()\n\n const handleKeyboardShown = () => {\n if (\n webchatContainerRef.current &&\n chatAreaRef.current &&\n headerRef.current &&\n inputPanelRef.current\n ) {\n webchatContainerRef.current.style.height = `${calculateResizedPercentualWebchatHeight()}%`\n chatAreaRef.current.style.height = `${calculateResizedPxChatAreaHeight()}px`\n }\n }\n\n const handleKeyboardHidden = () => {\n if (\n webchatContainerRef.current &&\n chatAreaRef.current &&\n inputPanelRef.current &&\n headerRef.current\n ) {\n webchatContainerRef.current.style.height = '100%'\n chatAreaRef.current.style.height = `${calculateResizedPxChatAreaHeight()}px`\n }\n }\n\n return {\n handleKeyboardShown,\n handleKeyboardHidden,\n }\n}\n"],"names":["useContext","WebchatContext","useWebchatDimensions","useWebchatResizer","webchatContainerRef","chatAreaRef","inputPanelRef","headerRef","calculateResizedPercentualWebchatHeight","calculateResizedPxChatAreaHeight","handleKeyboardShown","handleKeyboardHidden"],"mappings":";;;;;;;AAAkC;AAEoB;AACS;AAExD,MAAMG,iBAAiBA,GAAG;IAC/B,MAAM,EAAEC,mBAAmB,EAAEC,WAAW,EAAEC,aAAa,EAAEC,SAAS,EAAE,GAClEP,UAAUA,CAACC,cAAcA;IAE3B,MAAM,EACJO,uCAAuC,EACvCC,gCAAgC,EACjC,GAAGP,oBAAoBA;IAExB,MAAMQ,sBAAsB;QAC1B,IACEN,oBAAoB,OAAO,IAC3BC,YAAY,OAAO,IACnBE,UAAU,OAAO,IACjBD,cAAc,OAAO,EACrB;YACAF,oBAAoB,OAAO,CAAC,KAAK,CAAC,MAAM,GAAG,GAAGI,0CAA0C,CAAC,CAAC;YAC1FH,YAAY,OAAO,CAAC,KAAK,CAAC,MAAM,GAAG,GAAGI,mCAAmC,EAAE,CAAC;QAC9E;IACF;IAEA,MAAME,uBAAuB;QAC3B,IACEP,oBAAoB,OAAO,IAC3BC,YAAY,OAAO,IACnBC,cAAc,OAAO,IACrBC,UAAU,OAAO,EACjB;YACAH,oBAAoB,OAAO,CAAC,KAAK,CAAC,MAAM,GAAG;YAC3CC,YAAY,OAAO,CAAC,KAAK,CAAC,MAAM,GAAG,GAAGI,mCAAmC,EAAE,CAAC;QAC9E;IACF;IAEA,OAAO;QACLC;QACAC;IACF;AACF,EAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index-types.js","
|
|
1
|
+
{"version":3,"file":"webchat/index-types.js","sources":["../../../src/webchat/index-types.ts"],"sourcesContent":["import type { WebchatArgs } from '../index-types'\n\nexport interface WebchatDevProps extends WebchatArgs {\n initialDevSettings?: {\n keepSessionOnReload?: boolean\n showSessionView?: boolean\n }\n}\n"],"names":[],"mappings":"AAOC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { ClientSession, WebchatContext } from './context';
|
|
2
|
-
export * from './custom-messages';
|
|
3
|
-
export { Webchat } from './webchat';
|
|
4
|
-
export { WebchatDev } from './webchat-dev';
|
|
1
|
+
export { type ClientSession, WebchatContext } from './context/index.js';
|
|
2
|
+
export * from './custom-messages/index.js';
|
|
3
|
+
export { Webchat } from './webchat.js';
|
|
4
|
+
export { WebchatDev } from './webchat-dev.js';
|
|
5
5
|
export declare function getBotonicApp(): any;
|
|
6
|
-
export * from './index-types';
|
|
6
|
+
export * from './index-types.js';
|
package/lib/esm/webchat/index.js
CHANGED
|
@@ -1,20 +1,23 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
export * from "./custom-messages/index.js";
|
|
2
|
+
export * from "./index-types.js";
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
|
|
6
6
|
// @ts-nocheck
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
Object.defineProperty(exports, "Webchat", { enumerable: true, get: function () { return webchat_1.Webchat; } });
|
|
12
|
-
var webchat_dev_1 = require("./webchat-dev");
|
|
13
|
-
Object.defineProperty(exports, "WebchatDev", { enumerable: true, get: function () { return webchat_dev_1.WebchatDev; } });
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
|
|
14
11
|
function getBotonicApp() {
|
|
15
12
|
// Botonic is exported from your bot
|
|
16
13
|
// eslint-disable-next-line no-undef
|
|
17
14
|
return Botonic;
|
|
18
15
|
}
|
|
19
|
-
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
export { getBotonicApp };
|
|
19
|
+
export { WebchatContext } from "./context/index.js";
|
|
20
|
+
export { Webchat } from "./webchat.js";
|
|
21
|
+
export { WebchatDev } from "./webchat-dev.js";
|
|
22
|
+
|
|
20
23
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","
|
|
1
|
+
{"version":3,"file":"webchat/index.js","sources":["../../../src/webchat/index.ts"],"sourcesContent":["// @ts-nocheck\nexport { type ClientSession, WebchatContext } from './context'\nexport * from './custom-messages'\nexport { Webchat } from './webchat'\nexport { WebchatDev } from './webchat-dev'\n\nexport function getBotonicApp() {\n // Botonic is exported from your bot\n // eslint-disable-next-line no-undef\n return Botonic\n}\n\nexport * from './index-types'\n"],"names":["WebchatContext","Webchat","WebchatDev","getBotonicApp","Botonic"],"mappings":";;;;;AAAA,cAAc;AACgD;AAC7B;AACE;AACO;AAEnC,SAASG,aAAaA;IAC3B,oCAAoC;IACpC,oCAAoC;IACpC,OAAOC;AACT;AAE6B"}
|
|
@@ -1,30 +1,71 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
1
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { useContext, useRef } from "react";
|
|
3
|
+
import attachment_icon from "../../assets/attachment-icon.svg";
|
|
4
|
+
import { ROLES } from "../../constants.js";
|
|
5
|
+
import { WebchatContext } from "../context/index.js";
|
|
6
|
+
import { Icon } from "../components/common.js";
|
|
7
|
+
import { ConditionalAnimation } from "../components/conditional-animation.js";
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
const Attachment = ({ accept, onChange })=>{
|
|
24
|
+
const { webchatState } = useContext(WebchatContext);
|
|
25
|
+
const fileInputRef = useRef(null);
|
|
15
26
|
const CustomAttachments = webchatState.theme.userInput?.attachments?.custom;
|
|
16
|
-
const isAttachmentsEnabled = ()
|
|
27
|
+
const isAttachmentsEnabled = ()=>{
|
|
17
28
|
const hasCustomAttachments = !!CustomAttachments;
|
|
18
|
-
return
|
|
29
|
+
return webchatState.theme.userInput?.attachments?.enable ?? hasCustomAttachments;
|
|
19
30
|
};
|
|
20
31
|
const attachmentsEnabled = isAttachmentsEnabled();
|
|
21
|
-
const handleOnChange = event
|
|
32
|
+
const handleOnChange = (event)=>{
|
|
22
33
|
onChange(event);
|
|
23
34
|
if (fileInputRef.current) {
|
|
24
35
|
fileInputRef.current.value = '';
|
|
25
36
|
}
|
|
26
37
|
};
|
|
27
|
-
return
|
|
38
|
+
return /*#__PURE__*/ jsx(Fragment, {
|
|
39
|
+
children: attachmentsEnabled ? /*#__PURE__*/ jsx(ConditionalAnimation, {
|
|
40
|
+
children: /*#__PURE__*/ jsxs("div", {
|
|
41
|
+
role: ROLES.ATTACHMENT_ICON,
|
|
42
|
+
children: [
|
|
43
|
+
/*#__PURE__*/ jsx("label", {
|
|
44
|
+
htmlFor: "attachment",
|
|
45
|
+
style: {
|
|
46
|
+
marginTop: 4
|
|
47
|
+
},
|
|
48
|
+
children: CustomAttachments ? /*#__PURE__*/ jsx(CustomAttachments, {}) : /*#__PURE__*/ jsx(Icon, {
|
|
49
|
+
src: attachment_icon
|
|
50
|
+
})
|
|
51
|
+
}),
|
|
52
|
+
/*#__PURE__*/ jsx("input", {
|
|
53
|
+
ref: fileInputRef,
|
|
54
|
+
type: "file",
|
|
55
|
+
name: "file",
|
|
56
|
+
id: "attachment",
|
|
57
|
+
style: {
|
|
58
|
+
display: 'none'
|
|
59
|
+
},
|
|
60
|
+
onChange: handleOnChange,
|
|
61
|
+
accept: accept
|
|
62
|
+
})
|
|
63
|
+
]
|
|
64
|
+
})
|
|
65
|
+
}) : null
|
|
66
|
+
});
|
|
28
67
|
};
|
|
29
|
-
|
|
68
|
+
|
|
69
|
+
export { Attachment };
|
|
70
|
+
|
|
30
71
|
//# sourceMappingURL=attachment.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"attachment.js","
|
|
1
|
+
{"version":3,"file":"webchat/input-panel/attachment.js","sources":["../../../../src/webchat/input-panel/attachment.tsx"],"sourcesContent":["import { useContext, useRef } from 'react'\n\nimport AttachmentIcon from '../../assets/attachment-icon.svg'\nimport { ROLES } from '../../constants'\nimport { WebchatContext } from '../../webchat/context'\nimport { Icon } from '../components/common'\nimport { ConditionalAnimation } from '../components/conditional-animation'\n\ninterface AttachmentProps {\n accept: string\n onChange: (event: any) => void\n}\n\nexport const Attachment = ({ accept, onChange }: AttachmentProps) => {\n const { webchatState } = useContext(WebchatContext)\n\n const fileInputRef = useRef<HTMLInputElement | null>(null)\n\n const CustomAttachments = webchatState.theme.userInput?.attachments?.custom\n\n const isAttachmentsEnabled = () => {\n const hasCustomAttachments = !!CustomAttachments\n return (\n webchatState.theme.userInput?.attachments?.enable ?? hasCustomAttachments\n )\n }\n const attachmentsEnabled = isAttachmentsEnabled()\n\n const handleOnChange = event => {\n onChange(event)\n if (fileInputRef.current) {\n fileInputRef.current.value = ''\n }\n }\n\n return (\n <>\n {attachmentsEnabled ? (\n <ConditionalAnimation>\n <div role={ROLES.ATTACHMENT_ICON}>\n <label htmlFor='attachment' style={{ marginTop: 4 }}>\n {CustomAttachments ? (\n <CustomAttachments />\n ) : (\n <Icon src={AttachmentIcon} />\n )}\n </label>\n <input\n ref={fileInputRef}\n type='file'\n name='file'\n id='attachment'\n style={{ display: 'none' }}\n onChange={handleOnChange}\n accept={accept}\n />\n </div>\n </ConditionalAnimation>\n ) : null}\n </>\n )\n}\n"],"names":["useContext","useRef","AttachmentIcon","ROLES","WebchatContext","Icon","ConditionalAnimation","Attachment","accept","onChange","webchatState","fileInputRef","CustomAttachments","isAttachmentsEnabled","hasCustomAttachments","attachmentsEnabled","handleOnChange","event"],"mappings":";;;;;;;;;;;;;;;;AAA0C;AAEmB;AACtB;AACe;AACX;AAC+B;AAOnE,MAAMO,UAAUA,GAAG,CAAC,EAAEC,MAAM,EAAEC,QAAQ,EAAmB;IAC9D,MAAM,EAAEC,YAAY,EAAE,GAAGV,UAAUA,CAACI,cAAcA;IAElD,MAAMO,eAAeV,MAAMA,CAA0B;IAErD,MAAMW,oBAAoBF,aAAa,KAAK,CAAC,SAAS,EAAE,aAAa;IAErE,MAAMG,uBAAuB;QAC3B,MAAMC,uBAAuB,CAAC,CAACF;QAC/B,OACEF,aAAa,KAAK,CAAC,SAAS,EAAE,aAAa,UAAUI;IAEzD;IACA,MAAMC,qBAAqBF;IAE3B,MAAMG,iBAAiBC,CAAAA;QACrBR,SAASQ;QACT,IAAIN,aAAa,OAAO,EAAE;YACxBA,aAAa,OAAO,CAAC,KAAK,GAAG;QAC/B;IACF;IAEA,qBACE;kBACGI,mCACC,IAACT,oBAAoBA;sBACnB,mBAAC;gBAAI,MAAMH,qBAAqB;;kCAC9B,IAAC;wBAAM,SAAQ;wBAAa,OAAO;4BAAE,WAAW;wBAAE;kCAC/CS,kCACC,IAACA,uCAED,IAACP,IAAIA;4BAAC,KAAKH,eAAcA;;;kCAG7B,IAAC;wBACC,KAAKS;wBACL,MAAK;wBACL,MAAK;wBACL,IAAG;wBACH,OAAO;4BAAE,SAAS;wBAAO;wBACzB,UAAUK;wBACV,QAAQR;;;;aAIZ;;AAGV,EAAC"}
|
|
@@ -1,29 +1,50 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
1
|
+
import { Fragment, jsx } from "react/jsx-runtime";
|
|
2
|
+
import { useContext } from "react";
|
|
3
|
+
import emojiButton from "../../assets/emojiButton.svg";
|
|
4
|
+
import { ROLES } from "../../constants.js";
|
|
5
|
+
import { WebchatContext } from "../context/index.js";
|
|
6
|
+
import { Icon } from "../components/common.js";
|
|
7
|
+
import { ConditionalAnimation } from "../components/conditional-animation.js";
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
/** biome-ignore-all lint/a11y/noStaticElementInteractions: we need to use static elements for the emoji picker */ /** biome-ignore-all lint/a11y/useKeyWithClickEvents: we need to use key with click events for the emoji picker */
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
const EmojiPicker = ({ onClick })=>{
|
|
24
|
+
const { webchatState } = useContext(WebchatContext);
|
|
16
25
|
const CustomEmojiPicker = webchatState.theme.userInput?.emojiPicker?.custom;
|
|
17
|
-
const isEmojiPickerEnabled = ()
|
|
26
|
+
const isEmojiPickerEnabled = ()=>{
|
|
18
27
|
const hasCustomEmojiPicker = !!CustomEmojiPicker;
|
|
19
|
-
return
|
|
28
|
+
return webchatState.theme.userInput?.emojiPicker?.enable ?? hasCustomEmojiPicker;
|
|
20
29
|
};
|
|
21
30
|
const emojiPickerEnabled = isEmojiPickerEnabled();
|
|
22
|
-
const handleClick = (event)
|
|
31
|
+
const handleClick = (event)=>{
|
|
23
32
|
onClick();
|
|
24
33
|
event.stopPropagation();
|
|
25
34
|
};
|
|
26
|
-
return
|
|
35
|
+
return /*#__PURE__*/ jsx(Fragment, {
|
|
36
|
+
children: emojiPickerEnabled ? /*#__PURE__*/ jsx(ConditionalAnimation, {
|
|
37
|
+
children: /*#__PURE__*/ jsx("div", {
|
|
38
|
+
role: ROLES.EMOJI_PICKER_ICON,
|
|
39
|
+
onClick: handleClick,
|
|
40
|
+
children: CustomEmojiPicker ? /*#__PURE__*/ jsx(CustomEmojiPicker, {}) : /*#__PURE__*/ jsx(Icon, {
|
|
41
|
+
src: emojiButton
|
|
42
|
+
})
|
|
43
|
+
})
|
|
44
|
+
}) : null
|
|
45
|
+
});
|
|
27
46
|
};
|
|
28
|
-
|
|
47
|
+
|
|
48
|
+
export { EmojiPicker };
|
|
49
|
+
|
|
29
50
|
//# sourceMappingURL=emoji-picker.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"emoji-picker.js","
|
|
1
|
+
{"version":3,"file":"webchat/input-panel/emoji-picker.js","sources":["../../../../src/webchat/input-panel/emoji-picker.tsx"],"sourcesContent":["/** biome-ignore-all lint/a11y/noStaticElementInteractions: we need to use static elements for the emoji picker */\n/** biome-ignore-all lint/a11y/useKeyWithClickEvents: we need to use key with click events for the emoji picker */\nimport { useContext } from 'react'\n\nimport LogoEmoji from '../../assets/emojiButton.svg'\nimport { ROLES } from '../../constants'\nimport { WebchatContext } from '../../webchat/context'\nimport { Icon } from '../components/common'\nimport { ConditionalAnimation } from '../components/conditional-animation'\n\ninterface EmojiPickerProps {\n onClick: () => void\n}\n\nexport const EmojiPicker = ({ onClick }: EmojiPickerProps) => {\n const { webchatState } = useContext(WebchatContext)\n\n const CustomEmojiPicker = webchatState.theme.userInput?.emojiPicker?.custom\n\n const isEmojiPickerEnabled = () => {\n const hasCustomEmojiPicker = !!CustomEmojiPicker\n return (\n webchatState.theme.userInput?.emojiPicker?.enable ?? hasCustomEmojiPicker\n )\n }\n const emojiPickerEnabled = isEmojiPickerEnabled()\n\n const handleClick = (event: any) => {\n onClick()\n event.stopPropagation()\n }\n\n return (\n <>\n {emojiPickerEnabled ? (\n <ConditionalAnimation>\n <div role={ROLES.EMOJI_PICKER_ICON} onClick={handleClick}>\n {CustomEmojiPicker ? (\n <CustomEmojiPicker />\n ) : (\n <Icon src={LogoEmoji} />\n )}\n </div>\n </ConditionalAnimation>\n ) : null}\n </>\n )\n}\n"],"names":["useContext","LogoEmoji","ROLES","WebchatContext","Icon","ConditionalAnimation","EmojiPicker","onClick","webchatState","CustomEmojiPicker","isEmojiPickerEnabled","hasCustomEmojiPicker","emojiPickerEnabled","handleClick","event"],"mappings":";;;;;;;;;;;;;;;;AAAA,gHAAgH,GAChH,gHAAgH,GAC9E;AAEkB;AACb;AACe;AACX;AAC+B;AAMnE,MAAMM,WAAWA,GAAG,CAAC,EAAEC,OAAO,EAAoB;IACvD,MAAM,EAAEC,YAAY,EAAE,GAAGR,UAAUA,CAACG,cAAcA;IAElD,MAAMM,oBAAoBD,aAAa,KAAK,CAAC,SAAS,EAAE,aAAa;IAErE,MAAME,uBAAuB;QAC3B,MAAMC,uBAAuB,CAAC,CAACF;QAC/B,OACED,aAAa,KAAK,CAAC,SAAS,EAAE,aAAa,UAAUG;IAEzD;IACA,MAAMC,qBAAqBF;IAE3B,MAAMG,cAAc,CAACC;QACnBP;QACAO,MAAM,eAAe;IACvB;IAEA,qBACE;kBACGF,mCACC,IAACP,oBAAoBA;sBACnB,kBAAC;gBAAI,MAAMH,uBAAuB;gBAAE,SAASW;0BAC1CJ,kCACC,IAACA,uCAED,IAACL,IAAIA;oBAAC,KAAKH,WAASA;;;aAIxB;;AAGV,EAAC"}
|
|
@@ -1,36 +1,62 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
1
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { useContext } from "react";
|
|
3
|
+
import { WEBCHAT } from "../../constants.js";
|
|
4
|
+
import { getFullMimeWhitelist } from "../../message-utils.js";
|
|
5
|
+
import { WebchatContext } from "../context/index.js";
|
|
6
|
+
import { BotonicContainerId } from "../constants.js";
|
|
7
|
+
import { Attachment } from "./attachment.js";
|
|
8
|
+
import { EmojiPicker } from "./emoji-picker.js";
|
|
9
|
+
import { OpenedEmojiPicker } from "./opened-emoji-picker.js";
|
|
10
|
+
import { PersistentMenu } from "./persistent-menu.js";
|
|
11
|
+
import { SendButton } from "./send-button.js";
|
|
12
|
+
import { UserInputContainer } from "./styles.js";
|
|
13
|
+
import { Textarea } from "./textarea.js";
|
|
14
|
+
import { useTypingChatEventSender } from "./use-typing-chat-event-sender.js";
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
const InputPanel = ({ handleAttachment, textareaRef, host, onUserInput })=>{
|
|
45
|
+
const { getThemeProperty, sendText, togglePersistentMenu, toggleEmojiPicker, webchatState, inputPanelRef } = useContext(WebchatContext);
|
|
46
|
+
const handleSelectedEmoji = (event)=>{
|
|
21
47
|
if (!textareaRef.current) {
|
|
22
48
|
return;
|
|
23
49
|
}
|
|
24
50
|
textareaRef.current.value += event.emoji;
|
|
25
51
|
textareaRef.current.focus();
|
|
26
52
|
};
|
|
27
|
-
const handleEmojiClick = ()
|
|
53
|
+
const handleEmojiClick = ()=>{
|
|
28
54
|
toggleEmojiPicker(!webchatState.isEmojiPickerOpen);
|
|
29
55
|
};
|
|
30
|
-
const handleMenu = ()
|
|
56
|
+
const handleMenu = ()=>{
|
|
31
57
|
togglePersistentMenu(!webchatState.isPersistentMenuOpen);
|
|
32
58
|
};
|
|
33
|
-
const sendTextAreaText = async ()
|
|
59
|
+
const sendTextAreaText = async ()=>{
|
|
34
60
|
if (!textareaRef.current) {
|
|
35
61
|
return;
|
|
36
62
|
}
|
|
@@ -38,14 +64,46 @@ const InputPanel = ({ handleAttachment, textareaRef, host, onUserInput, }) => {
|
|
|
38
64
|
textareaRef.current.value = '';
|
|
39
65
|
};
|
|
40
66
|
// Network layer: deduplicates typing_on/off before they reach onUserInput.
|
|
41
|
-
const sendChatEvent =
|
|
67
|
+
const sendChatEvent = useTypingChatEventSender({
|
|
42
68
|
onUserInput,
|
|
43
69
|
session: webchatState.session,
|
|
44
|
-
lastRoutePath: webchatState.lastRoutePath
|
|
70
|
+
lastRoutePath: webchatState.lastRoutePath
|
|
71
|
+
});
|
|
72
|
+
return /*#__PURE__*/ jsxs(UserInputContainer, {
|
|
73
|
+
id: BotonicContainerId.InputPanel,
|
|
74
|
+
ref: inputPanelRef,
|
|
75
|
+
style: {
|
|
76
|
+
...getThemeProperty(WEBCHAT.CUSTOM_PROPERTIES.userInputStyle)
|
|
77
|
+
},
|
|
78
|
+
className: "user-input-container",
|
|
79
|
+
children: [
|
|
80
|
+
webchatState.isEmojiPickerOpen && /*#__PURE__*/ jsx(OpenedEmojiPicker, {
|
|
81
|
+
onEmojiClick: handleSelectedEmoji,
|
|
82
|
+
onClick: handleEmojiClick
|
|
83
|
+
}),
|
|
84
|
+
/*#__PURE__*/ jsx(PersistentMenu, {
|
|
85
|
+
onClick: handleMenu
|
|
86
|
+
}),
|
|
87
|
+
/*#__PURE__*/ jsx(Textarea, {
|
|
88
|
+
host: host,
|
|
89
|
+
textareaRef: textareaRef,
|
|
90
|
+
sendChatEvent: sendChatEvent,
|
|
91
|
+
sendTextAreaText: sendTextAreaText
|
|
92
|
+
}),
|
|
93
|
+
/*#__PURE__*/ jsx(EmojiPicker, {
|
|
94
|
+
onClick: handleEmojiClick
|
|
95
|
+
}),
|
|
96
|
+
/*#__PURE__*/ jsx(Attachment, {
|
|
97
|
+
onChange: handleAttachment,
|
|
98
|
+
accept: getFullMimeWhitelist().join(',')
|
|
99
|
+
}),
|
|
100
|
+
/*#__PURE__*/ jsx(SendButton, {
|
|
101
|
+
onClick: sendTextAreaText
|
|
102
|
+
})
|
|
103
|
+
]
|
|
45
104
|
});
|
|
46
|
-
return ((0, jsx_runtime_1.jsxs)(styles_1.UserInputContainer, { id: constants_2.BotonicContainerId.InputPanel, ref: inputPanelRef, style: {
|
|
47
|
-
...getThemeProperty(constants_1.WEBCHAT.CUSTOM_PROPERTIES.userInputStyle),
|
|
48
|
-
}, className: 'user-input-container', children: [webchatState.isEmojiPickerOpen && ((0, jsx_runtime_1.jsx)(opened_emoji_picker_1.OpenedEmojiPicker, { onEmojiClick: handleSelectedEmoji, onClick: handleEmojiClick })), (0, jsx_runtime_1.jsx)(persistent_menu_1.PersistentMenu, { onClick: handleMenu }), (0, jsx_runtime_1.jsx)(textarea_1.Textarea, { host: host, textareaRef: textareaRef, sendChatEvent: sendChatEvent, sendTextAreaText: sendTextAreaText }), (0, jsx_runtime_1.jsx)(emoji_picker_1.EmojiPicker, { onClick: handleEmojiClick }), (0, jsx_runtime_1.jsx)(attachment_1.Attachment, { onChange: handleAttachment, accept: (0, message_utils_1.getFullMimeWhitelist)().join(',') }), (0, jsx_runtime_1.jsx)(send_button_1.SendButton, { onClick: sendTextAreaText })] }));
|
|
49
105
|
};
|
|
50
|
-
|
|
106
|
+
|
|
107
|
+
export { InputPanel };
|
|
108
|
+
|
|
51
109
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","
|
|
1
|
+
{"version":3,"file":"webchat/input-panel/index.js","sources":["../../../../src/webchat/input-panel/index.tsx"],"sourcesContent":["import type React from 'react'\nimport { useContext } from 'react'\n\nimport { WEBCHAT } from '../../constants'\nimport { getFullMimeWhitelist } from '../../message-utils'\nimport { WebchatContext } from '../../webchat/context'\nimport { BotonicContainerId } from '../constants'\nimport { Attachment } from './attachment'\nimport { EmojiPicker } from './emoji-picker'\nimport { OpenedEmojiPicker } from './opened-emoji-picker'\nimport { PersistentMenu } from './persistent-menu'\nimport { SendButton } from './send-button'\nimport { UserInputContainer } from './styles'\nimport { Textarea } from './textarea'\nimport { useTypingChatEventSender } from './use-typing-chat-event-sender'\n\ninterface InputPanelProps {\n handleAttachment: (event: any) => void\n textareaRef: React.MutableRefObject<HTMLTextAreaElement | undefined>\n host: HTMLElement\n onUserInput?: (event: any) => Promise<void>\n}\n\nexport const InputPanel = ({\n handleAttachment,\n textareaRef,\n host,\n onUserInput,\n}: InputPanelProps) => {\n const {\n getThemeProperty,\n sendText,\n togglePersistentMenu,\n toggleEmojiPicker,\n webchatState,\n inputPanelRef,\n } = useContext(WebchatContext)\n\n const handleSelectedEmoji = event => {\n if (!textareaRef.current) {\n return\n }\n\n textareaRef.current.value += event.emoji\n textareaRef.current.focus()\n }\n\n const handleEmojiClick = () => {\n toggleEmojiPicker(!webchatState.isEmojiPickerOpen)\n }\n\n const handleMenu = () => {\n togglePersistentMenu(!webchatState.isPersistentMenuOpen)\n }\n\n const sendTextAreaText = async () => {\n if (!textareaRef.current) {\n return\n }\n\n await sendText(textareaRef.current?.value)\n textareaRef.current.value = ''\n }\n\n // Network layer: deduplicates typing_on/off before they reach onUserInput.\n const sendChatEvent = useTypingChatEventSender({\n onUserInput,\n session: webchatState.session,\n lastRoutePath: webchatState.lastRoutePath,\n })\n\n return (\n <UserInputContainer\n id={BotonicContainerId.InputPanel}\n ref={inputPanelRef}\n style={{\n ...getThemeProperty(WEBCHAT.CUSTOM_PROPERTIES.userInputStyle),\n }}\n className='user-input-container'\n >\n {webchatState.isEmojiPickerOpen && (\n <OpenedEmojiPicker\n onEmojiClick={handleSelectedEmoji}\n onClick={handleEmojiClick}\n />\n )}\n\n <PersistentMenu onClick={handleMenu} />\n\n <Textarea\n host={host}\n textareaRef={textareaRef}\n sendChatEvent={sendChatEvent}\n sendTextAreaText={sendTextAreaText}\n />\n\n <EmojiPicker onClick={handleEmojiClick} />\n\n <Attachment\n onChange={handleAttachment}\n accept={getFullMimeWhitelist().join(',')}\n />\n\n <SendButton onClick={sendTextAreaText} />\n </UserInputContainer>\n )\n}\n"],"names":["useContext","WEBCHAT","getFullMimeWhitelist","WebchatContext","BotonicContainerId","Attachment","EmojiPicker","OpenedEmojiPicker","PersistentMenu","SendButton","UserInputContainer","Textarea","useTypingChatEventSender","InputPanel","handleAttachment","textareaRef","host","onUserInput","getThemeProperty","sendText","togglePersistentMenu","toggleEmojiPicker","webchatState","inputPanelRef","handleSelectedEmoji","event","handleEmojiClick","handleMenu","sendTextAreaText","sendChatEvent"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACkC;AAEO;AACiB;AACJ;AACL;AACR;AACG;AACa;AACP;AACR;AACG;AACR;AACoC;AASlE,MAAMa,UAAUA,GAAG,CAAC,EACzBC,gBAAgB,EAChBC,WAAW,EACXC,IAAI,EACJC,WAAW,EACK;IAChB,MAAM,EACJC,gBAAgB,EAChBC,QAAQ,EACRC,oBAAoB,EACpBC,iBAAiB,EACjBC,YAAY,EACZC,aAAa,EACd,GAAGvB,UAAUA,CAACG,cAAcA;IAE7B,MAAMqB,sBAAsBC,CAAAA;QAC1B,IAAI,CAACV,YAAY,OAAO,EAAE;YACxB;QACF;QAEAA,YAAY,OAAO,CAAC,KAAK,IAAIU,MAAM,KAAK;QACxCV,YAAY,OAAO,CAAC,KAAK;IAC3B;IAEA,MAAMW,mBAAmB;QACvBL,kBAAkB,CAACC,aAAa,iBAAiB;IACnD;IAEA,MAAMK,aAAa;QACjBP,qBAAqB,CAACE,aAAa,oBAAoB;IACzD;IAEA,MAAMM,mBAAmB;QACvB,IAAI,CAACb,YAAY,OAAO,EAAE;YACxB;QACF;QAEA,MAAMI,SAASJ,YAAY,OAAO,EAAE;QACpCA,YAAY,OAAO,CAAC,KAAK,GAAG;IAC9B;IAEA,2EAA2E;IAC3E,MAAMc,gBAAgBjB,wBAAwBA,CAAC;QAC7CK;QACA,SAASK,aAAa,OAAO;QAC7B,eAAeA,aAAa,aAAa;IAC3C;IAEA,qBACE,KAACZ,kBAAkBA;QACjB,IAAIN,6BAA6B;QACjC,KAAKmB;QACL,OAAO;YACL,GAAGL,iBAAiBjB,wCAAwC,CAAC;QAC/D;QACA,WAAU;;YAETqB,aAAa,iBAAiB,kBAC7B,IAACf,iBAAiBA;gBAChB,cAAciB;gBACd,SAASE;;0BAIb,IAAClB,cAAcA;gBAAC,SAASmB;;0BAEzB,IAAChB,QAAQA;gBACP,MAAMK;gBACN,aAAaD;gBACb,eAAec;gBACf,kBAAkBD;;0BAGpB,IAACtB,WAAWA;gBAAC,SAASoB;;0BAEtB,IAACrB,UAAUA;gBACT,UAAUS;gBACV,QAAQZ,oBAAoBA,GAAG,IAAI,CAAC;;0BAGtC,IAACO,UAAUA;gBAAC,SAASmB;;;;AAG3B,EAAC"}
|
|
@@ -1,15 +1,39 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import emoji_picker_react from "emoji-picker-react";
|
|
3
|
+
import { ROLES } from "../../constants.js";
|
|
4
|
+
import { useComponentVisible } from "../hooks/index.js";
|
|
5
|
+
import { OpenedEmojiPickerContainer } from "./styles.js";
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
const OpenedEmojiPicker = ({ onClick, onEmojiClick })=>{
|
|
18
|
+
const { ref, isComponentVisible } = useComponentVisible(true, onClick);
|
|
19
|
+
return /*#__PURE__*/ jsx("div", {
|
|
20
|
+
ref: ref,
|
|
21
|
+
children: isComponentVisible && /*#__PURE__*/ jsx(OpenedEmojiPickerContainer, {
|
|
22
|
+
role: ROLES.EMOJI_PICKER,
|
|
23
|
+
children: /*#__PURE__*/ jsx(emoji_picker_react, {
|
|
24
|
+
width: "100%",
|
|
25
|
+
height: "19rem",
|
|
26
|
+
previewConfig: {
|
|
27
|
+
showPreview: false
|
|
28
|
+
},
|
|
29
|
+
lazyLoadEmojis: true,
|
|
30
|
+
onEmojiClick: onEmojiClick,
|
|
31
|
+
autoFocusSearch: false
|
|
32
|
+
})
|
|
33
|
+
})
|
|
34
|
+
});
|
|
13
35
|
};
|
|
14
|
-
|
|
36
|
+
|
|
37
|
+
export { OpenedEmojiPicker };
|
|
38
|
+
|
|
15
39
|
//# sourceMappingURL=opened-emoji-picker.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"opened-emoji-picker.js","
|
|
1
|
+
{"version":3,"file":"webchat/input-panel/opened-emoji-picker.js","sources":["../../../../src/webchat/input-panel/opened-emoji-picker.tsx"],"sourcesContent":["import Picker from 'emoji-picker-react'\nimport type { LegacyRef } from 'react'\n\nimport { ROLES } from '../../constants'\nimport { useComponentVisible } from '../hooks'\nimport { OpenedEmojiPickerContainer } from './styles'\n\ninterface OpenedEmojiPickerProps {\n onClick: () => void\n onEmojiClick: (event: any) => void\n}\n\nexport const OpenedEmojiPicker = ({\n onClick,\n onEmojiClick,\n}: OpenedEmojiPickerProps) => {\n const { ref, isComponentVisible } = useComponentVisible(true, onClick)\n return (\n <div ref={ref as LegacyRef<HTMLDivElement>}>\n {isComponentVisible && (\n <OpenedEmojiPickerContainer role={ROLES.EMOJI_PICKER}>\n <Picker\n width='100%'\n height='19rem'\n previewConfig={{ showPreview: false }}\n lazyLoadEmojis={true}\n onEmojiClick={onEmojiClick}\n autoFocusSearch={false}\n />\n </OpenedEmojiPickerContainer>\n )}\n </div>\n )\n}\n"],"names":["Picker","ROLES","useComponentVisible","OpenedEmojiPickerContainer","OpenedEmojiPicker","onClick","onEmojiClick","ref","isComponentVisible"],"mappings":";;;;;;;;;;;;AAAuC;AAGA;AACO;AACO;AAO9C,MAAMI,iBAAiBA,GAAG,CAAC,EAChCC,OAAO,EACPC,YAAY,EACW;IACvB,MAAM,EAAEC,GAAG,EAAEC,kBAAkB,EAAE,GAAGN,mBAAmBA,CAAC,MAAMG;IAC9D,qBACE,IAAC;QAAI,KAAKE;kBACPC,oCACC,IAACL,0BAA0BA;YAAC,MAAMF,kBAAkB;sBAClD,kBAACD,kBAAMA;gBACL,OAAM;gBACN,QAAO;gBACP,eAAe;oBAAE,aAAa;gBAAM;gBACpC,gBAAgB;gBAChB,cAAcM;gBACd,iBAAiB;;;;AAM7B,EAAC"}
|
|
@@ -1,21 +1,42 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
1
|
+
import { Fragment, jsx } from "react/jsx-runtime";
|
|
2
|
+
import { useContext } from "react";
|
|
3
|
+
import menuButton from "../../assets/menuButton.svg";
|
|
4
|
+
import { ROLES } from "../../constants.js";
|
|
5
|
+
import { WebchatContext } from "../context/index.js";
|
|
6
|
+
import { Icon } from "../components/common.js";
|
|
7
|
+
import { ConditionalAnimation } from "../components/conditional-animation.js";
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
/** biome-ignore-all lint/a11y/noStaticElementInteractions: we need to use static elements for the persistent menu */ /** biome-ignore-all lint/a11y/useKeyWithClickEvents: we need to use key with click events for the persistent menu */
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
const PersistentMenu = ({ onClick })=>{
|
|
24
|
+
const { webchatState } = useContext(WebchatContext);
|
|
16
25
|
const persistentMenuOptions = webchatState.theme.userInput?.persistentMenu;
|
|
17
26
|
const CustomMenuButton = webchatState.theme.userInput?.menuButton?.custom;
|
|
18
|
-
return
|
|
27
|
+
return /*#__PURE__*/ jsx(Fragment, {
|
|
28
|
+
children: persistentMenuOptions ? /*#__PURE__*/ jsx(ConditionalAnimation, {
|
|
29
|
+
children: /*#__PURE__*/ jsx("div", {
|
|
30
|
+
role: ROLES.PERSISTENT_MENU_ICON,
|
|
31
|
+
onClick: onClick,
|
|
32
|
+
children: CustomMenuButton ? /*#__PURE__*/ jsx(CustomMenuButton, {}) : /*#__PURE__*/ jsx(Icon, {
|
|
33
|
+
src: menuButton
|
|
34
|
+
})
|
|
35
|
+
})
|
|
36
|
+
}) : null
|
|
37
|
+
});
|
|
19
38
|
};
|
|
20
|
-
|
|
39
|
+
|
|
40
|
+
export { PersistentMenu };
|
|
41
|
+
|
|
21
42
|
//# sourceMappingURL=persistent-menu.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"persistent-menu.js","
|
|
1
|
+
{"version":3,"file":"webchat/input-panel/persistent-menu.js","sources":["../../../../src/webchat/input-panel/persistent-menu.tsx"],"sourcesContent":["/** biome-ignore-all lint/a11y/noStaticElementInteractions: we need to use static elements for the persistent menu */\n/** biome-ignore-all lint/a11y/useKeyWithClickEvents: we need to use key with click events for the persistent menu */\nimport { useContext } from 'react'\n\nimport LogoMenu from '../../assets/menuButton.svg'\nimport { ROLES } from '../../constants'\nimport { WebchatContext } from '../../webchat/context'\nimport { Icon } from '../components/common'\nimport { ConditionalAnimation } from '../components/conditional-animation'\n\ninterface PersistentMenuProps {\n onClick: () => void\n}\n\nexport const PersistentMenu = ({ onClick }: PersistentMenuProps) => {\n const { webchatState } = useContext(WebchatContext)\n\n const persistentMenuOptions = webchatState.theme.userInput?.persistentMenu\n\n const CustomMenuButton = webchatState.theme.userInput?.menuButton?.custom\n\n return (\n <>\n {persistentMenuOptions ? (\n <ConditionalAnimation>\n <div role={ROLES.PERSISTENT_MENU_ICON} onClick={onClick}>\n {CustomMenuButton ? <CustomMenuButton /> : <Icon src={LogoMenu} />}\n </div>\n </ConditionalAnimation>\n ) : null}\n </>\n )\n}\n"],"names":["useContext","LogoMenu","ROLES","WebchatContext","Icon","ConditionalAnimation","PersistentMenu","onClick","webchatState","persistentMenuOptions","CustomMenuButton"],"mappings":";;;;;;;;;;;;;;;;AAAA,mHAAmH,GACnH,mHAAmH,GACjF;AAEgB;AACX;AACe;AACX;AAC+B;AAMnE,MAAMM,cAAcA,GAAG,CAAC,EAAEC,OAAO,EAAuB;IAC7D,MAAM,EAAEC,YAAY,EAAE,GAAGR,UAAUA,CAACG,cAAcA;IAElD,MAAMM,wBAAwBD,aAAa,KAAK,CAAC,SAAS,EAAE;IAE5D,MAAME,mBAAmBF,aAAa,KAAK,CAAC,SAAS,EAAE,YAAY;IAEnE,qBACE;kBACGC,sCACC,IAACJ,oBAAoBA;sBACnB,kBAAC;gBAAI,MAAMH,0BAA0B;gBAAE,SAASK;0BAC7CG,iCAAmB,IAACA,sCAAsB,IAACN,IAAIA;oBAAC,KAAKH,UAAQA;;;aAGhE;;AAGV,EAAC"}
|