Skip to content

Commit 84e565c

Browse files
committed
More UI changes
1 parent 9b18d07 commit 84e565c

File tree

2 files changed

+3
-12
lines changed

2 files changed

+3
-12
lines changed

notebook/static/notebook/js/notebook.js

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2848,10 +2848,6 @@ define([
28482848
};
28492849

28502850
Notebook.prototype.save_notebook_as = function() {
2851-
// If current notebook has some changes, save them, or the copied notebook won't have them.
2852-
if (this.writable && this.dirty) {
2853-
this.save_notebook();
2854-
}
28552851
var that = this;
28562852
var current_dir = $('body').attr('data-notebook-path').split('/').slice(0, -1).join("/");
28572853
current_dir = current_dir? current_dir + "/": "";
@@ -2860,14 +2856,9 @@ define([
28602856
.text(i18n.msg._('Enter a notebook path relative to notebook dir'))
28612857
).append(
28622858
$('<br/>')
2863-
).append($('<label />').attr('for', 'save-as-dialog')
2864-
.html('<i class="fa fa-home"></i>')
28652859
).append(
28662860
$('<input/>').attr('type','text').attr('size','25')
2867-
.attr('value', current_dir)
2868-
.css({'display': 'inline-block', 'margin-left': '0.5em'})
2869-
.attr('id', 'save-as-dialog')
2870-
.addClass('form-inline')
2861+
.addClass('form-control')
28712862
);
28722863

28732864
var d = dialog.modal({
@@ -2935,7 +2926,7 @@ define([
29352926
return false;
29362927
}
29372928
});
2938-
d.find('input[type="text"]').focus().select();
2929+
d.find('input[type="text"]').val(current_dir).focus();
29392930
}
29402931
});
29412932
}

notebook/templates/notebook.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@
9191
<a href="#">{% trans %}Make a Copy...{% endtrans %}</a></li>
9292
<li id="save_notebook_as"
9393
title="{% trans %}Save a copy of the notebook's contents and start a new kernel{% endtrans %}">
94-
<a href="#">{% trans %}Save as{% endtrans %}</a></li>
94+
<a href="#">{% trans %}Save as...{% endtrans %}</a></li>
9595
<li id="rename_notebook"><a href="#">{% trans %}Rename...{% endtrans %}</a></li>
9696
<li id="save_checkpoint"><a href="#">{% trans %}Save and Checkpoint{% endtrans %}</a></li>
9797
<!-- <hr/> -->

0 commit comments

Comments
 (0)