File tree Expand file tree Collapse file tree
src/main/java/com/terraformersmc/modmenu/util/mod Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -40,11 +40,9 @@ default String getTranslatedName() {
4040 @ NotNull
4141 default String getSummary () {
4242 String string = getTranslatedSummary ();
43- //TODO Add back text placeholder api
44- //return ModMenu.TEXT_PLACEHOLDER_COMPAT ?
45- // TextPlaceholderApiCompat.PARSER.parseText(string, ParserContext.of()).getString() :
46- // string;
47- return string ;
43+ return ModMenu .TEXT_PLACEHOLDER_COMPAT ?
44+ TextPlaceholderApiCompat .PARSER .parseComponent (string , ParserContext .of ()).getString () :
45+ string ;
4846 }
4947
5048 @ NotNull
@@ -73,11 +71,9 @@ default String getTranslatedDescription() {
7371
7472 default Component getFormattedDescription () {
7573 String string = getTranslatedDescription ();
76- //TODO Add back text placeholder api
77- //return ModMenu.TEXT_PLACEHOLDER_COMPAT ?
78- // TextPlaceholderApiCompat.PARSER.parseText(string, ParserContext.of()) :
79- // Component.literal(string);
80- return Component .literal (string );
74+ return ModMenu .TEXT_PLACEHOLDER_COMPAT ?
75+ TextPlaceholderApiCompat .PARSER .parseComponent (string , ParserContext .of ()) :
76+ Component .literal (string );
8177 }
8278
8379 @ NotNull String getVersion ();
You can’t perform that action at this time.
0 commit comments