Skip to content

Commit

Permalink
refactor(styles): replace /deep/ with ::ng-deep (#1517)
Browse files Browse the repository at this point in the history
  • Loading branch information
nnixaa authored May 28, 2019
1 parent 8a7335a commit 721ad54
Show file tree
Hide file tree
Showing 41 changed files with 67 additions and 67 deletions.
14 changes: 7 additions & 7 deletions docs/app/@theme/components/header/header.component.scss
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
}
}

/deep/ nb-menu {
::ng-deep nb-menu {
flex: 1;
.menu-items {
display: flex;
Expand Down Expand Up @@ -130,13 +130,13 @@
margin-left: 0;
}
}
/deep/ nb-menu .menu-items li:nth-child(2) {
::ng-deep nb-menu .menu-items li:nth-child(2) {
display: list-item;
}
}

@include media-breakpoint-up(lg) {
/deep/ nb-menu .menu-items {
::ng-deep nb-menu .menu-items {
justify-content: flex-start;

li:not(:first-child) {
Expand Down Expand Up @@ -169,7 +169,7 @@
width: auto;
}
}
/deep/ nb-menu {
::ng-deep nb-menu {
flex-grow: 0;
flex-shrink: 1;
flex-basis: auto;
Expand All @@ -186,7 +186,7 @@
}

@include media-breakpoint-up(is) {
/deep/ nb-menu .menu-items li:first-child {
::ng-deep nb-menu .menu-items li:first-child {
display: list-item;
}
}
Expand All @@ -213,7 +213,7 @@
.section.middle {
justify-content: space-around;
}
/deep/ nb-menu {
::ng-deep nb-menu {
min-width: 28rem;

.menu-items li {
Expand All @@ -227,7 +227,7 @@
padding-left: 1.125rem;
width: nb-theme(sidebar-width);
}
/deep/ nb-menu {
::ng-deep nb-menu {
flex: 1;
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
display: flex;
flex-direction: column;

/deep/ nb-card {
::ng-deep nb-card {
font-weight: 300;
flex: 1;

Expand Down Expand Up @@ -54,7 +54,7 @@
flex-direction: row;
flex-wrap: wrap;

/deep/ nb-card {
::ng-deep nb-card {
margin-left: 1rem;

&:first-child {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
}
}

/deep/ nb-tabset.tabs-container {
::ng-deep nb-tabset.tabs-container {
border-radius: 0.5rem 0.5rem 0 0;

> ul {
Expand Down
10 changes: 5 additions & 5 deletions docs/app/documentation/documentation.component.scss
Original file line number Diff line number Diff line change
Expand Up @@ -46,22 +46,22 @@
border: none;
}

/deep/ nb-layout .main-container {
::ng-deep nb-layout .main-container {
padding-top: 3rem;

.scrollable {
padding-top: 0;
}
}

/deep/ nb-layout .layout-container {
::ng-deep nb-layout .layout-container {
max-width: $content-width;
width: 100%;
margin-left: auto;
margin-right: auto;
}

/deep/ nb-sidebar nb-menu {
::ng-deep nb-sidebar nb-menu {
.menu-group {
padding-left: 0;
}
Expand All @@ -85,7 +85,7 @@
}
}

/deep/ nb-layout-footer ngd-footer .contact {
::ng-deep nb-layout-footer ngd-footer .contact {
display: none;
}

Expand All @@ -96,7 +96,7 @@
}

@include media-breakpoint-up(macpro) {
/deep/ nb-layout-footer {
::ng-deep nb-layout-footer {
margin-right: $settings-width + $settings-margin;
}
}
Expand Down
4 changes: 2 additions & 2 deletions docs/app/documentation/page/page.component.scss
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@
font-size: 0.875rem;
}

/deep/ {
::ng-deep {
.widget-block {
display: block;
margin-bottom: 2rem;
Expand Down Expand Up @@ -226,7 +226,7 @@
}

@include media-breakpoint-up(md) {
.middle-column /deep/ nb-card nb-card-body {
.middle-column ::ng-deep nb-card nb-card-body {
padding: 2rem 3rem 2rem 2rem;
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/app/app.component.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
display: flex;
}

/deep/ {
::ng-deep {
.options-bar {
display: flex;
align-items: center;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
width: 100%;
max-width: 35rem;

/deep/ {
::ng-deep {
form {
width: 100%;
}
Expand Down
2 changes: 1 addition & 1 deletion src/framework/auth/components/auth.component.scss
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
}
}

/deep/ {
::ng-deep {
nb-layout .layout .layout-container .content .columns nb-layout-column {
padding: $auth-layout-padding;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
top: 0;
transition: none;

/deep/ nb-card-back {
::ng-deep nb-card-back {
top: 0;
}
}
Expand All @@ -16,7 +16,7 @@
}
}

/deep/ nb-card-front {
::ng-deep nb-card-front {
display: block;
height: 100%;
}
Expand All @@ -29,7 +29,7 @@
overflow: hidden;
transition: top 0s 0.5s;

/deep/ nb-card-back {
::ng-deep nb-card-back {
position: absolute;
left: 0;
top: 100%;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
height: 0;
}

/deep/ nb-overlay-container .primitive-overlay {
::ng-deep nb-overlay-container .primitive-overlay {
padding: 0.75rem 1rem;
}
}
8 changes: 4 additions & 4 deletions src/framework/theme/components/layout/layout.component.scss
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
flex-direction: column;
}

/deep/ nb-layout-header {
::ng-deep nb-layout-header {
display: block;

nav {
Expand All @@ -41,7 +41,7 @@
-ms-flex: 1 1 auto;
flex-direction: row;

/deep/ nb-sidebar {
::ng-deep nb-sidebar {
&.left {
@include nb-ltr(order, 0);
@include nb-rtl(order, 2);
Expand Down Expand Up @@ -83,7 +83,7 @@
flex-direction: row;
width: 100%;

/deep/ nb-layout-column {
::ng-deep nb-layout-column {
order: 1;
flex: 1 0;
min-width: 0; // fix for flexbug https://github.com/philipwalton/flexbugs#flexbug-1
Expand All @@ -97,7 +97,7 @@
}
}

/deep/ nb-layout-footer {
::ng-deep nb-layout-footer {
display: block;
margin-top: auto;

Expand Down
2 changes: 1 addition & 1 deletion src/framework/theme/components/menu/menu.component.scss
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

@import '../../styles/core/mixins';

:host /deep/ {
:host ::ng-deep {
display: block;

.menu-items,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

@import '../../../styles/core/mixins';

/deep/ nb-layout.column-curtain.with-search .layout {
::ng-deep nb-layout.column-curtain.with-search .layout {
pointer-events: none;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@
}
}

/deep/ nb-layout.curtain .scrollable-container {
::ng-deep nb-layout.curtain .scrollable-container {
position: relative;
z-index: 0;
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

@import '../../../styles/core/mixins';

/deep/ nb-layout.rotate-layout {
::ng-deep nb-layout.rotate-layout {
position: fixed;
overflow: hidden;
width: 100%;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@

@import '../../../styles/core/mixins';

/deep/ nb-layout.modal-drop .layout {
::ng-deep nb-layout.modal-drop .layout {
position: relative;
transition: transform 0.4s, opacity 0.4s;
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

/deep/ nb-layout.modal-drop.with-search .layout {
::ng-deep nb-layout.modal-drop.with-search .layout {
opacity: 0;
transform: scale3d(0.9, 0.9, 1);
pointer-events: none;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@

@import '../../../styles/core/mixins';

/deep/ nb-layout.modal-half {
::ng-deep nb-layout.modal-half {
.layout {
transition: transform 0.6s, opacity 0.6s;
transition-timing-function: cubic-bezier(0.2, 1, 0.3, 1);
}
}

/deep/ nb-layout.modal-half.with-search {
::ng-deep nb-layout.modal-half.with-search {
.layout {
transform: scale3d(0.8, 0.8, 1);
pointer-events: none;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@

@import '../../../styles/core/mixins';

/deep/ nb-layout.modal-move {
::ng-deep nb-layout.modal-move {
.layout {
transition: transform 0.5s;
}
}

/deep/ nb-layout.modal-move.with-search {
::ng-deep nb-layout.modal-move.with-search {
.layout {
transform: scale3d(0.8, 0.8, 1);
pointer-events: none;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
}
}

/deep/ nb-layout.with-search .scrollable-container {
::ng-deep nb-layout.with-search .scrollable-container {
position: relative;
z-index: 0;
}
Expand Down
4 changes: 2 additions & 2 deletions src/framework/theme/components/sidebar/sidebar.component.scss
Original file line number Diff line number Diff line change
Expand Up @@ -73,12 +73,12 @@
@include nb-rtl(left, 0);
}

/deep/ nb-sidebar-footer {
::ng-deep nb-sidebar-footer {
margin-top: auto;
display: block;
}

/deep/ nb-sidebar-header {
::ng-deep nb-sidebar-header {
display: block;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
justify-content: space-around;
}

/deep/ nb-tab {
::ng-deep nb-tab {
flex: 1;
-ms-flex: 1 1 auto;
overflow: auto;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
}


/deep/ .nb-tree-grid-cell,
/deep/ .nb-tree-grid-header-cell,
/deep/ .nb-tree-grid-footer-cell {
::ng-deep .nb-tree-grid-cell,
::ng-deep .nb-tree-grid-header-cell,
::ng-deep .nb-tree-grid-footer-cell {
overflow: hidden;
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
align-items: flex-end;
overflow-x: auto;

/deep/ nb-window:not(.full-screen) {
::ng-deep nb-window:not(.full-screen) {
margin: 0 2rem;
}
}
2 changes: 1 addition & 1 deletion src/playground/with-layout/dialog/dialog-common.scss
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/deep/ {
::ng-deep {
nb-layout-column {
height: 80vw;
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/deep/ body {
::ng-deep body {
height: 30rem;
}

Expand Down
Loading

0 comments on commit 721ad54

Please sign in to comment.