@box/box-ai-content-answers 0.158.0 → 0.159.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (70) hide show
  1. package/dist/esm/lib/components/answer/answer.js +153 -140
  2. package/dist/esm/lib/components/answer/embed-the-answer-button.js +65 -0
  3. package/dist/esm/lib/components/answer/messages.js +8 -0
  4. package/dist/esm/lib/components/chat/chat.js +74 -72
  5. package/dist/esm/lib/components/sidebar/content.js +78 -76
  6. package/dist/esm/lib/components/sidebar/sidebar.js +37 -35
  7. package/dist/i18n/bn-IN.js +7 -5
  8. package/dist/i18n/bn-IN.properties +11 -5
  9. package/dist/i18n/da-DK.js +7 -5
  10. package/dist/i18n/da-DK.properties +11 -5
  11. package/dist/i18n/de-DE.js +7 -5
  12. package/dist/i18n/de-DE.properties +11 -5
  13. package/dist/i18n/en-AU.js +3 -1
  14. package/dist/i18n/en-AU.properties +7 -1
  15. package/dist/i18n/en-CA.js +4 -2
  16. package/dist/i18n/en-CA.properties +8 -2
  17. package/dist/i18n/en-GB.js +3 -1
  18. package/dist/i18n/en-GB.properties +7 -1
  19. package/dist/i18n/en-US.js +2 -0
  20. package/dist/i18n/en-US.properties +4 -0
  21. package/dist/i18n/en-x-pseudo.js +88 -86
  22. package/dist/i18n/en-x-pseudo.properties +91 -85
  23. package/dist/i18n/es-419.js +7 -5
  24. package/dist/i18n/es-419.properties +11 -5
  25. package/dist/i18n/es-ES.js +7 -5
  26. package/dist/i18n/es-ES.properties +11 -5
  27. package/dist/i18n/fi-FI.js +7 -5
  28. package/dist/i18n/fi-FI.properties +11 -5
  29. package/dist/i18n/fr-CA.js +7 -5
  30. package/dist/i18n/fr-CA.properties +11 -5
  31. package/dist/i18n/fr-FR.js +7 -5
  32. package/dist/i18n/fr-FR.properties +11 -5
  33. package/dist/i18n/hi-IN.js +7 -5
  34. package/dist/i18n/hi-IN.properties +11 -5
  35. package/dist/i18n/it-IT.js +7 -5
  36. package/dist/i18n/it-IT.properties +11 -5
  37. package/dist/i18n/ja-JP.js +7 -5
  38. package/dist/i18n/ja-JP.properties +11 -5
  39. package/dist/i18n/json/src/lib/components/answer/messages.json +1 -1
  40. package/dist/i18n/ko-KR.js +7 -5
  41. package/dist/i18n/ko-KR.properties +11 -5
  42. package/dist/i18n/nb-NO.js +7 -5
  43. package/dist/i18n/nb-NO.properties +11 -5
  44. package/dist/i18n/nl-NL.js +7 -5
  45. package/dist/i18n/nl-NL.properties +11 -5
  46. package/dist/i18n/pl-PL.js +7 -5
  47. package/dist/i18n/pl-PL.properties +11 -5
  48. package/dist/i18n/pt-BR.js +7 -5
  49. package/dist/i18n/pt-BR.properties +11 -5
  50. package/dist/i18n/ru-RU.js +7 -5
  51. package/dist/i18n/ru-RU.properties +11 -5
  52. package/dist/i18n/sv-SE.js +7 -5
  53. package/dist/i18n/sv-SE.properties +11 -5
  54. package/dist/i18n/tr-TR.js +7 -5
  55. package/dist/i18n/tr-TR.properties +11 -5
  56. package/dist/i18n/zh-CN.js +7 -5
  57. package/dist/i18n/zh-CN.properties +11 -5
  58. package/dist/i18n/zh-TW.js +7 -5
  59. package/dist/i18n/zh-TW.properties +11 -5
  60. package/dist/styles/answer.css +1 -1
  61. package/dist/styles/embed-the-answer-button.css +1 -0
  62. package/dist/types/lib/components/answer/answer.d.ts +3 -1
  63. package/dist/types/lib/components/answer/embed-the-answer-button.d.ts +11 -0
  64. package/dist/types/lib/components/answer/messages.d.ts +10 -0
  65. package/dist/types/lib/components/chat/chat.d.ts +1 -1
  66. package/dist/types/lib/components/sidebar/content.d.ts +2 -0
  67. package/dist/types/lib/components/sidebar/sidebar.d.ts +2 -1
  68. package/dist/types/lib/stories/shared.d.ts +9 -0
  69. package/dist/types/lib/types.d.ts +10 -0
  70. package/package.json +4 -4
@@ -1,3 +1,9 @@
1
+ # Add to note button aria label and tooltip text
2
+ boxAI.contentAnswers.addToNote = Add to Note
3
+ # Added to note confirmation text
4
+ boxAI.contentAnswers.addedToNote = Added
5
+ # Text shown next to the loading indicator while analyzing the request
6
+ boxAI.contentAnswers.analyzingRequest = Analyzing your request
1
7
  # Notification banner success icon aria label
2
8
  boxAI.contentAnswers.ariaTypeSuccessIconLabel = lyckades
3
9
  # Content Answers submit input button text
@@ -149,15 +155,15 @@ boxAI.textInputWithCopyButton.copyButtonSuccessText = Kopierad
149
155
  # Label that shows up while someone hover on close button of files dropdown
150
156
  boxAi.contentAnswers.closeItemList = Stäng lista med filobjekt
151
157
  # Tooltip label for button to collapse thinking content
152
- boxui.contentAnswers.collapseThinkingContent = Collapse
158
+ boxui.contentAnswers.collapseThinkingContent = Dölj
153
159
  # Tooltip label for button to expand thinking content
154
- boxui.contentAnswers.expandThinkingContent = Expand
160
+ boxui.contentAnswers.expandThinkingContent = Expandera
155
161
  # Text shown when thinking is completed
156
- boxui.contentAnswers.thinkingCompleted = Thinking Complete
162
+ boxui.contentAnswers.thinkingCompleted = Tänkande slutfört
157
163
  # Aria label for the scrollable thinking content area
158
- boxui.contentAnswers.thinkingContentScrollableArea = Thinking content scrollable area
164
+ boxui.contentAnswers.thinkingContentScrollableArea = Rullningsbart område för tänkande innehåll
159
165
  # Text shown when thinking is in progress
160
- boxui.contentAnswers.thinkingInProgress = Thinking...
166
+ boxui.contentAnswers.thinkingInProgress = Tänker…
161
167
  # Content Answers welcome message spreadsheet supported by Intelligent Query notification
162
168
  boxui.contentAnswers.welcomeMessageIntelligentQueryNotice = Du kan ställa både enkla och komplexa frågor till Box AI i ditt kalkylblad: totala antal, medelvärden, avancerade jämförelser, trendanalyser och så vidare. Prova det idag!
163
169
  # Content Answers welcome message spreadsheet notification
@@ -1,4 +1,6 @@
1
1
  export default {
2
+ "boxAI.contentAnswers.addToNote": "Add to Note",
3
+ "boxAI.contentAnswers.addedToNote": "Added",
2
4
  "boxAI.contentAnswers.analyzingRequest": "Analyzing your request",
3
5
  "boxAI.contentAnswers.ariaTypeSuccessIconLabel": "başarılı",
4
6
  "boxAI.contentAnswers.ask": "Sor",
@@ -75,11 +77,11 @@ export default {
75
77
  "boxAI.popup.closeButtonText": "Kapat",
76
78
  "boxAI.textInputWithCopyButton.copyButtonSuccessText": "Kopyalandı",
77
79
  "boxAi.contentAnswers.closeItemList": "Dosya öğeleri listesini kapat",
78
- "boxui.contentAnswers.collapseThinkingContent": "Collapse",
79
- "boxui.contentAnswers.expandThinkingContent": "Expand",
80
- "boxui.contentAnswers.thinkingCompleted": "Thinking Complete",
81
- "boxui.contentAnswers.thinkingContentScrollableArea": "Thinking content scrollable area",
82
- "boxui.contentAnswers.thinkingInProgress": "Thinking...",
80
+ "boxui.contentAnswers.collapseThinkingContent": "Daralt",
81
+ "boxui.contentAnswers.expandThinkingContent": "Genişlet",
82
+ "boxui.contentAnswers.thinkingCompleted": "Düşünme Tamamlandı",
83
+ "boxui.contentAnswers.thinkingContentScrollableArea": "Düşünme içeriği kaydırılabilir alanı",
84
+ "boxui.contentAnswers.thinkingInProgress": "Düşünüyor…",
83
85
  "boxui.contentAnswers.welcomeMessageIntelligentQueryNotice": "Box AI'a elektronik tablonuzda hem basit hem de karmaşık sorular sorabilirsiniz: Toplam sayılar, ortalamalar, ileri düzey karşılaştırmalar, trend analizleri ve benzeri şeyler. Bugün deneyin!",
84
86
  "boxui.contentAnswers.welcomeMessageSpreadsheetNotice": "Elektronik tablo desteği, metin yoğun dosyalar için en iyi sonucu verir",
85
87
  "boxui.contentAnswers.welcomeMessageSpreadsheetNoticeAriaLabel": "elektronik tablo destek bildirim afişi",
@@ -1,3 +1,9 @@
1
+ # Add to note button aria label and tooltip text
2
+ boxAI.contentAnswers.addToNote = Add to Note
3
+ # Added to note confirmation text
4
+ boxAI.contentAnswers.addedToNote = Added
5
+ # Text shown next to the loading indicator while analyzing the request
6
+ boxAI.contentAnswers.analyzingRequest = Analyzing your request
1
7
  # Notification banner success icon aria label
2
8
  boxAI.contentAnswers.ariaTypeSuccessIconLabel = başarılı
3
9
  # Content Answers submit input button text
@@ -149,15 +155,15 @@ boxAI.textInputWithCopyButton.copyButtonSuccessText = Kopyalandı
149
155
  # Label that shows up while someone hover on close button of files dropdown
150
156
  boxAi.contentAnswers.closeItemList = Dosya öğeleri listesini kapat
151
157
  # Tooltip label for button to collapse thinking content
152
- boxui.contentAnswers.collapseThinkingContent = Collapse
158
+ boxui.contentAnswers.collapseThinkingContent = Daralt
153
159
  # Tooltip label for button to expand thinking content
154
- boxui.contentAnswers.expandThinkingContent = Expand
160
+ boxui.contentAnswers.expandThinkingContent = Genişlet
155
161
  # Text shown when thinking is completed
156
- boxui.contentAnswers.thinkingCompleted = Thinking Complete
162
+ boxui.contentAnswers.thinkingCompleted = Düşünme Tamamlandı
157
163
  # Aria label for the scrollable thinking content area
158
- boxui.contentAnswers.thinkingContentScrollableArea = Thinking content scrollable area
164
+ boxui.contentAnswers.thinkingContentScrollableArea = Düşünme içeriği kaydırılabilir alanı
159
165
  # Text shown when thinking is in progress
160
- boxui.contentAnswers.thinkingInProgress = Thinking...
166
+ boxui.contentAnswers.thinkingInProgress = Düşünüyor…
161
167
  # Content Answers welcome message spreadsheet supported by Intelligent Query notification
162
168
  boxui.contentAnswers.welcomeMessageIntelligentQueryNotice = Box AI'a elektronik tablonuzda hem basit hem de karmaşık sorular sorabilirsiniz: Toplam sayılar, ortalamalar, ileri düzey karşılaştırmalar, trend analizleri ve benzeri şeyler. Bugün deneyin!
163
169
  # Content Answers welcome message spreadsheet notification
@@ -1,4 +1,6 @@
1
1
  export default {
2
+ "boxAI.contentAnswers.addToNote": "Add to Note",
3
+ "boxAI.contentAnswers.addedToNote": "Added",
2
4
  "boxAI.contentAnswers.analyzingRequest": "Analyzing your request",
3
5
  "boxAI.contentAnswers.ariaTypeSuccessIconLabel": "成功",
4
6
  "boxAI.contentAnswers.ask": "询问",
@@ -75,11 +77,11 @@ export default {
75
77
  "boxAI.popup.closeButtonText": "关闭",
76
78
  "boxAI.textInputWithCopyButton.copyButtonSuccessText": "已复制",
77
79
  "boxAi.contentAnswers.closeItemList": "关闭文件项目列表",
78
- "boxui.contentAnswers.collapseThinkingContent": "Collapse",
79
- "boxui.contentAnswers.expandThinkingContent": "Expand",
80
- "boxui.contentAnswers.thinkingCompleted": "Thinking Complete",
81
- "boxui.contentAnswers.thinkingContentScrollableArea": "Thinking content scrollable area",
82
- "boxui.contentAnswers.thinkingInProgress": "Thinking...",
80
+ "boxui.contentAnswers.collapseThinkingContent": "折叠",
81
+ "boxui.contentAnswers.expandThinkingContent": "展开",
82
+ "boxui.contentAnswers.thinkingCompleted": "思考完成",
83
+ "boxui.contentAnswers.thinkingContentScrollableArea": "思考内容可滚动区域",
84
+ "boxui.contentAnswers.thinkingInProgress": "正在思考…",
83
85
  "boxui.contentAnswers.welcomeMessageIntelligentQueryNotice": "您可以在电子表格中向 Box AI 提出简单和复杂的问题:总计数、平均值、高级比较、趋势分析等。立即试用!",
84
86
  "boxui.contentAnswers.welcomeMessageSpreadsheetNotice": "电子表格支持最适合文本密集型文件",
85
87
  "boxui.contentAnswers.welcomeMessageSpreadsheetNoticeAriaLabel": "电子表格支持通知横幅",
@@ -1,3 +1,9 @@
1
+ # Add to note button aria label and tooltip text
2
+ boxAI.contentAnswers.addToNote = Add to Note
3
+ # Added to note confirmation text
4
+ boxAI.contentAnswers.addedToNote = Added
5
+ # Text shown next to the loading indicator while analyzing the request
6
+ boxAI.contentAnswers.analyzingRequest = Analyzing your request
1
7
  # Notification banner success icon aria label
2
8
  boxAI.contentAnswers.ariaTypeSuccessIconLabel = 成功
3
9
  # Content Answers submit input button text
@@ -149,15 +155,15 @@ boxAI.textInputWithCopyButton.copyButtonSuccessText = 已复制
149
155
  # Label that shows up while someone hover on close button of files dropdown
150
156
  boxAi.contentAnswers.closeItemList = 关闭文件项目列表
151
157
  # Tooltip label for button to collapse thinking content
152
- boxui.contentAnswers.collapseThinkingContent = Collapse
158
+ boxui.contentAnswers.collapseThinkingContent = 折叠
153
159
  # Tooltip label for button to expand thinking content
154
- boxui.contentAnswers.expandThinkingContent = Expand
160
+ boxui.contentAnswers.expandThinkingContent = 展开
155
161
  # Text shown when thinking is completed
156
- boxui.contentAnswers.thinkingCompleted = Thinking Complete
162
+ boxui.contentAnswers.thinkingCompleted = 思考完成
157
163
  # Aria label for the scrollable thinking content area
158
- boxui.contentAnswers.thinkingContentScrollableArea = Thinking content scrollable area
164
+ boxui.contentAnswers.thinkingContentScrollableArea = 思考内容可滚动区域
159
165
  # Text shown when thinking is in progress
160
- boxui.contentAnswers.thinkingInProgress = Thinking...
166
+ boxui.contentAnswers.thinkingInProgress = 正在思考…
161
167
  # Content Answers welcome message spreadsheet supported by Intelligent Query notification
162
168
  boxui.contentAnswers.welcomeMessageIntelligentQueryNotice = 您可以在电子表格中向 Box AI 提出简单和复杂的问题:总计数、平均值、高级比较、趋势分析等。立即试用!
163
169
  # Content Answers welcome message spreadsheet notification
@@ -1,4 +1,6 @@
1
1
  export default {
2
+ "boxAI.contentAnswers.addToNote": "Add to Note",
3
+ "boxAI.contentAnswers.addedToNote": "Added",
2
4
  "boxAI.contentAnswers.analyzingRequest": "Analyzing your request",
3
5
  "boxAI.contentAnswers.ariaTypeSuccessIconLabel": "成功",
4
6
  "boxAI.contentAnswers.ask": "詢問",
@@ -75,11 +77,11 @@ export default {
75
77
  "boxAI.popup.closeButtonText": "關閉",
76
78
  "boxAI.textInputWithCopyButton.copyButtonSuccessText": "已複製",
77
79
  "boxAi.contentAnswers.closeItemList": "關閉檔案項目清單",
78
- "boxui.contentAnswers.collapseThinkingContent": "Collapse",
79
- "boxui.contentAnswers.expandThinkingContent": "Expand",
80
- "boxui.contentAnswers.thinkingCompleted": "Thinking Complete",
81
- "boxui.contentAnswers.thinkingContentScrollableArea": "Thinking content scrollable area",
82
- "boxui.contentAnswers.thinkingInProgress": "Thinking...",
80
+ "boxui.contentAnswers.collapseThinkingContent": "收合",
81
+ "boxui.contentAnswers.expandThinkingContent": "展開",
82
+ "boxui.contentAnswers.thinkingCompleted": "完成思考",
83
+ "boxui.contentAnswers.thinkingContentScrollableArea": "思考內容可捲動的區域",
84
+ "boxui.contentAnswers.thinkingInProgress": "正在思考…",
83
85
  "boxui.contentAnswers.welcomeMessageIntelligentQueryNotice": "您可以在試算表中詢問 BoxAI 簡單和複雜的問題:總計數、平均值、進階比較、趨勢分析等。 立即試用!",
84
86
  "boxui.contentAnswers.welcomeMessageSpreadsheetNotice": "試算表支援最適合文字密集型檔案",
85
87
  "boxui.contentAnswers.welcomeMessageSpreadsheetNoticeAriaLabel": "試算表支援通知橫幅",
@@ -1,3 +1,9 @@
1
+ # Add to note button aria label and tooltip text
2
+ boxAI.contentAnswers.addToNote = Add to Note
3
+ # Added to note confirmation text
4
+ boxAI.contentAnswers.addedToNote = Added
5
+ # Text shown next to the loading indicator while analyzing the request
6
+ boxAI.contentAnswers.analyzingRequest = Analyzing your request
1
7
  # Notification banner success icon aria label
2
8
  boxAI.contentAnswers.ariaTypeSuccessIconLabel = 成功
3
9
  # Content Answers submit input button text
@@ -149,15 +155,15 @@ boxAI.textInputWithCopyButton.copyButtonSuccessText = 已複製
149
155
  # Label that shows up while someone hover on close button of files dropdown
150
156
  boxAi.contentAnswers.closeItemList = 關閉檔案項目清單
151
157
  # Tooltip label for button to collapse thinking content
152
- boxui.contentAnswers.collapseThinkingContent = Collapse
158
+ boxui.contentAnswers.collapseThinkingContent = 收合
153
159
  # Tooltip label for button to expand thinking content
154
- boxui.contentAnswers.expandThinkingContent = Expand
160
+ boxui.contentAnswers.expandThinkingContent = 展開
155
161
  # Text shown when thinking is completed
156
- boxui.contentAnswers.thinkingCompleted = Thinking Complete
162
+ boxui.contentAnswers.thinkingCompleted = 完成思考
157
163
  # Aria label for the scrollable thinking content area
158
- boxui.contentAnswers.thinkingContentScrollableArea = Thinking content scrollable area
164
+ boxui.contentAnswers.thinkingContentScrollableArea = 思考內容可捲動的區域
159
165
  # Text shown when thinking is in progress
160
- boxui.contentAnswers.thinkingInProgress = Thinking...
166
+ boxui.contentAnswers.thinkingInProgress = 正在思考…
161
167
  # Content Answers welcome message spreadsheet supported by Intelligent Query notification
162
168
  boxui.contentAnswers.welcomeMessageIntelligentQueryNotice = 您可以在試算表中詢問 BoxAI 簡單和複雜的問題:總計數、平均值、進階比較、趨勢分析等。 立即試用!
163
169
  # Content Answers welcome message spreadsheet notification
@@ -1 +1 @@
1
- ._answer_rp7w7_1{white-space:pre-wrap;border:none}._answer_rp7w7_1 ._loadingContainer_rp7w7_5{display:flex;gap:var(--space-2);align-items:center;margin:0;padding:18px}._answer_rp7w7_1 ._loadingContainer_rp7w7_5 ._loadingText_rp7w7_12{opacity:0;animation:_fadeIn_rp7w7_1 .3s ease-in-out 1s forwards}@keyframes _fadeIn_rp7w7_1{to{opacity:1}}._answer_rp7w7_1 ._alertIcon_rp7w7_21{margin-left:.5rem}._answer_rp7w7_1 ._error_rp7w7_24{display:flex;align-items:center}._answer_rp7w7_1 ._footer_rp7w7_28{display:flex;align-items:center;justify-content:space-between;height:1.5rem}._answer_rp7w7_1 ._footer_rp7w7_28 ._copyButtonContainer_rp7w7_34,._answer_rp7w7_1 ._footer_rp7w7_28 ._feedbackButtonsContainer_rp7w7_35{opacity:0;transition:opacity .3s}._answer_rp7w7_1 ._footer_rp7w7_28._shouldHaveMarginTop_rp7w7_39{margin-top:.75rem}._answer_rp7w7_1 ._footer_rp7w7_28._shouldUseAnimation_rp7w7_42{max-height:0;overflow-y:hidden}._answer_rp7w7_1 ._footer_rp7w7_28._shouldUseAnimation_rp7w7_42._shouldAnimateHeight_rp7w7_46{max-height:200px;transition:max-height 1s ease-in}._answer_rp7w7_1 ._footer_rp7w7_28 ._footerButtons_rp7w7_50,._answer_rp7w7_1 ._footer_rp7w7_28 ._feedbackButtonsContainer_rp7w7_35{display:flex;gap:.25rem;margin-inline-start:auto}._answer_rp7w7_1 ._iconAvatar_rp7w7_56{display:flex;align-items:center;justify-content:center;width:var(--size-16);height:var(--size-16);background-color:#faf5fe;border-radius:50%}@media (max-width: 374px){._answer_rp7w7_1 ._iconAvatar_rp7w7_56{width:var(--size-6);height:var(--size-6)}}._answer_rp7w7_1:hover ._copyButtonContainer_rp7w7_34,._answer_rp7w7_1:hover ._feedbackButtonsContainer_rp7w7_35,._answer_rp7w7_1 ._copyButtonContainer_rp7w7_34:focus-within,._answer_rp7w7_1 ._feedbackButtonsContainer_rp7w7_35:focus-within,._answer_rp7w7_1 ._footerButtons_rp7w7_50._buttonsVisible_rp7w7_72 ._copyButtonContainer_rp7w7_34,._answer_rp7w7_1 ._footerButtons_rp7w7_50._buttonsVisible_rp7w7_72 ._feedbackButtonsContainer_rp7w7_35{opacity:1}._answer_rp7w7_1:hover ._copyButtonContainer_rp7w7_34>button,._answer_rp7w7_1:hover ._feedbackButtonsContainer_rp7w7_35>button,._answer_rp7w7_1 ._copyButtonContainer_rp7w7_34:focus-within>button,._answer_rp7w7_1 ._feedbackButtonsContainer_rp7w7_35:focus-within>button,._answer_rp7w7_1 ._footerButtons_rp7w7_50._buttonsVisible_rp7w7_72 ._copyButtonContainer_rp7w7_34>button,._answer_rp7w7_1 ._footerButtons_rp7w7_50._buttonsVisible_rp7w7_72 ._feedbackButtonsContainer_rp7w7_35>button{outline-offset:-2px}
1
+ ._answer_1efjn_1{white-space:pre-wrap;border:none}._answer_1efjn_1 ._loadingContainer_1efjn_5{display:flex;gap:var(--space-2);align-items:center;margin:0;padding:18px}._answer_1efjn_1 ._loadingContainer_1efjn_5 ._loadingText_1efjn_12{opacity:0;animation:_fadeIn_1efjn_1 .3s ease-in-out 1s forwards}@keyframes _fadeIn_1efjn_1{to{opacity:1}}._answer_1efjn_1 ._alertIcon_1efjn_21{margin-left:.5rem}._answer_1efjn_1 ._error_1efjn_24{display:flex;align-items:center}._answer_1efjn_1 ._footer_1efjn_28{display:flex;align-items:center;justify-content:space-between;height:1.5rem}._answer_1efjn_1 ._footer_1efjn_28 ._copyButtonContainer_1efjn_34,._answer_1efjn_1 ._footer_1efjn_28 ._feedbackButtonsContainer_1efjn_35{opacity:0;transition:opacity .3s}._answer_1efjn_1 ._footer_1efjn_28._shouldHaveMarginTop_1efjn_39{margin-top:.75rem}._answer_1efjn_1 ._footer_1efjn_28._shouldUseAnimation_1efjn_42{max-height:0;overflow-y:hidden}._answer_1efjn_1 ._footer_1efjn_28._shouldUseAnimation_1efjn_42._shouldAnimateHeight_1efjn_46{max-height:200px;transition:max-height 1s ease-in}._answer_1efjn_1 ._footer_1efjn_28 ._footerButtons_1efjn_50,._answer_1efjn_1 ._footer_1efjn_28 ._feedbackButtonsContainer_1efjn_35{display:flex;gap:.25rem;margin-inline-start:auto}._answer_1efjn_1 ._iconAvatar_1efjn_56{display:flex;align-items:center;justify-content:center;width:var(--size-16);height:var(--size-16);background-color:#faf5fe;border-radius:50%}@media (max-width: 374px){._answer_1efjn_1 ._iconAvatar_1efjn_56{width:var(--size-6);height:var(--size-6)}}._answer_1efjn_1 ._embedTheAnswerButtonContainer_1efjn_71{display:flex;justify-content:flex-start;margin-top:.5rem;padding:0 1rem;opacity:1}._answer_1efjn_1:hover ._copyButtonContainer_1efjn_34,._answer_1efjn_1:hover ._feedbackButtonsContainer_1efjn_35,._answer_1efjn_1 ._copyButtonContainer_1efjn_34:focus-within,._answer_1efjn_1 ._feedbackButtonsContainer_1efjn_35:focus-within,._answer_1efjn_1 ._footerButtons_1efjn_50._buttonsVisible_1efjn_79 ._copyButtonContainer_1efjn_34,._answer_1efjn_1 ._footerButtons_1efjn_50._buttonsVisible_1efjn_79 ._feedbackButtonsContainer_1efjn_35{opacity:1}._answer_1efjn_1:hover ._copyButtonContainer_1efjn_34>button,._answer_1efjn_1:hover ._feedbackButtonsContainer_1efjn_35>button,._answer_1efjn_1 ._copyButtonContainer_1efjn_34:focus-within>button,._answer_1efjn_1 ._feedbackButtonsContainer_1efjn_35:focus-within>button,._answer_1efjn_1 ._footerButtons_1efjn_50._buttonsVisible_1efjn_79 ._copyButtonContainer_1efjn_34>button,._answer_1efjn_1 ._footerButtons_1efjn_50._buttonsVisible_1efjn_79 ._feedbackButtonsContainer_1efjn_35>button{outline-offset:-2px}
@@ -0,0 +1 @@
1
+ ._embedTheAnswerButtonContainer_1dz6d_1{display:inline-flex;align-items:center;justify-content:flex-start}._embedTheAnswerButtonContainer_1dz6d_1 ._embedTheAnswerButton_1dz6d_1{flex-flow:row-reverse;gap:.25rem;height:2rem;min-height:auto;padding:0 1rem;color:#222;font-weight:700;font-size:.9375rem;white-space:nowrap;background-color:#fff;border:.0625rem solid #bcbcbc;border-radius:1rem;opacity:1}._embedTheAnswerButtonContainer_1dz6d_1 ._embedTheAnswerButton_1dz6d_1:hover{color:#222;background-color:#f4f4f4;border-color:#bcbcbc}._embedTheAnswerButtonContainer_1dz6d_1 ._embedTheAnswerButton_1dz6d_1:focus{color:#222;background-color:#f4f4f4;border-color:#bcbcbc}._embedTheAnswerButtonContainer_1dz6d_1 ._embedTheAnswerButton_1dz6d_1 svg{opacity:.6}._embedTheAnswerButtonContainer_1dz6d_1 ._embedTheAnswerButton_1dz6d_1 svg g{fill:#222}._embedTheAnswerButtonContainer_1dz6d_1 ._completedText_1dz6d_37{display:flex;align-items:center;justify-content:flex-start;box-sizing:border-box;height:2rem;padding:0;border:.0625rem solid transparent;border-radius:1rem;opacity:1;color:#222;font-weight:700;font-size:.9375rem;white-space:nowrap}
@@ -1,4 +1,4 @@
1
- import { ANSWER_ERROR, CitationType, FeedbackFormData, FeedbackValue, ItemClickHandler, ItemType, PromptType, RecordActionType, StyleVariant } from '../../types';
1
+ import { ANSWER_ERROR, CitationType, EmbedTheAnswerButtonConfig, FeedbackFormData, FeedbackValue, ItemClickHandler, ItemType, PromptType, RecordActionType, StyleVariant } from '../../types';
2
2
  export interface AnswerProps {
3
3
  answer?: string;
4
4
  /** Citations list */
@@ -32,6 +32,8 @@ export interface AnswerProps {
32
32
  promptType?: PromptType;
33
33
  /** Callback function when the user clicks on the answer copy button */
34
34
  onAnswerCopy?: (answer: string) => void;
35
+ /** Configuration for the embed the answer button */
36
+ embedTheAnswerButtonConfig?: EmbedTheAnswerButtonConfig;
35
37
  /** Callback function when citation button is clicked */
36
38
  onCitationClick?: ItemClickHandler;
37
39
  /** Callback function for feedback form submit */
@@ -0,0 +1,11 @@
1
+ import { EmbedTheAnswerButtonConfig, RecordActionType, StyleVariant } from '../../types';
2
+ export type EmbedTheAnswerButtonProps = {
3
+ answer?: string;
4
+ hostAppName: string;
5
+ embedTheAnswerButtonConfig?: EmbedTheAnswerButtonConfig;
6
+ questionId?: string;
7
+ recordAction?: (params: RecordActionType) => void;
8
+ variant: StyleVariant;
9
+ };
10
+ export declare const EmbedTheAnswerButton: ({ answer, hostAppName, embedTheAnswerButtonConfig, questionId, recordAction, variant, }: EmbedTheAnswerButtonProps) => import("react/jsx-runtime").JSX.Element;
11
+ export default EmbedTheAnswerButton;
@@ -1,4 +1,14 @@
1
1
  declare const messages: {
2
+ addToNote: {
3
+ defaultMessage: string;
4
+ description: string;
5
+ id: string;
6
+ };
7
+ addedToNote: {
8
+ defaultMessage: string;
9
+ description: string;
10
+ id: string;
11
+ };
2
12
  basedOn: {
3
13
  defaultMessage: string;
4
14
  description: string;
@@ -1,3 +1,3 @@
1
1
  import { ChatProps } from '../../types';
2
- export declare const Chat: ({ askSuggestedQuestion, contentType, hasCustomSuggestedQuestions, hasRequestInProgress, isCitationsEnabled, isFeedbackEnabled, isFeedbackFormEnabled, isInlineCitationsEnabled, isMarkdownEnabled, isSessionLoading, onCitationClick, onAnswerCopy, onFeedbackFormSubmit, onDropdownOpenChange, onSuggestedQuestionInteraction, questions, recordAction, setAnswerFeedback, setAskSuggestedQuestion, suggestedQuestions, suggestedQuestionsRequestState, shouldFeedbackFormIncludeFeedbackText, shouldFeedbackIncludePromptData, shouldShowLandingPage, useAnimation, variant, hostAppName, isReactMarkdownEnabled, welcomeMessageClearText, ...welcomeMessageProps }: ChatProps) => import("react/jsx-runtime").JSX.Element;
2
+ export declare const Chat: ({ askSuggestedQuestion, contentType, hasCustomSuggestedQuestions, hasRequestInProgress, isCitationsEnabled, isFeedbackEnabled, isFeedbackFormEnabled, isInlineCitationsEnabled, isMarkdownEnabled, isSessionLoading, onCitationClick, onAnswerCopy, embedTheAnswerButtonConfig, onFeedbackFormSubmit, onDropdownOpenChange, onSuggestedQuestionInteraction, questions, recordAction, setAnswerFeedback, setAskSuggestedQuestion, suggestedQuestions, suggestedQuestionsRequestState, shouldFeedbackFormIncludeFeedbackText, shouldFeedbackIncludePromptData, shouldShowLandingPage, useAnimation, variant, hostAppName, isReactMarkdownEnabled, welcomeMessageClearText, ...welcomeMessageProps }: ChatProps) => import("react/jsx-runtime").JSX.Element;
3
3
  export default Chat;
@@ -1,8 +1,10 @@
1
1
  import { AgentListResponse } from '@box/box-ai-agent-selector';
2
+ import { EmbedTheAnswerButtonConfig } from '../../types';
2
3
  import * as React from 'react';
3
4
  declare const _default: React.ComponentType<{
4
5
  getAIStudioAgents: () => Promise<AgentListResponse>;
5
6
  hostAppName: string;
6
7
  isAIStudioAgentSelectorEnabled: boolean;
8
+ embedTheAnswerButtonConfig?: EmbedTheAnswerButtonConfig;
7
9
  } & import('../api-wrapper/types').ApiWrapperProps>;
8
10
  export default _default;
@@ -1,5 +1,5 @@
1
1
  import { AgentListResponse, AgentType } from '@box/box-ai-agent-selector';
2
- import { FeedbackFormData, ItemType, SuggestedQuestionType } from '../../types';
2
+ import { EmbedTheAnswerButtonConfig, FeedbackFormData, ItemType, SuggestedQuestionType } from '../../types';
3
3
  import { CreateSessionResponse, StreamResponseTimeout, SuggestedQuestionFetcherType, agentFetcherType, fetcherStreamingType, fetcherType } from '../api-wrapper/types';
4
4
  import { IntelligenceSidebarRecordActionType } from './context';
5
5
  import { IntelligenceSidebarCache, IntelligenceSidebarCacheSetter } from './types';
@@ -38,6 +38,7 @@ export interface IntelligenceSidebarProps {
38
38
  shouldPreinitSession?: boolean;
39
39
  setHasQuestions: (hasQuestions: boolean) => void;
40
40
  promptButtonClickHandler?: (clickHandler: (content: string) => void) => void;
41
+ embedTheAnswerButtonConfig?: EmbedTheAnswerButtonConfig;
41
42
  }
42
43
  export declare const IntelligenceSidebar: (props: IntelligenceSidebarProps) => import("react/jsx-runtime").JSX.Element;
43
44
  export default IntelligenceSidebar;
@@ -32,6 +32,13 @@ export declare const defaultBoxAiContentAnswersProps: {
32
32
  };
33
33
  useAnimation: boolean;
34
34
  };
35
+ export declare const defaultUseTheAnswerConfig: {
36
+ embedTheAnswerButtonConfig: {
37
+ onAction: (...args: any[]) => void;
38
+ actionText: string;
39
+ completedText: string;
40
+ };
41
+ };
35
42
  export declare const WithUpdatedRequestInProgress: (props: BoxAiContentAnswersProps) => import("react/jsx-runtime").JSX.Element;
36
43
  export declare const DefaultBoxAIContentAnswers: (props: BoxAiContentAnswersProps) => import("react/jsx-runtime").JSX.Element;
37
44
  export declare const DefaultBoxAISidebar: (props: BoxAiContentAnswersProps) => import("react/jsx-runtime").JSX.Element;
@@ -43,3 +50,5 @@ export declare const BoxAIContentAnswersWithInlineCitationsDisabled: (props: Box
43
50
  export declare const BoxAIContentAnswersWithSpecialCharacterFileNames: (props: BoxAiContentAnswersProps) => import("react/jsx-runtime").JSX.Element;
44
51
  export declare const BoxAIContentAnswersWithUnicodeFileNames: (props: BoxAiContentAnswersProps) => import("react/jsx-runtime").JSX.Element;
45
52
  export declare const BoxAIContentAnswersWithMultipleQuestions: (props: BoxAiContentAnswersProps) => import("react/jsx-runtime").JSX.Element;
53
+ export declare const BoxAIContentAnswersWithEmbedTheAnswerButton: (props: BoxAiContentAnswersProps) => import("react/jsx-runtime").JSX.Element;
54
+ export declare const BoxAISidebarWithEmbedTheAnswerButton: (props: BoxAiContentAnswersProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,6 +1,11 @@
1
1
  import { AgentType as AIStudioAgentType } from '@box/box-ai-agent-selector';
2
2
  import { LOGGER_ACTION_CLICK, LOGGER_ACTION_KEYPRESS, LOGGER_ACTION_PROGRAMMATIC } from './components/common/constants';
3
3
  import { APP_MODE } from './constants';
4
+ export type EmbedTheAnswerButtonConfig = {
5
+ onAction: (answer: string) => void;
6
+ actionText?: string;
7
+ completedText?: string;
8
+ };
4
9
  export declare enum ANSWER_ERROR {
5
10
  GENERAL = "general",
6
11
  RATE_LIMITING = "rate_limiting",
@@ -123,6 +128,8 @@ export type ChatProps = WelcomeMessageProps & {
123
128
  onCitationClick?: ItemClickHandler;
124
129
  /** Callback function when the user clicks on the answer copy button */
125
130
  onAnswerCopy?: (answer: string) => void;
131
+ /** Configuration for the embed the answer button */
132
+ embedTheAnswerButtonConfig?: EmbedTheAnswerButtonConfig;
126
133
  /** Callback function for feedback form submit */
127
134
  onFeedbackFormSubmit?: (data: FeedbackFormData, onSuccess: () => void) => void;
128
135
  /** Callback when the user interacts with suggested question */
@@ -187,6 +194,9 @@ export type RecordActionType = {
187
194
  hostAppName: string;
188
195
  linkCount: number;
189
196
  fileNameCount: number;
197
+ } | {
198
+ hostAppName: string;
199
+ questionId: string;
190
200
  };
191
201
  component: string;
192
202
  feature: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@box/box-ai-content-answers",
3
- "version": "0.158.0",
3
+ "version": "0.159.0",
4
4
  "peerDependencies": {
5
5
  "@box/blueprint-web": "^7.8.0",
6
6
  "@box/blueprint-web-assets": "^4.56.1",
@@ -17,10 +17,10 @@
17
17
  },
18
18
  "devDependencies": {
19
19
  "@box/babel-plugin-target-attributes": "1.3.0",
20
- "@box/blueprint-web": "^12.78.1",
20
+ "@box/blueprint-web": "^12.78.3",
21
21
  "@box/blueprint-web-assets": "^4.69.0",
22
- "@box/box-ai-agent-selector": "^0.64.0",
23
- "@box/item-icon": "^0.28.0",
22
+ "@box/box-ai-agent-selector": "^0.65.0",
23
+ "@box/item-icon": "^0.29.0",
24
24
  "@box/storybook-utils": "^0.14.5",
25
25
  "@testing-library/react": "^15.0.6",
26
26
  "react": "^18.3.0",