diff --git a/src/main.py b/src/main.py index 0314d4d..9459eb8 100644 --- a/src/main.py +++ b/src/main.py @@ -27,7 +27,7 @@ def scan_pages(folders: list[Path]) -> list[Page]: raw: Path = Path(folder, folder.get_name() + ".NEF") for file in files: if file.get_name().endswith(".png"): - page.add_picture(Picture(file, page=prev, raw=raw)) + page.add_picture(Picture(file, page=page, raw=raw)) if len(page.get_pictures()) == 0: bar.next() diff --git a/src/path.py b/src/path.py index a6bb560..4501fde 100644 --- a/src/path.py +++ b/src/path.py @@ -19,7 +19,7 @@ class Path(): def get_dirpath(self): return self._dirpath - def get_site_path(self): + def get_url(self): site_path: Path = Path(sys.argv[1]) return self._absolute_path[len(site_path._absolute_path):] diff --git a/src/picture.py b/src/picture.py index d9aa056..d2ea31e 100644 --- a/src/picture.py +++ b/src/picture.py @@ -25,6 +25,9 @@ class Picture(): self._albums_name.append("general") self._is_reperoried: bool = is_repertoried + def get_page(self): + return self._page + def get_albums_name(self): return self._albums_name diff --git a/src/templates/album.css b/src/templates/album.css index 438954d..2927114 100644 --- a/src/templates/album.css +++ b/src/templates/album.css @@ -1,3 +1,44 @@ +:root { + --bg1: #002b36; + --bg2: #073642; + --content1: #586e75; + --content2: #657b83; + --content3: #839496; + --content4: #93a1a1; + --lbg1: #eee8d5; + --lbg2: #fdf6e3; +} + +.picture-container { + display: flex; + flex-wrap: wrap; + justify-content: space-between; + background-color: var(--bg2); + width: auto; + padding: 30px; +} + body { - background-color: red; + color: white; + display: flex; + justify-content: center; + align-items: center; + flex-direction: column; + background-color: var(--bg1); +} + +img { + width: 100%; + height: auto; +} + +a { + display: flex; + flex-direction: row; + align-items: center; + background-color: var(--content1); + padding: 10px; + margin: 10px; + height: 200px; + width: 200px; } \ No newline at end of file diff --git a/src/templates/album.jinja b/src/templates/album.jinja index 9289948..aa972fc 100644 --- a/src/templates/album.jinja +++ b/src/templates/album.jinja @@ -6,12 +6,12 @@ - {{album.name}} - caaaa

{{ album._name }}

-
+
{% for picture in album._pictures %} - + + + {% endfor %}