Difference between revisions 21306614 and 21306615 on frwiktionarylocal export = {} -- The main entry point. -- This is the only function that can be invoked from a template. function export.show(frame) if mw.title.getCurrentTitle().nsText == "Template" then return "(This template should be used on pages in the Category: namespace.)" elseif mw.title.getCurrentTitle().nsText ~= "Category" then (contracted; show full) end end end end -- Show navigational "breadcrumbs" at the top of the page. function show_breadcrumbs(template, info) if not info.code and export.get_item(template, info, "umbrella-categorization") ~= "parallel" then return nil end⏎ ⏎ local steps = {} -- Start at the current label and move our way up the "chain" from child to parent, until we can't go further. local current = info.label while current do local parents = export.get_item(template, {code = info.code, label = current, sc = nil}, "parents"(info.code and "parents" or "umbrella_parents")) local parent = parents and parents[1] or nil if not parent then break elseif type(parent) == "table" then parent = parent.name end (contracted; show full) return mw.getCurrentFrame():expandTemplate{title = TOC_template.text, args = {}} end end return nil end return export All content in the above text box is licensed under the Creative Commons Attribution-ShareAlike license Version 4 and was originally sourced from https://fr.wiktionary.org/w/index.php?diff=prev&oldid=21306615.
![]() ![]() This site is not affiliated with or endorsed in any way by the Wikimedia Foundation or any of its affiliates. In fact, we fucking despise them.
|