diff --git a/Gruntfile.js b/Gruntfile.js index 53d332fd2..f747aff9f 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -265,7 +265,7 @@ module.exports = function( grunt) { grunt.loadNpmTasks( 'grunt-contrib-clean' ); grunt.loadNpmTasks( 'grunt-contrib-copy' ); grunt.loadNpmTasks( 'grunt-contrib-compress' ); - grunt.loadNpmTasks( 'grunt-notify' ); + // grunt.loadNpmTasks( 'grunt-notify' ); grunt.loadNpmTasks( 'grunt-wp-readme-to-markdown' ); grunt.loadNpmTasks( 'grunt-shell' ); grunt.loadNpmTasks( 'grunt-postcss' ); diff --git a/admin/form-builder/assets/js/components/builder-stage-v4-1/index.js b/admin/form-builder/assets/js/components/builder-stage-v4-1/index.js index e81a9fc38..eda337500 100644 --- a/admin/form-builder/assets/js/components/builder-stage-v4-1/index.js +++ b/admin/form-builder/assets/js/components/builder-stage-v4-1/index.js @@ -175,6 +175,18 @@ Vue.component('builder-stage-v4-1', { get_field_name: function (template) { return this.field_settings[template].title; - } + }, + + openRepeatFieldPicker(fieldId) { + // Find the repeat field component by ref and call openFieldPicker() + const refName = 'repeatFieldComponent_' + fieldId; + const comp = this.$refs[refName]; + // Vue 2: $refs[refName] is an array if used in v-for, so get first + if (Array.isArray(comp) && comp.length > 0) { + comp[0].openFieldPicker(); + } else if (comp && typeof comp.openFieldPicker === 'function') { + comp.openFieldPicker(); + } + }, } }); diff --git a/admin/form-builder/assets/js/components/builder-stage-v4-1/template.php b/admin/form-builder/assets/js/components/builder-stage-v4-1/template.php index 58613e89c..0399eeaff 100644 --- a/admin/form-builder/assets/js/components/builder-stage-v4-1/template.php +++ b/admin/form-builder/assets/js/components/builder-stage-v4-1/template.php @@ -5,7 +5,6 @@

-