Commit graph

46 commits

Author SHA1 Message Date
Ben Halpern
7003d9154d
Do not display skip link on mobile search page (#14999) 2021-10-11 10:02:18 -04:00
Ben Halpern
036d75aa6e
Admin-configurable display locale (#14620)
* Admin-configurable display locale

* Add i18n-js and namespacing

* Basic tests and clean up

* A few test adjustments

* Update vendor cache

* Fix a few tests

* Fix a few tests

* Update app/views/articles/_actions.html.erb

Co-authored-by: Michael Kohl <citizen428@dev.to>

* Update app/views/articles/_comments_actions.html.erb

Co-authored-by: Michael Kohl <citizen428@dev.to>

* Update app/views/articles/_single_story.html.erb

Co-authored-by: Michael Kohl <citizen428@dev.to>

* Update app/views/articles/_single_story.html.erb

Co-authored-by: Michael Kohl <citizen428@dev.to>

* Update app/views/comments/_comment_header.html.erb

Co-authored-by: Michael Kohl <citizen428@dev.to>

* Update app/views/layouts/_sidebar_tags.html.erb

Co-authored-by: Michael Kohl <citizen428@dev.to>

* Update app/views/listings/index.html.erb

Co-authored-by: Michael Kohl <citizen428@dev.to>

* Update spec/system/homepage/user_visits_homepage_articles_spec.rb

Co-authored-by: Michael Kohl <citizen428@dev.to>

* Update spec/system/user/view_user_index_spec.rb

Co-authored-by: Michael Kohl <citizen428@dev.to>

* Alphabetical locale page

* Add activerecord custom validation error translations

* Add i18n to webpacker

* Fix a few tests

* Adjust error messages

* Add i18n-tasks

* Adjust JS to get working with jest

* Adjust the way translations are pulled in

* Adjust jest tests

* Remove time localization

* Remove superfluous public js

* Add basic tests for i18n application controller

* Remove unnecessary content

Co-authored-by: Michael Kohl <citizen428@dev.to>
2021-09-28 11:04:35 -04:00
Suzanne Aitchison
a884c56828
Reinstate skip link on search page (#14463)
* reinstate skip link on search page

* actually commit the tests this time

* use optional chaining

* Revert "use optional chaining"

This reverts commit 921677f425c2e90f272a6e21dc8a8d37f916e0da.
2021-08-11 11:50:49 +01:00
Jeferson S. Brito
83a36cb80b
Add aria-live announcement to notify users of the route change (#14284)
* Add aria-live to search results

* Add aria-live inside page-content-inner

* Update title variable and aria-live attribute

Co-authored-by: Suzanne Aitchison <suzanne@forem.com>

Co-authored-by: Suzanne Aitchison <suzanne@forem.com>
2021-07-27 14:14:45 +01:00
Keshav Biswa
f36459e880
Fix changing feed filters on mobile screen size (#14191) 2021-07-12 13:02:55 +02:00
Michael Kohl
a627ede98d
Don't show "Skip to content" link for searches (#14072) 2021-06-28 09:58:38 +02:00
Monica Mateiu
486c1890f2
autofocus Skip Link on keyboard navigation (#13828)
* autofocus Skip Link on keyboard navigation

* focus Skip Link on route change if Skip Link exists

Co-authored-by: Suzanne Aitchison <suzanne@forem.com>

Co-authored-by: Suzanne Aitchison <suzanne@forem.com>
2021-05-27 13:13:46 +02:00
Nick Taylor
de64c3f4ff
[15 min fix] Used the all browser supported document.body. (#13397) 2021-04-14 19:51:41 -04:00
Nick Taylor
7c1343be9e
Revert "Revert "Removed service worker (#12974)" (#13014)" (#13015)
This reverts commit 2416387fb4.
2021-03-17 10:57:56 -04:00
Molly Struve
2416387fb4
Revert "Removed service worker (#12974)" (#13014)
This reverts commit 4fb6230606.
2021-03-16 18:10:01 -05:00
Nick Taylor
4fb6230606
Removed service worker (#12974) 2021-03-16 15:55:31 -04:00
Katie Davis
6a660776fa
fix check to remove class from null element (#12488) 2021-01-29 14:10:07 -05:00
Marcy Sutton
f072730f0f
Header navigation dropdown accessibility (#11509)
* Improve keyboard a11y of header menu dropdown

This commit also includes some cleanup of unnecessary functions that seemed to degrade performance.

Closes https://github.com/forem/forem/issues/1154

* Add temporary focus style on navigation-button

* Put menu items in a list

* Adjust menu button based on VoiceOver testing

* Refactor menu logic to be reusable/work on touch

* Preserve admin link visibility

* Focus on first item on menu open

* Clean up some HTML and CSS

* Apply suggestions from code review

Co-authored-by: ludwiczakpawel <ludwiczakpawel@gmail.com>

* Ensure menu hides on click outside

* Rename toggle function and adjust formatting

* Update nav button focus style

* Clean up padding on header avatar focus style

* Make button show focus state for keyboard only

Using .focus-visible:focus targets keyboard focus and eliminates a flash of the blue border on click before focus is moved to the child item (which also has no focus style on mouse click)

* Update app/views/layouts/_top_bar.html.erb

Co-authored-by: ludwiczakpawel <ludwiczakpawel@gmail.com>

* Add some defensive programming

* Removed initializeTouchDevice from base.js.erb

* navigation-butt ID is now member-menu-button

* Moved all the logic from initializeTouchDevice.js into a pack file/utilities.

* committing re-ordered schema after setup

* add tests for initializeTouchDevice

* remove some unneeded html setup

* make sure menu doesn't close if user tabs back from sign out

* Revert "committing re-ordered schema after setup"

This reverts commit a41a1c861cca3b97d8a7b8a99268b8afaae9f028.

* optimized code

* small tweaks, only show outline when focused

Co-authored-by: ludwiczakpawel <ludwiczakpawel@gmail.com>
Co-authored-by: rhymes <rhymes@hey.com>
Co-authored-by: Nick Taylor <nick@dev.to>
Co-authored-by: Suzanne Aitchison <suzanne@forem.com>
2021-01-27 09:39:17 +00:00
Robin Gagnon
1a3f2739f8
feat: Preload links on focus (#11377)
* feat: Preload links on focus

* Add explaining comment for link preload on focus

* Reformat comment

* Remove focus event listener removal
2020-11-12 09:16:04 -05:00
Andrew Bone
b37b633b35
[deploy] Add scroll to Anchor (#10464)
* Add scroll to Anchor

* Fix code typos

* Move to template litterals
2020-10-07 12:55:57 -05:00
Ben Halpern
3e09a7768f
[deploy] Remove need for ENV vars during asset precompile (#10349)
* Remove need for ENV vars during asset precompile

* Add open-search test
2020-09-16 13:57:05 -04:00
Mac Siri
e330298561
[deploy] Update instantClick's script clone logic (#9542) 2020-07-28 09:06:58 -04:00
Mac Siri
5e43911f17
[deploy] Update Honeybadger's ignorePatterns (#9420) 2020-07-21 17:15:36 -04:00
Mac Siri
aa8e6e29ab
[deploy] Log instantClick errors (#9226) 2020-07-09 14:32:22 -04:00
Mac Siri
f63d9a32bb
Ignore MetaMask errors on Honeybadger (#9190) 2020-07-08 12:35:43 +02:00
Mac Siri
5739b9d651
[deploy] Update Honeybadger to ignore ResizeObserver (#9057) 2020-07-02 16:24:36 -04:00
Ben Halpern
cfa5e882ce
[deploy] Add SiteConfig for feed style (#8721)
* Add SiteConfig for feed style

* Merge master

* Merge master

* Fix typo
2020-06-24 12:14:33 -04:00
Vaidehi Joshi
65341d9c6e
Disable ahoy.js visit tracking on server-side (#8872) 2020-06-24 09:53:47 -04:00
Vaidehi Joshi
fabef71fb7
[deploy] Disable ahoy.js cookie tracking (#8866) 2020-06-23 17:16:15 -04:00
Vaidehi Joshi
904f0dac78
Add ahoy + welcome notification tracking (#8758) [deploy]
* Set up ahoy gem, add ahoy-js

* Import ahoy.js into base.js.erb

* Add trackNotification function to notifications/index.html.erb

* Add sanitized_broadcast_id helper

* Use sanitized_broadcast_id in broadcast partial

* Add specs around tracking welcome notifications

* Remove optional fields from Ahoy::Visit migration + table

* Fiddle with trait to see if it helps with CI failures

* Disable geocode tracking in ahoy

* Stub out SiteConfig in notifications page spec
2020-06-18 13:40:14 -07:00
rhymes
2d26318cf9
[deploy] Replace (black|white)list with more inclusive language (#7459)
* Replace isBlacklisted

* Update fastly.rake task

* More renames

* Rename Faslty config file

* More changes

* Replace isForbiddenFromPreloading with isNotPreloadable

* Skip problematic test

* Re-enable
2020-04-27 18:00:12 +02:00
Molly Struve
4ab202ab0a
[deploy] Execute Reading List searches in Elasticsearch (#7440)
* Execute Reading List searches in Elasticsearch

* add additional readinglist front tests
2020-04-24 10:30:17 -04:00
rhymes
09cf6719eb Use honeybadger.js from npm (#5643)
rails-assets.org is often down, and apparently has been down intermittently since yesterday.

In addition to this the only thing the gem does is literally to add `honeybadger.js` to the assets path:

```ruby
gem_path.join('app/assets').each_child.to_a
```

Hence we can ditch the gem and use the library directly.
2020-01-22 08:22:51 -05:00
Ben Halpern
500ec5d3b0
Guard for presence of page-content in JS (#5138) [deploy]
* Guard for presence of page-content in JS

* Modify offline states sw

* Change from skipping . to skipping .js and .css

* Bump static cache version
2019-12-16 14:02:59 -05:00
Molly Struve
834eb51e98
Replace Airbrake with Honeybadger (#5007) [deploy] 2019-12-05 11:29:51 -06:00
Mac Siri
f62bc7faa8 Fix js-breaking webcomponent (#3087)
* Remove webcomponents-loader

* Add unpkg webcomponent-loader

* Update clipboard-copy-element to include @githubscope

* Make WebComponent loading async

* Simplify clipboardCopy
2019-06-10 11:23:42 -04:00
Ben Halpern
166e26bdf9
Move webcomponents-loader to lib and clean out some dead code (unrelated) (#2838) 2019-05-14 22:00:46 -04:00
Ben Halpern
995d4eb1e2
Add pagination to listings (#2775) 2019-05-09 14:58:26 -04:00
Ben Halpern
c90be27677
Ignore unnecessary airbrake notices (#2283) 2019-04-01 17:40:50 -04:00
rhymes
96d01b20a2 Use allow/allowed instead of whitelist (#1296)
* Use allow/allowed instead of whitelist

* Remove duplication in comment
2018-12-10 13:16:16 -05:00
Ben Halpern
c3d5220767
Add haptic message for iOS feedback (#1287) 2018-12-09 12:30:14 -05:00
Mac Siri
801043ab0d
Mute Pusher errors (#993) 2018-10-24 11:12:34 -04:00
Ben Halpern
e64782572e
Get way less cute with pull-to-refresh (#866) 2018-10-08 20:08:11 -04:00
Ben Halpern
0b2ecd44b3
Add pull-to-refresh for index views (#859) 2018-10-08 14:26:21 -04:00
Ben Halpern
a0491657dd
Add tracking for home page featured impressions/clicks (#804) 2018-10-03 14:05:00 -04:00
Ben Halpern
044be9e162
Modify instantclick to follow 404/500/302 statuses etc. (#593) 2018-09-04 17:20:13 -04:00
Ben Halpern
2cae371044
Remove event ping tracking because it was confusing us (#662) 2018-08-06 13:53:22 -04:00
Ben Halpern
e943087405
Add open source countdown and 30 second on-site ping (#645)
* Add open source countdown and 30 second on-site ping

* Add condition to not ping on first loop
2018-08-01 11:41:57 -04:00
Ben Halpern
749d61a5c1
Remove fetch polyfill and other misc small fixes (#629)
* Remove fetch polyfill and other misc small fixes

* Remove fetch polyfill and other misc small fixes
2018-07-27 10:13:38 -07:00
Mac Siri
40f488d991 Migrate to Travis CI (part 2) (#591)
* Update Travis.yml

* Update README

* Update README

* Adjust test to not rely on env vars

* Update encryption

* Refactor

* Update env key

* Stub AWS calls

* Create ApplicationConfig

* Fix specs

* Fix lint

* Update ApplicationConfig

* Remove travis env vars

* Fix lint

* Extend character limit to 100

* Add env to travis

* Take out auto-restart after deploy

* Immediately discarded test cache

* Stub GA in request specs

* Stub Pusher

* Fix broken specs

* Update fixture

* Add CodeClimate id

* Change CodeClimate key

* Remove merge mistakes

* WIP

* Add Envied gem & Change README

* Add missing keys

* Add missing key

* Update fixture

* Fix broken spec

* Add Slack Notification for Travis

* Fix wording

* Fix typo
2018-07-20 20:17:18 -04:00
Mac Siri
301c6080e3 Initial commit 2018-02-28 16:11:08 -05:00