Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(path): Keypath should parse if sub path contains spaces. #533

Merged
merged 2 commits into from
Mar 14, 2019

Conversation

exoego
Copy link
Collaborator

@exoego exoego commented Mar 13, 2019

Closes #532 (and its original #502)

I believe "hierarchical key containing space 0x20" like nested.Hello World should be OK, since non-hierarchical key like Hello {0} can contain space.

it('should return replaced string if available', () => {
assert.strictEqual(
i18n.t('Hello {0}', ['kazupon']),
'Hello kazupon'
)
})

@codecov-io
Copy link

Codecov Report

Merging #533 into dev will decrease coverage by 0.43%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##              dev     #533      +/-   ##
==========================================
- Coverage   96.63%   96.19%   -0.44%     
==========================================
  Files           9        9              
  Lines         684      684              
==========================================
- Hits          661      658       -3     
- Misses         23       26       +3
Impacted Files Coverage Δ
src/path.js 84.25% <ø> (-2.78%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 70eedb1...6dd6658. Read the comment docs.

@codecov-io
Copy link

codecov-io commented Mar 13, 2019

Codecov Report

Merging #533 into dev will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##              dev     #533   +/-   ##
=======================================
  Coverage   96.63%   96.63%           
=======================================
  Files           9        9           
  Lines         684      684           
=======================================
  Hits          661      661           
  Misses         23       23
Impacted Files Coverage Δ
src/path.js 87.03% <ø> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 70eedb1...7c7bba5. Read the comment docs.

@exoego exoego force-pushed the keypath-space branch 2 times, most recently from 31323b6 to dc96d28 Compare March 13, 2019 23:56
Copy link
Owner

@kazupon kazupon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good job! 👍
Thanks!

@kazupon kazupon merged commit 640daaf into kazupon:dev Mar 14, 2019
@pr-triage pr-triage bot added the PR: merged label Mar 14, 2019
@exoego exoego deleted the keypath-space branch March 14, 2019 08:18
xuhongbo added a commit to xuhongbo/vue-i18n that referenced this pull request Mar 25, 2019
* ⭐ new(path): Keypath should parse if sub path contains spaces. (kazupon#533) by @exoego

* feat(path): Keypath should parse if sub path contains spaces.

* feat(path): Added test for whitespaces

* 📝 docs(vuepress): pluralization will not work unless you use $tc (kazupon#540) by @lebesnec

* ⭐ new(number): i18n-n functional component (kazupon#541) by @bponomarenko
kazupon pushed a commit that referenced this pull request Mar 27, 2019
closes #531 

* docs: add vuepress zh docs config

* docs(zh/README.md): Translation README.md file

* docs(zh/README.md): Translation installation.md file

* docs: Translation introduction.md file

* docs: Translation started.md file

* docs: 更改称谓

* docs: Translation api/README.md file

* style: values type

* fix: pluralization -> 多元化

* fix: locale translation

* docs: Translation api/formatting file

* docs: Translation guide/pluralization.md file

* fixed: fix type

* docs: All translation completed

* Update vuepress/.vuepress/config.js

参照Vue的规范修正译文中的格式

Co-Authored-By: xuhongbo <[email protected]>

* fix: type

* fix: 区域设置 -> 语言环境

* style: Modify the format including punctuation and spaces

* fix: 修复vuepress config

* Update if not ..., check ... -> 如果没有则

Co-Authored-By: xuhongbo <[email protected]>

* Update 主语前置

Co-Authored-By: xuhongbo <[email protected]>

* Update 完善用语

Co-Authored-By: xuhongbo <[email protected]>

* Update 语义更明确

Co-Authored-By: xuhongbo <[email protected]>

* fix: Correct the format to remove extra spaces

* update: 提示 -> tip

* Update vuepress/zh/api/README.md

Co-Authored-By: xuhongbo <[email protected]>

* 更改主谓

Co-Authored-By: xuhongbo <[email protected]>

* 提高句子的可读性

Co-Authored-By: xuhongbo <[email protected]>

* 提高句子的可读性

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/api/README.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/api/README.md

Co-Authored-By: xuhongbo <[email protected]>

* fix: Fix some keyword errors and various issues

* update: Optimize text for readability

* Update vuepress/zh/guide/formatting.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/formatting.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/formatting.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/formatting.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/formatting.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/formatting.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/formatting.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/formatting.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/formatting.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/formatting.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/formatting.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/hot-reload.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/interpolation.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/interpolation.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/interpolation.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/interpolation.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/interpolation.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/lazy-loading.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/lazy-loading.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/lazy-loading.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/locale.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/locale.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/locale.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/lazy-loading.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/lazy-loading.md

Co-Authored-By: xuhongbo <[email protected]>

* 区域 -> 语言环境, 消息 -> 信息

* Update vuepress/zh/guide/messages.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/messages.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/messages.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/messages.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/number.md

Co-Authored-By: xuhongbo <[email protected]>

* fix: Locale Messages -> 语言环境信息

* 同步源仓库到Fock仓库 (#1)

* ⭐ new(path): Keypath should parse if sub path contains spaces. (#533) by @exoego

* feat(path): Keypath should parse if sub path contains spaces.

* feat(path): Added test for whitespaces

* 📝 docs(vuepress): pluralization will not work unless you use $tc (#540) by @lebesnec

* ⭐ new(number): i18n-n functional component (#541) by @bponomarenko

* Revert "同步源仓库到Fock仓库 (#1)" (#2)

This reverts commit 8f8a88b.

* Update vuepress/zh/guide/pluralization.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/pluralization.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/pluralization.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/sfc.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/sfc.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/sfc.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/sfc.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/sfc.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/sfc.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/sfc.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/sfc.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/sfc.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/sfc.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/sfc.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/guide/sfc.md

Co-Authored-By: xuhongbo <[email protected]>

* style: code style

* Update vuepress/zh/installation.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/installation.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/installation.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/installation.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/installation.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/installation.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/introduction.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/introduction.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/introduction.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/introduction.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/started.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/started.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/started.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/started.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/started.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/legacy/README.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/legacy/README.md

Co-Authored-By: xuhongbo <[email protected]>

* Update vuepress/zh/legacy/README.md

Co-Authored-By: xuhongbo <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants