mirror of
https://github.com/greflm13/StaticGalleryBuilder.git
synced 2026-02-05 02:59:27 +00:00
Compare commits
14 Commits
cfe1585c39
...
v2.9.0
| Author | SHA1 | Date | |
|---|---|---|---|
| 6593e63ea9 | |||
| 027a5688cb | |||
| 1aa9dd716b | |||
| d1f7f62229 | |||
| 2f37f78039 | |||
| b109627bf9 | |||
| 4ef1b429f2 | |||
| b8314c0e3d | |||
| 60f3ca1f20 | |||
| bc519ac5d0 | |||
| b0c1b2ce48 | |||
| faa283efa3 | |||
| ce70aa7bd9 | |||
| 59c7cfd406 |
4
.github/workflows/build-release.yml
vendored
4
.github/workflows/build-release.yml
vendored
@@ -8,7 +8,9 @@ jobs:
|
|||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
- uses: actions/setup-python@v5
|
- uses: actions/setup-python@v5
|
||||||
with:
|
with:
|
||||||
python-version: '3.x'
|
python-version: '3.12'
|
||||||
|
- name: Install PyInstaller
|
||||||
|
run: pip install pyinstaller
|
||||||
- name: Install Dependencies
|
- name: Install Dependencies
|
||||||
run: pip install -r requirements.txt
|
run: pip install -r requirements.txt
|
||||||
- name: Build Package
|
- name: Build Package
|
||||||
|
|||||||
@@ -103,3 +103,7 @@ To generate a web manifest file:
|
|||||||
## License
|
## License
|
||||||
|
|
||||||
This project is licensed under the AGPL-3.0 License. See the [LICENSE](LICENSE) file for details.
|
This project is licensed under the AGPL-3.0 License. See the [LICENSE](LICENSE) file for details.
|
||||||
|
|
||||||
|
## Star History
|
||||||
|
|
||||||
|
[](https://www.star-history.com/#greflm13/StaticGalleryBuilder&type=date&legend=top-left)
|
||||||
|
|||||||
95
builder.py
95
builder.py
@@ -18,11 +18,7 @@ from modules.argumentparser import parse_arguments, Args
|
|||||||
|
|
||||||
# fmt: off
|
# fmt: off
|
||||||
# Constants
|
# Constants
|
||||||
if __package__ is None:
|
SCRIPTDIR = os.path.dirname(os.path.realpath(__file__)).removesuffix(__package__ if __package__ else "")
|
||||||
PACKAGE = ""
|
|
||||||
else:
|
|
||||||
PACKAGE = __package__
|
|
||||||
SCRIPTDIR = os.path.abspath(os.path.dirname(__file__).removesuffix(PACKAGE))
|
|
||||||
STATIC_FILES_DIR = os.path.join(os.path.abspath(SCRIPTDIR), "files")
|
STATIC_FILES_DIR = os.path.join(os.path.abspath(SCRIPTDIR), "files")
|
||||||
VERSION = open(os.path.join(SCRIPTDIR, ".version"), "r", encoding="utf-8").read()
|
VERSION = open(os.path.join(SCRIPTDIR, ".version"), "r", encoding="utf-8").read()
|
||||||
RAW_EXTENSIONS = [
|
RAW_EXTENSIONS = [
|
||||||
@@ -75,7 +71,48 @@ def init_globals(_args: Args, raw: list[str]) -> tuple[Args, list[str]]:
|
|||||||
return _args, raw
|
return _args, raw
|
||||||
|
|
||||||
|
|
||||||
def copy_static_files(_args: Args) -> None:
|
def handle_theme_icon(themepath: str, dest: str) -> None:
|
||||||
|
"""
|
||||||
|
Handle the icon specified in the theme file.
|
||||||
|
"""
|
||||||
|
logger.info("reading theme file", extra={"theme": themepath})
|
||||||
|
with open(themepath, "r", encoding="utf-8") as f:
|
||||||
|
theme = f.read()
|
||||||
|
split = theme.split(".foldericon {")
|
||||||
|
split2 = split[1].split("}", maxsplit=1)
|
||||||
|
themehead = split[0]
|
||||||
|
themetail = split2[1]
|
||||||
|
foldericon = split2[0].strip()
|
||||||
|
foldericon = re.sub(r"/\*.*\*/", "", foldericon)
|
||||||
|
|
||||||
|
for match in re.finditer(r"content: (.*);", foldericon):
|
||||||
|
foldericon = match[1]
|
||||||
|
foldericon = foldericon.replace('"', "")
|
||||||
|
logger.info("found foldericon", extra={"foldericon": foldericon})
|
||||||
|
break
|
||||||
|
|
||||||
|
if "url" in foldericon:
|
||||||
|
logger.info("foldericon in theme file, using it")
|
||||||
|
shutil.copyfile(themepath, dest)
|
||||||
|
else:
|
||||||
|
with open(os.path.join(SCRIPTDIR, foldericon), "r", encoding="utf-8") as f:
|
||||||
|
logger.info("Reading foldericon svg")
|
||||||
|
svg = f.read()
|
||||||
|
|
||||||
|
if "svg.j2" in foldericon:
|
||||||
|
logger.info("foldericon in theme file is a jinja2 template")
|
||||||
|
colorscheme = extract_colorscheme(themepath)
|
||||||
|
for color_key, color_value in colorscheme.items():
|
||||||
|
svg = svg.replace(f"{{{{ {color_key} }}}}", color_value)
|
||||||
|
logger.info("replaced colors in svg")
|
||||||
|
|
||||||
|
svg = urllib.parse.quote(svg)
|
||||||
|
with open(dest, "x", encoding="utf-8") as f:
|
||||||
|
logger.info("writing theme file")
|
||||||
|
f.write(themehead + '\n.foldericon {\n content: url("data:image/svg+xml,' + svg + '");\n}\n' + themetail)
|
||||||
|
|
||||||
|
|
||||||
|
def copy_static_files(_args: Args) -> bool:
|
||||||
"""
|
"""
|
||||||
Copy static files to the root directory.
|
Copy static files to the root directory.
|
||||||
|
|
||||||
@@ -85,6 +122,7 @@ def copy_static_files(_args: Args) -> None:
|
|||||||
Parsed command-line arguments.
|
Parsed command-line arguments.
|
||||||
"""
|
"""
|
||||||
static_dir = os.path.join(_args.root_directory, ".static")
|
static_dir = os.path.join(_args.root_directory, ".static")
|
||||||
|
darktheme = False
|
||||||
if os.path.exists(static_dir):
|
if os.path.exists(static_dir):
|
||||||
print("Removing existing .static folder...")
|
print("Removing existing .static folder...")
|
||||||
logger.info("removing existing .static folder")
|
logger.info("removing existing .static folder")
|
||||||
@@ -93,42 +131,21 @@ def copy_static_files(_args: Args) -> None:
|
|||||||
print("Copying static files...")
|
print("Copying static files...")
|
||||||
logger.info("copying static files")
|
logger.info("copying static files")
|
||||||
shutil.copytree(STATIC_FILES_DIR, static_dir, dirs_exist_ok=True)
|
shutil.copytree(STATIC_FILES_DIR, static_dir, dirs_exist_ok=True)
|
||||||
logger.info("reading theme file", extra={"theme": _args.theme_path})
|
|
||||||
with open(_args.theme_path, "r", encoding="utf-8") as f:
|
theme = os.path.splitext(os.path.abspath(_args.theme_path))[0]
|
||||||
theme = f.read()
|
darktheme_path = f"{theme}-dark.css"
|
||||||
split = theme.split(".foldericon {")
|
if os.path.exists(darktheme_path):
|
||||||
split2 = split[1].split("}", maxsplit=1)
|
handle_theme_icon(darktheme_path, os.path.join(static_dir, "theme-dark.css"))
|
||||||
themehead = split[0]
|
darktheme = True
|
||||||
themetail = split2[1]
|
handle_theme_icon(_args.theme_path, os.path.join(static_dir, "theme.css"))
|
||||||
foldericon = split2[0].strip()
|
|
||||||
foldericon = re.sub(r"/\*.*\*/", "", foldericon)
|
|
||||||
for match in re.finditer(r"content: (.*);", foldericon):
|
|
||||||
foldericon = match[1]
|
|
||||||
foldericon = foldericon.replace('"', "")
|
|
||||||
logger.info("found foldericon", extra={"foldericon": foldericon})
|
|
||||||
break
|
|
||||||
if "url" in foldericon:
|
|
||||||
logger.info("foldericon in theme file, using it")
|
|
||||||
shutil.copyfile(_args.theme_path, os.path.join(static_dir, "theme.css"))
|
|
||||||
return
|
|
||||||
with open(os.path.join(SCRIPTDIR, foldericon), "r", encoding="utf-8") as f:
|
|
||||||
logger.info("Reading foldericon svg")
|
|
||||||
svg = f.read()
|
|
||||||
if "svg.j2" in foldericon:
|
|
||||||
logger.info("foldericon in theme file is a jinja2 template")
|
|
||||||
colorscheme = extract_colorscheme(_args.theme_path)
|
|
||||||
for color_key, color_value in colorscheme.items():
|
|
||||||
svg = svg.replace(f"{{{{ {color_key} }}}}", color_value)
|
|
||||||
logger.info("replaced colors in svg")
|
|
||||||
svg = urllib.parse.quote(svg)
|
|
||||||
with open(os.path.join(static_dir, "theme.css"), "x", encoding="utf-8") as f:
|
|
||||||
logger.info("writing theme file")
|
|
||||||
f.write(themehead + '\n.foldericon {\n content: url("data:image/svg+xml,' + svg + '");\n}\n' + themetail)
|
|
||||||
logger.info("minifying javascript")
|
logger.info("minifying javascript")
|
||||||
with open(os.path.join(SCRIPTDIR, "templates", "functionality.js"), "r", encoding="utf-8") as js_file:
|
with open(os.path.join(SCRIPTDIR, "templates", "functionality.js"), "r", encoding="utf-8") as js_file:
|
||||||
with open(os.path.join(static_dir, "functionality.min.js"), "w+", encoding="utf-8") as min_file:
|
with open(os.path.join(static_dir, "functionality.min.js"), "w+", encoding="utf-8") as min_file:
|
||||||
min_file.write(jsmin(js_file.read()))
|
min_file.write(jsmin(js_file.read()))
|
||||||
|
|
||||||
|
return darktheme
|
||||||
|
|
||||||
|
|
||||||
def generate_thumbnail(arguments: tuple[str, str, str]) -> None:
|
def generate_thumbnail(arguments: tuple[str, str, str]) -> None:
|
||||||
"""
|
"""
|
||||||
@@ -155,7 +172,7 @@ def generate_thumbnail(arguments: tuple[str, str, str]) -> None:
|
|||||||
imgrgb = imgfile.convert("RGB")
|
imgrgb = imgfile.convert("RGB")
|
||||||
img = ImageOps.exif_transpose(imgrgb)
|
img = ImageOps.exif_transpose(imgrgb)
|
||||||
img.thumbnail((512, 512))
|
img.thumbnail((512, 512))
|
||||||
img.save(path, "JPEG", quality=75, optimize=True, mode="RGB")
|
img.save(path, "JPEG", quality=50, optimize=True, mode="RGB", subsampling=2)
|
||||||
except OSError:
|
except OSError:
|
||||||
logger.error("Failed to generate thumbnail for %s", item, extra={"path": image})
|
logger.error("Failed to generate thumbnail for %s", item, extra={"path": image})
|
||||||
print(f"Failed to generate thumbnail for {image}")
|
print(f"Failed to generate thumbnail for {image}")
|
||||||
@@ -201,7 +218,7 @@ def main(args) -> None:
|
|||||||
shutil.rmtree(thumbdir)
|
shutil.rmtree(thumbdir)
|
||||||
os.makedirs(thumbdir, exist_ok=True)
|
os.makedirs(thumbdir, exist_ok=True)
|
||||||
|
|
||||||
copy_static_files(args)
|
args.darktheme = copy_static_files(args)
|
||||||
icons(args)
|
icons(args)
|
||||||
|
|
||||||
if args.generate_webmanifest:
|
if args.generate_webmanifest:
|
||||||
|
|||||||
3
example.config
Normal file
3
example.config
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
root-directory = /path/to/webroot
|
||||||
|
site-title = Website Title
|
||||||
|
web-root-url = https://www.example.com
|
||||||
@@ -77,10 +77,6 @@ figure {
|
|||||||
margin: 0;
|
margin: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.licensefile {
|
|
||||||
padding: 30px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.caption {
|
.caption {
|
||||||
padding-top: 4px;
|
padding-top: 4px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
@@ -93,7 +89,6 @@ figure {
|
|||||||
position: absolute;
|
position: absolute;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
right: 0;
|
right: 0;
|
||||||
font-size: xx-small;
|
|
||||||
padding: 6px;
|
padding: 6px;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -102,7 +97,8 @@ figure {
|
|||||||
bottom: 0;
|
bottom: 0;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
padding: 6px;
|
padding: 6px;
|
||||||
min-height: calc(6.75pt + 12px);
|
height: calc(9.75pt + 12px);
|
||||||
|
font-size: small;
|
||||||
}
|
}
|
||||||
|
|
||||||
.footer a {
|
.footer a {
|
||||||
@@ -110,7 +106,7 @@ figure {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.footer a img {
|
.footer a img {
|
||||||
height: 22px !important;
|
height: 9.75pt !important;
|
||||||
margin-left: 3px;
|
margin-left: 3px;
|
||||||
vertical-align: text-bottom;
|
vertical-align: text-bottom;
|
||||||
}
|
}
|
||||||
@@ -140,16 +136,19 @@ figure {
|
|||||||
|
|
||||||
.navbar .navleft {
|
.navbar .navleft {
|
||||||
float: left;
|
float: left;
|
||||||
|
height: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.navbar .navcenter {
|
.navbar .navcenter {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
left: 50%;
|
left: 50%;
|
||||||
transform: translateX(-50%);
|
transform: translateX(-50%);
|
||||||
|
height: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.navbar .navright {
|
.navbar .navright {
|
||||||
float: right
|
float: right;
|
||||||
|
height: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.navbar li .header {
|
.navbar li .header {
|
||||||
@@ -303,6 +302,59 @@ input {
|
|||||||
border-style: none;
|
border-style: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.darkmodeswitch {
|
||||||
|
font-size: smaller;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
#dark-mode-switch {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
border: none;
|
||||||
|
cursor: pointer;
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
#dark-mode-switch .checkbox {
|
||||||
|
position: absolute;
|
||||||
|
width: 100%;
|
||||||
|
margin: 0;
|
||||||
|
opacity: 0;
|
||||||
|
cursor: pointer;
|
||||||
|
z-index: 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
#dark-mode-switch .knobs {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
column-gap: 1em;
|
||||||
|
position: relative;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
#dark-mode-switch .light,
|
||||||
|
#dark-mode-switch .dark {
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
#dark-mode-switch .slider {
|
||||||
|
position: absolute;
|
||||||
|
width: calc(2em - 2px);
|
||||||
|
height: calc(2em - 2px);
|
||||||
|
border: 1px solid currentColor;
|
||||||
|
border-radius: 3px;
|
||||||
|
top: 50%;
|
||||||
|
transform: translate(-50%, -50%);
|
||||||
|
transition: left 0.25s ease, transform 0.25s ease;
|
||||||
|
left: calc(50% - 1em + 1px);
|
||||||
|
}
|
||||||
|
|
||||||
|
#dark-mode-switch .checkbox:checked+.knobs .slider {
|
||||||
|
left: calc(50% + 1em - 1px);
|
||||||
|
}
|
||||||
|
|
||||||
@media screen and (max-width: 1000px) {
|
@media screen and (max-width: 1000px) {
|
||||||
.column {
|
.column {
|
||||||
-ms-flex: 25%;
|
-ms-flex: 25%;
|
||||||
@@ -310,6 +362,14 @@ input {
|
|||||||
max-width: 25%;
|
max-width: 25%;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.footer {
|
||||||
|
font-size: small;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer a img {
|
||||||
|
height: 9.75pt !important;
|
||||||
|
}
|
||||||
|
|
||||||
.folders figure {
|
.folders figure {
|
||||||
width: 160px;
|
width: 160px;
|
||||||
}
|
}
|
||||||
@@ -343,6 +403,14 @@ input {
|
|||||||
max-width: 50%;
|
max-width: 50%;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.footer {
|
||||||
|
font-size: x-small;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer a img {
|
||||||
|
height: 7.5pt !important;
|
||||||
|
}
|
||||||
|
|
||||||
.folders figure {
|
.folders figure {
|
||||||
width: 140px;
|
width: 140px;
|
||||||
}
|
}
|
||||||
@@ -384,6 +452,14 @@ input {
|
|||||||
max-width: 100%;
|
max-width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.footer {
|
||||||
|
font-size: xx-small;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer a img {
|
||||||
|
height: 6.75pt !important;
|
||||||
|
}
|
||||||
|
|
||||||
.folders figure {
|
.folders figure {
|
||||||
width: 120px;
|
width: 120px;
|
||||||
}
|
}
|
||||||
|
|||||||
192
help.svg
192
help.svg
@@ -1,4 +1,4 @@
|
|||||||
<svg class="rich-terminal" viewBox="0 0 1482 977.1999999999999" xmlns="http://www.w3.org/2000/svg">
|
<svg class="rich-terminal" viewBox="0 0 1482 1074.8" xmlns="http://www.w3.org/2000/svg">
|
||||||
<!-- Generated with Rich https://www.textualize.io -->
|
<!-- Generated with Rich https://www.textualize.io -->
|
||||||
<style>
|
<style>
|
||||||
|
|
||||||
@@ -19,191 +19,207 @@
|
|||||||
font-weight: 700;
|
font-weight: 700;
|
||||||
}
|
}
|
||||||
|
|
||||||
.terminal-1232074479-matrix {
|
.terminal-1915255058-matrix {
|
||||||
font-family: Fira Code, monospace;
|
font-family: Fira Code, monospace;
|
||||||
font-size: 20px;
|
font-size: 20px;
|
||||||
line-height: 24.4px;
|
line-height: 24.4px;
|
||||||
font-variant-east-asian: full-width;
|
font-variant-east-asian: full-width;
|
||||||
}
|
}
|
||||||
|
|
||||||
.terminal-1232074479-title {
|
.terminal-1915255058-title {
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
font-family: arial;
|
font-family: arial;
|
||||||
}
|
}
|
||||||
|
|
||||||
.terminal-1232074479-r1 { fill: #ff8700 }
|
.terminal-1915255058-r1 { fill: #ff8700 }
|
||||||
.terminal-1232074479-r2 { fill: #c5c8c6 }
|
.terminal-1915255058-r2 { fill: #c5c8c6 }
|
||||||
.terminal-1232074479-r3 { fill: #808080 }
|
.terminal-1915255058-r3 { fill: #808080 }
|
||||||
.terminal-1232074479-r4 { fill: #68a0b3 }
|
.terminal-1915255058-r4 { fill: #68a0b3 }
|
||||||
.terminal-1232074479-r5 { fill: #00af87 }
|
.terminal-1915255058-r5 { fill: #00af87 }
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
<defs>
|
<defs>
|
||||||
<clipPath id="terminal-1232074479-clip-terminal">
|
<clipPath id="terminal-1915255058-clip-terminal">
|
||||||
<rect x="0" y="0" width="1463.0" height="926.1999999999999" />
|
<rect x="0" y="0" width="1463.0" height="1023.8" />
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-0">
|
<clipPath id="terminal-1915255058-line-0">
|
||||||
<rect x="0" y="1.5" width="1464" height="24.65"/>
|
<rect x="0" y="1.5" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-1">
|
<clipPath id="terminal-1915255058-line-1">
|
||||||
<rect x="0" y="25.9" width="1464" height="24.65"/>
|
<rect x="0" y="25.9" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-2">
|
<clipPath id="terminal-1915255058-line-2">
|
||||||
<rect x="0" y="50.3" width="1464" height="24.65"/>
|
<rect x="0" y="50.3" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-3">
|
<clipPath id="terminal-1915255058-line-3">
|
||||||
<rect x="0" y="74.7" width="1464" height="24.65"/>
|
<rect x="0" y="74.7" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-4">
|
<clipPath id="terminal-1915255058-line-4">
|
||||||
<rect x="0" y="99.1" width="1464" height="24.65"/>
|
<rect x="0" y="99.1" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-5">
|
<clipPath id="terminal-1915255058-line-5">
|
||||||
<rect x="0" y="123.5" width="1464" height="24.65"/>
|
<rect x="0" y="123.5" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-6">
|
<clipPath id="terminal-1915255058-line-6">
|
||||||
<rect x="0" y="147.9" width="1464" height="24.65"/>
|
<rect x="0" y="147.9" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-7">
|
<clipPath id="terminal-1915255058-line-7">
|
||||||
<rect x="0" y="172.3" width="1464" height="24.65"/>
|
<rect x="0" y="172.3" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-8">
|
<clipPath id="terminal-1915255058-line-8">
|
||||||
<rect x="0" y="196.7" width="1464" height="24.65"/>
|
<rect x="0" y="196.7" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-9">
|
<clipPath id="terminal-1915255058-line-9">
|
||||||
<rect x="0" y="221.1" width="1464" height="24.65"/>
|
<rect x="0" y="221.1" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-10">
|
<clipPath id="terminal-1915255058-line-10">
|
||||||
<rect x="0" y="245.5" width="1464" height="24.65"/>
|
<rect x="0" y="245.5" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-11">
|
<clipPath id="terminal-1915255058-line-11">
|
||||||
<rect x="0" y="269.9" width="1464" height="24.65"/>
|
<rect x="0" y="269.9" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-12">
|
<clipPath id="terminal-1915255058-line-12">
|
||||||
<rect x="0" y="294.3" width="1464" height="24.65"/>
|
<rect x="0" y="294.3" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-13">
|
<clipPath id="terminal-1915255058-line-13">
|
||||||
<rect x="0" y="318.7" width="1464" height="24.65"/>
|
<rect x="0" y="318.7" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-14">
|
<clipPath id="terminal-1915255058-line-14">
|
||||||
<rect x="0" y="343.1" width="1464" height="24.65"/>
|
<rect x="0" y="343.1" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-15">
|
<clipPath id="terminal-1915255058-line-15">
|
||||||
<rect x="0" y="367.5" width="1464" height="24.65"/>
|
<rect x="0" y="367.5" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-16">
|
<clipPath id="terminal-1915255058-line-16">
|
||||||
<rect x="0" y="391.9" width="1464" height="24.65"/>
|
<rect x="0" y="391.9" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-17">
|
<clipPath id="terminal-1915255058-line-17">
|
||||||
<rect x="0" y="416.3" width="1464" height="24.65"/>
|
<rect x="0" y="416.3" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-18">
|
<clipPath id="terminal-1915255058-line-18">
|
||||||
<rect x="0" y="440.7" width="1464" height="24.65"/>
|
<rect x="0" y="440.7" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-19">
|
<clipPath id="terminal-1915255058-line-19">
|
||||||
<rect x="0" y="465.1" width="1464" height="24.65"/>
|
<rect x="0" y="465.1" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-20">
|
<clipPath id="terminal-1915255058-line-20">
|
||||||
<rect x="0" y="489.5" width="1464" height="24.65"/>
|
<rect x="0" y="489.5" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-21">
|
<clipPath id="terminal-1915255058-line-21">
|
||||||
<rect x="0" y="513.9" width="1464" height="24.65"/>
|
<rect x="0" y="513.9" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-22">
|
<clipPath id="terminal-1915255058-line-22">
|
||||||
<rect x="0" y="538.3" width="1464" height="24.65"/>
|
<rect x="0" y="538.3" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-23">
|
<clipPath id="terminal-1915255058-line-23">
|
||||||
<rect x="0" y="562.7" width="1464" height="24.65"/>
|
<rect x="0" y="562.7" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-24">
|
<clipPath id="terminal-1915255058-line-24">
|
||||||
<rect x="0" y="587.1" width="1464" height="24.65"/>
|
<rect x="0" y="587.1" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-25">
|
<clipPath id="terminal-1915255058-line-25">
|
||||||
<rect x="0" y="611.5" width="1464" height="24.65"/>
|
<rect x="0" y="611.5" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-26">
|
<clipPath id="terminal-1915255058-line-26">
|
||||||
<rect x="0" y="635.9" width="1464" height="24.65"/>
|
<rect x="0" y="635.9" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-27">
|
<clipPath id="terminal-1915255058-line-27">
|
||||||
<rect x="0" y="660.3" width="1464" height="24.65"/>
|
<rect x="0" y="660.3" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-28">
|
<clipPath id="terminal-1915255058-line-28">
|
||||||
<rect x="0" y="684.7" width="1464" height="24.65"/>
|
<rect x="0" y="684.7" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-29">
|
<clipPath id="terminal-1915255058-line-29">
|
||||||
<rect x="0" y="709.1" width="1464" height="24.65"/>
|
<rect x="0" y="709.1" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-30">
|
<clipPath id="terminal-1915255058-line-30">
|
||||||
<rect x="0" y="733.5" width="1464" height="24.65"/>
|
<rect x="0" y="733.5" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-31">
|
<clipPath id="terminal-1915255058-line-31">
|
||||||
<rect x="0" y="757.9" width="1464" height="24.65"/>
|
<rect x="0" y="757.9" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-32">
|
<clipPath id="terminal-1915255058-line-32">
|
||||||
<rect x="0" y="782.3" width="1464" height="24.65"/>
|
<rect x="0" y="782.3" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-33">
|
<clipPath id="terminal-1915255058-line-33">
|
||||||
<rect x="0" y="806.7" width="1464" height="24.65"/>
|
<rect x="0" y="806.7" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-34">
|
<clipPath id="terminal-1915255058-line-34">
|
||||||
<rect x="0" y="831.1" width="1464" height="24.65"/>
|
<rect x="0" y="831.1" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-35">
|
<clipPath id="terminal-1915255058-line-35">
|
||||||
<rect x="0" y="855.5" width="1464" height="24.65"/>
|
<rect x="0" y="855.5" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
<clipPath id="terminal-1232074479-line-36">
|
<clipPath id="terminal-1915255058-line-36">
|
||||||
<rect x="0" y="879.9" width="1464" height="24.65"/>
|
<rect x="0" y="879.9" width="1464" height="24.65"/>
|
||||||
</clipPath>
|
</clipPath>
|
||||||
|
<clipPath id="terminal-1915255058-line-37">
|
||||||
|
<rect x="0" y="904.3" width="1464" height="24.65"/>
|
||||||
|
</clipPath>
|
||||||
|
<clipPath id="terminal-1915255058-line-38">
|
||||||
|
<rect x="0" y="928.7" width="1464" height="24.65"/>
|
||||||
|
</clipPath>
|
||||||
|
<clipPath id="terminal-1915255058-line-39">
|
||||||
|
<rect x="0" y="953.1" width="1464" height="24.65"/>
|
||||||
|
</clipPath>
|
||||||
|
<clipPath id="terminal-1915255058-line-40">
|
||||||
|
<rect x="0" y="977.5" width="1464" height="24.65"/>
|
||||||
|
</clipPath>
|
||||||
</defs>
|
</defs>
|
||||||
|
|
||||||
<rect fill="#292929" stroke="rgba(255,255,255,0.35)" stroke-width="1" x="1" y="1" width="1480" height="975.2" rx="8"/>
|
<rect fill="#292929" stroke="rgba(255,255,255,0.35)" stroke-width="1" x="1" y="1" width="1480" height="1072.8" rx="8"/>
|
||||||
<g transform="translate(26,22)">
|
<g transform="translate(26,22)">
|
||||||
<circle cx="0" cy="0" r="7" fill="#ff5f57"/>
|
<circle cx="0" cy="0" r="7" fill="#ff5f57"/>
|
||||||
<circle cx="22" cy="0" r="7" fill="#febc2e"/>
|
<circle cx="22" cy="0" r="7" fill="#febc2e"/>
|
||||||
<circle cx="44" cy="0" r="7" fill="#28c840"/>
|
<circle cx="44" cy="0" r="7" fill="#28c840"/>
|
||||||
</g>
|
</g>
|
||||||
|
|
||||||
<g transform="translate(9, 41)" clip-path="url(#terminal-1232074479-clip-terminal)">
|
<g transform="translate(9, 41)" clip-path="url(#terminal-1915255058-clip-terminal)">
|
||||||
|
|
||||||
<g class="terminal-1232074479-matrix">
|
<g class="terminal-1915255058-matrix">
|
||||||
<text class="terminal-1232074479-r1" x="0" y="20" textLength="73.2" clip-path="url(#terminal-1232074479-line-0)">Usage:</text><text class="terminal-1232074479-r3" x="85.4" y="20" textLength="122" clip-path="url(#terminal-1232074479-line-0)">builder.py</text><text class="terminal-1232074479-r2" x="207.4" y="20" textLength="24.4" clip-path="url(#terminal-1232074479-line-0)"> [</text><text class="terminal-1232074479-r4" x="231.8" y="20" textLength="24.4" clip-path="url(#terminal-1232074479-line-0)">-h</text><text class="terminal-1232074479-r2" x="256.2" y="20" textLength="36.6" clip-path="url(#terminal-1232074479-line-0)">] [</text><text class="terminal-1232074479-r4" x="292.8" y="20" textLength="24.4" clip-path="url(#terminal-1232074479-line-0)">-a</text><text class="terminal-1232074479-r5" x="329.4" y="20" textLength="73.2" clip-path="url(#terminal-1232074479-line-0)">AUTHOR</text><text class="terminal-1232074479-r2" x="402.6" y="20" textLength="36.6" clip-path="url(#terminal-1232074479-line-0)">] [</text><text class="terminal-1232074479-r4" x="439.2" y="20" textLength="24.4" clip-path="url(#terminal-1232074479-line-0)">-e</text><text class="terminal-1232074479-r5" x="475.8" y="20" textLength="109.8" clip-path="url(#terminal-1232074479-line-0)">EXTENSION</text><text class="terminal-1232074479-r2" x="585.6" y="20" textLength="36.6" clip-path="url(#terminal-1232074479-line-0)">] [</text><text class="terminal-1232074479-r4" x="622.2" y="20" textLength="24.4" clip-path="url(#terminal-1232074479-line-0)">-l</text><text class="terminal-1232074479-r5" x="658.8" y="20" textLength="85.4" clip-path="url(#terminal-1232074479-line-0)">LICENSE</text><text class="terminal-1232074479-r2" x="744.2" y="20" textLength="36.6" clip-path="url(#terminal-1232074479-line-0)">] [</text><text class="terminal-1232074479-r4" x="780.8" y="20" textLength="24.4" clip-path="url(#terminal-1232074479-line-0)">-m</text><text class="terminal-1232074479-r2" x="805.2" y="20" textLength="36.6" clip-path="url(#terminal-1232074479-line-0)">] [</text><text class="terminal-1232074479-r4" x="841.8" y="20" textLength="24.4" clip-path="url(#terminal-1232074479-line-0)">-n</text><text class="terminal-1232074479-r2" x="866.2" y="20" textLength="24.4" clip-path="url(#terminal-1232074479-line-0)">] </text><text class="terminal-1232074479-r4" x="890.6" y="20" textLength="24.4" clip-path="url(#terminal-1232074479-line-0)">-p</text><text class="terminal-1232074479-r5" x="927.2" y="20" textLength="48.8" clip-path="url(#terminal-1232074479-line-0)">ROOT</text><text class="terminal-1232074479-r4" x="988.2" y="20" textLength="24.4" clip-path="url(#terminal-1232074479-line-0)">-t</text><text class="terminal-1232074479-r5" x="1024.8" y="20" textLength="61" clip-path="url(#terminal-1232074479-line-0)">TITLE</text><text class="terminal-1232074479-r4" x="1098" y="20" textLength="24.4" clip-path="url(#terminal-1232074479-line-0)">-w</text><text class="terminal-1232074479-r5" x="1134.6" y="20" textLength="36.6" clip-path="url(#terminal-1232074479-line-0)">URL</text><text class="terminal-1232074479-r2" x="1464" y="20" textLength="12.2" clip-path="url(#terminal-1232074479-line-0)">
|
<text class="terminal-1915255058-r1" x="0" y="20" textLength="73.2" clip-path="url(#terminal-1915255058-line-0)">Usage:</text><text class="terminal-1915255058-r3" x="85.4" y="20" textLength="122" clip-path="url(#terminal-1915255058-line-0)">builder.py</text><text class="terminal-1915255058-r2" x="207.4" y="20" textLength="24.4" clip-path="url(#terminal-1915255058-line-0)"> [</text><text class="terminal-1915255058-r4" x="231.8" y="20" textLength="24.4" clip-path="url(#terminal-1915255058-line-0)">-h</text><text class="terminal-1915255058-r2" x="256.2" y="20" textLength="36.6" clip-path="url(#terminal-1915255058-line-0)">] [</text><text class="terminal-1915255058-r4" x="292.8" y="20" textLength="24.4" clip-path="url(#terminal-1915255058-line-0)">-a</text><text class="terminal-1915255058-r5" x="329.4" y="20" textLength="73.2" clip-path="url(#terminal-1915255058-line-0)">AUTHOR</text><text class="terminal-1915255058-r2" x="402.6" y="20" textLength="36.6" clip-path="url(#terminal-1915255058-line-0)">] [</text><text class="terminal-1915255058-r4" x="439.2" y="20" textLength="24.4" clip-path="url(#terminal-1915255058-line-0)">-e</text><text class="terminal-1915255058-r5" x="475.8" y="20" textLength="109.8" clip-path="url(#terminal-1915255058-line-0)">EXTENSION</text><text class="terminal-1915255058-r2" x="585.6" y="20" textLength="36.6" clip-path="url(#terminal-1915255058-line-0)">] [</text><text class="terminal-1915255058-r4" x="622.2" y="20" textLength="24.4" clip-path="url(#terminal-1915255058-line-0)">-l</text><text class="terminal-1915255058-r5" x="658.8" y="20" textLength="85.4" clip-path="url(#terminal-1915255058-line-0)">LICENSE</text><text class="terminal-1915255058-r2" x="744.2" y="20" textLength="36.6" clip-path="url(#terminal-1915255058-line-0)">] [</text><text class="terminal-1915255058-r4" x="780.8" y="20" textLength="24.4" clip-path="url(#terminal-1915255058-line-0)">-m</text><text class="terminal-1915255058-r2" x="805.2" y="20" textLength="36.6" clip-path="url(#terminal-1915255058-line-0)">] [</text><text class="terminal-1915255058-r4" x="841.8" y="20" textLength="24.4" clip-path="url(#terminal-1915255058-line-0)">-n</text><text class="terminal-1915255058-r2" x="866.2" y="20" textLength="24.4" clip-path="url(#terminal-1915255058-line-0)">] </text><text class="terminal-1915255058-r4" x="890.6" y="20" textLength="24.4" clip-path="url(#terminal-1915255058-line-0)">-p</text><text class="terminal-1915255058-r5" x="927.2" y="20" textLength="48.8" clip-path="url(#terminal-1915255058-line-0)">ROOT</text><text class="terminal-1915255058-r4" x="988.2" y="20" textLength="24.4" clip-path="url(#terminal-1915255058-line-0)">-t</text><text class="terminal-1915255058-r5" x="1024.8" y="20" textLength="61" clip-path="url(#terminal-1915255058-line-0)">TITLE</text><text class="terminal-1915255058-r4" x="1098" y="20" textLength="24.4" clip-path="url(#terminal-1915255058-line-0)">-w</text><text class="terminal-1915255058-r5" x="1134.6" y="20" textLength="36.6" clip-path="url(#terminal-1915255058-line-0)">URL</text><text class="terminal-1915255058-r2" x="1171.2" y="20" textLength="24.4" clip-path="url(#terminal-1915255058-line-0)"> [</text><text class="terminal-1915255058-r4" x="1195.6" y="20" textLength="24.4" clip-path="url(#terminal-1915255058-line-0)">-c</text><text class="terminal-1915255058-r5" x="1232.2" y="20" textLength="134.2" clip-path="url(#terminal-1915255058-line-0)">CONFIG_FILE</text><text class="terminal-1915255058-r2" x="1366.4" y="20" textLength="12.2" clip-path="url(#terminal-1915255058-line-0)">]</text><text class="terminal-1915255058-r2" x="1464" y="20" textLength="12.2" clip-path="url(#terminal-1915255058-line-0)">
|
||||||
</text><text class="terminal-1232074479-r2" x="0" y="44.4" textLength="231.8" clip-path="url(#terminal-1232074479-line-1)">                  [</text><text class="terminal-1232074479-r4" x="231.8" y="44.4" textLength="195.2" clip-path="url(#terminal-1232074479-line-1)">--exclude-folder</text><text class="terminal-1232074479-r5" x="439.2" y="44.4" textLength="73.2" clip-path="url(#terminal-1232074479-line-1)">FOLDER</text><text class="terminal-1232074479-r2" x="512.4" y="44.4" textLength="36.6" clip-path="url(#terminal-1232074479-line-1)">] [</text><text class="terminal-1232074479-r4" x="549" y="44.4" textLength="219.6" clip-path="url(#terminal-1232074479-line-1)">--folderthumbnails</text><text class="terminal-1232074479-r2" x="768.6" y="44.4" textLength="36.6" clip-path="url(#terminal-1232074479-line-1)">] [</text><text class="terminal-1232074479-r4" x="805.2" y="44.4" textLength="244" clip-path="url(#terminal-1232074479-line-1)">--ignore-other-files</text><text class="terminal-1232074479-r2" x="1049.2" y="44.4" textLength="36.6" clip-path="url(#terminal-1232074479-line-1)">] [</text><text class="terminal-1232074479-r4" x="1085.8" y="44.4" textLength="219.6" clip-path="url(#terminal-1232074479-line-1)">--ignore-extension</text><text class="terminal-1232074479-r5" x="1317.6" y="44.4" textLength="109.8" clip-path="url(#terminal-1232074479-line-1)">EXTENSION</text><text class="terminal-1232074479-r2" x="1427.4" y="44.4" textLength="12.2" clip-path="url(#terminal-1232074479-line-1)">]</text><text class="terminal-1232074479-r2" x="1464" y="44.4" textLength="12.2" clip-path="url(#terminal-1232074479-line-1)">
|
</text><text class="terminal-1915255058-r2" x="0" y="44.4" textLength="231.8" clip-path="url(#terminal-1915255058-line-1)">                  [</text><text class="terminal-1915255058-r4" x="231.8" y="44.4" textLength="195.2" clip-path="url(#terminal-1915255058-line-1)">--exclude-folder</text><text class="terminal-1915255058-r5" x="439.2" y="44.4" textLength="73.2" clip-path="url(#terminal-1915255058-line-1)">FOLDER</text><text class="terminal-1915255058-r2" x="512.4" y="44.4" textLength="36.6" clip-path="url(#terminal-1915255058-line-1)">] [</text><text class="terminal-1915255058-r4" x="549" y="44.4" textLength="219.6" clip-path="url(#terminal-1915255058-line-1)">--folderthumbnails</text><text class="terminal-1915255058-r2" x="768.6" y="44.4" textLength="36.6" clip-path="url(#terminal-1915255058-line-1)">] [</text><text class="terminal-1915255058-r4" x="805.2" y="44.4" textLength="244" clip-path="url(#terminal-1915255058-line-1)">--ignore-other-files</text><text class="terminal-1915255058-r2" x="1049.2" y="44.4" textLength="36.6" clip-path="url(#terminal-1915255058-line-1)">] [</text><text class="terminal-1915255058-r4" x="1085.8" y="44.4" textLength="219.6" clip-path="url(#terminal-1915255058-line-1)">--ignore-extension</text><text class="terminal-1915255058-r5" x="1317.6" y="44.4" textLength="109.8" clip-path="url(#terminal-1915255058-line-1)">EXTENSION</text><text class="terminal-1915255058-r2" x="1427.4" y="44.4" textLength="12.2" clip-path="url(#terminal-1915255058-line-1)">]</text><text class="terminal-1915255058-r2" x="1464" y="44.4" textLength="12.2" clip-path="url(#terminal-1915255058-line-1)">
|
||||||
</text><text class="terminal-1232074479-r2" x="0" y="68.8" textLength="231.8" clip-path="url(#terminal-1232074479-line-2)">                  [</text><text class="terminal-1232074479-r4" x="231.8" y="68.8" textLength="280.6" clip-path="url(#terminal-1232074479-line-2)">--regenerate-thumbnails</text><text class="terminal-1232074479-r2" x="512.4" y="68.8" textLength="36.6" clip-path="url(#terminal-1232074479-line-2)">] [</text><text class="terminal-1232074479-r4" x="549" y="68.8" textLength="207.4" clip-path="url(#terminal-1232074479-line-2)">--reread-metadata</text><text class="terminal-1232074479-r2" x="756.4" y="68.8" textLength="36.6" clip-path="url(#terminal-1232074479-line-2)">] [</text><text class="terminal-1232074479-r4" x="793" y="68.8" textLength="195.2" clip-path="url(#terminal-1232074479-line-2)">--reread-sidecar</text><text class="terminal-1232074479-r2" x="988.2" y="68.8" textLength="36.6" clip-path="url(#terminal-1232074479-line-2)">] [</text><text class="terminal-1232074479-r4" x="1024.8" y="68.8" textLength="170.8" clip-path="url(#terminal-1232074479-line-2)">--reverse-sort</text><text class="terminal-1232074479-r2" x="1195.6" y="68.8" textLength="12.2" clip-path="url(#terminal-1232074479-line-2)">]</text><text class="terminal-1232074479-r2" x="1464" y="68.8" textLength="12.2" clip-path="url(#terminal-1232074479-line-2)">
|
</text><text class="terminal-1915255058-r2" x="0" y="68.8" textLength="231.8" clip-path="url(#terminal-1915255058-line-2)">                  [</text><text class="terminal-1915255058-r4" x="231.8" y="68.8" textLength="280.6" clip-path="url(#terminal-1915255058-line-2)">--regenerate-thumbnails</text><text class="terminal-1915255058-r2" x="512.4" y="68.8" textLength="36.6" clip-path="url(#terminal-1915255058-line-2)">] [</text><text class="terminal-1915255058-r4" x="549" y="68.8" textLength="207.4" clip-path="url(#terminal-1915255058-line-2)">--reread-metadata</text><text class="terminal-1915255058-r2" x="756.4" y="68.8" textLength="36.6" clip-path="url(#terminal-1915255058-line-2)">] [</text><text class="terminal-1915255058-r4" x="793" y="68.8" textLength="195.2" clip-path="url(#terminal-1915255058-line-2)">--reread-sidecar</text><text class="terminal-1915255058-r2" x="988.2" y="68.8" textLength="36.6" clip-path="url(#terminal-1915255058-line-2)">] [</text><text class="terminal-1915255058-r4" x="1024.8" y="68.8" textLength="170.8" clip-path="url(#terminal-1915255058-line-2)">--reverse-sort</text><text class="terminal-1915255058-r2" x="1195.6" y="68.8" textLength="12.2" clip-path="url(#terminal-1915255058-line-2)">]</text><text class="terminal-1915255058-r2" x="1464" y="68.8" textLength="12.2" clip-path="url(#terminal-1915255058-line-2)">
|
||||||
</text><text class="terminal-1232074479-r2" x="0" y="93.2" textLength="231.8" clip-path="url(#terminal-1232074479-line-3)">                  [</text><text class="terminal-1232074479-r4" x="231.8" y="93.2" textLength="146.4" clip-path="url(#terminal-1232074479-line-3)">--theme-path</text><text class="terminal-1232074479-r5" x="390.4" y="93.2" textLength="48.8" clip-path="url(#terminal-1232074479-line-3)">PATH</text><text class="terminal-1232074479-r2" x="439.2" y="93.2" textLength="36.6" clip-path="url(#terminal-1232074479-line-3)">] [</text><text class="terminal-1232074479-r4" x="475.8" y="93.2" textLength="231.8" clip-path="url(#terminal-1232074479-line-3)">--use-fancy-folders</text><text class="terminal-1232074479-r2" x="707.6" y="93.2" textLength="36.6" clip-path="url(#terminal-1232074479-line-3)">] [</text><text class="terminal-1232074479-r4" x="744.2" y="93.2" textLength="109.8" clip-path="url(#terminal-1232074479-line-3)">--version</text><text class="terminal-1232074479-r2" x="854" y="93.2" textLength="12.2" clip-path="url(#terminal-1232074479-line-3)">]</text><text class="terminal-1232074479-r2" x="1464" y="93.2" textLength="12.2" clip-path="url(#terminal-1232074479-line-3)">
|
</text><text class="terminal-1915255058-r2" x="0" y="93.2" textLength="231.8" clip-path="url(#terminal-1915255058-line-3)">                  [</text><text class="terminal-1915255058-r4" x="231.8" y="93.2" textLength="146.4" clip-path="url(#terminal-1915255058-line-3)">--theme-path</text><text class="terminal-1915255058-r5" x="390.4" y="93.2" textLength="48.8" clip-path="url(#terminal-1915255058-line-3)">PATH</text><text class="terminal-1915255058-r2" x="439.2" y="93.2" textLength="36.6" clip-path="url(#terminal-1915255058-line-3)">] [</text><text class="terminal-1915255058-r4" x="475.8" y="93.2" textLength="231.8" clip-path="url(#terminal-1915255058-line-3)">--use-fancy-folders</text><text class="terminal-1915255058-r2" x="707.6" y="93.2" textLength="36.6" clip-path="url(#terminal-1915255058-line-3)">] [</text><text class="terminal-1915255058-r4" x="744.2" y="93.2" textLength="109.8" clip-path="url(#terminal-1915255058-line-3)">--version</text><text class="terminal-1915255058-r2" x="854" y="93.2" textLength="36.6" clip-path="url(#terminal-1915255058-line-3)">] [</text><text class="terminal-1915255058-r4" x="890.6" y="93.2" textLength="170.8" clip-path="url(#terminal-1915255058-line-3)">--write-config</text><text class="terminal-1915255058-r5" x="1073.6" y="93.2" textLength="134.2" clip-path="url(#terminal-1915255058-line-3)">CONFIG_FILE</text><text class="terminal-1915255058-r2" x="1207.8" y="93.2" textLength="12.2" clip-path="url(#terminal-1915255058-line-3)">]</text><text class="terminal-1915255058-r2" x="1464" y="93.2" textLength="12.2" clip-path="url(#terminal-1915255058-line-3)">
|
||||||
</text><text class="terminal-1232074479-r2" x="1464" y="117.6" textLength="12.2" clip-path="url(#terminal-1232074479-line-4)">
|
</text><text class="terminal-1915255058-r2" x="1464" y="117.6" textLength="12.2" clip-path="url(#terminal-1915255058-line-4)">
|
||||||
</text><text class="terminal-1232074479-r2" x="0" y="142" textLength="658.8" clip-path="url(#terminal-1232074479-line-5)">generate HTML files for a static image hosting website</text><text class="terminal-1232074479-r2" x="1464" y="142" textLength="12.2" clip-path="url(#terminal-1232074479-line-5)">
|
</text><text class="terminal-1915255058-r2" x="0" y="142" textLength="658.8" clip-path="url(#terminal-1915255058-line-5)">generate HTML files for a static image hosting website</text><text class="terminal-1915255058-r2" x="1464" y="142" textLength="12.2" clip-path="url(#terminal-1915255058-line-5)">
|
||||||
</text><text class="terminal-1232074479-r2" x="1464" y="166.4" textLength="12.2" clip-path="url(#terminal-1232074479-line-6)">
|
</text><text class="terminal-1915255058-r2" x="1464" y="166.4" textLength="12.2" clip-path="url(#terminal-1915255058-line-6)">
|
||||||
</text><text class="terminal-1232074479-r1" x="0" y="190.8" textLength="97.6" clip-path="url(#terminal-1232074479-line-7)">Options:</text><text class="terminal-1232074479-r2" x="1464" y="190.8" textLength="12.2" clip-path="url(#terminal-1232074479-line-7)">
|
</text><text class="terminal-1915255058-r1" x="0" y="190.8" textLength="97.6" clip-path="url(#terminal-1915255058-line-7)">Options:</text><text class="terminal-1915255058-r2" x="1464" y="190.8" textLength="12.2" clip-path="url(#terminal-1915255058-line-7)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="215.2" textLength="24.4" clip-path="url(#terminal-1232074479-line-8)">-h</text><text class="terminal-1232074479-r2" x="48.8" y="215.2" textLength="24.4" clip-path="url(#terminal-1232074479-line-8)">, </text><text class="terminal-1232074479-r4" x="73.2" y="215.2" textLength="73.2" clip-path="url(#terminal-1232074479-line-8)">--help</text><text class="terminal-1232074479-r2" x="292.8" y="215.2" textLength="378.2" clip-path="url(#terminal-1232074479-line-8)">show this help message and exit</text><text class="terminal-1232074479-r2" x="1464" y="215.2" textLength="12.2" clip-path="url(#terminal-1232074479-line-8)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="215.2" textLength="24.4" clip-path="url(#terminal-1915255058-line-8)">-h</text><text class="terminal-1915255058-r2" x="48.8" y="215.2" textLength="24.4" clip-path="url(#terminal-1915255058-line-8)">, </text><text class="terminal-1915255058-r4" x="73.2" y="215.2" textLength="73.2" clip-path="url(#terminal-1915255058-line-8)">--help</text><text class="terminal-1915255058-r2" x="292.8" y="215.2" textLength="378.2" clip-path="url(#terminal-1915255058-line-8)">show this help message and exit</text><text class="terminal-1915255058-r2" x="1464" y="215.2" textLength="12.2" clip-path="url(#terminal-1915255058-line-8)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="239.6" textLength="24.4" clip-path="url(#terminal-1232074479-line-9)">-a</text><text class="terminal-1232074479-r2" x="48.8" y="239.6" textLength="24.4" clip-path="url(#terminal-1232074479-line-9)">, </text><text class="terminal-1232074479-r4" x="73.2" y="239.6" textLength="158.6" clip-path="url(#terminal-1232074479-line-9)">--author-name</text><text class="terminal-1232074479-r5" x="244" y="239.6" textLength="73.2" clip-path="url(#terminal-1232074479-line-9)">AUTHOR</text><text class="terminal-1232074479-r2" x="1464" y="239.6" textLength="12.2" clip-path="url(#terminal-1232074479-line-9)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="239.6" textLength="24.4" clip-path="url(#terminal-1915255058-line-9)">-a</text><text class="terminal-1915255058-r2" x="48.8" y="239.6" textLength="24.4" clip-path="url(#terminal-1915255058-line-9)">, </text><text class="terminal-1915255058-r4" x="73.2" y="239.6" textLength="158.6" clip-path="url(#terminal-1915255058-line-9)">--author-name</text><text class="terminal-1915255058-r5" x="244" y="239.6" textLength="73.2" clip-path="url(#terminal-1915255058-line-9)">AUTHOR</text><text class="terminal-1915255058-r2" x="1464" y="239.6" textLength="12.2" clip-path="url(#terminal-1915255058-line-9)">
|
||||||
</text><text class="terminal-1232074479-r2" x="292.8" y="264" textLength="390.4" clip-path="url(#terminal-1232074479-line-10)">name of the author of the images</text><text class="terminal-1232074479-r2" x="1464" y="264" textLength="12.2" clip-path="url(#terminal-1232074479-line-10)">
|
</text><text class="terminal-1915255058-r2" x="292.8" y="264" textLength="390.4" clip-path="url(#terminal-1915255058-line-10)">name of the author of the images</text><text class="terminal-1915255058-r2" x="1464" y="264" textLength="12.2" clip-path="url(#terminal-1915255058-line-10)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="288.4" textLength="24.4" clip-path="url(#terminal-1232074479-line-11)">-e</text><text class="terminal-1232074479-r2" x="48.8" y="288.4" textLength="24.4" clip-path="url(#terminal-1232074479-line-11)">, </text><text class="terminal-1232074479-r4" x="73.2" y="288.4" textLength="207.4" clip-path="url(#terminal-1232074479-line-11)">--file-extensions</text><text class="terminal-1232074479-r5" x="292.8" y="288.4" textLength="109.8" clip-path="url(#terminal-1232074479-line-11)">EXTENSION</text><text class="terminal-1232074479-r2" x="1464" y="288.4" textLength="12.2" clip-path="url(#terminal-1232074479-line-11)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="288.4" textLength="24.4" clip-path="url(#terminal-1915255058-line-11)">-e</text><text class="terminal-1915255058-r2" x="48.8" y="288.4" textLength="24.4" clip-path="url(#terminal-1915255058-line-11)">, </text><text class="terminal-1915255058-r4" x="73.2" y="288.4" textLength="207.4" clip-path="url(#terminal-1915255058-line-11)">--file-extensions</text><text class="terminal-1915255058-r5" x="292.8" y="288.4" textLength="109.8" clip-path="url(#terminal-1915255058-line-11)">EXTENSION</text><text class="terminal-1915255058-r2" x="1464" y="288.4" textLength="12.2" clip-path="url(#terminal-1915255058-line-11)">
|
||||||
</text><text class="terminal-1232074479-r2" x="292.8" y="312.8" textLength="732" clip-path="url(#terminal-1232074479-line-12)">file extensions to include (can be specified multiple times)</text><text class="terminal-1232074479-r2" x="1464" y="312.8" textLength="12.2" clip-path="url(#terminal-1232074479-line-12)">
|
</text><text class="terminal-1915255058-r2" x="292.8" y="312.8" textLength="732" clip-path="url(#terminal-1915255058-line-12)">file extensions to include (can be specified multiple times)</text><text class="terminal-1915255058-r2" x="1464" y="312.8" textLength="12.2" clip-path="url(#terminal-1915255058-line-12)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="337.2" textLength="24.4" clip-path="url(#terminal-1232074479-line-13)">-l</text><text class="terminal-1232074479-r2" x="48.8" y="337.2" textLength="24.4" clip-path="url(#terminal-1232074479-line-13)">, </text><text class="terminal-1232074479-r4" x="73.2" y="337.2" textLength="170.8" clip-path="url(#terminal-1232074479-line-13)">--license-type</text><text class="terminal-1232074479-r5" x="256.2" y="337.2" textLength="85.4" clip-path="url(#terminal-1232074479-line-13)">LICENSE</text><text class="terminal-1232074479-r2" x="1464" y="337.2" textLength="12.2" clip-path="url(#terminal-1232074479-line-13)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="337.2" textLength="24.4" clip-path="url(#terminal-1915255058-line-13)">-l</text><text class="terminal-1915255058-r2" x="48.8" y="337.2" textLength="24.4" clip-path="url(#terminal-1915255058-line-13)">, </text><text class="terminal-1915255058-r4" x="73.2" y="337.2" textLength="170.8" clip-path="url(#terminal-1915255058-line-13)">--license-type</text><text class="terminal-1915255058-r5" x="256.2" y="337.2" textLength="85.4" clip-path="url(#terminal-1915255058-line-13)">LICENSE</text><text class="terminal-1915255058-r2" x="1464" y="337.2" textLength="12.2" clip-path="url(#terminal-1915255058-line-13)">
|
||||||
</text><text class="terminal-1232074479-r2" x="292.8" y="361.6" textLength="475.8" clip-path="url(#terminal-1232074479-line-14)">specify the license type for the images</text><text class="terminal-1232074479-r2" x="1464" y="361.6" textLength="12.2" clip-path="url(#terminal-1232074479-line-14)">
|
</text><text class="terminal-1915255058-r2" x="292.8" y="361.6" textLength="475.8" clip-path="url(#terminal-1915255058-line-14)">specify the license type for the images</text><text class="terminal-1915255058-r2" x="1464" y="361.6" textLength="12.2" clip-path="url(#terminal-1915255058-line-14)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="386" textLength="24.4" clip-path="url(#terminal-1232074479-line-15)">-m</text><text class="terminal-1232074479-r2" x="48.8" y="386" textLength="24.4" clip-path="url(#terminal-1232074479-line-15)">, </text><text class="terminal-1232074479-r4" x="73.2" y="386" textLength="170.8" clip-path="url(#terminal-1232074479-line-15)">--web-manifest</text><text class="terminal-1232074479-r2" x="292.8" y="386" textLength="341.6" clip-path="url(#terminal-1232074479-line-15)">generate a web manifest file</text><text class="terminal-1232074479-r2" x="1464" y="386" textLength="12.2" clip-path="url(#terminal-1232074479-line-15)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="386" textLength="24.4" clip-path="url(#terminal-1915255058-line-15)">-m</text><text class="terminal-1915255058-r2" x="48.8" y="386" textLength="24.4" clip-path="url(#terminal-1915255058-line-15)">, </text><text class="terminal-1915255058-r4" x="73.2" y="386" textLength="170.8" clip-path="url(#terminal-1915255058-line-15)">--web-manifest</text><text class="terminal-1915255058-r2" x="292.8" y="386" textLength="341.6" clip-path="url(#terminal-1915255058-line-15)">generate a web manifest file</text><text class="terminal-1915255058-r2" x="1464" y="386" textLength="12.2" clip-path="url(#terminal-1915255058-line-15)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="410.4" textLength="24.4" clip-path="url(#terminal-1232074479-line-16)">-n</text><text class="terminal-1232074479-r2" x="48.8" y="410.4" textLength="24.4" clip-path="url(#terminal-1232074479-line-16)">, </text><text class="terminal-1232074479-r4" x="73.2" y="410.4" textLength="268.4" clip-path="url(#terminal-1232074479-line-16)">--non-interactive-mode</text><text class="terminal-1232074479-r2" x="1464" y="410.4" textLength="12.2" clip-path="url(#terminal-1232074479-line-16)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="410.4" textLength="24.4" clip-path="url(#terminal-1915255058-line-16)">-n</text><text class="terminal-1915255058-r2" x="48.8" y="410.4" textLength="24.4" clip-path="url(#terminal-1915255058-line-16)">, </text><text class="terminal-1915255058-r4" x="73.2" y="410.4" textLength="268.4" clip-path="url(#terminal-1915255058-line-16)">--non-interactive-mode</text><text class="terminal-1915255058-r2" x="1464" y="410.4" textLength="12.2" clip-path="url(#terminal-1915255058-line-16)">
|
||||||
</text><text class="terminal-1232074479-r2" x="292.8" y="434.8" textLength="634.4" clip-path="url(#terminal-1232074479-line-17)">run in non-interactive mode, disabling progress bars</text><text class="terminal-1232074479-r2" x="1464" y="434.8" textLength="12.2" clip-path="url(#terminal-1232074479-line-17)">
|
</text><text class="terminal-1915255058-r2" x="292.8" y="434.8" textLength="634.4" clip-path="url(#terminal-1915255058-line-17)">run in non-interactive mode, disabling progress bars</text><text class="terminal-1915255058-r2" x="1464" y="434.8" textLength="12.2" clip-path="url(#terminal-1915255058-line-17)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="459.2" textLength="24.4" clip-path="url(#terminal-1232074479-line-18)">-p</text><text class="terminal-1232074479-r2" x="48.8" y="459.2" textLength="24.4" clip-path="url(#terminal-1232074479-line-18)">, </text><text class="terminal-1232074479-r4" x="73.2" y="459.2" textLength="195.2" clip-path="url(#terminal-1232074479-line-18)">--root-directory</text><text class="terminal-1232074479-r5" x="280.6" y="459.2" textLength="48.8" clip-path="url(#terminal-1232074479-line-18)">ROOT</text><text class="terminal-1232074479-r2" x="1464" y="459.2" textLength="12.2" clip-path="url(#terminal-1232074479-line-18)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="459.2" textLength="24.4" clip-path="url(#terminal-1915255058-line-18)">-p</text><text class="terminal-1915255058-r2" x="48.8" y="459.2" textLength="24.4" clip-path="url(#terminal-1915255058-line-18)">, </text><text class="terminal-1915255058-r4" x="73.2" y="459.2" textLength="195.2" clip-path="url(#terminal-1915255058-line-18)">--root-directory</text><text class="terminal-1915255058-r5" x="280.6" y="459.2" textLength="48.8" clip-path="url(#terminal-1915255058-line-18)">ROOT</text><text class="terminal-1915255058-r2" x="1464" y="459.2" textLength="12.2" clip-path="url(#terminal-1915255058-line-18)">
|
||||||
</text><text class="terminal-1232074479-r2" x="292.8" y="483.6" textLength="439.2" clip-path="url(#terminal-1232074479-line-19)">root directory containing the images</text><text class="terminal-1232074479-r2" x="1464" y="483.6" textLength="12.2" clip-path="url(#terminal-1232074479-line-19)">
|
</text><text class="terminal-1915255058-r2" x="292.8" y="483.6" textLength="439.2" clip-path="url(#terminal-1915255058-line-19)">root directory containing the images</text><text class="terminal-1915255058-r2" x="1464" y="483.6" textLength="12.2" clip-path="url(#terminal-1915255058-line-19)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="508" textLength="24.4" clip-path="url(#terminal-1232074479-line-20)">-t</text><text class="terminal-1232074479-r2" x="48.8" y="508" textLength="24.4" clip-path="url(#terminal-1232074479-line-20)">, </text><text class="terminal-1232074479-r4" x="73.2" y="508" textLength="146.4" clip-path="url(#terminal-1232074479-line-20)">--site-title</text><text class="terminal-1232074479-r5" x="231.8" y="508" textLength="61" clip-path="url(#terminal-1232074479-line-20)">TITLE</text><text class="terminal-1232074479-r2" x="1464" y="508" textLength="12.2" clip-path="url(#terminal-1232074479-line-20)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="508" textLength="24.4" clip-path="url(#terminal-1915255058-line-20)">-t</text><text class="terminal-1915255058-r2" x="48.8" y="508" textLength="24.4" clip-path="url(#terminal-1915255058-line-20)">, </text><text class="terminal-1915255058-r4" x="73.2" y="508" textLength="146.4" clip-path="url(#terminal-1915255058-line-20)">--site-title</text><text class="terminal-1915255058-r5" x="231.8" y="508" textLength="61" clip-path="url(#terminal-1915255058-line-20)">TITLE</text><text class="terminal-1915255058-r2" x="1464" y="508" textLength="12.2" clip-path="url(#terminal-1915255058-line-20)">
|
||||||
</text><text class="terminal-1232074479-r2" x="292.8" y="532.4" textLength="378.2" clip-path="url(#terminal-1232074479-line-21)">title of the image hosting site</text><text class="terminal-1232074479-r2" x="1464" y="532.4" textLength="12.2" clip-path="url(#terminal-1232074479-line-21)">
|
</text><text class="terminal-1915255058-r2" x="292.8" y="532.4" textLength="378.2" clip-path="url(#terminal-1915255058-line-21)">title of the image hosting site</text><text class="terminal-1915255058-r2" x="1464" y="532.4" textLength="12.2" clip-path="url(#terminal-1915255058-line-21)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="556.8" textLength="24.4" clip-path="url(#terminal-1232074479-line-22)">-w</text><text class="terminal-1232074479-r2" x="48.8" y="556.8" textLength="24.4" clip-path="url(#terminal-1232074479-line-22)">, </text><text class="terminal-1232074479-r4" x="73.2" y="556.8" textLength="170.8" clip-path="url(#terminal-1232074479-line-22)">--web-root-url</text><text class="terminal-1232074479-r5" x="256.2" y="556.8" textLength="36.6" clip-path="url(#terminal-1232074479-line-22)">URL</text><text class="terminal-1232074479-r2" x="1464" y="556.8" textLength="12.2" clip-path="url(#terminal-1232074479-line-22)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="556.8" textLength="24.4" clip-path="url(#terminal-1915255058-line-22)">-w</text><text class="terminal-1915255058-r2" x="48.8" y="556.8" textLength="24.4" clip-path="url(#terminal-1915255058-line-22)">, </text><text class="terminal-1915255058-r4" x="73.2" y="556.8" textLength="170.8" clip-path="url(#terminal-1915255058-line-22)">--web-root-url</text><text class="terminal-1915255058-r5" x="256.2" y="556.8" textLength="36.6" clip-path="url(#terminal-1915255058-line-22)">URL</text><text class="terminal-1915255058-r2" x="1464" y="556.8" textLength="12.2" clip-path="url(#terminal-1915255058-line-22)">
|
||||||
</text><text class="terminal-1232074479-r2" x="292.8" y="581.2" textLength="622.2" clip-path="url(#terminal-1232074479-line-23)">base URL of the web root for the image hosting site</text><text class="terminal-1232074479-r2" x="1464" y="581.2" textLength="12.2" clip-path="url(#terminal-1232074479-line-23)">
|
</text><text class="terminal-1915255058-r2" x="292.8" y="581.2" textLength="622.2" clip-path="url(#terminal-1915255058-line-23)">base URL of the web root for the image hosting site</text><text class="terminal-1915255058-r2" x="1464" y="581.2" textLength="12.2" clip-path="url(#terminal-1915255058-line-23)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="605.6" textLength="195.2" clip-path="url(#terminal-1232074479-line-24)">--exclude-folder</text><text class="terminal-1232074479-r5" x="231.8" y="605.6" textLength="73.2" clip-path="url(#terminal-1232074479-line-24)">FOLDER</text><text class="terminal-1232074479-r2" x="1464" y="605.6" textLength="12.2" clip-path="url(#terminal-1232074479-line-24)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="605.6" textLength="24.4" clip-path="url(#terminal-1915255058-line-24)">-c</text><text class="terminal-1915255058-r2" x="48.8" y="605.6" textLength="24.4" clip-path="url(#terminal-1915255058-line-24)">, </text><text class="terminal-1915255058-r4" x="73.2" y="605.6" textLength="158.6" clip-path="url(#terminal-1915255058-line-24)">--config-file</text><text class="terminal-1915255058-r5" x="244" y="605.6" textLength="134.2" clip-path="url(#terminal-1915255058-line-24)">CONFIG_FILE</text><text class="terminal-1915255058-r2" x="1464" y="605.6" textLength="12.2" clip-path="url(#terminal-1915255058-line-24)">
|
||||||
</text><text class="terminal-1232074479-r2" x="292.8" y="630" textLength="1037" clip-path="url(#terminal-1232074479-line-25)">folders to exclude from processing, globs supported (can be specified multiple times)</text><text class="terminal-1232074479-r2" x="1464" y="630" textLength="12.2" clip-path="url(#terminal-1232074479-line-25)">
|
</text><text class="terminal-1915255058-r2" x="292.8" y="630" textLength="195.2" clip-path="url(#terminal-1915255058-line-25)">config file path</text><text class="terminal-1915255058-r2" x="1464" y="630" textLength="12.2" clip-path="url(#terminal-1915255058-line-25)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="654.4" textLength="219.6" clip-path="url(#terminal-1232074479-line-26)">--folderthumbnails</text><text class="terminal-1232074479-r2" x="292.8" y="654.4" textLength="817.4" clip-path="url(#terminal-1232074479-line-26)">generate subfolder thumbnails (first image in folder will be shown)</text><text class="terminal-1232074479-r2" x="1464" y="654.4" textLength="12.2" clip-path="url(#terminal-1232074479-line-26)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="654.4" textLength="195.2" clip-path="url(#terminal-1915255058-line-26)">--exclude-folder</text><text class="terminal-1915255058-r5" x="231.8" y="654.4" textLength="73.2" clip-path="url(#terminal-1915255058-line-26)">FOLDER</text><text class="terminal-1915255058-r2" x="1464" y="654.4" textLength="12.2" clip-path="url(#terminal-1915255058-line-26)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="678.8" textLength="244" clip-path="url(#terminal-1232074479-line-27)">--ignore-other-files</text><text class="terminal-1232074479-r2" x="292.8" y="678.8" textLength="671" clip-path="url(#terminal-1232074479-line-27)">ignore files that do not match the specified extensions</text><text class="terminal-1232074479-r2" x="1464" y="678.8" textLength="12.2" clip-path="url(#terminal-1232074479-line-27)">
|
</text><text class="terminal-1915255058-r2" x="292.8" y="678.8" textLength="1037" clip-path="url(#terminal-1915255058-line-27)">folders to exclude from processing, globs supported (can be specified multiple times)</text><text class="terminal-1915255058-r2" x="1464" y="678.8" textLength="12.2" clip-path="url(#terminal-1915255058-line-27)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="703.2" textLength="219.6" clip-path="url(#terminal-1232074479-line-28)">--ignore-extension</text><text class="terminal-1232074479-r5" x="256.2" y="703.2" textLength="109.8" clip-path="url(#terminal-1232074479-line-28)">EXTENSION</text><text class="terminal-1232074479-r2" x="1464" y="703.2" textLength="12.2" clip-path="url(#terminal-1232074479-line-28)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="703.2" textLength="219.6" clip-path="url(#terminal-1915255058-line-28)">--folderthumbnails</text><text class="terminal-1915255058-r2" x="292.8" y="703.2" textLength="817.4" clip-path="url(#terminal-1915255058-line-28)">generate subfolder thumbnails (first image in folder will be shown)</text><text class="terminal-1915255058-r2" x="1464" y="703.2" textLength="12.2" clip-path="url(#terminal-1915255058-line-28)">
|
||||||
</text><text class="terminal-1232074479-r2" x="292.8" y="727.6" textLength="719.8" clip-path="url(#terminal-1232074479-line-29)">file extensions to ignore (can be specified multiple times)</text><text class="terminal-1232074479-r2" x="1464" y="727.6" textLength="12.2" clip-path="url(#terminal-1232074479-line-29)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="727.6" textLength="244" clip-path="url(#terminal-1915255058-line-29)">--ignore-other-files</text><text class="terminal-1915255058-r2" x="292.8" y="727.6" textLength="671" clip-path="url(#terminal-1915255058-line-29)">ignore files that do not match the specified extensions</text><text class="terminal-1915255058-r2" x="1464" y="727.6" textLength="12.2" clip-path="url(#terminal-1915255058-line-29)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="752" textLength="280.6" clip-path="url(#terminal-1232074479-line-30)">--regenerate-thumbnails</text><text class="terminal-1232074479-r2" x="1464" y="752" textLength="12.2" clip-path="url(#terminal-1232074479-line-30)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="752" textLength="219.6" clip-path="url(#terminal-1915255058-line-30)">--ignore-extension</text><text class="terminal-1915255058-r5" x="256.2" y="752" textLength="109.8" clip-path="url(#terminal-1915255058-line-30)">EXTENSION</text><text class="terminal-1915255058-r2" x="1464" y="752" textLength="12.2" clip-path="url(#terminal-1915255058-line-30)">
|
||||||
</text><text class="terminal-1232074479-r2" x="292.8" y="776.4" textLength="585.6" clip-path="url(#terminal-1232074479-line-31)">regenerate thumbnails even if they already exist</text><text class="terminal-1232074479-r2" x="1464" y="776.4" textLength="12.2" clip-path="url(#terminal-1232074479-line-31)">
|
</text><text class="terminal-1915255058-r2" x="292.8" y="776.4" textLength="719.8" clip-path="url(#terminal-1915255058-line-31)">file extensions to ignore (can be specified multiple times)</text><text class="terminal-1915255058-r2" x="1464" y="776.4" textLength="12.2" clip-path="url(#terminal-1915255058-line-31)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="800.8" textLength="207.4" clip-path="url(#terminal-1232074479-line-32)">--reread-metadata</text><text class="terminal-1232074479-r2" x="292.8" y="800.8" textLength="256.2" clip-path="url(#terminal-1232074479-line-32)">reread image metadata</text><text class="terminal-1232074479-r2" x="1464" y="800.8" textLength="12.2" clip-path="url(#terminal-1232074479-line-32)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="800.8" textLength="280.6" clip-path="url(#terminal-1915255058-line-32)">--regenerate-thumbnails</text><text class="terminal-1915255058-r2" x="1464" y="800.8" textLength="12.2" clip-path="url(#terminal-1915255058-line-32)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="825.2" textLength="195.2" clip-path="url(#terminal-1232074479-line-33)">--reread-sidecar</text><text class="terminal-1232074479-r2" x="292.8" y="825.2" textLength="244" clip-path="url(#terminal-1232074479-line-33)">reread sidecar files</text><text class="terminal-1232074479-r2" x="1464" y="825.2" textLength="12.2" clip-path="url(#terminal-1232074479-line-33)">
|
</text><text class="terminal-1915255058-r2" x="292.8" y="825.2" textLength="585.6" clip-path="url(#terminal-1915255058-line-33)">regenerate thumbnails even if they already exist</text><text class="terminal-1915255058-r2" x="1464" y="825.2" textLength="12.2" clip-path="url(#terminal-1915255058-line-33)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="849.6" textLength="170.8" clip-path="url(#terminal-1232074479-line-34)">--reverse-sort</text><text class="terminal-1232074479-r2" x="292.8" y="849.6" textLength="341.6" clip-path="url(#terminal-1232074479-line-34)">sort images in reverse order</text><text class="terminal-1232074479-r2" x="1464" y="849.6" textLength="12.2" clip-path="url(#terminal-1232074479-line-34)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="849.6" textLength="207.4" clip-path="url(#terminal-1915255058-line-34)">--reread-metadata</text><text class="terminal-1915255058-r2" x="292.8" y="849.6" textLength="256.2" clip-path="url(#terminal-1915255058-line-34)">reread image metadata</text><text class="terminal-1915255058-r2" x="1464" y="849.6" textLength="12.2" clip-path="url(#terminal-1915255058-line-34)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="874" textLength="146.4" clip-path="url(#terminal-1232074479-line-35)">--theme-path</text><text class="terminal-1232074479-r5" x="183" y="874" textLength="48.8" clip-path="url(#terminal-1232074479-line-35)">PATH</text><text class="terminal-1232074479-r2" x="292.8" y="874" textLength="317.2" clip-path="url(#terminal-1232074479-line-35)">path to the CSS theme file</text><text class="terminal-1232074479-r2" x="1464" y="874" textLength="12.2" clip-path="url(#terminal-1232074479-line-35)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="874" textLength="195.2" clip-path="url(#terminal-1915255058-line-35)">--reread-sidecar</text><text class="terminal-1915255058-r2" x="292.8" y="874" textLength="244" clip-path="url(#terminal-1915255058-line-35)">reread sidecar files</text><text class="terminal-1915255058-r2" x="1464" y="874" textLength="12.2" clip-path="url(#terminal-1915255058-line-35)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="898.4" textLength="231.8" clip-path="url(#terminal-1232074479-line-36)">--use-fancy-folders</text><text class="terminal-1232074479-r2" x="292.8" y="898.4" textLength="878.4" clip-path="url(#terminal-1232074479-line-36)">enable fancy folder view instead of the default Apache directory listing</text><text class="terminal-1232074479-r2" x="1464" y="898.4" textLength="12.2" clip-path="url(#terminal-1232074479-line-36)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="898.4" textLength="170.8" clip-path="url(#terminal-1915255058-line-36)">--reverse-sort</text><text class="terminal-1915255058-r2" x="292.8" y="898.4" textLength="341.6" clip-path="url(#terminal-1915255058-line-36)">sort images in reverse order</text><text class="terminal-1915255058-r2" x="1464" y="898.4" textLength="12.2" clip-path="url(#terminal-1915255058-line-36)">
|
||||||
</text><text class="terminal-1232074479-r4" x="24.4" y="922.8" textLength="109.8" clip-path="url(#terminal-1232074479-line-37)">--version</text><text class="terminal-1232074479-r2" x="292.8" y="922.8" textLength="463.6" clip-path="url(#terminal-1232074479-line-37)">show program's version number and exit</text><text class="terminal-1232074479-r2" x="1464" y="922.8" textLength="12.2" clip-path="url(#terminal-1232074479-line-37)">
|
</text><text class="terminal-1915255058-r4" x="24.4" y="922.8" textLength="146.4" clip-path="url(#terminal-1915255058-line-37)">--theme-path</text><text class="terminal-1915255058-r5" x="183" y="922.8" textLength="48.8" clip-path="url(#terminal-1915255058-line-37)">PATH</text><text class="terminal-1915255058-r2" x="292.8" y="922.8" textLength="317.2" clip-path="url(#terminal-1915255058-line-37)">path to the CSS theme file</text><text class="terminal-1915255058-r2" x="1464" y="922.8" textLength="12.2" clip-path="url(#terminal-1915255058-line-37)">
|
||||||
|
</text><text class="terminal-1915255058-r4" x="24.4" y="947.2" textLength="231.8" clip-path="url(#terminal-1915255058-line-38)">--use-fancy-folders</text><text class="terminal-1915255058-r2" x="292.8" y="947.2" textLength="878.4" clip-path="url(#terminal-1915255058-line-38)">enable fancy folder view instead of the default Apache directory listing</text><text class="terminal-1915255058-r2" x="1464" y="947.2" textLength="12.2" clip-path="url(#terminal-1915255058-line-38)">
|
||||||
|
</text><text class="terminal-1915255058-r4" x="24.4" y="971.6" textLength="109.8" clip-path="url(#terminal-1915255058-line-39)">--version</text><text class="terminal-1915255058-r2" x="292.8" y="971.6" textLength="463.6" clip-path="url(#terminal-1915255058-line-39)">show program's version number and exit</text><text class="terminal-1915255058-r2" x="1464" y="971.6" textLength="12.2" clip-path="url(#terminal-1915255058-line-39)">
|
||||||
|
</text><text class="terminal-1915255058-r4" x="24.4" y="996" textLength="170.8" clip-path="url(#terminal-1915255058-line-40)">--write-config</text><text class="terminal-1915255058-r5" x="207.4" y="996" textLength="134.2" clip-path="url(#terminal-1915255058-line-40)">CONFIG_FILE</text><text class="terminal-1915255058-r2" x="1464" y="996" textLength="12.2" clip-path="url(#terminal-1915255058-line-40)">
|
||||||
|
</text><text class="terminal-1915255058-r2" x="292.8" y="1020.4" textLength="561.2" clip-path="url(#terminal-1915255058-line-41)">write current command line args to config file</text><text class="terminal-1915255058-r2" x="1464" y="1020.4" textLength="12.2" clip-path="url(#terminal-1915255058-line-41)">
|
||||||
</text>
|
</text>
|
||||||
</g>
|
</g>
|
||||||
</g>
|
</g>
|
||||||
|
|||||||
|
Before Width: | Height: | Size: 29 KiB After Width: | Height: | Size: 32 KiB |
@@ -1,7 +1,8 @@
|
|||||||
from dataclasses import dataclass
|
from dataclasses import dataclass
|
||||||
from typing import Optional
|
from typing import Optional
|
||||||
import os
|
import os
|
||||||
import argparse
|
|
||||||
|
import configargparse
|
||||||
|
|
||||||
try:
|
try:
|
||||||
from rich_argparse import RichHelpFormatter, HelpPreviewAction
|
from rich_argparse import RichHelpFormatter, HelpPreviewAction
|
||||||
@@ -11,14 +12,18 @@ except ModuleNotFoundError:
|
|||||||
RICH = False
|
RICH = False
|
||||||
|
|
||||||
|
|
||||||
if __package__ is None:
|
SCRIPTDIR = os.path.dirname(os.path.realpath(__file__)).removesuffix(__package__)
|
||||||
PACKAGE = ""
|
|
||||||
else:
|
|
||||||
PACKAGE = __package__
|
|
||||||
SCRIPTDIR = os.path.abspath(os.path.dirname(__file__).removesuffix(PACKAGE))
|
|
||||||
DEFAULT_THEME_PATH = os.path.join(SCRIPTDIR, "templates", "default.css")
|
DEFAULT_THEME_PATH = os.path.join(SCRIPTDIR, "templates", "default.css")
|
||||||
DEFAULT_AUTHOR = "Author"
|
DEFAULT_AUTHOR = "Author"
|
||||||
|
|
||||||
|
if "APPDATA" in os.environ:
|
||||||
|
CONFIGHOME = os.environ["APPDATA"]
|
||||||
|
elif "XDG_CONFIG_HOME" in os.environ:
|
||||||
|
CONFIGHOME = os.environ["XDG_CONFIG_HOME"]
|
||||||
|
else:
|
||||||
|
CONFIGHOME = os.path.join(os.environ["HOME"], ".config")
|
||||||
|
CONFIGPATH = os.path.join(CONFIGHOME, "StaticGalleryBuilder")
|
||||||
|
|
||||||
|
|
||||||
@dataclass(init=True)
|
@dataclass(init=True)
|
||||||
class Args:
|
class Args:
|
||||||
@@ -55,6 +60,8 @@ class Args:
|
|||||||
Whether to enable fancy folder view.
|
Whether to enable fancy folder view.
|
||||||
web_root_url : str
|
web_root_url : str
|
||||||
The base URL of the web root for the image hosting site.
|
The base URL of the web root for the image hosting site.
|
||||||
|
darktheme : bool
|
||||||
|
Whether a dark theme is present.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
author_name: str
|
author_name: str
|
||||||
@@ -75,6 +82,7 @@ class Args:
|
|||||||
theme_path: str
|
theme_path: str
|
||||||
use_fancy_folders: bool
|
use_fancy_folders: bool
|
||||||
web_root_url: str
|
web_root_url: str
|
||||||
|
darktheme: bool = False
|
||||||
|
|
||||||
def to_dict(self) -> dict:
|
def to_dict(self) -> dict:
|
||||||
result: dict = {}
|
result: dict = {}
|
||||||
@@ -97,6 +105,7 @@ class Args:
|
|||||||
result["theme_path"] = self.theme_path
|
result["theme_path"] = self.theme_path
|
||||||
result["use_fancy_folders"] = self.use_fancy_folders
|
result["use_fancy_folders"] = self.use_fancy_folders
|
||||||
result["web_root_url"] = self.web_root_url
|
result["web_root_url"] = self.web_root_url
|
||||||
|
result["darktheme"] = self.darktheme
|
||||||
return result
|
return result
|
||||||
|
|
||||||
|
|
||||||
@@ -116,9 +125,9 @@ def parse_arguments(version: str) -> Args:
|
|||||||
"""
|
"""
|
||||||
# fmt: off
|
# fmt: off
|
||||||
if RICH:
|
if RICH:
|
||||||
parser = argparse.ArgumentParser(description="generate HTML files for a static image hosting website", formatter_class=RichHelpFormatter)
|
parser = configargparse.ArgumentParser(default_config_files=[CONFIGPATH], add_config_file_help=False, description="generate HTML files for a static image hosting website", formatter_class=RichHelpFormatter)
|
||||||
else:
|
else:
|
||||||
parser = argparse.ArgumentParser(description="generate HTML files for a static image hosting website")
|
parser = configargparse.ArgumentParser(default_config_files=[CONFIGPATH], add_config_file_help=False, description="generate HTML files for a static image hosting website")
|
||||||
parser.add_argument("-a", "--author-name", help="name of the author of the images", default=DEFAULT_AUTHOR, type=str, dest="author_name", metavar="AUTHOR")
|
parser.add_argument("-a", "--author-name", help="name of the author of the images", default=DEFAULT_AUTHOR, type=str, dest="author_name", metavar="AUTHOR")
|
||||||
parser.add_argument("-e", "--file-extensions", help="file extensions to include (can be specified multiple times)", action="append", dest="file_extensions", metavar="EXTENSION")
|
parser.add_argument("-e", "--file-extensions", help="file extensions to include (can be specified multiple times)", action="append", dest="file_extensions", metavar="EXTENSION")
|
||||||
parser.add_argument("-l", "--license-type", help="specify the license type for the images", choices=["cc-zero", "cc-by", "cc-by-sa", "cc-by-nd", "cc-by-nc", "cc-by-nc-sa", "cc-by-nc-nd"], default=None, dest="license_type", metavar="LICENSE")
|
parser.add_argument("-l", "--license-type", help="specify the license type for the images", choices=["cc-zero", "cc-by", "cc-by-sa", "cc-by-nd", "cc-by-nc", "cc-by-nc-sa", "cc-by-nc-nd"], default=None, dest="license_type", metavar="LICENSE")
|
||||||
@@ -127,10 +136,11 @@ def parse_arguments(version: str) -> Args:
|
|||||||
parser.add_argument("-p", "--root-directory", help="root directory containing the images", required=True, type=str, dest="root_directory", metavar="ROOT")
|
parser.add_argument("-p", "--root-directory", help="root directory containing the images", required=True, type=str, dest="root_directory", metavar="ROOT")
|
||||||
parser.add_argument("-t", "--site-title", help="title of the image hosting site", required=True, type=str, dest="site_title", metavar="TITLE")
|
parser.add_argument("-t", "--site-title", help="title of the image hosting site", required=True, type=str, dest="site_title", metavar="TITLE")
|
||||||
parser.add_argument("-w", "--web-root-url", help="base URL of the web root for the image hosting site", required=True, type=str, dest="web_root_url", metavar="URL")
|
parser.add_argument("-w", "--web-root-url", help="base URL of the web root for the image hosting site", required=True, type=str, dest="web_root_url", metavar="URL")
|
||||||
|
parser.add_argument('-c', '--config-file', is_config_file=True, help='config file path', metavar="CONFIG_FILE")
|
||||||
parser.add_argument("--exclude-folder", help="folders to exclude from processing, globs supported (can be specified multiple times)", action="append", dest="exclude_folders", metavar="FOLDER")
|
parser.add_argument("--exclude-folder", help="folders to exclude from processing, globs supported (can be specified multiple times)", action="append", dest="exclude_folders", metavar="FOLDER")
|
||||||
parser.add_argument("--folderthumbnails", help="generate subfolder thumbnails (first image in folder will be shown)", action="store_true", default=False, dest="folder_thumbs")
|
parser.add_argument("--folderthumbnails", help="generate subfolder thumbnails (first image in folder will be shown)", action="store_true", default=False, dest="folder_thumbs")
|
||||||
if RICH:
|
if RICH:
|
||||||
parser.add_argument("--generate-help-preview", action=HelpPreviewAction, path="help.svg", )
|
parser.add_argument("--generate-help-preview", action=HelpPreviewAction, path="help.svg")
|
||||||
parser.add_argument("--ignore-other-files", help="ignore files that do not match the specified extensions", action="store_true", default=False, dest="ignore_other_files")
|
parser.add_argument("--ignore-other-files", help="ignore files that do not match the specified extensions", action="store_true", default=False, dest="ignore_other_files")
|
||||||
parser.add_argument("--ignore-extension", help="file extensions to ignore (can be specified multiple times)", action="append", default=[], dest="ignore_extensions", metavar="EXTENSION")
|
parser.add_argument("--ignore-extension", help="file extensions to ignore (can be specified multiple times)", action="append", default=[], dest="ignore_extensions", metavar="EXTENSION")
|
||||||
parser.add_argument("--regenerate-thumbnails", help="regenerate thumbnails even if they already exist", action="store_true", default=False, dest="regenerate_thumbnails")
|
parser.add_argument("--regenerate-thumbnails", help="regenerate thumbnails even if they already exist", action="store_true", default=False, dest="regenerate_thumbnails")
|
||||||
@@ -140,7 +150,12 @@ def parse_arguments(version: str) -> Args:
|
|||||||
parser.add_argument("--theme-path", help="path to the CSS theme file", default=DEFAULT_THEME_PATH, type=str, dest="theme_path", metavar="PATH")
|
parser.add_argument("--theme-path", help="path to the CSS theme file", default=DEFAULT_THEME_PATH, type=str, dest="theme_path", metavar="PATH")
|
||||||
parser.add_argument("--use-fancy-folders", help="enable fancy folder view instead of the default Apache directory listing", action="store_true", default=False, dest="use_fancy_folders")
|
parser.add_argument("--use-fancy-folders", help="enable fancy folder view instead of the default Apache directory listing", action="store_true", default=False, dest="use_fancy_folders")
|
||||||
parser.add_argument("--version", action="version", version=f"%(prog)s {version}")
|
parser.add_argument("--version", action="version", version=f"%(prog)s {version}")
|
||||||
|
parser.add_argument("--write-config", type=str, required=False, help="write current command line args to config file", metavar="CONFIG_FILE")
|
||||||
parsed_args = parser.parse_args()
|
parsed_args = parser.parse_args()
|
||||||
|
if parsed_args.write_config:
|
||||||
|
config_path = parsed_args.write_config
|
||||||
|
del parsed_args.write_config
|
||||||
|
parser.write_config_file(parsed_args, [config_path], exit_after=False)
|
||||||
# fmt: on
|
# fmt: on
|
||||||
_args = Args(
|
_args = Args(
|
||||||
author_name=parsed_args.author_name,
|
author_name=parsed_args.author_name,
|
||||||
@@ -161,5 +176,6 @@ def parse_arguments(version: str) -> Args:
|
|||||||
theme_path=parsed_args.theme_path,
|
theme_path=parsed_args.theme_path,
|
||||||
use_fancy_folders=parsed_args.use_fancy_folders,
|
use_fancy_folders=parsed_args.use_fancy_folders,
|
||||||
web_root_url=parsed_args.web_root_url,
|
web_root_url=parsed_args.web_root_url,
|
||||||
|
darktheme=False,
|
||||||
)
|
)
|
||||||
return _args
|
return _args
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ def extract_colorscheme(theme_path: str) -> dict[str, str]:
|
|||||||
dictionary containing color scheme variables and their hexadecimal values.
|
dictionary containing color scheme variables and their hexadecimal values.
|
||||||
"""
|
"""
|
||||||
logger.info("extracting color scheme from theme file", extra={"theme_path": theme_path})
|
logger.info("extracting color scheme from theme file", extra={"theme_path": theme_path})
|
||||||
pattern = r"--(color[1-4]|bcolor1):\s*(#[0-9a-fA-F]+|rgba?\([^)]*\)|hsla?\([^)]*\)|[a-zA-Z]+);"
|
pattern = r"--(color\d+|bcolor\d+):\s*(#[0-9a-fA-F]+|rgba?\([^)]*\)|hsla?\([^)]*\)|[a-zA-Z]+);"
|
||||||
colorscheme = {}
|
colorscheme = {}
|
||||||
|
|
||||||
with open(theme_path, "r", encoding="utf-8") as f:
|
with open(theme_path, "r", encoding="utf-8") as f:
|
||||||
|
|||||||
@@ -52,7 +52,7 @@ def from_native_dict(f: Callable[[Any], T], x: Any) -> Dict[Any, T]:
|
|||||||
class ImageMetadata:
|
class ImageMetadata:
|
||||||
w: Optional[int]
|
w: Optional[int]
|
||||||
h: Optional[int]
|
h: Optional[int]
|
||||||
tags: List[str]
|
tags: Optional[List[str]]
|
||||||
exifdata: Optional[Dict[str, Any]]
|
exifdata: Optional[Dict[str, Any]]
|
||||||
xmp: Optional[Dict[str, Any]]
|
xmp: Optional[Dict[str, Any]]
|
||||||
src: str
|
src: str
|
||||||
@@ -67,7 +67,7 @@ class ImageMetadata:
|
|||||||
assert isinstance(obj, dict)
|
assert isinstance(obj, dict)
|
||||||
w = from_union([from_int, from_none], obj.get("w"))
|
w = from_union([from_int, from_none], obj.get("w"))
|
||||||
h = from_union([from_int, from_none], obj.get("h"))
|
h = from_union([from_int, from_none], obj.get("h"))
|
||||||
tags = from_list(from_str, obj.get("tags"))
|
tags = from_union([lambda x: from_list(from_str, x), from_none], obj.get("tags"))
|
||||||
exifdata = from_union([lambda x: from_native_dict(dict, x), from_none], obj.get("exifdata"))
|
exifdata = from_union([lambda x: from_native_dict(dict, x), from_none], obj.get("exifdata"))
|
||||||
xmp = from_union([lambda x: from_native_dict(dict, x), from_none], obj.get("xmp"))
|
xmp = from_union([lambda x: from_native_dict(dict, x), from_none], obj.get("xmp"))
|
||||||
src = from_str(obj.get("src"))
|
src = from_str(obj.get("src"))
|
||||||
@@ -84,7 +84,8 @@ class ImageMetadata:
|
|||||||
result["w"] = from_union([from_int, from_none], self.w)
|
result["w"] = from_union([from_int, from_none], self.w)
|
||||||
if self.h is not None:
|
if self.h is not None:
|
||||||
result["h"] = from_union([from_int, from_none], self.h)
|
result["h"] = from_union([from_int, from_none], self.h)
|
||||||
result["tags"] = from_list(from_str, self.tags)
|
if self.tags is not None:
|
||||||
|
result["tags"] = from_union([lambda x: from_list(from_str, x), from_none], self.tags)
|
||||||
result["src"] = from_str(self.src)
|
result["src"] = from_str(self.src)
|
||||||
result["msrc"] = from_str(self.msrc)
|
result["msrc"] = from_str(self.msrc)
|
||||||
result["name"] = from_str(self.name)
|
result["name"] = from_str(self.name)
|
||||||
|
|||||||
@@ -20,11 +20,7 @@ from modules.argumentparser import Args
|
|||||||
from modules.datatypes.metadata import Metadata, ImageMetadata, SubfolderMetadata
|
from modules.datatypes.metadata import Metadata, ImageMetadata, SubfolderMetadata
|
||||||
|
|
||||||
# Constants for file paths and exclusions
|
# Constants for file paths and exclusions
|
||||||
if __package__ is None:
|
SCRIPTDIR = os.path.dirname(os.path.realpath(__file__)).removesuffix(__package__)
|
||||||
PACKAGE = ""
|
|
||||||
else:
|
|
||||||
PACKAGE = __package__
|
|
||||||
SCRIPTDIR = os.path.abspath(os.path.dirname(__file__).removesuffix(PACKAGE))
|
|
||||||
FAVICON_PATH = ".static/favicon.ico"
|
FAVICON_PATH = ".static/favicon.ico"
|
||||||
GLOBAL_CSS_PATH = ".static/global.css"
|
GLOBAL_CSS_PATH = ".static/global.css"
|
||||||
EXCLUDES = ["index.html", "manifest.json", "robots.txt"]
|
EXCLUDES = ["index.html", "manifest.json", "robots.txt"]
|
||||||
@@ -427,7 +423,7 @@ def generate_html(folder: str, title: str, _args: Args, raw: list[str], version:
|
|||||||
|
|
||||||
logger.info("processing contents", extra={"folder": folder})
|
logger.info("processing contents", extra={"folder": folder})
|
||||||
if not _args.non_interactive_mode:
|
if not _args.non_interactive_mode:
|
||||||
for item in tqdm(items, total=len(items), desc=f"Getting image infos - {folder}", unit="files", ascii=True, dynamic_ncols=True):
|
for item in tqdm(items, total=len(items), desc=f"Getting image infos - {folder}", unit="files", ascii=True, dynamic_ncols=True, leave=False):
|
||||||
if item not in EXCLUDES and not item.startswith(".") and os.path.splitext(item)[1][1:].lower() not in _args.ignore_extensions:
|
if item not in EXCLUDES and not item.startswith(".") and os.path.splitext(item)[1][1:].lower() not in _args.ignore_extensions:
|
||||||
if os.path.isdir(os.path.join(folder, item)):
|
if os.path.isdir(os.path.join(folder, item)):
|
||||||
subfoldertags.update(process_subfolder(item, folder, baseurl, subfolders, _args, raw, version, logo))
|
subfoldertags.update(process_subfolder(item, folder, baseurl, subfolders, _args, raw, version, logo))
|
||||||
@@ -625,6 +621,7 @@ def create_html_file(
|
|||||||
favicon=f"{_args.web_root_url}{FAVICON_PATH}",
|
favicon=f"{_args.web_root_url}{FAVICON_PATH}",
|
||||||
stylesheet=f"{_args.web_root_url}{GLOBAL_CSS_PATH}",
|
stylesheet=f"{_args.web_root_url}{GLOBAL_CSS_PATH}",
|
||||||
theme=f"{_args.web_root_url}.static/theme.css",
|
theme=f"{_args.web_root_url}.static/theme.css",
|
||||||
|
darktheme=f"{_args.web_root_url}.static/theme-dark.css" if _args.darktheme else None,
|
||||||
root=_args.web_root_url,
|
root=_args.web_root_url,
|
||||||
parent=f"{_args.web_root_url}{urllib.parse.quote(foldername)}",
|
parent=f"{_args.web_root_url}{urllib.parse.quote(foldername)}",
|
||||||
header=f"{header} - LICENSE",
|
header=f"{header} - LICENSE",
|
||||||
@@ -642,6 +639,7 @@ def create_html_file(
|
|||||||
favicon=f"{_args.web_root_url}{FAVICON_PATH}",
|
favicon=f"{_args.web_root_url}{FAVICON_PATH}",
|
||||||
stylesheet=f"{_args.web_root_url}{GLOBAL_CSS_PATH}",
|
stylesheet=f"{_args.web_root_url}{GLOBAL_CSS_PATH}",
|
||||||
theme=f"{_args.web_root_url}.static/theme.css",
|
theme=f"{_args.web_root_url}.static/theme.css",
|
||||||
|
darktheme=f"{_args.web_root_url}.static/theme-dark.css" if _args.darktheme else None,
|
||||||
root=_args.web_root_url,
|
root=_args.web_root_url,
|
||||||
parent=parent,
|
parent=parent,
|
||||||
header=header,
|
header=header,
|
||||||
|
|||||||
@@ -21,11 +21,7 @@ from datetime import datetime
|
|||||||
from pythonjsonlogger import jsonlogger
|
from pythonjsonlogger import jsonlogger
|
||||||
|
|
||||||
# Constants for file paths and exclusions
|
# Constants for file paths and exclusions
|
||||||
if __package__ is None:
|
SCRIPTDIR = os.path.dirname(os.path.realpath(__file__)).removesuffix(__package__)
|
||||||
PACKAGE = ""
|
|
||||||
else:
|
|
||||||
PACKAGE = __package__
|
|
||||||
SCRIPTDIR = os.path.abspath(os.path.dirname(__file__).removesuffix(PACKAGE))
|
|
||||||
LOG_DIR = os.path.join(SCRIPTDIR, "logs")
|
LOG_DIR = os.path.join(SCRIPTDIR, "logs")
|
||||||
LATEST_LOG_FILE = os.path.join(LOG_DIR, "latest.jsonl")
|
LATEST_LOG_FILE = os.path.join(LOG_DIR, "latest.jsonl")
|
||||||
|
|
||||||
|
|||||||
@@ -18,11 +18,7 @@ from modules.argumentparser import Args
|
|||||||
from modules.css_color import extract_theme_color, extract_colorscheme
|
from modules.css_color import extract_theme_color, extract_colorscheme
|
||||||
|
|
||||||
# Define constants for static files directory and icon sizes
|
# Define constants for static files directory and icon sizes
|
||||||
if __package__ is None:
|
SCRIPTDIR = os.path.dirname(os.path.realpath(__file__)).removesuffix(__package__)
|
||||||
PACKAGE = ""
|
|
||||||
else:
|
|
||||||
PACKAGE = __package__
|
|
||||||
SCRIPTDIR = os.path.abspath(os.path.dirname(__file__).removesuffix(PACKAGE))
|
|
||||||
STATIC_FILES_DIR = os.path.join(SCRIPTDIR, "files")
|
STATIC_FILES_DIR = os.path.join(SCRIPTDIR, "files")
|
||||||
ICON_SIZES = ["36x36", "48x48", "72x72", "96x96", "144x144", "192x192", "512x512"]
|
ICON_SIZES = ["36x36", "48x48", "72x72", "96x96", "144x144", "192x192", "512x512"]
|
||||||
|
|
||||||
|
|||||||
@@ -1,12 +1,12 @@
|
|||||||
beautifulsoup4~=4.13.4
|
beautifulsoup4~=4.14.3
|
||||||
CairoSVG~=2.7.1
|
CairoSVG~=2.7.1
|
||||||
|
ConfigArgParse~=1.7.1
|
||||||
defusedxml~=0.7.1
|
defusedxml~=0.7.1
|
||||||
html5lib~=1.1
|
html5lib~=1.1
|
||||||
Jinja2~=3.1.6
|
Jinja2~=3.1.6
|
||||||
jsmin~=3.0.1
|
jsmin~=3.0.1
|
||||||
Pillow~=11.3.0
|
Pillow~=12.1.0
|
||||||
pyinstaller~=6.11.1
|
|
||||||
python_json_logger~=2.0.7
|
python_json_logger~=2.0.7
|
||||||
rich_argparse~=1.7.1
|
rich_argparse~=1.7.2
|
||||||
selenium~=4.34.2
|
selenium~=4.40.0
|
||||||
tqdm~=4.66.4
|
tqdm~=4.66.6
|
||||||
|
|||||||
111
templates/default-dark.css
Normal file
111
templates/default-dark.css
Normal file
@@ -0,0 +1,111 @@
|
|||||||
|
@import url("https://fonts.googleapis.com/css2?family=Ubuntu:ital,wght@0,300;0,400;0,500;0,700;1,300;1,400;1,500;1,700&display=swap");
|
||||||
|
|
||||||
|
* {
|
||||||
|
--color1: #262a2b;
|
||||||
|
--color2: #0d0e0e;
|
||||||
|
--color3: #313537;
|
||||||
|
--color4: #181a1b;
|
||||||
|
--color5: #5483ef;
|
||||||
|
--bcolor1: #e8e6e3;
|
||||||
|
--bcolor2: #0c0d0e;
|
||||||
|
}
|
||||||
|
|
||||||
|
.navbar {
|
||||||
|
font-weight: bold;
|
||||||
|
color: var(--bcolor1);
|
||||||
|
background-color: var(--color1);
|
||||||
|
}
|
||||||
|
|
||||||
|
.navbar li a {
|
||||||
|
font-weight: bold;
|
||||||
|
color: var(--bcolor1);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Change the link color on hover */
|
||||||
|
.navbar li a:hover {
|
||||||
|
background-color: var(--color2);
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer {
|
||||||
|
color: var(--bcolor1);
|
||||||
|
background-color: var(--color3);
|
||||||
|
font-weight: 500;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer a {
|
||||||
|
color: var(--color5);
|
||||||
|
text-decoration: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.foldericon {
|
||||||
|
content: "themes/icons/folder-2.svg.j2";
|
||||||
|
}
|
||||||
|
|
||||||
|
.folders a {
|
||||||
|
font-weight: 700;
|
||||||
|
color: var(--color5);
|
||||||
|
text-decoration: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tooltiptext {
|
||||||
|
font-weight: 400;
|
||||||
|
background-color: var(--color3);
|
||||||
|
}
|
||||||
|
|
||||||
|
.tagentry label:hover {
|
||||||
|
background-color: var(--color4);
|
||||||
|
}
|
||||||
|
|
||||||
|
.tagentry .tagtoggle:hover {
|
||||||
|
background-color: var(--color4);
|
||||||
|
}
|
||||||
|
|
||||||
|
.column img {
|
||||||
|
background-color: var(--bcolor2);
|
||||||
|
}
|
||||||
|
|
||||||
|
#totop:hover {
|
||||||
|
background-color: var(--color2);
|
||||||
|
}
|
||||||
|
|
||||||
|
#totop {
|
||||||
|
background-color: var(--color1);
|
||||||
|
color: var(--bcolor1);
|
||||||
|
font-weight: 800;
|
||||||
|
}
|
||||||
|
|
||||||
|
.loader {
|
||||||
|
width: 48px;
|
||||||
|
height: 48px;
|
||||||
|
border-radius: 50%;
|
||||||
|
display: inline-block;
|
||||||
|
border-top: 3px solid var(--bcolor1);
|
||||||
|
border-right: 3px solid transparent;
|
||||||
|
box-sizing: border-box;
|
||||||
|
animation: rotation 1s linear infinite;
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes rotation {
|
||||||
|
0% {
|
||||||
|
transform: rotate(0deg);
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
transform: rotate(360deg);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
body {
|
||||||
|
color: var(--bcolor1);
|
||||||
|
background-color: var(--color4);
|
||||||
|
font-family: "Ubuntu", sans-serif;
|
||||||
|
font-optical-sizing: auto;
|
||||||
|
font-weight: 400;
|
||||||
|
font-style: normal;
|
||||||
|
}
|
||||||
|
|
||||||
|
body a {
|
||||||
|
font-weight: 400;
|
||||||
|
color: var(--color5);
|
||||||
|
text-decoration: none;
|
||||||
|
}
|
||||||
@@ -24,6 +24,10 @@ class PhotoGallery {
|
|||||||
this.scrollFunction = this.scrollFunction.bind(this);
|
this.scrollFunction = this.scrollFunction.bind(this);
|
||||||
this.topFunction = this.topFunction.bind(this);
|
this.topFunction = this.topFunction.bind(this);
|
||||||
this.onLoad = this.onLoad.bind(this);
|
this.onLoad = this.onLoad.bind(this);
|
||||||
|
this.darkMode = this.darkMode.bind(this);
|
||||||
|
this.lightMode = this.lightMode.bind(this);
|
||||||
|
this.darkModeToggle = this.darkModeToggle.bind(this);
|
||||||
|
this.detectDarkMode = this.detectDarkMode.bind(this);
|
||||||
|
|
||||||
this.init();
|
this.init();
|
||||||
}
|
}
|
||||||
@@ -38,12 +42,7 @@ class PhotoGallery {
|
|||||||
|
|
||||||
openSwipe(imgIndex) {
|
openSwipe(imgIndex) {
|
||||||
const options = { index: imgIndex };
|
const options = { index: imgIndex };
|
||||||
const gallery = new PhotoSwipe(
|
const gallery = new PhotoSwipe(this.pswpElement, PhotoSwipeUI_Default, this.shown, options);
|
||||||
this.pswpElement,
|
|
||||||
PhotoSwipeUI_Default,
|
|
||||||
this.shown,
|
|
||||||
options
|
|
||||||
);
|
|
||||||
gallery.init();
|
gallery.init();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -78,9 +77,7 @@ class PhotoGallery {
|
|||||||
|
|
||||||
if (folders) folders.style.display = "";
|
if (folders) folders.style.display = "";
|
||||||
document.getElementById("recursive").checked = false;
|
document.getElementById("recursive").checked = false;
|
||||||
document
|
document.querySelectorAll("#tagdropdown input.tagcheckbox:checked").forEach((checkbox) => (checkbox.checked = false));
|
||||||
.querySelectorAll("#tagdropdown input.tagcheckbox:checked")
|
|
||||||
.forEach((checkbox) => (checkbox.checked = false));
|
|
||||||
window.history.replaceState({ html: content, pageTitle: title }, "", path);
|
window.history.replaceState({ html: content, pageTitle: title }, "", path);
|
||||||
this.requestMetadata();
|
this.requestMetadata();
|
||||||
}
|
}
|
||||||
@@ -150,10 +147,9 @@ class PhotoGallery {
|
|||||||
existingItems.add(image.src);
|
existingItems.add(image.src);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (Array.isArray(data.subfolders))
|
if (Array.isArray(data.subfolders)) nextLevel.push(...data.subfolders);
|
||||||
nextLevel.push(...data.subfolders);
|
|
||||||
} catch {}
|
} catch {}
|
||||||
})
|
}),
|
||||||
);
|
);
|
||||||
if (nextLevel.length > 0) await fetchFoldersRecursively(nextLevel);
|
if (nextLevel.length > 0) await fetchFoldersRecursively(nextLevel);
|
||||||
};
|
};
|
||||||
@@ -194,21 +190,15 @@ class PhotoGallery {
|
|||||||
filter() {
|
filter() {
|
||||||
const searchParams = new URLSearchParams(window.location.search);
|
const searchParams = new URLSearchParams(window.location.search);
|
||||||
this.shown = [];
|
this.shown = [];
|
||||||
let path = decodeURIComponent(
|
let path = decodeURIComponent(window.location.origin + window.location.pathname.replace("index.html", ""));
|
||||||
window.location.origin +
|
|
||||||
window.location.pathname.replace("index.html", "")
|
|
||||||
);
|
|
||||||
if (path.startsWith("null")) {
|
if (path.startsWith("null")) {
|
||||||
path = window.location.protocol + "//" + path.substring(4);
|
path = window.location.protocol + "//" + path.substring(4);
|
||||||
}
|
}
|
||||||
const selectedTags = [];
|
const selectedTags = [];
|
||||||
|
|
||||||
document
|
document.querySelectorAll("#tagdropdown input.tagcheckbox:checked").forEach((checkbox) => {
|
||||||
.querySelectorAll("#tagdropdown input.tagcheckbox:checked")
|
|
||||||
.forEach((checkbox) => {
|
|
||||||
let tag = checkbox.parentElement.id.trim().substring(1);
|
let tag = checkbox.parentElement.id.trim().substring(1);
|
||||||
if (checkbox.parentElement.parentElement.children.length > 1)
|
if (checkbox.parentElement.parentElement.children.length > 1) tag += "|";
|
||||||
tag += "|";
|
|
||||||
selectedTags.push(tag);
|
selectedTags.push(tag);
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -216,17 +206,14 @@ class PhotoGallery {
|
|||||||
|
|
||||||
let isRecursiveChecked = false;
|
let isRecursiveChecked = false;
|
||||||
try {
|
try {
|
||||||
isRecursiveChecked =
|
isRecursiveChecked = document.getElementById("recursive")?.checked || false;
|
||||||
document.getElementById("recursive")?.checked || false;
|
|
||||||
} catch {}
|
} catch {}
|
||||||
|
|
||||||
for (const item of this.items) {
|
for (const item of this.items) {
|
||||||
const tags = item.tags || [];
|
const tags = item.tags || [];
|
||||||
const include = selectedTags.every((selected) => {
|
const include = selectedTags.every((selected) => {
|
||||||
const isParent = selected.endsWith("|");
|
const isParent = selected.endsWith("|");
|
||||||
return isParent
|
return isParent ? tags.some((t) => t.startsWith(selected)) : tags.includes(selected);
|
||||||
? tags.some((t) => t.startsWith(selected))
|
|
||||||
: tags.includes(selected);
|
|
||||||
});
|
});
|
||||||
|
|
||||||
if (include || selectedTags.length === 0) {
|
if (include || selectedTags.length === 0) {
|
||||||
@@ -313,9 +300,7 @@ class PhotoGallery {
|
|||||||
let str = "";
|
let str = "";
|
||||||
this.shown.forEach((item, index) => {
|
this.shown.forEach((item, index) => {
|
||||||
let tags = this.parseHierarchicalTags(item.tags || []);
|
let tags = this.parseHierarchicalTags(item.tags || []);
|
||||||
str += `<div class="column"><figure title="${this.renderTree(
|
str += `<div class="column"><figure title="${this.renderTree(tags)}"><img src="${
|
||||||
tags
|
|
||||||
)}"><img src="${
|
|
||||||
item.msrc
|
item.msrc
|
||||||
}" data-index="${index}" /><figcaption class="caption">${item.name}`;
|
}" data-index="${index}" /><figcaption class="caption">${item.name}`;
|
||||||
if (item.tiff) str += ` <a href="${item.tiff}">TIFF</a>`;
|
if (item.tiff) str += ` <a href="${item.tiff}">TIFF</a>`;
|
||||||
@@ -328,16 +313,9 @@ class PhotoGallery {
|
|||||||
}
|
}
|
||||||
|
|
||||||
setFilter(selected) {
|
setFilter(selected) {
|
||||||
document
|
document.querySelectorAll("#tagdropdown input.tagcheckbox").forEach((checkbox) => {
|
||||||
.querySelectorAll("#tagdropdown input.tagcheckbox")
|
|
||||||
.forEach((checkbox) => {
|
|
||||||
selected.forEach((tag) => {
|
selected.forEach((tag) => {
|
||||||
if (
|
if (checkbox.parentElement.id.trim().substring(1).replace(" ", "%20") === tag) {
|
||||||
checkbox.parentElement.id
|
|
||||||
.trim()
|
|
||||||
.substring(1)
|
|
||||||
.replace(" ", "%20") === tag
|
|
||||||
) {
|
|
||||||
checkbox.checked = true;
|
checkbox.checked = true;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@@ -350,9 +328,7 @@ class PhotoGallery {
|
|||||||
const svg = tag?.parentElement.querySelector(".tagtoggle svg");
|
const svg = tag?.parentElement.querySelector(".tagtoggle svg");
|
||||||
if (!ol || !svg) return;
|
if (!ol || !svg) return;
|
||||||
ol.classList.toggle("show");
|
ol.classList.toggle("show");
|
||||||
svg.style.transform = ol.classList.contains("show")
|
svg.style.transform = ol.classList.contains("show") ? "rotate(180deg)" : "rotate(0deg)";
|
||||||
? "rotate(180deg)"
|
|
||||||
: "rotate(0deg)";
|
|
||||||
}
|
}
|
||||||
|
|
||||||
setupDropdownToggle() {
|
setupDropdownToggle() {
|
||||||
@@ -364,18 +340,12 @@ class PhotoGallery {
|
|||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
const svg = toggleLink.querySelector("svg");
|
const svg = toggleLink.querySelector("svg");
|
||||||
dropdown.classList.toggle("show");
|
dropdown.classList.toggle("show");
|
||||||
if (svg)
|
if (svg) svg.style.transform = dropdown.classList.contains("show") ? "rotate(180deg)" : "rotate(0deg)";
|
||||||
svg.style.transform = dropdown.classList.contains("show")
|
|
||||||
? "rotate(180deg)"
|
|
||||||
: "rotate(0deg)";
|
|
||||||
this.tagDropdownShown = dropdown.classList.contains("show");
|
this.tagDropdownShown = dropdown.classList.contains("show");
|
||||||
});
|
});
|
||||||
|
|
||||||
document.addEventListener("click", (event) => {
|
document.addEventListener("click", (event) => {
|
||||||
if (
|
if (!dropdown.contains(event.target) && !toggleLink.contains(event.target)) {
|
||||||
!dropdown.contains(event.target) &&
|
|
||||||
!toggleLink.contains(event.target)
|
|
||||||
) {
|
|
||||||
dropdown.classList.remove("show");
|
dropdown.classList.remove("show");
|
||||||
this.tagDropdownShown = false;
|
this.tagDropdownShown = false;
|
||||||
const svg = toggleLink.querySelector("svg");
|
const svg = toggleLink.querySelector("svg");
|
||||||
@@ -402,18 +372,18 @@ class PhotoGallery {
|
|||||||
}
|
}
|
||||||
|
|
||||||
setupClickHandlers() {
|
setupClickHandlers() {
|
||||||
const resetEl = document
|
const resetEl = document.getElementById("reset-filter")?.querySelector("label");
|
||||||
.getElementById("reset-filter")
|
|
||||||
?.querySelector("label");
|
|
||||||
if (resetEl) resetEl.addEventListener("click", this.reset);
|
if (resetEl) resetEl.addEventListener("click", this.reset);
|
||||||
|
|
||||||
const recurseEl = document.getElementById("recursive");
|
const recurseEl = document.getElementById("recursive");
|
||||||
if (recurseEl)
|
if (recurseEl) recurseEl.addEventListener("change", this.debounce(this.recursive, 150));
|
||||||
recurseEl.addEventListener("change", this.debounce(this.recursive, 150));
|
|
||||||
|
|
||||||
const totop = document.getElementById("totop");
|
const totop = document.getElementById("totop");
|
||||||
if (totop) totop.addEventListener("click", this.topFunction);
|
if (totop) totop.addEventListener("click", this.topFunction);
|
||||||
|
|
||||||
|
const darkModeSwitch = document.getElementById("dark-mode-switch");
|
||||||
|
if (darkModeSwitch) darkModeSwitch.addEventListener("click", this.darkModeToggle);
|
||||||
|
|
||||||
const imagelist = document.getElementById("imagelist");
|
const imagelist = document.getElementById("imagelist");
|
||||||
if (imagelist) {
|
if (imagelist) {
|
||||||
imagelist.addEventListener("click", (event) => {
|
imagelist.addEventListener("click", (event) => {
|
||||||
@@ -442,10 +412,7 @@ class PhotoGallery {
|
|||||||
scrollFunction() {
|
scrollFunction() {
|
||||||
const totopbutton = document.getElementById("totop");
|
const totopbutton = document.getElementById("totop");
|
||||||
if (!totopbutton) return;
|
if (!totopbutton) return;
|
||||||
if (
|
if (document.body.scrollTop > 20 || document.documentElement.scrollTop > 20) {
|
||||||
document.body.scrollTop > 20 ||
|
|
||||||
document.documentElement.scrollTop > 20
|
|
||||||
) {
|
|
||||||
totopbutton.style.display = "block";
|
totopbutton.style.display = "block";
|
||||||
} else {
|
} else {
|
||||||
totopbutton.style.display = "none";
|
totopbutton.style.display = "none";
|
||||||
@@ -456,6 +423,53 @@ class PhotoGallery {
|
|||||||
window.scrollTo({ top: 0, behavior: "smooth" });
|
window.scrollTo({ top: 0, behavior: "smooth" });
|
||||||
}
|
}
|
||||||
|
|
||||||
|
darkMode() {
|
||||||
|
const themeLink = document.getElementById("theme");
|
||||||
|
const darkThemeLink = document.getElementById("darktheme");
|
||||||
|
if (themeLink) themeLink.disabled = true;
|
||||||
|
if (darkThemeLink) darkThemeLink.disabled = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
lightMode() {
|
||||||
|
const themeLink = document.getElementById("theme");
|
||||||
|
const darkThemeLink = document.getElementById("darktheme");
|
||||||
|
if (themeLink) themeLink.disabled = false;
|
||||||
|
if (darkThemeLink) darkThemeLink.disabled = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
darkModeToggle(mode) {
|
||||||
|
const switchState = document.getElementById("dark-mode-switch-check");
|
||||||
|
if (mode == "dark") {
|
||||||
|
this.darkMode();
|
||||||
|
if (switchState) {
|
||||||
|
switchState.checked = true;
|
||||||
|
}
|
||||||
|
} else if (mode == "light") {
|
||||||
|
this.lightMode();
|
||||||
|
if (switchState) {
|
||||||
|
switchState.checked = false;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if (switchState.checked) {
|
||||||
|
switchState.checked = false;
|
||||||
|
this.lightMode();
|
||||||
|
} else {
|
||||||
|
switchState.checked = true;
|
||||||
|
this.darkMode();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
detectDarkMode() {
|
||||||
|
if (document.getElementById("darktheme")) {
|
||||||
|
if (window.matchMedia && window.matchMedia("(prefers-color-scheme: dark)").matches) {
|
||||||
|
this.darkModeToggle("dark");
|
||||||
|
} else {
|
||||||
|
this.darkModeToggle("light");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
onLoad() {
|
onLoad() {
|
||||||
document.querySelectorAll(".tagtoggle").forEach((toggle) => {
|
document.querySelectorAll(".tagtoggle").forEach((toggle) => {
|
||||||
toggle.addEventListener("mouseup", (event) => {
|
toggle.addEventListener("mouseup", (event) => {
|
||||||
@@ -469,6 +483,7 @@ class PhotoGallery {
|
|||||||
this.setupDropdownToggle();
|
this.setupDropdownToggle();
|
||||||
this.setupTagHandlers();
|
this.setupTagHandlers();
|
||||||
this.setupClickHandlers();
|
this.setupClickHandlers();
|
||||||
|
this.detectDarkMode();
|
||||||
|
|
||||||
window.addEventListener("scroll", this.scrollFunction);
|
window.addEventListener("scroll", this.scrollFunction);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -34,10 +34,16 @@
|
|||||||
{%- if theme %}
|
{%- if theme %}
|
||||||
<link rel="preload" href="{{ theme }}" as="style">
|
<link rel="preload" href="{{ theme }}" as="style">
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
|
{%- if darktheme %}
|
||||||
|
<link rel="preload" href="{{ darktheme }}" as="style">
|
||||||
|
{%- endif %}
|
||||||
<link rel="icon" type="image/x-icon" href="{{ favicon }}">
|
<link rel="icon" type="image/x-icon" href="{{ favicon }}">
|
||||||
<link rel="stylesheet" href="{{ stylesheet }}">
|
<link rel="stylesheet" href="{{ stylesheet }}">
|
||||||
{%- if theme %}
|
{%- if theme %}
|
||||||
<link rel="stylesheet" href="{{ theme }}">
|
<link rel="stylesheet" href="{{ theme }}" id="theme">
|
||||||
|
{%- endif %}
|
||||||
|
{%- if darktheme %}
|
||||||
|
<link rel="stylesheet" href="{{ darktheme }}" id="darktheme" disabled>
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
<link rel="preload" href="{{ root }}.static/pswp/photoswipe.css" as="style">
|
<link rel="preload" href="{{ root }}.static/pswp/photoswipe.css" as="style">
|
||||||
<link rel="preload" href="{{ root }}.static/pswp/default-skin/default-skin.css" as="style">
|
<link rel="preload" href="{{ root }}.static/pswp/default-skin/default-skin.css" as="style">
|
||||||
@@ -89,10 +95,22 @@
|
|||||||
{{ render_tags(tags, '') }}
|
{{ render_tags(tags, '') }}
|
||||||
</ol>
|
</ol>
|
||||||
</li>
|
</li>
|
||||||
{% endif %}
|
{%- endif %}
|
||||||
{%- if licensefile %}
|
{%- if licensefile %}
|
||||||
<li class="license"><a href="{{ licensefile }}">License</a></li>
|
<li class="license"><a href="{{ licensefile }}">License</a></li>
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
|
{%- if darktheme %}
|
||||||
|
<li class="darkmodeswitch">
|
||||||
|
<a class="button" id="dark-mode-switch">
|
||||||
|
<input type="checkbox" class="checkbox" id="dark-mode-switch-check" />
|
||||||
|
<div class="knobs">
|
||||||
|
<span class="light">☀︎</span>
|
||||||
|
<span class="slider"></span>
|
||||||
|
<span class="dark">☽</span>
|
||||||
|
</div>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
{%- endif %}
|
||||||
</div>
|
</div>
|
||||||
</ol>
|
</ol>
|
||||||
{% if subdirectories %}
|
{% if subdirectories %}
|
||||||
@@ -120,7 +138,7 @@
|
|||||||
<a property="dct:title" rel="cc:attributionURL" href="{{ root }}">{{ license.project }}</a> by <span property="cc:attributionName">{{ license.author }}</span> is marked with
|
<a property="dct:title" rel="cc:attributionURL" href="{{ root }}">{{ license.project }}</a> by <span property="cc:attributionName">{{ license.author }}</span> is marked with
|
||||||
<a href="{{ license.url }}" target="_blank" rel="license noopener noreferrer" style="display: inline-block">CC0 1.0
|
<a href="{{ license.url }}" target="_blank" rel="license noopener noreferrer" style="display: inline-block">CC0 1.0
|
||||||
{%- for pic in license.pics %}
|
{%- for pic in license.pics %}
|
||||||
<img style="height: 22px !important; margin-left: 3px; vertical-align: text-bottom" src="{{ pic }}" alt="" />
|
<img src="{{ pic }}" alt="" />
|
||||||
{%- endfor %}
|
{%- endfor %}
|
||||||
</a>
|
</a>
|
||||||
{%- else %}
|
{%- else %}
|
||||||
|
|||||||
2
themes
2
themes
Submodule themes updated: 2d2f96abb3...3bb36480e7
Reference in New Issue
Block a user