mirror of
http://gitea.phreedom.club/localhost_frssoft/pleroma-cli
synced 2024-11-21 19:41:30 +00:00
Hiden "Media" button if attachments empty
This commit is contained in:
parent
5ec56bc8a3
commit
02cff53107
|
@ -355,9 +355,11 @@ statuses_render()
|
|||
fi
|
||||
echo "$status" | jj -r content | delqse | html_to_txt_render
|
||||
attachments=$(echo "$status" | jj -l media_attachments.#.remote_url | delq)
|
||||
menuattachments=
|
||||
if [ -n "$attachments" ]; then
|
||||
echo "#EXTINF:-1, $uri" >> attachments.m3u8
|
||||
echo '[Attachments:]'
|
||||
menuattachments='\nMedia'
|
||||
echo "$attachments" | tee -a attachments.m3u8
|
||||
fi
|
||||
echo "$statuses_separator"
|
||||
|
@ -365,7 +367,7 @@ statuses_render()
|
|||
next=0
|
||||
force_stop=0
|
||||
while [ "$next" -eq 0 ]; do
|
||||
per_status_menu=$(echo 'Next\nMedia\nShare and favorite\nShare\nFavorite\nReply\nBack' | fzy)
|
||||
per_status_menu=$(echo "Next$menuattachments\nShare and favorite\nShare\nFavorite\nReply\nBack" | fzy)
|
||||
case "$per_status_menu" in
|
||||
"Next") next=1; clear ;;
|
||||
"Media")
|
||||
|
|
Loading…
Reference in a new issue