wordpress-mobile / wordpress-mobile/WordPress-iOS

Quote shared from Safari should put "Read on [url]" in <cite>

Open
#15,619 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

[Pri] Medium [Type] Bug Posting/Editing
Dominant language
Swift
Stars
3.9k
Forks
1.2k
Avg merge
23h 51m
Merged PRs (30d)
58

Description

Expected behavior

The "Read on" text of a shared quote from Safari should be wrapped in <cite> tags, as happens when using the quote Gutenberg block.

Actual behavior

Sharing a page on Safari with highlighted text creates a blockquote with "Read on [url]" as "naked" text inside of the blockquote <p>

Steps to reproduce the behavior
  1. Highlight some text on a page in Safari
  2. Share the page to WordPress and publish

The quote is saved with this markup:

<blockquote>
<p>Lorem ipsum dolor sit amet, lorem ipsum dolor sit amet,
lorem ipsum dolor sit amet, lorem ipsum dolor sit amet
<br />— Read on <a href="https://www.example.com">example.com</a></p>
</blockquote>

It should be saved with this markup:

<blockquote>
<p>Lorem ipsum dolor sit amet, lorem ipsum dolor sit amet,
lorem ipsum dolor sit amet, lorem ipsum dolor sit amet</p>
<cite>Read on <a href="https://www.example.com">example.com</a></cite>
</blockquote>
Tested on [device], iOS [version], WPiOS [version]

iPhone 11, iOS 14.3, WPiOS 16.3

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No file or test is named in the issue. Start by reproducing the Safari share flow and tracing where the shared quote HTML is assembled; done means the saved markup places “Read on [url]” in a cite element outside the paragraph, matching the Gutenberg block behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
ios, swift
Domain
mobile
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.