Skip to content

Commit 27ee23a

Browse files
committed
Fix topbar icon on controller
Fixes the icon being sized weird when a controller is connected Signed-off-by: Ryan Luu <ryan.luu@ryanluu.dev>
1 parent 97c05bd commit 27ee23a

1 file changed

Lines changed: 5 additions & 4 deletions

File tree

‎src/TopbarIcon.client.luau‎

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,13 @@ const Satchel = require("./")
55

66
const icon = Icon.new()
77
icon:setName("SatchelInventory")
8-
icon:modifyTheme({ "IconLabel", "AutoLocalize", false }) -- Don't translate font icon
9-
const iconLabelContainer = icon:getInstance("IconLabelContainer") :: Instance
10-
iconLabelContainer:SetAttribute("TargetWidth", 0) -- Force minimum width
8+
icon:modifyTheme({
9+
{ "IconLabel", "AutoLocalize", false }, -- Don't translate font icon
10+
{ "PaddingLeft", "Size", UDim2.new(0, 4, 1, 0) }, -- Remove icon left padding
11+
{ "PaddingRight", "Size", UDim2.new(0, 4, 1, 0) }, -- Remove icon right padding
12+
})
1113
icon:setLabel("backpack")
1214
icon:setOrder(-1)
13-
icon:setTextSize(24)
1415
icon:setTextFont(
1516
"rbxasset://LuaPackages/Packages/_Index/BuilderIcons/BuilderIcons/BuilderIcons.json",
1617
Enum.FontWeight.Bold,

0 commit comments

Comments
 (0)