🔖 dashboard v0.13.3 improve l10n

This commit is contained in:
naiba 2022-04-30 21:30:58 +08:00
parent 37315acfca
commit 9daa48945b
13 changed files with 16 additions and 16 deletions

View File

@ -4,7 +4,7 @@
<br>
<small><i>LOGO designed by <a href="https://xio.ng" target="_blank">熊大</a> .</i></small>
<br><br>
<img src="https://img.shields.io/github/workflow/status/naiba/nezha/Dashboard%20image?label=Dash%20v0.13.2&logo=github&style=for-the-badge">&nbsp;<img src="https://img.shields.io/github/v/release/naiba/nezha?color=brightgreen&label=Agent&style=for-the-badge&logo=github">&nbsp;<img src="https://img.shields.io/github/workflow/status/naiba/nezha/Agent%20release?label=Agent%20CI&logo=github&style=for-the-badge">&nbsp;<img src="https://img.shields.io/badge/Installer-v0.9.1-brightgreen?style=for-the-badge&logo=linux">
<img src="https://img.shields.io/github/workflow/status/naiba/nezha/Dashboard%20image?label=Dash%20v0.13.3&logo=github&style=for-the-badge">&nbsp;<img src="https://img.shields.io/github/v/release/naiba/nezha?color=brightgreen&label=Agent&style=for-the-badge&logo=github">&nbsp;<img src="https://img.shields.io/github/workflow/status/naiba/nezha/Agent%20release?label=Agent%20CI&logo=github&style=for-the-badge">&nbsp;<img src="https://img.shields.io/badge/Installer-v0.9.1-brightgreen?style=for-the-badge&logo=linux">
<br>
<br>
<p>:trollface: <b>Nezha Monitoring</b> self-hosted lightweight monitoring and operation and maintenance system. Supports system status, HTTP (SSL certificate change, upcoming expiration, expiration), TCP, Ping <b>monitoring</b> and <b>alerting</b>, execute scheduled tasks and <b>web terminal</b>.</p>

View File

@ -87,7 +87,7 @@ var funcMap = template.FuncMap{
}
},
"tf": func(t time.Time) string {
return t.In(singleton.Loc).Format("02/01/2006 15:04:05")
return t.In(singleton.Loc).Format("01/02/2006 15:04:05")
},
"len": func(slice []interface{}) string {
return strconv.Itoa(len(slice))
@ -99,7 +99,7 @@ var funcMap = template.FuncMap{
return template.HTML(`<` + s + `>`) // #nosec
},
"stf": func(s uint64) string {
return time.Unix(int64(s), 0).In(singleton.Loc).Format("02/01/2006 15:04")
return time.Unix(int64(s), 0).In(singleton.Loc).Format("01/02/2006 15:04")
},
"sf": func(duration uint64) string {
return time.Duration(time.Duration(duration) * time.Second).String()
@ -114,7 +114,7 @@ var funcMap = template.FuncMap{
return strings.TrimSpace(s)
},
"float32f": func(f float32) string {
return fmt.Sprintf("%.2f", f)
return fmt.Sprintf("%.3f", f)
},
"divU64": func(a, b uint64) float32 {
if b == 0 {
@ -151,7 +151,7 @@ var funcMap = template.FuncMap{
"dayBefore": func(i int) string {
year, month, day := time.Now().Date()
today := time.Date(year, month, day, 0, 0, 0, 0, time.Local)
return today.AddDate(0, 0, i-29).Format("02/01")
return today.AddDate(0, 0, i-29).Format("01/02")
},
"className": func(percent float32) string {
if percent == 0 {

View File

@ -1,6 +1,6 @@
{{define "common/header"}}
<!DOCTYPE html>
<html lang="zh-CN">
<html lang="{{.Conf.Language}}">
<head>
<meta charset="UTF-8">

View File

@ -1,6 +1,6 @@
{{define "dashboard/redirect"}}
<!DOCTYPE html>
<html lang="en">
<html lang="{{.Conf.Language}}">
<head>
<meta charset="UTF-8">

View File

@ -1,6 +1,6 @@
{{define "dashboard/terminal"}}
<!DOCTYPE html>
<html lang="en">
<html lang="{{.Conf.Language}}">
<head>
<meta charset="UTF-8">

View File

@ -1,6 +1,6 @@
{{define "theme-daynight/home"}}
<!doctype html>
<html lang="zh-Hans">
<html lang="{{.Conf.Language}}">
<head>
<meta charset="utf-8">

View File

@ -1,7 +1,7 @@
{{define "theme-daynight/service"}}
<!DOCTYPE html>
<html lang="zh-Hans">
<html lang="{{.Conf.Language}}">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />

View File

@ -1,6 +1,6 @@
{{define "theme-daynight/viewpassword"}}
<!DOCTYPE html>
<html lang="zh-Hans">
<html lang="{{.Conf.Language}}">
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />

View File

@ -1,6 +1,6 @@
{{define "theme-hotaru/home"}}
<!doctype html>
<html lang="zh">
<html lang="{{.Conf.Language}}">
<head>
<meta charset="utf-8">

View File

@ -1,6 +1,6 @@
{{define "theme-mdui/home"}}
<!doctype html>
<html lang="zh-CN">
<html lang="{{.Conf.Language}}">
<head>
<meta charset="utf-8">

View File

@ -1,6 +1,6 @@
{{define "theme-mdui/service"}}
<!doctype html>
<html lang="zh-CN">
<html lang="{{.Conf.Language}}">
<head>
<meta charset="utf-8">

View File

@ -1,6 +1,6 @@
{{define "theme-mdui/viewpassword"}}
<!doctype html>
<html lang="zh-CN">
<html lang="{{.Conf.Language}}">
<head>
<meta charset="utf-8">

View File

@ -12,7 +12,7 @@ import (
"github.com/naiba/nezha/pkg/utils"
)
var Version = "v0.13.2" // !!记得修改 README 中的 badge 版本!!
var Version = "v0.13.3" // !!记得修改 README 中的 badge 版本!!
var (
Conf *model.Config