From e14930f860c4e0ced43aafe986e541d0cbee40b4 Mon Sep 17 00:00:00 2001 From: vrana Date: Wed, 17 Oct 2012 17:20:04 -0700 Subject: [PATCH] Provide assist for Remarkup table Summary: Can you please pick up the icon for it and regenerate sprites? Test Plan: Selected text, clicked on it. Unselected text, clicked on it. Reviewers: epriestley, chad Reviewed By: epriestley CC: aran, Korvin Differential Revision: https://secure.phabricator.com/D3730 --- src/__celerity_resource_map__.php | 2 +- src/view/form/control/PhabricatorRemarkupControl.php | 3 +++ .../application/core/behavior-phabricator-remarkup-assist.js | 3 +++ 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/__celerity_resource_map__.php b/src/__celerity_resource_map__.php index b0198e160e..b786dde1d0 100644 --- a/src/__celerity_resource_map__.php +++ b/src/__celerity_resource_map__.php @@ -1559,7 +1559,7 @@ celerity_register_resource_map(array( ), 'javelin-behavior-phabricator-remarkup-assist' => array( - 'uri' => '/res/7cb3a2ff/rsrc/js/application/core/behavior-phabricator-remarkup-assist.js', + 'uri' => '/res/8a4f3a35/rsrc/js/application/core/behavior-phabricator-remarkup-assist.js', 'type' => 'js', 'requires' => array( diff --git a/src/view/form/control/PhabricatorRemarkupControl.php b/src/view/form/control/PhabricatorRemarkupControl.php index 8fe9615c76..cb31f4a950 100644 --- a/src/view/form/control/PhabricatorRemarkupControl.php +++ b/src/view/form/control/PhabricatorRemarkupControl.php @@ -58,6 +58,9 @@ final class PhabricatorRemarkupControl extends AphrontFormTextAreaControl { 'code' => array( 'tip' => pht('Code Block'), ), + 'table' => array( + 'tip' => pht('Table'), + ), 'help' => array( 'tip' => pht('Help'), 'align' => 'right', diff --git a/webroot/rsrc/js/application/core/behavior-phabricator-remarkup-assist.js b/webroot/rsrc/js/application/core/behavior-phabricator-remarkup-assist.js index 15ac125254..11db6f95ba 100644 --- a/webroot/rsrc/js/application/core/behavior-phabricator-remarkup-assist.js +++ b/webroot/rsrc/js/application/core/behavior-phabricator-remarkup-assist.js @@ -56,6 +56,9 @@ JX.behavior('phabricator-remarkup-assist', function(config) { sel = " " + sel.join("\n "); update(area, ((r.start == 0) ? "" : "\n\n"), sel, "\n\n"); break; + case 'table': + update(area, (r.start == 0 ? '' : '\n\n') + '| ', sel || 'data', ' |'); + break; } }