Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Weight.php

function Weight::getInfo

Overrides ElementInterface::getInfo

File

core/lib/Drupal/Core/Render/Element/Weight.php, line 34

Class

Weight
Provides a form element for input of a weight.

Namespace

Drupal\Core\Render\Element

Code

public function getInfo() {
    $class = static::class;
    return [
        '#input' => TRUE,
        '#delta' => 10,
        '#default_value' => 0,
        '#process' => [
            [
                $class,
                'processWeight',
            ],
            [
                $class,
                'processAjaxForm',
            ],
        ],
    ];
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal