mirror of
https://github.com/All-Of-Us-Mods/MiraAPI.git
synced 2026-10-19 15:51:48 +00:00
Wire a placeholder into the wiki search box so clearing an empty box works
This commit is contained in:
1 parent
9cefeebe2b
commit
5d9c38a503
2 files changed
+8
No files matched your search
@@ -296,7 +296,14 @@ public static class RoleGuidePatches
|
||||
|
||||
RefreshActiveTab(true);
|
||||
}));
|
||||
var placeholder = Object.Instantiate(tmpText, tmpText.transform.parent);
|
||||
placeholder.name = "Placeholder";
|
||||
placeholder.color = new Color(0.55f, 0.55f, 0.55f);
|
||||
placeholder.text = MiraLocaleManager.Get("MiraApi.Wiki.SearchPlaceholder");
|
||||
placeholder.GetComponent<TextTranslatorTMP>()?.Destroy();
|
||||
_searchBoxTmp.placeholderText = placeholder;
|
||||
_searchBoxTmp.transform.localPosition = new Vector3(-1.438f, 0.756f, -0.2f);
|
||||
_searchBoxTmp.Clear();
|
||||
|
||||
var playerButton = __instance.TabButtons[0];
|
||||
SetupTabButton(
|
||||
|
||||
@@ -55,4 +55,5 @@ Outlive the timer or eliminate the crew.</string>
|
||||
<string name="Options">Options</string>
|
||||
<string name="MiraApi.Wiki.PlayersTab">Player List</string>
|
||||
<string name="MiraApi.Wiki.SettingsTab">Game Settings</string>
|
||||
<string name="MiraApi.Wiki.SearchPlaceholder">Search...</string>
|
||||
</resources>
|
||||
Reference in new issue
Block a user