return the title used for InventoryMenu
@@ -78,6 +78,13 @@ static InventoryMenu of(ViewableInventory inventory) {
*/
void setTitle(Component title);
+ /**
+ * Returns the title of this menu if set.
+ *
+ * @return the title of this menu if set.
+ */
+ Optional<Component> title();
+
/**
* Registers click callbacks. Unregisters previously registered handler of the same type.
* <p>Return false in the handler to prevent changes.</p>
