X-Git-Url: https://git.mdrn.pl/redakcja.git/blobdiff_plain/88e7597e91bb03364d7846b160ff0b38b97c1be6..5489720d4099540b381b9fbc0e727c2fd8e52936:/src/redakcja/static/js/wiki/view_properties.js?ds=inline diff --git a/src/redakcja/static/js/wiki/view_properties.js b/src/redakcja/static/js/wiki/view_properties.js index e6ad1ca2..5af43e67 100644 --- a/src/redakcja/static/js/wiki/view_properties.js +++ b/src/redakcja/static/js/wiki/view_properties.js @@ -57,6 +57,10 @@ self.edit($(this).data('node')); }); + $(document).on('click', '#bubbles .badge', function(e) { + self.edit($(this).data('node')); + }); + self.$pane.on('change', '.form-control', function() { let $input = $(this); @@ -97,6 +101,14 @@ }); self.$edited; }); + + self.$pane.on('click', '.current-convert', function() { + self.convert($(this).attr('data-to')); + }); + self.$pane.on('click', '#current-delete', function() { + self.delete(); + }); + oldCallback.call(this); }; @@ -111,11 +123,22 @@ let $node = $(element); $("#parents", self.$pane).empty(); + $("#bubbles").empty(); + + let b = $("
").text($node.attr('x-node')); + b.data('node', element); + $("#bubbles").append(b); + $node.parents('[x-node]').each(function() { let a = $("