mirror of
https://github.com/claudehohl/Stikked.git
synced 2025-04-25 20:41:20 -05:00
embeddable pastes - the js part
This commit is contained in:
parent
ef7724b32f
commit
d86ce778a2
@ -4,6 +4,7 @@ ST.init = function() {
|
||||
ST.change();
|
||||
ST.show();
|
||||
ST.expand();
|
||||
ST.show_embed();
|
||||
};
|
||||
|
||||
ST.change = function() {
|
||||
@ -21,6 +22,18 @@ ST.show = function() {
|
||||
});
|
||||
};
|
||||
|
||||
ST.show_embed = function() {
|
||||
$embed_field = $('#embed_field');
|
||||
$embed_field.hide();
|
||||
$embed_field.after('<a id="show_code" href="#">Show code</a>');
|
||||
$('#show_code').live('click',
|
||||
function() {
|
||||
$(this).hide();
|
||||
$embed_field.show().select();
|
||||
return false;
|
||||
});
|
||||
};
|
||||
|
||||
ST.expand = function() {
|
||||
$('.expand').click(function() {
|
||||
if ($('.paste').hasClass('full')) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user