text/html
•
2.98 KB
•
93 lines
<!DOCTYPE html>
<html>
<head>
<title>{{ owner.name }}/{{ project.name }}/settings</title>
</head>
<body>
{% include "sidebar.html" %}
<main>
<section>
<div class="page-header">
<h1 class="project-header">
<a href="{{ owner.uri() }}">{{ owner.name }}</a> /
<a href="{{ project.uri() }}">{{ project.name }}</a> /
<a href="{{ project.uri_settings() }}">Settings</a>
</h1>
</div>
{% include "project_tabs.html" %}
{% if let Some(msg) = message %}
<div class="message" role="status">{{ msg }}</div>
{% endif %}
<form method="post" action="{{ project.uri_settings() }}" class="stack card simple-form">
{{ csrf_token_field|safe }}
<label>
ID (used in URIs, can't be changed)
<input name="slug" type="text" value="{{ project.slug }}" readonly>
</label>
<div class="form-row">
<label>
Name
<input name="name" type="text" value="{{ project.name }}">
</label>
<label>
Website
<input name="website" type="text" value="{{ project.website }}">
</label>
</div>
<div class="form-row">
<label>
Public access
<select name="public_access">
<option value="none" {% if project.public_access==AccessType::None %}selected{% endif %}>None
</option>
<option value="read" {% if project.public_access==AccessType::Read %}selected{% endif %}>Read
</option>
<option value="write" {% if project.public_access==AccessType::Write %}selected{% endif %}>Write
</option>
</select>
</label>
<label>
Default branch name (main / master)
<input name="main_branch" type="text" value="{{ project.main_branch }}">
</label>
</div>
<label>
Description
<textarea name="description" class="markdown-editor">{{ project.description }}</textarea>
</label>
<button type="submit">Save</button>
</form>
<!-- Danger Zone -->
<div class="danger-zone card">
<h2>Danger Zone</h2>
<p>Deleting a project is permanent and cannot be undone. All repository data and commit history will be lost.</p>
<form method="post" action="/~{{ owner.slug }}/{{ project.slug }}/delete" class="delete-form">
{{ csrf_token_field|safe }}
<input type="hidden" name="confirmation" value="" />
<button
type="button"
id="project-delete-button"
class="danger-button"
data-project-path="{{ owner.slug }}/{{ project.slug }}"
>
Delete Project
</button>
</form>
</div>
</section>
</main>
</body>
</html>