@flamingo-stack/openframe-frontend-core 0.0.825 → 0.0.826
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/build/export-map.json +1 -1
- package/dist/{case-study-card-IZBMHA6R.cjs → case-study-card-O4IQCJAX.cjs} +5 -5
- package/dist/{chunk-QOAA7ZHB.cjs → chunk-2HQNXX2K.cjs} +2 -2
- package/dist/{chunk-2U7GXE3T.cjs → chunk-2TQJSB62.cjs} +2157 -811
- package/dist/{chunk-NONMZ5WJ.cjs → chunk-2VLPXUQK.cjs} +14 -83
- package/dist/{chunk-7DJWIVQC.cjs → chunk-37OYBX7W.cjs} +36 -36
- package/dist/{chunk-OBQ5WUNG.cjs → chunk-3B6ZE4EZ.cjs} +29 -29
- package/dist/{chunk-AO6YVNAH.cjs → chunk-5AQKXEMI.cjs} +979 -1357
- package/dist/{chunk-25HBH4J6.cjs → chunk-5BM7X4GA.cjs} +2 -2
- package/dist/{chunk-47SHKOCY.cjs → chunk-63T2KKDZ.cjs} +86 -86
- package/dist/{chunk-MHR4C465.cjs → chunk-6G4WRMEM.cjs} +3 -3
- package/dist/{chunk-AUBR3FGY.cjs → chunk-74GWFGH2.cjs} +28 -28
- package/dist/{chunk-467T3LCG.cjs → chunk-7PZQ7SHB.cjs} +49 -32
- package/dist/{chunk-6LVJKPR3.cjs → chunk-AJM4YZTW.cjs} +8 -8
- package/dist/{chunk-2XLPRW7V.cjs → chunk-BIG3O33P.cjs} +6 -2
- package/dist/chunk-BMQLM2NU.cjs +40 -0
- package/dist/{chunk-DVHSYPDB.cjs → chunk-DAKGX2WF.cjs} +2 -2
- package/dist/{chunk-2IWAHBCC.cjs → chunk-DRSFR5AC.cjs} +159 -159
- package/dist/{chunk-IJCSQFLD.cjs → chunk-DU6AF77X.cjs} +83 -121
- package/dist/{chunk-NL34HKLS.cjs → chunk-EJNDTSKY.cjs} +91 -91
- package/dist/{chunk-SBFBNOKU.cjs → chunk-ENMPSEEQ.cjs} +4 -4
- package/dist/{chunk-ZECG6GU5.cjs → chunk-F2J5WN6U.cjs} +2 -2
- package/dist/{chunk-BOS7OIC4.cjs → chunk-GRHF5SWL.cjs} +5 -2
- package/dist/{chunk-Z7BLMJEI.cjs → chunk-GZAPOCKS.cjs} +54 -54
- package/dist/{chunk-5S2GW6YG.cjs → chunk-HJAPXKWK.cjs} +17 -17
- package/dist/{chunk-P25RVNGX.cjs → chunk-HQ4FKHOO.cjs} +249 -108
- package/dist/{chunk-ZRDVFADQ.cjs → chunk-IBD2FPSX.cjs} +75 -9
- package/dist/{chunk-T266OITJ.cjs → chunk-IKWQW3YJ.cjs} +45 -45
- package/dist/{chunk-B7NSH7IK.cjs → chunk-IWQ2LJGW.cjs} +5 -5
- package/dist/{chunk-MALCUN2G.cjs → chunk-JDR72QFU.cjs} +12 -14
- package/dist/{chunk-EHANO6UE.cjs → chunk-K34TTZAE.cjs} +9 -129
- package/dist/{chunk-QDDBOCG3.cjs → chunk-KPGKTEEB.cjs} +2 -2
- package/dist/{chunk-4IY5FKYL.cjs → chunk-MDEOCOIE.cjs} +23 -23
- package/dist/chunk-OEP5KAT6.cjs +56 -0
- package/dist/chunk-OT6P57ZS.cjs +94 -0
- package/dist/{chunk-QQT23JJ7.cjs → chunk-PBHP3FHO.cjs} +4 -4
- package/dist/{chunk-IMMTH3F3.cjs → chunk-PJY3SYCS.cjs} +29 -27
- package/dist/{chunk-N7IDLF2G.cjs → chunk-PWAKRRRO.cjs} +1283 -268
- package/dist/{chunk-UEULXVW2.cjs → chunk-QS6AKUUL.cjs} +22 -22
- package/dist/{chunk-BN7QENV7.cjs → chunk-QYJZDEG7.cjs} +6 -6
- package/dist/{chunk-NPNZAAOB.cjs → chunk-S6UJEW4G.cjs} +2 -2
- package/dist/{chunk-XJMLZ63Y.cjs → chunk-TJG2BJ5J.cjs} +4 -4
- package/dist/{chunk-QOOMUGF2.cjs → chunk-TYJ73DHW.cjs} +15 -15
- package/dist/{chunk-A34UNP5V.cjs → chunk-W4VEDSAX.cjs} +80 -11
- package/dist/{chunk-DNZCSPMU.cjs → chunk-WGMU45NV.cjs} +20 -20
- package/dist/{chunk-APTFXX2C.cjs → chunk-XDHQC4XH.cjs} +46 -46
- package/dist/{cloud-tenants-M4VFFN33.cjs → cloud-tenants-F67KQ5GC.cjs} +108 -106
- package/dist/components/case-studies/index.cjs +124 -122
- package/dist/components/chat/approval-batch-message.d.ts.map +1 -1
- package/dist/components/chat/approval-batch-message.js +2 -2
- package/dist/components/chat/chat-archive-page.d.ts +7 -0
- package/dist/components/chat/chat-archive-page.d.ts.map +1 -1
- package/dist/components/chat/chat-archive-page.js +9 -0
- package/dist/components/chat/chat-composer.d.ts +24 -4
- package/dist/components/chat/chat-composer.d.ts.map +1 -1
- package/dist/components/chat/chat-composer.js +90 -48
- package/dist/components/chat/chat-context-memory-bar.d.ts +4 -1
- package/dist/components/chat/chat-context-memory-bar.d.ts.map +1 -1
- package/dist/components/chat/chat-context-memory-bar.js +8 -5
- package/dist/components/chat/chat-context-picker.d.ts +8 -1
- package/dist/components/chat/chat-context-picker.d.ts.map +1 -1
- package/dist/components/chat/chat-context-picker.js +32 -9
- package/dist/components/chat/chat-header-rename-field.d.ts +18 -0
- package/dist/components/chat/chat-header-rename-field.d.ts.map +1 -0
- package/dist/components/chat/chat-header-rename-field.js +49 -0
- package/dist/components/chat/chat-input.d.ts.map +1 -1
- package/dist/components/chat/chat-input.js +5 -0
- package/dist/components/chat/composer-sheet.d.ts +44 -0
- package/dist/components/chat/composer-sheet.d.ts.map +1 -0
- package/dist/components/chat/composer-sheet.js +140 -0
- package/dist/components/chat/embeddable-chat.d.ts +114 -1
- package/dist/components/chat/embeddable-chat.d.ts.map +1 -1
- package/dist/components/chat/embeddable-chat.js +328 -215
- package/dist/components/chat/index.cjs +118 -103
- package/dist/components/chat/index.d.ts +6 -0
- package/dist/components/chat/index.d.ts.map +1 -1
- package/dist/components/chat/index.js +9 -0
- package/dist/components/chat/mingo-chat-day-groups.d.ts +18 -0
- package/dist/components/chat/mingo-chat-day-groups.d.ts.map +1 -0
- package/dist/components/chat/mingo-chat-day-groups.js +45 -0
- package/dist/components/chat/mingo-chat-header.d.ts +34 -6
- package/dist/components/chat/mingo-chat-header.d.ts.map +1 -1
- package/dist/components/chat/mingo-chat-header.js +44 -7
- package/dist/components/chat/mingo-chat-history-section.d.ts +30 -0
- package/dist/components/chat/mingo-chat-history-section.d.ts.map +1 -0
- package/dist/components/chat/mingo-chat-history-section.js +500 -0
- package/dist/components/chat/mingo-chat-history.d.ts +5 -2
- package/dist/components/chat/mingo-chat-history.d.ts.map +1 -1
- package/dist/components/chat/mingo-chat-history.js +26 -30
- package/dist/components/chat/mingo-chat-list-shared.d.ts +136 -0
- package/dist/components/chat/mingo-chat-list-shared.d.ts.map +1 -0
- package/dist/components/chat/mingo-chat-list-shared.js +76 -0
- package/dist/components/chat/mingo-chat-rail.d.ts +19 -51
- package/dist/components/chat/mingo-chat-rail.d.ts.map +1 -1
- package/dist/components/chat/mingo-chat-rail.js +23 -45
- package/dist/components/chat/mingo-edge-light.d.ts +13 -0
- package/dist/components/chat/mingo-edge-light.d.ts.map +1 -0
- package/dist/components/chat/mingo-edge-light.js +17 -0
- package/dist/components/chat/mingo-history-rail.d.ts +5 -4
- package/dist/components/chat/mingo-history-rail.d.ts.map +1 -1
- package/dist/components/chat/mingo-history-rail.js +5 -10
- package/dist/components/chat/mingo-quick-action-wall.d.ts +27 -0
- package/dist/components/chat/mingo-quick-action-wall.d.ts.map +1 -0
- package/dist/components/chat/mingo-quick-action-wall.js +41 -0
- package/dist/components/chat/mingo-welcome.d.ts.map +1 -1
- package/dist/components/chat/mingo-welcome.js +6 -20
- package/dist/components/chat/model-display.d.ts.map +1 -1
- package/dist/components/chat/model-display.js +38 -9
- package/dist/components/chat/tool-execution-display.d.ts.map +1 -1
- package/dist/components/chat/tool-execution-display.js +15 -1
- package/dist/components/chat/types/component.types.d.ts +13 -1
- package/dist/components/chat/types/component.types.d.ts.map +1 -1
- package/dist/components/chat/utils/chat-day-label.d.ts +8 -0
- package/dist/components/chat/utils/chat-day-label.d.ts.map +1 -0
- package/dist/components/chat/utils/chat-day-label.js +21 -0
- package/dist/components/contact/index.cjs +109 -107
- package/dist/components/docs/index.cjs +112 -110
- package/dist/components/embeds/index.cjs +109 -107
- package/dist/components/faq/index.cjs +110 -108
- package/dist/components/features/board/board-column.d.ts +3 -1
- package/dist/components/features/board/board-column.d.ts.map +1 -1
- package/dist/components/features/board/board-column.js +6 -2
- package/dist/components/features/board/board.d.ts +6 -0
- package/dist/components/features/board/board.d.ts.map +1 -1
- package/dist/components/features/board/board.js +14 -3
- package/dist/components/features/board/touch-board.d.ts +1 -1
- package/dist/components/features/board/touch-board.d.ts.map +1 -1
- package/dist/components/features/board/touch-board.js +3 -1
- package/dist/components/features/index.cjs +108 -106
- package/dist/components/features/notifications/approval-request-notification-tile.d.ts +7 -1
- package/dist/components/features/notifications/approval-request-notification-tile.d.ts.map +1 -1
- package/dist/components/features/notifications/approval-request-notification-tile.js +1 -1
- package/dist/components/features/notifications/notification-drawer.d.ts +6 -1
- package/dist/components/features/notifications/notification-drawer.d.ts.map +1 -1
- package/dist/components/features/notifications/notification-drawer.js +3 -2
- package/dist/components/features/notifications/notification-tile.d.ts +4 -1
- package/dist/components/features/notifications/notification-tile.d.ts.map +1 -1
- package/dist/components/features/notifications/notification-tile.js +9 -7
- package/dist/components/features/time-tracker/time-tracker-header-button.d.ts +18 -1
- package/dist/components/features/time-tracker/time-tracker-header-button.d.ts.map +1 -1
- package/dist/components/features/time-tracker/time-tracker-header-button.js +31 -7
- package/dist/components/help-center-pages/index.cjs +217 -215
- package/dist/components/icons-v2-generated/icon-loaders.d.ts.map +1 -1
- package/dist/components/icons-v2-generated/icon-loaders.js +1 -0
- package/dist/components/icons-v2-generated/icon-names.js +1 -1
- package/dist/components/icons-v2-generated/index.cjs +90 -86
- package/dist/components/icons-v2-generated/loaders/dots-loader-icon.d.ts.map +1 -1
- package/dist/components/icons-v2-generated/loaders/dots-loader-icon.js +21 -24
- package/dist/components/icons-v2-generated/logos/index.d.ts +1 -0
- package/dist/components/icons-v2-generated/logos/index.d.ts.map +1 -1
- package/dist/components/icons-v2-generated/logos/index.js +2 -0
- package/dist/components/icons-v2-generated/logos/mingo-logo-icon.d.ts +9 -0
- package/dist/components/icons-v2-generated/logos/mingo-logo-icon.d.ts.map +1 -0
- package/dist/components/icons-v2-generated/logos/mingo-logo-icon.js +36 -0
- package/dist/components/index.cjs +215 -182
- package/dist/components/meeting-scheduler/index.cjs +182 -180
- package/dist/components/navigation/account-popover.d.ts +62 -0
- package/dist/components/navigation/account-popover.d.ts.map +1 -0
- package/dist/components/navigation/account-popover.js +138 -0
- package/dist/components/navigation/app-header.d.ts +36 -2
- package/dist/components/navigation/app-header.d.ts.map +1 -1
- package/dist/components/navigation/app-header.js +28 -24
- package/dist/components/navigation/app-layout-context.d.ts +17 -0
- package/dist/components/navigation/app-layout-context.d.ts.map +1 -1
- package/dist/components/navigation/app-layout-context.js +9 -1
- package/dist/components/navigation/app-layout.d.ts +93 -1
- package/dist/components/navigation/app-layout.d.ts.map +1 -1
- package/dist/components/navigation/app-layout.js +149 -30
- package/dist/components/navigation/header-button.d.ts +11 -1
- package/dist/components/navigation/header-button.d.ts.map +1 -1
- package/dist/components/navigation/header-button.js +16 -5
- package/dist/components/navigation/header-mingo-button.d.ts.map +1 -1
- package/dist/components/navigation/header-mingo-button.js +6 -5
- package/dist/components/navigation/index.cjs +120 -109
- package/dist/components/navigation/index.d.ts +10 -1
- package/dist/components/navigation/index.d.ts.map +1 -1
- package/dist/components/navigation/index.js +8 -0
- package/dist/components/navigation/mingo-ai-button.d.ts.map +1 -1
- package/dist/components/navigation/mingo-ai-button.js +2 -1
- package/dist/components/navigation/mobile-burger-menu.d.ts.map +1 -1
- package/dist/components/navigation/mobile-burger-menu.js +155 -39
- package/dist/components/navigation/navigation-sidebar-grouped.d.ts +57 -0
- package/dist/components/navigation/navigation-sidebar-grouped.d.ts.map +1 -0
- package/dist/components/navigation/navigation-sidebar-grouped.js +365 -0
- package/dist/components/navigation/navigation-sidebar-match.d.ts +37 -0
- package/dist/components/navigation/navigation-sidebar-match.d.ts.map +1 -0
- package/dist/components/navigation/navigation-sidebar-match.js +85 -0
- package/dist/components/navigation/navigation-sidebar-slot.d.ts +7 -0
- package/dist/components/navigation/navigation-sidebar-slot.d.ts.map +1 -0
- package/dist/components/navigation/navigation-sidebar-slot.js +11 -0
- package/dist/components/navigation/navigation-sidebar-toggle.d.ts +7 -1
- package/dist/components/navigation/navigation-sidebar-toggle.d.ts.map +1 -1
- package/dist/components/navigation/navigation-sidebar-toggle.js +52 -23
- package/dist/components/navigation/navigation-sidebar.d.ts +13 -1
- package/dist/components/navigation/navigation-sidebar.d.ts.map +1 -1
- package/dist/components/navigation/navigation-sidebar.js +188 -52
- package/dist/components/navigation/notifications-bell-button.d.ts +28 -0
- package/dist/components/navigation/notifications-bell-button.d.ts.map +1 -0
- package/dist/components/navigation/notifications-bell-button.js +44 -0
- package/dist/components/navigation/ticket-alerts-button.d.ts +7 -1
- package/dist/components/navigation/ticket-alerts-button.d.ts.map +1 -1
- package/dist/components/navigation/ticket-alerts-button.js +3 -2
- package/dist/components/onboarding-guides/index.cjs +111 -109
- package/dist/components/product-demo/index.cjs +119 -117
- package/dist/components/related-content/index.cjs +13 -13
- package/dist/components/tickets/index.cjs +115 -113
- package/dist/components/ui/actions-menu.d.ts +6 -1
- package/dist/components/ui/actions-menu.d.ts.map +1 -1
- package/dist/components/ui/actions-menu.js +6 -2
- package/dist/components/ui/fade-preview.d.ts +8 -0
- package/dist/components/ui/fade-preview.d.ts.map +1 -1
- package/dist/components/ui/fade-preview.js +7 -5
- package/dist/components/ui/index.cjs +136 -111
- 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 +1 -0
- package/dist/components/ui/mobile-action-bar.d.ts +14 -0
- package/dist/components/ui/mobile-action-bar.d.ts.map +1 -0
- package/dist/components/ui/mobile-action-bar.js +68 -0
- package/dist/components/ui/no-data/no-data-styles.d.ts +1 -1
- package/dist/components/ui/no-data/no-data-styles.d.ts.map +1 -1
- package/dist/components/ui/no-data/no-data-styles.js +1 -1
- package/dist/components/ui/page-actions.d.ts.map +1 -1
- package/dist/components/ui/page-actions.js +24 -8
- package/dist/components/ui/panel-resize-handle.d.ts +6 -2
- package/dist/components/ui/panel-resize-handle.d.ts.map +1 -1
- package/dist/components/ui/panel-resize-handle.js +6 -3
- package/dist/components/ui/square-avatar.d.ts.map +1 -1
- package/dist/components/ui/square-avatar.js +5 -2
- package/dist/{devices-DW5NDXMD.cjs → devices-SJORCARH.cjs} +109 -107
- package/dist/dots-loader-icon-5JXWD6FB.cjs +7 -0
- package/dist/{embeddable-chat-NBJMXEXB.cjs → embeddable-chat-7Z4CEZJL.cjs} +513 -398
- package/dist/hooks/index.cjs +15 -16
- package/dist/hooks/ui/use-content-breakpoint.d.ts +4 -2
- package/dist/hooks/ui/use-content-breakpoint.d.ts.map +1 -1
- package/dist/{icon-loaders-OLGJZGRP.cjs → icon-loaders-SUPEKMBJ.cjs} +2 -1
- package/dist/index.cjs +154 -121
- package/dist/{knowledge-EYJG2TNW.cjs → knowledge-QXILUVEM.cjs} +109 -107
- package/dist/{logs-2LV7DTSL.cjs → logs-E3KQQQD6.cjs} +118 -115
- package/dist/mingo-logo-icon-WGPBSDTF.cjs +7 -0
- package/dist/{policies-HSDYIQBX.cjs → policies-IOYQY6TF.cjs} +112 -110
- package/dist/{remote-session-BQMTIQTU.cjs → remote-session-QGFG5WAL.cjs} +99 -97
- package/dist/{scripts-UI6V7ANQ.cjs → scripts-E5TWWUNP.cjs} +115 -113
- package/dist/{software-update-WMLY7VHH.cjs → software-update-QZGYG4TD.cjs} +112 -110
- package/dist/{tickets-board-TRXOX77R.cjs → tickets-board-KCH6ITUV.cjs} +95 -94
- package/dist/types/navigation.d.ts +131 -0
- package/dist/types/navigation.d.ts.map +1 -1
- package/dist/utils/index.cjs +65 -25
- package/package.json +1 -1
- package/src/components/chat/approval-batch-message.tsx +3 -2
- package/src/components/chat/chat-archive-page.tsx +16 -0
- package/src/components/chat/chat-composer.tsx +131 -61
- package/src/components/chat/chat-context-memory-bar.tsx +27 -17
- package/src/components/chat/chat-context-picker.tsx +45 -11
- package/src/components/chat/chat-header-rename-field.tsx +68 -0
- package/src/components/chat/chat-input.tsx +9 -1
- package/src/components/chat/composer-sheet.tsx +196 -0
- package/src/components/chat/embeddable-chat.tsx +636 -319
- package/src/components/chat/index.ts +6 -0
- package/src/components/chat/mingo-chat-day-groups.ts +62 -0
- package/src/components/chat/mingo-chat-header.tsx +99 -23
- package/src/components/chat/mingo-chat-history-section.tsx +670 -0
- package/src/components/chat/mingo-chat-history.tsx +31 -45
- package/src/components/chat/mingo-chat-list-shared.tsx +244 -0
- package/src/components/chat/mingo-chat-rail.tsx +45 -97
- package/src/components/chat/mingo-edge-light.tsx +25 -0
- package/src/components/chat/mingo-history-rail.tsx +7 -17
- package/src/components/chat/mingo-quick-action-wall.tsx +64 -0
- package/src/components/chat/mingo-welcome.tsx +5 -19
- package/src/components/chat/model-display.tsx +66 -14
- package/src/components/chat/tool-execution-display.tsx +9 -1
- package/src/components/chat/types/component.types.ts +13 -1
- package/src/components/chat/utils/chat-day-label.ts +24 -0
- package/src/components/features/board/board-column.tsx +8 -0
- package/src/components/features/board/board.tsx +16 -2
- package/src/components/features/board/touch-board.tsx +2 -0
- package/src/components/features/notifications/approval-request-notification-tile.tsx +8 -2
- package/src/components/features/notifications/notification-drawer.tsx +7 -1
- package/src/components/features/notifications/notification-tile.tsx +17 -9
- package/src/components/features/time-tracker/time-tracker-header-button.tsx +53 -6
- package/src/components/icons-v2/icon-colors.json +4 -0
- package/src/components/icons-v2-generated/icon-loaders.ts +1 -0
- package/src/components/icons-v2-generated/icon-names.ts +1 -1
- package/src/components/icons-v2-generated/loaders/dots-loader-icon.tsx +18 -27
- package/src/components/icons-v2-generated/logos/index.ts +1 -0
- package/src/components/icons-v2-generated/logos/mingo-logo-icon.tsx +35 -0
- package/src/components/navigation/account-popover.tsx +198 -0
- package/src/components/navigation/app-header.tsx +74 -33
- package/src/components/navigation/app-layout-context.ts +22 -0
- package/src/components/navigation/app-layout.tsx +290 -24
- package/src/components/navigation/header-button.tsx +27 -5
- package/src/components/navigation/header-mingo-button.tsx +6 -5
- package/src/components/navigation/index.ts +19 -0
- package/src/components/navigation/mingo-ai-button.tsx +2 -3
- package/src/components/navigation/mobile-burger-menu.tsx +219 -53
- package/src/components/navigation/navigation-sidebar-grouped.tsx +554 -0
- package/src/components/navigation/navigation-sidebar-match.ts +152 -0
- package/src/components/navigation/navigation-sidebar-slot.ts +12 -0
- package/src/components/navigation/navigation-sidebar-toggle.tsx +39 -6
- package/src/components/navigation/navigation-sidebar.tsx +278 -61
- package/src/components/navigation/notifications-bell-button.tsx +70 -0
- package/src/components/navigation/ticket-alerts-button.tsx +9 -2
- package/src/components/ui/actions-menu.tsx +19 -3
- package/src/components/ui/fade-preview.tsx +13 -6
- package/src/components/ui/index.ts +1 -0
- package/src/components/ui/mobile-action-bar.ts +87 -0
- package/src/components/ui/no-data/no-data-styles.ts +5 -2
- package/src/components/ui/page-actions.tsx +38 -11
- package/src/components/ui/panel-resize-handle.tsx +14 -5
- package/src/components/ui/square-avatar.tsx +5 -2
- package/src/hooks/ui/use-content-breakpoint.ts +4 -2
- package/src/styles/ods-interaction-states.css +68 -0
- package/src/types/navigation.ts +140 -0
- package/dist/chunk-C7GIHB3V.cjs +0 -59
- package/dist/dots-loader-icon-RBLX46X7.cjs +0 -7
- package/dist/{chunk-ZOZR3QI2.cjs → chunk-46547WQW.cjs} +0 -0
- package/dist/{video-file-player-IAMWBKEQ.cjs → video-file-player-IHO66P2Q.cjs} +1 -1
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
|
|
3
3
|
import { cn } from '../../utils/cn';
|
|
4
|
-
import { AlertCircleIcon, Refresh01RightIcon } from '../icons-v2-generated';
|
|
5
4
|
import { ChatsIcon } from '../icons-v2-generated/communication/chats-icon';
|
|
6
5
|
import { PlusCircleIcon } from '../icons-v2-generated/signs-and-symbols/plus-circle-icon';
|
|
7
6
|
import { Button } from '../ui/button';
|
|
@@ -9,16 +8,13 @@ import { useLoadingScope } from '../ui/loading-scope';
|
|
|
9
8
|
import { TabSelector } from '../ui/tab-selector';
|
|
10
9
|
import { ChatListEmptyState } from './chat-list-empty-state';
|
|
11
10
|
import { MingoChatHistory } from './mingo-chat-history';
|
|
11
|
+
import { ChatListLoadError, type MingoHistoryScope } from './mingo-chat-list-shared';
|
|
12
12
|
import type { DialogItem } from './types/component.types';
|
|
13
13
|
|
|
14
14
|
// =============================================================================
|
|
15
15
|
// Types
|
|
16
16
|
// =============================================================================
|
|
17
17
|
|
|
18
|
-
/** Ownership scope of the rail's dialog list — the current user's chats only,
|
|
19
|
-
* or every admin's chats in the tenant. */
|
|
20
|
-
export type MingoHistoryScope = 'my' | 'all';
|
|
21
|
-
|
|
22
18
|
export interface MingoHistoryRailProps {
|
|
23
19
|
/** Dialogs to list, assumed already sorted newest-first by the host. */
|
|
24
20
|
dialogs: ReadonlyArray<DialogItem>;
|
|
@@ -55,6 +51,9 @@ export interface MingoHistoryRailProps {
|
|
|
55
51
|
isLoadingMore?: boolean;
|
|
56
52
|
/** Fetch the next page. */
|
|
57
53
|
onLoadMore?: () => void;
|
|
54
|
+
/** How the next page loads: as the list's end scrolls into view (`'scroll'`, the default),
|
|
55
|
+
* or on a "Show more" under it (`'button'`, a page at a time). */
|
|
56
|
+
loadMore?: 'scroll' | 'button';
|
|
58
57
|
/** True while the FIRST page of dialogs is still loading. The list draws its
|
|
59
58
|
* own loading state so the rail doesn't flash the empty state before the list arrives. */
|
|
60
59
|
isLoadingHistory?: boolean;
|
|
@@ -99,6 +98,7 @@ export function MingoHistoryRail({
|
|
|
99
98
|
onScopeChange,
|
|
100
99
|
searchQuery,
|
|
101
100
|
hasMore = false,
|
|
101
|
+
loadMore = 'scroll',
|
|
102
102
|
isLoadingMore = false,
|
|
103
103
|
onLoadMore,
|
|
104
104
|
isLoadingHistory = false,
|
|
@@ -156,18 +156,7 @@ export function MingoHistoryRail({
|
|
|
156
156
|
) : null}
|
|
157
157
|
|
|
158
158
|
{loadError ? (
|
|
159
|
-
<
|
|
160
|
-
<AlertCircleIcon className="h-8 w-8 shrink-0 text-ods-text-secondary" />
|
|
161
|
-
<div className="flex flex-col gap-[var(--spacing-system-xxs)]">
|
|
162
|
-
<p className="text-ods-text-primary text-h4">Couldn’t load your chats</p>
|
|
163
|
-
<p className="text-ods-text-secondary text-h6">Something went wrong reaching the server. Try again.</p>
|
|
164
|
-
</div>
|
|
165
|
-
{onRetry && (
|
|
166
|
-
<Button variant="outline" size="small" leftIcon={<Refresh01RightIcon />} onClick={onRetry}>
|
|
167
|
-
Try again
|
|
168
|
-
</Button>
|
|
169
|
-
)}
|
|
170
|
-
</div>
|
|
159
|
+
<ChatListLoadError onRetry={onRetry} className="min-h-0 flex-1 justify-center" />
|
|
171
160
|
) : loading || hasList ? (
|
|
172
161
|
<MingoChatHistory
|
|
173
162
|
loading={loading}
|
|
@@ -183,6 +172,7 @@ export function MingoHistoryRail({
|
|
|
183
172
|
hasMore={hasMore}
|
|
184
173
|
isLoadingMore={isLoadingMore}
|
|
185
174
|
onLoadMore={onLoadMore}
|
|
175
|
+
loadMore={loadMore}
|
|
186
176
|
/>
|
|
187
177
|
) : (
|
|
188
178
|
// Figma 113:60939 — no-chats empty state.
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import { cn } from '../../utils/cn';
|
|
4
|
+
import type { MingoQuickAction } from './mingo-welcome';
|
|
5
|
+
import { QuickActionWall } from './quick-action-wall';
|
|
6
|
+
|
|
7
|
+
export interface MingoQuickActionWallProps {
|
|
8
|
+
quickActions: ReadonlyArray<MingoQuickAction>;
|
|
9
|
+
/** Pointer/keyboard focus enters a chip — e.g. preview its prompt in the composer. */
|
|
10
|
+
onQuickActionHover?: (action: MingoQuickAction) => void;
|
|
11
|
+
/** Pointer/keyboard focus leaves the chip. */
|
|
12
|
+
onQuickActionHoverEnd?: () => void;
|
|
13
|
+
/** A built-in agent (`'fae'`/`'mingo'`) caps the wall at 2 rows. Default `'mingo'`. */
|
|
14
|
+
agentSlug?: string;
|
|
15
|
+
/**
|
|
16
|
+
* The actions are still being read: the wall draws its chips' loading form at its full
|
|
17
|
+
* row count, so a host that holds its layout around the wall (a composer under it, a
|
|
18
|
+
* greeting centred above) does not move when the actions land.
|
|
19
|
+
*/
|
|
20
|
+
loading?: boolean;
|
|
21
|
+
className?: string;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* Mingo's quick actions as the chat's empty state draws them (`MingoWelcome`): the
|
|
26
|
+
* shared {@link QuickActionWall} in BRICK mode — stacked row marquees (2 for a built-in
|
|
27
|
+
* agent) under left/right edge fades, so a long action set gets "reach" without
|
|
28
|
+
* squeezing the composer. `pauseOnHover` freezes the hovered row so a moving chip
|
|
29
|
+
* never dodges a click. One component, so a host that shows the actions outside the
|
|
30
|
+
* chat (a docked composer's home) draws the very same wall.
|
|
31
|
+
*/
|
|
32
|
+
export function MingoQuickActionWall({
|
|
33
|
+
quickActions,
|
|
34
|
+
onQuickActionHover,
|
|
35
|
+
onQuickActionHoverEnd,
|
|
36
|
+
agentSlug = 'mingo',
|
|
37
|
+
loading = false,
|
|
38
|
+
className,
|
|
39
|
+
}: MingoQuickActionWallProps) {
|
|
40
|
+
if (quickActions.length === 0 && !loading) return null;
|
|
41
|
+
return (
|
|
42
|
+
<QuickActionWall
|
|
43
|
+
chips={quickActions.map(action => ({
|
|
44
|
+
id: action.id,
|
|
45
|
+
label: action.label,
|
|
46
|
+
icon: action.icon,
|
|
47
|
+
variant: action.variant,
|
|
48
|
+
onSelect: action.onClick,
|
|
49
|
+
onHoverStart: () => onQuickActionHover?.(action),
|
|
50
|
+
onHoverEnd: () => onQuickActionHoverEnd?.(),
|
|
51
|
+
}))}
|
|
52
|
+
agentSlug={agentSlug}
|
|
53
|
+
loading={loading}
|
|
54
|
+
rows={4}
|
|
55
|
+
pauseOnHover
|
|
56
|
+
dragScroll
|
|
57
|
+
fade={['left', 'right']}
|
|
58
|
+
fadeSize={{ left: 32 }}
|
|
59
|
+
fadeColor="var(--color-bg)"
|
|
60
|
+
copyGap="var(--spacing-system-xxs)"
|
|
61
|
+
className={cn('max-h-44 shrink-0', className)}
|
|
62
|
+
/>
|
|
63
|
+
);
|
|
64
|
+
}
|
|
@@ -10,8 +10,8 @@ import { Button } from '../ui/button';
|
|
|
10
10
|
import { useLoadingScope } from '../ui/loading-scope';
|
|
11
11
|
import { ScrollFadeOverlay, useScrollFade } from '../ui/scroll-fade';
|
|
12
12
|
import { MingoChatHistory } from './mingo-chat-history';
|
|
13
|
+
import { MingoQuickActionWall } from './mingo-quick-action-wall';
|
|
13
14
|
import { QuickActionChipButton } from './quick-action-chip';
|
|
14
|
-
import { QuickActionWall } from './quick-action-wall';
|
|
15
15
|
import type { DialogItem } from './types/component.types';
|
|
16
16
|
|
|
17
17
|
// =============================================================================
|
|
@@ -338,25 +338,11 @@ export function MingoWelcome({
|
|
|
338
338
|
/>
|
|
339
339
|
)}
|
|
340
340
|
{quickActions && quickActions.length > 0 && (
|
|
341
|
-
<
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
icon: action.icon,
|
|
346
|
-
variant: action.variant,
|
|
347
|
-
onSelect: action.onClick,
|
|
348
|
-
onHoverStart: () => onQuickActionHover?.(action),
|
|
349
|
-
onHoverEnd: () => onQuickActionHoverEnd?.(),
|
|
350
|
-
}))}
|
|
341
|
+
<MingoQuickActionWall
|
|
342
|
+
quickActions={quickActions}
|
|
343
|
+
onQuickActionHover={onQuickActionHover}
|
|
344
|
+
onQuickActionHoverEnd={onQuickActionHoverEnd}
|
|
351
345
|
agentSlug={agentSlug}
|
|
352
|
-
rows={4}
|
|
353
|
-
pauseOnHover
|
|
354
|
-
dragScroll
|
|
355
|
-
fade={['left', 'right']}
|
|
356
|
-
fadeSize={{ left: 32 }}
|
|
357
|
-
fadeColor="var(--color-bg)"
|
|
358
|
-
copyGap="var(--spacing-system-xxs)"
|
|
359
|
-
className="max-h-44 shrink-0"
|
|
360
346
|
/>
|
|
361
347
|
)}
|
|
362
348
|
</div>
|
|
@@ -6,6 +6,7 @@ import { HoverCard, HoverCardContent, HoverCardTrigger } from '../hover-card';
|
|
|
6
6
|
import { AnthropicLogoGreyIcon, GeminiLogoGreyIcon, OpenaiLogoGreyIcon } from '../icons-v2-generated';
|
|
7
7
|
import { MediaSkeleton, TextLineSkeleton } from '../loading/unified-skeleton';
|
|
8
8
|
import { useLoadingScope } from '../ui/loading-scope';
|
|
9
|
+
import { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger } from '../ui/tooltip';
|
|
9
10
|
import { useChatAppearance } from './chat-appearance-context';
|
|
10
11
|
import type { ModelDisplayProps, ModelUsageBreakdown } from './types';
|
|
11
12
|
import { CHAT_APPEARANCE } from './types/chat.types';
|
|
@@ -31,6 +32,10 @@ const getProviderIcon = (provider?: string) => {
|
|
|
31
32
|
}
|
|
32
33
|
};
|
|
33
34
|
|
|
35
|
+
/** What the tail's budget is: the agent's per-chat budget, not the model's window. */
|
|
36
|
+
const CONTEXT_BUDGET_HINT =
|
|
37
|
+
'Tokens this chat holds in memory. Older messages are summarized before the budget fills up.';
|
|
38
|
+
|
|
34
39
|
const formatTokenCount = (count: number): string => {
|
|
35
40
|
if (count >= 1_000_000) {
|
|
36
41
|
const val = count / 1_000_000;
|
|
@@ -68,18 +73,20 @@ const ModelDisplay = React.forwardRef<HTMLDivElement, ModelDisplayProps>(
|
|
|
68
73
|
hitRatePct,
|
|
69
74
|
inputTokens,
|
|
70
75
|
outputTokens,
|
|
76
|
+
onModelClick,
|
|
77
|
+
modelTooltip,
|
|
71
78
|
loading = false,
|
|
72
79
|
...props
|
|
73
80
|
},
|
|
74
81
|
ref,
|
|
75
82
|
) => {
|
|
76
83
|
// ONE switch: while the model metadata loads (or in the page's loading state) the SAME row draws the provider's
|
|
77
|
-
// mark box (only when the provider has a mark), the name as a bar, and the "
|
|
84
|
+
// mark box (only when the provider has a mark), the name as a bar, and the "context budget" tail as a bar when the
|
|
78
85
|
// loaded row would draw it (once the context window is known).
|
|
79
86
|
const isLoading = useLoadingScope() || loading;
|
|
80
87
|
const icon = getProviderIcon(provider);
|
|
81
88
|
const name = displayName || modelName;
|
|
82
|
-
// v2 spells the counts out ("372 / 50,000
|
|
89
|
+
// v2 spells the counts out ("372 / 50,000 context budget"); classic keeps them short.
|
|
83
90
|
const isV2 = useChatAppearance() === CHAT_APPEARANCE.V2;
|
|
84
91
|
const formatCount = (count: number) => (isV2 ? count.toLocaleString('en-US') : formatTokenCount(count));
|
|
85
92
|
|
|
@@ -97,22 +104,67 @@ const ModelDisplay = React.forwardRef<HTMLDivElement, ModelDisplayProps>(
|
|
|
97
104
|
);
|
|
98
105
|
}
|
|
99
106
|
|
|
100
|
-
//
|
|
101
|
-
//
|
|
102
|
-
|
|
107
|
+
// The provider icon + model name. With `onModelClick` it is a button (the
|
|
108
|
+
// host's settings, where the model is chosen); the token tail stays text.
|
|
109
|
+
const labelContent = (
|
|
110
|
+
<>
|
|
111
|
+
{icon && <span className={PROVIDER_ICON_BOX_CLASS}>{icon}</span>}
|
|
112
|
+
<span className="font-body">{name}</span>
|
|
113
|
+
</>
|
|
114
|
+
);
|
|
115
|
+
const label = onModelClick ? (
|
|
116
|
+
<button
|
|
117
|
+
type="button"
|
|
118
|
+
onClick={onModelClick}
|
|
119
|
+
className="flex items-center gap-1 rounded-sm text-ods-text-secondary transition-colors hover:text-ods-text-primary focus:outline-none focus-visible:text-ods-text-primary focus-visible:ring-2 focus-visible:ring-ods-accent"
|
|
120
|
+
>
|
|
121
|
+
{labelContent}
|
|
122
|
+
</button>
|
|
123
|
+
) : modelTooltip ? (
|
|
124
|
+
// A tooltip needs one element to anchor to.
|
|
125
|
+
<span className="flex items-center gap-1">{labelContent}</span>
|
|
126
|
+
) : (
|
|
127
|
+
// Neither: the same two spans the row always had.
|
|
128
|
+
labelContent
|
|
129
|
+
);
|
|
130
|
+
const labelWithTooltip = modelTooltip ? (
|
|
131
|
+
<TooltipProvider delayDuration={300}>
|
|
132
|
+
<Tooltip>
|
|
133
|
+
<TooltipTrigger asChild>{label}</TooltipTrigger>
|
|
134
|
+
<TooltipContent side="top" align="start">
|
|
135
|
+
{modelTooltip}
|
|
136
|
+
</TooltipContent>
|
|
137
|
+
</Tooltip>
|
|
138
|
+
</TooltipProvider>
|
|
139
|
+
) : (
|
|
140
|
+
label
|
|
141
|
+
);
|
|
142
|
+
|
|
143
|
+
// Inline pill: provider icon + model name + "X / Y context budget".
|
|
144
|
+
// `contextWindow` is the agent's context budget, not the model's window:
|
|
145
|
+
// the chat's memory is compacted before it fills, so the tail says how
|
|
146
|
+
// close the chat is to that. It renders as soon as the budget is known
|
|
147
|
+
// (typically from the leading metadata frame); `usedTokens` lags by a
|
|
103
148
|
// tick — it only becomes non-null after the first `message_start`
|
|
104
|
-
// usage frame
|
|
105
|
-
// model's capacity context without waiting for the first byte.
|
|
149
|
+
// usage frame, so the tail shows "— / 150K context budget" until then.
|
|
106
150
|
const inline = (
|
|
107
151
|
<div ref={ref} className={cn(MODEL_DISPLAY_ROW_CLASS, 'text-ods-text-secondary', className)} {...props}>
|
|
108
|
-
{
|
|
109
|
-
<span className="font-body">{name}</span>
|
|
152
|
+
{labelWithTooltip}
|
|
110
153
|
{contextWindow != null && (
|
|
111
|
-
<
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
154
|
+
<TooltipProvider delayDuration={300}>
|
|
155
|
+
<Tooltip>
|
|
156
|
+
<TooltipTrigger asChild>
|
|
157
|
+
<span className="ml-auto opacity-70 text-h6">
|
|
158
|
+
{usedTokens != null ? formatCount(usedTokens) : '—'}
|
|
159
|
+
{isV2 ? ' / ' : '/'}
|
|
160
|
+
{formatCount(contextWindow)} context budget
|
|
161
|
+
</span>
|
|
162
|
+
</TooltipTrigger>
|
|
163
|
+
<TooltipContent side="top" align="end">
|
|
164
|
+
{CONTEXT_BUDGET_HINT}
|
|
165
|
+
</TooltipContent>
|
|
166
|
+
</Tooltip>
|
|
167
|
+
</TooltipProvider>
|
|
116
168
|
)}
|
|
117
169
|
</div>
|
|
118
170
|
);
|
|
@@ -142,7 +142,15 @@ const ToolExecutionDisplay = forwardRef<HTMLDivElement, ToolExecutionDisplayProp
|
|
|
142
142
|
) : (
|
|
143
143
|
<>
|
|
144
144
|
{hasBody ? (
|
|
145
|
-
|
|
145
|
+
// Square: the frame clips the corners, so the hover keeps the frame's own rounding at the top
|
|
146
|
+
// and meets the open body flat at the bottom.
|
|
147
|
+
<Button
|
|
148
|
+
variant="row"
|
|
149
|
+
type="button"
|
|
150
|
+
aria-expanded={expanded}
|
|
151
|
+
onClick={() => setExpanded(prev => !prev)}
|
|
152
|
+
className="rounded-none"
|
|
153
|
+
>
|
|
146
154
|
{headerContent}
|
|
147
155
|
</Button>
|
|
148
156
|
) : (
|
|
@@ -539,6 +539,9 @@ export interface ChatInputProps extends Omit<TextareaHTMLAttributes<HTMLTextArea
|
|
|
539
539
|
/** Start adornment rendered inside the textarea's left edge (e.g. the
|
|
540
540
|
* composer `+` context-menu trigger). Forwarded to `Textarea.startIcon`. */
|
|
541
541
|
startIcon?: ReactNode;
|
|
542
|
+
/** End adornment between the editor and the Send / Stop button (e.g. the
|
|
543
|
+
* composer's ⋯ actions menu). */
|
|
544
|
+
endIcon?: ReactNode;
|
|
542
545
|
/** Suppress the textarea's own border/bg/radius — an outer card draws it
|
|
543
546
|
* instead (composer context-chip layout). Forwarded to `Textarea.hideBorder`. */
|
|
544
547
|
hideBorder?: boolean;
|
|
@@ -678,12 +681,13 @@ export interface AskDisplayProps extends Omit<HTMLAttributes<HTMLDivElement>, 'o
|
|
|
678
681
|
// ========== Model Display Props ==========
|
|
679
682
|
|
|
680
683
|
export interface ModelDisplayProps extends HTMLAttributes<HTMLDivElement> {
|
|
681
|
-
/** The model metadata is still loading: the row draws its own skeleton (with the "
|
|
684
|
+
/** The model metadata is still loading: the row draws its own skeleton (with the "context budget" tail when
|
|
682
685
|
* `contextWindow` is known). Inside a `LoadingScope` it does so whatever this says. */
|
|
683
686
|
loading?: boolean;
|
|
684
687
|
provider?: string;
|
|
685
688
|
modelName?: string;
|
|
686
689
|
displayName?: string;
|
|
690
|
+
/** The agent's context budget for the chat (its memory is compacted before it fills), not the model's window. */
|
|
687
691
|
contextWindow?: number;
|
|
688
692
|
usedTokens?: number;
|
|
689
693
|
showIcon?: boolean;
|
|
@@ -712,6 +716,11 @@ export interface ModelDisplayProps extends HTMLAttributes<HTMLDivElement> {
|
|
|
712
716
|
inputTokens?: number;
|
|
713
717
|
/** Answer call's output tokens — pairs with `inputTokens`. */
|
|
714
718
|
outputTokens?: number;
|
|
719
|
+
/** Makes the provider icon + model name a button (e.g. the host's AI
|
|
720
|
+
* settings, where the model is chosen). The token tail stays plain text. */
|
|
721
|
+
onModelClick?: () => void;
|
|
722
|
+
/** Tooltip over the model name (e.g. "Change in Settings → AI Settings"). */
|
|
723
|
+
modelTooltip?: string;
|
|
715
724
|
}
|
|
716
725
|
|
|
717
726
|
/**
|
|
@@ -739,6 +748,9 @@ export interface DialogItem {
|
|
|
739
748
|
/** Dialog owner (creator) — drives the trailing avatar in the chat-history
|
|
740
749
|
* rows (Figma 113:63224). Omit to render the row without an avatar. */
|
|
741
750
|
owner?: {
|
|
751
|
+
/** The owner's user id. With the viewer's (`currentUserId` on the chat
|
|
752
|
+
* lists) a list tells someone else's chat from the viewer's own. */
|
|
753
|
+
id?: string | null;
|
|
742
754
|
/** Full display name — initials fallback + `title` tooltip. */
|
|
743
755
|
name?: string | null;
|
|
744
756
|
/** Absolute avatar URL; falls back to initials when absent or failing. */
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { formatDateWithTimezone, VIEWER_TIMEZONE } from '../../../utils/format';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* The one rule for a chat's day caption — the chat page header ("· owner · day") and the day groups
|
|
5
|
+
* of the history lists both read it: "Today", "Yesterday", then the day in the viewer's own zone and
|
|
6
|
+
* locale ("9 Oct" / "Oct 9"), with the year when it is not this one. Local days; a time in the
|
|
7
|
+
* future counts as today. `null` for a missing or unparsable timestamp, so the caller leaves it out.
|
|
8
|
+
*/
|
|
9
|
+
export function chatDayLabel(timestamp: Date | string | null | undefined, now: Date = new Date()): string | null {
|
|
10
|
+
if (!timestamp) return null;
|
|
11
|
+
const date = typeof timestamp === 'string' ? new Date(timestamp) : timestamp;
|
|
12
|
+
const time = date.getTime();
|
|
13
|
+
if (Number.isNaN(time)) return null;
|
|
14
|
+
const startOfToday = new Date(now.getFullYear(), now.getMonth(), now.getDate()).getTime();
|
|
15
|
+
if (time >= startOfToday) return 'Today';
|
|
16
|
+
const startOfYesterday = new Date(now.getFullYear(), now.getMonth(), now.getDate() - 1).getTime();
|
|
17
|
+
if (time >= startOfYesterday) return 'Yesterday';
|
|
18
|
+
return formatDateWithTimezone(
|
|
19
|
+
date,
|
|
20
|
+
VIEWER_TIMEZONE,
|
|
21
|
+
{ day: 'numeric', month: 'short', year: date.getFullYear() === now.getFullYear() ? undefined : 'numeric' },
|
|
22
|
+
{ viewerLocale: true },
|
|
23
|
+
);
|
|
24
|
+
}
|
|
@@ -39,6 +39,8 @@ export interface BoardColumnProps {
|
|
|
39
39
|
* the same lane.
|
|
40
40
|
*/
|
|
41
41
|
touchMode?: boolean;
|
|
42
|
+
/** A CSS length the list keeps clear at its end (`BoardProps.laneEndInset`). */
|
|
43
|
+
endInset?: string;
|
|
42
44
|
/** Merged last, so the touch pager can override the fixed lane width. */
|
|
43
45
|
className?: string;
|
|
44
46
|
}
|
|
@@ -61,6 +63,7 @@ export const BoardColumn = memo(function BoardColumnImpl({
|
|
|
61
63
|
joinLeft = false,
|
|
62
64
|
joinRight = false,
|
|
63
65
|
touchMode = false,
|
|
66
|
+
endInset,
|
|
64
67
|
className,
|
|
65
68
|
}: BoardColumnProps) {
|
|
66
69
|
// The drop zone is the WHOLE lane, header included — not just the list. A
|
|
@@ -147,6 +150,7 @@ export const BoardColumn = memo(function BoardColumnImpl({
|
|
|
147
150
|
onLoadMore={onLoadMore}
|
|
148
151
|
loadMoreRootMargin={loadMoreRootMargin}
|
|
149
152
|
touchMode={touchMode}
|
|
153
|
+
endInset={endInset}
|
|
150
154
|
/>
|
|
151
155
|
</>
|
|
152
156
|
)}
|
|
@@ -163,6 +167,7 @@ interface ColumnBodyProps {
|
|
|
163
167
|
onLoadMore?: (columnId: string) => void;
|
|
164
168
|
loadMoreRootMargin: string;
|
|
165
169
|
touchMode: boolean;
|
|
170
|
+
endInset?: string;
|
|
166
171
|
}
|
|
167
172
|
|
|
168
173
|
function ColumnBody({
|
|
@@ -174,6 +179,7 @@ function ColumnBody({
|
|
|
174
179
|
onLoadMore,
|
|
175
180
|
loadMoreRootMargin,
|
|
176
181
|
touchMode,
|
|
182
|
+
endInset,
|
|
177
183
|
}: ColumnBodyProps) {
|
|
178
184
|
const scrollRef = useRef<HTMLDivElement | null>(null);
|
|
179
185
|
const sentinelRef = useRef<HTMLDivElement | null>(null);
|
|
@@ -232,6 +238,8 @@ function ColumnBody({
|
|
|
232
238
|
// is the sliver it lives in there — without it the line is clipped away by
|
|
233
239
|
// this element's own overflow exactly when a card is aimed at either end.
|
|
234
240
|
className="flex min-h-0 flex-1 flex-col gap-[var(--spacing-system-xs)] overflow-y-auto py-[5px] [overflow-anchor:none]"
|
|
241
|
+
// The end inset on top of that sliver: the last card scrolls clear of what lies over the board's bottom.
|
|
242
|
+
style={endInset ? { paddingBottom: `calc(5px + ${endInset})` } : undefined}
|
|
235
243
|
>
|
|
236
244
|
{column.isLoading ? (
|
|
237
245
|
// A lane loads one page of its tickets: its loading form draws that page, each card its own skeleton.
|
|
@@ -86,6 +86,12 @@ export interface BoardProps {
|
|
|
86
86
|
/** The lanes folded when the board mounts, by column id. Read only without `collapseStorageKey`. */
|
|
87
87
|
initialCollapsed?: Record<string, boolean>;
|
|
88
88
|
loadMoreRootMargin?: string;
|
|
89
|
+
/**
|
|
90
|
+
* A CSS length each lane keeps clear at the end of its list: a board that runs on
|
|
91
|
+
* under something lying over its bottom (the layout's floating composer dock,
|
|
92
|
+
* `var(--composer-dock-inset)`) scrolls a lane's last card out from under it.
|
|
93
|
+
*/
|
|
94
|
+
laneEndInset?: string;
|
|
89
95
|
className?: string;
|
|
90
96
|
}
|
|
91
97
|
|
|
@@ -134,7 +140,7 @@ function laneJoins(columns: BoardColumnDef[], i: number) {
|
|
|
134
140
|
* the drag board arranges them, each a `touchMode` lane (no drop target), none collapsed (the stored collapse is read
|
|
135
141
|
* after hydration). Nothing in it can be used, so it is inert.
|
|
136
142
|
*/
|
|
137
|
-
function BoardShell({ columns, className }: BoardProps) {
|
|
143
|
+
function BoardShell({ columns, laneEndInset, className }: BoardProps) {
|
|
138
144
|
return (
|
|
139
145
|
<div inert aria-hidden className={cn('flex h-full min-h-0 flex-col', className)}>
|
|
140
146
|
<div className="flex min-h-0 flex-1 overflow-x-hidden">
|
|
@@ -143,7 +149,13 @@ function BoardShell({ columns, className }: BoardProps) {
|
|
|
143
149
|
return (
|
|
144
150
|
<Fragment key={column.id}>
|
|
145
151
|
{showGap && <div aria-hidden className="w-[var(--spacing-system-mf)] shrink-0" />}
|
|
146
|
-
<BoardColumn
|
|
152
|
+
<BoardColumn
|
|
153
|
+
column={column}
|
|
154
|
+
touchMode
|
|
155
|
+
joinLeft={joinLeft}
|
|
156
|
+
joinRight={joinRight}
|
|
157
|
+
endInset={laneEndInset}
|
|
158
|
+
/>
|
|
147
159
|
</Fragment>
|
|
148
160
|
);
|
|
149
161
|
})}
|
|
@@ -176,6 +188,7 @@ function DragBoard({
|
|
|
176
188
|
collapseStorageKey,
|
|
177
189
|
initialCollapsed,
|
|
178
190
|
loadMoreRootMargin,
|
|
191
|
+
laneEndInset,
|
|
179
192
|
className,
|
|
180
193
|
}: BoardProps) {
|
|
181
194
|
const { collapsed, toggle } = useBoardCollapse(collapseStorageKey, initialCollapsed);
|
|
@@ -639,6 +652,7 @@ function DragBoard({
|
|
|
639
652
|
loadMoreRootMargin={loadMoreRootMargin}
|
|
640
653
|
joinLeft={joinLeft}
|
|
641
654
|
joinRight={joinRight}
|
|
655
|
+
endInset={laneEndInset}
|
|
642
656
|
/>
|
|
643
657
|
</Fragment>
|
|
644
658
|
);
|
|
@@ -35,6 +35,7 @@ export function TouchBoard({
|
|
|
35
35
|
collapseStorageKey,
|
|
36
36
|
initialCollapsed,
|
|
37
37
|
loadMoreRootMargin,
|
|
38
|
+
laneEndInset,
|
|
38
39
|
className,
|
|
39
40
|
}: BoardProps) {
|
|
40
41
|
const { collapsed, toggle } = useBoardCollapse(collapseStorageKey, initialCollapsed);
|
|
@@ -68,6 +69,7 @@ export function TouchBoard({
|
|
|
68
69
|
onReject={onReject}
|
|
69
70
|
onLoadMore={onLoadMore}
|
|
70
71
|
loadMoreRootMargin={loadMoreRootMargin}
|
|
72
|
+
endInset={laneEndInset}
|
|
71
73
|
/>
|
|
72
74
|
))}
|
|
73
75
|
</div>
|
|
@@ -20,7 +20,13 @@ export interface ApprovalRequestNotificationTileProps {
|
|
|
20
20
|
notification: Notification;
|
|
21
21
|
onApprove: (approvalRequestId: string) => void | Promise<void>;
|
|
22
22
|
onReject: (approvalRequestId: string) => void | Promise<void>;
|
|
23
|
-
|
|
23
|
+
/**
|
|
24
|
+
* Marks the notification complete: the tile's ✓, and after a successful
|
|
25
|
+
* Approve / Reject. Omit it for a card with no notification behind it (built
|
|
26
|
+
* from a chat's or a ticket's pending approval): no ✓ is drawn, and a
|
|
27
|
+
* decision completes nothing.
|
|
28
|
+
*/
|
|
29
|
+
onComplete?: (id: string) => void;
|
|
24
30
|
onSettle?: (id: string) => void;
|
|
25
31
|
liveDurationMs?: number;
|
|
26
32
|
defaultExpanded?: boolean;
|
|
@@ -98,7 +104,7 @@ export function ApprovalRequestNotificationTile({
|
|
|
98
104
|
}
|
|
99
105
|
// Outside the try: a throwing consumer callback must not roll back a request
|
|
100
106
|
// that already succeeded server-side.
|
|
101
|
-
onComplete(notification.id);
|
|
107
|
+
onComplete?.(notification.id);
|
|
102
108
|
};
|
|
103
109
|
|
|
104
110
|
return (
|
|
@@ -21,6 +21,11 @@ export interface NotificationDrawerProps {
|
|
|
21
21
|
liveDurationMs?: number;
|
|
22
22
|
loadMoreRootMargin?: string;
|
|
23
23
|
renderTile?: RenderNotificationTile;
|
|
24
|
+
/**
|
|
25
|
+
* Draw the title's × close button. Off by default: the header bell turns into × while the drawer
|
|
26
|
+
* is open. A host without a desktop header (`AppLayout desktopHeader={false}`) has no such bell.
|
|
27
|
+
*/
|
|
28
|
+
showClose?: boolean;
|
|
24
29
|
}
|
|
25
30
|
|
|
26
31
|
export function NotificationDrawer({
|
|
@@ -28,6 +33,7 @@ export function NotificationDrawer({
|
|
|
28
33
|
liveDurationMs,
|
|
29
34
|
loadMoreRootMargin = '200px',
|
|
30
35
|
renderTile: renderTileProp,
|
|
36
|
+
showClose = false,
|
|
31
37
|
}: NotificationDrawerProps) {
|
|
32
38
|
const ctx = useOptionalNotifications();
|
|
33
39
|
// Inside AppLayout the drawer renders in-layout (dims and covers only the
|
|
@@ -67,7 +73,7 @@ export function NotificationDrawer({
|
|
|
67
73
|
<>
|
|
68
74
|
<div className="px-[var(--spacing-system-m)] pt-[var(--spacing-system-m)]">
|
|
69
75
|
<DrawerTitle
|
|
70
|
-
hideClose
|
|
76
|
+
hideClose={!showClose}
|
|
71
77
|
className="truncate"
|
|
72
78
|
actions={
|
|
73
79
|
<Button
|
|
@@ -90,10 +90,13 @@ interface NotificationTileOptions {
|
|
|
90
90
|
/**
|
|
91
91
|
* The notification and what dismisses it, or `loading` while the host reads it: the tile then draws its own loading
|
|
92
92
|
* form, as it does in a loading scope (an approval tile, one given `actions`, draws its button row too).
|
|
93
|
+
*
|
|
94
|
+
* `onComplete` is the ✓ "Mark notification complete" control once the tile is no longer live. Omit it for a tile with
|
|
95
|
+
* no notification behind it (an approval card built from a chat or a ticket): no ✓ is drawn.
|
|
93
96
|
*/
|
|
94
97
|
export type NotificationTileProps = NotificationTileOptions &
|
|
95
98
|
(
|
|
96
|
-
| { notification: Notification; onComplete
|
|
99
|
+
| { notification: Notification; onComplete?: (id: string) => void; loading?: boolean }
|
|
97
100
|
| {
|
|
98
101
|
loading: true;
|
|
99
102
|
notification?: undefined;
|
|
@@ -105,7 +108,7 @@ export type NotificationTileProps = NotificationTileOptions &
|
|
|
105
108
|
|
|
106
109
|
type LoadedNotificationTileProps = NotificationTileOptions & {
|
|
107
110
|
notification: Notification;
|
|
108
|
-
onComplete
|
|
111
|
+
onComplete?: (id: string) => void;
|
|
109
112
|
};
|
|
110
113
|
|
|
111
114
|
/** A notification as a tile; ONE switch: in a loading scope (or `loading`) its own loading form. */
|
|
@@ -236,7 +239,8 @@ function LoadedNotificationTile({
|
|
|
236
239
|
</time>
|
|
237
240
|
) : null}
|
|
238
241
|
|
|
239
|
-
{
|
|
242
|
+
{/* Nothing to dismiss and nothing to complete: no slot at all. */}
|
|
243
|
+
{!lockscreen && (isLive || onComplete) && (
|
|
240
244
|
<>
|
|
241
245
|
{/* Live X and settled check swap in the same 16px slot; the inactive
|
|
242
246
|
one is removed from the a11y tree and disabled, not just faded. */}
|
|
@@ -248,12 +252,16 @@ function LoadedNotificationTile({
|
|
|
248
252
|
icon: <XmarkIcon size={16} />,
|
|
249
253
|
onClick: () => onSettle?.(id),
|
|
250
254
|
},
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
255
|
+
...(onComplete
|
|
256
|
+
? [
|
|
257
|
+
{
|
|
258
|
+
active: !isLive,
|
|
259
|
+
label: 'Mark notification complete',
|
|
260
|
+
icon: <CheckCircleIcon size={16} />,
|
|
261
|
+
onClick: () => onComplete(id),
|
|
262
|
+
},
|
|
263
|
+
]
|
|
264
|
+
: []),
|
|
257
265
|
].map(({ active, label, icon: actionIcon, onClick }) => (
|
|
258
266
|
<Button
|
|
259
267
|
variant="bare"
|