Skip to content

[i18n] Test EUI i18n tokens coverage#106377

Merged
Bamieh merged 6 commits intoelastic:masterfrom
Bamieh:i18n/eui_tokens
Jul 22, 2021
Merged

[i18n] Test EUI i18n tokens coverage#106377
Bamieh merged 6 commits intoelastic:masterfrom
Bamieh:i18n/eui_tokens

Conversation

@Bamieh
Copy link
Copy Markdown
Contributor

@Bamieh Bamieh commented Jul 21, 2021

Summary

Building on top of original PR #99613

Add tests to ensure that the i18n tokens from @elastic/eui and their mapping in Kibana are in sync.

The tests are meant to apply the following checks:

  1. Are we missing any label? Do we have any label that no longer applies?
  2. The labels that require values, are they mapped as functions?
  3. Are the EUI Tokens mapped to core.{EUI Tokens}?
  4. Does the defaultValue match EUI's defString for every token?
  5. Are we using the same values as expected in the props of EuiI18n?

Checklist

Delete any items that are not applicable to this PR.

For maintainers

Closes #99759
Closes #74657

@Bamieh Bamieh added Project:i18n v8.0.0 release_note:skip Skip the PR/issue when compiling release notes auto-backport Deprecated - use backport:version if exact versions are needed v7.15.0 labels Jul 21, 2021
@Bamieh Bamieh marked this pull request as ready for review July 21, 2021 15:17
@Bamieh Bamieh requested review from a team as code owners July 21, 2021 15:17
@kibanamachine
Copy link
Copy Markdown
Contributor

💚 Build Succeeded

Metrics [docs]

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
core 421.7KB 421.7KB +6.0B

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

@Bamieh Bamieh merged commit dbfca5c into elastic:master Jul 22, 2021
@Bamieh Bamieh deleted the i18n/eui_tokens branch July 22, 2021 21:26
@kibanamachine
Copy link
Copy Markdown
Contributor

💔 Backport failed

Status Branch Result
7.x Commit could not be cherrypicked due to conflicts

To backport manually run:
node scripts/backport --pr 106377

Bamieh added a commit that referenced this pull request Jul 26, 2021
# Conflicts:
#	x-pack/plugins/translations/translations/ja-JP.json
#	x-pack/plugins/translations/translations/zh-CN.json
@afharo afharo mentioned this pull request Aug 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

auto-backport Deprecated - use backport:version if exact versions are needed Project:i18n release_note:skip Skip the PR/issue when compiling release notes v7.15.0 v8.0.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[i18n] Generate EUI tokens mapping automatically from i18ntokens.json EUI labels not translating

3 participants