Commit graph

106 commits

Author SHA1 Message Date
Michael Goderbauer 10a7c9ba22
Unify analysis options (#108462) 2022-07-28 09:07:49 -07:00
Greg Spencer 6504f2896c
Adds menuBarMenuLabel, and removes unneeded key localizations (#102100)
When I added localizations for shortcut keys, I added some that actually can't be shortcut keys, so I'm removing them again. These are mostly Japanese-specific keys that don't even appear on modern keyboards for the most part.

Also, added menuBarMenuLabel for an accessibility label for menu bar menus.

I modified the code for the localization generation scripts to add a --remove-undefined flag that will remove any localizations that don't appear in the canonical locale.
2022-05-09 09:25:52 -07:00
Jonah Williams 29d814b700
[intl] speed up localization generation and regenerate symbols (#102614) 2022-04-27 11:14:05 -07:00
Michael Goderbauer d021509141
migrate generated i18n code to super params (#101065) 2022-03-30 12:20:14 -07:00
Ian Hickson 61a0add286
Enable avoid_redundant_argument_values lint (#91409) (#91462) 2021-10-08 09:25:14 -07:00
Zachary Anderson b9d2177da0
Revert "Enable avoid_redundant_argument_values lint (#91409)" (#91461)
This reverts commit 5fd259be24.
2021-10-07 21:11:07 -07:00
Ian Hickson 5fd259be24
Enable avoid_redundant_argument_values lint (#91409) 2021-10-07 20:13:02 -07:00
Christopher Fujino 5456cad343
Migrate gen_localizations to null-safety (#86051) 2021-07-08 15:06:04 -07:00
Dan Field e36e62e9a6
Revert "Revert "Audit hashCode overrides outside of packages/flutter (#85370)" (#85451)" (#85567)
This reverts commit 2be0d57fa2.
2021-06-30 09:46:54 -07:00
Ren You 2be0d57fa2
Revert "Audit hashCode overrides outside of packages/flutter (#85370)" (#85451)
This reverts commit 9846fa5145.
2021-06-28 09:55:31 -07:00
Dan Field 9846fa5145
Audit hashCode overrides outside of packages/flutter (#85370) 2021-06-26 17:36:04 -07:00
Abhishek Ghaskata 4705e0cc19
migrate localization to null safety (#84064)
migrate localization to null safety
2021-06-14 11:23:09 -07:00
Alexandre Ardhuin 34059eec2c
enable lint prefer_interpolation_to_compose_strings (#83407) 2021-06-01 11:14:06 -07:00
Alexandre Ardhuin 0ef0f0ba5e
fix lint from an improved unnecessary_parenthesis (#83433) 2021-05-27 13:39:03 -07:00
Christopher Fujino 8654e4ae3e
begin migrating //flutter/dev/tools to null-safety (#80834) 2021-04-23 20:24:03 -07:00
Phil Quitslund 61c30c41b2
fix sort_directives violations (#80817) 2021-04-21 13:49:03 -07:00
Michael Goderbauer 807bb29888
enable prefer_function_declarations_over_variables lint (#77398) 2021-03-05 18:29:04 -08:00
Darren Austin 1c7e34bb20
Migrate flutter_localizations to null safety. (#68645)
Migrate flutter_localizations to null safety.
2020-11-12 15:13:51 -08:00
Shi-Hao Hong a1a096e35a
[gen-l10n] Fix untranslated messages (#68553) 2020-11-05 16:24:02 -08:00
Shi-Hao Hong 4996f60b20
[gen_l10n] Fix unintended use of raw string in generateString (#69382)
* Fix failing tests from introducing raw string generation in gen_l10n tool
2020-10-31 19:24:53 +08:00
Alexandre Ardhuin 17cdf5559d
enable unnecessary_string_escapes and use_raw_strings (#68302) (#69025) 2020-10-26 12:42:05 -07:00
Zachary Anderson cbcd1321ed
Revert "enable unnecessary_string_escapes and use_raw_strings (#68302)" (#68714)
This reverts commit ae06c19a37.
2020-10-21 08:16:13 -07:00
Alexandre Ardhuin ae06c19a37
enable unnecessary_string_escapes and use_raw_strings (#68302) 2020-10-21 16:34:24 +02:00
Alexandre Ardhuin 73301a35a2
Sync lints (#68136) 2020-10-15 15:37:04 -07:00
Shi-Hao Hong 244f5ab598
Expose date symbols and patterns for en_US in framework (#67900)
* Expose date symbols and patterns for en_US in framework
2020-10-13 07:56:10 +08:00
Michael R Fairhurst 7f3c9b6bda
Remove unused 'dart:async' imports. (#65568) 2020-09-16 14:14:06 -07:00
Shi-Hao Hong b80b432555
Move gen_l10n into flutter_tools (#65025) 2020-09-03 09:26:58 -07:00
Shi-Hao Hong fd22fc3e35
[gen_l10n] Synthetic package generation by default (#62395)
* synthetic packages by default in gen_l10n tool

* Refactor default path for synthetic package

* Remove unused import

* Code cleanup

* Further improvements to help text

* Refactor synthetic package path

* Remove newlines

* Test cleanup

* clean up logic in inputs and outputs list function

* Update l10n.yaml usage

* only add option if value is non-null

* Update stocks app as proof of concept for synthetic package usage

* Address nits

* print pubspec contents

* add print statements

* Do not allow null value for useSyntheticPackage

* +

* +

* +

* +

* Cleanup

* Add test

* Fix text

* Dont parse pubspec directly

* Test using context

* WIP: generate synthetic packages on pub get -- needs tests

* Allow null value

* Update null handling

* Refactor to properly handle null case

* Fix yamlMap condition

* Fix yaml node for real

* WIP: struggling to write tests

* WIP - take absolute path as an option

* Add tests

* Use environment project directory for synthetic package generation pathway

* Fix typo

* Improve help text

* Update defaults

* Remove unauthorized path import

* Fix pathing issues at synthetic package generation

* Fix typo in test

* Use path.join so projectDir matches up based on OS

* Fix Windows pathing in test

* Remove unnecessary replaceApp code for projectDir.path

* Use globals.fs.currentDirectory.path in resident_runner_test.dart

* Fix merge conflict

* Add test to ensure that synthetic package is generated on pub get

* Fix resident_runner_test.dart tests

* Fix tests

* Use package:file instead of dart:io

* WIP - exploration

* Remove synthetic package use from stocks example

* Update integration test to not use synthetic packages

* Remove trailing whitespace

* flutter pub get runs synth package generation

* Remove more print statements

* Add license header

* WIP - minimally working pub.get

* Use own MockBuildSystem

* Modify test and implementation to be a little cleaner

* Fix flutter pub get invocation

* Use synthetic packages in stocks app

* Revert "Use synthetic packages in stocks app"

This reverts commit 45bf24903c.

* Add environment and buildSystem params to flutter test

* Address code review feedback

* +

* Isolate codegen into its own API

* Fix imports

* Slight refactor

* Add one more test for no l10n.yaml file

* Remove unneeded mock class and import in pub_get_test.dart

* More code review feedback

* Remove unnecessary imports

* Remove `return await`s that I missed

* use arrow functions instead
2020-08-31 13:19:41 +08:00
Shi-Hao Hong 0a7c6243fa
[gen_l10n] Absolute project path parameter (#63368) 2020-08-13 05:11:05 -07:00
Shi-Hao Hong c36b75e45b
Remove Special Handling of Norwegian Locales (#63034)
* Regenerate _no.arb and _nb.arb from scratch

* Revert no <--> nb synonym logic
2020-08-12 07:29:17 +08:00
Renzo Olivares d1c4bdb161
Add locales for fil(filipino) and gsw(swiss german) to locale list (#60632) 2020-07-09 13:56:01 -07:00
Shi-Hao Hong 61a04b1551
Fix and address Inconsistencies with Pashto support (#60600)
* Normalize Pashto incomplete translations

* Add comment to README.md about incomplete Pashto support
2020-07-09 15:52:19 +08:00
Shi-Hao Hong 1e6e7150f3
[gen_l10n] Update the arb filename parsing logic (#60185)
* Update the arb filename parsing to account for underscores

* Generalize the locale searching algorithm

* Update filename and @@locale behavior to require them to match
2020-06-26 12:01:59 +08:00
Per Classon 56a7dacd46
[flutter_tools] For l10n with deferred loading, use loadLibrary for non-web too (#59539)
After Dart VM change we are now required to use loadLibrary on an import whenever it is imported as deferred.

See: https://dart-review.googlesource.com/c/sdk/+/149613
2020-06-16 13:36:28 -07:00
Darren Austin b4788f290c
Updated gen_missing_localizations to copy the english strings instead of using 'TBD' for other locales. (#57053) 2020-05-14 11:12:05 -07:00
Shi-Hao Hong eadd30eb6c
Improve arb FormatException error message (#56373) 2020-05-07 18:09:03 -07:00
Shi-Hao Hong 13501af6e6
[gen_l10n] Optionally generate list of inputs/outputs (#56490) 2020-05-07 11:46:02 -07:00
Shi-Hao Hong c01c46c896
Test to ensure _kn.arb files are properly escaped (#56091)
* Run encode kn character encoding tool when gen_localizations is run

* Add test that ensures *_kn.arb files are properly encoded/escaped in order to be checked in

* Fix *_no.arb test to not incorrectly pass
2020-05-01 18:13:55 -07:00
Hans Muller b039fc7c09
Fixed a typo (#56146) 2020-05-01 15:39:02 -07:00
Shi-Hao Hong de4f052703
[gen_l10n] Fix unintended breaking change introduced by output-dir option (#55909)
* Fix breaking change introduced by gen_l10n output-dir option
2020-04-28 16:25:59 -07:00
Shi-Hao Hong 9d7af39a5b
[gen_l10n] Output directory option (#55792)
* Add new output-dir option for gen_l10n tool
2020-04-28 13:10:27 -07:00
Shi-Hao Hong bec1b734bd
Cleanup in gen_l10n files (#54401) 2020-04-10 10:35:33 -07:00
Per Classon 4451ffca23
Add option for deferred loading to gen_l10n (#53824) 2020-04-09 03:57:01 -07:00
Shi-Hao Hong 5d63637e43
[gen_l10n] Fallback feature for untranslated messages (#53374)
* Generate methods using template resources if they do not exist in other locales

* Added a flag to either output of messages that have not been translated with detail into a file, or display a summary on the terminal.

* Add integration test for fallback message usage
2020-04-08 18:55:50 -07:00
Shi-Hao Hong 592f7886e5
Remove escape dollar parameter in localizations_utils (#54219) 2020-04-08 12:52:03 -07:00
Per Classon e8d2907595
[gen_l10n] Handle single, double quotes, and dollar signs in strings (#54185) 2020-04-07 12:21:02 -07:00
Alexandre Ardhuin f5a9902577
enable avoid_equals_and_hash_code_on_mutable_classes (#52507) 2020-04-06 13:36:01 -07:00
Shi-Hao Hong 4e811d2819
[gen_l10n] Fix plural parsing for translated messages (#53954) 2020-04-03 15:46:01 -07:00
Shi-Hao Hong 365528aad6
Use no locale as synonym for nb (#53880) 2020-04-03 11:56:02 -07:00
Shi-Hao Hong 6837b0e353
[gen_l10n] Add scriptCode handling (#53868)
* [gen_l10n] Add scriptCode handling
2020-04-03 09:46:01 -07:00