ChatInputBarConfiguration TextBox automatically fires Focused event

Attempting to set a custom TextBox for ChatInputBarConfiguration automatically fires the Focused event. This occurs after assigning a custom TextBox to ChatInputBarConfiguration, and regardless of whether or not you connect the Focused event.

Steps in Studio (a Baseplate template will suffice);

  1. Add a ScreenGui with a TextBox object to StarterGui
  2. The following can be added to a LocalScript and placed in StarterPlayerScripts:
local LocalPlayer = game:GetService("Players").LocalPlayer
local PlrGui = LocalPlayer:WaitForChild("PlayerGui")
local InputConfig = game:GetService("TextChatService"):FindFirstChildOfClass("ChatInputBarConfiguration")
local ChatBox = PlrGui:WaitForChild("Chatbox")
InputConfig.TextBox = ChatBox.TextBox

InputConfig.TextBox.Focused:Connect(function()
	print"focused"
end)

InputConfig.TextBox.FocusLost:Connect(function()
	print"focuslost"
end)
  1. Click Play. Almost immediately on spawn, the Focused event will automatically fire and print "focused" once, without any other input.

Repro:
ChatInputBugRepro.rbxl (60.9 KB)

Expected behavior

Setting a custom TextBox should not fire the Focused event.

2 Likes