@flamingo-stack/openframe-frontend-core 0.0.204 → 0.0.205
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-4CWSZPXH.cjs → chunk-24KCAECR.cjs} +9 -9
- package/dist/{chunk-4CWSZPXH.cjs.map → chunk-24KCAECR.cjs.map} +1 -1
- package/dist/chunk-27APPAJN.cjs +24 -0
- package/dist/chunk-27APPAJN.cjs.map +1 -0
- package/dist/{chunk-UC43NICZ.cjs → chunk-664KA5FI.cjs} +2 -35
- package/dist/chunk-664KA5FI.cjs.map +1 -0
- package/dist/chunk-6RZYJICV.cjs +24 -0
- package/dist/chunk-6RZYJICV.cjs.map +1 -0
- package/dist/chunk-7L4DWM7P.js +24 -0
- package/dist/chunk-7L4DWM7P.js.map +1 -0
- package/dist/chunk-BZFW3FOF.cjs +21 -0
- package/dist/chunk-BZFW3FOF.cjs.map +1 -0
- package/dist/{chunk-N57KWHDB.js → chunk-CIPO6DXK.js} +5 -5
- package/dist/chunk-EL5YVPD5.js +21 -0
- package/dist/chunk-EL5YVPD5.js.map +1 -0
- package/dist/{chunk-ARQ4XP64.cjs → chunk-FDCFI7YT.cjs} +40080 -31492
- package/dist/chunk-FDCFI7YT.cjs.map +1 -0
- package/dist/chunk-G7UE6RKV.cjs +121 -0
- package/dist/chunk-G7UE6RKV.cjs.map +1 -0
- package/dist/{chunk-25LVV26X.cjs → chunk-JUZGUQMX.cjs} +178 -50
- package/dist/chunk-JUZGUQMX.cjs.map +1 -0
- package/dist/{chunk-SZPJ5R5B.js → chunk-KSOOKNBG.js} +1 -34
- package/dist/chunk-KSOOKNBG.js.map +1 -0
- package/dist/{chunk-RMB5DVED.cjs → chunk-KUZGEA7U.cjs} +83 -66
- package/dist/chunk-KUZGEA7U.cjs.map +1 -0
- package/dist/chunk-LXC6P2EO.js +63 -0
- package/dist/chunk-LXC6P2EO.js.map +1 -0
- package/dist/chunk-MJNXIEV2.js +24 -0
- package/dist/chunk-MJNXIEV2.js.map +1 -0
- package/dist/{chunk-CPXLQ57U.js → chunk-MVGGXOFA.js} +37 -20
- package/dist/chunk-MVGGXOFA.js.map +1 -0
- package/dist/{chunk-LY34ORX6.js → chunk-O55ZUAX7.js} +39920 -31332
- package/dist/chunk-O55ZUAX7.js.map +1 -0
- package/dist/chunk-OHPI2HRK.js +47 -0
- package/dist/chunk-OHPI2HRK.js.map +1 -0
- package/dist/chunk-PLJLE4A4.js +121 -0
- package/dist/chunk-PLJLE4A4.js.map +1 -0
- package/dist/{chunk-XGL5FKIK.js → chunk-SCN5WFIZ.js} +148 -20
- package/dist/chunk-SCN5WFIZ.js.map +1 -0
- package/dist/chunk-WBR7H6E3.cjs +47 -0
- package/dist/chunk-WBR7H6E3.cjs.map +1 -0
- package/dist/chunk-XL4V2PYG.cjs +63 -0
- package/dist/chunk-XL4V2PYG.cjs.map +1 -0
- package/dist/components/announcement-bar.d.ts.map +1 -1
- package/dist/components/chat/chat-attachment-bar.d.ts +66 -0
- package/dist/components/chat/chat-attachment-bar.d.ts.map +1 -0
- package/dist/components/chat/chat-container.d.ts +21 -1
- package/dist/components/chat/chat-container.d.ts.map +1 -1
- package/dist/components/chat/chat-input.d.ts.map +1 -1
- package/dist/components/chat/chat-message-enhanced.d.ts.map +1 -1
- package/dist/components/chat/chat-message-list.d.ts.map +1 -1
- package/dist/components/chat/chat-panel-context.d.ts +9 -0
- package/dist/components/chat/chat-panel-context.d.ts.map +1 -0
- package/dist/components/chat/chat-ticket-list.d.ts +1 -1
- package/dist/components/chat/chat-ticket-list.d.ts.map +1 -1
- package/dist/components/chat/embeddable-chat.d.ts +42 -0
- package/dist/components/chat/embeddable-chat.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/admin-content-card.d.ts +34 -0
- package/dist/components/chat/entity-cards/admin-content-card.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/block-card.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/blog-card.d.ts +30 -0
- package/dist/components/chat/entity-cards/blog-card.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/blog-image-placeholder.d.ts +26 -0
- package/dist/components/chat/entity-cards/blog-image-placeholder.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/campaign-card-admin.d.ts +33 -0
- package/dist/components/chat/entity-cards/campaign-card-admin.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/case-study-card.d.ts +20 -0
- package/dist/components/chat/entity-cards/case-study-card.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/chat-ticket-item.d.ts.map +1 -0
- package/dist/components/chat/{chat-video-entity-card.d.ts → entity-cards/chat-video-entity-card.d.ts} +1 -1
- package/dist/components/chat/entity-cards/chat-video-entity-card.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/customer-interview-card.d.ts +19 -0
- package/dist/components/chat/entity-cards/customer-interview-card.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/data-room-doc-card.d.ts +47 -0
- package/dist/components/chat/entity-cards/data-room-doc-card.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/dispatch.d.ts +119 -0
- package/dist/components/chat/entity-cards/dispatch.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/entity-author-card.d.ts +87 -0
- package/dist/components/chat/entity-cards/entity-author-card.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/generic-entity-card.d.ts +42 -0
- package/dist/components/chat/entity-cards/generic-entity-card.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/github-activity-card.d.ts +37 -0
- package/dist/components/chat/entity-cards/github-activity-card.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/hubspot-ticket-card.d.ts +28 -0
- package/dist/components/chat/entity-cards/hubspot-ticket-card.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/index.d.ts +32 -0
- package/dist/components/chat/entity-cards/index.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/investor-update-card.d.ts +19 -0
- package/dist/components/chat/entity-cards/investor-update-card.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/onboarding-guide-card.d.ts +20 -0
- package/dist/components/chat/entity-cards/onboarding-guide-card.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/product-release-card-defaults.d.ts +21 -0
- package/dist/components/chat/entity-cards/product-release-card-defaults.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/product-release-card.d.ts +12 -0
- package/dist/components/chat/entity-cards/product-release-card.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/program-card-defaults.d.ts +32 -0
- package/dist/components/chat/entity-cards/program-card-defaults.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/program-card.d.ts +37 -0
- package/dist/components/chat/entity-cards/program-card.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/roadmap-card.d.ts +28 -0
- package/dist/components/chat/entity-cards/roadmap-card.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/roadmap-vote-button.d.ts +12 -0
- package/dist/components/chat/entity-cards/roadmap-vote-button.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/slack-message-card.d.ts +28 -0
- package/dist/components/chat/entity-cards/slack-message-card.d.ts.map +1 -0
- package/dist/components/chat/entity-cards/task-type-icon.d.ts +6 -0
- package/dist/components/chat/entity-cards/task-type-icon.d.ts.map +1 -0
- package/dist/components/chat/hooks/index.d.ts +10 -0
- package/dist/components/chat/hooks/index.d.ts.map +1 -1
- package/dist/components/chat/hooks/use-chat-attachment-image-gallery.d.ts +5 -0
- package/dist/components/chat/hooks/use-chat-attachment-image-gallery.d.ts.map +1 -0
- package/dist/components/chat/hooks/use-chat-attachments.d.ts +33 -0
- package/dist/components/chat/hooks/use-chat-attachments.d.ts.map +1 -0
- package/dist/components/chat/hooks/use-chat-card-item.d.ts +7 -0
- package/dist/components/chat/hooks/use-chat-card-item.d.ts.map +1 -0
- package/dist/components/chat/hooks/use-chat-identity.d.ts +44 -0
- package/dist/components/chat/hooks/use-chat-identity.d.ts.map +1 -0
- package/dist/components/chat/hooks/use-chat.d.ts +30 -0
- package/dist/components/chat/hooks/use-chat.d.ts.map +1 -0
- package/dist/components/chat/hooks/use-close-on-navigation.d.ts +2 -0
- package/dist/components/chat/hooks/use-close-on-navigation.d.ts.map +1 -0
- package/dist/components/chat/hooks/use-embedded-chat.d.ts +174 -0
- package/dist/components/chat/hooks/use-embedded-chat.d.ts.map +1 -0
- package/dist/components/chat/hooks/use-proxied-image-url.d.ts +18 -0
- package/dist/components/chat/hooks/use-proxied-image-url.d.ts.map +1 -0
- package/dist/components/chat/hooks/use-slash-commands.d.ts +32 -0
- package/dist/components/chat/hooks/use-slash-commands.d.ts.map +1 -0
- package/dist/components/chat/hooks/use-sse.d.ts +57 -0
- package/dist/components/chat/hooks/use-sse.d.ts.map +1 -0
- package/dist/components/chat/index.cjs +393 -0
- package/dist/components/chat/index.cjs.map +1 -0
- package/dist/components/chat/index.d.ts +5 -3
- package/dist/components/chat/index.d.ts.map +1 -1
- package/dist/components/chat/index.js +393 -0
- package/dist/components/chat/index.js.map +1 -0
- package/dist/components/chat/nav-link-anchor-via-runtime.d.ts +33 -0
- package/dist/components/chat/nav-link-anchor-via-runtime.d.ts.map +1 -0
- package/dist/components/chat/source-action-button.d.ts +39 -0
- package/dist/components/chat/source-action-button.d.ts.map +1 -0
- package/dist/components/chat/types/chat.types.d.ts +36 -0
- package/dist/components/chat/types/chat.types.d.ts.map +1 -1
- package/dist/components/chat/types/component.types.d.ts +56 -11
- package/dist/components/chat/types/component.types.d.ts.map +1 -1
- package/dist/components/chat/types/entities/blog.d.ts +14 -0
- package/dist/components/chat/types/entities/blog.d.ts.map +1 -0
- package/dist/components/chat/types/entities/case-study.d.ts +10 -0
- package/dist/components/chat/types/entities/case-study.d.ts.map +1 -0
- package/dist/components/chat/types/entities/content-ref.d.ts +23 -0
- package/dist/components/chat/types/entities/content-ref.d.ts.map +1 -0
- package/dist/components/chat/types/entities/customer-interview.d.ts +10 -0
- package/dist/components/chat/types/entities/customer-interview.d.ts.map +1 -0
- package/dist/components/chat/types/entities/data-room-doc.d.ts +37 -0
- package/dist/components/chat/types/entities/data-room-doc.d.ts.map +1 -0
- package/dist/components/chat/types/entities/github-activity.d.ts +29 -0
- package/dist/components/chat/types/entities/github-activity.d.ts.map +1 -0
- package/dist/components/chat/types/entities/hubspot-ticket.d.ts +39 -0
- package/dist/components/chat/types/entities/hubspot-ticket.d.ts.map +1 -0
- package/dist/components/chat/types/entities/index.d.ts +28 -0
- package/dist/components/chat/types/entities/index.d.ts.map +1 -0
- package/dist/components/chat/types/entities/investor-update.d.ts +83 -0
- package/dist/components/chat/types/entities/investor-update.d.ts.map +1 -0
- package/dist/components/chat/types/entities/onboarding-guide.d.ts +79 -0
- package/dist/components/chat/types/entities/onboarding-guide.d.ts.map +1 -0
- package/dist/components/chat/types/entities/program-types.d.ts +303 -0
- package/dist/components/chat/types/entities/program-types.d.ts.map +1 -0
- package/dist/components/chat/types/entities/roadmap-item.d.ts +41 -0
- package/dist/components/chat/types/entities/roadmap-item.d.ts.map +1 -0
- package/dist/components/chat/types/entities/slack-message.d.ts +28 -0
- package/dist/components/chat/types/entities/slack-message.d.ts.map +1 -0
- package/dist/components/chat/types/index.d.ts +1 -0
- package/dist/components/chat/types/index.d.ts.map +1 -1
- package/dist/components/chat/utils/agent-status-message.d.ts +18 -0
- package/dist/components/chat/utils/agent-status-message.d.ts.map +1 -0
- package/dist/components/chat/utils/auto-continuation-directive.d.ts +38 -0
- package/dist/components/chat/utils/auto-continuation-directive.d.ts.map +1 -0
- package/dist/components/chat/utils/chat-attachment-markdown.d.ts +114 -0
- package/dist/components/chat/utils/chat-attachment-markdown.d.ts.map +1 -0
- package/dist/components/chat/utils/chat-authed-fetch.d.ts +13 -0
- package/dist/components/chat/utils/chat-authed-fetch.d.ts.map +1 -0
- package/dist/components/chat/utils/chat-nav-resolution.d.ts +72 -0
- package/dist/components/chat/utils/chat-nav-resolution.d.ts.map +1 -0
- package/dist/components/chat/utils/chat-proxy-auth-storage.d.ts +43 -0
- package/dist/components/chat/utils/chat-proxy-auth-storage.d.ts.map +1 -0
- package/dist/components/chat/utils/chip-action-class.d.ts +16 -0
- package/dist/components/chat/utils/chip-action-class.d.ts.map +1 -0
- package/dist/components/chat/utils/chip-styles.d.ts +32 -0
- package/dist/components/chat/utils/chip-styles.d.ts.map +1 -0
- package/dist/components/chat/utils/clickup-task-type-utils.d.ts +38 -0
- package/dist/components/chat/utils/clickup-task-type-utils.d.ts.map +1 -0
- package/dist/components/chat/utils/compact-card-classes.d.ts +50 -0
- package/dist/components/chat/utils/compact-card-classes.d.ts.map +1 -0
- package/dist/components/chat/utils/decide-new-tab.d.ts +39 -0
- package/dist/components/chat/utils/decide-new-tab.d.ts.map +1 -0
- package/dist/components/chat/utils/external-app-urls.d.ts +14 -0
- package/dist/components/chat/utils/external-app-urls.d.ts.map +1 -0
- package/dist/components/chat/utils/flatten-assistant-content.d.ts +25 -0
- package/dist/components/chat/utils/flatten-assistant-content.d.ts.map +1 -0
- package/dist/components/chat/utils/icon-registry.d.ts +67 -0
- package/dist/components/chat/utils/icon-registry.d.ts.map +1 -0
- package/dist/components/chat/utils/index.d.ts +21 -0
- package/dist/components/chat/utils/index.d.ts.map +1 -1
- package/dist/components/chat/utils/is-cross-origin-url.d.ts +22 -0
- package/dist/components/chat/utils/is-cross-origin-url.d.ts.map +1 -0
- package/dist/components/chat/utils/nav-anchor-props.d.ts +54 -0
- package/dist/components/chat/utils/nav-anchor-props.d.ts.map +1 -0
- package/dist/components/chat/utils/nav-click-handler.d.ts +51 -0
- package/dist/components/chat/utils/nav-click-handler.d.ts.map +1 -0
- package/dist/components/chat/utils/scroll-anchor.d.ts +30 -0
- package/dist/components/chat/utils/scroll-anchor.d.ts.map +1 -0
- package/dist/components/chat/utils/slash-dispatch-utils.d.ts +109 -0
- package/dist/components/chat/utils/slash-dispatch-utils.d.ts.map +1 -0
- package/dist/components/chat/utils/source-icons.d.ts +8 -0
- package/dist/components/chat/utils/source-icons.d.ts.map +1 -0
- package/dist/components/chat/utils/source-row-cta.d.ts +111 -0
- package/dist/components/chat/utils/source-row-cta.d.ts.map +1 -0
- package/dist/components/features/figma-prototype-viewer.d.ts.map +1 -1
- package/dist/components/features/index.cjs +12 -6
- package/dist/components/features/index.cjs.map +1 -1
- package/dist/components/features/index.js +11 -5
- package/dist/components/features/video.d.ts.map +1 -1
- package/dist/components/icons/index.cjs +3 -3
- package/dist/components/icons/index.js +2 -2
- package/dist/components/index.cjs +274 -8
- package/dist/components/index.cjs.map +1 -1
- package/dist/components/index.js +273 -7
- package/dist/components/interactive-wrapper.d.ts +3 -3
- package/dist/components/navigation/index.cjs +12 -6
- package/dist/components/navigation/index.cjs.map +1 -1
- package/dist/components/navigation/index.js +11 -5
- package/dist/components/resizable.d.ts +1 -1
- package/dist/components/shared/product-release/product-release-card-skeleton.d.ts +1 -1
- package/dist/components/shared/product-release/product-release-card-skeleton.d.ts.map +1 -1
- package/dist/components/shared/product-release/product-release-card.d.ts +19 -12
- package/dist/components/shared/product-release/product-release-card.d.ts.map +1 -1
- package/dist/components/shared/product-release/release-detail-page.d.ts +2 -4
- package/dist/components/shared/product-release/release-detail-page.d.ts.map +1 -1
- package/dist/components/ui/button/button.d.ts +13 -0
- package/dist/components/ui/button/button.d.ts.map +1 -1
- package/dist/components/ui/dashboard-info-card.d.ts.map +1 -1
- package/dist/components/ui/entity-image.d.ts.map +1 -1
- package/dist/components/ui/file-manager/index.cjs +71 -70
- package/dist/components/ui/file-manager/index.cjs.map +1 -1
- package/dist/components/ui/file-manager/index.js +6 -5
- package/dist/components/ui/file-manager/index.js.map +1 -1
- package/dist/components/ui/hover-dropdown.d.ts +66 -0
- package/dist/components/ui/hover-dropdown.d.ts.map +1 -0
- package/dist/components/ui/index.cjs +276 -6
- package/dist/components/ui/index.cjs.map +1 -1
- package/dist/components/ui/index.d.ts +1 -0
- package/dist/components/ui/index.d.ts.map +1 -1
- package/dist/components/ui/index.js +278 -8
- package/dist/components/ui/simple-markdown-renderer.d.ts.map +1 -1
- package/dist/components/ui/square-avatar.d.ts.map +1 -1
- package/dist/contexts/chat-runtime-context.d.ts +109 -0
- package/dist/contexts/chat-runtime-context.d.ts.map +1 -0
- package/dist/contexts/endpoints-runtime-context.d.ts +28 -0
- package/dist/contexts/endpoints-runtime-context.d.ts.map +1 -0
- package/dist/contexts/index.cjs +30 -0
- package/dist/contexts/index.cjs.map +1 -0
- package/dist/contexts/index.d.ts +26 -0
- package/dist/contexts/index.d.ts.map +1 -0
- package/dist/contexts/index.js +30 -0
- package/dist/contexts/index.js.map +1 -0
- package/dist/contexts/use-outer-or-default.d.ts +29 -0
- package/dist/contexts/use-outer-or-default.d.ts.map +1 -0
- package/dist/embed-shims/index.cjs +51 -0
- package/dist/embed-shims/index.cjs.map +1 -0
- package/dist/embed-shims/index.d.ts +31 -0
- package/dist/embed-shims/index.d.ts.map +1 -0
- package/dist/embed-shims/index.js +51 -0
- package/dist/embed-shims/index.js.map +1 -0
- package/dist/embed-shims/next-dynamic.cjs +12 -0
- package/dist/embed-shims/next-dynamic.cjs.map +1 -0
- package/dist/embed-shims/next-dynamic.d.ts +47 -0
- package/dist/embed-shims/next-dynamic.d.ts.map +1 -0
- package/dist/embed-shims/next-dynamic.js +12 -0
- package/dist/embed-shims/next-dynamic.js.map +1 -0
- package/dist/embed-shims/next-image.cjs +12 -0
- package/dist/embed-shims/next-image.cjs.map +1 -0
- package/dist/embed-shims/next-image.d.ts +28 -0
- package/dist/embed-shims/next-image.d.ts.map +1 -0
- package/dist/embed-shims/next-image.js +12 -0
- package/dist/embed-shims/next-image.js.map +1 -0
- package/dist/embed-shims/next-link.cjs +14 -0
- package/dist/embed-shims/next-link.cjs.map +1 -0
- package/dist/embed-shims/next-link.d.ts +22 -0
- package/dist/embed-shims/next-link.d.ts.map +1 -0
- package/dist/embed-shims/next-link.js +14 -0
- package/dist/embed-shims/next-link.js.map +1 -0
- package/dist/embed-shims/next-navigation.cjs +30 -0
- package/dist/embed-shims/next-navigation.cjs.map +1 -0
- package/dist/embed-shims/next-navigation.d.ts +46 -0
- package/dist/embed-shims/next-navigation.d.ts.map +1 -0
- package/dist/embed-shims/next-navigation.js +30 -0
- package/dist/embed-shims/next-navigation.js.map +1 -0
- package/dist/hooks/index.cjs +10 -4
- package/dist/hooks/index.cjs.map +1 -1
- package/dist/hooks/index.d.ts +2 -0
- package/dist/hooks/index.d.ts.map +1 -1
- package/dist/hooks/index.js +9 -3
- package/dist/hooks/use-access-code-integration.d.ts +48 -0
- package/dist/hooks/use-access-code-integration.d.ts.map +1 -0
- package/dist/hooks/use-contact-submission.d.ts.map +1 -1
- package/dist/hooks/use-og-placeholder.d.ts +31 -0
- package/dist/hooks/use-og-placeholder.d.ts.map +1 -0
- package/dist/hooks/use-toast.d.ts +1 -1
- package/dist/index.cjs +367 -7
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +378 -18
- package/dist/types/index.cjs.map +1 -1
- package/dist/types/index.js.map +1 -1
- package/dist/utils/access-code-client.d.ts +21 -37
- package/dist/utils/access-code-client.d.ts.map +1 -1
- package/dist/utils/cn.d.ts +0 -27
- package/dist/utils/cn.d.ts.map +1 -1
- package/dist/utils/color-analysis.d.ts +33 -0
- package/dist/utils/color-analysis.d.ts.map +1 -0
- package/dist/utils/date-formatters.d.ts +16 -5
- package/dist/utils/date-formatters.d.ts.map +1 -1
- package/dist/utils/fetch-priority.d.ts +3 -0
- package/dist/utils/fetch-priority.d.ts.map +1 -0
- package/dist/utils/format.d.ts +192 -1
- package/dist/utils/format.d.ts.map +1 -1
- package/dist/utils/image-proxy.d.ts +67 -2
- package/dist/utils/image-proxy.d.ts.map +1 -1
- package/dist/utils/index.cjs +1274 -155
- package/dist/utils/index.cjs.map +1 -1
- package/dist/utils/index.d.ts +19 -3
- package/dist/utils/index.d.ts.map +1 -1
- package/dist/utils/index.js +1200 -157
- package/dist/utils/index.js.map +1 -1
- package/dist/utils/local-storage-adapter.d.ts +46 -0
- package/dist/utils/local-storage-adapter.d.ts.map +1 -0
- package/dist/utils/source-icons.d.ts +78 -0
- package/dist/utils/source-icons.d.ts.map +1 -0
- package/package.json +29 -2
- package/src/components/announcement-bar.tsx +26 -4
- package/src/components/categories-cart.tsx +1 -1
- package/src/components/chat/chat-attachment-bar.tsx +323 -0
- package/src/components/chat/chat-container.tsx +39 -5
- package/src/components/chat/chat-input.tsx +7 -1
- package/src/components/chat/chat-message-enhanced.tsx +32 -22
- package/src/components/chat/chat-message-list.tsx +53 -4
- package/src/components/chat/chat-panel-context.tsx +37 -0
- package/src/components/chat/chat-ticket-list.tsx +1 -1
- package/src/components/chat/embeddable-chat.tsx +1106 -0
- package/src/components/chat/entity-cards/admin-content-card.tsx +155 -0
- package/src/components/chat/entity-cards/blog-card.tsx +259 -0
- package/src/components/chat/entity-cards/blog-image-placeholder.tsx +52 -0
- package/src/components/chat/entity-cards/campaign-card-admin.tsx +113 -0
- package/src/components/chat/entity-cards/case-study-card.tsx +192 -0
- package/src/components/chat/{chat-ticket-item.tsx → entity-cards/chat-ticket-item.tsx} +2 -2
- package/src/components/chat/{chat-video-entity-card.tsx → entity-cards/chat-video-entity-card.tsx} +2 -2
- package/src/components/chat/entity-cards/customer-interview-card.tsx +211 -0
- package/src/components/chat/entity-cards/data-room-doc-card.tsx +120 -0
- package/src/components/chat/entity-cards/dispatch.tsx +1093 -0
- package/src/components/chat/entity-cards/entity-author-card.tsx +193 -0
- package/src/components/chat/entity-cards/generic-entity-card.tsx +144 -0
- package/src/components/chat/entity-cards/github-activity-card.tsx +305 -0
- package/src/components/chat/entity-cards/hubspot-ticket-card.tsx +205 -0
- package/src/components/chat/entity-cards/index.ts +125 -0
- package/src/components/chat/entity-cards/investor-update-card.tsx +150 -0
- package/src/components/chat/entity-cards/onboarding-guide-card.tsx +326 -0
- package/src/components/chat/entity-cards/product-release-card-defaults.ts +57 -0
- package/src/components/chat/entity-cards/product-release-card.tsx +19 -0
- package/src/components/chat/entity-cards/program-card-defaults.ts +62 -0
- package/src/components/chat/entity-cards/program-card.tsx +451 -0
- package/src/components/chat/entity-cards/roadmap-card.tsx +356 -0
- package/src/components/chat/entity-cards/roadmap-vote-button.tsx +54 -0
- package/src/components/chat/entity-cards/slack-message-card.tsx +182 -0
- package/src/components/chat/entity-cards/task-type-icon.tsx +60 -0
- package/src/components/chat/hooks/index.ts +22 -0
- package/src/components/chat/hooks/use-chat-attachment-image-gallery.tsx +114 -0
- package/src/components/chat/hooks/use-chat-attachments.ts +429 -0
- package/src/components/chat/hooks/use-chat-card-item.ts +102 -0
- package/src/components/chat/hooks/use-chat-identity.ts +139 -0
- package/src/components/chat/hooks/use-chat.ts +501 -0
- package/src/components/chat/hooks/use-close-on-navigation.ts +87 -0
- package/src/components/chat/hooks/use-embedded-chat.ts +1023 -0
- package/src/components/chat/hooks/use-proxied-image-url.ts +31 -0
- package/src/components/chat/hooks/use-slash-commands.ts +106 -0
- package/src/components/chat/hooks/use-sse.ts +143 -0
- package/src/components/chat/index.ts +30 -4
- package/src/components/chat/nav-link-anchor-via-runtime.tsx +72 -0
- package/src/components/chat/source-action-button.tsx +120 -0
- package/src/components/chat/types/chat.types.ts +61 -0
- package/src/components/chat/types/component.types.ts +57 -11
- package/src/components/chat/types/entities/blog.ts +27 -0
- package/src/components/chat/types/entities/case-study.ts +14 -0
- package/src/components/chat/types/entities/content-ref.ts +23 -0
- package/src/components/chat/types/entities/customer-interview.ts +15 -0
- package/src/components/chat/types/entities/data-room-doc.ts +37 -0
- package/src/components/chat/types/entities/github-activity.ts +36 -0
- package/src/components/chat/types/entities/hubspot-ticket.ts +39 -0
- package/src/components/chat/types/entities/index.ts +28 -0
- package/src/components/chat/types/entities/investor-update.ts +100 -0
- package/src/components/chat/types/entities/onboarding-guide.ts +101 -0
- package/src/components/chat/types/entities/program-types.ts +433 -0
- package/src/components/chat/types/entities/roadmap-item.ts +42 -0
- package/src/components/chat/types/entities/slack-message.ts +28 -0
- package/src/components/chat/types/index.ts +1 -0
- package/src/components/chat/utils/agent-status-message.ts +52 -0
- package/src/components/chat/utils/auto-continuation-directive.ts +70 -0
- package/src/components/chat/utils/chat-attachment-markdown.ts +190 -0
- package/src/components/chat/utils/chat-authed-fetch.ts +73 -0
- package/src/components/chat/utils/chat-nav-resolution.ts +151 -0
- package/src/components/chat/utils/chat-proxy-auth-storage.ts +148 -0
- package/src/components/chat/utils/chip-action-class.ts +19 -0
- package/src/components/chat/utils/chip-styles.ts +51 -0
- package/src/components/chat/utils/clickup-task-type-utils.ts +59 -0
- package/src/components/chat/utils/compact-card-classes.ts +97 -0
- package/src/components/chat/utils/decide-new-tab.ts +57 -0
- package/src/components/chat/utils/external-app-urls.ts +19 -0
- package/src/components/chat/utils/flatten-assistant-content.ts +35 -0
- package/src/components/chat/utils/icon-registry.ts +297 -0
- package/src/components/chat/utils/index.ts +133 -0
- package/src/components/chat/utils/is-cross-origin-url.ts +28 -0
- package/src/components/chat/utils/nav-anchor-props.ts +78 -0
- package/src/components/chat/utils/nav-click-handler.ts +81 -0
- package/src/components/chat/utils/scroll-anchor.ts +35 -0
- package/src/components/chat/utils/slash-dispatch-utils.ts +183 -0
- package/src/components/chat/utils/source-icons.ts +14 -0
- package/src/components/chat/utils/source-row-cta.ts +215 -0
- package/src/components/empty-state.tsx +1 -1
- package/src/components/features/board/ticket-card.tsx +1 -1
- package/src/components/features/figma-prototype-viewer.tsx +2 -1
- package/src/components/features/media-gallery-manager.tsx +1 -1
- package/src/components/features/parallax-image-showcase.tsx +1 -1
- package/src/components/features/release-media-manager.tsx +1 -1
- package/src/components/features/seo-editor-preview.tsx +1 -1
- package/src/components/features/video.tsx +54 -3
- package/src/components/footer-waitlist-button.tsx +1 -1
- package/src/components/navigation/header.tsx +1 -1
- package/src/components/shared/onboarding/onboarding-step-card.tsx +1 -1
- package/src/components/shared/product-release/product-release-card-skeleton.tsx +8 -44
- package/src/components/shared/product-release/product-release-card.tsx +31 -116
- package/src/components/shared/product-release/release-detail-page.tsx +12 -16
- package/src/components/ui/actions-menu.tsx +1 -1
- package/src/components/ui/button/button.tsx +41 -11
- package/src/components/ui/button/split-button.tsx +1 -1
- package/src/components/ui/dashboard-info-card.tsx +2 -3
- package/src/components/ui/data-table/data-table-row.tsx +1 -1
- package/src/components/ui/entity-image.tsx +2 -8
- package/src/components/ui/hover-dropdown.tsx +258 -0
- package/src/components/ui/image-gallery-modal.tsx +1 -1
- package/src/components/ui/index.ts +1 -0
- package/src/components/ui/markdown-editor.tsx +1 -1
- package/src/components/ui/more-actions-menu.tsx +1 -1
- package/src/components/ui/organization-card.tsx +1 -1
- package/src/components/ui/simple-markdown-renderer.tsx +53 -5
- package/src/components/ui/square-avatar.tsx +3 -12
- package/src/components/ui/tab-navigation.tsx +1 -1
- package/src/components/ui/table/table-row.tsx +1 -1
- package/src/components/unified-filter-logic.tsx +1 -1
- package/src/components/unified-pagination.tsx +1 -1
- package/src/components/user-summary-stub.tsx +1 -1
- package/src/components/vendor-display-button.tsx +1 -1
- package/src/components/vendor-icon.tsx +1 -1
- package/src/contexts/chat-runtime-context.tsx +163 -0
- package/src/contexts/endpoints-runtime-context.tsx +68 -0
- package/src/contexts/index.ts +38 -0
- package/src/contexts/use-outer-or-default.ts +42 -0
- package/src/embed-shims/index.ts +42 -0
- package/src/embed-shims/next-dynamic.tsx +70 -0
- package/src/embed-shims/next-image.tsx +114 -0
- package/src/embed-shims/next-link.tsx +91 -0
- package/src/embed-shims/next-navigation.tsx +201 -0
- package/src/hooks/index.ts +9 -0
- package/src/hooks/state/use-api-params.ts +1 -1
- package/src/hooks/state/use-query-params.ts +1 -1
- package/src/hooks/use-access-code-integration.ts +107 -0
- package/src/hooks/use-contact-submission.ts +7 -3
- package/src/hooks/use-og-placeholder.ts +45 -0
- package/src/stories/OnboardingStepCard.stories.tsx +140 -0
- package/src/styles/chat-animations.css +65 -0
- package/src/styles/index.css +1 -0
- package/src/utils/access-code-client.ts +32 -75
- package/src/utils/cn.ts +0 -65
- package/src/utils/color-analysis.ts +205 -0
- package/src/utils/date-formatters.ts +54 -11
- package/src/utils/fetch-priority.ts +41 -0
- package/src/utils/format.ts +525 -1
- package/src/utils/image-proxy.ts +127 -7
- package/src/utils/index.ts +145 -5
- package/src/utils/local-storage-adapter.ts +105 -0
- package/src/utils/source-icons.ts +219 -0
- package/dist/chunk-25LVV26X.cjs.map +0 -1
- package/dist/chunk-ARQ4XP64.cjs.map +0 -1
- package/dist/chunk-CPXLQ57U.js.map +0 -1
- package/dist/chunk-LY34ORX6.js.map +0 -1
- package/dist/chunk-RMB5DVED.cjs.map +0 -1
- package/dist/chunk-SZPJ5R5B.js.map +0 -1
- package/dist/chunk-UC43NICZ.cjs.map +0 -1
- package/dist/chunk-XGL5FKIK.js.map +0 -1
- package/dist/components/chat/block-card.d.ts.map +0 -1
- package/dist/components/chat/chat-ticket-item.d.ts.map +0 -1
- package/dist/components/chat/chat-video-entity-card.d.ts.map +0 -1
- package/dist/utils/dynamic-icons.d.ts +0 -26
- package/dist/utils/dynamic-icons.d.ts.map +0 -1
- package/dist/utils/format-relative-time.d.ts +0 -21
- package/dist/utils/format-relative-time.d.ts.map +0 -1
- package/src/utils/.dynamic-icons.md +0 -30
- package/src/utils/.format-relative-time.md +0 -36
- package/src/utils/dynamic-icons.tsx +0 -120
- package/src/utils/format-relative-time.ts +0 -52
- /package/dist/{chunk-N57KWHDB.js.map → chunk-CIPO6DXK.js.map} +0 -0
- /package/dist/components/chat/{block-card.d.ts → entity-cards/block-card.d.ts} +0 -0
- /package/dist/components/chat/{chat-ticket-item.d.ts → entity-cards/chat-ticket-item.d.ts} +0 -0
- /package/src/components/chat/{block-card.tsx → entity-cards/block-card.tsx} +0 -0
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Runtime config consumed by the chat panel.
|
|
3
|
+
*/
|
|
4
|
+
export interface ChatRuntime {
|
|
5
|
+
endpoints: {
|
|
6
|
+
/** POST streaming chat. Hub: '/api/docs/chat'. */
|
|
7
|
+
chatStreamUrl: string;
|
|
8
|
+
/** POST agent approve/reject. Hub: '/api/chat/agent/confirm-tool'. */
|
|
9
|
+
approvalToolUrl: string;
|
|
10
|
+
/** GET slash-command catalog. Hub: '/api/docs/commands'. */
|
|
11
|
+
commandsUrl: string;
|
|
12
|
+
/** Build entity-card list URL for a content type + ids. Hub delegates
|
|
13
|
+
* to the rag-table-config registry; embedded app provides its own
|
|
14
|
+
* per-type URL builder against the reverse proxy. Returns null when
|
|
15
|
+
* the type has no list endpoint (caller skips rendering). */
|
|
16
|
+
buildListUrl: (type: string, ids: string[]) => string | null;
|
|
17
|
+
/** Chat-attachment endpoints — added for the v2 attachment feature.
|
|
18
|
+
*
|
|
19
|
+
* Three concerns:
|
|
20
|
+
* - `attachmentUploadUrl` — POSTed by the chat-attachment hook
|
|
21
|
+
* to mint a Supabase signed-upload-URL + HMAC view token.
|
|
22
|
+
* - `attachmentViewUrlPrefix` — embedded in markdown URLs the
|
|
23
|
+
* chat hosts in user message bubbles (`![]()` / `[Attached]`).
|
|
24
|
+
* Stored in chat history; chosen at SEND time. In host mode the
|
|
25
|
+
* relative `/api/storage/view/chat-attachments/` is sufficient
|
|
26
|
+
* (same-origin); embedders supply an absolute hub URL so the
|
|
27
|
+
* browser can fetch cross-origin.
|
|
28
|
+
* - `chatIdentityUrl` — GET endpoint the `useChatIdentity` hook
|
|
29
|
+
* hits to learn the `{authTier, source, attachmentsEnabled}`
|
|
30
|
+
* capability bag for the current session. */
|
|
31
|
+
attachmentUploadUrl: string;
|
|
32
|
+
attachmentViewUrlPrefix: string;
|
|
33
|
+
chatIdentityUrl: string;
|
|
34
|
+
/** Optional URL prefix for the image proxy (`<prefix>?url=<external>`).
|
|
35
|
+
* When unset, lib's `getProxiedImageUrl` returns the original URL
|
|
36
|
+
* unchanged. Hub default: '/api/image-proxy'. Embedders that don't
|
|
37
|
+
* host an image-proxy route leave this undefined → images load
|
|
38
|
+
* directly cross-origin (CORS-permitting). */
|
|
39
|
+
imageProxyUrlPrefix?: string;
|
|
40
|
+
/** Optional list of hostnames that should bypass the image proxy
|
|
41
|
+
* (rendered direct). Hub uses ['openmsp.ai']; embedders typically
|
|
42
|
+
* leave it unset. Matches the `skipDomains` parameter of
|
|
43
|
+
* `getProxiedImageUrl`. */
|
|
44
|
+
imageProxySkipDomains?: string[];
|
|
45
|
+
};
|
|
46
|
+
navigation: {
|
|
47
|
+
/** ONE knob, two behaviors:
|
|
48
|
+
* - 'host' = use the host page's existing click-routing untouched.
|
|
49
|
+
* The chat panel calls `navigate?.()` for in-app routing.
|
|
50
|
+
* - 'embed' = guest inside another app: short-circuit at the top
|
|
51
|
+
* of click handlers to force new-tab + absolutize via
|
|
52
|
+
* resolveExternalNavigation. */
|
|
53
|
+
mode: 'host' | 'embed';
|
|
54
|
+
/** Embed-only fallback origin for relative URLs whose target platform
|
|
55
|
+
* can't be inferred. Used by resolveExternalNavigation when
|
|
56
|
+
* `targetPlatform` is null — without this, a relative `/foo` href would
|
|
57
|
+
* window.open against the embedder's origin, which is WRONG.
|
|
58
|
+
* Set to your content host (e.g. 'https://hub.openframe.ai').
|
|
59
|
+
* Required by the embedded app whenever mode='embed'. */
|
|
60
|
+
defaultContentOrigin?: string;
|
|
61
|
+
/** Override for opening external URLs. MUST BE SYNCHRONOUS —
|
|
62
|
+
* Safari/Firefox block popups opened outside a direct user gesture.
|
|
63
|
+
* Default: window.open(href, '_blank', 'noopener,noreferrer'). */
|
|
64
|
+
openExternal?: (href: string) => void;
|
|
65
|
+
/** Optional in-app navigation callback (host-mode only).
|
|
66
|
+
* Returns `true` if the host handled the click in-app
|
|
67
|
+
* (router.push + docNav.navigate); returns `false`, `undefined`,
|
|
68
|
+
* or `void` → lib falls back to window.location.assign(href).
|
|
69
|
+
* Hub wires this via HubRuntimeProvider's HubNavigationWiring;
|
|
70
|
+
* embedders not in Next.js leave it undefined. */
|
|
71
|
+
navigate?: (input: {
|
|
72
|
+
href: string;
|
|
73
|
+
path?: string | null;
|
|
74
|
+
targetPlatform?: string | null;
|
|
75
|
+
}) => boolean | void;
|
|
76
|
+
/** Optional new-tab decision callback. Returns true → lib opens in
|
|
77
|
+
* new tab; false → same tab via `navigate`. Hub wires the existing
|
|
78
|
+
* `decideNewTab` logic from use-nav-link.tsx (re-imports the pure
|
|
79
|
+
* helper from lib). Embedders may omit; lib defaults to:
|
|
80
|
+
* same-origin/same-platform → same tab, else new tab. */
|
|
81
|
+
decideNewTab?: (args: {
|
|
82
|
+
href: string;
|
|
83
|
+
targetPlatform?: string | null;
|
|
84
|
+
}) => boolean;
|
|
85
|
+
};
|
|
86
|
+
/** Chat source identifier — REQUIRED. Used for localStorage
|
|
87
|
+
* namespacing (`mingo-chat-<source>-v1`). Hub sets via
|
|
88
|
+
* `currentPlatform()`; embedders set explicitly.
|
|
89
|
+
* `useEmbeddedChat()` throws if source is empty/missing. */
|
|
90
|
+
source: string;
|
|
91
|
+
}
|
|
92
|
+
export declare const ChatRuntimeContext: import("react").Context<ChatRuntime | null>;
|
|
93
|
+
/**
|
|
94
|
+
* Returns the active runtime, or null when no provider is mounted.
|
|
95
|
+
* NULL is a first-class value — it signals "no chat runtime configured."
|
|
96
|
+
* Optional consumers fall back to no-op behavior; strict consumers
|
|
97
|
+
* use `useRequiredChatRuntime` (below).
|
|
98
|
+
*/
|
|
99
|
+
export declare function useChatRuntime(): ChatRuntime | null;
|
|
100
|
+
/**
|
|
101
|
+
* Strict variant used INSIDE the chat panel. Throws if no provider.
|
|
102
|
+
* The hub guarantees one exists by mounting `<HubRuntimeProvider>` at
|
|
103
|
+
* root; the embedded app mounts its own `<ChatRuntimeContext.Provider>`
|
|
104
|
+
* at the tree root. In Jest / Storybook tests that render chat
|
|
105
|
+
* internals directly, wrap with `<HubRuntimeProvider>` (hub defaults)
|
|
106
|
+
* or supply `<ChatRuntimeContext.Provider value={mockedRuntime}>`.
|
|
107
|
+
*/
|
|
108
|
+
export declare function useRequiredChatRuntime(): ChatRuntime;
|
|
109
|
+
//# sourceMappingURL=chat-runtime-context.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"chat-runtime-context.d.ts","sourceRoot":"","sources":["../../src/contexts/chat-runtime-context.tsx"],"names":[],"mappings":"AAqCA;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,SAAS,EAAE;QACT,kDAAkD;QAClD,aAAa,EAAE,MAAM,CAAA;QACrB,sEAAsE;QACtE,eAAe,EAAE,MAAM,CAAA;QACvB,4DAA4D;QAC5D,WAAW,EAAE,MAAM,CAAA;QACnB;;;sEAG8D;QAC9D,YAAY,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,EAAE,KAAK,MAAM,GAAG,IAAI,CAAA;QAC5D;;;;;;;;;;;;;0DAakD;QAClD,mBAAmB,EAAE,MAAM,CAAA;QAC3B,uBAAuB,EAAE,MAAM,CAAA;QAC/B,eAAe,EAAE,MAAM,CAAA;QACvB;;;;uDAI+C;QAC/C,mBAAmB,CAAC,EAAE,MAAM,CAAA;QAC5B;;;oCAG4B;QAC5B,qBAAqB,CAAC,EAAE,MAAM,EAAE,CAAA;KACjC,CAAA;IACD,UAAU,EAAE;QACV;;;;;2CAKmC;QACnC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAA;QACtB;;;;;kEAK0D;QAC1D,oBAAoB,CAAC,EAAE,MAAM,CAAA;QAC7B;;2EAEmE;QACnE,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAA;QACrC;;;;;2DAKmD;QACnD,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE;YAAE,IAAI,EAAE,MAAM,CAAC;YAAC,IAAI,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;YAAC,cAAc,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;SAAE,KAAK,OAAO,GAAG,IAAI,CAAA;QAC5G;;;;kEAI0D;QAC1D,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE;YAAE,IAAI,EAAE,MAAM,CAAC;YAAC,cAAc,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;SAAE,KAAK,OAAO,CAAA;KACnF,CAAA;IACD;;;iEAG6D;IAC7D,MAAM,EAAE,MAAM,CAAA;CAQf;AAED,eAAO,MAAM,kBAAkB,6CAA0C,CAAA;AAEzE;;;;;GAKG;AACH,wBAAgB,cAAc,IAAI,WAAW,GAAG,IAAI,CAEnD;AAED;;;;;;;GAOG;AACH,wBAAgB,sBAAsB,IAAI,WAAW,CAapD"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
export interface EndpointsRuntime {
|
|
2
|
+
/** GET active announcement (used by `<AnnouncementBar>` polling). */
|
|
3
|
+
announcementsUrl: string;
|
|
4
|
+
accessCode: {
|
|
5
|
+
/** POST validate access code. */
|
|
6
|
+
validateUrl: string;
|
|
7
|
+
/** POST consume / redeem access code after registration. */
|
|
8
|
+
consumeUrl: string;
|
|
9
|
+
};
|
|
10
|
+
/** POST contact-form submission. */
|
|
11
|
+
contactUrl: string;
|
|
12
|
+
}
|
|
13
|
+
export declare const EndpointsRuntimeContext: import("react").Context<EndpointsRuntime | null>;
|
|
14
|
+
/**
|
|
15
|
+
* Optional read — returns null when no provider is mounted. Use for
|
|
16
|
+
* surfaces that should silently skip the fetch (e.g. announcement
|
|
17
|
+
* polling on a page rendered outside the provider tree).
|
|
18
|
+
*/
|
|
19
|
+
export declare function useEndpointsRuntime(): EndpointsRuntime | null;
|
|
20
|
+
/**
|
|
21
|
+
* Strict variant — throws on missing provider. Use for consumers that
|
|
22
|
+
* cannot function without an endpoint (form submission, code
|
|
23
|
+
* validation). In tests/Storybook, wrap with the hub's
|
|
24
|
+
* `<HubRuntimeProvider>` or a stub
|
|
25
|
+
* `<EndpointsRuntimeContext.Provider value={mockedEndpoints}>`.
|
|
26
|
+
*/
|
|
27
|
+
export declare function useRequiredEndpointsRuntime(): EndpointsRuntime;
|
|
28
|
+
//# sourceMappingURL=endpoints-runtime-context.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"endpoints-runtime-context.d.ts","sourceRoot":"","sources":["../../src/contexts/endpoints-runtime-context.tsx"],"names":[],"mappings":"AAyBA,MAAM,WAAW,gBAAgB;IAC/B,qEAAqE;IACrE,gBAAgB,EAAE,MAAM,CAAA;IACxB,UAAU,EAAE;QACV,iCAAiC;QACjC,WAAW,EAAE,MAAM,CAAA;QACnB,4DAA4D;QAC5D,UAAU,EAAE,MAAM,CAAA;KACnB,CAAA;IACD,oCAAoC;IACpC,UAAU,EAAE,MAAM,CAAA;CACnB;AAED,eAAO,MAAM,uBAAuB,kDAA+C,CAAA;AAEnF;;;;GAIG;AACH,wBAAgB,mBAAmB,IAAI,gBAAgB,GAAG,IAAI,CAE7D;AAED;;;;;;GAMG;AACH,wBAAgB,2BAA2B,IAAI,gBAAgB,CAW9D"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } }"use client";
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
var _chunk6RZYJICVcjs = require('../chunk-6RZYJICV.cjs');
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
var _chunk27APPAJNcjs = require('../chunk-27APPAJN.cjs');
|
|
12
|
+
require('../chunk-VRHGVLSL.cjs');
|
|
13
|
+
|
|
14
|
+
// src/contexts/use-outer-or-default.ts
|
|
15
|
+
var _react = require('react');
|
|
16
|
+
function useOuterOrDefault(context, factory, deps = []) {
|
|
17
|
+
const outer = _react.useContext.call(void 0, context);
|
|
18
|
+
const fallback = _react.useMemo.call(void 0, factory, deps);
|
|
19
|
+
return _nullishCoalesce(outer, () => ( fallback));
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
exports.ChatRuntimeContext = _chunk6RZYJICVcjs.ChatRuntimeContext; exports.EndpointsRuntimeContext = _chunk27APPAJNcjs.EndpointsRuntimeContext; exports.useChatRuntime = _chunk6RZYJICVcjs.useChatRuntime; exports.useEndpointsRuntime = _chunk27APPAJNcjs.useEndpointsRuntime; exports.useOuterOrDefault = useOuterOrDefault; exports.useRequiredChatRuntime = _chunk6RZYJICVcjs.useRequiredChatRuntime; exports.useRequiredEndpointsRuntime = _chunk27APPAJNcjs.useRequiredEndpointsRuntime;
|
|
30
|
+
//# sourceMappingURL=index.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["/home/runner/work/openframe-oss-lib/openframe-oss-lib/openframe-frontend-core/dist/contexts/index.cjs","../../src/contexts/use-outer-or-default.ts"],"names":[],"mappings":"AAAA,yLAAY;AACZ;AACE;AACA;AACA;AACF,yDAA8B;AAC9B;AACE;AACA;AACA;AACF,yDAA8B;AAC9B,iCAA8B;AAC9B;AACA;ACgBA,8BAAkD;AAE3C,SAAS,iBAAA,CACd,OAAA,EACA,OAAA,EACA,KAAA,EAA+B,CAAC,CAAA,EAC7B;AACH,EAAA,MAAM,MAAA,EAAQ,+BAAA,OAAkB,CAAA;AAGhC,EAAA,MAAM,SAAA,EAAW,4BAAA,OAAQ,EAAS,IAAI,CAAA;AACtC,EAAA,wBAAO,KAAA,UAAS,UAAA;AAClB;ADrBA;AACE;AACA;AACA;AACA;AACA;AACA;AACA;AACF,8dAAC","file":"/home/runner/work/openframe-oss-lib/openframe-oss-lib/openframe-frontend-core/dist/contexts/index.cjs","sourcesContent":[null,"'use client'\n\n/**\n * Outer-forward provider helper — used by hub + embedder providers\n * that supply default runtime values while allowing OUTER providers\n * to override.\n *\n * When an embedder mounts an outer `<ChatRuntimeContext.Provider>`\n * (or `<EndpointsRuntimeContext.Provider>`) ABOVE the hub provider,\n * the outer value wins. When no outer is mounted, the hub provider\n * supplies its `factory()` default. Tree shape stays constant —\n * same provider element at the same position regardless of outer\n * presence — so consumers below never remount when an embedder\n * toggles their providers at runtime.\n *\n * `deps` controls factory memoization:\n * - Empty `[]` (default) → factory runs ONCE per mount; safe ONLY\n * when factory closes over module-scope/constant values.\n * - Non-empty → factory re-runs when deps change. Use when the\n * factory closes over callbacks or other reactive values\n * (e.g. hub's ChatRuntime which includes `navigate` +\n * `decideNewTab` callbacks that depend on router + docNav).\n *\n * Returning the SAME reference across renders is critical for\n * downstream `useMemo` consumers. With empty deps, identity is\n * trivially stable. With reactive deps, the caller must memoize\n * the deps themselves (typically via `useCallback`).\n */\n\nimport { useContext, useMemo, type Context } from 'react'\n\nexport function useOuterOrDefault<T>(\n context: Context<T | null>,\n factory: () => T,\n deps: ReadonlyArray<unknown> = [],\n): T {\n const outer = useContext(context)\n // eslint-disable-next-line react-hooks/exhaustive-deps -- deps are the contract;\n // factory identity is intentionally ignored (caller controls re-creation via deps).\n const fallback = useMemo(factory, deps)\n return outer ?? fallback\n}\n"]}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Runtime contexts for embeddable oss-lib components.
|
|
3
|
+
*
|
|
4
|
+
* BUNDLE-SPLIT CONVENTION — read before adding new files here:
|
|
5
|
+
* Every module in `src/contexts/` calls `createContext()` at module
|
|
6
|
+
* top level. The tsup config builds this directory under the CLIENT
|
|
7
|
+
* bundle (with `"use client"` banner). Importing anything from here
|
|
8
|
+
* into a SERVER-bundled module (`utils/index.ts` and its `export *`
|
|
9
|
+
* transitive closure) crashes SSR with
|
|
10
|
+
* `createContext is not a function`.
|
|
11
|
+
*
|
|
12
|
+
* Rule of thumb when adding a runtime-aware helper:
|
|
13
|
+
* - Pure functions that take endpoints/runtime as args → `utils/`.
|
|
14
|
+
* - React hooks that READ the runtime via useContext → `hooks/`
|
|
15
|
+
* (with `'use client'` at the top of the file).
|
|
16
|
+
* - Never re-export from `utils/*` anything that pulls
|
|
17
|
+
* `src/contexts/*` transitively.
|
|
18
|
+
*
|
|
19
|
+
* The split between `utils/access-code-client.ts` (pure) and
|
|
20
|
+
* `hooks/use-access-code-integration.ts` (runtime-aware) is the
|
|
21
|
+
* reference example.
|
|
22
|
+
*/
|
|
23
|
+
export { EndpointsRuntimeContext, useEndpointsRuntime, useRequiredEndpointsRuntime, type EndpointsRuntime, } from './endpoints-runtime-context';
|
|
24
|
+
export { ChatRuntimeContext, useChatRuntime, useRequiredChatRuntime, type ChatRuntime, } from './chat-runtime-context';
|
|
25
|
+
export { useOuterOrDefault } from './use-outer-or-default';
|
|
26
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/contexts/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,EACL,uBAAuB,EACvB,mBAAmB,EACnB,2BAA2B,EAC3B,KAAK,gBAAgB,GACtB,MAAM,6BAA6B,CAAA;AAEpC,OAAO,EACL,kBAAkB,EAClB,cAAc,EACd,sBAAsB,EACtB,KAAK,WAAW,GACjB,MAAM,wBAAwB,CAAA;AAE/B,OAAO,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAA"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import {
|
|
3
|
+
ChatRuntimeContext,
|
|
4
|
+
useChatRuntime,
|
|
5
|
+
useRequiredChatRuntime
|
|
6
|
+
} from "../chunk-7L4DWM7P.js";
|
|
7
|
+
import {
|
|
8
|
+
EndpointsRuntimeContext,
|
|
9
|
+
useEndpointsRuntime,
|
|
10
|
+
useRequiredEndpointsRuntime
|
|
11
|
+
} from "../chunk-MJNXIEV2.js";
|
|
12
|
+
import "../chunk-GGWZFCYS.js";
|
|
13
|
+
|
|
14
|
+
// src/contexts/use-outer-or-default.ts
|
|
15
|
+
import { useContext, useMemo } from "react";
|
|
16
|
+
function useOuterOrDefault(context, factory, deps = []) {
|
|
17
|
+
const outer = useContext(context);
|
|
18
|
+
const fallback = useMemo(factory, deps);
|
|
19
|
+
return outer ?? fallback;
|
|
20
|
+
}
|
|
21
|
+
export {
|
|
22
|
+
ChatRuntimeContext,
|
|
23
|
+
EndpointsRuntimeContext,
|
|
24
|
+
useChatRuntime,
|
|
25
|
+
useEndpointsRuntime,
|
|
26
|
+
useOuterOrDefault,
|
|
27
|
+
useRequiredChatRuntime,
|
|
28
|
+
useRequiredEndpointsRuntime
|
|
29
|
+
};
|
|
30
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/contexts/use-outer-or-default.ts"],"sourcesContent":["'use client'\n\n/**\n * Outer-forward provider helper — used by hub + embedder providers\n * that supply default runtime values while allowing OUTER providers\n * to override.\n *\n * When an embedder mounts an outer `<ChatRuntimeContext.Provider>`\n * (or `<EndpointsRuntimeContext.Provider>`) ABOVE the hub provider,\n * the outer value wins. When no outer is mounted, the hub provider\n * supplies its `factory()` default. Tree shape stays constant —\n * same provider element at the same position regardless of outer\n * presence — so consumers below never remount when an embedder\n * toggles their providers at runtime.\n *\n * `deps` controls factory memoization:\n * - Empty `[]` (default) → factory runs ONCE per mount; safe ONLY\n * when factory closes over module-scope/constant values.\n * - Non-empty → factory re-runs when deps change. Use when the\n * factory closes over callbacks or other reactive values\n * (e.g. hub's ChatRuntime which includes `navigate` +\n * `decideNewTab` callbacks that depend on router + docNav).\n *\n * Returning the SAME reference across renders is critical for\n * downstream `useMemo` consumers. With empty deps, identity is\n * trivially stable. With reactive deps, the caller must memoize\n * the deps themselves (typically via `useCallback`).\n */\n\nimport { useContext, useMemo, type Context } from 'react'\n\nexport function useOuterOrDefault<T>(\n context: Context<T | null>,\n factory: () => T,\n deps: ReadonlyArray<unknown> = [],\n): T {\n const outer = useContext(context)\n // eslint-disable-next-line react-hooks/exhaustive-deps -- deps are the contract;\n // factory identity is intentionally ignored (caller controls re-creation via deps).\n const fallback = useMemo(factory, deps)\n return outer ?? fallback\n}\n"],"mappings":";;;;;;;;;;;;;;AA6BA,SAAS,YAAY,eAA6B;AAE3C,SAAS,kBACd,SACA,SACA,OAA+B,CAAC,GAC7B;AACH,QAAM,QAAQ,WAAW,OAAO;AAGhC,QAAM,WAAW,QAAQ,SAAS,IAAI;AACtC,SAAO,SAAS;AAClB;","names":[]}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Outer-forward provider helper — used by hub + embedder providers
|
|
3
|
+
* that supply default runtime values while allowing OUTER providers
|
|
4
|
+
* to override.
|
|
5
|
+
*
|
|
6
|
+
* When an embedder mounts an outer `<ChatRuntimeContext.Provider>`
|
|
7
|
+
* (or `<EndpointsRuntimeContext.Provider>`) ABOVE the hub provider,
|
|
8
|
+
* the outer value wins. When no outer is mounted, the hub provider
|
|
9
|
+
* supplies its `factory()` default. Tree shape stays constant —
|
|
10
|
+
* same provider element at the same position regardless of outer
|
|
11
|
+
* presence — so consumers below never remount when an embedder
|
|
12
|
+
* toggles their providers at runtime.
|
|
13
|
+
*
|
|
14
|
+
* `deps` controls factory memoization:
|
|
15
|
+
* - Empty `[]` (default) → factory runs ONCE per mount; safe ONLY
|
|
16
|
+
* when factory closes over module-scope/constant values.
|
|
17
|
+
* - Non-empty → factory re-runs when deps change. Use when the
|
|
18
|
+
* factory closes over callbacks or other reactive values
|
|
19
|
+
* (e.g. hub's ChatRuntime which includes `navigate` +
|
|
20
|
+
* `decideNewTab` callbacks that depend on router + docNav).
|
|
21
|
+
*
|
|
22
|
+
* Returning the SAME reference across renders is critical for
|
|
23
|
+
* downstream `useMemo` consumers. With empty deps, identity is
|
|
24
|
+
* trivially stable. With reactive deps, the caller must memoize
|
|
25
|
+
* the deps themselves (typically via `useCallback`).
|
|
26
|
+
*/
|
|
27
|
+
import { type Context } from 'react';
|
|
28
|
+
export declare function useOuterOrDefault<T>(context: Context<T | null>, factory: () => T, deps?: ReadonlyArray<unknown>): T;
|
|
29
|
+
//# sourceMappingURL=use-outer-or-default.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-outer-or-default.d.ts","sourceRoot":"","sources":["../../src/contexts/use-outer-or-default.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AAEH,OAAO,EAAuB,KAAK,OAAO,EAAE,MAAM,OAAO,CAAA;AAEzD,wBAAgB,iBAAiB,CAAC,CAAC,EACjC,OAAO,EAAE,OAAO,CAAC,CAAC,GAAG,IAAI,CAAC,EAC1B,OAAO,EAAE,MAAM,CAAC,EAChB,IAAI,GAAE,aAAa,CAAC,OAAO,CAAM,GAChC,CAAC,CAMH"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
var _chunkG7UE6RKVcjs = require('../chunk-G7UE6RKV.cjs');
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
var _chunkXL4V2PYGcjs = require('../chunk-XL4V2PYG.cjs');
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
var _chunkBZFW3FOFcjs = require('../chunk-BZFW3FOF.cjs');
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
var _chunkWBR7H6E3cjs = require('../chunk-WBR7H6E3.cjs');
|
|
28
|
+
require('../chunk-VRHGVLSL.cjs');
|
|
29
|
+
|
|
30
|
+
// src/embed-shims/index.ts
|
|
31
|
+
_chunkWBR7H6E3cjs.init_next_link.call(void 0, );
|
|
32
|
+
_chunkG7UE6RKVcjs.init_next_navigation.call(void 0, );
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
exports.Image = _chunkXL4V2PYGcjs.next_image_default; exports.Link = _chunkWBR7H6E3cjs.next_link_default; exports.RedirectType = _chunkG7UE6RKVcjs.RedirectType; exports.ServerInsertedHTMLContext = _chunkG7UE6RKVcjs.ServerInsertedHTMLContext; exports.dynamic = _chunkBZFW3FOFcjs.dynamic; exports.notFound = _chunkG7UE6RKVcjs.notFound; exports.permanentRedirect = _chunkG7UE6RKVcjs.permanentRedirect; exports.redirect = _chunkG7UE6RKVcjs.redirect; exports.registerDynamic = _chunkBZFW3FOFcjs.registerDynamic; exports.registerImage = _chunkXL4V2PYGcjs.registerImage; exports.registerLink = _chunkWBR7H6E3cjs.registerLink; exports.registerNavigation = _chunkG7UE6RKVcjs.registerNavigation; exports.useParams = _chunkG7UE6RKVcjs.useParams; exports.usePathname = _chunkG7UE6RKVcjs.usePathname; exports.useRouter = _chunkG7UE6RKVcjs.useRouter; exports.useSearchParams = _chunkG7UE6RKVcjs.useSearchParams;
|
|
51
|
+
//# sourceMappingURL=index.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["/home/runner/work/openframe-oss-lib/openframe-oss-lib/openframe-frontend-core/dist/embed-shims/index.cjs","../../src/embed-shims/index.ts"],"names":[],"mappings":"AAAA,qFAAY;AACZ;AACE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACF,yDAA8B;AAC9B;AACE;AACA;AACF,yDAA8B;AAC9B;AACE;AACA;AACF,yDAA8B;AAC9B;AACE;AACA;AACA;AACF,yDAA8B;AAC9B,iCAA8B;AAC9B;AACA;ACFA,8CAAA,CAAA;AAEA,oDAAA,CAAA;ADGA;AACE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACF,i4BAAC","file":"/home/runner/work/openframe-oss-lib/openframe-oss-lib/openframe-frontend-core/dist/embed-shims/index.cjs","sourcesContent":[null,"/**\n * Barrel for the `embed-shims/` shims.\n *\n * Each shim is environment-aware: by default it renders a plain HTML\n * equivalent so non-Next hosts (Vite, CRA, esbuild) work out of the\n * box. Next.js hosts opt into the REAL Next primitives by calling the\n * `register*` functions ONCE at app init — see each shim's docblock\n * for the host wiring snippet. After registration, every lib component\n * that renders through these shims delegates to the real Next impl\n * (Image Optimization, client-router prefetching, full app-router\n * navigation, etc.) without further config.\n *\n * Lib internals import each shim directly via its relative path\n * (`../embed-shims/next-link`). Hub and external consumers import\n * through this barrel:\n *\n * import { Link, Image, dynamic, useRouter, usePathname } from\n * '@flamingo-stack/openframe-frontend-core/embed-shims'\n *\n * Or per-shim:\n *\n * import Link from '@flamingo-stack/openframe-frontend-core/embed-shims/next-link'\n * import Image from '@flamingo-stack/openframe-frontend-core/embed-shims/next-image'\n *\n * Companion to the docblocks on each individual shim file.\n */\nexport { default as Image, registerImage } from './next-image'\nexport { default as Link, registerLink } from './next-link'\nexport { default as dynamic, registerDynamic } from './next-dynamic'\nexport {\n useRouter,\n usePathname,\n useSearchParams,\n useParams,\n redirect,\n permanentRedirect,\n notFound,\n RedirectType,\n ServerInsertedHTMLContext,\n registerNavigation,\n type NavigationImpl,\n} from './next-navigation'\n"]}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Barrel for the `embed-shims/` shims.
|
|
3
|
+
*
|
|
4
|
+
* Each shim is environment-aware: by default it renders a plain HTML
|
|
5
|
+
* equivalent so non-Next hosts (Vite, CRA, esbuild) work out of the
|
|
6
|
+
* box. Next.js hosts opt into the REAL Next primitives by calling the
|
|
7
|
+
* `register*` functions ONCE at app init — see each shim's docblock
|
|
8
|
+
* for the host wiring snippet. After registration, every lib component
|
|
9
|
+
* that renders through these shims delegates to the real Next impl
|
|
10
|
+
* (Image Optimization, client-router prefetching, full app-router
|
|
11
|
+
* navigation, etc.) without further config.
|
|
12
|
+
*
|
|
13
|
+
* Lib internals import each shim directly via its relative path
|
|
14
|
+
* (`../embed-shims/next-link`). Hub and external consumers import
|
|
15
|
+
* through this barrel:
|
|
16
|
+
*
|
|
17
|
+
* import { Link, Image, dynamic, useRouter, usePathname } from
|
|
18
|
+
* '@flamingo-stack/openframe-frontend-core/embed-shims'
|
|
19
|
+
*
|
|
20
|
+
* Or per-shim:
|
|
21
|
+
*
|
|
22
|
+
* import Link from '@flamingo-stack/openframe-frontend-core/embed-shims/next-link'
|
|
23
|
+
* import Image from '@flamingo-stack/openframe-frontend-core/embed-shims/next-image'
|
|
24
|
+
*
|
|
25
|
+
* Companion to the docblocks on each individual shim file.
|
|
26
|
+
*/
|
|
27
|
+
export { default as Image, registerImage } from './next-image';
|
|
28
|
+
export { default as Link, registerLink } from './next-link';
|
|
29
|
+
export { default as dynamic, registerDynamic } from './next-dynamic';
|
|
30
|
+
export { useRouter, usePathname, useSearchParams, useParams, redirect, permanentRedirect, notFound, RedirectType, ServerInsertedHTMLContext, registerNavigation, type NavigationImpl, } from './next-navigation';
|
|
31
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/embed-shims/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,aAAa,EAAE,MAAM,cAAc,CAAA;AAC9D,OAAO,EAAE,OAAO,IAAI,IAAI,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AAC3D,OAAO,EAAE,OAAO,IAAI,OAAO,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAA;AACpE,OAAO,EACL,SAAS,EACT,WAAW,EACX,eAAe,EACf,SAAS,EACT,QAAQ,EACR,iBAAiB,EACjB,QAAQ,EACR,YAAY,EACZ,yBAAyB,EACzB,kBAAkB,EAClB,KAAK,cAAc,GACpB,MAAM,mBAAmB,CAAA"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import {
|
|
3
|
+
RedirectType,
|
|
4
|
+
ServerInsertedHTMLContext,
|
|
5
|
+
init_next_navigation,
|
|
6
|
+
notFound,
|
|
7
|
+
permanentRedirect,
|
|
8
|
+
redirect,
|
|
9
|
+
registerNavigation,
|
|
10
|
+
useParams,
|
|
11
|
+
usePathname,
|
|
12
|
+
useRouter,
|
|
13
|
+
useSearchParams
|
|
14
|
+
} from "../chunk-PLJLE4A4.js";
|
|
15
|
+
import {
|
|
16
|
+
next_image_default,
|
|
17
|
+
registerImage
|
|
18
|
+
} from "../chunk-LXC6P2EO.js";
|
|
19
|
+
import {
|
|
20
|
+
dynamic,
|
|
21
|
+
registerDynamic
|
|
22
|
+
} from "../chunk-EL5YVPD5.js";
|
|
23
|
+
import {
|
|
24
|
+
init_next_link,
|
|
25
|
+
next_link_default,
|
|
26
|
+
registerLink
|
|
27
|
+
} from "../chunk-OHPI2HRK.js";
|
|
28
|
+
import "../chunk-GGWZFCYS.js";
|
|
29
|
+
|
|
30
|
+
// src/embed-shims/index.ts
|
|
31
|
+
init_next_link();
|
|
32
|
+
init_next_navigation();
|
|
33
|
+
export {
|
|
34
|
+
next_image_default as Image,
|
|
35
|
+
next_link_default as Link,
|
|
36
|
+
RedirectType,
|
|
37
|
+
ServerInsertedHTMLContext,
|
|
38
|
+
dynamic,
|
|
39
|
+
notFound,
|
|
40
|
+
permanentRedirect,
|
|
41
|
+
redirect,
|
|
42
|
+
registerDynamic,
|
|
43
|
+
registerImage,
|
|
44
|
+
registerLink,
|
|
45
|
+
registerNavigation,
|
|
46
|
+
useParams,
|
|
47
|
+
usePathname,
|
|
48
|
+
useRouter,
|
|
49
|
+
useSearchParams
|
|
50
|
+
};
|
|
51
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/embed-shims/index.ts"],"sourcesContent":["/**\n * Barrel for the `embed-shims/` shims.\n *\n * Each shim is environment-aware: by default it renders a plain HTML\n * equivalent so non-Next hosts (Vite, CRA, esbuild) work out of the\n * box. Next.js hosts opt into the REAL Next primitives by calling the\n * `register*` functions ONCE at app init — see each shim's docblock\n * for the host wiring snippet. After registration, every lib component\n * that renders through these shims delegates to the real Next impl\n * (Image Optimization, client-router prefetching, full app-router\n * navigation, etc.) without further config.\n *\n * Lib internals import each shim directly via its relative path\n * (`../embed-shims/next-link`). Hub and external consumers import\n * through this barrel:\n *\n * import { Link, Image, dynamic, useRouter, usePathname } from\n * '@flamingo-stack/openframe-frontend-core/embed-shims'\n *\n * Or per-shim:\n *\n * import Link from '@flamingo-stack/openframe-frontend-core/embed-shims/next-link'\n * import Image from '@flamingo-stack/openframe-frontend-core/embed-shims/next-image'\n *\n * Companion to the docblocks on each individual shim file.\n */\nexport { default as Image, registerImage } from './next-image'\nexport { default as Link, registerLink } from './next-link'\nexport { default as dynamic, registerDynamic } from './next-dynamic'\nexport {\n useRouter,\n usePathname,\n useSearchParams,\n useParams,\n redirect,\n permanentRedirect,\n notFound,\n RedirectType,\n ServerInsertedHTMLContext,\n registerNavigation,\n type NavigationImpl,\n} from './next-navigation'\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA2BA;AAEA;","names":[]}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
|
|
2
|
+
"use client";
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
var _chunkBZFW3FOFcjs = require('../chunk-BZFW3FOF.cjs');
|
|
7
|
+
require('../chunk-VRHGVLSL.cjs');
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
exports.default = _chunkBZFW3FOFcjs.dynamic; exports.registerDynamic = _chunkBZFW3FOFcjs.registerDynamic;
|
|
12
|
+
//# sourceMappingURL=next-dynamic.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["/home/runner/work/openframe-oss-lib/openframe-oss-lib/openframe-frontend-core/dist/embed-shims/next-dynamic.cjs"],"names":[],"mappings":"AAAA,qFAAY;AACZ,YAAY;AACZ;AACE;AACA;AACF,yDAA8B;AAC9B,iCAA8B;AAC9B;AACE;AACA;AACF,yGAAC","file":"/home/runner/work/openframe-oss-lib/openframe-oss-lib/openframe-frontend-core/dist/embed-shims/next-dynamic.cjs"}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `next/dynamic` shim — environment-aware lazy loader.
|
|
3
|
+
*
|
|
4
|
+
* Defaults to `React.lazy` so non-Next hosts (Vite, CRA, esbuild) work
|
|
5
|
+
* out of the box. Callers MUST be wrapped in a `<Suspense>` boundary
|
|
6
|
+
* somewhere up the tree (Next.js's runtime provides one automatically;
|
|
7
|
+
* non-Next embedders provide their own).
|
|
8
|
+
*
|
|
9
|
+
* Next.js hosts can opt into the REAL `next/dynamic` (with SSR support,
|
|
10
|
+
* loading components, prefetch hints) by calling {@link registerDynamic}
|
|
11
|
+
* ONCE at app init:
|
|
12
|
+
*
|
|
13
|
+
* // hub: lib/embed-shim-registration.ts
|
|
14
|
+
* import nextDynamic from 'next/dynamic'
|
|
15
|
+
* import { registerDynamic } from '@flamingo-stack/openframe-frontend-core/embed-shims'
|
|
16
|
+
* registerDynamic(nextDynamic)
|
|
17
|
+
*
|
|
18
|
+
* After registration, every lib call to this shim's default export
|
|
19
|
+
* delegates to `next/dynamic`. Without registration, `ssr` / `loading`
|
|
20
|
+
* options are ignored (React.lazy doesn't support them).
|
|
21
|
+
*/
|
|
22
|
+
import { type ComponentType, type ReactNode } from 'react';
|
|
23
|
+
interface DynamicOptions {
|
|
24
|
+
loading?: (props: {
|
|
25
|
+
error?: Error | null;
|
|
26
|
+
isLoading?: boolean;
|
|
27
|
+
pastDelay?: boolean;
|
|
28
|
+
retry?: () => void;
|
|
29
|
+
timedOut?: boolean;
|
|
30
|
+
}) => ReactNode | null;
|
|
31
|
+
ssr?: boolean;
|
|
32
|
+
suspense?: boolean;
|
|
33
|
+
}
|
|
34
|
+
type DynamicLoader<P> = () => Promise<{
|
|
35
|
+
default: ComponentType<P>;
|
|
36
|
+
} | ComponentType<P>>;
|
|
37
|
+
/** Matches `next/dynamic`'s exported signature. */
|
|
38
|
+
type DynamicFn = <P extends Record<string, any> = Record<string, never>>(loader: DynamicLoader<P>, options?: DynamicOptions) => ComponentType<P>;
|
|
39
|
+
/**
|
|
40
|
+
* Register the real `next/dynamic` so this shim delegates to it instead
|
|
41
|
+
* of `React.lazy`. Call ONCE at app init in a Next.js host. The function
|
|
42
|
+
* signature must match `next/dynamic`'s default export.
|
|
43
|
+
*/
|
|
44
|
+
export declare function registerDynamic(fn: DynamicFn): void;
|
|
45
|
+
export default function dynamic<P extends Record<string, any> = Record<string, never>>(loader: DynamicLoader<P>, options?: DynamicOptions): ComponentType<P>;
|
|
46
|
+
export {};
|
|
47
|
+
//# sourceMappingURL=next-dynamic.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"next-dynamic.d.ts","sourceRoot":"","sources":["../../src/embed-shims/next-dynamic.tsx"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,OAAO,EAAQ,KAAK,aAAa,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAA;AAEhE,UAAU,cAAc;IACtB,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE;QAChB,KAAK,CAAC,EAAE,KAAK,GAAG,IAAI,CAAA;QACpB,SAAS,CAAC,EAAE,OAAO,CAAA;QACnB,SAAS,CAAC,EAAE,OAAO,CAAA;QACnB,KAAK,CAAC,EAAE,MAAM,IAAI,CAAA;QAClB,QAAQ,CAAC,EAAE,OAAO,CAAA;KACnB,KAAK,SAAS,GAAG,IAAI,CAAA;IACtB,GAAG,CAAC,EAAE,OAAO,CAAA;IACb,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB;AAED,KAAK,aAAa,CAAC,CAAC,IAAI,MAAM,OAAO,CAAC;IAAE,OAAO,EAAE,aAAa,CAAC,CAAC,CAAC,CAAA;CAAE,GAAG,aAAa,CAAC,CAAC,CAAC,CAAC,CAAA;AAEvF,mDAAmD;AACnD,KAAK,SAAS,GAAG,CAAC,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,EACrE,MAAM,EAAE,aAAa,CAAC,CAAC,CAAC,EACxB,OAAO,CAAC,EAAE,cAAc,KACrB,aAAa,CAAC,CAAC,CAAC,CAAA;AAYrB;;;;GAIG;AACH,wBAAgB,eAAe,CAAC,EAAE,EAAE,SAAS,GAAG,IAAI,CAEnD;AAED,MAAM,CAAC,OAAO,UAAU,OAAO,CAAC,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,EACnF,MAAM,EAAE,aAAa,CAAC,CAAC,CAAC,EACxB,OAAO,CAAC,EAAE,cAAc,GACvB,aAAa,CAAC,CAAC,CAAC,CAElB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
|
|
2
|
+
"use client";
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
var _chunkXL4V2PYGcjs = require('../chunk-XL4V2PYG.cjs');
|
|
7
|
+
require('../chunk-VRHGVLSL.cjs');
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
exports.default = _chunkXL4V2PYGcjs.next_image_default; exports.registerImage = _chunkXL4V2PYGcjs.registerImage;
|
|
12
|
+
//# sourceMappingURL=next-image.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["/home/runner/work/openframe-oss-lib/openframe-oss-lib/openframe-frontend-core/dist/embed-shims/next-image.cjs"],"names":[],"mappings":"AAAA,qFAAY;AACZ,YAAY;AACZ;AACE;AACA;AACF,yDAA8B;AAC9B,iCAA8B;AAC9B;AACE;AACA;AACF,gHAAC","file":"/home/runner/work/openframe-oss-lib/openframe-oss-lib/openframe-frontend-core/dist/embed-shims/next-image.cjs"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { type ComponentType, type ImgHTMLAttributes } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* Register the real `next/image` so this shim delegates to it instead
|
|
4
|
+
* of rendering a plain `<img>`. Call ONCE at app init in a Next.js host
|
|
5
|
+
* — subsequent calls overwrite the registration silently. Safe to skip
|
|
6
|
+
* entirely in non-Next environments.
|
|
7
|
+
*/
|
|
8
|
+
export declare function registerImage(component: ComponentType<any>): void;
|
|
9
|
+
declare const Image: import("react").ForwardRefExoticComponent<Omit<ImgHTMLAttributes<HTMLImageElement>, "placeholder" | "src"> & {
|
|
10
|
+
src?: string | {
|
|
11
|
+
src: string;
|
|
12
|
+
};
|
|
13
|
+
alt?: string;
|
|
14
|
+
width?: number | string;
|
|
15
|
+
height?: number | string;
|
|
16
|
+
fill?: boolean;
|
|
17
|
+
sizes?: string;
|
|
18
|
+
quality?: number;
|
|
19
|
+
priority?: boolean;
|
|
20
|
+
loading?: "eager" | "lazy";
|
|
21
|
+
placeholder?: "blur" | "empty" | `data:image/${string}`;
|
|
22
|
+
blurDataURL?: string;
|
|
23
|
+
unoptimized?: boolean;
|
|
24
|
+
onLoadingComplete?: (img: HTMLImageElement) => void;
|
|
25
|
+
loader?: unknown;
|
|
26
|
+
} & import("react").RefAttributes<HTMLImageElement>>;
|
|
27
|
+
export default Image;
|
|
28
|
+
//# sourceMappingURL=next-image.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"next-image.d.ts","sourceRoot":"","sources":["../../src/embed-shims/next-image.tsx"],"names":[],"mappings":"AAsBA,OAAO,EAEL,KAAK,aAAa,EAClB,KAAK,iBAAiB,EACvB,MAAM,OAAO,CAAA;AAqBd;;;;;GAKG;AACH,wBAAgB,aAAa,CAAC,SAAS,EAAE,aAAa,CAAC,GAAG,CAAC,GAAG,IAAI,CAEjE;AAED,QAAA,MAAM,KAAK;UA5BH,MAAM,GAAG;QAAE,GAAG,EAAE,MAAM,CAAA;KAAE;UACxB,MAAM;YACJ,MAAM,GAAG,MAAM;aACd,MAAM,GAAG,MAAM;WACjB,OAAO;YACN,MAAM;cACJ,MAAM;eACL,OAAO;cACR,OAAO,GAAG,MAAM;kBACZ,MAAM,GAAG,OAAO,GAAG,cAAc,MAAM,EAAE;kBACzC,MAAM;kBACN,OAAO;wBACD,CAAC,GAAG,EAAE,gBAAgB,KAAK,IAAI;aAC1C,OAAO;oDAqEhB,CAAA;AAEF,eAAe,KAAK,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
|
|
2
|
+
"use client";
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
var _chunkWBR7H6E3cjs = require('../chunk-WBR7H6E3.cjs');
|
|
8
|
+
require('../chunk-VRHGVLSL.cjs');
|
|
9
|
+
_chunkWBR7H6E3cjs.init_next_link.call(void 0, );
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
exports.default = _chunkWBR7H6E3cjs.next_link_default; exports.registerLink = _chunkWBR7H6E3cjs.registerLink;
|
|
14
|
+
//# sourceMappingURL=next-link.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["/home/runner/work/openframe-oss-lib/openframe-oss-lib/openframe-frontend-core/dist/embed-shims/next-link.cjs"],"names":[],"mappings":"AAAA,qFAAY;AACZ,YAAY;AACZ;AACE;AACA;AACA;AACF,yDAA8B;AAC9B,iCAA8B;AAC9B,8CAAc,CAAE;AAChB;AACE;AACA;AACF,6GAAC","file":"/home/runner/work/openframe-oss-lib/openframe-oss-lib/openframe-frontend-core/dist/embed-shims/next-link.cjs"}
|