-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Closed
Labels
a: internationalizationSupporting other languages or locales. (aka i18n)Supporting other languages or locales. (aka i18n)found in release: 3.24Found to occur in 3.24Found to occur in 3.24frameworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.has reproducible stepsThe issue has been confirmed reproducible and is ready to work onThe issue has been confirmed reproducible and is ready to work onr: fixedIssue is closed as already fixed in a newer versionIssue is closed as already fixed in a newer versionteam-toolOwned by Flutter Tool teamOwned by Flutter Tool teamtoolAffects the "flutter" command-line tool. See also t: labels.Affects the "flutter" command-line tool. See also t: labels.
Description
Steps to reproduce
- Create a project as follows
flutter gen-l10n
<root>
├── pubspec.yaml
└── lib
└── l10n
└── app_en.arb
pubspec.yaml
name: gen_l10n
publish_to: "none"
version: 1.0.0+1
environment:
sdk: ^3.5.0
dependencies:
flutter:
sdk: flutter
flutter_localizations:
sdk: flutter
dev_dependencies:
flutter_test:
sdk: flutter
flutter:
generate: trueapp_en.arb
{
"@@locale": "en",
"springBegins": "Spring begins on {springStartDate}",
"@springBegins": {
"description": "The first day of spring",
"placeholders": {
"springStartDate": {
"type": "DateTime",
"format": "asdf",
"isCustomDateFormat": true
}
}
}
}Or running the following shell script.
# Set up
# In empty directory
# Init
flutter create . --platforms=web
mkdir -p lib/l10n
# Setup Localization
echo 'name: gen_l10n
publish_to: "none"
version: 1.0.0+1
environment:
sdk: ^3.5.0
dependencies:
flutter:
sdk: flutter
flutter_localizations:
sdk: flutter
dev_dependencies:
flutter_test:
sdk: flutter
flutter:
generate: true
' > pubspec.yaml
echo '{
"@@locale": "en",
"springBegins": "Spring begins on {springStartDate}",
"@springBegins": {
"description": "The first day of spring",
"placeholders": {
"springStartDate": {
"type": "DateTime",
"format": "asdf",
"isCustomDateFormat": true
}
}
}
}' > lib/l10n/app_en.arb
flutter pub get
# gen-l10n
flutter gen-l10nExpected results
AppLocalizations is generated.
Actual results
The "isCustomDateFormat" value of the "springStartDate" placeholder in message springBegins must be a boolean value.
Code sample
Code sample
[Paste your code here]Screenshots or Video
No response
Logs
No response
Flutter Doctor output
Doctor output
[Paste your output here]Metadata
Metadata
Assignees
Labels
a: internationalizationSupporting other languages or locales. (aka i18n)Supporting other languages or locales. (aka i18n)found in release: 3.24Found to occur in 3.24Found to occur in 3.24frameworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.has reproducible stepsThe issue has been confirmed reproducible and is ready to work onThe issue has been confirmed reproducible and is ready to work onr: fixedIssue is closed as already fixed in a newer versionIssue is closed as already fixed in a newer versionteam-toolOwned by Flutter Tool teamOwned by Flutter Tool teamtoolAffects the "flutter" command-line tool. See also t: labels.Affects the "flutter" command-line tool. See also t: labels.