Commit graph

2805 commits

Author SHA1 Message Date
Jess Lee
65fccf00a9 add rake task for fixing credit counter cache (#3962) 2019-09-06 13:08:39 -04:00
Anna Buianova
5248a781b5 Rescue InvalidURIError when busting cache (#3938) 2019-09-06 13:07:24 -04:00
Andy Zhao
8a4030c25d Revert changes as a hotfix (#3964) 2019-09-06 11:54:35 -04:00
Andy Zhao
aadd376f9c Use explicit email domain for badge email links and minor cleanup (#3943)
* Set domain for badge email links

* Add credits + listings info to plain text badge email

* Update environment variable setting

* Use ENV when ApplicationConfig has not been init
2019-09-06 10:20:48 -04:00
rhymes
69c8b24c34 Send JSON 404 response to API error routes (#3959)
* Fix an issue where API 404 calls got the HTML 404 page in response

* Use keyword for consistency
2019-09-06 10:18:50 -04:00
rhymes
3a0dc13fc7 Replace "access token" with "API Key" (#3960) [ci skip] 2019-09-06 09:08:39 -04:00
Almenon
1a99e9bf1a Hide scrollbars in the editor textarea (#3897)
* Hide scrollbars

There is no need for scrollbars in the textarea given the scrollbar at the edge of the browser and that `preact-textarea-autosize` used for the textarea already increases the height of the textarea when needed. Getting rid of scrollbars would solve #2939 and #3330

* add documentation
2019-09-05 18:04:24 -04:00
Jacob Herrington
287bc4432c Make report notification use theme colors (#3896) [ci skip] 2019-09-04 15:22:29 -04:00
rhymes
2e5a847ab8 API: /api/articles/me defaults to published articles (#3937)
* /api/articles/me defaults to published articles

We want to make it explicit to retrieve unpublished articles, this change defaults `/api/articles/me` to only published articles, also adds `/api/articles/me/published`, `/api/articles/me/unpublished` and `/api/articles/me/all` to make requests more explicit.

* Refactor /me logic into a case switch
2019-09-04 14:02:13 -04:00
Andy Zhao
f5e61fdae2 Update Docs deploy command (#3940)
Use make build instead of only gitdocs command
2019-09-04 09:29:49 -04:00
Jacob Herrington
4293a00544 Update notifications reply form to use theme colors (#3894) [ci skip] 2019-09-04 08:42:54 -04:00
Andy Zhao
e25d2eaec9 Escape raw tags in codeblocks properly (#3790) 2019-09-04 08:33:46 -04:00
rhymes
78f22c3682 Simplify the images uploading code (#3907) [ci skip] 2019-09-04 08:14:59 -04:00
not-a-patch
6b7d45baed Update article specs to include missing dependent: :destroy (#3873) [ci skip] 2019-09-03 17:38:13 -04:00
Andy Zhao
dd62a321d1 Add Setup for storybook.dev.to (#3885)
* WIP test custom deploy script

* Add console logs

* Use common JS require instead of import

* WIP

* Use proper names

* Move back one directory...?

* Add npm install?

* Remove console logs

* Refactor a bit
2019-09-03 16:49:37 -04:00
Ben Halpern
07ba4d8b2b
Modify headers to allow embed (#3935) 2019-09-03 16:38:04 -04:00
Jacob Herrington
81f7f73575 Format console copy (#3888) [ci skip] 2019-09-03 15:59:12 -04:00
Akshay Mahajan
c5577f68a3 Reading list: set default reading time to 1 minute (#3927)
* fixes 0 min reading time in reading list by setting the default reading time to 1 min

* Updated PropTypes for article_reading_time & reading_time to number.isRequired. Updated the relevant tests.
2019-09-03 15:50:40 -04:00
rhymes
0bafec4b4b DOC: Fix aggregated query to avoid deprecation (#3904) [ci skip] 2019-09-03 15:49:26 -04:00
Jess Lee
3c4dce0521 remove homepage placement for bronze and silver (#3934) 2019-09-03 13:26:36 -04:00
Stanimira Vlaeva
0088e9e9a3 Remove a link to a missing section in CONTRIBUTING.md (#3930) 2019-09-03 12:57:20 -04:00
Jacob Herrington
5325557701 Add a comma and fix split infinitive (#3931)
Split infinitives are super subjective:
https://www.quickanddirtytips.com/education/grammar/split-infinitives
2019-09-03 12:48:24 -04:00
rhymes
676cf002bd Webhooks: API fixes and docs (#3901)
* Fix webhook API and add POST /api/webhooks docs

* Document GET /api/webhooks/:id

* Fix DELETE /api/webhooks/{id} and document it

* Add proper 404 specs
2019-09-03 10:41:23 -04:00
Mac Siri
5e75bf3aaa
Update PingAdmins to show triggering event (#3853) 2019-09-03 10:23:25 -04:00
dependabot-preview[bot]
0d73cfe0a3 Bump twilio-video from 1.19.0 to 1.19.1 (#3917) [ci skip]
Bumps [twilio-video](https://github.com/twilio/twilio-video.js) from 1.19.0 to 1.19.1.
- [Release notes](https://github.com/twilio/twilio-video.js/releases)
- [Changelog](https://github.com/twilio/twilio-video.js/blob/1.19.1/CHANGELOG.md)
- [Commits](https://github.com/twilio/twilio-video.js/compare/1.19.0...1.19.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-03 10:22:21 -04:00
Jacob Herrington
9e34f81991 Re-sort example Algolia keys (#3886) [ci skip] 2019-09-03 10:20:49 -04:00
rhymes
e1334e3625 Use a self explanatory name to render chat channel (#3902) [ci skip] 2019-09-03 10:19:36 -04:00
tyronasaurus-rex
c9a4ae7f6d Add pixel limit to Editors Guide (#3903) [ci skip] 2019-09-03 10:18:48 -04:00
Jacob Herrington
07944755ff Fix rubocop lints (#3922) [ci skip] 2019-09-03 10:09:48 -04:00
Andrew Mason
af011f12d2 Update vscode-ruby config (#3923) [ci skip] 2019-09-03 10:08:16 -04:00
dependabot-preview[bot]
65811f98a6 Bump bootsnap from 1.4.4 to 1.4.5 (#3912) [ci skip]
Bumps [bootsnap](https://github.com/Shopify/bootsnap) from 1.4.4 to 1.4.5.
- [Release notes](https://github.com/Shopify/bootsnap/releases)
- [Changelog](https://github.com/Shopify/bootsnap/blob/master/CHANGELOG.md)
- [Commits](https://github.com/Shopify/bootsnap/compare/v1.4.4...v1.4.5)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-03 10:05:28 -04:00
dependabot-preview[bot]
ab826f7a3e Bump faker from 2.1.2 to 2.2.1 (#3911) [ci skip]
Bumps [faker](https://github.com/faker-ruby/faker) from 2.1.2 to 2.2.1.
- [Release notes](https://github.com/faker-ruby/faker/releases)
- [Changelog](https://github.com/faker-ruby/faker/blob/master/CHANGELOG.md)
- [Commits](https://github.com/faker-ruby/faker/compare/v2.1.2...v2.2.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-03 10:04:37 -04:00
dependabot-preview[bot]
a6fa4fb9c9 Bump devise from 4.6.2 to 4.7.0 (#3908) [ci skip]
Bumps [devise](https://github.com/plataformatec/devise) from 4.6.2 to 4.7.0.
- [Release notes](https://github.com/plataformatec/devise/releases)
- [Changelog](https://github.com/plataformatec/devise/blob/master/CHANGELOG.md)
- [Commits](https://github.com/plataformatec/devise/compare/v4.6.2...v4.7.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-03 10:02:32 -04:00
dependabot-preview[bot]
c0c258c177 Bump pusher-js from 5.0.0 to 5.0.1 (#3916) [ci skip]
Bumps [pusher-js](https://github.com/pusher/pusher-js) from 5.0.0 to 5.0.1.
- [Release notes](https://github.com/pusher/pusher-js/releases)
- [Changelog](https://github.com/pusher/pusher-js/blob/master/CHANGELOG.md)
- [Commits](https://github.com/pusher/pusher-js/compare/v5.0.0...v5.0.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-03 10:01:50 -04:00
dependabot-preview[bot]
f255191f99 Bump autoprefixer-rails from 9.6.1 to 9.6.1.1 (#3910) [ci skip]
Bumps [autoprefixer-rails](https://github.com/ai/autoprefixer-rails) from 9.6.1 to 9.6.1.1.
- [Release notes](https://github.com/ai/autoprefixer-rails/releases)
- [Changelog](https://github.com/ai/autoprefixer-rails/blob/master/CHANGELOG.md)
- [Commits](https://github.com/ai/autoprefixer-rails/compare/9.6.1...9.6.1.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-03 10:00:54 -04:00
dependabot-preview[bot]
afb527d206 Bump counter_culture from 2.2.3 to 2.2.4 (#3914) [ci skip]
Bumps [counter_culture](https://github.com/magnusvk/counter_culture) from 2.2.3 to 2.2.4.
- [Release notes](https://github.com/magnusvk/counter_culture/releases)
- [Changelog](https://github.com/magnusvk/counter_culture/blob/master/CHANGELOG.md)
- [Commits](https://github.com/magnusvk/counter_culture/compare/v2.2.3...v2.2.4)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-03 09:59:58 -04:00
dependabot-preview[bot]
4aad007f20 Bump rubocop-rails from 2.3.1 to 2.3.2 (#3913) [ci skip]
Bumps [rubocop-rails](https://github.com/rubocop-hq/rubocop-rails) from 2.3.1 to 2.3.2.
- [Release notes](https://github.com/rubocop-hq/rubocop-rails/releases)
- [Changelog](https://github.com/rubocop-hq/rubocop-rails/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rubocop-hq/rubocop-rails/compare/v2.3.1...v2.3.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-03 09:59:15 -04:00
rhymes
77e34a726d Fix flaky listings specs (#3899)
* Fix flaky listings specs

* Fix another flaky test
2019-09-02 13:23:41 -04:00
Jacob Herrington
099b188530 Rename uncommunicative variables (#3890)
* Clarify uncommunicative variables in labor classes

Single letter variable names are largely a question of preference, in
some cases I think that convention mitigates the opaque nature of single
letter variable names (e.g., e for error, i for index, etc).

However, in some cases they can be unclear and there isn't much reason
to use single letter variables unless for some reason character length is
really important.

In this case, I would prefer clarity in variable names over brevity of
code so I've used Reek to identify short variable names and I'm changing
them.

It's pretty boring, but hopefully incremental code love changes like
this one add up and improve readability and accessibility for those
interested in reading this codebase.

* Remove commented code from 2 years ago

* Clarify uncommunicative naming in services classes

There is some context for this change in 6b81880f

* Clarify uncommunicative naming in models

There is some context for this change in 6b81880f

* Clarify uncommunicative naming in liquid_tags

There is some context for this change in 6b81880f
2019-09-02 13:05:07 -04:00
dependabot-preview[bot]
055fe74633 Bump husky from 3.0.4 to 3.0.5 (#3918) [ci skip]
Bumps [husky](https://github.com/typicode/husky) from 3.0.4 to 3.0.5.
- [Release notes](https://github.com/typicode/husky/releases)
- [Changelog](https://github.com/typicode/husky/blob/master/CHANGELOG.md)
- [Commits](https://github.com/typicode/husky/compare/v3.0.4...v3.0.5)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-02 11:59:42 -04:00
dependabot-preview[bot]
a6f6ba812b Bump lint-staged from 9.2.4 to 9.2.5 (#3920) [ci skip]
Bumps [lint-staged](https://github.com/okonet/lint-staged) from 9.2.4 to 9.2.5.
- [Release notes](https://github.com/okonet/lint-staged/releases)
- [Commits](https://github.com/okonet/lint-staged/compare/v9.2.4...v9.2.5)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-02 11:57:59 -04:00
dependabot-preview[bot]
bcec9fed70 Bump guard from 2.15.0 to 2.15.1 (#3909) [ci skip]
Bumps [guard](https://github.com/guard/guard) from 2.15.0 to 2.15.1.
- [Release notes](https://github.com/guard/guard/releases)
- [Commits](https://github.com/guard/guard/compare/v2.15.0...v2.15.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-02 11:23:05 -04:00
dependabot-preview[bot]
b5ade36aa3 Bump aws-sdk-lambda from 1.29.0 to 1.30.0 (#3906) [ci skip]
Bumps [aws-sdk-lambda](https://github.com/aws/aws-sdk-ruby) from 1.29.0 to 1.30.0.
- [Release notes](https://github.com/aws/aws-sdk-ruby/releases)
- [Changelog](https://github.com/aws/aws-sdk-ruby/blob/master/gems/aws-sdk-lambda/CHANGELOG.md)
- [Commits](https://github.com/aws/aws-sdk-ruby/compare/1.29.0...1.30.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-02 11:22:21 -04:00
Mario See
fda048dc12 Listing Drafts and Deletion (#3540)
* wip init handle draft class and styling

* add draft button

* start splitting up listing row into multile files

* separate tag links

* split location

* fix location

* separate listing row action buttons

* update listing row proptypes to describe listing object

* contact via connect to jsx

* fix default checked

* init draft creation and first publish charge

* fix first publish logic and credit charging

* handle drafts in dashboard filtering

* adjust isDraft bool statement

* hide drafts from main listings feed

* fix expired and draft bools in listing row

* adjust create listing org credits

* internally handle drafts

* adjust listing row

* break down update method

* remove unnecessary logic and shorten lines

* fix logic again woops

* convert input hidden value + submit into one form button submit with corresponding name and value

also adds clear message that drafts do not cost credits

* handle insufficient org credits on first publish

- uses user credits to publish
- similar to bump implementation

* fix sorting for personal and all orgs

* space out some elements

* don't spend original users credit for them

* add delete buttons and delete_confirm and destroy methods

* remove notification removal since listings dont trigger notifications

* move draft message and add draft_params to tests

* Update classified_listings_controller.rb

* update tests

* update snapshot

* add del tests

* add guard preventing free draft publish

* fix draft filter

* update from master and resolve merge conflict in listing preact

* Revert "update from master and resolve merge conflict in listing preact"

This reverts commit 0a34fccf334a2ca0902644b486cb26ead6bef664.

* update column spec

instead of setting and saving

* separate two expectations into their own tests

* split more tests into single expectations

* change to unless bumped_at? instead of if nil

* Fix listing draft edge cases and styling

* Add title tags to listings pages
2019-09-01 13:54:54 -04:00
Mario See
3cf6a2d4bc Add singleListing specs (#3883) [ci skip] 2019-08-30 14:49:20 -04:00
Michael Tharrington
5cdd3e2f10 Update Email Copy for internal/reports (#3867) 2019-08-30 09:58:30 -04:00
dependabot-preview[bot]
0f341c6131 Bump carrierwave from 1.3.1 to 2.0.0 (#3762) [ci skip]
Bumps [carrierwave](https://github.com/carrierwaveuploader/carrierwave) from 1.3.1 to 2.0.0.
- [Release notes](https://github.com/carrierwaveuploader/carrierwave/releases)
- [Changelog](https://github.com/carrierwaveuploader/carrierwave/blob/master/CHANGELOG.md)
- [Commits](https://github.com/carrierwaveuploader/carrierwave/compare/v1.3.1...v2.0.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-08-30 09:27:51 -04:00
Ben Halpern
81bff4da35
Fix internal mods interactivity and improve layout (#3879) 2019-08-29 19:00:22 -04:00
Tiger Oakes
92e107e82e Use maskable icons for PWA (#3875) [ci skip] 2019-08-29 18:44:26 -04:00
Mario See
ecc22cf129 Update seed file to clear listing indexes (#3878) [ci skip] 2019-08-29 18:04:23 -04:00