Перейти к содержимому
Mineforgian

Bento Box

A modular library for expressive GUIs and declarative configs

1.6M загрузок114 подписчиковLGPL-3.0-onlyfabric

Обновлён 30 марта 2026 г. · опубликован 3 июня 2024 г.

Bento Box

Bento Box is a modular library with expressive GUIs, declarative configs, and more down the road!

For developers

Thanks to Bento Box being modular, you can depend on just the modules you need without pulling in everything else.

Bento modules include:

  • Bento Config, a declarative configuration system built using Bento GUI. It aims to be simple yet powerful, with no magic pre-processors or arbitrary limitations.

  • Bento GUI, an expressive GUI library that makes building dynamic screens fast and easy. It is a replacement for Minecraft’s UI widgets that is inspired by HTML and CSS, and uses the builder pattern for building GUI elements.

  • Bento Util, a general utility library that other Bento modules tend to make use of. It has a few things here you might find useful yourself!

Bento Box is documented in-code with JavaDocs and on my wiki.

For users

If you have multiple Bento modules (i.e. Bento Config, Bento GUI) in your mod list, you can replace them all with just Bento Box.

Версии

ВерсияКаналИграЗагрузчикиДатаСкачать
0.1.0+1.21Бета1.21, 1.21.1fabric30 марта 2026 г..jar (706 КБ)
0.2.2+1.20Релиз1.20, 1.20.1, 1.20.2fabric26 августа 2024 г..jar (92 КБ)
0.2.2+1.20.3Релиз1.20.3, 1.20.4fabric26 августа 2024 г..jar (92 КБ)
0.2.1+1.20Релиз1.20, 1.20.1, 1.20.2fabric18 июня 2024 г..jar (92 КБ)
0.2.1+1.20.3Релиз1.20.3, 1.20.4fabric18 июня 2024 г..jar (92 КБ)
0.2.0Релиз1.20.1, 1.20.2, 1.20.3, 1.20.4fabric14 июня 2024 г..jar (95 КБ)
0.1.1Релиз1.20.1, 1.20.2, 1.20.3, 1.20.4fabric10 июня 2024 г..jar (73 КБ)
0.1.0Релиз1.20, 1.20.1fabric6 июня 2024 г..jar (72 КБ)

Ченджлог

0.1.0+1.21Бета1.21, 1.21.1 · 30 марта 2026 г.

Let's start over!

Sushi Bar is now known as Bento Box, with a broader scope of expressive GUIs, declarative configs, and more down the road, wrapped up in a modular package. If you the developer only need just the GUI library and nothing else, you can do that! As for users, they can download just the Bento Box mod to keep their mod lists clean. It's a win-win for both!

Bento Util

Just a simple general utility library. Its main features is a fully-featured Color class that can parse many formats, and a nifty integration with Placeholder API that lets you use it within language translation files!

To activate QuickText formatting, surround a string with square brackets. You can use translation slots with the new <%s n> tag!

"text.bento_gui.checkbox.on": ["<gray>[<green>✔<gray>]</*> <%s 1>"]

Bento GUI

An expressive GUI library inspired by HTML that I built from scratch using the builder pattern. No more will you have to suffer dealing with Minecraft's UI widgets. Simply build your elements, add them as children to panels, and the system will automatically lay them out according to their constraints like min/max dimensions and alignments.

Label title = Label.builder()
    .text(Text.translatable("config." + config.getModId() + ".title"))
    .dimensions(true, 32) // Fixed height of 32, width expands to fill
    .build();
Panel body = Panel.ofMenu()
    .dimensions(true, true) // Width and height expand to fill
    .alignCenter()
    .padding(10, 0) // Padding of 10 on the X axis
    .spacing(10) // Spacing of 10 between children
    .displayAxis(Panel.DisplayAxis.HORIZONTAL)
    .build();
Panel footer = Panel.builder()
    .dimensions(true, 32) // Fixed height of 32, width expands to fill
    .alignCenter()
    .alignMiddle()
    .padding(20, 0) // Padding of 20 on the X axis
    .spacing(8) // Spacing of 8 between children
    .displayAxis(Panel.DisplayAxis.HORIZONTAL)
    .build();

Bento Config

A declarative configuration system built on top of Bento GUI. Simply declare your options in a class file, progressively enhance them with annotations, and then optionally register it to Modmenu!

public class TestConfig extends BentoConfig<TestConfig> {
    public boolean spawn_creepers = true;
    @Range(min = 1, max = 10)
    public int spawn_amount = 3;
    @Percentage
    public float spawn_chance = 0.5f;
    public Item creeper_loot = Items.GUNPOWDER;
    @Regex("[a-z]{1,10}")
    public String creeper_name = "creeper";
}
0.2.2+1.20Релиз1.20, 1.20.1, 1.20.2 · 26 августа 2024 г.

Fixed crash when installed on dedicated servers with certain mods

0.2.2+1.20.3Релиз1.20.3, 1.20.4 · 26 августа 2024 г.

Fixed crash when installed on dedicated servers with certain mods

0.2.1+1.20Релиз1.20, 1.20.1, 1.20.2 · 18 июня 2024 г.
  • Split into 1.20 and 1.20.3 to fix a Lavender crash issue on 1.20.3
  • Fixed silly fabric.mod.json issue
0.2.1+1.20.3Релиз1.20.3, 1.20.4 · 18 июня 2024 г.
  • Split into 1.20 and 1.20.3 to fix a Lavender crash issue on 1.20.3
  • Fixed silly fabric.mod.json issue
0.2.0Релиз1.20.2, 1.20.3, 1.20.4 · 14 июня 2024 г.
  • Added item registration helper
    • register.item(String)
    • register.item(String, Item)
    • register.item(String, Item::new)
    • register.item(String, ItemSettings)
  • Added dynamic recipe templates for Lavender
    • 2x2 crafting grid
      • e.g. <recipe_2x2;minecraft:crafting_table>
    • 1x1 crafting grid
      • e.g. <recipe_1x1;minecraft:oak_planks>
0.1.1Релиз1.20.2, 1.20.3, 1.20.4 · 10 июня 2024 г.

Fixed List<Identifier> breaking on +1.20.2

Полная история изменений — на Modrinth.

Комментарии

Загружаем…