sues_virtual_life: start site; install gulp

This commit is contained in:
marleyrae 2023-06-13 18:17:41 -07:00
parent 6afec146aa
commit e561163db4
7 changed files with 6201 additions and 3 deletions

14
.idea/webResources.xml Normal file
View file

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="WebResourcesPaths">
<contentEntries>
<entry url="file://$PROJECT_DIR$">
<entryData>
<resourceRoots>
<path value="file://$PROJECT_DIR$/sues_virtual_life" />
</resourceRoots>
</entryData>
</entry>
</contentEntries>
</component>
</project>

6106
package-lock.json generated

File diff suppressed because it is too large Load diff

View file

@ -1,7 +1,12 @@
{
"dependencies": {
},
"scripts": {
"dev": "browser-sync start --config bs-config.js"
},
"devDependencies": {
"browser-sync": "^2.29.3",
"gulp": "^4.0.2",
"gulp-posthtml": "^3.0.5",
"gulp-rename": "^2.0.0",
"posthtml-urls": "^1.0.0"
}
}

View file

View file

@ -0,0 +1,26 @@
const {src, dest, watch} = require('gulp')
const posthtml = require('gulp-posthtml')
const rename = require('gulp-rename')
const browserSync = require('browser-sync').create()
const htmlFiles = ['./**/*.html', '!./**/index.html']
function html() {
return src(htmlFiles)
.pipe(posthtml([
require('posthtml-urls')({
eachURL: (url) => url[0] === '/' && url !== '/menu.js' ? `/sues_virtual_life${url}` : url,
}),
]))
.pipe(rename(path => {
path.basename = 'index'
}))
.pipe(dest('.'))
.pipe(browserSync.stream())
}
exports.default = function () {
browserSync.init(require('../bs-config'))
watch(htmlFiles, {ignoreInitial: false}, html)
}

View file

@ -0,0 +1,27 @@
body {
--color: #000;
--background-color: #fff;
font-family: Tahoma, sans-serif;
color: var(--color);
font-weight: 100;
font-size: 10pt;
}
a, a:visited, a:active {
color: #fff;
text-decoration: none;
}
a:hover {
color: #fff;
text-decoration: underline overline;
cursor: crosshair;
}
header {
height: 90px;
background-color: #7ac5cd;
padding: 0 10px 10px;
text-align: center;
}

View file

@ -0,0 +1,22 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<!-- from source -->
<title>Sue's Virtual Life</title>
<link rel="shortcut icon" href="img/bs-icon.ico">
<!-- -->
<link rel="stylesheet" href="/sues_virtual_life.css">
<!-- archive menu -->
<script src="/menu.js" type="module"></script>
</head>
<body>
<header>
</header>
</body>
</html>