Modul:R:Yandex

A Wikiszótárból, a nyitott szótárból

A modult a Modul:R:Yandex/doc lapon tudod dokumentálni

local export = {}
 
function export.create(frame)
	local args = frame:getParent().args
	local title = mw.title.getCurrentTitle().text
	local title_url = mw.uri.encode(title, QUERY)
	local link = ""
	if args == '' then
		link = "[https://translate.yandex.com/ Yandex Translate]"
	else
		link = "[https://translate.yandex.com/?text=" ..title_url.. "&lang=" ..args[1].."-" ..args[2].." " ..title.. "] - Яндекс Переводчик (" ..args[1].."-"..args[2]..")"
	end
	return link
end
 
return export