Skip to content

Commit

Permalink
refactor: turn on view encapsulation for content pages (#647)
Browse files Browse the repository at this point in the history
  • Loading branch information
davidlj95 authored Jun 30, 2024
1 parent 37b94e1 commit b1c1039
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 18 deletions.
33 changes: 17 additions & 16 deletions src/app/content-page/content-page.component.scss
Original file line number Diff line number Diff line change
@@ -1,25 +1,26 @@
@use 'margins';
@use 'page';

app-content-page {
:host {
display: block;
padding: page.$padding;
}

h1 {
margin-block-end: margins.$m;
}
::ng-deep {
h1 {
margin-block-end: margins.$m;
}

h2 {
margin-block: margins.$m;
}

p {
margin-block: 1em;
}
h2 {
margin-block: margins.$m;
}

ul {
list-style-type: square;
margin-inline-start: 1em;
padding-inline-start: 1em;
p {
margin-block: 1em;
}
ul {
list-style-type: square;
margin-inline-start: 1em;
padding-inline-start: 1em;
}
}
}
3 changes: 1 addition & 2 deletions src/app/content-page/content-page.component.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
import { Component, ViewEncapsulation } from '@angular/core'
import { Component } from '@angular/core'

@Component({
selector: 'app-content-page',
standalone: true,
imports: [],
template: '<ng-content></ng-content>',
styleUrl: './content-page.component.scss',
encapsulation: ViewEncapsulation.None,
})
export class ContentPageComponent {}

0 comments on commit b1c1039

Please sign in to comment.