Commit graph

44 commits

Author SHA1 Message Date
ba4866919e
feat: Implement dark mode
#11 says we need this.
2025-05-02 08:35:06 +02:00
ac52e374c7
feat: Design improvements 2025-04-12 16:52:51 +02:00
e9efb063d7
feat: Redirects and .well-known files
Some checks failed
Build and Deploy Static Site / build (push) Has been cancelled
2025-04-12 14:11:39 +02:00
adb2e92a5c
fix: Make pride.coffee work with Forgejo Pages
All checks were successful
Build and Deploy Static Site / build (push) Successful in 43s
2025-04-12 13:25:54 +02:00
59fea3d111
feat: Forgejo Pages support
All checks were successful
Build and Deploy Static Site / build (push) Successful in 46s
2025-04-12 11:02:05 +02:00
4400093dea
feat: TDoV theme
All checks were successful
Build and Deploy Static Site / build (push) Successful in 39s
2025-03-31 13:14:52 +02:00
5a0aed1730
chore: Removes markdown exclusion from asset copying
Simplifies asset copying logic to include all file types.
Replaces "Recur" with "Recurse" in comments for clarity.
2025-02-02 14:12:00 +01:00
c037d1d918
feat: Add tagging support for blog posts
All checks were successful
Build and Deploy Static Site / build (push) Successful in 7m54s
Introduces tagging system that organizes posts by tags and
generates dedicated tag index pages. Updates templates to
display tags and streamlines tag page rendering.
2025-01-01 18:34:58 +01:00
d4818860ad
fix: Improves date handling in blog generation
Some checks failed
Build and Deploy Static Site / build (push) Has been cancelled
Formats post dates as "YYYY-MM-DD HH:MM:SS" for consistency.
Appends "(future)" to dates beyond the current time if not in
development mode, enhancing readability and debugging clarity.
2025-01-01 18:07:29 +01:00
4910e06935
fix: Ensure output directory creation if missing
Creates parent directories for output files to prevent errors
when the specified output path does not exist, enhancing
reliability and user experience in generating files.
2025-01-01 18:07:05 +01:00
5a7f68f4da
refactor: Enhances logging and refactors data handling
All checks were successful
Build and Deploy Static Site / build (push) Successful in 6m39s
Integrates logging across the application for improved debugging
Replaces print statements with logging methods for consistency
Adds environment variable checks to enable debug logging

Refactors data handling into a unified structure, enhancing the extensibility
and maintainability of the static site generation process.

Modifies template rendering to accept additional parameters, increasing
the flexibility of template customization.

Relates to improved site generation efficiency and scalability initiatives.
2024-12-29 08:42:00 +01:00
0ee4d1c8a3
feat: Enable dev mode for blog RSS links
Some checks failed
Build and Deploy Static Site / build (push) Failing after 2m6s
Adds support for development mode in blog RSS generation,
ensuring links point to the development subdomain.

This change assists in testing and development by allowing
RSS feeds to dynamically adjust URLs based on the environment.
2024-12-27 21:31:28 +01:00
2024afd411
fix: Ensure post dates are timezone-aware
Some checks failed
Build and Deploy Static Site / build (push) Failing after 2m10s
Adds logic to convert post dates to timezone-aware if
they are naive, ensuring consistent time formatting.
Also updates current time retrieval with timezone
awareness for RSS generation.
2024-12-27 20:32:30 +01:00
26e98cdb75
feat: Add RSS feed generation for blog posts
Some checks failed
Build and Deploy Static Site / build (push) Failing after 2m6s
Introduces a function to generate an RSS feed from blog posts,
ensuring dates are in RFC 822 format. Sorts posts by date and
includes development mode support for URLs. Adds RSS template
to render the feed with metadata and posts from the blog.

Enhances blog visibility and syndication capabilities.
2024-12-27 19:00:33 +01:00
066b7a098b
feat: Enhances future post handling and default metadata
Improves handling of future posts by checking date type before parsing.
Adds default metadata for blog posts, including license and author
details, ensuring consistency and compliance with CC BY-SA 4.0.
2024-11-27 16:18:16 +01:00
f2bfd92aaa
feat: Add scheduled workflows and handle future posts in dev
Some checks failed
Build and Deploy Static Site / build (push) Failing after 2m5s
Adds cron schedules to trigger build workflows hourly for
development and main branches for better automation.

Updates blog generation to skip future-dated posts unless in
development mode, enhancing content management.
2024-11-27 12:35:03 +01:00
62e71cadd0
fix: Repositions thumbnail generation logic
All checks were successful
Build and Deploy Static Site / build (push) Successful in 2m0s
Moves thumbnail generation code block for clarity and reusability.
Ensures thumbnails are created before copying assets, adhering
to logical order of operations.
2024-11-27 10:18:57 +01:00
32ddb8df24
feat: Enhances blog with thumbnails and excerpts
Some checks failed
Build and Deploy Static Site / build (push) Failing after 1m54s
Adds image thumbnails and automatically extracts an excerpt
from each blog post to improve visual engagement and content
overview. Modifies HTML templates to display thumbnails next to
post titles and includes "read more" links. Adjusts pagination
links for consistent relative paths and corrects the directory
structure for the first blog page. Updates dependencies to include
Pillow for image processing.

Relates to blog UI improvements.
2024-11-27 09:58:08 +01:00
c4f333e2a5
feat: Add blog generation functionality
All checks were successful
Build and Deploy Static Site / build (push) Successful in 2m20s
Introduces a static blog generation feature leveraging markdown
for content files and template rendering for HTML output.

Imports new dependencies for YAML parsing and markdown conversion.
Enhances site structure by copy-assets function to ensure non-markdown
contents like images are maintained.

Modifies templates for relative asset path resolution to allow
correct linking of stylesheets and images.

Helps in managing content workflow by auto-generating paginated
lists and individual post pages, improving content accessibility.
2024-11-27 09:37:39 +01:00
250daddcc6
feat: add 'membership-rallly' template and enhance matching
All checks were successful
Build and Deploy Static Site (Pride Theme) / build (push) Successful in 55s
Build and Deploy Static Site / build (push) Successful in 56s
Expanded the template matching condition to support templates starting with "membership". Added a new 'membership-rallly' template that extends the base 'membership' template, providing information about the Rallly Pro benefit for logged-in users and encouraging community support through donations.

This change improves the flexibility of template handling and introduces a specialized membership page aimed at enhancing user experience and engagement.
2024-09-24 14:43:17 +02:00
92238bcfa2
feat: add theme support and refactor assets
All checks were successful
Build and Deploy Static Site / build (push) Successful in 57s
Introduce support for themes by adding a `theme` parameter to the site generation process and as an argument to the main script. Created separate CSS files for different themes and adjusted the structure to accommodate the style changes. Also, updated the use of assets with new SVG images and logos.

Refactored HTML templates to dynamically select the theme and updated path references to images accordingly. Improved the development experience by adding a default "plain" theme and enhancing command-line argument parsing for theme selection.

Closes #7
2024-09-24 08:02:05 +02:00
9e8b54083a
feat: add dynamic timestamp to CSS cache-busting
All checks were successful
Build and Deploy Static Site / build (push) Successful in 1m2s
Included a timestamp in the static site generation to dynamically append to the CSS file version parameter. This ensures that users always get the latest CSS changes, reducing cache-related issues.
2024-08-04 16:24:17 +02:00
af29b0f3f5
feat: add onion location meta tag for Tor accessibility
All checks were successful
Build and Deploy Static Site / build (push) Successful in 57s
Included a `meta` tag in the base HTML template to provide the onion location for improved access through the Tor network. Enhanced context parameters to support this feature by adding the path generation logic. Updated argument parsing for better readability and consistency.

This change aims to enhance the privacy and accessibility of the site for users connecting via Tor.
2024-07-24 21:29:58 +02:00
440ef9828a
feat: add bridge data and display page for Matrix bots
All checks were successful
Build and Deploy Static Site / build (push) Successful in 58s
Integrated a new "bridges.json" file to list various Matrix bot bridges, including Telegram, WhatsApp, Discord, and more. Updated the main script to load this data and render it on a new "bridges" template. The new "bridges.html" template provides users with a clear and intuitive interface to view available bridges and their respective Matrix IDs.

Improves user experience by providing a dedicated page for bridge information.
2024-07-19 09:49:32 +02:00
a684c8b9df
feat: add built-in HTTP server to preview static site
Some checks failed
Build and Deploy Static Site / build (push) Has been cancelled
Introduced a new option `--serve` in `main.py` to provide an HTTP server for previewing the static site. Updated README with usage instructions. This enhancement allows users to quickly view the site on localhost without manually opening the `index.html` file.

Addresses usability improvements for local development.
2024-07-10 09:37:55 +02:00
ee2d53a36d
feat: extend asset copying to include data directory
All checks were successful
Build and Deploy Static Site / build (push) Successful in 58s
Expanded the asset copying functionality to also handle the 'data' directory in addition to the 'assets' folder. This ensures that both static assets and data files are included in the output directory, streamlining the build process and ensuring all necessary resources are available in the generated static site.
2024-07-01 12:12:39 +02:00
5cdb9ad43b
feat: add filter to convert month number to name
All checks were successful
Build and Deploy Static Site / build (push) Successful in 57s
Added a custom filter `month_name` to convert month numbers to their full names in templates. Updated the Transparency Report title to use this filter, enhancing readability and user experience. This change ensures that month names are displayed instead of numeric values, making the report titles clearer and more user-friendly.
2024-07-01 12:06:30 +02:00
feb273a8b0
Merge branch 'main' into dev
All checks were successful
Build and Deploy Static Site / build (push) Successful in 57s
2024-07-01 11:11:25 +02:00
7e89a67951
fix: include additional transparency data
Modified generate_transparency_table to include more detailed
transparency data by passing an additional boolean argument.
This change helps ensure all relevant data is captured and handled
properly, improving financial data accuracy and reporting.
2024-07-01 11:11:04 +02:00
d337e8a207
feat(ci): automate build and deploy for dev and main branches
Some checks failed
Build and Deploy Static Site / build (push) Failing after 59s
- Added a new GitHub Actions workflow for the development branch to build and deploy the static site.
- Modified the existing workflow to trigger on the main branch instead of the static branch.
- Refactored the main.py script for consistency in string quotation.

The new workflow simplifies deployment processes during development, ensuring seamless and automated integration and testing.
2024-07-01 10:24:24 +02:00
61de9ec81b
feat: convert Flask app to static site generator
Refactored the Flask application to generate a static site instead of running as a dynamic web app. Added a CI workflow to build and deploy the static site on pushes to the 'static' branch.

- Replaced Flask route handling with a function that generates HTML files using Jinja2 templates.
- Modified the argparse logic to trigger the static site generation.
- Updated the .gitignore file to exclude the build directory.
- Created a Forgejo Actions workflow to automate the build and deploy process.

This change improves performance and reduces server overhead by serving pre-rendered static content.
2024-07-01 09:56:04 +02:00
f9fa18a8c1
fix: update metrics endpoint URL
Changed the metrics route from "/_metrics/" to "/metrics/" for consistency and better readability. This should enhance usability and clarity for users accessing the metrics endpoint.
2024-07-01 07:10:13 +02:00
1e2d1e4119
feat: add support for current balances in metrics
Extended `get_transparency_data` function to allow current balances by adding an `allow_current` parameter. This change facilitates the inclusion of up-to-date balance information in the metrics output, enhancing the accuracy of financial reporting.
2024-07-01 07:06:19 +02:00
1acc142dba
feat: add production debug config and enhance data handling
Introduced a new debug configuration for production mode in VSCode, facilitating easier debugging in different environments. Additionally, updated the `get_transparency_data` function to handle year and month as strings, ensuring compatibility with subsequent operations. Added a necessary parameter to a function call in `main.py` to align with the updated function signature.
2024-07-01 07:04:47 +02:00
a37e8ec5c3
feat: add option to exclude current month data
Enhanced `get_transparency_data` to support an `allow_current` flag, preventing the inclusion of data from the current month. This ensures historical data analysis remains consistent when current month data might be incomplete. Updated calls to the function to pass appropriate parameters.
2024-07-01 06:57:16 +02:00
2357427d96
feat: add metrics endpoint and improve month handling
Added a new /_metrics/ endpoint to expose financial data in Prometheus format, facilitating better monitoring and analytics.

Enhanced the get_latest_month function to optionally exclude the current month, preventing potential issues in incomplete data scenarios, with this behavior being toggled by the application's development mode status.
2024-06-30 19:15:45 +02:00
1a10e8968b
feat: Enhance financial transparency
Introduced detailed financial reporting on a per-category basis, including notes for specific expenses and administrative costs in the data model. Enhanced the financial transparency feature by integrating a monthly financial report generator in the backend, enabling dynamic generation and display of detailed financial reports on the website. This commit also includes a new transparency report page, enriching user engagement with detailed insights into financial allocations and expenditures.

- Refactored finance-related data structures to include notes about specific financial activities.
- Extended the financial reporting capabilities to generate and display detailed notes and categorizations of expenses and incomes, improving transparency.
- Updated the UI to display these detailed reports, ensuring that users have access to comprehensive financial information.

This change aligns with our commitment to transparency and accountability by providing clear, detailed financial information to our members and donors.
2024-06-03 16:12:21 +02:00
45e6b36260
feat: enhance icon loading robustness
Improved the `icon` function to handle attribute errors gracefully by falling back to an alternative reading method. This change addresses potential situations where the `file.response.file` attribute does not exist, ensuring icons are consistently loaded without causing runtime errors. The fallback method, `file.response.read()`, provides a reliable alternative for retrieving SVG files, thus enhancing the application's resilience and user experience.
2024-05-29 19:02:19 +02:00
e77fc521bf
feat: introduce dynamic SVG icon functionality
Implemented a new template filter in Flask to dynamically render SVG icons, allowing for cleaner HTML templates and easier icon management. Added `coffee` and `envelope` SVG icons to the project's asset directory. This change not only streamlines the incorporation of new icons but also enhances the maintainability of the codebase by centralizing icon resources and reducing HTML clutter. Modified existing HTML templates to use this new dynamic icon rendering method, replacing hard-coded SVG and img tag icon implementations with the newly created template filter.

This update significantly improves the way icons are handled throughout the application, providing a more scalable and efficient approach to managing and displaying graphical elements.
2024-05-29 18:57:32 +02:00
2a174aa342
feat: Enhance data structure and transparency features
- Moved `finances.json` and `services.json` to a new `data` directory for better organization.
- Introduced `get_latest_month` function in `helpers/finances.py` to dynamically determine the latest financial reporting period.
- Updated `main.py` to use the new data paths and implement dynamic generation of the transparency report date, improving the clarity of financial reports.
- Modified `membership.html` template to display financial report for the dynamically determined latest month, enhancing transparency for donations.

These changes aim to improve data management, make financial reporting more transparent, and ensure users have access to the most current financial information. Moving JSON files to a dedicated directory helps with organizing resources better. By dynamically determining the latest financial period, the application now avoids hard-coded dates, increasing accuracy and reducing maintenance effort.
2024-05-29 15:04:57 +02:00
6033a47b6a
feat: enhance financial transparency with dynamic tables
Implemented dynamic financial transparency tables to automatically generate and display monthly financial data for memberships, including incomes, expenses, and balances across multiple currencies. This change involved adding a new `finances.py` helper to process financial data and integrate it with the existing Flask application. Additionally, adjusted the CSS for better alignment and readability of currency columns in the transparency tables.

- Introduced a `generate_transparency_table` function to generate HTML tables dynamically based on the latest financial data.
- Expanded the `main.py` Flask route for the membership page to include financial data rendering, ensuring up-to-date information is presented to users.
- Removed static HTML table from the membership template in favor of dynamically generated content, offering real-time insight into finances.
- Adjusted the width and text alignment of currency columns in `base.css` for enhanced table aesthetics and readability.

This update significantly improves the transparency of financial information, making it easier for members to understand the flow of funds within the organization.
2024-05-29 14:50:52 +02:00
0601a39829
feat: add dev mode warning and styling
Introduced a development mode toggle for the app, which, when enabled, displays a distinctive warning on every page to inform users they are viewing a development version of the site. This warning is styled for clear visibility. Development mode is toggled with a new `--dev` command line argument or by setting an environment variable. The change aims to prevent confusion between the development and production environments for both developers and early users.

- Added new CSS rules for a warning alert style in `base.css`.
- Modified `main.py` to check for a development mode flag and pass a warning message to the template if the flag is set.
- Updated `base.html` to include the warning message when present.
- Added a new template for the development warning message.
2024-05-27 17:37:30 +02:00
a6157c1f1e
feat: add CLI for server config
Introduced argument parsing to provide command-line options for configuring the server port and enabling debug mode, enhancing flexibility for local development or deployment needs. The changes include adjusting string quotes for consistency and minor formatting improvements.

This addition allows users to start the web server with custom configurations without modifying the source code directly, making it more convenient to run in different environments or debug as needed.
2024-04-17 10:45:28 +02:00
193546fcde
Implement dynamic service rendering with Flask
Refactored the website to serve dynamic content using Flask, replacing static HTML pages. This allows for the centralized management of service data through a JSON file. Optimizations include:

- Added a .gitignore file to exclude Python and Flask-specific temporary files.
- Migrated static assets into an organized directory structure to facilitate Flask's static file serving.
- Removed redundant HTML files and created Flask template versions with dynamic content rendering.
- Introduced Caddy server configuration for the new Flask architecture, including headers for security and CORS policy, and reverse proxy settings for route handling.

With these changes, website maintenance and updates are simplified, allowing for service information to be updated in a single location (`services.json`), which then propagates to the user-facing pages automatically.
2023-12-31 13:59:13 +01:00