#10034 closed bug (notabug)
Tabs destroy normal lists
Reported by: | Robotic-Brain | Owned by: | Robotic-Brain |
---|---|---|---|
Priority: | minor | Milestone: | none |
Component: | ui.tabs | Version: | 1.10.4 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
While developing for Typo3 I noticed that any list with <ul> inside a "tabbed div" is converted to tabs even though it shouldn't. The documentation states http://api.jqueryui.com/tabs/:
The tabs themselves must be in either an ordered (<ol>) or unordered (<ul>) list Each tab "title" must be inside of a list item (<li>) and wrapped by an anchor (<a>) with an href attribute
however this gets converted to tabs when calling $("#someCustomTabs").tabs();:
<div id="someCustomTabs"> <ul> <li>Test1</li> <li>Test2</li> <li>Test3</li> </ul> </div>
even multiple levels below as seen in the Typo3 backend.
Change History (4)
comment:1 Changed 9 years ago by
Owner: | set to Robotic-Brain |
---|---|
Status: | new → pending |
comment:2 Changed 9 years ago by
Status: | pending → new |
---|
The scenario i encountered this in was in an update script for a typo3 extension I'm not sure why they call .tabs() there but it affects my code (several levels down the hierarchy) in an unpleasant way (maybe i should file a bug there too)
however it does not matter in this case: if there is no anchor with a href it should be ignored since a tab without content makes no sense
consider this example: http://jsbin.com/keloliyu/1/edit?html,output
of course you could call this poor design but i have no control over that :(
comment:3 Changed 9 years ago by
Resolution: | → notabug |
---|---|
Status: | new → closed |
This is working as intended, tabs always use the first descendant list by default. I don't think we want to complicate the search for the list, especially since it's customizable though the _getList() extension point and very few people run into this problem.
comment:4 Changed 9 years ago by
Then it really is a Typo3 bug...
For reference: http://forge.typo3.org/issues/58697
I'm not sure why you would do that. Can you provide a scenario where it's sane to call
.tabs()
and not expect tabs to be created? If so, please provide a reduced test case in jsFiddle or jsbin.