Add basic scaffolding

This commit is contained in:
subnixr 2017-05-28 18:59:35 +02:00
parent f2402829b1
commit 169926ac2c
9 changed files with 289 additions and 0 deletions

5
src/base.less Normal file
View File

@ -0,0 +1,5 @@
html, body {
margin: 0;
padding: 0;
border: none;
}

7
src/content.less Normal file
View File

@ -0,0 +1,7 @@
@import 'globals';
.content {
padding-top: @header-height;
max-width: @content-width;
margin: 0 auto;
}

2
src/globals.less Normal file
View File

@ -0,0 +1,2 @@
@content-width: 800px;
@header-height: 40px;

19
src/header.less Normal file
View File

@ -0,0 +1,19 @@
@import 'globals';
.header {
width: 100%;
margin: 0 auto;
position: fixed;
}
.header .wrapper {
width: 100%;
height: @header-height;
max-width: @content-width;
margin: 0 auto;
overflow: hidden;
}
.header .logo,.title {
float: left;
}

26
src/index.html Normal file
View File

@ -0,0 +1,26 @@
<html>
<head>
<title>Unit</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="index.css">
</head>
<body>
<div class="header">
<div class="wrapper">
<div class="logo">
<img src="logo.svg" alt="logo">
</div>
<div class="title">Unit</div>
</div>
</div>
<div class="content">
<div class="no-js">
<a href="news.rss">news.rss</a>
</div>
</div>
<script src="index.js"></script>
</body>
</html>

5
src/index.js Normal file
View File

@ -0,0 +1,5 @@
var noJs = document.querySelectorAll('.no-js');
noJs.forEach(function (elem) {
elem.remove();
});

4
src/index.less Normal file
View File

@ -0,0 +1,4 @@
@import 'base';
@import 'header';
@import 'logo';
@import 'content';

6
src/logo.less Normal file
View File

@ -0,0 +1,6 @@
@import 'globals';
.logo img {
width: @header-height;
height: @header-height;
}

215
src/logo.svg Normal file

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 7.7 KiB