Commits

Ralph Bean committed e372a44

Update to selectors to match tests.

  • Participants
  • Parent commits 8e32841

Comments (0)

Files changed (2)

File tw2/jquery/plugins/fg/templates/menu.html

 <div xmlns:py="http://genshi.edgewall.org/"
      xmlns:xi="http://www.w3.org/2001/XInclude"
-     id="${w.attrs['id']}-wrapper">
+     id="${w.attrs['id']}:wrapper">
 
 ${w.child.display()}
-<div id="${w.attrs['id']}-target" class='hidden'>
+<div id="${w.attrs['id']}:target" class='hidden'>
     <ul>
     <py:for each="entry in w.items">
         <xi:include href="recursive_menu.html" py:with="item=entry" />
 $(function() {
     $(document).ready( function () {
         var opts = ${w.options};
-        opts['content'] = $('#${w.attrs["id"]}-target').html();
-        $("#${w.attrs['id']}").${w.jqmethod}(opts);
+        opts['content'] = $('#${w.selector}\\:target').html();
+        $("#${w.selector}").${w.jqmethod}(opts);
         <py:if test="w.click">
-        $("#${w.attrs['id']}").click(${w.click});
+        $("#${w.selector}").click(${w.click});
         </py:if>
     });
 });

File tw2/jquery/plugins/fg/templates/menu.mak

 <%namespace name="tw" module="tw2.core.mako_util"/>
-<div id="${w.attrs['id']}-wrapper">
+<div id="${w.attrs['id']}:wrapper">
 ${w.child.display()}
-<div id="${w.attrs['id']}-target" class='hidden'>
+<div id="${w.attrs['id']}:target" class='hidden'>
     <ul>
 	% for entry in w.items:
 		<%include file="recursive_menu.mak" args="item=entry" />
 $(function() {
     $(document).ready( function () {
         var opts = ${w.options};
-        opts['content'] = $('#${w.attrs["id"]}-target').html();
-        $("#${w.attrs['id']}").${w.jqmethod}(opts);
+        opts['content'] = $('#${w.selector}\\:target').html();
+        $("#${w.selector}").${w.jqmethod}(opts);
 		% if w.click:
-        $("#${w.attrs['id']}").click(${w.click});
+        $("#${w.selector}").click(${w.click});
 		% endif
     });
 });