From 648f7e6c0a44967301ed09475eb06da5abe181be Mon Sep 17 00:00:00 2001 From: Mike Bryant Date: Tue, 14 Nov 2023 11:05:31 +0000 Subject: [PATCH] Improve language switcher. Bump to 1.0.3 --- inc/template-tags.php | 15 ++------------- package-lock.json | 28 ++++++++++++++-------------- package.json | 2 +- style.css | 2 +- 4 files changed, 18 insertions(+), 29 deletions(-) diff --git a/inc/template-tags.php b/inc/template-tags.php index 3e6c949..6bc9760 100644 --- a/inc/template-tags.php +++ b/inc/template-tags.php @@ -152,7 +152,7 @@ function ehri_posted_on() { ) ); - if ( function_exists( "get_coauthors" ) && function_exists("coauthors_posts_links")) { + if ( function_exists( "get_coauthors" ) && function_exists( "coauthors_posts_links" ) ) { $coauthors = get_coauthors(); $byline = apply_filters( 'ehri_posted_by', sprintf( @@ -228,7 +228,6 @@ function ehri_has_gravitar( $user ) { /** * Experimental Polylang-based language switch widget. * - * TODO: improve greatly. */ if ( ! function_exists( "ehri_post_translations" ) ) { function ehri_post_translations( $post_id ) { @@ -245,19 +244,9 @@ function ehri_post_translations( $post_id ) { return; } - // FIXME: where to lookup with info??? - $langs = array( - "en" => "English", - "de" => "German", - "fr" => "French", - "cs" => "Czech", - "hu" => "Hungarian", - ); - $links = "" diff --git a/package-lock.json b/package-lock.json index 05dcbbb..cc0c676 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "ehri-wp-theme", - "version": "1.0.2", + "version": "1.0.3", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "ehri-wp-theme", - "version": "1.0.2", + "version": "1.0.3", "hasInstallScript": true, "license": "GPL-2.0", "dependencies": { @@ -3565,9 +3565,9 @@ } }, "node_modules/read-pkg/node_modules/semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz", + "integrity": "sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==", "dev": true, "bin": { "semver": "bin/semver" @@ -3744,9 +3744,9 @@ } }, "node_modules/semver": { - "version": "7.3.7", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.7.tgz", - "integrity": "sha512-QlYTucUYOews+WeEujDoEGziz4K6c47V/Bd+LjSSYcA94p+DmINdf7ncaUinThfvZyu13lN9OY1XDxt8C0Tw0g==", + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", + "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", "dev": true, "dependencies": { "lru-cache": "^6.0.0" @@ -7109,9 +7109,9 @@ } }, "semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz", + "integrity": "sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==", "dev": true }, "type-fest": { @@ -7275,9 +7275,9 @@ } }, "semver": { - "version": "7.3.7", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.7.tgz", - "integrity": "sha512-QlYTucUYOews+WeEujDoEGziz4K6c47V/Bd+LjSSYcA94p+DmINdf7ncaUinThfvZyu13lN9OY1XDxt8C0Tw0g==", + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", + "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", "dev": true, "requires": { "lru-cache": "^6.0.0" diff --git a/package.json b/package.json index 84e786c..0fa1186 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "ehri-wp-theme", - "version": "1.0.2", + "version": "1.0.3", "description": "EHRI Wordpress Theme", "main": "index.js", "scripts": { diff --git a/style.css b/style.css index 591918b..de1e5b8 100644 --- a/style.css +++ b/style.css @@ -2,7 +2,7 @@ Theme Name: EHRI GitHub Theme URI: https://github.com/EHRI/ehri-wp-theme Description: A theme for the EHRI Document Blog based on UnderStrap (http://github.com/understrap/understrap). -Version: 1.0.2 +Version: 1.0.3 License: UnderStrap WordPress Theme, Copyright 2013-2017 Holger Koenemann UnderStrap is distributed under the terms of the GNU GPL version 2 License URI: http://www.gnu.org/licenses/gpl-2.0.html