diff --git a/Developer/StylesheetBuilder.wl b/Developer/StylesheetBuilder.wl index c0911704..f84b9ff2 100644 --- a/Developer/StylesheetBuilder.wl +++ b/Developer/StylesheetBuilder.wl @@ -59,6 +59,7 @@ Get[ "Wolfram`Chatbook`" ]; tr[name_?StringQ] := Dynamic[FEPrivate`FrontEndResource["ChatbookStrings", name]] +trBox[name_?StringQ] := DynamicBox[FEPrivate`FrontEndResource["ChatbookStrings", name]] (* ::Subsection::Closed:: *) @@ -448,8 +449,8 @@ $cellInsertionPointCell := $cellInsertionPointCell = ReplaceAll[ item: HoldPattern[ _ :> FrontEndTokenExecute[ EvaluationNotebook[ ], "Style", "ExternalLanguage" ] ] :> Sequence[ item, - insertionPointMenuItem[ TemplateBox[ { }, "ChatInputIcon" ], "Chat Input", "'", "ChatInput" ], - insertionPointMenuItem[ TemplateBox[ { }, "SideChatIcon" ], "Side Chat", "''", "SideChat" ] + insertionPointMenuItem[ TemplateBox[ { }, "ChatInputIcon" ], trBox[ "StylesheetInsertionMenuChatInput" ], "'", "ChatInput" ], + insertionPointMenuItem[ TemplateBox[ { }, "SideChatIcon" ], trBox[ "StylesheetInsertionMenuSideChat" ], "''", "SideChat" ] ] } ]; diff --git a/FrontEnd/StyleSheets/Chatbook.nb b/FrontEnd/StyleSheets/Chatbook.nb index 67b61033..449e1fbc 100644 --- a/FrontEnd/StyleSheets/Chatbook.nb +++ b/FrontEnd/StyleSheets/Chatbook.nb @@ -398,7 +398,15 @@ Notebook[ TemplateBox[{}, "ChatInputIcon"], BaselinePosition -> Center -> Scaled[0.55] ], - StyleBox["Chat Input", "CellInsertionMenu"], + StyleBox[ + DynamicBox[ + FEPrivate`FrontEndResource[ + "ChatbookStrings", + "StylesheetInsertionMenuChatInput" + ] + ], + "CellInsertionMenu" + ], StyleBox[ StyleBox["'", "CellInsertionMenuShortcut"], "CellInsertionMenuShortcut" @@ -471,7 +479,15 @@ Notebook[ TemplateBox[{}, "SideChatIcon"], BaselinePosition -> Center -> Scaled[0.55] ], - StyleBox["Side Chat", "CellInsertionMenu"], + StyleBox[ + DynamicBox[ + FEPrivate`FrontEndResource[ + "ChatbookStrings", + "StylesheetInsertionMenuSideChat" + ] + ], + "CellInsertionMenu" + ], StyleBox[ StyleBox["''", "CellInsertionMenuShortcut"], "CellInsertionMenuShortcut" @@ -1161,7 +1177,7 @@ Notebook[ ], Cell[ StyleData["ChatStyleSheetInformation"], - TaggingRules -> <|"StyleSheetVersion" -> "1.4.6.3923736444"|> + TaggingRules -> <|"StyleSheetVersion" -> "1.4.6.3924158197"|> ], Cell[ StyleData["Text"], diff --git a/FrontEnd/TextResources/ChatbookStrings.tr b/FrontEnd/TextResources/ChatbookStrings.tr index c466bfd0..73735a1d 100644 --- a/FrontEnd/TextResources/ChatbookStrings.tr +++ b/FrontEnd/TextResources/ChatbookStrings.tr @@ -154,6 +154,8 @@ "StylesheetChatWidgetButtonTooltip" -> "Send to LLM", "StylesheetAssistantMenuInitializerButtonTooltip" -> "Disable automatic assistance", "StylesheetFeedbackButtonTooltip" -> "Send feedback to Wolfram", +"StylesheetInsertionMenuChatInput" -> "Chat Input", +"StylesheetInsertionMenuSideChat" -> "Side Chat", "StylesheetExplodeCellsInPlace" -> "Explode Cells (In Place)", "StylesheetExplodeCellsDuplicate" -> "Explode Cells (Duplicate)", "StylesheetCopyExplodedCells" -> "Copy Exploded Cells", diff --git a/FrontEnd/TextResources/Japanese/ChatbookStrings.tr b/FrontEnd/TextResources/Japanese/ChatbookStrings.tr index 87143993..037e9b21 100644 --- a/FrontEnd/TextResources/Japanese/ChatbookStrings.tr +++ b/FrontEnd/TextResources/Japanese/ChatbookStrings.tr @@ -154,7 +154,9 @@ "StylesheetExplodeCellsDuplicate" -> "Explode Cells (Duplicate)", "StylesheetCopyExplodedCells" -> "Copy Exploded Cells", "StylesheetToggleFormatting" -> "Toggle Formatting", -"StylesheetCopyChatObject" -> "Copy ChatObject" +"StylesheetCopyChatObject" -> "Copy ChatObject", +"StylesheetInsertionMenuChatInput" -> "Chat Input", +"StylesheetInsertionMenuSideChat" -> "Side Chat" } @| @| diff --git a/FrontEnd/TextResources/Spanish/ChatbookStrings.tr b/FrontEnd/TextResources/Spanish/ChatbookStrings.tr index d48fd735..069e3755 100644 --- a/FrontEnd/TextResources/Spanish/ChatbookStrings.tr +++ b/FrontEnd/TextResources/Spanish/ChatbookStrings.tr @@ -154,7 +154,9 @@ "StylesheetExplodeCellsDuplicate" -> "Explode Cells (Duplicate)", "StylesheetCopyExplodedCells" -> "Copy Exploded Cells", "StylesheetToggleFormatting" -> "Toggle Formatting", -"StylesheetCopyChatObject" -> "Copy ChatObject" +"StylesheetCopyChatObject" -> "Copy ChatObject", +"StylesheetInsertionMenuChatInput" -> "Chat Input", +"StylesheetInsertionMenuSideChat" -> "Side Chat" } @| @|