Spaces:
Sleeping
Sleeping
Duplicate from huggingface-projects/wordalle
Browse filesCo-authored-by: Radamés Ajna <[email protected]>
This view is limited to 50 files because it contains too many changes.
See raw diff
- .gitattributes +27 -0
- .github/README.md +1 -0
- .gitignore +31 -0
- ALT-README.md +1 -0
- Makefile +12 -0
- README.md +14 -0
- app.py +136 -0
- frontend/.eslintignore +13 -0
- frontend/.eslintrc.cjs +20 -0
- frontend/.gitignore +8 -0
- frontend/.npmrc +1 -0
- frontend/.nvmrc +1 -0
- frontend/.prettierignore +13 -0
- frontend/.prettierrc +6 -0
- frontend/README.md +38 -0
- frontend/package-lock.json +0 -0
- frontend/package.json +41 -0
- frontend/postcss.config.cjs +6 -0
- frontend/src/app.css +25 -0
- frontend/src/app.d.ts +10 -0
- frontend/src/app.html +13 -0
- frontend/src/lib/Keyboard.svelte +65 -0
- frontend/src/lib/Message.svelte +30 -0
- frontend/src/lib/Result.svelte +145 -0
- frontend/src/lib/badges/fifteen.svelte +119 -0
- frontend/src/lib/badges/fifty.svelte +106 -0
- frontend/src/lib/badges/five.svelte +120 -0
- frontend/src/lib/badges/ten.svelte +115 -0
- frontend/src/lib/badges/thirtyfive.svelte +109 -0
- frontend/src/lib/badges/twenty.svelte +109 -0
- frontend/src/lib/badges/two.svelte +84 -0
- frontend/src/lib/store.ts +26 -0
- frontend/src/lib/utils.ts +57 -0
- frontend/src/routes/__layout.svelte +5 -0
- frontend/src/routes/index.svelte +503 -0
- frontend/src/types.ts +33 -0
- frontend/static/img1.jpg +0 -0
- frontend/static/img2.jpg +0 -0
- frontend/svelte.config.js +32 -0
- frontend/tailwind.config.cjs +7 -0
- frontend/tsconfig.json +13 -0
- install-node.sh +11 -0
- main.py +3 -0
- requirements.txt +8 -0
- static/_app/immutable/assets/pages/__layout.svelte-7926a3a8.css +1 -0
- static/_app/immutable/assets/pages/index.svelte-b52b250e.css +1 -0
- static/_app/immutable/chunks/fifteen-9add13bd.js +1 -0
- static/_app/immutable/chunks/fifty-f65036e1.js +1 -0
- static/_app/immutable/chunks/five-ba00de65.js +1 -0
- static/_app/immutable/chunks/index-86f4d6c3.js +4 -0
.gitattributes
ADDED
@@ -0,0 +1,27 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
*.7z filter=lfs diff=lfs merge=lfs -text
|
2 |
+
*.arrow filter=lfs diff=lfs merge=lfs -text
|
3 |
+
*.bin filter=lfs diff=lfs merge=lfs -text
|
4 |
+
*.bz2 filter=lfs diff=lfs merge=lfs -text
|
5 |
+
*.ftz filter=lfs diff=lfs merge=lfs -text
|
6 |
+
*.gz filter=lfs diff=lfs merge=lfs -text
|
7 |
+
*.h5 filter=lfs diff=lfs merge=lfs -text
|
8 |
+
*.joblib filter=lfs diff=lfs merge=lfs -text
|
9 |
+
*.lfs.* filter=lfs diff=lfs merge=lfs -text
|
10 |
+
*.model filter=lfs diff=lfs merge=lfs -text
|
11 |
+
*.msgpack filter=lfs diff=lfs merge=lfs -text
|
12 |
+
*.onnx filter=lfs diff=lfs merge=lfs -text
|
13 |
+
*.ot filter=lfs diff=lfs merge=lfs -text
|
14 |
+
*.parquet filter=lfs diff=lfs merge=lfs -text
|
15 |
+
*.pb filter=lfs diff=lfs merge=lfs -text
|
16 |
+
*.pt filter=lfs diff=lfs merge=lfs -text
|
17 |
+
*.pth filter=lfs diff=lfs merge=lfs -text
|
18 |
+
*.rar filter=lfs diff=lfs merge=lfs -text
|
19 |
+
saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
20 |
+
*.tar.* filter=lfs diff=lfs merge=lfs -text
|
21 |
+
*.tflite filter=lfs diff=lfs merge=lfs -text
|
22 |
+
*.tgz filter=lfs diff=lfs merge=lfs -text
|
23 |
+
*.wasm filter=lfs diff=lfs merge=lfs -text
|
24 |
+
*.xz filter=lfs diff=lfs merge=lfs -text
|
25 |
+
*.zip filter=lfs diff=lfs merge=lfs -text
|
26 |
+
*.zstandard filter=lfs diff=lfs merge=lfs -text
|
27 |
+
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
.github/README.md
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
../ALT-README.md
|
.gitignore
ADDED
@@ -0,0 +1,31 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
.DS_Store
|
2 |
+
.env
|
3 |
+
.flaskenv
|
4 |
+
*.pyc
|
5 |
+
*.pyo
|
6 |
+
env/
|
7 |
+
venv/
|
8 |
+
.venv/
|
9 |
+
env*
|
10 |
+
dist/
|
11 |
+
build/
|
12 |
+
*.egg
|
13 |
+
*.egg-info/
|
14 |
+
_mailinglist
|
15 |
+
.tox/
|
16 |
+
.cache/
|
17 |
+
.pytest_cache/
|
18 |
+
.idea/
|
19 |
+
docs/_build/
|
20 |
+
.vscode
|
21 |
+
# Coverage reports
|
22 |
+
htmlcov/
|
23 |
+
.coverage
|
24 |
+
.coverage.*
|
25 |
+
*,cover
|
26 |
+
venv
|
27 |
+
*_cache.json
|
28 |
+
data
|
29 |
+
prompts.db
|
30 |
+
static/data.json
|
31 |
+
static/images
|
ALT-README.md
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
# Wordalle
|
Makefile
ADDED
@@ -0,0 +1,12 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
install-node:
|
2 |
+
./install-node.sh
|
3 |
+
build-client:
|
4 |
+
cd frontend && npm install && npm run build && rm -rf ../static && cp -r build/ ../static/
|
5 |
+
build-dev:
|
6 |
+
cd frontend && npm install && NODE_ENV=development npm run build && rm -rf ../static && cp -rv build/ ../static/
|
7 |
+
run-dev:
|
8 |
+
FLASK_DEBUG=development python app.py
|
9 |
+
run-prod:
|
10 |
+
python app.py
|
11 |
+
# build-all: install-node build-client run
|
12 |
+
build-all: run-prod
|
README.md
ADDED
@@ -0,0 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
title: Wordalle
|
3 |
+
emoji: 🥑📚🥑
|
4 |
+
colorFrom: blue
|
5 |
+
colorTo: gray
|
6 |
+
sdk: gradio
|
7 |
+
sdk_version: 3.0.17
|
8 |
+
app_file: main.py
|
9 |
+
fullWidth: true
|
10 |
+
pinned: false
|
11 |
+
duplicated_from: huggingface-projects/wordalle
|
12 |
+
---
|
13 |
+
|
14 |
+
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
app.py
ADDED
@@ -0,0 +1,136 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
import os
|
2 |
+
from datasets import load_dataset
|
3 |
+
import json
|
4 |
+
import uuid
|
5 |
+
from pathlib import Path
|
6 |
+
import json
|
7 |
+
from datasets import load_dataset
|
8 |
+
from flask import Flask, request, jsonify
|
9 |
+
from flask_cors import CORS
|
10 |
+
from flask_apscheduler import APScheduler
|
11 |
+
import shutil
|
12 |
+
from PIL import Image
|
13 |
+
import sqlite3
|
14 |
+
from huggingface_hub import Repository
|
15 |
+
import subprocess
|
16 |
+
|
17 |
+
app = Flask(__name__, static_url_path='/static')
|
18 |
+
|
19 |
+
CORS(app)
|
20 |
+
|
21 |
+
TOKEN = os.environ.get('dataset_token')
|
22 |
+
|
23 |
+
DB_FILE = Path("./prompts.db")
|
24 |
+
|
25 |
+
repo = Repository(
|
26 |
+
local_dir="data",
|
27 |
+
repo_type="dataset",
|
28 |
+
clone_from="huggingface-projects/wordalle_guesses",
|
29 |
+
use_auth_token=TOKEN
|
30 |
+
)
|
31 |
+
repo.git_pull()
|
32 |
+
# copy db on db to local path
|
33 |
+
shutil.copyfile("./data/prompts.db", DB_FILE)
|
34 |
+
|
35 |
+
dataset = load_dataset(
|
36 |
+
"huggingface-projects/wordalle_prompts",
|
37 |
+
use_auth_token=TOKEN)
|
38 |
+
|
39 |
+
Path("static/images").mkdir(parents=True, exist_ok=True)
|
40 |
+
|
41 |
+
db = sqlite3.connect(DB_FILE)
|
42 |
+
try:
|
43 |
+
data = db.execute("SELECT * FROM prompts").fetchall()
|
44 |
+
db.close()
|
45 |
+
except sqlite3.OperationalError:
|
46 |
+
db.execute('CREATE TABLE prompts (guess TEXT, correct TEXT)')
|
47 |
+
db.commit()
|
48 |
+
|
49 |
+
# extract images and prompts from dataset and save to dis
|
50 |
+
data = {}
|
51 |
+
for row in dataset['train']:
|
52 |
+
prompt = dataset['train'].features['label'].int2str(row['label'])
|
53 |
+
image = row['image']
|
54 |
+
hash = uuid.uuid4().hex
|
55 |
+
image_file = Path(f'static/images/{hash}.jpg')
|
56 |
+
image_compress = image.resize((136, 136), Image.Resampling.LANCZOS)
|
57 |
+
image_compress.save(image_file, optimize=True, quality=95)
|
58 |
+
if prompt not in data:
|
59 |
+
data[prompt] = []
|
60 |
+
data[prompt].append(str(image_file))
|
61 |
+
|
62 |
+
with open('static/data.json', 'w') as f:
|
63 |
+
json.dump(data, f)
|
64 |
+
|
65 |
+
|
66 |
+
def update_repository():
|
67 |
+
repo.git_pull()
|
68 |
+
# copy db on db to local path
|
69 |
+
shutil.copyfile(DB_FILE, "./data/prompts.db")
|
70 |
+
|
71 |
+
with sqlite3.connect("./data/prompts.db") as db:
|
72 |
+
db.row_factory = sqlite3.Row
|
73 |
+
result = db.execute("SELECT * FROM prompts").fetchall()
|
74 |
+
# data = [dict(row) for row in result]
|
75 |
+
os
|
76 |
+
# with open('./data/data.json', 'w') as f:
|
77 |
+
# json.dump(data, f, separators=(',', ':'))
|
78 |
+
|
79 |
+
print("Updating repository")
|
80 |
+
subprocess.Popen(
|
81 |
+
"git add . && git commit --amend -m 'update' && git push --force", cwd="./data", shell=True)
|
82 |
+
# repo.push_to_hub(blocking=False)
|
83 |
+
|
84 |
+
|
85 |
+
@ app.route('/')
|
86 |
+
def index():
|
87 |
+
return app.send_static_file('index.html')
|
88 |
+
|
89 |
+
|
90 |
+
@ app.route('/force_push')
|
91 |
+
def push():
|
92 |
+
if(request.headers['token'] == TOKEN):
|
93 |
+
print("Force Push repository")
|
94 |
+
shutil.copyfile(DB_FILE, "./data/prompts.db")
|
95 |
+
subprocess.Popen(
|
96 |
+
"git add . && git commit --amend -m 'update' && git push --force", cwd="./data", shell=True)
|
97 |
+
return "Success", 200
|
98 |
+
else:
|
99 |
+
return "Error", 401
|
100 |
+
|
101 |
+
|
102 |
+
@ app.route('/data')
|
103 |
+
def getdata():
|
104 |
+
return app.send_static_file('data.json')
|
105 |
+
|
106 |
+
|
107 |
+
@ app.route('/prompt', methods=['POST', 'GET'])
|
108 |
+
def create():
|
109 |
+
if request.method == 'POST':
|
110 |
+
try:
|
111 |
+
data = request.get_json()
|
112 |
+
guess = data['guess']
|
113 |
+
correct = data['correct']
|
114 |
+
with sqlite3.connect(DB_FILE) as db:
|
115 |
+
db.execute(
|
116 |
+
'INSERT INTO prompts (guess, correct) VALUES (?, ?)', (guess, correct))
|
117 |
+
db.commit()
|
118 |
+
return 'OK', 200
|
119 |
+
except:
|
120 |
+
return 'Missing guess or correct', 400
|
121 |
+
|
122 |
+
|
123 |
+
if __name__ == '__main__':
|
124 |
+
mode = os.environ.get('FLASK_ENV', 'production')
|
125 |
+
print(mode)
|
126 |
+
dev = mode == 'development'
|
127 |
+
if not dev:
|
128 |
+
print("Starting scheduler -- Running Production")
|
129 |
+
scheduler = APScheduler()
|
130 |
+
scheduler.add_job(id='Update Dataset Repository',
|
131 |
+
func=update_repository, trigger='interval', hours=1)
|
132 |
+
scheduler.start()
|
133 |
+
else:
|
134 |
+
print("Not Starting scheduler -- Running Development")
|
135 |
+
app.run(host='0.0.0.0', port=int(
|
136 |
+
os.environ.get('PORT', 7860)), debug=True, use_reloader=dev)
|
frontend/.eslintignore
ADDED
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
.DS_Store
|
2 |
+
node_modules
|
3 |
+
/build
|
4 |
+
/.svelte-kit
|
5 |
+
/package
|
6 |
+
.env
|
7 |
+
.env.*
|
8 |
+
!.env.example
|
9 |
+
|
10 |
+
# Ignore files for PNPM, NPM and YARN
|
11 |
+
pnpm-lock.yaml
|
12 |
+
package-lock.json
|
13 |
+
yarn.lock
|
frontend/.eslintrc.cjs
ADDED
@@ -0,0 +1,20 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
module.exports = {
|
2 |
+
root: true,
|
3 |
+
parser: '@typescript-eslint/parser',
|
4 |
+
extends: ['eslint:recommended', 'plugin:@typescript-eslint/recommended', 'prettier'],
|
5 |
+
plugins: ['svelte3', '@typescript-eslint'],
|
6 |
+
ignorePatterns: ['*.cjs'],
|
7 |
+
overrides: [{ files: ['*.svelte'], processor: 'svelte3/svelte3' }],
|
8 |
+
settings: {
|
9 |
+
'svelte3/typescript': () => require('typescript')
|
10 |
+
},
|
11 |
+
parserOptions: {
|
12 |
+
sourceType: 'module',
|
13 |
+
ecmaVersion: 2020
|
14 |
+
},
|
15 |
+
env: {
|
16 |
+
browser: true,
|
17 |
+
es2017: true,
|
18 |
+
node: true
|
19 |
+
}
|
20 |
+
};
|
frontend/.gitignore
ADDED
@@ -0,0 +1,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
.DS_Store
|
2 |
+
node_modules
|
3 |
+
/build
|
4 |
+
/.svelte-kit
|
5 |
+
/package
|
6 |
+
.env
|
7 |
+
.env.*
|
8 |
+
!.env.example
|
frontend/.npmrc
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
engine-strict=true
|
frontend/.nvmrc
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
v18.3.0
|
frontend/.prettierignore
ADDED
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
.DS_Store
|
2 |
+
node_modules
|
3 |
+
/build
|
4 |
+
/.svelte-kit
|
5 |
+
/package
|
6 |
+
.env
|
7 |
+
.env.*
|
8 |
+
!.env.example
|
9 |
+
|
10 |
+
# Ignore files for PNPM, NPM and YARN
|
11 |
+
pnpm-lock.yaml
|
12 |
+
package-lock.json
|
13 |
+
yarn.lock
|
frontend/.prettierrc
ADDED
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"useTabs": true,
|
3 |
+
"singleQuote": true,
|
4 |
+
"trailingComma": "none",
|
5 |
+
"printWidth": 100
|
6 |
+
}
|
frontend/README.md
ADDED
@@ -0,0 +1,38 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
# create-svelte
|
2 |
+
|
3 |
+
Everything you need to build a Svelte project, powered by [`create-svelte`](https://github.com/sveltejs/kit/tree/master/packages/create-svelte).
|
4 |
+
|
5 |
+
## Creating a project
|
6 |
+
|
7 |
+
If you're seeing this, you've probably already done this step. Congrats!
|
8 |
+
|
9 |
+
```bash
|
10 |
+
# create a new project in the current directory
|
11 |
+
npm init svelte
|
12 |
+
|
13 |
+
# create a new project in my-app
|
14 |
+
npm init svelte my-app
|
15 |
+
```
|
16 |
+
|
17 |
+
## Developing
|
18 |
+
|
19 |
+
Once you've created a project and installed dependencies with `npm install` (or `pnpm install` or `yarn`), start a development server:
|
20 |
+
|
21 |
+
```bash
|
22 |
+
npm run dev
|
23 |
+
|
24 |
+
# or start the server and open the app in a new browser tab
|
25 |
+
npm run dev -- --open
|
26 |
+
```
|
27 |
+
|
28 |
+
## Building
|
29 |
+
|
30 |
+
To create a production version of your app:
|
31 |
+
|
32 |
+
```bash
|
33 |
+
npm run build
|
34 |
+
```
|
35 |
+
|
36 |
+
You can preview the production build with `npm run preview`.
|
37 |
+
|
38 |
+
> To deploy your app, you may need to install an [adapter](https://kit.svelte.dev/docs/adapters) for your target environment.
|
frontend/package-lock.json
ADDED
The diff for this file is too large to render.
See raw diff
|
|
frontend/package.json
ADDED
@@ -0,0 +1,41 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"name": "wordalle",
|
3 |
+
"version": "0.0.1",
|
4 |
+
"scripts": {
|
5 |
+
"dev": "svelte-kit dev --host 0.0.0.0",
|
6 |
+
"build": "svelte-kit build",
|
7 |
+
"build-dev": "NODE_ENV=development npm run build",
|
8 |
+
"package": "svelte-kit package",
|
9 |
+
"preview": "svelte-kit preview",
|
10 |
+
"prepare": "svelte-kit sync",
|
11 |
+
"check": "svelte-check --tsconfig ./tsconfig.json",
|
12 |
+
"check:watch": "svelte-check --tsconfig ./tsconfig.json --watch",
|
13 |
+
"lint": "prettier --check --plugin-search-dir=. . && eslint .",
|
14 |
+
"format": "prettier --write --plugin-search-dir=. ."
|
15 |
+
},
|
16 |
+
"devDependencies": {
|
17 |
+
"@sveltejs/adapter-static": "^1.0.0-next.34",
|
18 |
+
"@sveltejs/kit": "^1.0.0-next.357",
|
19 |
+
"@types/dom-to-image": "^2.6.4",
|
20 |
+
"@typescript-eslint/eslint-plugin": "^5.30.0",
|
21 |
+
"@typescript-eslint/parser": "^5.30.0",
|
22 |
+
"autoprefixer": "^10.4.7",
|
23 |
+
"eslint": "^8.18.0",
|
24 |
+
"eslint-config-prettier": "^8.3.0",
|
25 |
+
"eslint-plugin-svelte3": "^4.0.0",
|
26 |
+
"postcss": "^8.4.14",
|
27 |
+
"prettier": "^2.7.1",
|
28 |
+
"prettier-plugin-svelte": "^2.7.0",
|
29 |
+
"svelte": "^3.44.0",
|
30 |
+
"svelte-check": "^2.8.0",
|
31 |
+
"svelte-preprocess": "^4.10.7",
|
32 |
+
"tailwindcss": "^3.1.4",
|
33 |
+
"tslib": "^2.3.1",
|
34 |
+
"typescript": "^4.7.4"
|
35 |
+
},
|
36 |
+
"type": "module",
|
37 |
+
"dependencies": {
|
38 |
+
"dom-to-image": "^2.6.0",
|
39 |
+
"nanoid": "^4.0.0"
|
40 |
+
}
|
41 |
+
}
|
frontend/postcss.config.cjs
ADDED
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
module.exports = {
|
2 |
+
plugins: {
|
3 |
+
tailwindcss: {},
|
4 |
+
autoprefixer: {},
|
5 |
+
},
|
6 |
+
}
|
frontend/src/app.css
ADDED
@@ -0,0 +1,25 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
@tailwind base;
|
2 |
+
@tailwind components;
|
3 |
+
@tailwind utilities;
|
4 |
+
|
5 |
+
:root {
|
6 |
+
--cols: 19;
|
7 |
+
}
|
8 |
+
|
9 |
+
.correct,
|
10 |
+
.present,
|
11 |
+
.absent {
|
12 |
+
color: #fff !important;
|
13 |
+
}
|
14 |
+
|
15 |
+
.correct {
|
16 |
+
background-color: #6aaa64 !important;
|
17 |
+
}
|
18 |
+
|
19 |
+
.present {
|
20 |
+
background-color: #c9b458 !important;
|
21 |
+
}
|
22 |
+
|
23 |
+
.absent {
|
24 |
+
background-color: #787c7e !important;
|
25 |
+
}
|
frontend/src/app.d.ts
ADDED
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/// <reference types="@sveltejs/kit" />
|
2 |
+
|
3 |
+
// See https://kit.svelte.dev/docs/types#app
|
4 |
+
// for information about these interfaces
|
5 |
+
declare namespace App {
|
6 |
+
// interface Locals {}
|
7 |
+
// interface Platform {}
|
8 |
+
// interface Session {}
|
9 |
+
// interface Stuff {}
|
10 |
+
}
|
frontend/src/app.html
ADDED
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<!DOCTYPE html>
|
2 |
+
<html lang="en">
|
3 |
+
<head>
|
4 |
+
<meta charset="utf-8" />
|
5 |
+
<!-- <link rel="icon" href="%sveltekit.assets%/favicon.png" /> -->
|
6 |
+
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
7 |
+
<script src="https://cdnjs.cloudflare.com/ajax/libs/iframe-resizer/4.3.1/iframeResizer.contentWindow.min.js"></script>
|
8 |
+
%sveltekit.head%
|
9 |
+
</head>
|
10 |
+
<body class="dark:bg-[rgb(11,15,25)] bg-white dark:text-white text-black">
|
11 |
+
<div>%sveltekit.body%</div>
|
12 |
+
</body>
|
13 |
+
</html>
|
frontend/src/lib/Keyboard.svelte
ADDED
@@ -0,0 +1,65 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<script lang="ts">
|
2 |
+
import type { LetterState } from '../types';
|
3 |
+
import { createEventDispatcher } from 'svelte';
|
4 |
+
|
5 |
+
export let letterStates: Record<string, LetterState>;
|
6 |
+
const dispatch = createEventDispatcher();
|
7 |
+
|
8 |
+
const rows = [
|
9 |
+
'qwertyuiop'.split(''),
|
10 |
+
[...'asdfghjkl'.split('')],
|
11 |
+
['Enter', ...'zxcvbnm'.split(''), 'Backspace']
|
12 |
+
];
|
13 |
+
</script>
|
14 |
+
|
15 |
+
<div class="my-3 mx-auto select-none max-w-md">
|
16 |
+
{#each rows as row, i}
|
17 |
+
<div class="row">
|
18 |
+
{#if i === 1}
|
19 |
+
<div class="spacer" />
|
20 |
+
{/if}
|
21 |
+
{#each row as key}
|
22 |
+
<button
|
23 |
+
class="{letterStates[key] === undefined ? '' : letterStates[key]} {key.length > 1 &&
|
24 |
+
'big'}"
|
25 |
+
on:click={() => dispatch('keyup', key)}
|
26 |
+
>
|
27 |
+
{#if key === 'Backspace'}
|
28 |
+
<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24">
|
29 |
+
<path
|
30 |
+
fill="currentColor"
|
31 |
+
d="M22 3H7c-.69 0-1.23.35-1.59.88L0 12l5.41 8.11c.36.53.9.89 1.59.89h15c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H7.07L2.4 12l4.66-7H22v14zm-11.59-2L14 13.41 17.59 17 19 15.59 15.41 12 19 8.41 17.59 7 14 10.59 10.41 7 9 8.41 12.59 12 9 15.59z"
|
32 |
+
/>
|
33 |
+
</svg>
|
34 |
+
{:else}
|
35 |
+
<span>{key}</span>
|
36 |
+
{/if}
|
37 |
+
</button>
|
38 |
+
{/each}
|
39 |
+
{#if i === 1}
|
40 |
+
<div class="spacer" />
|
41 |
+
{/if}
|
42 |
+
</div>
|
43 |
+
{/each}
|
44 |
+
</div>
|
45 |
+
|
46 |
+
<style lang="postcss" scoped>
|
47 |
+
.row {
|
48 |
+
@apply flex w-full mt-0 mb-2 mx-auto touch-manipulation;
|
49 |
+
}
|
50 |
+
button {
|
51 |
+
@apply flex font-bold text-xs m-0 mr-1 p-0 min-h-[58px] border-0
|
52 |
+
rounded-sm justify-center items-center uppercase cursor-pointer
|
53 |
+
transition-all duration-200 ease-in-out flex-1 select-none
|
54 |
+
bg-[#d3d6da] text-[#1a1a1b] hover:scale-105;
|
55 |
+
}
|
56 |
+
button.big {
|
57 |
+
flex: 1.5;
|
58 |
+
}
|
59 |
+
button:last-of-type {
|
60 |
+
margin: 0;
|
61 |
+
}
|
62 |
+
.spacer {
|
63 |
+
flex: 0.5;
|
64 |
+
}
|
65 |
+
</style>
|
frontend/src/lib/Message.svelte
ADDED
@@ -0,0 +1,30 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<script lang="ts">
|
2 |
+
import { fade } from 'svelte/transition';
|
3 |
+
import { GameState } from '../types';
|
4 |
+
import { createEventDispatcher } from 'svelte';
|
5 |
+
|
6 |
+
const dispatch = createEventDispatcher();
|
7 |
+
|
8 |
+
export let gameState: GameState;
|
9 |
+
export let message: string | null = null;
|
10 |
+
</script>
|
11 |
+
|
12 |
+
<div class="message" transition:fade>
|
13 |
+
{message}
|
14 |
+
{#if gameState === GameState.FAIL}
|
15 |
+
<div class="font-light flex-1 text-xs sm:text-base text-center">
|
16 |
+
<button
|
17 |
+
on:click={() => dispatch('restart')}
|
18 |
+
class="hover:no-underline underline underline-offset-2 hover:scale-105 transition-all duration-200 ease-in-out"
|
19 |
+
>Try Again</button
|
20 |
+
>
|
21 |
+
</div>
|
22 |
+
{/if}
|
23 |
+
</div>
|
24 |
+
|
25 |
+
<style lang="postcss" scoped>
|
26 |
+
.message {
|
27 |
+
@apply absolute left-1/2 top-1/2 text-white bg-black bg-opacity-80 font-semibold
|
28 |
+
text-center p-5 z-20 rounded-sm -translate-x-1/2 transition-opacity duration-300 ease-in-out;
|
29 |
+
}
|
30 |
+
</style>
|
frontend/src/lib/Result.svelte
ADDED
@@ -0,0 +1,145 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<script lang="ts">
|
2 |
+
import { colors, cheersMessages, badgesComponents } from '$lib/utils';
|
3 |
+
import type { Board } from '../types';
|
4 |
+
import { fade, scale } from 'svelte/transition';
|
5 |
+
import { createEventDispatcher, onDestroy, onMount } from 'svelte';
|
6 |
+
import type { SvelteComponent } from 'svelte';
|
7 |
+
import { dev } from '$app/env';
|
8 |
+
|
9 |
+
const dispatch = createEventDispatcher();
|
10 |
+
|
11 |
+
export let board: Board;
|
12 |
+
export let currentRowIndex: number;
|
13 |
+
export let imagePaths: string[];
|
14 |
+
export let totalStreaks: number;
|
15 |
+
const message = cheersMessages[currentRowIndex];
|
16 |
+
import domtoimage from 'dom-to-image';
|
17 |
+
const apiUrl = dev ? 'http://localhost:7860/' : '';
|
18 |
+
|
19 |
+
let modalEl: HTMLDivElement;
|
20 |
+
let elToShare: HTMLDivElement;
|
21 |
+
let disableDownload: boolean = false;
|
22 |
+
|
23 |
+
async function saveFile(node: HTMLDivElement) {
|
24 |
+
disableDownload = true;
|
25 |
+
try {
|
26 |
+
const blob = await domtoimage.toBlob(node, { bgcolor: '#000' });
|
27 |
+
const a = document.createElement('a');
|
28 |
+
a.download = `sucess-${Date.now()}.png`;
|
29 |
+
a.target = '_self';
|
30 |
+
a.onclick = async (e) => {
|
31 |
+
disableDownload = true;
|
32 |
+
if (a.href) {
|
33 |
+
URL.revokeObjectURL(a.href);
|
34 |
+
disableDownload = false;
|
35 |
+
return;
|
36 |
+
}
|
37 |
+
a.href = URL.createObjectURL(blob);
|
38 |
+
disableDownload = false;
|
39 |
+
};
|
40 |
+
a.click();
|
41 |
+
console.log('Downloding image.');
|
42 |
+
} catch (err) {
|
43 |
+
console.log(err.name, err.message);
|
44 |
+
}
|
45 |
+
}
|
46 |
+
const onKeyup = (e: KeyboardEvent) => {
|
47 |
+
if (e.key === 'Escape' || e.key === 'Enter') {
|
48 |
+
dispatch('restart');
|
49 |
+
} else if (e.key === ' ') {
|
50 |
+
saveFile(elToShare);
|
51 |
+
}
|
52 |
+
};
|
53 |
+
|
54 |
+
let badgeComponent: SvelteComponent;
|
55 |
+
|
56 |
+
onMount(async () => {
|
57 |
+
if (totalStreaks in badgesComponents) {
|
58 |
+
const compName = badgesComponents[totalStreaks];
|
59 |
+
badgeComponent = (await import(`./badges/${compName}.svelte`)).default;
|
60 |
+
}
|
61 |
+
setTimeout(() => {
|
62 |
+
window.addEventListener('keyup', onKeyup, true);
|
63 |
+
}, 1000);
|
64 |
+
});
|
65 |
+
|
66 |
+
onDestroy(() => {
|
67 |
+
window.removeEventListener('keyup', onKeyup, true);
|
68 |
+
});
|
69 |
+
const s = 10;
|
70 |
+
const p = 1;
|
71 |
+
const rx = s / 10;
|
72 |
+
</script>
|
73 |
+
|
74 |
+
<!-- Modal made with tailwind -->
|
75 |
+
<div bind:this={modalEl} class="modal relative z-50" transition:fade>
|
76 |
+
<div class="message">
|
77 |
+
<div class="border-0">
|
78 |
+
<div class="p-3" bind:this={elToShare}>
|
79 |
+
<header class="p-3 flex justify-between items-center">
|
80 |
+
<h1 class="text-xs font-bold uppercase whitespace-nowrap">WORDALLE 🥑</h1>
|
81 |
+
<span class="font-light">hf.co/wordalle</span>
|
82 |
+
</header>
|
83 |
+
<h2 class="text-center uppercase tracking-widest font-extrabold">{message}</h2>
|
84 |
+
<div class="grid grid-cols-3 gap-2 p-3 relative">
|
85 |
+
{#if totalStreaks in badgesComponents}
|
86 |
+
<div
|
87 |
+
transition:scale={{ duration: 500 }}
|
88 |
+
class="absolute left-0 right-0 top-0 bottom-0 flex place-content-center place-items-center"
|
89 |
+
>
|
90 |
+
<svelte:component this={badgeComponent} classNames="w-full max-w-[180px]" />
|
91 |
+
</div>
|
92 |
+
{/if}
|
93 |
+
{#each imagePaths as image}
|
94 |
+
<div>
|
95 |
+
<img src={apiUrl + image} alt="" class="aspect-square w-full h-full" />
|
96 |
+
</div>
|
97 |
+
{/each}
|
98 |
+
</div>
|
99 |
+
<svg
|
100 |
+
class="w-full p-3 mx-auto max-h-[30vh]"
|
101 |
+
viewBox="0 0 {board[0].length * (p + s) - p} {board.length * (p + s) - p}"
|
102 |
+
xmlns="http://www.w3.org/2000/svg"
|
103 |
+
>
|
104 |
+
{#each board as row, y}
|
105 |
+
{#each row as tile, x}
|
106 |
+
<rect
|
107 |
+
fill={colors[tile.state]}
|
108 |
+
x={x * (s + p)}
|
109 |
+
y={y * (s + p)}
|
110 |
+
width={s}
|
111 |
+
height={s}
|
112 |
+
{rx}
|
113 |
+
/>
|
114 |
+
{/each}
|
115 |
+
{/each}
|
116 |
+
</svg>
|
117 |
+
</div>
|
118 |
+
</div>
|
119 |
+
<div class="p-3 px-6 flex text-base">
|
120 |
+
<button
|
121 |
+
disabled={disableDownload}
|
122 |
+
class="min-w-[15ch] flex-1 mr-1"
|
123 |
+
on:click={() => saveFile(elToShare)}
|
124 |
+
>
|
125 |
+
{!disableDownload ? 'SAVE SCREENSHOT' : 'SAVING..'}
|
126 |
+
</button>
|
127 |
+
<button class="flex-1 ml-1" on:click={() => dispatch('restart')}> NEXT </button>
|
128 |
+
</div>
|
129 |
+
</div>
|
130 |
+
</div>
|
131 |
+
|
132 |
+
<style lang="postcss" scoped>
|
133 |
+
.message {
|
134 |
+
@apply text-white bg-black bg-opacity-80 font-semibold p-10 z-20 rounded-md transition-opacity duration-300 ease-in-out mx-auto max-w-lg;
|
135 |
+
}
|
136 |
+
.modal {
|
137 |
+
@apply fixed top-0 left-0 w-screen min-h-screen z-10 bg-black bg-opacity-80 backdrop-blur-sm;
|
138 |
+
transform: translateZ(1000px);
|
139 |
+
transform-style: preserve-3d;
|
140 |
+
}
|
141 |
+
.go-tweet,
|
142 |
+
button {
|
143 |
+
@apply bg-gray-700 hover:bg-gray-900 text-white font-bold p-1 my-1 text-sm rounded transition-opacity duration-500 ease-in-out;
|
144 |
+
}
|
145 |
+
</style>
|
frontend/src/lib/badges/fifteen.svelte
ADDED
@@ -0,0 +1,119 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<script lang="ts">
|
2 |
+
export let classNames = '';
|
3 |
+
</script>
|
4 |
+
|
5 |
+
<svg
|
6 |
+
xmlns="http://www.w3.org/2000/svg"
|
7 |
+
xmlns:xlink="http://www.w3.org/1999/xlink"
|
8 |
+
fill="none"
|
9 |
+
viewBox="0 0 385 450"
|
10 |
+
width="385"
|
11 |
+
height="450"
|
12 |
+
class={classNames}
|
13 |
+
>
|
14 |
+
<defs>
|
15 |
+
<path
|
16 |
+
id="a"
|
17 |
+
fill="#777A6F"
|
18 |
+
d="M372.7 107.8 201.9 7.6a25 25 0 0 0-25.7.2L12 107.7A25 25 0 0 0 0 129v194.2a25 25 0 0 0 12.2 21.5l164.2 97.7a25 25 0 0 0 25.3.2l170.7-98A25 25 0 0 0 385 323V129.3a25 25 0 0 0-12.3-21.5Z"
|
19 |
+
/>
|
20 |
+
</defs>
|
21 |
+
<use xlink:href="#a" />
|
22 |
+
<mask
|
23 |
+
id="b"
|
24 |
+
width="385"
|
25 |
+
height="443"
|
26 |
+
x="0"
|
27 |
+
y="4"
|
28 |
+
maskUnits="userSpaceOnUse"
|
29 |
+
style="mask-type:alpha"
|
30 |
+
>
|
31 |
+
<use xlink:href="#a" />
|
32 |
+
</mask>
|
33 |
+
<g mask="url(#b)">
|
34 |
+
<path
|
35 |
+
fill="#686C5D"
|
36 |
+
d="M177.5 322c-25 59-49.7 120.7-138.5 83s-182.7-151-157.6-210c25.1-59.1 116.3-93.2 205.1-55.5s116 123.4 91 182.5Z"
|
37 |
+
/>
|
38 |
+
<path
|
39 |
+
fill="#4E4F51"
|
40 |
+
d="M9 328.5c-9-17-15-206-15-206L-14.5 357 190 486l202-133V126.5s-7.5 187.5-15 202c-3.5 6.8-39.3 28.2-78 52-43.2 26.6-90.5 55.5-109 55.5-18.2 0-63-26.6-104-52.5-37.9-23.9-72.7-46.8-77-55Z"
|
41 |
+
/>
|
42 |
+
<path
|
43 |
+
fill="#CCDDE2"
|
44 |
+
d="M166 379h48c-9.3 31-9.3 47.8 0 77h-48c8.3-30 7.2-47 0-77Zm165-78.8 30-23.2c8.1 32.4 18.3 45.8 47.1 61l-30 23.2c-4.2-35-15.9-47.2-47.1-61Z"
|
45 |
+
opacity=".2"
|
46 |
+
/>
|
47 |
+
<path
|
48 |
+
fill="#C89435"
|
49 |
+
d="M330 111.8 342.6 76c25.7 20.2 41.6 26 72.7 25.6l-12.7 35.8c-24.7-20.3-41-25-72.6-25.6Z"
|
50 |
+
opacity=".3"
|
51 |
+
/>
|
52 |
+
<path
|
53 |
+
fill="#CCDDE2"
|
54 |
+
d="m22 273 29 24.7c-29.7 14.9-40.7 27.7-50 58.6l-29-24.7c30.4-13.8 40.9-27 50-58.6Z"
|
55 |
+
opacity=".2"
|
56 |
+
/>
|
57 |
+
</g>
|
58 |
+
<path
|
59 |
+
fill="url(#c)"
|
60 |
+
d="m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v174.5a25 25 0 0 0 12.2 21.5l147.6 87.7a25 25 0 0 0 25.2.2l153.4-88A25 25 0 0 0 368 293V119.1a25 25 0 0 0-12.4-21.6Z"
|
61 |
+
/>
|
62 |
+
<mask
|
63 |
+
id="e"
|
64 |
+
width="351"
|
65 |
+
height="403"
|
66 |
+
x="17"
|
67 |
+
y="4"
|
68 |
+
maskUnits="userSpaceOnUse"
|
69 |
+
style="mask-type:alpha"
|
70 |
+
>
|
71 |
+
<path
|
72 |
+
fill="url(#d)"
|
73 |
+
d="m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v174.5a25 25 0 0 0 12.2 21.5l147.6 87.7a25 25 0 0 0 25.2.2l153.4-88A25 25 0 0 0 368 293V119.1a25 25 0 0 0-12.4-21.6Z"
|
74 |
+
/>
|
75 |
+
</mask>
|
76 |
+
<g mask="url(#e)">
|
77 |
+
<path
|
78 |
+
fill="url(#f)"
|
79 |
+
d="M394.2 346.7c46.5-71.6-249.6-263-249.6-263L119 108s211.6 114.9 176.5 163.3c-35 48.4-217-78.3-217-78.3L107 311.7s240.7 106.5 287.3 35Z"
|
80 |
+
opacity=".4"
|
81 |
+
/>
|
82 |
+
<path
|
83 |
+
fill="#D9E8EF"
|
84 |
+
d="M157-47h177L137 459H-40L157-47Zm195.5-2H368L189.5 421H174L352.5-49Z"
|
85 |
+
opacity=".8"
|
86 |
+
/>
|
87 |
+
<path
|
88 |
+
fill="#ECF8FF"
|
89 |
+
d="M360.5 111c14 17 8 34 8 38L389 95 194-31 10 78.5V161s7.5-39.5 15.5-52.5 124-113 165-94 156 79.5 170 96.5Z"
|
90 |
+
/>
|
91 |
+
<path
|
92 |
+
fill="#DBEAF2"
|
93 |
+
d="M21.5 299c-14-17-8-34-8-38L-7 315l195 126 184-109.5V249s-7.5 39.5-15.5 52.5-124 113-165 94-156-79.5-170-96.5Z"
|
94 |
+
opacity=".7"
|
95 |
+
/>
|
96 |
+
</g>
|
97 |
+
<path
|
98 |
+
fill="#777A6F"
|
99 |
+
d="M108.6 326a5 5 0 0 1-5-5V58a5 5 0 0 1 5-5h41.8a5 5 0 0 1 5 5v263a5 5 0 0 1-5 5h-41.8Zm173-21.2a5 5 0 0 1-.5 2.1 34.5 34.5 0 0 1-30.6 19.1h-52.6a34.5 34.5 0 0 1-30.8-19.1c-.4-.6-.5-1.4-.5-2V227a5 5 0 0 1 5-5h38.8a5 5 0 0 1 5 5v42a5 5 0 0 0 5 5h7.4a5 5 0 0 0 5-5v-59a5 5 0 0 0-5-5h-56.2a5 5 0 0 1-5-5V58a5 5 0 0 1 5-5h97.7a5 5 0 0 1 5 5v37.9a5 5 0 0 1-5 5h-48.9a5 5 0 0 0-5 5v42a5 5 0 0 0 5 5h30c6.9 0 13.1 1.9 18.7 5.6a33 33 0 0 1 12 13.6c.3.6.5 1.3.5 2v130.7Z"
|
100 |
+
/>
|
101 |
+
<path
|
102 |
+
fill="#fff"
|
103 |
+
d="M108.6 310a5 5 0 0 1-5-5V42a5 5 0 0 1 5-5h41.8a5 5 0 0 1 5 5v263a5 5 0 0 1-5 5h-41.8Zm173-21.2c0 .7-.2 1.4-.5 2a34.5 34.5 0 0 1-30.6 19.2h-52.6a34.5 34.5 0 0 1-30.8-19.1 4 4 0 0 1-.5-2.1V211a5 5 0 0 1 5-5h38.8a5 5 0 0 1 5 5v42a5 5 0 0 0 5 5h7.4a5 5 0 0 0 5-5v-59.1a5 5 0 0 0-5-5h-56.2a5 5 0 0 1-5-5v-142a5 5 0 0 1 5-5h97.7a5 5 0 0 1 5 5v38a5 5 0 0 1-5 5h-48.9a5 5 0 0 0-5 5v42a5 5 0 0 0 5 5h30a33 33 0 0 1 18.7 5.5 33 33 0 0 1 12 13.6c.3.6.5 1.3.5 2v130.8Z"
|
104 |
+
/>
|
105 |
+
<defs>
|
106 |
+
<linearGradient id="c" x1="103" x2="192.5" y1="13" y2="410" gradientUnits="userSpaceOnUse">
|
107 |
+
<stop stop-color="#ACC0BE" />
|
108 |
+
<stop offset="1" stop-color="#8BAAA7" />
|
109 |
+
</linearGradient>
|
110 |
+
<linearGradient id="d" x1="94.5" x2="276" y1="12" y2="386.5" gradientUnits="userSpaceOnUse">
|
111 |
+
<stop stop-color="#F2B445" />
|
112 |
+
<stop offset="1" stop-color="#BD6D18" />
|
113 |
+
</linearGradient>
|
114 |
+
<linearGradient id="f" x1="357.5" x2="69.5" y1="335" y2="146.5" gradientUnits="userSpaceOnUse">
|
115 |
+
<stop stop-color="#6A807A" />
|
116 |
+
<stop offset="1" stop-color="#6A807A" stop-opacity="0" />
|
117 |
+
</linearGradient>
|
118 |
+
</defs>
|
119 |
+
</svg>
|
frontend/src/lib/badges/fifty.svelte
ADDED
@@ -0,0 +1,106 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<script lang="ts">
|
2 |
+
export let classNames = '';
|
3 |
+
</script>
|
4 |
+
|
5 |
+
<svg
|
6 |
+
xmlns="http://www.w3.org/2000/svg"
|
7 |
+
fill="none"
|
8 |
+
viewBox="0 0 385 450"
|
9 |
+
width="385"
|
10 |
+
height="450"
|
11 |
+
class={classNames}
|
12 |
+
>
|
13 |
+
<path
|
14 |
+
fill="#3F7B73"
|
15 |
+
d="M372.7 107.8 201.9 7.6a25 25 0 0 0-25.7.2L12 107.7A25 25 0 0 0 0 129v194.2a25 25 0 0 0 12.2 21.5l164.2 97.7a25 25 0 0 0 25.3.2l170.7-98A25 25 0 0 0 385 323V129.3a25 25 0 0 0-12.3-21.5Z"
|
16 |
+
/>
|
17 |
+
<mask
|
18 |
+
id="a"
|
19 |
+
width="385"
|
20 |
+
height="443"
|
21 |
+
x="0"
|
22 |
+
y="4"
|
23 |
+
maskUnits="userSpaceOnUse"
|
24 |
+
style="mask-type:alpha"
|
25 |
+
>
|
26 |
+
<path
|
27 |
+
fill="#D3720A"
|
28 |
+
d="M372.7 107.8 201.9 7.6a25 25 0 0 0-25.7.2L12 107.7A25 25 0 0 0 0 129v194.2a25 25 0 0 0 12.2 21.5l164.2 97.7a25 25 0 0 0 25.3.2l170.7-98A25 25 0 0 0 385 323V129.3a25 25 0 0 0-12.3-21.5Z"
|
29 |
+
/>
|
30 |
+
</mask>
|
31 |
+
<g mask="url(#a)">
|
32 |
+
<path
|
33 |
+
fill="#468A7D"
|
34 |
+
d="M177.5 322c-25 59-49.7 120.7-138.5 83s-182.7-151-157.6-210c25.1-59.1 116.3-93.2 205.1-55.5s116 123.4 91 182.5Z"
|
35 |
+
/>
|
36 |
+
<path
|
37 |
+
fill="#184F4F"
|
38 |
+
d="M9 328.5c-9-17-15-206-15-206L-14.5 357 190 486l202-133V126.5s-7.5 187.5-15 202c-3.5 6.8-39.3 28.2-78 52-43.2 26.6-90.5 55.5-109 55.5-18.2 0-63-26.6-104-52.5-37.9-23.9-72.7-46.8-77-55Z"
|
39 |
+
/>
|
40 |
+
<path
|
41 |
+
fill="#F5FFFF"
|
42 |
+
d="M166 379h48c-9.3 31-9.3 47.8 0 77h-48c8.3-30 7.2-47 0-77Zm165-78.8 30-23.2c8.1 32.4 18.3 45.8 47.1 61l-30 23.2c-4.2-35-15.9-47.2-47.1-61Z"
|
43 |
+
opacity=".3"
|
44 |
+
/>
|
45 |
+
<path
|
46 |
+
fill="#C89435"
|
47 |
+
d="M330 111.8 342.6 76c25.7 20.2 41.6 26 72.7 25.6l-12.7 35.8c-24.7-20.3-41-25-72.6-25.6Z"
|
48 |
+
opacity=".3"
|
49 |
+
/>
|
50 |
+
<path
|
51 |
+
fill="#F5FFFF"
|
52 |
+
d="m22 273 29 24.7c-29.7 14.9-40.7 27.7-50 58.6l-29-24.7c30.4-13.8 40.9-27 50-58.6Z"
|
53 |
+
opacity=".3"
|
54 |
+
/>
|
55 |
+
</g>
|
56 |
+
<path
|
57 |
+
fill="#80EBE2"
|
58 |
+
d="m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v174.5a25 25 0 0 0 12.2 21.5l147.6 87.7a25 25 0 0 0 25.2.2l153.4-88A25 25 0 0 0 368 293V119.1a25 25 0 0 0-12.4-21.6Z"
|
59 |
+
/>
|
60 |
+
<mask
|
61 |
+
id="b"
|
62 |
+
width="375"
|
63 |
+
height="428"
|
64 |
+
x="4"
|
65 |
+
y="4"
|
66 |
+
maskUnits="userSpaceOnUse"
|
67 |
+
style="mask-type:alpha"
|
68 |
+
>
|
69 |
+
<path
|
70 |
+
fill="#C4D6D6"
|
71 |
+
d="m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v184l-.1.4L4 326.5l12.5-17.7a1 1 0 0 1 1.3-.3L186 408l2.5 22.2c.1 1.2 1.9 1.2 2 0L193 408l171.7-98.5a1 1 0 0 1 1.3.3l13 19.2-10.9-22.3a1 1 0 0 1-.1-.4V119a25 25 0 0 0-12.4-21.6Z"
|
72 |
+
/>
|
73 |
+
</mask>
|
74 |
+
<g mask="url(#b)">
|
75 |
+
<path
|
76 |
+
fill="url(#c)"
|
77 |
+
d="M235.2 360.7c46.5-71.6-249.6-263-249.6-263L-40 122s211.6 114.9 176.5 163.3c-35 48.4-217-78.3-217-78.3L-52 325.7s240.7 106.5 287.3 35Z"
|
78 |
+
opacity=".7"
|
79 |
+
/>
|
80 |
+
<path fill="#ECFFFD" d="M246-47h177L226 459H49L246-47Z" opacity=".6" />
|
81 |
+
<path fill="#ECFFFD" d="M441.5-49H457L278.5 421H263L441.5-49Z" opacity=".8" />
|
82 |
+
<path
|
83 |
+
fill="#F5FFFF"
|
84 |
+
d="M359.5 120c9.5 27 0 162.5 10 162.5S388 99 388 99L193-27 9 82.5s-6 202.5 3.5 203 8-162 16-175 120-111 161-92S350 93 359.5 120Z"
|
85 |
+
/>
|
86 |
+
<path
|
87 |
+
fill="#E9FFFF"
|
88 |
+
d="M21.5 296c-14-17-8-34-8-38l-24 59 195 126 201-111.5L372 246s-7.5 39.5-15.5 52.5-124 113-165 94-156-79.5-170-96.5Z"
|
89 |
+
opacity=".7"
|
90 |
+
/>
|
91 |
+
</g>
|
92 |
+
<path
|
93 |
+
fill="#34776E"
|
94 |
+
d="M192.6 299.8a5 5 0 0 1-.5 2.1 34.5 34.5 0 0 1-30.6 19.1h-52.6a34.5 34.5 0 0 1-30.8-19c-.4-.6-.5-1.4-.5-2v-78a5 5 0 0 1 5-5h38.8a5 5 0 0 1 5 5v42a5 5 0 0 0 5 5h7.4a5 5 0 0 0 5-5v-59a5 5 0 0 0-5-5H82.6a5 5 0 0 1-5-5V53a5 5 0 0 1 5-5h97.7a5 5 0 0 1 5 5v37.9a5 5 0 0 1-5 5h-48.9a5 5 0 0 0-5 5v42a5 5 0 0 0 5 5h30c6.9 0 13.1 1.9 18.7 5.6a33 33 0 0 1 12 13.6c.3.6.5 1.3.5 2v130.7Zm126.4 0a4 4 0 0 1-.6 2.1c-2.8 5.5-6.9 10-12.1 13.6a32.3 32.3 0 0 1-18.7 5.5h-52.5a33 33 0 0 1-18.8-5.5c-5.2-3.6-9.2-8-11.9-13.6-.3-.6-.4-1.4-.4-2V65.4c0-.7.1-1.4.4-2 3.2-6.6 8-11.5 14.3-15a6 6 0 0 1 2.3-.5h80.7a6 6 0 0 1 2.3.5 34 34 0 0 1 14.5 14.9c.3.7.4 1.4.4 2.1v234.3ZM265 269a5 5 0 0 0 5-5V101a5 5 0 0 0-5-5h-7.3a5 5 0 0 0-5 5v163a5 5 0 0 0 5 5h7.3Z"
|
95 |
+
/>
|
96 |
+
<path
|
97 |
+
fill="#fff"
|
98 |
+
d="M192.6 287.8c0 .7-.2 1.4-.5 2a34.5 34.5 0 0 1-30.6 19.2h-52.6a34.5 34.5 0 0 1-30.8-19.1 4 4 0 0 1-.5-2.1V210a5 5 0 0 1 5-5h38.8a5 5 0 0 1 5 5v42a5 5 0 0 0 5 5h7.4a5 5 0 0 0 5-5v-59.1a5 5 0 0 0-5-5H82.6a5 5 0 0 1-5-5v-142a5 5 0 0 1 5-5h97.7a5 5 0 0 1 5 5v38a5 5 0 0 1-5 5h-48.9a5 5 0 0 0-5 5v42a5 5 0 0 0 5 5h30a33 33 0 0 1 18.7 5.5 33 33 0 0 1 12 13.6c.3.6.5 1.3.5 2v130.8Zm126.4-.1c0 .8-.2 1.5-.6 2.2-2.8 5.5-6.9 10-12.1 13.5a32.3 32.3 0 0 1-18.7 5.6h-52.5a34.4 34.4 0 0 1-30.7-19.1c-.3-.7-.4-1.4-.4-2.1V53.4c0-.7.1-1.4.4-2 3.2-6.5 8-11.5 14.3-14.9.7-.4 1.5-.5 2.3-.5h80.7c.8 0 1.6.1 2.3.5a34 34 0 0 1 14.5 14.8c.3.7.4 1.4.4 2.2v234.2ZM265 257a5 5 0 0 0 5-5V88.9a5 5 0 0 0-5-5h-7.3a5 5 0 0 0-5 5V252a5 5 0 0 0 5 5h7.3Z"
|
99 |
+
/>
|
100 |
+
<defs>
|
101 |
+
<linearGradient id="c" x1="242" x2="-4.5" y1="378" y2="154" gradientUnits="userSpaceOnUse">
|
102 |
+
<stop stop-color="#3F866C" />
|
103 |
+
<stop offset="1" stop-color="#48967A" stop-opacity="0" />
|
104 |
+
</linearGradient>
|
105 |
+
</defs>
|
106 |
+
</svg>
|
frontend/src/lib/badges/five.svelte
ADDED
@@ -0,0 +1,120 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<script lang="ts">
|
2 |
+
export let classNames = '';
|
3 |
+
</script>
|
4 |
+
|
5 |
+
<svg
|
6 |
+
xmlns="http://www.w3.org/2000/svg"
|
7 |
+
xmlns:xlink="http://www.w3.org/1999/xlink"
|
8 |
+
fill="none"
|
9 |
+
viewBox="0 0 385 450"
|
10 |
+
width="385"
|
11 |
+
height="450"
|
12 |
+
class={classNames}
|
13 |
+
>
|
14 |
+
<defs>
|
15 |
+
<path
|
16 |
+
id="a"
|
17 |
+
fill="#7A3A0C"
|
18 |
+
d="M372.7 107.8 201.9 7.6a25 25 0 0 0-25.7.2L12 107.7A25 25 0 0 0 0 129v194.2a25 25 0 0 0 12.2 21.5l164.2 97.7a25 25 0 0 0 25.3.2l170.7-98A25 25 0 0 0 385 323V129.3a25 25 0 0 0-12.3-21.5Z"
|
19 |
+
/>
|
20 |
+
</defs>
|
21 |
+
<use xlink:href="#a" />
|
22 |
+
<mask
|
23 |
+
id="b"
|
24 |
+
width="385"
|
25 |
+
height="443"
|
26 |
+
x="0"
|
27 |
+
y="4"
|
28 |
+
maskUnits="userSpaceOnUse"
|
29 |
+
style="mask-type:alpha"
|
30 |
+
>
|
31 |
+
<use xlink:href="#a" />
|
32 |
+
</mask>
|
33 |
+
<g mask="url(#b)">
|
34 |
+
<path
|
35 |
+
fill="#592805"
|
36 |
+
d="M9 328.5c-9-17-15-206-15-206L-14.5 357 190 486l202-133V126.5s-7.5 187.5-15 202c-3.5 6.8-39.3 28.2-78 52-43.2 26.6-90.5 55.5-109 55.5-18.2 0-63-26.6-104-52.5-37.9-23.9-72.7-46.8-77-55Z"
|
37 |
+
/>
|
38 |
+
<path
|
39 |
+
fill="#C89435"
|
40 |
+
d="M166 379h48c-9.3 31-9.3 47.8 0 77h-48c8.3-30 7.2-47 0-77Zm165-78.8 30-23.2c8.1 32.4 18.3 45.8 47.1 61l-30 23.2c-4.2-35-15.9-47.2-47.1-61Z"
|
41 |
+
opacity=".2"
|
42 |
+
/>
|
43 |
+
<path
|
44 |
+
fill="#C89435"
|
45 |
+
d="M330 111.8 342.6 76c25.7 20.2 41.6 26 72.7 25.6l-12.7 35.8c-24.7-20.3-41-25-72.6-25.6Z"
|
46 |
+
opacity=".3"
|
47 |
+
/>
|
48 |
+
<path
|
49 |
+
fill="#C89435"
|
50 |
+
d="m22 273 29 24.7c-29.7 14.9-40.7 27.7-50 58.6l-29-24.7c30.4-13.8 40.9-27 50-58.6Z"
|
51 |
+
opacity=".2"
|
52 |
+
/>
|
53 |
+
</g>
|
54 |
+
<path
|
55 |
+
fill="url(#c)"
|
56 |
+
d="m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v174.5a25 25 0 0 0 12.2 21.5l147.6 87.7a25 25 0 0 0 25.2.2l153.4-88A25 25 0 0 0 368 293V119.1a25 25 0 0 0-12.4-21.6Z"
|
57 |
+
/>
|
58 |
+
<mask
|
59 |
+
id="e"
|
60 |
+
width="351"
|
61 |
+
height="403"
|
62 |
+
x="17"
|
63 |
+
y="4"
|
64 |
+
maskUnits="userSpaceOnUse"
|
65 |
+
style="mask-type:alpha"
|
66 |
+
>
|
67 |
+
<path
|
68 |
+
fill="url(#d)"
|
69 |
+
d="m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v174.5a25 25 0 0 0 12.2 21.5l147.6 87.7a25 25 0 0 0 25.2.2l153.4-88A25 25 0 0 0 368 293V119.1a25 25 0 0 0-12.4-21.6Z"
|
70 |
+
/>
|
71 |
+
</mask>
|
72 |
+
<g mask="url(#e)">
|
73 |
+
<path
|
74 |
+
fill="url(#f)"
|
75 |
+
d="M389.2 334.7c46.5-71.6-249.6-263-249.6-263L114 96s211.6 114.9 176.5 163.3c-35 48.4-217-78.3-217-78.3L102 299.7s240.7 106.5 287.3 35Z"
|
76 |
+
opacity=".7"
|
77 |
+
/>
|
78 |
+
<path fill="#FFD893" d="M157-47h177L137 459H-40L157-47Z" opacity=".8" />
|
79 |
+
<path fill="#F9CB80" d="M352.5-49H368L189.5 421H174L352.5-49Z" />
|
80 |
+
<path
|
81 |
+
fill="#FFE9C2"
|
82 |
+
d="M360.5 111c14 17 8 34 8 38L389 95 194-31 10 78.5V161s7.5-39.5 15.5-52.5 124-113 165-94 156 79.5 170 96.5Z"
|
83 |
+
/>
|
84 |
+
<path
|
85 |
+
fill="#FFE0A9"
|
86 |
+
d="M21.5 299c-14-17-8-34-8-38L-7 315l195 126 184-109.5V249s-7.5 39.5-15.5 52.5-124 113-165 94-156-79.5-170-96.5Z"
|
87 |
+
opacity=".7"
|
88 |
+
/>
|
89 |
+
</g>
|
90 |
+
<path
|
91 |
+
fill="#7A3A0C"
|
92 |
+
d="M254.6 304.6c0 1-.2 1.8-.6 2.5a34.5 34.5 0 0 1-30.5 19h-52.6a34.5 34.5 0 0 1-30.7-19c-.4-.7-.6-1.6-.6-2.5v-76.5a6 6 0 0 1 6-6h36.8a6 6 0 0 1 6 6v40a6 6 0 0 0 6 6h5.4a6 6 0 0 0 6-6v-57.2a6 6 0 0 0-6-6h-54.2a6 6 0 0 1-6-6V59a6 6 0 0 1 6-6h95.7a6 6 0 0 1 6 6v36a6 6 0 0 1-6 6h-46.9a6 6 0 0 0-6 6v40a6 6 0 0 0 6 6h29a33 33 0 0 1 18.7 5.5 33 33 0 0 1 12 13.4c.3.8.5 1.6.5 2.5v130.2Z"
|
93 |
+
/>
|
94 |
+
<path fill="#8A4C15" d="M175 310h35v16h-35z" />
|
95 |
+
<path
|
96 |
+
fill="#FFF2DC"
|
97 |
+
d="M254.6 288.6c0 .9-.2 1.7-.6 2.5a34.5 34.5 0 0 1-30.5 19h-52.6a34.5 34.5 0 0 1-30.7-19c-.4-.8-.6-1.6-.6-2.5V212a6 6 0 0 1 6-6h36.8a6 6 0 0 1 6 6v40a6 6 0 0 0 6 6h5.4a6 6 0 0 0 6-6v-57a6 6 0 0 0-6-6h-54.2a6 6 0 0 1-6-6V43a6 6 0 0 1 6-6h95.7a6 6 0 0 1 6 6v35.9a6 6 0 0 1-6 6h-46.9a6 6 0 0 0-6 6v40a6 6 0 0 0 6 6h29c6.9 0 13.1 1.9 18.7 5.6a33 33 0 0 1 12 13.4c.3.7.5 1.6.5 2.4v130.3Z"
|
98 |
+
/>
|
99 |
+
<defs>
|
100 |
+
<linearGradient id="c" x1="140.5" x2="219" y1="0" y2="410" gradientUnits="userSpaceOnUse">
|
101 |
+
<stop stop-color="#F2B445" />
|
102 |
+
<stop offset="1" stop-color="#D7882F" />
|
103 |
+
</linearGradient>
|
104 |
+
<linearGradient id="d" x1="94.5" x2="276" y1="12" y2="386.5" gradientUnits="userSpaceOnUse">
|
105 |
+
<stop stop-color="#F2B445" />
|
106 |
+
<stop offset="1" stop-color="#BD6D18" />
|
107 |
+
</linearGradient>
|
108 |
+
<linearGradient
|
109 |
+
id="f"
|
110 |
+
x1="373.6"
|
111 |
+
x2="182.8"
|
112 |
+
y1="370.3"
|
113 |
+
y2="128.4"
|
114 |
+
gradientUnits="userSpaceOnUse"
|
115 |
+
>
|
116 |
+
<stop stop-color="#B05C13" />
|
117 |
+
<stop offset="1" stop-color="#B05C13" stop-opacity="0" />
|
118 |
+
</linearGradient>
|
119 |
+
</defs>
|
120 |
+
</svg>
|
frontend/src/lib/badges/ten.svelte
ADDED
@@ -0,0 +1,115 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<script lang="ts">
|
2 |
+
export let classNames = '';
|
3 |
+
</script>
|
4 |
+
|
5 |
+
<svg
|
6 |
+
xmlns="http://www.w3.org/2000/svg"
|
7 |
+
xmlns:xlink="http://www.w3.org/1999/xlink"
|
8 |
+
fill="none"
|
9 |
+
viewBox="0 0 385 450"
|
10 |
+
width="385"
|
11 |
+
height="450"
|
12 |
+
class={classNames}
|
13 |
+
>
|
14 |
+
<defs>
|
15 |
+
<path
|
16 |
+
id="a"
|
17 |
+
fill="#777A6F"
|
18 |
+
d="M372.7 107.8 201.9 7.6a25 25 0 0 0-25.7.2L12 107.7A25 25 0 0 0 0 129v194.2a25 25 0 0 0 12.2 21.5l164.2 97.7a25 25 0 0 0 25.3.2l170.7-98A25 25 0 0 0 385 323V129.3a25 25 0 0 0-12.3-21.5Z"
|
19 |
+
/>
|
20 |
+
</defs>
|
21 |
+
<use xlink:href="#a" />
|
22 |
+
<mask
|
23 |
+
id="b"
|
24 |
+
width="385"
|
25 |
+
height="443"
|
26 |
+
x="0"
|
27 |
+
y="4"
|
28 |
+
maskUnits="userSpaceOnUse"
|
29 |
+
style="mask-type:alpha"
|
30 |
+
>
|
31 |
+
<use xlink:href="#a" />
|
32 |
+
</mask>
|
33 |
+
<g mask="url(#b)">
|
34 |
+
<path
|
35 |
+
fill="#4E4F51"
|
36 |
+
d="M9 328.5c-9-17-15-206-15-206L-14.5 357 190 486l202-133V126.5s-7.5 187.5-15 202c-3.5 6.8-39.3 28.2-78 52-43.2 26.6-90.5 55.5-109 55.5-18.2 0-63-26.6-104-52.5-37.9-23.9-72.7-46.8-77-55Z"
|
37 |
+
/>
|
38 |
+
<path
|
39 |
+
fill="#CCDDE2"
|
40 |
+
d="M166 379h48c-9.3 31-9.3 47.8 0 77h-48c8.3-30 7.2-47 0-77Zm165-78.8 30-23.2c8.1 32.4 18.3 45.8 47.1 61l-30 23.2c-4.2-35-15.9-47.2-47.1-61Z"
|
41 |
+
opacity=".2"
|
42 |
+
/>
|
43 |
+
<path
|
44 |
+
fill="#C89435"
|
45 |
+
d="M330 111.8 342.6 76c25.7 20.2 41.6 26 72.7 25.6l-12.7 35.8c-24.7-20.3-41-25-72.6-25.6Z"
|
46 |
+
opacity=".3"
|
47 |
+
/>
|
48 |
+
<path
|
49 |
+
fill="#CCDDE2"
|
50 |
+
d="m22 273 29 24.7c-29.7 14.9-40.7 27.7-50 58.6l-29-24.7c30.4-13.8 40.9-27 50-58.6Z"
|
51 |
+
opacity=".2"
|
52 |
+
/>
|
53 |
+
</g>
|
54 |
+
<path
|
55 |
+
fill="url(#c)"
|
56 |
+
d="m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v174.5a25 25 0 0 0 12.2 21.5l147.6 87.7a25 25 0 0 0 25.2.2l153.4-88A25 25 0 0 0 368 293V119.1a25 25 0 0 0-12.4-21.6Z"
|
57 |
+
/>
|
58 |
+
<mask
|
59 |
+
id="e"
|
60 |
+
width="351"
|
61 |
+
height="403"
|
62 |
+
x="17"
|
63 |
+
y="4"
|
64 |
+
maskUnits="userSpaceOnUse"
|
65 |
+
style="mask-type:alpha"
|
66 |
+
>
|
67 |
+
<path
|
68 |
+
fill="url(#d)"
|
69 |
+
d="m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v174.5a25 25 0 0 0 12.2 21.5l147.6 87.7a25 25 0 0 0 25.2.2l153.4-88A25 25 0 0 0 368 293V119.1a25 25 0 0 0-12.4-21.6Z"
|
70 |
+
/>
|
71 |
+
</mask>
|
72 |
+
<g mask="url(#e)">
|
73 |
+
<path
|
74 |
+
fill="url(#f)"
|
75 |
+
d="M394.2 346.7c46.5-71.6-249.6-263-249.6-263L119 108s211.6 114.9 176.5 163.3c-35 48.4-217-78.3-217-78.3L107 311.7s240.7 106.5 287.3 35Z"
|
76 |
+
opacity=".4"
|
77 |
+
/>
|
78 |
+
<path
|
79 |
+
fill="#D9E8EF"
|
80 |
+
d="M157-47h177L137 459H-40L157-47Zm195.5-2H368L189.5 421H174L352.5-49Z"
|
81 |
+
opacity=".8"
|
82 |
+
/>
|
83 |
+
<path
|
84 |
+
fill="#ECF8FF"
|
85 |
+
d="M360.5 111c14 17 8 34 8 38L389 95 194-31 10 78.5V161s7.5-39.5 15.5-52.5 124-113 165-94 156 79.5 170 96.5Z"
|
86 |
+
/>
|
87 |
+
<path
|
88 |
+
fill="#DBEAF2"
|
89 |
+
d="M21.5 299c-14-17-8-34-8-38L-7 315l195 126 184-109.5V249s-7.5 39.5-15.5 52.5-124 113-165 94-156-79.5-170-96.5Z"
|
90 |
+
opacity=".7"
|
91 |
+
/>
|
92 |
+
</g>
|
93 |
+
<path
|
94 |
+
fill="#777A6F"
|
95 |
+
d="M109 325a5 5 0 0 1-5-5V57a5 5 0 0 1 5-5h41.8a5 5 0 0 1 5 5v263a5 5 0 0 1-5 5H109Zm173-21.2a5 5 0 0 1-.5 2.1c-2.9 5.5-7 10-12.2 13.6a32.3 32.3 0 0 1-18.6 5.5H198a33.2 33.2 0 0 1-30.6-19.1c-.4-.6-.5-1.4-.5-2V69.4c0-.7.1-1.4.5-2 3.2-6.6 8-11.5 14.3-15 .7-.3 1.4-.5 2.2-.5h80.8c.8 0 1.5.2 2.2.5a34 34 0 0 1 14.5 14.9c.3.7.5 1.4.5 2.1v234.3ZM228.2 273a5 5 0 0 0 5-5V105a5 5 0 0 0-5-5h-7.4a5 5 0 0 0-5 5v163a5 5 0 0 0 5 5h7.4Z"
|
96 |
+
/>
|
97 |
+
<path
|
98 |
+
fill="#fff"
|
99 |
+
d="M109 310a5 5 0 0 1-5-5V42a5 5 0 0 1 5-5h41.8a5 5 0 0 1 5 5v263a5 5 0 0 1-5 5H109Zm173-21.2a5 5 0 0 1-.5 2.1c-2.9 5.5-7 10-12.2 13.6a32.3 32.3 0 0 1-18.6 5.5H198a33.2 33.2 0 0 1-30.6-19.1c-.4-.6-.5-1.4-.5-2V54.4c0-.7.1-1.4.5-2 3.2-6.6 8-11.5 14.3-15 .7-.3 1.4-.5 2.2-.5h80.8c.8 0 1.5.2 2.2.5a34 34 0 0 1 14.5 14.9c.3.7.5 1.4.5 2.1v234.3ZM228.2 258a5 5 0 0 0 5-5V90a5 5 0 0 0-5-5h-7.4a5 5 0 0 0-5 5v163a5 5 0 0 0 5 5h7.4Z"
|
100 |
+
/>
|
101 |
+
<defs>
|
102 |
+
<linearGradient id="c" x1="103" x2="192.5" y1="13" y2="410" gradientUnits="userSpaceOnUse">
|
103 |
+
<stop stop-color="#ACC0BE" />
|
104 |
+
<stop offset="1" stop-color="#8BAAA7" />
|
105 |
+
</linearGradient>
|
106 |
+
<linearGradient id="d" x1="94.5" x2="276" y1="12" y2="386.5" gradientUnits="userSpaceOnUse">
|
107 |
+
<stop stop-color="#F2B445" />
|
108 |
+
<stop offset="1" stop-color="#BD6D18" />
|
109 |
+
</linearGradient>
|
110 |
+
<linearGradient id="f" x1="357.5" x2="69.5" y1="335" y2="146.5" gradientUnits="userSpaceOnUse">
|
111 |
+
<stop stop-color="#6A807A" />
|
112 |
+
<stop offset="1" stop-color="#6A807A" stop-opacity="0" />
|
113 |
+
</linearGradient>
|
114 |
+
</defs>
|
115 |
+
</svg>
|
frontend/src/lib/badges/thirtyfive.svelte
ADDED
@@ -0,0 +1,109 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<script lang="ts">
|
2 |
+
export let classNames = '';
|
3 |
+
</script>
|
4 |
+
|
5 |
+
<svg
|
6 |
+
xmlns="http://www.w3.org/2000/svg"
|
7 |
+
fill="none"
|
8 |
+
viewBox="0 0 385 450"
|
9 |
+
width="385"
|
10 |
+
height="450"
|
11 |
+
class={classNames}
|
12 |
+
>
|
13 |
+
<path
|
14 |
+
fill="#D9800D"
|
15 |
+
d="M372.7 107.8 201.9 7.6a25 25 0 0 0-25.7.2L12 107.7A25 25 0 0 0 0 129v194.2a25 25 0 0 0 12.2 21.5l164.2 97.7a25 25 0 0 0 25.3.2l170.7-98A25 25 0 0 0 385 323V129.3a25 25 0 0 0-12.3-21.5Z"
|
16 |
+
/>
|
17 |
+
<mask
|
18 |
+
id="a"
|
19 |
+
width="385"
|
20 |
+
height="443"
|
21 |
+
x="0"
|
22 |
+
y="4"
|
23 |
+
maskUnits="userSpaceOnUse"
|
24 |
+
style="mask-type:alpha"
|
25 |
+
>
|
26 |
+
<path
|
27 |
+
fill="#D3720A"
|
28 |
+
d="M372.7 107.8 201.9 7.6a25 25 0 0 0-25.7.2L12 107.7A25 25 0 0 0 0 129v194.2a25 25 0 0 0 12.2 21.5l164.2 97.7a25 25 0 0 0 25.3.2l170.7-98A25 25 0 0 0 385 323V129.3a25 25 0 0 0-12.3-21.5Z"
|
29 |
+
/>
|
30 |
+
</mask>
|
31 |
+
<g mask="url(#a)">
|
32 |
+
<path
|
33 |
+
fill="#B87711"
|
34 |
+
d="M164.6 311.8c-25.1 59-49.7 120.7-138.5 83s-182.7-151-157.6-210c25-59.1 116.3-93.2 205-55.5 88.9 37.7 116.2 123.4 91 182.5Z"
|
35 |
+
/>
|
36 |
+
<path
|
37 |
+
fill="#7C4D16"
|
38 |
+
d="M9 328.5c-9-17-15-206-15-206L-14.5 357 190 486l202-133V126.5s-7.5 187.5-15 202c-3.5 6.8-39.3 28.2-78 52-43.2 26.6-90.5 55.5-109 55.5-18.2 0-63-26.6-104-52.5-37.9-23.9-72.7-46.8-77-55Z"
|
39 |
+
/>
|
40 |
+
<path
|
41 |
+
fill="#F5DD21"
|
42 |
+
d="M166 379h48c-9.3 31-9.3 47.8 0 77h-48c8.3-30 7.2-47 0-77Zm165-78.8 30-23.2c8.1 32.4 18.3 45.8 47.1 61l-30 23.2c-4.2-35-15.9-47.2-47.1-61Z"
|
43 |
+
opacity=".3"
|
44 |
+
/>
|
45 |
+
<path
|
46 |
+
fill="#C89435"
|
47 |
+
d="M330 111.8 342.6 76c25.7 20.2 41.6 26 72.7 25.6l-12.7 35.8c-24.7-20.3-41-25-72.6-25.6Z"
|
48 |
+
opacity=".3"
|
49 |
+
/>
|
50 |
+
<path
|
51 |
+
fill="#F5DD21"
|
52 |
+
d="m22 273 29 24.7c-29.7 14.9-40.7 27.7-50 58.6l-29-24.7c30.4-13.8 40.9-27 50-58.6Z"
|
53 |
+
opacity=".3"
|
54 |
+
/>
|
55 |
+
</g>
|
56 |
+
<path
|
57 |
+
fill="url(#b)"
|
58 |
+
d="m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v174.5a25 25 0 0 0 12.2 21.5l147.6 87.7a25 25 0 0 0 25.2.2l153.4-88A25 25 0 0 0 368 293V119.1a25 25 0 0 0-12.4-21.6Z"
|
59 |
+
/>
|
60 |
+
<mask
|
61 |
+
id="c"
|
62 |
+
width="351"
|
63 |
+
height="403"
|
64 |
+
x="17"
|
65 |
+
y="4"
|
66 |
+
maskUnits="userSpaceOnUse"
|
67 |
+
style="mask-type:alpha"
|
68 |
+
>
|
69 |
+
<path
|
70 |
+
fill="#FBEC17"
|
71 |
+
d="m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v174.5a25 25 0 0 0 12.2 21.5l147.6 87.7a25 25 0 0 0 25.2.2l153.4-88A25 25 0 0 0 368 293V119.1a25 25 0 0 0-12.4-21.6Z"
|
72 |
+
/>
|
73 |
+
</mask>
|
74 |
+
<g mask="url(#c)">
|
75 |
+
<path
|
76 |
+
fill="url(#d)"
|
77 |
+
d="M197.2 341.7c46.5-71.6-249.6-263-249.6-263L-78 103S133.6 217.9 98.5 266.3c-35 48.4-217-78.3-217-78.3L-90 306.7s240.7 106.5 287.3 35Z"
|
78 |
+
opacity=".7"
|
79 |
+
/>
|
80 |
+
<path fill="#FFFA86" d="M259-47h177L239 459H62L259-47Z" opacity=".6" />
|
81 |
+
<path fill="#FFFA86" d="M454.5-49H470L291.5 421H276L454.5-49Z" opacity=".8" />
|
82 |
+
<path
|
83 |
+
fill="#FFFCE6"
|
84 |
+
d="M359.5 115c14 17 8 34 8 38L388 99 193-27 9 82.5V165s7.5-39.5 15.5-52.5 124-113 165-94 156 79.5 170 96.5Z"
|
85 |
+
/>
|
86 |
+
<path
|
87 |
+
fill="#FFFAD5"
|
88 |
+
d="M21.5 296c-14-17-8-34-8-38L-7 312l195 126 184-109.5V246s-7.5 39.5-15.5 52.5-124 113-165 94-156-79.5-170-96.5Z"
|
89 |
+
/>
|
90 |
+
</g>
|
91 |
+
<path
|
92 |
+
fill="#D9800D"
|
93 |
+
d="M187 167.4a33 33 0 0 1-8.6 11.4 32 32 0 0 1 8.6 11.6v115.5a34.5 34.5 0 0 1-31.1 20.1h-52.6A34.5 34.5 0 0 1 72 306v-81.2h48.8V274h17.4v-69H107v-52h31.2v-52h-17.4v32H72V69.3c3.4-7 8.4-12.5 15.3-16.2h84.4c6.8 3.7 12 9.1 15.3 16.2v98.2ZM313.4 306a34.5 34.5 0 0 1-31.2 20h-52.5a34.5 34.5 0 0 1-31.3-20.1V222h48.8v52h17.3v-69h-66.1V53H306v47.9h-59v52h35.1c6.9 0 13 1.9 18.7 5.6a33 33 0 0 1 12.5 14.5v133Z"
|
94 |
+
/>
|
95 |
+
<path
|
96 |
+
fill="#fff"
|
97 |
+
d="M187 150.4a33 33 0 0 1-8.6 11.4 32 32 0 0 1 8.6 11.6v115.5a34.5 34.5 0 0 1-31.1 20.1h-52.6A34.5 34.5 0 0 1 72 289v-81.2h48.8V257h17.4v-69H107v-52h31.2V84h-17.4v32H72V52.3c3.4-7 8.4-12.5 15.3-16.2h84.4c6.8 3.7 12 9.1 15.3 16.2v98.2ZM313.4 289a34.5 34.5 0 0 1-31.2 20h-52.5a34.5 34.5 0 0 1-31.3-20.1V205h48.8v52h17.3v-69h-66.1V36H306v47.9h-59v52h35.1c6.9 0 13 1.9 18.7 5.6a33 33 0 0 1 12.5 14.5v133Z"
|
98 |
+
/>
|
99 |
+
<defs>
|
100 |
+
<linearGradient id="b" x1="147" x2="201.5" y1="0" y2="418.5" gradientUnits="userSpaceOnUse">
|
101 |
+
<stop stop-color="#F8EF0A" />
|
102 |
+
<stop offset="1" stop-color="#F5BE1B" />
|
103 |
+
</linearGradient>
|
104 |
+
<linearGradient id="d" x1="111" x2="-21" y1="357.5" y2="126" gradientUnits="userSpaceOnUse">
|
105 |
+
<stop stop-color="#FE9C15" />
|
106 |
+
<stop offset="1" stop-color="#FE9C15" stop-opacity="0" />
|
107 |
+
</linearGradient>
|
108 |
+
</defs>
|
109 |
+
</svg>
|
frontend/src/lib/badges/twenty.svelte
ADDED
@@ -0,0 +1,109 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<script lang="ts">
|
2 |
+
export let classNames = '';
|
3 |
+
</script>
|
4 |
+
|
5 |
+
<svg
|
6 |
+
xmlns="http://www.w3.org/2000/svg"
|
7 |
+
fill="none"
|
8 |
+
viewBox="0 0 385 450"
|
9 |
+
width="385"
|
10 |
+
height="450"
|
11 |
+
class={classNames}
|
12 |
+
>
|
13 |
+
<path
|
14 |
+
fill="#D9800D"
|
15 |
+
d="M372.7 107.8 201.9 7.6a25 25 0 0 0-25.7.2L12 107.7A25 25 0 0 0 0 129v194.2a25 25 0 0 0 12.2 21.5l164.2 97.7a25 25 0 0 0 25.3.2l170.7-98A25 25 0 0 0 385 323V129.3a25 25 0 0 0-12.3-21.5Z"
|
16 |
+
/>
|
17 |
+
<mask
|
18 |
+
id="a"
|
19 |
+
width="385"
|
20 |
+
height="443"
|
21 |
+
x="0"
|
22 |
+
y="4"
|
23 |
+
maskUnits="userSpaceOnUse"
|
24 |
+
style="mask-type:alpha"
|
25 |
+
>
|
26 |
+
<path
|
27 |
+
fill="#D3720A"
|
28 |
+
d="M372.7 107.8 201.9 7.6a25 25 0 0 0-25.7.2L12 107.7A25 25 0 0 0 0 129v194.2a25 25 0 0 0 12.2 21.5l164.2 97.7a25 25 0 0 0 25.3.2l170.7-98A25 25 0 0 0 385 323V129.3a25 25 0 0 0-12.3-21.5Z"
|
29 |
+
/>
|
30 |
+
</mask>
|
31 |
+
<g mask="url(#a)">
|
32 |
+
<path
|
33 |
+
fill="#B87711"
|
34 |
+
d="M164.6 311.8c-25.1 59-49.7 120.7-138.5 83s-182.7-151-157.6-210c25-59.1 116.3-93.2 205-55.5 88.9 37.7 116.2 123.4 91 182.5Z"
|
35 |
+
/>
|
36 |
+
<path
|
37 |
+
fill="#7C4D16"
|
38 |
+
d="M9 328.5c-9-17-15-206-15-206L-14.5 357 190 486l202-133V126.5s-7.5 187.5-15 202c-3.5 6.8-39.3 28.2-78 52-43.2 26.6-90.5 55.5-109 55.5-18.2 0-63-26.6-104-52.5-37.9-23.9-72.7-46.8-77-55Z"
|
39 |
+
/>
|
40 |
+
<path
|
41 |
+
fill="#F5DD21"
|
42 |
+
d="M166 379h48c-9.3 31-9.3 47.8 0 77h-48c8.3-30 7.2-47 0-77Zm165-78.8 30-23.2c8.1 32.4 18.3 45.8 47.1 61l-30 23.2c-4.2-35-15.9-47.2-47.1-61Z"
|
43 |
+
opacity=".3"
|
44 |
+
/>
|
45 |
+
<path
|
46 |
+
fill="#C89435"
|
47 |
+
d="M330 111.8 342.6 76c25.7 20.2 41.6 26 72.7 25.6l-12.7 35.8c-24.7-20.3-41-25-72.6-25.6Z"
|
48 |
+
opacity=".3"
|
49 |
+
/>
|
50 |
+
<path
|
51 |
+
fill="#F5DD21"
|
52 |
+
d="m22 273 29 24.7c-29.7 14.9-40.7 27.7-50 58.6l-29-24.7c30.4-13.8 40.9-27 50-58.6Z"
|
53 |
+
opacity=".3"
|
54 |
+
/>
|
55 |
+
</g>
|
56 |
+
<path
|
57 |
+
fill="url(#b)"
|
58 |
+
d="m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v174.5a25 25 0 0 0 12.2 21.5l147.6 87.7a25 25 0 0 0 25.2.2l153.4-88A25 25 0 0 0 368 293V119.1a25 25 0 0 0-12.4-21.6Z"
|
59 |
+
/>
|
60 |
+
<mask
|
61 |
+
id="c"
|
62 |
+
width="351"
|
63 |
+
height="403"
|
64 |
+
x="17"
|
65 |
+
y="4"
|
66 |
+
maskUnits="userSpaceOnUse"
|
67 |
+
style="mask-type:alpha"
|
68 |
+
>
|
69 |
+
<path
|
70 |
+
fill="#FBEC17"
|
71 |
+
d="m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v174.5a25 25 0 0 0 12.2 21.5l147.6 87.7a25 25 0 0 0 25.2.2l153.4-88A25 25 0 0 0 368 293V119.1a25 25 0 0 0-12.4-21.6Z"
|
72 |
+
/>
|
73 |
+
</mask>
|
74 |
+
<g mask="url(#c)">
|
75 |
+
<path
|
76 |
+
fill="url(#d)"
|
77 |
+
d="M197.2 341.7c46.5-71.6-249.6-263-249.6-263L-78 103S133.6 217.9 98.5 266.3c-35 48.4-217-78.3-217-78.3L-90 306.7s240.7 106.5 287.3 35Z"
|
78 |
+
opacity=".7"
|
79 |
+
/>
|
80 |
+
<path fill="#FFFA86" d="M259-47h177L239 459H62L259-47Z" opacity=".6" />
|
81 |
+
<path fill="#FFFA86" d="M454.5-49H470L291.5 421H276L454.5-49Z" opacity=".8" />
|
82 |
+
<path
|
83 |
+
fill="#FFFCE6"
|
84 |
+
d="M359.5 115c14 17 8 34 8 38L388 99 193-27 9 82.5V165s7.5-39.5 15.5-52.5 124-113 165-94 156 79.5 170 96.5Z"
|
85 |
+
/>
|
86 |
+
<path
|
87 |
+
fill="#FFFAD5"
|
88 |
+
d="M21.5 296c-14-17-8-34-8-38L-7 312l195 126 184-109.5V246s-7.5 39.5-15.5 52.5-124 113-165 94-156-79.5-170-96.5Z"
|
89 |
+
/>
|
90 |
+
</g>
|
91 |
+
<path
|
92 |
+
fill="#D9800D"
|
93 |
+
d="M187 74.3a5 5 0 0 0-.5-2.1 34.2 34.2 0 0 0-12.2-13.6 32.3 32.3 0 0 0-18.6-5.6H103a34 34 0 0 0-30.6 19.2c-.4.6-.5 1.3-.5 2V152a5 5 0 0 0 5 5h38.8a5 5 0 0 0 5-5v-42a5 5 0 0 1 5-5h7.4a5 5 0 0 1 5 5v59.3a5 5 0 0 1-5 5h-30a33.6 33.6 0 0 0-30.7 19.1c-.3.7-.5 1.4-.5 2.1v113.4c0 .7.1 1.4.5 2a33 33 0 0 0 13.7 14.7c.7.4 1.5.6 2.3.6H182a5 5 0 0 0 5-5v-72.6a5 5 0 0 0-5-5h-38.8a5 5 0 0 0-5 5V273a5 5 0 0 1-5 5h-7.4a5 5 0 0 1-5-5v-41.8a5 5 0 0 1 5-5h29.9c7 0 13.2-1.9 18.6-5.6a36 36 0 0 0 12.2-13.5c.3-.7.5-1.4.5-2.2V74.3Zm126.4 230.5c0 .8-.2 1.5-.5 2.2-2.9 5.5-7 10-12.2 13.5a32.3 32.3 0 0 1-18.7 5.6h-52.5c-7 0-13.2-1.9-18.8-5.6-5.2-3.5-9.1-8-11.9-13.6-.3-.6-.4-1.3-.4-2V70.5c0-.7.1-1.4.4-2 3.2-6.5 8-11.5 14.4-15a5 5 0 0 1 2.2-.5H296c.8 0 1.6.2 2.3.6a34 34 0 0 1 14.5 14.8c.3.7.5 1.4.5 2.2v234.2Zm-53.9-30.7a5 5 0 0 0 5-5V105.9a5 5 0 0 0-5-5h-7.3a5 5 0 0 0-5 5v163.2a5 5 0 0 0 5 5h7.3Z"
|
94 |
+
/>
|
95 |
+
<path
|
96 |
+
fill="#FFFFEF"
|
97 |
+
d="M187 58.2c0-.7-.2-1.4-.5-2a34.2 34.2 0 0 0-12.2-13.6 32.3 32.3 0 0 0-18.6-5.6H103a33.2 33.2 0 0 0-30.6 19.2c-.4.6-.5 1.3-.5 2v77.6a5 5 0 0 0 5 5h38.8a5 5 0 0 0 5-5v-42a5 5 0 0 1 5-5h7.4a5 5 0 0 1 5 5v59.3a5 5 0 0 1-5 5h-30c-7 0-13.3 2-18.9 5.6-5.2 3.6-9.1 8-11.8 13.6-.3.6-.5 1.3-.5 2v113.4c0 .8.1 1.5.5 2.1 3 6.2 7.6 11.1 13.7 14.6.7.4 1.5.6 2.3.6H182a5 5 0 0 0 5-5v-72.5a5 5 0 0 0-5-5h-38.8a5 5 0 0 0-5 5V257a5 5 0 0 1-5 5h-7.4a5 5 0 0 1-5-5v-42a5 5 0 0 1 5-5h29.9a32 32 0 0 0 18.6-5.5c5.3-3.6 9.3-8 12.2-13.6a5 5 0 0 0 .5-2.1V58.2Zm126.4 230.6a5 5 0 0 1-.5 2.1c-2.9 5.5-7 10-12.2 13.6A32.3 32.3 0 0 1 282 310h-52.5a33.2 33.2 0 0 1-30.7-19.1c-.3-.6-.4-1.4-.4-2V54.4c0-.7.1-1.4.4-2 3.2-6.6 8-11.5 14.4-15a5 5 0 0 1 2.2-.5H296a6 6 0 0 1 2.3.5 34 34 0 0 1 14.5 14.9c.3.7.5 1.4.5 2.1v234.3ZM259.5 258a5 5 0 0 0 5-5V90a5 5 0 0 0-5-5h-7.3a5 5 0 0 0-5 5v163a5 5 0 0 0 5 5h7.3Z"
|
98 |
+
/>
|
99 |
+
<defs>
|
100 |
+
<linearGradient id="b" x1="147" x2="201.5" y1="0" y2="418.5" gradientUnits="userSpaceOnUse">
|
101 |
+
<stop stop-color="#F8EF0A" />
|
102 |
+
<stop offset="1" stop-color="#F5BE1B" />
|
103 |
+
</linearGradient>
|
104 |
+
<linearGradient id="d" x1="111" x2="-21" y1="357.5" y2="126" gradientUnits="userSpaceOnUse">
|
105 |
+
<stop stop-color="#FE9C15" />
|
106 |
+
<stop offset="1" stop-color="#FE9C15" stop-opacity="0" />
|
107 |
+
</linearGradient>
|
108 |
+
</defs>
|
109 |
+
</svg>
|
frontend/src/lib/badges/two.svelte
ADDED
@@ -0,0 +1,84 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<script lang="ts">
|
2 |
+
export let classNames = '';
|
3 |
+
</script>
|
4 |
+
|
5 |
+
<svg
|
6 |
+
xmlns="http://www.w3.org/2000/svg"
|
7 |
+
xmlns:xlink="http://www.w3.org/1999/xlink"
|
8 |
+
fill="none"
|
9 |
+
viewBox="0 0 385 450"
|
10 |
+
width="385"
|
11 |
+
height="450"
|
12 |
+
class={classNames}
|
13 |
+
>
|
14 |
+
<defs>
|
15 |
+
<path
|
16 |
+
id="a"
|
17 |
+
fill="#6A2B16"
|
18 |
+
d="M372.7 107.8 201.9 7.6a25 25 0 0 0-25.7.2L12 107.7A25 25 0 0 0 0 129v194.2a25 25 0 0 0 12.2 21.5l164.2 97.7a25 25 0 0 0 25.3.2l170.7-98A25 25 0 0 0 385 323V129.3a25 25 0 0 0-12.3-21.5Z"
|
19 |
+
/>
|
20 |
+
</defs>
|
21 |
+
<use xlink:href="#a" />
|
22 |
+
<mask
|
23 |
+
id="b"
|
24 |
+
width="385"
|
25 |
+
height="443"
|
26 |
+
x="0"
|
27 |
+
y="4"
|
28 |
+
maskUnits="userSpaceOnUse"
|
29 |
+
style="mask-type:alpha"
|
30 |
+
>
|
31 |
+
<use xlink:href="#a" />
|
32 |
+
</mask>
|
33 |
+
<g fill="#4D1D0D" mask="url(#b)">
|
34 |
+
<path
|
35 |
+
d="m-5.5 196 23-34.5L19 196l-23 25-1.5-25Zm394 111.5-21-18-3.5 11 23 25 1.5-18Zm0-60.5c7 0-21-25.5-21-25.5L364 240l23 25s-5.5-18 1.5-18Zm-1.5-71.5-19.5-24-25 14.5 24.5-4.5 19.5 20 .5-6Zm-1.5-59.1c6.7-2.3-28.2-17.1-28.2-17.1l2.8 18.6c18.4 7.4 23.7 10.7 30 16 0 0-11.2-15.1-4.6-17.5ZM-5 279.5c12.8-8 16.3-17.7 23-34.5l-1 14S5 285.5-4 281.5s-1-2-1-2Zm4 61c8-4 14.5-19 23-34.5l4 3.5c-15 18.5-9.5 24-19 40l-8-9Zm240 85c-17 2-12-18-20.5-33.5l-6.5 2.5c15 18.5-7 29.5 2.5 45.5l24.5-14.5Zm-205-62c3-22.5 14.5-19 23-34.5l17.5 11c-15 18.5-30 9-32.5 32.5l-8-9Zm72 41c-1-45.5-4.5-47.5 9-53.5l28.5 3c-8.2 7.6-17 8-24.5 11.5-4 5-8 23-8 39.5l-5-.5Zm177.5-49c6 14-14 38.1 0 49l-7.3 6.5c-15.9-17.8 7-39.5 1.3-52l6-3.5Z"
|
36 |
+
/>
|
37 |
+
</g>
|
38 |
+
<path
|
39 |
+
fill="url(#c)"
|
40 |
+
d="m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v174.5a25 25 0 0 0 12.2 21.5l66.4 39.5a25 25 0 0 0 16.2 3.3l29.7-4c1.2-.2 1.6 1.4.5 1.8l-22.3 9.5a2 2 0 0 0-.3 3.5l57.4 34.1a25 25 0 0 0 25.2.2l153.4-88A25 25 0 0 0 368 293V162.8a2 2 0 0 0-2.3-2l-16 2.6c-1 .2-1.5-1.4-.5-1.9l17.1-8.2a3 3 0 0 0 1.7-2.7v-31.5a25 25 0 0 0-12.4-21.6Z"
|
41 |
+
/>
|
42 |
+
<g opacity=".3" style="mix-blend-mode:multiply">
|
43 |
+
<mask
|
44 |
+
id="d"
|
45 |
+
width="351"
|
46 |
+
height="403"
|
47 |
+
x="17"
|
48 |
+
y="4"
|
49 |
+
maskUnits="userSpaceOnUse"
|
50 |
+
style="mask-type:alpha"
|
51 |
+
>
|
52 |
+
<path
|
53 |
+
fill="#C46545"
|
54 |
+
d="m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v174.5a25 25 0 0 0 12.2 21.5l147.6 87.7a25 25 0 0 0 25.2.2l153.4-88A25 25 0 0 0 368 293V119.1a25 25 0 0 0-12.4-21.6Z"
|
55 |
+
/>
|
56 |
+
</mask>
|
57 |
+
<g fill="#B66D40" mask="url(#d)">
|
58 |
+
<path
|
59 |
+
d="M399.5 80.5C266 122 87.5 50.5-19 203.5l8 12.5C166.5 93.5 301.8 111.5 399.5 80.5ZM269 32c-112 7-91.5-18-161.5-18L82 32c44.6 12.4 72.4 18.8 198 12.5L269 32Zm-68 125.5c-84.9 24.9-129.3 43-193 96l-10 21c74.6-60.5 118.5-88 203-117ZM64.2 276c-19.7 4.6-62.4 50.4-62.4 50.4C37 299.6 88 279 91.8 293.7c3.8 14.7-32.9 37.8-38.7 37.6C36.4 331 3.7 339 3.7 339s51.7 2.5 59.6 5.1c15.1 4.8 45.4-48.5 65-62.9-1.7-6.5-44.5-9.7-64.1-5.2ZM301 134.5c20.8-4.2 63.1-21 70.5-31.5l5 14.5c-27.2 13.8-44.5 15-75.5 17Zm-177.5 106C242 205.5 306.4 209.2 395 227l-4 27.5c-27.5-19.5-149-38.7-267.5-14Zm98.5 40.2c55.8-4.4 146.7 11.7 152 30.1l10.7-14.6c-51-22.6-87.8-24-162.7-15.5Zm55 88.3c27-39.5-8.5-61.5-106.5-21 67-14 114-18.5 106.5 21Zm-63.3 36c16.4-20.4-5.2-31.8-64.7-10.9 40.7-7.2 69.2-9.5 64.7 10.9Z"
|
60 |
+
/>
|
61 |
+
</g>
|
62 |
+
</g>
|
63 |
+
<path
|
64 |
+
fill="#98492E"
|
65 |
+
d="M249 68.5c0-1-.2-1.8-.6-2.6-2.8-5.5-6.9-10-12-13.3a32.3 32.3 0 0 0-18.7-5.6H165a34 34 0 0 0-30.6 19c-.3.7-.5 1.6-.5 2.4v76.4a6 6 0 0 0 6 6h36.8a6 6 0 0 0 6-6v-40a6 6 0 0 1 6-6h5.4a6 6 0 0 1 6 6v57.3a6 6 0 0 1-6 6h-29c-7 0-13.3 2-18.9 5.6a35 35 0 0 0-11.7 13.4c-.4.8-.6 1.6-.6 2.5v113c0 .8.2 1.6.6 2.4 3 6 7.5 10.8 13.4 14.3.8.5 1.8.7 2.8.7H243a6 6 0 0 0 6-6v-70.5a6 6 0 0 0-6-6h-36.8a6 6 0 0 0-6 6V266a6 6 0 0 1-6 6h-5.4a6 6 0 0 1-6-6v-40a6 6 0 0 1 6-6h28.9a32 32 0 0 0 18.6-5.5c5.2-3.5 9.2-8 12-13.4.5-.8.7-1.6.7-2.5V68.5Z"
|
66 |
+
/>
|
67 |
+
<path
|
68 |
+
fill="#FFD193"
|
69 |
+
d="M249 58.5c0-1-.2-1.8-.6-2.6-2.8-5.5-6.9-10-12-13.3a32.3 32.3 0 0 0-18.7-5.6H165a34 34 0 0 0-30.6 19c-.3.7-.5 1.6-.5 2.4v76.4a6 6 0 0 0 6 6h36.8a6 6 0 0 0 6-6v-40a6 6 0 0 1 6-6h5.4a6 6 0 0 1 6 6v57.3a6 6 0 0 1-6 6h-29c-7 0-13.3 2-18.9 5.6a35 35 0 0 0-11.7 13.4c-.4.8-.6 1.6-.6 2.5v113c0 .8.2 1.6.6 2.4 3 6 7.5 10.8 13.4 14.3.8.5 1.8.7 2.8.7H243a6 6 0 0 0 6-6v-70.5a6 6 0 0 0-6-6h-36.8a6 6 0 0 0-6 6V256a6 6 0 0 1-6 6h-5.4a6 6 0 0 1-6-6v-40a6 6 0 0 1 6-6h28.9a32 32 0 0 0 18.6-5.5c5.2-3.5 9.2-8 12-13.4.5-.8.7-1.6.7-2.5V58.5Z"
|
70 |
+
/>
|
71 |
+
<defs>
|
72 |
+
<linearGradient
|
73 |
+
id="c"
|
74 |
+
x1="107.5"
|
75 |
+
x2="208.5"
|
76 |
+
y1="-13.5"
|
77 |
+
y2="446.5"
|
78 |
+
gradientUnits="userSpaceOnUse"
|
79 |
+
>
|
80 |
+
<stop stop-color="#EEB657" />
|
81 |
+
<stop offset="1" stop-color="#B65841" />
|
82 |
+
</linearGradient>
|
83 |
+
</defs>
|
84 |
+
</svg>
|
frontend/src/lib/store.ts
ADDED
@@ -0,0 +1,26 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
import { browser } from '$app/env';
|
2 |
+
import { writable } from 'svelte/store';
|
3 |
+
import type { User, SuccessPrompt } from '../types';
|
4 |
+
import { nanoid } from 'nanoid';
|
5 |
+
|
6 |
+
const initialUser: User = nanoid();
|
7 |
+
const intialCompletedPrompts: SuccessPrompt[] = [];
|
8 |
+
|
9 |
+
export const currentUser = writable<User>(
|
10 |
+
browser ? JSON.parse(localStorage['user'] || JSON.stringify(initialUser)) : initialUser
|
11 |
+
);
|
12 |
+
currentUser.subscribe((value) => {
|
13 |
+
if (browser) {
|
14 |
+
return (localStorage['user'] = JSON.stringify(value));
|
15 |
+
}
|
16 |
+
});
|
17 |
+
export const completedPromptsStore = writable<SuccessPrompt[]>(
|
18 |
+
browser
|
19 |
+
? JSON.parse(localStorage['completedPrompts'] || JSON.stringify(intialCompletedPrompts))
|
20 |
+
: intialCompletedPrompts
|
21 |
+
);
|
22 |
+
completedPromptsStore.subscribe((value) => {
|
23 |
+
if (browser) {
|
24 |
+
return (localStorage['completedPrompts'] = JSON.stringify(value));
|
25 |
+
}
|
26 |
+
});
|
frontend/src/lib/utils.ts
ADDED
@@ -0,0 +1,57 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
// original code inspired by Evan You https://github.com/yyx990803/vue-wordle/
|
2 |
+
import { LetterState } from '../types';
|
3 |
+
import type { Board, BadgeComponent } from '../types';
|
4 |
+
|
5 |
+
export function clearTile(board: Board, currentRowIndex: number) {
|
6 |
+
const newBoard = [...board];
|
7 |
+
const currentRow = newBoard[currentRowIndex];
|
8 |
+
for (const tile of [...currentRow].reverse()) {
|
9 |
+
if (tile.letter) {
|
10 |
+
tile.letter = '';
|
11 |
+
break;
|
12 |
+
}
|
13 |
+
}
|
14 |
+
return newBoard;
|
15 |
+
}
|
16 |
+
|
17 |
+
export function fillTile(board: Board, currentRowIndex: number, letter: string) {
|
18 |
+
const newBoard = [...board];
|
19 |
+
const currentRow = newBoard[currentRowIndex];
|
20 |
+
for (const tile of currentRow) {
|
21 |
+
if (tile.correct === ' ') {
|
22 |
+
tile.letter = ' ';
|
23 |
+
}
|
24 |
+
if (!tile.letter) {
|
25 |
+
tile.letter = letter;
|
26 |
+
break;
|
27 |
+
}
|
28 |
+
}
|
29 |
+
return newBoard;
|
30 |
+
}
|
31 |
+
|
32 |
+
export const colors = {
|
33 |
+
[LetterState.CORRECT]: '#00b81a',
|
34 |
+
[LetterState.PRESENT]: '#ffc80a',
|
35 |
+
[LetterState.ABSENT]: '#d9d9d9',
|
36 |
+
[LetterState.INITIAL]: '#5d5d5d'
|
37 |
+
};
|
38 |
+
|
39 |
+
export const badgesComponents: BadgeComponent = {
|
40 |
+
2: 'two',
|
41 |
+
5: 'five',
|
42 |
+
10: 'ten',
|
43 |
+
15: 'fifteen',
|
44 |
+
20: 'twenty',
|
45 |
+
35: 'thirtyfive',
|
46 |
+
50: 'fifty'
|
47 |
+
};
|
48 |
+
|
49 |
+
export const cheersMessages = [
|
50 |
+
'🤗 Hugging 🤗',
|
51 |
+
'🧞 Genius 🧞',
|
52 |
+
'🤩 Magnificent 🤩',
|
53 |
+
'😲 Impressive 😲',
|
54 |
+
'🧚 Splendid 🧚',
|
55 |
+
'✳ Great ✳',
|
56 |
+
'🍡 Phew 🍡'
|
57 |
+
];
|
frontend/src/routes/__layout.svelte
ADDED
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<script>
|
2 |
+
import "../app.css";
|
3 |
+
</script>
|
4 |
+
|
5 |
+
<slot />
|
frontend/src/routes/index.svelte
ADDED
@@ -0,0 +1,503 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<script lang="ts">
|
2 |
+
// original code inspired by Evan You https://github.com/yyx990803/vue-wordle/
|
3 |
+
import { LetterState, GameState } from '../types';
|
4 |
+
import type { Board, PromptsData, SuccessPrompt, Tile } from '../types';
|
5 |
+
import { clearTile, fillTile } from '$lib/utils';
|
6 |
+
|
7 |
+
import Keyboard from '$lib/Keyboard.svelte';
|
8 |
+
import Result from '$lib/Result.svelte';
|
9 |
+
import Message from '$lib/Message.svelte';
|
10 |
+
import { currentUser, completedPromptsStore } from '$lib/store';
|
11 |
+
|
12 |
+
import { onMount, onDestroy } from 'svelte';
|
13 |
+
import { browser, dev } from '$app/env';
|
14 |
+
import { base } from '$app/paths';
|
15 |
+
|
16 |
+
const totalTime = 1000;
|
17 |
+
const apiUrl = dev ? 'http://localhost:7860/' : '';
|
18 |
+
let allowShare = true;
|
19 |
+
let promptsData: PromptsData;
|
20 |
+
let completedPrompts: SuccessPrompt[] = [];
|
21 |
+
let currPromptIndex: number;
|
22 |
+
onMount(async () => {
|
23 |
+
onResize();
|
24 |
+
promptsData = await fetch(apiUrl + 'data').then((d) => d.json());
|
25 |
+
|
26 |
+
completedPrompts = $completedPromptsStore;
|
27 |
+
if (completedPrompts.length >= Object.keys(promptsData).length) {
|
28 |
+
gameState = GameState.COMPLETED;
|
29 |
+
}
|
30 |
+
|
31 |
+
console.log('Current User Data:', $currentUser);
|
32 |
+
console.log('Completed Prompts:', $completedPromptsStore);
|
33 |
+
|
34 |
+
restartBoard();
|
35 |
+
window.addEventListener('keyup', onKeyup, true);
|
36 |
+
window.addEventListener('resize', onResize);
|
37 |
+
window.focus();
|
38 |
+
document.body.addEventListener('click', () => window.focus(), false);
|
39 |
+
// update completed prompts with local storage data
|
40 |
+
});
|
41 |
+
|
42 |
+
function onResize() {
|
43 |
+
document.body.style.setProperty('--vh', window.innerHeight + 'px');
|
44 |
+
}
|
45 |
+
|
46 |
+
onDestroy(() => {
|
47 |
+
if (browser) {
|
48 |
+
window.removeEventListener('keyup', onKeyup, true);
|
49 |
+
}
|
50 |
+
});
|
51 |
+
|
52 |
+
// Get word of the day
|
53 |
+
let answer: string;
|
54 |
+
let imagePaths: string[];
|
55 |
+
let cols: number;
|
56 |
+
let timePerTile: number;
|
57 |
+
|
58 |
+
let letterStates: Record<string, LetterState> = {};
|
59 |
+
|
60 |
+
let board: Board;
|
61 |
+
// Current active row.
|
62 |
+
let currentRowIndex = 0;
|
63 |
+
|
64 |
+
// Feedback state: message and shake
|
65 |
+
let message = '';
|
66 |
+
let shakeRowIndex = -1;
|
67 |
+
let gameState: GameState = GameState.LOADING;
|
68 |
+
// Handle keyboard input.
|
69 |
+
let allowInput = true;
|
70 |
+
|
71 |
+
function restartBoard() {
|
72 |
+
//reset all states
|
73 |
+
shakeRowIndex = -1;
|
74 |
+
message = '';
|
75 |
+
currentRowIndex = 0;
|
76 |
+
letterStates = {};
|
77 |
+
allowInput = true;
|
78 |
+
|
79 |
+
const prompts: string[] = Object.keys(promptsData);
|
80 |
+
|
81 |
+
if (completedPrompts.length >= prompts.length || gameState === GameState.COMPLETED) {
|
82 |
+
showMessage("You've completed all prompts. Please come back later for more!", -1);
|
83 |
+
gameState = GameState.COMPLETED;
|
84 |
+
allowInput = false;
|
85 |
+
completedPrompts = [];
|
86 |
+
} else {
|
87 |
+
gameState = GameState.PLAYING;
|
88 |
+
}
|
89 |
+
|
90 |
+
const idsToRemove = completedPrompts.map((e) => e.idx);
|
91 |
+
const promptsFiltered = prompts.filter((_, i) => !idsToRemove.includes(i));
|
92 |
+
const radomPromptId = ~~(Math.random() * promptsFiltered.length);
|
93 |
+
const randomPrompt: string = promptsFiltered[radomPromptId];
|
94 |
+
currPromptIndex = prompts.indexOf(randomPrompt);
|
95 |
+
|
96 |
+
answer = randomPrompt.replace(/_/g, ' ');
|
97 |
+
imagePaths = promptsData[randomPrompt].slice(0, 6);
|
98 |
+
const clue = [...answer].map((a) => (Math.random() > 0.5 ? '*' : a)).join('');
|
99 |
+
console.log('%cCLUE: ', 'color: red;font-weight:bold', clue);
|
100 |
+
// console.log(answer);
|
101 |
+
cols = answer.length;
|
102 |
+
timePerTile = totalTime / cols;
|
103 |
+
|
104 |
+
board = Array.from({ length: 7 }, () =>
|
105 |
+
Array.from(answer).map((l) => ({
|
106 |
+
letter: '',
|
107 |
+
correct: l,
|
108 |
+
state: LetterState.INITIAL
|
109 |
+
}))
|
110 |
+
);
|
111 |
+
document.body.style.setProperty('--cols', `${cols}`);
|
112 |
+
}
|
113 |
+
|
114 |
+
const onKeyup = (e: KeyboardEvent) => {
|
115 |
+
onKey(e.key);
|
116 |
+
};
|
117 |
+
|
118 |
+
function onKey(key: string) {
|
119 |
+
if (!allowInput) return;
|
120 |
+
if (/^[a-zA-Z]$/.test(key)) {
|
121 |
+
board = fillTile(board, currentRowIndex, key.toLowerCase());
|
122 |
+
} else if (key === 'Backspace') {
|
123 |
+
board = clearTile(board, currentRowIndex);
|
124 |
+
} else if (key === 'Enter') {
|
125 |
+
completeRow();
|
126 |
+
}
|
127 |
+
}
|
128 |
+
|
129 |
+
function completeRow() {
|
130 |
+
const newBoard = [...board];
|
131 |
+
const currentRow = newBoard[currentRowIndex];
|
132 |
+
const currentletterStates = { ...letterStates };
|
133 |
+
|
134 |
+
if (currentRow.every((tile) => tile.letter)) {
|
135 |
+
const guess = currentRow.map((tile) => tile.letter).join('');
|
136 |
+
// if (!allWords.includes(guess) && guess !== answer) {
|
137 |
+
// shake()
|
138 |
+
// showMessage(`Not in word list`)
|
139 |
+
// return
|
140 |
+
// }
|
141 |
+
if (allowShare) {
|
142 |
+
postProcess(currentRow);
|
143 |
+
}
|
144 |
+
|
145 |
+
const answerLetters: (string | null)[] = answer.split('');
|
146 |
+
// first pass: mark correct ones
|
147 |
+
currentRow.forEach((tile, i) => {
|
148 |
+
if (answerLetters[i] === tile.letter) {
|
149 |
+
tile.state = currentletterStates[tile.letter] = LetterState.CORRECT;
|
150 |
+
answerLetters[i] = null;
|
151 |
+
}
|
152 |
+
});
|
153 |
+
|
154 |
+
// second pass: mark the present
|
155 |
+
currentRow.forEach((tile) => {
|
156 |
+
if (!tile.state && answerLetters.includes(tile.letter)) {
|
157 |
+
tile.state = LetterState.PRESENT;
|
158 |
+
answerLetters[answerLetters.indexOf(tile.letter)] = null;
|
159 |
+
if (!currentletterStates[tile.letter]) {
|
160 |
+
currentletterStates[tile.letter] = LetterState.PRESENT;
|
161 |
+
}
|
162 |
+
}
|
163 |
+
});
|
164 |
+
// 3rd pass: mark absent
|
165 |
+
currentRow.forEach((tile) => {
|
166 |
+
if (!tile.state) {
|
167 |
+
tile.state = LetterState.ABSENT;
|
168 |
+
if (!currentletterStates[tile.letter]) {
|
169 |
+
currentletterStates[tile.letter] = LetterState.ABSENT;
|
170 |
+
}
|
171 |
+
}
|
172 |
+
});
|
173 |
+
|
174 |
+
allowInput = false;
|
175 |
+
if (currentRow.every((tile) => tile.state === LetterState.CORRECT)) {
|
176 |
+
// yay!
|
177 |
+
completedPrompts = [...completedPrompts, { prompt: answer, idx: currPromptIndex }];
|
178 |
+
$completedPromptsStore = completedPrompts;
|
179 |
+
|
180 |
+
setTimeout(() => {
|
181 |
+
gameState = GameState.SUCESS;
|
182 |
+
}, totalTime);
|
183 |
+
} else if (currentRowIndex < board.length - 1) {
|
184 |
+
// go the next row
|
185 |
+
currentRowIndex++;
|
186 |
+
setTimeout(() => {
|
187 |
+
allowInput = true;
|
188 |
+
}, totalTime);
|
189 |
+
} else {
|
190 |
+
// game over :(
|
191 |
+
gameState = GameState.FAIL;
|
192 |
+
setTimeout(() => {
|
193 |
+
showMessage(answer.toUpperCase(), -1);
|
194 |
+
}, totalTime);
|
195 |
+
}
|
196 |
+
} else {
|
197 |
+
shake();
|
198 |
+
showMessage('Not enough letters');
|
199 |
+
}
|
200 |
+
|
201 |
+
board = newBoard;
|
202 |
+
letterStates = currentletterStates;
|
203 |
+
}
|
204 |
+
function showMessage(msg: string, time = 1000) {
|
205 |
+
message = msg;
|
206 |
+
if (time > 0) {
|
207 |
+
setTimeout(() => {
|
208 |
+
message = '';
|
209 |
+
}, time);
|
210 |
+
}
|
211 |
+
}
|
212 |
+
|
213 |
+
function shake() {
|
214 |
+
shakeRowIndex = currentRowIndex;
|
215 |
+
setTimeout(() => {
|
216 |
+
shakeRowIndex = -1;
|
217 |
+
}, 1000);
|
218 |
+
}
|
219 |
+
async function postProcess(currentRow: Tile[]) {
|
220 |
+
const guess = currentRow.map((tile) => tile.letter).join('');
|
221 |
+
const correct = currentRow.map((tile) => tile.correct).join('');
|
222 |
+
fetch(apiUrl + 'prompt', {
|
223 |
+
method: 'POST',
|
224 |
+
headers: {
|
225 |
+
'Content-Type': 'application/json'
|
226 |
+
},
|
227 |
+
body: JSON.stringify({
|
228 |
+
guess: guess,
|
229 |
+
correct: correct
|
230 |
+
})
|
231 |
+
});
|
232 |
+
}
|
233 |
+
</script>
|
234 |
+
|
235 |
+
{#if board !== undefined}
|
236 |
+
<div class="max-w-screen-lg mx-auto px-1 relative z-0 mt-3">
|
237 |
+
{#if message}
|
238 |
+
<Message {message} {gameState} on:restart={restartBoard} />
|
239 |
+
{/if}
|
240 |
+
{#if gameState === GameState.SUCESS}
|
241 |
+
<Result
|
242 |
+
{board}
|
243 |
+
{currentRowIndex}
|
244 |
+
{imagePaths}
|
245 |
+
totalStreaks={completedPrompts.length}
|
246 |
+
on:restart={restartBoard}
|
247 |
+
/>
|
248 |
+
{/if}
|
249 |
+
<!-- <div class="message" transition:fade>
|
250 |
+
{message}
|
251 |
+
{#if grid}
|
252 |
+
<pre>{grid}</pre>
|
253 |
+
{/if}
|
254 |
+
</div> -->
|
255 |
+
<!-- {/if} -->
|
256 |
+
<header class="flex justify-between items-center uppercase sm:px-2 text-center">
|
257 |
+
<span class="font-light flex-1 text-xs sm:text-base"> Guess the prompt!</span>
|
258 |
+
<span class="sm:block hidden mx-3 flex-1 border-[0.5px] border-opacity-50 border-gray-400" />
|
259 |
+
<h1 class="text-xl font-bold text-center whitespace-nowrap">🥑 WORDALLE 🥑</h1>
|
260 |
+
<span class="sm:block hidden mx-3 flex-1 border-[0.5px] border-opacity-50 border-gray-400" />
|
261 |
+
<span class="font-light flex-1 text-xs sm:text-base">
|
262 |
+
<button
|
263 |
+
tabindex="-1"
|
264 |
+
on:click={(event) => {
|
265 |
+
restartBoard();
|
266 |
+
event.currentTarget.blur();
|
267 |
+
}}
|
268 |
+
class="hover:no-underline underline underline-offset-2 hover:scale-105 transition-all duration-200 ease-in-out"
|
269 |
+
>Skip to next</button
|
270 |
+
></span
|
271 |
+
>
|
272 |
+
</header>
|
273 |
+
<div class="grid grid-cols-3 gap-2 max-w-md mx-auto p-3">
|
274 |
+
{#each imagePaths as image}
|
275 |
+
<div>
|
276 |
+
<img src={apiUrl + image} alt="" class="aspect-square w-full h-full" />
|
277 |
+
</div>
|
278 |
+
{/each}
|
279 |
+
</div>
|
280 |
+
<div class="board">
|
281 |
+
{#each board as row, index}
|
282 |
+
<div
|
283 |
+
class="row {shakeRowIndex === index && 'shake'} {gameState == GameState.SUCESS &&
|
284 |
+
currentRowIndex === index &&
|
285 |
+
'jump'}"
|
286 |
+
>
|
287 |
+
{#each row as tile, index}
|
288 |
+
<div class="tile {tile.letter && 'filled'} {tile.state && 'revealed'}">
|
289 |
+
<div
|
290 |
+
class="front z-0 {tile.correct === ' ' ? 'space' : ''}"
|
291 |
+
style="transition-delay: {index * timePerTile}ms;"
|
292 |
+
>
|
293 |
+
<span class="letter">{tile.letter}</span>
|
294 |
+
</div>
|
295 |
+
<div
|
296 |
+
class="back z-0 {tile.state}"
|
297 |
+
style="transition-delay: {index * timePerTile}ms; animation-delay: {index * 100}ms;"
|
298 |
+
>
|
299 |
+
{tile.letter}
|
300 |
+
</div>
|
301 |
+
</div>
|
302 |
+
{/each}
|
303 |
+
</div>
|
304 |
+
{/each}
|
305 |
+
</div>
|
306 |
+
<Keyboard on:keyup={({ detail }) => onKey(detail)} bind:letterStates />
|
307 |
+
<footer class="max-w-md mx-auto pt-3">
|
308 |
+
<details class="text-xs my-3">
|
309 |
+
<summary class="cursor-pointer my-2">
|
310 |
+
<span>About</span>
|
311 |
+
</summary>
|
312 |
+
<p>
|
313 |
+
Welcome to Wordalle! The game that marries <a
|
314 |
+
href="https://huggingface.co/spaces/dalle-mini/dalle-mini"
|
315 |
+
target="_blank"
|
316 |
+
rel="noopener noreferrer"
|
317 |
+
class="underline hover:text-blue-500 hover:no-underline"
|
318 |
+
>
|
319 |
+
DALLE mini</a
|
320 |
+
> & Wordle!”
|
321 |
+
</p>
|
322 |
+
<h2 class="font-bold my-2">Instructions</h2>
|
323 |
+
<p>
|
324 |
+
You are given a board with a grid of letters. You must guess the prompt used to generate
|
325 |
+
the images.
|
326 |
+
</p>
|
327 |
+
<p>
|
328 |
+
Your guess must contain the same number of letters as tiles. After you guess, the tiles
|
329 |
+
will be revealed.
|
330 |
+
</p>
|
331 |
+
<h2 class="font-bold my-2">Example</h2>
|
332 |
+
<p class="pb-3">
|
333 |
+
The green tiles are correct letter placements. The yellow tiles are correct letters but in
|
334 |
+
wrong position and the gray tiles are letters not present in the prompt.
|
335 |
+
<img alt="wordalle example for dog eating pastas" src={base + '/img1.jpg'} />
|
336 |
+
<img alt="wordalle example for cat eating noodle " src={base + '/img2.jpg'} />
|
337 |
+
</p>
|
338 |
+
</details>
|
339 |
+
<details class="text-xs my-3">
|
340 |
+
<summary class="cursor-pointer my-2">
|
341 |
+
<span>Disclaimer</span>
|
342 |
+
</summary>
|
343 |
+
<p>
|
344 |
+
This demo collects the guesses to help with a research project. The demo stores no
|
345 |
+
personal data, such as your IP address, email, or account, only your guesses.
|
346 |
+
</p>
|
347 |
+
<label class="py-3 flex">
|
348 |
+
<input type="checkbox" bind:checked={allowShare} />
|
349 |
+
<span class="mx-1">Please uncheck to disable sharing {allowShare}</span>
|
350 |
+
</label>
|
351 |
+
</details>
|
352 |
+
</footer>
|
353 |
+
</div>
|
354 |
+
{/if}
|
355 |
+
|
356 |
+
<style lang="postcss">
|
357 |
+
.board {
|
358 |
+
@apply relative grid gap-1 mx-auto;
|
359 |
+
/* box-sizing: border-box; */
|
360 |
+
--height: min(200px, calc(var(--vh, 100vh) - 350px));
|
361 |
+
height: var(--height);
|
362 |
+
width: min(90vw, calc(var(--height) / 7 * var(--cols)));
|
363 |
+
}
|
364 |
+
.row {
|
365 |
+
@apply relative grid gap-1;
|
366 |
+
grid-template-columns: repeat(var(--cols), 1fr);
|
367 |
+
}
|
368 |
+
|
369 |
+
.tile {
|
370 |
+
@apply z-0 w-full text-base text-center font-bold
|
371 |
+
uppercase select-none relative bg-gray-50 text-black;
|
372 |
+
vertical-align: middle;
|
373 |
+
}
|
374 |
+
|
375 |
+
.tile .filled {
|
376 |
+
animation: zoom 0.2s;
|
377 |
+
}
|
378 |
+
|
379 |
+
.tile .front,
|
380 |
+
.tile .back {
|
381 |
+
@apply z-10 box-border inline-flex justify-center items-center w-full h-full
|
382 |
+
absolute top-0 left-0 transition-transform duration-500;
|
383 |
+
backface-visibility: hidden;
|
384 |
+
-webkit-backface-visibility: hidden;
|
385 |
+
}
|
386 |
+
.tile .letter {
|
387 |
+
@apply flex place-items-center h-full bg-gray-50 z-10;
|
388 |
+
}
|
389 |
+
.tile .space::before {
|
390 |
+
@apply absolute z-0 flex place-items-center text-black opacity-50;
|
391 |
+
content: '•';
|
392 |
+
}
|
393 |
+
|
394 |
+
.tile .front {
|
395 |
+
@apply border-[1.5px] border-solid border-gray-300;
|
396 |
+
}
|
397 |
+
|
398 |
+
.tile.filled .front {
|
399 |
+
@apply border-[1.5px] border-solid border-gray-500;
|
400 |
+
}
|
401 |
+
|
402 |
+
.tile .back {
|
403 |
+
transform: scale(0, 1);
|
404 |
+
}
|
405 |
+
.tile.revealed .front {
|
406 |
+
transform: scale(-1, 1);
|
407 |
+
}
|
408 |
+
.tile.revealed .back {
|
409 |
+
transform: scale(1, 1);
|
410 |
+
}
|
411 |
+
|
412 |
+
@keyframes zoom {
|
413 |
+
0% {
|
414 |
+
transform: scale(1.1);
|
415 |
+
}
|
416 |
+
|
417 |
+
100% {
|
418 |
+
transform: scale(1);
|
419 |
+
}
|
420 |
+
}
|
421 |
+
|
422 |
+
.shake {
|
423 |
+
animation: shake 0.5s;
|
424 |
+
}
|
425 |
+
|
426 |
+
@keyframes shake {
|
427 |
+
0% {
|
428 |
+
transform: translate3d(1px, -1px, 0);
|
429 |
+
}
|
430 |
+
|
431 |
+
10% {
|
432 |
+
transform: translate3d(-2px, 2px, 0);
|
433 |
+
}
|
434 |
+
|
435 |
+
20% {
|
436 |
+
transform: translate3d(2px, -2px, 0);
|
437 |
+
}
|
438 |
+
|
439 |
+
30% {
|
440 |
+
transform: translate3d(-2px, 2px, 0);
|
441 |
+
}
|
442 |
+
|
443 |
+
40% {
|
444 |
+
transform: translate3d(2px, -2px, 0);
|
445 |
+
}
|
446 |
+
|
447 |
+
50% {
|
448 |
+
transform: translate3d(-2px, 2px, 0);
|
449 |
+
}
|
450 |
+
|
451 |
+
60% {
|
452 |
+
transform: translate3d(2px, 2px, 0);
|
453 |
+
}
|
454 |
+
|
455 |
+
70% {
|
456 |
+
transform: translate3d(-2px, -2px, 0);
|
457 |
+
}
|
458 |
+
|
459 |
+
80% {
|
460 |
+
transform: translate3d(2px, 2px, 0);
|
461 |
+
}
|
462 |
+
|
463 |
+
90% {
|
464 |
+
transform: translate3d(-2px, -2px, 0);
|
465 |
+
}
|
466 |
+
|
467 |
+
100% {
|
468 |
+
transform: translate3d(1px, 1px, 0);
|
469 |
+
}
|
470 |
+
}
|
471 |
+
|
472 |
+
.jump .tile .back {
|
473 |
+
animation: jump 0.5s;
|
474 |
+
}
|
475 |
+
|
476 |
+
@keyframes jump {
|
477 |
+
0% {
|
478 |
+
transform: translate3d(0, 0px, 0);
|
479 |
+
}
|
480 |
+
|
481 |
+
20% {
|
482 |
+
transform: translate3d(0, 5px, 0);
|
483 |
+
}
|
484 |
+
|
485 |
+
60% {
|
486 |
+
transform: translate3d(0, -25px, 0);
|
487 |
+
}
|
488 |
+
|
489 |
+
90% {
|
490 |
+
transform: translate3d(0, 3px, 0);
|
491 |
+
}
|
492 |
+
|
493 |
+
100% {
|
494 |
+
transform: translate3d(0, 0px, 0);
|
495 |
+
}
|
496 |
+
}
|
497 |
+
|
498 |
+
@media (max-height: 680px) {
|
499 |
+
.tile {
|
500 |
+
font-size: 1.5vh;
|
501 |
+
}
|
502 |
+
}
|
503 |
+
</style>
|
frontend/src/types.ts
ADDED
@@ -0,0 +1,33 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
export const enum LetterState {
|
2 |
+
INITIAL = '',
|
3 |
+
CORRECT = 'correct',
|
4 |
+
PRESENT = 'present',
|
5 |
+
ABSENT = 'absent'
|
6 |
+
}
|
7 |
+
|
8 |
+
export const enum GameState {
|
9 |
+
LOADING,
|
10 |
+
PLAYING,
|
11 |
+
SUCESS,
|
12 |
+
FAIL,
|
13 |
+
COMPLETED
|
14 |
+
}
|
15 |
+
export interface Tile {
|
16 |
+
letter: string;
|
17 |
+
state: LetterState;
|
18 |
+
correct: string;
|
19 |
+
}
|
20 |
+
export type Board = Tile[][];
|
21 |
+
|
22 |
+
export interface PromptsData {
|
23 |
+
[key: string]: string[];
|
24 |
+
}
|
25 |
+
export interface BadgeComponent {
|
26 |
+
[key: number]: string;
|
27 |
+
}
|
28 |
+
export interface SuccessPrompt {
|
29 |
+
prompt: string;
|
30 |
+
idx: number;
|
31 |
+
}
|
32 |
+
|
33 |
+
export type User = string;
|
frontend/static/img1.jpg
ADDED
![]() |
frontend/static/img2.jpg
ADDED
![]() |
frontend/svelte.config.js
ADDED
@@ -0,0 +1,32 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
import adapter from '@sveltejs/adapter-static';
|
2 |
+
import preprocess from 'svelte-preprocess';
|
3 |
+
|
4 |
+
const dev = process.env.NODE_ENV === 'development';
|
5 |
+
|
6 |
+
console.log('dev', dev);
|
7 |
+
/** @type {import('@sveltejs/kit').Config} */
|
8 |
+
const config = {
|
9 |
+
// Consult https://github.com/sveltejs/svelte-preprocess
|
10 |
+
// for more information about preprocessors
|
11 |
+
preprocess: preprocess({
|
12 |
+
postcss: true
|
13 |
+
}),
|
14 |
+
|
15 |
+
kit: {
|
16 |
+
paths: {
|
17 |
+
base: '/static'
|
18 |
+
},
|
19 |
+
adapter: adapter({
|
20 |
+
pages: 'build',
|
21 |
+
assets: 'build',
|
22 |
+
fallback: null,
|
23 |
+
precompress: false
|
24 |
+
}),
|
25 |
+
|
26 |
+
prerender: {
|
27 |
+
default: true
|
28 |
+
}
|
29 |
+
}
|
30 |
+
};
|
31 |
+
|
32 |
+
export default config;
|
frontend/tailwind.config.cjs
ADDED
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
module.exports = {
|
2 |
+
content: ['./src/**/*.{html,js,svelte,ts}'],
|
3 |
+
theme: {
|
4 |
+
extend: {}
|
5 |
+
},
|
6 |
+
plugins: []
|
7 |
+
};
|
frontend/tsconfig.json
ADDED
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"extends": "./.svelte-kit/tsconfig.json",
|
3 |
+
"compilerOptions": {
|
4 |
+
"allowJs": true,
|
5 |
+
"checkJs": true,
|
6 |
+
"esModuleInterop": true,
|
7 |
+
"forceConsistentCasingInFileNames": true,
|
8 |
+
"resolveJsonModule": true,
|
9 |
+
"skipLibCheck": true,
|
10 |
+
"sourceMap": true,
|
11 |
+
"strict": true
|
12 |
+
}
|
13 |
+
}
|
install-node.sh
ADDED
@@ -0,0 +1,11 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.1/install.sh | bash
|
2 |
+
export NVM_DIR="$([ -z "${XDG_CONFIG_HOME-}" ] && printf %s "${HOME}/.nvm" || printf %s "${XDG_CONFIG_HOME}/nvm")"
|
3 |
+
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"
|
4 |
+
nvm install v18.3.0
|
5 |
+
nvm use v18.3.0
|
6 |
+
node --version
|
7 |
+
npm --version
|
8 |
+
which node
|
9 |
+
which npm
|
10 |
+
command ln -s "$NVM_BIN/node" /home/user/.local/bin/node
|
11 |
+
command ln -s "$NVM_BIN/npm" /home/user/.local/bin/npm
|
main.py
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
import subprocess
|
2 |
+
|
3 |
+
subprocess.run(["make", "build-all"], shell=False)
|
requirements.txt
ADDED
@@ -0,0 +1,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
datasets
|
2 |
+
flask
|
3 |
+
flask_cors
|
4 |
+
requests
|
5 |
+
Pillow
|
6 |
+
scipy
|
7 |
+
gradio==3.0.19
|
8 |
+
Flask-APScheduler
|
static/_app/immutable/assets/pages/__layout.svelte-7926a3a8.css
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji"}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;font-weight:inherit;line-height:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,[type=button],[type=reset],[type=submit]{-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input:-ms-input-placeholder,textarea:-ms-input-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }::-webkit-backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.left-1\/2{left:50%}.top-1\/2{top:50%}.left-0{left:0px}.right-0{right:0px}.top-0{top:0px}.bottom-0{bottom:0px}.z-20{z-index:20}.z-50{z-index:50}.z-10{z-index:10}.z-0{z-index:0}.m-0{margin:0}.m-5{margin:1.25rem}.my-3{margin-top:.75rem;margin-bottom:.75rem}.mx-auto{margin-left:auto;margin-right:auto}.my-1{margin-top:.25rem;margin-bottom:.25rem}.mx-3{margin-left:.75rem;margin-right:.75rem}.my-2{margin-top:.5rem;margin-bottom:.5rem}.mx-1{margin-left:.25rem;margin-right:.25rem}.mt-0{margin-top:0}.mb-2{margin-bottom:.5rem}.mr-1{margin-right:.25rem}.ml-1{margin-left:.25rem}.mt-3{margin-top:.75rem}.box-border{box-sizing:border-box}.flex{display:flex}.inline-flex{display:inline-flex}.grid{display:grid}.hidden{display:none}.aspect-square{aspect-ratio:1 / 1}.h-full{height:100%}.max-h-\[30vh\]{max-height:30vh}.min-h-\[58px\]{min-height:58px}.min-h-screen{min-height:100vh}.w-full{width:100%}.w-screen{width:100vw}.min-w-\[15ch\]{min-width:15ch}.max-w-md{max-width:28rem}.max-w-\[180px\]{max-width:180px}.max-w-screen-lg{max-width:1024px}.flex-1{flex:1 1 0%}.-translate-x-1\/2{--tw-translate-x: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.cursor-pointer{cursor:pointer}.select-none{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.resize{resize:both}.grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.place-content-center{place-content:center}.place-items-center{place-items:center}.items-center{align-items:center}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-2{gap:.5rem}.gap-1{gap:.25rem}.whitespace-nowrap{white-space:nowrap}.rounded-sm{border-radius:.125rem}.rounded-md{border-radius:.375rem}.rounded{border-radius:.25rem}.border-0{border-width:0px}.border-\[0\.5px\]{border-width:.5px}.border-\[1\.5px\]{border-width:1.5px}.border-solid{border-style:solid}.border-gray-400{--tw-border-opacity: 1;border-color:rgb(156 163 175 / var(--tw-border-opacity))}.border-opacity-50{--tw-border-opacity: .5}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity))}.bg-\[\#d3d6da\]{--tw-bg-opacity: 1;background-color:rgb(211 214 218 / var(--tw-bg-opacity))}.bg-black{--tw-bg-opacity: 1;background-color:rgb(0 0 0 / var(--tw-bg-opacity))}.bg-gray-700{--tw-bg-opacity: 1;background-color:rgb(55 65 81 / var(--tw-bg-opacity))}.bg-gray-50{--tw-bg-opacity: 1;background-color:rgb(249 250 251 / var(--tw-bg-opacity))}.bg-opacity-80{--tw-bg-opacity: .8}.p-0{padding:0}.p-5{padding:1.25rem}.p-3{padding:.75rem}.p-10{padding:2.5rem}.p-1{padding:.25rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.px-1{padding-left:.25rem;padding-right:.25rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.pt-3{padding-top:.75rem}.pb-3{padding-bottom:.75rem}.text-center{text-align:center}.text-xs{font-size:.75rem;line-height:1rem}.text-base{font-size:1rem;line-height:1.5rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.font-bold{font-weight:700}.font-light{font-weight:300}.font-semibold{font-weight:600}.font-extrabold{font-weight:800}.uppercase{text-transform:uppercase}.tracking-widest{letter-spacing:.1em}.text-black{--tw-text-opacity: 1;color:rgb(0 0 0 / var(--tw-text-opacity))}.text-\[\#1a1a1b\]{--tw-text-opacity: 1;color:rgb(26 26 27 / var(--tw-text-opacity))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity))}.underline{-webkit-text-decoration-line:underline;text-decoration-line:underline}.underline-offset-2{text-underline-offset:2px}.blur{--tw-blur: blur(8px);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-200{transition-duration:.2s}.duration-300{transition-duration:.3s}.duration-500{transition-duration:.5s}.ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}:root{--cols: 19}.correct,.present,.absent{color:#fff!important}.correct{background-color:#6aaa64!important}.present{background-color:#c9b458!important}.absent{background-color:#787c7e!important}.hover\:scale-105:hover{--tw-scale-x: 1.05;--tw-scale-y: 1.05;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\:bg-gray-900:hover{--tw-bg-opacity: 1;background-color:rgb(17 24 39 / var(--tw-bg-opacity))}.hover\:text-blue-500:hover{--tw-text-opacity: 1;color:rgb(59 130 246 / var(--tw-text-opacity))}.hover\:no-underline:hover{-webkit-text-decoration-line:none;text-decoration-line:none}@media (prefers-color-scheme: dark){.dark\:bg-\[rgb\(11\,15\,25\)\]{--tw-bg-opacity: 1;background-color:rgb(11 15 25 / var(--tw-bg-opacity))}.dark\:text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity))}}@media (min-width: 640px){.sm\:block{display:block}.sm\:px-2{padding-left:.5rem;padding-right:.5rem}.sm\:text-base{font-size:1rem;line-height:1.5rem}}
|
static/_app/immutable/assets/pages/index.svelte-b52b250e.css
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
.row.svelte-2ngxdh{margin-left:auto;margin-right:auto;margin-top:0;margin-bottom:.5rem;display:flex;width:100%;touch-action:manipulation}button.svelte-2ngxdh{margin:0;margin-right:.25rem;display:flex;min-height:58px;flex:1 1 0%;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;align-items:center;justify-content:center;border-radius:.125rem;border-width:0px;--tw-bg-opacity:1;background-color:rgb(211 214 218 / var(--tw-bg-opacity));padding:0;font-size:.75rem;line-height:1rem;font-weight:700;text-transform:uppercase;--tw-text-opacity:1;color:rgb(26 26 27 / var(--tw-text-opacity));transition-property:all;transition-duration:.2s;transition-timing-function:cubic-bezier(.4,0,.2,1)}button.svelte-2ngxdh:hover{--tw-scale-x:1.05;--tw-scale-y:1.05;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}button.big.svelte-2ngxdh{flex:1.5}button.svelte-2ngxdh:last-of-type{margin:0}.spacer.svelte-2ngxdh{flex:.5}.message.svelte-oufr2e{z-index:20;margin-left:auto;margin-right:auto;max-width:32rem;border-radius:.375rem;background-color:rgb(0 0 0 / var(--tw-bg-opacity));--tw-bg-opacity:.8;padding:2.5rem;font-weight:600;--tw-text-opacity:1;color:rgb(255 255 255 / var(--tw-text-opacity));transition-property:opacity;transition-duration:.3s;transition-timing-function:cubic-bezier(.4,0,.2,1)}.modal.svelte-oufr2e{position:fixed;top:0px;left:0px;z-index:10;min-height:100vh;width:100vw;background-color:rgb(0 0 0 / var(--tw-bg-opacity));--tw-bg-opacity:.8;--tw-backdrop-blur:blur(4px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);transform:translateZ(1000px);transform-style:preserve-3d}button.svelte-oufr2e{margin-top:.25rem;margin-bottom:.25rem;border-radius:.25rem;--tw-bg-opacity:1;background-color:rgb(55 65 81 / var(--tw-bg-opacity));padding:.25rem;font-size:.875rem;line-height:1.25rem;font-weight:700;--tw-text-opacity:1;color:rgb(255 255 255 / var(--tw-text-opacity));transition-property:opacity;transition-duration:.5s;transition-timing-function:cubic-bezier(.4,0,.2,1)}button.svelte-oufr2e:hover{--tw-bg-opacity:1;background-color:rgb(17 24 39 / var(--tw-bg-opacity))}.message.svelte-1sv0qpd{position:absolute;left:50%;top:50%;z-index:20;--tw-translate-x:-50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));border-radius:.125rem;background-color:rgb(0 0 0 / var(--tw-bg-opacity));--tw-bg-opacity:.8;padding:1.25rem;text-align:center;font-weight:600;--tw-text-opacity:1;color:rgb(255 255 255 / var(--tw-text-opacity));transition-property:opacity;transition-duration:.3s;transition-timing-function:cubic-bezier(.4,0,.2,1)}.board.svelte-1y5wh9j.svelte-1y5wh9j{position:relative;margin-left:auto;margin-right:auto;display:grid;gap:.25rem;--height:min(200px, calc(var(--vh, 100vh) - 350px));height:var(--height);width:min(90vw,calc(var(--height) / 7 * var(--cols)))}.row.svelte-1y5wh9j.svelte-1y5wh9j{position:relative;display:grid;gap:.25rem;grid-template-columns:repeat(var(--cols),1fr)}.tile.svelte-1y5wh9j.svelte-1y5wh9j{position:relative;z-index:0;width:100%;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;--tw-bg-opacity:1;background-color:rgb(249 250 251 / var(--tw-bg-opacity));text-align:center;font-size:1rem;line-height:1.5rem;font-weight:700;text-transform:uppercase;--tw-text-opacity:1;color:rgb(0 0 0 / var(--tw-text-opacity));vertical-align:middle}.tile.svelte-1y5wh9j .filled.svelte-1y5wh9j{-webkit-animation:svelte-1y5wh9j-zoom .2s;animation:svelte-1y5wh9j-zoom .2s}.tile.svelte-1y5wh9j .front.svelte-1y5wh9j,.tile.svelte-1y5wh9j .back.svelte-1y5wh9j{position:absolute;top:0px;left:0px;z-index:10;box-sizing:border-box;display:inline-flex;height:100%;width:100%;align-items:center;justify-content:center;transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.5s;backface-visibility:hidden;-webkit-backface-visibility:hidden}.tile.svelte-1y5wh9j .letter.svelte-1y5wh9j{z-index:10;display:flex;height:100%;place-items:center;--tw-bg-opacity:1;background-color:rgb(249 250 251 / var(--tw-bg-opacity))}.tile.svelte-1y5wh9j .space.svelte-1y5wh9j:before{position:absolute;z-index:0;display:flex;place-items:center;--tw-text-opacity:1;color:rgb(0 0 0 / var(--tw-text-opacity));opacity:.5;content:"\2022"}.tile.svelte-1y5wh9j .front.svelte-1y5wh9j{border-width:1.5px;border-style:solid;--tw-border-opacity:1;border-color:rgb(209 213 219 / var(--tw-border-opacity))}.tile.filled.svelte-1y5wh9j .front.svelte-1y5wh9j{border-width:1.5px;border-style:solid;--tw-border-opacity:1;border-color:rgb(107 114 128 / var(--tw-border-opacity))}.tile.svelte-1y5wh9j .back.svelte-1y5wh9j{transform:scaleX(0)}.tile.revealed.svelte-1y5wh9j .front.svelte-1y5wh9j{transform:scaleX(-1)}.tile.revealed.svelte-1y5wh9j .back.svelte-1y5wh9j{transform:scale(1)}@-webkit-keyframes svelte-1y5wh9j-zoom{0%{transform:scale(1.1)}to{transform:scale(1)}}@keyframes svelte-1y5wh9j-zoom{0%{transform:scale(1.1)}to{transform:scale(1)}}.shake.svelte-1y5wh9j.svelte-1y5wh9j{-webkit-animation:svelte-1y5wh9j-shake .5s;animation:svelte-1y5wh9j-shake .5s}@-webkit-keyframes svelte-1y5wh9j-shake{0%{transform:translate3d(1px,-1px,0)}10%{transform:translate3d(-2px,2px,0)}20%{transform:translate3d(2px,-2px,0)}30%{transform:translate3d(-2px,2px,0)}40%{transform:translate3d(2px,-2px,0)}50%{transform:translate3d(-2px,2px,0)}60%{transform:translate3d(2px,2px,0)}70%{transform:translate3d(-2px,-2px,0)}80%{transform:translate3d(2px,2px,0)}90%{transform:translate3d(-2px,-2px,0)}to{transform:translate3d(1px,1px,0)}}@keyframes svelte-1y5wh9j-shake{0%{transform:translate3d(1px,-1px,0)}10%{transform:translate3d(-2px,2px,0)}20%{transform:translate3d(2px,-2px,0)}30%{transform:translate3d(-2px,2px,0)}40%{transform:translate3d(2px,-2px,0)}50%{transform:translate3d(-2px,2px,0)}60%{transform:translate3d(2px,2px,0)}70%{transform:translate3d(-2px,-2px,0)}80%{transform:translate3d(2px,2px,0)}90%{transform:translate3d(-2px,-2px,0)}to{transform:translate3d(1px,1px,0)}}.jump.svelte-1y5wh9j .tile .back.svelte-1y5wh9j{-webkit-animation:svelte-1y5wh9j-jump .5s;animation:svelte-1y5wh9j-jump .5s}@-webkit-keyframes svelte-1y5wh9j-jump{0%{transform:translateZ(0)}20%{transform:translate3d(0,5px,0)}60%{transform:translate3d(0,-25px,0)}90%{transform:translate3d(0,3px,0)}to{transform:translateZ(0)}}@keyframes svelte-1y5wh9j-jump{0%{transform:translateZ(0)}20%{transform:translate3d(0,5px,0)}60%{transform:translate3d(0,-25px,0)}90%{transform:translate3d(0,3px,0)}to{transform:translateZ(0)}}@media (max-height: 680px){.tile.svelte-1y5wh9j.svelte-1y5wh9j{font-size:1.5vh}}
|
static/_app/immutable/chunks/fifteen-9add13bd.js
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
import{S as Y,i as t5,s as e5,N as a,O as r,a as l,d as e,b as t,$ as T,f as W,g as a5,J as s,E as X}from"./index-86f4d6c3.js";function r5($){let i,y,n,E,h,N,d,G,L,v,x,g,M,u,V,m,k,_,C,Z,F,D,w,p,b,B,c,H,S,f,q,A;return{c(){i=a("svg"),y=a("defs"),n=a("path"),E=a("use"),h=a("mask"),N=a("use"),d=a("g"),G=a("path"),L=a("path"),v=a("path"),x=a("path"),g=a("path"),M=a("path"),u=a("mask"),V=a("path"),m=a("g"),k=a("path"),_=a("path"),C=a("path"),Z=a("path"),F=a("path"),D=a("path"),w=a("defs"),p=a("linearGradient"),b=a("stop"),B=a("stop"),c=a("linearGradient"),H=a("stop"),S=a("stop"),f=a("linearGradient"),q=a("stop"),A=a("stop"),this.h()},l(U){i=r(U,"svg",{xmlns:!0,"xmlns:xlink":!0,fill:!0,viewBox:!0,width:!0,height:!0,class:!0});var o=l(i);y=r(o,"defs",{});var P=l(y);n=r(P,"path",{id:!0,fill:!0,d:!0}),l(n).forEach(e),P.forEach(e),E=r(o,"use",{"xlink:href":!0}),l(E).forEach(e),h=r(o,"mask",{id:!0,width:!0,height:!0,x:!0,y:!0,maskUnits:!0,style:!0});var Q=l(h);N=r(Q,"use",{"xlink:href":!0}),l(N).forEach(e),Q.forEach(e),d=r(o,"g",{mask:!0});var O=l(d);G=r(O,"path",{fill:!0,d:!0}),l(G).forEach(e),L=r(O,"path",{fill:!0,d:!0}),l(L).forEach(e),v=r(O,"path",{fill:!0,d:!0,opacity:!0}),l(v).forEach(e),x=r(O,"path",{fill:!0,d:!0,opacity:!0}),l(x).forEach(e),g=r(O,"path",{fill:!0,d:!0,opacity:!0}),l(g).forEach(e),O.forEach(e),M=r(o,"path",{fill:!0,d:!0}),l(M).forEach(e),u=r(o,"mask",{id:!0,width:!0,height:!0,x:!0,y:!0,maskUnits:!0,style:!0});var R=l(u);V=r(R,"path",{fill:!0,d:!0}),l(V).forEach(e),R.forEach(e),m=r(o,"g",{mask:!0});var J=l(m);k=r(J,"path",{fill:!0,d:!0,opacity:!0}),l(k).forEach(e),_=r(J,"path",{fill:!0,d:!0,opacity:!0}),l(_).forEach(e),C=r(J,"path",{fill:!0,d:!0}),l(C).forEach(e),Z=r(J,"path",{fill:!0,d:!0,opacity:!0}),l(Z).forEach(e),J.forEach(e),F=r(o,"path",{fill:!0,d:!0}),l(F).forEach(e),D=r(o,"path",{fill:!0,d:!0}),l(D).forEach(e),w=r(o,"defs",{});var j=l(w);p=r(j,"linearGradient",{id:!0,x1:!0,x2:!0,y1:!0,y2:!0,gradientUnits:!0});var z=l(p);b=r(z,"stop",{"stop-color":!0}),l(b).forEach(e),B=r(z,"stop",{offset:!0,"stop-color":!0}),l(B).forEach(e),z.forEach(e),c=r(j,"linearGradient",{id:!0,x1:!0,x2:!0,y1:!0,y2:!0,gradientUnits:!0});var I=l(c);H=r(I,"stop",{"stop-color":!0}),l(H).forEach(e),S=r(I,"stop",{offset:!0,"stop-color":!0}),l(S).forEach(e),I.forEach(e),f=r(j,"linearGradient",{id:!0,x1:!0,x2:!0,y1:!0,y2:!0,gradientUnits:!0});var K=l(f);q=r(K,"stop",{"stop-color":!0}),l(q).forEach(e),A=r(K,"stop",{offset:!0,"stop-color":!0,"stop-opacity":!0}),l(A).forEach(e),K.forEach(e),j.forEach(e),o.forEach(e),this.h()},h(){t(n,"id","a"),t(n,"fill","#777A6F"),t(n,"d","M372.7 107.8 201.9 7.6a25 25 0 0 0-25.7.2L12 107.7A25 25 0 0 0 0 129v194.2a25 25 0 0 0 12.2 21.5l164.2 97.7a25 25 0 0 0 25.3.2l170.7-98A25 25 0 0 0 385 323V129.3a25 25 0 0 0-12.3-21.5Z"),T(E,"xlink:href","#a"),T(N,"xlink:href","#a"),t(h,"id","b"),t(h,"width","385"),t(h,"height","443"),t(h,"x","0"),t(h,"y","4"),t(h,"maskUnits","userSpaceOnUse"),W(h,"mask-type","alpha"),t(G,"fill","#686C5D"),t(G,"d","M177.5 322c-25 59-49.7 120.7-138.5 83s-182.7-151-157.6-210c25.1-59.1 116.3-93.2 205.1-55.5s116 123.4 91 182.5Z"),t(L,"fill","#4E4F51"),t(L,"d","M9 328.5c-9-17-15-206-15-206L-14.5 357 190 486l202-133V126.5s-7.5 187.5-15 202c-3.5 6.8-39.3 28.2-78 52-43.2 26.6-90.5 55.5-109 55.5-18.2 0-63-26.6-104-52.5-37.9-23.9-72.7-46.8-77-55Z"),t(v,"fill","#CCDDE2"),t(v,"d","M166 379h48c-9.3 31-9.3 47.8 0 77h-48c8.3-30 7.2-47 0-77Zm165-78.8 30-23.2c8.1 32.4 18.3 45.8 47.1 61l-30 23.2c-4.2-35-15.9-47.2-47.1-61Z"),t(v,"opacity",".2"),t(x,"fill","#C89435"),t(x,"d","M330 111.8 342.6 76c25.7 20.2 41.6 26 72.7 25.6l-12.7 35.8c-24.7-20.3-41-25-72.6-25.6Z"),t(x,"opacity",".3"),t(g,"fill","#CCDDE2"),t(g,"d","m22 273 29 24.7c-29.7 14.9-40.7 27.7-50 58.6l-29-24.7c30.4-13.8 40.9-27 50-58.6Z"),t(g,"opacity",".2"),t(d,"mask","url(#b)"),t(M,"fill","url(#c)"),t(M,"d","m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v174.5a25 25 0 0 0 12.2 21.5l147.6 87.7a25 25 0 0 0 25.2.2l153.4-88A25 25 0 0 0 368 293V119.1a25 25 0 0 0-12.4-21.6Z"),t(V,"fill","url(#d)"),t(V,"d","m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v174.5a25 25 0 0 0 12.2 21.5l147.6 87.7a25 25 0 0 0 25.2.2l153.4-88A25 25 0 0 0 368 293V119.1a25 25 0 0 0-12.4-21.6Z"),t(u,"id","e"),t(u,"width","351"),t(u,"height","403"),t(u,"x","17"),t(u,"y","4"),t(u,"maskUnits","userSpaceOnUse"),W(u,"mask-type","alpha"),t(k,"fill","url(#f)"),t(k,"d","M394.2 346.7c46.5-71.6-249.6-263-249.6-263L119 108s211.6 114.9 176.5 163.3c-35 48.4-217-78.3-217-78.3L107 311.7s240.7 106.5 287.3 35Z"),t(k,"opacity",".4"),t(_,"fill","#D9E8EF"),t(_,"d","M157-47h177L137 459H-40L157-47Zm195.5-2H368L189.5 421H174L352.5-49Z"),t(_,"opacity",".8"),t(C,"fill","#ECF8FF"),t(C,"d","M360.5 111c14 17 8 34 8 38L389 95 194-31 10 78.5V161s7.5-39.5 15.5-52.5 124-113 165-94 156 79.5 170 96.5Z"),t(Z,"fill","#DBEAF2"),t(Z,"d","M21.5 299c-14-17-8-34-8-38L-7 315l195 126 184-109.5V249s-7.5 39.5-15.5 52.5-124 113-165 94-156-79.5-170-96.5Z"),t(Z,"opacity",".7"),t(m,"mask","url(#e)"),t(F,"fill","#777A6F"),t(F,"d","M108.6 326a5 5 0 0 1-5-5V58a5 5 0 0 1 5-5h41.8a5 5 0 0 1 5 5v263a5 5 0 0 1-5 5h-41.8Zm173-21.2a5 5 0 0 1-.5 2.1 34.5 34.5 0 0 1-30.6 19.1h-52.6a34.5 34.5 0 0 1-30.8-19.1c-.4-.6-.5-1.4-.5-2V227a5 5 0 0 1 5-5h38.8a5 5 0 0 1 5 5v42a5 5 0 0 0 5 5h7.4a5 5 0 0 0 5-5v-59a5 5 0 0 0-5-5h-56.2a5 5 0 0 1-5-5V58a5 5 0 0 1 5-5h97.7a5 5 0 0 1 5 5v37.9a5 5 0 0 1-5 5h-48.9a5 5 0 0 0-5 5v42a5 5 0 0 0 5 5h30c6.9 0 13.1 1.9 18.7 5.6a33 33 0 0 1 12 13.6c.3.6.5 1.3.5 2v130.7Z"),t(D,"fill","#fff"),t(D,"d","M108.6 310a5 5 0 0 1-5-5V42a5 5 0 0 1 5-5h41.8a5 5 0 0 1 5 5v263a5 5 0 0 1-5 5h-41.8Zm173-21.2c0 .7-.2 1.4-.5 2a34.5 34.5 0 0 1-30.6 19.2h-52.6a34.5 34.5 0 0 1-30.8-19.1 4 4 0 0 1-.5-2.1V211a5 5 0 0 1 5-5h38.8a5 5 0 0 1 5 5v42a5 5 0 0 0 5 5h7.4a5 5 0 0 0 5-5v-59.1a5 5 0 0 0-5-5h-56.2a5 5 0 0 1-5-5v-142a5 5 0 0 1 5-5h97.7a5 5 0 0 1 5 5v38a5 5 0 0 1-5 5h-48.9a5 5 0 0 0-5 5v42a5 5 0 0 0 5 5h30a33 33 0 0 1 18.7 5.5 33 33 0 0 1 12 13.6c.3.6.5 1.3.5 2v130.8Z"),t(b,"stop-color","#ACC0BE"),t(B,"offset","1"),t(B,"stop-color","#8BAAA7"),t(p,"id","c"),t(p,"x1","103"),t(p,"x2","192.5"),t(p,"y1","13"),t(p,"y2","410"),t(p,"gradientUnits","userSpaceOnUse"),t(H,"stop-color","#F2B445"),t(S,"offset","1"),t(S,"stop-color","#BD6D18"),t(c,"id","d"),t(c,"x1","94.5"),t(c,"x2","276"),t(c,"y1","12"),t(c,"y2","386.5"),t(c,"gradientUnits","userSpaceOnUse"),t(q,"stop-color","#6A807A"),t(A,"offset","1"),t(A,"stop-color","#6A807A"),t(A,"stop-opacity","0"),t(f,"id","f"),t(f,"x1","357.5"),t(f,"x2","69.5"),t(f,"y1","335"),t(f,"y2","146.5"),t(f,"gradientUnits","userSpaceOnUse"),t(i,"xmlns","http://www.w3.org/2000/svg"),t(i,"xmlns:xlink","http://www.w3.org/1999/xlink"),t(i,"fill","none"),t(i,"viewBox","0 0 385 450"),t(i,"width","385"),t(i,"height","450"),t(i,"class",$[0])},m(U,o){a5(U,i,o),s(i,y),s(y,n),s(i,E),s(i,h),s(h,N),s(i,d),s(d,G),s(d,L),s(d,v),s(d,x),s(d,g),s(i,M),s(i,u),s(u,V),s(i,m),s(m,k),s(m,_),s(m,C),s(m,Z),s(i,F),s(i,D),s(i,w),s(w,p),s(p,b),s(p,B),s(w,c),s(c,H),s(c,S),s(w,f),s(f,q),s(f,A)},p(U,[o]){o&1&&t(i,"class",U[0])},i:X,o:X,d(U){U&&e(i)}}}function l5($,i,y){let{classNames:n=""}=i;return $.$$set=E=>{"classNames"in E&&y(0,n=E.classNames)},[n]}class i5 extends Y{constructor(i){super(),t5(this,i,l5,r5,e5,{classNames:0})}}export{i5 as default};
|
static/_app/immutable/chunks/fifty-f65036e1.js
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
import{S as j,i as z,s as I,N as l,O as r,a as h,d as a,b as t,f as q,g as K,J as s,E as J}from"./index-86f4d6c3.js";function P(N){let e,n,i,d,u,_,M,m,v,y,x,p,w,f,E,F,g,V,Z,U,A,D,o,H,k;return{c(){e=l("svg"),n=l("path"),i=l("mask"),d=l("path"),u=l("g"),_=l("path"),M=l("path"),m=l("path"),v=l("path"),y=l("path"),x=l("path"),p=l("mask"),w=l("path"),f=l("g"),E=l("path"),F=l("path"),g=l("path"),V=l("path"),Z=l("path"),U=l("path"),A=l("path"),D=l("defs"),o=l("linearGradient"),H=l("stop"),k=l("stop"),this.h()},l(L){e=r(L,"svg",{xmlns:!0,fill:!0,viewBox:!0,width:!0,height:!0,class:!0});var c=h(e);n=r(c,"path",{fill:!0,d:!0}),h(n).forEach(a),i=r(c,"mask",{id:!0,width:!0,height:!0,x:!0,y:!0,maskUnits:!0,style:!0});var G=h(i);d=r(G,"path",{fill:!0,d:!0}),h(d).forEach(a),G.forEach(a),u=r(c,"g",{mask:!0});var S=h(u);_=r(S,"path",{fill:!0,d:!0}),h(_).forEach(a),M=r(S,"path",{fill:!0,d:!0}),h(M).forEach(a),m=r(S,"path",{fill:!0,d:!0,opacity:!0}),h(m).forEach(a),v=r(S,"path",{fill:!0,d:!0,opacity:!0}),h(v).forEach(a),y=r(S,"path",{fill:!0,d:!0,opacity:!0}),h(y).forEach(a),S.forEach(a),x=r(c,"path",{fill:!0,d:!0}),h(x).forEach(a),p=r(c,"mask",{id:!0,width:!0,height:!0,x:!0,y:!0,maskUnits:!0,style:!0});var O=h(p);w=r(O,"path",{fill:!0,d:!0}),h(w).forEach(a),O.forEach(a),f=r(c,"g",{mask:!0});var C=h(f);E=r(C,"path",{fill:!0,d:!0,opacity:!0}),h(E).forEach(a),F=r(C,"path",{fill:!0,d:!0,opacity:!0}),h(F).forEach(a),g=r(C,"path",{fill:!0,d:!0,opacity:!0}),h(g).forEach(a),V=r(C,"path",{fill:!0,d:!0}),h(V).forEach(a),Z=r(C,"path",{fill:!0,d:!0,opacity:!0}),h(Z).forEach(a),C.forEach(a),U=r(c,"path",{fill:!0,d:!0}),h(U).forEach(a),A=r(c,"path",{fill:!0,d:!0}),h(A).forEach(a),D=r(c,"defs",{});var b=h(D);o=r(b,"linearGradient",{id:!0,x1:!0,x2:!0,y1:!0,y2:!0,gradientUnits:!0});var B=h(o);H=r(B,"stop",{"stop-color":!0}),h(H).forEach(a),k=r(B,"stop",{offset:!0,"stop-color":!0,"stop-opacity":!0}),h(k).forEach(a),B.forEach(a),b.forEach(a),c.forEach(a),this.h()},h(){t(n,"fill","#3F7B73"),t(n,"d","M372.7 107.8 201.9 7.6a25 25 0 0 0-25.7.2L12 107.7A25 25 0 0 0 0 129v194.2a25 25 0 0 0 12.2 21.5l164.2 97.7a25 25 0 0 0 25.3.2l170.7-98A25 25 0 0 0 385 323V129.3a25 25 0 0 0-12.3-21.5Z"),t(d,"fill","#D3720A"),t(d,"d","M372.7 107.8 201.9 7.6a25 25 0 0 0-25.7.2L12 107.7A25 25 0 0 0 0 129v194.2a25 25 0 0 0 12.2 21.5l164.2 97.7a25 25 0 0 0 25.3.2l170.7-98A25 25 0 0 0 385 323V129.3a25 25 0 0 0-12.3-21.5Z"),t(i,"id","a"),t(i,"width","385"),t(i,"height","443"),t(i,"x","0"),t(i,"y","4"),t(i,"maskUnits","userSpaceOnUse"),q(i,"mask-type","alpha"),t(_,"fill","#468A7D"),t(_,"d","M177.5 322c-25 59-49.7 120.7-138.5 83s-182.7-151-157.6-210c25.1-59.1 116.3-93.2 205.1-55.5s116 123.4 91 182.5Z"),t(M,"fill","#184F4F"),t(M,"d","M9 328.5c-9-17-15-206-15-206L-14.5 357 190 486l202-133V126.5s-7.5 187.5-15 202c-3.5 6.8-39.3 28.2-78 52-43.2 26.6-90.5 55.5-109 55.5-18.2 0-63-26.6-104-52.5-37.9-23.9-72.7-46.8-77-55Z"),t(m,"fill","#F5FFFF"),t(m,"d","M166 379h48c-9.3 31-9.3 47.8 0 77h-48c8.3-30 7.2-47 0-77Zm165-78.8 30-23.2c8.1 32.4 18.3 45.8 47.1 61l-30 23.2c-4.2-35-15.9-47.2-47.1-61Z"),t(m,"opacity",".3"),t(v,"fill","#C89435"),t(v,"d","M330 111.8 342.6 76c25.7 20.2 41.6 26 72.7 25.6l-12.7 35.8c-24.7-20.3-41-25-72.6-25.6Z"),t(v,"opacity",".3"),t(y,"fill","#F5FFFF"),t(y,"d","m22 273 29 24.7c-29.7 14.9-40.7 27.7-50 58.6l-29-24.7c30.4-13.8 40.9-27 50-58.6Z"),t(y,"opacity",".3"),t(u,"mask","url(#a)"),t(x,"fill","#80EBE2"),t(x,"d","m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v174.5a25 25 0 0 0 12.2 21.5l147.6 87.7a25 25 0 0 0 25.2.2l153.4-88A25 25 0 0 0 368 293V119.1a25 25 0 0 0-12.4-21.6Z"),t(w,"fill","#C4D6D6"),t(w,"d","m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v184l-.1.4L4 326.5l12.5-17.7a1 1 0 0 1 1.3-.3L186 408l2.5 22.2c.1 1.2 1.9 1.2 2 0L193 408l171.7-98.5a1 1 0 0 1 1.3.3l13 19.2-10.9-22.3a1 1 0 0 1-.1-.4V119a25 25 0 0 0-12.4-21.6Z"),t(p,"id","b"),t(p,"width","375"),t(p,"height","428"),t(p,"x","4"),t(p,"y","4"),t(p,"maskUnits","userSpaceOnUse"),q(p,"mask-type","alpha"),t(E,"fill","url(#c)"),t(E,"d","M235.2 360.7c46.5-71.6-249.6-263-249.6-263L-40 122s211.6 114.9 176.5 163.3c-35 48.4-217-78.3-217-78.3L-52 325.7s240.7 106.5 287.3 35Z"),t(E,"opacity",".7"),t(F,"fill","#ECFFFD"),t(F,"d","M246-47h177L226 459H49L246-47Z"),t(F,"opacity",".6"),t(g,"fill","#ECFFFD"),t(g,"d","M441.5-49H457L278.5 421H263L441.5-49Z"),t(g,"opacity",".8"),t(V,"fill","#F5FFFF"),t(V,"d","M359.5 120c9.5 27 0 162.5 10 162.5S388 99 388 99L193-27 9 82.5s-6 202.5 3.5 203 8-162 16-175 120-111 161-92S350 93 359.5 120Z"),t(Z,"fill","#E9FFFF"),t(Z,"d","M21.5 296c-14-17-8-34-8-38l-24 59 195 126 201-111.5L372 246s-7.5 39.5-15.5 52.5-124 113-165 94-156-79.5-170-96.5Z"),t(Z,"opacity",".7"),t(f,"mask","url(#b)"),t(U,"fill","#34776E"),t(U,"d","M192.6 299.8a5 5 0 0 1-.5 2.1 34.5 34.5 0 0 1-30.6 19.1h-52.6a34.5 34.5 0 0 1-30.8-19c-.4-.6-.5-1.4-.5-2v-78a5 5 0 0 1 5-5h38.8a5 5 0 0 1 5 5v42a5 5 0 0 0 5 5h7.4a5 5 0 0 0 5-5v-59a5 5 0 0 0-5-5H82.6a5 5 0 0 1-5-5V53a5 5 0 0 1 5-5h97.7a5 5 0 0 1 5 5v37.9a5 5 0 0 1-5 5h-48.9a5 5 0 0 0-5 5v42a5 5 0 0 0 5 5h30c6.9 0 13.1 1.9 18.7 5.6a33 33 0 0 1 12 13.6c.3.6.5 1.3.5 2v130.7Zm126.4 0a4 4 0 0 1-.6 2.1c-2.8 5.5-6.9 10-12.1 13.6a32.3 32.3 0 0 1-18.7 5.5h-52.5a33 33 0 0 1-18.8-5.5c-5.2-3.6-9.2-8-11.9-13.6-.3-.6-.4-1.4-.4-2V65.4c0-.7.1-1.4.4-2 3.2-6.6 8-11.5 14.3-15a6 6 0 0 1 2.3-.5h80.7a6 6 0 0 1 2.3.5 34 34 0 0 1 14.5 14.9c.3.7.4 1.4.4 2.1v234.3ZM265 269a5 5 0 0 0 5-5V101a5 5 0 0 0-5-5h-7.3a5 5 0 0 0-5 5v163a5 5 0 0 0 5 5h7.3Z"),t(A,"fill","#fff"),t(A,"d","M192.6 287.8c0 .7-.2 1.4-.5 2a34.5 34.5 0 0 1-30.6 19.2h-52.6a34.5 34.5 0 0 1-30.8-19.1 4 4 0 0 1-.5-2.1V210a5 5 0 0 1 5-5h38.8a5 5 0 0 1 5 5v42a5 5 0 0 0 5 5h7.4a5 5 0 0 0 5-5v-59.1a5 5 0 0 0-5-5H82.6a5 5 0 0 1-5-5v-142a5 5 0 0 1 5-5h97.7a5 5 0 0 1 5 5v38a5 5 0 0 1-5 5h-48.9a5 5 0 0 0-5 5v42a5 5 0 0 0 5 5h30a33 33 0 0 1 18.7 5.5 33 33 0 0 1 12 13.6c.3.6.5 1.3.5 2v130.8Zm126.4-.1c0 .8-.2 1.5-.6 2.2-2.8 5.5-6.9 10-12.1 13.5a32.3 32.3 0 0 1-18.7 5.6h-52.5a34.4 34.4 0 0 1-30.7-19.1c-.3-.7-.4-1.4-.4-2.1V53.4c0-.7.1-1.4.4-2 3.2-6.5 8-11.5 14.3-14.9.7-.4 1.5-.5 2.3-.5h80.7c.8 0 1.6.1 2.3.5a34 34 0 0 1 14.5 14.8c.3.7.4 1.4.4 2.2v234.2ZM265 257a5 5 0 0 0 5-5V88.9a5 5 0 0 0-5-5h-7.3a5 5 0 0 0-5 5V252a5 5 0 0 0 5 5h7.3Z"),t(H,"stop-color","#3F866C"),t(k,"offset","1"),t(k,"stop-color","#48967A"),t(k,"stop-opacity","0"),t(o,"id","c"),t(o,"x1","242"),t(o,"x2","-4.5"),t(o,"y1","378"),t(o,"y2","154"),t(o,"gradientUnits","userSpaceOnUse"),t(e,"xmlns","http://www.w3.org/2000/svg"),t(e,"fill","none"),t(e,"viewBox","0 0 385 450"),t(e,"width","385"),t(e,"height","450"),t(e,"class",N[0])},m(L,c){K(L,e,c),s(e,n),s(e,i),s(i,d),s(e,u),s(u,_),s(u,M),s(u,m),s(u,v),s(u,y),s(e,x),s(e,p),s(p,w),s(e,f),s(f,E),s(f,F),s(f,g),s(f,V),s(f,Z),s(e,U),s(e,A),s(e,D),s(D,o),s(o,H),s(o,k)},p(L,[c]){c&1&&t(e,"class",L[0])},i:J,o:J,d(L){L&&a(e)}}}function Q(N,e,n){let{classNames:i=""}=e;return N.$$set=d=>{"classNames"in d&&n(0,i=d.classNames)},[i]}class T extends j{constructor(e){super(),z(this,e,Q,P,I,{classNames:0})}}export{T as default};
|
static/_app/immutable/chunks/five-ba00de65.js
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
import{S as tt,i as et,s as at,N as a,O as r,a as l,d as e,b as t,$ as W,f as X,g as rt,J as s,E as Y}from"./index-86f4d6c3.js";function lt($){let i,v,d,y,h,b,m,C,E,x,g,G,u,L,n,k,_,M,A,w,V,B,S,U,p,H,O,c,q,D,f,z,Z;return{c(){i=a("svg"),v=a("defs"),d=a("path"),y=a("use"),h=a("mask"),b=a("use"),m=a("g"),C=a("path"),E=a("path"),x=a("path"),g=a("path"),G=a("path"),u=a("mask"),L=a("path"),n=a("g"),k=a("path"),_=a("path"),M=a("path"),A=a("path"),w=a("path"),V=a("path"),B=a("path"),S=a("path"),U=a("defs"),p=a("linearGradient"),H=a("stop"),O=a("stop"),c=a("linearGradient"),q=a("stop"),D=a("stop"),f=a("linearGradient"),z=a("stop"),Z=a("stop"),this.h()},l(F){i=r(F,"svg",{xmlns:!0,"xmlns:xlink":!0,fill:!0,viewBox:!0,width:!0,height:!0,class:!0});var o=l(i);v=r(o,"defs",{});var Q=l(v);d=r(Q,"path",{id:!0,fill:!0,d:!0}),l(d).forEach(e),Q.forEach(e),y=r(o,"use",{"xlink:href":!0}),l(y).forEach(e),h=r(o,"mask",{id:!0,width:!0,height:!0,x:!0,y:!0,maskUnits:!0,style:!0});var R=l(h);b=r(R,"use",{"xlink:href":!0}),l(b).forEach(e),R.forEach(e),m=r(o,"g",{mask:!0});var J=l(m);C=r(J,"path",{fill:!0,d:!0}),l(C).forEach(e),E=r(J,"path",{fill:!0,d:!0,opacity:!0}),l(E).forEach(e),x=r(J,"path",{fill:!0,d:!0,opacity:!0}),l(x).forEach(e),g=r(J,"path",{fill:!0,d:!0,opacity:!0}),l(g).forEach(e),J.forEach(e),G=r(o,"path",{fill:!0,d:!0}),l(G).forEach(e),u=r(o,"mask",{id:!0,width:!0,height:!0,x:!0,y:!0,maskUnits:!0,style:!0});var T=l(u);L=r(T,"path",{fill:!0,d:!0}),l(L).forEach(e),T.forEach(e),n=r(o,"g",{mask:!0});var N=l(n);k=r(N,"path",{fill:!0,d:!0,opacity:!0}),l(k).forEach(e),_=r(N,"path",{fill:!0,d:!0,opacity:!0}),l(_).forEach(e),M=r(N,"path",{fill:!0,d:!0}),l(M).forEach(e),A=r(N,"path",{fill:!0,d:!0}),l(A).forEach(e),w=r(N,"path",{fill:!0,d:!0,opacity:!0}),l(w).forEach(e),N.forEach(e),V=r(o,"path",{fill:!0,d:!0}),l(V).forEach(e),B=r(o,"path",{fill:!0,d:!0}),l(B).forEach(e),S=r(o,"path",{fill:!0,d:!0}),l(S).forEach(e),U=r(o,"defs",{});var j=l(U);p=r(j,"linearGradient",{id:!0,x1:!0,x2:!0,y1:!0,y2:!0,gradientUnits:!0});var I=l(p);H=r(I,"stop",{"stop-color":!0}),l(H).forEach(e),O=r(I,"stop",{offset:!0,"stop-color":!0}),l(O).forEach(e),I.forEach(e),c=r(j,"linearGradient",{id:!0,x1:!0,x2:!0,y1:!0,y2:!0,gradientUnits:!0});var K=l(c);q=r(K,"stop",{"stop-color":!0}),l(q).forEach(e),D=r(K,"stop",{offset:!0,"stop-color":!0}),l(D).forEach(e),K.forEach(e),f=r(j,"linearGradient",{id:!0,x1:!0,x2:!0,y1:!0,y2:!0,gradientUnits:!0});var P=l(f);z=r(P,"stop",{"stop-color":!0}),l(z).forEach(e),Z=r(P,"stop",{offset:!0,"stop-color":!0,"stop-opacity":!0}),l(Z).forEach(e),P.forEach(e),j.forEach(e),o.forEach(e),this.h()},h(){t(d,"id","a"),t(d,"fill","#7A3A0C"),t(d,"d","M372.7 107.8 201.9 7.6a25 25 0 0 0-25.7.2L12 107.7A25 25 0 0 0 0 129v194.2a25 25 0 0 0 12.2 21.5l164.2 97.7a25 25 0 0 0 25.3.2l170.7-98A25 25 0 0 0 385 323V129.3a25 25 0 0 0-12.3-21.5Z"),W(y,"xlink:href","#a"),W(b,"xlink:href","#a"),t(h,"id","b"),t(h,"width","385"),t(h,"height","443"),t(h,"x","0"),t(h,"y","4"),t(h,"maskUnits","userSpaceOnUse"),X(h,"mask-type","alpha"),t(C,"fill","#592805"),t(C,"d","M9 328.5c-9-17-15-206-15-206L-14.5 357 190 486l202-133V126.5s-7.5 187.5-15 202c-3.5 6.8-39.3 28.2-78 52-43.2 26.6-90.5 55.5-109 55.5-18.2 0-63-26.6-104-52.5-37.9-23.9-72.7-46.8-77-55Z"),t(E,"fill","#C89435"),t(E,"d","M166 379h48c-9.3 31-9.3 47.8 0 77h-48c8.3-30 7.2-47 0-77Zm165-78.8 30-23.2c8.1 32.4 18.3 45.8 47.1 61l-30 23.2c-4.2-35-15.9-47.2-47.1-61Z"),t(E,"opacity",".2"),t(x,"fill","#C89435"),t(x,"d","M330 111.8 342.6 76c25.7 20.2 41.6 26 72.7 25.6l-12.7 35.8c-24.7-20.3-41-25-72.6-25.6Z"),t(x,"opacity",".3"),t(g,"fill","#C89435"),t(g,"d","m22 273 29 24.7c-29.7 14.9-40.7 27.7-50 58.6l-29-24.7c30.4-13.8 40.9-27 50-58.6Z"),t(g,"opacity",".2"),t(m,"mask","url(#b)"),t(G,"fill","url(#c)"),t(G,"d","m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v174.5a25 25 0 0 0 12.2 21.5l147.6 87.7a25 25 0 0 0 25.2.2l153.4-88A25 25 0 0 0 368 293V119.1a25 25 0 0 0-12.4-21.6Z"),t(L,"fill","url(#d)"),t(L,"d","m355.6 97.5-153.4-90a25 25 0 0 0-25.6.3L29 97.5a25 25 0 0 0-12 21.3v174.5a25 25 0 0 0 12.2 21.5l147.6 87.7a25 25 0 0 0 25.2.2l153.4-88A25 25 0 0 0 368 293V119.1a25 25 0 0 0-12.4-21.6Z"),t(u,"id","e"),t(u,"width","351"),t(u,"height","403"),t(u,"x","17"),t(u,"y","4"),t(u,"maskUnits","userSpaceOnUse"),X(u,"mask-type","alpha"),t(k,"fill","url(#f)"),t(k,"d","M389.2 334.7c46.5-71.6-249.6-263-249.6-263L114 96s211.6 114.9 176.5 163.3c-35 48.4-217-78.3-217-78.3L102 299.7s240.7 106.5 287.3 35Z"),t(k,"opacity",".7"),t(_,"fill","#FFD893"),t(_,"d","M157-47h177L137 459H-40L157-47Z"),t(_,"opacity",".8"),t(M,"fill","#F9CB80"),t(M,"d","M352.5-49H368L189.5 421H174L352.5-49Z"),t(A,"fill","#FFE9C2"),t(A,"d","M360.5 111c14 17 8 34 8 38L389 95 194-31 10 78.5V161s7.5-39.5 15.5-52.5 124-113 165-94 156 79.5 170 96.5Z"),t(w,"fill","#FFE0A9"),t(w,"d","M21.5 299c-14-17-8-34-8-38L-7 315l195 126 184-109.5V249s-7.5 39.5-15.5 52.5-124 113-165 94-156-79.5-170-96.5Z"),t(w,"opacity",".7"),t(n,"mask","url(#e)"),t(V,"fill","#7A3A0C"),t(V,"d","M254.6 304.6c0 1-.2 1.8-.6 2.5a34.5 34.5 0 0 1-30.5 19h-52.6a34.5 34.5 0 0 1-30.7-19c-.4-.7-.6-1.6-.6-2.5v-76.5a6 6 0 0 1 6-6h36.8a6 6 0 0 1 6 6v40a6 6 0 0 0 6 6h5.4a6 6 0 0 0 6-6v-57.2a6 6 0 0 0-6-6h-54.2a6 6 0 0 1-6-6V59a6 6 0 0 1 6-6h95.7a6 6 0 0 1 6 6v36a6 6 0 0 1-6 6h-46.9a6 6 0 0 0-6 6v40a6 6 0 0 0 6 6h29a33 33 0 0 1 18.7 5.5 33 33 0 0 1 12 13.4c.3.8.5 1.6.5 2.5v130.2Z"),t(B,"fill","#8A4C15"),t(B,"d","M175 310h35v16h-35z"),t(S,"fill","#FFF2DC"),t(S,"d","M254.6 288.6c0 .9-.2 1.7-.6 2.5a34.5 34.5 0 0 1-30.5 19h-52.6a34.5 34.5 0 0 1-30.7-19c-.4-.8-.6-1.6-.6-2.5V212a6 6 0 0 1 6-6h36.8a6 6 0 0 1 6 6v40a6 6 0 0 0 6 6h5.4a6 6 0 0 0 6-6v-57a6 6 0 0 0-6-6h-54.2a6 6 0 0 1-6-6V43a6 6 0 0 1 6-6h95.7a6 6 0 0 1 6 6v35.9a6 6 0 0 1-6 6h-46.9a6 6 0 0 0-6 6v40a6 6 0 0 0 6 6h29c6.9 0 13.1 1.9 18.7 5.6a33 33 0 0 1 12 13.4c.3.7.5 1.6.5 2.4v130.3Z"),t(H,"stop-color","#F2B445"),t(O,"offset","1"),t(O,"stop-color","#D7882F"),t(p,"id","c"),t(p,"x1","140.5"),t(p,"x2","219"),t(p,"y1","0"),t(p,"y2","410"),t(p,"gradientUnits","userSpaceOnUse"),t(q,"stop-color","#F2B445"),t(D,"offset","1"),t(D,"stop-color","#BD6D18"),t(c,"id","d"),t(c,"x1","94.5"),t(c,"x2","276"),t(c,"y1","12"),t(c,"y2","386.5"),t(c,"gradientUnits","userSpaceOnUse"),t(z,"stop-color","#B05C13"),t(Z,"offset","1"),t(Z,"stop-color","#B05C13"),t(Z,"stop-opacity","0"),t(f,"id","f"),t(f,"x1","373.6"),t(f,"x2","182.8"),t(f,"y1","370.3"),t(f,"y2","128.4"),t(f,"gradientUnits","userSpaceOnUse"),t(i,"xmlns","http://www.w3.org/2000/svg"),t(i,"xmlns:xlink","http://www.w3.org/1999/xlink"),t(i,"fill","none"),t(i,"viewBox","0 0 385 450"),t(i,"width","385"),t(i,"height","450"),t(i,"class",$[0])},m(F,o){rt(F,i,o),s(i,v),s(v,d),s(i,y),s(i,h),s(h,b),s(i,m),s(m,C),s(m,E),s(m,x),s(m,g),s(i,G),s(i,u),s(u,L),s(i,n),s(n,k),s(n,_),s(n,M),s(n,A),s(n,w),s(i,V),s(i,B),s(i,S),s(i,U),s(U,p),s(p,H),s(p,O),s(U,c),s(c,q),s(c,D),s(U,f),s(f,z),s(f,Z)},p(F,[o]){o&1&&t(i,"class",F[0])},i:Y,o:Y,d(F){F&&e(i)}}}function st($,i,v){let{classNames:d=""}=i;return $.$$set=y=>{"classNames"in y&&v(0,d=y.classNames)},[d]}class ot extends tt{constructor(i){super(),et(this,i,st,lt,at,{classNames:0})}}export{ot as default};
|
static/_app/immutable/chunks/index-86f4d6c3.js
ADDED
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
1 |
+
function k(){}const ct=t=>t;function ot(t,e){for(const n in e)t[n]=e[n];return t}function J(t){return t()}function I(){return Object.create(null)}function x(t){t.forEach(J)}function K(t){return typeof t=="function"}function qt(t,e){return t!=t?e==e:t!==e||t&&typeof t=="object"||typeof t=="function"}let S;function Tt(t,e){return S||(S=document.createElement("a")),S.href=e,t===S.href}function lt(t){return Object.keys(t).length===0}function ut(t,...e){if(t==null)return k;const n=t.subscribe(...e);return n.unsubscribe?()=>n.unsubscribe():n}function zt(t,e,n){t.$$.on_destroy.push(ut(e,n))}function Bt(t,e,n,r){if(t){const s=Q(t,e,n,r);return t[0](s)}}function Q(t,e,n,r){return t[1]&&r?ot(n.ctx.slice(),t[1](r(e))):n.ctx}function Lt(t,e,n,r){if(t[2]&&r){const s=t[2](r(n));if(e.dirty===void 0)return s;if(typeof s=="object"){const l=[],i=Math.max(e.dirty.length,s.length);for(let o=0;o<i;o+=1)l[o]=e.dirty[o]|s[o];return l}return e.dirty|s}return e.dirty}function Ft(t,e,n,r,s,l){if(s){const i=Q(e,n,r,l);t.p(i,s)}}function Ht(t){if(t.ctx.length>32){const e=[],n=t.ctx.length/32;for(let r=0;r<n;r++)e[r]=-1;return e}return-1}function It(t,e,n){return t.set(n),e}const U=typeof window!="undefined";let at=U?()=>window.performance.now():()=>Date.now(),F=U?t=>requestAnimationFrame(t):k;const b=new Set;function V(t){b.forEach(e=>{e.c(t)||(b.delete(e),e.f())}),b.size!==0&&F(V)}function ft(t){let e;return b.size===0&&F(V),{promise:new Promise(n=>{b.add(e={c:t,f:n})}),abort(){b.delete(e)}}}let O=!1;function _t(){O=!0}function dt(){O=!1}function ht(t,e,n,r){for(;t<e;){const s=t+(e-t>>1);n(s)<=r?t=s+1:e=s}return t}function mt(t){if(t.hydrate_init)return;t.hydrate_init=!0;let e=t.childNodes;if(t.nodeName==="HEAD"){const c=[];for(let u=0;u<e.length;u++){const _=e[u];_.claim_order!==void 0&&c.push(_)}e=c}const n=new Int32Array(e.length+1),r=new Int32Array(e.length);n[0]=-1;let s=0;for(let c=0;c<e.length;c++){const u=e[c].claim_order,_=(s>0&&e[n[s]].claim_order<=u?s+1:ht(1,s,a=>e[n[a]].claim_order,u))-1;r[c]=n[_]+1;const f=_+1;n[f]=c,s=Math.max(f,s)}const l=[],i=[];let o=e.length-1;for(let c=n[s]+1;c!=0;c=r[c-1]){for(l.push(e[c-1]);o>=c;o--)i.push(e[o]);o--}for(;o>=0;o--)i.push(e[o]);l.reverse(),i.sort((c,u)=>c.claim_order-u.claim_order);for(let c=0,u=0;c<i.length;c++){for(;u<l.length&&i[c].claim_order>=l[u].claim_order;)u++;const _=u<l.length?l[u]:null;t.insertBefore(i[c],_)}}function pt(t,e){t.appendChild(e)}function X(t){if(!t)return document;const e=t.getRootNode?t.getRootNode():t.ownerDocument;return e&&e.host?e:t.ownerDocument}function yt(t){const e=Y("style");return gt(X(t),e),e.sheet}function gt(t,e){pt(t.head||t,e)}function bt(t,e){if(O){for(mt(t),(t.actual_end_child===void 0||t.actual_end_child!==null&&t.actual_end_child.parentElement!==t)&&(t.actual_end_child=t.firstChild);t.actual_end_child!==null&&t.actual_end_child.claim_order===void 0;)t.actual_end_child=t.actual_end_child.nextSibling;e!==t.actual_end_child?(e.claim_order!==void 0||e.parentNode!==t)&&t.insertBefore(e,t.actual_end_child):t.actual_end_child=e.nextSibling}else(e.parentNode!==t||e.nextSibling!==null)&&t.appendChild(e)}function Wt(t,e,n){O&&!n?bt(t,e):(e.parentNode!==t||e.nextSibling!=n)&&t.insertBefore(e,n||null)}function xt(t){t.parentNode.removeChild(t)}function Gt(t,e){for(let n=0;n<t.length;n+=1)t[n]&&t[n].d(e)}function Y(t){return document.createElement(t)}function $t(t){return document.createElementNS("http://www.w3.org/2000/svg",t)}function H(t){return document.createTextNode(t)}function Jt(){return H(" ")}function Kt(){return H("")}function Qt(t,e,n,r){return t.addEventListener(e,n,r),()=>t.removeEventListener(e,n,r)}function Ut(t,e,n){n==null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n)}function Vt(t,e,n){t.setAttributeNS("http://www.w3.org/1999/xlink",e,n)}function wt(t){return Array.from(t.childNodes)}function vt(t){t.claim_info===void 0&&(t.claim_info={last_index:0,total_claimed:0})}function Z(t,e,n,r,s=!1){vt(t);const l=(()=>{for(let i=t.claim_info.last_index;i<t.length;i++){const o=t[i];if(e(o)){const c=n(o);return c===void 0?t.splice(i,1):t[i]=c,s||(t.claim_info.last_index=i),o}}for(let i=t.claim_info.last_index-1;i>=0;i--){const o=t[i];if(e(o)){const c=n(o);return c===void 0?t.splice(i,1):t[i]=c,s?c===void 0&&t.claim_info.last_index--:t.claim_info.last_index=i,o}}return r()})();return l.claim_order=t.claim_info.total_claimed,t.claim_info.total_claimed+=1,l}function tt(t,e,n,r){return Z(t,s=>s.nodeName===e,s=>{const l=[];for(let i=0;i<s.attributes.length;i++){const o=s.attributes[i];n[o.name]||l.push(o.name)}l.forEach(i=>s.removeAttribute(i))},()=>r(e))}function Xt(t,e,n){return tt(t,e,n,Y)}function Yt(t,e,n){return tt(t,e,n,$t)}function Et(t,e){return Z(t,n=>n.nodeType===3,n=>{const r=""+e;if(n.data.startsWith(r)){if(n.data.length!==r.length)return n.splitText(r.length)}else n.data=r},()=>H(e),!0)}function Zt(t){return Et(t," ")}function te(t,e){e=""+e,t.wholeText!==e&&(t.data=e)}function ee(t,e,n,r){n===null?t.style.removeProperty(e):t.style.setProperty(e,n,r?"important":"")}function et(t,e,{bubbles:n=!1,cancelable:r=!1}={}){const s=document.createEvent("CustomEvent");return s.initCustomEvent(t,n,r,e),s}const D=new Map;let P=0;function kt(t){let e=5381,n=t.length;for(;n--;)e=(e<<5)-e^t.charCodeAt(n);return e>>>0}function Nt(t,e){const n={stylesheet:yt(e),rules:{}};return D.set(t,n),n}function W(t,e,n,r,s,l,i,o=0){const c=16.666/r;let u=`{
|
2 |
+
`;for(let p=0;p<=1;p+=c){const g=e+(n-e)*l(p);u+=p*100+`%{${i(g,1-g)}}
|
3 |
+
`}const _=u+`100% {${i(n,1-n)}}
|
4 |
+
}`,f=`__svelte_${kt(_)}_${o}`,a=X(t),{stylesheet:d,rules:h}=D.get(a)||Nt(a,t);h[f]||(h[f]=!0,d.insertRule(`@keyframes ${f} ${_}`,d.cssRules.length));const y=t.style.animation||"";return t.style.animation=`${y?`${y}, `:""}${f} ${r}ms linear ${s}ms 1 both`,P+=1,f}function At(t,e){const n=(t.style.animation||"").split(", "),r=n.filter(e?l=>l.indexOf(e)<0:l=>l.indexOf("__svelte")===-1),s=n.length-r.length;s&&(t.style.animation=r.join(", "),P-=s,P||St())}function St(){F(()=>{P||(D.forEach(t=>{const{stylesheet:e}=t;let n=e.cssRules.length;for(;n--;)e.deleteRule(n);t.rules={}}),D.clear())})}let E;function v(t){E=t}function N(){if(!E)throw new Error("Function called outside component initialization");return E}function ne(t){N().$$.on_mount.push(t)}function ie(t){N().$$.after_update.push(t)}function re(t){N().$$.on_destroy.push(t)}function se(){const t=N();return(e,n,{cancelable:r=!1}={})=>{const s=t.$$.callbacks[e];if(s){const l=et(e,n,{cancelable:r});return s.slice().forEach(i=>{i.call(t,l)}),!l.defaultPrevented}return!0}}function ce(t,e){return N().$$.context.set(t,e),e}const w=[],G=[],C=[],B=[],nt=Promise.resolve();let L=!1;function it(){L||(L=!0,nt.then(rt))}function oe(){return it(),nt}function R(t){C.push(t)}function le(t){B.push(t)}const T=new Set;let j=0;function rt(){const t=E;do{for(;j<w.length;){const e=w[j];j++,v(e),jt(e.$$)}for(v(null),w.length=0,j=0;G.length;)G.pop()();for(let e=0;e<C.length;e+=1){const n=C[e];T.has(n)||(T.add(n),n())}C.length=0}while(w.length);for(;B.length;)B.pop()();L=!1,T.clear(),v(t)}function jt(t){if(t.fragment!==null){t.update(),x(t.before_update);const e=t.dirty;t.dirty=[-1],t.fragment&&t.fragment.p(t.ctx,e),t.after_update.forEach(R)}}let $;function Ct(){return $||($=Promise.resolve(),$.then(()=>{$=null})),$}function z(t,e,n){t.dispatchEvent(et(`${e?"intro":"outro"}${n}`))}const M=new Set;let m;function ue(){m={r:0,c:[],p:m}}function ae(){m.r||x(m.c),m=m.p}function Mt(t,e){t&&t.i&&(M.delete(t),t.i(e))}function fe(t,e,n,r){if(t&&t.o){if(M.has(t))return;M.add(t),m.c.push(()=>{M.delete(t),r&&(n&&t.d(1),r())}),t.o(e)}}const Dt={duration:0};function _e(t,e,n,r){let s=e(t,n),l=r?0:1,i=null,o=null,c=null;function u(){c&&At(t,c)}function _(a,d){const h=a.b-l;return d*=Math.abs(h),{a:l,b:a.b,d:h,duration:d,start:a.start,end:a.start+d,group:a.group}}function f(a){const{delay:d=0,duration:h=300,easing:y=ct,tick:p=k,css:g}=s||Dt,q={start:at()+d,b:a};a||(q.group=m,m.r+=1),i||o?o=q:(g&&(u(),c=W(t,l,a,h,d,y,g)),a&&p(0,1),i=_(q,h),R(()=>z(t,a,"start")),ft(A=>{if(o&&A>o.start&&(i=_(o,h),o=null,z(t,i.b,"start"),g&&(u(),c=W(t,l,i.b,i.duration,0,y,s.css))),i){if(A>=i.end)p(l=i.b,1-l),z(t,i.b,"end"),o||(i.b?u():--i.group.r||x(i.group.c)),i=null;else if(A>=i.start){const st=A-i.start;l=i.a+i.d*y(st/i.duration),p(l,1-l)}}return!!(i||o)}))}return{run(a){K(s)?Ct().then(()=>{s=s(),f(a)}):f(a)},end(){u(),i=o=null}}}function de(t,e){const n={},r={},s={$$scope:1};let l=t.length;for(;l--;){const i=t[l],o=e[l];if(o){for(const c in i)c in o||(r[c]=1);for(const c in o)s[c]||(n[c]=o[c],s[c]=1);t[l]=o}else for(const c in i)s[c]=1}for(const i in r)i in n||(n[i]=void 0);return n}function he(t){return typeof t=="object"&&t!==null?t:{}}function me(t,e,n){const r=t.$$.props[e];r!==void 0&&(t.$$.bound[r]=n,n(t.$$.ctx[r]))}function pe(t){t&&t.c()}function ye(t,e){t&&t.l(e)}function Pt(t,e,n,r){const{fragment:s,on_mount:l,on_destroy:i,after_update:o}=t.$$;s&&s.m(e,n),r||R(()=>{const c=l.map(J).filter(K);i?i.push(...c):x(c),t.$$.on_mount=[]}),o.forEach(R)}function Rt(t,e){const n=t.$$;n.fragment!==null&&(x(n.on_destroy),n.fragment&&n.fragment.d(e),n.on_destroy=n.fragment=null,n.ctx=[])}function Ot(t,e){t.$$.dirty[0]===-1&&(w.push(t),it(),t.$$.dirty.fill(0)),t.$$.dirty[e/31|0]|=1<<e%31}function ge(t,e,n,r,s,l,i,o=[-1]){const c=E;v(t);const u=t.$$={fragment:null,ctx:null,props:l,update:k,not_equal:s,bound:I(),on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],after_update:[],context:new Map(e.context||(c?c.$$.context:[])),callbacks:I(),dirty:o,skip_bound:!1,root:e.target||c.$$.root};i&&i(u.root);let _=!1;if(u.ctx=n?n(t,e.props||{},(f,a,...d)=>{const h=d.length?d[0]:a;return u.ctx&&s(u.ctx[f],u.ctx[f]=h)&&(!u.skip_bound&&u.bound[f]&&u.bound[f](h),_&&Ot(t,f)),a}):[],u.update(),_=!0,x(u.before_update),u.fragment=r?r(u.ctx):!1,e.target){if(e.hydrate){_t();const f=wt(e.target);u.fragment&&u.fragment.l(f),f.forEach(xt)}else u.fragment&&u.fragment.c();e.intro&&Mt(t.$$.fragment),Pt(t,e.target,e.anchor,e.customElement),dt(),rt()}v(c)}class be{$destroy(){Rt(this,1),this.$destroy=k}$on(e,n){const r=this.$$.callbacks[e]||(this.$$.callbacks[e]=[]);return r.push(n),()=>{const s=r.indexOf(n);s!==-1&&r.splice(s,1)}}$set(e){this.$$set&&!lt(e)&&(this.$$.skip_bound=!0,this.$$set(e),this.$$.skip_bound=!1)}}export{Vt as $,he as A,Rt as B,ot as C,oe as D,k as E,Bt as F,Ft as G,Ht as H,Lt as I,bt as J,Qt as K,Gt as L,se as M,$t as N,Yt as O,ct as P,R as Q,_e as R,be as S,Tt as T,x as U,re as V,G as W,le as X,zt as Y,It as Z,me as _,wt as a,Ut as b,Xt as c,xt as d,Y as e,ee as f,Wt as g,Et as h,ge as i,te as j,Jt as k,Kt as l,Zt as m,ue as n,fe as o,ae as p,Mt as q,ce as r,qt as s,H as t,ie as u,ne as v,pe as w,ye as x,Pt as y,de as z};
|