hi
This commit is contained in:
parent
9970de958f
commit
a859fb4dc7
12 changed files with 174 additions and 95 deletions
BIN
lightning/public/5Q14.gif
Normal file
BIN
lightning/public/5Q14.gif
Normal file
Binary file not shown.
After Width: | Height: | Size: 20 KiB |
20
lightning/src/components/Counter.css
Normal file
20
lightning/src/components/Counter.css
Normal file
|
@ -0,0 +1,20 @@
|
|||
.increment {
|
||||
font-family: inherit;
|
||||
font-size: inherit;
|
||||
padding: 1em 2em;
|
||||
color: #335d92;
|
||||
background-color: rgba(68, 107, 158, 0.1);
|
||||
border-radius: 2em;
|
||||
border: 2px solid rgba(68, 107, 158, 0);
|
||||
outline: none;
|
||||
width: 200px;
|
||||
font-variant-numeric: tabular-nums;
|
||||
}
|
||||
|
||||
.increment:focus {
|
||||
border: 2px solid #335d92;
|
||||
}
|
||||
|
||||
.increment:active {
|
||||
background-color: rgba(68, 107, 158, 0.2);
|
||||
}
|
11
lightning/src/components/Counter.tsx
Normal file
11
lightning/src/components/Counter.tsx
Normal file
|
@ -0,0 +1,11 @@
|
|||
import { createSignal } from "solid-js";
|
||||
import "./Counter.css";
|
||||
|
||||
export default function Counter() {
|
||||
const [count, setCount] = createSignal(0);
|
||||
return (
|
||||
<button class="increment" onClick={() => setCount(count() + 1)}>
|
||||
Clicks: {count()}
|
||||
</button>
|
||||
);
|
||||
}
|
|
@ -28,6 +28,10 @@ p {
|
|||
margin: 2rem auto;
|
||||
line-height: 1.35;
|
||||
}
|
||||
ul {
|
||||
max-width: 7rem;
|
||||
margin: auto;
|
||||
}
|
||||
|
||||
@media (min-width: 480px) {
|
||||
h1 {
|
||||
|
|
|
@ -12,6 +12,7 @@ import {
|
|||
Scripts,
|
||||
Title,
|
||||
} from "solid-start";
|
||||
import BadassMap from './components/BadassMap.tsx'
|
||||
import "./root.css";
|
||||
|
||||
export default function Root() {
|
||||
|
@ -25,8 +26,9 @@ export default function Root() {
|
|||
<Body>
|
||||
<Suspense>
|
||||
<ErrorBoundary>
|
||||
<A href="/">Index</A>
|
||||
<A href="/">Map</A>
|
||||
<A href="/about">About</A>
|
||||
<BadassMap />
|
||||
<Routes>
|
||||
<FileRoutes />
|
||||
</Routes>
|
||||
|
|
38
lightning/src/routes/about.tsx
Normal file
38
lightning/src/routes/about.tsx
Normal file
|
@ -0,0 +1,38 @@
|
|||
import { Title } from 'solid-start';
|
||||
|
||||
export default function Home() {
|
||||
return (
|
||||
<main>
|
||||
<Title>Lightning</Title>
|
||||
<h1>About</h1>
|
||||
<ul>
|
||||
<li>
|
||||
<a href="https://maplibre.org/" target="_blank">
|
||||
MapLibre
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="https://openmaptiles.org/" target="_blank">
|
||||
OpenMapTiles
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="https://start.solidjs.com/" target="_blank">
|
||||
SolidStart
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="https://gis-hub.gitbook.io/solid-map-gl/" target="_blank">
|
||||
Solid Map GL
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
<img src='5Q14.gif' />
|
||||
<p>
|
||||
<a href="https://github.com/adoyle0/maps" target="_blank">
|
||||
github.com/adoyle0/maps
|
||||
</a>
|
||||
</p>
|
||||
</main>
|
||||
);
|
||||
}
|
|
@ -1,12 +1,12 @@
|
|||
import { Title } from "solid-start";
|
||||
import BadassMap from "~/components/BadassMap";
|
||||
import Counter from "~/components/Counter";
|
||||
|
||||
export default function Home() {
|
||||
return (
|
||||
<main>
|
||||
<Title>Lightning</Title>
|
||||
<h1>Lightning</h1>
|
||||
<BadassMap />
|
||||
<Counter />
|
||||
<p>Click and drag to watch me explode!
|
||||
</p>
|
||||
</main>
|
||||
|
|
|
@ -8,10 +8,14 @@
|
|||
"jsxImportSource": "solid-js",
|
||||
"jsx": "preserve",
|
||||
"strict": true,
|
||||
"types": ["solid-start/env"],
|
||||
"types": [
|
||||
"solid-start/env"
|
||||
],
|
||||
"baseUrl": "./",
|
||||
"paths": {
|
||||
"~/*": ["./src/*"]
|
||||
"~/*": [
|
||||
"./src/*"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue