Skip to content

Commit

Permalink
Offcanvas adjustments for dynamic import, missing styling import
Browse files Browse the repository at this point in the history
  • Loading branch information
Oksydan committed Dec 4, 2023
1 parent 62ca5cd commit 662e26c
Show file tree
Hide file tree
Showing 6 changed files with 39 additions and 31 deletions.
2 changes: 2 additions & 0 deletions _dev/css/dynamic/offcanvas/_index.scss
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
@import "../../abstracts/index";
@import "~bootstrap/scss/offcanvas";
@import "override";
5 changes: 5 additions & 0 deletions _dev/css/dynamic/offcanvas/_override.scss
Original file line number Diff line number Diff line change
@@ -1 +1,6 @@
// Styles override for the offcanvas component


.offcanvas-footer {
padding: var(--bs-offcanvas-padding-y) var(--bs-offcanvas-padding-x);
}
11 changes: 0 additions & 11 deletions _dev/css/theme/components/cart/_blockcart.scss

This file was deleted.

7 changes: 6 additions & 1 deletion _dev/css/theme/utility/_dynamic-import-fix.scss
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,12 @@
display: none;
}

// FIX TO MODAL, hidden by default
// FIX TO OFFCANVAS, hidden by default
.offcanvas {
display: none;
}

// FIX TO DROPDOWN, hidden by default
.dropdown-menu {
display: none;
}
Expand Down
2 changes: 1 addition & 1 deletion _dev/css/theme/vendors/_bootstrap.scss
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
@import "~bootstrap/scss/spinners";
@import "~bootstrap/scss/placeholders";
@import "~bootstrap/scss/utilities";
@import "~bootstrap/scss/offcanvas";


// Helpers
Expand All @@ -37,6 +36,7 @@
// @import "~bootstrap/scss/popover";
// @import "~bootstrap/scss/toasts";
// @import "~bootstrap/scss/tooltip";
//@import "~bootstrap/scss/offcanvas";

//NOT USED
// @import "~bootstrap/scss/carousel";
43 changes: 25 additions & 18 deletions templates/components/offcanvas.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -5,24 +5,31 @@
tabindex="-1"
{block name='offcanvas_extra_attribues'}{/block}
>
{block name='offcanvas_header'}
<div class="offcanvas-header {block name='offcanvas_header_extra_class'}{/block}" >
{block name='offcanvas_title' hide}
<h5 class="offcanvas-title">{$smarty.block.child}</h5>
{/block}
<button
type="button"
class="btn-close"
data-bs-dismiss="offcanvas"
aria-label="Close"
>
</button>
</div>
{/block}
{block name='offcanvas_body' hide}
<div class="offcanvas-body {block name='offcanvas_body_extra_class'}{/block}">
{$smarty.block.child}
</div>
{block name='offcanvas_content'}
{block name='offcanvas_header'}
<div class="offcanvas-header {block name='offcanvas_header_extra_class'}{/block}">
{block name='offcanvas_title' hide}
<h5 class="offcanvas-title">{$smarty.block.child}</h5>
{/block}
<button
type="button"
class="btn-close"
data-bs-dismiss="offcanvas"
aria-label="Close"
>
</button>
</div>
{/block}
{block name='offcanvas_body' hide}
<div class="offcanvas-body {block name='offcanvas_body_extra_class'}{/block}">
{$smarty.block.child}
</div>
{/block}
{block name='offcanvas_footer' hide}
<div class="offcanvas-footer {block name='offcanvas_footer_extra_class'}{/block}">
{$smarty.block.child}
</div>
{/block}
{/block}
</div>
{/block}

0 comments on commit 662e26c

Please sign in to comment.