pyfedi/app/templates/community/add_post.html

25 lines
1.8 KiB
HTML
Raw Normal View History

{% extends "post/post_edit.html" %}
{% block title %}<h1>{{ _('Create post') }}</h1>{% endblock %}
{% block post_type %}
<div class="form-group">
<label class="form-control-label" for="type_of_post">
{{ _('Type of post') }}
</label>
<div id="type_of_post" class="btn-group flex-wrap" role="navigation">
2024-07-09 08:31:33 +02:00
<a href="{{ url_for('community.add_post', actor=actor, type='discussion') }}" class="btn {{ 'btn-primary' if request.path.endswith('submit/discussion') or request.path.endswith('submit') else 'btn-outline-secondary' }}" aria-label="{{ _('Start a discussion') }}">{{ _('Discussion') }}</a>
<a href="{{ url_for('community.add_post', actor=actor, type='link') }}" class="btn {{ 'btn-primary' if request.path.endswith('submit/link') else 'btn-outline-secondary' }}" aria-label="{{ _('Share a link') }}">{{ _('Link') }}</a>
<a href="{{ url_for('community.add_post', actor=actor, type='image') }}" class="btn {{ 'btn-primary' if request.path.endswith('submit/image') else 'btn-outline-secondary' }}" aria-label="{{ _('Share an image') }}">{{ _('Image') }}</a>
<a href="{{ url_for('community.add_post', actor=actor, type='video') }}" class="btn {{ 'btn-primary' if request.path.endswith('submit/video') else 'btn-outline-secondary' }}" aria-label="{{ _('Share a video') }}">{{ _('Video') }}</a>
<a href="{{ url_for('community.add_post', actor=actor, type='poll') }}" class="btn {{ 'btn-primary' if request.path.endswith('submit/poll') else 'btn-outline-secondary' }}" aria-label="{{ _('Create a poll') }}">{{ _('Poll') }}</a>
<!--
<a href="#" class="btn" aria-label="{{ _('Create an event') }}">{{ _('Event') }}</a> -->
</div>
</div>
{{ render_field(form.communities) }}
2024-07-08 13:21:02 +02:00
{% endblock %}