From 83b075015134e6c9c840498fec5d8349774f1235 Mon Sep 17 00:00:00 2001 From: Maxim Lebedev Date: Thu, 14 Dec 2023 16:31:12 +0600 Subject: [PATCH] :bento: Regenerated templates with fixed locale string for amount --- locales/en/messages.gotext.json | 6 +++--- locales/en/out.gotext.json | 2 +- locales/ru/messages.gotext.json | 6 +++--- locales/ru/out.gotext.json | 2 +- locales_gen.go | 36 ++++++++++++++++----------------- web/template/template.qtpl | 2 +- web/template/template.qtpl.go | 2 +- 7 files changed, 28 insertions(+), 28 deletions(-) diff --git a/locales/en/messages.gotext.json b/locales/en/messages.gotext.json index 9317ac8..7449eb5 100644 --- a/locales/en/messages.gotext.json +++ b/locales/en/messages.gotext.json @@ -25,9 +25,9 @@ "placeholders": [ { "id": "Amount__100", - "string": "%.2[1]f", - "type": "float64", - "underlyingType": "float64", + "string": "%[1]d", + "type": "uint64", + "underlyingType": "uint64", "argNum": 1, "expr": "ctx.amount / 100" }, diff --git a/locales/en/out.gotext.json b/locales/en/out.gotext.json index 19ecf64..7449eb5 100644 --- a/locales/en/out.gotext.json +++ b/locales/en/out.gotext.json @@ -25,7 +25,7 @@ "placeholders": [ { "id": "Amount__100", - "string": "%.2[1]f", + "string": "%[1]d", "type": "uint64", "underlyingType": "uint64", "argNum": 1, diff --git a/locales/ru/messages.gotext.json b/locales/ru/messages.gotext.json index 97359fd..73b16e9 100644 --- a/locales/ru/messages.gotext.json +++ b/locales/ru/messages.gotext.json @@ -24,9 +24,9 @@ "placeholders": [ { "id": "Amount__100", - "string": "%.2[1]f", - "type": "float64", - "underlyingType": "float64", + "string": "%[1]d", + "type": "uint64", + "underlyingType": "uint64", "argNum": 1, "expr": "ctx.amount / 100" }, diff --git a/locales/ru/out.gotext.json b/locales/ru/out.gotext.json index 52bba01..73b16e9 100644 --- a/locales/ru/out.gotext.json +++ b/locales/ru/out.gotext.json @@ -24,7 +24,7 @@ "placeholders": [ { "id": "Amount__100", - "string": "%.2[1]f", + "string": "%[1]d", "type": "uint64", "underlyingType": "uint64", "argNum": 1, diff --git a/locales_gen.go b/locales_gen.go index 681fd0d..54a9bd7 100644 --- a/locales_gen.go +++ b/locales_gen.go @@ -40,7 +40,7 @@ func init() { var messageKeyToIndex = map[string]int{ "Donate": 1, - "Donate $%.2f to %s": 0, + "Donate $%d to %s": 0, "annually": 7, "contribution frequency": 3, "dollar amount": 2, @@ -51,27 +51,27 @@ var messageKeyToIndex = map[string]int{ } var enIndex = []uint32{ // 10 elements - 0x00000000, 0x00000053, 0x0000005a, 0x00000068, - 0x0000007f, 0x00000088, 0x0000008f, 0x00000097, - 0x000000a0, 0x000000ac, + 0x00000000, 0x00000051, 0x00000058, 0x00000066, + 0x0000007d, 0x00000086, 0x0000008d, 0x00000095, + 0x0000009e, 0x000000aa, } // Size: 64 bytes -const enData string = "" + // Size: 172 bytes - "\x14\x01\x81\x01\x02=\x00\x10\x02Donate to %[2]s=\x01\x1d\x02Donate oned" + - "ollar™ to %[2]s\x00\x19\x02Donate $%.2[1]f to %[2]s\x02Donate\x02dollar " + - "amount\x02contribution frequency\x02one time\x02weekly\x02monthly\x02ann" + - "ually\x02from Russia" +const enData string = "" + // Size: 170 bytes + "\x14\x01\x81\x01\x00=\x00\x10\x02Donate to %[2]s=\x01\x1d\x02Donate oned" + + "ollar™ to %[2]s\x00\x17\x02Donate $%[1]d to %[2]s\x02Donate\x02dollar am" + + "ount\x02contribution frequency\x02one time\x02weekly\x02monthly\x02annua" + + "lly\x02from Russia" var ruIndex = []uint32{ // 10 elements - 0x00000000, 0x00000081, 0x0000009a, 0x000000b9, - 0x000000d7, 0x000000ee, 0x00000105, 0x0000011a, - 0x0000012b, 0x0000013d, + 0x00000000, 0x0000007f, 0x00000098, 0x000000b7, + 0x000000d5, 0x000000ec, 0x00000103, 0x00000118, + 0x00000129, 0x0000013b, } // Size: 64 bytes -const ruData string = "" + // Size: 317 bytes - "\x14\x01\x81\x01\x02=\x00\x1f\x02Пожертвовать %[2]s=\x01-\x02Пожертвоват" + - "ь долор™ %[2]s\x00(\x02Пожертвовать $%.2[1]f %[2]s\x02Пожертвовать\x02с" + - "умма в долларах\x02частота взносов\x02единоразово\x02еженедельно\x02еже" + - "месячно\x02ежегодно\x02из России" +const ruData string = "" + // Size: 315 bytes + "\x14\x01\x81\x01\x00=\x00\x1f\x02Пожертвовать %[2]s=\x01-\x02Пожертвоват" + + "ь долор™ %[2]s\x00&\x02Пожертвовать $%[1]d %[2]s\x02Пожертвовать\x02сум" + + "ма в долларах\x02частота взносов\x02единоразово\x02еженедельно\x02ежеме" + + "сячно\x02ежегодно\x02из России" - // Total table size 617 bytes (0KiB); checksum: 21DFB24C + // Total table size 613 bytes (0KiB); checksum: 7E1ACFAA diff --git a/web/template/template.qtpl b/web/template/template.qtpl index 470b08f..60ca6ef 100644 --- a/web/template/template.qtpl +++ b/web/template/template.qtpl @@ -53,7 +53,7 @@ func NewContext(processors domain.ConfigProcessors, lang language.Tag, amount ui

{%= ctx.title() %}

`) //line web/template/template.qtpl:56 - ctx.streamt(qw422016, `Donate $%.2f to %s`, ctx.amount/100, "toby3d") + ctx.streamt(qw422016, `Donate $%d to %s`, ctx.amount/100, "toby3d") //line web/template/template.qtpl:56 qw422016.N().S(`