Module:Flex

Revision as of 13:59, 12 October 2026 by ReisuDesign (talk | contribs) (Created page with " local p = {} function p.main(frame) local args = frame:getParent().args local items = {} for i = 1, #args do local item = args[i] if item and mw.text.trim(item) ~= "" then table.insert(items, '<div>' .. item .. '</div>' ) end end return '<div style="display:flex; column-gap:15px; flex-direction:row; flex-wrap:wrap;">' .. table.concat(items) .. '</div>' end return p")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Module documentation

The documentation for this module is missing. Click here to create it.

local p = {}

function p.main(frame)
    local args = frame:getParent().args
    local items = {}

    for i = 1, #args do
        local item = args[i]

        if item and mw.text.trim(item) ~= "" then
            table.insert(items,
                '<div>' .. item .. '</div>'
            )
        end
    end

    return '<div style="display:flex; column-gap:15px; flex-direction:row; flex-wrap:wrap;">'
        .. table.concat(items)
        .. '</div>'
end

return p