<?php
namespace SabaiApps\Directories\Component\WordPressContent\FieldWidget;

use SabaiApps\Directories\Component\Entity\Model\Bundle;
use SabaiApps\Directories\Component\Field\Widget\TextfieldWidget;

class ShortcodeFieldWidget extends TextfieldWidget {

	protected function _fieldWidgetInfo() {
		$info                = parent::_fieldWidgetInfo();
		$info['field_types'] = array( $this->_name );
		return $info;
	}

	public function fieldWidgetSettingsForm( $fieldType, Bundle $bundle, array $settings, array $parents = array(), array $rootParents = array() ) {
		$form                   = parent::fieldWidgetSettingsForm( $fieldType, $bundle, $settings, $parents, $rootParents );
		$form['mask']['#type']  = 'hidden';
		$form['mask']['#value'] = null;

		return $form;
	}
}
