File tree Expand file tree Collapse file tree 4 files changed +18
-4
lines changed Expand file tree Collapse file tree 4 files changed +18
-4
lines changed Original file line number Diff line number Diff line change 22 * Add support for :linenos: to code tabs (#22)
33 * Improve fallback for non-HTML builders (#19)
44 * Add spelling builder to list of builders (#20)
5+ * Fix naming a tab as a number (#24)
56
67v1.1.7
78 * Fix css files not being removed when tabs are not used on a page
Original file line number Diff line number Diff line change @@ -90,10 +90,13 @@ def run(self):
9090 env = self .state .document .settings .env
9191
9292 args = self .content [0 ].strip ()
93- try :
94- args = json .loads (args )
95- self .content .trim_start (1 )
96- except ValueError :
93+ if args .startswith ('{' ):
94+ try :
95+ args = json .loads (args )
96+ self .content .trim_start (1 )
97+ except ValueError :
98+ args = {}
99+ else :
97100 args = {}
98101
99102 tab_name = nodes .container ()
Original file line number Diff line number Diff line change 1212 < div class ="docutils container ">
1313Oranges</ div >
1414 </ div >
15+ < div class ="item sphinx-data-tab-3 docutils container ">
16+ < div class ="docutils container ">
17+ 404</ div >
18+ </ div >
1519 </ div >
1620 < div class ="ui bottom attached sphinx-tab tab segment sphinx-data-tab-0 active docutils container ">
1721Apples are green, or sometimes red.</ div >
1822 < div class ="ui bottom attached sphinx-tab tab segment sphinx-data-tab-1 docutils container ">
1923Pears are green.</ div >
2024 < div class ="ui bottom attached sphinx-tab tab segment sphinx-data-tab-2 docutils container ">
2125Oranges are orange.</ div >
26+ < div class ="ui bottom attached sphinx-tab tab segment sphinx-data-tab-3 docutils container ">
27+ A number in the name.</ div >
2228</ div >
Original file line number Diff line number Diff line change 1111 .. tab :: Oranges
1212
1313 Oranges are orange.
14+
15+ .. tab :: 404
16+
17+ A number in the name.
You can’t perform that action at this time.
0 commit comments