@krak-stack/registry 0.10.19 → 0.11.1
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/CHANGELOG.md +105 -0
- package/README.md +28 -7
- package/dist/components/agent/index.d.ts +454 -0
- package/dist/components/agent/react.d.ts +55 -0
- package/dist/components/agent/react.js +2594 -0
- package/dist/components/agent/schema.d.ts +55 -0
- package/dist/components/animated-list/classes.d.ts +9 -0
- package/dist/components/animated-list/html.d.ts +11 -0
- package/dist/components/animated-list/html.js +533 -0
- package/dist/components/animated-list/index.d.ts +205 -0
- package/dist/components/animated-list/react.d.ts +11 -0
- package/dist/components/animated-list/react.js +711 -0
- package/dist/components/animated-list/schema.d.ts +44 -0
- package/dist/components/animated-number/html.d.ts +19 -0
- package/dist/components/animated-number/html.js +101 -0
- package/dist/components/animated-number/index.d.ts +80 -0
- package/dist/components/{ui/animated-number.d.ts → animated-number/react.d.ts} +2 -7
- package/dist/components/animated-number/react.js +278 -0
- package/dist/components/animated-number/schema.d.ts +9 -0
- package/dist/components/app-brand/classes.d.ts +11 -0
- package/dist/components/app-brand/html.d.ts +26 -0
- package/dist/components/app-brand/html.js +78 -0
- package/dist/components/app-brand/react.d.ts +12 -0
- package/dist/components/app-brand/react.js +86 -0
- package/dist/components/app-brand/schema.d.ts +36 -0
- package/dist/components/app-switcher/classes.d.ts +15 -0
- package/dist/components/app-switcher/html.d.ts +72 -0
- package/dist/components/app-switcher/html.js +327 -0
- package/dist/components/app-switcher/index.d.ts +47 -0
- package/dist/components/app-switcher/react.d.ts +12 -0
- package/dist/components/{ui/app-switcher.js → app-switcher/react.js} +84 -15
- package/dist/components/app-switcher/schema.d.ts +39 -0
- package/dist/components/async-action-button/classes.d.ts +11 -0
- package/dist/components/async-action-button/html.d.ts +46 -0
- package/dist/components/async-action-button/html.js +266 -0
- package/dist/components/async-action-button/index.d.ts +73 -0
- package/dist/components/async-action-button/react.d.ts +10 -0
- package/dist/components/async-action-button/react.js +378 -0
- package/dist/components/async-action-button/schema.d.ts +28 -0
- package/dist/{services/events/client/audit-log-table.d.ts → components/audit-log-table/react.d.ts} +2 -2
- package/dist/{services/events/client/audit-log-table.js → components/audit-log-table/react.js} +2195 -918
- package/dist/components/auto-height/html.d.ts +8 -0
- package/dist/components/auto-height/html.js +81 -0
- package/dist/components/auto-height/index.d.ts +2 -0
- package/dist/components/{ui/auto-height.d.ts → auto-height/react.d.ts} +2 -4
- package/dist/components/auto-height/react.js +75 -0
- package/dist/components/auto-height/schema.d.ts +7 -0
- package/dist/components/bulk-list-input/classes.d.ts +7 -0
- package/dist/components/bulk-list-input/html.d.ts +41 -0
- package/dist/components/bulk-list-input/html.js +265 -0
- package/dist/components/bulk-list-input/index.d.ts +76 -0
- package/dist/components/bulk-list-input/react.d.ts +12 -0
- package/dist/components/{ui/bulk-list-input.js → bulk-list-input/react.js} +71 -4
- package/dist/components/bulk-list-input/schema.d.ts +33 -0
- package/dist/components/choice-cards/classes.d.ts +19 -0
- package/dist/components/choice-cards/html.d.ts +76 -0
- package/dist/components/choice-cards/html.js +237 -0
- package/dist/components/choice-cards/index.d.ts +1 -0
- package/dist/components/choice-cards/react.d.ts +21 -0
- package/dist/components/{ui/choice-cards.js → choice-cards/react.js} +29 -10
- package/dist/components/choice-cards/schema.d.ts +100 -0
- package/dist/components/code-block/classes.d.ts +13 -0
- package/dist/components/code-block/html.d.ts +21 -0
- package/dist/components/code-block/html.js +381 -0
- package/dist/components/code-block/index.d.ts +4 -0
- package/dist/components/code-block/react.d.ts +4 -0
- package/dist/components/code-block/react.js +493 -0
- package/dist/components/code-block/schema.d.ts +29 -0
- package/dist/components/color-input/classes.d.ts +9 -0
- package/dist/components/color-input/html.d.ts +48 -0
- package/dist/components/color-input/html.js +187 -0
- package/dist/components/color-input/index.d.ts +88 -0
- package/dist/components/color-input/react.d.ts +7 -0
- package/dist/components/{ui/color-picker.js → color-input/react.js} +165 -233
- package/dist/components/color-input/schema.d.ts +40 -0
- package/dist/components/copy-button/html.d.ts +48 -0
- package/dist/components/copy-button/html.js +266 -0
- package/dist/components/copy-button/index.d.ts +73 -0
- package/dist/components/copy-button/react.d.ts +12 -0
- package/dist/components/copy-button/react.js +388 -0
- package/dist/components/copy-button/schema.d.ts +37 -0
- package/dist/components/copy-value/html.d.ts +37 -0
- package/dist/components/copy-value/html.js +426 -0
- package/dist/components/copy-value/index.d.ts +57 -0
- package/dist/components/copy-value/react.d.ts +9 -0
- package/dist/components/copy-value/react.js +682 -0
- package/dist/components/copy-value/schema.d.ts +45 -0
- package/dist/components/cron-input/classes.d.ts +25 -0
- package/dist/components/cron-input/html.d.ts +36 -0
- package/dist/components/cron-input/html.js +204 -0
- package/dist/components/cron-input/index.d.ts +59 -0
- package/dist/components/cron-input/react.d.ts +7 -0
- package/dist/components/{ui/cron-expression-editor.js → cron-input/react.js} +126 -54
- package/dist/components/cron-input/schema.d.ts +24 -0
- package/dist/components/danger-confirmation/classes.d.ts +7 -0
- package/dist/components/danger-confirmation/html.d.ts +39 -0
- package/dist/components/danger-confirmation/html.js +227 -0
- package/dist/components/danger-confirmation/index.d.ts +113 -0
- package/dist/components/{ui/danger-confirmation.d.ts → danger-confirmation/react.d.ts} +3 -12
- package/dist/components/danger-confirmation/react.js +550 -0
- package/dist/components/danger-confirmation/schema.d.ts +34 -0
- package/dist/components/data-table/classes.d.ts +63 -0
- package/dist/components/data-table/html.d.ts +1938 -0
- package/dist/components/data-table/html.js +2682 -0
- package/dist/components/data-table/index.d.ts +2686 -0
- package/dist/components/data-table/react.d.ts +578 -0
- package/dist/components/{ui/data-table.js → data-table/react.js} +2189 -906
- package/dist/components/data-table/schema.d.ts +3012 -0
- package/dist/components/date-input/classes.d.ts +17 -0
- package/dist/components/date-input/html.d.ts +60 -0
- package/dist/components/date-input/html.js +418 -0
- package/dist/components/date-input/index.d.ts +91 -0
- package/dist/components/date-input/react.d.ts +10 -0
- package/dist/components/{ui/date-picker.js → date-input/react.js} +233 -79
- package/dist/components/date-input/schema.d.ts +41 -0
- package/dist/components/editable-text/classes.d.ts +17 -0
- package/dist/components/editable-text/html.d.ts +51 -0
- package/dist/components/editable-text/html.js +370 -0
- package/dist/components/editable-text/index.d.ts +143 -0
- package/dist/components/editable-text/react.d.ts +6 -0
- package/dist/components/editable-text/react.js +499 -0
- package/dist/components/editable-text/schema.d.ts +31 -0
- package/dist/components/editing-locale-switcher/classes.d.ts +7 -0
- package/dist/components/editing-locale-switcher/html.d.ts +27 -0
- package/dist/components/editing-locale-switcher/html.js +250 -0
- package/dist/components/editing-locale-switcher/index.d.ts +52 -0
- package/dist/components/editing-locale-switcher/react.d.ts +7 -0
- package/dist/components/{ui/editing-locale-switcher.js → editing-locale-switcher/react.js} +70 -17
- package/dist/components/editing-locale-switcher/schema.d.ts +16 -0
- package/dist/components/{ui/effect-form.d.ts → effect-form/react.d.ts} +2 -2
- package/dist/components/{ui/effect-form.js → effect-form/react.js} +309 -83
- package/dist/components/effectcn/alert-dialog.d.ts +13 -0
- package/dist/components/effectcn/button.d.ts +31 -0
- package/dist/components/effectcn/calendar.d.ts +12 -0
- package/dist/components/effectcn/checkbox.d.ts +10 -0
- package/dist/components/effectcn/combobox.d.ts +25 -0
- package/dist/components/effectcn/dialog.d.ts +19 -0
- package/dist/components/effectcn/field.d.ts +11 -0
- package/dist/components/effectcn/file-drop.d.ts +8 -0
- package/dist/components/effectcn/input.d.ts +26 -0
- package/dist/components/effectcn/menu.d.ts +85 -0
- package/dist/components/effectcn/menubar.d.ts +8 -0
- package/dist/components/effectcn/popover.d.ts +18 -0
- package/dist/components/effectcn/scroll-area.d.ts +12 -0
- package/dist/components/effectcn/select.d.ts +68 -0
- package/dist/components/effectcn/toast.d.ts +29 -0
- package/dist/components/email-composer/index.d.ts +229 -0
- package/dist/components/email-composer/labels.d.ts +12 -0
- package/dist/components/email-composer/react.d.ts +5 -0
- package/dist/components/email-composer/react.js +1354 -0
- package/dist/components/email-composer/schema.d.ts +42 -0
- package/dist/components/email-editor/classes.d.ts +21 -0
- package/dist/components/email-editor/html.d.ts +360 -0
- package/dist/components/email-editor/html.js +1706 -0
- package/dist/components/email-editor/index.d.ts +693 -0
- package/dist/components/{ui/email-editor.d.ts → email-editor/labels.d.ts} +1 -19
- package/dist/components/email-editor/legacy-editor.html.d.ts +160 -0
- package/dist/components/email-editor/react.d.ts +11 -0
- package/dist/components/{ui/email-editor.js → email-editor/react.js} +1057 -712
- package/dist/components/email-editor/schema.d.ts +162 -0
- package/dist/components/error-component/classes.d.ts +7 -0
- package/dist/components/error-component/html.d.ts +120 -0
- package/dist/components/error-component/html.js +346 -0
- package/dist/components/error-component/index.d.ts +69 -0
- package/dist/components/error-component/react.d.ts +8 -0
- package/dist/components/error-component/react.js +744 -0
- package/dist/components/error-component/schema.d.ts +56 -0
- package/dist/components/file-input/classes.d.ts +7 -0
- package/dist/components/file-input/html.d.ts +95 -0
- package/dist/components/file-input/html.js +368 -0
- package/dist/components/file-input/index.d.ts +99 -0
- package/dist/components/file-input/react.d.ts +11 -0
- package/dist/components/{ui/file-picker.js → file-input/react.js} +122 -19
- package/dist/components/file-input/schema.d.ts +37 -0
- package/dist/components/{ui/form.d.ts → form/react.d.ts} +4 -4
- package/dist/components/{ui/form.js → form/react.js} +314 -84
- package/dist/components/icon-input/html.d.ts +55 -0
- package/dist/components/icon-input/html.js +538 -0
- package/dist/components/icon-input/index.d.ts +143 -0
- package/dist/components/icon-input/react.d.ts +6 -0
- package/dist/components/{ui/icon-input.js → icon-input/react.js} +459 -89
- package/dist/components/icon-input/schema.d.ts +23 -0
- package/dist/components/image-crop-editor/classes.d.ts +19 -0
- package/dist/components/image-crop-editor/html.d.ts +66 -0
- package/dist/components/image-crop-editor/html.js +561 -0
- package/dist/components/image-crop-editor/index.d.ts +183 -0
- package/dist/components/image-crop-editor/react.d.ts +8 -0
- package/dist/components/image-crop-editor/react.js +802 -0
- package/dist/components/image-crop-editor/schema.d.ts +54 -0
- package/dist/components/krakstack-provider/html.d.ts +17 -0
- package/dist/components/krakstack-provider/html.js +37 -0
- package/dist/components/krakstack-provider/index.d.ts +7 -0
- package/dist/components/krakstack-provider/react.d.ts +8 -0
- package/dist/components/{ui/krakstack-provider.js → krakstack-provider/react.js} +14 -5
- package/dist/components/krakstack-provider/schema.d.ts +6 -0
- package/dist/components/loading/classes.d.ts +5 -0
- package/dist/components/loading/html.d.ts +18 -0
- package/dist/components/loading/html.js +166 -0
- package/dist/components/loading/index.d.ts +6 -0
- package/dist/components/loading/react.d.ts +4 -0
- package/dist/components/loading/react.js +51 -0
- package/dist/components/loading/schema.d.ts +23 -0
- package/dist/components/locale-switcher/html.d.ts +22 -0
- package/dist/components/locale-switcher/html.js +264 -0
- package/dist/components/locale-switcher/index.d.ts +50 -0
- package/dist/components/locale-switcher/react.d.ts +7 -0
- package/dist/components/{ui/locale-switcher.js → locale-switcher/react.js} +55 -22
- package/dist/components/locale-switcher/schema.d.ts +12 -0
- package/dist/components/map-menu/classes.d.ts +13 -0
- package/dist/components/map-menu/google-maps.d.ts +80 -0
- package/dist/components/map-menu/google-viewport.d.ts +7 -0
- package/dist/components/map-menu/html.d.ts +274 -0
- package/dist/components/map-menu/html.js +934 -0
- package/dist/components/map-menu/index.d.ts +246 -0
- package/dist/components/map-menu/map.d.ts +47 -0
- package/dist/components/map-menu/react.d.ts +40 -0
- package/dist/components/{ui/map-menu.js → map-menu/react.js} +502 -141
- package/dist/components/map-menu/schema.d.ts +132 -0
- package/dist/components/markdown/classes.d.ts +1 -0
- package/dist/components/markdown/html.d.ts +23 -0
- package/dist/components/markdown/html.js +510 -0
- package/dist/components/markdown/index.d.ts +6 -0
- package/dist/components/markdown/react.d.ts +3 -0
- package/dist/components/markdown/react.js +546 -0
- package/dist/components/markdown/schema.d.ts +20 -0
- package/dist/components/notification-menu/classes.d.ts +11 -0
- package/dist/components/notification-menu/html.d.ts +67 -0
- package/dist/components/notification-menu/html.js +425 -0
- package/dist/components/notification-menu/index.d.ts +132 -0
- package/dist/components/notification-menu/react.d.ts +57 -0
- package/dist/components/notification-menu/react.js +829 -0
- package/dist/components/notification-menu/schema.d.ts +59 -0
- package/dist/components/pagination/classes.d.ts +19 -0
- package/dist/components/pagination/html.d.ts +49 -0
- package/dist/components/pagination/html.js +387 -0
- package/dist/components/pagination/index.d.ts +109 -0
- package/dist/components/pagination/react.d.ts +9 -0
- package/dist/components/{ui/pagination.js → pagination/react.js} +130 -30
- package/dist/components/pagination/schema.d.ts +36 -0
- package/dist/components/phone-number-input/classes.d.ts +17 -0
- package/dist/components/phone-number-input/html.d.ts +52 -0
- package/dist/components/phone-number-input/html.js +655 -0
- package/dist/components/phone-number-input/index.d.ts +59 -0
- package/dist/components/phone-number-input/react.d.ts +11 -0
- package/dist/components/{ui/phone-number-input.js → phone-number-input/react.js} +368 -138
- package/dist/components/phone-number-input/schema.d.ts +31 -0
- package/dist/components/presence-transition/html.d.ts +13 -0
- package/dist/components/presence-transition/html.js +128 -0
- package/dist/components/presence-transition/index.d.ts +57 -0
- package/dist/components/{ui/presence-transition.d.ts → presence-transition/react.d.ts} +3 -5
- package/dist/components/presence-transition/react.js +293 -0
- package/dist/components/presence-transition/schema.d.ts +7 -0
- package/dist/components/registry-previews/component-example.d.ts +31 -0
- package/dist/components/registry-previews/component-example.js +679 -0
- package/dist/components/registry-previews/html-preview.d.ts +17 -0
- package/dist/components/registry-previews/html-preview.js +83 -0
- package/dist/components/rich-text-editor/classes.d.ts +15 -0
- package/dist/components/rich-text-editor/engine.d.ts +9 -0
- package/dist/components/rich-text-editor/html.d.ts +246 -0
- package/dist/components/rich-text-editor/html.js +830 -0
- package/dist/components/rich-text-editor/index.d.ts +453 -0
- package/dist/components/rich-text-editor/labels.d.ts +42 -0
- package/dist/components/rich-text-editor/react.d.ts +19 -0
- package/dist/components/rich-text-editor/react.js +1175 -0
- package/dist/components/rich-text-editor/schema.d.ts +116 -0
- package/dist/components/search-menu/classes.d.ts +9 -0
- package/dist/components/search-menu/html.d.ts +127 -0
- package/dist/components/search-menu/html.js +432 -0
- package/dist/components/search-menu/index.d.ts +85 -0
- package/dist/components/search-menu/react.d.ts +18 -0
- package/dist/components/{ui/search-menu.js → search-menu/react.js} +290 -31
- package/dist/components/search-menu/schema.d.ts +78 -0
- package/dist/components/select-with-custom-input/classes.d.ts +17 -0
- package/dist/components/select-with-custom-input/html.d.ts +60 -0
- package/dist/components/select-with-custom-input/html.js +238 -0
- package/dist/components/select-with-custom-input/index.d.ts +114 -0
- package/dist/components/select-with-custom-input/react.d.ts +7 -0
- package/dist/components/{ui/select-with-custom-input.js → select-with-custom-input/react.js} +134 -29
- package/dist/components/select-with-custom-input/schema.d.ts +54 -0
- package/dist/components/sidebar-layout/classes.d.ts +21 -0
- package/dist/components/sidebar-layout/html.d.ts +97 -0
- package/dist/components/sidebar-layout/html.js +361 -0
- package/dist/components/sidebar-layout/index.d.ts +57 -0
- package/dist/components/sidebar-layout/react.d.ts +30 -0
- package/dist/components/{ui/sidebar-layout.js → sidebar-layout/react.js} +353 -39
- package/dist/components/sidebar-layout/schema.d.ts +54 -0
- package/dist/components/stats-card/classes.d.ts +11 -0
- package/dist/components/stats-card/html.d.ts +15 -0
- package/dist/components/stats-card/html.js +55 -0
- package/dist/components/stats-card/react.d.ts +7 -0
- package/dist/components/{ui/stats-card.js → stats-card/react.js} +19 -15
- package/dist/components/stats-card/schema.d.ts +14 -0
- package/dist/components/stepper/classes.d.ts +39 -0
- package/dist/components/stepper/html.d.ts +107 -0
- package/dist/components/stepper/html.js +397 -0
- package/dist/components/stepper/index.d.ts +83 -0
- package/dist/components/stepper/react.d.ts +17 -0
- package/dist/components/{ui/stepper.js → stepper/react.js} +120 -21
- package/dist/components/stepper/schema.d.ts +52 -0
- package/dist/components/support/classes.d.ts +55 -0
- package/dist/components/support/form.d.ts +19 -0
- package/dist/components/support/html.d.ts +266 -0
- package/dist/components/support/html.js +604 -0
- package/dist/components/support/index.d.ts +226 -0
- package/dist/components/support/multipart.d.ts +21 -0
- package/dist/components/support/react.d.ts +54 -0
- package/dist/components/support/react.js +1252 -0
- package/dist/components/support/schema.d.ts +69 -0
- package/dist/components/support.d.ts +1 -66
- package/dist/components/theme-switcher/html.d.ts +28 -0
- package/dist/components/theme-switcher/html.js +288 -0
- package/dist/components/theme-switcher/index.d.ts +59 -0
- package/dist/components/{ui/theme-switcher.d.ts → theme-switcher/react.d.ts} +4 -12
- package/dist/components/{ui/theme-switcher.js → theme-switcher/react.js} +69 -35
- package/dist/components/theme-switcher/schema.d.ts +33 -0
- package/dist/components/time-input/classes.d.ts +23 -0
- package/dist/components/time-input/html.d.ts +75 -0
- package/dist/components/time-input/html.js +571 -0
- package/dist/components/time-input/index.d.ts +164 -0
- package/dist/components/time-input/react.d.ts +7 -0
- package/dist/components/{ui/time-picker.js → time-input/react.js} +286 -114
- package/dist/components/time-input/schema.d.ts +96 -0
- package/dist/components/timezone-input/classes.d.ts +13 -0
- package/dist/components/timezone-input/html.d.ts +58 -0
- package/dist/components/timezone-input/html.js +804 -0
- package/dist/components/timezone-input/index.d.ts +170 -0
- package/dist/components/timezone-input/react.d.ts +9 -0
- package/dist/components/{ui/timezone-select.js → timezone-input/react.js} +493 -106
- package/dist/components/timezone-input/schema.d.ts +43 -0
- package/dist/components/toast/classes.d.ts +7 -0
- package/dist/components/toast/html.d.ts +34 -0
- package/dist/components/toast/html.js +280 -0
- package/dist/components/toast/index.d.ts +10 -0
- package/dist/components/toast/react.d.ts +9 -0
- package/dist/components/{ui/toast.js → toast/react.js} +35 -15
- package/dist/components/toast/schema.d.ts +24 -0
- package/dist/{services/events/client/tracking-notice.d.ts → components/tracking-notice/react.d.ts} +7 -1
- package/dist/{services/events/client/tracking-notice.js → components/tracking-notice/react.js} +13 -7
- package/dist/components/ui/animated-list.d.ts +1 -21
- package/dist/components/ui/app-brand.d.ts +1 -33
- package/dist/components/ui/async-action-button.d.ts +1 -17
- package/dist/components/ui/code-block.d.ts +1 -14
- package/dist/components/ui/copy-button.d.ts +1 -21
- package/dist/components/ui/data-table.d.ts +1 -584
- package/dist/components/ui/krakstack-provider.d.ts +1 -9
- package/dist/components/ui/loading.d.ts +1 -13
- package/dist/components/ui/pagination.d.ts +1 -47
- package/dist/components/ui/rich-text-editor.d.ts +1 -70
- package/dist/components/ui/search-menu.d.ts +1 -36
- package/dist/components/ui/select.js +159 -0
- package/dist/components/ui/sidebar-layout.d.ts +1 -40
- package/dist/components/ui/virtualized-combobox.d.ts +1 -59
- package/dist/components/unsaved-changes-guard/html.d.ts +34 -0
- package/dist/components/unsaved-changes-guard/html.js +172 -0
- package/dist/components/unsaved-changes-guard/index.d.ts +56 -0
- package/dist/components/unsaved-changes-guard/react.d.ts +4 -0
- package/dist/components/{ui/unsaved-changes-guard.js → unsaved-changes-guard/react.js} +74 -11
- package/dist/components/unsaved-changes-guard/schema.d.ts +37 -0
- package/dist/components/upload-attachment/classes.d.ts +11 -0
- package/dist/components/upload-attachment/html.d.ts +84 -0
- package/dist/components/upload-attachment/html.js +312 -0
- package/dist/components/upload-attachment/index.d.ts +72 -0
- package/dist/components/upload-attachment/react.d.ts +9 -0
- package/dist/components/{ui/upload-attachment.js → upload-attachment/react.js} +114 -17
- package/dist/components/upload-attachment/schema.d.ts +53 -0
- package/dist/components/virtualized-combobox/classes.d.ts +7 -0
- package/dist/components/virtualized-combobox/html.d.ts +97 -0
- package/dist/components/virtualized-combobox/html.js +310 -0
- package/dist/components/virtualized-combobox/index.d.ts +182 -0
- package/dist/components/virtualized-combobox/react.d.ts +31 -0
- package/dist/components/{ui/virtualized-combobox.js → virtualized-combobox/react.js} +160 -40
- package/dist/components/virtualized-combobox/schema.d.ts +92 -0
- package/dist/components/webhook-delivery-table/html.d.ts +216 -0
- package/dist/components/webhook-delivery-table/html.js +3008 -0
- package/dist/components/webhook-delivery-table/index.d.ts +405 -0
- package/dist/components/webhook-delivery-table/react.d.ts +13 -0
- package/dist/{services/webhooks/client/delivery-table.js → components/webhook-delivery-table/react.js} +2475 -956
- package/dist/components/webhook-delivery-table/schema.d.ts +134 -0
- package/dist/lib/docs.d.ts +17 -1
- package/dist/lib/docs.integrations.server.js +358 -73
- package/dist/lib/docs.js +861 -293
- package/dist/lib/docs.server.js +342 -57
- package/dist/lib/documentation-toolkit.d.ts +4 -4
- package/dist/lib/documentation-toolkit.js +354 -69
- package/dist/lib/effect-ui-adapter/model-runtime.d.ts +17 -0
- package/dist/lib/effect-ui-adapter/use-model.d.ts +9 -0
- package/dist/lib/effectcn-form.d.ts +3 -0
- package/dist/lib/effectcn-form.js +54 -0
- package/dist/lib/email-composer/index.d.ts +12 -0
- package/dist/lib/email-composer/index.js +110 -0
- package/dist/lib/email-composer/schema.d.ts +14 -0
- package/dist/lib/email-composer/schema.js +13 -0
- package/dist/lib/email-document/legacy-rich-text/editor.d.ts +70 -0
- package/dist/lib/email-document/legacy-rich-text/model.d.ts +19 -0
- package/dist/lib/email-document/legacy-rich-text/schema.d.ts +65 -0
- package/dist/lib/email-document/legacy-rich-text/tiptap.d.ts +39 -0
- package/dist/lib/email-document/model.d.ts +1 -1
- package/dist/lib/email-document/model.js +2 -2
- package/dist/lib/email-document/render.js +2 -2
- package/dist/lib/email-document/schema.js +1 -1
- package/dist/lib/httpapi-toolkit.d.ts +1 -1
- package/dist/lib/lucide-effect.d.ts +39 -0
- package/dist/lib/markdown/content.d.ts +1 -12
- package/dist/lib/rich-text/model.d.ts +5 -19
- package/dist/lib/rich-text/model.js +79 -111
- package/dist/lib/rich-text/schema.d.ts +5 -55
- package/dist/lib/rich-text/schema.js +17 -36
- package/dist/lib/rich-text/tiptap.d.ts +12 -0
- package/dist/lib/webfetch-toolkit.d.ts +1 -1
- package/dist/services/agent/client/index.js +695 -179
- package/dist/services/agent/client/widget.d.ts +1 -55
- package/dist/services/notification/client/index.js +138 -27
- package/dist/services/notification/client/notification-menu.d.ts +1 -85
- package/dist/services/notification/public.js +138 -27
- package/dist/services/opentelemetry/browser.js +15 -9
- package/dist/services/webhooks/index.d.ts +4 -3
- package/package.json +199 -137
- package/dist/components/support-dialog.js +0 -881
- package/dist/components/support.js +0 -881
- package/dist/components/ui/animated-list.js +0 -414
- package/dist/components/ui/animated-number.js +0 -75
- package/dist/components/ui/app-brand.js +0 -126
- package/dist/components/ui/app-switcher.d.ts +0 -26
- package/dist/components/ui/async-action-button.js +0 -149
- package/dist/components/ui/auto-height.js +0 -86
- package/dist/components/ui/bulk-list-input.d.ts +0 -25
- package/dist/components/ui/choice-cards.d.ts +0 -33
- package/dist/components/ui/code-block.js +0 -221
- package/dist/components/ui/color-picker.d.ts +0 -31
- package/dist/components/ui/copy-button.js +0 -138
- package/dist/components/ui/copy-value.d.ts +0 -24
- package/dist/components/ui/copy-value.js +0 -352
- package/dist/components/ui/cron-expression-editor.d.ts +0 -16
- package/dist/components/ui/cron-expression-editor.schema.d.ts +0 -7
- package/dist/components/ui/danger-confirmation.js +0 -398
- package/dist/components/ui/date-picker.d.ts +0 -33
- package/dist/components/ui/date-picker.schema.d.ts +0 -9
- package/dist/components/ui/editable-text.d.ts +0 -19
- package/dist/components/ui/editable-text.js +0 -341
- package/dist/components/ui/editing-locale-switcher.d.ts +0 -11
- package/dist/components/ui/error-component.d.ts +0 -34
- package/dist/components/ui/error-component.js +0 -387
- package/dist/components/ui/file-picker.d.ts +0 -37
- package/dist/components/ui/icon-input.d.ts +0 -58
- package/dist/components/ui/image-crop-editor.d.ts +0 -41
- package/dist/components/ui/image-crop-editor.js +0 -417
- package/dist/components/ui/loading.js +0 -39
- package/dist/components/ui/locale-switcher.d.ts +0 -11
- package/dist/components/ui/map-menu-map.d.ts +0 -115
- package/dist/components/ui/map-menu.d.ts +0 -87
- package/dist/components/ui/phone-number-input.d.ts +0 -22
- package/dist/components/ui/phone-number-input.schema.d.ts +0 -7
- package/dist/components/ui/presence-transition.js +0 -94
- package/dist/components/ui/rich-text-editor.js +0 -1135
- package/dist/components/ui/select-with-custom-input.d.ts +0 -36
- package/dist/components/ui/stats-card.d.ts +0 -12
- package/dist/components/ui/stepper.d.ts +0 -37
- package/dist/components/ui/time-picker.d.ts +0 -50
- package/dist/components/ui/time-picker.schema.d.ts +0 -28
- package/dist/components/ui/timezone-select.d.ts +0 -57
- package/dist/components/ui/timezone-select.schema.d.ts +0 -9
- package/dist/components/ui/toast.d.ts +0 -18
- package/dist/components/ui/unsaved-changes-guard.d.ts +0 -16
- package/dist/components/ui/upload-attachment.d.ts +0 -39
- package/dist/lib/rich-text/dom.d.ts +0 -40
- package/dist/services/notification/persistence/drizzle.d.ts +0 -868
- package/dist/services/notification/persistence/drizzle.js +0 -214
- package/dist/services/notification/persistence/index.d.ts +0 -2
- package/dist/services/notification/persistence/index.js +0 -227
- package/dist/services/notification/persistence/schema.d.ts +0 -143
- package/dist/services/notification/persistence/schema.js +0 -118
- package/dist/services/webhooks/client/delivery-table.d.ts +0 -62
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,110 @@
|
|
|
1
1
|
# @krak-stack/registry
|
|
2
2
|
|
|
3
|
+
## 0.11.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 6cc75d9: Make AppBrand non-interactive in React and add a static Effect UI HTML renderer. Move any existing `to`, `href`, and link props to a surrounding link. Remove `to={null}` from static instances.
|
|
8
|
+
- 63bc4fc: Add an Effect UI HTML AsyncActionButton with an `/async-action-button/html` package import and `@krak-stack/async-action-button-html` source install. React and HTML share pending, retry, and duplicate-activation behavior. Existing React imports and props remain supported.
|
|
9
|
+
- f450775: Add Effect UI HTML renderers and shadcn install items for CopyButton and CopyValue. React and HTML share clipboard feedback and reveal behavior. Existing React imports and props remain supported.
|
|
10
|
+
- 241f843: Use the ghost variant for the Code Block copy button in React and Effect UI HTML.
|
|
11
|
+
- 3a7ae58: Expose typed `classes` overrides for shared style slots in React and Effect UI HTML components. Existing styling props continue to work.
|
|
12
|
+
- 3a7ae58: Add React DataTable workflows to Effect UI HTML: search, typed filters and dates, controlled client and server paging, column visibility and resizing, grouping, gallery, CSV and JSON export, row reordering, list actions, and row windowing. The platform previews share the same project data.
|
|
13
|
+
|
|
14
|
+
Match the React table’s full-width header triggers, column-edge resize handles, and compact row actions. Resize by dragging or using the arrow keys, or double-click the handle to restore the default width.
|
|
15
|
+
|
|
16
|
+
Share table layout classes across React and HTML. Align selection checkboxes, style the Selected actions menu, keep overflowing content inside its cell, and align relationship cells and group rows.
|
|
17
|
+
|
|
18
|
+
Place search and the menubar inline when space permits, and wrap the toolbar and menu controls on narrow tables.
|
|
19
|
+
|
|
20
|
+
Keep the HTML bulk-action count and targeted rows in sync, move rows between groups when dropped onto a row or card, and request the last valid server page when the current page disappears.
|
|
21
|
+
- bc3aeab: Keep React DataTable hydration consistent when saved preferences load early, and keep the table mounted while preferences are being saved.
|
|
22
|
+
- 241f843: Use the same Effect UI model for React and HTML DataTable state and saved preferences. Existing React query callbacks and saved browser preferences continue to work.
|
|
23
|
+
|
|
24
|
+
Both renderers also share the row-processing pipeline. Current-page exports now match the rows shown when client-side grouping turns pagination off.
|
|
25
|
+
- be6c9c6: Rename `DatePicker` to `DateInput` and replace the `date-picker` registry and package paths with `date-input`. The calendar and clear buttons sit inside the field in React and Effect UI HTML and accept overrides through `actionClassName`.
|
|
26
|
+
- be6c9c6: Rename Cron Expression Editor to Cron Input. Use the `CronInput` export from `@krak-stack/registry/cron-input/react` or `@krak-stack/registry/cron-input/html`, and `@krak-stack/cron-input` or `@krak-stack/cron-input-html` for shadcn installs. The docs moved to `/docs/cron-input`. Both renderers use Effect's built-in `Cron` module. The input still accepts five fields, but previews now follow Effect's cron semantics. Check schedules that combine wildcard steps in one day field with a restricted other day field, or use `cron-parser` extensions such as `L` and `#`.
|
|
27
|
+
- Fix source installs under custom component aliases and keep HTML-only registry installs free of React. Preserve the existing Support, Danger Confirmation, Events, and Webhooks React imports. Restore the published React Select defaults and the Map Menu 50 Km preset, and focus the search field when the HTML Search Menu opens. Notifications inbox and administration components now declare the registry version that provides their renderer imports.
|
|
28
|
+
- 62fd4ea: Remove the Form and Effect Form HTML adapters and their source-install items. Use Effect UI's built-in form validation (`Validation` from `effect/ui`) instead of `@krak-stack/registry/form/html` or `@krak-stack/registry/effect-form/html`. The React components are unchanged.
|
|
29
|
+
- 3a7ae58: Rename `TimezoneSelect`, `ColorPicker`, and `FilePicker` to `TimezoneInput`, `ColorInput`, and `FileInput` in React and Effect UI HTML. Update imports, source installs, and docs links to `timezone-input`, `color-input`, and `file-input`; the old names and paths are no longer available.
|
|
30
|
+
- 6cc75d9: Add an Effect UI HTML renderer for Loading. Both renderers share localized labels, layout variants, and reduced-motion support.
|
|
31
|
+
- be6c9c6: Use the browser-native color chooser in React, matching Effect UI HTML, and remove the `react-colorful` dependency. `contentClassName` now styles the swatch rather than the old React popover.
|
|
32
|
+
- bc3aeab: Make the HTML Notification Menu's bulk archive action and notification rows fill the popover, matching the React layout.
|
|
33
|
+
- 6cc75d9: Add controlled Pagination for Effect UI HTML, with shared React and HTML props, localization, and page-navigation rules.
|
|
34
|
+
|
|
35
|
+
Hide the page number and disable page navigation when there are no pages.
|
|
36
|
+
- d070a0a: Add Effect UI HTML renderers for more registry components, with shared prop schemas, renderer-neutral behavior where applicable, and separate React and HTML install entries. Existing React imports remain available.
|
|
37
|
+
- 3a7ae58: Let the React Effect UI adapter inherit a message log from context without adding logging props to individual components.
|
|
38
|
+
- 8f17684: Declare the optional TanStack Form Core peer used by the emitted React form types. Install it alongside TanStack React Form when consuming the form declarations.
|
|
39
|
+
- bc3aeab: Use renderer-specific component imports for the Webhook Delivery Table, Audit Log Table, and Tracking Notice. These components now have independent source installs, previews, and docs under Webhooks and Events.
|
|
40
|
+
- 3a7ae58: Remove the unused direct `date-fns` dependency. The calendar still gets it through `react-day-picker`.
|
|
41
|
+
- 3a7ae58: Remove the legacy Drizzle notification persistence adapter, its package exports and source-install item, and the optional `drizzle-orm` peer. Use the `@krak-stack/notifications` migration guide to adopt existing tables. This change does not drop or modify database tables.
|
|
42
|
+
- 241f843: Export the shared component docs page layout, platform example, installation tabs, and Effect UI HTML preview host for package-owned documentation. Export the existing Effect 4.2 effectcn button and field styles for consumers building HTML forms.
|
|
43
|
+
- 3a7ae58: Share feature styles between React and Effect UI HTML components without changing their appearance, and include the shared class files in both source installs.
|
|
44
|
+
- 62fd4ea: Align the support dialog's reply email label with the start of the input in React and Effect UI HTML.
|
|
45
|
+
- 62fd4ea: Show the selected light, dark, or system icon in Theme Switcher, independent of the document theme.
|
|
46
|
+
- 62fd4ea: Rename `TimePicker` to `TimeInput` and replace the `time-picker` registry and package paths with `time-input`. Use a native time field for direct editing in both renderers. The browser controls the field’s display format; `hourCycle` still controls the clock menu, whose AM and PM lists now start at 12. The clock and clear buttons sit inside the field, and the Effect UI menu has scrollable time columns.
|
|
47
|
+
- 62fd4ea: Remove the browser’s default popover background from the Effect UI Virtualized Combobox so only the themed popup is visible.
|
|
48
|
+
- bc3aeab: Use the shared Effect UI DataTable for webhook deliveries. The HTML `QueryChanged` event now sends DataTable query fields for server-side search, filters, sorting, and pagination. CSV export stays host-owned.
|
|
49
|
+
- 62fd4ea: Use `@krak-stack/registry/webhook-delivery-table/react` or `@krak-stack/registry/webhook-delivery-table/html` for `WebhookDeliveryTable`. The equivalent `/webhooks/react` and `/webhooks/html` aliases and the existing `/webhooks/client` React import are also available. The source install items are `@krak-stack/webhook-delivery-table` and `@krak-stack/webhook-delivery-table-html`.
|
|
50
|
+
|
|
51
|
+
## 0.11.0
|
|
52
|
+
|
|
53
|
+
### Minor Changes
|
|
54
|
+
|
|
55
|
+
- 82519d5: Add explicit `/react` and `/html` imports for Support and DangerConfirmation. The existing React imports remain available as aliases. Install the HTML source with `@krak-stack/support-dialog-html` or `@krak-stack/danger-confirmation-html`. Existing React source install commands are unchanged.
|
|
56
|
+
|
|
57
|
+
### Patch Changes
|
|
58
|
+
|
|
59
|
+
- 638519a: Add `@krak-stack/registry/async-action-button/react` as the explicit React entry point. The existing npm import and shadcn install command remain supported.
|
|
60
|
+
- 74bceea: Add explicit React entry points at `@krak-stack/registry/copy-button/react` and `@krak-stack/registry/copy-value/react`. The existing npm imports and shadcn install commands remain supported.
|
|
61
|
+
- b1871af: Add `@krak-stack/registry/editable-text/react` as the explicit React entry point. The existing npm import and shadcn install command remain supported.
|
|
62
|
+
- 9f769d7: Require Effect 4.2 for the registry and use the UI and UI Kit built into `effect`.
|
|
63
|
+
- 82519d5: Add an Effect UI HTML KrakstackProvider for shared locale configuration. Support and DangerConfirmation inherit its locale unless explicitly overridden. The existing React provider import remains supported.
|
|
64
|
+
- 6b8496b: Add explicit `/react` entry points for the remaining KrakStack registry components. Existing npm imports and shadcn install commands remain supported. Component docs show the matching live preview, usage, and install target.
|
|
65
|
+
- 9f769d7: Share Support’s message schema, English and French defaults, and locale overrides between the React and Effect UI HTML views.
|
|
66
|
+
- be41f07: Extract reusable support draft and request rules without changing the React support API.
|
|
67
|
+
- 805d5bd: Validate form field error messages, preserve readonly combobox option types, and
|
|
68
|
+
handle clipboard failures from synchronous button callbacks. Tighten table view
|
|
69
|
+
selection at the Base UI boundary.
|
|
70
|
+
- 294ec12: Allow individual Support layout class overrides and render icons as inline Lucide SVG.
|
|
71
|
+
- 247eb93: Include the React Effect UI adapter as local source in Support's registry install so it no longer needs a private workspace dependency.
|
|
72
|
+
- 9f769d7: Use the shared Support model for React forms, pages, and dialogs. The React preview uses the public dialog.
|
|
73
|
+
|
|
74
|
+
Show Support’s inline schema errors instead of native browser validation popups in both renderers, and mark invalid controls with the theme’s destructive border color.
|
|
75
|
+
|
|
76
|
+
Show separate inline validation messages for the support message and reply email.
|
|
77
|
+
- 9f769d7: Move shared Support styles from the validation schemas into the component's shared entry point without changing the React or HTML views.
|
|
78
|
+
- f382af2: Use native Tiptap JSONContent and standard Tiptap extensions in RichTextEditor, without the KrakStack versioned rich-text format or conversion layer. This changes the value/onChange contract: old version 1 documents are not accepted or silently migrated.
|
|
79
|
+
|
|
80
|
+
Fix caret placement inside links and apply URL edits or removal to the full existing link.
|
|
81
|
+
|
|
82
|
+
Add Email Composer: a document-style editor using the shared RichTextEditor surface, @react-email/editor extensions, and continuous HTML/plain-text previews with escaped variable samples instead of an export button. Keep programmatic React Email export available. Deprecate the drag-and-drop Email Editor, retaining its frozen legacy document support only for existing integrations.
|
|
83
|
+
- 247eb93: Use shadcn/ui for React Support and Effect 4.2-compatible effectcn source for its HTML view. Use Tailwind and the app's CSS theme instead of the shared theme package. Remove the KrakStack Button, Dialog, Field, and Theme entries and the Native Button export. The Support component entry points remain available; import `@krak-stack/registry/tailwind.css` from your Tailwind entry sheet for packaged React Support.
|
|
84
|
+
- 2aeb055: Add `features.virtualization.scroll: "internal"` to fill a height-constrained flex column while keeping the toolbar and pagination outside the internal scroll area. `"page"` still scrolls with the browser, and `"table"` retains the existing height cap.
|
|
85
|
+
|
|
86
|
+
## 0.10.20
|
|
87
|
+
|
|
88
|
+
### Patch Changes
|
|
89
|
+
|
|
90
|
+
- 18f5e37: Anchor select menus to their trigger instead of overlapping the selected option.
|
|
91
|
+
Keep narrow menus at trigger width and constrain wider menus to the available
|
|
92
|
+
viewport. Apply these defaults to forms, tables, pagination and editing-locale
|
|
93
|
+
selectors through a KrakStack-owned Select registry item; preserve positioning overrides.
|
|
94
|
+
- 08b3ce9: Add a 50 Km map radius preset and use the shared KrakStack Select for radius
|
|
95
|
+
selection. Preserve numeric callbacks, custom radius options, point mode and
|
|
96
|
+
inline/dialog behavior. Radius labels consistently use “Km”.
|
|
97
|
+
- 805d5bd: Validate form field error messages, preserve readonly combobox option types, and
|
|
98
|
+
handle clipboard failures from synchronous button callbacks. Tighten table view
|
|
99
|
+
selection at the Base UI boundary.
|
|
100
|
+
- f382af2: Use native Tiptap JSONContent and standard Tiptap extensions in RichTextEditor, without the KrakStack versioned rich-text format or conversion layer. This changes the value/onChange contract: old version 1 documents are not accepted or silently migrated.
|
|
101
|
+
|
|
102
|
+
Fix caret placement inside links and apply URL edits or removal to the full existing link.
|
|
103
|
+
|
|
104
|
+
Add Email Composer: a document-style editor using the shared RichTextEditor surface, @react-email/editor extensions, and continuous HTML/plain-text previews with escaped variable samples instead of an export button. Keep programmatic React Email export available. Deprecate the drag-and-drop Email Editor, retaining its frozen legacy document support only for existing integrations.
|
|
105
|
+
|
|
106
|
+
- 2aeb055: Add `features.virtualization.scroll: "internal"` to fill a height-constrained flex column while keeping the toolbar and pagination outside the internal scroll area. `"page"` still scrolls with the browser, and `"table"` retains the existing height cap.
|
|
107
|
+
|
|
3
108
|
## 0.10.19
|
|
4
109
|
|
|
5
110
|
### Patch Changes
|
package/README.md
CHANGED
|
@@ -10,6 +10,12 @@ bun add @krak-stack/registry
|
|
|
10
10
|
|
|
11
11
|
Install the peer dependencies required by the items you use. Each item's registry documentation lists its dependencies and setup.
|
|
12
12
|
|
|
13
|
+
Effect UI HTML consumers do not need React or React DOM. React consumers
|
|
14
|
+
install the React peers required by their components, including
|
|
15
|
+
`react-day-picker` for Date Input, `@tiptap/react` and
|
|
16
|
+
`@tiptap/static-renderer` for Rich Text Editor, and `@react-email/editor`
|
|
17
|
+
for Email Composer.
|
|
18
|
+
|
|
13
19
|
Animation components require the optional `motion` peer; the phone-number input
|
|
14
20
|
requires the optional `libphonenumber-js` peer. Install these only when using the
|
|
15
21
|
corresponding components. Notification-menu consumers do not need either package.
|
|
@@ -18,6 +24,24 @@ Les composants animés nécessitent la dépendance paire facultative `motion` ;
|
|
|
18
24
|
champ de numéro de téléphone nécessite `libphonenumber-js`. Installez ces paquets
|
|
19
25
|
uniquement pour les composants concernés. Le menu de notifications n'en a pas besoin.
|
|
20
26
|
|
|
27
|
+
## Select popup positioning
|
|
28
|
+
|
|
29
|
+
Use `@krak-stack/registry/select`, or install `@krak-stack/select` with shadcn
|
|
30
|
+
and import from `@/components/ui/select`. This shared Base UI composition serves
|
|
31
|
+
KrakStack forms/tables and consumer applications without product copy or policy.
|
|
32
|
+
Menus default to start alignment, trigger width, available viewport bounds and
|
|
33
|
+
`alignItemWithTrigger={false}`. Existing props can override those defaults.
|
|
34
|
+
Update this registry item rather than bare shadcn `select`; existing consumers
|
|
35
|
+
can update Select alone without upgrading tables or forms.
|
|
36
|
+
|
|
37
|
+
## Map radius selection
|
|
38
|
+
|
|
39
|
+
React Map Menu uses the shared KrakStack Select in inline and dialog presentations.
|
|
40
|
+
Default presets are 1, 2, 5, 10, 20, 40, 50, 60, 80, 100, 250 and 500 Km.
|
|
41
|
+
`radiusOptions` still overrides presets; values and callbacks remain numeric.
|
|
42
|
+
The radius popup exposes `data-map-menu-radius-popup` for host styling outside
|
|
43
|
+
the map root. Point mode has no radius control.
|
|
44
|
+
|
|
21
45
|
## Shared integration documentation
|
|
22
46
|
|
|
23
47
|
Generate API, OAuth MCP, and webhook guides in a Bun server loader:
|
|
@@ -81,13 +105,10 @@ import { Speech } from "@krak-stack/registry/speech";
|
|
|
81
105
|
|
|
82
106
|
Speech-to-text and text-to-speech use Cloudflare AI Gateway. See the [speech setup and API contract](https://krakstack.net/docs/speech); authentication and quotas stay application-owned. Schemas and the optional HTTP API contract are available from `@krak-stack/registry/speech/schema` and `@krak-stack/registry/speech/api`.
|
|
83
107
|
|
|
84
|
-
For durable notifications, install `@krak-stack/notifications
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
does not export these screens or depend on either notification SDK. The admin SDK
|
|
89
|
-
can use the published registry 0.2.2 primitives without a new registry release.
|
|
90
|
-
Legacy engine exports remain unchanged and are not redirected to a new backend.
|
|
108
|
+
For durable notifications, install `@krak-stack/notifications`. Its optional
|
|
109
|
+
React administration views use registry's generic tables and forms, and are
|
|
110
|
+
available at `@krak-stack/notifications/admin/<feature>/react`. Registry does
|
|
111
|
+
not export those screens.
|
|
91
112
|
|
|
92
113
|
For packaged UI components, include the Tailwind source in your application stylesheet:
|
|
93
114
|
|
|
@@ -0,0 +1,454 @@
|
|
|
1
|
+
import { Context, Effect, Layer, Redacted, Schema, Stream } from "effect";
|
|
2
|
+
import { AtomRegistry } from "effect/reactivity";
|
|
3
|
+
import type { Atom } from "effect/reactivity";
|
|
4
|
+
import { Command, Component, Subscription, UiSchema } from "effect/ui";
|
|
5
|
+
import type { AgentState } from "../../services/agent/client/atom.js";
|
|
6
|
+
import { AgentWidgetSnapshotSchema, type AgentWidgetIntent, type AgentWidgetSharedProps } from "./schema.js";
|
|
7
|
+
/** One binding per conversation scope. The host must validate every intent. */
|
|
8
|
+
export interface AgentWidgetHost {
|
|
9
|
+
readonly snapshots: Stream.Stream<AgentWidgetSnapshot>;
|
|
10
|
+
readonly dispatch: (intent: AgentWidgetIntent) => Effect.Effect<void, AgentWidgetHostFailure>;
|
|
11
|
+
}
|
|
12
|
+
export type AgentWidgetSnapshot = typeof AgentWidgetSnapshotSchema.Type;
|
|
13
|
+
export type AgentWidgetReferenceSummary = AgentWidgetSnapshot["availableReferences"][number];
|
|
14
|
+
export type AgentWidgetHostFailure = {
|
|
15
|
+
readonly _tag: "AgentWidgetHostFailure";
|
|
16
|
+
readonly reason: "stale" | "unavailable";
|
|
17
|
+
};
|
|
18
|
+
/** The atom and projection stay host-owned, and toStream releases its observer on interruption. */
|
|
19
|
+
export declare const agentWidgetSnapshots: <Resource>(registry: AtomRegistry.AtomRegistry, atom: Atom.Atom<AgentState<Resource>>, visible: (state: AgentState<Resource>) => AgentWidgetSnapshot) => Stream.Stream<AgentWidgetSnapshot>;
|
|
20
|
+
declare const ConversationHost_base: Context.ServiceClass<ConversationHost, "agent/ConversationHost", AgentWidgetHost>;
|
|
21
|
+
export declare class ConversationHost extends ConversationHost_base {
|
|
22
|
+
static layer: (host: AgentWidgetHost) => Layer.Layer<ConversationHost | DispatchIntent, never, never>;
|
|
23
|
+
}
|
|
24
|
+
export declare const hasPendingApproval: (messages: AgentWidgetSnapshot["messages"]) => boolean;
|
|
25
|
+
export declare const agentDraftText: (input: string) => string;
|
|
26
|
+
export declare const agentToolInput: (input: unknown) => string;
|
|
27
|
+
export declare const canSelectReference: (model: AgentWidgetModel, key: string) => boolean;
|
|
28
|
+
export declare const defaultMessages: {
|
|
29
|
+
en: {
|
|
30
|
+
approve: string;
|
|
31
|
+
approved: string;
|
|
32
|
+
approvalDestructive: string;
|
|
33
|
+
approvalDestructiveLabel: string;
|
|
34
|
+
approvalRequired: string;
|
|
35
|
+
cancel: string;
|
|
36
|
+
close: string;
|
|
37
|
+
completed: string;
|
|
38
|
+
conversation: string;
|
|
39
|
+
description: string;
|
|
40
|
+
errors: {
|
|
41
|
+
"invalid-request": string;
|
|
42
|
+
"stream-failed": string;
|
|
43
|
+
unavailable: string;
|
|
44
|
+
};
|
|
45
|
+
maximize: string;
|
|
46
|
+
open: string;
|
|
47
|
+
placeholder: string;
|
|
48
|
+
removeContext: string;
|
|
49
|
+
references: string;
|
|
50
|
+
reset: string;
|
|
51
|
+
restore: string;
|
|
52
|
+
send: string;
|
|
53
|
+
stop: string;
|
|
54
|
+
title: string;
|
|
55
|
+
toolActivity: string;
|
|
56
|
+
toolDenied: string;
|
|
57
|
+
toolFailed: string;
|
|
58
|
+
toolRunning: string;
|
|
59
|
+
viewMore: string;
|
|
60
|
+
welcome: string;
|
|
61
|
+
you: string;
|
|
62
|
+
};
|
|
63
|
+
fr: {
|
|
64
|
+
approve: string;
|
|
65
|
+
approved: string;
|
|
66
|
+
approvalDestructive: string;
|
|
67
|
+
approvalDestructiveLabel: string;
|
|
68
|
+
approvalRequired: string;
|
|
69
|
+
cancel: string;
|
|
70
|
+
close: string;
|
|
71
|
+
completed: string;
|
|
72
|
+
conversation: string;
|
|
73
|
+
description: string;
|
|
74
|
+
errors: {
|
|
75
|
+
"invalid-request": string;
|
|
76
|
+
"stream-failed": string;
|
|
77
|
+
unavailable: string;
|
|
78
|
+
};
|
|
79
|
+
maximize: string;
|
|
80
|
+
open: string;
|
|
81
|
+
placeholder: string;
|
|
82
|
+
removeContext: string;
|
|
83
|
+
references: string;
|
|
84
|
+
reset: string;
|
|
85
|
+
restore: string;
|
|
86
|
+
send: string;
|
|
87
|
+
stop: string;
|
|
88
|
+
title: string;
|
|
89
|
+
toolActivity: string;
|
|
90
|
+
toolDenied: string;
|
|
91
|
+
toolFailed: string;
|
|
92
|
+
toolRunning: string;
|
|
93
|
+
viewMore: string;
|
|
94
|
+
welcome: string;
|
|
95
|
+
you: string;
|
|
96
|
+
};
|
|
97
|
+
};
|
|
98
|
+
export declare const agentWidgetHtmlMessages: (locale: string) => {
|
|
99
|
+
approve: string;
|
|
100
|
+
approved: string;
|
|
101
|
+
approvalDestructive: string;
|
|
102
|
+
approvalDestructiveLabel: string;
|
|
103
|
+
approvalRequired: string;
|
|
104
|
+
cancel: string;
|
|
105
|
+
close: string;
|
|
106
|
+
completed: string;
|
|
107
|
+
conversation: string;
|
|
108
|
+
description: string;
|
|
109
|
+
errors: {
|
|
110
|
+
"invalid-request": string;
|
|
111
|
+
"stream-failed": string;
|
|
112
|
+
unavailable: string;
|
|
113
|
+
};
|
|
114
|
+
maximize: string;
|
|
115
|
+
open: string;
|
|
116
|
+
placeholder: string;
|
|
117
|
+
removeContext: string;
|
|
118
|
+
references: string;
|
|
119
|
+
reset: string;
|
|
120
|
+
restore: string;
|
|
121
|
+
send: string;
|
|
122
|
+
stop: string;
|
|
123
|
+
title: string;
|
|
124
|
+
toolActivity: string;
|
|
125
|
+
toolDenied: string;
|
|
126
|
+
toolFailed: string;
|
|
127
|
+
toolRunning: string;
|
|
128
|
+
viewMore: string;
|
|
129
|
+
welcome: string;
|
|
130
|
+
you: string;
|
|
131
|
+
};
|
|
132
|
+
export declare const AgentWidgetMessage: UiSchema.TaggedEnum<{
|
|
133
|
+
readonly Approval: Schema.TaggedStruct<"Approval", {
|
|
134
|
+
readonly approvalId: Schema.String;
|
|
135
|
+
readonly toolCallId: Schema.String;
|
|
136
|
+
readonly approved: Schema.Boolean;
|
|
137
|
+
}>;
|
|
138
|
+
readonly Delivered: Schema.TaggedStruct<"Delivered", {
|
|
139
|
+
readonly success: Schema.Boolean;
|
|
140
|
+
}>;
|
|
141
|
+
readonly Disconnected: Schema.TaggedStruct<"Disconnected", {}>;
|
|
142
|
+
readonly DraftChanged: Schema.TaggedStruct<"DraftChanged", {
|
|
143
|
+
readonly value: Schema.Redacted<Schema.String>;
|
|
144
|
+
}>;
|
|
145
|
+
readonly Interrupt: Schema.TaggedStruct<"Interrupt", {}>;
|
|
146
|
+
readonly OpenChanged: Schema.TaggedStruct<"OpenChanged", {
|
|
147
|
+
readonly open: Schema.Boolean;
|
|
148
|
+
}>;
|
|
149
|
+
readonly Received: Schema.TaggedStruct<"Received", {
|
|
150
|
+
readonly snapshot: Schema.Redacted<Schema.Struct<{
|
|
151
|
+
readonly context: Schema.optional<Schema.Struct<{
|
|
152
|
+
readonly key: Schema.String;
|
|
153
|
+
readonly label: Schema.String;
|
|
154
|
+
}>>;
|
|
155
|
+
readonly availableReferences: Schema.$Array<Schema.Struct<{
|
|
156
|
+
readonly key: Schema.String;
|
|
157
|
+
readonly label: Schema.String;
|
|
158
|
+
}>>;
|
|
159
|
+
readonly contextLocked: Schema.Boolean;
|
|
160
|
+
readonly pending: Schema.Boolean;
|
|
161
|
+
readonly error: Schema.optional<Schema.Literals<readonly ["invalid-request", "stream-failed", "unavailable"]>>;
|
|
162
|
+
readonly messages: Schema.$Array<Schema.Struct<{
|
|
163
|
+
readonly id: Schema.String;
|
|
164
|
+
readonly role: Schema.Literals<readonly ["user", "assistant"]>;
|
|
165
|
+
readonly text: Schema.String;
|
|
166
|
+
readonly markdown: Schema.optional<Schema.Struct<{
|
|
167
|
+
readonly html: Schema.String;
|
|
168
|
+
readonly codeBlocks: Schema.$Array<Schema.Struct<{
|
|
169
|
+
readonly code: Schema.String;
|
|
170
|
+
readonly language: Schema.String;
|
|
171
|
+
}>>;
|
|
172
|
+
}>>;
|
|
173
|
+
readonly tools: Schema.$Array<Schema.Struct<{
|
|
174
|
+
readonly type: Schema.Literal<"tool-call">;
|
|
175
|
+
readonly toolCallId: Schema.String;
|
|
176
|
+
readonly messageId: Schema.String;
|
|
177
|
+
readonly name: Schema.String;
|
|
178
|
+
readonly input: Schema.Unknown;
|
|
179
|
+
readonly metadata: Schema.Struct<{
|
|
180
|
+
readonly title: Schema.optional<Schema.String>;
|
|
181
|
+
readonly description: Schema.optional<Schema.String>;
|
|
182
|
+
readonly destructive: Schema.Boolean;
|
|
183
|
+
}>;
|
|
184
|
+
readonly approvalId: Schema.optional<Schema.String>;
|
|
185
|
+
readonly status: Schema.Literals<readonly ["running", "approval-required", "approved", "denied", "completed", "failed"]>;
|
|
186
|
+
}>>;
|
|
187
|
+
}>>;
|
|
188
|
+
}>>;
|
|
189
|
+
}>;
|
|
190
|
+
readonly ReferenceToggled: Schema.TaggedStruct<"ReferenceToggled", {
|
|
191
|
+
readonly key: Schema.String;
|
|
192
|
+
}>;
|
|
193
|
+
readonly RemoveContext: Schema.TaggedStruct<"RemoveContext", {}>;
|
|
194
|
+
readonly Reset: Schema.TaggedStruct<"Reset", {}>;
|
|
195
|
+
readonly Send: Schema.TaggedStruct<"Send", {}>;
|
|
196
|
+
readonly ToggleMaximize: Schema.TaggedStruct<"ToggleMaximize", {}>;
|
|
197
|
+
}>;
|
|
198
|
+
declare const DispatchIntent_base: Command.Service<DispatchIntent, "agent/DispatchIntent", {
|
|
199
|
+
readonly intent: {
|
|
200
|
+
readonly _tag: "Reset";
|
|
201
|
+
} | {
|
|
202
|
+
readonly _tag: "Submit";
|
|
203
|
+
readonly text: Redacted.Redacted<string>;
|
|
204
|
+
readonly referenceKeys: readonly string[];
|
|
205
|
+
} | {
|
|
206
|
+
readonly _tag: "DecideApproval";
|
|
207
|
+
readonly approvalId: string;
|
|
208
|
+
readonly toolCallId: string;
|
|
209
|
+
readonly approved: boolean;
|
|
210
|
+
} | {
|
|
211
|
+
readonly _tag: "Interrupt";
|
|
212
|
+
} | {
|
|
213
|
+
readonly _tag: "RemoveContext";
|
|
214
|
+
};
|
|
215
|
+
}, UiSchema.TaggedEnum<{
|
|
216
|
+
readonly Approval: Schema.TaggedStruct<"Approval", {
|
|
217
|
+
readonly approvalId: Schema.String;
|
|
218
|
+
readonly toolCallId: Schema.String;
|
|
219
|
+
readonly approved: Schema.Boolean;
|
|
220
|
+
}>;
|
|
221
|
+
readonly Delivered: Schema.TaggedStruct<"Delivered", {
|
|
222
|
+
readonly success: Schema.Boolean;
|
|
223
|
+
}>;
|
|
224
|
+
readonly Disconnected: Schema.TaggedStruct<"Disconnected", {}>;
|
|
225
|
+
readonly DraftChanged: Schema.TaggedStruct<"DraftChanged", {
|
|
226
|
+
readonly value: Schema.Redacted<Schema.String>;
|
|
227
|
+
}>;
|
|
228
|
+
readonly Interrupt: Schema.TaggedStruct<"Interrupt", {}>;
|
|
229
|
+
readonly OpenChanged: Schema.TaggedStruct<"OpenChanged", {
|
|
230
|
+
readonly open: Schema.Boolean;
|
|
231
|
+
}>;
|
|
232
|
+
readonly Received: Schema.TaggedStruct<"Received", {
|
|
233
|
+
readonly snapshot: Schema.Redacted<Schema.Struct<{
|
|
234
|
+
readonly context: Schema.optional<Schema.Struct<{
|
|
235
|
+
readonly key: Schema.String;
|
|
236
|
+
readonly label: Schema.String;
|
|
237
|
+
}>>;
|
|
238
|
+
readonly availableReferences: Schema.$Array<Schema.Struct<{
|
|
239
|
+
readonly key: Schema.String;
|
|
240
|
+
readonly label: Schema.String;
|
|
241
|
+
}>>;
|
|
242
|
+
readonly contextLocked: Schema.Boolean;
|
|
243
|
+
readonly pending: Schema.Boolean;
|
|
244
|
+
readonly error: Schema.optional<Schema.Literals<readonly ["invalid-request", "stream-failed", "unavailable"]>>;
|
|
245
|
+
readonly messages: Schema.$Array<Schema.Struct<{
|
|
246
|
+
readonly id: Schema.String;
|
|
247
|
+
readonly role: Schema.Literals<readonly ["user", "assistant"]>;
|
|
248
|
+
readonly text: Schema.String;
|
|
249
|
+
readonly markdown: Schema.optional<Schema.Struct<{
|
|
250
|
+
readonly html: Schema.String;
|
|
251
|
+
readonly codeBlocks: Schema.$Array<Schema.Struct<{
|
|
252
|
+
readonly code: Schema.String;
|
|
253
|
+
readonly language: Schema.String;
|
|
254
|
+
}>>;
|
|
255
|
+
}>>;
|
|
256
|
+
readonly tools: Schema.$Array<Schema.Struct<{
|
|
257
|
+
readonly type: Schema.Literal<"tool-call">;
|
|
258
|
+
readonly toolCallId: Schema.String;
|
|
259
|
+
readonly messageId: Schema.String;
|
|
260
|
+
readonly name: Schema.String;
|
|
261
|
+
readonly input: Schema.Unknown;
|
|
262
|
+
readonly metadata: Schema.Struct<{
|
|
263
|
+
readonly title: Schema.optional<Schema.String>;
|
|
264
|
+
readonly description: Schema.optional<Schema.String>;
|
|
265
|
+
readonly destructive: Schema.Boolean;
|
|
266
|
+
}>;
|
|
267
|
+
readonly approvalId: Schema.optional<Schema.String>;
|
|
268
|
+
readonly status: Schema.Literals<readonly ["running", "approval-required", "approved", "denied", "completed", "failed"]>;
|
|
269
|
+
}>>;
|
|
270
|
+
}>>;
|
|
271
|
+
}>>;
|
|
272
|
+
}>;
|
|
273
|
+
readonly ReferenceToggled: Schema.TaggedStruct<"ReferenceToggled", {
|
|
274
|
+
readonly key: Schema.String;
|
|
275
|
+
}>;
|
|
276
|
+
readonly RemoveContext: Schema.TaggedStruct<"RemoveContext", {}>;
|
|
277
|
+
readonly Reset: Schema.TaggedStruct<"Reset", {}>;
|
|
278
|
+
readonly Send: Schema.TaggedStruct<"Send", {}>;
|
|
279
|
+
readonly ToggleMaximize: Schema.TaggedStruct<"ToggleMaximize", {}>;
|
|
280
|
+
}>, false, Schema.Never, never>;
|
|
281
|
+
export declare class DispatchIntent extends DispatchIntent_base {
|
|
282
|
+
}
|
|
283
|
+
export declare const agentWidgetOptions: {
|
|
284
|
+
readonly name: "AgentWidget";
|
|
285
|
+
readonly props: Schema.Struct<{
|
|
286
|
+
readonly locale: Schema.optional<Schema.String>;
|
|
287
|
+
}>;
|
|
288
|
+
readonly model: Schema.Struct<{
|
|
289
|
+
readonly snapshot: Schema.NullOr<Schema.Redacted<Schema.Struct<{
|
|
290
|
+
readonly context: Schema.optional<Schema.Struct<{
|
|
291
|
+
readonly key: Schema.String;
|
|
292
|
+
readonly label: Schema.String;
|
|
293
|
+
}>>;
|
|
294
|
+
readonly availableReferences: Schema.$Array<Schema.Struct<{
|
|
295
|
+
readonly key: Schema.String;
|
|
296
|
+
readonly label: Schema.String;
|
|
297
|
+
}>>;
|
|
298
|
+
readonly contextLocked: Schema.Boolean;
|
|
299
|
+
readonly pending: Schema.Boolean;
|
|
300
|
+
readonly error: Schema.optional<Schema.Literals<readonly ["invalid-request", "stream-failed", "unavailable"]>>;
|
|
301
|
+
readonly messages: Schema.$Array<Schema.Struct<{
|
|
302
|
+
readonly id: Schema.String;
|
|
303
|
+
readonly role: Schema.Literals<readonly ["user", "assistant"]>;
|
|
304
|
+
readonly text: Schema.String;
|
|
305
|
+
readonly markdown: Schema.optional<Schema.Struct<{
|
|
306
|
+
readonly html: Schema.String;
|
|
307
|
+
readonly codeBlocks: Schema.$Array<Schema.Struct<{
|
|
308
|
+
readonly code: Schema.String;
|
|
309
|
+
readonly language: Schema.String;
|
|
310
|
+
}>>;
|
|
311
|
+
}>>;
|
|
312
|
+
readonly tools: Schema.$Array<Schema.Struct<{
|
|
313
|
+
readonly type: Schema.Literal<"tool-call">;
|
|
314
|
+
readonly toolCallId: Schema.String;
|
|
315
|
+
readonly messageId: Schema.String;
|
|
316
|
+
readonly name: Schema.String;
|
|
317
|
+
readonly input: Schema.Unknown;
|
|
318
|
+
readonly metadata: Schema.Struct<{
|
|
319
|
+
readonly title: Schema.optional<Schema.String>;
|
|
320
|
+
readonly description: Schema.optional<Schema.String>;
|
|
321
|
+
readonly destructive: Schema.Boolean;
|
|
322
|
+
}>;
|
|
323
|
+
readonly approvalId: Schema.optional<Schema.String>;
|
|
324
|
+
readonly status: Schema.Literals<readonly ["running", "approval-required", "approved", "denied", "completed", "failed"]>;
|
|
325
|
+
}>>;
|
|
326
|
+
}>>;
|
|
327
|
+
}>>>;
|
|
328
|
+
readonly draft: Schema.Redacted<Schema.String>;
|
|
329
|
+
readonly references: Schema.$Array<Schema.String>;
|
|
330
|
+
readonly sending: Schema.NullOr<Schema.Literals<readonly ["Submit", "DecideApproval", "Interrupt", "Reset", "RemoveContext"]>>;
|
|
331
|
+
readonly open: Schema.Boolean;
|
|
332
|
+
readonly maximized: Schema.Boolean;
|
|
333
|
+
readonly deliveryFailed: Schema.Boolean;
|
|
334
|
+
readonly disconnected: Schema.Boolean;
|
|
335
|
+
}>;
|
|
336
|
+
readonly message: UiSchema.TaggedEnum<{
|
|
337
|
+
readonly Approval: Schema.TaggedStruct<"Approval", {
|
|
338
|
+
readonly approvalId: Schema.String;
|
|
339
|
+
readonly toolCallId: Schema.String;
|
|
340
|
+
readonly approved: Schema.Boolean;
|
|
341
|
+
}>;
|
|
342
|
+
readonly Delivered: Schema.TaggedStruct<"Delivered", {
|
|
343
|
+
readonly success: Schema.Boolean;
|
|
344
|
+
}>;
|
|
345
|
+
readonly Disconnected: Schema.TaggedStruct<"Disconnected", {}>;
|
|
346
|
+
readonly DraftChanged: Schema.TaggedStruct<"DraftChanged", {
|
|
347
|
+
readonly value: Schema.Redacted<Schema.String>;
|
|
348
|
+
}>;
|
|
349
|
+
readonly Interrupt: Schema.TaggedStruct<"Interrupt", {}>;
|
|
350
|
+
readonly OpenChanged: Schema.TaggedStruct<"OpenChanged", {
|
|
351
|
+
readonly open: Schema.Boolean;
|
|
352
|
+
}>;
|
|
353
|
+
readonly Received: Schema.TaggedStruct<"Received", {
|
|
354
|
+
readonly snapshot: Schema.Redacted<Schema.Struct<{
|
|
355
|
+
readonly context: Schema.optional<Schema.Struct<{
|
|
356
|
+
readonly key: Schema.String;
|
|
357
|
+
readonly label: Schema.String;
|
|
358
|
+
}>>;
|
|
359
|
+
readonly availableReferences: Schema.$Array<Schema.Struct<{
|
|
360
|
+
readonly key: Schema.String;
|
|
361
|
+
readonly label: Schema.String;
|
|
362
|
+
}>>;
|
|
363
|
+
readonly contextLocked: Schema.Boolean;
|
|
364
|
+
readonly pending: Schema.Boolean;
|
|
365
|
+
readonly error: Schema.optional<Schema.Literals<readonly ["invalid-request", "stream-failed", "unavailable"]>>;
|
|
366
|
+
readonly messages: Schema.$Array<Schema.Struct<{
|
|
367
|
+
readonly id: Schema.String;
|
|
368
|
+
readonly role: Schema.Literals<readonly ["user", "assistant"]>;
|
|
369
|
+
readonly text: Schema.String;
|
|
370
|
+
readonly markdown: Schema.optional<Schema.Struct<{
|
|
371
|
+
readonly html: Schema.String;
|
|
372
|
+
readonly codeBlocks: Schema.$Array<Schema.Struct<{
|
|
373
|
+
readonly code: Schema.String;
|
|
374
|
+
readonly language: Schema.String;
|
|
375
|
+
}>>;
|
|
376
|
+
}>>;
|
|
377
|
+
readonly tools: Schema.$Array<Schema.Struct<{
|
|
378
|
+
readonly type: Schema.Literal<"tool-call">;
|
|
379
|
+
readonly toolCallId: Schema.String;
|
|
380
|
+
readonly messageId: Schema.String;
|
|
381
|
+
readonly name: Schema.String;
|
|
382
|
+
readonly input: Schema.Unknown;
|
|
383
|
+
readonly metadata: Schema.Struct<{
|
|
384
|
+
readonly title: Schema.optional<Schema.String>;
|
|
385
|
+
readonly description: Schema.optional<Schema.String>;
|
|
386
|
+
readonly destructive: Schema.Boolean;
|
|
387
|
+
}>;
|
|
388
|
+
readonly approvalId: Schema.optional<Schema.String>;
|
|
389
|
+
readonly status: Schema.Literals<readonly ["running", "approval-required", "approved", "denied", "completed", "failed"]>;
|
|
390
|
+
}>>;
|
|
391
|
+
}>>;
|
|
392
|
+
}>>;
|
|
393
|
+
}>;
|
|
394
|
+
readonly ReferenceToggled: Schema.TaggedStruct<"ReferenceToggled", {
|
|
395
|
+
readonly key: Schema.String;
|
|
396
|
+
}>;
|
|
397
|
+
readonly RemoveContext: Schema.TaggedStruct<"RemoveContext", {}>;
|
|
398
|
+
readonly Reset: Schema.TaggedStruct<"Reset", {}>;
|
|
399
|
+
readonly Send: Schema.TaggedStruct<"Send", {}>;
|
|
400
|
+
readonly ToggleMaximize: Schema.TaggedStruct<"ToggleMaximize", {}>;
|
|
401
|
+
}>;
|
|
402
|
+
readonly restore: false;
|
|
403
|
+
};
|
|
404
|
+
export type AgentWidgetModel = typeof agentWidgetOptions.model.Type;
|
|
405
|
+
type Message = typeof AgentWidgetMessage.Type;
|
|
406
|
+
type Update = Component.Update<AgentWidgetModel, Message, never, AgentWidgetSharedProps>;
|
|
407
|
+
type Transition = AgentWidgetModel | Component.Step<AgentWidgetModel, Message, never, DispatchIntent>;
|
|
408
|
+
export declare const readAgentWidgetSnapshot: (model: AgentWidgetModel) => {
|
|
409
|
+
readonly context?: {
|
|
410
|
+
readonly key: string;
|
|
411
|
+
readonly label: string;
|
|
412
|
+
} | undefined;
|
|
413
|
+
readonly availableReferences: readonly {
|
|
414
|
+
readonly key: string;
|
|
415
|
+
readonly label: string;
|
|
416
|
+
}[];
|
|
417
|
+
readonly contextLocked: boolean;
|
|
418
|
+
readonly pending: boolean;
|
|
419
|
+
readonly error?: "invalid-request" | "stream-failed" | "unavailable" | undefined;
|
|
420
|
+
readonly messages: readonly {
|
|
421
|
+
readonly id: string;
|
|
422
|
+
readonly role: "assistant" | "user";
|
|
423
|
+
readonly text: string;
|
|
424
|
+
readonly markdown?: {
|
|
425
|
+
readonly html: string;
|
|
426
|
+
readonly codeBlocks: readonly {
|
|
427
|
+
readonly code: string;
|
|
428
|
+
readonly language: string;
|
|
429
|
+
}[];
|
|
430
|
+
} | undefined;
|
|
431
|
+
readonly tools: readonly {
|
|
432
|
+
readonly type: "tool-call";
|
|
433
|
+
readonly toolCallId: string;
|
|
434
|
+
readonly messageId: string;
|
|
435
|
+
readonly name: string;
|
|
436
|
+
readonly input: unknown;
|
|
437
|
+
readonly metadata: {
|
|
438
|
+
readonly title?: string | undefined;
|
|
439
|
+
readonly description?: string | undefined;
|
|
440
|
+
readonly destructive: boolean;
|
|
441
|
+
};
|
|
442
|
+
readonly approvalId?: string | undefined;
|
|
443
|
+
readonly status: "approval-required" | "approved" | "completed" | "denied" | "failed" | "running";
|
|
444
|
+
}[];
|
|
445
|
+
}[];
|
|
446
|
+
} | null;
|
|
447
|
+
export declare const canCompose: (model: AgentWidgetModel) => boolean;
|
|
448
|
+
export declare const canSend: (model: AgentWidgetModel) => boolean;
|
|
449
|
+
export declare const agentWidgetBehaviours: {
|
|
450
|
+
init: () => AgentWidgetModel;
|
|
451
|
+
subscriptions: () => ReadonlyArray<Subscription.Subscription<Message, ConversationHost>>;
|
|
452
|
+
update: ($: Update, message: Message) => Transition;
|
|
453
|
+
};
|
|
454
|
+
export {};
|