Skip to content

Commit

Permalink
0.5.0
Browse files Browse the repository at this point in the history
  • Loading branch information
changwoo committed Aug 29, 2024
1 parent a8c6159 commit 24d822c
Show file tree
Hide file tree
Showing 10 changed files with 72 additions and 51 deletions.
10 changes: 10 additions & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
0.5.0
-----
2024-08-30

- Rename 'Twitter' to 'X'.
- Share to 'Naver Band' added.
- Fix composer.json make-pot script.
- Fix frontend.js a tag click behavior.


0.4.3
-----
2022-01-20
Expand Down
Binary file added assets/img/naver-band.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/img/x.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 4 additions & 1 deletion assets/js/front.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,9 @@
linkedIn(s) {
this.openPopup('https://www.linkedin.com/shareArticle?url=' + encodeURIComponent(s.permalink) + '&title=' + encodeURIComponent(s.title));
},
naverBand(s) {
this.openPopup('https://band.us/plugin/share?body=' + encodeURIComponent(s.title + '\n' + s.permalink) + '&route=' + encodeURIComponent(location.host));
},
naverBlog(s) {
this.openPopup('https://blog.naver.com/LinkShare.nhn?url=' + encodeURIComponent(s.permalink) + '&title=' + encodeURIComponent(s.title));
},
Expand Down Expand Up @@ -133,7 +136,7 @@
elem.addEventListener('click', function (e) {
const target = e.currentTarget,
type = target.dataset.nss;
if (target.tagName === 'A' && target.classList.contains('share')) {
if (target.tagName === 'A') {
e.preventDefault();
}
sharer.share(type);
Expand Down
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
],
"scripts": {
"daa": "@composer dump-autoload --classmap-authoritative --no-dev",
"make-pot": "@php -d xdebug.max_nesting_level=512 $(which wp) i18n make-pot . ./languages/nss.pot --domain=nss --include=assets/js/dist --exclude=src",
"make-pot": "@php -d xdebug.max_nesting_level=512 $(which wp) i18n make-pot . ./languages/nss.pot --domain=nss --include=includes,assets/js/dist --exclude=src",
"make-json": "@php $(which wp) i18n make-json ./languages --no-purge",
"version": "@php bin/sync-version.php index.php",
"test": "vendor/bin/phpunit",
Expand Down Expand Up @@ -55,7 +55,7 @@
"php": "^7.4",
"ext-json": "*"
},
"version": "0.4.3",
"version": "0.5.0",
"require-dev": {
"phpunit/phpunit": "^7"
},
Expand Down
6 changes: 4 additions & 2 deletions includes/functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,12 @@ function nss_get_available_services(): array {
'kakaoTalk' => __( 'KakaoTalk', 'nss' ),
'line' => __( 'Line', 'nss' ),
'linkedIn' => __( 'LinkedIn', 'nss' ),
'naverBand' => __( 'Naver Band', 'nss' ),
'naverBlog' => __( 'Naver Blog', 'nss' ),
'pinterest' => __( 'Pinterest', 'nss' ),
'pocket' => __( 'Pocket', 'nss' ),
'telegram' => __( 'Telegram', 'nss' ),
'twitter' => __( 'Twitter', 'nss' ),
'twitter' => __( 'X', 'nss' ),
] );
}
}
Expand All @@ -46,11 +47,12 @@ function nss_get_icon_sets(): array {
'kakaoTalk' => $img_url . 'kakao-talk.png',
'line' => $img_url . 'line.png',
'linkedIn' => $img_url . 'linked-in.png',
'naverBand' => $img_url . 'naver-band.png',
'naverBlog' => $img_url . 'naver-blog.png',
'pinterest' => $img_url . 'pinterest.png',
'pocket' => $img_url . 'pocket.png',
'telegram' => $img_url . 'telegram.png',
'twitter' => $img_url . 'twitter.png',
'twitter' => $img_url . 'x.png',
],
] );
}
Expand Down
4 changes: 2 additions & 2 deletions index.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* Plugin Name: Naran Social Share
* Plugin URI: https://github.com/chwnam/naran-social-share
* Description: Share your posts to social media, and so on.
* Version: 0.4.3
* Version: 0.5.0
* Requires at least: 4.4.0
* Requires PHP: 7.4
* Author: changwoo
Expand All @@ -23,7 +23,7 @@
require_once __DIR__ . '/vendor/autoload.php';

const NSS_MAIN_FILE = __FILE__;
const NSS_VERSION = '0.4.3';
const NSS_VERSION = '0.5.0';
const NSS_PRIORITY = 885;

nss();
Binary file modified languages/nss-ko_KR.mo
Binary file not shown.
57 changes: 32 additions & 25 deletions languages/nss-ko_KR.po
Original file line number Diff line number Diff line change
Expand Up @@ -5,53 +5,43 @@ msgstr ""
"Project-Id-Version: Naran Social Share 0.1.0\n"
"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/naran-social-"
"share\n"
"POT-Creation-Date: 2022-01-20T14:08:56+09:00\n"
"PO-Revision-Date: 2022-01-20 14:09+0900\n"
"POT-Creation-Date: 2024-08-29T15:28:19+00:00\n"
"PO-Revision-Date: 2024-08-30 00:29+0900\n"
"Last-Translator: \n"
"Language-Team: \n"
"Language: ko_KR\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Generator: Poedit 2.3\n"
"X-Domain: nss\n"
"Plural-Forms: nplurals=1; plural=0;\n"
"X-Generator: Poedit 3.4.2\n"
"X-Domain: nss\n"

#. Plugin Name of the plugin
#: includes/modules/class-nss-admin-settings.php:23
#: index.php includes/modules/class-nss-admin-settings.php:23
msgid "Naran Social Share"
msgstr "나란 소셜 공유"

#. Plugin URI of the plugin
#: index.php
msgid "https://github.com/chwnam/naran-social-share"
msgstr "https://github.com/chwnam/naran-social-share"

#. Description of the plugin
#: index.php
msgid "Share your posts to social media, and so on."
msgstr "포스트를 소셜 미디어 등에 공유하세요."

#. Author of the plugin
#: index.php
msgid "changwoo"
msgstr "changwoo"

#. Author URI of the plugin
#: index.php
msgid "https://blog.changwoo.pe.kr/"
msgstr "https://blog.changwoo.pe.kr/"

#. translators: formatted module name.
#: core/abstracts/abstract-nss-main-base.php:140
msgid "%s is invalid for callback."
msgstr "%s 는 잘못된 콜백."

#. translators: formatted callback
#: core/abstracts/registers/abstract-nss-register-base-rewrite-rule.php:64
msgid ""
"Rewrite rule binding `%s` is invalid. Please check your rewrite rule "
"register items."
msgstr ""
"다시쓰기 규칙 바인딩 '%s'는 잘못되었습니다. 다시쓰기 레지스터 항목을 다시 점"
"검하세요."

#: includes/class-nss-main.php:46
#: includes/modules/class-nss-admin-settings.php:22
msgid "Naran social share settings"
Expand Down Expand Up @@ -86,24 +76,28 @@ msgid "LinkedIn"
msgstr "링크드인"

#: includes/functions.php:22
msgid "Naver Band"
msgstr "네이버 밴드"

#: includes/functions.php:23
msgid "Naver Blog"
msgstr "네이버 블로그"

#: includes/functions.php:23
#: includes/functions.php:24
msgid "Pinterest"
msgstr "핀터레스트"

#: includes/functions.php:24
#: includes/functions.php:25
msgid "Pocket"
msgstr "포켓"

#: includes/functions.php:25
#: includes/functions.php:26
msgid "Telegram"
msgstr "텔레그램"

#: includes/functions.php:26
msgid "Twitter"
msgstr "트위터"
#: includes/functions.php:27
msgid "X"
msgstr "X"

#: includes/modules/class-nss-admin-settings.php:37
#: includes/templates/admin/shortcode-guide.php:26
Expand Down Expand Up @@ -322,3 +316,16 @@ msgstr "이 페이지의 URL을 %s로 공유."
#: includes/templates/buttons.php:60
msgid "%s icon"
msgstr "%s 아이콘"

#~ msgid "%s is invalid for callback."
#~ msgstr "%s 는 잘못된 콜백."

#~ msgid ""
#~ "Rewrite rule binding `%s` is invalid. Please check your rewrite rule "
#~ "register items."
#~ msgstr ""
#~ "다시쓰기 규칙 바인딩 '%s'는 잘못되었습니다. 다시쓰기 레지스터 항목을 다시 "
#~ "점검하세요."

#~ msgid "Twitter"
#~ msgstr "트위터"
37 changes: 18 additions & 19 deletions languages/nss.pot
Original file line number Diff line number Diff line change
@@ -1,50 +1,45 @@
# Copyright (C) 2022 changwoo
# Copyright (C) 2024 changwoo
# This file is distributed under the GPL v2 or later.
msgid ""
msgstr ""
"Project-Id-Version: Naran Social Share 0.4.2\n"
"Project-Id-Version: Naran Social Share 0.4.3\n"
"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/naran-social-share\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <[email protected]>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"POT-Creation-Date: 2022-01-20T14:08:56+09:00\n"
"POT-Creation-Date: 2024-08-29T15:28:19+00:00\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"X-Generator: WP-CLI 2.5.0\n"
"X-Generator: WP-CLI 2.11.0\n"
"X-Domain: nss\n"

#. Plugin Name of the plugin
#: index.php
#: includes/modules/class-nss-admin-settings.php:23
msgid "Naran Social Share"
msgstr ""

#. Plugin URI of the plugin
#: index.php
msgid "https://github.com/chwnam/naran-social-share"
msgstr ""

#. Description of the plugin
#: index.php
msgid "Share your posts to social media, and so on."
msgstr ""

#. Author of the plugin
#: index.php
msgid "changwoo"
msgstr ""

#. Author URI of the plugin
#: index.php
msgid "https://blog.changwoo.pe.kr/"
msgstr ""

#. translators: formatted module name.
#: core/abstracts/abstract-nss-main-base.php:140
msgid "%s is invalid for callback."
msgstr ""

#. translators: formatted callback
#: core/abstracts/registers/abstract-nss-register-base-rewrite-rule.php:64
msgid "Rewrite rule binding `%s` is invalid. Please check your rewrite rule register items."
msgstr ""

#: includes/class-nss-main.php:46
#: includes/modules/class-nss-admin-settings.php:22
msgid "Naran social share settings"
Expand Down Expand Up @@ -79,23 +74,27 @@ msgid "LinkedIn"
msgstr ""

#: includes/functions.php:22
msgid "Naver Blog"
msgid "Naver Band"
msgstr ""

#: includes/functions.php:23
msgid "Pinterest"
msgid "Naver Blog"
msgstr ""

#: includes/functions.php:24
msgid "Pocket"
msgid "Pinterest"
msgstr ""

#: includes/functions.php:25
msgid "Telegram"
msgid "Pocket"
msgstr ""

#: includes/functions.php:26
msgid "Twitter"
msgid "Telegram"
msgstr ""

#: includes/functions.php:27
msgid "X"
msgstr ""

#: includes/modules/class-nss-admin-settings.php:37
Expand Down

0 comments on commit 24d822c

Please sign in to comment.