diff core/modules/breakpoint/src/Breakpoint.php @ 0:c75dbcec494b

Initial commit from drush-created site
author Chris Cannam
date Thu, 05 Jul 2018 14:24:15 +0000
parents
children
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/core/modules/breakpoint/src/Breakpoint.php	Thu Jul 05 14:24:15 2018 +0000
@@ -0,0 +1,57 @@
+<?php
+
+namespace Drupal\breakpoint;
+
+use Drupal\Core\Plugin\PluginBase;
+
+/**
+ * Default object used for breakpoint plugins.
+ *
+ * @see \Drupal\breakpoint\BreakpointManager
+ * @see plugin_api
+ */
+class Breakpoint extends PluginBase implements BreakpointInterface {
+
+  /**
+   * {@inheritdoc}
+   */
+  public function getLabel() {
+    return $this->t($this->pluginDefinition['label'], [], ['context' => 'breakpoint']);
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  public function getWeight() {
+    return (int) $this->pluginDefinition['weight'];
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  public function getMediaQuery() {
+    return $this->pluginDefinition['mediaQuery'];
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  public function getMultipliers() {
+    return $this->pluginDefinition['multipliers'];
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  public function getProvider() {
+    return $this->pluginDefinition['provider'];
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  public function getGroup() {
+    return $this->pluginDefinition['group'];
+  }
+
+}