Skip to content

Commit 57d3d0e

Browse files
committedJan 9, 2022
version 1.0.3 bump
1 parent f9eb6ad commit 57d3d0e

File tree

4 files changed

+37
-5
lines changed

4 files changed

+37
-5
lines changed
 

‎CHANGES.md

+14
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,17 @@
1+
#### 1.0.3 / 2022-01-09
2+
* restored option to add Language Switcher to post/pages list
3+
* refactoring `admin-edit` script to support support for `Quick Edit` and post/pages list
4+
* refactoring `whenReady` into `whenNodeInserted`, added capabilities `whenNodeRemoved`
5+
* refactoring some methods to use `get_qt_config` method instead of `global $q_config`
6+
* added `session` option support
7+
* added support for shortcodes in menu
8+
* added `appearance` and `large` options - to change appearance of language buttons
9+
* got rid of `qTranslateConfig` in the __Block Editor__
10+
* implemented `inserted` hooks to deal with element removed from the page when the attribute Panel is closed
11+
* implemented `not synced` language switching
12+
* refactoring CSS to use common variables
13+
* small improvements
14+
115
#### 1.0.2 / 2022-01-05
216
* refactoring with `Zukit` components
317
* created custom `store` for RAW values

‎README.md

+18-2
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@ After the WordPress changed the `TinyMCE` to the Block Editor (*Gutenberg*), edi
2525
* Ability to add custom blocks to the list supported by this plugin
2626
* Control of the appearance of buttons to switch language
2727
* Ability to switch language in the list of posts/pages
28-
* Ability to switch language in the modal window of __Media Library__
28+
* Support for __Quick Edit__ in the list of posts/pages
29+
<!-- * Ability to switch language in the modal window of __Media Library__ -->
2930
* Supports adding a language switcher to any post or page using a `shortcode`
3031
* Ability to use `shortcode` in the WordPress __menu__
3132

@@ -38,6 +39,16 @@ You can also personalize the form by adding attributes to the shortcode:
3839
* __unsorted__ - if sorted (default) then the active language will be always on top: `unsorted=true`
3940
* __post_id__ - post ID for which you want to create a language switcher (default for the current post): `post_id=123`
4041

42+
If `shortcode` is used in the menu, use the following template to describe the shortcode:
43+
44+
`#location+tag?attribute1=value1&attribute2=value2&linkclass=red-color,bold#`
45+
46+
* __location__ - a position where the result of the shortcode will be inserted. Possible options - `after`|`before`|`url`, that is, before link, after link or instead of the link itself
47+
* __tag__ - the name of shortcode
48+
* __attribute1__, __attribute2__ - names of attributes of shortcode
49+
* __value1__, __value2__ - attribute values
50+
* __linkclass__ - a special attribute that sets the class name that will be added to the link (*note that if you want to add __several__ classes, you can specify them through the comma*)
51+
4152
#### Examples
4253

4354
* With language codes and "unsorted":
@@ -48,6 +59,11 @@ You can also personalize the form by adding attributes to the shortcode:
4859

4960
`[zu-lang class="my-switcher" post_id=1209]`
5061

62+
* In __menu__ with custom class, only language codes, before link and with a special link class:
63+
64+
`#before+zu-lang?class=my-switcher&as_code=true&linkclass=none#`
65+
66+
5167

5268
## Download
5369

@@ -61,7 +77,7 @@ You can also personalize the form by adding attributes to the shortcode:
6177

6278
## Public methods
6379

64-
In order to take advantage of the switching language implemented in this plugin, Plugins and themes can add their custom blocks using these functions:
80+
In order to take advantage of the switching language implemented in this plugin, plugins and themes can add their custom blocks using these functions:
6581

6682
+ __zutrans_is_multilang()__
6783
+ __zutrans_register_blocks(`$blocks`)__

‎package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "zutranslate",
3-
"version": "1.0.2",
3+
"version": "1.0.3",
44
"testedWP": "5.8.2",
55
"requiresPHP": ">=7.2.0",
66
"author": "Dmitry Rudakov",

‎zu-translate.php

+4-2
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
Plugin URI: https://github.com/picasso/zu-translate
55
GitHub Plugin URI: https://github.com/picasso/zu-translate
66
Description: Enhances "qTranslate-XT" with some features and Gutenberg support (WordPress Block Editor).
7-
Version: 1.0.2
7+
Version: 1.0.3
88
Author: Dmitry Rudakov
99
Author URI: https://github.com/picasso
1010
Text Domain: zu-translate
@@ -16,7 +16,8 @@
1616
// Prohibit direct script loading
1717
defined('ABSPATH') || die('No direct script access allowed!');
1818

19-
// add_action('plugins_loaded', function() { // DEBUG-ONLY
19+
// DEBUG-ONLY
20+
// add_action('plugins_loaded', function() {
2021

2122
// Always load Zukit even if we don't use it later ('wp_doing_ajax' or 'wp_doing_cron')
2223
// as other plugins or themes may want to use it
@@ -36,4 +37,5 @@
3637
zutranslate(__FILE__);
3738
}
3839

40+
// DEBUG-ONLY
3941
// });

0 commit comments

Comments
 (0)
Please sign in to comment.