Commit graph

66 commits

Author SHA1 Message Date
ee6cc2de6d
feat(sitemap): redesign UI for improved navigation
The sitemap page has undergone a significant redesign for enhanced user navigation. The update introduces a card-based layout with updated CSS for better visuals and user interaction, focusing on accessibility and aesthetics. The redesigned sitemap now features a containerized layout with cards, improving the overall page structure and readability. Each group within the sitemap is now displayed as a card, making individual sections more distinguishable and easier to navigate. This change aims to provide a more engaging user experience by making information easier to find and the page more pleasant to interact with.
2024-05-23 17:23:04 +02:00
d10381c687
feat: Update Matrix link and add issue-reporting guide
Updated the Matrix room link to ensure users are directed to the correct communication channel. Additionally introduced a new section on opening issues to guide users in reporting problems or providing feedback through the appropriate repositories and discussion forums. This enhancement aims to improve community engagement and streamline the feedback process.
2024-05-23 17:15:13 +02:00
de11b2843d
feat: bump version to 0.2.1, update .gitignore
Incremented the project version to 0.2.1, preparing for a new release with minor improvements and bug fixes. Additionally, refined the .gitignore file to explicitly include the distribution directory, ensuring build artifacts are not accidentally committed to version control. This step aligns with best practices for Python project maintenance and distribution.
2024-05-23 09:05:26 +02:00
0b4676b720
refactor: streamline README and enhance project visibility
Updated the project documentation and .gitignore for a cleaner structure and enhanced visibility. The README now integrates dynamic badges for real-time status like support links, PyPI version, and latest commit info, offering a quick overview of the project status at a glance. These changes aim to make the project more accessible to potential contributors and users by providing essential information more efficiently. Additionally, the `.gitignore` file has been updated to include the `dist/` directory, preventing the accidental inclusion of distribution files in the repository, thus maintaining a cleaner project structure.

The restructuring of the README content, including a simplified approach to setting up development and production environments, aligns with best practices, making it easier for new contributors to get started. Furthermore, the changes enhance project documentation coherence and readability by embedding relevant badges and updating linkage paths for better navigation.
2024-05-23 08:27:21 +02:00
85d5c88294
feat: Introduce pyproject.toml for build configuration
Migrated project dependencies and metadata into a newly added `pyproject.toml`, aligning with modern Python packaging practices. Removed `requirements.txt` as dependencies are now specified in the unified project configuration. Restructured the project by moving Python code, static assets, and templates into a `src/structables` directory to encapsulate project components better and facilitate packaging. Moreover, refactor `main.py` to read environment variables earlier, streamline argument parsing, and ensure configurations are correctly applied before the Flask app initialization. This reorganization supports better project scalability, simplifies the build process, and enhances maintainability by consolidating project configurations and dependencies.

Note: The usage of `pyproject.toml` requires tools that support PEP 518 and might necessitate updates to CI/CD pipelines or developer workflows.
2024-05-23 08:06:36 +02:00
25a07d797b
feat(article layout): Improve readability and multimedia integration
Revamped the article template to enhance visual appeal and user engagement. Introduced a modern, centered layout for article headers, enriched steps display, and standardized multimedia elements with rounded corners and shadows for a cohesive look. Adjustments ensure content is more engaging and accessible, encouraging longer visitor sessions and interaction. This change aligns with the goal of providing a more immersive user experience while maintaining the site's aesthetic consistency.

Refactored CSS to support these changes, defining variables for easier future theme adjustments and promoting code reuse across similar elements. The update signifies a pivotal shift towards a refined and flexible presentation of articles, potentially increasing visitor retention and satisfaction.
2024-05-23 07:30:45 +02:00
c32144d437
refactor: improve UI consistency across templates
Updated category and projects templates to enhance readability and maintain UI consistency. Both templates now use a card layout with image headers and a relocated author, channel information, and metrics (favorites, views) to the card footer for improved layout consistency and readability. Also standardized image and anchor tag formats across both pages, removing inline styles and deprecated classes for cleaner, more maintainable code. Changes aim to provide a more uniform user experience and simplify future template adjustments.
2024-05-22 18:21:40 +02:00
9eee296c81
feat(css): enhance card design with flex layout
Introduced a flexbox layout to cards for a more adaptive and cohesive structure. This update includes styling for `.card-body` and `.card-footer`, ensuring they occupy space efficiently and maintain visual consistency across different viewport sizes. The `.card-footer` now has a distinct background and top border to clearly delineate it from the body content, enhancing readability and aesthetic appeal.

This enhancement addresses the need for more flexible layout options within cards, improving the overall user experience by ensuring content is well-organized and visually appealing across devices.
2024-05-22 18:17:37 +02:00
b0adb37ce7
feat: Overhaul UI styling and structure
Introduced a modular CSS variable system for easier theme management, enhancing the maintainability and scalability of our site's design. Reorganized the HTML structure in the index page for a more semantic layout, improving accessibility and SEO. Additionally, updated the styling of UI components, such as navigation and cards, for a more modern and cohesive look. This change not only refreshes the website's aesthetics but also improves the user experience on both desktop and mobile devices.
2024-05-22 18:10:32 +02:00
d20f1d2e1b
refactor(footer): improve HTML structure and accessibility
Optimized the footer HTML markup for better readability and web accessibility. Changes include the use of more semantic HTML, such as replacing `<center>` tags with CSS for centering content, and ensuring proper use of self-closing `<hr />` tags. This update aims to enhance maintainability and ensure a more inclusive user experience by adhering to modern web standards.
2024-05-22 18:02:20 +02:00
0f9f8b21a4
refactor(header): streamline navigation and improve form aesthetics
Redesigned the header's navigation layout and search form to enhance user interface consistency and accessibility. Migrated the logo loading to utilize Flask's url_for, ensuring dynamic path resolution which is more maintainable and compatible across different deployment environments. Simplified the navbar structure by consolidating elements under a single navbar-collapse class, aligning with Bootstrap's best practices for responsive design. Upgraded the search button to be more visually appealing and accessible by replacing visibility styles with an outline class, promoting a clearer call-to-action for users to engage with the search functionality.
2024-05-22 18:01:09 +02:00
6324579b36
refactor: improve HTML formatting in base template
Adjusted the formatting in the base.html template for better readability and consistency. This includes changes to indentation, the self-closing of meta tags, and the simplification of the main block. These adjustments make the code cleaner and more in line with modern HTML practices, potentially easing future maintenance and readability.
2024-05-22 18:00:33 +02:00
83ed63b13f
feat: enhance accessibility and SEO on the base template
Improved the base template by setting the default language to English, enhancing SEO through better ordering of meta and title tags, and including an initial-scale for the viewport meta tag. Wrapped the main content area with a `<main>` tag to improve semantic HTML structure and accessibility. These changes make the site more accessible and potentially improve search engine rankings.
2024-05-22 17:57:14 +02:00
eb85c1c7fa
refactor: streamline imports and improve null checks
This commit makes several refinements across the main.py file for better readability and performance:
- Simplified the import statements by removing unused imports, such as `ConfigParser` and `stream_with_context`, and consolidating uses of `urllib.parse`.
- Enhanced code clarity by replacing `!= None` checks with the more Pythonic `is not None` for better readability and to adhere to PEP 8 recommendations.
- Omitted redundant variable assignments in functions where the variables were declared but not meaningfully used, focusing the logic and reducing memory usage slightly.
- Corrected a logical error in an if condition by ensuring a proper membership test with `"embedType" not in "file"` making the code not only more readable but also preventing potential bugs.

Together, these changes make the codebase leaner, more maintainable, and compliant with best practices.
2024-05-22 17:56:46 +02:00
455218f7b6
feat: stream proxy content dynamically
Refactored the proxy route to stream data dynamically from URLs starting
with specific domains, rather than loading it all at once. This change
introduces a subfunction within the proxy route handler to manage
streaming, which iterates through data chunks and yields them until
completion. The new approach aims to enhance performance and resource
utilization by avoiding the download of the entire content before
sending it to the client. Additionally, error handling has been
tightened, specifically for HTTP errors and missing 'content-type'
headers, improving the robustness and reliability of the proxy feature.
2024-03-29 08:17:56 +01:00
b517139b00
feat(main): track total project count in project
listing

Introduce a new variable to hold the total number of projects when
accessing the projects listing route. This addition enables improved
tracking and potential features that require knowing the total number of
projects upfront, such as pagination controls or statistics display.
This change only affects the `project_list` function when the path
matches the projects endpoint.

By having the total number of projects readily available, future
enhancements or adjustments to the UI/UX involving the display of
project quantities can be more easily implemented, offering a better
user experience.
2024-03-28 16:25:33 +01:00
a8c4ef5827
feat: support POST for search queries
Enhanced the search functionality to support POST requests, ensuring
more versatile and secure handling of search queries. This change
involves accepting search queries through both GET and POST methods,
aligning with best practices for handling potentially sensitive user
inputs. Additionally, refactored conditionals for improved readability
and maintainability of the code. This update aims at enhancing user
experience and security, paving the way for future improvements in how
user inputs are processed and handled within the application.
2024-03-28 16:22:59 +01:00
5a6d6d403c
feat: standardize navbar logo size
Introduced a specific height for the navbar logo across the application
to ensure consistency in the navbar's visual presentation. By adjusting
the CSS to set a fixed height and applying the corresponding class to
the logo in the header, the layout becomes more predictable and
harmonious, significantly improving the user interface's appearance.
2024-03-28 14:12:20 +01:00
5e99720328
Fix image embed check in file processing
Corrected the logic for identifying image files without an embedded type
by fixing the misplaced quotation marks in the conditional. This change
ensures that the correct files are appended with proxy URLs for step
images. Additionally, removed unnecessary whitespace for cleaner code
structure.
2024-02-16 18:31:38 +01:00
dfe7882b12
Consolidated matrix rooms and source links
Removed several Matrix chat room links from the README and streamlined
the list of instances to enhance readability and maintain a focus on
primary resources. Updated footer source code references to point to a
singular, official repository for increased clarity and to reflect the
project's centralization efforts. This change should make the
documentation less cluttered and more user-friendly for new
contributors.
2024-02-15 16:27:34 +01:00
bcdbf5ec69
Enhanced search integration
Refactored the project search function to dynamically construct query parameters, improving readability and maintainability. Introduced several new parameters to refine search results and included a timeout for reliability. Added logging for better debugging and transparency about the search operations.

Updated category and search routes to use the new search function capabilities, ensuring relevant results and proper exception handling. Additionally, implemented pagination support for better user experience when browsing projects.

To improve the UI, the category and project listing templates have been refreshed with a modern layout, including the use of Bootstrap classes and better organization of content.

Resolves issues with inefficient search parameter construction and user interface inconsistencies.
2024-01-31 19:22:58 +01:00
c1f4e157a4
Optimized navigation layout in header
Streamlined the header's HTML structure by consolidating navigation elements and search form into more efficient class usage, improving maintainability and readability. Removed fixed height for the logo to enhance flexibility in different resolutions. These adjustments make future styling and responsiveness optimizations smoother.
2024-01-31 17:36:47 +01:00
b730e9c6db
Center align media elements in article template
Improved visual consistency in 'article.html' by adding 'justify-content-center' to each media row, ensuring images, videos, and iframes are centered within their containers. Additionally, applied 'wrap' class to text content for enhanced readability. These changes cater to better user engagement and a more polished layout presentation.
2024-01-31 17:09:52 +01:00
9dd8f4e2e0
Enhanced environment configuration and content fetching
Extended environment variables to allow for greater configurability and aligned debug mode detection with the new STRUCTABLES_DEBUG variable. Additionally, introduced command-line arguments for specifying Invidious instance URLs and unsafe iframe display settings.

The content fetching logic has been revised for fetching JSON data directly instead of scraping HTML, resulting in a more robust and efficient data extraction process. New templates accommodate the change and present a cleaner UI, including handling of iframes, downloads, and proper proxying of external resources.

HTML templates have been refactored to utilize better layout and styling while enhancing support for iframes and downloads, complete with the new ability to block iframe content from outside sources unless explicitly permitted. This security-focused feature protects end-users from potentially unsafe content.
2024-01-31 12:50:19 +01:00
1a4e0360a2
Update Matrix room link in README
Corrected the Matrix room URL in the README documentation to point to the new `#structables:private.coffee` room. This ensures users can find and join the correct discussion channel.
2024-01-19 08:16:41 +01:00
9f117f5ccc
Improve text overflow handling in articles
Updated CSS to include word-wrapping rules and adjusted the article template to apply these styles to content rows, ensuring better handling of long strings without space characters and improving the readability of articles with unusual text content. No layout disruption expected.
2024-01-17 19:11:43 +01:00
6762004c50
Fix article template loop rendering issue
Corrected improper nesting within for-loop structure in the article template to ensure that step content is appropriately wrapped in a div, resolving visual inconsistencies in article step display. This change maintains structured and clean output for article content.
2024-01-17 18:46:20 +01:00
0249bccd9f
Update URL for Private.coffee's hosted instance
The README documentation has been updated to reflect the change in URL for the front-end alternative provided by Private.coffee. The updated link points to the new correct domain.
2024-01-17 18:30:24 +01:00
c8cb88e3b7
Rebrand project from Indestructables to Structables
Updated the project name and references across various files, including README, template headers, and footers to reflect the rebranding from 'Indestructables' to 'Structables'. The favicon has been removed, and the main logo updated to align with the new branding. The commit modifies links to the source code repository as part of rebranding efforts. This change creates a clear distinction from the upstream project while maintaining acknowledgments to the original sources.
2024-01-17 17:01:35 +01:00
232a1504fb
Update .gitignore and enhance project structure
- Add 'privacy.txt' to .gitignore to prevent checking it in
- Refactor data storage from arrays to dictionaries for better data handling in 'main.py'
- Include 'pathlib' import for handling filesystem paths
- Introduce new CSS and Bootstrap files providing updated styles and responsive design elements
- Modify HTML templates to use updated data structures and enhance accessibility

These changes improve code readability, maintain project consistency, and enhance the front-end presentation. This work is part of ongoing efforts to better manage project data, secure sensitive information, and provide a more robust user interface.
2024-01-17 16:43:51 +01:00
f60494af6e
Removed Selenium dependency from Indestructables
Enhanced the Indestructables fork by eliminating its reliance on Selenium and Playwright's Chromium binary. This change streamlines the setup process and potentially improves performance and stability. Additionally, a new matrix room link has been added to the README for community engagement. Related project licenses reiterated for clarity.
2024-01-16 17:18:47 +01:00
29592de90a
Refactor data fetching logic using stdlib
Removed dependencies on external libraries such as `requests`, `requests-html`, and `playwright` in favor of Python's standard libraries like `urllib` for HTTP requests and parsing functionality. A more robust and efficient data update function was introduced to scrape API keys and fetch project data using Typesense. Transitioned from a manual browser-based scraping approach to an API-based one for improved stability and performance. Added logging for better monitoring and debuggability. Error-handling now leverages `HTTPError` from `urllib.error`. Shifted the configuration of debug mode to rely on an environment variable, aligning with Twelve-Factor principles. Removed unused functions and streamlined the handling of various routes within the Flask app. This change shifts the project towards a more maintainable code base by using built-in libraries, reduces external dependencies, and improves resilience and scalability of the web scraping components.
2024-01-16 17:13:59 +01:00
d269a9992e Merge branch '3-so-there-s-another-upstream' into 'main'
License/Upstream link fixes

Closes #3

See merge request PrivateCoffee/indestructables!1
2023-07-19 06:28:04 +00:00
e09497f471
Improve error handling 2023-07-19 08:26:45 +02:00
9e6fa4501d
Add Destructables mention 2023-07-19 08:25:41 +02:00
9807d0fba5
Merge remote-tracking branch 'upstream/main'
Replace Font Awesome Pro icon with free version
2023-06-04 08:06:54 +02:00
snowcatridge10
2798786f51 update data on startup 2023-06-03 19:16:16 -04:00
snowcatridge10
ee274a7df7 Add privacy policy 2023-06-03 18:31:55 -04:00
snowcatridge10
e9b2928299 Add chromedrivermanager 2023-06-03 18:14:29 -04:00
snowcatridge10
499f0e9cbb add cronjob text file 2023-06-03 17:44:44 -04:00
snowcatridge10
3d1a1f6971 commit 2023-06-03 17:27:48 -04:00
063f4cc427
Merge remote-tracking branch 'upstream/main' 2023-06-03 23:04:34 +02:00
snowcatridge10
01622a6e9e oops 2023-06-03 12:38:20 -04:00
snowcatridge10
2fc73446b7 add instances link 2023-06-03 12:37:26 -04:00
snowcatridge10
bc18d42911 Add docker-compose 2023-06-03 11:42:49 -04:00
snowcatridge10
7ad40d8825 fix formating 2023-06-03 11:39:59 -04:00
snowcatridge10
fcecd19710 add docker 2023-06-03 11:36:06 -04:00
snowcatridge10
4fa9b1586b commit 2023-06-03 09:50:44 -04:00
75ec8b961f
Add cron endpoint to update global_ibles 2023-06-03 09:46:28 +02:00
fbb0fea2d5
Update upstream URL 2023-06-02 20:49:24 +02:00