Commit Graph
1331 Commits
Author SHA1 Message Date
a1a8652f7e [CORL 547] org-wide announcements (#2813)
* CRUD announcements

* only show announcement if not disabled

* make announcements dismissable

* add announcement mutations

* update announcement form logic

* style announcements on stream

* update snap

* localize strings

* close form if announcement is removed

* move announcement config below sitewide commenting config

* move date calculation inside useMemo

* move announcementconfig code to announcementconfigcontainer

* use coralContext for localStorage

* fix type of announcement createdAt

* move announcement form to modal

* remove payload pruning from configure route

* simplify announcement display logic

* make validation message full width

Co-authored-by: Kim Gardner <kgardnr@gmail.com>
2020-02-03 13:12:25 -05:00
a7b2af85fc fix: fixes bug related to migration error (#2816)
When a user did not have any comments when the migration 1575649180000
hits, they are not migrated to get a `commentCounts` property. This
migration finds those users without `commentCounts` and sets them to the
empty comment counts.

Co-authored-by: Kim Gardner <kgardnr@gmail.com>
2020-01-30 18:53:34 -05:00
516611e289 fix: set access token only once (#2815)
Co-authored-by: Kim Gardner <kgardnr@gmail.com>
2020-01-30 18:37:26 -05:00
Tessa ThorntonandGitHub 190010c898 change marker variant for suspect word badge (#2814) 2020-01-30 18:23:42 -05:00
VinhandGitHub 2b1c9aea78 [CORL-832] IE11 Compatibility for the Embed Stream (#2801)
* IE11 support

* fix: types and tests

* chore+fix: optimise polyfills and bugfixes for ie11

* chore+fix: fix docz, radically cleanup babel configs

* fix: ie11 proxy bug

* feat: normalize rte html

* fix: css issues in ie11

* chore: improve bundle size

* chore: upgrade coral rte

* feat: make counts work in ie11

* fix: remove native password reveal in ie11

* fix: markdowneditor icons in ie11

* fix: ie11 brittleness in auth popup

* fix: callout width in ie11

* test: fix snapshots
2020-01-29 17:42:32 -05:00
Felix DandKim Gardner 9c4a9753bb New language swedish (#2798)
* Adding Swedish translation

* updated snap file for Swedish translation

* Translated sv/auth.ftl and partially translated install.ftl and errors.ftl to swedish

* Translated server/error completly and removed the swedish translation file install

* Fixed merge conflict with Finnish language that was added before this PR was completed

* Fixed wrong semi colon and white space

Co-authored-by: Kim Gardner <kgardnr@gmail.com>
2020-01-28 15:51:22 -05:00
Dan ZajdbandandKim Gardner e43a3ddf75 Spanish translation fixes (#2812) 2020-01-28 10:58:20 -05:00
jpkilpiandKim Gardner 6364eced63 Finnish translation (#2811)
* Initial Finnish translation

* Added Finnish translation to test configuration
2020-01-23 12:45:23 -05:00
DzarrandKim Gardner 62ce3a2c49 Translations of server locales in french (#2807)
Co-authored-by: Kim Gardner <kgardnr@gmail.com>
2020-01-21 17:22:25 -05:00
Nick FunkandWyatt Johnson 48d815aebb Refactor v2 css variable names into post css variables (#2791)
We don't want to clog up the variables list with every
design token from AirTable. Instead, more efficient to
use Post CSS var's that compile down into the CSS bundle
more efficiently.

CORL-748
2020-01-20 21:09:10 +00:00
Nick FunkandWyatt Johnson 38ccbd0ef8 Show new message when no comments and story closed (#2792)
Show "There are no comments on this story." instead
of "There are no comments yet. Why don't you write one?"

CORL-787
2020-01-20 20:56:54 +00:00
Nick FunkandWyatt Johnson cfebe7733e Fix radio button positioning on Firefox (#2805)
Remove the top: 6px since it's unnecessary
to vertically align the dot in the radio
button.

CORL-873
2020-01-20 18:27:44 +00:00
e7b83c6b39 [CORL-875] Semi-bold selected text on radio buttons (#2804)
* Semi-bold selected text on radio buttons

Makes it very obvious which item is selected.

CORL-875

* fix: updated snapshots

Co-authored-by: Wyatt Johnson <accounts+github@wyattjoh.ca>
2020-01-20 18:13:11 +00:00
Nick FunkandWyatt Johnson 5c46884a97 Change load amounts for comments (#2800)
Load 20 comments initially and on load more.
Load 3 replies initially and on load more.

CORL-864
2020-01-20 17:54:34 +00:00
Nick FunkandWyatt Johnson 4bd929f3f0 [CORL-748] Update admin login to match new branding styles (#2788)
* Update admin login to match new branding styles

CORL-748

* Update admin login to match new branding styles

CORL-748
2020-01-20 17:43:40 +00:00
785735d36a [CORL-874] Align the sidebar and config content in Admin>Configure (#2803)
* Align the sidebar and config content in Admin>Configure

CORL-874

* fix: updated snapshots

Co-authored-by: Wyatt Johnson <accounts+github@wyattjoh.ca>
2020-01-20 17:27:37 +00:00
Wyatt JohnsonandGitHub 20da16331e fix: renamed migration file to ms format (#2802) 2020-01-17 18:59:50 +00:00
Wyatt JohnsonandGitHub a95694dff6 [CORL-867] Version SSL Bypass (#2797)
* fix: move /api/version outside SSL wrap

* chore: bump version
v5.4.2
2020-01-15 23:22:37 +00:00
Wyatt JohnsonandGitHub f58f65c7ae [CORL-867] Health SSL Bypass (#2796)
* fix: bypass enforceHTTPS for /api/health

* chore: version bump
v5.4.1
2020-01-15 20:11:28 +00:00
22516457ef Fix text field adornments to use correct font (#2795)
Font styling for text field adornments now
matches the text field input.

CORL-849

Co-authored-by: Wyatt Johnson <accounts+github@wyattjoh.ca>
v5.4.0
2020-01-14 22:48:06 +00:00
533d7633e1 [CORL-846] Restructure the slack comment message format (#2794)
* Restructure the slack comment message format

CORL-846

* feat: removed all comments

Co-authored-by: Wyatt Johnson <accounts+github@wyattjoh.ca>
2020-01-14 22:26:33 +00:00
e8fb234838 [CORL-850] use pngs for logo (#2790)
* use png instead of svg for logo

* update snap

Co-authored-by: Wyatt Johnson <accounts+github@wyattjoh.ca>
2020-01-14 17:26:56 +00:00
Wyatt JohnsonandGitHub 9b8ab6de5f 5.4.0 Release Bug Fixes (#2789)
* fix: addresses CORL-848

Fixed copy for new commenters feature.

* fix: address CORL-847

Revert the line hight changes on select fields for now.

* fix: addressed CORL-851

Changed copy on CSS field.

* fix: addressed CORL-840

Changed deletion window to 24 hours.
Refactored durations to use TIME enum.
2020-01-14 16:39:21 +00:00
a88644d98e [CORL-836] Create activeStories endpoint (#2787)
* Create activeStories GraphQL query endpoint

Set lastCommentedAt on stories when they are
commented upon.
Use lastCommentedAt to retrieve the activeStories.
Create a migration to partial index
lastCommentedAt on stories to make retrieval fast.

CORL-836

* fix: adjusted query to use index, more @auth directives

Co-authored-by: Wyatt Johnson <accounts+github@wyattjoh.ca>
2020-01-10 23:55:22 +00:00
Wyatt JohnsonandGitHub 745fb4056c fix: fixed tag styling due to localization (#2785) 2020-01-10 18:32:15 +00:00
a582773e1d I18n ro translation (#2786)
* add Romanian translation

* add further RO translations

* update locales.ts file

* add common.ftl RO translations

* fix: linting

* fix: updated snapshots

Co-authored-by: Wyatt Johnson <accounts+github@wyattjoh.ca>
2020-01-10 18:04:52 +00:00
Wyatt JohnsonandGitHub 6057edcb07 Heroku Build Fix (#2784)
* fix: pinned node and npm versions

* fix: addressed issues with package upgrades
2020-01-10 01:10:15 +00:00
852466e9a1 feat: add additional log messages, added nudge to metadata (#2781)
Co-authored-by: Kim Gardner <kgardnr@gmail.com>
2020-01-08 19:43:10 +00:00
Nick FunkandGitHub f53db233ce [CORL-829] Bump line-height on select fields (#2779)
* Bump line-height on select to account for hanging font characters

Prevents characters like "g" or "j" being cut off at the
bottom of the select.

CORL-829

* Create new tall line height

Use it for the select boxes to allow for dangling
characters like 'g' and 'j'.

CORL-829
2020-01-08 11:06:16 -07:00
Nick FunkandGitHub 31cf9a4f7d [CORL-818] Add validation and placeholder for Slack hook url field (#2782)
* Add a placeholder for Slack hook url field

CORL-818

* Validate slack hook url's before saving

CORL-818
2020-01-08 10:49:33 -07:00
Nick FunkandGitHub 81338d1386 [CORL-825-cp] Allow sending of moderation decisions to Google (#2783)
* Allow sending of moderation decisions to Google

If enabled in the config, moderation decisions can
be sent to Google.

Simplify OnOffField test id's

Consolidate guard clauses

Reconstruct tenant url's when sending perspective feedback

Use the comment revision id when sending perspective feedback

Use retrieveStory instead of findStory

Clarify logging warning levels on perspective feedback

Clean html tags from sent comment body

Fix include to match new graph context refactors

CORL-825

* Handle asynchronous perspective operation more cleanly

CORL-825
2020-01-08 10:32:24 -07:00
84bbc3d0c3 [CORL-688] Refactor: Consolidate the tenant and common context together (#2780)
* feat: initial impl

* Create preliminary comment moderation slices

CORL-688

* Move slices logic into stacks

CORL-688

* Create user comment counts

CORL-688

* Create naive mutation that initializes user comment counts

CORL-688

* Use bulk updates in user counts migration

CORL-688

* fix: review

* fix: fixed issue with aggregation

* Migrate creating comment into stacks

CORL-688

* Migrate editing a comment to the stacks

CORL-688

* Break publishing comment status out of updateAllCounts

CORL-688

* review: removed variable scoping in favor of export

* revert: feb8e8196cd448f5cd24f1ca2eb0b91fe9bd43c7

* review: simplification of stacks implementation

This simplifies the stacks implementation to better reuse code related
to count management and event publishing. This can be used to great
effect with the upcomming events PR #2738.

* Consolidate the tenant and common context together

CORL-688

* review: removed variable scoping in favor of export

* revert: feb8e8196cd448f5cd24f1ca2eb0b91fe9bd43c7

* review: simplification of stacks implementation

This simplifies the stacks implementation to better reuse code related
to count management and event publishing. This can be used to great
effect with the upcomming events PR #2738.

* fix: check if authorID is null before update user counts

CORL-688

* Consolidate common/tenant context supporting files

CORL-688

* feat: renamed TenantContext -> GraphContext

Co-authored-by: Wyatt Johnson <accounts+github@wyattjoh.ca>
2020-01-08 17:07:25 +00:00
d26e331a4f [CORL-664] Threshold moderate new commenters (#2752)
* add new commenters config

* fix specs and fixtures, add translation strings

* save whether a commenter is new

* fix specs and snaps

* add admin role to new config options

* Update copy

* remvoe unused ref

* feat: initial impl

* Create preliminary comment moderation slices

CORL-688

* Move slices logic into stacks

CORL-688

* Create user comment counts

CORL-688

* Create naive mutation that initializes user comment counts

CORL-688

* Use bulk updates in user counts migration

CORL-688

* fix: review

* fix: fixed issue with aggregation

* Migrate creating comment into stacks

CORL-688

* Migrate editing a comment to the stacks

CORL-688

* Break publishing comment status out of updateAllCounts

CORL-688

* review: removed variable scoping in favor of export

* revert: feb8e8196cd448f5cd24f1ca2eb0b91fe9bd43c7

* review: simplification of stacks implementation

This simplifies the stacks implementation to better reuse code related
to count management and event publishing. This can be used to great
effect with the upcomming events PR #2738.

* Remove un-necessary isNew flags on users

CORL-664

* review: removed variable scoping in favor of export

* revert: feb8e8196cd448f5cd24f1ca2eb0b91fe9bd43c7

* review: simplification of stacks implementation

This simplifies the stacks implementation to better reuse code related
to count management and event publishing. This can be used to great
effect with the upcomming events PR #2738.

* fix: check if authorID is null before update user counts

CORL-688

* fix: addressed bug in shared count retrival

Co-authored-by: Tessa Thornton <tessathornton@gmail.com>
Co-authored-by: Wyatt Johnson <accounts+github@wyattjoh.ca>
2020-01-07 14:38:50 -07:00
e3e2e0f52e [CORL-688] Add user comment count tracking (#2744)
* feat: initial impl

* Create preliminary comment moderation slices

CORL-688

* Move slices logic into stacks

CORL-688

* Create user comment counts

CORL-688

* Create naive mutation that initializes user comment counts

CORL-688

* Use bulk updates in user counts migration

CORL-688

* fix: review

* fix: fixed issue with aggregation

* Migrate creating comment into stacks

CORL-688

* Migrate editing a comment to the stacks

CORL-688

* Break publishing comment status out of updateAllCounts

CORL-688

* review: removed variable scoping in favor of export

* revert: feb8e8196cd448f5cd24f1ca2eb0b91fe9bd43c7

* review: simplification of stacks implementation

This simplifies the stacks implementation to better reuse code related
to count management and event publishing. This can be used to great
effect with the upcomming events PR #2738.

* fix: check if authorID is null before update user counts

CORL-688

Co-authored-by: Wyatt Johnson <accounts+github@wyattjoh.ca>
2020-01-07 21:00:25 +00:00
Wyatt JohnsonandGitHub 0dc3e8968a fix: package upgrade (#2777)
Upgraded some packages to latest. This should resolve #2774. Fixes were
also applied after types upgrades that helped discover other errors.
2020-01-06 16:14:56 +00:00
Hans SprecherandKim Gardner f900050ef4 2772: swapping a Perspective API link from a dead one to the README on their repo. (#2773) 2019-12-23 17:42:45 -05:00
0f456330c5 [CORL-827/828] Scrub downloaded comments of html tags, rename archive (#2767)
* Prefix comment download filename with "coral"

CORL-827

* Scrub html tags from downloaded comment data

CORL-828

Co-authored-by: Kim Gardner <kgardnr@gmail.com>
Co-authored-by: Wyatt Johnson <accounts+github@wyattjoh.ca>
2019-12-20 23:46:24 +00:00
Wyatt JohnsonandGitHub 9d050e8b51 [CORL-800] Fluent Upgrade (#2739)
* feat: upgraded fluent libraries

* fix: adjustments to support fluent upgrade
2019-12-20 23:18:49 +00:00
Wyatt JohnsonandKim Gardner 7581f0201d fix: improved the count management (#2769)
Count management has been adjusted to instead preserve the zero values
of the counts. Old count maintainence functions were also removed
because they were untested and not used.

Co-authored-by: Kim Gardner <kgardnr@gmail.com>
2019-12-20 18:07:29 -05:00
Nick FunkandKim Gardner 86b2ec1e56 Fix incorrectly set tabID on moderate card details (#2768)
CORL-826
2019-12-20 17:55:56 -05:00
Nick FunkandKim Gardner fd1ee39db4 Fix story message boxes to wrap text properly (#2761)
Need to set the message content width so that
the text knows how to wrap. Also accounts for
when the icon is present to set width to the
correct value so it doesn't shift past the edge
of the message box container.

CORL-802

Co-authored-by: Kim Gardner <kgardnr@gmail.com>
2019-12-20 17:25:55 -05:00
8c6f12c24d Improve pt-BR translation (#2757)
Update src/locales/pt-BR/admin.ftl

Co-Authored-By: Wyatt Johnson <accounts+github@wyattjoh.ca>

Co-authored-by: Wyatt Johnson <accounts+github@wyattjoh.ca>
Co-authored-by: Kim Gardner <kgardnr@gmail.com>
2019-12-20 17:15:31 -05:00
Nick FunkandKim Gardner 11a4a5ebe3 Update logo to match new Vox Media branding (#2766)
The Vox Media text now has reduced spacing.

CORL-804
2019-12-20 17:03:07 -05:00
Wyatt JohnsonandGitHub f3ecbf5dc6 [CORL-824] Feature Flags (#2756)
* feat: implemented feature flag

* fix: support deprecated enums
2019-12-20 18:06:30 +00:00
Tessa ThorntonandGitHub 116d3c0c81 fix jsdoc warnings (#2750) 2019-12-12 11:41:57 -05:00
Tessa ThorntonandKim Gardner 3358cef433 [CORL-746] updated branding: buttons (#2748)
* new button component

* update specs

* fix up markers

* fix docz so it renders

* clean up buttons implementation

* update snaps

* clean up slack buttons

* update snaps
2019-12-09 18:03:30 -05:00
Nick FunkandKim Gardner ec93789cff [CORL-645] Resolve mismanaged branch merging (#2746)
* Create preliminary schema for setting Slack channels

CORL-645

* Implement preliminary slack notification using tenant slack channels

CORL-645

* Very preliminarily get data loading with FieldArray's for slack channels

CORL-645

* Update settings input on schema to allow saving Slack settings to tenant

CORL-645

* Filter off UNMODERATED queue events from slack channels

We don't send these to slack through our filters, we only care
about pending, reported, and featured

CORL-645

* Include a moderation link in comments pushed to Slack

CORL-645

* Hook up proper callback functions for adding/removing slack channels

CORL-645

* Add missing translation for Slack navigation item

CORL-645

* Update snapshots for preliminary Slack configuration changes

CORL-645

* Add some FormField wrappers around slack config elements

Makes the UI appear a little nicer

CORL-645

* Set up slack config to only provide one slack channel

We need to do this until we can get ArrayField's working
in final-form.

CORL-645

* Disable the other trigger checkboxes when "All Comments" is checked

CORL-645

* Clean up the formatting of Slack messages

CORL-645

* Add error handling around sending comments to Slack

CORL-645

* Add links to external Slack setup documentation

CORL-645

* Replace form state with wrapped field element

CORL-645

* Clean up fetch request sending Slack notifications

CORL-645

* Prefer global string replacement over RegEx

CORL-645

* Use URL class to construct comment URL's

CORL-645

* Require slack configuration in schema

CORL-645

* Initialize Slack in fixtures

Also fix up a flaky test that wasn't waiting
on form submission and on-change events.

CORL-645

* Preliminarily fix up styles to match other config pages

CORL-645

* Create placeholder add/remove buttons

* Convert SlackConfigContainer to FunctionalComponent

CORL-645

* Add name field to slack channels

CORL-645

* Disable inner fields on Slack channel when not enabled

CORL-645

* Improve the delete channel button

CORL-645

* Use pureMerge to extract slack channel settings

CORL-645

* Do a bit of cleanup on the add channel button

CORL-645

* Update the styling of the Slack config

- Use sub header for channel headings
- Update add channel button text
- Move the remove channel button down
- Other minor spacing tweaks

CORL-645
2019-12-09 16:29:57 -05:00
Tessa ThorntonandKim Gardner f60fac651b use correct timestamp component (#2747) 2019-12-09 16:20:24 -05:00
Tessa ThorntonandKim Gardner 514a549a77 update markers to make sure they're legible (#2745) 2019-12-09 16:11:12 -05:00
Wyatt JohnsonandGitHub 88f6cad840 fix: resolved issue with incorrect moderation url being generated (#2743) 2019-12-06 18:46:54 +00:00