summaryrefslogtreecommitdiff
path: root/locale
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2022-06-29 02:43:02 +0800
committerGitHub <noreply@github.com>2022-06-29 02:43:02 +0800
commitcab40a0abe562db06e5bf4484c000559b0ccb4e4 (patch)
tree008aaa8744ba93543ac80fa3a1af8ad70fd388be /locale
parent2548e6d5f5744d38230866e07c1eaec1c16a1302 (diff)
parentb6f9aa8b9c04d11069440ea0369e30201a3969be (diff)
downloadlua-language-server-cab40a0abe562db06e5bf4484c000559b0ccb4e4.zip
Merge pull request #1247 from AlexCai2019/master
繁體中文翻譯
Diffstat (limited to 'locale')
-rw-r--r--locale/zh-tw/meta.lua2
-rw-r--r--locale/zh-tw/script.lua48
-rw-r--r--locale/zh-tw/setting.lua26
3 files changed, 38 insertions, 38 deletions
diff --git a/locale/zh-tw/meta.lua b/locale/zh-tw/meta.lua
index f97241df..23af021a 100644
--- a/locale/zh-tw/meta.lua
+++ b/locale/zh-tw/meta.lua
@@ -281,7 +281,7 @@ debug.getuservalue['>5.4']=
'回傳關聯在 `u` 上的第 `n` 個 `Lua` 值,以及一個布林, `false` 表示值不存在。'
debug.setcstacklimit =
[[
-### **已在 `Lua 5.4.2` 中廢棄**
+### **已在 `Lua 5.4.2` 中棄用**
設定新的C堆疊限制。該限制控制Lua中巢狀呼叫的深度,以避免堆疊溢出。
diff --git a/locale/zh-tw/script.lua b/locale/zh-tw/script.lua
index 14716598..da026422 100644
--- a/locale/zh-tw/script.lua
+++ b/locale/zh-tw/script.lua
@@ -85,7 +85,7 @@ DIAG_COUNT_DOWN_LOOP =
DIAG_UNKNOWN =
'無法推測出類型。'
DIAG_DEPRECATED =
-'已廢棄。'
+'已棄用。'
DIAG_DIFFERENT_REQUIRES =
'使用了不同的名字 `require` 了同一個檔案。'
DIAG_REDUNDANT_RETURN =
@@ -102,8 +102,8 @@ DIAG_CIRCLE_DOC_CLASS =
'循環繼承的類別。'
DIAG_DOC_FIELD_NO_CLASS =
'欄位必須定義在類別之後。'
-DIAG_DUPLICATE_DOC_ALIAS = -- TODO: need translate!
-'Duplicate defined alias `{}`.'
+DIAG_DUPLICATE_DOC_ALIAS =
+'重複定義的別名 `{}`.'
DIAG_DUPLICATE_DOC_FIELD =
'重複定義的欄位 `{}`。'
DIAG_DUPLICATE_DOC_PARAM =
@@ -128,18 +128,18 @@ DIAG_UNKNOWN_CAST_VARIABLE =
'未知的類型轉換變數 `{}`.'
DIAG_CAST_TYPE_MISMATCH =
'不能將 `{ref}` 轉換為 `{def}`。'
-DIAG_MISSING_RETURN_VALUE = -- TODO: need translate!
-'At least {min} return values are required, but here only {rmax} values are returned.'
-DIAG_MISSING_RETURN_VALUE_RANGE = -- TODO: need translate!
-'At least {min} return values are required, but here only {rmin} to {rmax} values are returned.'
-DIAG_REDUNDANT_RETURN_VALUE = -- TODO: need translate!
-'At most {max} values returned, but the {rmax}th value was returned here.'
-DIAG_REDUNDANT_RETURN_VALUE_RANGE = -- TODO: need translate!
-'At most {max} values returned, but {rmin}th to {rmax}th values were returned here.'
-DIAG_MISSING_RETURN = -- TODO: need translate!
-'Return value is required here.'
-DIAG_RETURN_TYPE_MISMATCH = -- TODO: need translate!
-'The type of the {index} return value is `{def}`, but the actual return is `{ref}`.'
+DIAG_MISSING_RETURN_VALUE =
+'至少需要 {min} 個回傳值,但此處只回傳 {rmax} 個值。'
+DIAG_MISSING_RETURN_VALUE_RANGE =
+'至少需要 {min} 個回傳值,但此處只回傳 {rmin} 到 {rmax} 個值。'
+DIAG_REDUNDANT_RETURN_VALUE =
+'最多只有 {max} 個回傳值,但此處回傳了第 {rmax} 個值。'
+DIAG_REDUNDANT_RETURN_VALUE_RANGE =
+'最多只有 {max} 個回傳值,但此處回傳了第 {rmin} 到第 {rmax} 個值。'
+DIAG_MISSING_RETURN =
+'此處需要回傳值。'
+DIAG_RETURN_TYPE_MISMATCH =
+'第 {index} 個回傳值的類型為 `{def}` ,但實際回傳的是 `{ref}`。'
MWS_NOT_SUPPORT =
'{} 目前還不支援多工作目錄,我可能需要重新啟動才能支援新的工作目錄...'
@@ -957,7 +957,7 @@ local module = require('string.utils')
]=]
LUADOC_DESC_ASYNC =
[=[
-將函式標記為非同步
+將函式標記為非同步。
## 語法
`---@async`
@@ -976,15 +976,15 @@ LUADOC_DESC_NODISCARD =
---
[檢視文件](https://github.com/sumneko/lua-language-server/wiki/EmmyLua-Annotations#nodiscard)
]=]
-LUADOC_DESC_CAST = -- TODO: need translate!
+LUADOC_DESC_CAST =
[=[
-Allows type casting (type conversion).
+允許轉型(類型轉換)。
-## Syntax
+## 語法
`@cast <variable> <[+|-]type>[, <[+|-]type>]...`
-## Usage
-### Overwrite type
+## 用法
+### 覆蓋類型
```
---@type integer
local x --> integer
@@ -992,7 +992,7 @@ local x --> integer
---@cast x string
print(x) --> string
```
-### Add Type
+### 增加類型
```
---@type string
local x --> string
@@ -1000,7 +1000,7 @@ local x --> string
---@cast x +boolean, +number
print(x) --> string|boolean|number
```
-### Remove Type
+### 移除類型
```
---@type string|table
local x --> string|table
@@ -1009,5 +1009,5 @@ local x --> string|table
print(x) --> table
```
---
-[View Wiki](https://github.com/sumneko/lua-language-server/wiki/EmmyLua-Annotations#cast)
+[檢視文件](https://github.com/sumneko/lua-language-server/wiki/EmmyLua-Annotations#cast)
]=]
diff --git a/locale/zh-tw/setting.lua b/locale/zh-tw/setting.lua
index 9369bbcd..3af50c5b 100644
--- a/locale/zh-tw/setting.lua
+++ b/locale/zh-tw/setting.lua
@@ -235,14 +235,14 @@ config.hint.arrayIndex.Disable =
'停用陣列索引提示。'
config.hint.await =
'如果呼叫的函數被標記為了 `---@async`,則在呼叫處提示 `await`。'
-config.hint.semicolon = -- TODO: need translate!
-'If there is no semicolon at the end of the statement, display a virtual semicolon.'
-config.hint.semicolon.All = -- TODO: need translate!
-'All statements display virtual semicolons.'
-config.hint.semicolon.SameLine = -- TODO: need translate!
-'When two statements are on the same line, display a semicolon between them.'
-config.hint.semicolon.Disable = -- TODO: need translate!
-'Disable virtual semicolons.'
+config.hint.semicolon =
+'若陳述式尾部沒有分號,則顯示虛擬分號。'
+config.hint.semicolon.All =
+'所有陳述式都顯示虛擬分號。'
+config.hint.semicolon.SameLine =
+'兩個陳述式在同一行時,在它們之間顯示分號。'
+config.hint.semicolon.Disable =
+'停用虛擬分號。'
config.format.enable =
'啟用程式碼格式化程式。'
config.format.defaultConfig =
@@ -266,13 +266,13 @@ config.IntelliSense.traceBeSetted =
'請查閱[文件](https://github.com/sumneko/lua-language-server/wiki/IntelliSense-optional-features)瞭解用法。'
config.IntelliSense.traceFieldInject =
'請查閱[文件](https://github.com/sumneko/lua-language-server/wiki/IntelliSense-optional-features)瞭解用法。'
-config.type.castNumberToInteger = -- TODO: need translate!
-'Allowed to assign the `number` type to the `integer` type.'
-config.type.weakUnionCheck = -- TODO: need translate!
+config.type.castNumberToInteger =
+'允許將 `number` 類型賦值給 `integer` 類型。'
+config.type.weakUnionCheck =
[[
-Once one subtype of a union type meets the condition, the union type also meets the condition.
+同位類型中只要有一個子類型滿足條件,則同位類型也滿足條件。
-When this setting is `false`, the `number|boolean` type cannot be assigned to the `number` type. It can be with `true`.
+此設定為 `false` 時,`number|boolean` 類型無法賦給 `number` 類型;為 `true` 時則可以。
]]
config.diagnostics['unused-local'] =
'未使用的區域變數'