Skip to content

Commit

Permalink
Merge pull request #76 from oruga-ui/add-z-index-classes
Browse files Browse the repository at this point in the history
feat(utility): add z index classes
  • Loading branch information
mlmoravek authored Jul 26, 2023
2 parents ff56b12 + edf6e67 commit 492f88d
Show file tree
Hide file tree
Showing 3 changed files with 59 additions and 12 deletions.
4 changes: 2 additions & 2 deletions src/assets/scss/bootstrap.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
* Oruga Theme Boostrap
***************************/

// Globals, helpers and functions
// Globals, utility and functions
@import "utils/animations";
@import "utils/functions";
@import "utils/helpers";
@import "utils/utility";
@import "utils/root";

// Oruga components
Expand Down
2 changes: 1 addition & 1 deletion src/assets/scss/utils/_all.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
@import "functions";
@import "variables";
@import "maps";
@import "helpers";
@import "utility";
@import "animations";
@import "root";
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,22 @@
* Global utility classes
*****************************/

// btn-close overrides

.btn-close > .icon,
.btn-close.icon > i,
.btn-close.icon > svg {
visibility: hidden;
}

@each $name, $pair in $theme-colors {
.variant-#{$name} > .btn-close {
@extend .btn-close-white;
}
}

// Utlity classes

.clickable {
cursor: pointer;
}
Expand Down Expand Up @@ -32,6 +48,8 @@
height: unset;
}

// Utility classes for text

.text-right {
text-align: right;
}
Expand All @@ -56,15 +74,44 @@
white-space: break-spaces;
}

// btn-close overrides
.btn-close > .icon,
.btn-close.icon > i,
.btn-close.icon > svg {
visibility: hidden;
// Utitlity classes for z-index sass variables (see https://getbootstrap.com/docs/5.3/layout/z-index/)

.z-dropdown {
z-index: $zindex-dropdown;
}

@each $name, $pair in $theme-colors {
.variant-#{$name} > .btn-close {
@extend .btn-close-white;
}
.z-sticky {
z-index: $zindex-sticky;
}

.z-fixed {
z-index: $zindex-fixed;
}

.z-offcanvas-backdrop {
z-index: $zindex-offcanvas-backdrop;
}

.z-offcanvas {
z-index: $zindex-offcanvas;
}

.z-modal-backdrop {
z-index: $zindex-modal-backdrop;
}

.z-modal {
z-index: $zindex-modal;
}

.z-popover {
z-index: $zindex-popover;
}

.z-tooltip {
z-index: $zindex-tooltip;
}

.z-toast {
z-index: $zindex-toast;
}

0 comments on commit 492f88d

Please sign in to comment.