Fix background and fix PageElement system
This commit is contained in:
parent
6fc16f4de0
commit
91d92f7f48
24 changed files with 528 additions and 809 deletions
6
src/page/main/main.html.ts
Normal file
6
src/page/main/main.html.ts
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
import './main.scss';
|
||||
import { html } from '../../types/html';
|
||||
|
||||
export const generate = (): html => `
|
||||
<main></main>
|
||||
`;
|
||||
21
src/page/main/main.scss
Normal file
21
src/page/main/main.scss
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
@use '../../style/mixins' as *;
|
||||
|
||||
main {
|
||||
height: 100%;
|
||||
overflow-x: hidden;
|
||||
overflow-y: scroll;
|
||||
perspective: 5px;
|
||||
|
||||
@media (hover: hover) {
|
||||
&::-webkit-scrollbar-track,
|
||||
&::-webkit-scrollbar {
|
||||
background-color: transparent;
|
||||
width: 12px;
|
||||
}
|
||||
|
||||
&::-webkit-scrollbar-thumb {
|
||||
background-color: var(--accent-color);
|
||||
border-radius: var(--border-radius);
|
||||
}
|
||||
}
|
||||
}
|
||||
10
src/page/main/main.ts
Normal file
10
src/page/main/main.ts
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
import { PageElement } from '../page-element';
|
||||
import { generate } from './main.html';
|
||||
import { createElement } from '../../helper/create-element';
|
||||
|
||||
export class Main extends PageElement {
|
||||
constructor(...children: Array<PageElement>) {
|
||||
super(createElement(generate()), children);
|
||||
children.forEach(c => this.attachElement(c));
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue