Module:UpdateExcerpt: Difference between revisions

Jump to navigation Jump to search
No edit summary
No edit summary
Line 1: Line 1:
local p = {}
local p = {}


-- =====================================================================
-- 1. CORE LOGIC (Private internal function)
-- =====================================================================
local function _render(month, day, year, maxLines, frame)
local function _render(month, day, year, maxLines, frame)
     if not month or month == "" or not day or day == "" or not year or year == "" then
     if not month or month == "" or not day or day == "" or not year or year == "" then
Line 44: Line 41:
end
end


-- =====================================================================
-- 2. OLD ENTRY POINT (For backwards compatibility)
-- =====================================================================
function p.render(frame)
function p.render(frame)
     local args = frame.args
     local args = frame.args
Line 59: Line 53:
end
end


-- =====================================================================
-- 3. NEW ULTRA-OPTIMIZED WIDGET ENTRY POINT
-- =====================================================================
function p.drawWidget(frame)
function p.drawWidget(frame)
     local parentArgs = frame:getParent().args
     local parentArgs = frame:getParent().args