ItemPresentation () { return new ItemPresentation() { @Override public String getPresentableText() { final var nestedPresentation = getSimpleNestedPresentation(MarkdownList.this); if (nestedPresentation != null) { return nestedPresentation.getPresentableText(); } return getNode().getElementType() == MarkdownElementTypes.ORDERED_LIST ? ORDERED_LIST_TEXT : UNORDERED_LIST_TEXT; } @Override public String getLocationString() { final var nestedPresentation = getSimpleNestedPresentation(MarkdownList.this); if (nestedPresentation != null) { return nestedPresentation.getLocationString(); } return null; } @Override public Icon getIcon(final boolean open) { return MarkdownPsiStructureUtil.isSimpleNestedList(getParent().getChildren()) ? null : AllIcons.Actions.ListFiles; } }; }