Stable Bugfix Release 2.1.2 to roll out immediately in compensation of previous overdue, as a goodwill gesture

git-svn-id: https://plugins.svn.wordpress.org/footnotes/tags/2.1.2@2422035 b8457f37-d9ea-0310-8a92-e5e31aec5664
This commit is contained in:
pewgeuges 2020-11-20 05:40:03 +00:00
commit 1eb1ddb6aa
13 changed files with 525 additions and 492 deletions

View file

@ -90,7 +90,6 @@ class MCI_Footnotes_Layout_Init {
*
* @author Stefan Herndler
* @since 1.5.0
* Claimed it was added for 2.0.2 while already present since 1.5.0 2020-11-19T1201+0100
* @see http://codex.wordpress.org/Function_Reference/add_menu_page
*/
public function registerMainMenu() {

View file

@ -6,9 +6,9 @@
* @author Stefan Herndler
* @since 1.5.0 12.09.14 10:56
*
* Updated for 2.1.2 added version # of settings.css for cache busting
* ############ update line 200 after changes to settings.css
* Last modified 2020-11-19T1456+0100
* 2.1.2 added version # of settings.css for cache busting 2020-11-19T1456+0100
*
* ############ Please update line 210 after changes to settings.css ###############
*/
@ -202,7 +202,7 @@ abstract class MCI_Footnotes_LayoutEngine {
// register stylesheet
// added version after changes started to settings.css from 2.1.2 on:
// added version # after changes started to settings.css from 2.1.2 on:
wp_register_style(
'mci-footnotes-admin-styles',
plugins_url('../../css/settings.css', __FILE__),

View file

@ -492,7 +492,12 @@ class MCI_Footnotes_Layout_Settings extends MCI_Footnotes_LayoutEngine {
$l_obj_Template->replace(
array(
"description" => __("The priority level determines whether Footnotes is executed timely before other plugins, and how the reference container is positioned relative to other features. Default 9223372036854775807 or -1 is lowest priority, 0 is highest. For the reference container to sit above related posts, the priority level of the_content hook may need to be at most 1200. For Footnotes to work when a glossary plugin is active, a higher priority of 1000 may be needed. Another priority level for the_content with proven efficiency is 10.", MCI_Footnotes_Config::C_STR_PLUGIN_NAME),
"description-1" => __("The priority level determines whether Footnotes is executed timely before other plugins, and how the reference container is positioned relative to other features.", MCI_Footnotes_Config::C_STR_PLUGIN_NAME),
"description-2" => __("Default 9223372036854775807 is lowest priority, 0 is highest.", MCI_Footnotes_Config::C_STR_PLUGIN_NAME),
"description-3" => __("To restore default priority, set to -1, interpreted as 9223372036854775807, the constant PHP_INT_MAX.", MCI_Footnotes_Config::C_STR_PLUGIN_NAME),
"description-4" => __("For the reference container to sit above related posts, the priority level of the_content hook may need to be at most 1200.", MCI_Footnotes_Config::C_STR_PLUGIN_NAME),
"description-5" => __("For Footnotes to work when a glossary plugin is active, a higher priority of 1000 may be needed.", MCI_Footnotes_Config::C_STR_PLUGIN_NAME),
"description-6" => __("For the_content, another good pick with proven efficiency is priority level 10.", MCI_Footnotes_Config::C_STR_PLUGIN_NAME),
"head-hook" => __("WordPress hook function name", MCI_Footnotes_Config::C_STR_PLUGIN_NAME),
"head-checkbox" => __("Activate", MCI_Footnotes_Config::C_STR_PLUGIN_NAME),

View file

@ -425,17 +425,14 @@ class MCI_Footnotes_Settings {
"footnotes_storage" => array(
self::C_STR_REFERENCE_CONTAINER_NAME => 'References',
self::C_BOOL_REFERENCE_CONTAINER_COLLAPSE => '',
self::C_BOOL_REFERENCE_CONTAINER_COLLAPSE => 'no',
self::C_STR_REFERENCE_CONTAINER_POSITION => 'post_end',
// Identical footnotes should not be combined by default
// as long as the feature raises criticism for malfunctioning:
// <https://wordpress.org/support/topic/too-many-errors-18/>
self::C_BOOL_COMBINE_IDENTICAL_FOOTNOTES => '',
self::C_BOOL_COMBINE_IDENTICAL_FOOTNOTES => 'yes',
self::C_BOOL_REFERENCE_CONTAINER_BACKLINK_SYMBOL_ENABLE => 'yes',
self::C_BOOL_REFERENCE_CONTAINER_START_PAGE_ENABLE => 'yes',
self::C_BOOL_REFERENCE_CONTAINER_3COLUMN_LAYOUT_ENABLE => '',
self::C_BOOL_REFERENCE_CONTAINER_BACKLINK_SYMBOL_SWITCH => '',
self::C_BOOL_REFERENCE_CONTAINER_3COLUMN_LAYOUT_ENABLE => 'no',
self::C_BOOL_REFERENCE_CONTAINER_BACKLINK_SYMBOL_SWITCH => 'no',
self::C_STR_FOOTNOTES_SHORT_CODE_START => '((',
self::C_STR_FOOTNOTES_SHORT_CODE_END => '))',
@ -444,7 +441,11 @@ class MCI_Footnotes_Settings {
self::C_STR_FOOTNOTES_COUNTER_STYLE => 'arabic_plain',
self::C_STR_FOOTNOTES_LOVE => 'no',
self::C_BOOL_FOOTNOTES_IN_EXCERPT => 'yes',
self::C_BOOL_FOOTNOTES_EXPERT_MODE => 'no'
// since removal of the_post hook, expert mode is no danger zone
// not for experts only; raising awareness about relative positioning
// changed default to 'yes':
self::C_BOOL_FOOTNOTES_EXPERT_MODE => 'yes'
),
@ -455,14 +456,18 @@ class MCI_Footnotes_Settings {
self::C_BOOL_FOOTNOTES_REFERRER_SUPERSCRIPT_TAGS => 'yes',
// The default footnote referrer surroundings should be square brackets:
// * as in English typesetting;
// * with respect to baseline footnote referrers new option;
// * as in English or US American typesetting;
// * for better UX thanks to a more button-like appearance;
// * for stylistic consistency with the expand-collapse button
// * for stylistic consistency with the expand-collapse button;
self::C_STR_FOOTNOTES_STYLING_BEFORE => '[',
self::C_STR_FOOTNOTES_STYLING_AFTER => ']',
self::C_BOOL_FOOTNOTES_MOUSE_OVER_BOX_ENABLED => 'yes',
self::C_BOOL_FOOTNOTES_MOUSE_OVER_BOX_ALTERNATIVE => '',
// alternative, low-script tooltips using CSS for transitions
// in response to user demand for website with jQuery UI outage
self::C_BOOL_FOOTNOTES_MOUSE_OVER_BOX_ALTERNATIVE => 'no',
// The mouse over content truncation should be enabled by default
// to raise awareness of the functionality and to prevent the screen

View file

@ -16,8 +16,8 @@
* 2.1.1: combining identical footnotes: fixed dead links 2020-11-14T2233+0100
* 2.1.1: options fixing ref container layout and referrer vertical alignment 2020-11-16T2024+0100
* 2.1.1: option fixing ref container relative position 2020-11-17T0254+0100
*
* Last modified 2020-11-18T0138+0100
* 2.1.2: options for the other hooks 2020-11-19T1849+0100
* 2.1.2: support for Elementor accordion toggle section names 2020-11-20T0617+0100
*/
// If called directly, abort:
@ -75,7 +75,8 @@ class MCI_Footnotes_Task {
* Documentation: <https://codex.wordpress.org/Plugin_API/#Hook_in_your_Filter>
*
* Default remains PHP_INT_MAX.
* PHP_INT_MAX can be reset by leaving the number box empty.
* PHP_INT_MAX cannot be reset by leaving the number box empty. because browsers
* (WebKit) dont allow it, so we must resort to -1.
*/
public function registerHooks() {
@ -86,12 +87,12 @@ class MCI_Footnotes_Task {
$p_int_WidgetTitlePriority = intval(MCI_Footnotes_Settings::instance()->get(MCI_Footnotes_Settings::C_INT_EXPERT_LOOKUP_WIDGET_TITLE_PRIORITY_LEVEL));
$p_int_WidgetTextPriority = intval(MCI_Footnotes_Settings::instance()->get(MCI_Footnotes_Settings::C_INT_EXPERT_LOOKUP_WIDGET_TEXT_PRIORITY_LEVEL));
// PHP_INT_MAX can be set leaving the input field empty:
$p_int_TheTitlePriority = !empty($p_int_TheTitlePriority ) ? $p_int_TheTitlePriority : PHP_INT_MAX;
$p_int_TheContentPriority = !empty($p_int_TheContentPriority ) ? $p_int_TheContentPriority : PHP_INT_MAX;
$p_int_TheExcerptPriority = !empty($p_int_TheExcerptPriority ) ? $p_int_TheExcerptPriority : PHP_INT_MAX;
$p_int_WidgetTitlePriority = !empty($p_int_WidgetTitlePriority) ? $p_int_WidgetTitlePriority : PHP_INT_MAX;
$p_int_WidgetTextPriority = !empty($p_int_WidgetTextPriority ) ? $p_int_WidgetTextPriority : PHP_INT_MAX;
// PHP_INT_MAX can be set by -1:
$p_int_TheTitlePriority = ($p_int_TheTitlePriority == -1) ? PHP_INT_MAX : $p_int_TheTitlePriority ;
$p_int_TheContentPriority = ($p_int_TheContentPriority == -1) ? PHP_INT_MAX : $p_int_TheContentPriority ;
$p_int_TheExcerptPriority = ($p_int_TheExcerptPriority == -1) ? PHP_INT_MAX : $p_int_TheExcerptPriority ;
$p_int_WidgetTitlePriority = ($p_int_WidgetTitlePriority == -1) ? PHP_INT_MAX : $p_int_WidgetTitlePriority;
$p_int_WidgetTextPriority = ($p_int_WidgetTextPriority == -1) ? PHP_INT_MAX : $p_int_WidgetTextPriority ;
// append custom css to the header
@ -375,7 +376,15 @@ class MCI_Footnotes_Task {
// post ID to make everything unique wrt infinite scroll and archive view
global $l_int_PostId;
// add support for Elementor section names:
// Element_Section::get_name()
// see <https://code.elementor.com/?s=section>
if (function_exists('Element_Section::get_name')) {
$l_int_PostId = Element_Section::get_name();
} else {
// work in WordPress mode:
$l_int_PostId = get_the_id();
}
// contains the index for the next footnote on this page
$l_int_FootnoteIndex = count(self::$a_arr_Footnotes) + 1;
@ -538,7 +547,15 @@ class MCI_Footnotes_Task {
// post ID to make everything unique wrt infinite scroll and archive view:
global $l_int_PostId;
// add support for Elementor section names: 2020-11-20T0615+0100
// Element_Section::get_name()
// see <https://code.elementor.com/?s=section>
if (function_exists('Element_Section::get_name')) {
$l_int_PostId = Element_Section::get_name();
} else {
// work in WordPress mode:
$l_int_PostId = get_the_id();
}
// no footnotes has been replaced on this page
if (empty(self::$a_arr_Footnotes)) {

View file

@ -6,7 +6,7 @@
* Since: 1.0
* Version: 2.1.2
*
* Last modified: 2020-11-19T1444+0100
* Last modified: 2020-11-20T0620+0100
*/
@ -218,7 +218,6 @@ when hovered in some themes, not in others:
.footnote_plugin_index.pointer:hover,
*/
.footnote_backlink:hover,
.footnote_plugin_index_combi:hover,
.footnote_plugin_link:hover,
.footnote_plugin_text a:hover {
text-decoration: unset;

View file

@ -6,7 +6,7 @@
* Since: 1.0
* Version: 2.1.2
*
* Last modified: 2020-11-19T1445+0100
* Last modified: 2020-11-20T0620+0100
*/
@ -125,8 +125,9 @@ IE doesnt support nth child, but these are not critical
}
.footnotes-description {
padding: 0 10px;
padding: 0 10%;
}
.footnotes-description p {
font-size: 1.4em;
font-style: italic;
}

View file

@ -4,7 +4,7 @@ Tags: footnote, footnotes, bibliography, formatting, notes, Post, posts, referen
Requires at least: 3.9
Tested up to: 5.5
Requires PHP: 5.6
Stable Tag: 2.1.1
Stable Tag: 2.1.2
License: GPLv3 or later
License URI: http://www.gnu.org/licenses/gpl-3.0.html
@ -81,9 +81,11 @@ Visit this swift write-up from a **footnotes** user by the name of **Southwest**
== Changelog ==
= 2.1.2 =
- Bugfix: Dashboard: priority level settings for all other hooks, preventing them from being zeroed at save
- Bugfix: Layout: Reference container: Backlinks: no underline on hover cell when combining identicals is on
- Bugfix: Elementor: add experimental support for section name function
- Bugfix: Dashboard: priority level settings for all other hooks
- Update: Dashboard: WordPress documentation URLs of the hooks
- Update: Dashboard: feature description for the hooks priority level settings
- Update: Dashboard: feature description for the hooks priority level settings (not yet localized)
= 2.1.1 =
- Bugfix: Combining identical footnotes: fix dead links, ensure referrer-backlink bijectivity

View file

@ -1,5 +1,10 @@
<div class="expert-lookup footnotes-description">
<p>[[description]]</p>
<p>[[description-1]]</p>
<p>[[description-2]]</p>
<p>[[description-3]]</p>
<p>[[description-4]]</p>
<p>[[description-5]]</p>
<p>[[description-6]]</p>
</div>
<table class="expert-lookup widefat fixed">
<thead>

View file

@ -55,7 +55,7 @@
jQuery('html, body').animate({
scrollTop: l_obj_Target.offset().top - window.innerHeight * 0.20
},
380);/*speed*/
380);/*duration*/
}
}
</script>