From 70c9e3db0b1cf81076230bb505e72aed53eee395 Mon Sep 17 00:00:00 2001 From: Joshua Zeltser Date: Tue, 25 Jun 2019 14:15:30 +0100 Subject: [PATCH] made the numbering of certain menus dymanic --- notebook/static/tree/js/newnotebook.js | 3 ++- notebook/templates/tree.html | 30 +++++++++++++------------- 2 files changed, 17 insertions(+), 16 deletions(-) diff --git a/notebook/static/tree/js/newnotebook.js b/notebook/static/tree/js/newnotebook.js index c8cf0b927..f20c02d77 100644 --- a/notebook/static/tree/js/newnotebook.js +++ b/notebook/static/tree/js/newnotebook.js @@ -63,7 +63,8 @@ define([ .attr("id", "kernel-" +ks.name) .data('kernelspec', ks).append( $('') - .attr("aria-label","list item "+(i+1)+" "+ks.name) + .attr("aria-label", ks.name) + .attr("role", "menuitem") .attr('href', '#') .click($.proxy(this.new_notebook, this, ks.name)) .text(ks.spec.display_name) diff --git a/notebook/templates/tree.html b/notebook/templates/tree.html index d59e3e27e..0a8001643 100644 --- a/notebook/templates/tree.html +++ b/notebook/templates/tree.html @@ -66,23 +66,23 @@ data-server-root="{{server_root}}" {% trans %}New{% endtrans %} -