public function js_templates()
{
?>
<script type="text/html" id="tmpl-Jetpack_Modules_List_Table_Template">
<# var i = 0;
if ( data.items.length ) {
_.each( data.items, function( item, key, list ) {
if ( item === undefined ) return;
#>
<tr class="jetpack-module <# if ( ++i % 2 ) { #> alternate<# } #><# if ( item.activated ) { #> active<# } #><# if ( ! item.available ) { #> unavailable<# } #>" id="{{{ item.module }}}">
<th scope="row" class="check-column">
<# if ( wpcom_vip_jetpack_forced.indexOf(item.module) === -1 ) { #>
<input type="checkbox" name="modules[]" value="{{{ item.module }}}" />
<# } #>
</th>
<td class='name column-name'>
<span class='info'><a href="#">{{{ item.name }}}</a></span>
<div class="row-actions">
<# if ( item.configurable ) { #>
<span class='configure'>{{{ item.configurable }}}</span>
<# } #>
<# if ( wpcom_vip_jetpack_forced.indexOf(item.module) !== -1 ) { #>
<span class='wpcom-vip-no-delete' id="wpcom-vip-no-delete-{{ item.module }}"><?php
_e('This module is required for WordPress.com VIP', 'wpcom-vip-jetpack');
?>
</span>
<# } else if ( item.activated && 'vaultpress' !== item.module ) { #>
<# if ( 'omnisearch' !== item.module ) { #>
<span class='delete'><a href="<?php
echo admin_url('admin.php');
?>
?page=jetpack&action=deactivate&module={{{ item.module }}}&_wpnonce={{{ item.deactivate_nonce }}}"><?php
_e('Deactivate', 'jetpack');
?>
</a></span>
<# } #>
<# } else if ( item.available ) { #>
<span class='activate'><a href="<?php
echo admin_url('admin.php');
?>
?page=jetpack&action=activate&module={{{ item.module }}}&_wpnonce={{{ item.activate_nonce }}}"><?php
_e('Activate', 'jetpack');
?>
</a></span>
<# } #>
</div>
</td>
</tr>
<# }); } else { #>
<tr class="no-modules-found">
<td colspan="2"><?php
esc_html_e('No Modules Found', 'jetpack');
?>
</td>
</tr>
<# } #>
</script>
<?php
}