comparison core/lib/Drupal/Core/Template/Attribute.php @ 18:af1871eacc83

Update to Drupal core 8.7.1
author Chris Cannam
date Thu, 09 May 2019 15:33:08 +0100
parents 4c8ae668cc8c
children
comparison
equal deleted inserted replaced
17:129ea1e6d783 18:af1871eacc83
260 } 260 }
261 return $this; 261 return $this;
262 } 262 }
263 263
264 /** 264 /**
265 * Gets the class attribute value if set.
266 *
267 * This method is implemented to take precedence over hasClass() for Twig 2.0.
268 *
269 * @return \Drupal\Core\Template\AttributeValueBase
270 * The class attribute value if set.
271 *
272 * @see twig_get_attribute()
273 */
274 public function getClass() {
275 return $this->offsetGet('class');
276 }
277
278 /**
265 * Checks if the class array has the given CSS class. 279 * Checks if the class array has the given CSS class.
266 * 280 *
267 * @param string $class 281 * @param string $class
268 * The CSS class to check for. 282 * The CSS class to check for.
269 * 283 *