diff --git a/core/modules/contextual/contextual.api.php b/core/modules/contextual/contextual.api.php index d972045..428c514 100644 --- a/core/modules/contextual/contextual.api.php +++ b/core/modules/contextual/contextual.api.php @@ -18,9 +18,9 @@ * is passed in by reference. Further links may be added or existing links can * be altered. * - * @param $element + * @param array $element * A renderable array representing the contextual links. - * @param $items + * @param array $items * An associative array containing the original contextual link items, as * generated by * \Drupal\Core\Menu\ContextualLinkManagerInterface::getContextualLinksArrayByGroup(), diff --git a/core/modules/contextual/css/contextual.icons.css b/core/modules/contextual/css/contextual.icons.css index 2a755ca..7b2bd6e 100644 --- a/core/modules/contextual/css/contextual.icons.css +++ b/core/modules/contextual/css/contextual.icons.css @@ -34,8 +34,8 @@ /* Override the .focusable height: auto */ width: 28px !important; text-indent: -9999px; - } + .no-svg .contextual .trigger { background-image: url("../../../misc/icons/bebebe/pencil.png"); } diff --git a/core/modules/contextual/css/contextual.toolbar.css b/core/modules/contextual/css/contextual.toolbar.css index dd06c75..b9023bd 100644 --- a/core/modules/contextual/css/contextual.toolbar.css +++ b/core/modules/contextual/css/contextual.toolbar.css @@ -20,10 +20,10 @@ padding-right: 1.3333em; } .toolbar .toolbar-bar .contextual-toolbar-tab .toolbar-item.active { - background-image:-moz-linear-gradient(rgb(78,159,234) 0%,rgb(69,132,221) 100%); - background-image:-webkit-gradient(linear,color-stop(0, rgb(78,159,234)),color-stop(1, rgb(69,132,221))); + background-image: -moz-linear-gradient(rgb(78,159,234) 0%,rgb(69,132,221) 100%); + background-image: -webkit-gradient(linear,color-stop(0, rgb(78,159,234)),color-stop(1, rgb(69,132,221))); background-image: -webkit-linear-gradient(top, rgb(78,159,234) 0%, rgb(69,132,221) 100%); - background-image:linear-gradient(rgb(78,159,234) 0%,rgb(69,132,221) 100%); + background-image: linear-gradient(rgb(78,159,234) 0%,rgb(69,132,221) 100%); } /* @todo get rid of this declaration by making toolbar.module's CSS less specific */ diff --git a/core/modules/contextual/js/toolbar/models/StateModel.js b/core/modules/contextual/js/toolbar/models/StateModel.js index 048524f..79f8bc7 100644 --- a/core/modules/contextual/js/toolbar/models/StateModel.js +++ b/core/modules/contextual/js/toolbar/models/StateModel.js @@ -25,7 +25,6 @@ tabbingContext: null }, - /** * {@inheritdoc} * diff --git a/core/modules/contextual/src/Plugin/views/field/ContextualLinks.php b/core/modules/contextual/src/Plugin/views/field/ContextualLinks.php index aff000c..4f32746 100644 --- a/core/modules/contextual/src/Plugin/views/field/ContextualLinks.php +++ b/core/modules/contextual/src/Plugin/views/field/ContextualLinks.php @@ -28,6 +28,9 @@ public function usesGroupBy() { return FALSE; } + /** + * {@inheritdoc} + */ protected function defineOptions() { $options = parent::defineOptions(); @@ -37,6 +40,9 @@ protected function defineOptions() { return $options; } + /** + * {@inheritdoc} + */ public function buildOptionsForm(&$form, &$form_state) { $all_fields = $this->view->display_handler->getFieldLabels(); // Offer to include only those fields that follow this one. @@ -60,6 +66,9 @@ public function buildOptionsForm(&$form, &$form_state) { ); } + /** + * {@inheritdoc} + */ public function preRender(&$values) { // Add a row plugin css class for the contextual link. $class = 'contextual-region'; @@ -117,8 +126,8 @@ public function render(ResultRow $values) { array(), array( 'contextual-views-field-links' => UrlHelper::encodePath(Json::encode($links)), - ) - ) + ), + ), ); $element = array( @@ -132,6 +141,9 @@ public function render(ResultRow $values) { } } - public function query() { } + /** + * {@inheritdoc} + */ + public function query() {} } diff --git a/core/modules/contextual/src/Tests/ContextualDynamicContextTest.php b/core/modules/contextual/src/Tests/ContextualDynamicContextTest.php index fd9368a..36cb5bd 100644 --- a/core/modules/contextual/src/Tests/ContextualDynamicContextTest.php +++ b/core/modules/contextual/src/Tests/ContextualDynamicContextTest.php @@ -23,6 +23,9 @@ class ContextualDynamicContextTest extends WebTestBase { */ public static $modules = array('contextual', 'node', 'views', 'views_ui'); + /** + * {@inheritdoc} + */ public static function getInfo() { return array( 'name' => 'Contextual links on node lists', @@ -31,13 +34,20 @@ public static function getInfo() { ); } - function setUp() { + /** + * {@inheritdoc} + */ + public function setUp() { parent::setUp(); $this->drupalCreateContentType(array('type' => 'page', 'name' => 'Basic page')); $this->drupalCreateContentType(array('type' => 'article', 'name' => 'Article')); - $this->editor_user = $this->drupalCreateUser(array('access content', 'access contextual links', 'edit any article content')); + $this->editor_user = $this->drupalCreateUser(array( + 'access content', + 'access contextual links', + 'edit any article content', + )); $this->authenticated_user = $this->drupalCreateUser(array('access content', 'access contextual links')); $this->anonymous_user = $this->drupalCreateUser(array('access content')); } @@ -48,7 +58,7 @@ function setUp() { * Ensures that contextual link placeholders always exist, even if the user is * not allowed to use contextual links. */ - function testDifferentPermissions() { + public function testDifferentPermissions() { $this->drupalLogin($this->editor_user); // Create three nodes in the following order: @@ -118,20 +128,16 @@ function testDifferentPermissions() { * * @param string $id * A contextual link id. - * - * @return bool */ protected function assertContextualLinkPlaceHolder($id) { $this->assertRaw('