name, $project->name ) ); gp_breadcrumb( array( gp_project_links_from_root( $project ), gp_link_get( $url, $translation_set->name ), ) ); wp_enqueue_script( 'jquery-ui' ); wp_enqueue_script( 'gp-editor' ); wp_enqueue_script( 'gp-translations-page' ); wp_localize_script( 'translations-page', '$gp_translations_options', array( 'sort' => __('Sort'), 'filter' => __('Filter') ) ); // localizer adds var in front of the variable name, so we can't use $gp.editor.options $editor_options = compact('can_approve', 'can_write', 'url', 'discard_warning_url', 'set_priority_url', 'set_status_url'); wp_localize_script( 'editor', '$gp_editor_options', $editor_options ); $parity = gp_parity_factory(); add_action( 'gp_head', function() use ( $locale ) { return gp_preferred_sans_serif_style_tag( $locale ); } ); gp_tmpl_header(); $i = 0; ?>

name )); ?>: name ); ?> slug, $translation_set->slug ) . '/glossary', __('glossary'), array('class'=>'glossary-link') ); ?> $translation_set->id ) ), __('Create glossary'), array('class'=>'glossary-link') ); ?>

• • 'untranslated', 'sort[by]' => 'priority', 'sort[how]' => 'desc'), $url ), __('Untranslated') ); $untranslated .= ' ('.gp_link_get( add_query_arg( array('filters[status]' => 'untranslated', 'sort[by]' => 'random'), $url ), __('random') ).')'; $filter_links[] = $untranslated; if ( $can_approve ) { $filter_links[] = gp_link_get( add_query_arg( array('filters[translated]' => 'yes', 'filters[status]' => 'waiting'), $url ), __('Waiting') ); $filter_links[] = gp_link_get( add_query_arg( array('filters[translated]' => 'yes', 'filters[status]' => 'fuzzy'), $url ), __('Fuzzy') ); $filter_links[] = gp_link_get( add_query_arg( array('filters[warnings]' => 'yes', 'filters[status]' => 'current_or_waiting', 'sort[by]' => 'translation_date_added'), $url ), __('Warnings') ); } // TODO: with warnings // TODO: saved searches echo implode( ' • ', $filter_links ); ?>
—
get_static( 'statuses' ) as $status ): if ( 'rejected' == $status ) continue; ?>

slug, $translation_set->slug, 'import-translations' ) ), __('Import translations') ); } $export_url = gp_url_project( $project, array( $locale->slug, $translation_set->slug, 'export-translations' ) ); $export_link = gp_link_get( $export_url , __('Export'), array('id' => 'export', 'filters' => add_query_arg( array( 'filters' => $filters ), $export_url ) ) ); $format_options = array(); foreach ( GP::$formats as $slug => $format ) { $format_options[$slug] = $format->name; } $what_dropdown = gp_select( 'what-to-export', array('all' => _x('all current', 'export choice'), 'filtered' => _x('only matching the filter', 'export choice')), 'all' ); $format_dropdown = gp_select( 'export-format', $format_options, 'po' ); /* translators: 1: export 2: what to export dropdown (all/filtered) 3: export format */ $footer_links[] = sprintf( __('%1$s %2$s as %3$s'), $export_link, $what_dropdown, $format_dropdown ); echo implode( ' • ', apply_filters( 'translations_footer_links', $footer_links, $project, $locale, $translation_set ) ); ?>