| Conditions | 2 |
| Paths | 2 |
| Total Lines | 21 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 30 | public function render_widget() { |
||
| 31 | $term_count = $this->term_count->get_term_count(); |
||
| 32 | if ( $term_count <= 0 ) { |
||
| 33 | return; |
||
| 34 | } |
||
| 35 | |||
| 36 | $match_terms_url = menu_page_url('wl-vocabulary-match-terms', false); |
||
| 37 | $term_count_link = "<a href='$match_terms_url'>" . $term_count . " term(s)</a>"; |
||
| 38 | $match_terms = __('Match terms', 'wordlift'); |
||
| 39 | $additional_text = __(' waiting to be matched with entities.', 'wordlift'); |
||
| 40 | echo <<<EOF |
||
| 41 | <div id="wl-match-terms" class="wl-dashboard__block wl-dashboard__block--match-terms"> |
||
| 42 | <header> |
||
| 43 | <h3>$match_terms</h3> |
||
| 44 | </header> |
||
| 45 | <p> |
||
| 46 | <strong>$term_count_link</strong> $additional_text |
||
| 47 | </p> |
||
| 48 | </div> |
||
| 49 | EOF; |
||
| 50 | } |
||
| 51 | |||
| 52 | } |