יחידה:הערה: הבדלים בין גרסאות בדף
מראה
מאין תקציר עריכה |
מאין תקציר עריכה |
||
| שורה 13: | שורה 13: | ||
end | end | ||
if args['שמאל'] then | if args['שמאל'] then | ||
text = '<div style="direction: ltr;text-align:left;">' .. args[1] .. '</div>' | text = '<div style="direction: ltr;text-align:left;">' .. frame:preprocess(args[1]) .. '</div>' | ||
else | else | ||
text = args[1] | text = frame:preprocess(args[1]) | ||
end | end | ||
גרסה מ־20:25, 28 בפברואר 2017
ניתן ליצור תיעוד על היחידה הזאת בדף יחידה:הערה/תיעוד
local Ref = {}
function parseRef(frame)
local argModule = require('Module:Arguments')
local warnings=''
local text=''
local refDic = {}
local args = argModule.getArgs(frame)
local refName = args['שם']
local refGroup = args['קבוצה']
if args[2] then
warnings = '<span class="error"><sup> פרמטר שני בהערה: </sup></span>[[קטגוריה:דפים עם שגיאות בהערה]]'
end
if args['שמאל'] then
text = '<div style="direction: ltr;text-align:left;">' .. frame:preprocess(args[1]) .. '</div>'
else
text = frame:preprocess(args[1])
end
return frame:extensionTag{ name = 'ref', content=text, args = { name = refName, group = refGroup } } .. warnings
end
Ref['הערה'] = parseRef
return Ref