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

Add fix for localization of not supported message #1427

Closed
wants to merge 13 commits into from
Closed

Add fix for localization of not supported message #1427

wants to merge 13 commits into from

Conversation

tomjohnson916
Copy link
Contributor

Fix for Socrates issue #358.

@heff
Copy link
Member

heff commented Aug 19, 2014

Cool. Socrates isn't a public project, so you gotta keep that in mind when describing these.

Didn't realize we had a translation in there for that already. That's great. This looks good to go.

Languages
=========

Multiple language support allows for users of non-English locales to property interact with the displayed player. Video.js will compile multiple langauge files (see below) and instantiate with a global dictionary of language key/value support. Video.js player instances can be created with per-player language support that amends/overrides this default values. Player instances can also hard-set default languges to values other than English as of version 4.7.
Copy link
Member

Choose a reason for hiding this comment

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

'property interact'

1. During Video.js build process. Once you have your language file created, add it to the /lang folder. Then proceed to build Video.js as normal;

```bash
grunt build
Copy link
Member

Choose a reason for hiding this comment

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

This actually doesn't work. I dropped the language compile from the default build because we wanted it to be optional and really only have our fake spanish translation anyway. So we either need to figure out how we want the grunt process to work, or describe how someone can take the json lang files and add the to a player when they create it.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We should probably do both of those. Adding additional languages to the player when they create it is described by the next point.

Copy link
Member

Choose a reason for hiding this comment

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

Until we have a grunt task this shouldn't say we do. Also have we told people where they can find the existing translations files?

@heff
Copy link
Member

heff commented Aug 19, 2014

It currently looks like we support all those language codes when we don't. Want to make it clear what's currently been translated, where they can find those files, and also how someone can contribute additional translations?

</video>
```

Language Codes
Copy link
Member

Choose a reason for hiding this comment

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

This needs to be clearer. It makes it sound like you can just plug in these language codes and they should work, but the languages need to be defined first.

Also can we tell people how they can contribute translations?


ok(vjs.options.languages[code], 'should exist');
equal(vjs.options.languages[code], data, 'should match');
deepEqual(result[code], vjs.options.languages[code], 'should also match');
Copy link
Member

Choose a reason for hiding this comment

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

Any time you use options.languages, use the string version. options['languages']['code']. I think that will fix the breaking tests.

heff added a commit that referenced this pull request Aug 20, 2014
@heff
Copy link
Member

heff commented Aug 20, 2014

This was merged in and released with 4.7.3

@heff heff closed this Aug 20, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants