@@ -12,11 +12,10 @@ const GEN_DIR = joinpath(WORK_DIR, "generated")
12
12
const ATTRIBUTE_SEARCH = Dict {String,Any} () # search terms
13
13
14
14
# monkey patch `Documenter` - note that this could break on minor `Documenter` releases
15
- @eval Documenter. Writers. HTMLWriter domify (ctx, navnode) = begin
16
- # github.com/JuliaDocs/Documenter.jl/blob/327d155f992ec7c63e35fa2cb08f7f7c2d33409a/src/Writers/HTMLWriter.jl#L1448-L1455
17
- page = getpage (ctx, navnode)
18
- map (page. elements) do elem
19
- rec = SearchRecord (ctx, navnode, elem)
15
+ @eval Documenter. Writers. HTMLWriter domify (dctx:: DCtx ) = begin
16
+ ctx, navnode = dctx. ctx, dctx. navnode
17
+ return map (getpage (ctx, navnode). mdast. children) do node
18
+ rec = SearchRecord (ctx, navnode, node, node. element)
20
19
# ###########################################################
21
20
# begin addition
22
21
info = " [src=$(rec. src) fragment=$(rec. fragment) title=$(rec. title) page_title=$(rec. page_title) ]"
@@ -43,7 +42,7 @@ const ATTRIBUTE_SEARCH = Dict{String,Any}() # search terms
43
42
end
44
43
# end addition
45
44
# ###########################################################
46
- domify (ctx, navnode, page . mapping[elem] )
45
+ domify (dctx, node, node . element )
47
46
end
48
47
end
49
48
0 commit comments