Mô đun:zh-numbers

Từ điển mở Wiktionary
export = {}

local output = [=[
{| class="wikitable mw-collapsible mw-expanded" style="text-align:center; width:55em;"
|-
! colspan=17| Số tiếng Trung Quốc
|-
!
! 0
! 1
! 2
! 3
! 4
! 5
! 6
! 7
! 8
! 9
! 10
! 10<sup>2</sup>
! 10<sup>3</sup>
! 10<sup>4</sup>
! 10<sup>8</sup>
! 10<sup>12</sup>
|-
! Thông thường<br><span style="white-space:nowrap">([[小寫#]]/[[小写#]])</span>
| [[〇#]], [[零#]]
| [[一#]]
| [[二#]]
| [[三#]]
| [[四#]]
| [[五#]]
| [[六#]]
| [[七#]]
| [[八#]]
| [[九#]]
| [[十#]]
| [[百#]]
| [[千#]]
| rowspan="2" | [[萬#]]/[[万#]]<br />[[十千#]] <span style="font-size: small;">(Malaysia, Singapore)</span>
| rowspan="2" | [[億#]]/[[亿#]]
| rowspan="2" | <span style="white-space:nowrap">[[兆#]] <span style="font-size: small;">(Đài Loan)</span></span><br><span style="white-space:nowrap">[[萬億#]]/[[万亿#]] <span style="font-size: small;">(Đại lục)</span></span>
|-
! [[w:en:Chinese numerals#Standard numbers|Tài chính]]<br><span style="white-space:nowrap">([[大寫#]]/[[大写#]])</span>
| [[零#]]
| [[壹#]]
| [[貳#]]/[[贰#]]
| [[參#]]/[[叁#]]
| [[肆#]]
| [[伍#]]
| [[陸#]]/[[陆#]]
| [[柒#]]
| [[捌#]]
| [[玖#]]
| [[拾#]]
| [[佰#]]
| [[仟#]]
|}[[Thể loại:Số đếm tiếng Trung Quốc]]]=]

local function link(text)
	return '<span class="Hani" lang="zh">[[' .. text .. '#Tiếng Trung Quốc|' .. text .. ']]</span>'
end

function export.show(frame)	
	output = mw.ustring.gsub(
		output,
		'%[%[([^%]]+)#%]%]',
		link
	)

	return output
end

return export