diff options
author | Mario Vavti <mario@mariovavti.com> | 2017-01-21 23:28:57 +0100 |
---|---|---|
committer | Mario Vavti <mario@mariovavti.com> | 2017-01-21 23:28:57 +0100 |
commit | 8794106e85f8d2486d636fd37605fb3408c73ee0 (patch) | |
tree | 487f80984b997f4ea0af05d86842b6cf276983cc /view | |
parent | 88caa14030f29c59424beb0237ea10526565b4e6 (diff) | |
download | volse-hubzilla-8794106e85f8d2486d636fd37605fb3408c73ee0.tar.gz volse-hubzilla-8794106e85f8d2486d636fd37605fb3408c73ee0.tar.bz2 volse-hubzilla-8794106e85f8d2486d636fd37605fb3408c73ee0.zip |
add observer.language to autocomplete and return a default value for observer
Diffstat (limited to 'view')
-rw-r--r-- | view/js/autocomplete.js | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/view/js/autocomplete.js b/view/js/autocomplete.js index 62fc37420..5a616b6fc 100644 --- a/view/js/autocomplete.js +++ b/view/js/autocomplete.js @@ -270,7 +270,7 @@ function string2bb(element) { $.fn.bbco_autocomplete = function(type) { if(type=='bbcode') { - var open_close_elements = ['bold', 'italic', 'underline', 'overline', 'strike', 'superscript', 'subscript', 'quote', 'code', 'open', 'spoiler', 'map', 'nobb', 'list', 'checklist', 'ul', 'ol', 'dl', 'li', 'table', 'tr', 'th', 'td', 'center', 'color', 'font', 'size', 'zrl', 'zmg', 'rpost', 'qr', 'observer', 'embed', 'highlight']; + var open_close_elements = ['bold', 'italic', 'underline', 'overline', 'strike', 'superscript', 'subscript', 'quote', 'code', 'open', 'spoiler', 'map', 'nobb', 'list', 'checklist', 'ul', 'ol', 'dl', 'li', 'table', 'tr', 'th', 'td', 'center', 'color', 'font', 'size', 'zrl', 'zmg', 'rpost', 'qr', 'observer', 'observer.language','embed', 'highlight']; var open_elements = ['observer.baseurl', 'observer.address', 'observer.photo', 'observer.name', 'observer.webname', 'observer.url', '*', 'hr', ]; var elements = open_close_elements.concat(open_elements); @@ -309,6 +309,10 @@ function string2bb(element) { return ['\[' + element + '\]' + '\n\[*=Item name\] ', '\n\[/' + element + '\]']; } else if(element === 'table') { return ['\[' + element + '\]' + '\n\[tr\]', '\[/tr\]\n\[/' + element + '\]']; + } else if(element === 'observer') { + return ['\[' + element + '=1\]', '\[/observer\]']; + } else if(element === 'observer.language') { + return ['\[' + element + '=en\]', '\[/observer\]']; } else { return ['\[' + element + '\]', '\[/' + element + '\]']; |