@promptbook/components 0.112.0-49 → 0.112.0-50

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (37) hide show
  1. package/esm/index.es.js +491 -154
  2. package/esm/index.es.js.map +1 -1
  3. package/esm/src/avatars/visuals/octopus3AvatarVisual.d.ts +72 -0
  4. package/esm/src/avatars/visuals/octopus3AvatarVisual.test.d.ts +1 -0
  5. package/esm/src/avatars/visuals/octopusAvatarVisualShared.d.ts +16 -0
  6. package/esm/src/book-components/BookEditor/BookEditor.d.ts +9 -0
  7. package/esm/src/book-components/BookEditor/useBookEditorMonacoLanguage.d.ts +10 -2
  8. package/esm/src/book-components/BookEditor/useBookEditorMonacoStyles.d.ts +2 -1
  9. package/esm/src/book-components/Chat/Chat/ChatMessageRichContent.d.ts +4 -0
  10. package/esm/src/book-components/Chat/Chat/ChatProps.d.ts +9 -0
  11. package/esm/src/book-components/Chat/Chat/ChatToolCallModal.d.ts +1 -0
  12. package/esm/src/book-components/Chat/Chat/ChatToolCallModalContent.d.ts +2 -1
  13. package/esm/src/book-components/Chat/Chat/renderAdvancedToolCallDetails.d.ts +4 -0
  14. package/esm/src/book-components/Chat/CodeBlock/CodeBlock.d.ts +2 -1
  15. package/esm/src/speech-recognition/OpenAiSpeechRecognition.d.ts +24 -2
  16. package/esm/src/speech-recognition/OpenAiSpeechRecognition.test.d.ts +1 -0
  17. package/esm/src/types/SpeechRecognition.d.ts +4 -0
  18. package/esm/src/version.d.ts +1 -1
  19. package/package.json +1 -1
  20. package/umd/index.umd.js +491 -154
  21. package/umd/index.umd.js.map +1 -1
  22. package/umd/src/avatars/visuals/octopus3AvatarVisual.d.ts +72 -0
  23. package/umd/src/avatars/visuals/octopus3AvatarVisual.test.d.ts +1 -0
  24. package/umd/src/avatars/visuals/octopusAvatarVisualShared.d.ts +16 -0
  25. package/umd/src/book-components/BookEditor/BookEditor.d.ts +9 -0
  26. package/umd/src/book-components/BookEditor/useBookEditorMonacoLanguage.d.ts +10 -2
  27. package/umd/src/book-components/BookEditor/useBookEditorMonacoStyles.d.ts +2 -1
  28. package/umd/src/book-components/Chat/Chat/ChatMessageRichContent.d.ts +4 -0
  29. package/umd/src/book-components/Chat/Chat/ChatProps.d.ts +9 -0
  30. package/umd/src/book-components/Chat/Chat/ChatToolCallModal.d.ts +1 -0
  31. package/umd/src/book-components/Chat/Chat/ChatToolCallModalContent.d.ts +2 -1
  32. package/umd/src/book-components/Chat/Chat/renderAdvancedToolCallDetails.d.ts +4 -0
  33. package/umd/src/book-components/Chat/CodeBlock/CodeBlock.d.ts +2 -1
  34. package/umd/src/speech-recognition/OpenAiSpeechRecognition.d.ts +24 -2
  35. package/umd/src/speech-recognition/OpenAiSpeechRecognition.test.d.ts +1 -0
  36. package/umd/src/types/SpeechRecognition.d.ts +4 -0
  37. package/umd/src/version.d.ts +1 -1
package/umd/index.umd.js CHANGED
@@ -30,7 +30,7 @@
30
30
  * @generated
31
31
  * @see https://github.com/webgptorg/promptbook
32
32
  */
33
- const PROMPTBOOK_ENGINE_VERSION = '0.112.0-49';
33
+ const PROMPTBOOK_ENGINE_VERSION = '0.112.0-50';
34
34
  /**
35
35
  * TODO: string_promptbook_version should be constrained to the all versions of Promptbook engine
36
36
  * Note: [💞] Ignore a discrepancy between file name and entity name
@@ -18718,8 +18718,8 @@
18718
18718
  // <- [🐱‍🚀] Buttons into genesis book
18719
18719
  // <- TODO: [🐱‍🚀] generateBookBoilerplate and deprecate `DEFAULT_BOOK`
18720
18720
 
18721
- var css_248z$d = ".BookEditor-module_BookEditor__s-0PU{width:100%}.BookEditor-module_bookEditorContainer__wLMwM{box-sizing:border-box;height:100%;padding:10px 25px 0;position:relative;width:100%}.BookEditor-module_bookEditorContainer__wLMwM.BookEditor-module_isVerbose__VQ6iL{background-color:rgba(0,0,0,.05);outline:1px dotted rgba(0,0,0,.5)}.BookEditor-module_isVerbose__VQ6iL{outline:2px dotted #ff7526}.BookEditor-module_bookEditorWrapper__twppD{background-color:#fff;border:1px solid rgba(209,213,219,.8);border-radius:1rem;box-shadow:0 1px 2px 0 rgba(0,0,0,.05);overflow:hidden;padding-top:10px;transition:box-shadow .2s ease-in-out}.BookEditor-module_isVerbose__VQ6iL .BookEditor-module_bookEditorWrapper__twppD{overflow:visible}.BookEditor-module_bookEditorWrapper__twppD:hover{box-shadow:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -1px rgba(0,0,0,.06)}.BookEditor-module_bookEditorWrapper__twppD.BookEditor-module_isBorderRadiusDisabled__h1I3v{border-radius:0}.BookEditor-module_dropOverlay__xWWoX{align-items:center;background-color:rgba(0,0,0,.5);bottom:0;color:#fff;display:flex;font-size:1.5rem;justify-content:center;left:0;pointer-events:none;position:absolute;right:0;top:0;z-index:100}.BookEditor-module_bookEditorActionbar__KW6dc{position:absolute;right:55px;top:10px;z-index:100}.BookEditor-module_fullscreen__rktsl{border:none;border-radius:0;bottom:0;box-shadow:none;height:100%;left:0;padding-top:50px;position:fixed;right:0;top:0;width:100%;z-index:9999}.BookEditor-module_button__hS390{align-items:center;background-color:#fff;border:1px solid #d1d5db;border-radius:.375rem;box-shadow:0 1px 2px 0 rgba(0,0,0,.05);color:#374151;cursor:pointer;display:inline-flex;gap:.5rem;padding:.5rem 1rem;transition:all .2s ease-in-out}.BookEditor-module_button__hS390:hover{background-color:#f9fafb;border-color:#b7bcce;box-shadow:0 1px 3px 0 rgba(0,0,0,.1),0 1px 2px 0 rgba(0,0,0,.06)}.BookEditor-module_savedNotification__OiX9L{align-items:center;animation:BookEditor-module_fadeOut__q8JnR 2s forwards;background-color:rgba(0,0,0,.7);border-radius:.5rem;color:#fff;display:flex;font-size:1.25rem;gap:.5rem;left:50%;padding:1rem 2rem;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%);z-index:1000}.BookEditor-module_uploadPanel__2JJtD{background:hsla(0,0%,100%,.98);border:1px solid rgba(209,213,219,.9);border-radius:12px;bottom:20px;box-shadow:0 12px 30px rgba(15,23,42,.15);display:flex;flex-direction:column;gap:10px;max-width:calc(100% - 40px);padding:12px;position:absolute;right:20px;width:420px;z-index:220}.BookEditor-module_uploadPanelHeader__pdJd2{align-items:center;display:flex;gap:12px;justify-content:space-between}.BookEditor-module_uploadPanelTitle__TJIVF{color:#111827;font-size:.95rem;font-weight:600}.BookEditor-module_uploadPanelHeaderMeta__Xw0uI{color:#6b7280;font-size:.75rem}.BookEditor-module_uploadPanelSummary__rwSbG{color:#6b7280;display:grid;font-size:.75rem;gap:4px 12px;grid-template-columns:1fr 1fr}.BookEditor-module_uploadPanelProgressBar__a6pjf{background:#e5e7eb;border-radius:999px;height:6px;overflow:hidden}.BookEditor-module_uploadPanelProgressFill__l-TKR{background:linear-gradient(90deg,#2563eb,#10b981);height:100%;transition:width .2s ease}.BookEditor-module_uploadPanelList__VxEd5{display:flex;flex-direction:column;gap:8px;max-height:220px;overflow-y:auto;padding-right:4px}.BookEditor-module_uploadRow__QiSFg{background:#fff;border:1px solid #e5e7eb;border-radius:10px;display:flex;flex-direction:column;gap:6px;padding:8px}.BookEditor-module_uploadRowHeader__po0j5{align-items:center;display:flex;gap:8px;justify-content:space-between}.BookEditor-module_uploadRowName__doQRO{color:#111827;font-size:.8rem;font-weight:600;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.BookEditor-module_uploadRowStatus__jsUb-{color:#6b7280;font-size:.7rem}.BookEditor-module_uploadRowMeta__1lz9h{color:#6b7280;display:flex;font-size:.7rem;justify-content:space-between}.BookEditor-module_uploadRowProgressBar__NoBA7{background:#e5e7eb;border-radius:999px;height:4px;overflow:hidden}.BookEditor-module_uploadRowProgressFill__TrP7e{background:#3b82f6;height:100%;transition:width .2s ease}.BookEditor-module_uploadRowActions__5Y1Mq{display:flex;gap:6px}.BookEditor-module_uploadActionButton__CqJrr{background:#f9fafb;border:1px solid #d1d5db;border-radius:6px;color:#374151;cursor:pointer;font-size:.7rem;padding:2px 8px;transition:all .15s ease-in-out}.BookEditor-module_uploadActionButton__CqJrr:hover{background:#eef2f7;border-color:#cbd5f5}.BookEditor-module_uploadRowError__eEHWw{color:#b91c1c;font-size:.7rem}@keyframes BookEditor-module_fadeOut__q8JnR{0%{opacity:0}10%{opacity:1}70%{opacity:1}to{opacity:0}}\n/*# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIkJvb2tFZGl0b3IubW9kdWxlLmNzcyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxxQ0FFSSxVQUNKLENBRUEsOENBS0kscUJBQXNCLENBSHRCLFdBQVksQ0FFWixtQkFBb0IsQ0FEcEIsaUJBQWtCLENBRmxCLFVBS0osQ0FFQSxpRkFFSSxnQ0FBcUMsQ0FDckMsaUNBRUosQ0FFQSxvQ0FDSSwwQkFDSixDQUVBLDRDQUtJLHFCQUF1QixDQUR2QixxQ0FBMEMsQ0FGMUMsa0JBQW1CLENBSW5CLHNDQUEyQyxDQUwzQyxlQUFnQixDQUVoQixnQkFBaUIsQ0FJakIscUNBQ0osQ0FDQSxnRkFFSSxnQkFFSixDQUVBLGtEQUNJLHVFQUNKLENBVUEsNEZBQ0ksZUFDSixDQUVBLHNDQVNJLGtCQUFtQixDQUhuQiwrQkFBb0MsQ0FEcEMsUUFBUyxDQUVULFVBQVksQ0FDWixZQUFhLENBR2IsZ0JBQWlCLENBRGpCLHNCQUF1QixDQVB2QixNQUFPLENBVVAsbUJBQW9CLENBWnBCLGlCQUFrQixDQUdsQixPQUFRLENBRlIsS0FBTSxDQVVOLFdBRUosQ0FRQSw4Q0FDSSxpQkFBa0IsQ0FFbEIsVUFBVyxDQURYLFFBQVMsQ0FFVCxXQUNKLENBRUEscUNBV0ksV0FBWSxDQUZaLGVBQWdCLENBSmhCLFFBQVMsQ0FPVCxlQUFnQixDQUxoQixXQUFZLENBSlosTUFBTyxDQU9QLGdCQUFpQixDQVRqQixjQUFlLENBR2YsT0FBUSxDQUZSLEtBQU0sQ0FJTixV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93UHJvZ3Jlc3NGaWxsIHtcbiAgICBoZWlnaHQ6IDEwMCU7XG4gICAgYmFja2dyb3VuZDogIzNiODJmNjtcbiAgICB0cmFuc2l0aW9uOiB3aWR0aCAwLjJzIGVhc2U7XG59XG5cbi51cGxvYWRSb3dBY3Rpb25zIHtcbiAgICBkaXNwbGF5OiBmbGV4O1xuICAgIGdhcDogNnB4O1xufVxuXG4udXBsb2FkQWN0aW9uQnV0dG9uIHtcbiAgICBib3JkZXI6IDFweCBzb2xpZCAjZDFkNWRiO1xuICAgIGJhY2tncm91bmQ6ICNmOWZhZmI7XG4gICAgY29sb3I6ICMzNzQxNTE7XG4gICAgZm9udC1zaXplOiAwLjdyZW07XG4gICAgcGFkZGluZzogMnB4IDhweDtcbiAgICBib3JkZXItcmFkaXVzOiA2cHg7XG4gICAgY3Vyc29yOiBwb2ludGVyO1xuICAgIHRyYW5zaXRpb246IGFsbCAwLjE1cyBlYXNlLWluLW91dDtcbn1cblxuLnVwbG9hZEFjdGlvbkJ1dHRvbjpob3ZlciB7XG4gICAgYmFja2dyb3VuZDogI2VlZjJmNztcbiAgICBib3JkZXItY29sb3I6ICNjYmQ1ZjU7XG59XG5cbi51cGxvYWRSb3dFcnJvciB7XG4gICAgZm9udC1zaXplOiAwLjdyZW07XG4gICAgY29sb3I6ICNiOTFjMWM7XG59XG5cbkBrZXlmcmFtZXMgZmFkZU91dCB7XG4gICAgMCUge1xuICAgICAgICBvcGFjaXR5OiAwO1xuICAgIH1cbiAgICAxMCUge1xuICAgICAgICBvcGFjaXR5OiAxO1xuICAgIH1cbiAgICA3MCUge1xuICAgICAgICBvcGFjaXR5OiAxO1xuICAgIH1cbiAgICAxMDAlIHtcbiAgICAgICAgb3BhY2l0eTogMDtcbiAgICB9XG59XG4iXX0= */";
18722
- var styles$d = {"BookEditor":"BookEditor-module_BookEditor__s-0PU","bookEditorContainer":"BookEditor-module_bookEditorContainer__wLMwM","isVerbose":"BookEditor-module_isVerbose__VQ6iL","bookEditorWrapper":"BookEditor-module_bookEditorWrapper__twppD","isBorderRadiusDisabled":"BookEditor-module_isBorderRadiusDisabled__h1I3v","dropOverlay":"BookEditor-module_dropOverlay__xWWoX","bookEditorActionbar":"BookEditor-module_bookEditorActionbar__KW6dc","fullscreen":"BookEditor-module_fullscreen__rktsl","button":"BookEditor-module_button__hS390","savedNotification":"BookEditor-module_savedNotification__OiX9L","fadeOut":"BookEditor-module_fadeOut__q8JnR","uploadPanel":"BookEditor-module_uploadPanel__2JJtD","uploadPanelHeader":"BookEditor-module_uploadPanelHeader__pdJd2","uploadPanelTitle":"BookEditor-module_uploadPanelTitle__TJIVF","uploadPanelHeaderMeta":"BookEditor-module_uploadPanelHeaderMeta__Xw0uI","uploadPanelSummary":"BookEditor-module_uploadPanelSummary__rwSbG","uploadPanelProgressBar":"BookEditor-module_uploadPanelProgressBar__a6pjf","uploadPanelProgressFill":"BookEditor-module_uploadPanelProgressFill__l-TKR","uploadPanelList":"BookEditor-module_uploadPanelList__VxEd5","uploadRow":"BookEditor-module_uploadRow__QiSFg","uploadRowHeader":"BookEditor-module_uploadRowHeader__po0j5","uploadRowName":"BookEditor-module_uploadRowName__doQRO","uploadRowStatus":"BookEditor-module_uploadRowStatus__jsUb-","uploadRowMeta":"BookEditor-module_uploadRowMeta__1lz9h","uploadRowProgressBar":"BookEditor-module_uploadRowProgressBar__NoBA7","uploadRowProgressFill":"BookEditor-module_uploadRowProgressFill__TrP7e","uploadRowActions":"BookEditor-module_uploadRowActions__5Y1Mq","uploadActionButton":"BookEditor-module_uploadActionButton__CqJrr","uploadRowError":"BookEditor-module_uploadRowError__eEHWw"};
18721
+ var css_248z$d = ".BookEditor-module_BookEditor__s-0PU{width:100%}.BookEditor-module_bookEditorContainer__wLMwM{box-sizing:border-box;height:100%;padding:10px 25px 0;position:relative;width:100%}.BookEditor-module_bookEditorContainer__wLMwM.BookEditor-module_isVerbose__VQ6iL{background-color:rgba(0,0,0,.05);outline:1px dotted rgba(0,0,0,.5)}.BookEditor-module_isVerbose__VQ6iL{outline:2px dotted #ff7526}.BookEditor-module_bookEditorWrapper__twppD{background-color:#fff;border:1px solid rgba(209,213,219,.8);border-radius:1rem;box-shadow:0 1px 2px 0 rgba(0,0,0,.05);overflow:hidden;padding-top:10px;transition:box-shadow .2s ease-in-out}.BookEditor-module_isVerbose__VQ6iL .BookEditor-module_bookEditorWrapper__twppD{overflow:visible}.BookEditor-module_bookEditorWrapper__twppD:hover{box-shadow:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -1px rgba(0,0,0,.06)}.BookEditor-module_BookEditor__s-0PU[data-book-editor-theme=dark] .BookEditor-module_bookEditorWrapper__twppD{background:linear-gradient(180deg,rgba(15,23,42,.98),rgba(8,15,28,.98));border-color:rgba(51,65,85,.92);box-shadow:0 20px 45px rgba(2,6,23,.4)}.BookEditor-module_BookEditor__s-0PU[data-book-editor-theme=dark] .BookEditor-module_bookEditorWrapper__twppD:hover{box-shadow:0 24px 50px rgba(2,6,23,.48)}.BookEditor-module_bookEditorWrapper__twppD.BookEditor-module_isBorderRadiusDisabled__h1I3v{border-radius:0}.BookEditor-module_dropOverlay__xWWoX{align-items:center;background-color:rgba(0,0,0,.5);bottom:0;color:#fff;display:flex;font-size:1.5rem;justify-content:center;left:0;pointer-events:none;position:absolute;right:0;top:0;z-index:100}.BookEditor-module_bookEditorActionbar__KW6dc{position:absolute;right:55px;top:10px;z-index:100}.BookEditor-module_fullscreen__rktsl{border:none;border-radius:0;bottom:0;box-shadow:none;height:100%;left:0;padding-top:50px;position:fixed;right:0;top:0;width:100%;z-index:9999}.BookEditor-module_button__hS390{align-items:center;background-color:#fff;border:1px solid #d1d5db;border-radius:.375rem;box-shadow:0 1px 2px 0 rgba(0,0,0,.05);color:#374151;cursor:pointer;display:inline-flex;gap:.5rem;padding:.5rem 1rem;transition:all .2s ease-in-out}.BookEditor-module_button__hS390:hover{background-color:#f9fafb;border-color:#b7bcce;box-shadow:0 1px 3px 0 rgba(0,0,0,.1),0 1px 2px 0 rgba(0,0,0,.06)}.BookEditor-module_BookEditor__s-0PU[data-book-editor-theme=dark] .BookEditor-module_button__hS390{background-color:rgba(15,23,42,.92);border-color:rgba(71,85,105,.9);box-shadow:0 1px 2px 0 rgba(2,6,23,.35);color:#e2e8f0}.BookEditor-module_BookEditor__s-0PU[data-book-editor-theme=dark] .BookEditor-module_button__hS390:hover{background-color:rgba(30,41,59,.98);border-color:rgba(125,211,252,.5);box-shadow:0 10px 24px rgba(2,6,23,.35)}.BookEditor-module_savedNotification__OiX9L{align-items:center;animation:BookEditor-module_fadeOut__q8JnR 2s forwards;background-color:rgba(0,0,0,.7);border-radius:.5rem;color:#fff;display:flex;font-size:1.25rem;gap:.5rem;left:50%;padding:1rem 2rem;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%);z-index:1000}.BookEditor-module_BookEditor__s-0PU[data-book-editor-theme=dark] .BookEditor-module_savedNotification__OiX9L{background-color:rgba(2,6,23,.86);border:1px solid rgba(51,65,85,.9);color:#e2e8f0}.BookEditor-module_uploadPanel__2JJtD{background:hsla(0,0%,100%,.98);border:1px solid rgba(209,213,219,.9);border-radius:12px;bottom:20px;box-shadow:0 12px 30px rgba(15,23,42,.15);display:flex;flex-direction:column;gap:10px;max-width:calc(100% - 40px);padding:12px;position:absolute;right:20px;width:420px;z-index:220}.BookEditor-module_BookEditor__s-0PU[data-book-editor-theme=dark] .BookEditor-module_uploadPanel__2JJtD{background:rgba(8,15,28,.96);border-color:rgba(51,65,85,.9);box-shadow:0 18px 40px rgba(2,6,23,.45)}.BookEditor-module_uploadPanelHeader__pdJd2{align-items:center;display:flex;gap:12px;justify-content:space-between}.BookEditor-module_uploadPanelTitle__TJIVF{color:#111827;font-size:.95rem;font-weight:600}.BookEditor-module_BookEditor__s-0PU[data-book-editor-theme=dark] .BookEditor-module_uploadPanelTitle__TJIVF{color:#f8fafc}.BookEditor-module_uploadPanelHeaderMeta__Xw0uI{color:#6b7280;font-size:.75rem}.BookEditor-module_BookEditor__s-0PU[data-book-editor-theme=dark] .BookEditor-module_uploadPanelHeaderMeta__Xw0uI,.BookEditor-module_BookEditor__s-0PU[data-book-editor-theme=dark] .BookEditor-module_uploadPanelSummary__rwSbG,.BookEditor-module_BookEditor__s-0PU[data-book-editor-theme=dark] .BookEditor-module_uploadRowMeta__1lz9h,.BookEditor-module_BookEditor__s-0PU[data-book-editor-theme=dark] .BookEditor-module_uploadRowStatus__jsUb-{color:#94a3b8}.BookEditor-module_uploadPanelSummary__rwSbG{color:#6b7280;display:grid;font-size:.75rem;gap:4px 12px;grid-template-columns:1fr 1fr}.BookEditor-module_uploadPanelProgressBar__a6pjf{background:#e5e7eb;border-radius:999px;height:6px;overflow:hidden}.BookEditor-module_uploadPanelProgressFill__l-TKR{background:linear-gradient(90deg,#2563eb,#10b981);height:100%;transition:width .2s ease}.BookEditor-module_BookEditor__s-0PU[data-book-editor-theme=dark] .BookEditor-module_uploadPanelProgressBar__a6pjf,.BookEditor-module_BookEditor__s-0PU[data-book-editor-theme=dark] .BookEditor-module_uploadRowProgressBar__NoBA7{background:#1e293b}.BookEditor-module_uploadPanelList__VxEd5{display:flex;flex-direction:column;gap:8px;max-height:220px;overflow-y:auto;padding-right:4px}.BookEditor-module_uploadRow__QiSFg{background:#fff;border:1px solid #e5e7eb;border-radius:10px;display:flex;flex-direction:column;gap:6px;padding:8px}.BookEditor-module_BookEditor__s-0PU[data-book-editor-theme=dark] .BookEditor-module_uploadRow__QiSFg{background:rgba(15,23,42,.92);border-color:#334155}.BookEditor-module_uploadRowHeader__po0j5{align-items:center;display:flex;gap:8px;justify-content:space-between}.BookEditor-module_uploadRowName__doQRO{color:#111827;font-size:.8rem;font-weight:600;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.BookEditor-module_BookEditor__s-0PU[data-book-editor-theme=dark] .BookEditor-module_uploadRowName__doQRO{color:#f8fafc}.BookEditor-module_uploadRowStatus__jsUb-{color:#6b7280;font-size:.7rem}.BookEditor-module_uploadRowMeta__1lz9h{color:#6b7280;display:flex;font-size:.7rem;justify-content:space-between}.BookEditor-module_uploadRowProgressBar__NoBA7{background:#e5e7eb;border-radius:999px;height:4px;overflow:hidden}.BookEditor-module_uploadRowProgressFill__TrP7e{background:#3b82f6;height:100%;transition:width .2s ease}.BookEditor-module_uploadRowActions__5Y1Mq{display:flex;gap:6px}.BookEditor-module_uploadActionButton__CqJrr{background:#f9fafb;border:1px solid #d1d5db;border-radius:6px;color:#374151;cursor:pointer;font-size:.7rem;padding:2px 8px;transition:all .15s ease-in-out}.BookEditor-module_uploadActionButton__CqJrr:hover{background:#eef2f7;border-color:#cbd5f5}.BookEditor-module_BookEditor__s-0PU[data-book-editor-theme=dark] .BookEditor-module_uploadActionButton__CqJrr{background:#0f172a;border-color:#475569;color:#e2e8f0}.BookEditor-module_BookEditor__s-0PU[data-book-editor-theme=dark] .BookEditor-module_uploadActionButton__CqJrr:hover{background:#1e293b;border-color:#7dd3fc}.BookEditor-module_uploadRowError__eEHWw{color:#b91c1c;font-size:.7rem}@keyframes BookEditor-module_fadeOut__q8JnR{0%{opacity:0}10%{opacity:1}70%{opacity:1}to{opacity:0}}\n/*# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIkJvb2tFZGl0b3IubW9kdWxlLmNzcyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxxQ0FFSSxVQUNKLENBRUEsOENBS0kscUJBQXNCLENBSHRCLFdBQVksQ0FFWixtQkFBb0IsQ0FEcEIsaUJBQWtCLENBRmxCLFVBS0osQ0FFQSxpRkFFSSxnQ0FBcUMsQ0FDckMsaUNBRUosQ0FFQSxvQ0FDSSwwQkFDSixDQUVBLDRDQUtJLHFCQUF1QixDQUR2QixxQ0FBMEMsQ0FGMUMsa0JBQW1CLENBSW5CLHNDQUEyQyxDQUwzQyxlQUFnQixDQUVoQixnQkFBaUIsQ0FJakIscUNBQ0osQ0FDQSxnRkFFSSxnQkFFSixDQ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m9vay1lZGl0b3ItdGhlbWU9J2RhcmsnXSAudXBsb2FkQWN0aW9uQnV0dG9uIHtcbiAgICBib3JkZXItY29sb3I6ICM0NzU1Njk7XG4gICAgYmFja2dyb3VuZDogIzBmMTcyYTtcbiAgICBjb2xvcjogI2UyZThmMDtcbn1cblxuLkJvb2tFZGl0b3JbZGF0YS1ib29rLWVkaXRvci10aGVtZT0nZGFyayddIC51cGxvYWRBY3Rpb25CdXR0b246aG92ZXIge1xuICAgIGJhY2tncm91bmQ6ICMxZTI5M2I7XG4gICAgYm9yZGVyLWNvbG9yOiAjN2RkM2ZjO1xufVxuXG4udXBsb2FkUm93RXJyb3Ige1xuICAgIGZvbnQtc2l6ZTogMC43cmVtO1xuICAgIGNvbG9yOiAjYjkxYzFjO1xufVxuXG5Aa2V5ZnJhbWVzIGZhZGVPdXQge1xuICAgIDAlIHtcbiAgICAgICAgb3BhY2l0eTogMDtcbiAgICB9XG4gICAgMTAlIHtcbiAgICAgICAgb3BhY2l0eTogMTtcbiAgICB9XG4gICAgNzAlIHtcbiAgICAgICAgb3BhY2l0eTogMTtcbiAgICB9XG4gICAgMTAwJSB7XG4gICAgICAgIG9wYWNpdHk6IDA7XG4gICAgfVxufVxuIl19 */";
18722
+ var styles$d = {"BookEditor":"BookEditor-module_BookEditor__s-0PU","bookEditorContainer":"BookEditor-module_bookEditorContainer__wLMwM","isVerbose":"BookEditor-module_isVerbose__VQ6iL","bookEditorWrapper":"BookEditor-module_bookEditorWrapper__twppD","isBorderRadiusDisabled":"BookEditor-module_isBorderRadiusDisabled__h1I3v","dropOverlay":"BookEditor-module_dropOverlay__xWWoX","bookEditorActionbar":"BookEditor-module_bookEditorActionbar__KW6dc","fullscreen":"BookEditor-module_fullscreen__rktsl","button":"BookEditor-module_button__hS390","savedNotification":"BookEditor-module_savedNotification__OiX9L","fadeOut":"BookEditor-module_fadeOut__q8JnR","uploadPanel":"BookEditor-module_uploadPanel__2JJtD","uploadPanelHeader":"BookEditor-module_uploadPanelHeader__pdJd2","uploadPanelTitle":"BookEditor-module_uploadPanelTitle__TJIVF","uploadPanelHeaderMeta":"BookEditor-module_uploadPanelHeaderMeta__Xw0uI","uploadPanelSummary":"BookEditor-module_uploadPanelSummary__rwSbG","uploadRowStatus":"BookEditor-module_uploadRowStatus__jsUb-","uploadRowMeta":"BookEditor-module_uploadRowMeta__1lz9h","uploadPanelProgressBar":"BookEditor-module_uploadPanelProgressBar__a6pjf","uploadPanelProgressFill":"BookEditor-module_uploadPanelProgressFill__l-TKR","uploadRowProgressBar":"BookEditor-module_uploadRowProgressBar__NoBA7","uploadPanelList":"BookEditor-module_uploadPanelList__VxEd5","uploadRow":"BookEditor-module_uploadRow__QiSFg","uploadRowHeader":"BookEditor-module_uploadRowHeader__po0j5","uploadRowName":"BookEditor-module_uploadRowName__doQRO","uploadRowProgressFill":"BookEditor-module_uploadRowProgressFill__TrP7e","uploadRowActions":"BookEditor-module_uploadRowActions__5Y1Mq","uploadActionButton":"BookEditor-module_uploadActionButton__CqJrr","uploadRowError":"BookEditor-module_uploadRowError__eEHWw"};
18723
18723
  styleInject(css_248z$d);
18724
18724
 
18725
18725
  /**
@@ -18930,7 +18930,7 @@
18930
18930
  return CODE_BLOCK_LANGUAGE_ALIASES[normalizedLanguage] || 'plaintext';
18931
18931
  }
18932
18932
 
18933
- var css_248z$c = ".CodeBlock-module_CodeBlock__6K33Z{border:1px solid #444;border-radius:5px;margin:10px 0;max-width:100%;overflow:hidden;width:100%}.CodeBlock-module_CodeBlockHeader__tfOwl{align-items:center;background-color:#2d2d2d;border-bottom:1px solid #444;color:#ccc;display:flex;font-size:.8em;justify-content:space-between;padding:5px 10px}.CodeBlock-module_CodeBlockButtons__rz1VO{display:flex;gap:8px}.CodeBlock-module_CopyButton__M07tp,.CodeBlock-module_CreateAgentButton__kUEnp,.CodeBlock-module_DownloadButton__ZTrzQ{align-items:center;background:transparent;border:none;color:#aaa;cursor:pointer;display:flex;font-size:inherit;gap:5px;padding:0;transition:color .2s}.CodeBlock-module_CopyButton__M07tp:hover,.CodeBlock-module_CreateAgentButton__kUEnp:hover,.CodeBlock-module_DownloadButton__ZTrzQ:hover{color:#fff}.CodeBlock-module_CodeBlock__6K33Z .monaco-editor,.CodeBlock-module_CodeBlock__6K33Z .monaco-editor .overflow-guard{max-width:100%}\n/*# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIkNvZGVCbG9jay5tb2R1bGUuY3NzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLG1DQUlJLHFCQUFzQixDQUZ0QixpQkFBa0IsQ0FEbEIsYUFBYyxDQUtkLGNBQWUsQ0FIZixlQUFnQixDQUVoQixVQUVKLENBRUEseUNBUUksa0JBQW1CLENBUG5CLHdCQUF5QixDQUl6Qiw0QkFBNkIsQ0FIN0IsVUFBVyxDQUlYLFlBQWEsQ0FGYixjQUFnQixDQUdoQiw2QkFBOEIsQ0FKOUIsZ0JBTUosQ0FFQSwwQ0FDSSxZQUFhLENBQ2IsT0FDSixDQUVBLHVIQVVJLGtCQUFtQixDQVBuQixzQkFBdUIsQ0FDdkIsV0FBWSxDQUNaLFVBQVcsQ0FDWCxjQUFlLENBR2YsWUFBYSxDQUZiLGlCQUFrQixDQUlsQixPQUFRLENBSFIsU0FBVSxDQUlWLG9CQUNKLENBRUEseUlBR0ksVUFDSixDQUVBLG9IQUVJLGNBQ0oiLCJmaWxlIjoiQ29kZUJsb2NrLm1vZHVsZS5jc3MiLCJzb3VyY2VzQ29udGVudCI6WyIuQ29kZUJsb2NrIHtcbiAgICBtYXJnaW46IDEwcHggMDtcbiAgICBib3JkZXItcmFkaXVzOiA1cHg7XG4gICAgb3ZlcmZsb3c6IGhpZGRlbjtcbiAgICBib3JkZXI6IDFweCBzb2xpZCAjNDQ0OyAvKiBEYXJrIG1vZGUgYm9yZGVyICovXG4gICAgd2lkdGg6IDEwMCU7XG4gICAgbWF4LXdpZHRoOiAxMDAlO1xufVxu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 var css_248z$c = ".CodeBlock-module_CodeBlock__6K33Z{background:#fff;border:1px solid #d0d7e2;border-radius:5px;margin:10px 0;max-width:100%;overflow:hidden;width:100%}.CodeBlock-module_CodeBlockHeader__tfOwl{align-items:center;background-color:#f8fafc;border-bottom:1px solid #d0d7e2;color:#475569;display:flex;font-size:.8em;justify-content:space-between;padding:5px 10px}.CodeBlock-module_CodeBlockButtons__rz1VO{display:flex;gap:8px}.CodeBlock-module_CopyButton__M07tp,.CodeBlock-module_CreateAgentButton__kUEnp,.CodeBlock-module_DownloadButton__ZTrzQ{align-items:center;background:transparent;border:none;color:#64748b;cursor:pointer;display:flex;font-size:inherit;gap:5px;padding:0;transition:color .2s}.CodeBlock-module_CopyButton__M07tp:hover,.CodeBlock-module_CreateAgentButton__kUEnp:hover,.CodeBlock-module_DownloadButton__ZTrzQ:hover{color:#0f172a}.CodeBlock-module_CodeBlock__6K33Z[data-code-theme=dark]{background:#0f172a;border-color:#334155}.CodeBlock-module_CodeBlock__6K33Z[data-code-theme=dark] .CodeBlock-module_CodeBlockHeader__tfOwl{background-color:#111827;border-bottom-color:#334155;color:#cbd5e1}.CodeBlock-module_CodeBlock__6K33Z[data-code-theme=dark] .CodeBlock-module_CopyButton__M07tp,.CodeBlock-module_CodeBlock__6K33Z[data-code-theme=dark] .CodeBlock-module_CreateAgentButton__kUEnp,.CodeBlock-module_CodeBlock__6K33Z[data-code-theme=dark] .CodeBlock-module_DownloadButton__ZTrzQ{color:#94a3b8}.CodeBlock-module_CodeBlock__6K33Z[data-code-theme=dark] .CodeBlock-module_CopyButton__M07tp:hover,.CodeBlock-module_CodeBlock__6K33Z[data-code-theme=dark] .CodeBlock-module_CreateAgentButton__kUEnp:hover,.CodeBlock-module_CodeBlock__6K33Z[data-code-theme=dark] .CodeBlock-module_DownloadButton__ZTrzQ:hover{color:#f8fafc}.CodeBlock-module_CodeBlock__6K33Z .monaco-editor,.CodeBlock-module_CodeBlock__6K33Z .monaco-editor .overflow-guard{max-width:100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WRlciB7XG4gICAgYmFja2dyb3VuZC1jb2xvcjogIzExMTgyNztcbiAgICBjb2xvcjogI2NiZDVlMTtcbiAgICBib3JkZXItYm90dG9tLWNvbG9yOiAjMzM0MTU1O1xufVxuXG4uQ29kZUJsb2NrW2RhdGEtY29kZS10aGVtZT0nZGFyayddIC5Db3B5QnV0dG9uLFxuLkNvZGVCbG9ja1tkYXRhLWNvZGUtdGhlbWU9J2RhcmsnXSAuRG93bmxvYWRCdXR0b24sXG4uQ29kZUJsb2NrW2RhdGEtY29kZS10aGVtZT0nZGFyayddIC5DcmVhdGVBZ2VudEJ1dHRvbiB7XG4gICAgY29sb3I6ICM5NGEzYjg7XG59XG5cbi5Db2RlQmxvY2tbZGF0YS1jb2RlLXRoZW1lPSdkYXJrJ10gLkNvcHlCdXR0b246aG92ZXIsXG4uQ29kZUJsb2NrW2RhdGEtY29kZS10aGVtZT0nZGFyayddIC5Eb3dubG9hZEJ1dHRvbjpob3Zlcixcbi5Db2RlQmxvY2tbZGF0YS1jb2RlLXRoZW1lPSdkYXJrJ10gLkNyZWF0ZUFnZW50QnV0dG9uOmhvdmVyIHtcbiAgICBjb2xvcjogI2Y4ZmFmYztcbn1cblxuLkNvZGVCbG9jayA6Z2xvYmFsKC5tb25hY28tZWRpdG9yKSxcbi5Db2RlQmxvY2sgOmdsb2JhbCgubW9uYWNvLWVkaXRvciAub3ZlcmZsb3ctZ3VhcmQpIHtcbiAgICBtYXgtd2lkdGg6IDEwMCU7XG59XG4iXX0= */";
18934
18934
  var styles$c = {"CodeBlock":"CodeBlock-module_CodeBlock__6K33Z","CodeBlockHeader":"CodeBlock-module_CodeBlockHeader__tfOwl","CodeBlockButtons":"CodeBlock-module_CodeBlockButtons__rz1VO","CopyButton":"CodeBlock-module_CopyButton__M07tp","DownloadButton":"CodeBlock-module_DownloadButton__ZTrzQ","CreateAgentButton":"CodeBlock-module_CreateAgentButton__kUEnp"};
18935
18935
  styleInject(css_248z$c);
18936
18936
 
@@ -18976,7 +18976,7 @@
18976
18976
  *
18977
18977
  * @private Internal utility of `<ChatMessage />` component
18978
18978
  */
18979
- function CodeBlock({ code, language, className, onCreateAgent }) {
18979
+ function CodeBlock({ code, language, className, onCreateAgent, theme = 'LIGHT' }) {
18980
18980
  const reactId = react.useId();
18981
18981
  const normalizedLanguage = resolveCodeBlockLanguage(language);
18982
18982
  const isBookLanguage = normalizedLanguage === 'book';
@@ -19009,9 +19009,9 @@
19009
19009
  };
19010
19010
  const header = language ? (jsxRuntime.jsxs("div", { className: styles$c.CodeBlockHeader, children: [jsxRuntime.jsx("span", { children: language }), jsxRuntime.jsxs("div", { className: styles$c.CodeBlockButtons, children: [jsxRuntime.jsx("button", { onClick: handleCopy, className: styles$c.CopyButton, title: "Copy to clipboard", children: copied ? 'Copied!' : 'Copy' }), jsxRuntime.jsx("button", { onClick: handleDownload, className: styles$c.DownloadButton, title: "Download code", children: "Download" }), isBookLanguage && onCreateAgent && (jsxRuntime.jsx("button", { onClick: () => onCreateAgent(code), className: styles$c.CreateAgentButton, title: "Create agent from this book", children: "Create Agent" }))] })] })) : null;
19011
19011
  if (isBookLanguage) {
19012
- return (jsxRuntime.jsxs("div", { className: classNames(styles$c.CodeBlock, className), children: [header, jsxRuntime.jsx(BookEditor, { value: code, isReadonly: true, height: lines * 25 /* <- [🧠] A bit more than 19px to accommodate BookEditor lines */ })] }));
19012
+ return (jsxRuntime.jsxs("div", { className: classNames(styles$c.CodeBlock, className), "data-code-theme": theme.toLowerCase(), children: [header, jsxRuntime.jsx(BookEditor, { value: code, isReadonly: true, height: lines * 25 /* <- [🧠] A bit more than 19px to accommodate BookEditor lines */, theme: theme })] }));
19013
19013
  }
19014
- return (jsxRuntime.jsxs("div", { className: classNames(styles$c.CodeBlock, className), children: [header, jsxRuntime.jsx(MonacoEditorWithShadowDom, { height: `${height}px`, language: normalizedLanguage, path: modelPath, value: code, theme: "vs-dark", options: {
19014
+ return (jsxRuntime.jsxs("div", { className: classNames(styles$c.CodeBlock, className), "data-code-theme": theme.toLowerCase(), children: [header, jsxRuntime.jsx(MonacoEditorWithShadowDom, { height: `${height}px`, language: normalizedLanguage, path: modelPath, value: code, theme: theme === 'DARK' ? 'vs-dark' : 'vs-light', options: {
19015
19015
  readOnly: true,
19016
19016
  minimap: { enabled: false },
19017
19017
  automaticLayout: true,
@@ -20508,12 +20508,91 @@
20508
20508
  * @private function of BookEditorMonaco
20509
20509
  */
20510
20510
  const BOOK_EDITOR_LANGUAGE_INITIALIZED_FLAG = 'promptbookBookEditorLanguageInitialized';
20511
+ /**
20512
+ * Internal Monaco flag used to avoid re-defining the Book theme when the requested mode stays unchanged.
20513
+ *
20514
+ * @private function of BookEditorMonaco
20515
+ */
20516
+ const BOOK_EDITOR_THEME_MODE_FLAG = 'promptbookBookEditorThemeMode';
20511
20517
  /**
20512
20518
  * Matches fenced code-block delimiters, including optional leading indentation.
20513
20519
  *
20514
20520
  * @private function of BookEditorMonaco
20515
20521
  */
20516
20522
  const CODE_BLOCK_FENCE_REGEX = /^\s*```.*$/;
20523
+ /**
20524
+ * Shared token rules reused by both light and dark Book Monaco themes.
20525
+ *
20526
+ * @private function of BookEditorMonaco
20527
+ */
20528
+ const BOOK_EDITOR_THEME_RULES = [
20529
+ {
20530
+ token: 'title',
20531
+ foreground: PROMPTBOOK_SYNTAX_COLORS.TITLE.toHex(),
20532
+ fontStyle: 'bold underline',
20533
+ },
20534
+ {
20535
+ token: 'commitment',
20536
+ foreground: PROMPTBOOK_SYNTAX_COLORS.COMMITMENT.toHex(),
20537
+ fontStyle: 'bold',
20538
+ },
20539
+ {
20540
+ token: 'note-commitment',
20541
+ foreground: PROMPTBOOK_SYNTAX_COLORS.NOTE_COMMITMENT.toHex(),
20542
+ },
20543
+ {
20544
+ token: 'todo-commitment',
20545
+ foreground: PROMPTBOOK_SYNTAX_COLORS.TODO_COMMITMENT_TEXT.toHex(),
20546
+ background: PROMPTBOOK_SYNTAX_COLORS.TODO_COMMITMENT_BACKGROUND.toHex(),
20547
+ fontStyle: 'bold',
20548
+ },
20549
+ {
20550
+ token: 'parameter',
20551
+ foreground: PROMPTBOOK_SYNTAX_COLORS.PARAMETER.toHex(),
20552
+ fontStyle: 'italic',
20553
+ },
20554
+ {
20555
+ token: 'agent-reference',
20556
+ foreground: PROMPTBOOK_SYNTAX_COLORS.COMMITMENT.toHex(),
20557
+ fontStyle: 'underline',
20558
+ },
20559
+ {
20560
+ token: 'code-block',
20561
+ foreground: PROMPTBOOK_SYNTAX_COLORS.CODE_BLOCK.toHex(),
20562
+ },
20563
+ ];
20564
+ /**
20565
+ * Re-defines the shared Book Monaco theme according to the requested light/dark mode.
20566
+ *
20567
+ * @private function of BookEditorMonaco
20568
+ */
20569
+ function applyBookEditorMonacoTheme(monaco, theme) {
20570
+ const colors = theme === 'DARK'
20571
+ ? {
20572
+ 'editor.background': '#09111f',
20573
+ 'editor.foreground': '#e2e8f0',
20574
+ 'editorLineNumber.foreground': '#64748b',
20575
+ 'editorLineNumber.activeForeground': '#cbd5e1',
20576
+ 'editorCursor.foreground': '#7dd3fc',
20577
+ 'editor.selectionBackground': '#1d4ed866',
20578
+ 'editor.inactiveSelectionBackground': '#1e3a8a44',
20579
+ 'editor.scrollbarSlider.background': '#334155',
20580
+ 'editor.scrollbarSlider.hoverBackground': '#475569',
20581
+ 'editor.scrollbarSlider.activeBackground': '#64748b',
20582
+ }
20583
+ : {
20584
+ 'editor.scrollbarSlider.background': '#E0E0E0',
20585
+ 'editor.scrollbarSlider.hoverBackground': '#D0D0D0',
20586
+ 'editor.scrollbarSlider.activeBackground': '#C0C0C0',
20587
+ };
20588
+ monaco.editor.defineTheme(BookEditorMonacoConstants.BOOK_THEME_ID, {
20589
+ base: theme === 'DARK' ? 'vs-dark' : 'vs',
20590
+ inherit: true,
20591
+ rules: [...BOOK_EDITOR_THEME_RULES],
20592
+ colors,
20593
+ });
20594
+ monaco.editor.setTheme(BookEditorMonacoConstants.BOOK_THEME_ID);
20595
+ }
20517
20596
  /**
20518
20597
  * Builds a regex that matches one commitment keyword at line start.
20519
20598
  *
@@ -20591,13 +20670,19 @@
20591
20670
  *
20592
20671
  * @private function of BookEditorMonaco
20593
20672
  */
20594
- function ensureBookEditorMonacoLanguage(monaco) {
20673
+ function ensureBookEditorMonacoLanguage(monaco, theme = 'LIGHT') {
20595
20674
  const monacoWithLanguageState = monaco;
20596
20675
  if (monacoWithLanguageState[BOOK_EDITOR_LANGUAGE_INITIALIZED_FLAG]) {
20676
+ if (monacoWithLanguageState[BOOK_EDITOR_THEME_MODE_FLAG] !== theme) {
20677
+ applyBookEditorMonacoTheme(monaco, theme);
20678
+ monacoWithLanguageState[BOOK_EDITOR_THEME_MODE_FLAG] = theme;
20679
+ return;
20680
+ }
20597
20681
  monaco.editor.setTheme(BookEditorMonacoConstants.BOOK_THEME_ID);
20598
20682
  return;
20599
20683
  }
20600
20684
  monacoWithLanguageState[BOOK_EDITOR_LANGUAGE_INITIALIZED_FLAG] = true;
20685
+ monacoWithLanguageState[BOOK_EDITOR_THEME_MODE_FLAG] = theme;
20601
20686
  monaco.languages.register({ id: BookEditorMonacoConstants.BOOK_LANGUAGE_ID });
20602
20687
  const commitmentDefinitions = getAllCommitmentDefinitions();
20603
20688
  const commitmentTypes = [...new Set(commitmentDefinitions.map(({ type }) => type))];
@@ -20692,52 +20777,7 @@
20692
20777
  return { links };
20693
20778
  },
20694
20779
  });
20695
- monaco.editor.defineTheme(BookEditorMonacoConstants.BOOK_THEME_ID, {
20696
- base: 'vs',
20697
- inherit: true,
20698
- rules: [
20699
- {
20700
- token: 'title',
20701
- foreground: PROMPTBOOK_SYNTAX_COLORS.TITLE.toHex(),
20702
- fontStyle: 'bold underline',
20703
- },
20704
- {
20705
- token: 'commitment',
20706
- foreground: PROMPTBOOK_SYNTAX_COLORS.COMMITMENT.toHex(),
20707
- fontStyle: 'bold',
20708
- },
20709
- {
20710
- token: 'note-commitment',
20711
- foreground: PROMPTBOOK_SYNTAX_COLORS.NOTE_COMMITMENT.toHex(),
20712
- },
20713
- {
20714
- token: 'todo-commitment',
20715
- foreground: PROMPTBOOK_SYNTAX_COLORS.TODO_COMMITMENT_TEXT.toHex(),
20716
- background: PROMPTBOOK_SYNTAX_COLORS.TODO_COMMITMENT_BACKGROUND.toHex(),
20717
- fontStyle: 'bold',
20718
- },
20719
- {
20720
- token: 'parameter',
20721
- foreground: PROMPTBOOK_SYNTAX_COLORS.PARAMETER.toHex(),
20722
- fontStyle: 'italic',
20723
- },
20724
- {
20725
- token: 'agent-reference',
20726
- foreground: PROMPTBOOK_SYNTAX_COLORS.COMMITMENT.toHex(),
20727
- fontStyle: 'underline',
20728
- },
20729
- {
20730
- token: 'code-block',
20731
- foreground: PROMPTBOOK_SYNTAX_COLORS.CODE_BLOCK.toHex(),
20732
- },
20733
- ],
20734
- colors: {
20735
- 'editor.scrollbarSlider.background': '#E0E0E0',
20736
- 'editor.scrollbarSlider.hoverBackground': '#D0D0D0',
20737
- 'editor.scrollbarSlider.activeBackground': '#C0C0C0',
20738
- },
20739
- });
20740
- monaco.editor.setTheme(BookEditorMonacoConstants.BOOK_THEME_ID);
20780
+ applyBookEditorMonacoTheme(monaco, theme);
20741
20781
  }
20742
20782
  /**
20743
20783
  * Ensures the mounted Monaco editor model uses Book language and Book theme.
@@ -20750,8 +20790,8 @@
20750
20790
  * @private function of BookEditorMonaco
20751
20791
  */
20752
20792
  function ensureBookEditorMonacoLanguageForEditor(props) {
20753
- const { monaco, monacoEditor } = props;
20754
- ensureBookEditorMonacoLanguage(monaco);
20793
+ const { monaco, monacoEditor, theme = 'LIGHT' } = props;
20794
+ ensureBookEditorMonacoLanguage(monaco, theme);
20755
20795
  const model = monacoEditor.getModel();
20756
20796
  if (!model) {
20757
20797
  return;
@@ -20766,13 +20806,13 @@
20766
20806
  *
20767
20807
  * @private function of BookEditorMonaco
20768
20808
  */
20769
- function useBookEditorMonacoLanguage({ monaco }) {
20809
+ function useBookEditorMonacoLanguage({ monaco, theme }) {
20770
20810
  react.useEffect(() => {
20771
20811
  if (!monaco) {
20772
20812
  return;
20773
20813
  }
20774
- ensureBookEditorMonacoLanguage(monaco);
20775
- }, [monaco]);
20814
+ ensureBookEditorMonacoLanguage(monaco, theme);
20815
+ }, [monaco, theme]);
20776
20816
  }
20777
20817
 
20778
20818
  /**
@@ -20786,9 +20826,13 @@
20786
20826
  *
20787
20827
  * @private function of BookEditorMonaco
20788
20828
  */
20789
- function useBookEditorMonacoStyles({ instanceClass, scaledLineHeight, scaledContentPaddingLeft, scaledVerticalLineLeft, zoomLevel, }) {
20829
+ function useBookEditorMonacoStyles({ instanceClass, scaledLineHeight, scaledContentPaddingLeft, scaledVerticalLineLeft, zoomLevel, theme, }) {
20790
20830
  react.useEffect(() => {
20791
20831
  const styleId = `notebook-margin-line-style-${instanceClass}`;
20832
+ const lineColor = theme === 'DARK' ? '#1f2937' : PROMPTBOOK_SYNTAX_COLORS.LINE.toHex();
20833
+ const separatorColor = theme === 'DARK' ? '#334155' : PROMPTBOOK_SYNTAX_COLORS.SEPARATOR.toHex();
20834
+ const codeBlockBackground = theme === 'DARK' ? '#0f172a99' : '#f5f5f566';
20835
+ const codeBlockBorderColor = theme === 'DARK' ? '#38bdf8aa' : PROMPTBOOK_SYNTAX_COLORS.CODE_BLOCK.toHex();
20792
20836
  let style = document.getElementById(styleId);
20793
20837
  if (!style) {
20794
20838
  style = document.createElement('style');
@@ -20801,7 +20845,7 @@
20801
20845
  /* <- [🚚] */
20802
20846
 
20803
20847
  .${instanceClass} .monaco-editor .view-lines {
20804
- background-image: linear-gradient(to bottom, transparent ${scaledLineHeight - 1}px, ${PROMPTBOOK_SYNTAX_COLORS.LINE.toHex()} ${scaledLineHeight - 1}px);
20848
+ background-image: linear-gradient(to bottom, transparent ${scaledLineHeight - 1}px, ${lineColor} ${scaledLineHeight - 1}px);
20805
20849
  background-size: calc(100% + ${scaledContentPaddingLeft}px) ${scaledLineHeight}px;
20806
20850
  background-position-x: -${scaledContentPaddingLeft}px;
20807
20851
  background-position-y: ${scaledLineHeight * BACKGROUND_POSITION_Y_MULTIPLIER}px;
@@ -20813,7 +20857,7 @@
20813
20857
  top: 0;
20814
20858
  bottom: 0;
20815
20859
  width: 1px;
20816
- background-color: ${PROMPTBOOK_SYNTAX_COLORS.LINE.toHex()};
20860
+ background-color: ${lineColor};
20817
20861
  z-index: 10;
20818
20862
  }
20819
20863
 
@@ -20821,8 +20865,8 @@
20821
20865
  background: linear-gradient(
20822
20866
  to bottom,
20823
20867
  transparent ${scaledLineHeight * 0.9 - 2}px,
20824
- ${PROMPTBOOK_SYNTAX_COLORS.SEPARATOR.toHex()} ${scaledLineHeight * 0.9 - 2}px,
20825
- ${PROMPTBOOK_SYNTAX_COLORS.SEPARATOR.toHex()} ${scaledLineHeight * 0.9 + 1}px,
20868
+ ${separatorColor} ${scaledLineHeight * 0.9 - 2}px,
20869
+ ${separatorColor} ${scaledLineHeight * 0.9 + 1}px,
20826
20870
  transparent ${scaledLineHeight * 0.9 + 1}px
20827
20871
  );
20828
20872
  }
@@ -20832,22 +20876,22 @@
20832
20876
  }
20833
20877
 
20834
20878
  .${instanceClass} .monaco-editor .code-block-box {
20835
- background-color: #f5f5f566;
20836
- border-left: 1px solid ${PROMPTBOOK_SYNTAX_COLORS.CODE_BLOCK.toHex()};
20837
- border-right: 1px solid ${PROMPTBOOK_SYNTAX_COLORS.CODE_BLOCK.toHex()};
20879
+ background-color: ${codeBlockBackground};
20880
+ border-left: 1px solid ${codeBlockBorderColor};
20881
+ border-right: 1px solid ${codeBlockBorderColor};
20838
20882
  padding-left: ${Math.round(8 * zoomLevel)}px;
20839
20883
  padding-right: ${Math.round(8 * zoomLevel)}px;
20840
20884
  }
20841
20885
 
20842
20886
  .${instanceClass} .monaco-editor .code-block-top {
20843
- border-top: 1px solid ${PROMPTBOOK_SYNTAX_COLORS.CODE_BLOCK.toHex()};
20887
+ border-top: 1px solid ${codeBlockBorderColor};
20844
20888
  border-top-left-radius: ${Math.round(10 * zoomLevel)}px;
20845
20889
  border-top-right-radius: ${Math.round(10 * zoomLevel)}px;
20846
20890
  overflow: hidden;
20847
20891
  }
20848
20892
 
20849
20893
  .${instanceClass} .monaco-editor .code-block-bottom {
20850
- border-bottom: 1px solid ${PROMPTBOOK_SYNTAX_COLORS.CODE_BLOCK.toHex()};
20894
+ border-bottom: 1px solid ${codeBlockBorderColor};
20851
20895
  border-bottom-left-radius: ${Math.round(10 * zoomLevel)}px;
20852
20896
  border-bottom-right-radius: ${Math.round(10 * zoomLevel)}px;
20853
20897
  overflow: hidden;
@@ -20858,7 +20902,7 @@
20858
20902
  style === null || style === void 0 ? void 0 : style.remove();
20859
20903
  }
20860
20904
  };
20861
- }, [instanceClass, scaledLineHeight, scaledContentPaddingLeft, scaledVerticalLineLeft, zoomLevel]);
20905
+ }, [instanceClass, scaledLineHeight, scaledContentPaddingLeft, scaledVerticalLineLeft, theme, zoomLevel]);
20862
20906
  }
20863
20907
 
20864
20908
  /**
@@ -21771,7 +21815,7 @@
21771
21815
  * @private Internal component used by `BookEditor`
21772
21816
  */
21773
21817
  function BookEditorMonaco(props) {
21774
- const { value, onChange, diagnostics, isReadonly, translations, onFileUpload, isUploadButtonShown, isCameraButtonShown, isDownloadButtonShown, isAboutButtonShown = true, isFullscreenButtonShown = true, onFullscreenClick, isFullscreen, zoom = 1, monacoModelPath, hoistedMenuItems, } = props;
21818
+ const { value, onChange, diagnostics, isReadonly, theme = 'LIGHT', translations, onFileUpload, isUploadButtonShown, isCameraButtonShown, isDownloadButtonShown, isAboutButtonShown = true, isFullscreenButtonShown = true, onFullscreenClick, isFullscreen, zoom = 1, monacoModelPath, hoistedMenuItems, } = props;
21775
21819
  const zoomLevel = zoom;
21776
21820
  const scaledLineHeight = Math.round(BookEditorMonacoConstants.LINE_HEIGHT * zoomLevel);
21777
21821
  const scaledContentPaddingLeft = Math.max(8, Math.round(BookEditorMonacoConstants.CONTENT_PADDING_LEFT * zoomLevel));
@@ -21796,7 +21840,7 @@
21796
21840
  onFileUpload,
21797
21841
  });
21798
21842
  const combinedDiagnostics = [...(diagnostics || []), ...createDeprecatedCommitmentDiagnostics(value)];
21799
- useBookEditorMonacoLanguage({ monaco });
21843
+ useBookEditorMonacoLanguage({ monaco, theme });
21800
21844
  useBookEditorMonacoDiagnostics({ monaco, editor, diagnostics: combinedDiagnostics });
21801
21845
  useBookEditorMonacoDecorations({ editor, monaco });
21802
21846
  useBookEditorMonacoStyles({
@@ -21805,6 +21849,7 @@
21805
21849
  scaledLineHeight,
21806
21850
  scaledVerticalLineLeft,
21807
21851
  zoomLevel,
21852
+ theme,
21808
21853
  });
21809
21854
  /**
21810
21855
  * Re-applies Book language + theme to the currently mounted Monaco model.
@@ -21813,9 +21858,9 @@
21813
21858
  if (!editor || !monaco) {
21814
21859
  return;
21815
21860
  }
21816
- ensureBookEditorMonacoLanguageForEditor({ monaco, monacoEditor: editor });
21861
+ ensureBookEditorMonacoLanguageForEditor({ monaco, monacoEditor: editor, theme });
21817
21862
  logBookEditorMonacoDebug(`Re-applied Book Monaco language/theme (${reason}).`);
21818
- }, [editor, monaco]);
21863
+ }, [editor, monaco, theme]);
21819
21864
  react.useEffect(() => {
21820
21865
  setIsTouchDevice(typeof window !== 'undefined' && window.matchMedia('(pointer: coarse)').matches);
21821
21866
  }, []);
@@ -21922,16 +21967,16 @@
21922
21967
  * Ensures Book language/tokenizer is ready before Monaco creates the editor model.
21923
21968
  */
21924
21969
  const handleBeforeMonacoMount = react.useCallback((beforeMountMonaco) => {
21925
- ensureBookEditorMonacoLanguage(beforeMountMonaco);
21926
- }, []);
21970
+ ensureBookEditorMonacoLanguage(beforeMountMonaco, theme);
21971
+ }, [theme]);
21927
21972
  /**
21928
21973
  * Re-applies Book language/theme once Monaco editor is mounted.
21929
21974
  */
21930
21975
  const handleMonacoMount = react.useCallback((mountedEditor, mountedMonaco) => {
21931
21976
  setEditor(mountedEditor);
21932
- ensureBookEditorMonacoLanguageForEditor({ monaco: mountedMonaco, monacoEditor: mountedEditor });
21977
+ ensureBookEditorMonacoLanguageForEditor({ monaco: mountedMonaco, monacoEditor: mountedEditor, theme });
21933
21978
  logBookEditorMonacoDebug('Mounted Monaco editor and re-applied Book language/theme.');
21934
- }, []);
21979
+ }, [theme]);
21935
21980
  const handleDragOver = react.useCallback((event) => {
21936
21981
  event.preventDefault();
21937
21982
  setIsDragOver(true);
@@ -22037,7 +22082,7 @@
22037
22082
  * @public exported from `@promptbook/components`
22038
22083
  */
22039
22084
  function BookEditor(props) {
22040
- const { agentSource, className, style, zoom = 1, value, onChange, diagnostics, onFileUpload, isVerbose = DEFAULT_IS_VERBOSE, isBorderRadiusDisabled = false, isReadonly = false, translations, isUploadButtonShown = true, isCameraButtonShown, isDownloadButtonShown = true, isAboutButtonShown = true, isFullscreenButtonShown = true, sync, monacoModelPath, hoistedMenuItems, } = props;
22085
+ const { agentSource, className, style, theme = 'LIGHT', zoom = 1, value, onChange, diagnostics, onFileUpload, isVerbose = DEFAULT_IS_VERBOSE, isBorderRadiusDisabled = false, isReadonly = false, translations, isUploadButtonShown = true, isCameraButtonShown, isDownloadButtonShown = true, isAboutButtonShown = true, isFullscreenButtonShown = true, sync, monacoModelPath, hoistedMenuItems, } = props;
22041
22086
  const [isFullscreen, setIsFullscreen] = react.useState(false);
22042
22087
  /**
22043
22088
  * Toggles fullscreen mode for the editor.
@@ -22045,7 +22090,7 @@
22045
22090
  const handleFullscreenToggle = () => {
22046
22091
  setIsFullscreen(!isFullscreen);
22047
22092
  };
22048
- const editorContent = (jsxRuntime.jsx("div", { "data-book-component": "BookEditor", className: classNames(styles$d.BookEditor, isVerbose && styles$d.isVerbose, styles$d.bookEditorWrapper, isBorderRadiusDisabled && styles$d.isBorderRadiusDisabled, isFullscreen && styles$d.fullscreen, className), style: isFullscreen
22093
+ const editorContent = (jsxRuntime.jsx("div", { "data-book-component": "BookEditor", "data-book-editor-theme": theme.toLowerCase(), className: classNames(styles$d.BookEditor, isVerbose && styles$d.isVerbose, styles$d.bookEditorWrapper, isBorderRadiusDisabled && styles$d.isBorderRadiusDisabled, isFullscreen && styles$d.fullscreen, className), style: isFullscreen
22049
22094
  ? style
22050
22095
  : {
22051
22096
  ...(style || {}),
@@ -22056,7 +22101,7 @@
22056
22101
  ? `${props.height}px`
22057
22102
  : props.height || `${DEFAULT_BOOK_EDITOR_HEIGHT}px`,
22058
22103
  }),
22059
- }, children: jsxRuntime.jsx(BookEditorMonaco, { value: agentSource || value, onChange: onChange, diagnostics: diagnostics, onFileUpload: onFileUpload, isVerbose: isVerbose, isBorderRadiusDisabled: isBorderRadiusDisabled, isReadonly: isReadonly, translations: translations, isUploadButtonShown: isUploadButtonShown, isCameraButtonShown: isCameraButtonShown, isDownloadButtonShown: isDownloadButtonShown, isAboutButtonShown: isAboutButtonShown, isFullscreenButtonShown: isFullscreenButtonShown, onFullscreenClick: handleFullscreenToggle, isFullscreen: isFullscreen, sync: sync, zoom: zoom, monacoModelPath: monacoModelPath, hoistedMenuItems: hoistedMenuItems }) }));
22104
+ }, children: jsxRuntime.jsx(BookEditorMonaco, { value: agentSource || value, onChange: onChange, diagnostics: diagnostics, onFileUpload: onFileUpload, isVerbose: isVerbose, isBorderRadiusDisabled: isBorderRadiusDisabled, isReadonly: isReadonly, translations: translations, isUploadButtonShown: isUploadButtonShown, isCameraButtonShown: isCameraButtonShown, isDownloadButtonShown: isDownloadButtonShown, isAboutButtonShown: isAboutButtonShown, isFullscreenButtonShown: isFullscreenButtonShown, onFullscreenClick: handleFullscreenToggle, isFullscreen: isFullscreen, sync: sync, zoom: zoom, monacoModelPath: monacoModelPath, hoistedMenuItems: hoistedMenuItems, theme: theme }) }));
22060
22105
  return isFullscreen && typeof document !== 'undefined' ? reactDom.createPortal(editorContent, document.body) : editorContent;
22061
22106
  }
22062
22107
 
@@ -26467,37 +26512,49 @@
26467
26512
  * @private shared geometry helper of `octopus3AvatarVisual` and `asciiOctopusAvatarVisual`
26468
26513
  */
26469
26514
  function createOrganicOctopusTentacleShapes(options) {
26470
- const { size, centerX, centerY, bodyRadius, horizontalStretch, tentacleCount, shapePhase, createRandom, timeMs, saltPrefix, bodyPoints } = options;
26515
+ var _a, _b, _c, _d, _e, _f, _g, _h;
26516
+ const { size, centerX, centerY, bodyRadius, horizontalStretch, tentacleCount, shapePhase, createRandom, timeMs, saltPrefix, bodyPoints, variation, } = options;
26471
26517
  const baseY = centerY + bodyRadius * 0.74;
26472
26518
  const lowerBodyAnchorPoints = bodyPoints ? resolveTentacleBodyAnchorPoints(bodyPoints, centerY + bodyRadius * 0.04) : null;
26519
+ const flowLengthScale = (_a = variation === null || variation === void 0 ? void 0 : variation.flowLengthScale) !== null && _a !== void 0 ? _a : 1;
26520
+ const lateralReachScale = (_b = variation === null || variation === void 0 ? void 0 : variation.lateralReachScale) !== null && _b !== void 0 ? _b : 1;
26521
+ const tipReachScale = (_c = variation === null || variation === void 0 ? void 0 : variation.tipReachScale) !== null && _c !== void 0 ? _c : 1;
26522
+ const baseWidthScale = (_d = variation === null || variation === void 0 ? void 0 : variation.baseWidthScale) !== null && _d !== void 0 ? _d : 1;
26523
+ const tipWidthScale = (_e = variation === null || variation === void 0 ? void 0 : variation.tipWidthScale) !== null && _e !== void 0 ? _e : 1;
26524
+ const rootSpreadScale = (_f = variation === null || variation === void 0 ? void 0 : variation.rootSpreadScale) !== null && _f !== void 0 ? _f : 1;
26525
+ const startYOffsetScale = (_g = variation === null || variation === void 0 ? void 0 : variation.startYOffsetScale) !== null && _g !== void 0 ? _g : 1;
26526
+ const swayScale = (_h = variation === null || variation === void 0 ? void 0 : variation.swayScale) !== null && _h !== void 0 ? _h : 1;
26473
26527
  return Array.from({ length: tentacleCount }, (_, tentacleIndex) => {
26474
26528
  const tentacleRandom = createRandom(`${saltPrefix}-tentacle-${tentacleIndex}`);
26475
26529
  const spreadProgress = tentacleCount === 1 ? 0.5 : tentacleIndex / (tentacleCount - 1);
26476
26530
  const centeredProgress = spreadProgress - 0.5;
26531
+ const spreadCenteredProgress = centeredProgress * rootSpreadScale;
26532
+ const spreadAnchorProgress = Math.min(1, Math.max(0, 0.5 + spreadCenteredProgress));
26477
26533
  const temporalSway = Math.sin(timeMs / (720 + tentacleIndex * 34) + shapePhase + tentacleRandom() * Math.PI * 2) *
26478
26534
  size *
26479
- (0.014 + tentacleRandom() * 0.015);
26480
- const flowLength = size * (0.24 + tentacleRandom() * 0.18);
26481
- const curlDirection = centeredProgress === 0 ? (tentacleRandom() < 0.5 ? -1 : 1) : Math.sign(centeredProgress);
26482
- const lateralReach = centeredProgress * size * (0.1 + tentacleRandom() * 0.1) + temporalSway;
26483
- const tipReach = curlDirection * size * (0.025 + tentacleRandom() * 0.07);
26484
- const startYOffset = Math.abs(centeredProgress) * size * 0.012 + tentacleRandom() * size * 0.01;
26535
+ (0.014 + tentacleRandom() * 0.015) *
26536
+ swayScale;
26537
+ const flowLength = size * (0.24 + tentacleRandom() * 0.18) * flowLengthScale;
26538
+ const curlDirection = spreadCenteredProgress === 0 ? (tentacleRandom() < 0.5 ? -1 : 1) : Math.sign(spreadCenteredProgress);
26539
+ const lateralReach = spreadCenteredProgress * size * (0.1 + tentacleRandom() * 0.1) * lateralReachScale + temporalSway;
26540
+ const tipReach = curlDirection * size * (0.025 + tentacleRandom() * 0.07) * tipReachScale;
26541
+ const startYOffset = (Math.abs(spreadCenteredProgress) * size * 0.012 + tentacleRandom() * size * 0.01) * startYOffsetScale;
26485
26542
  const startPoint = lowerBodyAnchorPoints && lowerBodyAnchorPoints.length >= 2
26486
26543
  ? createInsetTentacleStartPoint({
26487
26544
  bodyPoints: lowerBodyAnchorPoints,
26488
- anchorProgress: spreadProgress,
26545
+ anchorProgress: spreadAnchorProgress,
26489
26546
  centerX,
26490
26547
  centerY,
26491
26548
  bodyRadius,
26492
- centeredProgress,
26549
+ centeredProgress: spreadCenteredProgress,
26493
26550
  startYOffset,
26494
26551
  })
26495
26552
  : {
26496
- x: centerX + centeredProgress * bodyRadius * horizontalStretch * 1.52,
26553
+ x: centerX + spreadCenteredProgress * bodyRadius * horizontalStretch * 1.52,
26497
26554
  y: baseY + startYOffset,
26498
26555
  };
26499
26556
  const controlPointOne = {
26500
- x: startPoint.x + centeredProgress * size * 0.045 + temporalSway * 0.4,
26557
+ x: startPoint.x + spreadCenteredProgress * size * 0.045 * lateralReachScale + temporalSway * 0.4,
26501
26558
  y: startPoint.y + flowLength * (0.21 + tentacleRandom() * 0.08),
26502
26559
  };
26503
26560
  const controlPointTwo = {
@@ -26510,8 +26567,8 @@
26510
26567
  flowLength * (0.9 + tentacleRandom() * 0.12) +
26511
26568
  Math.cos(timeMs / (840 + tentacleIndex * 41) + shapePhase) * size * (0.008 + tentacleRandom() * 0.01),
26512
26569
  };
26513
- const baseWidth = size * (0.038 + tentacleRandom() * 0.02) * (1 - Math.abs(centeredProgress) * 0.18);
26514
- const tipWidth = baseWidth * (0.18 + tentacleRandom() * 0.2);
26570
+ const baseWidth = size * (0.038 + tentacleRandom() * 0.02) * (1 - Math.abs(spreadCenteredProgress) * 0.18) * baseWidthScale;
26571
+ const tipWidth = baseWidth * Math.min(0.52, (0.18 + tentacleRandom() * 0.2) * tipWidthScale);
26515
26572
  return {
26516
26573
  startPoint,
26517
26574
  controlPointOne,
@@ -28167,6 +28224,244 @@
28167
28224
  }
28168
28225
 
28169
28226
  /* eslint-disable no-magic-numbers */
28227
+ /**
28228
+ * Builds one deterministic morphology profile for `Octopus3`.
28229
+ *
28230
+ * @param createRandom Seeded random factory scoped to the current avatar.
28231
+ * @returns Stable morphology profile.
28232
+ *
28233
+ * @private helper of `octopus3AvatarVisual`
28234
+ */
28235
+ function createOctopus3MorphologyProfile(createRandom) {
28236
+ const bodyRandom = createRandom('octopus3-body-profile');
28237
+ const faceRandom = createRandom('octopus3-face-profile');
28238
+ const detailRandom = createRandom('octopus3-detail-profile');
28239
+ const bodyFamilyRoll = bodyRandom();
28240
+ let bodyFamily;
28241
+ let body;
28242
+ let tentacles;
28243
+ if (bodyFamilyRoll < 0.34) {
28244
+ bodyFamily = 'lantern';
28245
+ body = {
28246
+ centerXJitterRatio: resolveSeededRange(bodyRandom, -0.018, 0.018),
28247
+ centerYRatio: resolveSeededRange(bodyRandom, 0.39, 0.435),
28248
+ bodyRadiusRatio: resolveSeededRange(bodyRandom, 0.19, 0.23),
28249
+ horizontalStretch: resolveSeededRange(bodyRandom, 0.94, 1.08),
28250
+ verticalStretch: resolveSeededRange(bodyRandom, 1.02, 1.18),
28251
+ mantleLiftRatio: resolveSeededRange(bodyRandom, 0.115, 0.148),
28252
+ lowerDropRatio: resolveSeededRange(bodyRandom, 0.042, 0.066),
28253
+ tentacleDepthRatio: resolveSeededRange(bodyRandom, 0.018, 0.03),
28254
+ wobbleAmplitudeRatio: resolveSeededRange(bodyRandom, 0.009, 0.017),
28255
+ lobeCount: resolveSeededIntegerRange(bodyRandom, 4, 6),
28256
+ pointCount: resolveSeededIntegerRange(bodyRandom, 38, 42),
28257
+ shadowWidthRatio: resolveSeededRange(bodyRandom, 0.18, 0.23),
28258
+ shadowHeightRatio: resolveSeededRange(bodyRandom, 0.055, 0.075),
28259
+ crownHighlightWidthRatio: resolveSeededRange(bodyRandom, 0.14, 0.18),
28260
+ crownHighlightHeightRatio: resolveSeededRange(bodyRandom, 0.045, 0.062),
28261
+ crownHighlightYOffsetRatio: resolveSeededRange(bodyRandom, -0.165, -0.135),
28262
+ };
28263
+ tentacles = {
28264
+ count: resolveSeededIntegerRange(bodyRandom, 7, 10),
28265
+ flowLengthScale: resolveSeededRange(bodyRandom, 1.08, 1.34),
28266
+ lateralReachScale: resolveSeededRange(bodyRandom, 0.72, 0.94),
28267
+ tipReachScale: resolveSeededRange(bodyRandom, 0.82, 1.06),
28268
+ baseWidthScale: resolveSeededRange(bodyRandom, 0.82, 0.98),
28269
+ tipWidthScale: resolveSeededRange(bodyRandom, 0.9, 1.08),
28270
+ rootSpreadScale: resolveSeededRange(bodyRandom, 0.76, 0.94),
28271
+ startYOffsetScale: resolveSeededRange(bodyRandom, 0.82, 1),
28272
+ swayScale: resolveSeededRange(bodyRandom, 0.82, 1.02),
28273
+ };
28274
+ }
28275
+ else if (bodyFamilyRoll < 0.68) {
28276
+ bodyFamily = 'drifter';
28277
+ body = {
28278
+ centerXJitterRatio: resolveSeededRange(bodyRandom, -0.025, 0.025),
28279
+ centerYRatio: resolveSeededRange(bodyRandom, 0.425, 0.46),
28280
+ bodyRadiusRatio: resolveSeededRange(bodyRandom, 0.175, 0.215),
28281
+ horizontalStretch: resolveSeededRange(bodyRandom, 1.22, 1.42),
28282
+ verticalStretch: resolveSeededRange(bodyRandom, 0.82, 0.92),
28283
+ mantleLiftRatio: resolveSeededRange(bodyRandom, 0.092, 0.115),
28284
+ lowerDropRatio: resolveSeededRange(bodyRandom, 0.02, 0.036),
28285
+ tentacleDepthRatio: resolveSeededRange(bodyRandom, 0.032, 0.052),
28286
+ wobbleAmplitudeRatio: resolveSeededRange(bodyRandom, 0.013, 0.022),
28287
+ lobeCount: resolveSeededIntegerRange(bodyRandom, 7, 9),
28288
+ pointCount: resolveSeededIntegerRange(bodyRandom, 40, 46),
28289
+ shadowWidthRatio: resolveSeededRange(bodyRandom, 0.24, 0.28),
28290
+ shadowHeightRatio: resolveSeededRange(bodyRandom, 0.06, 0.082),
28291
+ crownHighlightWidthRatio: resolveSeededRange(bodyRandom, 0.17, 0.22),
28292
+ crownHighlightHeightRatio: resolveSeededRange(bodyRandom, 0.038, 0.055),
28293
+ crownHighlightYOffsetRatio: resolveSeededRange(bodyRandom, -0.14, -0.11),
28294
+ };
28295
+ tentacles = {
28296
+ count: resolveSeededIntegerRange(bodyRandom, 10, 13),
28297
+ flowLengthScale: resolveSeededRange(bodyRandom, 0.88, 1.08),
28298
+ lateralReachScale: resolveSeededRange(bodyRandom, 1.18, 1.42),
28299
+ tipReachScale: resolveSeededRange(bodyRandom, 1.12, 1.42),
28300
+ baseWidthScale: resolveSeededRange(bodyRandom, 0.9, 1.06),
28301
+ tipWidthScale: resolveSeededRange(bodyRandom, 0.88, 1.08),
28302
+ rootSpreadScale: resolveSeededRange(bodyRandom, 1.12, 1.32),
28303
+ startYOffsetScale: resolveSeededRange(bodyRandom, 0.92, 1.14),
28304
+ swayScale: resolveSeededRange(bodyRandom, 1.04, 1.22),
28305
+ };
28306
+ }
28307
+ else {
28308
+ bodyFamily = 'rounded';
28309
+ body = {
28310
+ centerXJitterRatio: resolveSeededRange(bodyRandom, -0.02, 0.02),
28311
+ centerYRatio: resolveSeededRange(bodyRandom, 0.398, 0.442),
28312
+ bodyRadiusRatio: resolveSeededRange(bodyRandom, 0.208, 0.248),
28313
+ horizontalStretch: resolveSeededRange(bodyRandom, 1.06, 1.22),
28314
+ verticalStretch: resolveSeededRange(bodyRandom, 0.9, 1.01),
28315
+ mantleLiftRatio: resolveSeededRange(bodyRandom, 0.1, 0.128),
28316
+ lowerDropRatio: resolveSeededRange(bodyRandom, 0.032, 0.052),
28317
+ tentacleDepthRatio: resolveSeededRange(bodyRandom, 0.038, 0.06),
28318
+ wobbleAmplitudeRatio: resolveSeededRange(bodyRandom, 0.014, 0.024),
28319
+ lobeCount: resolveSeededIntegerRange(bodyRandom, 5, 8),
28320
+ pointCount: resolveSeededIntegerRange(bodyRandom, 39, 44),
28321
+ shadowWidthRatio: resolveSeededRange(bodyRandom, 0.2, 0.25),
28322
+ shadowHeightRatio: resolveSeededRange(bodyRandom, 0.055, 0.08),
28323
+ crownHighlightWidthRatio: resolveSeededRange(bodyRandom, 0.16, 0.2),
28324
+ crownHighlightHeightRatio: resolveSeededRange(bodyRandom, 0.05, 0.07),
28325
+ crownHighlightYOffsetRatio: resolveSeededRange(bodyRandom, -0.155, -0.122),
28326
+ };
28327
+ tentacles = {
28328
+ count: resolveSeededIntegerRange(bodyRandom, 8, 12),
28329
+ flowLengthScale: resolveSeededRange(bodyRandom, 0.94, 1.16),
28330
+ lateralReachScale: resolveSeededRange(bodyRandom, 0.9, 1.14),
28331
+ tipReachScale: resolveSeededRange(bodyRandom, 0.96, 1.22),
28332
+ baseWidthScale: resolveSeededRange(bodyRandom, 1.02, 1.2),
28333
+ tipWidthScale: resolveSeededRange(bodyRandom, 1.02, 1.22),
28334
+ rootSpreadScale: resolveSeededRange(bodyRandom, 0.94, 1.08),
28335
+ startYOffsetScale: resolveSeededRange(bodyRandom, 0.9, 1.08),
28336
+ swayScale: resolveSeededRange(bodyRandom, 0.9, 1.1),
28337
+ };
28338
+ }
28339
+ const faceFamilyRoll = faceRandom();
28340
+ let faceFamily;
28341
+ let face;
28342
+ if (faceFamilyRoll < 0.34) {
28343
+ faceFamily = 'watchful';
28344
+ face = {
28345
+ eyeSpacingRatio: resolveSeededRange(faceRandom, 0.118, 0.152),
28346
+ eyeCenterYOffsetRatio: resolveSeededRange(faceRandom, -0.026, -0.002),
28347
+ eyeRadiusXRatio: resolveSeededRange(faceRandom, 0.05, 0.062),
28348
+ eyeHeightRatio: resolveSeededRange(faceRandom, 1.18, 1.38),
28349
+ eyeRotationRange: resolveSeededRange(faceRandom, 0.16, 0.28),
28350
+ eyeTiltBias: resolveSeededRange(faceRandom, 0.02, 0.06),
28351
+ mouthWidthRatio: resolveSeededRange(faceRandom, 0.058, 0.074),
28352
+ mouthYOffsetRatio: resolveSeededRange(faceRandom, 0.086, 0.104),
28353
+ mouthCurveDepthRatio: resolveSeededRange(faceRandom, 0.126, 0.15),
28354
+ mouthCenterOffsetRatio: resolveSeededRange(faceRandom, -0.006, 0.006),
28355
+ mouthCornerTiltRatio: resolveSeededRange(faceRandom, -0.002, 0.002),
28356
+ eyeStyle: {
28357
+ irisScale: resolveSeededRange(faceRandom, 1, 1.1),
28358
+ pupilWidthScale: resolveSeededRange(faceRandom, 0.86, 1.02),
28359
+ pupilHeightScale: resolveSeededRange(faceRandom, 0.94, 1.08),
28360
+ upperLidArchRatio: resolveSeededRange(faceRandom, 0.96, 1.12),
28361
+ upperLidInsetRatio: resolveSeededRange(faceRandom, 0.08, 0.14),
28362
+ lowerLidOpacity: resolveSeededRange(faceRandom, 0.12, 0.22),
28363
+ },
28364
+ };
28365
+ }
28366
+ else if (faceFamilyRoll < 0.68) {
28367
+ faceFamily = 'sleepy';
28368
+ face = {
28369
+ eyeSpacingRatio: resolveSeededRange(faceRandom, 0.092, 0.124),
28370
+ eyeCenterYOffsetRatio: resolveSeededRange(faceRandom, -0.002, 0.024),
28371
+ eyeRadiusXRatio: resolveSeededRange(faceRandom, 0.058, 0.074),
28372
+ eyeHeightRatio: resolveSeededRange(faceRandom, 0.96, 1.14),
28373
+ eyeRotationRange: resolveSeededRange(faceRandom, 0.1, 0.22),
28374
+ eyeTiltBias: resolveSeededRange(faceRandom, 0.01, 0.05),
28375
+ mouthWidthRatio: resolveSeededRange(faceRandom, 0.066, 0.086),
28376
+ mouthYOffsetRatio: resolveSeededRange(faceRandom, 0.094, 0.118),
28377
+ mouthCurveDepthRatio: resolveSeededRange(faceRandom, 0.118, 0.145),
28378
+ mouthCenterOffsetRatio: resolveSeededRange(faceRandom, -0.004, 0.004),
28379
+ mouthCornerTiltRatio: resolveSeededRange(faceRandom, -0.004, 0.004),
28380
+ eyeStyle: {
28381
+ irisScale: resolveSeededRange(faceRandom, 0.9, 1),
28382
+ pupilWidthScale: resolveSeededRange(faceRandom, 1, 1.18),
28383
+ pupilHeightScale: resolveSeededRange(faceRandom, 0.78, 0.92),
28384
+ upperLidArchRatio: resolveSeededRange(faceRandom, 0.7, 0.88),
28385
+ upperLidInsetRatio: resolveSeededRange(faceRandom, -0.02, 0.06),
28386
+ lowerLidOpacity: resolveSeededRange(faceRandom, 0.22, 0.34),
28387
+ },
28388
+ };
28389
+ }
28390
+ else {
28391
+ faceFamily = 'mischief';
28392
+ face = {
28393
+ eyeSpacingRatio: resolveSeededRange(faceRandom, 0.086, 0.114),
28394
+ eyeCenterYOffsetRatio: resolveSeededRange(faceRandom, -0.018, 0.01),
28395
+ eyeRadiusXRatio: resolveSeededRange(faceRandom, 0.046, 0.06),
28396
+ eyeHeightRatio: resolveSeededRange(faceRandom, 1.08, 1.28),
28397
+ eyeRotationRange: resolveSeededRange(faceRandom, 0.28, 0.44),
28398
+ eyeTiltBias: resolveSeededRange(faceRandom, 0.12, 0.22),
28399
+ mouthWidthRatio: resolveSeededRange(faceRandom, 0.052, 0.074),
28400
+ mouthYOffsetRatio: resolveSeededRange(faceRandom, 0.082, 0.1),
28401
+ mouthCurveDepthRatio: resolveSeededRange(faceRandom, 0.116, 0.15),
28402
+ mouthCenterOffsetRatio: resolveSeededRange(faceRandom, -0.018, 0.018),
28403
+ mouthCornerTiltRatio: resolveSeededRange(faceRandom, -0.01, 0.01),
28404
+ eyeStyle: {
28405
+ irisScale: resolveSeededRange(faceRandom, 1.04, 1.12),
28406
+ pupilWidthScale: resolveSeededRange(faceRandom, 0.72, 0.9),
28407
+ pupilHeightScale: resolveSeededRange(faceRandom, 0.96, 1.14),
28408
+ upperLidArchRatio: resolveSeededRange(faceRandom, 0.88, 1.02),
28409
+ upperLidInsetRatio: resolveSeededRange(faceRandom, 0.04, 0.12),
28410
+ lowerLidOpacity: resolveSeededRange(faceRandom, 0.08, 0.18),
28411
+ },
28412
+ };
28413
+ }
28414
+ return {
28415
+ bodyFamily,
28416
+ faceFamily,
28417
+ body,
28418
+ tentacles,
28419
+ face,
28420
+ details: {
28421
+ mantleCurrentCount: resolveSeededIntegerRange(detailRandom, 4, 8),
28422
+ mantleNodeCount: resolveSeededIntegerRange(detailRandom, 3, 7),
28423
+ },
28424
+ };
28425
+ }
28426
+ /**
28427
+ * Resolves one seeded floating-point number inside the provided range.
28428
+ *
28429
+ * @param random Seeded random generator.
28430
+ * @param minimumValue Inclusive lower bound.
28431
+ * @param maximumValue Inclusive upper bound.
28432
+ * @returns Seeded number within the range.
28433
+ *
28434
+ * @private helper of `octopus3AvatarVisual`
28435
+ */
28436
+ function resolveSeededRange(random, minimumValue, maximumValue) {
28437
+ return minimumValue + random() * (maximumValue - minimumValue);
28438
+ }
28439
+ /**
28440
+ * Resolves one seeded integer inside the provided inclusive range.
28441
+ *
28442
+ * @param random Seeded random generator.
28443
+ * @param minimumValue Inclusive lower bound.
28444
+ * @param maximumValue Inclusive upper bound.
28445
+ * @returns Seeded integer within the range.
28446
+ *
28447
+ * @private helper of `octopus3AvatarVisual`
28448
+ */
28449
+ function resolveSeededIntegerRange(random, minimumValue, maximumValue) {
28450
+ return minimumValue + Math.floor(random() * (maximumValue - minimumValue + 1));
28451
+ }
28452
+ /**
28453
+ * Converts an opacity ratio into a two-digit hexadecimal alpha suffix.
28454
+ *
28455
+ * @param opacity Opacity ratio in the range `[0, 1]`.
28456
+ * @returns Two-digit hexadecimal alpha string.
28457
+ *
28458
+ * @private helper of `octopus3AvatarVisual`
28459
+ */
28460
+ function formatAlphaHex(opacity) {
28461
+ return Math.round(Math.min(1, Math.max(0, opacity)) * 255)
28462
+ .toString(16)
28463
+ .padStart(2, '0');
28464
+ }
28170
28465
  /**
28171
28466
  * Octopus3 avatar visual.
28172
28467
  *
@@ -28179,22 +28474,24 @@
28179
28474
  isAnimated: true,
28180
28475
  supportsPointerTracking: true,
28181
28476
  render({ context, size, palette, createRandom, timeMs, interaction }) {
28182
- const staticRandom = createRandom('octopus3-static');
28183
- const centerX = size * (0.5 + (staticRandom() - 0.5) * 0.02) + interaction.bodyOffsetX * size * 0.05;
28184
- const centerY = size * (0.41 + staticRandom() * 0.05) + interaction.bodyOffsetY * size * 0.035;
28185
- const bodyRadius = size * (0.2 + staticRandom() * 0.045);
28186
- const horizontalStretch = 1.08 + staticRandom() * 0.22;
28187
- const verticalStretch = 0.9 + staticRandom() * 0.12;
28188
- const mantleLift = size * (0.105 + staticRandom() * 0.03);
28189
- const lowerDrop = size * (0.028 + staticRandom() * 0.022);
28190
- const tentacleDepth = size * (0.022 + staticRandom() * 0.018);
28191
- const wobbleAmplitude = size * (0.01 + staticRandom() * 0.01);
28192
- const lobeCount = 5 + Math.floor(staticRandom() * 3);
28193
- const shapePhase = staticRandom() * Math.PI * 2;
28194
- const tentacleCount = 8 + Math.floor(staticRandom() * 5);
28195
- const eyeSpacing = size * (0.11 + staticRandom() * 0.04);
28196
- const eyeRadiusX = size * (0.056 + staticRandom() * 0.014);
28197
- const eyeRadiusY = eyeRadiusX * (1.18 + staticRandom() * 0.18);
28477
+ const morphologyProfile = createOctopus3MorphologyProfile(createRandom);
28478
+ const animationRandom = createRandom('octopus3-animation-profile');
28479
+ const eyeRandom = createRandom('octopus3-eye-profile');
28480
+ const centerX = size * (0.5 + morphologyProfile.body.centerXJitterRatio) + interaction.bodyOffsetX * size * 0.05;
28481
+ const centerY = size * morphologyProfile.body.centerYRatio + interaction.bodyOffsetY * size * 0.035;
28482
+ const bodyRadius = size * morphologyProfile.body.bodyRadiusRatio;
28483
+ const horizontalStretch = morphologyProfile.body.horizontalStretch;
28484
+ const verticalStretch = morphologyProfile.body.verticalStretch;
28485
+ const mantleLift = size * morphologyProfile.body.mantleLiftRatio;
28486
+ const lowerDrop = size * morphologyProfile.body.lowerDropRatio;
28487
+ const tentacleDepth = size * morphologyProfile.body.tentacleDepthRatio;
28488
+ const wobbleAmplitude = size * morphologyProfile.body.wobbleAmplitudeRatio;
28489
+ const lobeCount = morphologyProfile.body.lobeCount;
28490
+ const shapePhase = animationRandom() * Math.PI * 2;
28491
+ const eyeSpacing = size * morphologyProfile.face.eyeSpacingRatio;
28492
+ const eyeCenterY = centerY + size * morphologyProfile.face.eyeCenterYOffsetRatio;
28493
+ const eyeRadiusX = size * morphologyProfile.face.eyeRadiusXRatio;
28494
+ const eyeRadiusY = eyeRadiusX * morphologyProfile.face.eyeHeightRatio;
28198
28495
  const bodyPoints = createOrganicOctopusBodyPoints({
28199
28496
  centerX,
28200
28497
  centerY,
@@ -28208,7 +28505,7 @@
28208
28505
  lobeCount,
28209
28506
  shapePhase,
28210
28507
  timeMs,
28211
- pointCount: 40,
28508
+ pointCount: morphologyProfile.body.pointCount,
28212
28509
  });
28213
28510
  const tentacleShapes = createOrganicOctopusTentacleShapes({
28214
28511
  size,
@@ -28216,17 +28513,27 @@
28216
28513
  centerY,
28217
28514
  bodyRadius,
28218
28515
  horizontalStretch,
28219
- tentacleCount,
28516
+ tentacleCount: morphologyProfile.tentacles.count,
28220
28517
  shapePhase,
28221
28518
  createRandom,
28222
28519
  timeMs,
28223
28520
  saltPrefix: 'octopus3',
28224
28521
  bodyPoints,
28522
+ variation: {
28523
+ flowLengthScale: morphologyProfile.tentacles.flowLengthScale,
28524
+ lateralReachScale: morphologyProfile.tentacles.lateralReachScale,
28525
+ tipReachScale: morphologyProfile.tentacles.tipReachScale,
28526
+ baseWidthScale: morphologyProfile.tentacles.baseWidthScale,
28527
+ tipWidthScale: morphologyProfile.tentacles.tipWidthScale,
28528
+ rootSpreadScale: morphologyProfile.tentacles.rootSpreadScale,
28529
+ startYOffsetScale: morphologyProfile.tentacles.startYOffsetScale,
28530
+ swayScale: morphologyProfile.tentacles.swayScale,
28531
+ },
28225
28532
  });
28226
28533
  drawAvatarFrame(context, size, palette);
28227
- drawOctopus3Atmosphere(context, size, palette, centerX, centerY, timeMs, shapePhase);
28534
+ drawOctopus3Atmosphere(context, size, palette, centerX, centerY, timeMs, shapePhase, morphologyProfile);
28228
28535
  context.beginPath();
28229
- context.ellipse(centerX, centerY + size * 0.25, size * 0.24, size * 0.08, 0, 0, Math.PI * 2);
28536
+ context.ellipse(centerX, centerY + size * 0.25, size * morphologyProfile.body.shadowWidthRatio, size * morphologyProfile.body.shadowHeightRatio, 0, 0, Math.PI * 2);
28230
28537
  context.fillStyle = `${palette.shadow}33`;
28231
28538
  context.fill();
28232
28539
  for (const tentacleShape of tentacleShapes) {
@@ -28254,8 +28561,8 @@
28254
28561
  innerGlowGradient.addColorStop(1, `${palette.shadow}00`);
28255
28562
  context.fillStyle = innerGlowGradient;
28256
28563
  context.fillRect(centerX - size * 0.36, centerY - size * 0.34, size * 0.72, size * 0.72);
28257
- drawMantleCurrents(context, centerX, centerY, size, palette, timeMs, shapePhase);
28258
- drawMantleNodes(context, centerX, centerY, size, palette, createRandom);
28564
+ drawMantleCurrents(context, centerX, centerY, size, palette, timeMs, shapePhase, morphologyProfile);
28565
+ drawMantleNodes(context, centerX, centerY, size, palette, createRandom, morphologyProfile);
28259
28566
  context.restore();
28260
28567
  context.save();
28261
28568
  traceSmoothClosedPath(context, bodyPoints);
@@ -28264,14 +28571,19 @@
28264
28571
  context.stroke();
28265
28572
  context.restore();
28266
28573
  context.beginPath();
28267
- context.ellipse(centerX, centerY - size * 0.14, size * 0.18, size * 0.062, 0, Math.PI, Math.PI * 2);
28574
+ context.ellipse(centerX, centerY + size * morphologyProfile.body.crownHighlightYOffsetRatio, size * morphologyProfile.body.crownHighlightWidthRatio, size * morphologyProfile.body.crownHighlightHeightRatio, 0, Math.PI, Math.PI * 2);
28268
28575
  context.fillStyle = `${palette.highlight}3d`;
28269
28576
  context.fill();
28270
- drawSeededEye(context, centerX - eyeSpacing, centerY - size * 0.01, eyeRadiusX, eyeRadiusY, (staticRandom() - 0.5) * 0.28, palette, timeMs, shapePhase, interaction);
28271
- drawSeededEye(context, centerX + eyeSpacing, centerY - size * 0.01, eyeRadiusX, eyeRadiusY, (staticRandom() - 0.5) * 0.28, palette, timeMs, shapePhase + Math.PI / 4, interaction);
28577
+ drawSeededEye(context, centerX - eyeSpacing, eyeCenterY, eyeRadiusX, eyeRadiusY, -morphologyProfile.face.eyeTiltBias + (eyeRandom() - 0.5) * morphologyProfile.face.eyeRotationRange, palette, timeMs, shapePhase, interaction, morphologyProfile.face.eyeStyle);
28578
+ drawSeededEye(context, centerX + eyeSpacing, eyeCenterY, eyeRadiusX, eyeRadiusY, morphologyProfile.face.eyeTiltBias + (eyeRandom() - 0.5) * morphologyProfile.face.eyeRotationRange, palette, timeMs, shapePhase + Math.PI / 4, interaction, morphologyProfile.face.eyeStyle);
28579
+ const mouthHalfWidth = size * morphologyProfile.face.mouthWidthRatio;
28580
+ const mouthY = centerY + size * morphologyProfile.face.mouthYOffsetRatio;
28581
+ const mouthCornerTilt = size * morphologyProfile.face.mouthCornerTiltRatio;
28272
28582
  context.beginPath();
28273
- context.moveTo(centerX - size * 0.07, centerY + size * 0.09);
28274
- context.quadraticCurveTo(centerX, centerY + size * (0.14 + Math.sin(timeMs / 620 + shapePhase) * 0.016) + interaction.gazeY * size * 0.012, centerX + size * 0.07, centerY + size * 0.09);
28583
+ context.moveTo(centerX - mouthHalfWidth, mouthY - mouthCornerTilt);
28584
+ context.quadraticCurveTo(centerX + size * morphologyProfile.face.mouthCenterOffsetRatio, centerY +
28585
+ size * (morphologyProfile.face.mouthCurveDepthRatio + Math.sin(timeMs / 620 + shapePhase) * 0.016) +
28586
+ interaction.gazeY * size * 0.012, centerX + mouthHalfWidth, mouthY + mouthCornerTilt);
28275
28587
  context.strokeStyle = `${palette.ink}b3`;
28276
28588
  context.lineWidth = size * 0.012;
28277
28589
  context.lineCap = 'round';
@@ -28288,17 +28600,18 @@
28288
28600
  * @param centerY Body center Y coordinate.
28289
28601
  * @param timeMs Current animation time in milliseconds.
28290
28602
  * @param shapePhase Seed-based phase offset.
28603
+ * @param morphologyProfile Seeded morphology profile.
28291
28604
  *
28292
28605
  * @private helper of `octopus3AvatarVisual`
28293
28606
  */
28294
- function drawOctopus3Atmosphere(context, size, palette, centerX, centerY, timeMs, shapePhase) {
28295
- const haloGradient = context.createRadialGradient(centerX, centerY - size * 0.08, size * 0.06, centerX, centerY, size * 0.62);
28607
+ function drawOctopus3Atmosphere(context, size, palette, centerX, centerY, timeMs, shapePhase, morphologyProfile) {
28608
+ const haloGradient = context.createRadialGradient(centerX, centerY - size * (0.07 + (morphologyProfile.body.verticalStretch - 0.9) * 0.05), size * 0.06, centerX, centerY, size * (0.56 + morphologyProfile.body.bodyRadiusRatio * 0.45));
28296
28609
  haloGradient.addColorStop(0, `${palette.highlight}5c`);
28297
28610
  haloGradient.addColorStop(0.35, `${palette.accent}26`);
28298
28611
  haloGradient.addColorStop(1, `${palette.highlight}00`);
28299
28612
  context.fillStyle = haloGradient;
28300
28613
  context.fillRect(0, 0, size, size);
28301
- const lowerGlowGradient = context.createRadialGradient(centerX + Math.sin(timeMs / 1600 + shapePhase) * size * 0.04, centerY + size * 0.2, size * 0.04, centerX, centerY + size * 0.2, size * 0.48);
28614
+ const lowerGlowGradient = context.createRadialGradient(centerX + Math.sin(timeMs / 1600 + shapePhase) * size * 0.04, centerY + size * (0.18 + morphologyProfile.tentacles.flowLengthScale * 0.025), size * 0.04, centerX, centerY + size * (0.18 + morphologyProfile.tentacles.flowLengthScale * 0.025), size * (0.42 + morphologyProfile.tentacles.lateralReachScale * 0.06));
28302
28615
  lowerGlowGradient.addColorStop(0, `${palette.secondary}1f`);
28303
28616
  lowerGlowGradient.addColorStop(1, `${palette.secondary}00`);
28304
28617
  context.fillStyle = lowerGlowGradient;
@@ -28407,18 +28720,22 @@
28407
28720
  * @param palette Derived avatar palette.
28408
28721
  * @param timeMs Current animation time in milliseconds.
28409
28722
  * @param shapePhase Seed-based phase offset.
28723
+ * @param morphologyProfile Seeded morphology profile.
28410
28724
  *
28411
28725
  * @private helper of `octopus3AvatarVisual`
28412
28726
  */
28413
- function drawMantleCurrents(context, centerX, centerY, size, palette, timeMs, shapePhase) {
28414
- for (let currentIndex = 0; currentIndex < 6; currentIndex++) {
28415
- const horizontalOffset = (currentIndex - 2.5) * size * 0.06;
28727
+ function drawMantleCurrents(context, centerX, centerY, size, palette, timeMs, shapePhase, morphologyProfile) {
28728
+ const centeredCurrentIndex = (morphologyProfile.details.mantleCurrentCount - 1) / 2;
28729
+ for (let currentIndex = 0; currentIndex < morphologyProfile.details.mantleCurrentCount; currentIndex++) {
28730
+ const horizontalOffset = (currentIndex - centeredCurrentIndex) *
28731
+ size *
28732
+ (0.05 + (morphologyProfile.body.horizontalStretch - 0.9) * 0.025);
28416
28733
  const sway = Math.sin(timeMs / 680 + currentIndex * 0.78 + shapePhase) * size * 0.024;
28417
28734
  context.beginPath();
28418
- context.moveTo(centerX + horizontalOffset * 0.3, centerY - size * 0.13);
28419
- context.bezierCurveTo(centerX + horizontalOffset - sway * 0.25, centerY - size * 0.04, centerX + horizontalOffset + sway, centerY + size * 0.06, centerX + horizontalOffset * 0.7 + sway * 0.46, centerY + size * 0.2);
28735
+ context.moveTo(centerX + horizontalOffset * 0.3, centerY - size * (0.11 + morphologyProfile.body.verticalStretch * 0.02));
28736
+ context.bezierCurveTo(centerX + horizontalOffset - sway * 0.25, centerY - size * 0.04, centerX + horizontalOffset + sway, centerY + size * 0.06, centerX + horizontalOffset * 0.7 + sway * 0.46, centerY + size * (0.16 + morphologyProfile.body.verticalStretch * 0.035));
28420
28737
  context.strokeStyle = currentIndex % 2 === 0 ? `${palette.highlight}30` : `${palette.accent}26`;
28421
- context.lineWidth = size * (0.008 + currentIndex * 0.0007);
28738
+ context.lineWidth = size * (0.0075 + currentIndex * 0.00065 + morphologyProfile.tentacles.baseWidthScale * 0.0005);
28422
28739
  context.lineCap = 'round';
28423
28740
  context.stroke();
28424
28741
  }
@@ -28432,14 +28749,17 @@
28432
28749
  * @param size Canvas size in CSS pixels.
28433
28750
  * @param palette Derived avatar palette.
28434
28751
  * @param createRandom Seeded random factory scoped to the avatar.
28752
+ * @param morphologyProfile Seeded morphology profile.
28435
28753
  *
28436
28754
  * @private helper of `octopus3AvatarVisual`
28437
28755
  */
28438
- function drawMantleNodes(context, centerX, centerY, size, palette, createRandom) {
28439
- for (let nodeIndex = 0; nodeIndex < 5; nodeIndex++) {
28756
+ function drawMantleNodes(context, centerX, centerY, size, palette, createRandom, morphologyProfile) {
28757
+ for (let nodeIndex = 0; nodeIndex < morphologyProfile.details.mantleNodeCount; nodeIndex++) {
28440
28758
  const nodeRandom = createRandom(`octopus3-node-${nodeIndex}`);
28441
- const nodeX = centerX + (nodeRandom() - 0.5) * size * 0.28;
28442
- const nodeY = centerY - size * 0.03 + (nodeRandom() - 0.5) * size * 0.2;
28759
+ const nodeX = centerX + (nodeRandom() - 0.5) * size * (0.2 + (morphologyProfile.body.horizontalStretch - 0.9) * 0.16);
28760
+ const nodeY = centerY -
28761
+ size * 0.03 +
28762
+ (nodeRandom() - 0.5) * size * (0.16 + (morphologyProfile.body.verticalStretch - 0.82) * 0.1);
28443
28763
  const nodeRadius = size * (0.016 + nodeRandom() * 0.016);
28444
28764
  context.beginPath();
28445
28765
  context.arc(nodeX, nodeY, nodeRadius, 0, Math.PI * 2);
@@ -28460,10 +28780,11 @@
28460
28780
  * @param timeMs Current animation time in milliseconds.
28461
28781
  * @param phase Seed-based animation phase.
28462
28782
  * @param interaction Smoothed avatar interaction state.
28783
+ * @param eyeStyle Seeded eye-style traits.
28463
28784
  *
28464
28785
  * @private helper of `octopus3AvatarVisual`
28465
28786
  */
28466
- function drawSeededEye(context, centerX, centerY, radiusX, radiusY, rotation, palette, timeMs, phase, interaction) {
28787
+ function drawSeededEye(context, centerX, centerY, radiusX, radiusY, rotation, palette, timeMs, phase, interaction, eyeStyle) {
28467
28788
  const { pupilOffsetX, pupilOffsetY } = resolveOrganicEyeMotion({
28468
28789
  radiusX,
28469
28790
  radiusY,
@@ -28484,11 +28805,11 @@
28484
28805
  irisGradient.addColorStop(0.58, palette.secondary);
28485
28806
  irisGradient.addColorStop(1, palette.shadow);
28486
28807
  context.beginPath();
28487
- context.ellipse(pupilOffsetX, pupilOffsetY, radiusX * 0.66, radiusY * 0.74, 0, 0, Math.PI * 2);
28808
+ context.ellipse(pupilOffsetX, pupilOffsetY, radiusX * 0.66 * eyeStyle.irisScale, radiusY * 0.74 * eyeStyle.irisScale, 0, 0, Math.PI * 2);
28488
28809
  context.fillStyle = irisGradient;
28489
28810
  context.fill();
28490
28811
  context.beginPath();
28491
- context.ellipse(pupilOffsetX, pupilOffsetY, radiusX * 0.14, radiusY * 0.5, 0, 0, Math.PI * 2);
28812
+ context.ellipse(pupilOffsetX, pupilOffsetY, radiusX * 0.14 * eyeStyle.pupilWidthScale, radiusY * 0.5 * eyeStyle.pupilHeightScale, 0, 0, Math.PI * 2);
28492
28813
  context.fillStyle = palette.ink;
28493
28814
  context.fill();
28494
28815
  context.beginPath();
@@ -28505,12 +28826,21 @@
28505
28826
  context.lineWidth = radiusX * 0.18;
28506
28827
  context.stroke();
28507
28828
  context.beginPath();
28508
- context.moveTo(-radiusX * 0.88, -radiusY * 0.08);
28509
- context.quadraticCurveTo(0, -radiusY * (0.9 - interaction.gazeY * 0.16 + interaction.intensity * 0.08), radiusX * 0.88, -radiusY * 0.08);
28829
+ context.moveTo(-radiusX * 0.88, -radiusY * eyeStyle.upperLidInsetRatio);
28830
+ context.quadraticCurveTo(0, -radiusY * (eyeStyle.upperLidArchRatio - interaction.gazeY * 0.16 + interaction.intensity * 0.08), radiusX * 0.88, -radiusY * eyeStyle.upperLidInsetRatio);
28510
28831
  context.strokeStyle = `${palette.shadow}73`;
28511
28832
  context.lineWidth = radiusX * 0.16;
28512
28833
  context.lineCap = 'round';
28513
28834
  context.stroke();
28835
+ if (eyeStyle.lowerLidOpacity > 0) {
28836
+ context.beginPath();
28837
+ context.moveTo(-radiusX * 0.74, radiusY * 0.2);
28838
+ context.quadraticCurveTo(0, radiusY * 0.38, radiusX * 0.74, radiusY * 0.2);
28839
+ context.strokeStyle = `${palette.highlight}${formatAlphaHex(eyeStyle.lowerLidOpacity)}`;
28840
+ context.lineWidth = radiusX * 0.08;
28841
+ context.lineCap = 'round';
28842
+ context.stroke();
28843
+ }
28514
28844
  context.restore();
28515
28845
  }
28516
28846
 
@@ -30237,7 +30567,7 @@
30237
30567
  * @private internal component of `<ChatMessageItem/>`
30238
30568
  */
30239
30569
  function ChatMessageRichContent(props) {
30240
- const { content, contentSegments, streamingFeaturePlaceholderKind, onCreateAgent } = props;
30570
+ const { content, contentSegments, streamingFeaturePlaceholderKind, onCreateAgent, mode } = props;
30241
30571
  if (content === LOADING_INTERACTIVE_IMAGE) {
30242
30572
  return null;
30243
30573
  }
@@ -30246,7 +30576,7 @@
30246
30576
  return (jsxRuntime.jsx(MarkdownContent, { content: segment.content, onCreateAgent: onCreateAgent }, `text-${segmentIndex}`));
30247
30577
  }
30248
30578
  if (segment.type === 'code') {
30249
- return (jsxRuntime.jsx(CodeBlock, { code: segment.code, language: segment.language, onCreateAgent: onCreateAgent }, `code-${segmentIndex}`));
30579
+ return (jsxRuntime.jsx(CodeBlock, { code: segment.code, language: segment.language, onCreateAgent: onCreateAgent, theme: mode }, `code-${segmentIndex}`));
30250
30580
  }
30251
30581
  if (segment.type === 'image') {
30252
30582
  return (jsxRuntime.jsx(ImagePromptRenderer, { alt: segment.alt, prompt: segment.prompt }, `image-${segmentIndex}`));
@@ -47079,6 +47409,8 @@
47079
47409
  const swipeDirectionMultiplier = isMe ? -1 : 1;
47080
47410
  const swipeTranslation = `${isMe ? -replySwipeDistance : replySwipeDistance}px`;
47081
47411
  const isReplySwipeArmed = replySwipeDistance >= REPLY_SWIPE_TRIGGER_PX * 0.5;
47412
+ const articleModeBackgroundColor = mode === 'DARK' ? 'rgba(15, 23, 42, 0.78)' : '#ffffff';
47413
+ const articleModeTextColor = mode === 'DARK' ? '#e2e8f0' : '#0f172a';
47082
47414
  /**
47083
47415
  * Renders the optional message utility buttons used for copy/read actions.
47084
47416
  *
@@ -47280,10 +47612,12 @@
47280
47612
  aspectRatio: '1 / 1',
47281
47613
  borderRadius: '50%',
47282
47614
  } })), isAvatarTooltipVisible && (participant === null || participant === void 0 ? void 0 : participant.agentSource) && avatarTooltipPosition && (jsxRuntime.jsx(AvatarProfileTooltip, { ref: tooltipRef, agentSource: participant.agentSource, position: avatarTooltipPosition }))] })), jsxRuntime.jsxs("div", { className: classNames(styles$5.messageStack, chatCssClassNames.messageStack), children: [shouldShowParticipantLabel && participantLabel && (jsxRuntime.jsx("div", { className: styles$5.participantLabel, children: participantLabel })), jsxRuntime.jsxs("div", { className: classNames(styles$5.messageText, isReplyActionEnabled && styles$5.replyEnabledMessageText, isReplySwipeArmed && styles$5.replySwipeActive, isAgentArticleMode && styles$5.articleModeAgentMessageText, chatCssClassNames.messageContent), style: {
47283
- '--message-bg-color': isAgentArticleMode ? '#ffffff' : color.toHex(),
47284
- '--message-text-color': isAgentArticleMode ? '#0f172a' : colorOfText.toHex(),
47615
+ '--message-bg-color': isAgentArticleMode ? articleModeBackgroundColor : color.toHex(),
47616
+ '--message-text-color': isAgentArticleMode
47617
+ ? articleModeTextColor
47618
+ : colorOfText.toHex(),
47285
47619
  '--chat-message-swipe-offset': swipeTranslation,
47286
- }, onPointerDown: handleReplyPointerDown, onPointerMove: handleReplyPointerMove, onPointerUp: handleReplyPointerEnd, onPointerCancel: resetReplySwipe, children: [isReplyActionEnabled && (jsxRuntime.jsx("div", { className: classNames(styles$5.replySwipeIndicator, isMe && styles$5.replySwipeIndicatorRight, isReplySwipeArmed && styles$5.replySwipeIndicatorActive), "aria-hidden": "true", children: jsxRuntime.jsx(lucideReact.Reply, { className: styles$5.replySwipeIndicatorIcon }) })), !shouldRenderArticleActionsBar && renderMessageReadAndCopyControls(), message.isVoiceCall && (jsxRuntime.jsx("div", { className: styles$5.voiceCallIndicator, children: jsxRuntime.jsx("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "currentColor", children: jsxRuntime.jsx("path", { d: "M6.62 10.79c1.44 2.83 3.76 5.14 6.59 6.59l2.2-2.2c.27-.27.67-.36 1.02-.24 1.12.37 2.33.57 3.57.57.55 0 1 .45 1 1V20c0 .55-.45 1-1 1-9.39 0-17-7.61-17-17 0-.55.45-1 1-1h3.5c.55 0 1 .45 1 1 0 1.25.2 2.45.57 3.57.11.35.03.74-.25 1.02l-2.2 2.2z" }) }) })), replyingToMessage && replyPreviewText && replySenderLabel && (jsxRuntime.jsx(ChatReplyPreview, { label: replyPreviewLabel, senderLabel: replySenderLabel, previewText: replyPreviewText, className: styles$5.replyBubblePreview })), jsxRuntime.jsx("div", { ref: contentWithoutButtonsRef, children: jsxRuntime.jsx(ChatMessageRichContent, { content: message.content, contentSegments: contentSegments, streamingFeaturePlaceholderKind: streamingFeaturePlaceholderKind, onCreateAgent: onCreateAgent }) }), message.attachments && message.attachments.length > 0 && (jsxRuntime.jsx("div", { className: styles$5.attachments, children: message.attachments.map((attachment, index) => (jsxRuntime.jsxs("a", { href: attachment.url, target: "_blank", rel: "noopener noreferrer", className: styles$5.attachment, title: attachment.name, children: [jsxRuntime.jsx("span", { className: styles$5.attachmentIcon, children: "\uD83D\uDCCE" }), jsxRuntime.jsx("span", { className: styles$5.attachmentName, children: attachment.name })] }, index))) })), jsxRuntime.jsx(ChatMessageToolCallChips, { chips: toolCallChips, onToolCallClick: onToolCallClick }), citationFootnoteRenderModel.footnotes.length > 0 && (jsxRuntime.jsx("div", { className: styles$5.citationFootnotes, children: citationFootnoteRenderModel.footnotes.map((footnote) => (jsxRuntime.jsxs("div", { className: styles$5.citationFootnoteItem, children: [jsxRuntime.jsx("span", { className: styles$5.citationFootnoteNumber, children: footnote.number }), jsxRuntime.jsx(SourceChip, { citation: footnote.citation, onClick: onCitationClick, isCitationIdVisible: false })] }, `citation-footnote-${footnote.number}-${footnote.citation.source}`))) })), transitiveCitations.length > 0 && (jsxRuntime.jsx("div", { className: styles$5.sourceCitations, children: transitiveCitations.map((citation, index) => (jsxRuntime.jsx(SourceChip, { citation: citation, suffix: `by ${citation.origin.label}`, onClick: onCitationClick }, `team-source-${citation.source}-${index}`))) })), shouldShowButtons && (jsxRuntime.jsx("div", { className: styles$5.messageButtons, children: renderableButtons.map(({ button, buttonIndex }) => (jsxRuntime.jsx("button", { type: "button", className: classNames(styles$5.messageButton, button.type === 'action' && styles$5.actionMessageButton), onClick: (event) => {
47620
+ }, onPointerDown: handleReplyPointerDown, onPointerMove: handleReplyPointerMove, onPointerUp: handleReplyPointerEnd, onPointerCancel: resetReplySwipe, children: [isReplyActionEnabled && (jsxRuntime.jsx("div", { className: classNames(styles$5.replySwipeIndicator, isMe && styles$5.replySwipeIndicatorRight, isReplySwipeArmed && styles$5.replySwipeIndicatorActive), "aria-hidden": "true", children: jsxRuntime.jsx(lucideReact.Reply, { className: styles$5.replySwipeIndicatorIcon }) })), !shouldRenderArticleActionsBar && renderMessageReadAndCopyControls(), message.isVoiceCall && (jsxRuntime.jsx("div", { className: styles$5.voiceCallIndicator, children: jsxRuntime.jsx("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "currentColor", children: jsxRuntime.jsx("path", { d: "M6.62 10.79c1.44 2.83 3.76 5.14 6.59 6.59l2.2-2.2c.27-.27.67-.36 1.02-.24 1.12.37 2.33.57 3.57.57.55 0 1 .45 1 1V20c0 .55-.45 1-1 1-9.39 0-17-7.61-17-17 0-.55.45-1 1-1h3.5c.55 0 1 .45 1 1 0 1.25.2 2.45.57 3.57.11.35.03.74-.25 1.02l-2.2 2.2z" }) }) })), replyingToMessage && replyPreviewText && replySenderLabel && (jsxRuntime.jsx(ChatReplyPreview, { label: replyPreviewLabel, senderLabel: replySenderLabel, previewText: replyPreviewText, className: styles$5.replyBubblePreview })), jsxRuntime.jsx("div", { ref: contentWithoutButtonsRef, children: jsxRuntime.jsx(ChatMessageRichContent, { content: message.content, contentSegments: contentSegments, streamingFeaturePlaceholderKind: streamingFeaturePlaceholderKind, onCreateAgent: onCreateAgent, mode: mode }) }), message.attachments && message.attachments.length > 0 && (jsxRuntime.jsx("div", { className: styles$5.attachments, children: message.attachments.map((attachment, index) => (jsxRuntime.jsxs("a", { href: attachment.url, target: "_blank", rel: "noopener noreferrer", className: styles$5.attachment, title: attachment.name, children: [jsxRuntime.jsx("span", { className: styles$5.attachmentIcon, children: "\uD83D\uDCCE" }), jsxRuntime.jsx("span", { className: styles$5.attachmentName, children: attachment.name })] }, index))) })), jsxRuntime.jsx(ChatMessageToolCallChips, { chips: toolCallChips, onToolCallClick: onToolCallClick }), citationFootnoteRenderModel.footnotes.length > 0 && (jsxRuntime.jsx("div", { className: styles$5.citationFootnotes, children: citationFootnoteRenderModel.footnotes.map((footnote) => (jsxRuntime.jsxs("div", { className: styles$5.citationFootnoteItem, children: [jsxRuntime.jsx("span", { className: styles$5.citationFootnoteNumber, children: footnote.number }), jsxRuntime.jsx(SourceChip, { citation: footnote.citation, onClick: onCitationClick, isCitationIdVisible: false })] }, `citation-footnote-${footnote.number}-${footnote.citation.source}`))) })), transitiveCitations.length > 0 && (jsxRuntime.jsx("div", { className: styles$5.sourceCitations, children: transitiveCitations.map((citation, index) => (jsxRuntime.jsx(SourceChip, { citation: citation, suffix: `by ${citation.origin.label}`, onClick: onCitationClick }, `team-source-${citation.source}-${index}`))) })), shouldShowButtons && (jsxRuntime.jsx("div", { className: styles$5.messageButtons, children: renderableButtons.map(({ button, buttonIndex }) => (jsxRuntime.jsx("button", { type: "button", className: classNames(styles$5.messageButton, button.type === 'action' && styles$5.actionMessageButton), onClick: (event) => {
47287
47621
  event.stopPropagation();
47288
47622
  if (button.type === 'message') {
47289
47623
  const quickMessageHandler = onQuickMessageButton || onMessage;
@@ -47477,7 +47811,7 @@
47477
47811
  }
47478
47812
  return '';
47479
47813
  })();
47480
- return (jsxRuntime.jsx("div", { className: styles$5.ratingModal, onClick: (event) => {
47814
+ return (jsxRuntime.jsx("div", { className: styles$5.ratingModal, "data-chat-modal": "rating", "data-chat-theme": mode.toLowerCase(), onClick: (event) => {
47481
47815
  if (event.target === event.currentTarget && isMobile) {
47482
47816
  onClose();
47483
47817
  }
@@ -47581,12 +47915,14 @@
47581
47915
  */
47582
47916
  function renderAdvancedToolCallDetails(options) {
47583
47917
  const { toolCall } = options;
47918
+ const mode = options.mode || 'LIGHT';
47584
47919
  const header = resolveAdvancedToolCallHeader(options);
47585
47920
  const payloadSections = createAdvancedToolCallPayloadSections(toolCall, options.availableTools);
47586
47921
  return (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsxs("header", { className: styles$5.toolCallHeader, children: [jsxRuntime.jsx("span", { className: styles$5.toolCallIcon, "aria-hidden": "true", children: header.emoji }), jsxRuntime.jsxs("div", { className: styles$5.toolCallHeaderMeta, children: [jsxRuntime.jsx("p", { className: styles$5.toolCallModalLabel, children: "Advanced" }), jsxRuntime.jsx("h3", { className: styles$5.toolCallTitle, children: header.title }), jsxRuntime.jsxs("p", { className: styles$5.toolCallSubtitle, children: [header.subtitle, " \u00B7 ", resolveToolCallState(toolCall).toLowerCase()] })] })] }), jsxRuntime.jsx("div", { className: styles$5.toolCallGrid, children: payloadSections.map((payloadSection) => (jsxRuntime.jsxs("section", { className: styles$5.toolCallPanel, children: [jsxRuntime.jsx("p", { className: styles$5.toolCallPanelTitle, children: payloadSection.title }), renderAdvancedToolCallPayload({
47587
47922
  toolCall,
47588
47923
  sectionId: payloadSection.id,
47589
47924
  payload: payloadSection.payload,
47925
+ mode,
47590
47926
  })] }, payloadSection.id))) })] }));
47591
47927
  }
47592
47928
  /**
@@ -47720,7 +48056,7 @@
47720
48056
  * @private function of ChatToolCallModal
47721
48057
  */
47722
48058
  function renderAdvancedToolCallPayload(options) {
47723
- const { toolCall, sectionId, payload } = options;
48059
+ const { toolCall, sectionId, payload, mode } = options;
47724
48060
  const formattedPayload = formatToolCallPayload(payload);
47725
48061
  const modelPath = createToolCallPayloadMonacoPath({
47726
48062
  toolCall,
@@ -47728,7 +48064,7 @@
47728
48064
  language: formattedPayload.language,
47729
48065
  });
47730
48066
  const editorHeight = resolveToolCallPayloadEditorHeight(formattedPayload.content);
47731
- return (jsxRuntime.jsx("div", { className: styles$5.toolCallPayloadContainer, children: jsxRuntime.jsx("div", { className: styles$5.toolCallPayloadEditor, children: jsxRuntime.jsx(MonacoEditorWithShadowDom, { height: `${editorHeight}px`, language: formattedPayload.language, path: modelPath, value: formattedPayload.content, theme: "vs-light", options: TOOL_CALL_PAYLOAD_EDITOR_OPTIONS }) }) }));
48067
+ return (jsxRuntime.jsx("div", { className: styles$5.toolCallPayloadContainer, children: jsxRuntime.jsx("div", { className: styles$5.toolCallPayloadEditor, children: jsxRuntime.jsx(MonacoEditorWithShadowDom, { height: `${editorHeight}px`, language: formattedPayload.language, path: modelPath, value: formattedPayload.content, theme: mode === 'DARK' ? 'vs-dark' : 'vs-light', options: TOOL_CALL_PAYLOAD_EDITOR_OPTIONS }) }) }));
47732
48068
  }
47733
48069
  /**
47734
48070
  * Resolves Monaco editor height from payload line count with bounded limits.
@@ -49860,12 +50196,13 @@
49860
50196
  *
49861
50197
  * @private component of `ChatToolCallModal`
49862
50198
  */
49863
- function ChatToolCallModalContent({ agentParticipant, availableTools, buttonColor, chatUiTranslations, focusedToolCall, isAdvancedView, locale, onClearSelectedTeamToolCall, onRequestAdvancedView, onSelectTeamToolCall, selectedTeamToolCall, teamProfiles, teamResult, teamToolCallSummary, toolCall, toolCallDate, toolTitles, }) {
50199
+ function ChatToolCallModalContent({ agentParticipant, availableTools, buttonColor, chatUiTranslations, focusedToolCall, isAdvancedView, locale, mode, onClearSelectedTeamToolCall, onRequestAdvancedView, onSelectTeamToolCall, selectedTeamToolCall, teamProfiles, teamResult, teamToolCallSummary, toolCall, toolCallDate, toolTitles, }) {
49864
50200
  if (isAdvancedView) {
49865
50201
  return renderAdvancedToolCallDetails({
49866
50202
  toolCall: focusedToolCall,
49867
50203
  toolTitles,
49868
50204
  availableTools,
50205
+ mode,
49869
50206
  });
49870
50207
  }
49871
50208
  if (teamResult === null || teamResult === void 0 ? void 0 : teamResult.teammate) {
@@ -50132,7 +50469,7 @@
50132
50469
  * @private component of `<Chat/>`
50133
50470
  */
50134
50471
  function ChatToolCallModal(props) {
50135
- const { isOpen, toolCall, toolCallIdentity, onClose, toolTitles, agentParticipant, buttonColor, teamAgentProfiles, chatUiTranslations, locale, availableTools, } = props;
50472
+ const { isOpen, toolCall, mode = 'LIGHT', toolCallIdentity, onClose, toolTitles, agentParticipant, buttonColor, teamAgentProfiles, chatUiTranslations, locale, availableTools, } = props;
50136
50473
  const { clearSelectedTeamToolCall, exportAdvancedToolCallReport, focusedToolCall, isAdvancedView, modalDialogRef, openAdvancedView, selectTeamToolCall, selectedTeamToolCall, teamProfiles, teamResult, teamToolCallSummary, toggleViewMode, toolCallDate, } = useChatToolCallModalState({
50137
50474
  isOpen,
50138
50475
  toolCall,
@@ -50152,9 +50489,9 @@
50152
50489
  const modeToggleLabel = isAdvancedView
50153
50490
  ? (chatUiTranslations === null || chatUiTranslations === void 0 ? void 0 : chatUiTranslations.toolCallModalSimpleLabel) || 'Simple'
50154
50491
  : (chatUiTranslations === null || chatUiTranslations === void 0 ? void 0 : chatUiTranslations.toolCallModalAdvancedLabel) || 'Advanced';
50155
- return (jsxRuntime.jsx("div", { className: styles$5.ratingModal, onClick: (event) => {
50492
+ return (jsxRuntime.jsx("div", { className: styles$5.ratingModal, "data-chat-modal": "tool-call", "data-chat-theme": mode.toLowerCase(), onClick: (event) => {
50156
50493
  handleModalBackdropClick(event, onClose);
50157
- }, children: jsxRuntime.jsxs("div", { ref: modalDialogRef, className: classNames(styles$5.ratingModalContent, styles$5.toolCallModal), role: "dialog", "aria-modal": "true", "aria-label": modalTitle, tabIndex: -1, children: [jsxRuntime.jsx("button", { type: "button", className: styles$5.modalCloseButton, onClick: onClose, "aria-label": closeButtonLabel, children: jsxRuntime.jsx(CloseIcon, {}) }), jsxRuntime.jsx(ChatToolCallModalContent, { toolCall: toolCall, focusedToolCall: resolvedFocusedToolCall, isAdvancedView: isAdvancedView, teamResult: teamResult, toolCallDate: toolCallDate, teamToolCallSummary: teamToolCallSummary, selectedTeamToolCall: selectedTeamToolCall, onSelectTeamToolCall: selectTeamToolCall, onClearSelectedTeamToolCall: clearSelectedTeamToolCall, teamProfiles: teamProfiles, toolTitles: toolTitles, agentParticipant: agentParticipant, buttonColor: buttonColor, locale: locale, chatUiTranslations: chatUiTranslations, availableTools: availableTools, onRequestAdvancedView: openAdvancedView }), jsxRuntime.jsxs("div", { className: styles$5.toolCallModeFooter, children: [isAdvancedView && (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx("button", { type: "button", className: styles$5.toolCallModeButton, onClick: () => {
50494
+ }, children: jsxRuntime.jsxs("div", { ref: modalDialogRef, className: classNames(styles$5.ratingModalContent, styles$5.toolCallModal), role: "dialog", "aria-modal": "true", "aria-label": modalTitle, tabIndex: -1, children: [jsxRuntime.jsx("button", { type: "button", className: styles$5.modalCloseButton, onClick: onClose, "aria-label": closeButtonLabel, children: jsxRuntime.jsx(CloseIcon, {}) }), jsxRuntime.jsx(ChatToolCallModalContent, { toolCall: toolCall, focusedToolCall: resolvedFocusedToolCall, isAdvancedView: isAdvancedView, teamResult: teamResult, toolCallDate: toolCallDate, teamToolCallSummary: teamToolCallSummary, selectedTeamToolCall: selectedTeamToolCall, onSelectTeamToolCall: selectTeamToolCall, onClearSelectedTeamToolCall: clearSelectedTeamToolCall, teamProfiles: teamProfiles, toolTitles: toolTitles, agentParticipant: agentParticipant, buttonColor: buttonColor, locale: locale, chatUiTranslations: chatUiTranslations, availableTools: availableTools, onRequestAdvancedView: openAdvancedView, mode: mode }), jsxRuntime.jsxs("div", { className: styles$5.toolCallModeFooter, children: [isAdvancedView && (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx("button", { type: "button", className: styles$5.toolCallModeButton, onClick: () => {
50158
50495
  void exportAdvancedToolCallReport('clipboard');
50159
50496
  }, children: copyButtonLabel }), jsxRuntime.jsx("button", { type: "button", className: styles$5.toolCallModeButton, onClick: () => {
50160
50497
  void exportAdvancedToolCallReport('file');
@@ -50780,7 +51117,7 @@
50780
51117
  * @public exported from `@promptbook/components`
50781
51118
  */
50782
51119
  function Chat(props) {
50783
- const { title = 'Chat', messages, onChange, onMessage, onActionButton, onQuickMessageButton, onReplyToMessage, onCancelReply, onReset, resetRequiresConfirmation = true, newChatButtonHref, onFeedback, feedbackMode = 'stars', feedbackTranslations, timingTranslations, onFileUpload, chatLocale, speechRecognition, placeholderMessageContent, defaultMessage, enterBehavior, resolveEnterBehavior, children, className, style, isAiTextHumanizedAndPromptbookified = true, isVoiceCalling = false, isFocusedOnLoad, participants = [], canReplyToMessage, replyingToMessage, extraActions, actionsContainer, saveFormats, isSaveButtonEnabled = true, isCopyButtonEnabled = true, buttonColor: buttonColorRaw, onUseTemplate, onCreateAgent, toolTitles, teammates, teamAgentProfiles, layout, visualMode = 'ARTICLE_MODE', effectConfigs, soundSystem, speechRecognitionLanguage, isSpeechPlaybackEnabled = true, elevenLabsVoiceId, chatUiTranslations, } = props;
51120
+ const { title = 'Chat', messages, onChange, onMessage, onActionButton, onQuickMessageButton, onReplyToMessage, onCancelReply, onReset, resetRequiresConfirmation = true, newChatButtonHref, onFeedback, feedbackMode = 'stars', feedbackTranslations, timingTranslations, onFileUpload, chatLocale, speechRecognition, placeholderMessageContent, defaultMessage, enterBehavior, resolveEnterBehavior, children, className, style, isAiTextHumanizedAndPromptbookified = true, isVoiceCalling = false, isFocusedOnLoad, participants = [], canReplyToMessage, replyingToMessage, extraActions, actionsContainer, saveFormats, isSaveButtonEnabled = true, isCopyButtonEnabled = true, buttonColor: buttonColorRaw, onUseTemplate, onCreateAgent, toolTitles, teammates, teamAgentProfiles, layout, visualMode = 'ARTICLE_MODE', theme = 'LIGHT', effectConfigs, soundSystem, speechRecognitionLanguage, isSpeechPlaybackEnabled = true, elevenLabsVoiceId, chatUiTranslations, } = props;
50784
51121
  const buttonColor = react.useMemo(() => Color.from(buttonColorRaw || '#0066cc'), [buttonColorRaw]);
50785
51122
  const agentParticipant = react.useMemo(() => participants.find((participant) => participant.name === 'AGENT'), [participants]);
50786
51123
  const postprocessedMessages = useChatPostprocessedMessages({
@@ -50800,7 +51137,7 @@
50800
51137
  const { citationModalOpen, closeCitationModal, closeToolCallModal, openCitation, openToolCall, selectedCitation, selectedMessageAvailableTools, selectedToolCall, selectedToolCallIdentity, toolCallModalOpen, } = useChatToolCallState({
50801
51138
  messages: postprocessedMessages,
50802
51139
  });
50803
- const mode = 'LIGHT';
51140
+ const mode = theme;
50804
51141
  const scrollToBottomCssClassName = getChatCssClassName('scrollToBottom');
50805
51142
  const handleButtonClick = react.useCallback((originalHandler) => {
50806
51143
  return (event) => {
@@ -50825,7 +51162,7 @@
50825
51162
  useChatCompleteNotification(messages, soundSystem);
50826
51163
  return (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [feedbackStatus && (jsxRuntime.jsx("div", { className: classNames(styles$5.feedbackStatus, feedbackStatus.variant === 'success'
50827
51164
  ? styles$5.feedbackStatusSuccess
50828
- : styles$5.feedbackStatusError), "aria-live": "polite", role: "status", children: feedbackStatus.message })), effectConfigs && effectConfigs.length > 0 && (jsxRuntime.jsx(ChatEffectsSystem, { messages: postprocessedMessages, effectConfigs: effectConfigs, soundSystem: soundSystem })), jsxRuntime.jsx("div", { className: classNames(className, styles$5.Chat, layout === 'STANDALONE' && styles$5.standaloneVisual, layout === 'FULL_PAGE' && styles$5.fullPageVisual, isConstrainedArticleMode && styles$5.constrainedArticleVisual, getChatCssClassName('Chat'), chatCssClassNames.chat), style, children: jsxRuntime.jsxs("div", { className: classNames(className, styles$5.chatMainFlow, getChatCssClassName('chatMainFlow'), chatCssClassNames.chatMainFlow), children: [children && jsxRuntime.jsx("div", { className: classNames(styles$5.chatChildren), children: children }), shouldShowScrollToBottom && (jsxRuntime.jsx("div", { className: styles$5.scrollToBottomContainer, children: jsxRuntime.jsxs("div", { className: styles$5.scrollToBottomWrapper, children: [jsxRuntime.jsx(SolidArrowButton, { "data-button-type": "custom", direction: "down", iconSize: 33, className: classNames(styles$5.scrollToBottom, scrollToBottomCssClassName), onClick: handleButtonClick(() => scrollToBottom()), "aria-label": ariaLabel, title: ariaLabel }), badgeLabel && (jsxRuntime.jsx("span", { className: styles$5.scrollToBottomBadge, "aria-live": "polite", role: "status", children: badgeLabel }))] }) })), isVoiceCalling && (jsxRuntime.jsx("div", { className: styles$5.voiceCallIndicatorBar, children: jsxRuntime.jsxs("div", { className: styles$5.voiceCallIndicator, children: [jsxRuntime.jsx("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "currentColor", children: jsxRuntime.jsx("path", { d: "M6.62 10.79c1.44 2.83 3.76 5.14 6.59 6.59l2.2-2.2c.27-.27.67-.36 1.02-.24 1.12.37 2.33.57 3.57.57.55 0 1 .45 1 1V20c0 .55-.45 1-1 1-9.39 0-17-7.61-17-17 0-.55.45-1 1-1h3.5c.55 0 1 .45 1 1 0 1.25.2 2.45.57 3.57.11.35.03.74-.25 1.02l-2.2 2.2z" }) }), jsxRuntime.jsx("span", { children: "Voice call active" }), jsxRuntime.jsx("div", { className: styles$5.voiceCallPulse })] }) })), jsxRuntime.jsx(ChatActionsBar, { actionsRef: actionsRef, actionsContainer: actionsContainer, messages: postprocessedMessages, participants: participants, title: title, onReset: onReset, resetRequiresConfirmation: resetRequiresConfirmation, newChatButtonHref: newChatButtonHref, onUseTemplate: onUseTemplate, extraActions: extraActions, saveFormats: saveFormats, isSaveButtonEnabled: isSaveButtonEnabled, shouldFadeActions: shouldFadeActions, shouldDisableActions: shouldDisableActions, chatUiTranslations: chatUiTranslations, onButtonClick: handleButtonClick }), jsxRuntime.jsx(ChatMessageList, { messages: postprocessedMessages, participants: participants, expandedMessageId: expandedMessageId, messageRatings: messageRatings, setExpandedMessageId: setExpandedMessageId, handleRating: handleRating, mode: mode, isCopyButtonEnabled: isCopyButtonEnabled, isFeedbackEnabled: isFeedbackEnabled, feedbackMode: feedbackMode, feedbackTranslations: feedbackTranslations, timingTranslations: timingTranslations, chatLocale: chatLocale, onCopy: handleCopy, onMessage: onMessage, onActionButton: onActionButton, onQuickMessageButton: onQuickMessageButton, onReplyToMessage: onReplyToMessage, canReplyToMessage: canReplyToMessage, onCreateAgent: onCreateAgent, toolTitles: toolTitles, teammates: teammates, teamAgentProfiles: teamAgentProfiles, visualMode: visualMode, soundSystem: soundSystem, onToolCallClick: openToolCall, onCitationClick: openCitation, setChatMessagesElement: setChatMessagesElement, onScroll: handleChatScroll, isSpeechPlaybackEnabled: isSpeechPlaybackEnabled, elevenLabsVoiceId: elevenLabsVoiceId, chatUiTranslations: chatUiTranslations, chatMessagesClassName: classNames(isConstrainedArticleMode && styles$5.articleModeChatMessages, getChatCssClassName('chatMessages'), chatCssClassNames.chatMessages), hasActions: hasActions }), onMessage && (jsxRuntime.jsx(ChatInputArea, { onMessage: onMessage, onChange: onChange, onFileUpload: onFileUpload, speechRecognition: speechRecognition, speechRecognitionLanguage: speechRecognitionLanguage, replyingToMessage: replyingToMessage, onCancelReply: onCancelReply, defaultMessage: defaultMessage, enterBehavior: enterBehavior, resolveEnterBehavior: resolveEnterBehavior, placeholderMessageContent: placeholderMessageContent || (chatUiTranslations === null || chatUiTranslations === void 0 ? void 0 : chatUiTranslations.inputPlaceholder), isFocusedOnLoad: isFocusedOnLoad, isMobile: isMobile, isVoiceCalling: isVoiceCalling, participants: participants, buttonColor: buttonColor, soundSystem: soundSystem, onButtonClick: handleButtonClick, chatUiTranslations: chatUiTranslations, chatInputClassName: classNames(isConstrainedArticleMode && styles$5.articleModeChatInput, getChatCssClassName('chatInput'), chatCssClassNames.chatInput) }))] }) }), jsxRuntime.jsx(ChatToolCallModal, { isOpen: toolCallModalOpen, toolCall: selectedToolCall, toolCallIdentity: selectedToolCallIdentity, onClose: closeToolCallModal, toolTitles: toolTitles, agentParticipant: agentParticipant, buttonColor: buttonColor, teamAgentProfiles: teamAgentProfiles, chatUiTranslations: chatUiTranslations, locale: chatLocale, availableTools: selectedMessageAvailableTools }), jsxRuntime.jsx(ChatCitationModal, { isOpen: citationModalOpen, citation: selectedCitation, participants: participants, soundSystem: soundSystem, onClose: closeCitationModal }), jsxRuntime.jsx(ChatRatingModal, { isOpen: ratingModalOpen, selectedMessage: selectedMessage, postprocessedMessages: postprocessedMessages, messages: messages, hoveredRating: hoveredRating, messageRatings: messageRatings, textRating: textRating, feedbackMode: feedbackMode, feedbackTranslations: feedbackTranslations, mode: mode, isMobile: isMobile, onClose: () => setRatingModalOpen(false), setHoveredRating: setHoveredRating, setMessageRatings: setMessageRatings, setSelectedMessage: setSelectedMessage, setTextRating: setTextRating, submitRating: submitRating })] }));
51165
+ : styles$5.feedbackStatusError), "aria-live": "polite", role: "status", children: feedbackStatus.message })), effectConfigs && effectConfigs.length > 0 && (jsxRuntime.jsx(ChatEffectsSystem, { messages: postprocessedMessages, effectConfigs: effectConfigs, soundSystem: soundSystem })), jsxRuntime.jsx("div", { className: classNames(className, styles$5.Chat, layout === 'STANDALONE' && styles$5.standaloneVisual, layout === 'FULL_PAGE' && styles$5.fullPageVisual, isConstrainedArticleMode && styles$5.constrainedArticleVisual, getChatCssClassName('Chat'), chatCssClassNames.chat), "data-chat-theme": mode.toLowerCase(), style, children: jsxRuntime.jsxs("div", { className: classNames(className, styles$5.chatMainFlow, getChatCssClassName('chatMainFlow'), chatCssClassNames.chatMainFlow), children: [children && jsxRuntime.jsx("div", { className: classNames(styles$5.chatChildren), children: children }), shouldShowScrollToBottom && (jsxRuntime.jsx("div", { className: styles$5.scrollToBottomContainer, children: jsxRuntime.jsxs("div", { className: styles$5.scrollToBottomWrapper, children: [jsxRuntime.jsx(SolidArrowButton, { "data-button-type": "custom", direction: "down", iconSize: 33, className: classNames(styles$5.scrollToBottom, scrollToBottomCssClassName), onClick: handleButtonClick(() => scrollToBottom()), "aria-label": ariaLabel, title: ariaLabel }), badgeLabel && (jsxRuntime.jsx("span", { className: styles$5.scrollToBottomBadge, "aria-live": "polite", role: "status", children: badgeLabel }))] }) })), isVoiceCalling && (jsxRuntime.jsx("div", { className: styles$5.voiceCallIndicatorBar, children: jsxRuntime.jsxs("div", { className: styles$5.voiceCallIndicator, children: [jsxRuntime.jsx("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "currentColor", children: jsxRuntime.jsx("path", { d: "M6.62 10.79c1.44 2.83 3.76 5.14 6.59 6.59l2.2-2.2c.27-.27.67-.36 1.02-.24 1.12.37 2.33.57 3.57.57.55 0 1 .45 1 1V20c0 .55-.45 1-1 1-9.39 0-17-7.61-17-17 0-.55.45-1 1-1h3.5c.55 0 1 .45 1 1 0 1.25.2 2.45.57 3.57.11.35.03.74-.25 1.02l-2.2 2.2z" }) }), jsxRuntime.jsx("span", { children: "Voice call active" }), jsxRuntime.jsx("div", { className: styles$5.voiceCallPulse })] }) })), jsxRuntime.jsx(ChatActionsBar, { actionsRef: actionsRef, actionsContainer: actionsContainer, messages: postprocessedMessages, participants: participants, title: title, onReset: onReset, resetRequiresConfirmation: resetRequiresConfirmation, newChatButtonHref: newChatButtonHref, onUseTemplate: onUseTemplate, extraActions: extraActions, saveFormats: saveFormats, isSaveButtonEnabled: isSaveButtonEnabled, shouldFadeActions: shouldFadeActions, shouldDisableActions: shouldDisableActions, chatUiTranslations: chatUiTranslations, onButtonClick: handleButtonClick }), jsxRuntime.jsx(ChatMessageList, { messages: postprocessedMessages, participants: participants, expandedMessageId: expandedMessageId, messageRatings: messageRatings, setExpandedMessageId: setExpandedMessageId, handleRating: handleRating, mode: mode, isCopyButtonEnabled: isCopyButtonEnabled, isFeedbackEnabled: isFeedbackEnabled, feedbackMode: feedbackMode, feedbackTranslations: feedbackTranslations, timingTranslations: timingTranslations, chatLocale: chatLocale, onCopy: handleCopy, onMessage: onMessage, onActionButton: onActionButton, onQuickMessageButton: onQuickMessageButton, onReplyToMessage: onReplyToMessage, canReplyToMessage: canReplyToMessage, onCreateAgent: onCreateAgent, toolTitles: toolTitles, teammates: teammates, teamAgentProfiles: teamAgentProfiles, visualMode: visualMode, soundSystem: soundSystem, onToolCallClick: openToolCall, onCitationClick: openCitation, setChatMessagesElement: setChatMessagesElement, onScroll: handleChatScroll, isSpeechPlaybackEnabled: isSpeechPlaybackEnabled, elevenLabsVoiceId: elevenLabsVoiceId, chatUiTranslations: chatUiTranslations, chatMessagesClassName: classNames(isConstrainedArticleMode && styles$5.articleModeChatMessages, getChatCssClassName('chatMessages'), chatCssClassNames.chatMessages), hasActions: hasActions }), onMessage && (jsxRuntime.jsx(ChatInputArea, { onMessage: onMessage, onChange: onChange, onFileUpload: onFileUpload, speechRecognition: speechRecognition, speechRecognitionLanguage: speechRecognitionLanguage, replyingToMessage: replyingToMessage, onCancelReply: onCancelReply, defaultMessage: defaultMessage, enterBehavior: enterBehavior, resolveEnterBehavior: resolveEnterBehavior, placeholderMessageContent: placeholderMessageContent || (chatUiTranslations === null || chatUiTranslations === void 0 ? void 0 : chatUiTranslations.inputPlaceholder), isFocusedOnLoad: isFocusedOnLoad, isMobile: isMobile, isVoiceCalling: isVoiceCalling, participants: participants, buttonColor: buttonColor, soundSystem: soundSystem, onButtonClick: handleButtonClick, chatUiTranslations: chatUiTranslations, chatInputClassName: classNames(isConstrainedArticleMode && styles$5.articleModeChatInput, getChatCssClassName('chatInput'), chatCssClassNames.chatInput) }))] }) }), jsxRuntime.jsx(ChatToolCallModal, { isOpen: toolCallModalOpen, toolCall: selectedToolCall, toolCallIdentity: selectedToolCallIdentity, onClose: closeToolCallModal, toolTitles: toolTitles, agentParticipant: agentParticipant, buttonColor: buttonColor, teamAgentProfiles: teamAgentProfiles, chatUiTranslations: chatUiTranslations, locale: chatLocale, availableTools: selectedMessageAvailableTools, mode: mode }), jsxRuntime.jsx(ChatCitationModal, { isOpen: citationModalOpen, citation: selectedCitation, participants: participants, soundSystem: soundSystem, onClose: closeCitationModal }), jsxRuntime.jsx(ChatRatingModal, { isOpen: ratingModalOpen, selectedMessage: selectedMessage, postprocessedMessages: postprocessedMessages, messages: messages, hoveredRating: hoveredRating, messageRatings: messageRatings, textRating: textRating, feedbackMode: feedbackMode, feedbackTranslations: feedbackTranslations, mode: mode, isMobile: isMobile, onClose: () => setRatingModalOpen(false), setHoveredRating: setHoveredRating, setMessageRatings: setMessageRatings, setSelectedMessage: setSelectedMessage, setTextRating: setTextRating, submitRating: submitRating })] }));
50829
51166
  }
50830
51167
 
50831
51168
  /**