File tree 2 files changed +28
-19
lines changed
2 files changed +28
-19
lines changed Original file line number Diff line number Diff line change @@ -34,7 +34,7 @@ Homepage = "https://github.com/executablebooks/sphinx-design"
34
34
Documentation = " https://sphinx-design.readthedocs.io"
35
35
36
36
[project .optional-dependencies ]
37
- code_style = [" pre-commit>=3,<4" ]
37
+ code-style = [" pre-commit>=3,<4" ]
38
38
rtd = [" myst-parser>=1,<3" ]
39
39
testing = [
40
40
" myst-parser>=1,<3" ,
@@ -43,10 +43,10 @@ testing = [
43
43
" pytest-regressions" ,
44
44
" defusedxml" ,
45
45
]
46
- theme_furo = [" furo~=2023.7.0" ]
47
- theme_pydata = [" pydata-sphinx-theme~=0.13.0" ]
48
- theme_rtd = [" sphinx-rtd-theme~=1.0" ]
49
- theme_sbt = [" sphinx-book-theme~=1.0" ]
46
+ theme-furo = [" furo~=2023.7.0" ]
47
+ theme-pydata = [" pydata-sphinx-theme~=0.13.0" ]
48
+ theme-rtd = [" sphinx-rtd-theme~=1.0" ]
49
+ theme-sbt = [" sphinx-book-theme~=1.0" ]
50
50
51
51
[tool .flit .sdist ]
52
52
exclude = [
Original file line number Diff line number Diff line change @@ -155,22 +155,31 @@ class AllOcticons(SphinxDirective):
155
155
def run (self ) -> list [nodes .Node ]:
156
156
"""Run the directive."""
157
157
classes = self .options .get ("class" , [])
158
- list_node = nodes .bullet_list ()
158
+ table = nodes .table ()
159
+ group = nodes .tgroup (cols = 2 )
160
+ table += group
161
+ group .extend (
162
+ (
163
+ nodes .colspec (colwidth = 1 ),
164
+ nodes .colspec (colwidth = 1 ),
165
+ )
166
+ )
167
+ body = nodes .tbody ()
168
+ group += body
159
169
for icon in list_octicons ():
160
- item_node = nodes .list_item ()
161
- item_node . extend (
162
- (
163
- nodes . literal ( icon , icon ),
164
- nodes .Text ( ": " ),
165
- nodes .raw (
166
- "" ,
167
- nodes .Text ( get_octicon ( icon , classes = classes )),
168
- format = "html " ,
169
- ),
170
- )
170
+ row = nodes .row ()
171
+ body += row
172
+ cell = nodes . entry ()
173
+ row += cell
174
+ cell += nodes .literal ( icon , icon )
175
+ cell = nodes .entry ()
176
+ row += cell
177
+ cell += nodes .raw (
178
+ " " ,
179
+ get_octicon ( icon , classes = classes ),
180
+ format = "html" ,
171
181
)
172
- list_node += item_node
173
- return [list_node ]
182
+ return [table ]
174
183
175
184
176
185
class fontawesome (nodes .Element , nodes .General ): # noqa: N801
You can’t perform that action at this time.
0 commit comments