Commit Graph

4135 Commits (0f8e560247834f978afa7706ca9b231962786280)

Author SHA1 Message Date
David Baker 0f8e560247 Add function to display i18n keys in UI
Avoids having to load translations in riot-web tests
2017-05-26 15:29:11 +01:00
David Baker e3e848d09e Fix missing full stop on translation key 2017-05-26 13:19:46 +01:00
David Baker bb344740dd Add test languages file 2017-05-26 13:09:29 +01:00
David Baker 0de0b8954d Trailing whitespace 2017-05-26 12:03:36 +01:00
David Baker e44f3cc709 Fix tests
* Serve translation files from the karma server
 * Port UserSettingsStore to ES6 exports because the test runner
   gets confused by ES6 importing a commonjs module
 * Remove extra spaces in translations strings for MELS
 * Fix 'his/her' back to be 'their'
 * Change test to expect singular 'invitation' for a single person
   (there may be multiple invitations, but IMO this should be
   'rejected n invitations' and we can play with the wording later,
   I don't think the singular is any worse than the plural).
 * set language in the MELS tests (and wait for it to complete)
 * Don't bother setting lang in other tests for now
2017-05-26 11:58:45 +01:00
David Baker dfc8cf3f54 Merge branch 'dbkr/dont_put_src_in_resolve_root' into dbkr/translations 2017-05-25 23:16:39 +01:00
David Baker ba8e37a84e Don't include src in the test resolve root
Don't include src in resolve root for the karma test, as otherwise
modules from react sdk get pulled in instead of npm libraries like
'extend' which breaks everything in really subtle ways.
2017-05-25 23:13:49 +01:00
David Baker 2d6bf5fa91 Remove messages with HTML formatting
The translations strings are not HTML and it gets escaped.
2017-05-25 20:04:28 +01:00
David Baker ab92cc2254 Question marks do not internationalise 2017-05-25 19:55:54 +01:00
David Baker e7fbf889fa Make current language more accurate
Make it reflect reality if it's been taken from the browser langs
by just getting what was saet in counterpart rather than the saved
setting.

Also fix style.
2017-05-25 19:53:27 +01:00
David Baker be4944a4b6 Hopefully get translations with '.'s sorted
attempt 2
2017-05-25 19:43:34 +01:00
David Baker dac6a3360b Oops, don't change these reason strings. 2017-05-25 19:25:06 +01:00
David Baker 43d8ccf128 Hopefully sort out strings with appended '.'s 2017-05-25 19:21:18 +01:00
David Baker c3c2916449 Use array literals 2017-05-25 18:26:42 +01:00
David Baker 6c41be3c14 Missed OKs 2017-05-25 18:23:15 +01:00
David Baker 443ab1add7 Put back default strings on dialogs
But make them work by calling _t in render rather than
getDefaultProps().

Also sort out some 'Warning!' strings
2017-05-25 18:20:48 +01:00
David Baker 9112fc231a More translation string fixups 2017-05-25 17:35:18 +01:00
David Baker 6d67655f66 Add german for Change password 2017-05-25 17:22:04 +01:00
David Baker 85756c78b4 Change to object literal 2017-05-25 17:17:37 +01:00
David Baker feef7d49e9 More tabs 2017-05-25 16:55:24 +01:00
David Baker 3a379d09de Update translations
Actually translate the language dropdown label & add the string.
Remove some unused ones.
2017-05-25 16:52:15 +01:00
David Baker 39dbc4c6e1 Lots of changes to languageHandler
* Replace callbacks with promises
 * Move plain functions to top level
 * De-duplicate bits that fetched languages.json
 * Take full language preference list from the browser if we
   can get it, rather than just the first.
2017-05-25 16:45:32 +01:00
David Baker db45e99536 Remove defaulting here
We already do it in the place this function gets called
2017-05-25 12:09:48 +01:00
David Baker 913723b76b Remove extCounterpart now we only use one instance 2017-05-25 12:08:14 +01:00
David Baker 9fa6e8b1e2 Add us to copyright
As I've now added code to this file
2017-05-25 12:02:05 +01:00
David Baker c7776915f7 Kill off more tabs 2017-05-25 11:45:36 +01:00
David Baker 107024efa8 Unnecessary whitespace 2017-05-25 11:42:19 +01:00
David Baker 5c359e63ab Bulk change counterpart imports
to use languageHandler wrapper func
2017-05-25 11:39:08 +01:00
David Baker ec146c7f45 Switch to stock counterpart
We no longer need the custom counterpart. The things that were
changed in it and reasosn we no lomger need them are:

 1. set separator - this can be done with standard counterpart
 2. ES6 port: this was done to allow importing as _t, but is
    unnecessary with the _t wrapper function in react-sdk
    (although also seems to work fine with
    `import _t from 'counterpart';`)
 3. Fallback to key name: unnecessary with
    `setMissingEntryGenerator` in 0.18, but we've changed to just
    using a fallback locale anyway since No code missing en
    translations should ever make it to the devbelop branch.
 4. Logging on missing translations. Unnecessary with
    `onTranslationNotFound`, but now not used anyway because we
    let missing translations show up in the UI as
    'missing translation'

Bulk changes to imports coming in separate commit for easy reading.
2017-05-25 11:24:17 +01:00
David Baker b677a2002f Minimal UI fixes
Add a label. Make css selector match style. Also fix import.
2017-05-24 14:36:14 +01:00
David Baker aef068b00e Indenting 2017-05-24 14:28:30 +01:00
David Baker c2df23395d Fix up language dropdown
* Read languages from the available ones rather than the config
 * Make the search work (add searchEnabled=true)
 * Move variables to the class since they were populated there
2017-05-24 11:25:06 +01:00
David Baker a95f3252b8 s/tabs/spaces/ 2017-05-24 10:48:10 +01:00
David Baker f412552c2c Fix imports/exports 2017-05-23 18:32:45 +01:00
David Baker cc0924f1c7 Fix imports 2017-05-23 18:16:02 +01:00
MTRNord 9bce417400 fix algorithm ReferenceError 2017-05-23 18:01:30 +01:00
David Baker dd1c50ce80 README formatting
Move translation status to its own heading
2017-05-23 15:30:36 +01:00
David Baker d419c42a4f Squash merge https://github.com/matrix-org/matrix-react-sdk/pull/801 2017-05-23 15:16:31 +01:00
David Baker 46bb29a3af Merge pull request #910 from matrix-org/t3chguy/version_anchor_newtab
Make the linked versions open a new tab, turt2live complained :P
2017-05-23 13:51:40 +01:00
Michael Telatynski a10c2faac1 lets not open an attack vector :)
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-05-23 13:12:21 +01:00
Michael Telatynski b65ba6b080 Merge pull request #919 from matrix-org/rav/delint_slashcommands
Fix lint errors in SlashCommands
2017-05-23 12:10:34 +01:00
David Baker 6d30bc7182 Merge pull request #911 from matrix-org/t3chguy/autofocus_directorysearchbox
autoFocus input box
2017-05-23 09:57:20 +01:00
Richard van der Hoff 5df4b9de16 Fix lint errors in SlashCommands 2017-05-23 09:44:11 +01:00
Richard van der Hoff 26c8540d03 Add in a "verify" slash command to confirm signing keys (#912)
Allows users to send a text string via an alternative channel (like email
or SMS) which Riot can leverage to confirm that the signing keys match.

Effectively removes the tedium of checking keys until a better mechanism
is completed.

Signed-off-by: Kit Sczudlo <kit@kitscz.com>
2017-05-23 09:24:18 +01:00
Luke Barnard f2e526f1d5 Merge pull request #916 from matrix-org/dbkr/use_right_riot_branch
Add right-branch logic to travis test script
2017-05-22 16:57:03 +01:00
David Baker 52d3dd4de9 cd first so we checkout the right repo 2017-05-22 16:48:53 +01:00
David Baker c5a873c316 Remove depth=1 otherwise we won't find the branch 2017-05-22 16:41:43 +01:00
David Baker 77cd9d78db Use develop if no matching branch found 2017-05-22 16:34:15 +01:00
David Baker 2c462bdfb4 Add right-branch logic to travis test script 2017-05-22 16:27:41 +01:00
Michael Telatynski 0d70f796e2 Merge pull request #914 from matrix-org/rav/key_formatting
Group e2e keys into blocks of 4 characters
2017-05-22 12:14:14 +01:00