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: Localization feature was added #45 #107

Merged
merged 2 commits into from
Dec 21, 2018

Conversation

anton-marchenko
Copy link
Contributor

@anton-marchenko anton-marchenko commented Dec 17, 2018

Description

Localization feature was added. Please, let me know if I need to change something into my PR.
Maybe tests should be added.
Also, maybe this feature must to change current npm version of tui.image-editor.


Thank you for your contribution to TOAST UI product. 🎉 😘 ✨

@seonim-ryu
Copy link
Member

Can one of the admins verify this patch?

@anton-marchenko
Copy link
Contributor Author

anton-marchenko commented Dec 18, 2018

@junghwan-park
@jungeun-cho
@jinwoo-kim-nhn
Anyone, give me feedback, please!

@dongsik-yoo
Copy link
Contributor

oh, there was a deployment of a service on this week. Thanks for your effort and PRs. We'll review them soon.

Copy link
Contributor

@dongsik-yoo dongsik-yoo left a comment

Choose a reason for hiding this comment

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

There are 2 comments to check. Please review them.

* @returns {string}
*/
localize(message) {
return (this._locale[message]) ? this._locale[message] : message;
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this parenthesis necessary? I think it's better using short-circuit evaluation than conditional ternary operator.

return this._locale[message] || message;

Copy link
Contributor Author

@anton-marchenko anton-marchenko Dec 21, 2018

Choose a reason for hiding this comment

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

@dongsik-yoo, It is a good idea. I was refactored it.

@@ -247,12 +247,18 @@ Add dependencies & initialize ImageEditor class with given element to make an im
```javascript
var ImageEditor = require('tui-image-editor');
var blackTheme = require('./js/theme/black-theme.js');
var locale_ru = { // override default English locale to your custom
Copy link
Contributor

@dongsik-yoo dongsik-yoo Dec 21, 2018

Choose a reason for hiding this comment

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

I think we need a document of a full key list. How about /docs/Basic-Tutorial.md?
@jinwoo-kim-nhn Any idea?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@dongsik-yoo, I will make doc today.

@dongsik-yoo
Copy link
Contributor

The documentation issue is on #110 .
Thank you @anton-marchenko . Really great helpful!.

anton-marchenko added a commit to anton-marchenko/am.image-editor that referenced this pull request Dec 21, 2018
dongsik-yoo pushed a commit that referenced this pull request Dec 21, 2018
Docs: #110 - Need a full key list of localization for #107
HerlinMatos pushed a commit to EveryMundo/tui.image-editor that referenced this pull request Jul 2, 2020
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.

None yet

3 participants