custom-file-tree
Advanced tools
Changelog
v5.0.0 (August 11, 2024)
<dir-entry>
and <file-entry>
buttons in a <span class="buttons">
element so that folks can more easily move the entire button collection around in their own CSS. This is a breaking change if you have CSS in place for overriding the default button placement.The relevant CSS rule changes are that the previous:
file-tree {
...
& button {
...
}
& .selected > button,
& [path="."] > button {
...
}
...
}
has become:
file-tree {
...
& .buttons {
...
}
& .selected > .buttons,
& [path="."] > .buttons {
...
}
...
}
So you will have to update your own CSS accordingly.
Similarly, any code that you've written for automatic button interaction using querySelector
will need selectors like [path="..."] > .create-dir
changed to [path="..."] > .buttons .create-dir
instead.
Changelog
v4.0.0 (July 23, 2024)
src
attribute so the file tree can be bootstrapped purely in HTML, with changes to the attribute triggering reloads..setFiles
function was renamed to .setContent
. This is a breaking change.setContent()
and src
attribute resolution, generating tree:add:file
and tree:add:dir
events. The documentation has been updated to include these events.tree:reset
event when a clear happens prior to assigning new content. There is, admittedly very little use for this event, but it's there now.tree:ready
event when it has finished building its content.Changelog
v3.2.5 (July 22, 2024)
/
could lead to duplicate dir entries, breaking dir moving in the process.Changelog
v3.2.3 (July 20, 2024)
file:click
and dir:click
no longer double-wrap their event details (i.e. they no longer contain { detail: { detail: ... }}
).Changelog
v3.2.0 (July 17, 2024)
setFiles
and select
functions on FileTree....:error
events rather than throw
s, because the code was throwing errors in code paths where they could not be caught.Changelog
v3.1.0 (July 17, 2024)