Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Comments

Article ellipses Open in Browser Support#22642

Closed
mikeydorje wants to merge 1 commit intoforem:mainfrom
mikeydorje:mikeydorje/open-in-browser-dropdown
Closed

Article ellipses Open in Browser Support#22642
mikeydorje wants to merge 1 commit intoforem:mainfrom
mikeydorje:mikeydorje/open-in-browser-dropdown

Conversation

@mikeydorje
Copy link
Contributor

@mikeydorje mikeydorje commented Nov 30, 2025

What type of PR is this? (check all applicable)

  • Refactor
  • Feature
  • Bug Fix
  • Optimization
  • Documentation Update

Description

Add "Open in Browser" link to article dropdown for mobile app

Adds conditional link in article actions dropdown that only appears when accessed from ForemWebView mobile app. Allows users to open articles in their external browser.

Changes:

  • application_helper.rb: forem_webview? helper to detect mobile app
  • _actions.html.erb: Conditional link with external-link icon

Related Tickets & Documents

App counterpart: https://github.com/forem/app/pull/84

  • Related Issue #
  • Closes #

QA Instructions, Screenshots, Recordings

Please replace this line with instructions on how to test your changes, a note
on the devices and browsers this has been tested on, as well as any relevant
images for UI changes.

UI accessibility checklist

If your PR includes UI changes, please utilize this checklist:

  • Semantic HTML implemented?
  • Keyboard operability supported?
  • Checked with axe DevTools and addressed Critical and Serious issues?
  • Color contrast tested?

For more info, check out the
Forem Accessibility Docs.

Added/updated tests?

We encourage you to keep the code coverage percentage at 80% and above.

  • Yes
  • No, and this is why: please replace this line with details on why tests
    have not been included
  • I need help with writing tests

[optional] Are there any post deployment tasks we need to perform?

[optional] What gif best describes this PR or how it makes you feel?

alt_text

@mikeydorje mikeydorje requested a review from a team as a code owner November 30, 2025 23:07
@github-actions
Copy link
Contributor

Thank you for opening this PR! We appreciate you!

For all pull requests coming from third-party forks we will need to
review the PR before we can process it through our CI pipelines.

A Forem Team member will review this contribution and get back to
you as soon as possible!

@mikeydorje mikeydorje force-pushed the mikeydorje/open-in-browser-dropdown branch from 4bd3d04 to 9b6bd01 Compare November 30, 2025 23:53
@mikeydorje mikeydorje changed the title Add Open in Browser to article dropdown for mobile app Article ellipses Open in Browser Support Nov 30, 2025
@mikeydorje mikeydorje requested a review from benhalpern December 1, 2025 16:32
Copy link
Contributor

@benhalpern benhalpern left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This actually won't work because due to caching we won't always know on the server side what the request's user agent is because we cache across all responses. We must add this dynamically via javascript on the frontend.

@mikeydorje
Copy link
Contributor Author

@benhalpern The other version is better anyway I think: https://github.com/forem/app/pull/83

This one would be in the article view only, not in an external webpage, which is the idea.

@mikeydorje mikeydorje marked this pull request as draft December 5, 2025 20:58
@mikeydorje
Copy link
Contributor Author

Other solution is better

@mikeydorje mikeydorje closed this Jan 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants