mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-29 19:10:26 +00:00
LibJS: Format sanctioned units such that there is one unit per line
Much easier to manage and view diffs this way, rather than one large single line. This will soon be the only method in this file, so there's no concern over taking up too much vertical space here.
This commit is contained in:
parent
305cb8a5d1
commit
8ff0d35386
Notes:
sideshowbarker
2024-07-17 05:02:42 +09:00
Author: https://github.com/trflynn89 Commit: https://github.com/SerenityOS/serenity/commit/8ff0d35386 Pull-request: https://github.com/SerenityOS/serenity/pull/15108 Reviewed-by: https://github.com/IdanHo Reviewed-by: https://github.com/linusg ✅
1 changed files with 45 additions and 1 deletions
|
@ -14,7 +14,51 @@ namespace JS::Intl {
|
|||
// Table 2: Single units sanctioned for use in ECMAScript, https://tc39.es/ecma402/#table-sanctioned-single-unit-identifiers
|
||||
constexpr auto sanctioned_single_unit_identifiers()
|
||||
{
|
||||
return AK::Array { "acre"sv, "bit"sv, "byte"sv, "celsius"sv, "centimeter"sv, "day"sv, "degree"sv, "fahrenheit"sv, "fluid-ounce"sv, "foot"sv, "gallon"sv, "gigabit"sv, "gigabyte"sv, "gram"sv, "hectare"sv, "hour"sv, "inch"sv, "kilobit"sv, "kilobyte"sv, "kilogram"sv, "kilometer"sv, "liter"sv, "megabit"sv, "megabyte"sv, "meter"sv, "mile"sv, "mile-scandinavian"sv, "milliliter"sv, "millimeter"sv, "millisecond"sv, "minute"sv, "month"sv, "ounce"sv, "percent"sv, "petabyte"sv, "pound"sv, "second"sv, "stone"sv, "terabit"sv, "terabyte"sv, "week"sv, "yard"sv, "year"sv };
|
||||
return AK::Array {
|
||||
"acre"sv,
|
||||
"bit"sv,
|
||||
"byte"sv,
|
||||
"celsius"sv,
|
||||
"centimeter"sv,
|
||||
"day"sv,
|
||||
"degree"sv,
|
||||
"fahrenheit"sv,
|
||||
"fluid-ounce"sv,
|
||||
"foot"sv,
|
||||
"gallon"sv,
|
||||
"gigabit"sv,
|
||||
"gigabyte"sv,
|
||||
"gram"sv,
|
||||
"hectare"sv,
|
||||
"hour"sv,
|
||||
"inch"sv,
|
||||
"kilobit"sv,
|
||||
"kilobyte"sv,
|
||||
"kilogram"sv,
|
||||
"kilometer"sv,
|
||||
"liter"sv,
|
||||
"megabit"sv,
|
||||
"megabyte"sv,
|
||||
"meter"sv,
|
||||
"mile"sv,
|
||||
"mile-scandinavian"sv,
|
||||
"milliliter"sv,
|
||||
"millimeter"sv,
|
||||
"millisecond"sv,
|
||||
"minute"sv,
|
||||
"month"sv,
|
||||
"ounce"sv,
|
||||
"percent"sv,
|
||||
"petabyte"sv,
|
||||
"pound"sv,
|
||||
"second"sv,
|
||||
"stone"sv,
|
||||
"terabit"sv,
|
||||
"terabyte"sv,
|
||||
"week"sv,
|
||||
"yard"sv,
|
||||
"year"sv,
|
||||
};
|
||||
}
|
||||
|
||||
// Additional single units used in ECMAScript required by the Intl.DurationFormat proposal
|
||||
|
|
Loading…
Reference in a new issue