Compare commits

...
467 Commits
Author SHA1 Message Date
Kim Gardner eda9a0cadf Merge pull request #1594 from coralproject/ignore-user
Fixed Ignore User Error
2018-05-08 18:08:42 -04:00
Wyatt Johnson 763e091e3f Merge branch 'master' into ignore-user 2018-05-08 16:00:56 -06:00
Kim Gardner 02d5a503c4 Merge pull request #1593 from coralproject/reply-missing-postdontagree
Pass postDontAgree to replies
2018-05-08 18:00:33 -04:00
Kim Gardner 13ffeb5889 Merge branch 'master' into reply-missing-postdontagree 2018-05-08 17:49:13 -04:00
Chi Vinh Le b50fde619e Pass postDontAgree to replies 2018-05-08 23:46:33 +02:00
Wyatt Johnson 7348bfc7c9 fixed error 2018-05-08 15:46:24 -06:00
Kim Gardner b27bfda759 Merge pull request #1592 from coralproject/delete-fix
Delete Fix
2018-05-08 17:40:08 -04:00
Wyatt Johnson 1815bd4d75 fix translation copy 2018-05-08 15:30:12 -06:00
Wyatt Johnson 8c29b0f1d4 fix for delete 2018-05-08 15:20:56 -06:00
Kiwi eb66cef4fc Merge pull request #1590 from coralproject/deleted-comments
Exclude deleted comments
2018-05-08 17:11:27 -03:00
Wyatt Johnson 17a0297911 fixed bug.. 2018-05-08 14:03:11 -06:00
Wyatt Johnson a1edbcf974 disallow adding a tag to a deleted comment 2018-05-08 14:03:11 -06:00
Kim Gardner 8c304c762d Merge branch 'deleted-comments' of git+ssh://github.com/coralproject/talk into deleted-comments 2018-05-08 15:49:51 -04:00
Kiwi d64af05093 Merge branch 'master' into deleted-comments 2018-05-08 16:25:05 -03:00
Kiwi 8aff2f69b3 Merge pull request #1591 from coralproject/translation-patch
Update translations.yml
2018-05-08 16:24:53 -03:00
Kiwi 4e9cf2b912 Merge branch 'master' into deleted-comments 2018-05-08 16:24:48 -03:00
Kim Gardner b10141716f Merge branch 'master' into translation-patch 2018-05-08 15:00:58 -04:00
Wyatt Johnson 4973a2021d Merge pull request #1589 from coralproject/notification-fixes
Fixes for notifications
2018-05-08 12:41:33 -06:00
Wyatt Johnson 7b86ec7d0a Update translations.yml 2018-05-08 12:06:52 -06:00
Wyatt Johnson e14af46c68 prevent actions against deleted comments 2018-05-08 12:02:04 -06:00
Wyatt Johnson 74dbfda633 Exclude deleted comments 2018-05-08 11:53:49 -06:00
Wyatt Johnson 44ba77b202 Merge branch 'master' into notification-fixes 2018-05-08 10:38:26 -06:00
Wyatt Johnson 9cee164a15 Merge pull request #1582 from coralproject/settings
Settings Cache Refactor
2018-05-08 10:38:13 -06:00
Wyatt Johnson 231dfe7997 Fixes for notifications 2018-05-08 09:32:14 -06:00
okbel d02bb20333 removing extra 2018-05-08 11:33:39 -03:00
okbel e9c18faf32 Deleted Comment display in Queues 2018-05-08 11:30:33 -03:00
okbel 2f94674b78 Adding CommentDeletedTombstone 2018-05-08 11:08:46 -03:00
Kim Gardner b7b60e6436 Merge branch 'master' into settings 2018-05-07 20:22:26 -04:00
Kim Gardner 778064d756 Merge pull request #1585 from coralproject/docs-fixes
Links, typos, updates for docs
2018-05-07 20:21:34 -04:00
Kim Gardner 57917335cb Merge branch 'master' into settings 2018-05-07 20:21:17 -04:00
Wyatt Johnson 7926c5ccbf Merge branch 'master' into docs-fixes 2018-05-07 18:13:16 -06:00
Kim Gardner 7aad40b0e3 Merge pull request #1587 from coralproject/email
Fixed email in use error
2018-05-07 20:11:09 -04:00
Wyatt Johnson a7c9f01125 fixed bug 2018-05-07 17:59:43 -06:00
Kim Gardner e74b8c9099 Merge branch 'master' into email 2018-05-07 19:55:37 -04:00
Kim Gardner c6a76990f4 Merge pull request #1586 from coralproject/password
Fixed bug with password form
2018-05-07 19:55:21 -04:00
Wyatt Johnson 08a857e07c Fixed email in use error 2018-05-07 17:51:46 -06:00
Wyatt Johnson 10a99aab88 Fixed bug with password form 2018-05-07 17:47:02 -06:00
Wyatt Johnson 15c3a96291 fixed settings 2018-05-07 17:16:52 -06:00
Wyatt Johnson 7b0a7f7d9a Merge branch 'master' into settings 2018-05-07 16:30:21 -06:00
Kim Gardner 926364ad72 Merge pull request #1584 from coralproject/trace
Tracing
2018-05-07 18:30:08 -04:00
Kim Gardner 0e7961aa1c Fix broken links 2018-05-07 17:27:59 -04:00
Kim Gardner 890730a26d Merge branch 'master' into docs-fixes 2018-05-07 17:20:21 -04:00
Kim Gardner a2f5af69b4 Merge branch 'master' into trace 2018-05-07 17:20:16 -04:00
Kim Gardner 0d1f3d1da3 Merge branch 'master' into settings 2018-05-07 17:19:54 -04:00
Kim Gardner 1c7606b651 Merge pull request #1583 from coralproject/security
Node Security Patch
2018-05-07 17:19:27 -04:00
Kim Gardner 7a32bf855d Links, typos, updates for docs 2018-05-07 17:14:43 -04:00
Wyatt Johnson cb50a1e709 updated excemptions 2018-05-07 15:12:37 -06:00
Wyatt Johnson 86595b4dd0 Added exception for metascraper 2018-05-07 15:07:21 -06:00
Wyatt Johnson fa2730a661 Upgraded lodash 2018-05-07 15:06:53 -06:00
Wyatt Johnson 01039aa411 include trace ID in each downstream request 2018-05-07 14:57:51 -06:00
Wyatt Johnson 732ff98f9b fixed test 2018-05-07 14:50:03 -06:00
Wyatt Johnson 3024300a3f Merge branch 'master' into settings 2018-05-07 14:43:07 -06:00
Kim Gardner 7f543f543b Merge pull request #1581 from coralproject/fix-add-email-dialog
Fix Add Email Dialog
2018-05-07 16:36:31 -04:00
Wyatt Johnson c9957add72 Merge branch 'master' into settings 2018-05-07 14:31:09 -06:00
Wyatt Johnson 2b1108cd88 Settings Cache Refactor 2018-05-07 14:27:00 -06:00
Chi Vinh Le 5953ed711a Remove unused code 2018-05-07 22:21:25 +02:00
Chi Vinh Le 8c2733734a Fix Add Email Dialog 2018-05-07 22:16:36 +02:00
Kim Gardner 66bb61ed13 Merge pull request #1580 from coralproject/save-icon
Fix save icon
2018-05-07 15:35:23 -04:00
Kim Gardner f2ea3bdd42 Merge branch 'master' into save-icon 2018-05-07 15:23:11 -04:00
Kim Gardner 71bda42cfb Merge pull request #1577 from coralproject/inputfield-controlled
Fix InputField controlled / uncontrolled mode
2018-05-07 15:23:02 -04:00
Kim Gardner 030b805290 Merge branch 'master' into save-icon 2018-05-07 15:22:09 -04:00
Kim Gardner 1ca7fd58bd Merge branch 'master' into inputfield-controlled 2018-05-07 15:10:45 -04:00
Kim Gardner 7aa31b7cb2 Merge pull request #1571 from coralproject/change-pass-error-bug
Change Password Errors BUG
2018-05-07 15:10:09 -04:00
Chi Vinh Le 4fb511e488 Fix save icon 2018-05-07 21:07:46 +02:00
Kim Gardner e3fa99100b Merge branch 'master' into change-pass-error-bug 2018-05-07 14:59:05 -04:00
Kim Gardner 5aeb16fc99 Merge pull request #1579 from coralproject/bug-fixes
Fixes password validation field for Change Email Dialog
2018-05-07 14:58:56 -04:00
Kim Gardner 21e92b92f3 Merge branch 'master' into bug-fixes 2018-05-07 14:38:55 -04:00
Kim Gardner ecf05d76c0 Merge branch 'master' into inputfield-controlled 2018-05-07 14:37:51 -04:00
Kim Gardner 0f47378ae3 Merge pull request #1576 from coralproject/restore-cancel
Restore cancel buttons
2018-05-07 14:37:00 -04:00
Belen Curcio 46e5efbd55 validation for password input in change email 2018-05-07 15:00:55 -03:00
Chi Vinh Le 06abccabb4 Fix InputField controlled / uncontrolled mode 2018-05-07 18:26:37 +02:00
Chi Vinh Le 565ba2af06 Restore cancel buttons 2018-05-07 17:54:59 +02:00
Wyatt Johnson 802a3bd656 Merge pull request #1573 from coralproject/copy-changes
Copy and bug fixes
2018-05-05 10:04:56 -06:00
Wyatt Johnson 413b6a2a60 Merge branch 'master' into copy-changes 2018-05-05 09:40:50 -06:00
Wyatt Johnson e37346f544 Merge pull request #1572 from coralproject/csv-copy-changes
CSV Copy Changes
2018-05-05 09:40:06 -06:00
Kim Gardner ce92765218 Swap DeletedOn and DeletedFor 2018-05-04 17:40:10 -04:00
Kim Gardner 8b5cb9d96d Copy tweaks 2018-05-04 17:36:05 -04:00
Kim Gardner 7cf991d672 Change copy 2018-05-04 17:03:22 -04:00
Belen Curcio 4312b8d024 bug 2018-05-04 17:49:40 -03:00
Kim Gardner 910beb0f40 Merge pull request #1547 from jerodb/es-translations
Changed general spanish translations
2018-05-04 16:23:04 -04:00
Kim Gardner 810cb222f9 Merge branch 'master' into es-translations 2018-05-04 15:48:56 -04:00
Jero 7a7dcdd7c6 corrections in spanish translations 2018-05-04 16:35:24 -03:00
Kim Gardner 66f1fd7d8a Merge pull request #1569 from coralproject/username-change-fixes
Username Change Fixes
2018-05-04 14:55:44 -04:00
Wyatt Johnson 7362c6c993 Merge branch 'master' into username-change-fixes 2018-05-04 12:09:52 -06:00
Wyatt Johnson a0fbfe4ff4 Merge pull request #1568 from coralproject/forgot-password-change
Forgot password in Change Password
2018-05-04 12:09:38 -06:00
Wyatt Johnson 103543f830 Merge branch 'master' into forgot-password-change 2018-05-04 11:59:10 -06:00
Wyatt Johnson f2d8e49d5b Merge branch 'master' into username-change-fixes 2018-05-04 11:58:46 -06:00
Kim Gardner ade9b99a09 Merge pull request #1570 from coralproject/small-styling-tweaks
GDPR styling tweaks
2018-05-04 13:53:39 -04:00
Wyatt Johnson 6bad9e5306 Fixed bug with button placement 2018-05-04 11:50:37 -06:00
Wyatt Johnson 2a5075f434 Form update 2018-05-04 11:33:20 -06:00
Chi Vinh Le d41984f171 Remove unused field 2018-05-04 19:32:29 +02:00
Chi Vinh Le 4bc8a167a4 Styling tweaks 2018-05-04 19:29:05 +02:00
Wyatt Johnson 9a8f0e98a4 Username Change Fixes 2018-05-04 11:16:53 -06:00
Belén Curcio 05ec8eaee2 Merge branch 'master' into forgot-password-change 2018-05-04 13:40:22 -03:00
Belen Curcio eabcbc36c6 forgot password 2018-05-04 13:34:20 -03:00
Kiwi 822193bba5 Merge pull request #1556 from coralproject/user-detail-enh
User detail refactor
2018-05-04 17:46:52 +02:00
Kim Gardner a008503b52 Merge branch 'master' into user-detail-enh 2018-05-04 09:14:06 -04:00
Kim Gardner 401593afde Merge pull request #1564 from coralproject/email-auth-gdpr
[GDPR] Attach Local Authentication (External Auth)
2018-05-04 09:13:47 -04:00
okbel 7f9c71a802 Merge branch 'master' of github.com:coralproject/talk into email-auth-gdpr
* 'master' of github.com:coralproject/talk:
  fix
  handle confirmed email better
  standardized styles, fixed mutation bug
  password patches
  fixed merge error
  Fix build fail
  Missed an s
  docs patch
  Add feature overview to GDPR docs
  InputField conflict
  moving mutations to /hocs folder
  moving mutations to /hocs folder
  withUpdateEmailAddress in the plugins hoc
2018-05-04 09:46:58 -03:00
okbel f3a3746d6b Merge branch 'email-auth-gdpr' of github.com:coralproject/talk into email-auth-gdpr
* 'email-auth-gdpr' of github.com:coralproject/talk: (51 commits)
  JWT_Audience is listed twice in the docs under required keys
  moved settings loading into try/catch block
  Grammar
  fix
  Fix email subject variables
  Update email copy
  Styling
  Styling
  Updating InputField
  Updating InputField
  added emails around account deletion
  moving mutations to /hocs folder
  typo
  cleaned up config as js instead of json file
  added space
  added durations to configuration file
  Update copy to reflect ability to take action up until account is deleted
  translations
  copy fixes
  added email to final step
  ...
2018-05-04 09:41:22 -03:00
Kim Gardner e51736040f Merge branch 'master' into user-detail-enh 2018-05-03 20:27:16 -04:00
Kim Gardner 9d47d3ff91 Merge pull request #1538 from coralproject/gdpr-email
[GDPR] Change Email (Local)
2018-05-03 20:08:27 -04:00
Wyatt Johnson 15df20e720 fix 2018-05-03 17:57:53 -06:00
Kim Gardner 00b6f0816c Merge branch 'master' into gdpr-email 2018-05-03 19:52:39 -04:00
Wyatt Johnson 949925586f handle confirmed email better 2018-05-03 17:50:53 -06:00
Wyatt Johnson 3fbd655cb8 Merge branch 'master' into email-auth-gdpr 2018-05-03 16:22:43 -06:00
Wyatt Johnson 848ec34e99 Merge pull request #1566 from davisshaver/patch-1
JWT_Audience is listed twice in the docs under required keys
2018-05-03 16:22:06 -06:00
Wyatt Johnson fa66f07db6 standardized styles, fixed mutation bug 2018-05-03 15:58:52 -06:00
Wyatt Johnson ea71b779d2 password patches 2018-05-03 15:51:50 -06:00
Wyatt Johnson b5958d5879 fixed merge error 2018-05-03 15:45:43 -06:00
Kim Gardner 35cefd5570 Fix build fail 2018-05-03 17:42:47 -04:00
Davis Shaver 31cb70fa77 JWT_Audience is listed twice in the docs under required keys 2018-05-03 17:42:10 -04:00
Kim Gardner aee963ce39 Missed an s 2018-05-03 17:34:41 -04:00
Wyatt Johnson bc3ceac61a docs patch 2018-05-03 15:26:50 -06:00
Kim Gardner ae9732c9b4 Merge branch 'gdpr-email' of git+ssh://github.com/coralproject/talk into gdpr-email 2018-05-03 17:19:17 -04:00
Wyatt Johnson c783d15df3 Merge branch 'master' into gdpr-email 2018-05-03 15:18:22 -06:00
Wyatt Johnson e9fdaa1b5a Merge branch 'master' into email-auth-gdpr 2018-05-03 15:13:13 -06:00
Kim Gardner 8bfe344c39 Merge pull request #1536 from coralproject/gdpr-delete
[GDPR] Delete Account
2018-05-03 17:08:55 -04:00
Kim Gardner a20e050559 Merge branch 'gdpr-email' of git+ssh://github.com/coralproject/talk into gdpr-email 2018-05-03 17:08:39 -04:00
Kim Gardner 58b73a4d0a Add feature overview to GDPR docs 2018-05-03 17:08:20 -04:00
Wyatt Johnson 2e7bad3508 moved settings loading into try/catch block 2018-05-03 14:57:11 -06:00
Kim Gardner bfda6a4ce8 Merge branch 'master' into gdpr-email 2018-05-03 16:54:54 -04:00
Kim Gardner 9d448d4185 Merge branch 'master' into gdpr-delete 2018-05-03 16:46:32 -04:00
Kim Gardner 68dfb9cad7 Merge pull request #1559 from coralproject/cli
CLI Fixes
2018-05-03 16:45:52 -04:00
Kim Gardner 3e9d835eb2 Grammar 2018-05-03 16:37:19 -04:00
Wyatt Johnson f5099d94bc fix 2018-05-03 14:32:56 -06:00
Kim Gardner d9806c0ecc Fix email subject variables 2018-05-03 16:23:47 -04:00
Wyatt Johnson edf32a911d Merge branch 'master' into cli 2018-05-03 14:20:05 -06:00
Kim Gardner 903b74cb31 Update email copy 2018-05-03 15:43:22 -04:00
okbel 070ecbaafc translations 2018-05-03 16:30:15 -03:00
okbel f9f7855775 Merge branch 'email-auth-gdpr' of github.com:coralproject/talk into email-auth-gdpr
* 'email-auth-gdpr' of github.com:coralproject/talk:
  added docs
  Added TALK_ prefix to constants RECAPTCHA_WINDOW and RECAPTCHA_INCORRECT_TRIGGER
  cleaned up refs to passwor dhash
  RECAPTCHA_WINDOW and RECAPTCHA_INCORRECT_TRIGGER now can be set with env vars
2018-05-03 16:25:17 -03:00
okbel 438c515d2f moving mutations to /hocs folder 2018-05-03 16:06:28 -03:00
okbel 65aa90904a Styling 2018-05-03 16:00:25 -03:00
okbel 140ef3eb5e Styling 2018-05-03 15:57:00 -03:00
okbel 467aecf0ee Merge branch 'gdpr-delete' of github.com:coralproject/talk into gdpr-delete
* 'gdpr-delete' of github.com:coralproject/talk:
  added emails around account deletion
2018-05-03 15:48:49 -03:00
okbel 10dbce55ba Updating InputField 2018-05-03 15:45:19 -03:00
okbel 6cfebb408f Updating InputField 2018-05-03 15:42:28 -03:00
okbel 29a840fe06 InputField conflict 2018-05-03 15:38:17 -03:00
Wyatt Johnson 690e6752ee added emails around account deletion 2018-05-03 12:29:05 -06:00
okbel 788cf25fa5 moving mutations to /hocs folder 2018-05-03 15:20:07 -03:00
okbel 687d0555c8 moving mutations to /hocs folder 2018-05-03 15:18:09 -03:00
okbel bc9e76c889 Merge branch 'gdpr-delete' of github.com:coralproject/talk into gdpr-delete
* 'gdpr-delete' of github.com:coralproject/talk:
  typo
  cleaned up config as js instead of json file
  added space
  added durations to configuration file
  Update copy to reflect ability to take action up until account is deleted
  added docs
  Added TALK_ prefix to constants RECAPTCHA_WINDOW and RECAPTCHA_INCORRECT_TRIGGER
  RECAPTCHA_WINDOW and RECAPTCHA_INCORRECT_TRIGGER now can be set with env vars
2018-05-03 15:17:04 -03:00
okbel f173f495a5 moving mutations to /hocs folder 2018-05-03 15:15:58 -03:00
okbel 2b52f07c45 Merge branch 'gdpr-email' of github.com:coralproject/talk into gdpr-email
* 'gdpr-email' of github.com:coralproject/talk:
  added docs
  Added TALK_ prefix to constants RECAPTCHA_WINDOW and RECAPTCHA_INCORRECT_TRIGGER
  RECAPTCHA_WINDOW and RECAPTCHA_INCORRECT_TRIGGER now can be set with env vars
  Update version to 4.4.0
2018-05-03 15:13:09 -03:00
okbel 8a9af89699 withUpdateEmailAddress in the plugins hoc 2018-05-03 15:12:23 -03:00
Kim Gardner 64cb665124 typo 2018-05-03 14:00:07 -04:00
Wyatt Johnson df29e610b3 cleaned up config as js instead of json file 2018-05-03 11:40:55 -06:00
Wyatt Johnson 20c5804559 added space 2018-05-03 11:38:23 -06:00
Wyatt Johnson 06b08756e7 added durations to configuration file 2018-05-03 11:36:34 -06:00
Kim Gardner e23933e9df Merge branch 'master' into email-auth-gdpr 2018-05-03 13:28:34 -04:00
Kim Gardner e1f6dc49a8 Merge branch 'master' into gdpr-email 2018-05-03 13:18:25 -04:00
Kim Gardner 8caf995517 Merge branch 'master' into gdpr-delete 2018-05-03 13:17:44 -04:00
Kim Gardner 287cff289b Update copy to reflect ability to take action up until account is deleted 2018-05-03 13:04:05 -04:00
Wyatt Johnson 368b6fb847 Merge pull request #1565 from cristiandean/recaptcha-env
Set RECAPTCHA_WINDOW and RECAPTCHA_INCORRECT_TRIGGER by env vars
2018-05-03 10:58:16 -06:00
okbel 3b5a45ec01 translations 2018-05-03 13:45:33 -03:00
Wyatt Johnson 0e20ddb2fd added docs 2018-05-03 10:40:06 -06:00
okbel f6d3f4cb14 translations 2018-05-03 13:32:52 -03:00
Wyatt Johnson 375f1bb6b1 copy fixes 2018-05-03 10:09:36 -06:00
Wyatt Johnson 6485b1f080 added email to final step 2018-05-03 10:09:36 -06:00
Cristian 8b35f2300a Added TALK_ prefix to constants RECAPTCHA_WINDOW and RECAPTCHA_INCORRECT_TRIGGER 2018-05-03 13:06:47 -03:00
Kim Gardner 0caa82c1c4 Typo 2018-05-03 11:59:27 -04:00
okbel 94b3ab4ac8 translations 2018-05-03 12:59:03 -03:00
Wyatt Johnson 8fee07a3f8 cleaned up refs to passwor dhash 2018-05-03 09:58:49 -06:00
Cristian 12701942c6 RECAPTCHA_WINDOW and RECAPTCHA_INCORRECT_TRIGGER now can be set with env vars 2018-05-03 12:57:51 -03:00
Wyatt Johnson bab9347d06 adjusted copy 2018-05-03 09:53:24 -06:00
Kim Gardner b995da8301 Unbold a word 2018-05-03 11:37:48 -04:00
Wyatt Johnson 51847cf955 Updated copy for delete 2018-05-03 09:26:48 -06:00
Wyatt Johnson ee0f734705 cleaned up download mutations 2018-05-03 09:13:44 -06:00
Wyatt Johnson 87d0c99558 moved hoc's into plugin 2018-05-03 08:59:26 -06:00
Kim Gardner 225a04fed1 Copy fixes 2018-05-03 10:53:16 -04:00
Wyatt Johnson a42135c3bb merge bug 2018-05-03 08:39:34 -06:00
okbel a9132c1353 stream fragment 2018-05-03 11:07:58 -03:00
okbel fff6e1c231 Review changes 2018-05-03 10:24:43 -03:00
Kim Gardner 0791a2731b Merge branch 'master' into gdpr-email 2018-05-02 22:18:26 -04:00
okbel aa6c9890b2 Merge branch 'email-auth-gdpr' of github.com:coralproject/talk into email-auth-gdpr
* 'email-auth-gdpr' of github.com:coralproject/talk:
  Update version to 4.4.0
2018-05-02 21:02:10 -03:00
okbel a649bd8252 done - but translations 2018-05-02 21:01:08 -03:00
okbel 59cac9db8b Adding reducer 2018-05-02 20:58:34 -03:00
okbel 478770f6c6 Changes 2018-05-02 20:41:32 -03:00
Belén Curcio 262c68ca8f Merge branch 'master' into email-auth-gdpr 2018-05-02 20:14:32 -03:00
okbel e409695979 Merge branch 'gdpr-delete' of github.com:coralproject/talk into gdpr-delete
* 'gdpr-delete' of github.com:coralproject/talk:
  Update version to 4.4.0
2018-05-02 20:09:49 -03:00
okbel ccb62263c1 checking me null 2018-05-02 20:08:29 -03:00
Wyatt Johnson 74acf73396 Merge branch 'master' into gdpr-delete 2018-05-02 17:00:51 -06:00
okbel cdae2796a5 Changes 2018-05-02 18:48:52 -03:00
okbel 09d20257ac Changes 2018-05-02 18:46:41 -03:00
okbel 1bf440c4a6 Changes 2018-05-02 18:43:06 -03:00
okbel 3b2deeb007 Checking if email verification is required 2018-05-02 18:35:15 -03:00
okbel b04fc1faf8 wip 2018-05-02 18:15:04 -03:00
Wyatt Johnson db11dc4928 Merge pull request #1563 from coralproject/version-4-4-0
Update version to 4.4.0
2018-05-02 14:37:07 -06:00
okbel bfb4b790d4 Adding error 2018-05-02 16:49:56 -03:00
okbel c7db780582 Updating the cache with data from the fragment 2018-05-02 16:46:20 -03:00
Kim Gardner 45c75f3c48 Update version to 4.4.0 2018-05-02 15:22:17 -04:00
Wyatt Johnson c1492d1065 Added incorrect password error 2018-05-02 13:22:15 -06:00
Wyatt Johnson 0159918049 docs updates 2018-05-02 13:04:17 -06:00
Kim Gardner cb9b02c180 remove profile-settings from gitignore 2018-05-02 14:20:19 -04:00
okbel c8e5678c9c Using fragments :) 2018-05-02 14:18:40 -03:00
okbel 48a78735bd Importing translations 2018-05-02 14:11:11 -03:00
okbel 8dcaf8ea4c Moving the translations too 2018-05-02 14:08:29 -03:00
okbel 58cc078d25 Moving gdpr to talk-plugin-profile-data 2018-05-02 14:03:21 -03:00
okbel c57acddfc0 Moving gdpr to talk-plugin-profile-data 2018-05-02 14:01:03 -03:00
okbel 780bd42ceb Moving gdpr to talk-plugin-local-auth 2018-05-02 13:49:23 -03:00
okbel b2f37733e8 Sending correct parameters 2018-05-02 13:39:08 -03:00
okbel 6c0c76328f merge conflict 2018-05-02 13:28:03 -03:00
Wyatt Johnson 7c16ae2220 cli fix 2018-05-02 10:17:41 -06:00
Wyatt Johnson 26438d0b90 patched json 2018-05-02 09:59:10 -06:00
Wyatt Johnson ddaa8eb858 Merge branch 'master' into gdpr-delete 2018-05-02 09:58:04 -06:00
Kim Gardner 72ca9b38bb Merge branch 'master' into gdpr-email 2018-05-02 11:21:11 -04:00
Kim Gardner 26b9dcdaa9 Merge branch 'master' into cli 2018-05-02 11:13:42 -04:00
Kim Gardner 9dc040f6d2 Merge pull request #1560 from mkonikov/rich-text-docs
Add note explaining possible plugin conflict
2018-05-02 11:13:10 -04:00
Mendel Konikov 018addc6ad Remove space to correct markdown link formatting 2018-05-01 20:37:42 -04:00
Mendel Konikov c3d01be0df Add note explaining possible plugin conflict 2018-05-01 20:34:42 -04:00
Wyatt Johnson d6828c5ef4 cli fixes 2018-05-01 16:27:47 -06:00
Kim Gardner 17a63c0bf9 Merge branch 'master' into gdpr-email 2018-05-01 17:50:27 -04:00
Kim Gardner a8dd1ec38b Merge pull request #1557 from coralproject/indexes
Index Creation Patch
2018-05-01 17:48:48 -04:00
Wyatt Johnson d12310026b Fixes to shema loading 2018-05-01 15:41:05 -06:00
okbel 864e06222c Adding input 2018-05-01 17:59:31 -03:00
okbel d5fa7455e5 Adding InputField 2018-05-01 17:55:01 -03:00
okbel 49fcc1ea43 Adding missing slot 2018-05-01 17:30:57 -03:00
okbel ff7ee2aefc Updating cache 2018-05-01 17:18:58 -03:00
okbel 5eead8b7ee Adding AccountDeletionRequestedSign.js 2018-05-01 16:32:42 -03:00
okbel 9b4d650427 Wip: mutations, styles and functionality 2018-05-01 16:18:37 -03:00
okbel 5c806174bb Adding withRequestAccountDeletion, withRequestDownloadLink, withCancelAccountDeletion 2018-05-01 15:51:56 -03:00
okbel 3bb91f6833 Adding withRequestAccountDeletion, withRequestDownloadLink, withCancelAccountDeletion 2018-05-01 15:43:10 -03:00
Wyatt Johnson b014225b73 fixes for index creation 2018-05-01 12:02:39 -06:00
Kim Gardner 92d32aaa8d Merge branch 'master' into user-detail-enh 2018-05-01 13:41:10 -04:00
Kim Gardner 7717462300 Merge pull request #1555 from coralproject/configure-enh
Configure enhancements
2018-05-01 13:32:38 -04:00
Kim Gardner 06682225c8 Fix error message 2018-05-01 13:25:33 -04:00
Kim Gardner 3145411921 Merge branch 'master' into configure-enh 2018-05-01 13:23:14 -04:00
okbel bd21d9a1a1 fix b 2018-05-01 14:19:43 -03:00
okbel f4cb16e56e styles wip 2018-05-01 14:14:43 -03:00
okbel 867523140c Adding StepProgress component, and all the steps 2018-05-01 14:09:43 -03:00
Kim Gardner a12e7a0e90 Merge pull request #1533 from coralproject/gdpr-username
[GDPR] Username Change
2018-05-01 12:55:24 -04:00
Kim Gardner 9c809f99c5 Merge branch 'master' into gdpr-email 2018-05-01 12:51:05 -04:00
Kim Gardner 16a21a0562 Merge branch 'master' into gdpr-username 2018-05-01 12:42:12 -04:00
Chi Vinh Le e0dad39600 Merge branch 'configure-enh' of ssh://github.com/coralproject/talk into configure-enh 2018-05-01 18:14:34 +02:00
Chi Vinh Le 74821a4d4c Readd save dialog on section change 2018-05-01 18:14:07 +02:00
Kiwi 41b3245bf4 Merge branch 'master' into configure-enh 2018-05-01 17:58:56 +02:00
Kiwi 40b157206a Merge branch 'master' into user-detail-enh 2018-05-01 17:58:02 +02:00
Kim Gardner 71cdd146fa Merge pull request #1554 from coralproject/change-config-tab-copy
Update copy for stream Configure tab
2018-05-01 11:39:33 -04:00
Chi Vinh Le d07b77b8f7 Remove forgotten console.log 2018-05-01 16:49:44 +02:00
Chi Vinh Le b2988e540e Move mutation logic to coral-admin 2018-05-01 16:48:52 +02:00
Chi Vinh Le 68b1670a55 Prevent reload or closing tab or window with pending data 2018-05-01 16:33:21 +02:00
Chi Vinh Le 2af3a94ce4 No dialog when switching sections 2018-05-01 16:29:40 +02:00
Chi Vinh Le fd3f5e5116 Cleanup leave hook 2018-05-01 16:19:47 +02:00
Chi Vinh Le e8cd938b65 Move next route out of state 2018-05-01 16:18:17 +02:00
Chi Vinh Le 9310a4734d Fix viewing/editing empty org contact email 2018-05-01 16:16:41 +02:00
Andrew Losowsky 8d1d96884e small wording change
changed 'Customize' for 'Change' (more plain English)
2018-05-01 09:08:58 -04:00
okbel 876eb1e413 wip 2018-05-01 00:17:57 -03:00
okbel 720089d3c2 Initial Delete 2018-04-30 23:45:13 -03:00
okbel bbd02dda81 Finished with crossed steps 2018-04-30 23:14:47 -03:00
okbel f5563c80b1 Merge branch 'gdpr-username' of github.com:coralproject/talk into gdpr-email
* 'gdpr-username' of github.com:coralproject/talk:
  ChangeUsername instead of setUsername
2018-04-30 22:04:18 -03:00
okbel 4cd7ad9c33 ChangeUsername instead of setUsername 2018-04-30 20:20:58 -03:00
okbel 227e52c16e Merge branch 'gdpr-username' of github.com:coralproject/talk into gdpr-email
* 'gdpr-username' of github.com:coralproject/talk:
  Adding translations
  Catching if username cant be updated
  fixes for tests
  fixed tests
  Fixed bug in mutation
2018-04-30 20:14:15 -03:00
okbel 5dbf379bde Merge branch 'gdpr-username' of github.com:coralproject/talk into gdpr-username
* 'gdpr-username' of github.com:coralproject/talk:
  fixes for tests
  fixed tests
2018-04-30 20:04:09 -03:00
okbel cdb392cd0e Adding translations 2018-04-30 20:03:01 -03:00
okbel ad342c4bb3 Catching if username cant be updated 2018-04-30 19:56:53 -03:00
Kim Gardner 4212f0b014 Update copy 2018-04-30 18:22:35 -04:00
Wyatt Johnson b42d325cb0 fixes for tests 2018-04-30 16:13:48 -06:00
Wyatt Johnson 7a0c9c85bc fixed tests 2018-04-30 15:59:35 -06:00
Wyatt Johnson 31f0cb12b3 Fixed bug in mutation 2018-04-30 15:43:12 -06:00
Wyatt Johnson 457f305062 Merge branch 'master' into gdpr-email 2018-04-30 14:10:52 -06:00
Kim Gardner b31b01bc50 Merge branch 'master' into gdpr-username 2018-04-30 16:01:58 -04:00
Kim Gardner 743327a53b Merge pull request #1543 from coralproject/remove-profile-settings-refs
Remove refs to talk-plugin-profile-settings
2018-04-30 16:01:35 -04:00
okbel 691bfa4e30 Passing Dialog content 2018-04-30 16:53:05 -03:00
okbel 58108f257f Addin g withUpdateEmailAddress 2018-04-30 16:28:08 -03:00
Wyatt Johnson ec8f42496d Merge branch 'master' into remove-profile-settings-refs 2018-04-30 13:21:04 -06:00
okbel 35e8c005f3 WIP: Steps 2018-04-30 16:20:09 -03:00
Wyatt Johnson a5f94360b3 Merge pull request #1546 from jerodb/plugin-auth-translation
Added translation for the talk-plugin-auth's password error
2018-04-30 13:18:46 -06:00
okbel 1574dabd69 Merge branch 'gdpr-email' of github.com:coralproject/talk into gdpr-email
* 'gdpr-email' of github.com:coralproject/talk:
  fixed typo
  nightwatchjs.org doesn't support HTTPS
  added viewing and sorting spanish translations
  Added email.password_reset.subject translation
2018-04-30 16:04:44 -03:00
okbel be86b70b24 WIP: Steps 2018-04-30 16:01:35 -03:00
Belén Curcio 05a6399638 Merge branch 'master' into gdpr-email 2018-04-30 15:44:46 -03:00
Belén Curcio dbb9686074 Merge branch 'master' into remove-profile-settings-refs 2018-04-30 14:45:14 -03:00
Kim Gardner 4e10a23ad0 Merge branch 'master' into plugin-auth-translation 2018-04-30 13:43:57 -04:00
Kim Gardner e48f07f4dd Merge pull request #1548 from jerodb/password_reset-subject-translation
Added translation for email's subject
2018-04-30 13:19:27 -04:00
Kim Gardner 1143f74ba8 Merge branch 'master' into password_reset-subject-translation 2018-04-30 12:58:54 -04:00
Kim Gardner bc5a045886 Merge pull request #1549 from jerodb/viewing-sorting-translations-es
Changed spanish translations for the viewing options list
2018-04-30 12:58:20 -04:00
okbel 8df9a1e66e wip 2018-04-30 13:47:15 -03:00
Kim Gardner 4130ad5217 Merge branch 'master' into viewing-sorting-translations-es 2018-04-30 12:43:48 -04:00
Wyatt Johnson 1e8c3de221 Merge pull request #1550 from theel0ja/patch-1
nightwatchjs.org doesn't support HTTPS
2018-04-30 10:23:55 -06:00
Kim Gardner fdf5ca1d7a Merge branch 'master' into patch-1 2018-04-30 11:15:36 -04:00
Kim Gardner 612230ad0c Merge pull request #1551 from theel0ja/patch-2
fixed typo
2018-04-30 11:15:03 -04:00
okbel e67d68267c Adding Change Email 2018-04-29 22:00:42 -03:00
okbel 9419b67fff Merge branch 'gdpr-username' of github.com:coralproject/talk into gdpr-email
* 'gdpr-username' of github.com:coralproject/talk: (36 commits)
  performing mutation
  Spanish translations
  More translations
  No empty username, no same username
  Decrease font-size and padding in Flag Comment popup a bit.
  Translations
  Adding translations
  Adding translations
  InputField refactor
  wip more validations
  Full functionality, needs translation
  Adding Dialog, styles and more
  Use email vs e-mail
  Small fix
  Adding withChangeUsername to plugin hocs, wip and more
  Introducing profileHeader slot
  Adding a notification after saving
  Fix lint
  Add missing ctx arg for CLI users create
  final refactor, done.
  ...
2018-04-29 20:29:54 -03:00
Elias Ojala edbd21f25f fixed typo 2018-04-28 23:02:29 +03:00
Elias Ojala f42e9dab4c nightwatchjs.org doesn't support HTTPS 2018-04-28 12:27:15 +03:00
Jero 90c235d9d1 Added the password error translation 2018-04-27 10:52:38 -03:00
Jero 3dbe59fd27 Translation for talk-plugin-auth password_error added 2018-04-27 10:25:59 -03:00
Jero 885f186e39 added viewing and sorting spanish translations 2018-04-26 19:19:06 -03:00
Kim Gardner 12d48d6248 Merge branch 'master' into gdpr-username 2018-04-26 18:02:13 -04:00
Jero 878cbb9195 Added email.password_reset.subject translation 2018-04-26 18:35:45 -03:00
Jero b8d435fb07 Added missing spanish translations 2018-04-26 18:29:25 -03:00
okbel a7e09352ef performing mutation 2018-04-26 18:09:27 -03:00
okbel 0a0bbbb3ce Spanish translations 2018-04-26 17:55:44 -03:00
okbel ad5c51c486 More translations 2018-04-26 17:53:02 -03:00
okbel ab02b1b6ca No empty username, no same username 2018-04-26 17:00:08 -03:00
Kim Gardner 2d6a6d652e Merge pull request #1545 from conversario/popupmenu-style
Decrease font-size and padding in Report comment popup
2018-04-26 13:36:26 -04:00
Kim Gardner 287d0bf538 Merge branch 'master' into popupmenu-style 2018-04-26 12:47:56 -04:00
Fabian Neumann 8643b1fbf2 Decrease font-size and padding in Flag Comment popup a bit. 2018-04-26 17:52:03 +02:00
okbel ba7de6bf81 Translations 2018-04-26 11:25:40 -03:00
okbel 6495c0a16b Adding translations 2018-04-26 11:19:25 -03:00
okbel 2db9489646 Adding translations 2018-04-26 11:15:35 -03:00
okbel 8f6691f7a4 InputField refactor 2018-04-26 11:15:18 -03:00
Kim Gardner dd9a9d5882 Remove refs to talk-plugin-profile-settings 2018-04-25 15:30:40 -04:00
okbel cbdd1921ec Merge branch 'gdpr-username' of github.com:coralproject/talk into gdpr-username
* 'gdpr-username' of github.com:coralproject/talk:
  Use email vs e-mail
  Small fix
2018-04-25 13:36:14 -03:00
okbel aefac2056e wip more validations 2018-04-25 13:36:00 -03:00
Kim Gardner 2fa81111ba Merge branch 'master' into gdpr-username 2018-04-25 12:34:15 -04:00
Kim Gardner 2048a2cc7f Merge pull request #1541 from coralproject/docs-formatting
Small docs fix
2018-04-25 12:33:47 -04:00
okbel 5a0a30fc12 Merge branch 'gdpr-username' of github.com:coralproject/talk into gdpr-username
* 'gdpr-username' of github.com:coralproject/talk:
  Fix lint
  Add missing ctx arg for CLI users create
2018-04-25 13:13:38 -03:00
Belén Curcio 358d56c2cf Merge branch 'master' into docs-formatting 2018-04-25 13:10:55 -03:00
Belén Curcio 6376fe21cb Merge pull request #1542 from coralproject/grammar-fixes
Use email vs e-mail
2018-04-25 13:10:29 -03:00
okbel a79d71da7d Full functionality, needs translation 2018-04-25 12:53:03 -03:00
okbel 754b5c5fbb Adding Dialog, styles and more 2018-04-25 12:20:51 -03:00
Kim Gardner 2bc6687957 Use email vs e-mail 2018-04-25 11:09:54 -04:00
Kim Gardner 3bd2d0b3fc Small fix 2018-04-24 17:17:57 -04:00
Kim Gardner 93f102e9c1 Merge branch 'master' into gdpr-username 2018-04-24 14:59:33 -04:00
Kim Gardner d483b13aa8 Merge pull request #1539 from clintabrown/fix-cli-user-create
Fix CLI users create task
2018-04-24 14:12:08 -04:00
okbel 89114ecd13 Adding withChangeUsername to plugin hocs, wip and more 2018-04-24 14:13:24 -03:00
Kim Gardner 47a860c09d Merge branch 'master' into fix-cli-user-create 2018-04-24 13:07:38 -04:00
okbel 01ad397561 Merge branch 'master' of github.com:coralproject/talk into gdpr-username
* 'master' of github.com:coralproject/talk:
  Adding a notification after saving
  final refactor, done.
  Adding translations, en, es, more
  Validation finished
  as InputField
  fix for large icons, reorder of styles
  changes
  validations
  Adding withChangePassword to mutations and plugins API, styles
  Frontend for Change Password
2018-04-24 13:59:21 -03:00
okbel 15817712c0 Introducing profileHeader slot 2018-04-24 13:58:28 -03:00
Kim Gardner 7f506f3fea Merge pull request #1532 from coralproject/gdpr-password
[GDPR] Password Change
2018-04-24 12:55:14 -04:00
okbel 9df9b9fa46 Merge branch 'master' of github.com:coralproject/talk into gdpr-username
* 'master' of github.com:coralproject/talk:
  Fix typo
  Renamed nl to nlTA. Sorted ta.register calls
  added direct download mutation
  adjusted download to include all comments
  Added NL translation for Moment. Also, sorted locale imports alphabetically.
2018-04-24 13:47:55 -03:00
okbel f910d7023c Merge branch 'master' of github.com:coralproject/talk into gdpr-password
* 'master' of github.com:coralproject/talk:
  Fix typo
  added direct download mutation
  adjusted download to include all comments
2018-04-24 13:43:24 -03:00
okbel 37919a11ab Adding a notification after saving 2018-04-24 13:39:13 -03:00
Clint Brown f83d6246cb Fix lint 2018-04-24 17:34:14 +10:00
Clint Brown ea96b7b7ce Merge branch 'master' into fix-cli-user-create 2018-04-24 17:23:57 +10:00
Clint Brown a444d98733 Add missing ctx arg for CLI users create 2018-04-24 17:17:48 +10:00
okbel eaf0df9573 final refactor, done. 2018-04-24 00:45:51 -03:00
okbel 5e3fc2b22a Adding translations, en, es, more 2018-04-24 00:20:10 -03:00
okbel 1d2be0cef0 Validation finished 2018-04-23 23:56:54 -03:00
okbel 493c4689c2 as InputField 2018-04-23 23:34:16 -03:00
Kim Gardner 51e4bcfef9 Merge pull request #1493 from coralproject/gdpr-download
[GDPR] Download My Comments
2018-04-23 14:39:18 -04:00
okbel 76ede5c541 fix for large icons, reorder of styles 2018-04-23 15:32:21 -03:00
okbel f4f0400c4d Merge branch 'gdpr-password' of github.com:coralproject/talk into gdpr-password
* 'gdpr-password' of github.com:coralproject/talk:
  Renamed nl to nlTA. Sorted ta.register calls
  Added NL translation for Moment. Also, sorted locale imports alphabetically.
2018-04-23 15:23:14 -03:00
okbel 9bb3a9f7cb changes 2018-04-23 15:22:50 -03:00
Kim Gardner 89711b2010 Merge branch 'master' into gdpr-password 2018-04-23 12:07:52 -04:00
Kim Gardner 61ec6c886c Merge branch 'master' into gdpr-download 2018-04-23 11:00:53 -04:00
Kim Gardner 6dd0dd41e0 Merge pull request #1535 from sanoma/master
Fix Dutch locale for Moment.JS
2018-04-23 11:00:38 -04:00
Kim Gardner c936a6ff2c Fix typo 2018-04-23 10:59:23 -04:00
D. Luijten 18e8f9c3dc Merge branch 'hotfix/fix_dutch_moment_locale'
* hotfix/fix_dutch_moment_locale:
  Renamed nl to nlTA. Sorted ta.register calls
2018-04-23 16:47:08 +02:00
D. Luijten c103a0c481 Renamed nl to nlTA.
Sorted ta.register calls
2018-04-23 16:46:42 +02:00
okbel 21f942a219 validations 2018-04-23 11:43:40 -03:00
Kim Gardner 89546c4066 Merge branch 'master' into master 2018-04-23 10:23:57 -04:00
okbel b5dd63aec1 Adding withChangePassword to mutations and plugins API, styles 2018-04-23 10:32:56 -03:00
okbel bc71366fd5 Frontend for Change Password 2018-04-20 18:23:46 -03:00
Wyatt Johnson c27c60346e fixed client building 2018-04-20 13:27:03 -06:00
Wyatt Johnson 9471026162 Referenced new plugin 2018-04-20 13:20:55 -06:00
Wyatt Johnson 8e21857a52 added new plugin to registry 2018-04-20 13:20:11 -06:00
Wyatt Johnson 10d27357f4 reorganized 2018-04-20 13:17:57 -06:00
Wyatt Johnson 7d644115d1 cleanups 2018-04-20 13:11:35 -06:00
Wyatt Johnson 7fa10b1a9a Merge branch 'master' into gdpr-email 2018-04-20 12:07:23 -06:00
Wyatt Johnson ea0be250c1 Merge branch 'master' into gdpr-delete 2018-04-20 12:07:10 -06:00
Wyatt Johnson 685bd02758 Merge branch 'master' into gdpr-username 2018-04-20 12:06:52 -06:00
Wyatt Johnson aa80f47b1c Merge branch 'master' into gdpr-password 2018-04-20 12:03:59 -06:00
Wyatt Johnson 84ebd1b66f Merge branch 'master' into gdpr-download 2018-04-20 12:00:22 -06:00
Wyatt Johnson 2a3b8e511c Merge pull request #1496 from coralproject/organization-contact
Organization Email Contact
2018-04-20 11:58:53 -06:00
Wyatt Johnson 80f219513b fixed e2e 2018-04-20 11:39:34 -06:00
Wyatt Johnson 7d4102e3aa Merge branch 'master' into organization-contact 2018-04-20 10:57:47 -06:00
Wyatt Johnson 3b657e120f fix for logger 2018-04-20 10:52:03 -06:00
Wyatt Johnson a477af3b4f Merge branch 'master' into gdpr-download 2018-04-20 10:33:29 -06:00
Wyatt Johnson d4fdb20436 Merge branch 'master' into master 2018-04-20 10:31:32 -06:00
Wyatt Johnson 5a88fda511 Merge pull request #1537 from sanoma/fix_translation_staff
Added translation to staff label in comment stream.
2018-04-20 10:31:15 -06:00
Wyatt Johnson e0ebbf5119 Merge branch 'master' into gdpr-delete 2018-04-20 10:30:29 -06:00
Wyatt Johnson 3129a6615f added direct download mutation 2018-04-20 09:37:20 -06:00
Wyatt Johnson 2e013c33ac GDPR Email Support
- Email and password can be used to create a new local profile
- Email can be changed with accounts that already have a local profile
2018-04-19 17:19:14 -06:00
Wyatt Johnson 5c5cde535e Merge branch 'organization-contact' into gdpr-email 2018-04-19 17:06:13 -06:00
Wyatt Johnson 16838f0fa1 Merge branch 'organization-contact' into gdpr-email 2018-04-19 17:03:56 -06:00
Wyatt Johnson 68461308c6 pull ignored users from db 2018-04-19 13:37:14 -06:00
okbel 99cb9da0b1 Merge branch 'organization-contact' of github.com:coralproject/talk into organization-contact
* 'organization-contact' of github.com:coralproject/talk: (48 commits)
  Change to UserHistory in UserDetail.js
  Add system withheld status to InactiveCommentLabel
  fix e2e test
  removed deprecated not logged in ui for profile tab
  fixed proptype missing validation
  icon patch
  Adds Author Index for Comments
  don't show profile tab if user is logged out
  version bump
  Removed storage check
  logic cleanup
  cleanups around storageAccess
  Storage Fixes
  adjusted env
  adjusted index creation and managemen
  autocapitalize off for the username field
  added beforeTest to wait for mongoose to be ready
  small fixes
  Jest for server
  Authors cannot see their own status history
  ...
2018-04-19 14:07:51 -03:00
okbel 84b373ed95 Validation Added 2018-04-19 14:07:24 -03:00
Wyatt Johnson 67405937ed adjusted download to include all comments 2018-04-19 10:48:48 -06:00
Wyatt Johnson b60e62f976 small fixes for db logic 2018-04-19 09:21:12 -06:00
Wyatt Johnson b4e2712dfb Merge branch 'master' into fix_translation_staff 2018-04-19 08:59:29 -06:00
Tibo Beijen 43fa0d2b58 Added translation to staff label in comment stream. 2018-04-19 10:43:41 +02:00
Wyatt Johnson 8e34fd1925 implemented tombstoning 2018-04-18 17:22:39 -06:00
Kim Gardner d55d914fb4 Merge branch 'master' into gdpr-download 2018-04-18 17:27:01 -04:00
Kim Gardner 31a8de852c Merge branch 'master' into organization-contact 2018-04-18 17:01:13 -04:00
Kim Gardner 825851f603 Merge branch 'master' into master 2018-04-18 16:57:38 -04:00
Kim Gardner d9a2b10afd Merge pull request #1530 from clintabrown/fix-view-context-system-withheld
Fix admin View Context view for comments with SYSTEM_WITHHELD status
2018-04-18 16:51:05 -04:00
Kim Gardner 06c2f328d1 Merge branch 'master' into fix-view-context-system-withheld 2018-04-18 16:44:08 -04:00
Kim Gardner 5aea8d71da Merge pull request #1531 from coralproject/indexes
Adds Author Index for Comments
2018-04-18 16:32:44 -04:00
Kim Gardner 71d413004e Merge branch 'master' into indexes 2018-04-18 16:26:40 -04:00
Kim Gardner 59658fcb29 Merge pull request #1504 from coralproject/155910162
Account History to User History
2018-04-18 16:18:26 -04:00
Kim Gardner 6d2c4d215d Merge branch 'master' into 155910162 2018-04-18 16:09:06 -04:00
Kim Gardner fe23b83044 Merge pull request #1507 from coralproject/155836892
Bug: User Comment History - After loading more comments, rejecting/accepting a comment reloads the user history
2018-04-18 16:08:49 -04:00
Kim Gardner c4cbefeb81 Change to UserHistory in UserDetail.js 2018-04-18 16:02:39 -04:00
Kim Gardner d822d8343a Merge branch 'master' into 155836892 2018-04-18 15:54:07 -04:00
Kim Gardner 3e8abf554e Merge branch 'master' into 155910162 2018-04-18 15:35:21 -04:00
Wyatt Johnson 431e9d8b09 Merge branch 'master' into gdpr-delete 2018-04-18 13:17:51 -06:00
Wyatt Johnson 2adec1bc34 added deletion graph endpoints 2018-04-18 13:13:41 -06:00
Wyatt Johnson 0e2a37ac91 Merge branch 'master' into gdpr-username 2018-04-18 10:29:18 -06:00
Wyatt Johnson 84360bfddf Merge branch 'master' into gdpr-password 2018-04-18 10:28:17 -06:00
D. Luijten ea2552e173 Merge branch 'hotfix/fix_dutch_moment_locale'
* hotfix/fix_dutch_moment_locale:
  Added NL translation for Moment. Also, sorted locale imports alphabetically.
2018-04-18 14:29:02 +02:00
D. Luijten ca2070eada Added NL translation for Moment. Also, sorted locale imports alphabetically. 2018-04-18 14:28:42 +02:00
Clint Brown 3ae1051148 Add system withheld status to InactiveCommentLabel 2018-04-18 07:55:11 +10:00
Belén Curcio 6b441291c0 Merge branch 'master' into organization-contact 2018-04-17 17:32:37 -03:00
Wyatt Johnson 786c91c4ff Merge pull request #1526 from kitwestneat/no-tabs-logged-out
don't show profile tab if user is logged out
2018-04-17 13:45:27 -06:00
Wyatt Johnson b6299c2d40 fix e2e test 2018-04-17 13:35:30 -06:00
Wyatt Johnson a257fdb623 removed deprecated not logged in ui for profile tab 2018-04-17 13:23:02 -06:00
Wyatt Johnson a6344d8e71 fixed proptype missing validation 2018-04-17 13:19:03 -06:00
Wyatt Johnson ec54db58dd Merge branch 'master' into no-tabs-logged-out 2018-04-17 13:11:32 -06:00
Wyatt Johnson dcf10643a0 Merge branch 'master' into gdpr-download 2018-04-17 13:09:17 -06:00
Wyatt Johnson bc7c37241e Merge branch 'master' into organization-contact 2018-04-17 13:07:16 -06:00
Wyatt Johnson 360dbdf02d icon patch 2018-04-17 13:06:07 -06:00
Wyatt Johnson 6c8b281a82 Merge branch 'master' into indexes 2018-04-17 12:56:48 -06:00
Wyatt Johnson fb1d431948 Merge pull request #1522 from coralproject/server-jest
Serverside Jest Support
2018-04-17 12:42:00 -06:00
Wyatt Johnson 87a97d4053 Adds Author Index for Comments
- Fixes #1529
2018-04-17 12:31:31 -06:00
Belén Curcio d17c704f38 Merge branch 'master' into server-jest 2018-04-17 13:01:19 -03:00
Wyatt Johnson ba9f034bfb Allow a user to change their own username 2018-04-16 17:37:08 -06:00
Wyatt Johnson ce291448f1 Added some change to mutators 2018-04-16 12:45:17 -06:00
Wyatt Johnson 8dbfa8f274 Merge branch 'organization-contact' into gdpr-password 2018-04-16 12:32:09 -06:00
Wyatt Johnson 0ccb8b6217 Merge branch 'master' into organization-contact 2018-04-16 12:30:45 -06:00
Wyatt Johnson 0fcb0be360 Password Change Graph Support 2018-04-16 12:29:37 -06:00
Wyatt Johnson f23f962adb Updated error styling 2018-04-16 10:47:09 -06:00
Wyatt Johnson 276cb03953 fixed missing partial 2018-04-13 18:27:40 -06:00
Wyatt Johnson 12bb886032 itterated on copy 2018-04-13 18:24:46 -06:00
Belén Curcio 1f719e3aa5 Merge branch 'master' into 155836892 2018-04-13 12:52:28 -03:00
Kit Westneat e5a2152cfd don't show profile tab if user is logged out 2018-04-12 17:52:49 -04:00
Wyatt Johnson 392d7177f6 Merge branch 'master' into gdpr-download 2018-04-12 15:17:12 -06:00
Wyatt Johnson 6553096bc7 Merge branch 'master' into organization-contact 2018-04-12 13:11:35 -06:00
Wyatt Johnson 5178529083 adjusted env 2018-04-12 09:44:17 -06:00
Wyatt Johnson 10d11c1615 adjusted index creation and managemen 2018-04-12 09:37:17 -06:00
Wyatt Johnson 68473e5a29 added beforeTest to wait for mongoose to be ready 2018-04-12 08:36:45 -06:00
Wyatt Johnson d481dc8651 Merge branch 'master' into server-jest 2018-04-11 19:30:18 -06:00
Wyatt Johnson 322740d1a9 small fixes 2018-04-11 19:29:54 -06:00
Wyatt Johnson 86385e0d86 Jest for server
- Introduced the Jest testing framework into our server side code so
plugins can now have tests that run
2018-04-11 19:02:38 -06:00
Wyatt Johnson 412fd34cc1 Merge branch 'master' into gdpr-download 2018-04-11 13:46:46 -06:00
Belén Curcio e4cc49cda5 Merge branch 'master' into 155836892 2018-04-11 12:58:33 -03:00
okbel 9e07618a26 Adding min-width for inputs 2018-04-10 13:07:40 -03:00
okbel 46ef214bd3 tiny css changes 2018-04-10 11:55:22 -03:00
okbel 5c2d8c4b62 styles 2018-04-10 11:49:44 -03:00
okbel 1ceb1b4014 Save, and edit changes 2018-04-10 11:46:32 -03:00
Wyatt Johnson afa592aa78 e2e fixes 2018-04-09 16:34:08 -06:00
Wyatt Johnson 8a7d4c4fcc readme update 2018-04-09 16:14:25 -06:00
Wyatt Johnson adb7e97a91 Merge branch 'master' into gdpr-download 2018-04-09 16:09:53 -06:00
Wyatt Johnson 43e3cb8f10 cleanup of plugin code 2018-04-09 16:07:05 -06:00
Wyatt Johnson 333ef98378 Added new plugin 2018-04-09 15:58:31 -06:00
Wyatt Johnson 5941bfac7c pulled data download into seperate plugin 2018-04-09 15:52:40 -06:00
okbel 6d4623f8bf Wip - Almost finished! 2018-04-09 17:43:58 -03:00
okbel 91aa95d3f2 Merge branch 'master' of github.com:coralproject/talk into organization-contact
* 'master' of github.com:coralproject/talk: (36 commits)
  Fixes #1505
  PropTypes
  Removin actions, using routes, and continuing the transition when the user makes an action
  fixes related to external auth
  Adding size, and proptypes
  IfSlotIsNotEmpty Bug
  Style and translations
  allow plugin code from clients to be parsed by webpack
  SaveChangesDialog
  Spanish translations
  Adding translations
  alert route hook ready!
  Removing plugin
  Restore Links
  Removing plugin
  Save changes / discard changes dialohg
  router and state lifted
  routes
  renaming slot :D
  renaming
  ...
2018-04-09 16:51:06 -03:00
Wyatt Johnson 841738c34c Merge branch 'master' into 155836892 2018-04-09 09:11:07 -06:00
Belén Curcio f27c41b83c Merge branch 'master' into 155836892 2018-04-08 21:18:46 -03:00
okbel 071942faca Merge branch '155836892' of github.com:coralproject/talk into 155836892
* '155836892' of github.com:coralproject/talk:
  updated yarn.lock
2018-04-06 18:40:56 -03:00
okbel 9bbcb6a073 wip - inconcistencies with cache, considering refetching 2018-04-06 18:39:23 -03:00
okbel 48bfc2699b Merge branch 'master' of github.com:coralproject/talk into 155836892
* 'master' of github.com:coralproject/talk:
  PropTypes
  Removin actions, using routes, and continuing the transition when the user makes an action
  Adding size, and proptypes
  IfSlotIsNotEmpty Bug
  Style and translations
  SaveChangesDialog
  Spanish translations
  Adding translations
  alert route hook ready!
  Restore Links
  Save changes / discard changes dialohg
  router and state lifted
  routes
2018-04-06 17:59:25 -03:00
Belén Curcio ad214a8e76 Merge branch 'master' into 155836892 2018-04-06 17:56:49 -03:00
Belén Curcio d0652d0583 Merge branch 'master' into 155836892 2018-04-05 17:28:24 -03:00
Wyatt Johnson 0c6ee2fe99 updated yarn.lock 2018-04-05 10:33:38 -06:00
Wyatt Johnson c29b12688c Merge branch 'master' into 155836892 2018-04-05 10:30:53 -06:00
Belén Curcio ccfa7aff5f Merge branch 'master' into 155836892 2018-04-04 07:53:48 -03:00
okbel 0b6b85b2a5 Removing logs 2018-04-04 07:37:27 -03:00
okbel a6a0b3e931 Removing reloads 2018-04-04 07:33:50 -03:00
okbel 06f8926964 Avoiding refetching 2018-04-04 07:25:47 -03:00
okbel ef10ab8088 Renaming components and styles 2018-04-03 11:20:22 -03:00
okbel 1a39727e38 account history to user history 2018-04-03 10:29:07 -03:00
Wyatt Johnson bb7f1a57f0 Added UI for downloading your comment data
- Added button on profile page
- Added date when last downloaded data
2018-04-02 17:53:27 -06:00
Wyatt Johnson c904d0f0c0 improved routing, cleaned mail 2018-04-02 14:58:54 -06:00
Wyatt Johnson 64d8d53987 Merge branch 'master' into gdpr-download 2018-04-02 14:58:06 -06:00
okbel 133984ab36 wip 2018-03-28 13:13:29 -03:00
Belén Curcio bcbaf25365 Merge branch 'master' into organization-contact 2018-03-28 10:42:03 -03:00
okbel 6c815c1132 Working on the admin side 2018-03-28 10:39:50 -03:00
okbel b32d1ef717 Adding the email to the schema 2018-03-28 10:16:57 -03:00
okbel 94d12dfbd4 Adding organizationContactEmail 2018-03-28 10:12:58 -03:00
okbel 6a22cd54ec Adding OrganizationDetails 2018-03-28 10:04:14 -03:00
okbel 480428b4a2 PropTypes and adding field 2018-03-28 09:44:02 -03:00
okbel 5650b7cf3a Adding proptypes 2018-03-28 09:34:06 -03:00
Wyatt Johnson a808cdc195 refactored some request logic 2018-03-27 18:47:34 -06:00
Wyatt Johnson ee5316e6ef initial download support 2018-03-27 18:28:14 -06:00
287 changed files with 9090 additions and 2655 deletions
+18 -1
View File
@@ -1,12 +1,27 @@
# job_environment will setup the environment for any job being executed.
job_environment: &job_environment
NODE_ENV: test
DISABLE_CREATE_MONGO_INDEXES: TRUE
# job_defaults applies all the defaults for each job.
job_defaults: &job_defaults
working_directory: ~/coralproject/talk
docker:
- image: circleci/node:8
environment:
<<: *job_environment
# create_indexes will create the mongo indexes and wait until they have been
# built.
create_indexes: &create_indexes
run:
name: Create the database indexes and wait until they are built
command: ./bin/cli db createIndexes
# integration_environment is the environment that configures the tests.
integration_environment: &integration_environment
NODE_ENV: test
<<: *job_environment
CIRCLE_TEST_REPORTS: /tmp/circleci-test-results
E2E_MAX_RETRIES: 3
@@ -25,6 +40,7 @@ integration_job: &integration_job
- checkout
- attach_workspace:
at: ~/coralproject/talk
- <<: *create_indexes
- run:
name: Setup the database with defaults
command: ./bin/cli setup --defaults
@@ -117,6 +133,7 @@ jobs:
environment:
JEST_JUNIT_OUTPUT: /tmp/circleci-test-results/jest/test-results.xml
JEST_REPORTER: jest-junit
- <<: *create_indexes
- run:
name: Run the server unit tests
command: yarn test:server
+3
View File
@@ -1,3 +1,6 @@
{
"env": {
"jest": true
},
"extends": "@coralproject/eslint-config-talk"
}
+3 -2
View File
@@ -38,6 +38,7 @@ plugins/*
!plugins/talk-plugin-google-auth
!plugins/talk-plugin-ignore-user
!plugins/talk-plugin-like
!plugins/talk-plugin-local-auth
!plugins/talk-plugin-love
!plugins/talk-plugin-member-since
!plugins/talk-plugin-mod
@@ -50,9 +51,10 @@ plugins/*
!plugins/talk-plugin-notifications-digest-hourly
!plugins/talk-plugin-offtopic
!plugins/talk-plugin-permalink
!plugins/talk-plugin-profile-settings
!plugins/talk-plugin-profile-data
!plugins/talk-plugin-remember-sort
!plugins/talk-plugin-respect
!plugins/talk-plugin-rich-text
!plugins/talk-plugin-slack-notifications
!plugins/talk-plugin-sort-most-downvoted
!plugins/talk-plugin-sort-most-liked
@@ -66,7 +68,6 @@ plugins/*
!plugins/talk-plugin-toxic-comments
!plugins/talk-plugin-upvote
!plugins/talk-plugin-viewing-options
!plugins/talk-plugin-rich-text
**/node_modules/*
yarn-error.log
+6 -1
View File
@@ -2,6 +2,11 @@
"exceptions": [
"https://nodesecurity.io/advisories/531",
"https://nodesecurity.io/advisories/532",
"https://nodesecurity.io/advisories/566"
"https://nodesecurity.io/advisories/566",
"https://nodesecurity.io/advisories/577",
"https://nodesecurity.io/advisories/594",
"https://nodesecurity.io/advisories/603",
"https://nodesecurity.io/advisories/611",
"https://nodesecurity.io/advisories/612"
]
}
+1 -1
View File
@@ -32,7 +32,7 @@ Youve installed Talk on your server, and youre preparing to launch it on y
## End-to-End Testing
Talk uses [Nightwatch](https://nightwatchjs.org/) as our e2e testing framework. The testing infrastructure that allows us to run our tests in real browsers is provided with love by our friends at [Browserstack](https://browserstack.com).
Talk uses [Nightwatch](http://nightwatchjs.org/) as our e2e testing framework. The testing infrastructure that allows us to run our tests in real browsers is provided with love by our friends at [Browserstack](https://browserstack.com).
[![Browserstack](/public/img/browserstack_logo.png)](https://browserstack.com)
+6 -24
View File
@@ -1,16 +1,15 @@
#!/usr/bin/env node
/**
* Module dependencies.
*/
require('./util');
const program = require('commander');
const { head, map } = require('lodash');
const Matcher = require('did-you-mean');
// We're requiring this here so it'll setup some promise rejection hooks to log
// out.
require('./util');
// Setup the program.
program
.command('serve', 'serve the application')
.command('db', 'run database commands')
.command('settings', 'interact with the application settings')
.command('assets', 'interact with assets')
.command('setup', 'setup the application')
@@ -23,20 +22,3 @@ program
'provides utilities for interacting with the plugin system'
)
.parse(process.argv);
// If the command wasn't found, output help.
const commands = map(program.commands, '_name');
const command = head(program.args);
if (!commands.includes(command)) {
const m = new Matcher(commands);
const similarCommands = m.list(command);
console.error(
`cli '${command}' is not a talk cli command. See 'cli --help'.`
);
if (similarCommands.length > 0) {
const sc = similarCommands.map(({ value }) => `\t${value}\n`).join('');
console.error(`\nThe most similar commands are\n${sc}`);
}
process.exit(1);
}
Executable
+53
View File
@@ -0,0 +1,53 @@
#!/usr/bin/env node
const util = require('./util');
const program = require('commander');
const config = require('../config');
async function createIndexes() {
try {
// Ensure we enable the index creation.
config.CREATE_MONGO_INDEXES = true;
// TODO: handle the plugin index creation?
// Let's register the shutdown hooks.
util.onshutdown([() => require('../services/mongoose').disconnect()]);
// Lets create all the database indexes for the application and wait for all
// them to finish their indexing.
const models = [
require('../models/action'),
require('../models/asset'),
require('../models/comment'),
require('../models/setting'),
require('../models/user'),
require('../models/migration'),
];
// Call the `.init()` method to setup all the indexes on each model.
// `init()` returns a promise that resolves when the indexes have finished
// building successfully. The `init()` function is idempotent, so we don't
// have to worry about triggering an index rebuild.
await Promise.all(models.map(Model => Model.init()));
console.log('Indexes created');
util.shutdown(0);
} catch (err) {
console.error(err);
util.shutdown(1);
}
}
program
.command('createIndexes')
.description('creates the database indexes and waits until they are created')
.action(createIndexes);
program.parse(process.argv);
// If there is no command listed, output help.
if (process.argv.length <= 2) {
program.outputHelp();
util.shutdown();
}
+11 -8
View File
@@ -4,7 +4,8 @@ const util = require('./util');
const program = require('commander');
const inquirer = require('inquirer');
const mongoose = require('../services/mongoose');
const SettingsService = require('../services/settings');
const Settings = require('../services/settings');
const cache = require('../services/cache');
// Register the shutdown criteria.
util.onshutdown([() => mongoose.disconnect()]);
@@ -14,9 +15,12 @@ util.onshutdown([() => mongoose.disconnect()]);
*/
async function changeOrgName() {
try {
let settings = await SettingsService.retrieve();
await cache.init();
let { organizationName } = await inquirer.prompt([
// Get the original settings.
const settings = await Settings.select('organizationName');
const { organizationName } = await inquirer.prompt([
{
name: 'organizationName',
message: 'Organization Name',
@@ -25,9 +29,8 @@ async function changeOrgName() {
]);
if (settings.organizationName !== organizationName) {
settings.organizationName = organizationName;
await SettingsService.update(settings);
// Set the organization name if there was a mutation to it.
await Settings.update({ organizationName });
console.log('Settings were updated.');
} else {
@@ -36,9 +39,9 @@ async function changeOrgName() {
} catch (err) {
console.error(err);
util.shutdown(1);
} finally {
util.shutdown();
}
util.shutdown();
}
//==============================================================================
+8 -1
View File
@@ -287,8 +287,15 @@ async function createUser() {
const { email, username, password, role } = answers;
const ctx = Context.forSystem();
// Create the user.
const user = await UsersService.createLocalUser(email, password, username);
const user = await UsersService.createLocalUser(
ctx,
email,
password,
username
);
// Set the role.
await UsersService.setRole(user.id, role);
+5 -2
View File
@@ -4,7 +4,8 @@ require('../services/env');
const debug = require('debug')('talk:util');
const { uniq } = require('lodash');
const util = (module.exports = {});
// Setup the utilities.
const util = {};
/**
* Stores an array of functions that should be executed in the event that the
@@ -15,7 +16,7 @@ util.toshutdown = [];
/**
* Calls all the shutdown functions and then ends the process.
* @param {Number} [defaultCode=0] default return code upon sucesfull shutdown.
* @param {Number} [defaultCode=0] default return code upon successful shutdown.
*/
util.shutdown = (defaultCode = 0, signal = null) => {
if (signal) {
@@ -63,3 +64,5 @@ process.on('unhandledRejection', err => {
console.error(err);
process.exit(1);
});
module.exports = util;
+2
View File
@@ -10,6 +10,7 @@ import Configure from 'routes/Configure';
import StreamSettings from './routes/Configure/containers/StreamSettings';
import ModerationSettings from './routes/Configure/containers/ModerationSettings';
import TechSettings from './routes/Configure/containers/TechSettings';
import OrganizationSettings from './routes/Configure/containers/OrganizationSettings';
import { ModerationLayout, Moderation } from 'routes/Moderation';
@@ -25,6 +26,7 @@ const routes = (
<Route path="stream" component={StreamSettings} />
<Route path="moderation" component={ModerationSettings} />
<Route path="tech" component={TechSettings} />
<Route path="organization" component={OrganizationSettings} />
<IndexRedirect to="stream" />
</Route>
@@ -29,7 +29,7 @@ const CommentAnimatedEdit = ({ children, body }) => {
CommentAnimatedEdit.propTypes = {
children: PropTypes.node,
body: PropTypes.string,
body: PropTypes.string.isRequired,
};
export default CommentAnimatedEdit;
@@ -0,0 +1,5 @@
.tombstone {
background-color: #f0f0f0;
padding: 1em;
color: #1a212f;
}
@@ -0,0 +1,9 @@
import React from 'react';
import styles from './CommentDeletedTombstone.css';
import t from 'coral-framework/services/i18n';
const CommentDeletedTombstone = () => (
<div className={styles.tombstone}>{t('framework.comment_is_deleted')}</div>
);
export default CommentDeletedTombstone;
+15 -31
View File
@@ -3,7 +3,7 @@ import cn from 'classnames';
import PropTypes from 'prop-types';
import capitalize from 'lodash/capitalize';
import styles from './UserDetail.css';
import AccountHistory from './AccountHistory';
import UserHistory from './UserHistory';
import { Slot } from 'coral-framework/components';
import UserDetailCommentList from '../components/UserDetailCommentList';
import {
@@ -28,26 +28,6 @@ import UserInfoTooltip from './UserInfoTooltip';
import t from 'coral-framework/services/i18n';
class UserDetail extends React.Component {
rejectThenReload = async info => {
await this.props.rejectComment(info);
this.props.data.refetch();
};
acceptThenReload = async info => {
await this.props.acceptComment(info);
this.props.data.refetch();
};
bulkAcceptThenReload = async () => {
await this.props.bulkAccept();
this.props.data.refetch();
};
bulkRejectThenReload = async () => {
await this.props.bulkReject();
this.props.data.refetch();
};
changeTab = tab => {
this.props.changeTab(tab);
};
@@ -110,6 +90,10 @@ class UserDetail extends React.Component {
unbanUser,
unsuspendUser,
modal,
acceptComment,
rejectComment,
bulkAccept,
bulkReject,
} = this.props;
// if totalComments is 0, you're dividing by zero
@@ -286,7 +270,7 @@ class UserDetail extends React.Component {
'talk-admin-user-detail-history-tab'
)}
>
{t('user_detail.account_history')}
{t('user_detail.user_history')}
</Tab>
</TabBar>
@@ -304,12 +288,12 @@ class UserDetail extends React.Component {
loadMore={loadMore}
toggleSelect={toggleSelect}
viewUserDetail={viewUserDetail}
acceptComment={this.acceptThenReload}
rejectComment={this.rejectThenReload}
acceptComment={acceptComment}
rejectComment={rejectComment}
selectedCommentIds={selectedCommentIds}
toggleSelectAll={toggleSelectAll}
bulkAcceptThenReload={this.bulkAcceptThenReload}
bulkRejectThenReload={this.bulkRejectThenReload}
bulkAcceptThenReload={bulkAccept}
bulkRejectThenReload={bulkReject}
/>
</TabPane>
<TabPane
@@ -322,19 +306,19 @@ class UserDetail extends React.Component {
loadMore={loadMore}
toggleSelect={toggleSelect}
viewUserDetail={viewUserDetail}
acceptComment={this.acceptThenReload}
rejectComment={this.rejectThenReload}
acceptComment={acceptComment}
rejectComment={rejectComment}
selectedCommentIds={selectedCommentIds}
toggleSelectAll={toggleSelectAll}
bulkAcceptThenReload={this.bulkAcceptThenReload}
bulkRejectThenReload={this.bulkRejectThenReload}
bulkAcceptThenReload={bulkAccept}
bulkRejectThenReload={bulkReject}
/>
</TabPane>
<TabPane
tabId={'history'}
className={'talk-admin-user-detail-history-tab-pane'}
>
<AccountHistory user={user} />
<UserHistory user={user} />
</TabPane>
</TabContent>
</Drawer>
@@ -12,6 +12,7 @@ import CommentAnimatedEdit from './CommentAnimatedEdit';
import CommentLabels from '../containers/CommentLabels';
import ApproveButton from './ApproveButton';
import RejectButton from 'coral-admin/src/components/RejectButton';
import CommentDeletedTombstone from './CommentDeletedTombstone';
import t, { timeago } from 'coral-framework/services/i18n';
@@ -43,6 +44,19 @@ class UserDetailComment extends React.Component {
body: comment.body,
};
if (!comment.body) {
return (
<li
tabIndex={0}
className={cn(className, styles.root, {
[styles.rootSelected]: selected,
})}
>
<CommentDeletedTombstone />
</li>
);
}
return (
<li
tabIndex={0}
@@ -152,7 +166,7 @@ UserDetailComment.propTypes = {
comment: PropTypes.shape({
id: PropTypes.string.isRequired,
status: PropTypes.string.isRequired,
body: PropTypes.string.isRequired,
body: PropTypes.string,
actions: PropTypes.array,
created_at: PropTypes.string.isRequired,
asset: PropTypes.shape({
@@ -1,7 +1,7 @@
import React from 'react';
import PropTypes from 'prop-types';
import { murmur3 } from 'murmurhash-js';
import styles from './AccountHistory.css';
import styles from './UserHistory.css';
import cn from 'classnames';
import flatten from 'lodash/flatten';
import orderBy from 'lodash/orderBy';
@@ -43,15 +43,15 @@ const readableDuration = (startDate, endDate) => {
const buildActionResponse = (typename, created_at, until, status) => {
switch (typename) {
case 'UsernameStatusHistory':
return t('account_history.username_status', status);
return t('user_history.username_status', status);
case 'BannedStatusHistory':
return status
? t('account_history.user_banned')
: t('account_history.ban_removed');
? t('user_history.user_banned')
: t('user_history.ban_removed');
case 'SuspensionStatusHistory':
return until
? t('account_history.suspended', readableDuration(created_at, until))
: t('account_history.suspension_removed');
? t('user_history.suspended', readableDuration(created_at, until))
: t('user_history.suspension_removed');
default:
return '-';
}
@@ -62,43 +62,41 @@ const getModerationValue = assignedBy =>
assignedBy.username
) : (
<span>
<Icon name="computer" /> {t('account_history.system')}
<Icon name="computer" /> {t('user_history.system')}
</span>
);
class AccountHistory extends React.Component {
class UserHistory extends React.Component {
render() {
const { user } = this.props;
const userHistory = buildUserHistory(user.state);
return (
<div>
<div className={cn(styles.table, 'talk-admin-account-history')}>
<div className={cn(styles.table, 'talk-admin-user-history')}>
<div
className={cn(
styles.headerRow,
'talk-admin-account-history-header-row'
'talk-admin-user-history-header-row'
)}
>
<div className={styles.headerRowItem}>{t('user_history.date')}</div>
<div className={styles.headerRowItem}>
{t('account_history.date')}
{t('user_history.action')}
</div>
<div className={styles.headerRowItem}>
{t('account_history.action')}
</div>
<div className={styles.headerRowItem}>
{t('account_history.taken_by')}
{t('user_history.taken_by')}
</div>
</div>
{userHistory.map(
({ __typename, created_at, assigned_by, until, status }) => (
<div
className={cn(styles.row, 'talk-admin-account-history-row')}
className={cn(styles.row, 'talk-admin-user-history-row')}
key={`${__typename}_${murmur3(created_at)}`}
>
<div
className={cn(
styles.item,
'talk-admin-account-history-row-date'
'talk-admin-user-history-row-date'
)}
>
{moment(new Date(created_at)).format('MMM DD, YYYY')}
@@ -107,7 +105,7 @@ class AccountHistory extends React.Component {
className={cn(
styles.item,
styles.action,
'talk-admin-account-history-row-status'
'talk-admin-user-history-row-status'
)}
>
{buildActionResponse(__typename, created_at, until, status)}
@@ -116,7 +114,7 @@ class AccountHistory extends React.Component {
className={cn(
styles.item,
styles.username,
'talk-admin-account-history-row-assigned-by'
'talk-admin-user-history-row-assigned-by'
)}
>
{getModerationValue(assigned_by)}
@@ -130,8 +128,8 @@ class AccountHistory extends React.Component {
}
}
AccountHistory.propTypes = {
UserHistory.propTypes = {
user: PropTypes.object.isRequired,
};
export default AccountHistory;
export default UserHistory;
@@ -148,6 +148,7 @@ UserDetailContainer.propTypes = {
selectedCommentIds: PropTypes.array,
unbanUser: PropTypes.func.isRequired,
unsuspendUser: PropTypes.func.isRequired,
userId: PropTypes.string,
};
const LOAD_MORE_QUERY = gql`
@@ -245,7 +246,6 @@ export const withUserDetailQuery = withQuery(
options: ({ userId, statuses }) => {
return {
variables: { author_id: userId, statuses },
fetchPolicy: 'network-only',
};
},
skip: ownProps => !ownProps.userId,
+31
View File
@@ -291,5 +291,36 @@ export default {
},
},
}),
SetCommentStatus: ({ variables: { status } }) => ({
updateQueries: {
CoralAdmin_UserDetail: prev => {
const increment = {
rejectedComments: {
$apply: count => (count < prev.totalComments ? count + 1 : count),
},
};
const decrement = {
rejectedComments: {
$apply: count => (count > 0 ? count - 1 : 0),
},
};
// If rejected then increment rejectedComments by one
if (status === 'REJECTED') {
const updated = update(prev, increment);
return updated;
}
// If approved then decrement rejectedComments by one
if (status === 'ACCEPTED') {
const updated = update(prev, decrement);
return updated;
}
return prev;
},
},
}),
},
};
@@ -5,6 +5,7 @@ const initialState = {
isLoading: false,
data: {
settings: {
organizationContactEmail: '',
organizationName: '',
domains: {
whitelist: [],
@@ -19,6 +20,7 @@ const initialState = {
},
errors: {
organizationName: '',
organizationContactEmail: '',
username: '',
email: '',
password: '',
@@ -8,7 +8,14 @@ import SaveChangesDialog from './SaveChangesDialog';
class Configure extends React.Component {
render() {
const { canSave, currentUser, root, savePending, settings } = this.props;
const {
canSave,
currentUser,
root,
savePending,
settings,
clearPending,
} = this.props;
if (!can(currentUser, 'UPDATE_CONFIG')) {
return <p>{t('configure.access_message')}</p>;
@@ -17,6 +24,9 @@ class Configure extends React.Component {
const passProps = {
root,
settings,
savePending,
clearPending,
canSave,
};
return (
@@ -41,6 +51,9 @@ class Configure extends React.Component {
<Item itemId="tech" icon="code">
{t('configure.tech_settings')}
</Item>
<Item itemId="organization" icon="people">
{t('configure.organization_information')}
</Item>
</List>
<div className={styles.saveBox}>
{canSave ? (
@@ -81,6 +94,7 @@ Configure.propTypes = {
children: PropTypes.node.isRequired,
saveDialog: PropTypes.bool,
hideSaveDialog: PropTypes.func.isRequired,
clearPending: PropTypes.func.isRequired,
};
export default Configure;
@@ -0,0 +1,87 @@
.label {
display: block;
}
.detailList {
padding: 0;
margin: 0;
}
.detailLabel {
color: #000;
font-size: 1.1em;
font-weight: bold;
display: block;
margin-bottom: 4px;
}
.detailValue {
padding: 6px 0;
border: solid 1px transparent;
display: block;
font-size: 1.1em;
border-radius: 2px;
color: #424242;
box-sizing: border-box;
min-width: 300px;
}
.editable {
padding-left: 10px;
padding-right: 10px;
border-color: grey;
}
.detailItem {
margin-bottom: 16px;
list-style: none;
}
.button, .button:disabled {
background: white;
border: solid 1px grey;
}
.actionBox {
flex-grow: 0;
}
.cancelButton {
padding: 10px;
display: block;
color: #4f5c67;
font-weight: 500;
&:hover {
cursor: pointer;
}
}
.changedSave {
background-color: #00796B;
color: white;
}
.errorList {
list-style: none;
padding: 0;
margin: 0;
}
.errorItem {
padding: 5px 10px;
margin-bottom: 20px;
color: #b71c1c;
border-radius: 2px;
display: inline-block;
background: #F9D3CE;
}
.container {
display: flex;
}
.content {
flex-grow: 1;
padding-right: 40px;
}
@@ -0,0 +1,185 @@
import React from 'react';
import cn from 'classnames';
import { Button } from 'coral-ui';
import PropTypes from 'prop-types';
import styles from './OrganizationSettings.css';
import Slot from 'coral-framework/components/Slot';
import t from 'coral-framework/services/i18n';
import ConfigurePage from './ConfigurePage';
import ConfigureCard from 'coral-framework/components/ConfigureCard';
import validate from 'coral-framework/helpers/validate';
import errorMsj from 'coral-framework/helpers/error';
class OrganizationSettings extends React.Component {
state = { editing: false, errors: [] };
addError = err => {
if (this.state.errors.indexOf(err) === -1) {
this.setState(({ errors }) => ({
errors: errors.concat(err),
}));
}
};
removeError = err => {
this.setState(({ errors }) => ({
errors: errors.filter(i => i !== err),
}));
};
toggleEditing = () => {
this.setState(({ editing }) => ({
editing: !editing,
}));
};
disableEditing = () => {
this.setState(() => ({
editing: false,
}));
};
updateName = event => {
const updater = { organizationName: { $set: event.target.value } };
this.props.updatePending({ updater });
};
updateEmail = event => {
let error = null;
const email = event.target.value;
// Add a blocker error
if (!validate.email(email)) {
error = true;
this.addError('email');
} else {
this.removeError('email');
}
const updater = { organizationContactEmail: { $set: email } };
const errorUpdater = { organizationContactEmail: { $set: error } };
this.props.updatePending({ updater, errorUpdater });
};
cancelEditing = () => {
this.disableEditing();
this.props.clearPending();
};
save = async () => {
await this.props.savePending();
this.disableEditing();
};
displayErrors = (errors = []) => (
<ul className={styles.errorList}>
{errors.map((errKey, i) => (
<li key={`${i}_${errKey}`} className={styles.errorItem}>
{errorMsj[errKey]}
</li>
))}
</ul>
);
render() {
const { settings, slotPassthrough, canSave } = this.props;
const hasErrors = this.state.errors.length;
return (
<ConfigurePage title={t('configure.organization_information')}>
<p>{t('configure.organization_info_copy')}</p>
<p>{t('configure.organization_info_copy_2')}</p>
<ConfigureCard>
<div className={styles.container}>
<div className={styles.content}>
{this.displayErrors(this.state.errors)}
<ul className={styles.detailList}>
<li className={styles.detailItem}>
<label
className={styles.detailLabel}
id={t('configure.organization_name')}
>
{t('configure.organization_name')}
</label>
<input
type="text"
className={cn(styles.detailValue, {
[styles.editable]: this.state.editing,
})}
onChange={this.updateName}
value={settings.organizationName}
id={t('configure.organization_name')}
readOnly={!this.state.editing}
/>
</li>
<li className={styles.detailItem}>
<label
className={styles.detailLabel}
id={t('configure.organization_contact_email')}
>
{t('configure.organization_contact_email')}
</label>
<input
type="text"
className={cn(styles.detailValue, {
[styles.editable]: this.state.editing,
})}
onChange={this.updateEmail}
value={settings.organizationContactEmail || ''}
id={t('configure.organization_contact_email')}
readOnly={!this.state.editing}
/>
</li>
</ul>
</div>
{!this.state.editing ? (
<div className={styles.actionBox}>
<Button
className={styles.button}
icon="settings"
onClick={this.toggleEditing}
full
>
{t('configure.edit_info')}
</Button>
</div>
) : (
<div className={styles.actionBox}>
{canSave && !hasErrors ? (
<Button
raised
onClick={this.save}
className={styles.changedSave}
icon="check"
full
>
{t('configure.save')}
</Button>
) : (
<Button className={styles.button} disabled icon="check" full>
{t('configure.save')}
</Button>
)}
<a className={styles.cancelButton} onClick={this.cancelEditing}>
{t('cancel')}
</a>
</div>
)}
</div>
</ConfigureCard>
<Slot fill="adminOrganizationSettings" passthrough={slotPassthrough} />
</ConfigurePage>
);
}
}
OrganizationSettings.propTypes = {
savePending: PropTypes.func.isRequired,
clearPending: PropTypes.func.isRequired,
updatePending: PropTypes.func.isRequired,
errors: PropTypes.object.isRequired,
settings: PropTypes.object.isRequired,
slotPassthrough: PropTypes.object.isRequired,
canSave: PropTypes.bool.isRequired,
};
export default OrganizationSettings;
@@ -16,10 +16,12 @@ import {
hideSaveDialog,
} from '../../../actions/configure';
import Configure from '../components/Configure';
import OrganizationSettings from './OrganizationSettings';
import { withRouter } from 'react-router';
class ConfigureContainer extends React.Component {
state = { nextRoute: '' };
nextRoute = '';
unregisterLeaveHook = null;
savePending = async () => {
await this.props.updateSettings(this.props.pending);
@@ -39,18 +41,16 @@ class ConfigureContainer extends React.Component {
};
gotoNextRoute = () => {
const { nextRoute } = this.state;
if (nextRoute) {
this.props.router.push(nextRoute);
this.setState({ nextRoute: '' });
if (this.nextRoute) {
this.props.router.push(this.nextRoute);
this.nextRoute = '';
}
};
handleSectionChange = async section => {
const nextRoute = `/admin/configure/${section}`;
if (this.shouldShowSaveDialog()) {
await this.setState({ nextRoute });
if (this.hasPendingData()) {
this.nextRoute = nextRoute;
this.props.showSaveDialog();
} else {
// Just go to the section
@@ -58,20 +58,37 @@ class ConfigureContainer extends React.Component {
}
};
shouldShowSaveDialog = () => {
navigationPrompt = e => {
if (this.hasPendingData()) {
const confirmationMessage = 'Changes that you made may not be saved.';
e.returnValue = confirmationMessage; // Gecko, Trident, Chrome 34+
return confirmationMessage; // Gecko, WebKit, Chrome <34
}
};
hasPendingData = () => {
return !!Object.keys(this.props.pending).length;
};
routeLeave = ({ pathname }) => {
if (this.shouldShowSaveDialog()) {
this.setState({ nextRoute: pathname });
if (this.hasPendingData()) {
this.nextRoute = pathname;
this.props.showSaveDialog();
return false;
}
};
componentDidMount() {
this.props.router.setRouteLeaveHook(this.props.route, this.routeLeave);
this.unregisterLeaveHook = this.props.router.setRouteLeaveHook(
this.props.route,
this.routeLeave
);
window.addEventListener('beforeunload', this.navigationPrompt);
}
componentWillUnmount() {
this.unregisterLeaveHook();
window.removeEventListener('beforeunload', this.navigationPrompt);
}
render() {
@@ -83,18 +100,21 @@ class ConfigureContainer extends React.Component {
return <Spinner />;
}
const activeSection = this.props.routes[3].path;
return (
<Configure
saveChanges={this.saveChanges}
discardChanges={this.discardChanges}
saveDialog={this.props.saveDialog}
activeSection={this.props.routes[3].path}
activeSection={activeSection}
hideSaveDialog={this.props.hideSaveDialog}
canSave={this.props.canSave}
currentUser={this.props.currentUser}
root={this.props.root}
settings={this.props.mergedSettings}
handleSectionChange={this.handleSectionChange}
clearPending={this.props.clearPending}
savePending={this.savePending}
>
{this.props.children}
@@ -110,10 +130,12 @@ const withConfigureQuery = withQuery(
...${getDefinitionName(StreamSettings.fragments.settings)}
...${getDefinitionName(TechSettings.fragments.settings)}
...${getDefinitionName(ModerationSettings.fragments.settings)}
...${getDefinitionName(OrganizationSettings.fragments.settings)}
}
...${getDefinitionName(StreamSettings.fragments.root)}
...${getDefinitionName(TechSettings.fragments.root)}
...${getDefinitionName(ModerationSettings.fragments.root)}
...${getDefinitionName(OrganizationSettings.fragments.root)}
}
${StreamSettings.fragments.root}
${StreamSettings.fragments.settings}
@@ -121,6 +143,8 @@ const withConfigureQuery = withQuery(
${TechSettings.fragments.settings}
${ModerationSettings.fragments.root}
${ModerationSettings.fragments.settings}
${OrganizationSettings.fragments.root}
${OrganizationSettings.fragments.settings}
`,
{
options: () => ({
@@ -0,0 +1,53 @@
import { connect } from 'react-redux';
import { bindActionCreators } from 'redux';
import { compose, gql } from 'react-apollo';
import OrganizationSettings from '../components/OrganizationSettings';
import withFragments from 'coral-framework/hocs/withFragments';
import { getSlotFragmentSpreads } from 'coral-framework/utils';
import { updatePending } from '../../../actions/configure';
import { mapProps } from 'recompose';
const slots = ['adminOrganizationSettings'];
const mapStateToProps = state => ({
errors: state.configure.errors,
});
const mapDispatchToProps = dispatch =>
bindActionCreators(
{
updatePending,
},
dispatch
);
export default compose(
withFragments({
root: gql`
fragment TalkAdmin_OrganizationSettings_root on RootQuery {
__typename
${getSlotFragmentSpreads(slots, 'root')}
}
`,
settings: gql`
fragment TalkAdmin_OrganizationSettings_settings on Settings {
organizationName
organizationContactEmail
${getSlotFragmentSpreads(slots, 'settings')}
}
`,
}),
connect(mapStateToProps, mapDispatchToProps),
mapProps(({ root, settings, updatePending, errors, ...rest }) => ({
slotPassthrough: {
root,
settings,
updatePending,
errors,
},
updatePending,
settings,
errors,
...rest,
}))
)(OrganizationSettings);
@@ -1,15 +1,16 @@
import React, { Component } from 'react';
import React from 'react';
import styles from './Install.css';
import { Wizard, WizardNav } from 'coral-ui';
import Layout from 'coral-admin/src/components/Layout';
import PropTypes from 'prop-types';
import InitialStep from './Steps/InitialStep';
import AddOrganizationName from './Steps/AddOrganizationName';
import OrganizationDetails from './Steps/OrganizationDetails';
import CreateYourAccount from './Steps/CreateYourAccount';
import PermittedDomainsStep from './Steps/PermittedDomainsStep';
import FinalStep from './Steps/FinalStep';
export default class Install extends Component {
class Install extends React.Component {
handleDomainsChange = value => {
this.props.updatePermittedDomains(value);
};
@@ -55,7 +56,7 @@ export default class Install extends Component {
goToStep={this.props.goToStep}
>
<InitialStep />
<AddOrganizationName
<OrganizationDetails
install={install}
handleSettingsChange={this.handleSettingsChange}
handleSettingsSubmit={this.handleSettingsSubmit}
@@ -81,3 +82,18 @@ export default class Install extends Component {
);
}
}
Install.propTypes = {
updatePermittedDomains: PropTypes.func.isRequired,
updateSettingsFormData: PropTypes.func.isRequired,
updateUserFormData: PropTypes.func.isRequired,
submitSettings: PropTypes.func.isRequired,
submitUser: PropTypes.func.isRequired,
install: PropTypes.object.isRequired,
nextStep: PropTypes.func.isRequired,
previousStep: PropTypes.func.isRequired,
goToStep: PropTypes.func.isRequired,
finishInstall: PropTypes.func.isRequired,
};
export default Install;
@@ -21,6 +21,17 @@ const AddOrganizationName = props => {
showErrors={install.showErrors}
errorMsg={install.errors.organizationName}
/>
<TextField
className={styles.TextField}
id="organizationContactEmail"
type="email"
label={t('install.create.organization_contact_email')}
onChange={handleSettingsChange}
showErrors={install.showErrors}
errorMsg={install.errors.organizationContactEmail}
/>
<Button
className="talk-install-step-2-save-button"
type="submit"
@@ -1,8 +1,7 @@
import React, { Component } from 'react';
import React from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import { bindActionCreators } from 'redux';
import { compose } from 'react-apollo';
import Install from '../components/Install';
import {
@@ -18,7 +17,7 @@ import {
updatePermittedDomains,
} from '../../../actions/install';
class InstallContainer extends Component {
class InstallContainer extends React.Component {
componentDidMount() {
const { checkInstall } = this.props;
checkInstall(() => {
@@ -27,7 +26,21 @@ class InstallContainer extends Component {
}
render() {
return <Install {...this.props} />;
return (
<Install
install={this.props.install}
goToStep={this.props.goToStep}
nextStep={this.props.nextStep}
submitUser={this.props.submitUser}
checkInstall={this.props.checkInstall}
previousStep={this.props.previousStep}
finishInstall={this.props.finishInstall}
submitSettings={this.props.submitSettings}
updateUserFormData={this.props.updateUserFormData}
updateSettingsFormData={this.props.updateSettingsFormData}
updatePermittedDomains={this.props.updatePermittedDomains}
/>
);
}
}
@@ -35,6 +48,20 @@ InstallContainer.contextTypes = {
router: PropTypes.object,
};
InstallContainer.propTypes = {
install: PropTypes.object.isRequired,
goToStep: PropTypes.func.isRequired,
nextStep: PropTypes.func.isRequired,
submitUser: PropTypes.func.isRequired,
checkInstall: PropTypes.func.isRequired,
previousStep: PropTypes.func.isRequired,
finishInstall: PropTypes.func.isRequired,
submitSettings: PropTypes.func.isRequired,
updateUserFormData: PropTypes.func.isRequired,
updateSettingsFormData: PropTypes.func.isRequired,
updatePermittedDomains: PropTypes.func.isRequired,
};
const mapStateToProps = state => ({
install: state.install,
});
@@ -56,6 +83,4 @@ const mapDispatchToProps = dispatch =>
dispatch
);
export default compose(connect(mapStateToProps, mapDispatchToProps))(
InstallContainer
);
export default connect(mapStateToProps, mapDispatchToProps)(InstallContainer);
@@ -85,6 +85,10 @@
font-weight: 300;
}
.deleted {
background-color: #f0f0f0;
}
.moderateArticle {
font-size: 14px;
margin: 10px 0;
@@ -13,6 +13,7 @@ import IfHasLink from 'coral-admin/src/components/IfHasLink';
import cn from 'classnames';
import ApproveButton from 'coral-admin/src/components/ApproveButton';
import RejectButton from 'coral-admin/src/components/RejectButton';
import CommentDeletedTombstone from '../../../components/CommentDeletedTombstone';
import t, { timeago } from 'coral-framework/services/i18n';
@@ -75,6 +76,27 @@ class Comment extends React.Component {
asset: comment.asset,
};
if (!comment.body) {
return (
<li
tabIndex={0}
className={cn(
className,
'mdl-card',
selectionStateCSS,
styles.root,
{ [styles.selected]: selected, [styles.dangling]: dangling },
'talk-admin-moderate-comment',
styles.deleted
)}
id={`comment_${comment.id}`}
ref={this.handleRef}
>
<CommentDeletedTombstone />
</li>
);
}
return (
<li
tabIndex={0}
@@ -200,7 +222,7 @@ Comment.propTypes = {
comment: PropTypes.shape({
id: PropTypes.string.isRequired,
status: PropTypes.string.isRequired,
body: PropTypes.string.isRequired,
body: PropTypes.string,
action_summaries: PropTypes.array,
actions: PropTypes.array,
created_at: PropTypes.string.isRequired,
@@ -432,6 +432,7 @@ const withModQueueQuery = withQuery(
${Object.keys(queueConfig).map(
queue => `
${queue}: comments(query: {
excludeDeleted: true,
statuses: ${
queueConfig[queue].statuses
? `[${queueConfig[queue].statuses.join(', ')}],`
@@ -458,6 +459,7 @@ const withModQueueQuery = withQuery(
${Object.keys(queueConfig).map(
queue => `
${queue}Count: commentCount(query: {
excludeDeleted: true,
statuses: ${
queueConfig[queue].statuses
? `[${queueConfig[queue].statuses.join(', ')}],`
@@ -24,14 +24,20 @@ export default class Embed extends React.Component {
>
{t('embed_comments_tab')}
</Tab>,
<Tab
key="profile"
tabId="profile"
className="talk-embed-stream-profile-tab"
>
{t('framework.my_profile')}
</Tab>,
];
if (this.props.currentUser) {
tabs.push(
<Tab
key="profile"
tabId="profile"
className="talk-embed-stream-profile-tab"
>
{t('framework.my_profile')}
</Tab>
);
}
if (can(this.props.currentUser, 'UPDATE_ASSET_CONFIG')) {
tabs.push(
<Tab
@@ -43,6 +49,7 @@ export default class Embed extends React.Component {
</Tab>
);
}
return tabs;
}
@@ -16,9 +16,11 @@ class ExtendableTabPanel extends React.Component {
} = this.props;
return (
<div {...rest}>
<TabBar activeTab={activeTab} onTabClick={setActiveTab} sub={sub}>
{tabs}
</TabBar>
{tabs && (
<TabBar activeTab={activeTab} onTabClick={setActiveTab} sub={sub}>
{tabs}
</TabBar>
)}
{loading ? (
<div className={styles.spinnerContainer}>
<Spinner />
@@ -1,14 +0,0 @@
.message {
padding: 10px 0 20px;
letter-spacing: 0.1px;
font-size: 13px;
line-height: 33px;
}
.message a {
color: black;
font-weight: bold;
cursor: pointer;
margin: 0px;
padding-bottom: 2px;
}
@@ -1,15 +0,0 @@
import React from 'react';
import styles from './NotLoggedIn.css';
import cn from 'classnames';
import t from 'coral-framework/services/i18n';
export default ({ showSignInDialog }) => (
<div className={cn(styles.message, 'talk-embed-stream-not-logged-in')}>
<div>
<a onClick={showSignInDialog}>{t('settings.sign_in')}</a>{' '}
{t('settings.to_access')}
</div>
<div>{t('from_settings_page')}</div>
</div>
);
@@ -4,13 +4,32 @@ import Slot from 'coral-framework/components/Slot';
import styles from './Profile.css';
import TabPanel from '../containers/TabPanel';
const Profile = ({ username, emailAddress, root, slotPassthrough }) => {
const DefaultProfileHeader = ({ username, emailAddress }) => (
<div className={styles.userInfo}>
<h2 className={styles.username}>{username}</h2>
{emailAddress ? <p className={styles.email}>{emailAddress}</p> : null}
</div>
);
DefaultProfileHeader.propTypes = {
username: PropTypes.string,
emailAddress: PropTypes.string,
};
const Profile = ({ id, username, emailAddress, root, slotPassthrough }) => {
return (
<div className="talk-my-profile talk-profile-container">
<div className={styles.userInfo}>
<h2 className={styles.username}>{username}</h2>
{emailAddress ? <p className={styles.email}>{emailAddress}</p> : null}
</div>
<Slot
fill="profileHeader"
size={1}
defaultComponent={DefaultProfileHeader}
passthrough={{
...slotPassthrough,
id,
username,
emailAddress,
}}
/>
<Slot fill="profileSections" passthrough={slotPassthrough} />
<TabPanel root={root} slotPassthrough={slotPassthrough} />
</div>
@@ -18,6 +37,7 @@ const Profile = ({ username, emailAddress, root, slotPassthrough }) => {
};
Profile.propTypes = {
id: PropTypes.string,
username: PropTypes.string,
emailAddress: PropTypes.string,
root: PropTypes.object,
@@ -2,27 +2,17 @@ import React, { Component } from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import { compose, gql } from 'react-apollo';
import { bindActionCreators } from 'redux';
import { withQuery } from 'coral-framework/hocs';
import NotLoggedIn from '../components/NotLoggedIn';
import { Spinner } from 'coral-ui';
import Profile from '../components/Profile';
import TabPanel from './TabPanel';
import { getDefinitionName } from 'coral-framework/utils';
import { showSignInDialog } from 'coral-embed-stream/src/actions/login';
import { getSlotFragmentSpreads } from 'coral-framework/utils';
class ProfileContainer extends Component {
componentWillReceiveProps(nextProps) {
if (!this.props.currentUser && nextProps.currentUser) {
// Refetch after login.
this.props.data.refetch();
}
}
render() {
const { currentUser, showSignInDialog, root } = this.props;
const { currentUser, root } = this.props;
const { me } = this.props.root;
const loading = this.props.data.loading;
@@ -30,10 +20,6 @@ class ProfileContainer extends Component {
return <div>{this.props.data.error.message}</div>;
}
if (!currentUser) {
return <NotLoggedIn showSignInDialog={showSignInDialog} />;
}
if (loading || !me) {
return <Spinner />;
}
@@ -44,6 +30,7 @@ class ProfileContainer extends Component {
return (
<Profile
id={me.id}
username={me.username}
emailAddress={emailAddress}
root={root}
@@ -57,10 +44,9 @@ ProfileContainer.propTypes = {
data: PropTypes.object,
root: PropTypes.object,
currentUser: PropTypes.object,
showSignInDialog: PropTypes.func,
};
const slots = ['profileSections'];
const slots = ['profileSections', 'profileSettings', 'profileHeader'];
const withProfileQuery = withQuery(
gql`
@@ -68,6 +54,15 @@ const withProfileQuery = withQuery(
me {
id
username
state {
status {
username {
history {
created_at
}
}
}
}
}
...${getDefinitionName(TabPanel.fragments.root)}
${getSlotFragmentSpreads(slots, 'root')}
@@ -85,10 +80,6 @@ const mapStateToProps = state => ({
currentUser: state.auth.user,
});
const mapDispatchToProps = dispatch =>
bindActionCreators({ showSignInDialog }, dispatch);
export default compose(
connect(mapStateToProps, mapDispatchToProps),
withProfileQuery
)(ProfileContainer);
export default compose(connect(mapStateToProps), withProfileQuery)(
ProfileContainer
);
@@ -214,7 +214,7 @@ AllCommentsPane.propTypes = {
asset: PropTypes.object,
currentUser: PropTypes.object,
postFlag: PropTypes.func,
postDontAgree: PropTypes.func,
postDontAgree: PropTypes.func.isRequired,
loadNewReplies: PropTypes.func,
deleteAction: PropTypes.func,
showSignInDialog: PropTypes.func,
@@ -27,6 +27,7 @@ import {
getActionSummary,
iPerformedThisAction,
isCommentActive,
isCommentDeleted,
getShallowChanges,
} from 'coral-framework/utils';
import t from 'coral-framework/services/i18n';
@@ -183,7 +184,7 @@ export default class Comment extends React.Component {
maxCharCount: PropTypes.number,
root: PropTypes.object,
loadMore: PropTypes.func,
postDontAgree: PropTypes.func,
postDontAgree: PropTypes.func.isRequired,
animateEnter: PropTypes.bool,
commentClassNames: PropTypes.array,
comment: PropTypes.object.isRequired,
@@ -409,6 +410,7 @@ export default class Comment extends React.Component {
charCountEnable,
showSignInDialog,
liveUpdates,
postDontAgree,
emit,
} = this.props;
return (
@@ -439,6 +441,7 @@ export default class Comment extends React.Component {
key={reply.id}
comment={reply}
emit={emit}
postDontAgree={postDontAgree}
/>
);
})}
@@ -574,7 +577,9 @@ export default class Comment extends React.Component {
'talk-stream-comment-header-tags-container'
)}
>
{isStaff(comment.tags) ? <TagLabel>Staff</TagLabel> : null}
{isStaff(comment.tags) ? (
<TagLabel>{t('community.staff')}</TagLabel>
) : null}
<Slot
className={cn(
@@ -742,8 +747,14 @@ export default class Comment extends React.Component {
return (
<div className={rootClassName} id={id}>
{this.renderComment()}
{activeReplyBox === comment.id && this.renderReplyBox()}
{isCommentDeleted(comment) ? (
<CommentTombstone action="deleted" />
) : (
<div>
{this.renderComment()}
{activeReplyBox === comment.id && this.renderReplyBox()}
</div>
)}
{this.renderRepliesContainer()}
</div>
);
@@ -13,6 +13,8 @@ class CommentTombstone extends React.Component {
return t('framework.comment_is_ignored');
case 'reject':
return t('framework.comment_is_rejected');
case 'deleted':
return t('framework.comment_is_deleted');
default:
return t('framework.comment_is_hidden');
}
@@ -18,6 +18,10 @@ const InactiveCommentLabel = ({ status, className, ...rest }) => {
label = t('modqueue.rejected');
icon = 'close';
break;
case 'SYSTEM_WITHHELD':
label = t('modqueue.system_withheld');
icon = 'flag';
break;
default:
throw new Error(`Unknown inactive status ${status}`);
}
@@ -265,7 +265,7 @@ StreamContainer.propTypes = {
commentClassNames: PropTypes.array,
setActiveStreamTab: PropTypes.func,
postFlag: PropTypes.func,
postDontAgree: PropTypes.func,
postDontAgree: PropTypes.func.isRequired,
deleteAction: PropTypes.func,
showSignInDialog: PropTypes.func,
currentUser: PropTypes.object,
@@ -372,6 +372,7 @@ const slots = [
'streamTabsPrepend',
'streamTabPanes',
'streamFilter',
'stream',
];
const fragments = {
+2 -2
View File
@@ -177,8 +177,8 @@ button.comment__action-button[disabled],
}
.talk-plugin-flags-popup-header {
font-weight: bolder;
font-size: 1.33rem;
font-weight: bold;
font-size: 1rem;
margin-bottom: 10px;
}
@@ -43,7 +43,7 @@ const ConfigureCard = ({
);
ConfigureCard.propTypes = {
title: PropTypes.string.isRequired,
title: PropTypes.string,
className: PropTypes.string,
onCheckbox: PropTypes.func,
checked: PropTypes.bool,
+4 -1
View File
@@ -25,6 +25,9 @@ export default {
'UnsuspendUserResponse',
'UpdateAssetSettingsResponse',
'UpdateAssetStatusResponse',
'UpdateSettingsResponse'
'UpdateSettingsResponse',
'ChangePasswordResponse',
'UpdateEmailAddressResponse',
'AttachLocalAuthResponse'
),
};
+24 -1
View File
@@ -169,7 +169,7 @@ export const withSetCommentStatus = withMutation(
},
update: proxy => {
const fragment = gql`
fragment Talk_SetCommentStatus on Comment {
fragment Talk_SetCommentStatus_Comment on Comment {
status
status_history {
type
@@ -182,9 +182,11 @@ export const withSetCommentStatus = withMutation(
const data = proxy.readFragment({ fragment, id: fragmentId });
data.status = status;
data.status_history = data.status_history
? data.status_history
: [];
data.status_history.push({
__typename: 'CommentStatusHistory',
type: status,
@@ -590,6 +592,27 @@ export const withUpdateSettings = withMutation(
}
);
export const withChangePassword = withMutation(
gql`
mutation ChangePassword($input: ChangePasswordInput!) {
changePassword(input: $input) {
...ChangePasswordResponse
}
}
`,
{
props: ({ mutate }) => ({
changePassword: input => {
return mutate({
variables: {
input,
},
});
},
}),
}
);
export const withUpdateAssetSettings = withMutation(
gql`
mutation UpdateAssetSettings($id: ID!, $input: AssetSettingsInput!) {
+1
View File
@@ -6,4 +6,5 @@ export default {
username: t('error.username'),
confirmPassword: t('error.confirm_password'),
organizationName: t('error.organization_name'),
organizationContactEmail: t('error.organization_contact_email'),
};
@@ -4,4 +4,5 @@ export default {
confirmPassword: () => true,
username: username => /^[a-zA-Z0-9_]+$/.test(username),
organizationName: org => /^[a-zA-Z0-9_ ]+$/.test(org),
organizationContactEmail: email => /^.+@.+\..+$/.test(email),
};
+4 -3
View File
@@ -9,6 +9,7 @@ import 'moment/locale/da';
import 'moment/locale/de';
import 'moment/locale/es';
import 'moment/locale/fr';
import 'moment/locale/nl';
import 'moment/locale/pt-br';
import { createStorage } from 'coral-framework/services/storage';
@@ -18,10 +19,10 @@ import daTA from 'timeago.js/locales/da';
import deTA from 'timeago.js/locales/de';
import esTA from 'timeago.js/locales/es';
import frTA from 'timeago.js/locales/fr';
import nlTA from 'timeago.js/locales/nl';
import pt_BRTA from 'timeago.js/locales/pt_BR';
import zh_CNTA from 'timeago.js/locales/zh_CN';
import zh_TWTA from 'timeago.js/locales/zh_TW';
import nl from 'timeago.js/locales/nl';
import ar from '../../../locales/ar.yml';
import en from '../../../locales/en.yml';
@@ -29,10 +30,10 @@ import da from '../../../locales/da.yml';
import de from '../../../locales/de.yml';
import es from '../../../locales/es.yml';
import fr from '../../../locales/fr.yml';
import nl_NL from '../../../locales/nl_NL.yml';
import pt_BR from '../../../locales/pt_BR.yml';
import zh_CN from '../../../locales/zh_CN.yml';
import zh_TW from '../../../locales/zh_TW.yml';
import nl_NL from '../../../locales/nl_NL.yml';
const defaultLanguage = process.env.TALK_DEFAULT_LANG;
const translations = {
@@ -112,10 +113,10 @@ export function setupTranslations() {
ta.register('da', daTA);
ta.register('de', deTA);
ta.register('fr', frTA);
ta.register('nl_NL', nlTA);
ta.register('pt_BR', pt_BRTA);
ta.register('zh_CN', zh_CNTA);
ta.register('zh_TW', zh_TWTA);
ta.register('nl_NL', nl);
timeagoInstance = ta();
}
+13 -1
View File
@@ -1,6 +1,7 @@
import { gql } from 'react-apollo';
import t from 'coral-framework/services/i18n';
import union from 'lodash/union';
import get from 'lodash/get';
import { capitalize } from 'coral-framework/helpers/strings';
import assignWith from 'lodash/assignWith';
import mapValues from 'lodash/mapValues';
@@ -221,6 +222,13 @@ export function isCommentActive(commentStatus) {
return ['NONE', 'ACCEPTED'].indexOf(commentStatus) >= 0;
}
export function isCommentDeleted(comment) {
return (
get(comment, 'body', null) === null ||
get(comment, 'deleted_at', null) !== null
);
}
export function getShallowChanges(a, b) {
return union(Object.keys(a), Object.keys(b)).filter(key => a[key] !== b[key]);
}
@@ -237,7 +245,11 @@ export function getTotalReactionsCount(actionSummaries) {
// Like lodash merge but does not recurse into arrays.
export function mergeExcludingArrays(objValue, srcValue) {
if (typeof srcValue === 'object' && !Array.isArray(srcValue)) {
if (
typeof srcValue === 'object' &&
!Array.isArray(srcValue) &&
srcValue !== null
) {
return assignWith({}, objValue, srcValue, mergeExcludingArrays);
}
return srcValue;
+16
View File
@@ -1,4 +1,5 @@
import get from 'lodash/get';
import moment from 'moment';
/**
* getReliability
@@ -33,3 +34,18 @@ export const isSuspended = user => {
export const isBanned = user => {
return get(user, 'state.status.banned.status');
};
/**
* canUsernameBeUpdated
* retrieves boolean whether a username can be updated or not
*/
export const canUsernameBeUpdated = status => {
const oldestEditTime = moment()
.subtract(14, 'days')
.toDate();
return !status.username.history.some(({ created_at }) =>
moment(created_at).isAfter(oldestEditTime)
);
};
+1 -1
View File
@@ -1,5 +1,5 @@
.root {
vertical-align: middle;
vertical-align: sub;
font-size: inherit;
}
+1 -1
View File
@@ -9,7 +9,7 @@
box-sizing: border-box;
background: white;
border-radius: 3px;
padding: 20px 10px;
padding: 10px 10px;
z-index: 300;
right: 1%;
}
+36
View File
@@ -0,0 +1,36 @@
const { pluginsPath } = require('../plugins');
const buildTargets = ['coral-admin'];
const buildEmbeds = ['stream'];
const specPattern = 'client/**/__tests__/**/*.spec.js?(x)';
module.exports = {
rootDir: '../',
testMatch: [
`<rootDir>/${specPattern}`,
`<rootDir>/plugins/**/${specPattern}`,
],
setupTestFrameworkScriptFile: '<rootDir>/test/client/setupJest.js',
modulePaths: [
'<rootDir>/plugins',
'<rootDir>/client',
...buildTargets.map(target => `<rootDir>/client/${target}/src`),
...buildEmbeds.map(embed => `<rootDir>/client/coral-embed-${embed}/src`),
],
moduleFileExtensions: ['js', 'jsx', 'json', 'yaml', 'yml'],
moduleDirectories: ['node_modules'],
transform: {
'^.+\\.jsx?$': 'babel-jest',
'\\.ya?ml$': '<rootDir>/test/client/yamlTransformer.js',
},
testResultsProcessor: process.env.JEST_REPORTER,
moduleNameMapper: {
'^plugin-api\\/(.*)$': '<rootDir>/plugin-api/$1',
'^plugins\\/(.*)$': '<rootDir>/plugins/$1',
'^pluginsConfig$': pluginsPath,
'\\.(scss|css|less)$': 'identity-obj-proxy',
'\\.(gif|ttf|eot|svg)$': '<rootDir>/test/client/fileMock.js',
},
};
+7
View File
@@ -212,6 +212,13 @@ const CONFIG = {
RECAPTCHA_PUBLIC: process.env.TALK_RECAPTCHA_PUBLIC,
RECAPTCHA_SECRET: process.env.TALK_RECAPTCHA_SECRET,
// RECAPTCHA_WINDOW is the rate limit's time interval
RECAPTCHA_WINDOW: process.env.TALK_RECAPTCHA_WINDOW || '10m',
// After RECAPTCHA_INCORRECT_TRIGGER incorrect attempts, recaptcha will be required.
RECAPTCHA_INCORRECT_TRIGGER:
process.env.TALK_RECAPTCHA_INCORRECT_TRIGGER || 5,
// WEBSOCKET_LIVE_URI is the absolute url to the live endpoint.
WEBSOCKET_LIVE_URI: process.env.TALK_WEBSOCKET_LIVE_URI || null,
+3 -1
View File
@@ -41,7 +41,7 @@ relative_link: false
future: true
highlight:
enable: false
# Home page setting
# path: Root path for your blogs index page. (default = '')
# per_page: Posts displayed per page. (0 = disable pagination)
@@ -114,6 +114,8 @@ sidebar:
url: /integrating/styling-css/
- title: Translations and i18n
url: /integrating/translations-i18n/
- title: GDPR Compliance
url: /integrating/gdpr/
- title: Product Guide
children:
- title: How Talk Works
+13 -1
View File
@@ -316,6 +316,18 @@ default to providing only a time based lockout. Refer to
[reCAPTCHA](https://www.google.com/recaptcha/intro/index.html) for information
on getting an account setup.
## TALK_RECAPTCHA_WINDOW
The rate limit time interval that there can be [TALK_RECAPTCHA_INCORRECT_TRIGGER](#talk_recaptcha_incorrect_trigger) incorrect attempts until the reCAPTCHA is
marked as required, parsed by
[ms](https://www.npmjs.com/package/ms). (Default `10m`)
## TALK_RECAPTCHA_INCORRECT_TRIGGER
The number of times that an incorrect login can be entered before within a time
perioud indicated by [TALK_RECAPTCHA_WINDOW](#talk_recaptcha_window) until the
reCAPTCHA is marked as required. (Default `5`)
## TALK_REDIS_CLIENT_CONFIGURATION
Configuration overrides for the redis client configuration in a JSON encoded
@@ -531,4 +543,4 @@ Sets the logging level for the context logger (from [Bunyan](https://github.com/
A JSON string representing the configuration passed to the
[fetch](https://www.npmjs.com/package/node-fetch) call for the scraper. It
can be used to set an authorization header, or change the user agent. (Default
`{}`)
`{}`)
@@ -28,8 +28,7 @@ Plugins are additional functionality which are optional to use with Talk. You
can turn these on or off, depending on your specific needs. Plugins are either
part of our core plugins, which ship with Talk, or they are developed by 3rd
parties and either used privately and internally, or are open sourced for use
across the greater community. You can explore the plugins we offer by visiting our [Default Plugins](/talk/default-plugins/)
and [Additional Plugins](/talk/additional-plugins/) pages.
across the greater community. You can explore the plugins we offer by visiting our [Plugin Directory](/talk/plugins-directory/).
## Recipes
@@ -170,8 +170,9 @@ moderators.
All your team and commenters show in the People sub-tab. From here, you can
manage your team members roles (Admins, Moderators, Staff), as well as search
for commenters and take action on them (e.g. Ban/Un-ban, Suspend, etc.). ###
Configure
for commenters and take action on them (e.g. Ban/Un-ban, Suspend, etc.).
### Configure
See [Configuring Talk](/talk/configuring-talk/).
@@ -50,7 +50,7 @@ trying to improve a broken part of the internet.
## How do I add the Toxic Comments plugin?
To enable this behavior, visit the
[talk-plugin-toxic-comments](/talk/additional-plugins/#talk-plugin-toxic-comments)
[talk-plugin-toxic-comments](/talk/plugin/talk-plugin-toxic-comments)
plugin documentation.
+54
View File
@@ -0,0 +1,54 @@
---
title: GDPR Compliance
permalink: /integrating/gdpr/
---
In order to facilitate compliance with the
[EU General Data Protection Regulation (GDPR)](https://www.eugdpr.org/), you
can enable the following plugins:
- [talk-plugin-auth](/talk/plugin/talk-plugin-auth) - to facilitate username and password changes
- [talk-plugin-local-auth](/talk/plugin/talk-plugin-local-auth) - to facilitate email changes and email association
- [talk-plugin-profile-data](/talk/plugin/talk-plugin-profile-data) - to facilitate account download and deletion
Even if you don't reside in a location where GDPR will apply, it is recommended
to enable these features as a best practice to provide your users with control over their
own data.
## GPDR Feature Overview
Integrating our GDPR tools will give your users and organizations the following benefits:
- **Download my comment data**: Users can request a download of their comments. An email with a link is emailed to them to download a CSV with each comment they've made, what story it was made on, and the comment's ID and timestamp.
- **Delete my account**: Users can request deletion of their account. Deleted account requests are pending for 24 hours to allow the user to download their comments, or to change their mind and reactivate their account before the expiry. Account deletions remove all of their comments from the site, all their comments and actions from the database, and their account info from our system.
- **Add an email to an Oauth/external account**: Users are prompted to add an email to their non-Talk account (Facebook, Google, external, etc) so that they can take part in GDPR and other features requiring email communication.
- **Change my username**: Users can update their username. This is capped at once every 2 weeks.
- **Change my email**: Users can change their email.
- **Change my password**: Users can change their password.
## Custom Authentication Solutions
As many of the newsrooms who have integrated Talk have followed our guides on
[Integrating Authentication](/talk/integrating/authentication/), we have also
provided tools for those newsrooms to integrate GDPR features into their
existing workflows.
### Account Data
Through the [talk-plugin-profile-data](/talk/plugin/talk-plugin-profile-data)
plugin we allow users to download and delete their account data easily. For
custom integrations, this isn't always possible, so we instead provide some
GraphQL mutations designed to allow you to integrate it into your existing user
interfaces or exports.
- `downloadUser(id: ID!)` - lets you grab the direct link to download a users
account in a zip format. From there, you can integrate it into your existing
data export or simply proxy it to the user to allow them to download it
elsewhere in your UI.
- `delUser(id: ID!)` - lets you delete the specified user
**Note: These mutations require an administrative token**
If you would prefer to write your own user interfaces or integrate it into your
own, you can disable the client plugin for [talk-plugin-profile-data](/talk/plugin/talk-plugin-profile-data)
but keep the server side plugin active (See [Server and Client Plugins](/talk/plugins/#server-and-client-plugins) for more information).
@@ -70,7 +70,7 @@ The most important predictors of the success of an online community are:
* Utilize [our Toxic Comments plugin](https://blog.coralproject.net/toxic-avenging/), developed with Google Jigsaw, to improve commenter behavior and use AI to help identify and prevent the most abusive comments from appearing on your site.
* Enable our [Akismet plugin](https://coralproject.github.io/talk/additional-plugins/#talk-plugin-akismet) to keep spam from appearing in your comments.
* Enable our [Akismet plugin](/talk/plugin/talk-plugin-akismet) to keep spam from appearing in your comments.
* Use keyboard shortcuts in the moderation queue to moderate quickly (type '?' in the moderation view to see the list of shortcuts), and if there is a sudden deluge of comments, ask for someone in your newsroom to help you moderate. Talk will notify you in the moderation interface if someone else moderates a comment that's already on your screen.
* Click on a community member's name in the moderation interface to review all their comments, and see if there is a clear pattern of abuse among their Rejected comments. You can also select all their recent comments and delete them in bulk.![A screenshot of the moderation interface with the user drawer on display. Pink arrows indicate the user name, which can be clicked to open the drawer, and the drawer itself.](http://blog.coralproject.net/wp-content/uploads/2018/03/userdrawer.jpg)
@@ -83,7 +83,7 @@ The most important predictors of the success of an online community are:
![A screenshot of the comments stream with a moderation menu popped out and a large pink arrow pointing to the caret where moderators can unfold the moderation menu](http://blog.coralproject.net/wp-content/uploads/2018/03/caret-mod.jpg)
* If you find new commenters are causing a lot of trouble with their first comments, consider changing [the User Karma threshold](https://coralproject.github.io/talk/trust/) from negative one to zero, forcing every new commenter's first comment into pre-moderation.
* If you find new commenters are causing a lot of trouble with their first comments, consider changing [the User Karma threshold](/talk/trust/) from negative one to zero, forcing every new commenter's first comment into pre-moderation.
#### Effectively
+13 -1
View File
@@ -3,10 +3,17 @@
tags:
- moderation
- name: talk-plugin-auth
description: Enables internal authentication from Coral.
description: Enables internal sign-in authentication.
tags:
- default
- auth
- gdpr
- name: talk-plugin-local-auth
description: Enables email and password based authentication.
tags:
- default
- auth
- gdpr
- name: talk-plugin-author-menu
description: Enables the comment author name plugin area.
tags:
@@ -81,6 +88,11 @@
description: Shows a Link button on comments for direct-linking to a comment.
tags:
- default
- name: talk-plugin-profile-data
description: Enables users to manage their own data within Talk.
tags:
- default
- gdpr
- name: talk-plugin-remember-sort
description: Remembers the sort selection made by a user.
- name: talk-plugin-respect
+2 -2
View File
@@ -33,8 +33,7 @@ By default, Talk has various plugins provided by default. We can see this in `pl
"talk-plugin-sort-most-respected",
"talk-plugin-sort-newest",
"talk-plugin-sort-oldest",
"talk-plugin-viewing-options",
"talk-plugin-profile-settings"
"talk-plugin-viewing-options"
]
}
```
@@ -81,6 +80,7 @@ You won't have to use this to build plugins, but it's helpful to find where to e
* `adminCommentMoreDetails`
* `adminCommentLabels`
* `adminModerationSettings`
* `adminOrganizationSettings`
* `adminStreamSettings`
* `adminTechSettings`
* `adminCommentInfoBar`
+3 -3
View File
@@ -5,8 +5,8 @@ permalink: /contact/
## How can I get help integrating Talk into my newsroom?
We're here to help with newsrooms of all sizes. Email our Integration Engineer
([jeff@mozillafoundation.org](mailto:jeff@mozillafoundation.org)) to set up a meeting.
We're here to help with newsrooms of all sizes. Email our Support Team
([support@coralproject.net](mailto:support@coralproject.net)) to set up a meeting.
## How do I request a feature or submit a bug?
@@ -14,4 +14,4 @@ The best way is to [submit a GitHub issue](https://github.com/coralproject/talk/
## How can our dev team contribute to Talk?
We are lucky to work with newsroom dev teams and individual contributors who span the world, and come from newsrooms of all sizes. You can read our [Contribution Guide](https://github.com/coralproject/talk/blob/master/CONTRIBUTING.md) to get started, but feel free to reach out to us via GitHub, or get in touch directly with Jeff via jeff@mozillafoundation.org.
We are lucky to work with newsroom dev teams and individual contributors who span the world, and come from newsrooms of all sizes. You can read our [Contribution Guide](https://github.com/coralproject/talk/blob/master/CONTRIBUTING.md) to get started, but feel free to reach out to us via GitHub, or get in touch with us directly via support@coralproject.net.
+1 -2
View File
@@ -74,7 +74,6 @@ example issuer and Talk must match:
|------|----------------------|
|`JWT_ISSUER`|`JWT_ISSUER`|
|`JWT_AUDIENCE`|`JWT_AUDIENCE`|
|`JWT_AUDIENCE`|`JWT_AUDIENCE`|
|`SECRET`|`JWT_SECRET`*|
\* Note that secrets is a pretty complex topic, refer to the
@@ -83,4 +82,4 @@ reference, the basic takeaway is that the secret used to sign the tokens issued
by the issuer must be able to be verified by Talk.
For an example of implementing the plugin, refer to [`tokenUserNotFound`](/talk/reference/server/#tokenUserNotFound)
reference.
reference.
@@ -65,10 +65,6 @@ First, you'll enable `talk-plugin-author-menu`, as this houses the Ignore button
And then we will enable the Ignore User plugin: `talk-plugin-ignore-user`.
And finally, we will need to enable Profile Settings; this is the tab on My Profile > Settings where commenters can manage their Ignored Users list.
`talk-plugin-profile-settings`
### Featured Comments
To enable the featuring of comments, you'll need to activate `talk-plugin-featured-comments`. If you would like the Featured Comments tab to be the default tab you land on for the stream, you will need to set the default tab ENV variable:
-4
View File
@@ -36,10 +36,6 @@ Adding the `talk-plugin-notifications` plugin will also enable the `notification
See https://github.com/coralproject/talk/blob/8b669a31c551a042f0f079d8cfc16825673eb8f0/plugins/talk-plugin-notifications-reply/index.js for an example.
### Commenter Notification Settings
Note that notifications REQUIRE the `talk-plugin-profile-settings` plugin; this is where on My Profile commenters will enable and manage their notification settings.
### Notification Categories
Talk currently supports the following Notifications options out of the box:
+1
View File
@@ -0,0 +1 @@
../../../plugins/talk-plugin-local-auth/README.md
+1
View File
@@ -0,0 +1 @@
../../../plugins/talk-plugin-profile-data/README.md
+15 -4
View File
@@ -9,11 +9,16 @@ functionality. We provide methods to inject behavior into the server side and
the client side application to affect different parts of the application
life cycle.
## Recipes
## Server and Client Plugins
Recipes are plugin templates provided by the Coral Core team. Developers can use
these recipes to build their own plugins. You can find all the Talk recipes
here: [github.com/coralproject/talk-recipes](https://github.com/coralproject/talk-recipes/).
When you're adding a plugin to Talk, you can specify it in the `client` and/or
the `server` section. If you only want to enable the server side component of a
plugin, you simply only specify the plugin in the `server` section. If you only
want the client side plugin, the `client` section.
Plugins listed in the [Plugins Directory](/talk/plugins-directory/) will
indicate if they have/support a client/server plugin, and should be activated
accordingly.
## Plugin Registration
@@ -117,3 +122,9 @@ assets inside the image as well.
For more information on the onbuild image, refer to the
[Installation from Docker](/talk/installation-from-docker/) documentation.
## Recipes
Recipes are plugin templates provided by the Coral Core team. Developers can use
these recipes to build their own plugins. You can find all the Talk recipes
here: [github.com/coralproject/talk-recipes](https://github.com/coralproject/talk-recipes/).
+2 -1
View File
@@ -3,8 +3,9 @@ title: Plugins Directory
permalink: /plugins-directory/
layout: plugins
data: plugins
class: plugins
---
Talk provides a growing ecosystem of plugins that interact with our extensive
Server and Client API's. Below you can search for a plugin to use with Talk and
discover what their requirements and configuration are.
discover what their requirements and configuration are.
+5 -4
View File
@@ -4,9 +4,9 @@
<h1>{{ page.title }}</h1>
<hr/>
{% endif %}
{{ page.content }}
<div class="form-group mt-5">
<div class="clearfix">
<label for="exampleInputEmail1">Plugin Search</label>
@@ -15,6 +15,7 @@
<input type="text" class="form-control" id="plugin-search-input" aria-describedby="pluginSearchHelp">
<small id="pluginSearchHelp" class="form-text text-muted">Enter a few keywords about the plugin to filter the list</small>
</div>
<div class="row plugins">
{% for plugin in _.sortBy(site.data[page.data], 'name') %}
<div class="col-sm-6 plugin d-block">
@@ -25,7 +26,7 @@
{% if plugin.tags %}
<p class="card-text">
{% for tag in plugin.tags %}
<span class="badge badge-{% if tag == "default" %}success{% else %}light{% endif %}">{{ tag }}</span>
<a class="plain-link" title="Search for plugins with the {{ tag }} tag" href="?q={{ tag }}"><span class="badge badge-light badge-tag badge-tag-{{ _.kebabCase(tag) }}">{{ tag }}</span></a>
{% endfor %}
</p>
{% endif %}
@@ -35,4 +36,4 @@
{% endfor %}
</ul>
</article>
<script>window.SEARCH_INDEX = {{ lunr_index(site.data[page.data]) }}</script>
<script>window.SEARCH_INDEX = {{ lunr_index(site.data[page.data]) }}</script>
+14
View File
@@ -448,3 +448,17 @@ a.brand {
.plugin {
display: none;
}
.badge-tag {
font-family: monospace;
}
.badge-tag-default {
background: #28a745;
color: #fff;
}
.badge-tag-gdpr {
background: rgb(0, 102, 176);
color: #fff;
}
+17
View File
@@ -1,6 +1,17 @@
/* global lunr */
/* eslint-env browser */
// Sourced from https://stackoverflow.com/questions/901115/how-can-i-get-query-string-values-in-javascript
function getParameterByName(name, url) {
if (!url) url = window.location.href;
name = name.replace(/[\[\]]/g, '\\$&');
var regex = new RegExp('[?&]' + name + '(=([^&#]*)|&|#|$)'),
results = regex.exec(url);
if (!results) return null;
if (!results[2]) return '';
return decodeURIComponent(results[2].replace(/\+/g, ' '));
}
// Sourced from https://github.com/hexojs/site/blob/8e8ed4901769abbf76263125f82832df76ced58b/themes/navy/source/js/plugins.js.
(function() {
'use strict';
@@ -60,6 +71,12 @@
updateCount(elements.length);
}
var searchParam = getParameterByName('q');
if (searchParam && searchParam.length > 0) {
$input.value = searchParam;
search(searchParam);
}
$input.addEventListener('input', function() {
var value = this.value;
+9
View File
@@ -371,6 +371,14 @@ class ErrParentDoesNotVisible extends TalkError {
}
}
class ErrPasswordIncorrect extends TalkError {
constructor() {
super('Your current password was entered incorrectly', {
translation_key: 'PASSWORD_INCORRECT',
});
}
}
module.exports = {
TalkError,
ErrAlreadyExists,
@@ -395,6 +403,7 @@ module.exports = {
ErrNotFound,
ErrNotVerified,
ErrParentDoesNotVisible,
ErrPasswordIncorrect,
ErrPasswordResetToken,
ErrPasswordTooShort,
ErrPermissionUpdateUsername,
+4
View File
@@ -10,6 +10,9 @@ const secrets = require('../secrets');
// Errors.
const errors = require('../errors');
// URLs.
const url = require('../url');
// Graph.
const { getBroker } = require('./subscriptions/broker');
const { getPubsub } = require('./subscriptions/pubsub');
@@ -58,6 +61,7 @@ const defaultConnectors = {
errors,
config,
secrets,
url,
models: {
Action,
Asset,
+7
View File
@@ -137,6 +137,13 @@ class Context {
);
}
/**
* masqueradeAs will allow a given context to be copied to a new user.
*/
masqueradeAs(user) {
return new Context(merge({}, this, { user }));
}
/**
* forSystem returns a system context object that can be used for internal
* operations.
+1 -1
View File
@@ -71,7 +71,7 @@ const findOrCreateAssetByURL = async (ctx, url) => {
// Check for whitelisting + get the settings at the same time.
const [whitelisted, settings] = await Promise.all([
DomainList.urlCheck(url),
Settings.load('autoCloseStream closedTimeout'),
Settings.select('autoCloseStream', 'closedTimeout'),
]);
// If the domain wasn't whitelisted, then we shouldn't create this asset!
+24 -10
View File
@@ -94,6 +94,7 @@ const getCommentCountByQuery = (ctx, options) => {
author_id,
tags,
action_type,
excludeDeleted,
} = options;
// If user queries for statuses other than NONE and/or ACCEPTED statuses, it needs
@@ -120,6 +121,12 @@ const getCommentCountByQuery = (ctx, options) => {
query.merge({ author_id });
}
if (excludeDeleted) {
// The null query matches documents that either contain the `deleted_at`
// field whose value is null or that do not contain the `deleted_at` field.
query.merge({ deleted_at: null });
}
if (ctx.user != null && ctx.user.can(SEARCH_OTHERS_COMMENTS) && action_type) {
query.merge({
[`action_counts.${sc(action_type.toLowerCase())}`]: {
@@ -328,11 +335,12 @@ const getCommentsByQuery = async (
sortOrder,
sortBy,
excludeIgnored,
excludeDeleted,
tags,
action_type,
}
) => {
let comments = CommentModel.find();
const query = CommentModel.find();
// Enforce that the limit must be gte 0 if this option is not true.
if (!ALLOW_NO_LIMIT_QUERIES && limit < 0) {
@@ -350,11 +358,17 @@ const getCommentsByQuery = async (
}
if (statuses) {
comments = comments.where({ status: { $in: statuses } });
query.merge({ status: { $in: statuses } });
}
if (excludeDeleted) {
// The null query matches documents that either contain the `deleted_at`
// field whose value is null or that do not contain the `deleted_at` field.
query.merge({ deleted_at: null });
}
if (ctx.user != null && ctx.user.can(SEARCH_OTHERS_COMMENTS) && action_type) {
comments = comments.where({
query.merge({
[`action_counts.${sc(action_type.toLowerCase())}`]: {
$gt: 0,
},
@@ -362,7 +376,7 @@ const getCommentsByQuery = async (
}
if (ids) {
comments = comments.find({
query.merge({
id: {
$in: ids,
},
@@ -370,7 +384,7 @@ const getCommentsByQuery = async (
}
if (tags) {
comments = comments.find({
query.merge({
'tags.tag.name': {
$in: tags,
},
@@ -383,17 +397,17 @@ const getCommentsByQuery = async (
(ctx.user.can(SEARCH_OTHERS_COMMENTS) || ctx.user.id === author_id) &&
author_id != null
) {
comments = comments.where({ author_id });
query.merge({ author_id });
}
if (asset_id) {
comments = comments.where({ asset_id });
query.merge({ asset_id });
}
// We perform the undefined check because, null, is a valid state for the
// search to be with, which indicates that it is at depth 0.
if (parent_id !== undefined) {
comments = comments.where({ parent_id });
query.merge({ parent_id });
}
if (
@@ -402,12 +416,12 @@ const getCommentsByQuery = async (
ctx.user.ignoresUsers &&
ctx.user.ignoresUsers.length > 0
) {
comments = comments.where({
query.merge({
author_id: { $nin: ctx.user.ignoresUsers },
});
}
return executeWithSort(ctx, comments, { cursor, sortOrder, sortBy, limit });
return executeWithSort(ctx, query, { cursor, sortOrder, sortBy, limit });
};
/**
+55 -18
View File
@@ -1,23 +1,60 @@
const SettingsService = require('../../services/settings');
const Settings = require('../../services/settings');
const DataLoader = require('dataloader');
const { zipObject } = require('lodash');
/**
* Creates a set of loaders based on a GraphQL context.
* @param {Object} context the context of the GraphQL request
* @return {Object} object of loaders
* SettingsLoader manages loading specific fields only of the Settings object.
*/
module.exports = () => {
const loader = new DataLoader(selections =>
Promise.all(
selections.map(fields => {
return SettingsService.retrieve(fields);
})
)
);
class SettingsLoader {
constructor() {
this._loader = new DataLoader(this._batchLoadFn.bind(this));
this._cache = null;
}
return {
Settings: {
load: (fields = false) => loader.load(fields),
},
};
};
async _batchLoadFn(fields) {
// Load a settings object with all the requested fields, unless we have the
// entire object cached, in which case we'll return the whole cache.
const obj = this._cache
? await this._cache
: await Settings.select(...fields);
// Return the specific fields for each of the fields that were loaded.
return fields.map(field => obj[field]);
}
/**
* load will return the entire Settings object with all fields.
*/
load() {
if (this._cache) {
// Return the cached settings promise.
return this._cache;
}
// Create a promise that will return the settings object.
const promise = Settings.retrieve();
// Set this as the cached value.
this._cache = promise;
// Return the promised settings.
return promise;
}
/**
* select will return a promise which resolves to the Settings object that
* contains the requested fields only.
*
* @param {Array<String>} fields the fields from Settings we want to load.
*/
async select(...fields) {
// Load all the values for the specific fields.
const values = await this._loader.loadMany(fields);
// Zip up the fields and values to create an object to return and return the
// assembled Settings object.
return zipObject(fields, values);
}
}
module.exports = () => ({ Settings: new SettingsLoader() });
+9 -2
View File
@@ -14,8 +14,15 @@ const getActionItem = async (ctx, { item_id, item_type }) => {
const { loaders: { Comments, Users } } = ctx;
switch (item_type) {
case 'COMMENTS':
return Comments.get.load(item_id);
case 'COMMENTS': {
// Get a comment by ID, unless the comment is deleted, then return null.
const comment = await Comments.get.load(item_id);
if (comment.deleted_at) {
return null;
}
return comment;
}
case 'USERS':
return Users.getByID.load(item_id);
default:
+110 -51
View File
@@ -1,5 +1,9 @@
const { ErrNotFound, ErrNotAuthorized } = require('../../errors');
const UsersService = require('../../services/users');
const {
ErrNotFound,
ErrNotAuthorized,
ErrPasswordIncorrect,
} = require('../../errors');
const Users = require('../../services/users');
const migrationHelpers = require('../../services/migration/helpers');
const {
CHANGE_USERNAME,
@@ -8,11 +12,12 @@ const {
SET_USER_BAN_STATUS,
SET_USER_SUSPENSION_STATUS,
UPDATE_USER_ROLES,
DELETE_USER,
DELETE_OTHER_USER,
CHANGE_PASSWORD,
} = require('../../perms/constants');
const setUserUsernameStatus = async (ctx, id, status) => {
const user = await UsersService.setUsernameStatus(id, status, ctx.user.id);
const user = await Users.setUsernameStatus(id, status, ctx.user.id);
if (status === 'REJECTED') {
ctx.pubsub.publish('usernameRejected', user);
} else if (status === 'APPROVED') {
@@ -21,12 +26,7 @@ const setUserUsernameStatus = async (ctx, id, status) => {
};
const setUserBanStatus = async (ctx, id, status = false, message = null) => {
const user = await UsersService.setBanStatus(
id,
status,
ctx.user.id,
message
);
const user = await Users.setBanStatus(id, status, ctx.user.id, message);
if (user.banned) {
ctx.pubsub.publish('userBanned', user);
}
@@ -38,52 +38,57 @@ const setUserSuspensionStatus = async (
until = null,
message = null
) => {
const user = await UsersService.setSuspensionStatus(
id,
until,
ctx.user.id,
message
);
const user = await Users.setSuspensionStatus(id, until, ctx.user.id, message);
if (user.suspended) {
ctx.pubsub.publish('userSuspended', user);
}
};
const ignoreUser = ({ user }, userToIgnore) => {
return UsersService.ignoreUsers(user.id, [userToIgnore.id]);
return Users.ignoreUsers(user.id, [userToIgnore.id]);
};
const stopIgnoringUser = ({ user }, userToStopIgnoring) => {
return UsersService.stopIgnoringUsers(user.id, [userToStopIgnoring.id]);
return Users.stopIgnoringUsers(user.id, [userToStopIgnoring.id]);
};
const changeUsername = async (ctx, id, username) => {
const user = await UsersService.changeUsername(id, username, ctx.user.id);
const user = await Users.changeUsername(id, username, ctx.user.id);
const previousUsername = ctx.user.username;
ctx.pubsub.publish('usernameChanged', { previousUsername, user });
return user;
};
const setUsername = async (ctx, id, username) => {
return UsersService.setUsername(id, username, ctx.user.id);
return Users.setUsername(id, username, ctx.user.id);
};
const setRole = (ctx, id, role) => {
return UsersService.setRole(id, role);
return Users.setRole(id, role);
};
/**
* transforms a specific action to a removal action on the target model.
*/
const actionDecrTransformer = ({ item_id, action_type, group_id }) => ({
query: { id: item_id },
update: {
const actionDecrTransformer = ({ item_id, action_type, group_id }) => {
const update = {
$inc: {
[`action_counts.${action_type.toLowerCase()}`]: -1,
[`action_counts.${action_type.toLowerCase()}_${group_id.toLowerCase()}`]: -1,
},
},
});
};
if (group_id) {
// If the action had a groupID, also decrement that key.
update.$inc[
`action_counts.${action_type.toLowerCase()}_${group_id.toLowerCase()}`
] = -1;
}
return {
query: { id: item_id },
update,
};
};
// delUser will delete a given user with the specified id.
const delUser = async (ctx, id) => {
@@ -102,7 +107,7 @@ const delUser = async (ctx, id) => {
updateBatchSize: 10000,
});
// Remove all actions against comments.
// Remove all actions against this users comments.
await transformSingleWithCursor(
Action.collection.find({ user_id: user.id, item_type: 'COMMENTS' }),
actionDecrTransformer,
@@ -121,38 +126,86 @@ const delUser = async (ctx, id) => {
.setOptions({ multi: true })
.remove();
// Removes all the user's reply counts on each of the comments that they
// have commented on.
// Remove the user from all other user's ignore lists.
await User.update(
{ ignoresUsers: user.id },
{
$pull: { ignoresUsers: user.id },
},
{ multi: true }
);
// For each comment that the user has authored, purge the comment data from it
// and unset their id from those comments.
await transformSingleWithCursor(
Comment.collection.aggregate([
{ $match: { author_id: user.id } },
{
$group: {
_id: '$parent_id',
count: { $sum: 1 },
},
},
]),
({ _id: parent_id, count }) => ({
query: { id: parent_id },
update: {
$inc: {
reply_count: -1 * count,
},
Comment.collection.find({ author_id: user.id }),
({
id,
asset_id,
status,
parent_id,
reply_count,
created_at,
updated_at,
}) => ({
query: { id },
replace: {
id,
body: null,
body_history: [],
asset_id,
author_id: null,
status_history: [],
status,
parent_id,
reply_count,
action_counts: {},
tags: [],
metadata: {},
deleted_at: new Date(),
created_at,
updated_at,
},
}),
Comment
);
// Remove all the user's comments.
await Comment.where({ author_id: user.id })
.setOptions({ multi: true })
.remove();
// Remove the user.
await user.remove();
};
const changeUserPassword = async (ctx, oldPassword, newPassword) => {
const {
user,
loaders: { Settings },
connectors: { services: { I18n } },
} = ctx;
// Verify the old password.
const validPassword = await user.verifyPassword(oldPassword);
if (!validPassword) {
throw new ErrPasswordIncorrect();
}
// Change the users password now.
await Users.changePassword(user.id, newPassword);
// Get some context for the email to be sent.
const { organizationName, organizationContactEmail } = await Settings.select(
'organizationName',
'organizationContactEmail'
);
// Send the password change email.
await Users.sendEmail(user, {
template: 'plain',
locals: {
body: I18n.t('email.password_change.body', organizationContactEmail),
},
subject: I18n.t('email.password_change.subject', organizationName),
});
};
module.exports = ctx => {
let mutators = {
User: {
@@ -165,6 +218,7 @@ module.exports = ctx => {
setUsername: () => Promise.reject(new ErrNotAuthorized()),
stopIgnoringUser: () => Promise.reject(new ErrNotAuthorized()),
del: () => Promise.reject(new ErrNotAuthorized()),
changePassword: () => Promise.reject(new ErrNotAuthorized()),
},
};
@@ -201,9 +255,14 @@ module.exports = ctx => {
setUserSuspensionStatus(ctx, id, until, message);
}
if (ctx.user.can(DELETE_USER)) {
if (ctx.user.can(DELETE_OTHER_USER)) {
mutators.User.del = id => delUser(ctx, id);
}
if (ctx.user.can(CHANGE_PASSWORD)) {
mutators.User.changePassword = ({ oldPassword, newPassword }) =>
changeUserPassword(ctx, oldPassword, newPassword);
}
}
return mutators;
+8 -5
View File
@@ -1,4 +1,4 @@
const { decorateWithTags } = require('./util');
const { decorateWithTags, getRequestedFields } = require('./util');
const Asset = {
async comment({ id }, { id: commentId }, { loaders: { Comments } }) {
@@ -64,14 +64,17 @@ const Asset = {
return Comments.countByAssetID.load(id);
},
async settings({ settings = null }, _, { loaders: { Settings } }) {
async settings({ settings = null }, _, { loaders: { Settings } }, info) {
// Get the fields we want from the settings.
const fields = getRequestedFields(info);
// Load the global settings, and merge them into the asset specific settings
// if we have some.
let globalSettings = await Settings.load();
let globalSettings = await Settings.select(...fields);
if (settings !== null) {
settings = Object.assign({}, globalSettings.toObject(), settings);
settings = Object.assign({}, globalSettings, settings);
} else {
settings = globalSettings.toObject();
settings = globalSettings;
}
return settings;
+23 -4
View File
@@ -1,8 +1,10 @@
const { URL } = require('url');
const { property } = require('lodash');
const {
SEARCH_ACTIONS,
SEARCH_COMMENT_STATUS_HISTORY,
VIEW_BODY_HISTORY,
VIEW_COMMENT_DELETED_AT,
} = require('../../perms/constants');
const {
decorateWithTags,
@@ -22,7 +24,9 @@ const Comment = {
return Comments.get.load(parent_id);
},
user({ author_id }, _, { loaders: { Users } }) {
return Users.getByID.load(author_id);
if (author_id) {
return Users.getByID.load(author_id);
}
},
replies({ id, asset_id, reply_count }, { query }, { loaders: { Comments } }) {
// Don't bother looking up replies if there aren't any there!
@@ -54,15 +58,29 @@ const Comment = {
return Assets.getByID.load(asset_id);
},
async editing(comment, _, { loaders: { Settings } }) {
const settings = await Settings.load();
const editableUntil = new Date(
Number(new Date(comment.created_at)) + settings.editCommentWindowLength
const { editCommentWindowLength } = await Settings.select(
'editCommentWindowLength'
);
const editableUntil = new Date(
Number(new Date(comment.created_at)) + editCommentWindowLength
);
return {
edited: comment.edited,
editableUntil: editableUntil,
};
},
async url(comment, args, { loaders: { Assets } }) {
const asset = await Assets.getByID.load(comment.asset_id);
if (!asset) {
return null;
}
const assetURL = new URL(asset.url);
assetURL.searchParams.set('commentId', comment.id);
return assetURL.href;
},
};
// Decorate the Comment type resolver with a tags field.
@@ -72,6 +90,7 @@ decorateWithTags(Comment);
decorateWithPermissionCheck(Comment, {
actions: [SEARCH_ACTIONS],
status_history: [SEARCH_COMMENT_STATUS_HISTORY],
deleted_at: [VIEW_COMMENT_DELETED_AT],
});
// Protect privileged fields.
+3
View File
@@ -139,6 +139,9 @@ const RootMutation = {
delUser: async (_, { id }, { mutators: { User } }) => {
await User.del(id);
},
changePassword: async (_, { input }, { mutators: { User } }) => {
await User.changePassword(input);
},
};
module.exports = RootMutation;
+7 -3
View File
@@ -1,4 +1,4 @@
const { decorateWithPermissionCheck } = require('./util');
const { decorateWithPermissionCheck, getRequestedFields } = require('./util');
const {
SEARCH_ASSETS,
SEARCH_OTHERS_COMMENTS,
@@ -16,8 +16,12 @@ const RootQuery = {
return Assets.getByURL(query.url);
},
settings(_, args, { loaders: { Settings } }) {
return Settings.load();
settings(_, args, { loaders: { Settings } }, info) {
// Get the fields we want from the settings.
const fields = getRequestedFields(info);
// Load only the requested fields.
return Settings.select(...fields);
},
// This endpoint is used for loading moderation queues, so hide it in the
+6 -1
View File
@@ -2,7 +2,8 @@ const {
ADD_COMMENT_TAG,
SEARCH_OTHER_USERS,
} = require('../../perms/constants');
const { property, isBoolean } = require('lodash');
const { property, isBoolean, pull } = require('lodash');
const graphqlFields = require('graphql-fields');
/**
* getResolver will get the resolver from the typeResolver or apply the default
@@ -207,7 +208,11 @@ const decorateWithTags = (
};
};
const getRequestedFields = info =>
pull(Object.keys(graphqlFields(info)), '__typename');
module.exports = {
getRequestedFields,
decorateUserField,
decorateWithTags,
decorateWithPermissionCheck,
+42 -2
View File
@@ -418,6 +418,9 @@ input CommentsQuery {
# Exclude comments ignored by the requesting user
excludeIgnored: Boolean
# excludeDeleted when true will exclude deleted comments from the response.
excludeDeleted: Boolean = false
}
input RepliesQuery {
@@ -434,6 +437,9 @@ input RepliesQuery {
# Exclude comments ignored by the requesting user
excludeIgnored: Boolean
# excludeDeleted when true will exclude deleted comments from the response.
excludeDeleted: Boolean = false
}
# CommentCountQuery allows the ability to query comment counts by specific
@@ -463,6 +469,9 @@ input CommentCountQuery {
# Filter by a specific tag name.
tags: [String!]
# excludeDeleted when true will exclude deleted comments from the count.
excludeDeleted: Boolean = false
}
# UserCountQuery allows the ability to query user counts by specific
@@ -503,7 +512,7 @@ type Comment {
id: ID!
# The actual comment data.
body: String!
body: String
# The body history of the comment. Requires the `ADMIN` or `MODERATOR` role or
# the author.
@@ -519,7 +528,7 @@ type Comment {
replies(query: RepliesQuery = {}): CommentConnection!
# replyCount is the number of replies with a depth of 1. Only direct replies
# to this comment are counted.
# to this comment are counted. Deleted comments are included in this count.
replyCount: Int
# Actions completed on the parent. Requires the `ADMIN` role.
@@ -537,6 +546,9 @@ type Comment {
# The status history of the comment. Requires the `ADMIN` or `MODERATOR` role.
status_history: [CommentStatusHistory!]
# The date that the comment was deleted at if it was.
deleted_at: Date
# The time when the comment was created
created_at: Date!
@@ -548,6 +560,9 @@ type Comment {
# Indicates if it has a parent
hasParent: Boolean
# url is the permalink to this particular Comment on the Asset.
url: String
}
# CommentConnection represents a paginable subset of a comment list.
@@ -835,6 +850,9 @@ type Settings {
# organizationName is the name of the organization.
organizationName: String
# organizationContactEmail is the email of the organization.
organizationContactEmail: String
# wordlist will return a given list of words.
wordlist: Wordlist
@@ -1291,6 +1309,9 @@ input UpdateSettingsInput {
# organizationName is the name of the organization.
organizationName: String
# organizationContactEmail is the email of the organization.
organizationContactEmail: String
# editCommentWindowLength is the length of time (in milliseconds) after a
# comment is posted that it can still be edited by the author.
editCommentWindowLength: Int
@@ -1433,6 +1454,21 @@ type DelUserResponse implements Response {
errors: [UserError!]
}
input ChangePasswordInput {
# oldPassword is the previous password set on the account. An incorrect
# password here will result in an unauthorized error being thrown.
oldPassword: String!
# newPassword is the password we're changing it to.
newPassword: String!
}
type ChangePasswordResponse implements Response {
# An array of errors relating to the mutation that occurred.
errors: [UserError!]
}
# All mutations for the application are defined on this object.
type RootMutation {
@@ -1533,6 +1569,10 @@ type RootMutation {
# delUser will delete the user with the specified id.
delUser(id: ID!): DelUserResponse
# changePassword allows the current user to change their password that have an
# associated local user account.
changePassword(input: ChangePasswordInput!): ChangePasswordResponse
}
type UsernameChangedPayload {
+5 -37
View File
@@ -1,40 +1,8 @@
const path = require('path');
const { pluginsPath } = require('./plugins');
const buildTargets = ['coral-admin'];
const buildEmbeds = ['stream'];
// jest.config.js
module.exports = {
testMatch: ['**/client/**/__tests__/**/*.js?(x)'],
setupTestFrameworkScriptFile: '<rootDir>/test/client/setupJest.js',
modulePaths: [
'<rootDir>/plugins',
'<rootDir>/client',
...buildTargets.map(target =>
path.join('<rootDir>', 'client', target, 'src')
),
...buildEmbeds.map(embed =>
path.join('<rootDir>', 'client', `coral-embed-${embed}`, 'src')
),
],
moduleFileExtensions: ['js', 'jsx', 'json', 'yaml', 'yml'],
moduleDirectories: ['node_modules'],
transform: {
'^.+\\.jsx?$': 'babel-jest',
'\\.ya?ml$': '<rootDir>/test/client/yamlTransformer.js',
},
projects: ['<rootDir>', '<rootDir>/client'],
testPathIgnorePatterns: ['client'],
setupTestFrameworkScriptFile: '<rootDir>/test/setupJest.js',
testResultsProcessor: process.env.JEST_REPORTER,
moduleNameMapper: {
'^plugin-api\\/(.*)$': '<rootDir>/plugin-api/$1',
'^plugins\\/(.*)$': '<rootDir>/plugins/$1',
'^pluginsConfig$': pluginsPath,
'\\.(scss|css|less)$': 'identity-obj-proxy',
'\\.(gif|ttf|eot|svg)$': '<rootDir>/test/client/fileMock.js',
},
testEnvironment: 'node',
modulePaths: ['<rootDir>'],
};
+3 -2
View File
@@ -438,8 +438,8 @@ ar:
reports: "Reports"
all: "All"
rejected: "Rejected"
account_history: "Account History"
account_history:
user_history: "User History"
user_history:
user_banned: "User banned"
ban_removed: "Ban removed"
username_status: "Username {0}"
@@ -466,6 +466,7 @@ ar:
username: "Username"
password: "Password"
confirm_password: "Confirm Password"
organization_contact_email: "Organization Contact Email"
save: "Save"
permitted_domains:
title: "Permitted domains"
+3 -2
View File
@@ -431,8 +431,8 @@ da:
reports: "Rapporter"
all: "Alle"
rejected: "Afvist"
account_history: "Konto historik"
account_history:
user_history: "Konto historik"
user_history:
user_banned: "Bruger bannet"
ban_removed: "Ban fjernet"
username_status: "Brugernavn {0}"
@@ -459,6 +459,7 @@ da:
username: "Brugernavn"
password: "Kodeord"
confirm_password: "Bekræft kodeord"
organization_contact_email: "Organization Contact Email"
save: "Gem"
permitted_domains:
title: "Tilladte domæner"
+3 -2
View File
@@ -430,8 +430,8 @@ de:
reports: "Meldungen"
all: "Alle"
rejected: "Abgelehnte"
account_history: "Konto-Verlauf"
account_history:
user_history: "Konto-Verlauf"
user_history:
user_banned: "User banned"
ban_removed: "Ban removed"
username_status: "Username {0}"
@@ -458,6 +458,7 @@ de:
username: "Nutzername"
password: "Passwort"
confirm_password: "Passwort bestätigen"
organization_contact_email: "Organization Contact Email"
save: "Speichern"
permitted_domains:
title: "Zugelassene Domains"
+30 -9
View File
@@ -20,11 +20,13 @@ en:
bio_offensive: "This bio is offensive"
cancel: "Cancel"
confirm_email:
click_to_confirm: "Click below to confirm your email address"
email_confirmation: "Email Confirmation"
click_to_confirm: "Click below to confirm your email address."
confirm: "Confirm"
password_reset:
mail_sent: 'If you have a registered account, a password reset link was sent to that email'
set_new_password: "Change Your Password"
change_password_help: "Please enter a new password to use to login. Make it secure!"
new_password: "New Password"
new_password_help: "Password must be at least 8 characters"
confirm_new_password: "Confirm New Password"
@@ -121,9 +123,10 @@ en:
custom_css_url: "Custom CSS URL"
custom_css_url_desc: "URL of a CSS stylesheet that will override default Embed Stream styles. Can be internal or external."
days: Days
description: "As an admin, you can customize the settings for the comment stream for this story:"
description: "Change the comment settings on this story."
domain_list_text: "Enter the domains you would like to permit for Talk e.g. your local staging and production environments (ex. localhost:3000 staging.domain.com domain.com)."
domain_list_title: "Permitted Domains"
edit_info: "Edit Info"
edit_comment_timeframe_heading: "Edit Comment Timeframe"
edit_comment_timeframe_text_pre: "Commenters will have"
edit_comment_timeframe_text_post: "seconds to edit their comments."
@@ -149,6 +152,7 @@ en:
open_stream_configuration: "This comment stream is currently open. By closing this comment stream no new comments may be submitted and all previous comments will still be displayed."
require_email_verification: "Require Email Verification"
require_email_verification_text: "New Users must verify their email before commenting"
save: Save
save_changes: "Save Changes"
shortcuts: Shortcuts
sign_out: "Sign Out"
@@ -158,6 +162,12 @@ en:
suspect_word_title: "Suspect words list"
suspect_word_text: "Comments which contain these words or phrases (not case-sensitive) will be highlighted in the comment stream. Type a word and press Enter or Tab to add. Optionally paste a comma-separated list."
tech_settings: "Tech Settings"
organization_information: "Organization information"
organization_info_copy: "We use this information in email notifications generated by Talk. This connects the messages to your organization, and provides a way for users to contact you if they have an issue with their account."
organization_info_copy_2: "We recommend creating a generic email account (eg. community@yournewsroom.com) for this purpose. This means it can remain consistent over time, and doesn't expose a name that users could target if their account were blocked."
organization_details: "Organization Details"
organization_name: "Organization Name"
organization_contact_email: "Organization Contact Email"
title: "Configure Comment Stream"
weeks: Weeks
wordlist: "Banned Words"
@@ -208,9 +218,14 @@ en:
we_received_a_request: "We received a request to reset your password. If you did not request this change, you can ignore this email."
if_you_did: "If you did,"
please_click: "please click here to reset password"
subject: "Password reset"
password_change:
subject: "{0} password change"
body: "The password on your account has been changed.\n\nIf you did not request this change, please contact us at {0}."
embedlink:
copy: "Copy to Clipboard"
error:
PASSWORD_INCORRECT: "Your current password was entered incorrectly"
COMMENT_PARENT_NOT_VISIBLE: "The comment that you're replying to has been removed or doesn't exist."
EMAIL_VERIFICATION_TOKEN_INVALID: "Email verification token is invalid."
EMAIL_ALREADY_VERIFIED: "Email address already verified."
@@ -223,7 +238,7 @@ en:
RATE_LIMIT_EXCEEDED: "Rate limit exceeded"
USERNAME_IN_USE: "Username already in use"
USERNAME_REQUIRED: "Must input a username"
EMAIL_NOT_VERIFIED: "E-mail address not verified"
EMAIL_NOT_VERIFIED: "Email address not verified"
EDIT_WINDOW_ENDED: "You can no longer edit this comment. The time window to do so has expired."
EDIT_USERNAME_NOT_AUTHORIZED: "You do not have permission to update your username."
SAME_USERNAME_PROVIDED: "You must submit a different username."
@@ -236,12 +251,15 @@ en:
ALREADY_EXISTS: "Resource already exists"
INVALID_ASSET_URL: "Assert URL is invalid"
CANNOT_IGNORE_STAFF: "Cannot ignore Staff members."
email: "Not a valid E-Mail"
INCORRECT_PASSWORD: "Incorrect Password"
email: "Please enter a valid email."
DELETION_NOT_SCHEDULED: "Deletion was not scheduled"
confirm_password: "Passwords don't match. Please check again"
network_error: "Failed to connect to server. Check your internet connection and try again."
email_not_verified: "E-mail address {0} not verified."
email_password: "E-mail and/or password combination incorrect."
email_not_verified: "Email address {0} not verified."
email_password: "Email and/or password combination incorrect."
organization_name: "Organization name must only contain letters or numbers."
organization_contact_email: "Organization email is not valid."
password: "Password must be at least 8 characters"
username: "Usernames can contain letters numbers and _ only"
unexpected: "Unexpected error occurred. Sorry!"
@@ -256,6 +274,7 @@ en:
comment: comment
comment_is_ignored: "This comment is hidden because you ignored this user."
comment_is_rejected: "You have rejected this comment."
comment_is_deleted: "This comment was deleted."
comment_is_hidden: "This comment is not available."
comments: comments
configure_stream: "Configure"
@@ -344,6 +363,7 @@ en:
sort: "Sort"
show_shortcuts: "Show Shortcuts"
singleview: "Zen mode"
system_withheld: "System Withheld"
thismenu: "Open this menu"
jump_to_queue: "Jump to specific queue"
thousand: k
@@ -426,7 +446,7 @@ en:
title_reject: "We noticed you rejected a username"
suspend_user: "Suspend User"
yes_suspend: "Yes suspend"
email_message_reject: "Another member of the community recently flagged your username for review. Because of its content your user was rejected. This means you can no longer comment, like, or flag content until you rewrite your username. Please e-mail us if you have any questions or concerns."
email_message_reject: "Another member of the community recently flagged your username for review. Because of its content your user was rejected. This means you can no longer comment, like, or flag content until you rewrite your username. Please email us if you have any questions or concerns."
write_message: "Write a message"
send: Send
thank_you: "We value your safety and feedback. A moderator will review your report."
@@ -446,8 +466,8 @@ en:
reports: "Reports"
all: "All"
rejected: "Rejected"
account_history: "Account History"
account_history:
user_history: "User History"
user_history:
user_banned: "User banned"
ban_removed: "Ban removed"
username_status: "Username {0}"
@@ -474,6 +494,7 @@ en:
username: "Username"
password: "Password"
confirm_password: "Confirm Password"
organization_contact_email: "Organization Contact Email"
save: "Save"
permitted_domains:
title: "Permitted domains"
+76 -63
View File
@@ -16,26 +16,27 @@ es:
send: "Enviar"
notify_ban_headline: "Notificar al usuario de la suspensión"
notify_ban_description: "Esto notificará al usuario por email que fueron suspendidos de la comunidad"
email_message_ban: "Dear {0},\n\nSomeone with access to your account has violated our community guidelines. As a result, your account has been banned. You will no longer be able to comment, like or report comments. if you think this has been done in error, please contact our community team."
email_message_ban: "Estimado/a {0},\n\nUsted o alguien con acceso a su cuenta a violado los lineamientos de nuestra comunidad. Como consecuencia de esto, su cuenta fue bloqueada. No podrá realizar ni reportar más comentarios. Si usted piensa que esto ha sido un error, por favor contáctese con nosotros."
bio_offensive: "Esta biografia es ofensiva"
cancel: Cancelar
confirm_email:
click_to_confirm: "Click below to confirm your email address"
confirm: "Confirm"
click_to_confirm: "Haga click debajo para confirmar su dirección de email"
confirm: "Confirmar"
password_reset:
set_new_password: "Change Your Password"
new_password: "New Password"
new_password_help: "Password must be at least 8 characters"
confirm_new_password: "Confirm New Password"
change_password: "Change Password"
characters_remaining: "carácteres restantes"
mail_sent: 'Si tiene una cuenta registrada, un enlace para resetear su clave ha sido enviado a esa dirección de correo.'
set_new_password: "Cambie su contraseña"
new_password: "Nueva contraseña"
new_password_help: "La contraseña debe tener al menos 8 caracteres"
confirm_new_password: "Confirme su nueva contraseña"
change_password: "Cambio de contraseña"
characters_remaining: "caracteres restantes"
comment:
anon: Anónimo
undo_reject: "Undo"
undo_reject: "Deshacer"
ban_user: "Usuario Suspendido"
comment: "Publicar un comentario"
edited: Editado
flagged: reportado
flagged: Reportado
view_context: "Ver contexto"
comment_box:
post: "Publicar"
@@ -62,16 +63,16 @@ es:
reactions: 'reacciones'
story: 'Artículo'
flagged_usernames:
notify_approved: '{0} approved username {1}'
notify_rejected: '{0} rejected username {1}'
notify_flagged: '{0} reported username {1}'
notify_changed: 'user {0} changed their username to {1}'
notify_approved: '{0} ha aprobado el nombre de usuario {1}'
notify_rejected: '{0} ha rechazado el nombre de usuario {1}'
notify_flagged: '{0} ha reportado el nombre de usuario {1}'
notify_changed: 'El usuario {0} ha modificado su nombre de usuario por {1}'
community:
account_creation_date: "Fecha de creación de la cuenta"
active: Activa
admin: Administrator
ads_marketing: "This looks like an ad/marketing"
are_you_sure: "¿Estas segura que quieres suspender a {0}?"
ads_marketing: "Esto parece ser un ad/marketing"
are_you_sure: "¿Estás segura que quieres suspender a {0}?"
ban_user: "¿Quieres suspender al Usuario?"
banned: Suspendido
banned_user: "Usuario Suspendido"
@@ -120,9 +121,10 @@ es:
custom_css_url: "URL CSS a medida"
custom_css_url_desc: "URL de una hoja de estilo que va a sobrescribir los estilos por defecto del hilo de comentarios. Puede ser interna o externa."
days: Días
description: "Como Administrador/a puedes modificar la configuración de los comentarios en este artículo"
description: "Modificar la configuración de los comentarios en este artículo."
domain_list_text: "Agrega dominios permitidos a Talk, por ejemplo tu localhost, staging y ambientes de producción (ej. localhost:3000, staging.domain.com, domain.com)."
domain_list_title: "Dominios Permitidos"
edit_info: "Editar Información"
edit_comment_timeframe_heading: "Periodo de Tiempo para Edición del Comentario"
edit_comment_timeframe_text_pre: "Los comentaristas tendrán"
edit_comment_timeframe_text_post: "segundos para editar sus comentarios."
@@ -148,6 +150,7 @@ es:
open_stream_configuration: "Este hilo de comentarios está abierto. Al cerrarlo no se podrán publicar nuevos comentarios pero todos los comentarios anteriores aún serán mostrados."
require_email_verification: "Necesita confirmación su correo"
require_email_verification_text: "Nuevos usuarios deben confirmar sus correos antes de comentar"
save: Guardar
save_changes: "Guardar Cambios"
shortcuts: Atajos
sign_out: "Desconectar"
@@ -157,6 +160,12 @@ es:
suspect_word_title: "Lista de palabras sospechosas"
suspect_word_text: "Comentarios que contengan estas palabras o frases, considerando mayusculas y minúsculas, serán automáticamente destacadas en los comentarios publicados. Escribir una palabra y apretar Enter o Tabulador para agregarla. O pegar una lista de palabras separadas por coma."
tech_settings: "Configuración Técnica"
organization_information: "Información de la Organización"
organization_details: "Detalles de la Organización"
organization_info_copy: "Nosotros usamos esta información en las notificaciones de email generadas por Talk. Esto conecta los mensajes de tu organización, y provee una forma para que los usuarios se comuniquen si tienen un inconveniente con su cuenta."
organization_info_copy_2: "Recomendamos crear un email genérico (ej: community@yournewsroom.com) for this purpose. Esto significa que puede permanecer consistente con el tiempo y no expone un nombre que los usuarios puedan atacar si su cuenta fue bloqueada."
organization_name: "Nombre de la Organización"
organization_contact_email: "Email de la Organización"
title: "Configurar los comentarios"
weeks: Semanas
wordlist: "Palabras Suspendidas"
@@ -193,10 +202,10 @@ es:
minutes_plural: "minutos"
email:
suspended:
subject: "Your account has been suspended"
subject: "Su cuenta ha sido suspendida"
banned:
subject: "Your account has been banned"
body: "In accordance with The Coral Projects community guidelines, your account has been banned. You are now longer allowed to comment, flag or engage with our community."
subject: "Su cuenta ha sido bloqueada"
body: "De acuerdo con las guías de comunidad de The Coral Project, su cuenta a sido bloqueada. No podrá hacer comentarios, reportar o entrar en contacto con nuestra comunidad."
confirm:
has_been_requested: "Un correo de confirmación ha sido pedido para la siguiente cuenta:"
to_confirm: "Para confirmar la cuenta, por favor visitar el siguiente enlace:"
@@ -207,12 +216,13 @@ es:
we_received_a_request: "Recibimos un pedido para resetear su contraseña. Si no ha pedido ese cambio, por favor ignorar el correo. "
if_you_did: "Si lo hizo,"
please_click: "por favor cliquea aqui para resetear la contraseña."
subject: "Recuperar contraseña"
embedlink:
copy: "Copiar al portapapeles"
error:
COMMENT_PARENT_NOT_VISIBLE: "El comentario a la que estás contestando ha sido eliminado o no existe."
EMAIL_VERIFICATION_TOKEN_INVALID: "Email verification token is invalid."
PASSWORD_RESET_TOKEN_INVALID: "Your password reset link is invalid."
EMAIL_VERIFICATION_TOKEN_INVALID: "El token de verificación de su cuenta de correo es inválido."
PASSWORD_RESET_TOKEN_INVALID: "El enlace para resetear su clave es inválido."
COMMENT_TOO_SHORT: "Tu comentario debe tener algo escrito"
NOT_AUTHORIZED: "Acción no autorizada."
NO_SPECIAL_CHARACTERS: "Los nombres pueden contener letras números y _"
@@ -221,30 +231,32 @@ es:
RATE_LIMIT_EXCEEDED: "Rate limit exceeded"
USERNAME_IN_USE: "Este nombre ya está siendo usado."
USERNAME_REQUIRED: "Debe ingresar un nombre"
EMAIL_NOT_VERIFIED: "E-mail address not verified"
EDIT_WINDOW_ENDED:: "No puedes editar este comentario. El tiempo de edición ha expirado."
EMAIL_NOT_VERIFIED: "La cuenta de email no ha sido verificada."
EDIT_WINDOW_ENDED: "No puedes editar este comentario. El tiempo de edición ha expirado."
EDIT_USERNAME_NOT_AUTHORIZED: "No tiene permiso para editar el nombre de usuario."
SAME_USERNAME_PROVIDED: "You must submit a different username."
SAME_USERNAME_PROVIDED: "Debe proporcinar un nombre de usuario diferente."
EMAIL_IN_USE: "Este correo se encuentra en uso"
EMAIL_REQUIRED: "Se requiere un correo"
LOGIN_MAXIMUM_EXCEEDED: "Ha realizado demasiados intentos fallidos de usar la contraseña. Por favor espere."
PASSWORD_REQUIRED: "Debe ingresar la contraseña"
COMMENTING_CLOSED: "Los comentarios ya estan cerrados"
NOT_FOUND: "Recurso no encontrado"
ALREADY_EXISTS: "Resource already exists"
ALREADY_EXISTS: "El recurso ya existe"
INVALID_ASSET_URL: "La URL del articulo no es valida"
CANNOT_IGNORE_STAFF: "Cannot ignore Staff members."
CANNOT_IGNORE_STAFF: "No puede ignorar a miembros del Staff."
INCORRECT_PASSWORD: "Contraseña Incorrecta"
email: "No es un correo válido"
confirm_password: "Las contraseñas no coinciden. Inténtelo nuevamente"
network_error: "Error al conectar con el servidor. Compruebe su conexión a Internet y vuelva a intentarlo."
email_not_verified: "Correo {0} no confirmado."
email_password: "Correo y/o contraseña incorrecta."
organization_name: "El nombre de la organización debe contener letras y/o números."
organization_contact_email: "El email de la organización no es válido."
password: "La contraseña debe tener por lo menos 8 caracteres"
username: "Los nombres pueden contener letras números y _"
required_field: "Este campo es requerido"
unexpected: "Lo siento. Ha habido un error no previsto."
temporarily_suspended: "Your account is currently suspended. It will be reactivated {0}. Please contact us if you have any questions."
unexpected: "Lo siento. Ha ocurrido un error no previsto."
temporarily_suspended: "Su cuenta fue suspendida. Será reactivada {0}. Si tiene preguntas, por favor contáctese con nosotros."
flag_comment: "Reportar este comentario"
flag_reason: "Razón por la que hacer este reporte (Opcional)"
flag_username: "Reportar el nombre de usuario"
@@ -264,7 +276,7 @@ es:
label: "Nuevo Nombre"
msg: "Tu cuenta está suspendida porque tu nombre de usuario ha sido considerado no apropiado para el espacio. Para recuperar la cuenta, por favor ingresar un nuevo nombre de usuario. Contáctanos si tienes alguna pregunta."
changed_name:
msg: "Your username change is under review by our moderation team."
msg: "El cambio en su nombre de usuario está siendo revisado por nuestro equipo de moderación."
my_comments: "Mis Comentarios"
my_profile: "Mi perfil"
new_count: "Ver {0} más {1} "
@@ -295,9 +307,9 @@ es:
comment_spam: "Contiene spam"
comment_noagree: "No está de acuerdo"
comment_other: "Otra razón"
suspect_word: "Suspect Word"
banned_word: "Banned Word"
body_count: "Body exceeds max length"
suspect_word: "Palabra sospechosa"
banned_word: "Palabra prohibida"
body_count: "El texto exede el límite permitido"
trust: "Trust"
links: "Link"
modqueue:
@@ -305,14 +317,14 @@ es:
actions: Acciones
all: todos
all_streams: "Todos los Hilos"
notify_edited: '{0} edited comment "{1}"'
notify_accepted: '{0} accepted comment "{1}"'
notify_rejected: '{0} rejected comment "{1}"'
notify_flagged: '{0} flagged comment "{1}"'
notify_reset: '{0} reset status of comment "{1}"'
notify_edited: '{0} ha editado el comentario "{1}"'
notify_accepted: '{0} ha aceptado el comentario "{1}"'
notify_rejected: '{0} ha rechazado el comentario "{1}"'
notify_flagged: '{0} ha reportado el comentario "{1}"'
notify_reset: '{0} ha reseteado el status del comentario "{1}"'
approve: "Aprobar"
approved: "Aprobado"
ban_user: "Ban"
ban_user: "Bloquear"
billion: B
close: Cerrar
empty_queue: "¡No hay más comentarios para moderar! Tiempo para un ☕️"
@@ -352,7 +364,7 @@ es:
no_agree_comment: "No estoy de acuerdo con este comentario"
no_like_bio: "No me gusta esta biografia"
no_like_username: "No me gusta este nombre de usuario"
already_flagged_username: "You have already flagged this username."
already_flagged_username: "Usted ya reportó a este usuario."
other: Otro
permalink: Compartir
personal_info: "Este comentario muestra información personal"
@@ -428,28 +440,28 @@ es:
user_bio: "Bio de Usuario"
username_flags: "reportes para este nombre de usuario"
user_detail:
remove_suspension: "Remove Suspension"
suspend: "Suspend User"
remove_ban: "Remove Ban"
ban: "Ban User"
member_since: "Member Since"
remove_suspension: "Cancelar suspensión"
suspend: "Suspender usuario"
remove_ban: "Cancelar bloqueo"
ban: "Bloquear usuario"
member_since: "Miembro desde"
email: "Email"
total_comments: "Total Comments"
total_comments: "Comentarios totales"
reject_rate: "Reject Rate"
reports: "Reports"
all: "All"
rejected: "Rejected"
account_history: "Account History"
account_history:
user_banned: "User banned"
ban_removed: "Ban removed"
username_status: "Username {0}"
suspended: "Suspended, {0}"
suspension_removed: "Suspension removed"
system: "System"
date: "Date"
action: "Action"
taken_by: "Taken By"
reports: "Reportes"
all: "Todo"
rejected: "Rechazar"
user_history: "Historial del usuario"
user_history:
user_banned: "Usuario bloqueado"
ban_removed: "Bloqueo cancelado"
username_status: "Nombre de usuario {0}"
suspended: "Suspendido, {0}"
suspension_removed: "Suspensión cancelada"
system: "Sistema"
date: "Fecha"
action: "Acción"
taken_by: "Está en uso"
user_impersonating: "Este usuario suplanta a alguien"
user_no_comment: "No has dejado aún ningún comentario. ¡Únete a la conversación!"
username_offensive: "Este nombre de usuario es ofensivo"
@@ -467,6 +479,7 @@ es:
username: "Nombre de Usuario"
password: "Contraseña"
confirm_password: "Confirmar Contraseña"
organization_contact_email: "Organización: Email de contacto"
save: "Guardar"
permitted_domains:
title: "Dominios permitidos"
@@ -477,5 +490,5 @@ es:
launch: "Iniciar Talk"
close: "Cerrar este instalador"
admin_sidebar:
view_options: "View Options"
sort_comments: "Sort Comments"
view_options: "Ver opciones"
sort_comments: "Ordenar comentarios"
+2 -1
View File
@@ -121,7 +121,7 @@ fr:
custom_css_url: "URL CSS personnalisée"
custom_css_url_desc: "URL d'une feuille de style CSS qui remplacera les styles par défaut d'intégration des commentaires. Peut être interne ou externe."
days: Journées
description: "En tant qu'administrateur, vous pouvez personnaliser les paramètres du fil de commentaires pour cet élément."
description: "Personnaliser les paramètres du fil de commentaires pour cet élément."
domain_list_text: "Entrez les domaines que vous souhaitez autoriser pour Talk, par exemple vos environnements locaux de production et de production (ex : localhost: 3000 staging.domain.com domain.com)."
domain_list_title: "Domaines autorisés"
edit_comment_timeframe_heading: "Modifier l'horodatage des commentaires"
@@ -474,6 +474,7 @@ fr:
username: "Nom d'utilisateur"
password: "Mot de passe"
confirm_password: "Confirmez Le mot de passe"
organization_contact_email: "Organization Contact Email"
save: "Sauvegarder"
permitted_domains:
title: "Domaines autorisés"
+2 -2
View File
@@ -431,8 +431,8 @@ nl_NL:
reports: "Rapportages"
all: "Alle"
rejected: "Afgewezen"
account_history: "Accountgeschiedenis"
account_history:
user_history: "Accountgeschiedenis"
user_history:
user_banned: "User banned"
ban_removed: "Ban removed"
username_status: "Username {0}"
+4 -3
View File
@@ -120,7 +120,7 @@ pt_BR:
custom_css_url: "URL para CSS customizado"
custom_css_url_desc: "URL de uma folha de estilo CSS para substituir os estilos padrão dos comentários embutidos. Pode ser interno ou externo."
days: Dias
description: "Como administrador, você pode personalizar as configurações da lista de comentários para esta história:"
description: "Personalizar as configurações da lista de comentários para esta história."
domain_list_text: "Insira os domínios que você gostaria de permitir para o Talk, como seus ambientes de desenvolvimento, teste ou produção (ej. localhost:3000 staging.domain.com domain.com)."
domain_list_title: "Domínios permitidos"
edit_comment_timeframe_heading: "Período de tempo para editar comentários"
@@ -430,8 +430,8 @@ pt_BR:
reports: "Reports"
all: "All"
rejected: "Rejected"
account_history: "Account History"
account_history:
user_history: "User History"
user_history:
user_banned: "User banned"
ban_removed: "Ban removed"
username_status: "Username {0}"
@@ -458,6 +458,7 @@ pt_BR:
username: "Nome de usuário"
password: "Senha"
confirm_password: "Confirme a senha"
organization_contact_email: "Organization Contact Email"
save: "Salvar"
permitted_domains:
title: "Domínios permitidos"
+2 -2
View File
@@ -432,8 +432,8 @@ zh_CN:
reports: "Reports"
all: "All"
rejected: "Rejected"
account_history: "Account History"
account_history:
user_history: "User History"
user_history:
user_banned: "User banned"
ban_removed: "Ban removed"
username_status: "Username {0}"

Some files were not shown because too many files have changed in this diff Show More