openlayers-8.x-4.x-dev/src/Plugin/Source/Stamen/Stamen.php
src/Plugin/Source/Stamen/Stamen.php
<?php
namespace Drupal\openlayers\Plugin\Source\Stamen;
use Drupal\openlayers\Types\Source;
/**
* FIX - Insert short comment here.
*
* @OpenlayersPlugin(
* id = "ol_source_stamen",
* label = @Translation("Stamen"),
* description = @Translation("TODO..."),
* service = "openlayers.Source:Stamen",
* library = "openlayers-plugin-source-stamen",
* is_configurable = "true",
* type = "source"
* )
*/
class Stamen extends Source {
/**
* {@inheritdoc}
*/
public function optionsForm(array &$form, array &$form_state) {
$form['options']['layer'] = array(
'#title' => t('Source type'),
'#type' => 'select',
'#default_value' => $this->getOption('layer', 'osm'),
'#options' => array(
'terrain-labels' => 'Terrain labels',
'watercolor' => 'Watercolor',
),
);
}
}
