fix(select-tree): adjust tree node indentation and alignment logic
- Add level prop to track node hierarchy - Fix indentation calculation for leaves and nodes - Simplify alignment logic based on node level
This commit is contained in:
No files matched your search
@@ -21,7 +21,7 @@ function handleSelect(value: string) {
|
||||
<CommandItem
|
||||
:value="item.value"
|
||||
class="flex items-center justify-between p-2 w-full text-sm font-normal hover:text-primary cursor-pointer rounded-md"
|
||||
:class="{ 'pl-12': shouldAlign }"
|
||||
:class="{ 'pl-8': shouldAlign }"
|
||||
@select="() => handleSelect(item.value)"
|
||||
>
|
||||
<span class="text-sm font-normal">{{ item.label }}</span>
|
||||
|
||||
Reference in New Issue
Block a user