don't show jot bb-edit buttons if a mimetype other than text/bbcode is selected (:todo: also disable bbcode autocomplete)

This commit is contained in:
zotlabs 2018-01-29 18:43:20 -08:00
parent 668f56807a
commit 9bf83a57bd

View File

@ -110,10 +110,21 @@ var activeCommentID = 0;
var activeCommentText = '';
$(document).ready(function() {
/* enable tinymce on focus and click */
$("#profile-jot-text").focus(enableOnUser);
$("#profile-jot-text").click(enableOnUser);
$('#id_mimetype').on('load', jotSetMime);
$('#id_mimetype').on('change', jotSetMime);
function jotSetMime() {
var mtype = $('#id_mimetype').val();
if(mtype == 'text/bbcode')
$('#profile-jot-submit-left').show();
else
$('#profile-jot-submit-left').hide();
}
$('#invisible-wall-file-upload').fileupload({
url: 'wall_attach/{{$nickname}}',