From 8bec3a79b2cf412610a65d939ca0ddd890c59c8a Mon Sep 17 00:00:00 2001 From: Matthias Bussonnier Date: Tue, 18 Aug 2015 13:27:25 +0200 Subject: [PATCH] improvement of UI UI to replace only in selected cell, use bootstrap way of doing it. Button order is now more keyboard friendly --- .../static/notebook/js/searchandreplace.js | 73 +++++++++++++------ .../notebook/less/searchandreplace.less | 19 +---- 2 files changed, 51 insertions(+), 41 deletions(-) diff --git a/notebook/static/notebook/js/searchandreplace.js b/notebook/static/notebook/js/searchandreplace.js index d63d94060..e9eb93f74 100644 --- a/notebook/static/notebook/js/searchandreplace.js +++ b/notebook/static/notebook/js/searchandreplace.js @@ -37,7 +37,7 @@ define(function(require){ if(aborted){ body.append($('

').addClass('bg-warning').text("Warning, too many matches ("+html.length+"+), some changes might not be shown or applied")); } else { - body.append($('

').addClass('bg-info').text(html.length+" matche"+(html.length==1?'':'s'))); + body.append($('

').addClass('bg-info').text(html.length+" match"+(html.length==1?'':'es'))); } for(var rindex=0; rindex") .addClass('form-control') .attr('placeholder','Search'); @@ -107,15 +107,23 @@ define(function(require){ .addClass("btn btn-default") .attr('data-toggle','button') .attr('title', 'use regular expression (now you have N+1 problems)') - .attr('value', '.*') .text('.*'); + var onlySelectedButton = $('