upload.unturf.com/templates/home.html.j2

133 lines
5.9 KiB
Django/Jinja

<!-- home.html.j2 -->
{% extends 'base.html.j2' %}
{% block title %}Home{% endblock %}
{% block content %}
<h1>Welcome to PyraFiles</h1>
<p>
{% if request.user and request.user.is_verified %}
Hello, {{ request.user.username }}!
{% else %}
Welcome, Guest!
{% endif %}
</p>
<section>
<h2>🚀 What is PyraFiles?</h2>
<p>PyraFiles is a powerful, multi-tenant file sharing and management platform designed for teams, organizations, and automated systems. Built with security and flexibility in mind, it provides a comprehensive solution for managing digital assets across different environments.</p>
</section>
{% if request.user and request.user.is_verified %}
<section>
<h2>Your Namespaces</h2>
{% if user_namespaces %}
<ul>
{% for ns in user_namespaces %}
<li>
<a href="{{ request.route_url('list_media', namespace_short_id=ns.short_id) }}">{{ ns.name }}</a> ({{ ns.role }})
{% if ns.role == "owner" %}
| <a href="{{ request.route_url('manage_namespace', namespace_short_id=ns.short_id) }}">Manage</a>
{% endif %}
</li>
{% endfor %}
</ul>
{% else %}
<p>You are not a member of any namespaces. <a href="{{ request.route_url('create_namespace') }}">Create your first namespace</a> to get started!</p>
{% endif %}
</section>
{% endif %}
<section>
<h2>Public Namespaces</h2>
{% if public_namespaces %}
<ul>
{% for ns in public_namespaces %}
<li>
<a href="{{ request.route_url('list_media', namespace_short_id=ns.short_id) }}">{{ ns.name }}</a>
</li>
{% endfor %}
</ul>
{% else %}
<p>No public namespaces available.</p>
{% endif %}
</section>
{% if not request.user or not request.user.is_verified %}
<section>
<h2>Get Started</h2>
<p><a href="{{ request.route_url('login') }}">Login or create an account</a> to start managing your files with PyraFiles!</p>
</section>
{% endif %}
<section>
<h2>✨ Key Features</h2>
<h3>🔐 Advanced Authentication & Authorization</h3>
<ul>
<li><strong>Email-based authentication</strong> with secure 6-digit verification codes</li>
<li><strong>Dual access modes:</strong> Human users via web interface and automated agents via JWT tokens</li>
<li><strong>Role-based permissions:</strong> Owner, Editor, and Reader roles with granular access control</li>
<li><strong>Namespace isolation:</strong> Complete separation of data between different organizations</li>
</ul>
<h3>📁 Flexible File Management</h3>
<ul>
<li><strong>Multi-format support:</strong> Images, audio, video, documents, and text files up to 310MB</li>
<li><strong>Three visibility modes:</strong>
<ul>
<li><em>Public:</em> Visible in listings and accessible to all</li>
<li><em>Private:</em> Only accessible to namespace members</li>
<li><em>Unlisted:</em> Accessible via direct link but hidden from listings</li>
</ul>
</li>
<li><strong>Built-in text editor:</strong> Edit ASCII files (JSON, TXT, YAML, etc.) directly in the browser</li>
<li><strong>File previews:</strong> View first 100 lines of text files inline</li>
</ul>
<h3>⏰ Scheduled Actions</h3>
<ul>
<li><strong>Automated visibility changes:</strong> Schedule files to become public, private, or unlisted</li>
<li><strong>Automated deletion:</strong> Set expiration dates for temporary files</li>
<li><strong>Background processing:</strong> Reliable scheduler ensures actions execute on time</li>
<li><strong>Audit trail:</strong> Track all scheduled actions and their status</li>
</ul>
<h3>🤖 Agent & API Support</h3>
<ul>
<li><strong>JWT authentication:</strong> Secure token-based access for automated systems</li>
<li><strong>Agent management:</strong> Create, revoke, and manage API access per namespace</li>
<li><strong>RESTful API:</strong> Full programmatic access to all file operations</li>
<li><strong>CORS support:</strong> Cross-origin requests enabled for web applications</li>
</ul>
<h3>👥 Team Collaboration</h3>
<ul>
<li><strong>User invitations:</strong> Invite team members via email with specific roles</li>
<li><strong>Namespace sharing:</strong> Control who can view, edit, or manage your files</li>
<li><strong>Public namespaces:</strong> Share collections openly while maintaining private spaces</li>
<li><strong>Gravatar integration:</strong> Personalized user profiles</li>
</ul>
<h3>🛡️ Security & Reliability</h3>
<ul>
<li><strong>Secure file storage:</strong> Base64 encoding with SQLite backend</li>
<li><strong>CSRF protection:</strong> Built-in protection against cross-site request forgery</li>
<li><strong>Session management:</strong> Secure, long-lived sessions with proper timeouts</li>
<li><strong>Input validation:</strong> Comprehensive validation of all user inputs</li>
<li><strong>Error handling:</strong> Graceful error handling with user-friendly messages</li>
</ul>
</section>
<section>
<h2>🎯 Perfect For</h2>
<ul>
<li><strong>Development Teams:</strong> Share code snippets, documentation, and assets</li>
<li><strong>Content Creators:</strong> Manage media files with scheduled publishing</li>
<li><strong>Automated Systems:</strong> Integrate file storage into your applications via API</li>
<li><strong>Organizations:</strong> Secure file sharing with proper access controls</li>
<li><strong>Temporary Sharing:</strong> Share files with automatic expiration</li>
</ul>
</section>
{% endblock %}