From 2617eade475ac26bf0ed542c9998c1849c4646b7 Mon Sep 17 00:00:00 2001 From: Nico Melone Date: Thu, 18 Sep 2025 16:59:30 -0500 Subject: [PATCH] reorganized files --- .DS_Store | Bin 6148 -> 6148 bytes .gitattributes => app/.gitattributes | 0 .gitignore => app/.gitignore | 0 app/Dockerfile | 27 + .../DragDropExample.html | 0 app/__pycache__/models.cpython-310.pyc | Bin 0 -> 486 bytes app.py => app/app.py | 48 +- {instance => app/instance}/items.db | Bin models.py => app/models.py | 0 requirements.txt => app/requirements.txt | 1 + {static => app/static}/css/motion.css | 0 app/static/css/nationalparks.css | 673 ++++++++++++++++++ {static => app/static}/css/relative_rank.css | 0 {static => app/static}/css/short_stories.css | 0 {static => app/static}/css/styles.css | 0 {static => app/static}/favicon.ico | Bin app/static/js/nationalparks.js | 3 + {static => app/static}/js/ranking.js | 0 {static => app/static}/js/ranking_ai.js | 0 {static => app/static}/stories.json | 0 {static => app/static}/vocab.csv | 0 {templates => app/templates}/about.html | 0 {templates => app/templates}/add_item.html | 0 {templates => app/templates}/base.html | 2 + {templates => app/templates}/home.html | 0 {templates => app/templates}/motion.html | 0 app/templates/nationalparks.html | 20 + {templates => app/templates}/pcc.html | 0 .../templates}/relative_rank.html | 0 .../templates}/relative_rank_ai.html | 0 .../templates}/short_stories.html | 0 .../templates}/short_stories_base.html | 0 app/templates/transcript.html | 26 + {templates => app/templates}/vocabulary.html | 0 {templates => app/templates}/weather.html | 2 +- compose.yaml | 13 + 36 files changed, 811 insertions(+), 4 deletions(-) rename .gitattributes => app/.gitattributes (100%) rename .gitignore => app/.gitignore (100%) create mode 100644 app/Dockerfile rename DragDropExample.html => app/DragDropExample.html (100%) create mode 100644 app/__pycache__/models.cpython-310.pyc rename app.py => app/app.py (72%) rename {instance => app/instance}/items.db (100%) rename models.py => app/models.py (100%) rename requirements.txt => app/requirements.txt (70%) rename {static => app/static}/css/motion.css (100%) create mode 100644 app/static/css/nationalparks.css rename {static => app/static}/css/relative_rank.css (100%) rename {static => app/static}/css/short_stories.css (100%) rename {static => app/static}/css/styles.css (100%) rename {static => app/static}/favicon.ico (100%) create mode 100644 app/static/js/nationalparks.js rename {static => app/static}/js/ranking.js (100%) rename {static => app/static}/js/ranking_ai.js (100%) rename {static => app/static}/stories.json (100%) rename {static => app/static}/vocab.csv (100%) rename {templates => app/templates}/about.html (100%) rename {templates => app/templates}/add_item.html (100%) rename {templates => app/templates}/base.html (90%) rename {templates => app/templates}/home.html (100%) rename {templates => app/templates}/motion.html (100%) create mode 100644 app/templates/nationalparks.html rename {templates => app/templates}/pcc.html (100%) rename {templates => app/templates}/relative_rank.html (100%) rename {templates => app/templates}/relative_rank_ai.html (100%) rename {templates => app/templates}/short_stories.html (100%) rename {templates => app/templates}/short_stories_base.html (100%) create mode 100644 app/templates/transcript.html rename {templates => app/templates}/vocabulary.html (100%) rename {templates => app/templates}/weather.html (97%) create mode 100644 compose.yaml diff --git a/.DS_Store b/.DS_Store index d5a32afb1a43de9e60fad73eb4546900efe64d87..f32b50d2b1a39861ca444d9995c48bee6f803bad 100644 GIT binary patch delta 491 zcmZoMXfc@J&&aViH%BSF!FUT+qPR`FQ0P102P?*3lc^!+?zNr6844H*lFEwm9X!pg?Z!NI}J5gVM5UmjeNSW;T-lvorE;)Uer=On?{iAiCZspatkBF_1F zC5f4NsYPH7nJKA2B{AWdc`5njPWh#IDaByD!4L_KdQMKxcmb*EY9kXvQym2(W8+#K zg=#}nV8m%B|q0iZVd0#9& z-EEkDf1-cTOY9BqE>fvXd-x6LgxYj~(xVRd7%XU-S>!|}IX#}gp6*;rPPx%zhTlgU ze92|L4m9f1kVatJ2j7lAYzM6<3b6U5o#ryK2S_g9-nkH~S8@TViNa`1eNtQo=^0IU z1oG`9VZ&jNox8onf((C>=u*L_tp`c;OU#&LUW`GoDn*%vo*fGD9t6;p+ruQy47Wj+ z)($~7BPvOGW&Q2Bt|(_lj)_l>H0aX}CjQIDuPw|eE3~y$z$#!B_*8)R2N#9W(-(bE_!ga;;6Do~{geZ>$e9sRD3^EAc^RXPcM`4D<$p>HTc z&W`b28BW4eXltv0RlroBpdKrH{%_^q|IH-(WEHRq{3``SvC(YQu_S%ArWVI%t&6gc q!p3p2LYaa}AIGx6NAUuRH27R@06mSdLiE7w9|0+Yt*in+s=x;<-^kJc diff --git a/.gitattributes b/app/.gitattributes similarity index 100% rename from .gitattributes rename to app/.gitattributes diff --git a/.gitignore b/app/.gitignore similarity index 100% rename from .gitignore rename to app/.gitignore diff --git a/app/Dockerfile b/app/Dockerfile new file mode 100644 index 0000000..98dfa62 --- /dev/null +++ b/app/Dockerfile @@ -0,0 +1,27 @@ +# syntax=docker/dockerfile:1.4 +FROM --platform=$BUILDPLATFORM python:3.10-alpine AS builder + +WORKDIR /app + +COPY requirements.txt /app +RUN --mount=type=cache,target=/root/.cache/pip \ + pip3 install -r requirements.txt + +COPY . /app + +ENTRYPOINT ["python3"] +CMD ["app.py"] + +FROM builder as dev-envs + +RUN <>9_>r{p)%9jpt`sY=?=(31)VH0tBccA?1`3Nmqok zO9BjxM*@aqGh=0N6U-6utTj#(k7{>xdv&TN4>Bw!CEAXS^*K^WI0ZD6#>~XDfC77B z+^*}F1{kjtOt6qS8)hS;6>CBR*E-r9EM<7-QQk_@AoSBh%w@5@!37rxohVnzA1k^3 zKr-}P?FbS1p%g;9LWD8os=T*_SmeI?>o6E|`z%&@81cp+TFR+RH48x7qh%UIQ*D-m zx&<W}UEEN~Pq*(UNgvIn$_|qvHLzo0W)6x&dUTiW(~1r~i}&u8pUp+K oP=5VyDJz|tDBQX(O{&p<|N6FreeE38PdKJnWj0Ei*ldse0;sWaEC2ui literal 0 HcmV?d00001 diff --git a/app.py b/app/app.py similarity index 72% rename from app.py rename to app/app.py index 29d8b33..d8e6ee5 100644 --- a/app.py +++ b/app/app.py @@ -1,4 +1,7 @@ -from flask import Flask, render_template, request, redirect, url_for, jsonify +import tempfile +from urllib.parse import parse_qs, urlparse +from flask import Flask, render_template, request, redirect, send_file, url_for, jsonify +from youtube_transcript_api import YouTubeTranscriptApi from models import db, Item from datetime import datetime as dt import requests, csv, json @@ -66,7 +69,7 @@ def short_stories(story=1): @app.route('/weather') def get_weather(): # Replace with your API's URL - api_url = "https://api.open-meteo.com/v1/forecast?latitude=32.0015&longitude=-102.1394¤t_weather=true" + api_url = "https://api.open-meteo.com/v1/forecast?latitude=32.681676709461826&longitude=-97.373412014933¤t_weather=true" try: # Make the GET request to the API @@ -128,5 +131,44 @@ def pcc(): return render_template('pcc.html', value = value_chain) return render_template('pcc.html') +def get_video_id(url: str) -> str: + """Extract YouTube video ID from URL.""" + query = urlparse(url) + if query.hostname in ['www.youtube.com', 'youtube.com']: + return parse_qs(query.query)['v'][0] + elif query.hostname == 'youtu.be': + return query.path[1:] + else: + raise ValueError("Invalid YouTube URL") + +def fetch_transcript(url: str, language: str = 'ja') -> str: + """Fetch transcript text.""" + video_id = get_video_id(url) + ytt_api = YouTubeTranscriptApi() + transcript = ytt_api.fetch(video_id, languages=[language]) + return (" ".join([entry.text for entry in transcript]),transcript.video_id) + +@app.route("/transcript", methods=["GET", "POST"]) +def transcript(): + if request.method == "POST": + yt_url = request.form["url"] + lang = request.form.get("lang", "ja") + try: + transcript, video_id = fetch_transcript(yt_url, lang) + except Exception as e: + return f"Error: {e}", 400 + + # Save to a temporary file and return immediately + tmp = tempfile.NamedTemporaryFile(delete=False, suffix=".txt", mode="w", encoding="utf-8") + tmp.write(transcript) + tmp.close() + return send_file(tmp.name, as_attachment=True, download_name=f"{video_id}-transcript.txt") + + return render_template("transcript.html") + +@app.route("/nationalparks") +def nationalparks(): + return render_template("nationalparks.html") + if __name__ == '__main__': - app.run(debug=True) + app.run(debug=True, host='0.0.0.0', port=8000) diff --git a/instance/items.db b/app/instance/items.db similarity index 100% rename from instance/items.db rename to app/instance/items.db diff --git a/models.py b/app/models.py similarity index 100% rename from models.py rename to app/models.py diff --git a/requirements.txt b/app/requirements.txt similarity index 70% rename from requirements.txt rename to app/requirements.txt index 8e951c9..4c94154 100644 --- a/requirements.txt +++ b/app/requirements.txt @@ -1,3 +1,4 @@ Flask==2.3.3 Flask-SQLAlchemy==3.0.5 Werkzeug==2.3.7 +youtube-transcript-api \ No newline at end of file diff --git a/static/css/motion.css b/app/static/css/motion.css similarity index 100% rename from static/css/motion.css rename to app/static/css/motion.css diff --git a/app/static/css/nationalparks.css b/app/static/css/nationalparks.css new file mode 100644 index 0000000..e995086 --- /dev/null +++ b/app/static/css/nationalparks.css @@ -0,0 +1,673 @@ +@import url(https://unpkg.com/leaflet@1.9.4/dist/leaflet.css); +body { + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; + font-family: -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Oxygen, Ubuntu, Cantarell, Fira Sans, Droid Sans, Helvetica Neue, sans-serif; + margin: 0; +} +code { + font-family: source-code-pro, Menlo, Monaco, Consolas, Courier New, monospace; +} +.leaflet-image-layer, +.leaflet-layer, +.leaflet-marker-icon, +.leaflet-marker-shadow, +.leaflet-pane, +.leaflet-pane > canvas, +.leaflet-pane > svg, +.leaflet-tile, +.leaflet-tile-container, +.leaflet-zoom-box { + left: 0; + position: absolute; + top: 0; +} +.leaflet-container { + overflow: hidden; +} +.leaflet-marker-icon, +.leaflet-marker-shadow, +.leaflet-tile { + -webkit-user-drag: none; + -webkit-user-select: none; + user-select: none; +} +.leaflet-tile::selection { + background: #0000; +} +.leaflet-safari .leaflet-tile { + image-rendering: -webkit-optimize-contrast; +} +.leaflet-safari .leaflet-tile-container { + height: 1600px; + -webkit-transform-origin: 0 0; + width: 1600px; +} +.leaflet-marker-icon, +.leaflet-marker-shadow { + display: block; +} +.leaflet-container .leaflet-overlay-pane svg { + max-height: none !important; + max-width: none !important; +} +.leaflet-container .leaflet-marker-pane img, +.leaflet-container .leaflet-shadow-pane img, +.leaflet-container .leaflet-tile, +.leaflet-container .leaflet-tile-pane img, +.leaflet-container img.leaflet-image-layer { + max-height: none !important; + max-width: none !important; + padding: 0; + width: auto; +} +.leaflet-container img.leaflet-tile { + mix-blend-mode: plus-lighter; +} +.leaflet-container.leaflet-touch-zoom { + touch-action: pan-x pan-y; +} +.leaflet-container.leaflet-touch-drag { + touch-action: none; + touch-action: pinch-zoom; +} +.leaflet-container.leaflet-touch-drag.leaflet-touch-zoom { + touch-action: none; +} +.leaflet-container { + -webkit-tap-highlight-color: transparent; +} +.leaflet-container a { + -webkit-tap-highlight-color: rgba(51, 181, 229, 0.4); +} +.leaflet-tile { + filter: inherit; + visibility: hidden; +} +.leaflet-tile-loaded { + visibility: inherit; +} +.leaflet-zoom-box { + box-sizing: border-box; + height: 0; + width: 0; + z-index: 800; +} +.leaflet-overlay-pane svg { + -moz-user-select: none; +} +.leaflet-pane { + z-index: 400; +} +.leaflet-tile-pane { + z-index: 200; +} +.leaflet-overlay-pane { + z-index: 400; +} +.leaflet-shadow-pane { + z-index: 500; +} +.leaflet-marker-pane { + z-index: 600; +} +.leaflet-tooltip-pane { + z-index: 650; +} +.leaflet-popup-pane { + z-index: 700; +} +.leaflet-map-pane canvas { + z-index: 100; +} +.leaflet-map-pane svg { + z-index: 200; +} +.leaflet-vml-shape { + height: 1px; + width: 1px; +} +.lvml { + behavior: url(#default#VML); + display: inline-block; + position: absolute; +} +.leaflet-control { + pointer-events: visiblePainted; + pointer-events: auto; + position: relative; + z-index: 800; +} +.leaflet-bottom, +.leaflet-top { + pointer-events: none; + position: absolute; + z-index: 1000; +} +.leaflet-top { + top: 0; +} +.leaflet-right { + right: 0; +} +.leaflet-bottom { + bottom: 0; +} +.leaflet-left { + left: 0; +} +.leaflet-control { + clear: both; + float: left; +} +.leaflet-right .leaflet-control { + float: right; +} +.leaflet-top .leaflet-control { + margin-top: 10px; +} +.leaflet-bottom .leaflet-control { + margin-bottom: 10px; +} +.leaflet-left .leaflet-control { + margin-left: 10px; +} +.leaflet-right .leaflet-control { + margin-right: 10px; +} +.leaflet-fade-anim .leaflet-popup { + opacity: 0; + transition: opacity 0.2s linear; +} +.leaflet-fade-anim .leaflet-map-pane .leaflet-popup { + opacity: 1; +} +.leaflet-zoom-animated { + transform-origin: 0 0; +} +svg.leaflet-zoom-animated { + will-change: transform; +} +.leaflet-zoom-anim .leaflet-zoom-animated { + transition: transform 0.25s cubic-bezier(0, 0, 0.25, 1); +} +.leaflet-pan-anim .leaflet-tile, +.leaflet-zoom-anim .leaflet-tile { + transition: none; +} +.leaflet-zoom-anim .leaflet-zoom-hide { + visibility: hidden; +} +.leaflet-interactive { + cursor: pointer; +} +.leaflet-grab { + cursor: grab; +} +.leaflet-crosshair, +.leaflet-crosshair .leaflet-interactive { + cursor: crosshair; +} +.leaflet-control, +.leaflet-popup-pane { + cursor: auto; +} +.leaflet-dragging .leaflet-grab, +.leaflet-dragging .leaflet-grab .leaflet-interactive, +.leaflet-dragging .leaflet-marker-draggable { + cursor: move; + cursor: grabbing; +} +.leaflet-image-layer, +.leaflet-marker-icon, +.leaflet-marker-shadow, +.leaflet-pane > svg path, +.leaflet-tile-container { + pointer-events: none; +} +.leaflet-image-layer.leaflet-interactive, +.leaflet-marker-icon.leaflet-interactive, +.leaflet-pane > svg path.leaflet-interactive, +svg.leaflet-image-layer.leaflet-interactive path { + pointer-events: visiblePainted; + pointer-events: auto; +} +.leaflet-container { + background: #ddd; + outline-offset: 1px; +} +.leaflet-container a { + color: #0078a8; +} +.leaflet-zoom-box { + background: #ffffff80; + border: 2px dotted #38f; +} +.leaflet-container { + font-family: Helvetica Neue, Arial, Helvetica, sans-serif; + font-size: 12px; + font-size: 0.75rem; + line-height: 1.5; +} +.leaflet-bar { + border-radius: 4px; + box-shadow: 0 1px 5px #000000a6; +} +.leaflet-bar a { + background-color: #fff; + border-bottom: 1px solid #ccc; + color: #000; + display: block; + height: 26px; + line-height: 26px; + text-align: center; + text-decoration: none; + width: 26px; +} +.leaflet-bar a, +.leaflet-control-layers-toggle { + background-position: 50% 50%; + background-repeat: no-repeat; + display: block; +} +.leaflet-bar a:focus, +.leaflet-bar a:hover { + background-color: #f4f4f4; +} +.leaflet-bar a:first-child { + border-top-left-radius: 4px; + border-top-right-radius: 4px; +} +.leaflet-bar a:last-child { + border-bottom: none; + border-bottom-left-radius: 4px; + border-bottom-right-radius: 4px; +} +.leaflet-bar a.leaflet-disabled { + background-color: #f4f4f4; + color: #bbb; + cursor: default; +} +.leaflet-touch .leaflet-bar a { + height: 30px; + line-height: 30px; + width: 30px; +} +.leaflet-touch .leaflet-bar a:first-child { + border-top-left-radius: 2px; + border-top-right-radius: 2px; +} +.leaflet-touch .leaflet-bar a:last-child { + border-bottom-left-radius: 2px; + border-bottom-right-radius: 2px; +} +.leaflet-control-zoom-in, +.leaflet-control-zoom-out { + font: 700 18px Lucida Console, Monaco, monospace; + text-indent: 1px; +} +.leaflet-touch .leaflet-control-zoom-in, +.leaflet-touch .leaflet-control-zoom-out { + font-size: 22px; +} +.leaflet-control-layers { + background: #fff; + border-radius: 5px; + box-shadow: 0 1px 5px #0006; +} +.leaflet-control-layers-toggle { + background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABoAAAAaCAQAAAADQ4RFAAACf0lEQVR4AY1UM3gkARTePdvdoTxXKc+qTl3aU5U6b2Kbkz3Gtq3Zw6ziLGNPzrYx7946Tr6/ee/XeCQ4D3ykPtL5tHno4n0d/h3+xfuWHGLX81cn7r0iTNzjr7LrlxCqPtkbTQEHeqOrTy4Yyt3VCi/IOB0v7rVC7q45Q3Gr5K6jt+3Gl5nCoDD4MtO+j96Wu8atmhGqcNGHObuf8OM/x3AMx38+4Z2sPqzCxRFK2aF2e5Jol56XTLyggAMTL56XOMoS1W4pOyjUcGGQdZxU6qRh7B9Zp+PfpOFlqt0zyDZckPi1ttmIp03jX8gyJ8a/PG2yutpS/Vol7peZIbZcKBAEEheEIAgFbDkz5H6Zrkm2hVWGiXKiF4Ycw0RWKdtC16Q7qe3X4iOMxruonzegJzWaXFrU9utOSsLUmrc0YjeWYjCW4PDMADElpJSSQ0vQvA1Tm6/JlKnqFs1EGyZiFCqnRZTEJJJiKRYzVYzJck2Rm6P4iH+cmSY0YzimYa8l0EtTODFWhcMIMVqdsI2uiTvKmTisIDHJ3od5GILVhBCarCfVRmo4uTjkhrhzkiBV7SsaqS+TzrzM1qpGGUFt28pIySQHR6h7F6KSwGWm97ay+Z+ZqMcEjEWebE7wxCSQwpkhJqoZA5ivCdZDjJepuJ9IQjGGUmuXJdBFUygxVqVsxFsLMbDe8ZbDYVCGKxs+W080max1hFCarCfV+C1KATwcnvE9gRRuMP2prdbWGowm1KB1y+zwMMENkM755cJ2yPDtqhTI6ED1M/82yIDtC/4j4BijjeObflpO9I9MwXTCsSX8jWAFeHr05WoLTJ5G8IQVS/7vwR6ohirYM7f6HzYpogfS3R2OAAAAAElFTkSuQmCC); + height: 36px; + width: 36px; +} +.leaflet-retina .leaflet-control-layers-toggle { + background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADQAAAA0CAQAAABvcdNgAAAEsklEQVR4AWL4TydIhpZK1kpWOlg0w3ZXP6D2soBtG42jeI6ZmQTHzAxiTbSJsYLjO9HhP+WOmcuhciVnmHVQcJnp7DFvScowZorad/+V/fVzMdMT2g9Cv9guXGv/7pYOrXh2U+RRR3dSd9JRx6bIFc/ekqHI29JC6pJ5ZEh1yWkhkbcFeSjxgx3L2m1cb1C7bceyxA+CNjT/Ifff+/kDk2u/w/33/IeCMOSaWZ4glosqT3DNnNZQ7Cs58/3Ce5HL78iZH/vKVIaYlqzfdLu8Vi7dnvUbEza5Idt36tquZFldl6N5Z/POLof0XLK61mZCmJSWjVF9tEjUluu74IUXvgttuVIHE7YxSkaYhJZam7yiM9Pv82JYfl9nptxZaxMJE4YSPty+vF0+Y2up9d3wwijfjZbabqm/3bZ9ecKHsiGmRflnn1MW4pjHf9oLufyn2z3y1D6n8g8TZhxyzipLNPnAUpsOiuWimg52psrTZYnOWYNDTMuWBWa0tJb4rgq1UvmutpaYEbZlwU3CLJm/ayYjHW5/h7xWLn9Hh1vepDkyf7dE7MtT5LR4e7yYpHrkhOUpEfssBLq2pPhAqoSWKUkk7EDqkmK6RrCEzqDjhNDWNE+XSMvkJRDWlZTmCW0l0PHQGRZY5t1L83kT0Y3l2SItk5JAWHl2dCOBm+fPu3fo5/3v61RMCO9Jx2EEYYhb0rmNQMX/vm7gqOEJLcXTGw3CAuRNeyaPWwjR8PRqKQ1PDA/dpv+on9Shox52WFnx0KY8onHayrJzm87i5h9xGw/tfkev0jGsQizqezUKjk12hBMKJ4kbCqGPVNXudyyrShovGw5CgxsRICxF6aRmSjlBnHRzg7Gx8fKqEubI2rahQYdR1YgDIRQO7JvQyD52hoIQx0mxa0ODtW2Iozn1le2iIRdzwWewedyZzewidueOGqlsn1MvcnQpuVwLGG3/IR1hIKxCjelIDZ8ldqWz25jWAsnldEnK0Zxro19TGVb2ffIZEsIO89EIEDvKMPrzmBOQcKQ+rroye6NgRRxqR4U8EAkz0CL6uSGOm6KQCdWjvjRiSP1BPalCRS5iQYiEIvxuBMJEWgzSoHADcVMuN7IuqqTeyUPq22qFimFtxDyBBJEwNyt6TM88blFHao/6tWWhuuOM4SAK4EI4QmFHA+SEyWlp4EQoJ13cYGzMu7yszEIBOm2rVmHUNqwAIQabISNMRstmdhNWcFLsSm+0tjJH1MdRxO5Nx0WDMhCtgD6OKgZeljJqJKc9po8juskR9XN0Y1lZ3mWjLR9JCO1jRDMd0fpYC2VnvjBSEFg7wBENc0R9HFlb0xvF1+TBEpF68d+DHR6IOWVv2BECtxo46hOFUBd/APU57WIoEwJhIi2CdpyZX0m93BZicktMj1AS9dClteUFAUNUIEygRZCtik5zSxI9MubTBH1GOiHsiLJ3OCoSZkILa9PxiN0EbvhsAo8tdAf9Seepd36lGWHmtNANTv5Jd0z4QYyeo/UEJqxKRpg5LZx6btLPsOaEmdMyxYdlc8LMaJnikDlhclqmPiQnTEpLUIZEwkRagjYkEibQErwhkTAKCLQEbUgkzJQWc/0PstHHcfEdQ+UAAAAASUVORK5CYII=); + background-size: 26px 26px; +} +.leaflet-touch .leaflet-control-layers-toggle { + height: 44px; + width: 44px; +} +.leaflet-control-layers .leaflet-control-layers-list, +.leaflet-control-layers-expanded .leaflet-control-layers-toggle { + display: none; +} +.leaflet-control-layers-expanded .leaflet-control-layers-list { + display: block; + position: relative; +} +.leaflet-control-layers-expanded { + background: #fff; + color: #333; + padding: 6px 10px 6px 6px; +} +.leaflet-control-layers-scrollbar { + overflow-x: hidden; + overflow-y: scroll; + padding-right: 5px; +} +.leaflet-control-layers-selector { + margin-top: 2px; + position: relative; + top: 1px; +} +.leaflet-control-layers label { + display: block; + font-size: 13px; + font-size: 1.08333em; +} +.leaflet-control-layers-separator { + border-top: 1px solid #ddd; + height: 0; + margin: 5px -10px 5px -6px; +} +.leaflet-default-icon-path { + background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABkAAAApCAYAAADAk4LOAAAFgUlEQVR4Aa1XA5BjWRTN2oW17d3YaZtr2962HUzbDNpjszW24mRt28p47v7zq/bXZtrp/lWnXr337j3nPCe85NcypgSFdugCpW5YoDAMRaIMqRi6aKq5E3YqDQO3qAwjVWrD8Ncq/RBpykd8oZUb/kaJutow8r1aP9II0WmLKLIsJyv1w/kqw9Ch2MYdB++12Onxee/QMwvf4/Dk/Lfp/i4nxTXtOoQ4pW5Aj7wpici1A9erdAN2OH64x8OSP9j3Ft3b7aWkTg/Fm91siTra0f9on5sQr9INejH6CUUUpavjFNq1B+Oadhxmnfa8RfEmN8VNAsQhPqF55xHkMzz3jSmChWU6f7/XZKNH+9+hBLOHYozuKQPxyMPUKkrX/K0uWnfFaJGS1QPRtZsOPtr3NsW0uyh6NNCOkU3Yz+bXbT3I8G3xE5EXLXtCXbbqwCO9zPQYPRTZ5vIDXD7U+w7rFDEoUUf7ibHIR4y6bLVPXrz8JVZEql13trxwue/uDivd3fkWRbS6/IA2bID4uk0UpF1N8qLlbBlXs4Ee7HLTfV1j54APvODnSfOWBqtKVvjgLKzF5YdEk5ewRkGlK0i33Eofffc7HT56jD7/6U+qH3Cx7SBLNntH5YIPvODnyfIXZYRVDPqgHtLs5ABHD3YzLuespb7t79FY34DjMwrVrcTuwlT55YMPvOBnRrJ4VXTdNnYug5ucHLBjEpt30701A3Ts+HEa73u6dT3FNWwflY86eMHPk+Yu+i6pzUpRrW7SNDg5JHR4KapmM5Wv2E8Tfcb1HoqqHMHU+uWDD7zg54mz5/2BSnizi9T1Dg4QQXLToGNCkb6tb1NU+QAlGr1++eADrzhn/u8Q2YZhQVlZ5+CAOtqfbhmaUCS1ezNFVm2imDbPmPng5wmz+gwh+oHDce0eUtQ6OGDIyR0uUhUsoO3vfDmmgOezH0mZN59x7MBi++WDL1g/eEiU3avlidO671bkLfwbw5XV2P8Pzo0ydy4t2/0eu33xYSOMOD8hTf4CrBtGMSoXfPLchX+J0ruSePw3LZeK0juPJbYzrhkH0io7B3k164hiGvawhOKMLkrQLyVpZg8rHFW7E2uHOL888IBPlNZ1FPzstSJM694fWr6RwpvcJK60+0HCILTBzZLFNdtAzJaohze60T8qBzyh5ZuOg5e7uwQppofEmf2++DYvmySqGBuKaicF1blQjhuHdvCIMvp8whTTfZzI7RldpwtSzL+F1+wkdZ2TBOW2gIF88PBTzD/gpeREAMEbxnJcaJHNHrpzji0gQCS6hdkEeYt9DF/2qPcEC8RM28Hwmr3sdNyht00byAut2k3gufWNtgtOEOFGUwcXWNDbdNbpgBGxEvKkOQsxivJx33iow0Vw5S6SVTrpVq11ysA2Rp7gTfPfktc6zhtXBBC+adRLshf6sG2RfHPZ5EAc4sVZ83yCN00Fk/4kggu40ZTvIEm5g24qtU4KjBrx/BTTH8ifVASAG7gKrnWxJDcU7x8X6Ecczhm3o6YicvsLXWfh3Ch1W0k8x0nXF+0fFxgt4phz8QvypiwCCFKMqXCnqXExjq10beH+UUA7+nG6mdG/Pu0f3LgFcGrl2s0kNNjpmoJ9o4B29CMO8dMT4Q5ox8uitF6fqsrJOr8qnwNbRzv6hSnG5wP+64C7h9lp30hKNtKdWjtdkbuPA19nJ7Tz3zR/ibgARbhb4AlhavcBebmTHcFl2fvYEnW0ox9xMxKBS8btJ+KiEbq9zA4RthQXDhPa0T9TEe69gWupwc6uBUphquXgf+/FrIjweHQS4/pduMe5ERUMHUd9xv8ZR98CxkS4F2n3EUrUZ10EYNw7BWm9x1GiPssi3GgiGRDKWRYZfXlON+dfNbM+GgIwYdwAAAAASUVORK5CYII=); +} +.leaflet-container .leaflet-control-attribution { + background: #fff; + background: #fffc; + margin: 0; +} +.leaflet-control-attribution, +.leaflet-control-scale-line { + color: #333; + line-height: 1.4; + padding: 0 5px; +} +.leaflet-control-attribution a { + text-decoration: none; +} +.leaflet-control-attribution a:focus, +.leaflet-control-attribution a:hover { + text-decoration: underline; +} +.leaflet-attribution-flag { + display: inline !important; + height: 0.6669em; + vertical-align: initial !important; + width: 1em; +} +.leaflet-left .leaflet-control-scale { + margin-left: 5px; +} +.leaflet-bottom .leaflet-control-scale { + margin-bottom: 5px; +} +.leaflet-control-scale-line { + background: #fffc; + border: 2px solid #777; + border-top: none; + box-sizing: border-box; + line-height: 1.1; + padding: 2px 5px 1px; + text-shadow: 1px 1px #fff; + white-space: nowrap; +} +.leaflet-control-scale-line:not(:first-child) { + border-bottom: none; + border-top: 2px solid #777; + margin-top: -2px; +} +.leaflet-control-scale-line:not(:first-child):not(:last-child) { + border-bottom: 2px solid #777; +} +.leaflet-touch .leaflet-bar, +.leaflet-touch .leaflet-control-attribution, +.leaflet-touch .leaflet-control-layers { + box-shadow: none; +} +.leaflet-touch .leaflet-bar, +.leaflet-touch .leaflet-control-layers { + background-clip: padding-box; + border: 2px solid #0003; +} +.leaflet-popup { + margin-bottom: 20px; + position: absolute; + text-align: center; +} +.leaflet-popup-content-wrapper { + border-radius: 12px; + padding: 1px; + text-align: left; +} +.leaflet-popup-content { + font-size: 13px; + font-size: 1.08333em; + line-height: 1.3; + margin: 13px 24px 13px 20px; + min-height: 1px; +} +.leaflet-popup-content p { + margin: 1.3em 0; +} +.leaflet-popup-tip-container { + height: 20px; + left: 50%; + margin-left: -20px; + margin-top: -1px; + overflow: hidden; + pointer-events: none; + position: absolute; + width: 40px; +} +.leaflet-popup-tip { + height: 17px; + margin: -10px auto 0; + padding: 1px; + pointer-events: auto; + transform: rotate(45deg); + width: 17px; +} +.leaflet-popup-content-wrapper, +.leaflet-popup-tip { + background: #fff; + box-shadow: 0 3px 14px #0006; + color: #333; +} +.leaflet-container a.leaflet-popup-close-button { + background: #0000; + border: none; + color: #757575; + font: 16px/24px Tahoma, Verdana, sans-serif; + height: 24px; + position: absolute; + right: 0; + text-align: center; + text-decoration: none; + top: 0; + width: 24px; +} +.leaflet-container a.leaflet-popup-close-button:focus, +.leaflet-container a.leaflet-popup-close-button:hover { + color: #585858; +} +.leaflet-popup-scrolled { + overflow: auto; +} +.leaflet-oldie .leaflet-popup-content-wrapper { + -ms-zoom: 1; +} +.leaflet-oldie .leaflet-popup-tip { + -ms-filter: "progid:DXImageTransform.Microsoft.Matrix(M11=0.70710678, M12=0.70710678, M21=-0.70710678, M22=0.70710678)"; + filter: progid:DXImageTransform.Microsoft.Matrix(M11=0.70710678,M12=0.70710678,M21=-0.70710678,M22=0.70710678); + margin: 0 auto; + width: 24px; +} +.leaflet-oldie .leaflet-control-layers, +.leaflet-oldie .leaflet-control-zoom, +.leaflet-oldie .leaflet-popup-content-wrapper, +.leaflet-oldie .leaflet-popup-tip { + border: 1px solid #999; +} +.leaflet-div-icon { + background: #fff; + border: 1px solid #666; +} +.leaflet-tooltip { + background-color: #fff; + border: 1px solid #fff; + border-radius: 3px; + box-shadow: 0 1px 3px #0006; + color: #222; + padding: 6px; + pointer-events: none; + position: absolute; + -webkit-user-select: none; + user-select: none; + white-space: nowrap; +} +.leaflet-tooltip.leaflet-interactive { + cursor: pointer; + pointer-events: auto; +} +.leaflet-tooltip-bottom:before, +.leaflet-tooltip-left:before, +.leaflet-tooltip-right:before, +.leaflet-tooltip-top:before { + background: #0000; + border: 6px solid #0000; + content: ""; + pointer-events: none; + position: absolute; +} +.leaflet-tooltip-bottom { + margin-top: 6px; +} +.leaflet-tooltip-top { + margin-top: -6px; +} +.leaflet-tooltip-bottom:before, +.leaflet-tooltip-top:before { + left: 50%; + margin-left: -6px; +} +.leaflet-tooltip-top:before { + border-top-color: #fff; + bottom: 0; + margin-bottom: -12px; +} +.leaflet-tooltip-bottom:before { + border-bottom-color: #fff; + margin-left: -6px; + margin-top: -12px; + top: 0; +} +.leaflet-tooltip-left { + margin-left: -6px; +} +.leaflet-tooltip-right { + margin-left: 6px; +} +.leaflet-tooltip-left:before, +.leaflet-tooltip-right:before { + margin-top: -6px; + top: 50%; +} +.leaflet-tooltip-left:before { + border-left-color: #fff; + margin-right: -12px; + right: 0; +} +.leaflet-tooltip-right:before { + border-right-color: #fff; + left: 0; + margin-left: -12px; +} +@media print { + .leaflet-control { + -webkit-print-color-adjust: exact; + print-color-adjust: exact; + } +} +.App { + background: #f5f5f5; + display: flex; + flex-direction: column; + font-family: system-ui, sans-serif; + height: 100vh; +} +ul { + list-style: none; + padding: 0; +} +li { + margin-bottom: 0.5rem; +} +.main-content { + display: flex; + flex: 1 1 auto; + overflow-y: auto; + overflow: hidden; + z-index: 1; +} +.park-list { + background: #fff; + border-radius: 10px; + border-right: 1px solid #ddd; + overflow-x: hidden; + overflow-y: auto; + padding: 0 0.5rem; + width: 20%; +} +.map-section { + display: flex; + flex: 1 1 auto; + flex-direction: column; + overflow: hidden; + padding: 0 0.5rem; +} +.sticky-header { + background: #fff; + box-shadow: 0 2px 4px #0000001a; + justify-content: space-between; + padding: 0.75rem 1rem; + position: -webkit-sticky; + position: sticky; + top: 0; + z-index: 999; +} +.controls, +.sticky-header { + align-items: center; + display: flex; +} +.controls { + flex-wrap: wrap; + gap: 1rem; +} +.leaflet-container { + border-radius: 10px; + flex: 1 1 auto; + height: 100%; + width: 100%; +} +ul.park-list { + display: flex; + flex-wrap: wrap; + gap: 1rem; + list-style: none; + margin: 0; + padding: 0; +} +.park-card { + background: #fff; + border-radius: 8px; + box-shadow: 0 2px 6px #0000001a; + display: flex; + flex: 1 0 250px; + flex-direction: column; + overflow: hidden; +} +.park-card__img { + display: block; + height: 140px; + object-fit: cover; + width: 100%; +} +.park-card__label { + font-size: 0.9rem; + padding: 0.75rem 0.75rem 1rem; +} +/*# sourceMappingURL=main.149f127c.css.map*/ diff --git a/static/css/relative_rank.css b/app/static/css/relative_rank.css similarity index 100% rename from static/css/relative_rank.css rename to app/static/css/relative_rank.css diff --git a/static/css/short_stories.css b/app/static/css/short_stories.css similarity index 100% rename from static/css/short_stories.css rename to app/static/css/short_stories.css diff --git a/static/css/styles.css b/app/static/css/styles.css similarity index 100% rename from static/css/styles.css rename to app/static/css/styles.css diff --git a/static/favicon.ico b/app/static/favicon.ico similarity index 100% rename from static/favicon.ico rename to app/static/favicon.ico diff --git a/app/static/js/nationalparks.js b/app/static/js/nationalparks.js new file mode 100644 index 0000000..8f47b02 --- /dev/null +++ b/app/static/js/nationalparks.js @@ -0,0 +1,3 @@ +/*! For license information please see main.6717997b.js.LICENSE.txt */ +(()=>{var e={4:(e,t,n)=>{"use strict";var i=n(853),o=n(43),r=n(950);function a(e){var t="https://react.dev/errors/"+e;if(1D||(e.current=B[D],B[D]=null,D--)}function F(e,t){D++,B[D]=e.current,e.current=t}var H=Z(null),U=Z(null),W=Z(null),V=Z(null);function q(e,t){switch(F(W,t),F(U,e),F(H,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?oh(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)e=rh(t=oh(t),e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}j(H),F(H,e)}function K(){j(H),j(U),j(W)}function Q(e){null!==e.memoizedState&&F(V,e);var t=H.current,n=rh(t,e.type);t!==n&&(F(U,e),F(H,n))}function G(e){U.current===e&&(j(H),j(U)),V.current===e&&(j(V),Qh._currentValue=R)}var Y=Object.prototype.hasOwnProperty,X=i.unstable_scheduleCallback,J=i.unstable_cancelCallback,$=i.unstable_shouldYield,ee=i.unstable_requestPaint,te=i.unstable_now,ne=i.unstable_getCurrentPriorityLevel,ie=i.unstable_ImmediatePriority,oe=i.unstable_UserBlockingPriority,re=i.unstable_NormalPriority,ae=i.unstable_LowPriority,se=i.unstable_IdlePriority,le=i.log,ue=i.unstable_setDisableYieldValue,ce=null,he=null;function de(e){if("function"===typeof le&&ue(e),he&&"function"===typeof he.setStrictMode)try{he.setStrictMode(ce,e)}catch(t){}}var fe=Math.clz32?Math.clz32:function(e){return 0===(e>>>=0)?32:31-(pe(e)/me|0)|0},pe=Math.log,me=Math.LN2;var ge=256,_e=4194304;function ve(e){var t=42&e;if(0!==t)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return 4194048&e;case 4194304:case 8388608:case 16777216:case 33554432:return 62914560&e;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function ye(e,t,n){var i=e.pendingLanes;if(0===i)return 0;var o=0,r=e.suspendedLanes,a=e.pingedLanes;e=e.warmLanes;var s=134217727&i;return 0!==s?0!==(i=s&~r)?o=ve(i):0!==(a&=s)?o=ve(a):n||0!==(n=s&~e)&&(o=ve(n)):0!==(s=i&~r)?o=ve(s):0!==a?o=ve(a):n||0!==(n=i&~e)&&(o=ve(n)),0===o?0:0!==t&&t!==o&&0===(t&r)&&((r=o&-o)>=(n=t&-t)||32===r&&0!==(4194048&n))?t:o}function be(e,t){return 0===(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)}function we(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;default:return-1}}function ke(){var e=ge;return 0===(4194048&(ge<<=1))&&(ge=256),e}function xe(){var e=_e;return 0===(62914560&(_e<<=1))&&(_e=4194304),e}function Se(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Pe(e,t){e.pendingLanes|=t,268435456!==t&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function Le(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var i=31-fe(t);e.entangledLanes|=t,e.entanglements[i]=1073741824|e.entanglements[i]|4194090&n}function Ee(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var i=31-fe(n),o=1<)":-1--o||l[i]!==u[o]){var c="\n"+l[i].replace(" at new "," at ");return e.displayName&&c.includes("")&&(c=c.replace("",e.displayName)),c}}while(1<=i&&0<=o);break}}}finally{rt=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:"")?ot(n):""}function st(e){switch(e.tag){case 26:case 27:case 5:return ot(e.type);case 16:return ot("Lazy");case 13:return ot("Suspense");case 19:return ot("SuspenseList");case 0:case 15:return at(e.type,!1);case 11:return at(e.type.render,!1);case 1:return at(e.type,!0);case 31:return ot("Activity");default:return""}}function lt(e){try{var t="";do{t+=st(e),e=e.return}while(e);return t}catch(n){return"\nError generating stack: "+n.message+"\n"+n.stack}}function ut(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":case"object":return e;default:return""}}function ct(e){var t=e.type;return(e=e.nodeName)&&"input"===e.toLowerCase()&&("checkbox"===t||"radio"===t)}function ht(e){e._valueTracker||(e._valueTracker=function(e){var t=ct(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),i=""+e[t];if(!e.hasOwnProperty(t)&&"undefined"!==typeof n&&"function"===typeof n.get&&"function"===typeof n.set){var o=n.get,r=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return o.call(this)},set:function(e){i=""+e,r.call(this,e)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return i},setValue:function(e){i=""+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}(e))}function dt(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),i="";return e&&(i=ct(e)?e.checked?"true":"false":e.value),(e=i)!==n&&(t.setValue(e),!0)}function ft(e){if("undefined"===typeof(e=e||("undefined"!==typeof document?document:void 0)))return null;try{return e.activeElement||e.body}catch(t){return e.body}}var pt=/[\n"\\]/g;function mt(e){return e.replace(pt,function(e){return"\\"+e.charCodeAt(0).toString(16)+" "})}function gt(e,t,n,i,o,r,a,s){e.name="",null!=a&&"function"!==typeof a&&"symbol"!==typeof a&&"boolean"!==typeof a?e.type=a:e.removeAttribute("type"),null!=t?"number"===a?(0===t&&""===e.value||e.value!=t)&&(e.value=""+ut(t)):e.value!==""+ut(t)&&(e.value=""+ut(t)):"submit"!==a&&"reset"!==a||e.removeAttribute("value"),null!=t?vt(e,a,ut(t)):null!=n?vt(e,a,ut(n)):null!=i&&e.removeAttribute("value"),null==o&&null!=r&&(e.defaultChecked=!!r),null!=o&&(e.checked=o&&"function"!==typeof o&&"symbol"!==typeof o),null!=s&&"function"!==typeof s&&"symbol"!==typeof s&&"boolean"!==typeof s?e.name=""+ut(s):e.removeAttribute("name")}function _t(e,t,n,i,o,r,a,s){if(null!=r&&"function"!==typeof r&&"symbol"!==typeof r&&"boolean"!==typeof r&&(e.type=r),null!=t||null!=n){if(!("submit"!==r&&"reset"!==r||void 0!==t&&null!==t))return;n=null!=n?""+ut(n):"",t=null!=t?""+ut(t):n,s||t===e.value||(e.value=t),e.defaultValue=t}i="function"!==typeof(i=null!=i?i:o)&&"symbol"!==typeof i&&!!i,e.checked=s?e.checked:!!i,e.defaultChecked=!!i,null!=a&&"function"!==typeof a&&"symbol"!==typeof a&&"boolean"!==typeof a&&(e.name=a)}function vt(e,t,n){"number"===t&&ft(e.ownerDocument)===e||e.defaultValue===""+n||(e.defaultValue=""+n)}function yt(e,t,n,i){if(e=e.options,t){t={};for(var o=0;o=xn),Ln=String.fromCharCode(32),En=!1;function Tn(e,t){switch(e){case"keyup":return-1!==wn.indexOf(t.keyCode);case"keydown":return 229!==t.keyCode;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Cn(e){return"object"===typeof(e=e.detail)&&"data"in e?e.data:null}var zn=!1;var Mn={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function On(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return"input"===t?!!Mn[e.type]:"textarea"===t}function An(e,t,n,i){Ot?At?At.push(i):At=[i]:Ot=i,0<(t=Wc(t,"onChange")).length&&(n=new $t("onChange","change",null,n,i),e.push({event:n,listeners:t}))}var Nn=null,In=null;function Rn(e){Rc(e,0)}function Bn(e){if(dt(Ue(e)))return e}function Dn(e,t){if("change"===e)return t}var Zn=!1;if(Dt){var jn;if(Dt){var Fn="oninput"in document;if(!Fn){var Hn=document.createElement("div");Hn.setAttribute("oninput","return;"),Fn="function"===typeof Hn.oninput}jn=Fn}else jn=!1;Zn=jn&&(!document.documentMode||9=t)return{node:i,offset:t-e};e=n}e:{for(;i;){if(i.nextSibling){i=i.nextSibling;break e}i=i.parentNode}i=void 0}i=Xn(i)}}function $n(e,t){return!(!e||!t)&&(e===t||(!e||3!==e.nodeType)&&(t&&3===t.nodeType?$n(e,t.parentNode):"contains"in e?e.contains(t):!!e.compareDocumentPosition&&!!(16&e.compareDocumentPosition(t))))}function ei(e){for(var t=ft((e=null!=e&&null!=e.ownerDocument&&null!=e.ownerDocument.defaultView?e.ownerDocument.defaultView:window).document);t instanceof e.HTMLIFrameElement;){try{var n="string"===typeof t.contentWindow.location.href}catch(i){n=!1}if(!n)break;t=ft((e=t.contentWindow).document)}return t}function ti(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&("input"===t&&("text"===e.type||"search"===e.type||"tel"===e.type||"url"===e.type||"password"===e.type)||"textarea"===t||"true"===e.contentEditable)}var ni=Dt&&"documentMode"in document&&11>=document.documentMode,ii=null,oi=null,ri=null,ai=!1;function si(e,t,n){var i=n.window===n?n.document:9===n.nodeType?n:n.ownerDocument;ai||null==ii||ii!==ft(i)||("selectionStart"in(i=ii)&&ti(i)?i={start:i.selectionStart,end:i.selectionEnd}:i={anchorNode:(i=(i.ownerDocument&&i.ownerDocument.defaultView||window).getSelection()).anchorNode,anchorOffset:i.anchorOffset,focusNode:i.focusNode,focusOffset:i.focusOffset},ri&&Yn(ri,i)||(ri=i,0<(i=Wc(oi,"onSelect")).length&&(t=new $t("onSelect","select",null,t,n),e.push({event:t,listeners:i}),t.target=ii)))}function li(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var ui={animationend:li("Animation","AnimationEnd"),animationiteration:li("Animation","AnimationIteration"),animationstart:li("Animation","AnimationStart"),transitionrun:li("Transition","TransitionRun"),transitionstart:li("Transition","TransitionStart"),transitioncancel:li("Transition","TransitionCancel"),transitionend:li("Transition","TransitionEnd")},ci={},hi={};function di(e){if(ci[e])return ci[e];if(!ui[e])return e;var t,n=ui[e];for(t in n)if(n.hasOwnProperty(t)&&t in hi)return ci[e]=n[t];return e}Dt&&(hi=document.createElement("div").style,"AnimationEvent"in window||(delete ui.animationend.animation,delete ui.animationiteration.animation,delete ui.animationstart.animation),"TransitionEvent"in window||delete ui.transitionend.transition);var fi=di("animationend"),pi=di("animationiteration"),mi=di("animationstart"),gi=di("transitionrun"),_i=di("transitionstart"),vi=di("transitioncancel"),yi=di("transitionend"),bi=new Map,wi="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function ki(e,t){bi.set(e,t),Qe(t,[e])}wi.push("scrollEnd");var xi=new WeakMap;function Si(e,t){if("object"===typeof e&&null!==e){var n=xi.get(e);return void 0!==n?n:(t={value:e,source:t,stack:lt(t)},xi.set(e,t),t)}return{value:e,source:t,stack:lt(t)}}var Pi=[],Li=0,Ei=0;function Ti(){for(var e=Li,t=Ei=Li=0;t>=a,o-=a,Xi=1<<32-fe(t)+o|n<r?r:8;var a=N.T,s={};N.T=s,Fa(e,!1,t,n);try{var l=o(),u=N.S;if(null!==u&&u(s,l),null!==l&&"object"===typeof l&&"function"===typeof l.then)ja(e,t,function(e,t){var n=[],i={status:"pending",value:null,reason:null,then:function(e){n.push(e)}};return e.then(function(){i.status="fulfilled",i.value=t;for(var e=0;ep?(m=h,h=null):m=h.sibling;var g=f(o,h,s[p],l);if(null===g){null===h&&(h=m);break}e&&h&&null===g.alternate&&t(o,h),a=r(g,a,p),null===c?u=g:c.sibling=g,c=g,h=m}if(p===s.length)return n(o,h),ro&&$i(o,p),u;if(null===h){for(;pm?(g=p,p=null):g=p.sibling;var y=f(o,p,v.value,u);if(null===y){null===p&&(p=g);break}e&&p&&null===y.alternate&&t(o,p),s=r(y,s,m),null===h?c=y:h.sibling=y,h=y,p=g}if(v.done)return n(o,p),ro&&$i(o,m),c;if(null===p){for(;!v.done;m++,v=l.next())null!==(v=d(o,v.value,u))&&(s=r(v,s,m),null===h?c=v:h.sibling=v,h=v);return ro&&$i(o,m),c}for(p=i(p);!v.done;m++,v=l.next())null!==(v=_(p,o,m,v.value,u))&&(e&&null!==v.alternate&&p.delete(null===v.key?m:v.key),s=r(v,s,m),null===h?c=v:h.sibling=v,h=v);return e&&p.forEach(function(e){return t(o,e)}),ro&&$i(o,m),c}(l,u,c=y.call(c),h)}if("function"===typeof c.then)return v(l,u,Xa(c),h);if(c.$$typeof===w)return v(l,u,To(l,c),h);$a(l,c)}return"string"===typeof c&&""!==c||"number"===typeof c||"bigint"===typeof c?(c=""+c,null!==u&&6===u.tag?(n(l,u.sibling),(h=o(u,c)).return=l,l=h):(n(l,u),(h=Hi(c,l.mode,h)).return=l,l=h),s(l)):n(l,u)}return function(e,t,n,i){try{Ya=0;var o=v(e,t,n,i);return Ga=null,o}catch(a){if(a===qo||a===Qo)throw a;var r=Ri(29,a,null,e.mode);return r.lanes=i,r.return=e,r}}}var ns=ts(!0),is=ts(!1),os=Z(null),rs=null;function as(e){var t=e.alternate;F(cs,1&cs.current),F(os,e),null===rs&&(null===t||null!==pr.current||null!==t.memoizedState)&&(rs=e)}function ss(e){if(22===e.tag){if(F(cs,cs.current),F(os,e),null===rs){var t=e.alternate;null!==t&&null!==t.memoizedState&&(rs=e)}}else ls()}function ls(){F(cs,cs.current),F(os,os.current)}function us(e){j(os),rs===e&&(rs=null),j(cs)}var cs=Z(0);function hs(e){for(var t=e;null!==t;){if(13===t.tag){var n=t.memoizedState;if(null!==n&&(null===(n=n.dehydrated)||"$?"===n.data||gh(n)))return t}else if(19===t.tag&&void 0!==t.memoizedProps.revealOrder){if(0!==(128&t.flags))return t}else if(null!==t.child){t.child.return=t,t=t.child;continue}if(t===e)break;for(;null===t.sibling;){if(null===t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}function ds(e,t,n,i){n=null===(n=n(i,t=e.memoizedState))||void 0===n?t:d({},t,n),e.memoizedState=n,0===e.lanes&&(e.updateQueue.baseState=n)}var fs={enqueueSetState:function(e,t,n){e=e._reactInternals;var i=Nu(),o=rr(i);o.payload=t,void 0!==n&&null!==n&&(o.callback=n),null!==(t=ar(e,o,i))&&(Ru(t,e,i),sr(t,e,i))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var i=Nu(),o=rr(i);o.tag=1,o.payload=t,void 0!==n&&null!==n&&(o.callback=n),null!==(t=ar(e,o,i))&&(Ru(t,e,i),sr(t,e,i))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=Nu(),i=rr(n);i.tag=2,void 0!==t&&null!==t&&(i.callback=t),null!==(t=ar(e,i,n))&&(Ru(t,e,n),sr(t,e,n))}};function ps(e,t,n,i,o,r,a){return"function"===typeof(e=e.stateNode).shouldComponentUpdate?e.shouldComponentUpdate(i,r,a):!t.prototype||!t.prototype.isPureReactComponent||(!Yn(n,i)||!Yn(o,r))}function ms(e,t,n,i){e=t.state,"function"===typeof t.componentWillReceiveProps&&t.componentWillReceiveProps(n,i),"function"===typeof t.UNSAFE_componentWillReceiveProps&&t.UNSAFE_componentWillReceiveProps(n,i),t.state!==e&&fs.enqueueReplaceState(t,t.state,null)}function gs(e,t){var n=t;if("ref"in t)for(var i in n={},t)"ref"!==i&&(n[i]=t[i]);if(e=e.defaultProps)for(var o in n===t&&(n=d({},n)),e)void 0===n[o]&&(n[o]=e[o]);return n}var _s="function"===typeof reportError?reportError:function(e){if("object"===typeof window&&"function"===typeof window.ErrorEvent){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:"object"===typeof e&&null!==e&&"string"===typeof e.message?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if("object"===typeof process&&"function"===typeof process.emit)return void process.emit("uncaughtException",e);console.error(e)};function vs(e){_s(e)}function ys(e){console.error(e)}function bs(e){_s(e)}function ws(e,t){try{(0,e.onUncaughtError)(t.value,{componentStack:t.stack})}catch(n){setTimeout(function(){throw n})}}function ks(e,t,n){try{(0,e.onCaughtError)(n.value,{componentStack:n.stack,errorBoundary:1===t.tag?t.stateNode:null})}catch(i){setTimeout(function(){throw i})}}function xs(e,t,n){return(n=rr(n)).tag=3,n.payload={element:null},n.callback=function(){ws(e,t)},n}function Ss(e){return(e=rr(e)).tag=3,e}function Ps(e,t,n,i){var o=n.type.getDerivedStateFromError;if("function"===typeof o){var r=i.value;e.payload=function(){return o(r)},e.callback=function(){ks(t,n,i)}}var a=n.stateNode;null!==a&&"function"===typeof a.componentDidCatch&&(e.callback=function(){ks(t,n,i),"function"!==typeof o&&(null===Su?Su=new Set([this]):Su.add(this));var e=i.stack;this.componentDidCatch(i.value,{componentStack:null!==e?e:""})})}var Ls=Error(a(461)),Es=!1;function Ts(e,t,n,i){t.child=null===e?is(t,null,n,i):ns(t,e.child,n,i)}function Cs(e,t,n,i,o){n=n.render;var r=t.ref;if("ref"in i){var a={};for(var s in i)"ref"!==s&&(a[s]=i[s])}else a=i;return Lo(t),i=Or(e,t,n,a,r,o),s=Rr(),null===e||Es?(ro&&s&&to(t),t.flags|=1,Ts(e,t,i,o),t.child):(Br(e,t,o),Gs(e,t,o))}function zs(e,t,n,i,o){if(null===e){var r=n.type;return"function"!==typeof r||Bi(r)||void 0!==r.defaultProps||null!==n.compare?((e=ji(n.type,null,i,t,t.mode,o)).ref=t.ref,e.return=t,t.child=e):(t.tag=15,t.type=r,Ms(e,t,r,i,o))}if(r=e.child,!Ys(e,o)){var a=r.memoizedProps;if((n=null!==(n=n.compare)?n:Yn)(a,i)&&e.ref===t.ref)return Gs(e,t,o)}return t.flags|=1,(e=Di(r,i)).ref=t.ref,e.return=t,t.child=e}function Ms(e,t,n,i,o){if(null!==e){var r=e.memoizedProps;if(Yn(r,i)&&e.ref===t.ref){if(Es=!1,t.pendingProps=i=r,!Ys(e,o))return t.lanes=e.lanes,Gs(e,t,o);0!==(131072&e.flags)&&(Es=!0)}}return Is(e,t,n,i,o)}function Os(e,t,n){var i=t.pendingProps,o=i.children,r=null!==e?e.memoizedState:null;if("hidden"===i.mode){if(0!==(128&t.flags)){if(i=null!==r?r.baseLanes|n:n,null!==e){for(o=t.child=e.child,r=0;null!==o;)r=r|o.lanes|o.childLanes,o=o.sibling;t.childLanes=r&~i}else t.childLanes=0,t.child=null;return As(e,t,i,n)}if(0===(536870912&n))return t.lanes=t.childLanes=536870912,As(e,t,null!==r?r.baseLanes|n:n,n);t.memoizedState={baseLanes:0,cachePool:null},null!==e&&Wo(0,null!==r?r.cachePool:null),null!==r?gr(t,r):_r(),ss(t)}else null!==r?(Wo(0,r.cachePool),gr(t,r),ls(),t.memoizedState=null):(null!==e&&Wo(0,null),_r(),ls());return Ts(e,t,o,n),t.child}function As(e,t,n,i){var o=Uo();return o=null===o?null:{parent:Ao._currentValue,pool:o},t.memoizedState={baseLanes:n,cachePool:o},null!==e&&Wo(0,null),_r(),ss(t),null!==e&&So(e,t,i,!0),null}function Ns(e,t){var n=t.ref;if(null===n)null!==e&&null!==e.ref&&(t.flags|=4194816);else{if("function"!==typeof n&&"object"!==typeof n)throw Error(a(284));null!==e&&e.ref===n||(t.flags|=4194816)}}function Is(e,t,n,i,o){return Lo(t),n=Or(e,t,n,i,void 0,o),i=Rr(),null===e||Es?(ro&&i&&to(t),t.flags|=1,Ts(e,t,n,o),t.child):(Br(e,t,o),Gs(e,t,o))}function Rs(e,t,n,i,o,r){return Lo(t),t.updateQueue=null,n=Nr(t,i,n,o),Ar(e),i=Rr(),null===e||Es?(ro&&i&&to(t),t.flags|=1,Ts(e,t,n,r),t.child):(Br(e,t,r),Gs(e,t,r))}function Bs(e,t,n,i,o){if(Lo(t),null===t.stateNode){var r=Ni,a=n.contextType;"object"===typeof a&&null!==a&&(r=Eo(a)),r=new n(i,r),t.memoizedState=null!==r.state&&void 0!==r.state?r.state:null,r.updater=fs,t.stateNode=r,r._reactInternals=t,(r=t.stateNode).props=i,r.state=t.memoizedState,r.refs={},ir(t),a=n.contextType,r.context="object"===typeof a&&null!==a?Eo(a):Ni,r.state=t.memoizedState,"function"===typeof(a=n.getDerivedStateFromProps)&&(ds(t,n,a,i),r.state=t.memoizedState),"function"===typeof n.getDerivedStateFromProps||"function"===typeof r.getSnapshotBeforeUpdate||"function"!==typeof r.UNSAFE_componentWillMount&&"function"!==typeof r.componentWillMount||(a=r.state,"function"===typeof r.componentWillMount&&r.componentWillMount(),"function"===typeof r.UNSAFE_componentWillMount&&r.UNSAFE_componentWillMount(),a!==r.state&&fs.enqueueReplaceState(r,r.state,null),hr(t,i,r,o),cr(),r.state=t.memoizedState),"function"===typeof r.componentDidMount&&(t.flags|=4194308),i=!0}else if(null===e){r=t.stateNode;var s=t.memoizedProps,l=gs(n,s);r.props=l;var u=r.context,c=n.contextType;a=Ni,"object"===typeof c&&null!==c&&(a=Eo(c));var h=n.getDerivedStateFromProps;c="function"===typeof h||"function"===typeof r.getSnapshotBeforeUpdate,s=t.pendingProps!==s,c||"function"!==typeof r.UNSAFE_componentWillReceiveProps&&"function"!==typeof r.componentWillReceiveProps||(s||u!==a)&&ms(t,r,i,a),nr=!1;var d=t.memoizedState;r.state=d,hr(t,i,r,o),cr(),u=t.memoizedState,s||d!==u||nr?("function"===typeof h&&(ds(t,n,h,i),u=t.memoizedState),(l=nr||ps(t,n,l,i,d,u,a))?(c||"function"!==typeof r.UNSAFE_componentWillMount&&"function"!==typeof r.componentWillMount||("function"===typeof r.componentWillMount&&r.componentWillMount(),"function"===typeof r.UNSAFE_componentWillMount&&r.UNSAFE_componentWillMount()),"function"===typeof r.componentDidMount&&(t.flags|=4194308)):("function"===typeof r.componentDidMount&&(t.flags|=4194308),t.memoizedProps=i,t.memoizedState=u),r.props=i,r.state=u,r.context=a,i=l):("function"===typeof r.componentDidMount&&(t.flags|=4194308),i=!1)}else{r=t.stateNode,or(e,t),c=gs(n,a=t.memoizedProps),r.props=c,h=t.pendingProps,d=r.context,u=n.contextType,l=Ni,"object"===typeof u&&null!==u&&(l=Eo(u)),(u="function"===typeof(s=n.getDerivedStateFromProps)||"function"===typeof r.getSnapshotBeforeUpdate)||"function"!==typeof r.UNSAFE_componentWillReceiveProps&&"function"!==typeof r.componentWillReceiveProps||(a!==h||d!==l)&&ms(t,r,i,l),nr=!1,d=t.memoizedState,r.state=d,hr(t,i,r,o),cr();var f=t.memoizedState;a!==h||d!==f||nr||null!==e&&null!==e.dependencies&&Po(e.dependencies)?("function"===typeof s&&(ds(t,n,s,i),f=t.memoizedState),(c=nr||ps(t,n,c,i,d,f,l)||null!==e&&null!==e.dependencies&&Po(e.dependencies))?(u||"function"!==typeof r.UNSAFE_componentWillUpdate&&"function"!==typeof r.componentWillUpdate||("function"===typeof r.componentWillUpdate&&r.componentWillUpdate(i,f,l),"function"===typeof r.UNSAFE_componentWillUpdate&&r.UNSAFE_componentWillUpdate(i,f,l)),"function"===typeof r.componentDidUpdate&&(t.flags|=4),"function"===typeof r.getSnapshotBeforeUpdate&&(t.flags|=1024)):("function"!==typeof r.componentDidUpdate||a===e.memoizedProps&&d===e.memoizedState||(t.flags|=4),"function"!==typeof r.getSnapshotBeforeUpdate||a===e.memoizedProps&&d===e.memoizedState||(t.flags|=1024),t.memoizedProps=i,t.memoizedState=f),r.props=i,r.state=f,r.context=l,i=c):("function"!==typeof r.componentDidUpdate||a===e.memoizedProps&&d===e.memoizedState||(t.flags|=4),"function"!==typeof r.getSnapshotBeforeUpdate||a===e.memoizedProps&&d===e.memoizedState||(t.flags|=1024),i=!1)}return r=i,Ns(e,t),i=0!==(128&t.flags),r||i?(r=t.stateNode,n=i&&"function"!==typeof n.getDerivedStateFromError?null:r.render(),t.flags|=1,null!==e&&i?(t.child=ns(t,e.child,null,o),t.child=ns(t,null,n,o)):Ts(e,t,n,o),t.memoizedState=r.state,e=t.child):e=Gs(e,t,o),e}function Ds(e,t,n,i){return po(),t.flags|=256,Ts(e,t,n,i),t.child}var Zs={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function js(e){return{baseLanes:e,cachePool:Vo()}}function Fs(e,t,n){return e=null!==e?e.childLanes&~n:0,t&&(e|=gu),e}function Hs(e,t,n){var i,o=t.pendingProps,r=!1,s=0!==(128&t.flags);if((i=s)||(i=(null===e||null!==e.memoizedState)&&0!==(2&cs.current)),i&&(r=!0,t.flags&=-129),i=0!==(32&t.flags),t.flags&=-33,null===e){if(ro){if(r?as(t):ls(),ro){var l,u=oo;if(l=u){e:{for(l=u,u=so;8!==l.nodeType;){if(!u){u=null;break e}if(null===(l=_h(l.nextSibling))){u=null;break e}}u=l}null!==u?(t.memoizedState={dehydrated:u,treeContext:null!==Yi?{id:Xi,overflow:Ji}:null,retryLane:536870912,hydrationErrors:null},(l=Ri(18,null,null,0)).stateNode=u,l.return=t,t.child=l,io=t,oo=null,l=!0):l=!1}l||uo(t)}if(null!==(u=t.memoizedState)&&null!==(u=u.dehydrated))return gh(u)?t.lanes=32:t.lanes=536870912,null;us(t)}return u=o.children,o=o.fallback,r?(ls(),u=Ws({mode:"hidden",children:u},r=t.mode),o=Fi(o,r,n,null),u.return=t,o.return=t,u.sibling=o,t.child=u,(r=t.child).memoizedState=js(n),r.childLanes=Fs(e,i,n),t.memoizedState=Zs,o):(as(t),Us(t,u))}if(null!==(l=e.memoizedState)&&null!==(u=l.dehydrated)){if(s)256&t.flags?(as(t),t.flags&=-257,t=Vs(e,t,n)):null!==t.memoizedState?(ls(),t.child=e.child,t.flags|=128,t=null):(ls(),r=o.fallback,u=t.mode,o=Ws({mode:"visible",children:o.children},u),(r=Fi(r,u,n,null)).flags|=2,o.return=t,r.return=t,o.sibling=r,t.child=o,ns(t,e.child,null,n),(o=t.child).memoizedState=js(n),o.childLanes=Fs(e,i,n),t.memoizedState=Zs,t=r);else if(as(t),gh(u)){if(i=u.nextSibling&&u.nextSibling.dataset)var c=i.dgst;i=c,(o=Error(a(419))).stack="",o.digest=i,go({value:o,source:null,stack:null}),t=Vs(e,t,n)}else if(Es||So(e,t,n,!1),i=0!==(n&e.childLanes),Es||i){if(null!==(i=iu)&&(0!==(o=0!==((o=0!==(42&(o=n&-n))?1:Te(o))&(i.suspendedLanes|n))?0:o)&&o!==l.retryLane))throw l.retryLane=o,Mi(e,o),Ru(i,e,o),Ls;"$?"===u.data||Ku(),t=Vs(e,t,n)}else"$?"===u.data?(t.flags|=192,t.child=e.child,t=null):(e=l.treeContext,oo=_h(u.nextSibling),io=t,ro=!0,ao=null,so=!1,null!==e&&(Qi[Gi++]=Xi,Qi[Gi++]=Ji,Qi[Gi++]=Yi,Xi=e.id,Ji=e.overflow,Yi=t),(t=Us(t,o.children)).flags|=4096);return t}return r?(ls(),r=o.fallback,u=t.mode,c=(l=e.child).sibling,(o=Di(l,{mode:"hidden",children:o.children})).subtreeFlags=65011712&l.subtreeFlags,null!==c?r=Di(c,r):(r=Fi(r,u,n,null)).flags|=2,r.return=t,o.return=t,o.sibling=r,t.child=o,o=r,r=t.child,null===(u=e.child.memoizedState)?u=js(n):(null!==(l=u.cachePool)?(c=Ao._currentValue,l=l.parent!==c?{parent:c,pool:c}:l):l=Vo(),u={baseLanes:u.baseLanes|n,cachePool:l}),r.memoizedState=u,r.childLanes=Fs(e,i,n),t.memoizedState=Zs,o):(as(t),e=(n=e.child).sibling,(n=Di(n,{mode:"visible",children:o.children})).return=t,n.sibling=null,null!==e&&(null===(i=t.deletions)?(t.deletions=[e],t.flags|=16):i.push(e)),t.child=n,t.memoizedState=null,n)}function Us(e,t){return(t=Ws({mode:"visible",children:t},e.mode)).return=e,e.child=t}function Ws(e,t){return(e=Ri(22,e,null,t)).lanes=0,e.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null},e}function Vs(e,t,n){return ns(t,e.child,null,n),(e=Us(t,t.pendingProps.children)).flags|=2,t.memoizedState=null,e}function qs(e,t,n){e.lanes|=t;var i=e.alternate;null!==i&&(i.lanes|=t),ko(e.return,t,n)}function Ks(e,t,n,i,o){var r=e.memoizedState;null===r?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:i,tail:n,tailMode:o}:(r.isBackwards=t,r.rendering=null,r.renderingStartTime=0,r.last=i,r.tail=n,r.tailMode=o)}function Qs(e,t,n){var i=t.pendingProps,o=i.revealOrder,r=i.tail;if(Ts(e,t,i.children,n),0!==(2&(i=cs.current)))i=1&i|2,t.flags|=128;else{if(null!==e&&0!==(128&e.flags))e:for(e=t.child;null!==e;){if(13===e.tag)null!==e.memoizedState&&qs(e,n,t);else if(19===e.tag)qs(e,n,t);else if(null!==e.child){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;null===e.sibling;){if(null===e.return||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}i&=1}switch(F(cs,i),o){case"forwards":for(n=t.child,o=null;null!==n;)null!==(e=n.alternate)&&null===hs(e)&&(o=n),n=n.sibling;null===(n=o)?(o=t.child,t.child=null):(o=n.sibling,n.sibling=null),Ks(t,!1,o,n,r);break;case"backwards":for(n=null,o=t.child,t.child=null;null!==o;){if(null!==(e=o.alternate)&&null===hs(e)){t.child=o;break}e=o.sibling,o.sibling=n,n=o,o=e}Ks(t,!0,n,null,r);break;case"together":Ks(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function Gs(e,t,n){if(null!==e&&(t.dependencies=e.dependencies),fu|=t.lanes,0===(n&t.childLanes)){if(null===e)return null;if(So(e,t,n,!1),0===(n&t.childLanes))return null}if(null!==e&&t.child!==e.child)throw Error(a(153));if(null!==t.child){for(n=Di(e=t.child,e.pendingProps),t.child=n,n.return=t;null!==e.sibling;)e=e.sibling,(n=n.sibling=Di(e,e.pendingProps)).return=t;n.sibling=null}return t.child}function Ys(e,t){return 0!==(e.lanes&t)||!(null===(e=e.dependencies)||!Po(e))}function Xs(e,t,n){if(null!==e)if(e.memoizedProps!==t.pendingProps)Es=!0;else{if(!Ys(e,n)&&0===(128&t.flags))return Es=!1,function(e,t,n){switch(t.tag){case 3:q(t,t.stateNode.containerInfo),bo(0,Ao,e.memoizedState.cache),po();break;case 27:case 5:Q(t);break;case 4:q(t,t.stateNode.containerInfo);break;case 10:bo(0,t.type,t.memoizedProps.value);break;case 13:var i=t.memoizedState;if(null!==i)return null!==i.dehydrated?(as(t),t.flags|=128,null):0!==(n&t.child.childLanes)?Hs(e,t,n):(as(t),null!==(e=Gs(e,t,n))?e.sibling:null);as(t);break;case 19:var o=0!==(128&e.flags);if((i=0!==(n&t.childLanes))||(So(e,t,n,!1),i=0!==(n&t.childLanes)),o){if(i)return Qs(e,t,n);t.flags|=128}if(null!==(o=t.memoizedState)&&(o.rendering=null,o.tail=null,o.lastEffect=null),F(cs,cs.current),i)break;return null;case 22:case 23:return t.lanes=0,Os(e,t,n);case 24:bo(0,Ao,e.memoizedState.cache)}return Gs(e,t,n)}(e,t,n);Es=0!==(131072&e.flags)}else Es=!1,ro&&0!==(1048576&t.flags)&&eo(t,Ki,t.index);switch(t.lanes=0,t.tag){case 16:e:{e=t.pendingProps;var i=t.elementType,o=i._init;if(i=o(i._payload),t.type=i,"function"!==typeof i){if(void 0!==i&&null!==i){if((o=i.$$typeof)===k){t.tag=11,t=Cs(null,t,i,e,n);break e}if(o===P){t.tag=14,t=zs(null,t,i,e,n);break e}}throw t=O(i)||i,Error(a(306,t,""))}Bi(i)?(e=gs(i,e),t.tag=1,t=Bs(null,t,i,e,n)):(t.tag=0,t=Is(null,t,i,e,n))}return t;case 0:return Is(e,t,t.type,t.pendingProps,n);case 1:return Bs(e,t,i=t.type,o=gs(i,t.pendingProps),n);case 3:e:{if(q(t,t.stateNode.containerInfo),null===e)throw Error(a(387));i=t.pendingProps;var r=t.memoizedState;o=r.element,or(e,t),hr(t,i,null,n);var s=t.memoizedState;if(i=s.cache,bo(0,Ao,i),i!==r.cache&&xo(t,[Ao],n,!0),cr(),i=s.element,r.isDehydrated){if(r={element:i,isDehydrated:!1,cache:s.cache},t.updateQueue.baseState=r,t.memoizedState=r,256&t.flags){t=Ds(e,t,i,n);break e}if(i!==o){go(o=Si(Error(a(424)),t)),t=Ds(e,t,i,n);break e}if(9===(e=t.stateNode.containerInfo).nodeType)e=e.body;else e="HTML"===e.nodeName?e.ownerDocument.body:e;for(oo=_h(e.firstChild),io=t,ro=!0,ao=null,so=!0,n=is(t,null,i,n),t.child=n;n;)n.flags=-3&n.flags|4096,n=n.sibling}else{if(po(),i===o){t=Gs(e,t,n);break e}Ts(e,t,i,n)}t=t.child}return t;case 26:return Ns(e,t),null===e?(n=Th(t.type,null,t.pendingProps,null))?t.memoizedState=n:ro||(n=t.type,e=t.pendingProps,(i=ih(W.current).createElement(n))[Oe]=t,i[Ae]=e,eh(i,n,e),Ve(i),t.stateNode=i):t.memoizedState=Th(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return Q(t),null===e&&ro&&(i=t.stateNode=bh(t.type,t.pendingProps,W.current),io=t,so=!0,o=oo,fh(t.type)?(vh=o,oo=_h(i.firstChild)):oo=o),Ts(e,t,t.pendingProps.children,n),Ns(e,t),null===e&&(t.flags|=4194304),t.child;case 5:return null===e&&ro&&((o=i=oo)&&(null!==(i=function(e,t,n,i){for(;1===e.nodeType;){var o=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!i&&("INPUT"!==e.nodeName||"hidden"!==e.type))break}else if(i){if(!e[Ze])switch(t){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if("stylesheet"===(r=e.getAttribute("rel"))&&e.hasAttribute("data-precedence"))break;if(r!==o.rel||e.getAttribute("href")!==(null==o.href||""===o.href?null:o.href)||e.getAttribute("crossorigin")!==(null==o.crossOrigin?null:o.crossOrigin)||e.getAttribute("title")!==(null==o.title?null:o.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(((r=e.getAttribute("src"))!==(null==o.src?null:o.src)||e.getAttribute("type")!==(null==o.type?null:o.type)||e.getAttribute("crossorigin")!==(null==o.crossOrigin?null:o.crossOrigin))&&r&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else{if("input"!==t||"hidden"!==e.type)return e;var r=null==o.name?null:""+o.name;if("hidden"===o.type&&e.getAttribute("name")===r)return e}if(null===(e=_h(e.nextSibling)))break}return null}(i,t.type,t.pendingProps,so))?(t.stateNode=i,io=t,oo=_h(i.firstChild),so=!1,o=!0):o=!1),o||uo(t)),Q(t),o=t.type,r=t.pendingProps,s=null!==e?e.memoizedProps:null,i=r.children,ah(o,r)?i=null:null!==s&&ah(o,s)&&(t.flags|=32),null!==t.memoizedState&&(o=Or(e,t,Ir,null,null,n),Qh._currentValue=o),Ns(e,t),Ts(e,t,i,n),t.child;case 6:return null===e&&ro&&((e=n=oo)&&(null!==(n=function(e,t,n){if(""===t)return null;for(;3!==e.nodeType;){if((1!==e.nodeType||"INPUT"!==e.nodeName||"hidden"!==e.type)&&!n)return null;if(null===(e=_h(e.nextSibling)))return null}return e}(n,t.pendingProps,so))?(t.stateNode=n,io=t,oo=null,e=!0):e=!1),e||uo(t)),null;case 13:return Hs(e,t,n);case 4:return q(t,t.stateNode.containerInfo),i=t.pendingProps,null===e?t.child=ns(t,null,i,n):Ts(e,t,i,n),t.child;case 11:return Cs(e,t,t.type,t.pendingProps,n);case 7:return Ts(e,t,t.pendingProps,n),t.child;case 8:case 12:return Ts(e,t,t.pendingProps.children,n),t.child;case 10:return i=t.pendingProps,bo(0,t.type,i.value),Ts(e,t,i.children,n),t.child;case 9:return o=t.type._context,i=t.pendingProps.children,Lo(t),i=i(o=Eo(o)),t.flags|=1,Ts(e,t,i,n),t.child;case 14:return zs(e,t,t.type,t.pendingProps,n);case 15:return Ms(e,t,t.type,t.pendingProps,n);case 19:return Qs(e,t,n);case 31:return i=t.pendingProps,n=t.mode,i={mode:i.mode,children:i.children},null===e?((n=Ws(i,n)).ref=t.ref,t.child=n,n.return=t,t=n):((n=Di(e.child,i)).ref=t.ref,t.child=n,n.return=t,t=n),t;case 22:return Os(e,t,n);case 24:return Lo(t),i=Eo(Ao),null===e?(null===(o=Uo())&&(o=iu,r=No(),o.pooledCache=r,r.refCount++,null!==r&&(o.pooledCacheLanes|=n),o=r),t.memoizedState={parent:i,cache:o},ir(t),bo(0,Ao,o)):(0!==(e.lanes&n)&&(or(e,t),hr(t,null,null,n),cr()),o=e.memoizedState,r=t.memoizedState,o.parent!==i?(o={parent:i,cache:i},t.memoizedState=o,0===t.lanes&&(t.memoizedState=t.updateQueue.baseState=o),bo(0,Ao,i)):(i=r.cache,bo(0,Ao,i),i!==o.cache&&xo(t,[Ao],n,!0))),Ts(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(a(156,t.tag))}function Js(e){e.flags|=4}function $s(e,t){if("stylesheet"!==t.type||0!==(4&t.state.loading))e.flags&=-16777217;else if(e.flags|=16777216,!Fh(t)){if(null!==(t=os.current)&&((4194048&ru)===ru?null!==rs:(62914560&ru)!==ru&&0===(536870912&ru)||t!==rs))throw $o=Go,Ko;e.flags|=8192}}function el(e,t){null!==t&&(e.flags|=4),16384&e.flags&&(t=22!==e.tag?xe():536870912,e.lanes|=t,_u|=t)}function tl(e,t){if(!ro)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;null!==t;)null!==t.alternate&&(n=t),t=t.sibling;null===n?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var i=null;null!==n;)null!==n.alternate&&(i=n),n=n.sibling;null===i?t||null===e.tail?e.tail=null:e.tail.sibling=null:i.sibling=null}}function nl(e){var t=null!==e.alternate&&e.alternate.child===e.child,n=0,i=0;if(t)for(var o=e.child;null!==o;)n|=o.lanes|o.childLanes,i|=65011712&o.subtreeFlags,i|=65011712&o.flags,o.return=e,o=o.sibling;else for(o=e.child;null!==o;)n|=o.lanes|o.childLanes,i|=o.subtreeFlags,i|=o.flags,o.return=e,o=o.sibling;return e.subtreeFlags|=i,e.childLanes=n,t}function il(e,t,n){var i=t.pendingProps;switch(no(t),t.tag){case 31:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:case 1:return nl(t),null;case 3:return n=t.stateNode,i=null,null!==e&&(i=e.memoizedState.cache),t.memoizedState.cache!==i&&(t.flags|=2048),wo(Ao),K(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),null!==e&&null!==e.child||(fo(t)?Js(t):null===e||e.memoizedState.isDehydrated&&0===(256&t.flags)||(t.flags|=1024,mo())),nl(t),null;case 26:return n=t.memoizedState,null===e?(Js(t),null!==n?(nl(t),$s(t,n)):(nl(t),t.flags&=-16777217)):n?n!==e.memoizedState?(Js(t),nl(t),$s(t,n)):(nl(t),t.flags&=-16777217):(e.memoizedProps!==i&&Js(t),nl(t),t.flags&=-16777217),null;case 27:G(t),n=W.current;var o=t.type;if(null!==e&&null!=t.stateNode)e.memoizedProps!==i&&Js(t);else{if(!i){if(null===t.stateNode)throw Error(a(166));return nl(t),null}e=H.current,fo(t)?co(t):(e=bh(o,i,n),t.stateNode=e,Js(t))}return nl(t),null;case 5:if(G(t),n=t.type,null!==e&&null!=t.stateNode)e.memoizedProps!==i&&Js(t);else{if(!i){if(null===t.stateNode)throw Error(a(166));return nl(t),null}if(e=H.current,fo(t))co(t);else{switch(o=ih(W.current),e){case 1:e=o.createElementNS("http://www.w3.org/2000/svg",n);break;case 2:e=o.createElementNS("http://www.w3.org/1998/Math/MathML",n);break;default:switch(n){case"svg":e=o.createElementNS("http://www.w3.org/2000/svg",n);break;case"math":e=o.createElementNS("http://www.w3.org/1998/Math/MathML",n);break;case"script":(e=o.createElement("div")).innerHTML=" + + +
+ + +{% endblock %} \ No newline at end of file diff --git a/templates/pcc.html b/app/templates/pcc.html similarity index 100% rename from templates/pcc.html rename to app/templates/pcc.html diff --git a/templates/relative_rank.html b/app/templates/relative_rank.html similarity index 100% rename from templates/relative_rank.html rename to app/templates/relative_rank.html diff --git a/templates/relative_rank_ai.html b/app/templates/relative_rank_ai.html similarity index 100% rename from templates/relative_rank_ai.html rename to app/templates/relative_rank_ai.html diff --git a/templates/short_stories.html b/app/templates/short_stories.html similarity index 100% rename from templates/short_stories.html rename to app/templates/short_stories.html diff --git a/templates/short_stories_base.html b/app/templates/short_stories_base.html similarity index 100% rename from templates/short_stories_base.html rename to app/templates/short_stories_base.html diff --git a/app/templates/transcript.html b/app/templates/transcript.html new file mode 100644 index 0000000..721dc60 --- /dev/null +++ b/app/templates/transcript.html @@ -0,0 +1,26 @@ +{% extends "base.html" %} +{% block content %} + + +

YouTube Transcript Fetcher

+
+
+ + + + +
+ +{% if transcript %} +

Transcript

+ +
+ + + +
+{% endif %} + + + +{% endblock %} \ No newline at end of file diff --git a/templates/vocabulary.html b/app/templates/vocabulary.html similarity index 100% rename from templates/vocabulary.html rename to app/templates/vocabulary.html diff --git a/templates/weather.html b/app/templates/weather.html similarity index 97% rename from templates/weather.html rename to app/templates/weather.html index e6ac02f..4a78a1f 100644 --- a/templates/weather.html +++ b/app/templates/weather.html @@ -2,7 +2,7 @@ {% block content %} -

Current Weather

+

Current Weather in Fort Worth

diff --git a/compose.yaml b/compose.yaml new file mode 100644 index 0000000..1b69d50 --- /dev/null +++ b/compose.yaml @@ -0,0 +1,13 @@ +services: + web: + build: + context: app + target: builder + # flask requires SIGINT to stop gracefully + # (default stop signal from Compose is SIGTERM) + stop_signal: SIGINT + restart: always + ports: + - '8000:8000' + volumes: + - /Users/nico/Documents/GitHub/flask-practice/app:/app \ No newline at end of file