Commit graph

3678 commits

Author SHA1 Message Date
Mac Siri
20faec4899
Support chromedriver in container (#20224) 2023-10-16 15:12:53 -04:00
ktmouk
b45f3d3024
Fix code block rendering not working inside details (#20229) 2023-10-16 14:14:04 -04:00
Ben Halpern
bc89cf3e38
Store browser accept language header on users (#20212)
* Store browser accept language header on users

* Change to tracking via user context

* Remove async info code

* First draft of spec

* Work out tests

* Delete dependents
2023-10-16 11:59:30 -04:00
Anna Buianova
5ac786c9a1
Add email to the users api (#20241)
* Add email to the users api if display_public_email_on_profile is set to true

* Fixed selected user fields in the api

* A separate partial for user data with email (for the api)
2023-10-13 16:27:21 +03:00
ktmouk
33a32db94f
Support all embed URL options of Stackblitz (#20228) 2023-10-11 12:58:53 -04:00
Anna Buianova
a14a1e9e7a
Accept published_at in Article API (#20235) 2023-10-11 09:12:35 -04:00
Mac Siri
341f64c0d3
Bump with_model (#20222) 2023-10-06 11:24:25 -04:00
Narender Singh
2a489210a2
Remove unique article title validation (#20031) 2023-10-05 14:59:50 -04:00
ktmouk
bbf2719582
Update OAuth removal instructions (#20036) 2023-10-04 14:43:20 -04:00
Ben Halpern
044fe88230
Follow on adjustments to flag counts (#20207) 2023-10-02 17:23:37 +07:00
Ben Halpern
f811f17830
Fix irrelevant flag numbers (#20204)
* Fix irrelevent numbers in admin display

* Remove unused possible_spam_users_count

* Fix tab styles
2023-10-02 15:01:50 +07:00
Ben Halpern
19004680de
Make admin reports default to showing open (#20200) 2023-10-02 12:24:56 +07:00
Ben Halpern
456a5e61d2
Add filters to /mod (#20179)
* Add filters to /mod

* Adjust cypress to look for proper text

* Adjust cypress to be less sensitive
2023-10-02 11:47:49 +07:00
Ben Halpern
8268a59ae5
Add feed event for extended page view (#20198) 2023-10-02 10:28:31 +07:00
Ben Halpern
c5201ca888
Remove dead code associated with old roles (#20175)
* Remove dead code associated with old roles

* Remove test references

* Removed from seeds

* Removed unused roles from locales

---------

Co-authored-by: lightalloy <lightallloy@gmail.com>
2023-10-01 09:33:25 +07:00
Ben Halpern
c71b2b182f
Change profile image max size to 8 MB (#20183)
* Change profile image max size to 8 MB

* Stub the const for the sake of the test
2023-09-28 17:05:35 -04:00
Ben Halpern
e998e5bcac
Do not show suspended followers in aggregated siblings for notification (#20174) 2023-09-27 20:23:25 -04:00
Ben Halpern
f50e3e7511
Add out-of-date notice to admin overview (#20172) 2023-09-27 10:13:47 -04:00
Joshua Wehner
8216700858
Trusted user _can_ use moderator comment (#20158)
* Trusted user _can_ use moderator comment

* Update spec to confirm cannot create

* Trusted user is trusted

* Better mod template access
2023-09-26 10:24:37 -04:00
Joshua Wehner
2c138d86ef
Add or remove limited role via API (#20136)
* Refactor API user suspend, make room for more roles

* Handle adding limited

* Handle remove limited

* And swagger docs

* Update & refactor roles spec

* Remove old route

* Remove old specs
2023-09-26 09:57:14 -04:00
Joshua Wehner
6a48b486ca
Onboarding: custom newsletter opt-in settings (#20114)
* Settings can process markdown into html

* Update Settings with new onboarding settings

* Async render onboarding newsletter step

* Tweak onboarding design

* Fix broken spec

* Better rendered component test

* Tweaks to match design

* Try to tweak design

* Try having a default state

* Tweak placeholder content

* Better await componentDidMount

* Continue to tweak the design

* ContentRenderer#process should always return Result

* Try more clarity in the partial

* Rubocop
2023-09-26 06:34:19 -04:00
PJ
47deeefe57
Optionally limit new users based on admin setting (#20149)
* create admin setting for new user status

* limiting on signup working 🎉

* update registration specs

* sort out OAuth registrations
2023-09-26 10:46:36 +01:00
Rajat Talesra
5fb94d372b
Reset password design and Signup page update for invite-only forems. (#20145)
* Private forem signup issue fix

* Minor design fixes

* Added click on logo

* Reset password design

* UX fix

* Updated dynamic contact

* Padding fix and test fix

* Complete translations

* Skipped flay test 'should show Feature Post button on an unfeatured post'
2023-09-22 14:49:31 +05:30
Anna Buianova
61f3c517e1
Display post languages in the dashboard (#20137)
* Display post languages in the dashboard

* Added languages locales to several languages variations
2023-09-21 14:42:44 +03:00
PJ
da73343540
Skip round robin mod notifications for limited users (#20128)
* return early if user is limited

* fix worker specs
2023-09-19 15:03:20 +01:00
Ben Halpern
cadebde66f
Add feed_success_score and other count tallies (#20106)
* Add initial feed events score

* Add feed events score

* Clean up code styles

* Adjust how tests are run

* Fix conflicts

* Update app/javascript/articles/Feed.jsx

* Add additional feed events tabulation queries for more reliable eventual consistency

* Add additional feed events tabulation queries for more reliable eventual consistency

* Fix test logic

* Updates from feedback
2023-09-15 12:02:26 -04:00
Ridhwana
aa201060e8
Override Tag Moderation Actions (#20088)
* feat: remove the validation for the article_id and tag_name to be unique on a tag_adjustment

* chore: remove unique index

* feat: update the validate_tag method to align with the removal of unique indexes on the table

* feat: do not allow removal and addition of tags that were added/removed by admins

* spec: add tests for the tag_adjustment_spec

* fix: update the validation of tags

* spec: article validation

* spec: test the action_panel helper

* chore: amend language

* add styles

* Empty commit
2023-09-15 15:06:58 +02:00
Joshua Wehner
c91a652245
Allow trusted users to see whether a user is suspended (#20061)
* Async append user suspended status pill

* Rubocop

* Relocate JS tests, for build & coverage

* Better error-handling for this controller

* Refactor HTML to render pill outside h1

* Continuing to tweak design

* JS class prepended
2023-09-15 08:44:31 -04:00
Ben Halpern
a079434397
Add new invitation params (#20074)
* Add new invitation fields

* SMTP enabled check

* Update spec/requests/api/v1/admin/users_spec.rb

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* Add devise_mailer spec

* Add devise_mailer spec

* Update spec/mailers/devise_mailer_spec.rb

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* Update spec/mailers/devise_mailer_spec.rb

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* Update spec/mailers/devise_mailer_spec.rb

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-09-13 13:01:39 -04:00
Rajat Talesra
a679486572
Redesign sign-up and login pages (#20065)
* Signin Signup screen update

* Design for signin signup finished

* On hover effect

* Fixed few tests

* Fixed rSpec tests

* Minor design fixes

* Design changes suggested by Anuj

* Test fixes

* Updated test

* Nit fixes

* Path changes and footer and topbar hidden

* A bit simplified css

* Removed custom css

* Updated tests

* Nit css fixes

* Updates as per Ridhwana's review

* CSS fixes

* Used js-registration
2023-09-13 21:46:57 +05:30
Ben Halpern
d6d7eeeb59
Add proper follow-user class to liquid when passed UserDecorator (#20101)
* Add proper follow-user class to liquid

* Adjust test
2023-09-13 11:36:21 -04:00
Joshua Wehner
dfe71c15a1
Record feed event for article comments (#20087) 2023-09-13 11:14:27 -04:00
Anna Buianova
56f2a58e95
Default content language for forems (#20089)
Co-authored-by: Ben Halpern <bendhalpern@gmail.com>
2023-09-13 13:26:45 +03:00
Narender Singh
da7c25c987
add new org button in settings (#20014)
* add new org button in settings

* add support for mobile view

* remove varible for new org check

* fix design suggestions

* fix org settings test

* remove the settings for test since this text does not exists in user settings

* remove un-used copy

* Update class name

Co-authored-by: Ridhwana <Ridhwana.Khan16@gmail.com>

* Fix follow user spec

* fix the rspec test case

---------

Co-authored-by: Ridhwana <Ridhwana.Khan16@gmail.com>
2023-09-13 11:52:57 +02:00
PJ
3f922921e5
Admin setting to control enabled countries for billboard geotargeting (#20083)
* use instance setting for enabled target geolocations

* add validation for enabled geolocations setting

* a start on the UI?

* backend tweaks for UI

* proper crack at autocomplete component

* fix region targeting toggle

* e2e spec
2023-09-12 12:06:00 -04:00
PJ
95ca9d37c5
Record feed events for public reactions (#20079)
* create feed event on feed reaction

* move feed event creation to feed event model

* tiny whoops

* fix failing specs

* slightly less flaky e2e spec (maybe)

* tiny fixes (couldn't resist)
2023-09-12 08:36:10 -04:00
Duke Greene
bf4c34636e
display tag moderation history in article's mod panel (#20041)
* logic and markup to display tag adjustment history on article mod panel

* add tag adjustment reason to markup

* add specs for article's tag adjustment association and ordered tag adjustments

* style tag adjustment history

* sketch out cypress test for visible tag moderation history

* tweak spacing and sizing of adjustment history heading

* adjust cypress tests, tag adjustments still coming back empty in spec

* get past first cypress snag by waiting for request and reloading

* add spec for viewing multiple tag adjustments in a post history

* restore defer: true in actions panel js packs call

* add e2e tests for remaining mod views with tag adjustment UI
2023-09-12 07:08:44 -04:00
Anna Buianova
aa5cb535fa
Add languages to User model (#20059) 2023-09-11 11:44:19 -04:00
PJ
3f7d1fbc1a
Create feed impression and click events (#20043)
* getting started: model setup

* basic controller action & spec

* somewhat working click events

* pick up on impressions

* there was an attempt at batching without duplicates

* (better) bulk upsert service

* fix specs?

* touch up feed events JS

* end-to-end specs??

* workers wip

* fix failing user delete spec
2023-09-11 13:32:36 +01:00
Ben Halpern
ed853f7e1e
Fix "register" bugs in invitations (#20071)
* Fix registered bugs in invitations

* Update spec/requests/api/v0/admin/users_spec.rb

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* Move to v1 spec

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-09-08 17:00:37 -04:00
Ben Halpern
22f836edc2
Add priority weight to billboards (#20019)
* Add priority weight to billboards

* Rewrite query as activerecord

* Change naming from priority_weight to just weight
2023-09-05 16:04:18 -04:00
Ridhwana
a6d8767aaa
Use explicit points for following and hidden tags (#20032) 2023-09-05 19:17:27 +02:00
Anna Buianova
7e83f18eca
Renamed display ad leftovers (test descriptions, swagger) (#20007) 2023-08-30 17:52:55 +03:00
Ben Halpern
02db638d9d
Remove cache headers from sidebars controller (#20002)
* Remove cache headers from sidebars controller

* Remove cache bust logic for sidebar
2023-08-29 13:42:10 -04:00
Ben Halpern
944991a432
Adjust ActiveThreadsQuery to use home_feed_minimum_score (#20004) 2023-08-29 09:35:09 -04:00
Joshua Wehner
d227e1d285
Suppressing articles negative-follow tags from appearing in the "relevant" feed (#19948)
* Try suppressing all negative-follow tags

* userData isn't always available

* Bolster test coverage for tag filter scenarios

* Antitags for the non-basic 'strategy'

* Rename antitags -> hidden_tags

* Rename 'anti_tags' -> 'hidden_tags' as well

* Use userData.followed_tags to derive hidden_tags
2023-08-28 10:11:20 -04:00
Ben Halpern
3324bf47f1
Add http_header to FastText for Fastly compatibility (#19999)
* Add http_header to FastText for Fastly compatibility

* Update app/services/articles/enrich_image_attributes.rb

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* Update app/services/html/parser.rb

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* Update spec/models/display_ad_spec.rb

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* Fix rubocop

* Also accept canges to main image for this re-calc

* Rename display_ad_spec for compatibility with main

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-08-28 09:34:59 -04:00
Anna Buianova
2d6b740940
Renamed DisplayAd model to Billboard (#19993)
* Renamed Resource Admin: DisplayAd to Billboard

* Renamed DisplayAd to Billboard

* Added a data update script for roles
2023-08-28 08:09:36 -04:00
Ridhwana
5266dd1afb
Showing and hiding tags in the Following and Hidden Tags Pages (#19954)
* feat: remove updated weights

* feat: click on following on the following tags page

* feat: add and listen for the following button click

* fix: dropdowns

* feat: handle hide button click

* feat: update the nav link for following tags

* feat: handel the 'unhide button' on the hidden tags page

* feat: add the styling for the buttons

* feat: add localization

* feat: remove the brand from the card

* feat: add some styling to the page

* feat: init scrolling

* chore: update the name of the file

* feat: abstract out the comment fetch code

* fix: close the attribute

* feta: make some adjustments to where the tag adn the follow show up

* rename class from plural to singular

* feat: updae the comment

* feat: add a mutation observer to initialize the dropdown

* test: follow_craete

* chore: remove irrelevant test

* feat: update the cypress seeds

* feat: update the cypress seeds

* spec: write soem initial tests for the following tags page

* spec: update the unfollow cypress spec

* spec: update the hide cypress spec

* spec: update the posts published spec

* note to add test for pagination

* spec: hidden tags page

* feat: remove aria pressed attributes

* fix: ordering by explicit points gets the page params confused and returns the incorrect and not all results on pagination

* fix: use explicit points

* feat: remove the message at the top of the following and hidden tags page

* chore: remove comment and rather add it to the PR itself

* refactor: do all the actions on success

* feat: refactor the dashboard tag file

* refactor: only show the tagId and followId dataset attributes on the dashboard__tag__container

* feat: disconnect the observer

* chore: add some documentation

* feat: add fr localization

* chore: empty line

* fix: update the dashboardTags page to first declare the observer"
"
"

* fix: update the rails test

* Empty commit

* fix: because I added more tags, the dropdown was longre and covering the body of the editor hence it could not find the text, so I've escaped after selecting my tags
2023-08-25 14:49:39 +02:00
Rajat Talesra
5ef0f43636
Added limited role (#19969)
* Added limited role

* Nit fix

* Updated tetss

* Added spec tests

* Attempt at 100% code coverage

* Rollback DB migration

* Revert timestamp
2023-08-25 14:41:17 +05:30