You are here

public static function SchemaTypeBase::labels in Schema.org Metatag 8

Return a list of object labels.

This is generally the only method that needs to be extended for type tags. Either return a simple array of types, or prefix the type names with dashes and spaces to indicate their hierarchy. The prefixed dashes and spaces will be removed when creating the raw list of available types.

See also

SchemaOrganizationType::labels()

2 calls to SchemaTypeBase::labels()
SchemaTypeBase::typeOptions in src/Plugin/metatag/Tag/SchemaTypeBase.php
Turn the list of types into an option list.
SchemaTypeBase::types in src/Plugin/metatag/Tag/SchemaTypeBase.php
Return a list of object types.
23 methods override SchemaTypeBase::labels()
SchemaArticleType::labels in schema_article/src/Plugin/metatag/Tag/SchemaArticleType.php
Return a list of object labels.
SchemaBookType::labels in schema_book/src/Plugin/metatag/Tag/SchemaBookType.php
Return a list of object labels.
SchemaCourseType::labels in schema_course/src/Plugin/metatag/Tag/SchemaCourseType.php
Return a list of object labels.
SchemaEventType::labels in schema_event/src/Plugin/metatag/Tag/SchemaEventType.php
Return a list of object labels.
SchemaHowToType::labels in schema_how_to/src/Plugin/metatag/Tag/SchemaHowToType.php
Return a list of object labels.

... See full list

File

src/Plugin/metatag/Tag/SchemaTypeBase.php, line 20

Class

SchemaTypeBase
Provides a plugin for the 'schema_type_base' meta tag.

Namespace

Drupal\schema_metatag\Plugin\metatag\Tag

Code

public static function labels() {
  return [
    'Organization',
  ];
}