mirror of
https://github.com/MCSManager/MCSManager.git
synced 2025-01-12 14:54:34 +08:00
Feat: i18n text
This commit is contained in:
parent
fc44b8ef80
commit
f1eae98244
@ -1015,9 +1015,7 @@ export const configData: {
|
|||||||
Settings: {
|
Settings: {
|
||||||
ServerPassword: t("TXT_CODE_448df2bd"),
|
ServerPassword: t("TXT_CODE_448df2bd"),
|
||||||
ServerPort: t("TXT_CODE_a379038f"),
|
ServerPort: t("TXT_CODE_a379038f"),
|
||||||
MaxSlots: t(
|
MaxSlots: t("TXT_CODE_e304faa"),
|
||||||
"最大同时连接数。如果你想让玩家被踢出“服务器已满”的设定,请将其设置为你设置的最大玩家数,然后将泰拉瑞亚的最大玩家设置为2个或以上"
|
|
||||||
),
|
|
||||||
ReservedSlots: t("TXT_CODE_369a4a22"),
|
ReservedSlots: t("TXT_CODE_369a4a22"),
|
||||||
ServerName: t("TXT_CODE_60e3c342"),
|
ServerName: t("TXT_CODE_60e3c342"),
|
||||||
UseServerName: t("TXT_CODE_8a924345"),
|
UseServerName: t("TXT_CODE_8a924345"),
|
||||||
@ -1071,22 +1069,14 @@ export const configData: {
|
|||||||
PreventInvalidPlaceStyle: t("TXT_CODE_fe82609a"),
|
PreventInvalidPlaceStyle: t("TXT_CODE_fe82609a"),
|
||||||
ForceXmas: t("TXT_CODE_b649a71a"),
|
ForceXmas: t("TXT_CODE_b649a71a"),
|
||||||
ForceHalloween: t("TXT_CODE_ac52ad06"),
|
ForceHalloween: t("TXT_CODE_ac52ad06"),
|
||||||
AllowAllowedGroupsToSpawnBannedItems: t(
|
AllowAllowedGroupsToSpawnBannedItems: t("TXT_CODE_3f3e734b"),
|
||||||
"允许禁止项目允许列表中的组生成被禁止的项目,即使 PreventBannedItemSpawn 设置为 true"
|
RespawnSeconds: t("TXT_CODE_288830f4"),
|
||||||
),
|
RespawnBossSeconds: t("TXT_CODE_b45e73fb"),
|
||||||
RespawnSeconds: t(
|
|
||||||
"玩家在重生之前必须等待的秒数。有效范围:0(默认值)到 15 秒。使用风险自负"
|
|
||||||
),
|
|
||||||
RespawnBossSeconds: t(
|
|
||||||
"如果附近有 Boss,玩家在重生之前必须等待的秒数。有效范围:0(默认值)到 30 秒。使用风险自负"
|
|
||||||
),
|
|
||||||
AnonymousBossInvasions: t("TXT_CODE_87e18bb5"),
|
AnonymousBossInvasions: t("TXT_CODE_87e18bb5"),
|
||||||
MaxHP: t("TXT_CODE_3f470950"),
|
MaxHP: t("TXT_CODE_3f470950"),
|
||||||
MaxMP: t("TXT_CODE_95dfd5bd"),
|
MaxMP: t("TXT_CODE_95dfd5bd"),
|
||||||
BombExplosionRadius: t("TXT_CODE_f71475e2"),
|
BombExplosionRadius: t("TXT_CODE_f71475e2"),
|
||||||
GiveItemsDirectly: t(
|
GiveItemsDirectly: t("TXT_CODE_260d96a0"),
|
||||||
"如果设置为 true,则给予玩家的物品将直接插入到他们的物品栏中。否则,给予玩家的物品将作为掉落的物品生成。实验性功能,可能无法正常工作或导致物品丢失"
|
|
||||||
),
|
|
||||||
DefaultRegistrationGroupName: t("TXT_CODE_cfd64e73"),
|
DefaultRegistrationGroupName: t("TXT_CODE_cfd64e73"),
|
||||||
DefaultGuestGroupName: t("TXT_CODE_90896d08"),
|
DefaultGuestGroupName: t("TXT_CODE_90896d08"),
|
||||||
RememberLeavePos: t("TXT_CODE_52b31aef"),
|
RememberLeavePos: t("TXT_CODE_52b31aef"),
|
||||||
@ -1099,9 +1089,7 @@ export const configData: {
|
|||||||
EnableWhitelist: t("TXT_CODE_d0e37f20"),
|
EnableWhitelist: t("TXT_CODE_d0e37f20"),
|
||||||
WhitelistKickReason: t("TXT_CODE_f160d877"),
|
WhitelistKickReason: t("TXT_CODE_f160d877"),
|
||||||
ServerFullReason: t("TXT_CODE_4ff6a125"),
|
ServerFullReason: t("TXT_CODE_4ff6a125"),
|
||||||
ServerFullNoReservedReason: t(
|
ServerFullNoReservedReason: t("TXT_CODE_5f23008"),
|
||||||
"在服务器已满且没有可用预留插槽的情况下踢出试图加入的玩家时给出的原因"
|
|
||||||
),
|
|
||||||
KickOnHardcoreDeath: t("TXT_CODE_95340802"),
|
KickOnHardcoreDeath: t("TXT_CODE_95340802"),
|
||||||
HardcoreKickReason: t("TXT_CODE_129475a7"),
|
HardcoreKickReason: t("TXT_CODE_129475a7"),
|
||||||
BanOnHardcoreDeath: t("TXT_CODE_8ab0cc1a"),
|
BanOnHardcoreDeath: t("TXT_CODE_8ab0cc1a"),
|
||||||
@ -1130,14 +1118,10 @@ export const configData: {
|
|||||||
KickOnProjectileThresholdBroken: t("TXT_CODE_946d4401"),
|
KickOnProjectileThresholdBroken: t("TXT_CODE_946d4401"),
|
||||||
HealOtherThreshold: t("TXT_CODE_449efd26"),
|
HealOtherThreshold: t("TXT_CODE_449efd26"),
|
||||||
KickOnHealOtherThresholdBroken: t("TXT_CODE_e0643e6f"),
|
KickOnHealOtherThresholdBroken: t("TXT_CODE_e0643e6f"),
|
||||||
SuppressPermissionFailureNotices: t(
|
SuppressPermissionFailureNotices: t("TXT_CODE_decf21ee"),
|
||||||
"禁止来自区域、重生点或服务器编辑失败的生成权限失败的警告"
|
|
||||||
),
|
|
||||||
DisableModifiedZenith: t("TXT_CODE_d4b058a9"),
|
DisableModifiedZenith: t("TXT_CODE_d4b058a9"),
|
||||||
DisableCustomDeathMessages: t("TXT_CODE_5143c584"),
|
DisableCustomDeathMessages: t("TXT_CODE_5143c584"),
|
||||||
CommandSpecifier: t(
|
CommandSpecifier: t("TXT_CODE_235cd293"),
|
||||||
"指定哪个字符串作为命令的起始部分。如果长度大于1,则可能无法正常工作。"
|
|
||||||
),
|
|
||||||
CommandSilentSpecifier: t("TXT_CODE_1049cbd1"),
|
CommandSilentSpecifier: t("TXT_CODE_1049cbd1"),
|
||||||
DisableSpewLogs: t("TXT_CODE_f29d5d2"),
|
DisableSpewLogs: t("TXT_CODE_f29d5d2"),
|
||||||
DisableSecondUpdateLogs: t("TXT_CODE_ef97db20"),
|
DisableSecondUpdateLogs: t("TXT_CODE_ef97db20"),
|
||||||
@ -1146,12 +1130,8 @@ export const configData: {
|
|||||||
SuperAdminChatSuffix: t("TXT_CODE_5bc16b9a"),
|
SuperAdminChatSuffix: t("TXT_CODE_5bc16b9a"),
|
||||||
EnableGeoIP: t("TXT_CODE_6bf4665b"),
|
EnableGeoIP: t("TXT_CODE_6bf4665b"),
|
||||||
DisplayIPToAdmins: t("TXT_CODE_1b763e24"),
|
DisplayIPToAdmins: t("TXT_CODE_1b763e24"),
|
||||||
ChatFormat: t(
|
ChatFormat: t("TXT_CODE_2374966e"),
|
||||||
"更改游戏内聊天格式:{0} = 群组名称,{1} = 群组前缀,{2} = 玩家名称,{3} = 群组后缀,{4} = 聊天消息。"
|
ChatAboveHeadsFormat: t("TXT_CODE_97535446"),
|
||||||
),
|
|
||||||
ChatAboveHeadsFormat: t(
|
|
||||||
"更改在头顶聊天时使用的玩家名称。以方括号包裹的玩家名称开头,格式与 Terraria 的一致。与 ChatFormat 相同的格式,但不包括消息。"
|
|
||||||
),
|
|
||||||
EnableChatAboveHeads: t("TXT_CODE_9c39c7ae"),
|
EnableChatAboveHeads: t("TXT_CODE_9c39c7ae"),
|
||||||
BroadcastRGB: t("TXT_CODE_11d2ab6b"),
|
BroadcastRGB: t("TXT_CODE_11d2ab6b"),
|
||||||
StorageType: t("TXT_CODE_8e5f865e"),
|
StorageType: t("TXT_CODE_8e5f865e"),
|
||||||
@ -1167,9 +1147,7 @@ export const configData: {
|
|||||||
LogRest: t("TXT_CODE_fdd1a61"),
|
LogRest: t("TXT_CODE_fdd1a61"),
|
||||||
EnableTokenEndpointAuthentication: t("TXT_CODE_b9d7fe43"),
|
EnableTokenEndpointAuthentication: t("TXT_CODE_b9d7fe43"),
|
||||||
RESTMaximumRequestsPerInterval: t("TXT_CODE_8298bfde"),
|
RESTMaximumRequestsPerInterval: t("TXT_CODE_8298bfde"),
|
||||||
RESTRequestBucketDecreaseIntervalMinutes: t(
|
RESTRequestBucketDecreaseIntervalMinutes: t("TXT_CODE_5b190bc4"),
|
||||||
"REST 请求存储桶减少 1 的频率(以分钟为单位)。最小值为 1 分钟"
|
|
||||||
),
|
|
||||||
ApplicationRestTokens: t("TXT_CODE_f0ca2761")
|
ApplicationRestTokens: t("TXT_CODE_f0ca2761")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -162,7 +162,7 @@ const save = async () => {
|
|||||||
</div>
|
</div>
|
||||||
<a-modal
|
<a-modal
|
||||||
v-model:open="open"
|
v-model:open="open"
|
||||||
:title="t('设置图片列表')"
|
:title="t('TXT_CODE_4a56836d')"
|
||||||
:closable="false"
|
:closable="false"
|
||||||
:destroy-on-close="true"
|
:destroy-on-close="true"
|
||||||
>
|
>
|
||||||
@ -171,7 +171,7 @@ const save = async () => {
|
|||||||
v-for="(imgItem, index) in imgList"
|
v-for="(imgItem, index) in imgList"
|
||||||
:key="imgItem.url + imgItem.key"
|
:key="imgItem.url + imgItem.key"
|
||||||
v-bind="formItemLayout"
|
v-bind="formItemLayout"
|
||||||
:label="`${t('图片')} ${index + 1}`"
|
:label="`${t('TXT_CODE_9900f79e')} ${index + 1}`"
|
||||||
:name="[index, 'url']"
|
:name="[index, 'url']"
|
||||||
:rules="{
|
:rules="{
|
||||||
required: true,
|
required: true,
|
||||||
@ -200,7 +200,7 @@ const save = async () => {
|
|||||||
|
|
||||||
<div v-else style="display: inline-flex; width: 80%">
|
<div v-else style="display: inline-flex; width: 80%">
|
||||||
<a-input :value="`${t('TXT_CODE_b625dbf0') + imgItem.uploadPercent}%`" disabled />
|
<a-input :value="`${t('TXT_CODE_b625dbf0') + imgItem.uploadPercent}%`" disabled />
|
||||||
<a-tooltip :title="t('取消上传')">
|
<a-tooltip :title="t('TXT_CODE_7ec87e8a')">
|
||||||
<a-button type="link" @click="cancelUpload(imgItem)">
|
<a-button type="link" @click="cancelUpload(imgItem)">
|
||||||
<CloseOutlined />
|
<CloseOutlined />
|
||||||
</a-button>
|
</a-button>
|
||||||
|
@ -127,7 +127,7 @@ const close = () => {
|
|||||||
</a-typography-paragraph>
|
</a-typography-paragraph>
|
||||||
</a-typography>
|
</a-typography>
|
||||||
</a-tab-pane>
|
</a-tab-pane>
|
||||||
<a-tab-pane key="url" :tab="t('网络URL')" force-render>
|
<a-tab-pane key="url" :tab="t('TXT_CODE_ba42d467')" force-render>
|
||||||
<a-input v-model:value.lazy.trim="imgSrc" autofocus :placeholder="t('TXT_CODE_c8a51b2e')" />
|
<a-input v-model:value.lazy.trim="imgSrc" autofocus :placeholder="t('TXT_CODE_c8a51b2e')" />
|
||||||
</a-tab-pane>
|
</a-tab-pane>
|
||||||
</a-tabs>
|
</a-tabs>
|
||||||
|
@ -37,7 +37,8 @@ module.exports = {
|
|||||||
options.defaultValue = key;
|
options.defaultValue = key;
|
||||||
let hashKey = `${FN_KEY}${crc32(key).toString(16)}`;
|
let hashKey = `${FN_KEY}${crc32(key).toString(16)}`;
|
||||||
console.log("Transform text:", key, "->", hashKey);
|
console.log("Transform text:", key, "->", hashKey);
|
||||||
newCode = String(newCode).replace(`t("${key}")`, `t("${hashKey}")`);
|
newCode = String(newCode).replace(`"${key}"`, `"${hashKey}"`);
|
||||||
|
newCode = String(newCode).replace(`'${key}'`, `'${hashKey}'`);
|
||||||
parser.set(hashKey, options);
|
parser.set(hashKey, options);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user