From c9200a5f59c8e207871ace81ac9e90d271fc2573 Mon Sep 17 00:00:00 2001 From: Kevin Date: Thu, 21 Nov 2024 22:15:49 +0100 Subject: [PATCH] v 3.20.0 - Fix X url. - Add sharing on threads & bluesky. --- inc/theme/utilities/share.php | 12 ++++++++++-- package.json | 2 +- style.css | 2 +- 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/inc/theme/utilities/share.php b/inc/theme/utilities/share.php index 6553757..c41e2d5 100644 --- a/inc/theme/utilities/share.php +++ b/inc/theme/utilities/share.php @@ -63,6 +63,10 @@ function wputh_get_share_methods($item, $title = false, $permalink = false, $ima $_twitter_text = wputh_truncate($_twitter_text, 100 - strlen($_via)); $_methods = array( + 'bluesky' => array( + 'name' => 'BlueSky', + 'url' => 'https://bsky.app/intent/compose?text=' . urlencode($_title . ' ' . $_permalink) + ), 'email' => array( 'name' => 'Email', 'url' => str_replace('+', '%20', 'mailto:?subject=' . urlencode($_title) . '&body=' . urlencode($_title . ' ' . $_permalink)) @@ -83,9 +87,13 @@ function wputh_get_share_methods($item, $title = false, $permalink = false, $ima 'name' => 'Pinterest', 'url' => 'https://pinterest.com/pin/create/button/?url=' . urlencode($_permalink) . (!empty($_image) ? '&media=' . $_image : '') . '&description=' . urlencode($_title) ), + 'threads' => array( + 'name' => 'Threads', + 'url' => 'https://www.threads.net/intent/post?url=' . urlencode($_permalink) . '&text=' . urlencode($_title) + ), 'twitter' => array( - 'name' => 'Twitter', - 'url' => 'https://twitter.com/intent/tweet?text=' . urlencode($_twitter_text . ' ' . $_permalink . $_via), + 'name' => 'X', + 'url' => 'https://x.com/intent/post?text=' . urlencode($_twitter_text . ' ' . $_permalink . $_via), 'datas' => array( 'via' => $_via_user ) diff --git a/package.json b/package.json index 7ba9a76..00cfecb 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "wputheme", - "version": "3.18.0", + "version": "3.20.0", "description": "WPUTheme", "devDependencies": { "gulp": "^4.0.2", diff --git a/style.css b/style.css index 4fcf6ae..673ea14 100644 --- a/style.css +++ b/style.css @@ -3,7 +3,7 @@ Theme Name: WP Utilities Base Theme Theme URI: https://github.com/WordPressUtilities/WPUTheme Update URI: https://github.com/WordPressUtilities/WPUTheme Description: A Framework WordPress Theme -Version: 3.19.0 +Version: 3.20.0 Author: Darklg Author URI: https://darklg.me/ License: GPLv2 or later