Commit graph

10886 commits

Author SHA1 Message Date
Alex
f071903176
Remove counts from instance API (#16479) 2022-02-09 11:07:44 -05:00
dependabot[bot]
7ea2ecaf7a
Bump @babel/core from 7.17.0 to 7.17.2 (#16498) 2022-02-09 09:38:15 -05:00
dependabot[bot]
ac09320d74
Bump @storybook/addon-storysource from 6.4.10 to 6.4.18 (#16471)
Bumps [@storybook/addon-storysource](https://github.com/storybookjs/storybook/tree/HEAD/addons/storysource) from 6.4.10 to 6.4.18.
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v6.4.18/addons/storysource)

---
updated-dependencies:
- dependency-name: "@storybook/addon-storysource"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-09 06:45:59 -07:00
ludwiczakpawel
50a4f0422b
Admin's Member view (#16174)
* init

* .

* partials

* few extras

* revert indicators in favor of separate PR

* stuff

* .

* stuff

* whoops

* .

* .

* .

* .

* opacity

* partial

* cosmetics

* move actions to a partial

* whoopsy

* Added an @admin alias for the frontend and removed the @admin-controllers alias.

* Added modal support for admin user actions.

* Added modal support for more parts of the user admin.

* pills

* pills

* pills

* Added optional chaining for when the overview panel isn't loaded.

* styling updates

* fix

* modals

* pass size

* tags

* .

* balance modal

* comment

* fixes

* Improved modal trigger implementation.

* Removed default value for dataset.

* Moved prevent default to after modal trigger check so forms still submit.

* Update app/views/admin/users/widgets/_credits.html.erb

Co-authored-by: Julianna Tetreault <32834804+juliannatetreault@users.noreply.github.com>

* Update app/views/admin/users/reports/_index.html.erb

* Apply suggestions from code review

* Apply suggestions from code review

* Update app/views/admin/users/actions/_export.html.erb

* Update app/views/admin/users/widgets/_tag_moderation.html.erb

* Update app/views/admin/users/actions/_merge.html.erb

* Removed <AdminUserActionsModal /> component as it wasn't necessary.

* Fixed duplicate ID errors detected by Axe.

* Redirects to the Show page rather than the Edit page

* Adjusts quotations within _social_accounts.html.erb

* Ensures that Learn More links open in new tab

* updates with latests and greatest

* .

* fixes

* wip. Fixed some issues in the credits form.

* Changed Subtract to Remove for credits dropdown.

* Cleaned up the edits form.

* Wraps functionality in feature flag and calls #set_user_details

* Wraps /admin/users/show.html.erb in feature flag

* wip: Got credit params form working.

* empty select

* responsiveness

* empty commiit

* Updates redirects in spec and controller to show rather than edit

* Updates tag moderation copy in Admin Member Detail View

* Now the note is saved when changing credits.

* Fixed label for attributes as it was affecting writing tests and a11y.

* Removes unused index.js component

* Refactored credit params.

* chore: move method under private and update comment

* verified email responsiveness

* better opacity variables

* better org logo

* indicators

* refactor the credits method

Co-authored-by: Nick Taylor <nick@dev.to>
Co-authored-by: Nick Taylor <nick@iamdeveloper.com>
Co-authored-by: Julianna Tetreault <32834804+juliannatetreault@users.noreply.github.com>
Co-authored-by: Nick Taylor <nick@forem.com>
Co-authored-by: Ridhwana <ridhwana.khan16@gmail.com>
2022-02-09 14:33:01 +01:00
Nick Taylor
32e1b3f228
Removed colour picker from onboarding as it's never used. (#16491) 2022-02-09 06:17:16 -05:00
lionel-rowe
f72e60b15d
Add color-scheme: dark to dark.css (#16493) 2022-02-09 08:52:46 +01:00
Ben Halpern
84379574d5
Feed experiment 6: recency (#16438)
* Feed experiment 6: recency

* Update app/services/articles/feeds/weighted_query_strategy.rb

Co-authored-by: Michael Kohl <me@citizen428.net>

* Update app/services/articles/feeds/weighted_query_strategy.rb

Co-authored-by: Michael Kohl <me@citizen428.net>

Co-authored-by: Michael Kohl <me@citizen428.net>
2022-02-08 15:01:18 -05:00
Nick Taylor
5409f5f024
Fixed post moderation flaky test (#16480) 2022-02-08 14:06:55 -05:00
dependabot[bot]
ed217bb100
Bump @testing-library/dom from 8.11.2 to 8.11.3 (#16474)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-08 13:44:21 -05:00
Jeremy Friesen
d19dad3b28
Ensuring optionally rendering dashboard listings (#16467)
Relates to forem/rfcs#291, #16420, #16437, #16423, and #16461.
2022-02-08 13:41:22 -05:00
dependabot[bot]
7a4b618821
Bump sidekiq from 6.4.0 to 6.4.1 (#16476)
Bumps [sidekiq](https://github.com/mperham/sidekiq) from 6.4.0 to 6.4.1.
- [Release notes](https://github.com/mperham/sidekiq/releases)
- [Changelog](https://github.com/mperham/sidekiq/blob/main/Changes.md)
- [Commits](https://github.com/mperham/sidekiq/compare/v6.4.0...v6.4.1)

---
updated-dependencies:
- dependency-name: sidekiq
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-08 13:28:08 -05:00
Daniel Uber
83b35444a6
Remove system test for editing draft posts (#16472)
* Remove system test for editing draft posts

This behavior is checked in the cypress tests in
publishingFlows/publishOrSavePost.spec.js

* Copy original regression test back into cypress check

The system spec was checking that after attempting to save as draft,
when seeing an error, editing and saving as draft was permitted.

Replicate that behavior in the existing cypress test that checks invalid
markdown raises error, specifying that replacing the content and
saving succeeds (and stays in draft status).
2022-02-08 10:24:49 -06:00
dependabot[bot]
637b13349a
Bump eslint from 8.6.0 to 8.8.0 (#16463)
Bumps [eslint](https://github.com/eslint/eslint) from 8.6.0 to 8.8.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v8.6.0...v8.8.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-08 09:20:31 -07:00
dependabot[bot]
7c490b15c3
Bump babel-jest from 27.4.6 to 27.5.1 (#16469)
Bumps [babel-jest](https://github.com/facebook/jest/tree/HEAD/packages/babel-jest) from 27.4.6 to 27.5.1.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/commits/v27.5.1/packages/babel-jest)

---
updated-dependencies:
- dependency-name: babel-jest
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-08 09:20:14 -07:00
dependabot[bot]
d51fa58126
Bump preact from 10.6.4 to 10.6.5 (#16470) 2022-02-08 10:51:01 -05:00
Jamie Gaskins
5d00a4d967
Show image-upload errors on /admin/advanced/tools (#16448)
* Show image-upload errors on /admin/advanced/tools

* Simplify error handling

This also makes the error message consistent with the rest of the admin
validation errors, so it's probably better even if it doesn't look as
flashy.

* Remove obsolete clearTimeout call

We aren't setting this timer anymore
2022-02-08 10:41:54 -05:00
dependabot[bot]
1f6ea6fb3f
Bump @storybook/addon-a11y from 6.4.17 to 6.4.18 (#16466)
Bumps [@storybook/addon-a11y](https://github.com/storybookjs/storybook/tree/HEAD/addons/a11y) from 6.4.17 to 6.4.18.
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v6.4.18/addons/a11y)

---
updated-dependencies:
- dependency-name: "@storybook/addon-a11y"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-08 08:30:09 -07:00
dependabot[bot]
742b531e56
Bump jest from 27.5.0 to 27.5.1 (#16468)
Bumps [jest](https://github.com/facebook/jest) from 27.5.0 to 27.5.1.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.5.0...v27.5.1)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-08 09:16:31 -06:00
dependabot[bot]
9319c88b27
Bump @etchteam/storybook-addon-css-variables-theme from 1.1.0 to 1.1.1 (#16459)
Bumps [@etchteam/storybook-addon-css-variables-theme](https://github.com/etchteam/storybook-addon-css-variables-theme) from 1.1.0 to 1.1.1.
- [Release notes](https://github.com/etchteam/storybook-addon-css-variables-theme/releases)
- [Commits](https://github.com/etchteam/storybook-addon-css-variables-theme/commits)

---
updated-dependencies:
- dependency-name: "@etchteam/storybook-addon-css-variables-theme"
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-08 14:51:15 +00:00
Daniel Uber
39c5bcd518
remove activex fallback for internet explorer (#16453)
* remove IE6 XHR support

IE7 and later support XMLHttpRequest natively, and most of the rest of
the code base uses fetch() which may not work in any version of IE

Drop the conditional here in the assumption that this would only be
the first of many problems for a user with an unsupported browser.
2022-02-08 08:36:04 -06:00
dependabot[bot]
097298a5e6
Bump @babel/core from 7.16.7 to 7.17.0 (#16462)
Bumps [@babel/core](https://github.com/babel/babel/tree/HEAD/packages/babel-core) from 7.16.7 to 7.17.0.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.17.0/packages/babel-core)

---
updated-dependencies:
- dependency-name: "@babel/core"
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-08 07:27:35 -07:00
dependabot[bot]
a11f76e5c4
Bump @storybook/preact from 6.4.17 to 6.4.18 (#16458)
Bumps [@storybook/preact](https://github.com/storybookjs/storybook/tree/HEAD/app/preact) from 6.4.17 to 6.4.18.
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v6.4.18/app/preact)

---
updated-dependencies:
- dependency-name: "@storybook/preact"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-08 06:49:46 -07:00
dependabot[bot]
9b15758bb3
Bump @testing-library/jest-dom from 5.16.1 to 5.16.2 (#16457)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-08 08:21:08 -05:00
dependabot[bot]
e0620a340c
Bump @storybook/manager-webpack5 from 6.4.10 to 6.4.18 (#16452)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-08 07:53:42 -05:00
Jeremy Friesen
2fd94fcc87
Ensuring that body.dataset is JSON parsable (#16441)
Prior to this commit, if our community name included a `"` we would
encounter a parse error.  Using the [j][1] which is a terse alias for
[escape_javascript][2], we will now be escaping those characters that
cause grief in some of our parsings.

I believe there is a larger audit that needs to occur regarding all
`data-` renderings.

Hopefully this will catch a flakey test.

Closes #16440

[1]:https://api.rubyonrails.org/classes/ActionView/Helpers/JavaScriptHelper.html#method-i-j
[2]:https://api.rubyonrails.org/classes/ActionView/Helpers/JavaScriptHelper.html#method-i-escape_javascript
2022-02-08 07:30:43 -05:00
dependabot[bot]
bae6a5e4e1
Bump @storybook/addon-backgrounds from 6.4.14 to 6.4.18 (#16445)
Bumps [@storybook/addon-backgrounds](https://github.com/storybookjs/storybook/tree/HEAD/addons/backgrounds) from 6.4.14 to 6.4.18.
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v6.4.18/addons/backgrounds)

---
updated-dependencies:
- dependency-name: "@storybook/addon-backgrounds"
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-08 10:08:49 +00:00
dependabot[bot]
d58a6ddb80
Bump core-js from 3.20.2 to 3.21.0 (#16451)
Bumps [core-js](https://github.com/zloirock/core-js) from 3.20.2 to 3.21.0.
- [Release notes](https://github.com/zloirock/core-js/releases)
- [Changelog](https://github.com/zloirock/core-js/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zloirock/core-js/compare/v3.20.2...v3.21.0)

---
updated-dependencies:
- dependency-name: core-js
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-08 10:05:59 +00:00
dependabot[bot]
f52fa78072
Bump postcss from 8.4.5 to 8.4.6 (#16444)
Bumps [postcss](https://github.com/postcss/postcss) from 8.4.5 to 8.4.6.
- [Release notes](https://github.com/postcss/postcss/releases)
- [Changelog](https://github.com/postcss/postcss/blob/main/CHANGELOG.md)
- [Commits](https://github.com/postcss/postcss/compare/8.4.5...8.4.6)

---
updated-dependencies:
- dependency-name: postcss
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-08 09:40:49 +00:00
dependabot[bot]
b3282db8e4
Bump @storybook/addon-controls from 6.4.13 to 6.4.18 (#16443)
Bumps [@storybook/addon-controls](https://github.com/storybookjs/storybook/tree/HEAD/addons/controls) from 6.4.13 to 6.4.18.
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v6.4.18/addons/controls)

---
updated-dependencies:
- dependency-name: "@storybook/addon-controls"
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-08 09:36:19 +00:00
Michael Kohl
a7a3d6d3e7
Ignore device_detector warnings (#16432) 2022-02-08 10:35:26 +07:00
Arit Amana
2842bc68d6
Implement Unified Embeds for Github Repo, Issue, Pull-Request and Comment URLs (#16422)
* figuring things out

* working both ways for issues PRs except disc and PRreview

* working on repo urls

* complete implementation and check specs

* resolve Travis failures

* resolving travis failures

* Fix VCR cassette

* fix regexs

Co-authored-by: Jamie Gaskins <jgaskins@hey.com>
2022-02-07 16:38:43 -05:00
dependabot[bot]
d2424e6032
Bump @storybook/builder-webpack5 from 6.4.17 to 6.4.18 (#16450)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-07 15:05:13 -05:00
dependabot[bot]
1b89e2d8fc
Bump @babel/preset-env from 7.16.8 to 7.16.11 (#16449)
Bumps [@babel/preset-env](https://github.com/babel/babel/tree/HEAD/packages/babel-preset-env) from 7.16.8 to 7.16.11.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.16.11/packages/babel-preset-env)

---
updated-dependencies:
- dependency-name: "@babel/preset-env"
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-07 12:24:24 -07:00
dependabot[bot]
19ebcbbba3
Bump omniauth-rails_csrf_protection from 1.0.0 to 1.0.1 (#16447)
Bumps [omniauth-rails_csrf_protection](https://github.com/cookpad/omniauth-rails_csrf_protection) from 1.0.0 to 1.0.1.
- [Release notes](https://github.com/cookpad/omniauth-rails_csrf_protection/releases)
- [Commits](https://github.com/cookpad/omniauth-rails_csrf_protection/compare/v1.0.0...v1.0.1)

---
updated-dependencies:
- dependency-name: omniauth-rails_csrf_protection
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-07 13:18:14 -06:00
dependabot[bot]
dfedeaee68
Bump jest from 27.4.7 to 27.5.0 (#16446)
Bumps [jest](https://github.com/facebook/jest) from 27.4.7 to 27.5.0.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.4.7...v27.5.0)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-07 12:02:10 -07:00
Arit Amana
63c957b12d
Implement Unified Embeds for StackExchange and StackOverflow URLs (#16415)
* complete implementation and add specs

* improvements

* more robust condition

* update API version; re-record VCR cassettes

* PR review comments
2022-02-07 11:21:11 -05:00
Mac Siri
0559a808c4
Allow nil pubDate in Podcast sorting (#16349)
* Allow nil pubDate in Podcast sorting

* Choose a shorter syntax

* Typo
2022-02-07 11:18:51 -05:00
Nick Taylor
0132ef67ee
Added a custom Cypress command to get the modal compoonent. (#16439) 2022-02-07 11:01:31 -05:00
Jeremy Friesen
30a894a6eb
Removing deprecated User methods (#16435)
* Removing deprecated User methods

Related to #15762, #15691, and #15624

* Bump for travis
2022-02-07 10:32:58 -05:00
dependabot[bot]
0a07ae8fe9
Bump rouge from 3.27.0 to 3.28.0 (#16421)
Bumps [rouge](https://github.com/rouge-ruby/rouge) from 3.27.0 to 3.28.0.
- [Release notes](https://github.com/rouge-ruby/rouge/releases)
- [Changelog](https://github.com/rouge-ruby/rouge/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rouge-ruby/rouge/compare/v3.27.0...v3.28.0)

---
updated-dependencies:
- dependency-name: rouge
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-07 09:58:50 -05:00
Suzanne Aitchison
8a14504a8e
Add accessible color picker component (#16385)
* add colorpicker component

* add tests

* separate out label, change swatch border
2022-02-07 14:30:02 +00:00
dependabot[bot]
bac1e83131
Bump sidekiq-unique-jobs from 7.1.12 to 7.1.14 (#16419)
Bumps [sidekiq-unique-jobs](https://github.com/mhenrixon/sidekiq-unique-jobs) from 7.1.12 to 7.1.14.
- [Release notes](https://github.com/mhenrixon/sidekiq-unique-jobs/releases)
- [Changelog](https://github.com/mhenrixon/sidekiq-unique-jobs/blob/main/CHANGELOG.md)
- [Commits](https://github.com/mhenrixon/sidekiq-unique-jobs/compare/v7.1.12...v7.1.14)

---
updated-dependencies:
- dependency-name: sidekiq-unique-jobs
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-07 07:19:16 -07:00
Jeremy Friesen
446e74ca83
Documenting and addl testing FeatureFlag.enabled? (#16420)
Prior to this commit, we had a single test for `FeatureFlag.enabled?`,
namely that it delegates to `Flipper.enabled?`.  This commit adds some
tests to both verify behavior and communicate to developers the
intentions of the related methods:

- `FeatureFlag.enabled?`
- `FeatureFlag.accessible?`

My hope is the documentation and tests will help address the horrors
mentioned in conversation in #16416:

> I have lived the horrors of having a feature flag accidently
> flipped or incorrectly setup in the first place and half baked
> functionality going live.

Note: I'm not proposing that we test other `Flipper` methods, but
instead to ensure that we're testing and documenting the behavior of
what I believe to be the two primary mechanisms of "putting something
behind a feature flag."

Related to #16406, #16416
2022-02-07 08:53:30 -05:00
Jeremy Friesen
75ae759465
Short-circuiting parsing any articles to update (#16413)
* Short-circuiting parsing any articles to update

Setting a field that is to help track from where we received an image.

Related to #16075 and #16407.

See [Slack Thread][1] for all the details

[1]:https://forem-team.slack.com/archives/CSY5KKK9U/p1643916711077719

* Fix

* Apply suggestions from code review

Co-authored-by: Jamie Gaskins <jgaskins@hey.com>

Co-authored-by: Jamie Gaskins <jgaskins@hey.com>
2022-02-04 11:13:01 -05:00
Jeremy Friesen
765df66084
Scoping the :listing routes to feature (#16406)
This commit builds on the conditional rendering of navigation links by
adding a routing constraint to all :listing routes.

The impact is, if we were to disable the listing feature (e.g.,
`FeatureFlag.disable(:listing_feature_enabled)`) all requests to `GET
/listings` (and those drawn in the [config/routes/listings.rb][1] file)
would return a 404 response.

Related to forem/rfcs#291, #16335, #16338, #16362.

Testing this change:

1. Start your local application (e.g. `$ bin/startup`)
2. Go to http://localhost:3000/listings
3. You should get a Successful response.
4. Now disable the feature (e.g. `$ bin/rails r \
   "FeatureFlag.disable(:listing_feature_enabled)"`)
5. Refresh http://localhost:3000/listings
6. You should get an `ActiveRecord::RecordNotFound` error; because the
   application is now looking for a user or org named "listings"; in other
   words we're not routing `GET "/listings"` to `listings#index` controller
   action.
7. Now enable the feature (e.g. `$ bin/rails r \
   "FeatureFlag.enable(:listing_feature_enabled)"`)
8. Refresh http://localhost:3000/listings
9. You should get a Successful response.
10. Goto 4

This commit is intended to be the penultimate change before we toggle
the listings section off by default.

[1]:c2ce2c32d5/config/routes/listing.rb (L1)
2022-02-04 10:13:56 -05:00
Jamie Gaskins
a9cdb2bae2
A suspended user returns 403 instead of 500 (#16408) 2022-02-04 09:42:23 -05:00
Nick Taylor
52e4e571b7
Reworked some webpack aliases as prework for #16174. (#16412) 2022-02-04 06:34:37 -05:00
dependabot[bot]
a309d09027
Bump simple-get from 3.1.0 to 3.1.1 (#16411)
Bumps [simple-get](https://github.com/feross/simple-get) from 3.1.0 to 3.1.1.
- [Release notes](https://github.com/feross/simple-get/releases)
- [Commits](https://github.com/feross/simple-get/compare/v3.1.0...v3.1.1)

---
updated-dependencies:
- dependency-name: simple-get
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-04 08:58:05 +00:00
ludwiczakpawel
baa4ea1ed0
Applying Crayons to Content Manager pages (#16375)
* .

* comments

* .

* badges new

* edit podcasts

* edit badges

* whoops

* fixes

* like

* like
2022-02-04 09:31:59 +01:00
Suzanne Aitchison
e8154fb19c
Copy organization secret code to clipboard (#16358)
* init copy to clipboard functionality for org secret code

* add cypress test

* woops
2022-02-04 08:22:03 +00:00