initial commit

This commit is contained in:
Elizabeth Hunt 2023-12-27 14:38:39 -07:00
commit 7d0611aa8d
Signed by: simponic
GPG Key ID: 52B3774857EB24B1
22 changed files with 6853 additions and 0 deletions

2
.dockerignore Normal file
View File

@ -0,0 +1,2 @@
node_modules
dist

21
.gitignore vendored Normal file
View File

@ -0,0 +1,21 @@
# build output
dist/
# generated types
.astro/
# dependencies
node_modules/
# logs
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
# environment variables
.env
.env.production
# macOS-specific files
.DS_Store

12
.prettierrc.mjs Normal file
View File

@ -0,0 +1,12 @@
/** @type {import("prettier").Config} */
export default {
plugins: ["prettier-plugin-astro"],
overrides: [
{
files: "*.astro",
options: {
parser: "astro",
},
},
],
};

4
.vscode/extensions.json vendored Normal file
View File

@ -0,0 +1,4 @@
{
"recommendations": ["astro-build.astro-vscode"],
"unwantedRecommendations": []
}

11
.vscode/launch.json vendored Normal file
View File

@ -0,0 +1,11 @@
{
"version": "0.2.0",
"configurations": [
{
"command": "./node_modules/.bin/astro dev",
"name": "Development server",
"request": "launch",
"type": "node-terminal"
}
]
}

11
Dockerfile Normal file
View File

@ -0,0 +1,11 @@
FROM node:lts AS build
WORKDIR /app
COPY . .
RUN npm install
RUN npm run build
FROM nginx:latest AS runner
COPY --from=build /app/dist /usr/share/nginx/html
COPY ./nginx.conf /etc/nginx/conf.d/default.conf

54
README.md Normal file
View File

@ -0,0 +1,54 @@
# Astro Starter Kit: Basics
```sh
npm create astro@latest -- --template basics
```
[![Open in StackBlitz](https://developer.stackblitz.com/img/open_in_stackblitz.svg)](https://stackblitz.com/github/withastro/astro/tree/latest/examples/basics)
[![Open with CodeSandbox](https://assets.codesandbox.io/github/button-edit-lime.svg)](https://codesandbox.io/p/sandbox/github/withastro/astro/tree/latest/examples/basics)
[![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/withastro/astro?devcontainer_path=.devcontainer/basics/devcontainer.json)
> 🧑‍🚀 **Seasoned astronaut?** Delete this file. Have fun!
![just-the-basics](https://github.com/withastro/astro/assets/2244813/a0a5533c-a856-4198-8470-2d67b1d7c554)
## 🚀 Project Structure
Inside of your Astro project, you'll see the following folders and files:
```text
/
├── public/
│ └── favicon.svg
├── src/
│ ├── components/
│ │ └── Card.astro
│ ├── layouts/
│ │ └── Layout.astro
│ └── pages/
│ └── index.astro
└── package.json
```
Astro looks for `.astro` or `.md` files in the `src/pages/` directory. Each page is exposed as a route based on its file name.
There's nothing special about `src/components/`, but that's where we like to put any Astro/React/Vue/Svelte/Preact components.
Any static assets, like images, can be placed in the `public/` directory.
## 🧞 Commands
All commands are run from the root of the project, from a terminal:
| Command | Action |
| :------------------------ | :----------------------------------------------- |
| `npm install` | Installs dependencies |
| `npm run dev` | Starts local dev server at `localhost:4321` |
| `npm run build` | Build your production site to `./dist/` |
| `npm run preview` | Preview your build locally, before deploying |
| `npm run astro ...` | Run CLI commands like `astro add`, `astro check` |
| `npm run astro -- --help` | Get help using the Astro CLI |
## 👀 Want to learn more?
Feel free to check [our documentation](https://docs.astro.build) or jump into our [Discord server](https://astro.build/chat).

4
astro.config.mjs Normal file
View File

@ -0,0 +1,4 @@
import { defineConfig } from 'astro/config';
// https://astro.build/config
export default defineConfig({});

16
docker-compose.yml Normal file
View File

@ -0,0 +1,16 @@
version: '3.7'
services:
web:
image: simponic/wedding
build:
context: .
dockerfile: ./Dockerfile
ports:
- "4322:80"
networks:
- app-network
networks:
app-network:
driver: bridge

8
nginx.conf Normal file
View File

@ -0,0 +1,8 @@
server {
listen 80;
index index.php index.html;
server_name localhost;
error_log /var/log/nginx/error.log;
access_log /var/log/nginx/access.log;
root /usr/share/html;
}

6494
package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

21
package.json Normal file
View File

@ -0,0 +1,21 @@
{
"name": "",
"type": "module",
"version": "0.0.1",
"scripts": {
"dev": "astro dev",
"start": "astro dev",
"build": "astro check && astro build",
"preview": "astro preview",
"astro": "astro"
},
"dependencies": {
"@astrojs/check": "^0.3.4",
"astro": "^4.0.7",
"typescript": "^5.3.3"
},
"devDependencies": {
"prettier": "^3.1.1",
"prettier-plugin-astro": "^0.12.2"
}
}

BIN
public/antic_slab.ttf Normal file

Binary file not shown.

BIN
public/dancing_script.ttf Normal file

Binary file not shown.

BIN
public/flowers_br.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 956 KiB

BIN
public/flowers_ct.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 240 KiB

BIN
public/playfair_display.ttf Normal file

Binary file not shown.

View File

@ -0,0 +1,44 @@
---
const pathname = new URL(Astro.request.url).pathname;
const currentPath = pathname.slice(1);
---
<header style="text-align: center">
<h1>Riley and Lizzy</h1>
<nav>
<ul>
<li>
<a class={currentPath === "" ? "active" : ""} href="/">About</a>
</li>
<li>
<a class={currentPath === "gallery" ? "active" : ""} href="/gallery"
>Gallery</a
>
</li>
<li>
<a class={currentPath === "rsvp" ? "active" : ""} href="/rsvp">RSVP</a>
</li>
</ul>
</nav>
<hr />
</header>
<style>
h1 {
font-family: "dancing_script";
font-weight: lighter;
}
p {
margin-top: 1rem;
}
ul {
list-style-type: none;
display: flex;
justify-content: center;
text-align: center;
gap: 2rem;
}
</style>

1
src/env.d.ts vendored Normal file
View File

@ -0,0 +1 @@
/// <reference types="astro/client" />

136
src/layouts/Layout.astro Normal file
View File

@ -0,0 +1,136 @@
---
import Header from "../components/Header.astro";
interface Props {
title?: string;
}
const title = Astro.props.title ?? "Riley and Lizzy 2024";
---
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="description" content="Riley and Lizzy 2024" />
<meta name="viewport" content="width=device-width" />
<link
rel="icon"
href="data:image/svg+xml,<svg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 100 100%22><text y=%22.9em%22 font-size=%2290%22>💍</text></svg>"
/>
<meta name="generator" content={Astro.generator} />
<title>{title}</title>
</head>
<body>
<div class="content">
<Header />
<div>
<slot />
</div>
<div class="flowers-br">
<img src="/flowers_br.png" />
</div>
</div>
</body>
</html>
<style is:global>
* {
padding: 0;
margin: 0;
font-family: "antic_slab";
transition: background 0.2s ease-in-out;
}
@font-face {
font-family: "antic_slab";
src: url("/antic_slab.ttf");
}
@font-face {
font-family: "dancing_script";
src: url("/dancing_script.ttf");
}
:root {
--bg: #fbf1c7;
--text: #3c3836;
--red: #9d0006;
--green: #6d790e;
--yellow: #b57614;
--blue: #075678;
--aqua: #57ab7e;
--purple: #b16286;
--orange: #af3a03;
}
[data-theme="dark"] {
--bg: #282828;
--text: #f9f5d7;
--red: #fb4934;
--green: #b8bb26;
--yellow: #fabd2f;
--blue: #83a598;
--aqua: #8ec07c;
--purple: #d3869b;
--orange: #d65d0e;
}
body {
background: var(--bg);
}
.flowers-br {
position: fixed;
bottom: -6%;
right: -5%;
width: auto;
height: auto;
}
.flowers-br img {
min-width: 200px;
width: 25vw;
height: auto;
}
hr {
margin-top: 0.75em;
overflow: visible; /* For IE */
padding: 0;
border: none;
border-top: medium double #333;
color: #333;
text-align: center;
}
hr:after {
content: "§";
display: inline-block;
position: relative;
top: -0.74em;
font-size: 1.5em;
padding: 0 0.25em;
}
.content {
padding-top: 2rem;
margin-left: auto;
margin-right: auto;
max-width: 1000px;
width: 100%;
}
a {
text-decoration: none;
color: var(--aqua);
}
a:hover {
text-decoration: underline;
}
.active {
color: var(--purple);
}
</style>

11
src/pages/index.astro Normal file
View File

@ -0,0 +1,11 @@
---
import Layout from "../layouts/Layout.astro";
---
<Layout>
<main>
<p>Hello world!</p>
</main>
</Layout>
<style></style>

3
tsconfig.json Normal file
View File

@ -0,0 +1,3 @@
{
"extends": "astro/tsconfigs/strict"
}