mirror of
https://we.phorge.it/source/phorge.git
synced 2025-03-24 02:01:01 +01:00
Fix quick create on mobile
Summary: Fixes T4903. At some point maybe-soonish we should maybe go make `"device" => true` the default, and put `"device" => "hella-busted"` on the remaining bad pages. Test Plan: L@@K @ W/ iOS Simulator Reviewers: chad Reviewed By: chad Subscribers: epriestley, k Maniphest Tasks: T4903 Differential Revision: https://secure.phabricator.com/D8863
This commit is contained in:
parent
b53a9f0e12
commit
8fc5977b9a
2 changed files with 5 additions and 1 deletions
src/applications
home/controller
people/remarkup
|
@ -29,6 +29,7 @@ final class PhabricatorHomeQuickCreateController
|
|||
),
|
||||
array(
|
||||
'title' => pht('Quick Create'),
|
||||
'device' => true,
|
||||
));
|
||||
}
|
||||
|
||||
|
|
|
@ -18,7 +18,10 @@ final class PhabricatorRemarkupRuleMention
|
|||
// username, so we'll incorrectly pick it up, but there's little to be done
|
||||
// about that. We forbid terminal periods so that we can correctly capture
|
||||
// "@joe" instead of "@joe." in "Hey, @joe.".
|
||||
const REGEX = '/(?<!\w)@([a-zA-Z0-9._-]*[a-zA-Z0-9_-])/';
|
||||
//
|
||||
// We disallow "@@joe" because it creates a false positive in the common
|
||||
// construction "l@@k", made popular by eBay.
|
||||
const REGEX = '/(?<!\w|@)@([a-zA-Z0-9._-]*[a-zA-Z0-9_-])/';
|
||||
|
||||
public function apply($text) {
|
||||
return preg_replace_callback(
|
||||
|
|
Loading…
Add table
Reference in a new issue