HtmlChunk (@Nullable Icon icon, @NotNull String id) { if (icon instanceof DeferredIcon) { icon = ((DeferredIcon)icon).evaluate(); } return icon == null ? HtmlChunk.empty() : new HtmlBuilder().append(HtmlChunk.icon(id, icon)).nbsp().toFragment(); }