IComponent (@NotNull final IComponent component, @NotNull final String id) { if (id.equals(component.getId())) { return component; } if (!(component instanceof IContainer uiContainer)) { return null; } for (int i = 0; i < uiContainer.getComponentCount(); i++) { final IComponent found = findComponent(uiContainer.getComponent(i), id); if (found != null) { return found; } } return null; }