మాడ్యూల్:Lang: కూర్పుల మధ్య తేడాలు

Content deleted Content added
దిద్దుబాటు సారాంశం లేదు
దిద్దుబాటు సారాంశం లేదు
పంక్తి 1,312:
 
local function is_ietf_tag (frame)
return _is_ietf_tag (getArgs (frame, {frameOnly = true,})[1]); -- args[1] is the ietf language tag to be tested; getArgs() so we also get parent frame
end
 
 
--[[--------------------------< I S _ I E T F _ T A G _ F R A M E >--------------------------------------------
 
Module entry point from an {{#invoke:}}; same as is_ietf_tag() except does not get parameters from the parent
(template) frame. This function not useful when called by {{lang|fn=is_ietf_tag_frame|<tag>}} because <tag>
is in the parent frame.
 
]]
 
local function is_ietf_tag_frame (frame)
-- work around for problem noted at Template talk:R from alternative language#Swedish to Swedish?
return _is_ietf_tag (getArgs (frame, {frameOnly = true,})[1]); -- args[1] is the ietf language tag to be tested; do not get parent frame
-- local args = {}; -- create table to hold holds args from getArgs (frame)
-- args = getArgs (frame, {frameOnly = true,}); -- fill args{} from frame.args
-- mw.logObject (frame.args, '1. frame.args'); -- should only be one arg in frame
-- mw.logObject (args, '2. args'); -- should only be one arg in args and it should match frame.args[1] unless frame.args[1] is empty string when args[1] should be nil
-- return _is_ietf_tag (frame.args[1]);
end
 
Line 1,573 ⟶ 1,579:
lang_xx_italic = lang_xx_italic,
is_ietf_tag = is_ietf_tag,
is_ietf_tag_frame = is_ietf_tag_frame,
is_lang_name = is_lang_name,
tag_from_name = tag_from_name, -- returns ietf tag associated with language name
"https://te.wikipedia.org/wiki/మాడ్యూల్:Lang" నుండి వెలికితీశారు