forked from Snck3rs/contao-leaflet-maps
Add map width and height to the content element.
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
|
||||
$GLOBALS['TL_DCA']['tl_content']['metapalettes']['leaflet'] = array(
|
||||
'type' => array('type', 'headline'),
|
||||
'leaflet' => array('leaflet_map'),
|
||||
'leaflet' => array('leaflet_map', 'leaflet_width', 'leaflet_height'),
|
||||
'templates' => array(':hide', 'customTpl'),
|
||||
'protected' => array(':hide', 'protected'),
|
||||
'expert' => array(':hide', 'guests', 'cssID', 'space'),
|
||||
@@ -20,3 +20,24 @@ $GLOBALS['TL_DCA']['tl_content']['fields']['leaflet_map'] = array(
|
||||
),
|
||||
'sql' => "int(10) unsigned NOT NULL default '0'"
|
||||
);
|
||||
|
||||
$GLOBALS['TL_DCA']['tl_content']['fields']['leaflet_width'] = array(
|
||||
'label' => &$GLOBALS['TL_LANG']['tl_content']['leaflet_width'],
|
||||
'inputType' => 'inputUnit',
|
||||
'options' => array('px', '%', 'em', 'pt', 'pc', 'in', 'cm', 'mm'),
|
||||
'search' => false,
|
||||
'exclude' => true,
|
||||
'eval' => array('rgxp' => 'digit', 'tl_class' => 'clr w50'),
|
||||
'sql' => "varchar(64) NOT NULL default ''"
|
||||
);
|
||||
|
||||
|
||||
$GLOBALS['TL_DCA']['tl_content']['fields']['leaflet_height'] = array(
|
||||
'label' => &$GLOBALS['TL_LANG']['tl_content']['leaflet_height'],
|
||||
'inputType' => 'inputUnit',
|
||||
'options' => array('px', '%', 'em', 'pt', 'pc', 'in', 'cm', 'mm'),
|
||||
'search' => false,
|
||||
'exclude' => true,
|
||||
'eval' => array('rgxp' => 'digit', 'tl_class' => 'w50'),
|
||||
'sql' => "varchar(64) NOT NULL default ''"
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user