Skip to content
This repository has been archived by the owner on May 9, 2022. It is now read-only.

Commit

Permalink
Change text in button in the middle of commit
Browse files Browse the repository at this point in the history
  • Loading branch information
fferegrino committed Jul 22, 2018
1 parent 90edefc commit b2574c2
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions jupygit/static/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ define([
data: data,
success: function(d) {
alert("Now you can go ahead and commit your notebook! do not forget to press the button again when you are done")
$("#jupygit-button span").text("Keep working");
}
});
});
Expand All @@ -55,6 +56,7 @@ define([
Jupyter.notebook.rename(Jupyter.original_name).then(function (){
Jupyter.original_name = "";
alert("You can now keep working");
$("#jupygit-button span").text("Prepare notebook");
});
}
});
Expand All @@ -79,10 +81,12 @@ define([
$([Jupyter.events]).on("app_initialized.NotebookApp", place_button);
return;
}

Jupyter.toolbar.add_buttons_group([{
label: 'Prepare 4',
id: 'jupygit-button',
label: 'Prepare notebook',
icon: 'fa-git',
help: 'Hola',
help: 'Clean and prepare your notebook to be commited to Git',
callback: make_request
}])
}
Expand Down

0 comments on commit b2574c2

Please sign in to comment.