mirror of
https://git.sr.ht/~tsileo/microblog.pub
synced 2024-12-22 05:04:27 +00:00
Add support for CW, and tweak the new note form for mobile
This commit is contained in:
parent
ae809cc46d
commit
30eb21203c
2 changed files with 5 additions and 2 deletions
|
@ -432,6 +432,7 @@ def api_new_note() -> _Response:
|
|||
attributedTo=MY_PERSON.id,
|
||||
cc=list(set(cc)),
|
||||
to=list(set(to)),
|
||||
summary=_user_api_arg("summary", default=""),
|
||||
content=content,
|
||||
tag=tags,
|
||||
source={"mediaType": "text/markdown", "content": source},
|
||||
|
|
|
@ -23,13 +23,15 @@
|
|||
<form action="/api/new_{% if request.args.get("question") == "1" %}question{%else%}note{%endif%}" method="POST" enctype="multipart/form-data">
|
||||
<input type="hidden" name="redirect" value="/">
|
||||
<input type="hidden" name="csrf_token" value="{{ csrf_token() }}">
|
||||
<select name="visibility">
|
||||
<select name="visibility" style="padding:8px 10px;">
|
||||
{% for v in visibility %}
|
||||
<option value="{{v.name}}">{{ v.value }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
{% if reply %}<input type="hidden" name="reply" value="{{reply}}">{% endif %}
|
||||
|
||||
<p><input type="text" name="summary" placeholder="summary/CW (optional)"></p>
|
||||
|
||||
<p>
|
||||
{% for emoji in emojis %}
|
||||
<span class="ji">{{ emoji | emojify | safe }}</span>
|
||||
|
@ -39,7 +41,7 @@
|
|||
{% endfor %}
|
||||
</p>
|
||||
|
||||
<textarea name="content" rows="10" cols="50" autofocus="autofocus" designMode="on" style="font-size:1.2em;">{{ content }}</textarea>
|
||||
<textarea name="content" rows="10" cols="50" autofocus="autofocus" designMode="on" style="font-size:1.2em;width:95%;">{{ content }}</textarea>
|
||||
<input type="file" name="file">
|
||||
|
||||
{% if request.args.get("question") == "1" %}
|
||||
|
|
Loading…
Reference in a new issue