Gruntfuggly / todo-tree

Use ripgrep to find TODO tags and display the results in a tree view
Other
1.4k stars 134 forks source link

[Feature] - Hide the tag name from Tree view #783

Open gabriel-abn opened 11 months ago

gabriel-abn commented 11 months ago

The thing here is to let us mark anything as is already doing, but in Tree View I would be able to hide just the tag text.

Exemple:

src/anything.py

# TODO Implement method 1 (Suppose this is highlighted)
def my_function(params):
pass

# TODO Implement method 2 (Suppose this is highlighted)
def my_function2(params):
pass

# TODO Implement method 3 (Suppose this is highlighted)
def my_function3(params):
pass

Tree View (No Group by Tag)

:o: Implement method 1 (Suppose this is highlighted) :o: Implement method 2 (Suppose this is highlighted) :o: Implement method 3 (Suppose this is highlighted)

Tree View (Group by Tag)

:o: TODO

GurjinderSingh commented 8 months ago

removing ${tag} from label Format will remove tag name. you can also just use ${afterOrBefore} (use "after" text or "before" text if after is empty) and custom Icon from https://primer.style/ look into Highlighting todo-tree.highlights.customHighlight test with workflow icon.

"todo-tree.tree.labelFormat": "${after}",

"todo-tree.highlights.customHighlight": { "BUG": { "icon": "workflow" } }

from Read me

todo-tree.tree.labelFormat (${tag} ${after})

Format of the TODO item labels. Available placeholders are ${line}, ${column}, ${tag}, ${before} (text from before the tag), ${after} (text from after the tag), ${filename}, ${filepath} and ${afterOrBefore} (use "after" text or "before" text if after is empty). When using ${tag} or ${subTag} you can also transform the text with "uppercase", "lowercase" or "capitalize", e.g. ${tag:lowercase}.