diff --git a/assets/js/odw-admin-fields.js b/assets/js/odw-admin-fields.js index 6f89664..bb68bcc 100644 --- a/assets/js/odw-admin-fields.js +++ b/assets/js/odw-admin-fields.js @@ -219,45 +219,6 @@ observer.observe( document.body, { childList: true, subtree: true } ); } - // ------------------------------------------------------------------------- - // Auto-show distribution fields when Tab 3 is activated - // ------------------------------------------------------------------------- - function autoShowDistributionFields() { - // Only run once per page load - var ran = false; - - function tryClickAddEntry() { - if ( ran ) { - return; - } - - // The placeholder is only visible when there are no entries yet - var placeholder = document.querySelector( '.cf-complex__placeholder' ); - if ( ! placeholder ) { - return; - } - - // Find the "Add Entry" inserter button next to or after the placeholder - var inserterButton = document.querySelector( '.cf-complex__inserter-button' ); - if ( ! inserterButton ) { - return; - } - - ran = true; - inserterButton.click(); - } - - // Watch for Carbon Fields rendering the placeholder (lazy tab render) - var observer = new MutationObserver( function () { - tryClickAddEntry(); - } ); - - observer.observe( document.body, { childList: true, subtree: true } ); - - // Also try immediately in case tab is already active - tryClickAddEntry(); - } - // ------------------------------------------------------------------------- // Boot on DOMContentLoaded // ------------------------------------------------------------------------- @@ -266,9 +227,6 @@ initCessdaAutosuggest(); initFileSizeWidgets(); observeNewGroups(); - - // Auto-show distribution fields if no entries exist - setTimeout( autoShowDistributionFields, 500 ); } ); } )(); diff --git a/open-data-wizard.php b/open-data-wizard.php index b52dad7..44a6b89 100644 --- a/open-data-wizard.php +++ b/open-data-wizard.php @@ -3,7 +3,7 @@ * Plugin Name: Open Data Wizard * Plugin URI: https://github.com/daimpad/OpenDataWizard * Description: DCAT-AP 3.0 konforme Open Data Metadatenverwaltung für WordPress. Bereitstellung als maschinenlesbarer JSON-LD-Endpoint für offene Daten. - * Version: 2.1.2 + * Version: 2.1.3 * Requires at least: 6.4 * Requires PHP: 8.1 * Author: nozilla @@ -25,7 +25,7 @@ exit; } -define( 'ODW_VERSION', '2.1.2' ); +define( 'ODW_VERSION', '2.1.3' ); define( 'ODW_PLUGIN_DIR', plugin_dir_path( __FILE__ ) ); define( 'ODW_PLUGIN_URL', plugin_dir_url( __FILE__ ) ); define( 'ODW_PLUGIN_FILE', __FILE__ );