Skip to content

Commit

Permalink
feat(inte): edit collapse folder margin
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexis committed May 27, 2024
1 parent 6893be1 commit f558f32
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
4 changes: 4 additions & 0 deletions assets/dist/styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -954,6 +954,10 @@ body {
transform: rotate(0deg) !important;
}

.c-collapse__openable {
margin-left: -2.3rem;
}

.c-collapse__head {
display: flex;
align-items: center;
Expand Down
4 changes: 4 additions & 0 deletions assets/src/scss/05_components/_components.collapse.scss
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,10 @@
}
}

.c-collapse__openable {
margin-left: -2.3rem;
}

.c-collapse__head {
display: flex;
align-items: center;
Expand Down
2 changes: 1 addition & 1 deletion templates/components/folder_collapse.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

{% set hasChild = filesystem.listDirectory(node.path)|filter(child => child.isDir())|length > 0 %}

<li {{ attributes.defaults({class: 'c-collapse', 'data-controller': hasChild ? 'mezcalito--ux-filemanager--collapse' : '', 'data-mezcalito--ux-filemanager--collapse-visible-value': "false"}) }}>
<li {{ attributes.defaults({class: hasChild ? 'c-collapse c-collapse__openable' : 'c-collapse', 'data-controller': hasChild ? 'mezcalito--ux-filemanager--collapse' : '', 'data-mezcalito--ux-filemanager--collapse-visible-value': "false"}) }}>

<div class='c-collapse__head{% if currentPath == node.path %} c-collapse__head--active{% endif %}'>
{% if hasChild %}
Expand Down

0 comments on commit f558f32

Please sign in to comment.