<div class="form-inline" ng-if=":: $ctrl.parent.canBeImage(col)">
  <label>
    <input type="checkbox" ng-click="$ctrl.parent.toggleImage(col)" >
    {{:: ts('Image') }}
  </label>
</div>
<div class="form-inline" ng-if=":: !$ctrl.parent.canBeImage(col)">
  <label>
    <input type="checkbox" ng-click="$ctrl.parent.toggleHtml(col)" >
    {{:: ts('Allow HTML') }}
  </label>
</div>
<div class="form-inline crm-search-admin-flex-row" >
  <label title="{{:: ts('Display as clickable link') }}" >
    <input type="checkbox" ng-checked="col.link" ng-click="$ctrl.parent.toggleLink(col)" >
    {{:: ts('Link') }}
  </label>
  <select class="form-control" ng-model="col.link.target" ng-if="col.link">
    <option value>{{:: ts('Open normally') }}</option>
    <option value="_blank">{{:: ts('New tab') }}</option>
    <option value="crm-popup">{{:: ts('Popup dialog') }}</option>
  </select>
  <crm-search-admin-link-select ng-if="col.link" link="col.link" on-change="$ctrl.parent.onChangeLink(col, newLink)" api-entity="$ctrl.apiEntity" api-params="$ctrl.apiParams" links="$ctrl.parent.getLinks(col.key)">
  </crm-search-admin-link-select>
</div>
<div class="form-inline crm-search-admin-flex-row">
  <label>
    <input type="checkbox" ng-checked="col.title" ng-click="col.title = col.title ? null : $ctrl.parent.getFieldLabel(col.key)" >
    {{:: ts('Tooltip') }}
  </label>
  <input type="text" class="form-control crm-flex-1" ng-model="col.title" ng-if="col.title" ng-model-options="{updateOn: 'blur'}" />
  <crm-search-admin-token-select ng-if="col.title" model="col" field="title" suffix=":label"></crm-search-admin-token-select>
</div>
<div class="form-inline crm-search-admin-flex-row">
  <label title="{{:: ts('Text to display if the field contents are empty.') }}">
    <input type="checkbox" ng-checked="col.empty_value" ng-click="$ctrl.parent.toggleEmptyVal(col)" >
    {{:: ts('Empty placeholder') }}
  </label>
  <a crm-ui-help="hs({id: 'empty', title: ts('Empty placeholder')})"></a>
  <textarea rows="2" class="form-control crm-flex-1" ng-if="col.empty_value" ng-model="col.empty_value" ng-model-options="{updateOn: 'blur'}"></textarea>
  <crm-search-admin-token-select ng-if="col.empty_value" model="col" field="empty_value" suffix=":label"></crm-search-admin-token-select>
</div>
<div class="form-inline crm-search-admin-flex-row">
  <label title="{{:: ts('Change the contents of this field, or combine multiple field values.') }}">
    <input type="checkbox" ng-checked="col.rewrite" ng-click="$ctrl.parent.toggleRewrite(col)" >
    {{:: ts('Rewrite Text') }}
  </label>
  <a crm-ui-help="hs({id: 'rewrite', title: ts('Rewrite Text')})"></a>
  <textarea rows="2" class="form-control crm-flex-1" ng-if="col.rewrite" ng-model="col.rewrite" ng-model-options="{updateOn: 'blur'}" ng-trim="false"></textarea>
  <crm-search-admin-token-select ng-if="col.rewrite" model="col" field="rewrite" suffix=":label"></crm-search-admin-token-select>
</div>
<div class="form-inline">
  <label ng-if="$ctrl.parent.canBeEditable(col)" title="{{:: ts('Users will be able to click to edit this field.') }}">
    <input type="checkbox" ng-checked="col.editable" ng-click="$ctrl.parent.toggleEditable(col)">
    {{:: ts('In-Place Edit') }}
  </label>
  <label ng-if="!$ctrl.parent.canBeEditable(col)" class="disabled" title="{{:: ts('Read-only or rewritten fields cannot be editable.') }}">
    <input type="checkbox" disabled>
    {{:: ts('In-Place Edit') }}
  </label>
</div>
<search-admin-icons item="col"></search-admin-icons>
<search-admin-css-rules label="{{:: ts('Style') }}" item="col" default="col.key"></search-admin-css-rules>
