Page MenuHomePhabricator

Make remarkup link generation rules more flexible and consistent
ClosedPublic

Authored by epriestley on Jun 2 2016, 1:44 AM.
Tags
None
Referenced Files
F14436548: D16006.diff
Thu, Dec 26, 12:26 AM
F14429155: D16006.diff
Wed, Dec 25, 3:57 PM
Unknown Object (File)
Thu, Dec 19, 5:25 PM
Unknown Object (File)
Thu, Dec 12, 10:49 PM
Unknown Object (File)
Thu, Dec 12, 10:49 PM
Unknown Object (File)
Thu, Dec 12, 10:49 PM
Unknown Object (File)
Mon, Dec 9, 7:05 PM
Unknown Object (File)
Wed, Dec 4, 3:34 PM
Subscribers
None

Details

Summary

Ref T10903. Ref T6299. This provides better support for same-window Remarkup links (for CORGI) and getting the base URI / current page / anchor behavior correct (for Phame custom domains).

The uri.prefix config setting currently has no callsites and is essentially always wrong for either anchor links or same-domain links, unless you happen to be on the home page. Instead:

  • uri.base: Base URI for /x/y/ links, e.g. https://blog.whatever.com/.
  • uri.here: Base URI for #anchor links, e.g. https://blog.whatever.com/post/whatever/.
  • uri.same-window: Render offsite hyperlinks without target="_blank".

The first two will fix Phame custom domain stuff. The third one will let CORGI links stay in the same window.

Test Plan

Unit tests, see also next diff.

Diff Detail

Repository
rPHU libphutil
Branch
phame1
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 12395
Build 15692: Run Core Tests
Build 15691: arc lint + arc unit

Event Timeline

epriestley retitled this revision from to Make remarkup link generation rules more flexible and consistent.
epriestley updated this object.
epriestley edited the test plan for this revision. (Show Details)
epriestley added a reviewer: chad.
chad edited edge metadata.
This revision is now accepted and ready to land.Jun 2 2016, 2:23 AM
This revision was automatically updated to reflect the committed changes.