Skip to content

Fix issues with duplicating Section field#2648

Open
AbdiTolesa wants to merge 19 commits into
masterfrom
issue-5630-fix_duplicate_section_groups
Open

Fix issues with duplicating Section field#2648
AbdiTolesa wants to merge 19 commits into
masterfrom
issue-5630-fix_duplicate_section_groups

Conversation

@AbdiTolesa
Copy link
Copy Markdown
Contributor

@AbdiTolesa AbdiTolesa commented Dec 12, 2025

Fixes https://github.com/Strategy11/formidable-pro/issues/5630

This PR fixes a few issues related to duplicating section fields in/outside of a field group. Screen casts of those issues are available in the issue description for reference to the test this update.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Dec 12, 2025

Walkthrough

This PR introduces a webpack-style modular architecture for JavaScript bundles (dashboard and overlay), extracts new component classes (counter, tabs-navigator, overlay), exposes utility modules through a centralized core/utils re-export system, and modifies field duplication logic in admin code. Additionally, CSS files contain duplicated blocks and minified bundles exhibit various identifier, operand, and accessor changes.

Changes

Cohort / File(s) Summary
Dashboard modularization
js/formidable_dashboard.js
Replaces self-contained IIFE with webpack-style modular bundle; introduces new class-counter.js and class-tabs-navigator.js components; wires initialization via DOMContentLoaded instead of inline calls.
Overlay modularization
js/formidable_overlay.js
Rewrites overlay bundle into modular webpack structure with new frmOverlay class; extracts logic into core/constants.js, core/utils/* modules (animation, async, error, validation, visibility, globalModules, url).
Core utilities infrastructure
js/src/core/constants.js, js/src/core/utils/animation.js, js/src/core/utils/async.js, js/src/core/utils/error.js, js/src/core/utils/validation.js, js/src/core/utils/visibility.js, js/src/core/utils/globalModules.js, js/src/core/utils/url.js, js/src/core/utils/index.js
Introduces new modular utilities and centralizes exports; provides animation, async queueing, form error handling, validation, visibility helpers, DOM element factories, and URL/query parameter utilities.
Component exports
js/src/components/class-counter.js, js/src/components/class-tabs-navigator.js, js/src/components/class-overlay.js
Adds new exported components: frmCounter, frmTabsNavigator, frmOverlay with respective class methods.
Admin field duplication
js/src/admin/admin.js
Introduces getSectionField helper to extract single divider-li elements; refactors field duplication/insertion to append only divider-li when present; normalizes className updates with regex-based whitespace collapsing.
CSS duplications
css/admin/frm-settings-components.css, css/frm_testing_mode.css
Duplicates entire existing CSS blocks (settings components stylesheet and Bootstrap tooltip styles).
Minified bundle changes
js/formidable_blocks.js
Updates public export name from A to Ay; changes internal binding from i to l; updates CSS class tokens and style injection identifiers.
Minified operand changes
js/frm_testing_mode.js
Swaps operand order in binary operator implementations (e.g., * now uses t\*e instead of e\*t) across operator map; parameter names also renamed.
No-op or refactoring changes
js/addons-page.js, js/formidable-settings-components.js, js/formidable_styles.js, js/onboarding-wizard.js
Contain identical added/deleted blocks or only local identifier refactoring with no observable functional changes.
Modal accessor update
js/welcome-tour.js
Changes modal accessor from p().beginTourModal to h().beginTourModal.

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

Possibly related PRs

Suggested reviewers

  • lauramekaj1
  • truongwp
  • Crabcyborg
🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 1.65% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately reflects the primary focus of the changeset, which centers on fixes for duplicating Section fields as evidenced by the substantial changes in js/src/admin/admin.js and referenced issue #5630.
Description check ✅ Passed The description is directly related to the changeset, referencing the specific issue #5630 and explaining the PR fixes issues with duplicating section fields inside and outside field groups.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 11

♻️ Duplicate comments (1)
js/formidable_dashboard.js (1)

407-409: Duplicate: addToRequestQueue has the same double-execution-on-failure issue as in formidable_overlay.js.

🧹 Nitpick comments (2)
js/formidable_overlay.js (1)

102-127: Buttons rendering: filter invalid entries + double-check primary/secondary logic.

  • map() returns '' for invalid buttons, but the wrapper still renders them; filter instead.
  • buttonTypeClassname makes the second button primary (1 === index); confirm intended ordering.
js/formidable_dashboard.js (1)

920-935: Consider email validation + error handling for saveSubscribedEmail.

At least validate before POSTing (you already bundle isValidEmail / showFormError in core/utils) and add a .catch(...) so failures don’t silently noop. Also verify whether WP expects a nonce for this action (if so, include it).

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 50c1777 and 83dcf42.

⛔ Files ignored due to path filters (9)
  • js/addons-page.js.map is excluded by !**/*.map, !**/*.map
  • js/form-templates.js.map is excluded by !**/*.map, !**/*.map
  • js/formidable-settings-components.js.map is excluded by !**/*.map, !**/*.map
  • js/formidable_admin.js.map is excluded by !**/*.map, !**/*.map
  • js/formidable_blocks.js.map is excluded by !**/*.map, !**/*.map
  • js/formidable_dashboard.js.map is excluded by !**/*.map, !**/*.map
  • js/formidable_overlay.js.map is excluded by !**/*.map, !**/*.map
  • js/formidable_styles.js.map is excluded by !**/*.map, !**/*.map
  • js/onboarding-wizard.js.map is excluded by !**/*.map, !**/*.map
📒 Files selected for processing (6)
  • css/admin/frm-settings-components.css (1 hunks)
  • css/admin/welcome-tour.css (1 hunks)
  • css/font_icons.css (1 hunks)
  • js/formidable_dashboard.js (1 hunks)
  • js/formidable_overlay.js (1 hunks)
  • js/src/admin/admin.js (1 hunks)
🧰 Additional context used
🧬 Code graph analysis (2)
js/formidable_dashboard.js (6)
js/src/components/class-counter.js (1)
  • frmCounter (1-46)
js/src/components/class-tabs-navigator.js (1)
  • frmTabsNavigator (1-135)
js/src/core/utils/animation.js (1)
  • frmAnimate (1-76)
js/src/core/utils/error.js (3)
  • inputElement (16-16)
  • errorElement (17-17)
  • span (26-26)
js/src/core/utils/globalModules.js (1)
  • bold (6-6)
js/src/dashboard.js (1)
  • frmDashboardClass (91-91)
js/formidable_overlay.js (4)
js/src/components/class-overlay.js (1)
  • frmOverlay (6-133)
js/src/core/utils/animation.js (1)
  • frmAnimate (1-76)
js/src/core/utils/error.js (1)
  • span (26-26)
js/src/core/utils/globalModules.js (1)
  • bold (6-6)
🪛 Biome (2.1.2)
js/formidable_dashboard.js

[error] 15-15: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 83-83: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 285-285: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 588-588: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 848-848: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

js/formidable_overlay.js

[error] 16-16: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 224-224: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 527-527: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

🔇 Additional comments (5)
css/admin/frm-settings-components.css (2)

1-12: ⚠️ Verify selector syntax on line 10.

Line 10 contains a selector .formidable_page_formidable-styles.js with a .js extension, which appears unusual. Confirm whether this is:

  1. An intentional class selector that was in the original minified code
  2. A formatting error introduced during CSS conversion
- .formidable_page_formidable-styles.js .control-section .accordion-section-title:focus {
+ .formidable_page_formidable-styles .control-section .accordion-section-title:focus {

(pending verification of intent)


1-627: Unable to verify review comment - insufficient evidence available.

The review raises valid concerns about a potential mismatch between the PR objective (fixing a layout issue with half-width sections) and the CSS changes shown. However, verification cannot be completed because:

  • The git diff output is not accessible to confirm if only formatting changes were made or if functional CSS properties were modified
  • The JavaScript files mentioned (formidable_dashboard.js, formidable_overlay.js, admin.js) could not be located to verify if they contain the actual layout fix
  • The PR title and metadata are not available to confirm the stated objective

To properly verify this review, access to the actual git diff, the source SCSS file, and the referenced JavaScript files is required.

css/admin/welcome-tour.css (1)

1-152: CSS reformatting: Approved, but not addressing PR objective.

This file has been correctly converted from minified to readable CSS with proper formatting, indentation, and source map reference. However, like the previous CSS file, it contains no functional CSS changes related to the stated PR objective ("Fix section getting half width when duplicated with group").

css/font_icons.css (2)

1-10: Good practice: @charset declaration added.

The addition of @charset "UTF-8" (line 4) is a best practice for stylesheets using unicode characters (font icons). This ensures proper character encoding across different environments.


1-853: CSS reformatting: Approved, but not addressing PR objective.

This file has been correctly converted from minified to readable CSS with proper formatting and unicode charset handling. All icon definitions, mappings, and content values are preserved. However, this file is unrelated to the stated PR objective and does not contribute to fixing the "section getting half width when duplicated with group" issue.

Comment thread js/formidable_dashboard.js Outdated
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ frmCounter: () => (/* binding */ frmCounter)
/* harmony export */ });
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

# First, let's verify the file exists and check the lines mentioned
if [ -f "js/formidable_dashboard.js" ]; then
  echo "=== Checking line 15 ==="
  sed -n '15p' js/formidable_dashboard.js | head -c 200
  echo ""
  echo ""
  echo "=== Checking lines 83, 285, 588, 848 ==="
  for line in 83 285 588 848; do
    echo "Line $line:"
    sed -n "${line}p" js/formidable_dashboard.js | head -c 150
    echo ""
  done
else
  echo "File not found"
fi

Repository: Strategy11/formidable-forms

Length of output: 981


🌐 Web query:

Biome lint/suspicious/noFunctionAssign ignore generated files configuration

💡 Result:

Options to ignore generated files (so lint rule lint/suspicious/noFunctionAssign won't run on them):

  1. Project config (recommended)
  • Add file-glob negations in files.includes to exclude generated files from lint/format. Example (biome.json):
    {
    "files": { "includes": ["", "!/*.generated.js"] }
    }
    This excludes those files from linting/formatting. Note: a single leading ! still lets Biome index the folder; use double-leading !! to prevent indexing/project operations. [1]
  1. Linter-specific ignore
  • Use linter.ignore to skip directories/globs only for the linter:
    {
    "linter": { "ignore": ["generated", "**/*.generated.js"] }
    }
    This prevents lint diagnostics (including suspicious/noFunctionAssign) in matched files. [1][2]
  1. Per-file comments (if you must keep file but silence diagnostics)
  • Add a top-level suppression in the generated file:
    // biome-ignore-all lint/suspicious/noFunctionAssign: generated file
    This disables that rule for the whole file. Or use inline: // biome-ignore lint/suspicious/noFunctionAssign: reason. [3]

Notes:

  • Use "!!" (double negation) when you want Biome to completely skip indexing/project operations for a folder (example: "!!**/dist"). [1]
  • Use the suppression comments only inside the file; Biome does not provide a comment to ignore an external file. [3]

Sources: Biome configuration and linter docs. [1][2][3]


🏁 Script executed:

# Check for Biome configuration files
echo "=== Looking for Biome config files ==="
find . -maxdepth 2 -type f \( -name "biome.json" -o -name ".biomerc*" -o -name "biome.jsonc" \) 2>/dev/null

# Also check package.json for Biome config
echo ""
echo "=== Checking for Biome config in package.json ==="
if [ -f "package.json" ]; then
  cat package.json | grep -A 20 '"biome"' || echo "No Biome config in package.json"
fi

# Check for Eslint or other linter overrides patterns that might apply
echo ""
echo "=== Checking for linter overrides in comments ==="
rg "noFunctionAssign|@biome|biome-ignore" --type js --max-count 10 2>/dev/null || echo "No pattern found"

Repository: Strategy11/formidable-forms

Length of output: 241


🏁 Script executed:

# Check current Biome configuration
echo "=== Current biome.json ==="
cat biome.json

echo ""
echo "=== Check if js/ is in .gitignore (indicating generated) ==="
if [ -f ".gitignore" ]; then
  grep -E "^js/|^\*\.bundle|dist|build" .gitignore || echo "No js/ in gitignore"
fi

echo ""
echo "=== Check git status for js/formidable_dashboard.js ==="
git ls-files js/formidable_dashboard.js > /dev/null 2>&1 && echo "File IS tracked in git" || echo "File NOT tracked in git"

echo ""
echo "=== Check if file has Babel banner or is clearly generated ==="
head -5 js/formidable_dashboard.js | grep -i "babel\|generated\|webpack\|bundle" || echo "No generation indicators in first 5 lines"

Repository: Strategy11/formidable-forms

Length of output: 2174


Exclude generated webpack bundles from Biome linting.

The noFunctionAssign rule is being applied to js/formidable_dashboard.js (a webpack bundle with Babel helpers), which is generated code. Update biome.json to exclude these files:

{
  "linter": {
    "ignore": ["js/formidable_dashboard.js"]
  }
}

Alternatively, use glob patterns like ["!**/dist/**", "!**/js/**/*.bundle.js"] if bundled output lives in a dedicated directory.

Also applies to: lines 83, 285, 588, 848 (same _typeof helper).

🧰 Tools
🪛 Biome (2.1.2)

[error] 15-15: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

🤖 Prompt for AI Agents
In js/formidable_dashboard.js around lines 15 (and also 83, 285, 588, 848) the
Babel-generated webpack bundle is being linted and tripping the noFunctionAssign
rule; update biome.json to exclude generated bundles by adding appropriate
ignore entries such as the specific file "js/formidable_dashboard.js" or a glob
pattern excluding build outputs (for example add entries like "!**/dist/**" or
"!**/js/**/*.bundle.js" or "js/formidable_dashboard.js" under linter.ignore) so
Biome skips these generated files.

Comment thread js/formidable_dashboard.js Outdated
Comment thread js/formidable_dashboard.js Outdated
Comment on lines +109 to +124
key: "init",
value: function init() {
var _this = this;
if (null === this.wrapper || !this.navs.length || null === this.slideTrackLine || null === this.slideTrack || !this.slides.length) {
return;
}
this.initDefaultSlideTrackerWidth();
this.navs.forEach(function (nav, index) {
nav.addEventListener('click', function (event) {
return _this.onNavClick(event, index);
});
});
this.setupScrollbarObserver();
// Cleanup observers when page unloads to prevent memory leaks
window.addEventListener('beforeunload', this.cleanupObservers);
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

cleanupObservers is registered unbound, so it won’t clean up.

window.addEventListener('beforeunload', this.cleanupObservers) calls the method with this === window, so this.resizeObserver is undefined and disconnect never happens. Bind once in the constructor (or wrap in an arrow).

Also applies to: 185-191

🤖 Prompt for AI Agents
In js/formidable_dashboard.js around lines 109-124 (and similarly at 185-191),
the cleanupObservers function is registered unbound so when called this ===
window and observers aren't disconnected; bind the method once (e.g. in the
constructor set this.cleanupObservers = this.cleanupObservers.bind(this)) or
convert cleanupObservers to an arrow function so it retains class this, then
register window.addEventListener('beforeunload', this.cleanupObservers) and
ensure any corresponding removeEventListener uses the same bound reference so
observers are actually cleaned up.

Comment thread js/formidable_dashboard.js Outdated
Comment on lines +151 to +158
key: "initSlideTrackUnderline",
value: function initSlideTrackUnderline(nav, index) {
this.slideTrackLine.classList.remove('frm-first', 'frm-last');
var activeNav = 'undefined' !== typeof nav ? nav : this.navs.filter(function (nav) {
return nav.classList.contains('frm-active');
});
this.positionUnderlineIndicator(activeNav);
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

this.navs.filter(...) is unsafe (NodeList doesn’t have filter).

If initSlideTrackUnderline() is ever called without a nav argument, this becomes a runtime error. Use Array.from(this.navs).filter(...) (or querySelector for the active nav).

🤖 Prompt for AI Agents
In js/formidable_dashboard.js around lines 151 to 158, the code uses
this.navs.filter(...) but this.navs is a NodeList (no filter) and calling filter
will throw if nav is undefined; change the logic to obtain a single active nav
element safely: either use this.el.querySelector('.frm-active') to find the
active nav, or convert the NodeList to an Array with
Array.from(this.navs).filter(...) and then pick the first matching element (e.g.
[0] or shift()), and pass that element to positionUnderlineIndicator; ensure the
fallback when nothing is found is handled (no-op or a safe default).

Comment thread js/formidable_dashboard.js Outdated
Comment on lines +884 to +893
key: "initInbox",
value: function initInbox() {
var _this = this;
new _components_class_tabs_navigator__WEBPACK_IMPORTED_MODULE_1__.frmTabsNavigator('.frm-inbox-wrapper');
var userEmailInput = document.querySelector('#frm_leave_email');
var subscribeButton = document.querySelector('#frm-add-my-email-address');
subscribeButton.addEventListener('click', function () {
_this.saveSubscribedEmail(userEmailInput.value).then();
});
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🔴 Critical

Null checks needed before wiring inbox subscription click handler.

If #frm_leave_email or #frm-add-my-email-address isn’t present, subscribeButton.addEventListener will throw.

 var userEmailInput = document.querySelector('#frm_leave_email');
 var subscribeButton = document.querySelector('#frm-add-my-email-address');
+if (!userEmailInput || !subscribeButton) {
+  return;
+}
 subscribeButton.addEventListener('click', function () {
   _this.saveSubscribedEmail(userEmailInput.value).then();
 });
🤖 Prompt for AI Agents
In js/formidable_dashboard.js around lines 884 to 893, the click handler wires
up without checking DOM nodes which will throw if #frm_leave_email or
#frm-add-my-email-address are missing; update the code to first query both
elements, check they are non-null (if either is missing simply skip wiring), and
inside the click handler read the email value defensively (e.g. use
userEmailInput.value || '' or check userEmailInput before accessing value)
before calling this.saveSubscribedEmail to avoid runtime errors.

Comment thread js/formidable_overlay.js Outdated
Comment on lines +49 to +61
value: function open(overlayData) {
this.overlayData = {
hero_image: null,
heading: null,
copy: null,
buttons: []
};
this.overlayData = _objectSpread(_objectSpread({}, this.overlayData), overlayData);
this.bodyAddOverflowHidden();
this.body.insertBefore(this.buildOverlay(), this.body.firstChild);
this.initCloseButton();
this.initOverlayIntroAnimation(200);
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

Prevent duplicate overlays when open() is called multiple times.

open() always inserts a new .frm-overlay--wrapper without first removing an existing one, so repeated calls can stack overlays and leave the body in a locked-scroll state.

 value: function open(overlayData) {
+  this.close(); // ensure only one overlay at a time
   this.overlayData = {
     hero_image: null,
     heading: null,
     copy: null,
     buttons: []
   };
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
value: function open(overlayData) {
this.overlayData = {
hero_image: null,
heading: null,
copy: null,
buttons: []
};
this.overlayData = _objectSpread(_objectSpread({}, this.overlayData), overlayData);
this.bodyAddOverflowHidden();
this.body.insertBefore(this.buildOverlay(), this.body.firstChild);
this.initCloseButton();
this.initOverlayIntroAnimation(200);
}
value: function open(overlayData) {
this.close(); // ensure only one overlay at a time
this.overlayData = {
hero_image: null,
heading: null,
copy: null,
buttons: []
};
this.overlayData = _objectSpread(_objectSpread({}, this.overlayData), overlayData);
this.bodyAddOverflowHidden();
this.body.insertBefore(this.buildOverlay(), this.body.firstChild);
this.initCloseButton();
this.initOverlayIntroAnimation(200);
}
🤖 Prompt for AI Agents
In js/formidable_overlay.js around lines 49–61, open() currently always inserts
a new .frm-overlay--wrapper which lets multiple overlays stack and leaves body
scroll locked; fix by checking for an existing overlay element before inserting:
if one exists, remove it (or clean it up via its close/destroy routine) and
ensure any body overflow/hidden state is cleared, or simply return early to
avoid duplication; then proceed to insert the new overlay and call
bodyAddOverflowHidden so the body scroll lock is applied idempotently.

Comment thread js/formidable_overlay.js Outdated
Comment on lines +81 to +90
key: "initCloseButton",
value: function initCloseButton() {
var overlayWrapper = document.querySelector('.frm-overlay--wrapper');
if (overlayWrapper) {
var closeButton = document.createElement('span');
closeButton.classList.add('frm-overlay--close');
closeButton.addEventListener('click', this.close);
overlayWrapper.prepend(closeButton);
}
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion | 🟠 Major

Close control should be keyboard-accessible (don’t use clickable <span>).

A <span> with only a click handler is not accessible (no focus/keyboard semantics). Prefer a <button type="button" aria-label="Close"> (or add role/tabindex + key handlers at minimum).

🤖 Prompt for AI Agents
In js/formidable_overlay.js around lines 81 to 90, the close control is created
as a non-focusable <span> with only a click handler which is not
keyboard-accessible; replace the span element with a semantic <button
type="button"> element, preserve the class 'frm-overlay--close', add
aria-label="Close" (or localized label) so screen readers announce it, attach
the existing click handler to the button, and ensure it is focusable by default
(no tabindex needed) so keyboard users can activate it via Enter/Space.

Comment thread js/formidable_overlay.js Outdated
Comment on lines +140 to +149
key: "getCopy",
value: function getCopy() {
if (this.overlayData.copy) {
var copy = frmDom.tag('div');
copy.innerHTML = this.overlayData.copy;
return frmDom.div({
className: 'frm-overlay--copy',
child: copy
});
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🔴 Critical

Potential XSS: innerHTML = this.overlayData.copy.

If overlayData.copy can contain user-controlled content (even indirectly), this is an injection vector. Prefer textContent, or sanitize (e.g., allowlist sanitizer) before assignment.

🤖 Prompt for AI Agents
In js/formidable_overlay.js around lines 140 to 149, assigning
this.overlayData.copy to element.innerHTML is a potential XSS vector; replace it
by assigning to textContent (copy.textContent = this.overlayData.copy) so
user-controlled data is rendered as plain text, or if HTML must be allowed, run
the content through a vetted allowlist sanitizer (e.g., DOMPurify) and then set
innerHTML to the sanitized result; ensure any sanitizer is imported/available
and fallback to textContent if sanitization fails.

Comment thread js/formidable_overlay.js Outdated
Comment on lines +346 to +348
var addToRequestQueue = function addToRequestQueue(task) {
return lastPromise = lastPromise.then(task).catch(task);
};
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

addToRequestQueue can execute task twice on failures (and passes an arg unexpectedly).

lastPromise.then(task).catch(task) will call task again if task rejects, and it will receive the rejection reason argument (despite the JSDoc expecting task()).

 var addToRequestQueue = function addToRequestQueue(task) {
-  return lastPromise = lastPromise.then(task).catch(task);
+  lastPromise = lastPromise
+    .catch(function () {})
+    .then(function () {
+      return Promise.resolve().then(task);
+    });
+  return lastPromise;
 };
🤖 Prompt for AI Agents
In js/formidable_overlay.js around lines 346 to 348, the current chain uses
lastPromise.then(task).catch(task) which will invoke task twice on rejection and
pass the rejection reason as an argument; replace this with a single then call
that supplies both onFulfilled and onRejected handlers which each call task with
no arguments so task runs exactly once per enqueue and never receives the
previous rejection value.

Comment thread js/src/admin/admin.js Outdated
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

♻️ Duplicate comments (1)
js/src/admin/admin.js (1)

2329-2399: Fix “section field” duplication to operate on the actually-inserted node (and don’t insert an unwrapped li as a new row)
This currently appends ul li in some branches but still calls makeDraggable(replaceWith.get(0)) and passes replaceWith.get(0) to layout syncing—replaceWith.get(0) may not be in the DOM / may not be the inserted element. Also, in the “no siblings” branch you’re inserting a bare li at the row level, which risks breaking the builder DOM/layout.

-		const isSectionField = $fieldObject => $fieldObject.find( 'ul li[data-ftype="divider"]' ).length > 0;
+		const isSectionField = $fieldObject => $fieldObject.find( 'ul li[data-ftype="divider"]' ).length > 0;

 			success: function( msg ) {
 				let newRow;
-
 				let replaceWith;
+				let appendedEl = null;

 				if ( null !== newRowId ) {
 					newRow = document.getElementById( newRowId );
 					if ( null !== newRow ) {
 						replaceWith = msgAsjQueryObject( msg );
-						if ( isSectionField( replaceWith ) ) {
-							jQuery( newRow ).append( jQuery( replaceWith.get(0).querySelector( 'ul li' ) ) );
-						} else {
-							jQuery( newRow ).append( replaceWith );
-						}
-						makeDraggable( replaceWith.get( 0 ), '.frm-move' );
+						const wrapperEl = replaceWith.get( 0 );
+						const $toAppend = ( wrapperEl && isSectionField( replaceWith ) )
+							? jQuery( wrapperEl.querySelector( 'ul li[data-ftype="divider"]' ) )
+							: replaceWith;
+
+						jQuery( newRow ).append( $toAppend );
+						appendedEl = newRow.lastElementChild;
+						if ( appendedEl ) {
+							makeDraggable( appendedEl, '.frm-move' );
+						}
 						if ( null !== fieldOrder ) {
 							newRow.lastElementChild.setAttribute( 'frm-field-order', fieldOrder );
 						}
 ...
-						setLayoutClassesForDuplicatedFieldInGroup( $field.get( 0 ), replaceWith.get( 0 ) );
+						if ( appendedEl ) {
+							setLayoutClassesForDuplicatedFieldInGroup( $field.get( 0 ), appendedEl );
+						}
 						return;
 					}
 				}

 				if ( $field.siblings( 'li.form-field' ).length ) {
 					replaceWith = msgAsjQueryObject( msg );
-					if ( isSectionField( replaceWith ) ) {
-						$field.after( jQuery( replaceWith.get(0).querySelector( 'ul li' ) ) );
-					} else {
-						$field.after( replaceWith );
-					}
+					{
+						const wrapperEl = replaceWith.get( 0 );
+						const $toInsert = ( wrapperEl && isSectionField( replaceWith ) )
+							? jQuery( wrapperEl.querySelector( 'ul li[data-ftype="divider"]' ) )
+							: replaceWith;
+						$field.after( $toInsert );
+						appendedEl = $field.get( 0 )?.nextElementSibling || null;
+					}
 					
 					syncLayoutClasses( $field );
-					makeDraggable( replaceWith.get( 0 ), '.frm-move' );
+					if ( appendedEl ) {
+						makeDraggable( appendedEl, '.frm-move' );
+					}
 				} else {
 					replaceWith = wrapFieldLi( msg );
-					if ( isSectionField( replaceWith ) ) {
-						$field.parent().parent().after( jQuery( replaceWith.get(0).querySelector( 'ul li' ) ) );
-					} else {
-						$field.parent().parent().after( replaceWith );
-					}
+					// NOTE: This branch creates/inserts a *new row wrapper*; do not insert a bare <li>.
+					$field.parent().parent().after( replaceWith );
 					makeDroppable( replaceWith.get( 0 ).querySelector( 'ul.frm_sorting' ) );
 					makeDraggable( replaceWith.get( 0 ).querySelector( 'li.form-field' ), '.frm-move' );
 				}
 ...
-				setLayoutClassesForDuplicatedFieldInGroup( $field.get( 0 ), replaceWith.get( 0 ) );
+				if ( appendedEl ) {
+					setLayoutClassesForDuplicatedFieldInGroup( $field.get( 0 ), appendedEl );
+				}
 			}
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 83dcf42 and c413751.

⛔ Files ignored due to path filters (1)
  • js/formidable_admin.js.map is excluded by !**/*.map, !**/*.map
📒 Files selected for processing (1)
  • js/src/admin/admin.js (4 hunks)

Comment thread js/src/admin/admin.js
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

♻️ Duplicate comments (2)
js/formidable_overlay.js (1)

1-1: Previously flagged overlay issues still apply (XSS / idempotency / a11y / queue chaining).
The bundle still contains patterns previously called out (e.g., innerHTML from overlayData.copy, clickable <span> close control, open() stacking behavior, and lastPromise.then(task).catch(task) semantics).

js/formidable_dashboard.js (1)

1-1: Previously flagged dashboard issues still apply (binding/null-guards/NodeList usage + bundle linting).
This file still shows the same hazards already reviewed (e.g., beforeunload handler not bound, this.navs.filter(...) on NodeList, missing DOM null checks in inbox wiring, and frmCounter options null-guard).

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between c413751 and 5219df7.

📒 Files selected for processing (12)
  • css/admin/frm-settings-components.css (1 hunks)
  • css/frm_testing_mode.css (1 hunks)
  • js/addons-page.js (1 hunks)
  • js/formidable-settings-components.js (1 hunks)
  • js/formidable_blocks.js (1 hunks)
  • js/formidable_dashboard.js (1 hunks)
  • js/formidable_overlay.js (1 hunks)
  • js/formidable_styles.js (1 hunks)
  • js/frm_testing_mode.js (1 hunks)
  • js/onboarding-wizard.js (1 hunks)
  • js/src/admin/admin.js (3 hunks)
  • js/welcome-tour.js (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (2)
  • css/admin/frm-settings-components.css
  • js/src/admin/admin.js
🧰 Additional context used
🧬 Code graph analysis (4)
js/welcome-tour.js (2)
js/src/admin/admin.js (46)
  • t (718-718)
  • t (743-743)
  • t (9067-9067)
  • t (10258-10258)
  • e (8280-8280)
  • i (440-440)
  • i (1798-1798)
  • i (2276-2276)
  • i (3036-3036)
  • i (3051-3051)
  • i (3123-3123)
  • i (3141-3141)
  • i (3155-3158)
  • i (3181-3189)
  • i (3219-3219)
  • i (3228-3228)
  • i (3489-3495)
  • i (3631-3634)
  • i (5481-5481)
  • i (5550-5551)
  • i (5625-5627)
  • a (3099-3099)
  • c (723-723)
  • c (748-748)
  • c (7318-7318)
  • c (9143-9143)
  • s (276-276)
  • s (8286-8286)
  • s (9043-9043)
  • s (9120-9120)
  • f (9082-9082)
  • p (8222-8222)
  • p (8237-8237)
  • v (3395-3395)
  • v (3415-3415)
  • v (6950-6950)
  • v (7322-7322)
  • v (7873-7873)
  • v (7889-7889)
  • v (7905-7905)
  • b (8829-8830)
  • w (9616-9616)
  • frmDom (241-241)
  • frmDom (242-242)
  • frmDom (243-243)
  • at (3063-3063)
js/src/welcome-tour/ui/spotlight.js (1)
  • getComputedStyle (123-123)
js/formidable-settings-components.js (1)
js/admin/style.js (5)
  • frmDom (23-23)
  • frmDom (24-24)
  • frmDom (25-25)
  • frmDom (26-26)
  • frmDom (1164-1164)
js/frm_testing_mode.js (2)
js/src/admin/upgrade-popup.js (1)
  • frmDom (3-3)
js/src/frm_testing_mode.js (1)
  • frmDom (34-34)
js/onboarding-wizard.js (1)
js/src/admin/addon-state.js (3)
  • frmDom (3-3)
  • a (198-198)
  • ajaxurl (12-12)
🪛 Biome (2.1.2)
js/formidable_dashboard.js

[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

js/formidable_blocks.js

[error] 1-1: Unsafe usage of 'return'.

'return' in 'finally' overwrites the control flow statements inside 'try' and 'catch'.

(lint/correctness/noUnsafeFinally)


[error] 1-1: Unsafe usage of 'throw'.

'throw' in 'finally' overwrites the control flow statements inside 'try' and 'catch'.

(lint/correctness/noUnsafeFinally)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

js/welcome-tour.js

[error] 2-2: This case is falling through to the next case.

Add a break or return statement to the end of this case to prevent fallthrough.

(lint/suspicious/noFallthroughSwitchClause)


[error] 2-2: This case is falling through to the next case.

Add a break or return statement to the end of this case to prevent fallthrough.

(lint/suspicious/noFallthroughSwitchClause)


[error] 2-2: Do not use the t variable name as a label

The variable is declared here

Creating a label with the same name as an in-scope variable leads to confusion.

(lint/suspicious/noLabelVar)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

css/frm_testing_mode.css

[error] 3-3: Unexpected shorthand property background after background-color

(lint/suspicious/noShorthandPropertyOverrides)


[error] 3-3: Duplicate properties can lead to unexpected behavior and may override previous declarations unintentionally.

text-align is already defined here.

Remove or rename the duplicate property to ensure consistent styling.

(lint/suspicious/noDuplicateProperties)


[error] 3-3: Duplicate properties can lead to unexpected behavior and may override previous declarations unintentionally.

min-width is already defined here.

Remove or rename the duplicate property to ensure consistent styling.

(lint/suspicious/noDuplicateProperties)


[error] 3-3: Duplicate properties can lead to unexpected behavior and may override previous declarations unintentionally.

border-radius is already defined here.

Remove or rename the duplicate property to ensure consistent styling.

(lint/suspicious/noDuplicateProperties)

js/addons-page.js

[error] 1-1: Unsafe usage of 'throw'.

'throw' in 'finally' overwrites the control flow statements inside 'try' and 'catch'.

(lint/correctness/noUnsafeFinally)


[error] 1-1: Unsafe usage of 'return'.

'return' in 'finally' overwrites the control flow statements inside 'try' and 'catch'.

(lint/correctness/noUnsafeFinally)


[error] 1-1: Unsafe usage of 'throw'.

'throw' in 'finally' overwrites the control flow statements inside 'try' and 'catch'.

(lint/correctness/noUnsafeFinally)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: Do not use the t variable name as a label

The variable is declared here

Creating a label with the same name as an in-scope variable leads to confusion.

(lint/suspicious/noLabelVar)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

js/formidable-settings-components.js

[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

js/formidable_overlay.js

[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

js/formidable_styles.js

[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: Do not use the t variable name as a label

The variable is declared here

Creating a label with the same name as an in-scope variable leads to confusion.

(lint/suspicious/noLabelVar)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

js/frm_testing_mode.js

[error] 2-2: This case is falling through to the next case.

Add a break or return statement to the end of this case to prevent fallthrough.

(lint/suspicious/noFallthroughSwitchClause)


[error] 2-2: Do not use the t variable name as a label

The variable is declared here

Creating a label with the same name as an in-scope variable leads to confusion.

(lint/suspicious/noLabelVar)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

js/onboarding-wizard.js

[error] 2-2: This case is falling through to the next case.

Add a break or return statement to the end of this case to prevent fallthrough.

(lint/suspicious/noFallthroughSwitchClause)


[error] 2-2: Unsafe usage of 'throw'.

'throw' in 'finally' overwrites the control flow statements inside 'try' and 'catch'.

(lint/correctness/noUnsafeFinally)


[error] 2-2: This case is falling through to the next case.

Add a break or return statement to the end of this case to prevent fallthrough.

(lint/suspicious/noFallthroughSwitchClause)


[error] 2-2: This case is falling through to the next case.

Add a break or return statement to the end of this case to prevent fallthrough.

(lint/suspicious/noFallthroughSwitchClause)


[error] 2-2: This case is falling through to the next case.

Add a break or return statement to the end of this case to prevent fallthrough.

(lint/suspicious/noFallthroughSwitchClause)


[error] 2-2: This case is falling through to the next case.

Add a break or return statement to the end of this case to prevent fallthrough.

(lint/suspicious/noFallthroughSwitchClause)


[error] 2-2: This case is falling through to the next case.

Add a break or return statement to the end of this case to prevent fallthrough.

(lint/suspicious/noFallthroughSwitchClause)


[error] 2-2: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 2-2: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 2-2: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 2-2: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 2-2: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 2-2: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 2-2: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

🔇 Additional comments (7)
js/addons-page.js (1)

1-1: Looks like rebuilt/minified output only.
No actionable logic-level delta is apparent in this bundle; if this file is a generated artifact, consider excluding it from Biome linting to avoid false positives from helper patterns.

js/formidable_styles.js (1)

1-1: Looks like rebuilt bundle output (no reviewable semantic change visible).
If this is generated, consider excluding it from Biome linting to avoid false positives (use-before-declare / function-assign helpers).

js/frm_testing_mode.js (1)

2-2: LGTM (appears to be identifier-only changes in generated bundle).
If js/frm_testing_mode.js is a built artifact, consider excluding it from Biome linting to avoid bundle-helper violations.

js/welcome-tour.js (1)

2-2: Verify begin-tour modal caching is truly idempotent (avoid duplicate modal instances).
The new h().beginTourModal || p({ beginTourModal: t }) path assumes the created t is the same underlying modal instance across calls (e.g., maybeCreateModal keyed by id). If not, repeated calls could create extra DOM/modal instances that aren’t tracked by beginTourModal.

css/frm_testing_mode.css (1)

3-3: OK (formatting-only change).
If Biome is linting this vendor-ish block and producing noise (duplicate properties/shorthand overrides), consider suppressing/excluding for this file or vendor section.

js/onboarding-wizard.js (1)

2-2: Minified file – compiled output only.

This file contains minified JavaScript with internal variable renaming (e.g., nr, te). According to the AI summary, there are no observable behavioral changes. Since this is a compiled artifact, detailed review is not applicable.

Note: The PR title mentions fixing "section getting half width when duplicated with group," but the actual fix logic appears to be in js/src/admin/admin.js (the getLiElement helper mentioned in the AI summary), which was not provided for review.

js/formidable_blocks.js (1)

1-1: Minified file – compiled output with CSS hash updates.

This file contains minified JavaScript with CSS class name hash updates (e.g., .X_GKlxRFRHSOWckGcSPJ.t3RQZV1ZQbHGYyQUnhIY) and internal module binding changes. According to the AI summary, functional parity is retained. Since this is a compiled artifact generated from CSS modules and bundled source files, detailed review is not applicable.

Note: Like the previous file, this doesn't contain the actual fix mentioned in the PR title. The duplication logic fix appears to be in source files not included in this review.

@AbdiTolesa AbdiTolesa changed the title Fix section getting half width when duplicated with group Fix issues with duplicating Section field Dec 12, 2025
@AbdiTolesa AbdiTolesa self-assigned this Dec 12, 2025
@lauramekaj1
Copy link
Copy Markdown
Contributor

@AbdiTolesa I noticed and tested that when a group contains two section fields, duplicating the group itself works as expected. However, duplicating a section field within the group causes layout issues even with two fields.
When the group contains three or more section fields, the issues occur both when duplicating the group and when duplicating a section field within the group.

Issue 1: Duplicating a group containing three or more section fields causes section fields to have incorrect widths (https://www.loom.com/share/97c9d31e177b4a0c8b18673150cea5d0)
Issue 2: Duplicating a section field within a group does not apply the correct layout class (https://www.loom.com/share/f853ab3cbcae4b0a97d92099232ebb41)

@AbdiTolesa AbdiTolesa added the deploy Deploy website on push label Dec 24, 2025
@AbdiTolesa
Copy link
Copy Markdown
Contributor Author

Issue 1: Duplicating a group containing three or more section fields causes section fields to have incorrect widths (https://www.loom.com/share/97c9d31e177b4a0c8b18673150cea5d0)

@lauramekaj1 I couldn't reproduce this:

CleanShot.2025-12-24.at.21.07.21.mp4

@AbdiTolesa
Copy link
Copy Markdown
Contributor Author

Issue 2: Duplicating a section field within a group does not apply the correct layout class

I couldn't see this error anymore too:

CleanShot.2025-12-24.at.21.11.59.mp4

@lauramekaj1
Copy link
Copy Markdown
Contributor

@AbdiTolesa These issues are easier reproduced when the form has not yet been saved or updated. After saving or updating the form, the section fields realign to the expected widths (https://www.loom.com/share/af6b08881a924d76a287af21e660a5a4)
Let me know if you can reproduce it!

coderabbitai[bot]

This comment was marked as resolved.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 4

♻️ Duplicate comments (5)
js/formidable-settings-components.js (2)

1-1: Guard updateAllDependentElements when propagateInputs is empty.

h.updateAllDependentElements assumes this.data.propagateInputs[0] exists; if the will-change list has no matching inputs, this throws at runtime when dispatching the change event. Add a simple length check and early return.

Suggested source-level fix
updateAllDependentElements( value ) {
-  this.data.propagateInputs.forEach( ( input ) => {
-    input.value = value;
-  } );
-  this.data.propagateInputs[0].dispatchEvent( this.data.changeEvent );
+  const { propagateInputs, changeEvent } = this.data || {};
+  if ( ! propagateInputs || propagateInputs.length === 0 ) {
+    return;
+  }
+
+  propagateInputs.forEach( ( input ) => {
+    input.value = value;
+  } );
+
+  propagateInputs[0].dispatchEvent( changeEvent );
}

1-1: Bind cleanupObservers in tabs navigator before registering beforeunload.

In the tabs navigator class (w), window.addEventListener("beforeunload", this.cleanupObservers) will call cleanupObservers with this === window, so this.resizeObserver is never disconnected.

Suggested source-level change
class TabsNavigator {
  constructor( wrapper ) {
    // ...
-   window.addEventListener( 'beforeunload', this.cleanupObservers );
+   this.cleanupObservers = this.cleanupObservers.bind( this );
+   window.addEventListener( 'beforeunload', this.cleanupObservers );
  }

  cleanupObservers() {
    if ( this.resizeObserver ) {
      this.resizeObserver.disconnect();
      this.resizeObserver = null;
    }
  }
}
js/formidable_overlay.js (1)

1-1: Harden overlay open() + close control and avoid unsafe innerHTML.

Three related concerns here:

  1. Multiple overlays can stack.
    open() always inserts a new .frm-overlay--wrapper without removing an existing one, so repeated calls can produce multiple overlays and leave the body in a locked-scroll state.

  2. Close control isn’t keyboard‑accessible.
    The close UI is a <span> with only a click handler; it’s not focusable and has no keyboard semantics.

  3. Potential XSS via getCopy() using innerHTML.
    If overlayData.copy can contain any user‑controlled or unsanitized HTML, assigning it directly to innerHTML is unsafe.

Suggested source-level improvements
open( overlayData ) {
-  this.overlayData = {
-    hero_image: null,
-    heading: null,
-    copy: null,
-    buttons: [],
-  };
-  this.overlayData = { ...this.overlayData, ...overlayData };
-  this.bodyAddOverflowHidden();
-  this.body.insertBefore( this.buildOverlay(), this.body.firstChild );
-  this.initCloseButton();
+  // Ensure only one overlay at a time.
+  this.close();
+
+  this.overlayData = {
+    hero_image: null,
+    heading: null,
+    copy: null,
+    buttons: [],
+    ...overlayData,
+  };
+
+  this.bodyAddOverflowHidden();
+  this.body.insertBefore( this.buildOverlay(), this.body.firstChild );
+  this.initCloseButton();
   this.initOverlayIntroAnimation( 200 );
}

initCloseButton() {
  const wrapper = document.querySelector( '.frm-overlay--wrapper' );
  if ( ! wrapper ) {
    return;
  }
- const closeEl = document.createElement( 'span' );
- closeEl.classList.add( 'frm-overlay--close' );
- closeEl.addEventListener( 'click', this.close );
+ const closeEl = document.createElement( 'button' );
+ closeEl.type = 'button';
+ closeEl.classList.add( 'frm-overlay--close' );
+ closeEl.setAttribute( 'aria-label', 'Close' );
+ closeEl.addEventListener( 'click', () => this.close() );
  wrapper.prepend( closeEl );
}

getCopy() {
  if ( ! this.overlayData.copy ) {
    return '';
  }
- const inner = frmDom.tag( 'div' );
- inner.innerHTML = this.overlayData.copy;
+ const inner = frmDom.tag( 'div' );
+ // Prefer textContent; if HTML is required, ensure it is sanitized upstream.
+ inner.textContent = this.overlayData.copy;
  return frmDom.div( { className: 'frm-overlay--copy', child: inner } );
}
js/formidable_dashboard.js (1)

1-1: Fix tabs navigator cleanup, NodeList usage, counter options guard, and inbox null checks.

This bundle still reflects several runtime-footgun issues that were previously flagged in the source:

  1. Unbound cleanupObservers in tabs navigator.
    In the tabs class, window.addEventListener('beforeunload', this.cleanupObservers) calls the method with this === window, so this.resizeObserver never disconnects. Bind the method once in the constructor or wrap in an arrow.

  2. NodeList .filter() in initSlideTrackUnderline.
    this.navs is a NodeList from querySelectorAll, which doesn’t reliably support .filter. If the fallback path (no explicit nav arg) is ever used, this will throw.

  3. frmCounter options can be null.
    The counter constructor uses typeof options !== 'undefined' && typeof options.timetoFinish !== 'undefined', which is still true when options === null, and options.timetoFinish will throw. Guard with a truthy check (e.g. options && options.timetoFinish).

  4. Inbox subscription DOM nodes may be missing.
    initInbox calls document.querySelector('#frm-add-my-email-address').addEventListener(...) and then reads userEmailInput.value without verifying either element exists. On dashboards without that widget, this will blow up.

Suggested source-level fixes
// class-tabs-navigator.js (source)
constructor( wrapper ) {
  // ...
- window.addEventListener( 'beforeunload', this.cleanupObservers );
+ this.cleanupObservers = this.cleanupObservers.bind( this );
+ window.addEventListener( 'beforeunload', this.cleanupObservers );
}

initSlideTrackUnderline( nav, index ) {
- const target = nav !== undefined
-   ? nav
-   : this.navs.filter( ( el ) => el.classList.contains( 'frm-active' ) );
+ let target = nav;
+ if ( ! target ) {
+   target = Array.from( this.navs ).find( ( el ) =>
+     el.classList.contains( 'frm-active' )
+   );
+ }
+ if ( ! target ) {
+   return;
+ }
  this.positionUnderlineIndicator( target );
}

// class-counter.js (source)
function frmCounter( el, options ) {
  // ...
- this.timeToFinish = typeof options !== 'undefined' &&
-   typeof options.timetoFinish !== 'undefined'
-   ? options.timetoFinish
-   : 1400;
+ this.timeToFinish = options && typeof options.timetoFinish !== 'undefined'
+   ? options.timetoFinish
+   : 1400;
}

// js/src/dashboard.js (source)
initInbox() {
  new TabsNavigator( '.frm-inbox-wrapper' );
  const userEmailInput = document.querySelector( '#frm_leave_email' );
  const subscribeButton = document.querySelector( '#frm-add-my-email-address' );
+ if ( ! userEmailInput || ! subscribeButton ) {
+   return;
+ }
  subscribeButton.addEventListener( 'click', () => {
    this.saveSubscribedEmail( userEmailInput.value || '' ).then();
  } );
}
js/src/admin/admin.js (1)

2335-2407: Duplicating fields: operate on the actually inserted element + guard layout class handling (still risks runtime errors and mis-synced layout).

Within duplicateField:

  • getLiElement is now used to select the <li data-ftype="divider"> when duplicating dividers, and all three insertion paths append/insert that result:

    const newField = getLiElement( replaceWith );
    jQuery( newRow ).append( newField );           // new-row path
    ...
    const newField = getLiElement( replaceWith );
    $field.after( newField );                      // in-row path
    ...
    $field.parent().parent().after( getLiElement( replaceWith ) ); // wrapFieldLi path
  • However you still treat replaceWith.get( 0 ) as “the duplicated field” for behavior wiring and layout syncing:

    makeDraggable( replaceWith.get( 0 ), '.frm-move' );
    ...
    setLayoutClassesForDuplicatedFieldInGroup( $field.get( 0 ), replaceWith.get( 0 ) );

    and similarly in the other branches.

For divider cases, getLiElement( replaceWith ) returns an inner <li> that is actually appended, while replaceWith.get( 0 ) remains a detached wrapper. That means:

  • makeDraggable is wired to an element that’s not in the DOM, leaving the real duplicated divider non‑draggable.
  • setLayoutClassesForDuplicatedFieldInGroup receives a node that isn’t the inserted divider, so layout syncing for field groups can still be off — the exact problem this PR is trying to solve.
    (This matches the previous review’s concern about using the actually appended node, just now via getLiElement.)

Additionally, the new layout-class copy logic:

const layoutClass = getLayoutClassName( $field.get(0).classList );
if ( ! newField.get( 0 ).classList.contains( layoutClass ) ) {
	newField.get( 0 ).classList.add( layoutClass );
}

has two problems:

  1. Empty layout class → DOMException: getLayoutClassName returns '' when no layout class exists. Calling classList.contains( '' ) or classList.add( '' ) throws, so duplicating a field with no layout class will raise at runtime.
  2. ESLint spacing: $field.get(0) violates the space-in-parens rule (get( 0 ) is the local convention and what ESLint is complaining about).

Concrete changes to consider:

  • Track and use the inserted element (from getLiElement) consistently for drag/drop and layout syncing:

    • In each branch, after you append/insert newField, grab:

      const appendedEl = newField.get( 0 );
    • Use appendedEl for:

      • makeDraggable( appendedEl, '.frm-move' );
      • The setLayoutClassesForDuplicatedFieldInGroup call (both in the new‑row early‑return path and at the end of the success handler).
    • Avoid calling helpers on replaceWith.get( 0 ) when you didn’t actually insert replaceWith into the DOM for divider responses.

  • Harden the layout-class copy and fix spacing:

  • const layoutClass = getLayoutClassName( $field.get(0).classList );

  • if ( ! newField.get( 0 ).classList.contains( layoutClass ) ) {

  • newField.get( 0 ).classList.add( layoutClass );

  • }

  • const layoutClass = getLayoutClassName( $field.get( 0 ).classList );
  • const newFieldEl = newField.get( 0 );
  • if ( layoutClass && newFieldEl && ! newFieldEl.classList.contains( layoutClass ) ) {
  • newFieldEl.classList.add( layoutClass );
  • }
    
    

This should:

  • Ensure the draggable behavior and layout helper always operate on the real duplicated node the user sees.
  • Prevent a DOMException when duplicating fields that have no layout class.
  • Clear the ESLint space-in-parens error on this line.
🧹 Nitpick comments (1)
js/addons-page.js (1)

1-1: Addons bundle appears unchanged functionally (treat as generated).

This file looks like a rebuilt/minified bundle with no behavioral changes. I wouldn’t hand-edit it; any Biome noFunctionAssign/noUnsafeFinally warnings here are from transpiled helpers and are better handled by excluding js/addons-page.js (or js/** bundles) from linting rather than changing the code.

📜 Review details

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between cbbb847 and 204b212.

📒 Files selected for processing (15)
  • css/admin/frm-settings-components.css
  • css/frm_admin.css
  • css/frm_testing_mode.css
  • js/addons-page.js
  • js/form-templates.js
  • js/formidable-settings-components.js
  • js/formidable_admin.js
  • js/formidable_blocks.js
  • js/formidable_dashboard.js
  • js/formidable_overlay.js
  • js/formidable_styles.js
  • js/frm_testing_mode.js
  • js/onboarding-wizard.js
  • js/src/admin/admin.js
  • js/welcome-tour.js
🧰 Additional context used
🧬 Code graph analysis (5)
js/frm_testing_mode.js (1)
js/src/admin/upgrade-popup.js (1)
  • frmDom (3-3)
js/addons-page.js (2)
js/src/admin/addon-state.js (2)
  • a (198-198)
  • frmDom (3-3)
js/src/admin/upgrade-popup.js (1)
  • frmDom (3-3)
js/formidable-settings-components.js (1)
js/src/admin/upgrade-popup.js (1)
  • frmDom (3-3)
js/formidable_overlay.js (3)
js/src/admin/admin.js (41)
  • e (8296-8296)
  • t (718-718)
  • t (743-743)
  • t (9083-9083)
  • t (10274-10274)
  • frmDom (241-241)
  • frmDom (242-242)
  • frmDom (243-243)
  • a (3115-3115)
  • i (440-440)
  • i (1798-1798)
  • i (2283-2283)
  • i (3052-3052)
  • i (3067-3067)
  • i (3139-3139)
  • i (3157-3157)
  • i (3171-3174)
  • i (3197-3205)
  • i (3235-3235)
  • i (3244-3244)
  • i (3505-3511)
  • i (3647-3650)
  • i (5497-5497)
  • i (5566-5567)
  • i (5641-5643)
  • c (723-723)
  • c (748-748)
  • c (7334-7334)
  • c (9159-9159)
  • s (276-276)
  • s (8302-8302)
  • s (9059-9059)
  • s (9136-9136)
  • f (9098-9098)
  • v (3411-3411)
  • v (3431-3431)
  • v (6966-6966)
  • v (7338-7338)
  • v (7889-7889)
  • v (7905-7905)
  • v (7921-7921)
js/src/admin/upgrade-popup.js (1)
  • frmDom (3-3)
js/src/admin/addon-state.js (2)
  • frmDom (3-3)
  • a (198-198)
js/welcome-tour.js (1)
js/src/welcome-tour/ui/spotlight.js (1)
  • getComputedStyle (123-123)
🪛 Biome (2.1.2)
js/frm_testing_mode.js

[error] 2-2: This case is falling through to the next case.

Add a break or return statement to the end of this case to prevent fallthrough.

(lint/suspicious/noFallthroughSwitchClause)


[error] 2-2: Do not use the t variable name as a label

The variable is declared here

Creating a label with the same name as an in-scope variable leads to confusion.

(lint/suspicious/noLabelVar)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

css/frm_testing_mode.css

[error] 3-3: Unexpected shorthand property background after background-color

(lint/suspicious/noShorthandPropertyOverrides)


[error] 3-3: Duplicate properties can lead to unexpected behavior and may override previous declarations unintentionally.

text-align is already defined here.

Remove or rename the duplicate property to ensure consistent styling.

(lint/suspicious/noDuplicateProperties)


[error] 3-3: Duplicate properties can lead to unexpected behavior and may override previous declarations unintentionally.

min-width is already defined here.

Remove or rename the duplicate property to ensure consistent styling.

(lint/suspicious/noDuplicateProperties)


[error] 3-3: Duplicate properties can lead to unexpected behavior and may override previous declarations unintentionally.

border-radius is already defined here.

Remove or rename the duplicate property to ensure consistent styling.

(lint/suspicious/noDuplicateProperties)

js/addons-page.js

[error] 1-1: Unsafe usage of 'throw'.

'throw' in 'finally' overwrites the control flow statements inside 'try' and 'catch'.

(lint/correctness/noUnsafeFinally)


[error] 1-1: Unsafe usage of 'return'.

'return' in 'finally' overwrites the control flow statements inside 'try' and 'catch'.

(lint/correctness/noUnsafeFinally)


[error] 1-1: Unsafe usage of 'throw'.

'throw' in 'finally' overwrites the control flow statements inside 'try' and 'catch'.

(lint/correctness/noUnsafeFinally)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: Do not use the t variable name as a label

The variable is declared here

Creating a label with the same name as an in-scope variable leads to confusion.

(lint/suspicious/noLabelVar)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

js/formidable-settings-components.js

[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

js/formidable_blocks.js

[error] 1-1: Unsafe usage of 'return'.

'return' in 'finally' overwrites the control flow statements inside 'try' and 'catch'.

(lint/correctness/noUnsafeFinally)


[error] 1-1: Unsafe usage of 'throw'.

'throw' in 'finally' overwrites the control flow statements inside 'try' and 'catch'.

(lint/correctness/noUnsafeFinally)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

js/formidable_dashboard.js

[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

js/formidable_overlay.js

[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

js/formidable_styles.js

[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: Do not use the t variable name as a label

The variable is declared here

Creating a label with the same name as an in-scope variable leads to confusion.

(lint/suspicious/noLabelVar)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

js/onboarding-wizard.js

[error] 2-2: This case is falling through to the next case.

Add a break or return statement to the end of this case to prevent fallthrough.

(lint/suspicious/noFallthroughSwitchClause)


[error] 2-2: Unsafe usage of 'throw'.

'throw' in 'finally' overwrites the control flow statements inside 'try' and 'catch'.

(lint/correctness/noUnsafeFinally)


[error] 2-2: This case is falling through to the next case.

Add a break or return statement to the end of this case to prevent fallthrough.

(lint/suspicious/noFallthroughSwitchClause)


[error] 2-2: This case is falling through to the next case.

Add a break or return statement to the end of this case to prevent fallthrough.

(lint/suspicious/noFallthroughSwitchClause)


[error] 2-2: This case is falling through to the next case.

Add a break or return statement to the end of this case to prevent fallthrough.

(lint/suspicious/noFallthroughSwitchClause)


[error] 2-2: This case is falling through to the next case.

Add a break or return statement to the end of this case to prevent fallthrough.

(lint/suspicious/noFallthroughSwitchClause)


[error] 2-2: This case is falling through to the next case.

Add a break or return statement to the end of this case to prevent fallthrough.

(lint/suspicious/noFallthroughSwitchClause)


[error] 2-2: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 2-2: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 2-2: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 2-2: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 2-2: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 2-2: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 2-2: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

js/welcome-tour.js

[error] 2-2: This case is falling through to the next case.

Add a break or return statement to the end of this case to prevent fallthrough.

(lint/suspicious/noFallthroughSwitchClause)


[error] 2-2: This case is falling through to the next case.

Add a break or return statement to the end of this case to prevent fallthrough.

(lint/suspicious/noFallthroughSwitchClause)


[error] 2-2: Do not use the t variable name as a label

The variable is declared here

Creating a label with the same name as an in-scope variable leads to confusion.

(lint/suspicious/noLabelVar)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 2-2: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

🪛 GitHub Check: Run ESLint
js/src/admin/admin.js

[failure] 2390-2390:
There must be a space before this paren


[failure] 2390-2390:
There must be a space after this paren


[failure] 6815-6815:
There must be a space before this paren


[failure] 6815-6815:
There must be a space after this paren

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (3)
  • GitHub Check: Cypress
  • GitHub Check: PHP 7.4 tests in WP 6.9
  • GitHub Check: PHP 8 tests in WP 6.9
🔇 Additional comments (5)
js/onboarding-wizard.js (1)

2-2: Onboarding wizard bundle: behavior appears unchanged; no issues spotted.

Given this is a rebuilt/minified asset and the control flow matches the previous wizard logic, I don’t see new runtime risks in this change.

css/frm_testing_mode.css (1)

3-3: Tooltip license/comment tweak is safe; no behavioral change.

The updated /* Bootstrap v4.6.1 */ comment/line wrapping doesn’t alter the .tooltip rules or any testing‑mode styles. No action needed beyond this formatting.

css/admin/frm-settings-components.css (1)

1-1: The .js suffix requirement is isolated to a single selector, not universal.

Only one CSS selector in the file requires the .js class (.formidable_page_formidable-styles.js .control-section .accordion-section-title:focus), while all other selectors use .formidable_page_formidable-styles without the suffix. Additionally, WordPress automatically adds the .js class to the document root when JavaScript is enabled, so this is standard behavior rather than a breaking change.

Likely an incorrect or invalid review comment.

js/frm_testing_mode.js (1)

2-2: The review comment cannot be verified. While the code does show operator implementations like "/":function(t,e){return t/e}, there is no git history to confirm a reversal from a previous version, no test files to validate actual failures, and no evidence this represents a recent change. The implementation appears mathematically sound for a stack-based RPN evaluator. Either provide test cases demonstrating the calculation failures, or compare against a previous version of the code.

js/formidable_blocks.js (1)

1-1: This is a bundled script loaded as a WordPress admin script, not an ES module. The minified file shows webpack-generated code with side-effect imports registering WordPress blocks. The export name change (A → Ay) is a normal minification artifact with no breaking impact because:

  1. The script is enqueued as a script tag (not imported by name) via FrmSimpleBlocksController.php
  2. No code in the repository imports or references the export by name
  3. The source files (js/src/blocks.js and related modules) contain only side-effect imports and block registrations—no named exports meant for external consumption

Minifying generated bundles is expected; reviewing changes at this level adds limited value. The actual functionality is preserved.

Comment thread js/formidable_styles.js Outdated
@@ -1 +1 @@
(()=>{var t={8616:t=>{t.exports=function(t,e){var n,r,i=0;function o(){var o,s,a=n,c=arguments.length;t:for(;a;){if(a.args.length===arguments.length){for(s=0;s<c;s++)if(a.args[s]!==arguments[s]){a=a.next;continue t}return a!==n&&(a===r&&(r=a.prev),a.prev.next=a.next,a.next&&(a.next.prev=a.prev),a.next=n,a.prev=null,n.prev=a,n=a),a.val}a=a.next}for(o=new Array(c),s=0;s<c;s++)o[s]=arguments[s];return a={args:o,val:t.apply(null,o)},n?(n.prev=a,a.next=n):r=a,i===e.maxSize?(r=r.prev).next=null:i++,n=a,a.val}return e=e||{},o.clear=function(){n=null,r=null,i=0},o}},7604:(t,e,n)=>{var r;!function(){"use strict";var i={not_string:/[^s]/,not_bool:/[^t]/,not_type:/[^T]/,not_primitive:/[^v]/,number:/[diefg]/,numeric_arg:/[bcdiefguxX]/,json:/[j]/,not_json:/[^j]/,text:/^[^\x25]+/,modulo:/^\x25{2}/,placeholder:/^\x25(?:([1-9]\d*)\$|\(([^)]+)\))?(\+)?(0|'[^$])?(-)?(\d+)?(?:\.(\d+))?([b-gijostTuvxX])/,key:/^([a-z_][a-z_\d]*)/i,key_access:/^\.([a-z_][a-z_\d]*)/i,index_access:/^\[(\d+)\]/,sign:/^[+-]/};function o(t){return function(t,e){var n,r,s,a,c,l,u,f,p,d=1,h=t.length,y="";for(r=0;r<h;r++)if("string"==typeof t[r])y+=t[r];else if("object"==typeof t[r]){if((a=t[r]).keys)for(n=e[d],s=0;s<a.keys.length;s++){if(null==n)throw new Error(o('[sprintf] Cannot access property "%s" of undefined value "%s"',a.keys[s],a.keys[s-1]));n=n[a.keys[s]]}else n=a.param_no?e[a.param_no]:e[d++];if(i.not_type.test(a.type)&&i.not_primitive.test(a.type)&&n instanceof Function&&(n=n()),i.numeric_arg.test(a.type)&&"number"!=typeof n&&isNaN(n))throw new TypeError(o("[sprintf] expecting number but found %T",n));switch(i.number.test(a.type)&&(f=n>=0),a.type){case"b":n=parseInt(n,10).toString(2);break;case"c":n=String.fromCharCode(parseInt(n,10));break;case"d":case"i":n=parseInt(n,10);break;case"j":n=JSON.stringify(n,null,a.width?parseInt(a.width):0);break;case"e":n=a.precision?parseFloat(n).toExponential(a.precision):parseFloat(n).toExponential();break;case"f":n=a.precision?parseFloat(n).toFixed(a.precision):parseFloat(n);break;case"g":n=a.precision?String(Number(n.toPrecision(a.precision))):parseFloat(n);break;case"o":n=(parseInt(n,10)>>>0).toString(8);break;case"s":n=String(n),n=a.precision?n.substring(0,a.precision):n;break;case"t":n=String(!!n),n=a.precision?n.substring(0,a.precision):n;break;case"T":n=Object.prototype.toString.call(n).slice(8,-1).toLowerCase(),n=a.precision?n.substring(0,a.precision):n;break;case"u":n=parseInt(n,10)>>>0;break;case"v":n=n.valueOf(),n=a.precision?n.substring(0,a.precision):n;break;case"x":n=(parseInt(n,10)>>>0).toString(16);break;case"X":n=(parseInt(n,10)>>>0).toString(16).toUpperCase()}i.json.test(a.type)?y+=n:(!i.number.test(a.type)||f&&!a.sign?p="":(p=f?"+":"-",n=n.toString().replace(i.sign,"")),l=a.pad_char?"0"===a.pad_char?"0":a.pad_char.charAt(1):" ",u=a.width-(p+n).length,c=a.width&&u>0?l.repeat(u):"",y+=a.align?p+n+c:"0"===l?p+c+n:c+p+n)}return y}(function(t){if(a[t])return a[t];for(var e,n=t,r=[],o=0;n;){if(null!==(e=i.text.exec(n)))r.push(e[0]);else if(null!==(e=i.modulo.exec(n)))r.push("%");else{if(null===(e=i.placeholder.exec(n)))throw new SyntaxError("[sprintf] unexpected placeholder");if(e[2]){o|=1;var s=[],c=e[2],l=[];if(null===(l=i.key.exec(c)))throw new SyntaxError("[sprintf] failed to parse named argument key");for(s.push(l[1]);""!==(c=c.substring(l[0].length));)if(null!==(l=i.key_access.exec(c)))s.push(l[1]);else{if(null===(l=i.index_access.exec(c)))throw new SyntaxError("[sprintf] failed to parse named argument key");s.push(l[1])}e[2]=s}else o|=2;if(3===o)throw new Error("[sprintf] mixing positional and named placeholders is not (yet) supported");r.push({placeholder:e[0],param_no:e[1],keys:e[2],sign:e[3],pad_char:e[4],align:e[5],width:e[6],precision:e[7],type:e[8]})}n=n.substring(e[0].length)}return a[t]=r}(t),arguments)}function s(t,e){return o.apply(null,[t].concat(e||[]))}var a=Object.create(null);"undefined"!=typeof window&&(window.sprintf=o,window.vsprintf=s,void 0===(r=function(){return{sprintf:o,vsprintf:s}}.call(e,n,e,t))||(t.exports=r))}()}},e={};function n(r){var i=e[r];if(void 0!==i)return i.exports;var o=e[r]={exports:{}};return t[r](o,o.exports,n),o.exports}n.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return n.d(e,{a:e}),e},n.d=(t,e)=>{for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),(()=>{"use strict";var t,e,r,i,o=n(8616),s=n.n(o);function a(t){return a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},a(t)}function c(t){var e=function(t){if("object"!=a(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=a(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==a(e)?e:e+""}n(7604),s()(console.error),t={"(":9,"!":8,"*":7,"/":7,"%":7,"+":6,"-":6,"<":5,"<=":5,">":5,">=":5,"==":4,"!=":4,"&&":3,"||":2,"?":1,"?:":1},e=["(","?"],r={")":["("],":":["?","?:"]},i=/<=|>=|==|!=|&&|\|\||\?:|\(|!|\*|\/|%|\+|-|<|>|\?|\)|:/;var l={"!":function(t){return!t},"*":function(t,e){return t*e},"/":function(t,e){return t/e},"%":function(t,e){return t%e},"+":function(t,e){return t+e},"-":function(t,e){return t-e},"<":function(t,e){return t<e},"<=":function(t,e){return t<=e},">":function(t,e){return t>e},">=":function(t,e){return t>=e},"==":function(t,e){return t===e},"!=":function(t,e){return t!==e},"&&":function(t,e){return t&&e},"||":function(t,e){return t||e},"?:":function(t,e,n){if(t)throw e;return n}};var u={contextDelimiter:"",onMissingKey:null};function f(t,e){var n;for(n in this.data=t,this.pluralForms={},this.options={},u)this.options[n]=void 0!==e&&n in e?e[n]:u[n]}function p(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),n.push.apply(n,r)}return n}function d(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?p(Object(n),!0).forEach(function(e){var r,i,o;r=t,i=e,o=n[e],(i=c(i))in r?Object.defineProperty(r,i,{value:o,enumerable:!0,configurable:!0,writable:!0}):r[i]=o}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):p(Object(n)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))})}return t}f.prototype.getPluralForm=function(n,o){var s,a,c,u,f=this.pluralForms[n];return f||("function"!=typeof(c=(s=this.data[n][""])["Plural-Forms"]||s["plural-forms"]||s.plural_forms)&&(a=function(t){var e,n,r;for(e=t.split(";"),n=0;n<e.length;n++)if(0===(r=e[n].trim()).indexOf("plural="))return r.substr(7)}(s["Plural-Forms"]||s["plural-forms"]||s.plural_forms),u=function(n){var o=function(n){for(var o,s,a,c,l=[],u=[];o=n.match(i);){for(s=o[0],(a=n.substr(0,o.index).trim())&&l.push(a);c=u.pop();){if(r[s]){if(r[s][0]===c){s=r[s][1]||s;break}}else if(e.indexOf(c)>=0||t[c]<t[s]){u.push(c);break}l.push(c)}r[s]||u.push(s),n=n.substr(o.index+s.length)}return(n=n.trim())&&l.push(n),l.concat(u.reverse())}(n);return function(t){return function(t,e){var n,r,i,o,s,a,c=[];for(n=0;n<t.length;n++){if(s=t[n],o=l[s]){for(r=o.length,i=Array(r);r--;)i[r]=c.pop();try{a=o.apply(null,i)}catch(t){return t}}else a=e.hasOwnProperty(s)?e[s]:+s;c.push(a)}return c[0]}(o,t)}}(a),c=function(t){return+u({n:t})}),f=this.pluralForms[n]=c),f(o)},f.prototype.dcnpgettext=function(t,e,n,r,i){var o,s,a;return o=void 0===i?0:this.getPluralForm(t,i),s=n,e&&(s=e+this.options.contextDelimiter+n),(a=this.data[t][s])&&a[o]?a[o]:(this.options.onMissingKey&&this.options.onMissingKey(n,t),0===o?n:r)};var h={"":{plural_forms:function(t){return 1===t?0:1}}},y=/^i18n\.(n?gettext|has_translation)(_|$)/;const m=function(t){return"string"!=typeof t||""===t?(console.error("The namespace must be a non-empty string."),!1):!!/^[a-zA-Z][a-zA-Z0-9_.\-\/]*$/.test(t)||(console.error("The namespace can only contain numbers, letters, dashes, periods, underscores and slashes."),!1)},v=function(t){return"string"!=typeof t||""===t?(console.error("The hook name must be a non-empty string."),!1):/^__/.test(t)?(console.error("The hook name cannot begin with `__`."),!1):!!/^[a-zA-Z][a-zA-Z0-9_.-]*$/.test(t)||(console.error("The hook name can only contain numbers, letters, dashes, periods and underscores."),!1)},g=function(t,e){return function(n,r,i){var o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:10,s=t[e];if(v(n)&&m(r))if("function"==typeof i)if("number"==typeof o){var a={callback:i,priority:o,namespace:r};if(s[n]){var c,l=s[n].handlers;for(c=l.length;c>0&&!(o>=l[c-1].priority);c--);c===l.length?l[c]=a:l.splice(c,0,a),s.__current.forEach(function(t){t.name===n&&t.currentIndex>=c&&t.currentIndex++})}else s[n]={handlers:[a],runs:0};"hookAdded"!==n&&t.doAction("hookAdded",n,r,i,o)}else console.error("If specified, the hook priority must be a number.");else console.error("The hook callback must be a function.")}},b=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(r,i){var o=t[e];if(v(r)&&(n||m(i))){if(!o[r])return 0;var s=0;if(n)s=o[r].handlers.length,o[r]={runs:o[r].runs,handlers:[]};else for(var a=o[r].handlers,c=function(t){a[t].namespace===i&&(a.splice(t,1),s++,o.__current.forEach(function(e){e.name===r&&e.currentIndex>=t&&e.currentIndex--}))},l=a.length-1;l>=0;l--)c(l);return"hookRemoved"!==r&&t.doAction("hookRemoved",r,i),s}}},_=function(t,e){return function(n,r){var i=t[e];return void 0!==r?n in i&&i[n].handlers.some(function(t){return t.namespace===r}):n in i}},x=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(r){var i=t[e];i[r]||(i[r]={handlers:[],runs:0}),i[r].runs++;for(var o=i[r].handlers,s=arguments.length,a=new Array(s>1?s-1:0),c=1;c<s;c++)a[c-1]=arguments[c];if(!o||!o.length)return n?a[0]:void 0;var l={name:r,currentIndex:0};for(i.__current.push(l);l.currentIndex<o.length;){var u=o[l.currentIndex].callback.apply(null,a);n&&(a[0]=u),l.currentIndex++}return i.__current.pop(),n?a[0]:void 0}},w=function(t,e){return function(){var n,r,i=t[e];return null!==(n=null===(r=i.__current[i.__current.length-1])||void 0===r?void 0:r.name)&&void 0!==n?n:null}},S=function(t,e){return function(n){var r=t[e];return void 0===n?void 0!==r.__current[0]:!!r.__current[0]&&n===r.__current[0].name}},k=function(t,e){return function(n){var r=t[e];if(v(n))return r[n]&&r[n].runs?r[n].runs:0}};var E=new function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.actions=Object.create(null),this.actions.__current=[],this.filters=Object.create(null),this.filters.__current=[],this.addAction=g(this,"actions"),this.addFilter=g(this,"filters"),this.removeAction=b(this,"actions"),this.removeFilter=b(this,"filters"),this.hasAction=_(this,"actions"),this.hasFilter=_(this,"filters"),this.removeAllActions=b(this,"actions",!0),this.removeAllFilters=b(this,"filters",!0),this.doAction=x(this,"actions"),this.applyFilters=x(this,"filters",!0),this.currentAction=w(this,"actions"),this.currentFilter=w(this,"filters"),this.doingAction=S(this,"actions"),this.doingFilter=S(this,"filters"),this.didAction=k(this,"actions"),this.didFilter=k(this,"filters")},C=(E.addAction,E.addFilter,E.removeAction,E.removeFilter,E.hasAction,E.hasFilter,E.removeAllActions,E.removeAllFilters,E.doAction,E.applyFilters,E.currentAction,E.currentFilter,E.doingAction,E.doingFilter,E.didAction,E.didFilter,E.actions,E.filters,function(t,e,n){var r=new f({}),i=new Set,o=function(){i.forEach(function(t){return t()})},s=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"default";r.data[e]=d(d(d({},h),r.data[e]),t),r.data[e][""]=d(d({},h[""]),r.data[e][""])},a=function(t,e){s(t,e),o()},c=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default",e=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0,i=arguments.length>3?arguments[3]:void 0,o=arguments.length>4?arguments[4]:void 0;return r.data[t]||s(void 0,t),r.dcnpgettext(t,e,n,i,o)},l=function(){return arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default"},u=function(t,e,r){var i=c(r,e,t);return n?(i=n.applyFilters("i18n.gettext_with_context",i,t,e,r),n.applyFilters("i18n.gettext_with_context_"+l(r),i,t,e,r)):i};if(n){var p=function(t){y.test(t)&&o()};n.addAction("hookAdded","core/i18n",p),n.addAction("hookRemoved","core/i18n",p)}return{getLocaleData:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default";return r.data[t]},setLocaleData:a,resetLocaleData:function(t,e){r.data={},r.pluralForms={},a(t,e)},subscribe:function(t){return i.add(t),function(){return i.delete(t)}},__:function(t,e){var r=c(e,void 0,t);return n?(r=n.applyFilters("i18n.gettext",r,t,e),n.applyFilters("i18n.gettext_"+l(e),r,t,e)):r},_x:u,_n:function(t,e,r,i){var o=c(i,void 0,t,e,r);return n?(o=n.applyFilters("i18n.ngettext",o,t,e,r,i),n.applyFilters("i18n.ngettext_"+l(i),o,t,e,r,i)):o},_nx:function(t,e,r,i,o){var s=c(o,i,t,e,r);return n?(s=n.applyFilters("i18n.ngettext_with_context",s,t,e,r,i,o),n.applyFilters("i18n.ngettext_with_context_"+l(o),s,t,e,r,i,o)):s},isRTL:function(){return"rtl"===u("ltr","text direction")},hasTranslation:function(t,e,i){var o,s,a=e?e+""+t:t,c=!(null===(o=r.data)||void 0===o||null===(s=o[null!=i?i:"default"])||void 0===s||!s[a]);return n&&(c=n.applyFilters("i18n.has_translation",c,t,e,i),c=n.applyFilters("i18n.has_translation_"+l(i),c,t,e,i)),c}}}(0,0,E));C.getLocaleData.bind(C),C.setLocaleData.bind(C),C.resetLocaleData.bind(C),C.subscribe.bind(C);var A=C.__.bind(C);function O(t){return O="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},O(t)}function F(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,I(r.key),r)}}function I(t){var e=function(t){if("object"!=O(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=O(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==O(e)?e:e+""}C._x.bind(C),C._n.bind(C),C._nx.bind(C),C.isRTL.bind(C),C.hasTranslation.bind(C);var j=function(){return t=function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.component=e;try{var n=JSON.parse(this.component.dataset.willChange);this.data={propagateInputs:this.initPropagationList(n),changeEvent:new Event("change",{bubbles:!0})}}catch(t){console.error('Error parsing JSON data from "will-change" attribute.',t)}},(e=[{key:"initPropagationList",value:function(t){var e=[];return t.forEach(function(t){var n=document.querySelector('input[name="'.concat(t,'"]'));null!==n&&e.push(n)}),e}},{key:"updateAllDependentElements",value:function(t){this.data.propagateInputs.forEach(function(e){e.value=t}),this.data.propagateInputs[0].dispatchEvent(this.data.changeEvent)}}])&&F(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function T(t){return T="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},T(t)}function P(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,L(r.key),r)}}function L(t){var e=function(t){if("object"!=T(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=T(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==T(e)?e:e+""}new(function(){return t=function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.success=frmDom.success,this.cssEditorInstance=null,this.cssInlineStyleElement=null,this.cssEditorOptions={retryLimit:5,retryInterval:500,retryCount:0},this.init(),this.initHover(),this.initCustomCSSEditorInstance()},(e=[{key:"init",value:function(){this.initColorPickerDependentUpdaterComponents(),this.initStyleClassCopyToClipboard(A("The class name has been copied.","formidable")),this.toggleVisibilityOfCustomCSSEditor()}},{key:"initCustomCSSEditorInstance",value:function(){var t=this;null!==this.cssEditorInstance||this.cssEditorOptions.retryCount>=this.cssEditorOptions.retryLimit||(void 0!==window.frm_single_style_custom_css_wp_editor&&void 0!==window.frm_single_style_custom_css_wp_editor.codemirror?(this.cssEditorInstance=window.frm_single_style_custom_css_wp_editor.codemirror,this.onCssEditorReady()):setTimeout(function(){t.cssEditorOptions.retryCount++,t.initCustomCSSEditorInstance()},500))}},{key:"getInlineStyleElement",value:function(){return null!==this.cssInlineStyleElement||(this.cssInlineStyleElement=document.createElement("style"),document.head.appendChild(this.cssInlineStyleElement)),this.cssInlineStyleElement}},{key:"onCssEditorReady",value:function(){var t,e=this,n=null===(t=document.getElementById("frm_style_class_custom_css"))||void 0===t||null===(t=t.dataset)||void 0===t?void 0:t.cssScope;if(null!==n){var r=CSS.escape(n);this.cssEditorInstance.on("change",function(t){var n=t.getValue().replace(/<[^>]*>/g,"").trim();e.getInlineStyleElement().textContent=".".concat(r," { ").concat(n," }")})}}},{key:"initColorPickerDependentUpdaterComponents",value:function(){var t=document.querySelectorAll(".frm-style-dependent-updater-component.frm-colorpicker"),e=[];t.forEach(function(t){var n=t.querySelector("input.hex"),r=void 0!==n?n.getAttribute("id"):null;null!==r&&e.push({id:r,dependentUpdaterClass:new j(t,"colorpicker")})}),wp.hooks.addAction("frm_style_options_color_change","formidable",function(t){var n=t.event,r=t.value,i=n.target.closest(".wp-picker-container"),o=n.target.getAttribute("id");i.querySelector(".wp-color-result-text").innerText=r,e.forEach(function(t){t.id===o&&t.dependentUpdaterClass.updateAllDependentElements(r)})})}},{key:"initHover",value:function(){var t=document.querySelector(".frm-right-panel .styling_settings .accordion-container");if(null!==t){var e=document.createElement("div");e.classList.add("frm_hidden"),e.classList.add("frm-style-settings-hover"),t.appendChild(e),t.querySelector(":scope > ul").querySelectorAll(":scope > li").forEach(function(t){t.querySelector("h3").addEventListener("mouseover",function(t){e.style.transform="translateY(".concat(t.target.closest("li").offsetTop,"px)"),e.classList.add("frm-animating"),e.classList.remove("frm_hidden"),setTimeout(function(){e.classList.remove("frm-animating")},250)})}),document.querySelectorAll("#frm_style_sidebar .accordion-section h3").forEach(function(t){t.addEventListener("click",function(){e.classList.add("frm_hidden")})})}}},{key:"initStyleClassCopyToClipboard",value:function(t){var e=this;document.querySelectorAll(".frm-copy-text").forEach(function(n){n.addEventListener("click",function(n){var r=n.currentTarget.innerText;navigator.clipboard&&navigator.clipboard.writeText?navigator.clipboard.writeText(r).then(function(){e.success(t)}):!0===e.fallbackCopyToClipboard(r,n.currentTarget)&&e.success(t)})})}},{key:"toggleVisibilityOfCustomCSSEditor",value:function(){var t=document.getElementById("frm_enable_single_style_custom_css"),e=document.getElementById("frm_single_style_custom_css_editor");t&&e&&t.addEventListener("change",function(t){e.classList.toggle("frm_hidden",!t.target.checked)})}},{key:"fallbackCopyToClipboard",value:function(t,e){if("function"!=typeof document.execCommand)return!1;var n,r=document.createElement("input");r.setAttribute("type","text"),r.value=t,e.parentElement.appendChild(r),r.focus(),r.select(),r.setSelectionRange(0,99999),r.style.position="absolute",r.style.left="-9999px",r.style.top="-9999px";try{n=document.execCommand("copy")}catch(t){n=!1}return r.remove(),n}}])&&P(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}())})()})(); No newline at end of file
(()=>{var t={8616:t=>{t.exports=function(t,e){var n,r,i=0;function o(){var o,s,a=n,c=arguments.length;t:for(;a;){if(a.args.length===arguments.length){for(s=0;s<c;s++)if(a.args[s]!==arguments[s]){a=a.next;continue t}return a!==n&&(a===r&&(r=a.prev),a.prev.next=a.next,a.next&&(a.next.prev=a.prev),a.next=n,a.prev=null,n.prev=a,n=a),a.val}a=a.next}for(o=new Array(c),s=0;s<c;s++)o[s]=arguments[s];return a={args:o,val:t.apply(null,o)},n?(n.prev=a,a.next=n):r=a,i===e.maxSize?(r=r.prev).next=null:i++,n=a,a.val}return e=e||{},o.clear=function(){n=null,r=null,i=0},o}},7604:(t,e,n)=>{var r;!function(){"use strict";var i={not_string:/[^s]/,not_bool:/[^t]/,not_type:/[^T]/,not_primitive:/[^v]/,number:/[diefg]/,numeric_arg:/[bcdiefguxX]/,json:/[j]/,not_json:/[^j]/,text:/^[^\x25]+/,modulo:/^\x25{2}/,placeholder:/^\x25(?:([1-9]\d*)\$|\(([^)]+)\))?(\+)?(0|'[^$])?(-)?(\d+)?(?:\.(\d+))?([b-gijostTuvxX])/,key:/^([a-z_][a-z_\d]*)/i,key_access:/^\.([a-z_][a-z_\d]*)/i,index_access:/^\[(\d+)\]/,sign:/^[+-]/};function o(t){return function(t,e){var n,r,s,a,c,l,u,f,p,d=1,h=t.length,y="";for(r=0;r<h;r++)if("string"==typeof t[r])y+=t[r];else if("object"==typeof t[r]){if((a=t[r]).keys)for(n=e[d],s=0;s<a.keys.length;s++){if(null==n)throw new Error(o('[sprintf] Cannot access property "%s" of undefined value "%s"',a.keys[s],a.keys[s-1]));n=n[a.keys[s]]}else n=a.param_no?e[a.param_no]:e[d++];if(i.not_type.test(a.type)&&i.not_primitive.test(a.type)&&n instanceof Function&&(n=n()),i.numeric_arg.test(a.type)&&"number"!=typeof n&&isNaN(n))throw new TypeError(o("[sprintf] expecting number but found %T",n));switch(i.number.test(a.type)&&(f=n>=0),a.type){case"b":n=parseInt(n,10).toString(2);break;case"c":n=String.fromCharCode(parseInt(n,10));break;case"d":case"i":n=parseInt(n,10);break;case"j":n=JSON.stringify(n,null,a.width?parseInt(a.width):0);break;case"e":n=a.precision?parseFloat(n).toExponential(a.precision):parseFloat(n).toExponential();break;case"f":n=a.precision?parseFloat(n).toFixed(a.precision):parseFloat(n);break;case"g":n=a.precision?String(Number(n.toPrecision(a.precision))):parseFloat(n);break;case"o":n=(parseInt(n,10)>>>0).toString(8);break;case"s":n=String(n),n=a.precision?n.substring(0,a.precision):n;break;case"t":n=String(!!n),n=a.precision?n.substring(0,a.precision):n;break;case"T":n=Object.prototype.toString.call(n).slice(8,-1).toLowerCase(),n=a.precision?n.substring(0,a.precision):n;break;case"u":n=parseInt(n,10)>>>0;break;case"v":n=n.valueOf(),n=a.precision?n.substring(0,a.precision):n;break;case"x":n=(parseInt(n,10)>>>0).toString(16);break;case"X":n=(parseInt(n,10)>>>0).toString(16).toUpperCase()}i.json.test(a.type)?y+=n:(!i.number.test(a.type)||f&&!a.sign?p="":(p=f?"+":"-",n=n.toString().replace(i.sign,"")),l=a.pad_char?"0"===a.pad_char?"0":a.pad_char.charAt(1):" ",u=a.width-(p+n).length,c=a.width&&u>0?l.repeat(u):"",y+=a.align?p+n+c:"0"===l?p+c+n:c+p+n)}return y}(function(t){if(a[t])return a[t];for(var e,n=t,r=[],o=0;n;){if(null!==(e=i.text.exec(n)))r.push(e[0]);else if(null!==(e=i.modulo.exec(n)))r.push("%");else{if(null===(e=i.placeholder.exec(n)))throw new SyntaxError("[sprintf] unexpected placeholder");if(e[2]){o|=1;var s=[],c=e[2],l=[];if(null===(l=i.key.exec(c)))throw new SyntaxError("[sprintf] failed to parse named argument key");for(s.push(l[1]);""!==(c=c.substring(l[0].length));)if(null!==(l=i.key_access.exec(c)))s.push(l[1]);else{if(null===(l=i.index_access.exec(c)))throw new SyntaxError("[sprintf] failed to parse named argument key");s.push(l[1])}e[2]=s}else o|=2;if(3===o)throw new Error("[sprintf] mixing positional and named placeholders is not (yet) supported");r.push({placeholder:e[0],param_no:e[1],keys:e[2],sign:e[3],pad_char:e[4],align:e[5],width:e[6],precision:e[7],type:e[8]})}n=n.substring(e[0].length)}return a[t]=r}(t),arguments)}function s(t,e){return o.apply(null,[t].concat(e||[]))}var a=Object.create(null);"undefined"!=typeof window&&(window.sprintf=o,window.vsprintf=s,void 0===(r=function(){return{sprintf:o,vsprintf:s}}.call(e,n,e,t))||(t.exports=r))}()}},e={};function n(r){var i=e[r];if(void 0!==i)return i.exports;var o=e[r]={exports:{}};return t[r](o,o.exports,n),o.exports}n.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return n.d(e,{a:e}),e},n.d=(t,e)=>{for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),(()=>{"use strict";var t,e,r,i,o=n(8616),s=n.n(o);function a(t){return a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},a(t)}function c(t){var e=function(t){if("object"!=a(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=a(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==a(e)?e:e+""}n(7604),s()(console.error),t={"(":9,"!":8,"*":7,"/":7,"%":7,"+":6,"-":6,"<":5,"<=":5,">":5,">=":5,"==":4,"!=":4,"&&":3,"||":2,"?":1,"?:":1},e=["(","?"],r={")":["("],":":["?","?:"]},i=/<=|>=|==|!=|&&|\|\||\?:|\(|!|\*|\/|%|\+|-|<|>|\?|\)|:/;var l={"!":function(t){return!t},"*":function(t,e){return t*e},"/":function(t,e){return t/e},"%":function(t,e){return t%e},"+":function(t,e){return t+e},"-":function(t,e){return t-e},"<":function(t,e){return t<e},"<=":function(t,e){return t<=e},">":function(t,e){return t>e},">=":function(t,e){return t>=e},"==":function(t,e){return t===e},"!=":function(t,e){return t!==e},"&&":function(t,e){return t&&e},"||":function(t,e){return t||e},"?:":function(t,e,n){if(t)throw e;return n}};var u={contextDelimiter:"",onMissingKey:null};function f(t,e){var n;for(n in this.data=t,this.pluralForms={},this.options={},u)this.options[n]=void 0!==e&&n in e?e[n]:u[n]}function p(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function d(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?p(Object(n),!0).forEach((function(e){var r,i,o;r=t,i=e,o=n[e],(i=c(i))in r?Object.defineProperty(r,i,{value:o,enumerable:!0,configurable:!0,writable:!0}):r[i]=o})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):p(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}f.prototype.getPluralForm=function(n,o){var s,a,c,u,f=this.pluralForms[n];return f||("function"!=typeof(c=(s=this.data[n][""])["Plural-Forms"]||s["plural-forms"]||s.plural_forms)&&(a=function(t){var e,n,r;for(e=t.split(";"),n=0;n<e.length;n++)if(0===(r=e[n].trim()).indexOf("plural="))return r.substr(7)}(s["Plural-Forms"]||s["plural-forms"]||s.plural_forms),u=function(n){var o=function(n){for(var o,s,a,c,l=[],u=[];o=n.match(i);){for(s=o[0],(a=n.substr(0,o.index).trim())&&l.push(a);c=u.pop();){if(r[s]){if(r[s][0]===c){s=r[s][1]||s;break}}else if(e.indexOf(c)>=0||t[c]<t[s]){u.push(c);break}l.push(c)}r[s]||u.push(s),n=n.substr(o.index+s.length)}return(n=n.trim())&&l.push(n),l.concat(u.reverse())}(n);return function(t){return function(t,e){var n,r,i,o,s,a,c=[];for(n=0;n<t.length;n++){if(s=t[n],o=l[s]){for(r=o.length,i=Array(r);r--;)i[r]=c.pop();try{a=o.apply(null,i)}catch(t){return t}}else a=e.hasOwnProperty(s)?e[s]:+s;c.push(a)}return c[0]}(o,t)}}(a),c=function(t){return+u({n:t})}),f=this.pluralForms[n]=c),f(o)},f.prototype.dcnpgettext=function(t,e,n,r,i){var o,s,a;return o=void 0===i?0:this.getPluralForm(t,i),s=n,e&&(s=e+this.options.contextDelimiter+n),(a=this.data[t][s])&&a[o]?a[o]:(this.options.onMissingKey&&this.options.onMissingKey(n,t),0===o?n:r)};var h={"":{plural_forms:function(t){return 1===t?0:1}}},y=/^i18n\.(n?gettext|has_translation)(_|$)/;const m=function(t){return"string"!=typeof t||""===t?(console.error("The namespace must be a non-empty string."),!1):!!/^[a-zA-Z][a-zA-Z0-9_.\-\/]*$/.test(t)||(console.error("The namespace can only contain numbers, letters, dashes, periods, underscores and slashes."),!1)},v=function(t){return"string"!=typeof t||""===t?(console.error("The hook name must be a non-empty string."),!1):/^__/.test(t)?(console.error("The hook name cannot begin with `__`."),!1):!!/^[a-zA-Z][a-zA-Z0-9_.-]*$/.test(t)||(console.error("The hook name can only contain numbers, letters, dashes, periods and underscores."),!1)},g=function(t,e){return function(n,r,i){var o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:10,s=t[e];if(v(n)&&m(r))if("function"==typeof i)if("number"==typeof o){var a={callback:i,priority:o,namespace:r};if(s[n]){var c,l=s[n].handlers;for(c=l.length;c>0&&!(o>=l[c-1].priority);c--);c===l.length?l[c]=a:l.splice(c,0,a),s.__current.forEach((function(t){t.name===n&&t.currentIndex>=c&&t.currentIndex++}))}else s[n]={handlers:[a],runs:0};"hookAdded"!==n&&t.doAction("hookAdded",n,r,i,o)}else console.error("If specified, the hook priority must be a number.");else console.error("The hook callback must be a function.")}},b=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(r,i){var o=t[e];if(v(r)&&(n||m(i))){if(!o[r])return 0;var s=0;if(n)s=o[r].handlers.length,o[r]={runs:o[r].runs,handlers:[]};else for(var a=o[r].handlers,c=function(t){a[t].namespace===i&&(a.splice(t,1),s++,o.__current.forEach((function(e){e.name===r&&e.currentIndex>=t&&e.currentIndex--})))},l=a.length-1;l>=0;l--)c(l);return"hookRemoved"!==r&&t.doAction("hookRemoved",r,i),s}}},_=function(t,e){return function(n,r){var i=t[e];return void 0!==r?n in i&&i[n].handlers.some((function(t){return t.namespace===r})):n in i}},x=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(r){var i=t[e];i[r]||(i[r]={handlers:[],runs:0}),i[r].runs++;for(var o=i[r].handlers,s=arguments.length,a=new Array(s>1?s-1:0),c=1;c<s;c++)a[c-1]=arguments[c];if(!o||!o.length)return n?a[0]:void 0;var l={name:r,currentIndex:0};for(i.__current.push(l);l.currentIndex<o.length;){var u=o[l.currentIndex].callback.apply(null,a);n&&(a[0]=u),l.currentIndex++}return i.__current.pop(),n?a[0]:void 0}},w=function(t,e){return function(){var n,r,i=t[e];return null!==(n=null===(r=i.__current[i.__current.length-1])||void 0===r?void 0:r.name)&&void 0!==n?n:null}},S=function(t,e){return function(n){var r=t[e];return void 0===n?void 0!==r.__current[0]:!!r.__current[0]&&n===r.__current[0].name}},k=function(t,e){return function(n){var r=t[e];if(v(n))return r[n]&&r[n].runs?r[n].runs:0}};var E=new function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.actions=Object.create(null),this.actions.__current=[],this.filters=Object.create(null),this.filters.__current=[],this.addAction=g(this,"actions"),this.addFilter=g(this,"filters"),this.removeAction=b(this,"actions"),this.removeFilter=b(this,"filters"),this.hasAction=_(this,"actions"),this.hasFilter=_(this,"filters"),this.removeAllActions=b(this,"actions",!0),this.removeAllFilters=b(this,"filters",!0),this.doAction=x(this,"actions"),this.applyFilters=x(this,"filters",!0),this.currentAction=w(this,"actions"),this.currentFilter=w(this,"filters"),this.doingAction=S(this,"actions"),this.doingFilter=S(this,"filters"),this.didAction=k(this,"actions"),this.didFilter=k(this,"filters")},C=(E.addAction,E.addFilter,E.removeAction,E.removeFilter,E.hasAction,E.hasFilter,E.removeAllActions,E.removeAllFilters,E.doAction,E.applyFilters,E.currentAction,E.currentFilter,E.doingAction,E.doingFilter,E.didAction,E.didFilter,E.actions,E.filters,function(t,e,n){var r=new f({}),i=new Set,o=function(){i.forEach((function(t){return t()}))},s=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"default";r.data[e]=d(d(d({},h),r.data[e]),t),r.data[e][""]=d(d({},h[""]),r.data[e][""])},a=function(t,e){s(t,e),o()},c=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default",e=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0,i=arguments.length>3?arguments[3]:void 0,o=arguments.length>4?arguments[4]:void 0;return r.data[t]||s(void 0,t),r.dcnpgettext(t,e,n,i,o)},l=function(){return arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default"},u=function(t,e,r){var i=c(r,e,t);return n?(i=n.applyFilters("i18n.gettext_with_context",i,t,e,r),n.applyFilters("i18n.gettext_with_context_"+l(r),i,t,e,r)):i};if(n){var p=function(t){y.test(t)&&o()};n.addAction("hookAdded","core/i18n",p),n.addAction("hookRemoved","core/i18n",p)}return{getLocaleData:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default";return r.data[t]},setLocaleData:a,resetLocaleData:function(t,e){r.data={},r.pluralForms={},a(t,e)},subscribe:function(t){return i.add(t),function(){return i.delete(t)}},__:function(t,e){var r=c(e,void 0,t);return n?(r=n.applyFilters("i18n.gettext",r,t,e),n.applyFilters("i18n.gettext_"+l(e),r,t,e)):r},_x:u,_n:function(t,e,r,i){var o=c(i,void 0,t,e,r);return n?(o=n.applyFilters("i18n.ngettext",o,t,e,r,i),n.applyFilters("i18n.ngettext_"+l(i),o,t,e,r,i)):o},_nx:function(t,e,r,i,o){var s=c(o,i,t,e,r);return n?(s=n.applyFilters("i18n.ngettext_with_context",s,t,e,r,i,o),n.applyFilters("i18n.ngettext_with_context_"+l(o),s,t,e,r,i,o)):s},isRTL:function(){return"rtl"===u("ltr","text direction")},hasTranslation:function(t,e,i){var o,s,a=e?e+""+t:t,c=!(null===(o=r.data)||void 0===o||null===(s=o[null!=i?i:"default"])||void 0===s||!s[a]);return n&&(c=n.applyFilters("i18n.has_translation",c,t,e,i),c=n.applyFilters("i18n.has_translation_"+l(i),c,t,e,i)),c}}}(0,0,E));C.getLocaleData.bind(C),C.setLocaleData.bind(C),C.resetLocaleData.bind(C),C.subscribe.bind(C);var A=C.__.bind(C);function O(t){return O="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},O(t)}function F(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,I(r.key),r)}}function I(t){var e=function(t){if("object"!=O(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=O(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==O(e)?e:e+""}C._x.bind(C),C._n.bind(C),C._nx.bind(C),C.isRTL.bind(C),C.hasTranslation.bind(C);var j=function(){return t=function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.component=e;try{var n=JSON.parse(this.component.dataset.willChange);this.data={propagateInputs:this.initPropagationList(n),changeEvent:new Event("change",{bubbles:!0})}}catch(t){console.error('Error parsing JSON data from "will-change" attribute.',t)}},(e=[{key:"initPropagationList",value:function(t){var e=[];return t.forEach((function(t){var n=document.querySelector('input[name="'.concat(t,'"]'));null!==n&&e.push(n)})),e}},{key:"updateAllDependentElements",value:function(t){this.data.propagateInputs.forEach((function(e){e.value=t})),this.data.propagateInputs[0].dispatchEvent(this.data.changeEvent)}}])&&F(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function T(t){return T="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},T(t)}function P(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,L(r.key),r)}}function L(t){var e=function(t){if("object"!=T(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=T(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==T(e)?e:e+""}new(function(){return t=function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.success=frmDom.success,this.cssEditorInstance=null,this.cssInlineStyleElement=null,this.cssEditorOptions={retryLimit:5,retryInterval:500,retryCount:0},this.init(),this.initHover(),this.initCustomCSSEditorInstance()},(e=[{key:"init",value:function(){this.initColorPickerDependentUpdaterComponents(),this.initStyleClassCopyToClipboard(A("The class name has been copied.","formidable")),this.toggleVisibilityOfCustomCSSEditor()}},{key:"initCustomCSSEditorInstance",value:function(){var t=this;null!==this.cssEditorInstance||this.cssEditorOptions.retryCount>=this.cssEditorOptions.retryLimit||(void 0!==window.frm_single_style_custom_css_wp_editor&&void 0!==window.frm_single_style_custom_css_wp_editor.codemirror?(this.cssEditorInstance=window.frm_single_style_custom_css_wp_editor.codemirror,this.onCssEditorReady()):setTimeout((function(){t.cssEditorOptions.retryCount++,t.initCustomCSSEditorInstance()}),500))}},{key:"getInlineStyleElement",value:function(){return null!==this.cssInlineStyleElement||(this.cssInlineStyleElement=document.createElement("style"),document.head.appendChild(this.cssInlineStyleElement)),this.cssInlineStyleElement}},{key:"onCssEditorReady",value:function(){var t,e=this,n=null===(t=document.getElementById("frm_style_class_custom_css"))||void 0===t||null===(t=t.dataset)||void 0===t?void 0:t.cssScope;if(null!==n){var r=CSS.escape(n);this.cssEditorInstance.on("change",(function(t){var n=t.getValue().replace(/<[^>]*>/g,"").trim();e.getInlineStyleElement().textContent=".".concat(r," { ").concat(n," }")}))}}},{key:"initColorPickerDependentUpdaterComponents",value:function(){var t=document.querySelectorAll(".frm-style-dependent-updater-component.frm-colorpicker"),e=[];t.forEach((function(t){var n=t.querySelector("input.hex"),r=void 0!==n?n.getAttribute("id"):null;null!==r&&e.push({id:r,dependentUpdaterClass:new j(t,"colorpicker")})})),wp.hooks.addAction("frm_style_options_color_change","formidable",(function(t){var n=t.event,r=t.value,i=n.target.closest(".wp-picker-container"),o=n.target.getAttribute("id");i.querySelector(".wp-color-result-text").innerText=r,e.forEach((function(t){t.id===o&&t.dependentUpdaterClass.updateAllDependentElements(r)}))}))}},{key:"initHover",value:function(){var t=document.querySelector(".frm-right-panel .styling_settings .accordion-container");if(null!==t){var e=document.createElement("div");e.classList.add("frm_hidden"),e.classList.add("frm-style-settings-hover"),t.appendChild(e),t.querySelector(":scope > ul").querySelectorAll(":scope > li").forEach((function(t){t.querySelector("h3").addEventListener("mouseover",(function(t){e.style.transform="translateY(".concat(t.target.closest("li").offsetTop,"px)"),e.classList.add("frm-animating"),e.classList.remove("frm_hidden"),setTimeout((function(){e.classList.remove("frm-animating")}),250)}))})),document.querySelectorAll("#frm_style_sidebar .accordion-section h3").forEach((function(t){t.addEventListener("click",(function(){e.classList.add("frm_hidden")}))}))}}},{key:"initStyleClassCopyToClipboard",value:function(t){var e=this;document.querySelectorAll(".frm-copy-text").forEach((function(n){n.addEventListener("click",(function(n){var r=n.currentTarget.innerText;navigator.clipboard&&navigator.clipboard.writeText?navigator.clipboard.writeText(r).then((function(){e.success(t)})):!0===e.fallbackCopyToClipboard(r,n.currentTarget)&&e.success(t)}))}))}},{key:"toggleVisibilityOfCustomCSSEditor",value:function(){var t=document.getElementById("frm_enable_single_style_custom_css"),e=document.getElementById("frm_single_style_custom_css_editor");t&&e&&t.addEventListener("change",(function(t){e.classList.toggle("frm_hidden",!t.target.checked)}))}},{key:"fallbackCopyToClipboard",value:function(t,e){if("function"!=typeof document.execCommand)return!1;var n,r=document.createElement("input");r.setAttribute("type","text"),r.value=t,e.parentElement.appendChild(r),r.focus(),r.select(),r.setSelectionRange(0,99999),r.style.position="absolute",r.style.left="-9999px",r.style.top="-9999px";try{n=document.execCommand("copy")}catch(t){n=!1}return r.remove(),n}}])&&P(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}())})()})(); No newline at end of file
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

Add length check in j.updateAllDependentElements to avoid empty propagation list crash.

The dependent updater used for style settings/color pickers also does:

this.data.propagateInputs.forEach(input => { input.value = value; });
this.data.propagateInputs[0].dispatchEvent(this.data.changeEvent);

If no matching inputs are found, this.data.propagateInputs[0] is undefined and this will throw.

Suggested source-level change
updateAllDependentElements( value ) {
-  this.data.propagateInputs.forEach( ( input ) => {
-    input.value = value;
-  } );
-  this.data.propagateInputs[0].dispatchEvent( this.data.changeEvent );
+  const { propagateInputs, changeEvent } = this.data || {};
+  if ( ! propagateInputs || propagateInputs.length === 0 ) {
+    return;
+  }
+
+  propagateInputs.forEach( ( input ) => {
+    input.value = value;
+  } );
+  propagateInputs[0].dispatchEvent( changeEvent );
}
🧰 Tools
🪛 Biome (2.1.2)

[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: Do not use the t variable name as a label

The variable is declared here

Creating a label with the same name as an in-scope variable leads to confusion.

(lint/suspicious/noLabelVar)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

🤖 Prompt for AI Agents
In js/formidable_styles.js around lines 1-1, the method
j.updateAllDependentElements assumes this.data.propagateInputs has at least one
element and calls this.data.propagateInputs[0].dispatchEvent(...), which will
throw if the list is empty; fix by checking the array length (or truthiness of
this.data.propagateInputs[0]) before calling dispatchEvent and skip the dispatch
(or return early) when there are no propagated inputs so the code no longer
accesses index 0 when the list is empty.

Comment thread js/formidable-settings-components.js Outdated
@@ -1 +1 @@
(()=>{"use strict";var e=window.frmGlobal,t=(e.url,e.nonce,"frm_hidden"),n="frm_disabled",i=(Promise.resolve(),frmDom),r=(i.div,i.span,i.tag,i.a,i.img,i.svg,frmDom.modal),a=(r.maybeCreateModal,r.footerButton,frmDom.util),o=(a.onClickPreventDefault,a.documentOn);frmDom.ajax.doJsonPost;var l=(new URL(window.location.href).searchParams,function(e){return null==e?void 0:e.classList.remove(t)});function s(e){return s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s(e)}function c(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,u(i.key),i)}}function u(e){var t=function(e){if("object"!=s(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=s(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==s(t)?t:t+""}var d=function(){return e=function e(){var t=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.radioElements=document.querySelectorAll(".frm-style-component.frm-radio-component"),this.observers=new Map,0<this.radioElements.length&&this.init(),document.addEventListener("frm_added_field",function(e){var n=e.frmField;return t.discoverAndInitFieldRadios(n.dataset.fid)}),document.addEventListener("frm_ajax_loaded_field",function(e){return e.frmFields.forEach(function(e){return t.discoverAndInitFieldRadios(e.id)})}),window.addEventListener("beforeunload",function(){return t.cleanupObservers()})},(n=[{key:"init",value:function(){this.initRadio(),this.initTrackerOnAccordionClick()}},{key:"discoverAndInitFieldRadios",value:function(e){var t=document.getElementById("frm-single-settings-".concat(e));if(!t)throw new Error("Field container not found for field ID: ".concat(e));this.radioElements=t.querySelectorAll(".frm-style-component.frm-radio-component"),this.initRadio()}},{key:"initRadio",value:function(){var e=this;this.radioElements.forEach(function(t){e.initOnRadioChange(t),e.initVisibilityObserver(t)})}},{key:"initTrackerOnAccordionClick",value:function(){var e=this;document.querySelectorAll("#frm_style_sidebar .accordion-section h3").forEach(function(t){t.addEventListener("click",function(t){t.target.closest(".accordion-section").querySelectorAll('.frm-style-component.frm-radio-component input[type="radio"]:checked').forEach(function(t){setTimeout(function(){return e.onRadioChange(t)},200)})})})}},{key:"initOnRadioChange",value:function(e){var t=this;e.querySelectorAll('input[type="radio"]').forEach(function(e){e.checked&&t.onRadioChange(e),e.addEventListener("change",function(e){t.onRadioChange(e.target)})})}},{key:"onRadioChange",value:function(e){var t=e.closest(".frm-style-component.frm-radio-component"),n=t.querySelector('input[type="radio"]:checked + label');null!==n&&(this.moveTracker(n,t),this.hideExtraElements(e),this.maybeShowExtraElements(e))}},{key:"maybeShowExtraElements",value:function(e){var t=e.getAttribute("data-frm-show-element");if(null!==t){var n=document.querySelectorAll('div[data-frm-element="'.concat(t,'"]'));0!==n.length&&n.forEach(function(e){l(e),e.classList.add("frm-element-is-visible")})}}},{key:"initVisibilityObserver",value:function(e){var t=this;this.observers.has(e)&&this.observers.get(e).disconnect();var n=new MutationObserver(function(){if(function(e){return"none"!==window.getComputedStyle(e).getPropertyValue("display")}(e)){var n=e.querySelector('input[type="radio"]:checked');n&&t.onRadioChange(n)}});this.observers.set(e,n),n.observe(e,{attributes:!0,attributeFilter:["class","style"]});for(var i=e.parentElement,r=0;r<7&&i;r++)n.observe(i,{attributes:!0,attributeFilter:["class","style"]}),i=i.parentElement}},{key:"cleanupObservers",value:function(){this.observers.forEach(function(e){e.disconnect()}),this.observers.clear()}},{key:"hideExtraElements",value:function(){var e=document.querySelectorAll(".frm-element-is-visible");0!==e.length&&e.forEach(function(e){e.classList.remove("frm-element-is-visible"),e.classList.add(t),function(e){null==e||e.classList.add(t)}(e)})}},{key:"moveTracker",value:function(e,t){var n=e.offsetLeft,i=e.offsetWidth,r=t.querySelector(".frm-radio-active-tracker");r.style.left=0,r.style.width="".concat(i,"px"),r.style.transform="translateX(".concat(n,"px)")}}])&&c(e.prototype,n),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,n}();function f(e){return f="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},f(e)}function v(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,m(i.key),i)}}function m(e){var t=function(e){if("object"!=f(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=f(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==f(t)?t:t+""}var h=function(){return e=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.component=t;try{var n=JSON.parse(this.component.dataset.willChange);this.data={propagateInputs:this.initPropagationList(n),changeEvent:new Event("change",{bubbles:!0})}}catch(e){console.error('Error parsing JSON data from "will-change" attribute.',e)}},(t=[{key:"initPropagationList",value:function(e){var t=[];return e.forEach(function(e){var n=document.querySelector('input[name="'.concat(e,'"]'));null!==n&&t.push(n)}),t}},{key:"updateAllDependentElements",value:function(e){this.data.propagateInputs.forEach(function(t){t.value=e}),this.data.propagateInputs[0].dispatchEvent(this.data.changeEvent)}}])&&v(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();function p(e){return p="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},p(e)}function y(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,g(i.key),i)}}function g(e){var t=function(e){if("object"!=p(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=p(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==p(t)?t:t+""}var b=function(){return e=function e(){var t=this;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.sliderElements=document.querySelectorAll(".frm-slider-component"),0!==this.sliderElements.length){this.sliderBulletWidth=16,this.sliderMarginRight=5,this.eventsChange=[];var n=frmDom.util.debounce;this.valueChangeDebouncer=n(function(e){return t.triggerValueChange(e)},25),this.initOptions(),this.init()}},(n=[{key:"initOptions",value:function(){var e=this;this.options=[],this.sliderElements.forEach(function(t,n){var i=t.classList.contains("frm-has-multiple-values")?t.closest(".frm-style-component"):t;e.options.push({dragging:!1,startX:0,translateX:0,maxValue:parseInt(t.dataset.maxValue,10),element:t,index:n,value:0,dependentUpdater:i.classList.contains("frm-style-dependent-updater-component")?new h(i):null})})}},{key:"init",value:function(){this.initSlidersPosition(),this.initDraggable()}},{key:"initDraggable",value:function(){var e=this;this.sliderElements.forEach(function(t,n){e.eventsChange[n]=new Event("change",{bubbles:!0,cancelable:!0});var i=t.querySelector(".frm-slider-bullet"),r=t.querySelector('.frm-slider-value input[type="text"]');r.addEventListener("change",function(i){var a=t.querySelector("select").value;e.getMaxValue(a,n)<parseInt(i.target.value,10)||(e.initSliderWidth(t),e.options[n].fullValue=e.updateValue(t,r.value+a),e.triggerValueChange(n))}),e.expandSliderGroup(t),e.updateOnUnitChange(t,r,n),e.changeSliderPositionOnClick(t,r,n),i.addEventListener("mousedown",function(i){i.preventDefault(),i.stopPropagation(),t.classList.contains("frm-disabled")||e.enableDragging(i,n)}),i.addEventListener("mousemove",function(i){t.classList.contains("frm-disabled")||e.moveTracker(i,n)}),i.addEventListener("mouseup",function(i){t.classList.contains("frm-disabled")||e.disableDragging(n,i)}),i.addEventListener("mouseleave",function(i){t.classList.contains("frm-disabled")||e.disableDragging(n,i)})})}},{key:"expandSliderGroup",value:function(e){var n=e.querySelector(".frmsvg");if(void 0!==e.dataset.displaySliders&&null!==n){var i=this.getSliderGroupItems(e);n.addEventListener("click",function(){i.forEach(function(e){e.classList.toggle(t)})})}}},{key:"updateOnUnitChange",value:function(e,t,n){var i=this;e.querySelector("select").addEventListener("change",function(r){var a=r.target.value.toLowerCase();if(""!==a){if("auto"===a)return e.classList.add("frm-disabled"),i.updateValue(e,"auto"),void i.triggerValueChange(n);e.classList.remove("frm-disabled","frm-empty"),i.options[n].fullValue=t.value+a,i.updateValue(e,i.options[n].fullValue),i.triggerValueChange(n)}else e.classList.add("frm-disabled","frm-empty")})}},{key:"changeSliderPositionOnClick",value:function(e,t,n){var i=this,r=e.querySelector(".frm-slider"),a=new Event("change",{bubbles:!0,cancelable:!0});r.addEventListener("click",function(o){if(!e.classList.contains("frm-disabled")&&(o.preventDefault(),o.stopPropagation(),o.target.classList.contains("frm-slider")||o.target.classList.contains("frm-slider-active-track"))){var l=r.offsetWidth-i.sliderBulletWidth,s=r.getBoundingClientRect(),c=o.clientX-s.left-i.sliderBulletWidth,u=e.querySelector("select").value,d=i.calculateValue(l,c,i.getMaxValue(u,n));d<0||(i.options[n].fullValue=i.updateValue(e,d+u),i.initChildSlidersWidth(e,c,n,d+u),t.value=d,t.dispatchEvent(a))}})}},{key:"getSliderGroupItems",value:function(e){if(void 0===e.dataset.displaySliders)return[];var t=e.dataset.displaySliders.split(",").map(function(e){return'.frm-slider-component[data-type="'.concat(e,'"]')}).join(", ");return e.closest(".frm-style-component").querySelectorAll(t)}},{key:"initSlidersPosition",value:function(){var e=this,t=document.querySelectorAll("#frm_style_sidebar .accordion-section h3"),n=document.querySelector(".frm-quick-settings"),i=document.querySelector(".accordion-section.open");wp.hooks.addAction("frm_pro_on_bg_image_upload","formidable",function(t){var n=t.closest(".accordion-section-content").querySelector("#frm-bg-image-opacity-slider");e.initSlidersWidth(n)}),null!==n&&this.initSlidersWidth(n),null!==i&&this.initSlidersWidth(i),t.forEach(function(t){t.addEventListener("click",function(t){e.initSlidersWidth(t.target.closest(".accordion-section"))})}),this.initSliderPositionOnFieldShapeChange()}},{key:"initSliderPositionOnFieldShapeChange",value:function(){var e=this,t=document.querySelector(".frm-style-component.frm-field-shape");null!==t&&t.querySelectorAll('input[type="radio"]').forEach(function(t){t.addEventListener("change",function(t){if(t.target.checked&&"rounded-corner"===t.target.value){var n=document.querySelector('div[data-frm-element="field-shape-corner-radius"] .frm-slider-component');e.initSliderWidth(n)}})})}},{key:"initSlidersWidth",value:function(e){var t=this;e.querySelectorAll(".frm-slider-component").forEach(function(e){setTimeout(function(){t.initSliderWidth(e)},100)})}},{key:"initSliderWidth",value:function(e){if(!e.classList.contains("frm-disabled")){var t=this.getSliderIndex(e),n=e.querySelector(".frm-slider").offsetWidth-this.sliderBulletWidth,i=parseInt(e.querySelector('.frm-slider-value input[type="text"]').value,10),r=e.querySelector("select").value,a="%"===r?Math.round(n*i/100):Math.ceil(i/this.options[t].maxValue*n);e.querySelector(".frm-slider-active-track").style.width="".concat(a,"px"),this.options[t].translateX=a,this.options[t].value=i+r}}},{key:"initChildSlidersWidth",value:function(e,t,n,i){var r=this;(e.classList.contains("frm-has-independent-fields")||e.classList.contains("frm-has-multiple-values"))&&(e.classList.contains("frm-has-independent-fields")?e.querySelectorAll(".frm-independent-slider-field"):this.getSliderGroupItems(e)).forEach(function(e,a){e.querySelector(".frm-slider-active-track").style.width="".concat(t,"px"),r.options[n+a+1].translateX=t,r.options[n+a+1].value=i})}},{key:"getSliderIndex",value:function(e){return this.options.filter(function(t){return t.element===e})[0].index}},{key:"moveTracker",value:function(e,t){if(this.options[t].dragging){var n=e.clientX-this.options[t].startX,i=this.sliderElements[t],r=i.querySelector(".frm-slider").offsetWidth;if(!((n=Math.max(n,0))+this.sliderBulletWidth/2+this.sliderMarginRight>=r)){var a=i.querySelector("select").value,o=this.calculateValue(r,n,this.getMaxValue(a,t));i.querySelector('.frm-slider-value input[type="text"]').value=o,i.querySelector(".frm-slider-bullet .frm-slider-value-label").innerText=o,i.querySelector(".frm-slider-active-track").style.width="".concat(n,"px"),this.initChildSlidersWidth(i,n,t,o+a),this.options[t].translateX=n,this.options[t].value=o+a,this.options[t].fullValue=this.updateValue(i,this.options[t].value),this.valueChangeDebouncer(t)}}}},{key:"getMaxValue",value:function(e,t){return"%"===e?100:this.options[t].maxValue}},{key:"enableDragging",value:function(e,t){e.target.classList.add("frm-dragging"),this.options[t].dragging=!0,this.options[t].startX=e.clientX-this.options[t].translateX}},{key:"disableDragging",value:function(e,t){!1!==this.options[e].dragging&&(t.target.classList.remove("frm-dragging"),this.options[e].dragging=!1,this.triggerValueChange(e))}},{key:"triggerValueChange",value:function(e){var t=this;if(null===this.options[e].dependentUpdater){var n=this.sliderElements[e].classList.contains("frm-has-multiple-values")?this.sliderElements[e].closest(".frm-style-component").querySelector('input[type="hidden"]'):this.sliderElements[e].querySelectorAll('.frm-slider-value input[type="hidden"]');n instanceof NodeList?n.forEach(function(n){n.dispatchEvent(t.eventsChange[e])}):n.dispatchEvent(this.eventsChange[e])}else this.options[e].dependentUpdater.updateAllDependentElements(this.options[e].fullValue)}},{key:"calculateValue",value:function(e,t,n){var i=Math.ceil(this.sliderBulletWidth*(t/e)),r=Math.ceil((t+i)/e*n);return Math.min(r,n)}},{key:"updateValue",value:function(e,t){var n=this;if(e.classList.contains("frm-base-font-size")){var i=document.querySelector('input[name="frm_style_setting[post_content][use_base_font_size]"]');null!==i&&(i.value="true")}if(e.classList.contains("frm-has-multiple-values")){var r=e.closest(".frm-style-component").querySelector('input[type="hidden"]'),a=r.value.split(" "),o=e.dataset.type;switch(a[2]||(a[2]="0px"),a[3]||(a[3]="0px"),o){case"vertical":a[0]=t,a[2]=t;break;case"horizontal":a[1]=t,a[3]=t;break;case"top":a[0]=t;break;case"bottom":a[2]=t;break;case"left":a[3]=t;break;case"right":a[1]=t}var l=a.join(" ");return r.value=l,this.getSliderGroupItems(e).forEach(function(e){var i=n.getUnitMeasureFromValue(t);e.querySelector('.frm-slider-value input[type="text"]').value=parseInt(t,10),e.querySelector("select").value=i}),l}if(e.classList.contains("frm-has-independent-fields")){var s=e.querySelectorAll('.frm-slider-value input[type="hidden"]'),c=e.querySelectorAll('.frm-slider-value input[type="text"]');return s.forEach(function(e,n){e.value=t,c[n+1].value=parseInt(t,10)}),t}return e.querySelector('.frm-slider-value input[type="hidden"]').value=t,t}},{key:"getUnitMeasureFromValue",value:function(e){return["%","px","em"].find(function(t){return e.includes(t)})||""}}])&&y(e.prototype,n),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,n}();function S(e){return S="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},S(e)}function k(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,E(i.key),i)}}function E(e){var t=function(e){if("object"!=S(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=S(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==S(t)?t:t+""}var w=function(){return e=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),void 0!==t&&(this.wrapper=t instanceof Element?t:document.querySelector(t),null!==this.wrapper&&(this.flexboxSlidesGap="16px",this.navs=this.wrapper.querySelectorAll(".frm-tabs-navs ul > li"),this.slideTrackLine=this.wrapper.querySelector(".frm-tabs-active-underline"),this.slideTrack=this.wrapper.querySelector(".frm-tabs-slide-track"),this.slides=this.wrapper.querySelectorAll(".frm-tabs-slide-track > div"),this.isRTL="rtl"===document.documentElement.dir||"rtl"===document.body.dir,this.resizeObserver=null,this.init()))},(t=[{key:"init",value:function(){var e=this;null!==this.wrapper&&this.navs.length&&null!==this.slideTrackLine&&null!==this.slideTrack&&this.slides.length&&(this.initDefaultSlideTrackerWidth(),this.navs.forEach(function(t,n){t.addEventListener("click",function(t){return e.onNavClick(t,n)})}),this.setupScrollbarObserver(),window.addEventListener("beforeunload",this.cleanupObservers))}},{key:"onNavClick",value:function(e,t){var n=e.currentTarget;e.preventDefault(),this.removeActiveClassnameFromNavs(),n.classList.add("frm-active"),this.initSlideTrackUnderline(n,t),this.changeSlide(t);var i,r,a=n.querySelector("a");a&&"frm_insert_fields_tab"===a.id&&!a.closest("#frm_adv_info")&&(null===(i=window.frmAdminBuild)||void 0===i||null===(r=i.clearSettingsBox)||void 0===r||r.call(i))}},{key:"initDefaultSlideTrackerWidth",value:function(){this.slideTrackLine.dataset.initialWidth&&(this.slideTrackLine.style.width="".concat(this.slideTrackLine.dataset.initialWidth,"px"))}},{key:"initSlideTrackUnderline",value:function(e,t){this.slideTrackLine.classList.remove("frm-first","frm-last");var n=void 0!==e?e:this.navs.filter(function(e){return e.classList.contains("frm-active")});this.positionUnderlineIndicator(n)}},{key:"setupScrollbarObserver",value:function(){var e=this,t=this.wrapper.closest(".frm-scrollbar-wrapper");t&&"ResizeObserver"in window&&(this.resizeObserver=new ResizeObserver(function(){var t=e.wrapper.querySelector(".frm-tabs-navs ul > li.frm-active");t&&e.positionUnderlineIndicator(t)}),this.resizeObserver.observe(t))}},{key:"cleanupObservers",value:function(){this.resizeObserver&&(this.resizeObserver.disconnect(),this.resizeObserver=null)}},{key:"positionUnderlineIndicator",value:function(e){var t=this;requestAnimationFrame(function(){var n=t.isRTL?-(e.parentElement.offsetWidth-e.offsetLeft-e.offsetWidth):e.offsetLeft;t.slideTrackLine.style.transform="translateX(".concat(n,"px)"),t.slideTrackLine.style.width=e.clientWidth+"px"})}},{key:"changeSlide",value:function(e){this.removeActiveClassnameFromSlides();var t=0==e?"0px":"calc( ( ".concat(100*e,"% + ").concat(parseInt(this.flexboxSlidesGap,10)*e,"px ) * ").concat(this.isRTL?1:-1," )");"0px"!==t?this.slideTrack.style.transform="translateX(".concat(t,")"):this.slideTrack.style.removeProperty("transform"),e in this.slides&&this.slides[e].classList.add("frm-active")}},{key:"removeActiveClassnameFromSlides",value:function(){this.slides.forEach(function(e){return e.classList.remove("frm-active")})}},{key:"removeActiveClassnameFromNavs",value:function(){this.navs.forEach(function(e){return e.classList.remove("frm-active")})}}])&&k(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();function L(e){return L="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},L(e)}function q(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,x(i.key),i)}}function x(e){var t=function(e){if("object"!=L(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=L(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==L(t)?t:t+""}var C=function(){return e=function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.elements=document.querySelectorAll(".frm-style-tabs-wrapper"),0<this.elements.length&&this.init()},(t=[{key:"init",value:function(){this.elements.forEach(function(e){new w(e)})}},{key:"initOnTabClick",value:function(e){var t=this;this.initActiveBackgroundWidth(e),e.querySelectorAll(".frm-tab-item").forEach(function(e){e.addEventListener("click",function(e){t.onTabClick(e.target.closest(".frm-tabs-wrapper"))})})}}])&&q(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}(),A="frm-token-container",T="frm-tokens",O="frm-token",_="frm-token-value",P="frm-token-remove",V="frm-token-proxy-input",W=window.frmDom,j=W.span,D=W.svg,I=W.tag;function R(){document.querySelectorAll(".".concat(A)).forEach(function(e){return M(e.querySelector(".".concat(V)),e.querySelector(".".concat(T)))})}function M(e,t){if(e&&t){var n=t.querySelectorAll(".".concat(O));if(!(n.length>0))return e.style.paddingLeft="",e.style.paddingTop="",void(e.style.height="");var i=t.offsetHeight;if(Math.max(1,Math.ceil(i/36))>1){var r=function(e){if(!e.length)return 0;var t=0;return e.forEach(function(e){t+=e.offsetWidth}),(t+=4*(e.length-1))+4}(function(e){if(!e.length)return[];var t=Array.from(e),n=-1;t.forEach(function(e){var t=e.getBoundingClientRect().bottom;t>n&&(n=t)});return t.filter(function(e){var t=e.getBoundingClientRect();return Math.abs(t.bottom-n)<=2})}(n));e.style.height="".concat(i,"px"),e.style.paddingTop="".concat(i-36+4,"px"),e.style.paddingLeft=r?"".concat(r+8,"px"):""}else e.style.height="",e.style.paddingTop="",e.style.paddingLeft="".concat(t.offsetWidth-4,"px")}}function B(e,t,n){e&&n&&t&&(n.innerHTML="",N(e).forEach(function(e){return function(e,t){var n=j({className:O,children:[j({text:e,className:_}),j({className:P,child:D({href:"#frm_close_icon"})})]});t.appendChild(n)}(e,n)}),M(t,n),t.focus())}function F(e,t,n){if(!e||!t||!n)return!1;var i=N(t.value);return i.includes(e)?(z(n),!1):(i.push(e),U(t,i),z(n),!0)}function X(e,t,n){if(e&&t&&n){var i=e.querySelector(".".concat(_)).textContent;U(t,N(t.value).filter(function(e){return e!==i})),e.remove(),n.focus()}}function N(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return(e=e.trim())?e.split(/\s+/).filter(Boolean):[]}function U(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];e&&(e.value=t.join(" "),jQuery(e).trigger("change"))}function z(e){e&&(e.value="",e.focus())}function G(e){var n=(e?document.getElementById("frm-single-settings-".concat(e)):document.body).querySelectorAll(".".concat("frm-token-input-field"));if(n.length){var i=new Set;n.forEach(function(e){i.has(e.id)||(function(e){var n=function(e){var n=e.closest(".".concat("frm-with-right-icon"));if(n.querySelector(".".concat(T)))return null;n.classList.add(A);var i=j({className:T});n.insertBefore(i,n.firstChild);var r=I("input",{className:V,id:"".concat(e.id,"-proxy-input")});return r.type="text",e.parentNode.insertBefore(r,e.nextSibling),e.classList.add(t),n}(e);if(n){var i=n.querySelector(".".concat(V)),r=n.querySelector(".".concat(T));B(e.value,i,r),function(e,t,n){jQuery(e).on("change",function(){return B(e.value,t,n)}),t.addEventListener("keydown",function(i){return function(e,t,n,i){var r=e.key,a=n.value.trim();switch(r){case"Backspace":a||(e.preventDefault(),X(i.querySelector(".".concat(O,":last-child")),t,n));break;case" ":case",":case"Enter":e.preventDefault(),F(a,t,n)}M(n,i)}(i,e,t,n)}),t.addEventListener("blur",function(){return F(t.value.trim(),e,t)}),n.addEventListener("click",function(n){return function(e,t,n){var i=e.target.closest(".".concat(P));if(i){var r=i.closest(".".concat(O));if(r){var a=r.parentElement;X(r,t,n),M(n,a)}}}(n,e,t)})}(e,i,r)}}(e),i.add(e.id))})}}var J,H="frm-toggle-group",Q="frm_toggle_block",K="data-group-name";function Y(e){var t=e.target,n=t.closest(".".concat(H));n&&Z(t,n)}function Z(e,i){var r,a=(null===(r=i.closest(".".concat("frm-single-settings")))||void 0===r?void 0:r.dataset.fid)||i.dataset.fid,o=e.checked,l=e.getAttribute("data-show");l&&document.querySelectorAll($(l,a)).forEach(function(e){return e.classList.toggle(t,!o)});var s=e.getAttribute("data-disable");s&&document.querySelectorAll($(s,a)).forEach(function(e){e.classList.toggle(n,o),e.querySelectorAll("input, select, textarea").forEach(function(e){return e.disabled=o}),e.querySelectorAll(".frm-show-inline-modal[tabindex]").forEach(function(e){return e.tabIndex=o?-1:0})});var c=e.getAttribute("data-enable");c&&document.querySelectorAll($(c,a)).forEach(function(e){return e.classList.toggle(n,!o)});var u=e.closest(".".concat(Q));Array.from(i.querySelectorAll(".".concat(Q))).filter(function(e){return e!==u}).forEach(function(e){e.classList.toggle(n,o);var t=e.querySelector(".frm_toggle");t.tabIndex=o?-1:0,t.setAttribute("aria-disabled",o)})}function $(e,t){return e.replace(/{id}/g,t)}function ee(e){var t=e.target.closest(".frm-unit-input"),n=t.querySelector(".frm-unit-input-control"),i=t.querySelector("select").value;e.target.matches("select")&&(n.type=""===i?"text":"number");var r=n.value.trim();t.querySelector('input[type="hidden"]').value=""!==r?r+i:""}J=function(){var e,t;new d,new b,new C,null===(t=document.getElementById("frm-form-add-field"))||void 0===t||t.addEventListener("click",function(e){var t;e.preventDefault(),null===(t=document.querySelector(".frm-settings-panel .frm-tabs-navs ul > li:first-child"))||void 0===t||t.click()}),G(),document.addEventListener("frm_added_field",function(e){return G(e.frmField.dataset.fid)}),document.addEventListener("frm_ajax_loaded_field",function(e){return e.frmFields.forEach(function(e){return G(e.id)})}),wp.hooks.addAction("frmShowedFieldSettings","formidable-token-input",R),(e=document.querySelectorAll(".".concat(H))).length&&e.forEach(function(e){var t=e.querySelector("[".concat(K,"]:checked"));t&&Z(t,e)}),o("change",".".concat(H," [").concat(K,"]"),Y),o("change",".frm-unit-input .frm-unit-input-control",ee),o("change",".frm-unit-input select",ee)},"undefined"!=typeof document&&("complete"!==document.readyState&&"interactive"!==document.readyState?document.addEventListener("DOMContentLoaded",J):J())})(); No newline at end of file
(()=>{"use strict";var e=window.frmGlobal,t=(e.url,e.nonce,"frm_hidden"),n="frm_disabled",i=(Promise.resolve(),frmDom),r=(i.div,i.span,i.tag,i.a,i.img,i.svg,frmDom.modal),a=(r.maybeCreateModal,r.footerButton,frmDom.util),o=(a.onClickPreventDefault,a.documentOn);frmDom.ajax.doJsonPost;var l=(new URL(window.location.href).searchParams,function(e){return null==e?void 0:e.classList.remove(t)});function s(e){return s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s(e)}function c(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,u(i.key),i)}}function u(e){var t=function(e){if("object"!=s(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=s(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==s(t)?t:t+""}var d=function(){return e=function e(){var t=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.radioElements=document.querySelectorAll(".frm-style-component.frm-radio-component"),this.observers=new Map,0<this.radioElements.length&&this.init(),document.addEventListener("frm_added_field",(function(e){var n=e.frmField;return t.discoverAndInitFieldRadios(n.dataset.fid)})),document.addEventListener("frm_ajax_loaded_field",(function(e){return e.frmFields.forEach((function(e){return t.discoverAndInitFieldRadios(e.id)}))})),window.addEventListener("beforeunload",(function(){return t.cleanupObservers()}))},(n=[{key:"init",value:function(){this.initRadio(),this.initTrackerOnAccordionClick()}},{key:"discoverAndInitFieldRadios",value:function(e){var t=document.getElementById("frm-single-settings-".concat(e));if(!t)throw new Error("Field container not found for field ID: ".concat(e));this.radioElements=t.querySelectorAll(".frm-style-component.frm-radio-component"),this.initRadio()}},{key:"initRadio",value:function(){var e=this;this.radioElements.forEach((function(t){e.initOnRadioChange(t),e.initVisibilityObserver(t)}))}},{key:"initTrackerOnAccordionClick",value:function(){var e=this;document.querySelectorAll("#frm_style_sidebar .accordion-section h3").forEach((function(t){t.addEventListener("click",(function(t){t.target.closest(".accordion-section").querySelectorAll('.frm-style-component.frm-radio-component input[type="radio"]:checked').forEach((function(t){setTimeout((function(){return e.onRadioChange(t)}),200)}))}))}))}},{key:"initOnRadioChange",value:function(e){var t=this;e.querySelectorAll('input[type="radio"]').forEach((function(e){e.checked&&t.onRadioChange(e),e.addEventListener("change",(function(e){t.onRadioChange(e.target)}))}))}},{key:"onRadioChange",value:function(e){var t=e.closest(".frm-style-component.frm-radio-component"),n=t.querySelector('input[type="radio"]:checked + label');null!==n&&(this.moveTracker(n,t),this.hideExtraElements(e),this.maybeShowExtraElements(e))}},{key:"maybeShowExtraElements",value:function(e){var t=e.getAttribute("data-frm-show-element");if(null!==t){var n=document.querySelectorAll('div[data-frm-element="'.concat(t,'"]'));0!==n.length&&n.forEach((function(e){l(e),e.classList.add("frm-element-is-visible")}))}}},{key:"initVisibilityObserver",value:function(e){var t=this;this.observers.has(e)&&this.observers.get(e).disconnect();var n=new MutationObserver((function(){if(function(e){return"none"!==window.getComputedStyle(e).getPropertyValue("display")}(e)){var n=e.querySelector('input[type="radio"]:checked');n&&t.onRadioChange(n)}}));this.observers.set(e,n),n.observe(e,{attributes:!0,attributeFilter:["class","style"]});for(var i=e.parentElement,r=0;r<7&&i;r++)n.observe(i,{attributes:!0,attributeFilter:["class","style"]}),i=i.parentElement}},{key:"cleanupObservers",value:function(){this.observers.forEach((function(e){e.disconnect()})),this.observers.clear()}},{key:"hideExtraElements",value:function(){var e=document.querySelectorAll(".frm-element-is-visible");0!==e.length&&e.forEach((function(e){e.classList.remove("frm-element-is-visible"),e.classList.add(t),function(e){null==e||e.classList.add(t)}(e)}))}},{key:"moveTracker",value:function(e,t){var n=e.offsetLeft,i=e.offsetWidth,r=t.querySelector(".frm-radio-active-tracker");r.style.left=0,r.style.width="".concat(i,"px"),r.style.transform="translateX(".concat(n,"px)")}}])&&c(e.prototype,n),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,n}();function f(e){return f="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},f(e)}function v(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,m(i.key),i)}}function m(e){var t=function(e){if("object"!=f(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=f(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==f(t)?t:t+""}var h=function(){return e=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.component=t;try{var n=JSON.parse(this.component.dataset.willChange);this.data={propagateInputs:this.initPropagationList(n),changeEvent:new Event("change",{bubbles:!0})}}catch(e){console.error('Error parsing JSON data from "will-change" attribute.',e)}},(t=[{key:"initPropagationList",value:function(e){var t=[];return e.forEach((function(e){var n=document.querySelector('input[name="'.concat(e,'"]'));null!==n&&t.push(n)})),t}},{key:"updateAllDependentElements",value:function(e){this.data.propagateInputs.forEach((function(t){t.value=e})),this.data.propagateInputs[0].dispatchEvent(this.data.changeEvent)}}])&&v(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();function p(e){return p="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},p(e)}function y(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,g(i.key),i)}}function g(e){var t=function(e){if("object"!=p(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=p(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==p(t)?t:t+""}var b=function(){return e=function e(){var t=this;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.sliderElements=document.querySelectorAll(".frm-slider-component"),0!==this.sliderElements.length){this.sliderBulletWidth=16,this.sliderMarginRight=5,this.eventsChange=[];var n=frmDom.util.debounce;this.valueChangeDebouncer=n((function(e){return t.triggerValueChange(e)}),25),this.initOptions(),this.init()}},(n=[{key:"initOptions",value:function(){var e=this;this.options=[],this.sliderElements.forEach((function(t,n){var i=t.classList.contains("frm-has-multiple-values")?t.closest(".frm-style-component"):t;e.options.push({dragging:!1,startX:0,translateX:0,maxValue:parseInt(t.dataset.maxValue,10),element:t,index:n,value:0,dependentUpdater:i.classList.contains("frm-style-dependent-updater-component")?new h(i):null})}))}},{key:"init",value:function(){this.initSlidersPosition(),this.initDraggable()}},{key:"initDraggable",value:function(){var e=this;this.sliderElements.forEach((function(t,n){e.eventsChange[n]=new Event("change",{bubbles:!0,cancelable:!0});var i=t.querySelector(".frm-slider-bullet"),r=t.querySelector('.frm-slider-value input[type="text"]');r.addEventListener("change",(function(i){var a=t.querySelector("select").value;e.getMaxValue(a,n)<parseInt(i.target.value,10)||(e.initSliderWidth(t),e.options[n].fullValue=e.updateValue(t,r.value+a),e.triggerValueChange(n))})),e.expandSliderGroup(t),e.updateOnUnitChange(t,r,n),e.changeSliderPositionOnClick(t,r,n),i.addEventListener("mousedown",(function(i){i.preventDefault(),i.stopPropagation(),t.classList.contains("frm-disabled")||e.enableDragging(i,n)})),i.addEventListener("mousemove",(function(i){t.classList.contains("frm-disabled")||e.moveTracker(i,n)})),i.addEventListener("mouseup",(function(i){t.classList.contains("frm-disabled")||e.disableDragging(n,i)})),i.addEventListener("mouseleave",(function(i){t.classList.contains("frm-disabled")||e.disableDragging(n,i)}))}))}},{key:"expandSliderGroup",value:function(e){var n=e.querySelector(".frmsvg");if(void 0!==e.dataset.displaySliders&&null!==n){var i=this.getSliderGroupItems(e);n.addEventListener("click",(function(){i.forEach((function(e){e.classList.toggle(t)}))}))}}},{key:"updateOnUnitChange",value:function(e,t,n){var i=this;e.querySelector("select").addEventListener("change",(function(r){var a=r.target.value.toLowerCase();if(""!==a){if("auto"===a)return e.classList.add("frm-disabled"),i.updateValue(e,"auto"),void i.triggerValueChange(n);e.classList.remove("frm-disabled","frm-empty"),i.options[n].fullValue=t.value+a,i.updateValue(e,i.options[n].fullValue),i.triggerValueChange(n)}else e.classList.add("frm-disabled","frm-empty")}))}},{key:"changeSliderPositionOnClick",value:function(e,t,n){var i=this,r=e.querySelector(".frm-slider"),a=new Event("change",{bubbles:!0,cancelable:!0});r.addEventListener("click",(function(o){if(!e.classList.contains("frm-disabled")&&(o.preventDefault(),o.stopPropagation(),o.target.classList.contains("frm-slider")||o.target.classList.contains("frm-slider-active-track"))){var l=r.offsetWidth-i.sliderBulletWidth,s=r.getBoundingClientRect(),c=o.clientX-s.left-i.sliderBulletWidth,u=e.querySelector("select").value,d=i.calculateValue(l,c,i.getMaxValue(u,n));d<0||(i.options[n].fullValue=i.updateValue(e,d+u),i.initChildSlidersWidth(e,c,n,d+u),t.value=d,t.dispatchEvent(a))}}))}},{key:"getSliderGroupItems",value:function(e){if(void 0===e.dataset.displaySliders)return[];var t=e.dataset.displaySliders.split(",").map((function(e){return'.frm-slider-component[data-type="'.concat(e,'"]')})).join(", ");return e.closest(".frm-style-component").querySelectorAll(t)}},{key:"initSlidersPosition",value:function(){var e=this,t=document.querySelectorAll("#frm_style_sidebar .accordion-section h3"),n=document.querySelector(".frm-quick-settings"),i=document.querySelector(".accordion-section.open");wp.hooks.addAction("frm_pro_on_bg_image_upload","formidable",(function(t){var n=t.closest(".accordion-section-content").querySelector("#frm-bg-image-opacity-slider");e.initSlidersWidth(n)})),null!==n&&this.initSlidersWidth(n),null!==i&&this.initSlidersWidth(i),t.forEach((function(t){t.addEventListener("click",(function(t){e.initSlidersWidth(t.target.closest(".accordion-section"))}))})),this.initSliderPositionOnFieldShapeChange()}},{key:"initSliderPositionOnFieldShapeChange",value:function(){var e=this,t=document.querySelector(".frm-style-component.frm-field-shape");null!==t&&t.querySelectorAll('input[type="radio"]').forEach((function(t){t.addEventListener("change",(function(t){if(t.target.checked&&"rounded-corner"===t.target.value){var n=document.querySelector('div[data-frm-element="field-shape-corner-radius"] .frm-slider-component');e.initSliderWidth(n)}}))}))}},{key:"initSlidersWidth",value:function(e){var t=this;e.querySelectorAll(".frm-slider-component").forEach((function(e){setTimeout((function(){t.initSliderWidth(e)}),100)}))}},{key:"initSliderWidth",value:function(e){if(!e.classList.contains("frm-disabled")){var t=this.getSliderIndex(e),n=e.querySelector(".frm-slider").offsetWidth-this.sliderBulletWidth,i=parseInt(e.querySelector('.frm-slider-value input[type="text"]').value,10),r=e.querySelector("select").value,a="%"===r?Math.round(n*i/100):Math.ceil(i/this.options[t].maxValue*n);e.querySelector(".frm-slider-active-track").style.width="".concat(a,"px"),this.options[t].translateX=a,this.options[t].value=i+r}}},{key:"initChildSlidersWidth",value:function(e,t,n,i){var r=this;(e.classList.contains("frm-has-independent-fields")||e.classList.contains("frm-has-multiple-values"))&&(e.classList.contains("frm-has-independent-fields")?e.querySelectorAll(".frm-independent-slider-field"):this.getSliderGroupItems(e)).forEach((function(e,a){e.querySelector(".frm-slider-active-track").style.width="".concat(t,"px"),r.options[n+a+1].translateX=t,r.options[n+a+1].value=i}))}},{key:"getSliderIndex",value:function(e){return this.options.filter((function(t){return t.element===e}))[0].index}},{key:"moveTracker",value:function(e,t){if(this.options[t].dragging){var n=e.clientX-this.options[t].startX,i=this.sliderElements[t],r=i.querySelector(".frm-slider").offsetWidth;if(!((n=Math.max(n,0))+this.sliderBulletWidth/2+this.sliderMarginRight>=r)){var a=i.querySelector("select").value,o=this.calculateValue(r,n,this.getMaxValue(a,t));i.querySelector('.frm-slider-value input[type="text"]').value=o,i.querySelector(".frm-slider-bullet .frm-slider-value-label").innerText=o,i.querySelector(".frm-slider-active-track").style.width="".concat(n,"px"),this.initChildSlidersWidth(i,n,t,o+a),this.options[t].translateX=n,this.options[t].value=o+a,this.options[t].fullValue=this.updateValue(i,this.options[t].value),this.valueChangeDebouncer(t)}}}},{key:"getMaxValue",value:function(e,t){return"%"===e?100:this.options[t].maxValue}},{key:"enableDragging",value:function(e,t){e.target.classList.add("frm-dragging"),this.options[t].dragging=!0,this.options[t].startX=e.clientX-this.options[t].translateX}},{key:"disableDragging",value:function(e,t){!1!==this.options[e].dragging&&(t.target.classList.remove("frm-dragging"),this.options[e].dragging=!1,this.triggerValueChange(e))}},{key:"triggerValueChange",value:function(e){var t=this;if(null===this.options[e].dependentUpdater){var n=this.sliderElements[e].classList.contains("frm-has-multiple-values")?this.sliderElements[e].closest(".frm-style-component").querySelector('input[type="hidden"]'):this.sliderElements[e].querySelectorAll('.frm-slider-value input[type="hidden"]');n instanceof NodeList?n.forEach((function(n){n.dispatchEvent(t.eventsChange[e])})):n.dispatchEvent(this.eventsChange[e])}else this.options[e].dependentUpdater.updateAllDependentElements(this.options[e].fullValue)}},{key:"calculateValue",value:function(e,t,n){var i=Math.ceil(this.sliderBulletWidth*(t/e)),r=Math.ceil((t+i)/e*n);return Math.min(r,n)}},{key:"updateValue",value:function(e,t){var n=this;if(e.classList.contains("frm-base-font-size")){var i=document.querySelector('input[name="frm_style_setting[post_content][use_base_font_size]"]');null!==i&&(i.value="true")}if(e.classList.contains("frm-has-multiple-values")){var r=e.closest(".frm-style-component").querySelector('input[type="hidden"]'),a=r.value.split(" "),o=e.dataset.type;switch(a[2]||(a[2]="0px"),a[3]||(a[3]="0px"),o){case"vertical":a[0]=t,a[2]=t;break;case"horizontal":a[1]=t,a[3]=t;break;case"top":a[0]=t;break;case"bottom":a[2]=t;break;case"left":a[3]=t;break;case"right":a[1]=t}var l=a.join(" ");return r.value=l,this.getSliderGroupItems(e).forEach((function(e){var i=n.getUnitMeasureFromValue(t);e.querySelector('.frm-slider-value input[type="text"]').value=parseInt(t,10),e.querySelector("select").value=i})),l}if(e.classList.contains("frm-has-independent-fields")){var s=e.querySelectorAll('.frm-slider-value input[type="hidden"]'),c=e.querySelectorAll('.frm-slider-value input[type="text"]');return s.forEach((function(e,n){e.value=t,c[n+1].value=parseInt(t,10)})),t}return e.querySelector('.frm-slider-value input[type="hidden"]').value=t,t}},{key:"getUnitMeasureFromValue",value:function(e){return["%","px","em"].find((function(t){return e.includes(t)}))||""}}])&&y(e.prototype,n),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,n}();function S(e){return S="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},S(e)}function k(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,E(i.key),i)}}function E(e){var t=function(e){if("object"!=S(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=S(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==S(t)?t:t+""}var w=function(){return e=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),void 0!==t&&(this.wrapper=t instanceof Element?t:document.querySelector(t),null!==this.wrapper&&(this.flexboxSlidesGap="16px",this.navs=this.wrapper.querySelectorAll(".frm-tabs-navs ul > li"),this.slideTrackLine=this.wrapper.querySelector(".frm-tabs-active-underline"),this.slideTrack=this.wrapper.querySelector(".frm-tabs-slide-track"),this.slides=this.wrapper.querySelectorAll(".frm-tabs-slide-track > div"),this.isRTL="rtl"===document.documentElement.dir||"rtl"===document.body.dir,this.resizeObserver=null,this.init()))},(t=[{key:"init",value:function(){var e=this;null!==this.wrapper&&this.navs.length&&null!==this.slideTrackLine&&null!==this.slideTrack&&this.slides.length&&(this.initDefaultSlideTrackerWidth(),this.navs.forEach((function(t,n){t.addEventListener("click",(function(t){return e.onNavClick(t,n)}))})),this.setupScrollbarObserver(),window.addEventListener("beforeunload",this.cleanupObservers))}},{key:"onNavClick",value:function(e,t){var n=e.currentTarget;e.preventDefault(),this.removeActiveClassnameFromNavs(),n.classList.add("frm-active"),this.initSlideTrackUnderline(n,t),this.changeSlide(t);var i,r,a=n.querySelector("a");a&&"frm_insert_fields_tab"===a.id&&!a.closest("#frm_adv_info")&&(null===(i=window.frmAdminBuild)||void 0===i||null===(r=i.clearSettingsBox)||void 0===r||r.call(i))}},{key:"initDefaultSlideTrackerWidth",value:function(){this.slideTrackLine.dataset.initialWidth&&(this.slideTrackLine.style.width="".concat(this.slideTrackLine.dataset.initialWidth,"px"))}},{key:"initSlideTrackUnderline",value:function(e,t){this.slideTrackLine.classList.remove("frm-first","frm-last");var n=void 0!==e?e:this.navs.filter((function(e){return e.classList.contains("frm-active")}));this.positionUnderlineIndicator(n)}},{key:"setupScrollbarObserver",value:function(){var e=this,t=this.wrapper.closest(".frm-scrollbar-wrapper");t&&"ResizeObserver"in window&&(this.resizeObserver=new ResizeObserver((function(){var t=e.wrapper.querySelector(".frm-tabs-navs ul > li.frm-active");t&&e.positionUnderlineIndicator(t)})),this.resizeObserver.observe(t))}},{key:"cleanupObservers",value:function(){this.resizeObserver&&(this.resizeObserver.disconnect(),this.resizeObserver=null)}},{key:"positionUnderlineIndicator",value:function(e){var t=this;requestAnimationFrame((function(){var n=t.isRTL?-(e.parentElement.offsetWidth-e.offsetLeft-e.offsetWidth):e.offsetLeft;t.slideTrackLine.style.transform="translateX(".concat(n,"px)"),t.slideTrackLine.style.width=e.clientWidth+"px"}))}},{key:"changeSlide",value:function(e){this.removeActiveClassnameFromSlides();var t=0==e?"0px":"calc( ( ".concat(100*e,"% + ").concat(parseInt(this.flexboxSlidesGap,10)*e,"px ) * ").concat(this.isRTL?1:-1," )");"0px"!==t?this.slideTrack.style.transform="translateX(".concat(t,")"):this.slideTrack.style.removeProperty("transform"),e in this.slides&&this.slides[e].classList.add("frm-active")}},{key:"removeActiveClassnameFromSlides",value:function(){this.slides.forEach((function(e){return e.classList.remove("frm-active")}))}},{key:"removeActiveClassnameFromNavs",value:function(){this.navs.forEach((function(e){return e.classList.remove("frm-active")}))}}])&&k(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();function L(e){return L="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},L(e)}function q(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,x(i.key),i)}}function x(e){var t=function(e){if("object"!=L(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=L(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==L(t)?t:t+""}var C=function(){return e=function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.elements=document.querySelectorAll(".frm-style-tabs-wrapper"),0<this.elements.length&&this.init()},(t=[{key:"init",value:function(){this.elements.forEach((function(e){new w(e)}))}},{key:"initOnTabClick",value:function(e){var t=this;this.initActiveBackgroundWidth(e),e.querySelectorAll(".frm-tab-item").forEach((function(e){e.addEventListener("click",(function(e){t.onTabClick(e.target.closest(".frm-tabs-wrapper"))}))}))}}])&&q(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}(),A="frm-token-container",T="frm-tokens",O="frm-token",_="frm-token-value",P="frm-token-remove",V="frm-token-proxy-input",W=window.frmDom,j=W.span,D=W.svg,I=W.tag;function R(){document.querySelectorAll(".".concat(A)).forEach((function(e){return M(e.querySelector(".".concat(V)),e.querySelector(".".concat(T)))}))}function M(e,t){if(e&&t){var n=t.querySelectorAll(".".concat(O));if(!(n.length>0))return e.style.paddingLeft="",e.style.paddingTop="",void(e.style.height="");var i=t.offsetHeight;if(Math.max(1,Math.ceil(i/36))>1){var r=function(e){if(!e.length)return 0;var t=0;return e.forEach((function(e){t+=e.offsetWidth})),(t+=4*(e.length-1))+4}(function(e){if(!e.length)return[];var t=Array.from(e),n=-1;t.forEach((function(e){var t=e.getBoundingClientRect().bottom;t>n&&(n=t)}));return t.filter((function(e){var t=e.getBoundingClientRect();return Math.abs(t.bottom-n)<=2}))}(n));e.style.height="".concat(i,"px"),e.style.paddingTop="".concat(i-36+4,"px"),e.style.paddingLeft=r?"".concat(r+8,"px"):""}else e.style.height="",e.style.paddingTop="",e.style.paddingLeft="".concat(t.offsetWidth-4,"px")}}function B(e,t,n){e&&n&&t&&(n.innerHTML="",N(e).forEach((function(e){return function(e,t){var n=j({className:O,children:[j({text:e,className:_}),j({className:P,child:D({href:"#frm_close_icon"})})]});t.appendChild(n)}(e,n)})),M(t,n),t.focus())}function F(e,t,n){if(!e||!t||!n)return!1;var i=N(t.value);return i.includes(e)?(z(n),!1):(i.push(e),U(t,i),z(n),!0)}function X(e,t,n){if(e&&t&&n){var i=e.querySelector(".".concat(_)).textContent;U(t,N(t.value).filter((function(e){return e!==i}))),e.remove(),n.focus()}}function N(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return(e=e.trim())?e.split(/\s+/).filter(Boolean):[]}function U(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];e&&(e.value=t.join(" "),jQuery(e).trigger("change"))}function z(e){e&&(e.value="",e.focus())}function G(e){var n=(e?document.getElementById("frm-single-settings-".concat(e)):document.body).querySelectorAll(".".concat("frm-token-input-field"));if(n.length){var i=new Set;n.forEach((function(e){i.has(e.id)||(function(e){var n=function(e){var n=e.closest(".".concat("frm-with-right-icon"));if(n.querySelector(".".concat(T)))return null;n.classList.add(A);var i=j({className:T});n.insertBefore(i,n.firstChild);var r=I("input",{className:V,id:"".concat(e.id,"-proxy-input")});return r.type="text",e.parentNode.insertBefore(r,e.nextSibling),e.classList.add(t),n}(e);if(n){var i=n.querySelector(".".concat(V)),r=n.querySelector(".".concat(T));B(e.value,i,r),function(e,t,n){jQuery(e).on("change",(function(){return B(e.value,t,n)})),t.addEventListener("keydown",(function(i){return function(e,t,n,i){var r=e.key,a=n.value.trim();switch(r){case"Backspace":a||(e.preventDefault(),X(i.querySelector(".".concat(O,":last-child")),t,n));break;case" ":case",":case"Enter":e.preventDefault(),F(a,t,n)}M(n,i)}(i,e,t,n)})),t.addEventListener("blur",(function(){return F(t.value.trim(),e,t)})),n.addEventListener("click",(function(n){return function(e,t,n){var i=e.target.closest(".".concat(P));if(i){var r=i.closest(".".concat(O));if(r){var a=r.parentElement;X(r,t,n),M(n,a)}}}(n,e,t)}))}(e,i,r)}}(e),i.add(e.id))}))}}var J,H="frm-toggle-group",Q="frm_toggle_block",K="data-group-name";function Y(e){var t=e.target,n=t.closest(".".concat(H));n&&Z(t,n)}function Z(e,i){var r,a=(null===(r=i.closest(".".concat("frm-single-settings")))||void 0===r?void 0:r.dataset.fid)||i.dataset.fid,o=e.checked,l=e.getAttribute("data-show");l&&document.querySelectorAll($(l,a)).forEach((function(e){return e.classList.toggle(t,!o)}));var s=e.getAttribute("data-disable");s&&document.querySelectorAll($(s,a)).forEach((function(e){e.classList.toggle(n,o),e.querySelectorAll("input, select, textarea").forEach((function(e){return e.disabled=o})),e.querySelectorAll(".frm-show-inline-modal[tabindex]").forEach((function(e){return e.tabIndex=o?-1:0}))}));var c=e.getAttribute("data-enable");c&&document.querySelectorAll($(c,a)).forEach((function(e){return e.classList.toggle(n,!o)}));var u=e.closest(".".concat(Q));Array.from(i.querySelectorAll(".".concat(Q))).filter((function(e){return e!==u})).forEach((function(e){e.classList.toggle(n,o);var t=e.querySelector(".frm_toggle");t.tabIndex=o?-1:0,t.setAttribute("aria-disabled",o)}))}function $(e,t){return e.replace(/{id}/g,t)}function ee(e){var t=e.target.closest(".frm-unit-input"),n=t.querySelector(".frm-unit-input-control"),i=t.querySelector("select").value;e.target.matches("select")&&(n.type=""===i?"text":"number");var r=n.value.trim();t.querySelector('input[type="hidden"]').value=""!==r?r+i:""}J=function(){var e,t;new d,new b,new C,null===(t=document.getElementById("frm-form-add-field"))||void 0===t||t.addEventListener("click",(function(e){var t;e.preventDefault(),null===(t=document.querySelector(".frm-settings-panel .frm-tabs-navs ul > li:first-child"))||void 0===t||t.click()})),G(),document.addEventListener("frm_added_field",(function(e){return G(e.frmField.dataset.fid)})),document.addEventListener("frm_ajax_loaded_field",(function(e){return e.frmFields.forEach((function(e){return G(e.id)}))})),wp.hooks.addAction("frmShowedFieldSettings","formidable-token-input",R),(e=document.querySelectorAll(".".concat(H))).length&&e.forEach((function(e){var t=e.querySelector("[".concat(K,"]:checked"));t&&Z(t,e)})),o("change",".".concat(H," [").concat(K,"]"),Y),o("change",".frm-unit-input .frm-unit-input-control",ee),o("change",".frm-unit-input select",ee)},"undefined"!=typeof document&&("complete"!==document.readyState&&"interactive"!==document.readyState?document.addEventListener("DOMContentLoaded",J):J())})(); No newline at end of file
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

Avoid calling filter directly on NodeList in initSlideTrackUnderline.

this.navs comes from querySelectorAll, so it’s a NodeList without filter in many environments. The fallback path this.navs.filter(...) will throw if ever used without an explicit nav arg.

Suggested source-level change
initSlideTrackUnderline( nav, index ) {
-  this.slideTrackLine.classList.remove( 'frm-first', 'frm-last' );
-  const targetNav = nav !== undefined
-    ? nav
-    : this.navs.filter( ( el ) => el.classList.contains( 'frm-active' ) );
-  this.positionUnderlineIndicator( targetNav );
+  this.slideTrackLine.classList.remove( 'frm-first', 'frm-last' );
+
+  let targetNav = nav;
+  if ( ! targetNav ) {
+    targetNav = Array.from( this.navs ).find( ( el ) =>
+      el.classList.contains( 'frm-active' )
+    );
+  }
+
+  if ( targetNav ) {
+    this.positionUnderlineIndicator( targetNav );
+  }
}

Committable suggestion skipped: line range outside the PR's diff.

🧰 Tools
🪛 Biome (2.1.2)

[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

🤖 Prompt for AI Agents
In js/formidable-settings-components.js around lines 1 to 1,
initSlideTrackUnderline uses this.navs.filter(...) but this.navs is a NodeList
(from querySelectorAll) which may not implement filter in all environments;
convert the NodeList to an Array before calling filter (e.g.
Array.from(this.navs).filter(...) or [...this.navs].filter(...)) and use that
array for the subsequent logic so the fallback path never throws.

Comment thread js/src/admin/admin.js Outdated
Comment on lines 6815 to 6816
field.className = field.className.replace(/\s+/g, ' ').replace( replace, replaceWith );
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

changeFieldClass: whitespace normalization order can break replacements + fix ESLint spacing.

The new line:

field.className = field.className.replace(/\s+/g, ' ').replace( replace, replaceWith );

has two issues:

  1. Behavioral bug with the “no existing classes” branch
    In the classes.trim() === '' path you set:

    replace = ' frmstart  frmend ';
    if ( -1 === field.className.indexOf( replace ) ) {
    	replace = ' frmstart frmend ';
    }

    If field.className currently contains ' frmstart frmend ', then:

    • replace is ' frmstart frmend '.
    • field.className.replace(/\s+/g, ' ') normalizes this to ' frmstart frmend '.
    • The subsequent .replace( replace, replaceWith ) no longer finds ' frmstart frmend ', so the replacement never happens and the new classes are not applied.

    To avoid this, do the semantic replacement first, then normalize whitespace:

  • field.className = field.className.replace(/\s+/g, ' ').replace( replace, replaceWith );
  • field.className = field.className.replace( replace, replaceWith )
  • .replace( /\s+/g, ' ' );

2. **ESLint `space-in-parens`**  
The regex call should follow the local spacing convention:

```diff
- .replace(/\s+/g, ' ')
+ .replace( /\s+/g, ' ' )

This keeps the new normalization behavior while preserving the original replacement logic and fixes the lint error.

🧰 Tools
🪛 GitHub Check: Run ESLint

[failure] 6815-6815:
There must be a space before this paren


[failure] 6815-6815:
There must be a space after this paren

🤖 Prompt for AI Agents
In js/src/admin/admin.js around lines 6815-6816, the current line normalizes
whitespace before doing the semantic class replacement which can break matching
when multiple spaces exist, and it also violates ESLint space-in-parens; change
the order to perform the .replace(replace, replaceWith) first and then normalize
whitespace with .replace(/\s+/g, ' '), and remove the extra spaces inside the
.replace(...) call so there are no spaces after the opening paren or before the
closing paren.

Comment thread js/welcome-tour.js Outdated
@AbdiTolesa
Copy link
Copy Markdown
Contributor Author

@AbdiTolesa These issues are easier reproduced when the form has not yet been saved or updated. After saving or updating the form, the section fields realign to the expected widths (https://www.loom.com/share/af6b08881a924d76a287af21e660a5a4) Let me know if you can reproduce it!

@lauramekaj1 Thanks for mentioning that I should test before saving the fields! I was able to reproduce those issues and have worked on fixing them. Could you give it another around of test from your end?

@lauramekaj1
Copy link
Copy Markdown
Contributor

@lauramekaj1 Thanks for mentioning that I should test before saving the fields! I was able to reproduce those issues and have worked on fixing them. Could you give it another around of test from your end?

@AbdiTolesa thank you for addressing the issues. I tested the fixes and now it's working fine. However I noticed this error shown on forms, entries, styles and some other pages:
image

@AbdiTolesa
Copy link
Copy Markdown
Contributor Author

@AbdiTolesa thank you for addressing the issues. I tested the fixes and now it's working fine. However I noticed this error shown on forms, entries, styles and some other pages:

Thanks @lauramekaj1! That error likely isn't related to this update since this update only includes JS files update but that error is coming from PHP. I need your confirmation on that too by switching to the master branch since I don't see that error in the main branch or this one. Could you create a new issue to track that with the steps needed, if you can still reproduce that error?

@AbdiTolesa AbdiTolesa requested a review from truongwp January 1, 2026 11:09
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

♻️ Duplicate comments (2)
js/src/admin/admin.js (2)

2334-2406: Use the actually inserted <li> for drag/layout logic in duplicateField (current code still targets the wrong node + risks classList.add('')).

The new getLiElement helper correctly picks the inner li[data-ftype="divider"] when duplicating section fields, but the success callback still uses replaceWith.get( 0 ) for makeDraggable and for setLayoutClassesForDuplicatedFieldInGroup. In divider cases, that means:

  • You append newField = getLiElement( replaceWith ) into the DOM,
    but
  • You attach draggable and layout syncing to replaceWith.get( 0 ), which may never be inserted.

This can leave the real duplicated field non‑draggable and mis‑synced for layout, especially when duplicating section fields in a group or into newRowId.

Additionally, in the $field.siblings( 'li.form-field' ).length branch, you call:

const layoutClass = getLayoutClassName( $field.get( 0 ).classList );
if ( ! newField.get( 0 ).classList.contains( layoutClass ) ) {
	newField.get( 0 ).classList.add( layoutClass );
}

If getLayoutClassName returns '' (no layout class), this becomes classList.add( '' ), which throws a DOMException in browsers.

Finally, the wrapFieldLi branch now does:

replaceWith = wrapFieldLi( msg );
$field.parent().parent().after( getLiElement( replaceWith ) );
makeDroppable( replaceWith.get( 0 ).querySelector( 'ul.frm_sorting' ) );
makeDraggable( replaceWith.get( 0 ).querySelector( 'li.form-field' ), '.frm-move' );

For divider responses, getLiElement( replaceWith ) returns the inner li[data-ftype="divider"], so you append only that li while still configuring droppable/draggable on the wrapper replaceWith (which was never inserted), leading to inconsistent structure vs. the rest of the builder.

Consider tightening this logic so all downstream calls operate on the actual inserted element, and keep wrapFieldLi semantics unchanged for the “new row” case. One way to do this with minimal behavior change:

  • Track a newFieldEl that always points to the element actually inserted.
  • Use getLiElement only in the newRowId and “has siblings” branches (where you truly want the inner divider li).
  • Guard against empty layoutClass before calling contains/add.
Proposed refactor for duplicateField success handler
 function duplicateField() {
@@
-		jQuery.ajax( {
+		jQuery.ajax( {
 			type: 'POST',
 			url: ajaxurl,
@@
-			success: function( msg ) {
-				let newRow;
-
-				let replaceWith;
+			success: function( msg ) {
+				let newRow;
+				let replaceWith;
+				let newFieldEl;
@@
 				if ( null !== newRowId ) {
 					newRow = document.getElementById( newRowId );
 					if ( null !== newRow ) {
 						replaceWith = msgAsjQueryObject( msg );
-						const newField = getLiElement( replaceWith );
-
-						jQuery( newRow ).append( newField );
-
-						makeDraggable( replaceWith.get( 0 ), '.frm-move' );
+						const newField = getLiElement( replaceWith );
+
+						jQuery( newRow ).append( newField );
+
+						newFieldEl = newRow.lastElementChild;
+						if ( newFieldEl ) {
+							makeDraggable( newFieldEl, '.frm-move' );
+							setLayoutClassesForDuplicatedFieldInGroup( $field.get( 0 ), newFieldEl );
+						}
 						if ( null !== fieldOrder ) {
 							newRow.lastElementChild.setAttribute( 'frm-field-order', fieldOrder );
@@
 						);
 						afterAddField( msg, false );
-						setLayoutClassesForDuplicatedFieldInGroup( $field.get( 0 ), replaceWith.get( 0 ) );
 						return;
 					}
 				}
@@
 				if ( $field.siblings( 'li.form-field' ).length ) {
 					replaceWith = msgAsjQueryObject( msg );
 					const newField = getLiElement( replaceWith );
-					$field.after( newField );
-					syncLayoutClasses( $field );
-					makeDraggable( replaceWith.get( 0 ), '.frm-move' );
-
-					const layoutClass = getLayoutClassName( $field.get( 0 ).classList );
-					if ( ! newField.get( 0 ).classList.contains( layoutClass ) ) {
-						newField.get( 0 ).classList.add( layoutClass );
-					}
+					$field.after( newField );
+					syncLayoutClasses( $field );
+
+					newFieldEl = newField.get( 0 );
+					if ( newFieldEl ) {
+						makeDraggable( newFieldEl, '.frm-move' );
+
+						const layoutClass = getLayoutClassName( $field.get( 0 ).classList );
+						if ( layoutClass && ! newFieldEl.classList.contains( layoutClass ) ) {
+							newFieldEl.classList.add( layoutClass );
+						}
+					}
 				} else {
-					replaceWith = wrapFieldLi( msg );
-					$field.parent().parent().after( getLiElement( replaceWith ) );
+					// When duplicating into a new row, keep the existing wrapFieldLi behavior.
+					replaceWith = wrapFieldLi( msg );
+					$field.parent().parent().after( replaceWith );
+					newFieldEl = replaceWith.get( 0 );
 					makeDroppable( replaceWith.get( 0 ).querySelector( 'ul.frm_sorting' ) );
 					makeDraggable( replaceWith.get( 0 ).querySelector( 'li.form-field' ), '.frm-move' );
 				}
@@
 				updateFieldOrder();
 				afterAddField( msg, false );
 				maybeDuplicateUnsavedSettings( fieldId, msg );
 				toggleOneSectionHolder( replaceWith.find( '.start_divider' ) );
 				$field[ 0 ].querySelector( '.frm-dropdown-menu.dropdown-menu-right' )?.classList.remove( 'show' );
-				setLayoutClassesForDuplicatedFieldInGroup( $field.get( 0 ), replaceWith.get( 0 ) );
+				if ( newFieldEl ) {
+					setLayoutClassesForDuplicatedFieldInGroup( $field.get( 0 ), newFieldEl );
+				}
 			}
 		} );

This keeps getLiElement where it is needed for section duplication, but ensures all draggable/layout operations run on the actual DOM node the user sees, and avoids classList.add('') exceptions.


6814-6815: Fix changeFieldClass replacement order to avoid breaking the “no existing classes” path.

changeFieldClass still normalizes whitespace before doing the semantic replacement:

field.className = field.className.replace( /\s+/g, ' ' ).replace( replace, replaceWith );

In the classes.trim() === '' branch, replace can be ' frmstart frmend ', but .replace( /\s+/g, ' ' ) first collapses that to ' frmstart frmend ', so the subsequent .replace( replace, replaceWith ) no longer matches and the new classes aren’t applied.

Flip the order so you replace the semantic token first, then normalize:

Proposed fix
-		field.className = field.className.replace( /\s+/g, ' ' ).replace( replace, replaceWith );
+		field.className = field.className
+			.replace( replace, replaceWith )
+			.replace( /\s+/g, ' ' );

This preserves the intended class substitution while still collapsing extra whitespace and stays within your ESLint spacing rules.

📜 Review details

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between f2207d9 and f7677e3.

📒 Files selected for processing (3)
  • css/frm_testing_mode.css
  • js/formidable_admin.js
  • js/src/admin/admin.js
🧰 Additional context used
🪛 Biome (2.1.2)
css/frm_testing_mode.css

[error] 3-3: Duplicate properties can lead to unexpected behavior and may override previous declarations unintentionally.

text-align is already defined here.

Remove or rename the duplicate property to ensure consistent styling.

(lint/suspicious/noDuplicateProperties)


[error] 3-3: Duplicate properties can lead to unexpected behavior and may override previous declarations unintentionally.

min-width is already defined here.

Remove or rename the duplicate property to ensure consistent styling.

(lint/suspicious/noDuplicateProperties)


[error] 3-3: Duplicate properties can lead to unexpected behavior and may override previous declarations unintentionally.

border-radius is already defined here.

Remove or rename the duplicate property to ensure consistent styling.

(lint/suspicious/noDuplicateProperties)

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (3)
  • GitHub Check: Cypress
  • GitHub Check: PHP 8 tests in WP 6.9
  • GitHub Check: PHP 7.4 tests in WP 6.9

@lauramekaj1
Copy link
Copy Markdown
Contributor

Thanks @lauramekaj1! That error likely isn't related to this update since this update only includes JS files update but that error is coming from PHP. I need your confirmation on that too by switching to the master branch since I don't see that error in the main branch or this one. Could you create a new issue to track that with the steps needed, if you can still reproduce that error?

@AbdiTolesa I wasn't able to reproduce the PHP error again. But I tested the other fixes and it's working fine now. Thank you!

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

Fix all issues with AI Agents 🤖
In @css/font_icons.css:
- Around line 36-41: Remove the deprecated speak: none declaration from the
i.frmfont and i.frm_icon_font rules in resources/scss/font_icons.scss; locate
the selectors i.frmfont and i.frm_icon_font and delete the line containing
"speak: none" (or the entire property) so the stylesheet no longer uses the
deprecated property while leaving font-style and font-variant intact.

In @js/formidable_overlay.js:
- Around line 430-443: The overlay script formidable_overlay.js destructures
from the global frmDom but the PHP asset registration in
FrmOverlayController::register_assets() does not list the formidable_dom
dependency, causing load order issues; update the dependency array passed when
registering the formidable-overlay script from array() to
array('formidable_dom') so the formidable_dom bundle (which exposes
window.frmDom) is enqueued and loaded before formidable_overlay.js.
- Around line 198-200: The script registration for the overlay is missing the
dependency on the script that exposes window.frmGlobal, so add
'formidable_admin_global' to the dependency array in the wp_register_script call
(the registration in FrmOverlayController.php around the wp_register_script for
the overlay script/handle) so that the localized object is guaranteed to load
before formidable_overlay.js; update the dependencies array for the overlay
handle (verify the handle name used in wp_register_script) to include
'formidable_admin_global'.
♻️ Duplicate comments (6)
js/formidable_dashboard.js (1)

1-961: Previous review comments comprehensively cover all issues; no new concerns identified.

This webpack-generated bundle has been thoroughly reviewed in previous comments, which document:

  1. Biome lint exclusion needed for generated Babel helpers (lines 15, 83, 285, 588, 848)
  2. Three runtime errors in source files requiring fixes:
    • Unbound cleanupObservers method in js/src/components/class-tabs-navigator.js
    • NodeList .filter() error in js/src/components/class-tabs-navigator.js
    • Missing null checks in js/src/dashboard.js

The previous comprehensive comment (tagged with fingerprint phantom:poseidon:puma) provides exact source file locations and specific fixes for each issue. Those recommendations remain valid.

I've scanned the current bundle and confirmed no additional runtime errors, logic bugs, or security issues exist beyond those already documented. The modular structure and dashboard initialization logic follow appropriate patterns.

js/formidable_overlay.js (5)

16-16: Biome lint errors on generated Babel helpers already addressed.

The _typeof reassignment errors at lines 16, 224, and 527 are expected Babel helper patterns in this webpack bundle. As noted in a previous review, add a suppression comment or exclude js/ from Biome linting.


49-61: Duplicate overlay stacking concern already raised.

The previous review correctly identified that open() should call this.close() first to prevent stacking overlays.


81-90: Accessibility concern for close button already raised.

The previous review correctly identified that the <span> close button should be a <button> with proper keyboard accessibility.


140-151: XSS concern with innerHTML already raised.

The previous review correctly identified the potential XSS vector when assigning this.overlayData.copy to innerHTML.


346-348: Double-execution bug in addToRequestQueue already raised.

The previous review correctly identified that .then(task).catch(task) will execute task twice if it rejects.

🧹 Nitpick comments (1)
js/formidable_overlay.js (1)

534-535: Module-level URL state may not reflect current page URL after navigation.

url and urlParams are captured once at module load. If the page URL changes externally (e.g., browser back/forward, manual history.pushState), these helpers will operate on stale data. Consider re-parsing window.location.href when needed, or document this limitation.

📜 Review details

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between f7677e3 and 12f8738.

⛔ Files ignored due to path filters (1)
  • js/formidable_admin.js.map is excluded by !**/*.map, !**/*.map
📒 Files selected for processing (17)
  • css/admin/frm-settings-components.css
  • css/admin/welcome-tour.css
  • css/font_icons.css
  • css/frm_admin.css
  • css/frm_testing_mode.css
  • js/addons-page.js
  • js/form-templates.js
  • js/formidable-settings-components.js
  • js/formidable_admin.js
  • js/formidable_blocks.js
  • js/formidable_dashboard.js
  • js/formidable_overlay.js
  • js/formidable_styles.js
  • js/frm_testing_mode.js
  • js/onboarding-wizard.js
  • js/src/admin/admin.js
  • js/welcome-tour.js
🚧 Files skipped from review as they are similar to previous changes (1)
  • js/src/admin/admin.js
🧰 Additional context used
🧬 Code graph analysis (2)
js/formidable_dashboard.js (6)
js/src/components/class-counter.js (1)
  • frmCounter (1-46)
js/src/components/class-tabs-navigator.js (1)
  • frmTabsNavigator (1-135)
js/src/core/utils/animation.js (1)
  • frmAnimate (1-76)
js/src/core/utils/error.js (1)
  • span (26-26)
js/src/core/utils/globalModules.js (1)
  • bold (6-6)
js/src/dashboard.js (1)
  • frmDashboardClass (91-91)
js/formidable_overlay.js (3)
js/src/components/class-overlay.js (1)
  • frmOverlay (6-133)
js/src/core/utils/animation.js (1)
  • frmAnimate (1-76)
js/src/core/utils/error.js (3)
  • inputElement (16-16)
  • errorElement (17-17)
  • span (26-26)
🪛 Biome (2.1.2)
js/formidable_dashboard.js

[error] 15-15: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 83-83: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 285-285: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 588-588: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 848-848: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

js/formidable_overlay.js

[error] 16-16: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 224-224: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 527-527: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

🔇 Additional comments (9)
css/admin/welcome-tour.css (1)

1-152: Generated CSS file - LGTM.

This is a Webpack-compiled output from the SCSS source. The styles for the welcome tour checklist and spotlight components are well-structured, use CSS custom properties appropriately, and include proper transitions. Any modifications should be made in the source file resources/scss/admin/welcome-tour.scss.

css/font_icons.css (1)

1-88: Generated CSS file - approve with minor note above.

This Webpack-compiled CSS from the SCSS source provides standard font icon styling. The @font-face declaration and icon classes follow established patterns. Source modifications should be made in resources/scss/font_icons.scss.

css/admin/frm-settings-components.css (2)

10-12: Selector includes .js class suffix - verify intent.

The selector .formidable_page_formidable-styles.js combines two classes where .js appears to be a JavaScript-enabled indicator class (common pattern where JS adds a js class to body). Confirm this is intentional in the source SCSS and that the corresponding JS properly adds this class.


1-627: Generated CSS file - LGTM.

This is a comprehensive Webpack-compiled stylesheet for Formidable Forms settings components. The CSS is well-organized with clear section headers, uses CSS custom properties consistently, and implements performant animations (transform/opacity). The !important declarations are appropriate for overriding WordPress admin defaults. Source modifications should be made in resources/scss/admin/frm-settings-components.scss.

js/formidable_overlay.js (5)

230-323: Animation utility class looks well-structured.

The frmAnimate class handles both single elements and collections, with proper animation cleanup via the once: true event listener option.


377-403: Error display utility is well-implemented.

Proper null checks, clean once: true pattern for auto-hide on user input. No issues here.


618-640: Validation utilities are functional.

The validation helpers work correctly. Minor note: isHTMLElement has a side effect (console.warn) which may not always be desirable, but this is acceptable for the current use case.


670-719: Visibility utilities are clean and defensive.

Good use of optional chaining for null safety. The implementation correctly handles both single elements and collections.


783-788: Entry point correctly exposes overlay instance globally.

The bundle properly assigns the frmOverlay instance to window.frmOverlay for external access.

Comment thread css/font_icons.css Outdated
Comment on lines +36 to +41
i.frmfont,
i.frm_icon_font {
font-style: normal;
font-variant: normal;
speak: none;
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Deprecated CSS property speak: none.

The speak property (line 40) is deprecated and no longer part of the CSS specification. Modern screen readers ignore this property. Consider removing it from the source SCSS file (resources/scss/font_icons.scss) if it's not needed for legacy support.

🤖 Prompt for AI Agents
In @css/font_icons.css around lines 36-41, Remove the deprecated speak: none
declaration from the i.frmfont and i.frm_icon_font rules in
resources/scss/font_icons.scss; locate the selectors i.frmfont and
i.frm_icon_font and delete the line containing "speak: none" (or the entire
property) so the stylesheet no longer uses the deprecated property while leaving
font-style and font-variant intact.

Comment thread js/formidable_overlay.js Outdated
Comment on lines +198 to +200
var _window$frmGlobal = window.frmGlobal,
PLUGIN_URL = _window$frmGlobal.url,
nonce = _window$frmGlobal.nonce;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Search for frmGlobal references in PHP files to understand how it's provided
rg "frmGlobal" --type=php -B2 -A2 | head -100

Repository: Strategy11/formidable-forms

Length of output: 642


🏁 Script executed:

#!/bin/bash
# Also check for any script localization or window global setup
rg "window\.frmGlobal\|wp_localize_script\|wp_enqueue_script" --type=php -B1 -A1 | head -100

Repository: Strategy11/formidable-forms

Length of output: 53


🏁 Script executed:

#!/bin/bash
# Check the formidable_overlay.js file for context around lines 198-200
wc -l js/formidable_overlay.js

Repository: Strategy11/formidable-forms

Length of output: 99


🏁 Script executed:

#!/bin/bash
# View the context around the problematic lines
sed -n '190,210p' js/formidable_overlay.js

Repository: Strategy11/formidable-forms

Length of output: 1004


🏁 Script executed:

#!/bin/bash
# Find where formidable_overlay.js is enqueued and check its dependencies
rg "formidable_overlay|formidable_admin_global" --type=php -B2 -A2 | head -150

Repository: Strategy11/formidable-forms

Length of output: 2406


🏁 Script executed:

#!/bin/bash
# Check the beginning of formidable_overlay.js to see if it's a webpack bundle
head -20 js/formidable_overlay.js

Repository: Strategy11/formidable-forms

Length of output: 157


🏁 Script executed:

#!/bin/bash
# Search for all script enqueue calls in the helpers directory
rg "wp_enqueue_script.*formidable" --type=php -B1 -A3 | head -100

Repository: Strategy11/formidable-forms

Length of output: 7025


🏁 Script executed:

#!/bin/bash
# Search for where formidable_overlay.js is enqueued and what dependencies might be added
rg "formidable_overlay" --type=php -B3 -A3

Repository: Strategy11/formidable-forms

Length of output: 755


🏁 Script executed:

#!/bin/bash
# Also check FrmOverlayController.php for the complete registration and enqueue logic
grep -n "formidable_overlay\|wp_enqueue_script\|wp_register_script" classes/controllers/FrmOverlayController.php | head -30

Repository: Strategy11/formidable-forms

Length of output: 361


Add formidable_admin_global as a script dependency.

The script is registered with an empty dependency array in FrmOverlayController.php line 175, but the code destructures from window.frmGlobal (created by wp_localize_script on the formidable_admin_global script). Without an explicit dependency declaration, there is no guaranteed load order. If formidable_overlay.js loads before formidable_admin_global, destructuring will fail with TypeError: Cannot destructure property 'url' of 'window.frmGlobal' as it is undefined.

Add 'formidable_admin_global' to the dependency array in the wp_register_script call.

🤖 Prompt for AI Agents
In @js/formidable_overlay.js around lines 198-200, The script registration for
the overlay is missing the dependency on the script that exposes
window.frmGlobal, so add 'formidable_admin_global' to the dependency array in
the wp_register_script call (the registration in FrmOverlayController.php around
the wp_register_script for the overlay script/handle) so that the localized
object is guaranteed to load before formidable_overlay.js; update the
dependencies array for the overlay handle (verify the handle name used in
wp_register_script) to include 'formidable_admin_global'.

Comment thread js/formidable_overlay.js Outdated
Comment on lines +430 to +443
var _frmDom = frmDom,
div = _frmDom.div,
span = _frmDom.span,
tag = _frmDom.tag,
a = _frmDom.a,
img = _frmDom.img,
svg = _frmDom.svg;
var _frmDom$modal = frmDom.modal,
maybeCreateModal = _frmDom$modal.maybeCreateModal,
footerButton = _frmDom$modal.footerButton;
var _frmDom$util = frmDom.util,
onClickPreventDefault = _frmDom$util.onClickPreventDefault,
documentOn = _frmDom$util.documentOn;
var doJsonPost = frmDom.ajax.doJsonPost;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Search for where frmDom is defined
echo "=== Searching for frmDom definition ==="
rg "frmDom\s*=" --type=js -B2 -A2 | head -50

echo ""
echo "=== Searching for formidable_overlay in PHP files ==="
rg "formidable_overlay" --type=php -B2 -A2 | head -50

Repository: Strategy11/formidable-forms

Length of output: 3351


🏁 Script executed:

#!/bin/bash
# Search for script enqueuing patterns
echo "=== Searching for wp_enqueue_script patterns ==="
rg "wp_enqueue_script" --type=php -B1 -A1 | grep -E "(formidable|frmDom)" -B1 -A1 | head -40

echo ""
echo "=== Check for global frmDom assignment ==="
rg "window\.frmDom|globalThis\.frmDom|var frmDom" --type=js -B2 -A2 | head -40

Repository: Strategy11/formidable-forms

Length of output: 4399


🏁 Script executed:

#!/bin/bash
# Search for formidable_dom registration
echo "=== Searching for formidable_dom or dom.js registration ==="
rg "formidable_dom|dom\.js" --type=php -B2 -A2 | grep -E "(wp_register_script|wp_enqueue|formidable_dom)" | head -30

echo ""
echo "=== Check FrmOverlayController for full context ==="
rg "class FrmOverlayController|register_assets" --type=php -A20 classes/controllers/FrmOverlayController.php | head -50

Repository: Strategy11/formidable-forms

Length of output: 4606


🏁 Script executed:

#!/bin/bash
# Find where dom.js/formidable_dom is registered
echo "=== Search for dom.js registration ==="
rg "dom\.js|formidable_dom" --type=php -B3 -A1 | head -60

Repository: Strategy11/formidable-forms

Length of output: 5370


Add formidable_dom as a dependency for the formidable-overlay script.

The formidable_overlay.js script destructures from the global frmDom object (lines 430-443) but is registered without declaring formidable_dom as a dependency. The formidable_dom script (which exposes window.frmDom) must load first. Update the dependency array in FrmOverlayController::register_assets() from array() to array( 'formidable_dom' ) to match the pattern used by other scripts in the codebase.

🤖 Prompt for AI Agents
In @js/formidable_overlay.js around lines 430-443, The overlay script
formidable_overlay.js destructures from the global frmDom but the PHP asset
registration in FrmOverlayController::register_assets() does not list the
formidable_dom dependency, causing load order issues; update the dependency
array passed when registering the formidable-overlay script from array() to
array('formidable_dom') so the formidable_dom bundle (which exposes
window.frmDom) is enqueued and loaded before formidable_overlay.js.

@truongwp
Copy link
Copy Markdown
Contributor

truongwp commented Jan 8, 2026

@AbdiTolesa Please fix the PHPCS errors and resolve the conflicts with the master branch.

@AbdiTolesa AbdiTolesa requested review from truongwp and removed request for truongwp January 12, 2026 11:54
Copy link
Copy Markdown
Contributor

@truongwp truongwp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me! Just one thing is that the CSS files in master are minified, but the ones in this PR are not. Can you run npm run build again to minify them? @AbdiTolesa

@Crabcyborg Look like there are some problems with Cypress in the master branch.

@truongwp truongwp requested a review from Crabcyborg January 12, 2026 19:24
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Fix all issues with AI agents
In @css/admin/frm-settings-components.css:
- Line 1: The CSS file css/admin/frm-settings-components.css contains an
identical duplicated block that doubles the file; open
frm-settings-components.css, locate the repeated block (e.g., selectors starting
with .formidable_page_formidable-styles and .frm-style-component and the initial
rule .formidable_page_formidable-styles .control-section
.accordion-section-title:focus) and remove the second copy so each selector/rule
appears only once; after removal, run the provided verification script (or
compare the first and second halves) to confirm the file is no longer duplicated
and that formatting remains intact.

In @css/frm_testing_mode.css:
- Line 3: The file starts with a stray closing comment delimiter ("*/") before
the .tooltip rule which breaks CSS parsing; remove that stray "*/" at the very
start so the stylesheet begins with the .tooltip selector (look for the leading
"*/.tooltip" sequence) and verify there are no other orphaned comment markers at
the top of the file.
📜 Review details

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between c3886dc and ef8d05a.

📒 Files selected for processing (10)
  • css/admin/frm-settings-components.css
  • css/frm_admin.css
  • css/frm_testing_mode.css
  • js/form-templates.js
  • js/formidable-settings-components.js
  • js/formidable_admin.js
  • js/formidable_styles.js
  • js/frm_testing_mode.js
  • js/src/admin/admin.js
  • js/welcome-tour.js
🚧 Files skipped from review as they are similar to previous changes (1)
  • js/src/admin/admin.js
🧰 Additional context used
🧬 Code graph analysis (1)
js/formidable-settings-components.js (1)
js/src/admin/addon-state.js (2)
  • frmDom (3-3)
  • a (198-198)
🪛 Biome (2.1.2)
css/frm_testing_mode.css

[error] 3-3: Duplicate properties can lead to unexpected behavior and may override previous declarations unintentionally.

text-align is already defined here.

Remove or rename the duplicate property to ensure consistent styling.

(lint/suspicious/noDuplicateProperties)


[error] 3-3: Duplicate properties can lead to unexpected behavior and may override previous declarations unintentionally.

min-width is already defined here.

Remove or rename the duplicate property to ensure consistent styling.

(lint/suspicious/noDuplicateProperties)


[error] 3-3: Duplicate properties can lead to unexpected behavior and may override previous declarations unintentionally.

border-radius is already defined here.

Remove or rename the duplicate property to ensure consistent styling.

(lint/suspicious/noDuplicateProperties)

js/formidable-settings-components.js

[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: This variable is used before its declaration.

The variable is declared here:

(lint/correctness/noInvalidUseBeforeDeclaration)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)


[error] 1-1: Do not reassign a function declaration.

Reassigned here.

Use a local variable instead.

(lint/suspicious/noFunctionAssign)

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (3)
  • GitHub Check: Cypress
  • GitHub Check: PHP 8 tests in WP 6.9
  • GitHub Check: PHP 7.4 tests in WP 6.9
🔇 Additional comments (1)
js/formidable-settings-components.js (1)

1-1: Minified bundle is expected webpack output; source files are clean.

This is a webpack-generated bundle from js/src/settings-components/index.js. The static analysis errors (Biome's noInvalidUseBeforeDeclaration, noFunctionAssign) are expected false positives for minified code due to variable hoisting and class expression patterns that are valid at runtime.

The source files in js/src/settings-components/ are well-structured, properly documented with JSDoc, include memory leak prevention (observer cleanup), and contain no static analysis issues. The minified bundle is the correct output of the build process and can be approved.

Comment thread css/admin/frm-settings-components.css Outdated
@@ -1 +1 @@
.formidable_page_formidable-styles.js .control-section .accordion-section-title:focus{background:none}.formidable_page_formidable-styles .frm-right-panel h3.accordion-section-title:hover>svg:last-child,.formidable_page_formidable-styles .frm-right-panel .open h3.accordion-section-title>svg:first-child,.formidable_page_formidable-styles .frm-right-panel .open h3.accordion-section-title>svg:last-child{color:var(--grey-900)}.formidable_page_formidable-styles .frm-right-panel .frm-style-component{align-self:center}.frm_settings_form .frm-style-editor-form.frm-pro .frm-style-component .wp-picker-container button,.formidable_page_formidable-styles .frm-right-panel .frm-style-editor-form.frm-pro .frm-style-component .wp-picker-container button{background-color:#fff !important}.frm_settings_form .frm-style-component .wp-picker-container button,.formidable_page_formidable-styles .frm-right-panel .frm-style-component .wp-picker-container button{position:relative;height:36px !important;background-image:none !important;overflow:hidden;background-color:#fff !important}.frm_settings_form .frm-style-component .wp-picker-container::after,.formidable_page_formidable-styles .frm-right-panel .frm-style-component .wp-picker-container::after{content:"";width:20px;height:20px;display:block;position:absolute;top:0;right:8px;bottom:0;margin:auto;background:url("../../images/style/small-arrow.svg") no-repeat;background-position:center;z-index:10}.frm_settings_form .frm-style-component .wp-color-result-text,.formidable_page_formidable-styles .frm-right-panel .frm-style-component .wp-color-result-text{line-height:36px !important;padding:0 12px;border:0}.frm_settings_form .frm-style-component .color-alpha,.formidable_page_formidable-styles .frm-right-panel .frm-style-component .color-alpha{width:20px !important;height:20px !important;border-radius:50% !important;border:1px solid #d0d5dd;top:0;left:0;bottom:0;margin:auto;margin-left:12px}.frm_settings_form .frm-style-component .wp-picker-input-wrap input,.formidable_page_formidable-styles .frm-right-panel .frm-style-component .wp-picker-input-wrap input{width:calc(100% - 10px) !important;margin:1px 5px;height:32px;line-height:32px}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component>div{max-width:216px}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .wp-picker-container{max-width:calc(100% - 44px);position:relative}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component button.frm_choose_image_box{width:36px;height:36px;padding:0;background:#fff;overflow:hidden;text-indent:-999px;flex-wrap:wrap;border:none}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_image_styling_frame{margin-left:0}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_image_preview_wrapper{position:relative;width:36px;height:36px;margin:0;border:1px solid var(--grey-300);border-radius:var(--small-radius);overflow:hidden;box-sizing:border-box}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_image_preview_wrapper .frm_image_preview_frame{max-width:120%;height:120%;margin:-10%;position:relative}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_image_data{position:absolute;left:0;top:0;width:100%;height:100%;overflow:hidden;margin:0;border-radius:var(--small-radius)}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_remove_image_option{width:100%;height:100%;border:1px solid var(--red-500);text-indent:-9999px;position:absolute;top:0;left:0}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_remove_image_option::before{opacity:0;content:"";display:block;position:absolute;width:100%;height:100%;z-index:1;top:0;left:0;background:rgba(255,255,255,.8)}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_remove_image_option::after{opacity:0;content:"";display:block;position:absolute;width:100%;height:100%;z-index:1;top:0;left:0;background:url("../../images/style/close.svg") no-repeat;background-position:center}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_remove_image_option:hover::before,.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_remove_image_option:hover::after{opacity:1}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_image_preview_wrapper .frm_image_preview_frame .frm_image_styling_frame,.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_image_preview_wrapper .frm_image_preview_frame .frm_image_styling_frame img{width:100%;height:100%}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_image_preview_wrapper+*,.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_image_preview_wrapper .frm_image_preview_title,.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_bg_image_additional_settings,.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_remove_image_option *{display:none}.frm-style-component .frm-radio-container{max-width:216px;height:36px;background:#f2f4f7;gap:var(--small-gap);padding:var(--gap-2xs);box-sizing:border-box;border-radius:var(--small-radius);position:relative}.frm-style-component.frm-field-shape .frm-radio-container{max-width:unset}.frm-style-component.frm-direction-component .frm-radio-container{gap:var(--gap-xs)}.frm-style-component .frm-radio-container svg{width:16px}.frm-style-component .frm-radio-container .frm-radio-active-tracker{display:block;width:28%;height:calc(100% - 8px);background:#fff;border-radius:var(--small-radius);box-shadow:var(--button-shadow);position:absolute;top:var(--gap-2xs);bottom:0;left:var(--gap-2xs);z-index:1;transition:.35s transform cubic-bezier(0.075, 0.82, 0.165, 1)}.frm-style-component.frm-field-shape .frm-radio-container .frm-radio-active-tracker{width:23%}.frm-style-component.frm-align-component.frm-2-options .frm-radio-container .frm-radio-active-tracker,.frm-style-component.frm-direction-component .frm-radio-container .frm-radio-active-tracker,.frm-style-component.frm-text-toggle-component .frm-radio-container .frm-radio-active-tracker{width:calc(50% - var(--gap-xs))}.frm-style-component .frm-radio-container>label{width:30%;height:100%;margin:0;cursor:pointer;position:relative;display:flex;z-index:2}.frm-style-component.frm-field-shape .frm-radio-container>label{width:23%}.frm-style-component.frm-align-component.frm-2-options .frm-radio-container>label,.frm-style-component.frm-direction-component .frm-radio-container>label,.frm-style-component.frm-text-toggle-component .frm-radio-container>label{width:50%}.frm-style-component.frm-text-toggle-component .frm-radio-container{height:44px;max-width:unset;gap:var(--gap-xs);padding:var(--gap-xs)}.frm-style-component.frm-text-toggle-component .frm-radio-container .frm-radio-active-tracker{height:calc(100% - var(--gap-sm));top:var(--gap-xs)}.frm-style-tabs-wrapper .frm-tabs-navs ul>li:not(.frm-active):hover,.frm-style-component .frm-radio-container input:not(:checked)+label:hover{background:#eaecf0;border-radius:var(--small-radius);box-shadow:var(--button-shadow)}.frm-style-component .frm-radio-container input{display:none}.frm-style-component .frm-slider-container{width:calc(100% - 91px);display:flex;align-items:center;color:#1d2939}.frm-style-component .frm-slider-container svg.frmsvg{color:currentColor;margin-right:8px;margin-left:-5px;position:relative;z-index:15}.frm-style-component .frm-group-sliders .frm-slider-container svg.frmsvg:hover{color:#4199fd;cursor:pointer}.frm-style-component .frm-slider-container .frm-slider-active-track{display:block;height:100%;width:0;position:relative;border-radius:200px}.frm-style-component .frm-slider-container .frm-slider-active-track,.frm-style-component .frm-slider-container .frm-slider-active-track .frm-slider-bullet{background:#4199fd;box-shadow:0 1.88px 4px -1px rgba(16,24,40,.03),0 6px 8px -2px rgba(16,24,40,.08)}.frm-style-component .frm-slider-container .frm-slider-active-track .frm-slider-bullet{position:absolute;display:block;width:16px;height:16px;border-radius:50%;transform:translateX(15px);cursor:grab;right:0;top:0;bottom:0;margin:auto}.frm-style-component .frm-slider-container .frm-slider-active-track .frm-slider-bullet .frm-slider-value-label{position:absolute;display:block;width:48px;height:36px;background:#101828;color:#fff;font-weight:400;font-size:var(--text-sm);line-height:36px;border-radius:var(--small-radius);transform:translate(-18px, -42px) scale3d(0.7, 1, 1);opacity:0;z-index:-2;pointer-events:none;text-align:center;user-select:none}.frm-style-component .frm-slider-container .frm-slider-active-track .frm-slider-bullet.frm-dragging .frm-slider-value-label{z-index:12;transform:translate(-18px, -42px) scale3d(1, 1, 1);opacity:1;transition:.3s opacity,.35s transform cubic-bezier(0.25, 0.46, 0.45, 0.94)}.frm-style-component .frm-slider-container .frm-slider-active-track .frm-slider-bullet::before{content:"";display:block;position:absolute;width:18px;height:18px;border-radius:50%;left:0;top:0;transform:translate(-5px, -5px) scale3d(0.7, 0.7, 1);border:4px solid #4199fd;opacity:0;transition:.3s opacity,.35s transform cubic-bezier(0.25, 0.46, 0.45, 0.94)}.frm-style-component .frm-slider-container .frm-slider-active-track .frm-slider-bullet.frm-dragging::before{opacity:.5;transform:translate(-5px, -5px) scale3d(1, 1, 1);transition:.3s opacity,.35s transform cubic-bezier(0.25, 0.46, 0.45, 0.94)}.frm-style-component .frm-slider-container .frm-slider-active-track .frm-slider-bullet::after{content:"";position:absolute;display:block;width:180%;height:200%;border-radius:50%;left:0;top:0;transform:translate(-24%, -24%)}.frm-style-component .frm-slider-value{width:86px;height:36px;display:flex;justify-content:center;box-sizing:border-box;background:#fff;border-radius:var(--small-radius);border:1px solid var(--grey-300)}.frm-style-component .frm-slider-value>*{border:none}.frm-style-component .frm-slider-value input{width:40px;height:100%;padding:0;font-size:var(--text-sm);color:#101828;padding-left:12px;box-sizing:border-box}.frm-style-component .frm-slider-value select{text-align:right;padding:0;font-size:var(--text-sm);color:#667085;width:44px;background:url("../../images/style/small-arrow.svg") no-repeat;background-position:center right 12px;padding-right:24px !important}.frm-style-component .frm-slider{display:block;width:calc(100% - 5px);height:4px;background:#eaecf0;border-radius:200px;cursor:pointer}.frm-slider-component .frm-independent-slider-field{margin-top:10px}.frm-slider-component.frm-disabled .frm-slider-container{pointer-events:none;opacity:.5}.frm-slider-component.frm-disabled .frm-slider-value input[type=text]{width:28px}.frm-slider-component.frm-disabled .frm-slider-value select{width:56px}.frm-slider-component.frm-disabled.frm-empty .frm-slider-value input[type=text]{width:56px}.frm-slider-component.frm-disabled.frm-empty .frm-slider-value select{width:28px}.frm-style-component .frm-slider-component.frm-has-multiple-values{margin-bottom:10px}.frm-tabs-wrapper{position:relative;overflow:hidden}.frm-tabs-wrapper .frm-tabs-navigator{margin:0;padding:0;display:flex;gap:var(--gap-xs);justify-content:space-between;align-items:center;background:#f2f4f7;border-radius:var(--small-radius);box-sizing:border-box;height:44px;position:relative;z-index:2}.frm-tabs-wrapper .frm-tabs-navigator .frm-tab-item{flex:1;text-align:center;cursor:pointer}.frm-tabs-wrapper .frm-tabs-navigator .frm-active-background{display:block;height:100%;background:#fff;position:absolute;top:0;left:0;z-index:1}.frm-style-tabs-wrapper{position:relative}.frm-style-tabs-wrapper .frm-tabs-navs{padding:0;min-height:44px}.frm-style-tabs-wrapper .frm-tabs-navs ul{margin:0;height:var(--h-md);position:relative;justify-content:space-between}.frm-style-tabs-wrapper .frm-tabs-navs ul li,.frm-style-tabs-wrapper .frm-tabs-navs ul li a{color:var(--grey-500);font-weight:500;font-size:var(--text-sm);line-height:28px}.frm-style-tabs-wrapper .frm-tabs-navs ul li{flex:1;height:28px;text-align:center;margin-top:var(--gap-xs);margin-bottom:0;cursor:pointer}.frm-style-tabs-wrapper .frm-tabs-navs ul li.frm-active,.frm-style-tabs-wrapper .frm-tabs-navs ul li.frm-active a{color:var(--grey-900)}.frm-style-tabs-wrapper .frm-tabs-navs ul li:first-child{margin-left:var(--gap-xs)}.frm-style-tabs-wrapper .frm-tabs-navs ul li:last-child{margin-right:var(--gap-xs)}.frm-style-tabs-wrapper .frm-tabs-delimiter{position:absolute;top:0;left:0;width:100%;background:#f2f4f7;height:44px;margin:0;border-radius:var(--small-radius)}.frm-style-tabs-wrapper .frm-tabs-delimiter .frm-tabs-active-underline{height:28px;background:#fff;position:absolute;left:0;bottom:8px;width:45px;transition:.4s transform cubic-bezier(0.25, 0.46, 0.45, 0.94);border-radius:var(--small-radius);box-shadow:var(--button-shadow)}.frm-style-tabs-wrapper .frm-tabs-delimiter .frm-tabs-active-underline.frm-first{left:var(--gap-xs)}.frm-style-tabs-wrapper .frm-tabs-delimiter .frm-tabs-active-underline.frm-last{left:calc(-1*var(--gap-xs))}.frm-tabs-container{position:relative;overflow:hidden;margin-top:var(--gap-md);height:100%}.frm-style-tabs-wrapper .frm-tabs-container .frm-tabs-slide-track{transition:.32s transform cubic-bezier(0.25, 0.46, 0.45, 0.94)}.frm-style-tabs-wrapper .frm-tabs-slide-track>div{flex:0 0 100%;opacity:0;transition:.25s opacity linear;position:relative;height:auto;max-height:unset;overflow:hidden;box-sizing:border-box}.frm-style-tabs-wrapper .frm-tabs-slide-track>div>div{overflow:auto;position:relative;width:100%;padding:0;box-sizing:border-box}.frm-tabs-slide-track>div>div:first-child{height:100%}.frm-tabs-slide-track>div.frm-active{opacity:1;transition:.35s opacity linear}.frm-style-component .frm_toggle_slider{background:#f2f4f7}.frm-style-component label.frm-copy-text{line-height:32px;cursor:pointer;white-space:nowrap}.frm-style-component .wp-picker-holder{right:0}.frm-style-component .CodeMirror{min-height:unset !important;height:350px !important}.frm-style-component .CodeMirror .CodeMirror-placeholder{color:var(--grey-400)}.formidable_page_formidable-styles .accordion-section-content .frm-style-item-heading{font-weight:500;font-size:var(--text-md);color:var(--grey-900)}.frm-unit-input{position:relative;display:flex;align-items:center}.frm-unit-input input[type=number]::-webkit-outer-spin-button,.frm-unit-input input[type=number]::-webkit-inner-spin-button{-webkit-appearance:none;appearance:none}.frm-unit-input .frm-input-group-suffix{position:absolute;top:1px;right:1px;display:flex;align-items:center;height:calc(100% - 2px);padding-right:var(--gap-xs)}.frm-unit-input .frm-input-group-suffix select{width:fit-content;height:100%;min-height:unset;font-size:var(--text-sm);text-align:right;color:var(--grey-500) !important;background:#fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' fill='none'%3E%3Cpath stroke='%23667085' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M12.708 8.959 10 11.875 7.292 8.96'/%3E%3C/svg%3E") no-repeat right 0 top 50%;padding-left:var(--gap-2xs);padding-right:21px !important;border:rgba(0,0,0,0)}.frm-unit-input .frm-input-group-suffix select:focus-visible{outline:1px solid var(--primary-500);outline-offset:-2px}
.formidable_page_formidable-styles.js .control-section .accordion-section-title:focus{background:none}.formidable_page_formidable-styles .frm-right-panel h3.accordion-section-title:hover>svg:last-child,.formidable_page_formidable-styles .frm-right-panel .open h3.accordion-section-title>svg:first-child,.formidable_page_formidable-styles .frm-right-panel .open h3.accordion-section-title>svg:last-child{color:var(--grey-900)}.formidable_page_formidable-styles .frm-right-panel .frm-style-component{align-self:center}.frm_settings_form .frm-style-editor-form.frm-pro .frm-style-component .wp-picker-container button,.formidable_page_formidable-styles .frm-right-panel .frm-style-editor-form.frm-pro .frm-style-component .wp-picker-container button{background-color:#fff !important}.frm_settings_form .frm-style-component .wp-picker-container button,.formidable_page_formidable-styles .frm-right-panel .frm-style-component .wp-picker-container button{position:relative;height:36px !important;background-image:none !important;overflow:hidden;background-color:#fff !important}.frm_settings_form .frm-style-component .wp-picker-container::after,.formidable_page_formidable-styles .frm-right-panel .frm-style-component .wp-picker-container::after{content:"";width:20px;height:20px;display:block;position:absolute;top:0;right:8px;bottom:0;margin:auto;background:url("../../images/style/small-arrow.svg") no-repeat;background-position:center;z-index:10}.frm_settings_form .frm-style-component .wp-color-result-text,.formidable_page_formidable-styles .frm-right-panel .frm-style-component .wp-color-result-text{line-height:36px !important;padding:0 12px;border:0}.frm_settings_form .frm-style-component .color-alpha,.formidable_page_formidable-styles .frm-right-panel .frm-style-component .color-alpha{width:20px !important;height:20px !important;border-radius:50% !important;border:1px solid #d0d5dd;top:0;left:0;bottom:0;margin:auto;margin-left:12px}.frm_settings_form .frm-style-component .wp-picker-input-wrap input,.formidable_page_formidable-styles .frm-right-panel .frm-style-component .wp-picker-input-wrap input{width:calc(100% - 10px) !important;margin:1px 5px;height:32px;line-height:32px}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component>div{max-width:216px}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .wp-picker-container{max-width:calc(100% - 44px);position:relative}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component button.frm_choose_image_box{width:36px;height:36px;padding:0;background:#fff;overflow:hidden;text-indent:-999px;flex-wrap:wrap;border:none}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_image_styling_frame{margin-left:0}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_image_preview_wrapper{position:relative;width:36px;height:36px;margin:0;border:1px solid var(--grey-300);border-radius:var(--small-radius);overflow:hidden;box-sizing:border-box}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_image_preview_wrapper .frm_image_preview_frame{max-width:120%;height:120%;margin:-10%;position:relative}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_image_data{position:absolute;left:0;top:0;width:100%;height:100%;overflow:hidden;margin:0;border-radius:var(--small-radius)}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_remove_image_option{width:100%;height:100%;border:1px solid var(--red-500);text-indent:-9999px;position:absolute;top:0;left:0}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_remove_image_option::before{opacity:0;content:"";display:block;position:absolute;width:100%;height:100%;z-index:1;top:0;left:0;background:hsla(0,0%,100%,.8)}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_remove_image_option::after{opacity:0;content:"";display:block;position:absolute;width:100%;height:100%;z-index:1;top:0;left:0;background:url("../../images/style/close.svg") no-repeat;background-position:center}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_remove_image_option:hover::before,.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_remove_image_option:hover::after{opacity:1}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_image_preview_wrapper .frm_image_preview_frame .frm_image_styling_frame,.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_image_preview_wrapper .frm_image_preview_frame .frm_image_styling_frame img{width:100%;height:100%}.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_image_preview_wrapper+*,.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_image_preview_wrapper .frm_image_preview_title,.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_bg_image_additional_settings,.formidable_page_formidable-styles .frm-right-panel .frm-style-component.frm-background-image-component .frm_remove_image_option *{display:none}.frm-style-component .frm-radio-container{max-width:216px;height:36px;background:#f2f4f7;gap:var(--small-gap);padding:var(--gap-2xs);box-sizing:border-box;border-radius:var(--small-radius);position:relative}.frm-style-component.frm-field-shape .frm-radio-container{max-width:unset}.frm-style-component.frm-direction-component .frm-radio-container{gap:var(--gap-xs)}.frm-style-component .frm-radio-container svg{width:16px}.frm-style-component .frm-radio-container .frm-radio-active-tracker{display:block;width:28%;height:calc(100% - 8px);background:#fff;border-radius:var(--small-radius);box-shadow:var(--button-shadow);position:absolute;top:var(--gap-2xs);bottom:0;left:var(--gap-2xs);z-index:1;transition:.35s transform cubic-bezier(0.075, 0.82, 0.165, 1)}.frm-style-component.frm-field-shape .frm-radio-container .frm-radio-active-tracker{width:23%}.frm-style-component.frm-align-component.frm-2-options .frm-radio-container .frm-radio-active-tracker,.frm-style-component.frm-direction-component .frm-radio-container .frm-radio-active-tracker,.frm-style-component.frm-text-toggle-component .frm-radio-container .frm-radio-active-tracker{width:calc(50% - var(--gap-xs))}.frm-style-component .frm-radio-container>label{width:30%;height:100%;margin:0;cursor:pointer;position:relative;display:flex;z-index:2}.frm-style-component.frm-field-shape .frm-radio-container>label{width:23%}.frm-style-component.frm-align-component.frm-2-options .frm-radio-container>label,.frm-style-component.frm-direction-component .frm-radio-container>label,.frm-style-component.frm-text-toggle-component .frm-radio-container>label{width:50%}.frm-style-component.frm-text-toggle-component .frm-radio-container{height:44px;max-width:unset;gap:var(--gap-xs);padding:var(--gap-xs)}.frm-style-component.frm-text-toggle-component .frm-radio-container .frm-radio-active-tracker{height:calc(100% - var(--gap-sm));top:var(--gap-xs)}.frm-style-tabs-wrapper .frm-tabs-navs ul>li:not(.frm-active):hover,.frm-style-component .frm-radio-container input:not(:checked)+label:hover{background:#eaecf0;border-radius:var(--small-radius);box-shadow:var(--button-shadow)}.frm-style-component .frm-radio-container input{display:none}.frm-style-component .frm-slider-container{width:calc(100% - 91px);display:flex;align-items:center;color:#1d2939}.frm-style-component .frm-slider-container svg.frmsvg{color:currentColor;margin-right:8px;margin-left:-5px;position:relative;z-index:15}.frm-style-component .frm-group-sliders .frm-slider-container svg.frmsvg:hover{color:#4199fd;cursor:pointer}.frm-style-component .frm-slider-container .frm-slider-active-track{display:block;height:100%;width:0;position:relative;border-radius:200px}.frm-style-component .frm-slider-container .frm-slider-active-track,.frm-style-component .frm-slider-container .frm-slider-active-track .frm-slider-bullet{background:#4199fd;box-shadow:0 1.88px 4px -1px rgba(16,24,40,.03),0 6px 8px -2px rgba(16,24,40,.08)}.frm-style-component .frm-slider-container .frm-slider-active-track .frm-slider-bullet{position:absolute;display:block;width:16px;height:16px;border-radius:50%;transform:translateX(15px);cursor:grab;right:0;top:0;bottom:0;margin:auto}.frm-style-component .frm-slider-container .frm-slider-active-track .frm-slider-bullet .frm-slider-value-label{position:absolute;display:block;width:48px;height:36px;background:#101828;color:#fff;font-weight:400;font-size:var(--text-sm);line-height:36px;border-radius:var(--small-radius);transform:translate(-18px, -42px) scale3d(0.7, 1, 1);opacity:0;z-index:-2;pointer-events:none;text-align:center;user-select:none}.frm-style-component .frm-slider-container .frm-slider-active-track .frm-slider-bullet.frm-dragging .frm-slider-value-label{z-index:12;transform:translate(-18px, -42px) scale3d(1, 1, 1);opacity:1;transition:.3s opacity,.35s transform cubic-bezier(0.25, 0.46, 0.45, 0.94)}.frm-style-component .frm-slider-container .frm-slider-active-track .frm-slider-bullet::before{content:"";display:block;position:absolute;width:18px;height:18px;border-radius:50%;left:0;top:0;transform:translate(-5px, -5px) scale3d(0.7, 0.7, 1);border:4px solid #4199fd;opacity:0;transition:.3s opacity,.35s transform cubic-bezier(0.25, 0.46, 0.45, 0.94)}.frm-style-component .frm-slider-container .frm-slider-active-track .frm-slider-bullet.frm-dragging::before{opacity:.5;transform:translate(-5px, -5px) scale3d(1, 1, 1);transition:.3s opacity,.35s transform cubic-bezier(0.25, 0.46, 0.45, 0.94)}.frm-style-component .frm-slider-container .frm-slider-active-track .frm-slider-bullet::after{content:"";position:absolute;display:block;width:180%;height:200%;border-radius:50%;left:0;top:0;transform:translate(-24%, -24%)}.frm-style-component .frm-slider-value{width:86px;height:36px;display:flex;justify-content:center;box-sizing:border-box;background:#fff;border-radius:var(--small-radius);border:1px solid var(--grey-300)}.frm-style-component .frm-slider-value>*{border:none}.frm-style-component .frm-slider-value input{width:40px;height:100%;padding:0;font-size:var(--text-sm);color:#101828;padding-left:12px;box-sizing:border-box}.frm-style-component .frm-slider-value select{text-align:right;padding:0;font-size:var(--text-sm);color:#667085;width:44px;background:url("../../images/style/small-arrow.svg") no-repeat;background-position:center right 12px;padding-right:24px !important}.frm-style-component .frm-slider{display:block;width:calc(100% - 5px);height:4px;background:#eaecf0;border-radius:200px;cursor:pointer}.frm-slider-component .frm-independent-slider-field{margin-top:10px}.frm-slider-component.frm-disabled .frm-slider-container{pointer-events:none;opacity:.5}.frm-slider-component.frm-disabled .frm-slider-value input[type=text]{width:28px}.frm-slider-component.frm-disabled .frm-slider-value select{width:56px}.frm-slider-component.frm-disabled.frm-empty .frm-slider-value input[type=text]{width:56px}.frm-slider-component.frm-disabled.frm-empty .frm-slider-value select{width:28px}.frm-style-component .frm-slider-component.frm-has-multiple-values{margin-bottom:10px}.frm-tabs-wrapper{position:relative;overflow:hidden}.frm-tabs-wrapper .frm-tabs-navigator{margin:0;padding:0;display:flex;gap:var(--gap-xs);justify-content:space-between;align-items:center;background:#f2f4f7;border-radius:var(--small-radius);box-sizing:border-box;height:44px;position:relative;z-index:2}.frm-tabs-wrapper .frm-tabs-navigator .frm-tab-item{flex:1;text-align:center;cursor:pointer}.frm-tabs-wrapper .frm-tabs-navigator .frm-active-background{display:block;height:100%;background:#fff;position:absolute;top:0;left:0;z-index:1}.frm-style-tabs-wrapper{position:relative}.frm-style-tabs-wrapper .frm-tabs-navs{padding:0;min-height:44px}.frm-style-tabs-wrapper .frm-tabs-navs ul{margin:0;height:var(--h-md);position:relative;justify-content:space-between}.frm-style-tabs-wrapper .frm-tabs-navs ul li,.frm-style-tabs-wrapper .frm-tabs-navs ul li a{color:var(--grey-500);font-weight:500;font-size:var(--text-sm);line-height:28px}.frm-style-tabs-wrapper .frm-tabs-navs ul li{flex:1;height:28px;text-align:center;margin-top:var(--gap-xs);margin-bottom:0;cursor:pointer}.frm-style-tabs-wrapper .frm-tabs-navs ul li.frm-active,.frm-style-tabs-wrapper .frm-tabs-navs ul li.frm-active a{color:var(--grey-900)}.frm-style-tabs-wrapper .frm-tabs-navs ul li:first-child{margin-left:var(--gap-xs)}.frm-style-tabs-wrapper .frm-tabs-navs ul li:last-child{margin-right:var(--gap-xs)}.frm-style-tabs-wrapper .frm-tabs-delimiter{position:absolute;top:0;left:0;width:100%;background:#f2f4f7;height:44px;margin:0;border-radius:var(--small-radius)}.frm-style-tabs-wrapper .frm-tabs-delimiter .frm-tabs-active-underline{height:28px;background:#fff;position:absolute;left:0;bottom:8px;width:45px;transition:.4s transform cubic-bezier(0.25, 0.46, 0.45, 0.94);border-radius:var(--small-radius);box-shadow:var(--button-shadow)}.frm-style-tabs-wrapper .frm-tabs-delimiter .frm-tabs-active-underline.frm-first{left:var(--gap-xs)}.frm-style-tabs-wrapper .frm-tabs-delimiter .frm-tabs-active-underline.frm-last{left:calc(-1*var(--gap-xs))}.frm-tabs-container{position:relative;overflow:hidden;margin-top:var(--gap-md);height:100%}.frm-style-tabs-wrapper .frm-tabs-container .frm-tabs-slide-track{transition:.32s transform cubic-bezier(0.25, 0.46, 0.45, 0.94)}.frm-style-tabs-wrapper .frm-tabs-slide-track>div{flex:0 0 100%;opacity:0;transition:.25s opacity linear;position:relative;height:auto;max-height:unset;overflow:hidden;box-sizing:border-box}.frm-style-tabs-wrapper .frm-tabs-slide-track>div>div{overflow:auto;position:relative;width:100%;padding:0;box-sizing:border-box}.frm-tabs-slide-track>div>div:first-child{height:100%}.frm-tabs-slide-track>div.frm-active{opacity:1;transition:.35s opacity linear}.frm-style-component .frm_toggle_slider{background:#f2f4f7}.frm-style-component label.frm-copy-text{line-height:32px;cursor:pointer;white-space:nowrap}.frm-style-component .wp-picker-holder{right:0}.frm-style-component .CodeMirror{min-height:unset !important;height:350px !important}.frm-style-component .CodeMirror .CodeMirror-placeholder{color:var(--grey-400)}.formidable_page_formidable-styles .accordion-section-content .frm-style-item-heading{font-weight:500;font-size:var(--text-md);color:var(--grey-900)}.frm-unit-input{position:relative;display:flex;align-items:center}.frm-unit-input input[type=number]::-webkit-outer-spin-button,.frm-unit-input input[type=number]::-webkit-inner-spin-button{-webkit-appearance:none;appearance:none}.frm-unit-input .frm-input-group-suffix{position:absolute;top:1px;right:1px;display:flex;align-items:center;height:calc(100% - 2px);padding-right:var(--gap-xs)}.frm-unit-input .frm-input-group-suffix select{width:fit-content;height:100%;min-height:unset;font-size:var(--text-sm);text-align:right;color:var(--grey-500) !important;background:#fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' fill='none'%3E%3Cpath stroke='%23667085' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M12.708 8.959 10 11.875 7.292 8.96'/%3E%3C/svg%3E") no-repeat right 0 top 50%;padding-left:var(--gap-2xs);padding-right:21px !important;border:rgba(0,0,0,0)}.frm-unit-input .frm-input-group-suffix select:focus-visible{outline:1px solid var(--primary-500);outline-offset:-2px}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Entire CSS content appears to be duplicated.

The AI summary indicates this file now contains an identical copy of its CSS content appended to itself. This doubles the file size unnecessarily and is likely an unintended side effect of the build process or merge conflicts.

Since this PR focuses on JavaScript fixes for section field duplication, please verify this change and remove the duplicate CSS block.

#!/bin/bash
# Verify if the CSS file contains duplicated content by checking for repeated patterns
# First, get the file size
wc -c css/admin/frm-settings-components.css

# Check if the first half matches the second half (approximate check for duplication)
file_content=$(cat css/admin/frm-settings-components.css)
content_length=${#file_content}
half_length=$((content_length / 2))

first_half="${file_content:0:$half_length}"
second_half="${file_content:$half_length}"

# Check if they start with the same content (first 200 chars)
echo "First 200 chars of first half:"
echo "${first_half:0:200}"
echo ""
echo "First 200 chars of second half:"
echo "${second_half:0:200}"
🤖 Prompt for AI Agents
In @css/admin/frm-settings-components.css at line 1, The CSS file
css/admin/frm-settings-components.css contains an identical duplicated block
that doubles the file; open frm-settings-components.css, locate the repeated
block (e.g., selectors starting with .formidable_page_formidable-styles and
.frm-style-component and the initial rule .formidable_page_formidable-styles
.control-section .accordion-section-title:focus) and remove the second copy so
each selector/rule appears only once; after removal, run the provided
verification script (or compare the first and second halves) to confirm the file
is no longer duplicated and that formatting remains intact.

Comment thread css/frm_testing_mode.css Outdated
:root,.frm-white-body,.frm_wrap{--grey-900: #101828;--grey-800: #1D2939;--grey-700: #344054;--grey-600: #475467;--grey-500: #667085;--grey-400: #98A2B3;--grey-300: #D0D5DD;--grey-200: #EAECF0;--grey-100: #F2F4F7;--grey-50: #F9FAFB;--grey-25: #FCFCFD;--dark-grey: var(--grey-700);--medium-grey: rgba(40, 47, 54, .65);--grey: var(--grey-500);--grey-border: var(--grey-300);--lightest-grey: rgb(250, 250, 250);--sidebar-color: var(--grey-50);--sidebar-hover: var(--grey-200);--primary-700: #2B66A9;--primary-500: #4199FD;--primary-300: #80BBFE;--primary-200: #C0DDFE;--primary-50: #ECF5FF;--primary-25: #F5FAFF;--primary-color: var(--primary-500);--primary-hover: var(--primary-700);--light-blue: var(--primary-25);--blue-border: rgb(188, 224, 253);--error-700: #B42318;--error-500: #F04438;--error-300: #FECDCA;--error-100: #FEE4E2;--error-25: #FFF5F4;--green: rgb(63, 172, 37);--orange: #F15A24;--warning-500: #F79009;--pink: rgb(226, 42, 110);--purple: rgb(141, 53, 245);--success-900: #054F31;--success-800: #065F46;--success-500: #12b76a;--success-100: #D1FAE5;--success-200: #A6F4C5;--success-50: #ECFDF3;--success-25: #f6fef9;--border-radius: 35px;--small-radius: 8px;--medium-radius: 16px;--small-sidebar: 275px;--medium-sidebar: 350px;--big-sidebar: 390px;--biggest-sidebar: 450px;--text-xs: 12px;--text-sm: 14px;--text-md: 16px;--text-lg: 18px;--text-xl: 20px;--h-xs: 24px;--h-sm: 30px;--h-md: 36px;--leading: 1.5;--gap-2xs: 4px;--gap-xs: 8px;--gap-sm: 16px;--gap-md: 24px;--gap-lg: 32px;--gap-xl: 40px;--gap-2xl: 48px;--box-shadow-xs: 0 0.47074466943740845px 0.9414893388748169px 0 rgba(16, 24, 40, 0.05);--box-shadow-sm: 0 0.470745px 1.41223px rgba(16, 24, 40, 0.1), 0 0.470745px 0.941489px rgba(16, 24, 40, 0.06);--box-shadow-md: 0 1.88298px 3.76596px -0.941489px rgba(16, 24, 40, 0.1), 0 0.941489px 1.88298px -0.941489px rgba(16, 24, 40, 0.06);--box-shadow-lg: 0 6px 8px -2px rgba(16, 24, 40, 0.08), 0 1.88298px 4px -1px rgba(16, 24, 40, 0.03), 0 0.470745px 1.41223px rgba(16, 24, 40, 0.1), 0 0.470745px 0.941489px rgba(16, 24, 40, 0.06);--box-shadow-xl: 0 9.41489px 11.2979px -1.88298px rgba(16, 24, 40, 0.08), 0 3.76596px 3.76596px -1.88298px rgba(16, 24, 40, 0.03);--box-shadow-xxl: 0 11px 22px -5px rgba(16, 24, 40, 0.18);--button-shadow: 0 0.47px 0.94px 0 rgba(16, 24, 40, 0.06), 0 0.47px 1.47px 0 rgba(16, 24, 40, 0.1);--check-label-color: var(--grey-700)}.frm_toggle_opt{padding:0;white-space:normal;display:inline;vertical-align:middle;font-weight:400}.frm_on_label,.frm_off_label{color:var(--grey-700)}.frm_toggle{position:relative;display:inline-block;width:40px;height:var(--h-xs);vertical-align:middle}.frm_toggle_block{display:inline-flex !important;gap:var(--gap-xs);align-items:center}.frm_toggle input,.frm_toggle_block input{display:none !important}.frm_toggle_slider{position:absolute;cursor:pointer;top:0;left:0;right:0;bottom:0;background-color:var(--grey-200);transition:.4s;border-radius:30px}.frm_toggle_slider::before{box-sizing:border-box;content:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' fill='none'%3E%3Cpath stroke='%2398A2B3' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m10.063 3.938-6.126 6.124M3.938 3.938l6.124 6.124'/%3E%3C/svg%3E");position:absolute;left:2px;bottom:2px;display:flex;align-items:center;justify-content:center;width:20px;height:20px;font-size:20px;line-height:20px;background-color:#fff;border-radius:50%;transition:.4s;box-shadow:var(--box-shadow-md)}input:checked+.frm_toggle .frm_toggle_slider{background-color:var(--primary-500)}input:focus+.frm_toggle .frm_toggle_slider{box-shadow:var(--box-shadow-md)}input:checked+.frm_toggle .frm_toggle_slider::before{transform:translateX(16px);content:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' fill='none'%3E%3Cpath stroke='%234199FD' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m4.52 7.437 1.313 1.459L9.48 5.104'/%3E%3C/svg%3E")}input[disabled]+.frm_toggle_slider,input[disabled]+.frm_toggle .frm_toggle_slider{pointer-events:none;cursor:text;opacity:.5}.frm_toggle_opt~.frm_toggle:not(#frm_testing_mode .frm_toggle) .frm_toggle_slider::before{content:"" !important}.rtl .frm_toggle_opt{padding:0 8px}.rtl .frm_toggle_slider::before{left:17px}.rtl input:checked+.frm_toggle .frm_toggle_slider::before{transform:none !important;left:1px}.frm_toggle_off,.frm_toggle_on{display:none;color:#fff;z-index:999;position:absolute;font-size:10px;line-height:20px;left:6px}.frm_toggle_off{display:inline;left:auto;right:5px;color:var(--dark-grey)}.frm_toggle_long{width:80% !important;height:28px;display:inline-block !important}.frm_toggle_long .frm_toggle_slider{background:var(--primary-700);box-shadow:0 0 0 2px var(--primary-700)}.frm_toggle_long .frm_toggle_off,.frm_toggle_long .frm_toggle_on{width:50%;text-align:center;font-size:13px;line-height:28px}.frm_toggle_long .frm_toggle_on{left:0}.frm_toggle_long .frm_toggle_off{right:0}.frm_toggle_long .frm_toggle_slider::before{width:50%;left:0;top:0;border-radius:var(--border-radius) 0 0 var(--border-radius);height:100%;background-color:#fff;color:var(--primary-color);content:"" !important}.frm_toggle_long input:checked+.frm_toggle_slider::before{transform:translateX(101%);border-radius:0 var(--border-radius) var(--border-radius) 0}input:checked+.frm_toggle_slider+.frm_toggle_on{display:inline}input:checked+.frm_toggle_slider+.frm_toggle_on+.frm_toggle_off{display:none}.frm_toggle_long .frm_toggle_on,.frm_toggle_long input:checked+.frm_toggle_slider+.frm_toggle_on+.frm_toggle_off{display:inline;color:var(--primary-500);font-weight:400}.frm_toggle_long .frm_toggle_off,.frm_toggle_long input:checked+.frm_toggle_slider+.frm_toggle_on{color:#fff;font-weight:700}.frmdates_add_blackout_date_link,.frmdates_add_exception_link,.frm_form_field.frm_scroll_box .frm_opt_container,.frm-white-body .wrap input[type=text],.frm-white-body .wrap input[type=search],.frm-white-body .wrap input[type=number],.frm-white-body .wrap select,#frm-form-templates-modal select,.frm-white-body .wrap textarea,button.frm_choose_image_box,#titlediv input[type=text],.frm-fields button.btn,.frm_wrap textarea,.frm_wrap input[type=tel],.frm_wrap input[type=text],.frm_wrap input[type=email] .frm_wrap input[type=search],.frm_wrap input[type=number],.frm_wrap input[type=date],.frm_wrap select,.wp-admin .frm_wrap select,.field-group textarea,.field-group input[type=text],.field-group select,.frm-fields .frm-input-field{outline:0;box-shadow:var(--box-shadow-xs);border-radius:var(--small-radius);padding:5px 14px;border-color:var(--grey-300);color:var(--grey-800);font-size:var(--text-md);margin:0;background-color:#fff;line-height:var(--leading)}.frm_input_with_suffix{border-radius:var(--small-radius);border:1px solid var(--grey-300);display:inline-block;padding-right:14px}.frm_input_with_suffix input{border:0 !important;padding-right:5px !important}.frm_wrap ::-webkit-datetime-edit{line-height:var(--leading)}.frm-white-body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) textarea:focus,.frm-white-body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) input:focus,.frm-white-body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) select:focus,.frm_wrap input:focus,.frm_wrap select:focus,.wp-core-ui .frm_wrap select:focus,#frm-form-templates-modal select:focus,.frm-btn-group .multiselect.dropdown-toggle:focus,.frm_wrap textarea:focus{border-color:var(--primary-500) !important;box-shadow:none !important}.wp-admin .frm_fields_container textarea:focus,.wp-admin .frm_fields_container input:focus,.wp-admin .frm_fields_container select:focus{border-color:var(--primary-500);box-shadow:none}#postbox-container-2 textarea,.frm_wrap textarea,.field-group textarea{line-height:2}.frm_wrap input[type=number]{height:auto}.frm_wrap select{padding:2px}.wp-admin .frm_wrap select,#frm-form-templates-modal select{max-width:100%}.frm_form_field.frm_scroll_box .frm_opt_container{padding:10px 12px}.frm_wrap input[disabled],.frm_wrap select[disabled],.frm_wrap textarea[disabled],.frm_wrap input[readonly],.frm_wrap select[readonly],.frm_wrap textarea[readonly],.frm_wrap input::placeholder{color:var(--grey-500)}textarea[id^=frm_calc_]::placeholder{font-size:var(--text-sm);line-height:var(--leading);font-style:italic;color:var(--grey-400);padding-top:5px}.frm_wrap .frm-button-primary.frm-disabled{opacity:.5;cursor:default}#postcustomstuff table td>div{padding-top:0 !important}.wp-admin .frm_wrap .form-table select{vertical-align:top}.frm_wrap .frm_form_builder select{line-height:var(--leading);height:var(--text-md);width:100%}#postbox-container-2 select,.wp-admin .frm_wrap select,.frm_wrap .frm_form_builder select,#frm-form-templates-modal select{height:auto}.frm-white-body .tablenav select,.frm-white-body .tablenav input[type=text],.wp-admin .frm_wrap .tablenav select,.frm_wrap .tablenav input[type=date],.frm_wrap .tablenav input[type=text]{padding-top:0;padding-bottom:0;line-height:1}.frm_wrap .tablenav ::-webkit-datetime-edit{line-height:1}.frm-fields button.btn,.frm-fields textarea,.frm-fields input[type=text],.frm-fields select,.field-group textarea,.field-group input[type=text],.field-group select,.accordion-container input.hex,.frm-fields .frm-input-field{width:100%;outline:0}.frm-fields button.btn{height:var(--h-md);text-align:inherit}.global-font .field-group input[type=text]{width:auto}.frm_orange_button,.frm_reverse_button{font-size:12px;border:1px solid var(--orange);color:var(--orange);font-weight:600;padding:1px 4px;border-radius:4px;background:rgba(0,0,0,0)}.frm_reverse_button:hover,.frm_reverse_button:active,.frm_reverse_button:focus{color:#fff;background:var(--orange);border:1px solid var(--orange)}.frm_reverse_button{font-size:1em;transition:all .2s ease}.frm-button-primary,.wp-core-ui .button-primary.frm-button-primary,.wp-core-ui .button.frm-button-primary,.frm-button-secondary,.wp-core-ui .button-secondary.frm-button-secondary,.wp-core-ui .button.frm-button-secondary,.frm-white-body .frm-search .button,.frm-white-body .search-box .button,.frm-white-body .tablenav .button,.frm_orange_button,.toplevel_page_formidable #frm_upgrade_modal .button-primary,.wp-core-ui.frm-white-body .button-primary,.wp-core-ui.frm-white-body .button-secondary,.frm-white-body .button-primary,.frm-white-body .button-secondary,#frm-form-button button,.frm-form-button button,.frm-preview-buttons button,.frm-button-red,.frm-button-tertiary{text-shadow:none;box-shadow:none;border-radius:30px;border:1px solid var(--primary-500);font-size:var(--text-sm);transition:all .2s ease;padding:7px 16px;height:auto;min-height:28px;outline:none;line-height:var(--leading);box-sizing:border-box;font-weight:500;margin-bottom:0;display:inline-block}.frm-button-primary.frm-sharp,.frm-button-secondary.frm-sharp{border-radius:12px !important}#wpcontent .frm-button-secondary.frm-button-gradient{position:relative;border-color:rgba(0,0,0,0) !important;background-clip:padding-box !important}#wpcontent .frm-button-secondary.frm-button-gradient::before{content:"";position:absolute;top:0;right:0;bottom:0;left:0;z-index:-1;margin:-1px;border-radius:inherit;background:linear-gradient(90deg, #129EFD 0%, #A334FD 100%);transition:opacity 150ms ease-out}#wpcontent .frm-button-secondary:hover::before{opacity:.5}.no-js.wp-core-ui .frm-search .button.hide-if-no-js,.js.wp-core-ui .frm-search .button.hide-if-js{display:none}.frm-button-tertiary{border-color:rgba(0,0,0,0);color:var(--primary-500)}.frm-button-tertiary:focus{outline:none}.frm-button-tertiary.frm_loading_button::before{border-right-color:var(--grey);border-bottom-color:var(--grey)}.frm-button-red,.frm-button-red:focus{--primary-color: var(--error-500);--primary-500: var(--error-500);--primary-700: var(--error-700)}.frm-button-red:not(.frm-button-tertiary),.frm-button-red:not(.frm-button-tertiary):focus{color:#fff !important}.frm-white-body h2 .button,.post-type-frm_display h2 .frm-button-primary,.frm-white-body .tablenav .button,.frm-button-primary.frm-button-sm,.frm-button-secondary.frm-button-sm,.frm-button-tertiary.frm-button-sm,.frm-button-red.frm-button-sm{padding:4px 12px !important;font-size:var(--text-xs) !important}.frm_no_style_button{background:rgba(0,0,0,0)}.frm-with-icon{display:flex;gap:var(--gap-xs);align-items:center}.frm-with-icon svg{opacity:.65}.frm-with-icon.button svg{height:var(--text-sm);width:var(--text-sm)}.frm-with-icon.frm-button-sm svg{height:var(--text-xs);width:var(--text-xs)}.frm-white-body .button.add_media{padding-left:12px !important;padding-right:12px !important;font-size:var(--text-xs);border-radius:var(--border-radius)}.wp-core-ui.frm-white-body #post-query-submit.button,.wp-core-ui.frm-white-body .button.tablenav-pages-navspan,.wp-core-ui.frm-white-body .button.first-page,.wp-core-ui.frm-white-body .button.prev-page,.wp-core-ui.frm-white-body .button.next-page,.wp-core-ui.frm-white-body .button.last-page,.wp-core-ui.frm-white-body .button.action{background-color:rgba(0,0,0,0);border-color:var(--grey-300);color:var(--grey-700);border-radius:var(--border-radius)}.post-type-frm_display.wp-core-ui .button-primary,.frm-button-primary,.wp-core-ui .button-primary.frm-button-primary,.frm_single_entry_page #frm-publishing .button-primary{background-color:var(--primary-500) !important;color:#fff !important}.frm-button-primary.frm_large,.frm-button-secondary.frm_large{height:auto !important;padding:12px 16px !important}.frm-button-secondary.frm-small,.frm-button-primary.frm-small{font-size:var(--text-xs) !important;height:auto !important;padding:var(--gap-2xs) 12px !important}.frm-button-primary i::before{color:#fff}.wp-core-ui .button-primary.frm-button-primary:not([disabled]):hover,.frm-button-primary:not([disabled]):hover{background:var(--primary-700) !important;border-color:var(--primary-700) !important}.wp-core-ui .button-primary.frm-button-primary:active{vertical-align:inherit}.frm-white-body #search-submit,#frm-form-button .frm_button_submit,.frm-form-button .frm_button_submit,.frm-white-body .frm-preview-buttons button,.frm-white-body .button:not(.frm-button-primary),.wp-core-ui.frm-white-body .button-secondary,.wp-core-ui .button-secondary.frm-button-secondary,.wp-core-ui .button.frm-button-secondary,.frm-white-body .frm-button-secondary,.frm-button-secondary{color:var(--grey-800);border-color:var(--grey-300);background-color:#fff}#wp-content-media-buttons button,#wp-content-media-buttons a.button{border-color:var(--grey-300)}.frm_orange_button{border-color:#da791d !important;background:var(--orange);color:#fff}.frm-white-body .button:not(.frm-button-primary):focus,.frm-white-body .button:not(.frm-button-primary):active,.frm-white-body .frm-button-secondary:hover,.wp-core-ui.frm-white-body .frm-button-secondary:hover,.wp-core-ui.frm-white-body .button-secondary:hover,.wp-core-ui.frm-white-body .button-secondary:focus,.wp-core-ui.frm-white-body .tablenav .button:hover,.frm_wrap .preview>.button:hover,.frm-white-body #search-submit:hover{border-color:var(--grey-300) !important;color:var(--grey-800);background:var(--grey-50) !important;box-shadow:none !important;outline:none !important}.frm-button-primary .frmsvg{color:#fff}.frm_wrap .preview i{font-size:inherit}.frm-white-body .frm-button-primary:focus,.frm-white-body .frm-button-primary:active,#frm-addons-page .button-primary:focus,#form_global_settings .button-primary:focus,#frm_upgrade_modal .button-primary:focus{border-color:var(--primary-700) !important;background-color:var(--primary-700) !important;box-shadow:none !important;outline:none !important}.frm_wrap .preview>.button:focus,.frm_orange_button:hover,.frm_orange_button:focus,.toplevel_page_formidable #frm_upgrade_modal .button-primary:hover,.toplevel_page_formidable #frm_upgrade_modal .button-primary:focus,.toplevel_page_formidable .frm_wrap button.button-primary:hover,.toplevel_page_formidable .frm_wrap button.button-primary:focus{outline:none}.frm_orange_button:hover,.frm_orange_button:focus{border-color:var(--orange) !important;background:rgba(0,0,0,0);color:var(--orange);opacity:1}.major-publishing-actions.frm_create_form_header{padding:8px 0}.major-publishing-actions.frm_create_form_header .frm_create_form_header_inner{font-size:15px;background:rgba(0,0,0,0)}.frm-menu-boxes .frm_blank_form_text{padding-bottom:26px}input.frm_insert_in_template{font-size:10px;width:98%;font-weight:400}.frm-dismissible a.dismiss:focus{box-shadow:none}.frm-dismissible a.dismiss{top:10px;right:10px;position:absolute}.frm-dismissible a.dismiss svg{color:var(--grey-800)}.frm-btn-unstyled{font:inherit;background:none;border:none;padding:0;cursor:pointer;outline:inherit}.frm-btn-unstyled:hover,.frm-btn-unstyled:focus,.frm-btn-unstyled:active{text-decoration:none;background:none;border:none;box-shadow:none}.frm-btn-unstyled:disabled,.frm-btn-unstyled[disabled]{pointer-events:none;opacity:.65}/*!
* Bootstrap v4.6.1
*/.tooltip{position:absolute;display:block;margin:0;font-style:normal;font-weight:400;line-height:1.5;text-align:left;text-align:start;text-decoration:none;text-shadow:none;text-transform:none;letter-spacing:normal;word-break:normal;word-spacing:normal;white-space:normal;line-break:auto;font-size:.875rem;word-wrap:break-word;opacity:0;z-index:9999999;pointer-events:none}.tooltip.show{opacity:.9}.tooltip .arrow{position:absolute;display:block;width:.8rem;height:.4rem;margin-left:0 !important}.tooltip .arrow::before{position:absolute;content:"";border-color:rgba(0,0,0,0);border-style:solid}.bs-tooltip-top,.bs-tooltip-auto[x-placement^=top]{padding:.4rem 0}.bs-tooltip-top .arrow,.bs-tooltip-auto[x-placement^=top] .arrow{bottom:0}.bs-tooltip-top .arrow::before,.bs-tooltip-auto[x-placement^=top] .arrow::before{top:0;border-width:.4rem .4rem 0;border-top-color:#000}.bs-tooltip-right,.bs-tooltip-auto[x-placement^=right]{padding:0 .4rem}.bs-tooltip-right .arrow,.bs-tooltip-auto[x-placement^=right] .arrow{left:0;width:.4rem;height:.8rem}.bs-tooltip-right .arrow::before,.bs-tooltip-auto[x-placement^=right] .arrow::before{right:0;border-width:.4rem .4rem .4rem 0;border-right-color:#000}.bs-tooltip-bottom,.bs-tooltip-auto[x-placement^=bottom]{padding:.4rem 0}.bs-tooltip-bottom .arrow,.bs-tooltip-auto[x-placement^=bottom] .arrow{top:0}.bs-tooltip-bottom .arrow::before,.bs-tooltip-auto[x-placement^=bottom] .arrow::before{bottom:0;border-width:0 .4rem .4rem;border-bottom-color:#000}.bs-tooltip-left,.bs-tooltip-auto[x-placement^=left]{padding:0 .4rem}.bs-tooltip-left .arrow,.bs-tooltip-auto[x-placement^=left] .arrow{right:0;width:.4rem;height:.8rem}.bs-tooltip-left .arrow::before,.bs-tooltip-auto[x-placement^=left] .arrow::before{left:0;border-width:.4rem 0 .4rem .4rem;border-left-color:#000}.tooltip-inner{max-width:200px;padding:.25rem .5rem;color:#fff;text-align:center;background-color:#000;border-radius:.25rem}.frm-dropdown-menu.show{display:block}.frm-single-settings .frm-dropdown-menu.show{background:#fff}.preview.dropdown .dropdown-menu{min-width:205px}.frm_clear{clear:both}.frm_clearfix::after{content:".";display:block;clear:both;visibility:hidden;line-height:0;height:0}.frm_clearfix{display:block}.frm_admin_progress{overflow:hidden;height:20px;margin-bottom:20px;background-color:#f5f5f5;border-radius:4px;box-shadow:inset 0 1px 2px rgba(0,0,0,.1)}.frm_admin_progress_bar{float:left;width:0;height:100%;font-size:12px;line-height:20px;color:#fff;text-align:center;box-shadow:inset 0 -1px 0 rgba(0,0,0,.15);transition:width .6s ease;background-color:#04a4cc}.tooltip.frm_tooltip{position:fixed;top:auto !important;bottom:0 !important;left:0 !important;max-width:none;width:100% !important;z-index:99999}.tooltip.frm_tooltip.bottom{padding:0}.frm_tooltip .tooltip-inner{max-width:none;min-height:40px !important;text-align:left;box-shadow:5px 5px 25px rgba(0,0,0,.5);padding:10px 40px;border-top-color:#ccc;background:var(--sidebar-color);color:var(--grey-700);border-radius:0;opacity:1;font-size:var(--text-sm)}#frm_custom_css_box{width:100%}h1 .fa-caret-down{font-size:18px}.caret{display:inline-block;width:19px;height:9px;margin-right:-8px;vertical-align:middle}.caret,.wp-admin .frm_wrap select,.frm_wrap .frm_form_builder select,.frm_wrap .ui-autocomplete-input{background:rgba(0,0,0,0) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' fill='none'%3E%3Cpath stroke='%2398A2B3' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M12.708 8.959 10 11.875 7.292 8.96'/%3E%3C/svg%3E") no-repeat right 8px top 50%;padding-right:var(--gap-lg) !important}.caret{padding-right:var(--gap-xs) !important;background-position-x:5px}.frm-btn-group .caret{float:right;margin-top:calc(var(--text-md)/2)}.dropdown{position:relative}.dropdown-toggle:focus{outline:0}.frm_wrap .ui-autocomplete,#frm_adv_info.frm-dropdown-menu,.frm-dropdown-menu{position:absolute;top:100%;left:0;z-index:1000;display:none;min-width:10rem;padding-left:4px;padding-right:4px;margin:var(--gap-xs) 0 0;text-align:left;list-style:none;background:none;background-color:#fff;background-clip:padding-box;border:1px solid var(--grey-100);border-radius:.25rem;box-shadow:var(--box-shadow-lg);max-height:200px;overflow-y:auto;overflow-x:hidden;font-size:var(--text-md);width:auto;min-width:160px}.frm6 .frm-dropdown-menu{min-width:100px;max-width:99%}#frm_bs_dropdown .frm-dropdown-menu{max-width:400px}.field_type_list .frm-dropdown-menu{min-width:150px !important}#frm_field_group_controls .frm-dropdown-menu,.frm-field-action-icons .frm-dropdown-menu{min-width:180px !important}.frm-field-action-icons .frm-dropdown-toggle svg,#frm_field_group_controls .frm-dropdown-toggle svg{color:#9ea9b8}.multiselect-container.frm-dropdown-menu,#search-submit .frm-dropdown-menu{min-width:200px !important}.preview .frm-dropdown-menu{min-width:230px !important}.frm-dropdown-menu.dropdown-menu-right{right:0;left:auto}.frm-dropdown-menu .divider{height:1px;margin:9px 0;overflow:hidden;background-color:#e5e5e5}.frm-dropdown-menu>.dropdown-item{margin:0}.frm-select-list-item,.frm_wrap .ui-autocomplete li>div,.multiselect-container button.multiselect-option,.frm-dropdown-menu>.dropdown-item>a,.frm-dropdown-menu .frm_dropdown_li{clear:both;font-weight:400;white-space:nowrap;text-decoration:none;border-radius:var(--small-radius)}.frm-dropdown-menu>.active>a,.frm-dropdown-menu>.active>a:hover,.frm-dropdown-menu>.active>a:focus{text-decoration:none;outline:0}.frm-select-list-item.disabled,.frm-dropdown-menu>.disabled>a,.frm-dropdown-menu>.disabled>a:hover,.frm-dropdown-menu>.disabled>a:focus{color:#999}.frm-select-list-item.disabled:hover,.frm-dropdown-menu>.disabled>a:hover,.frm-dropdown-menu>.disabled>a:focus{text-decoration:none;background-color:rgba(0,0,0,0);background-image:none;cursor:not-allowed}.open>.frm-dropdown-menu{display:block}.open>a{outline:0}.dropdown-header{display:block;padding:3px 10px;font-size:var(--text-xs);color:var(--grey-400)}.dropdown-backdrop{position:fixed;left:0;right:0;bottom:0;top:0;z-index:990}.dropdown-menu-right>.frm-dropdown-menu,.pull-right>.frm-dropdown-menu{right:0;left:auto}.navbar-fixed-bottom .dropdown .caret{border-top:0 dotted;border-bottom:4px solid #000;content:""}.navbar-fixed-bottom .dropdown .frm-dropdown-menu{top:auto;bottom:100%;margin-bottom:1px}.btn{border:1px solid #ddd;background:#fff;height:28px;line-height:var(--leading)}a.frm_option_icon::before{color:var(--primary-500);font-size:22px;width:22px;height:22px}a.frm_option_icon:focus::before,a.frm_option_icon:hover::before{color:var(--primary-700)}.frm_top_left .frm-dropdown-toggle{color:#999}.frm-card ol{margin-left:15px}.frm-dropdown-toggle{text-decoration:none}.frm-card .frm-dropdown-toggle{border:1px solid var(--grey-300);border-radius:var(--small-radius);font-size:13px;color:var(--grey-700);padding:7px 20px}.frm-dropdown-menu .frm_icon_font{vertical-align:middle;color:#5f6c72;margin-right:3px}.multiselect-container.frm-dropdown-menu{top:auto;left:auto;font-size:var(--text-sm);padding:4px;margin-bottom:3px}.multiselect-container{position:absolute;list-style-type:none;margin:0;padding:0;width:100%;max-width:250px}.multiselect-container button.multiselect-option{width:100%;text-align:left;border:none;margin-bottom:4px}.multiselect-container button.multiselect-option label{margin-left:5px}.accordion-container .multiselect-container label{padding:3px 19px 3px 7px}.frm-btn-group.btn-group>.btn-group:nth-child(2)>.multiselect.btn{border-top-left-radius:4px;border-bottom-left-radius:4px}.frm-btn-group.btn-group,.frm-btn-group.btn-group-vertical{display:block}.multiselect-option label{max-width:calc(100% - 22px);text-overflow:ellipsis;overflow:hidden;white-space:nowrap}#frm_field_multiselect_popup{background:#fff;height:48px;position:fixed;border-radius:4px;box-shadow:0 8px 24px rgba(40,47,54,.15);color:rgba(40,47,54,.85);font-size:13px;right:30px;bottom:10px;z-index:2}#frm_field_multiselect_popup>div{display:inline-block;line-height:48px;vertical-align:top}#frm_field_multiselect_popup.frm-unmergable>.frm-merge-fields-into-row,#frm_field_multiselect_popup.frm-unmergable>.frm-multiselect-popup-separator{display:none}#frm_field_multiselect_popup>div:not(.frm-multiselect-popup-separator){padding:0 20px;cursor:pointer}#frm_field_multiselect_popup>div:not(.frm-multiselect-popup-separator):hover{background:rgba(245,245,245,.9607843137)}.frm-builder-popup-heading{font-weight:600;font-size:11px;line-height:15px;text-transform:uppercase;color:rgba(40,47,54,.45);margin-bottom:7px}.frm-builder-popup-subheading{font-size:12px;line-height:16px;color:rgba(40,47,54,.45)}#frm_field_group_popup input[type=text]{height:30px;border-radius:3px;font-size:14px;padding:8px;color:#545f6e;border-color:rgba(40,47,54,.2)}.frm-multiselect-popup-separator{height:36px;width:1px;position:relative;top:6px;background:#c4c4c4}.frm-sortable-helper,.frm-multiselect-key-is-down li.form-field:not(.edit_field_type_divider){pointer-events:none}.frm-sortable-helper{z-index:99}.frm_code_list a.button{display:block;text-align:center;font-size:11px;overflow:hidden}#frm-navbarDrop+.frm_code_list.frm-full-hover{margin:var(--gap-xs) 0 0;min-width:300px;max-height:256px}.frm_code_list.frm-full-hover li{margin:0}.frm-select-list-item,.frm_wrap .ui-autocomplete li>div,.multiselect-container button.multiselect-option,.frm-dropdown-menu>.dropdown-item>a,.frm-dropdown-menu>.dropdown-item>a:visited,.frm-dropdown-menu>.dropdown-item>a:link,.frm-dropdown-menu .frm_dropdown_li,.frm_code_list.frm-full-hover a{display:flex;color:var(--grey-700);padding:5px 10px;font-size:var(--text-md);gap:var(--gap-xs);align-items:center}.multiselect-container button.multiselect-option.disabled{opacity:.5}.frm_code_list.frm-full-hover a span{max-width:83px;margin-right:var(--gap-xs);margin-left:auto}.frm_code_list.frm-full-hover a{border-radius:var(--small-radius)}.frm_code_list.frm-full-hover a:not(#frm-insert-condition),.frm_code_list.frm-full-hover a span{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.frm_code_list.frm-full-hover a:focus span:last-child{outline:1px solid var(--primary-500);outline-offset:var(--gap-2xs)}.frm_code_list.frm-full-hover.frmcenter a{display:block}#frm-layout-classes frm-full-hover a span{max-width:45%}.frm-select-list-item.active,.frm-select-list-item:hover,.frm_wrap .ui-autocomplete li div.ui-state-active,.frm_wrap .ui-autocomplete li.ui-state-focus,.multiselect-container button.multiselect-option.active,.multiselect-container button.multiselect-option:hover,.frm-dropdown-menu>.dropdown-item>a:hover,.frm_code_list.frm-full-hover a:hover span,.frm_code_list.frm-full-hover a:hover{background:var(--primary-25);color:var(--primary-500)}.frm-select-list-item .frmsvg,.frm-dropdown-menu>.dropdown-item>a .frmsvg{opacity:.8}.frm-select-list-item:hover .frmsvg,.frm-dropdown-menu>.dropdown-item>a:hover .frmsvg{opacity:1}.frm-dropdown-menu.frm_code_list>li>a{padding:3px 15px;width:300px}#frm_edit_box_content_modal .frm-with-search,.frm-dropdown-menu .frm-with-search{padding:var(--gap-xs) 10px 0}.frm-dropdown-menu .subsubsub{padding:0 10px}.frm_grid_container{overflow:visible}.frm_code_list.frm_grid_container{grid-gap:var(--gap-xs)}.frm_code_list.frm_grid_container li{width:auto;margin:0}.frm_code_list.frm_grid_container a{display:block;font-size:var(--text-md) !important;font-weight:500;text-align:center;color:var(--primary-500);background-color:var(--light-blue);border:1px solid var(--primary-300);border-radius:var(--small-radius);padding:10px 0;box-shadow:var(--box-shadow-sm)}.frm_code_list.frm_grid_container a:hover{background-color:var(--primary-500);color:#fff}.frm_code_list.frm_grid_container a:focus-visible{outline:2px solid var(--primary-500);outline-offset:-1px}.frm-single-settings .frm_code_list.frm-full-hover,#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover{padding:0;margin:var(--gap-xs) -10px 0}.frm-single-settings .frm_code_list.frm-full-hover>li>a,#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover>li>a{font-size:var(--text-md);color:var(--grey-900);padding:var(--gap-xs) 12px}.frm-single-settings .frm_code_list.frm-full-hover>li>a span,#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover>li>a span{margin:0}.frm-single-settings .frm_code_list.frm-full-hover>li>a span:first-child,#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover>li>a span:first-child{max-width:130px}.frm-single-settings .frm_code_list.frm-full-hover>li>a span:last-child,#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover>li>a span:last-child{max-width:120px;margin-left:auto}.frm-single-settings .frm_code_list.frm-full-hover>li>a:hover,#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover>li>a:hover{font-weight:500}.frm-single-settings .frm_code_list.frm-full-hover>li>a:hover,.frm-single-settings .frm_code_list.frm-full-hover>li>a:hover .frmsvg,.frm-single-settings .frm_code_list.frm-full-hover>li>a:hover span,#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover>li>a:hover,#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover>li>a:hover .frmsvg,#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover>li>a:hover span{color:var(--primary-500)}#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover{margin:var(--gap-xs) 0 0}#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover a .frmsvg{width:20px;height:20px}#post-body-content+.frm-right-panel h3.accordion-section-title{padding:7px 10px 8px 14px;font-size:var(--text-md);color:var(--grey-700)}.frm-with-line,.accordion-section-content h4{font-size:var(--text-md);font-weight:400;margin:20px -20px 10px;padding:0 20px;color:var(--grey-700);position:relative;border:none !important}.frm-with-line span,.accordion-section-content h4 span{background:#fff;padding:0 var(--gap-xs);position:relative;display:inline-block;z-index:2}.accordion-section-content h4 span{background:var(--sidebar-color)}.frm-right-panel .frm-with-line span{background:var(--sidebar-color) !important;margin-left:-4px}.frm-right-panel .frm-inline-modal .frm-with-line span{background:#fff !important}.frm-with-line::before,.accordion-section-content h4::before{content:"";display:block;position:absolute;border-bottom:1px solid var(--grey-300);left:0;width:100%;top:50%}.control-section .accordion-section-title::after,.customize-pane-child .accordion-section-title::after{top:15px}.accordion-container .frm-dropdown-menu{min-width:40px}.frm-btn-group .multiselect.dropdown-toggle{box-sizing:border-box;min-height:unset;cursor:pointer}.accordion-container .frm-dropdown-menu::before,.accordion-container .multiselect.dropdown-toggle::before{font-family:"s11-fp" !important}.frm-search input[name=s],.frm-search .dropdown-toggle,.frm-search input.frm-search-input{color:var(--grey-800);border-color:var(--grey-300);border-radius:var(--small-radius);box-shadow:var(--box-shadow-xs)}.frm-search input[type=search],.frm-search input[type=text]{padding-left:var(--gap-lg) !important}.frm-search .dropdown-toggle{width:100%;float:none;max-width:200px;background:rgba(0,0,0,0);padding:7px;padding-left:33px !important;min-height:32px;text-align:inherit;overflow:hidden;text-overflow:ellipsis}.frm-search #search-submit a{color:var(--grey-800)}.frm-search #search-submit .caret{opacity:.7}.frm-white-body .search-box input[name=s],#wpwrap .frm-search input[type=search]{flex:1;font-size:var(--text-md);line-height:var(--text-xl);padding:var(--gap-xs)}span.multiselect-selected-text{white-space:nowrap;display:inline-block;max-width:calc(90% - var(--gap-xs));text-overflow:ellipsis;overflow:hidden}.frm_pro_tip,.frm-cta{justify-content:space-between;align-items:center;gap:var(--gap-2xl);padding:var(--gap-xs) var(--gap-sm);border-radius:var(--small-radius);background:var(--primary-25)}.frm-cta.frm-cta-border{border:1px solid var(--primary-200)}.frm-cta.frm-cta-border .frm-cta-footer{background-color:#fff;padding:12px var(--gap-sm);border-top:1px solid var(--primary-200);border-bottom-left-radius:var(--small-radius);border-bottom-right-radius:var(--small-radius);margin-top:12px;margin-bottom:calc(-1*var(--gap-sm));margin-left:calc(-1*var(--gap-sm));margin-right:calc(-1*var(--gap-sm))}.frm-cta h4{font-weight:600;margin-top:0;margin-bottom:var(--gap-2xs)}.frm-cta-green{background-color:var(--success-25)}.frm-cta-green .frm-banner-title{gap:calc(var(--gap-2xs) + 1px);color:var(--grey-700)}.frm-cta-green.frm-cta-border{border-color:var(--success-100)}.frm-cta-green.frm-cta-border .frm-cta-footer{border-color:var(--success-100)}.frm-cta-red{background-color:var(--error-25)}.frm-cta-red.frm-cta-border{border-color:var(--error-100)}.frm-cta-icon{padding:3px 15px 3px 0;border-right:1px solid currentColor}#frm-upgrade-banner{gap:0}#frm-upgrade-banner .frm-cta-icon+.frm-cta-content{margin-right:auto;padding-left:15px}#frm-upgrade-banner.frm-gradient h4,#frm-upgrade-banner.frm-gradient p{color:currentColor}#frm-upgrade-banner.frm-gradient h4{font-size:16px;font-weight:600}#frm-upgrade-banner.frm-gradient p{font-size:14px}.frm-right-panel .inside .frm_pro_tip,.frm_pro_tip{color:var(--grey-700);background:#ffe7de;margin:0 auto;display:flex;gap:var(--gap-xs)}.frm_field_list .frm_pro_tip{margin:10px 15px;position:relative;width:calc(100% - 30px);box-sizing:border-box;font-size:14px}.frm_pro_tip .frmsvg,.frm_pro_tip i{color:var(--orange)}.frm-tip-info{flex:1;text-align:left}.frm-tip-cta{color:var(--orange)}.frm-gradient .frm-tip-cta,.frm-light-tip .frm-gradient .frm-tip-cta{color:currentColor;font-weight:700}.frm-tip-badge{font-size:9px;font-weight:700;text-transform:uppercase;color:#1e63d5;background-color:#fff;line-height:1;border-radius:4px;padding:3px 4px}.frm-light-tip .frm_pro_tip{background:var(--primary-25)}.frm-light-tip .frm_pro_tip .frmsvg,.frm-light-tip .frm_pro_tip i,.frm-light-tip .frm-tip-cta{color:var(--primary-500)}.nav-tab-wrapper .frm_pro_tip{float:right}.frm-gradient,.frm-upgrade-bar{background:linear-gradient(90deg, #388CF3, #1961D5, #8C7FD8) !important;color:#fff !important;border:0 !important}.frm-gradient.frm-button-primary:not([disabled]),.frm-gradient.frm-button-primary:not([disabled]):hover,.frm-gradient.frm-button-primary:not([disabled]):focus{background:linear-gradient(90deg, #1961D5, #816CFA) !important}.frm-upgrade-bar,.frm-gradient{position:relative}.frm-upgrade-bar::before,.frm-gradient::before{content:"";display:none;position:absolute;top:0;right:0;bottom:0;left:0;background-color:rgba(255,255,255,.1);z-index:0}.frm-upgrade-bar:hover::before,.frm-gradient:hover::before,.frm-gradient:focus::before{display:block}.frm-upgrade-bar-inner,.frm-gradient>*{position:relative;z-index:1}.frm-upgrade-bar{border-bottom:1px solid var(--sidebar-hover);padding:9px 0;font-size:12px;text-align:center}.frm-upgrade-bar a{color:currentColor !important;text-decoration:underline}.frm-upgrade-bar a:focus{outline:1px dotted var(--sidebar-hover)}.frm-upgrade-bar span{opacity:.9}.toplevel_page_formidable #wpbody-content>.error{margin:1px;padding:5px 12px}.frm_error_style,.frm_warning_style,.frm_note_style2,.frm_note_style,.frm_message,#post-body-content .frm_updated_message,div.frm_updated_message{border-radius:var(--small-radius);background-color:#d5f2dc;color:#1e561f;padding:var(--gap-sm) var(--gap-md);font-size:var(--text-sm);margin:var(--gap-sm) 0;text-align:left}.frm_note_style2{background:linear-gradient(90deg, #e9effa, #fcf6fe) padding-box,linear-gradient(90deg, #1961D5, #E8ABEF) border-box;border:1px solid rgba(0,0,0,0)}#frm_top_bar+.wrap>.frm_updated_message,#frm_top_bar+.wrap>.frm_warning_style{display:inline-block;width:100%;box-sizing:border-box}#post-body-content>.frm_updated_message{margin:5px 65px}#form_global_settings #post-body-content>.frm_updated_message,#form_global_settings #post-body-content>.frm_warning_style{margin:5px 25px}.frm_error_style{color:#973937;background-color:#ebcccc;clear:both}.frm_error_style a{text-decoration:underline;font-weight:600}.frm_error_style svg{opacity:.7}.frm_warning_style{color:#7a4d05;background-color:#fff2d2}.frm_warning_heading{font-weight:700;margin-bottom:4px}.frm_warning_style{position:relative;padding-right:calc(var(--gap-md) + 15px)}body.rtl .frm_warning_style{padding-right:var(--gap-md);padding-left:calc(var(--gap-md) + 15px)}.frm-warning-dismiss{position:absolute;top:10px;right:10px;display:flex;cursor:pointer;transition:opacity .2s ease-out}body.rtl .frm-warning-dismiss{left:10px;right:auto}.frm-warning-dismiss:hover{opacity:.8}.frm-warning-dismiss.frmsvg,.frm-warning-dismiss.frmsvg svg{width:15px;height:15px}.frm_note_style{background:rgba(188,224,253,.23);color:var(--grey-700)}.frm-banner-alert{text-align:left;margin:0;border-radius:0;padding:10px 0 10px 40px}.frm-banner-alert a{color:var(--primary-500);font-weight:400;text-decoration:none}.frm_updated_message ul,.frm_updated_message li,.frm_warning_style ul,.frm_warning_style li,.frm_error_style ul,.frm_error_style li{margin:0}.frm-inline-message{border:1px solid var(--primary-700);border-radius:var(--small-radius);color:var(--primary-700);background:#fff;text-align:center;padding:20px;font-size:var(--text-sm);line-height:var(--leading)}.frm-inline-message a{text-decoration:underline;font-weight:600;color:var(--primary-700)}.frm_pro_heading span{margin-top:10px}.frm_pro_heading .alignright{text-align:right}.frm-yes{color:var(--green);font-size:var(--text-xl)}.frm-nope{color:var(--grey-400);font-size:var(--text-xl)}.frm-modal:not(#frm-dismissable-cta) .postbox{max-height:600px;overflow:hidden;margin-bottom:0}.frm-modal .postbox .frm_modal_top,.frm-dialog .frm_common_modal .postbox>div:first-child,.frm-error-modal .frm_modal_top{padding:var(--gap-md) var(--gap-md) 0;position:relative}.frm-modal h2,.frm-modal .postbox .inside h2,.frm-modal .postbox .frm-modal-title,.frm-dialog .frm_common_modal .postbox>div:first-child>div:first-child,.frm-error-modal .frm-modal-title{display:inline-block;font-size:var(--text-lg);color:var(--grey-900);font-weight:600;margin:0;padding:0}.frm-modal h3{font-weight:500}.frm-inline-modal>a.dismiss,.frm-modal .postbox>a.dismiss,.frm-modal .postbox .frm-modal-title+div:last-child,.frm-dialog .frm_common_modal .postbox>div:first-child>div:last-child{position:absolute;top:19px;right:19px;display:flex;z-index:2}body.rtl .frm-inline-modal>a.dismiss,body.rtl .frm-modal .postbox>a.dismiss,body.rtl .frm-modal .postbox .frm-modal-title+div:last-child,body.rtl .frm-dialog .frm_common_modal .postbox>div:first-child>div:last-child{right:unset;left:30px}.frm-info-modal .postbox>a.dismiss,.frm-inline-modal>a.dismiss{right:13px;top:13px}.frm-modal .postbox .frm-modal-title+div:last-child a,.frm-modal a.dismiss .frmsvg,.frm_common_modal .frm_modal_top a .frmsvg{color:var(--grey-500)}.frm-modal .postbox .frm-modal-title+div:last-child a:hover,.frm-modal a.dismiss .frmsvg:hover,.frm_common_modal .frm_modal_top a .frmsvg:hover{color:var(--grey-700)}.frm-modal .frm_modal_content>div.inside,.frm_common_modal .frm_modal_content>div.inside{padding:var(--gap-md);margin:0;font-size:var(--text-sm);color:var(--grey-700)}.frm-modal p{color:var(--grey-900)}.frm_common_modal .postbox{display:flex;flex-direction:column}.frm-modal .postbox>div.inside .cta-inside{overflow-y:auto;height:auto}.frm_modal_footer{padding:0 var(--gap-md) var(--gap-sm);text-align:right}body.frm-body-with-open-modal{overflow-y:hidden}.frm-dialog{z-index:100;padding:0 !important;border-radius:16px;border:none;background-color:#fff;max-width:100% !important}.frm-dialog .postbox{background:rgba(0,0,0,0);box-shadow:none;border:none;line-height:var(--leading)}.frm-dialog input[type=text],.frm-dialog textarea{font-size:var(--text-md)}.frm-dialog textarea{height:75px}.frm-dialog button.frm-button-primary{margin-right:10px}.frm-dialog .frm-sub-label,.frm-sub-label{color:var(--grey);text-transform:none;padding-left:8px}h2 .frm-sub-label{font-size:var(--text-md)}.frm-views-editor-body .ui-widget-overlay,.frm-white-body .ui-widget-overlay,.toplevel_page_formidable .ui-widget-overlay,body[class*=formidable-payments] .ui-widget-overlay,body.plugins-php .ui-widget-overlay{position:fixed;width:100%;height:100%;top:0;left:0;right:0;bottom:0;background:var(--grey-500);opacity:.5;z-index:2}.frm-circled-icon{width:60px;height:60px;border-radius:50%;background-color:var(--primary-25)}.frm-circled-icon-large{width:80px;height:80px}.frm-circled-icon-green{background-color:var(--success-50)}.frm-circled-icon .frmsvg{width:21px;height:24px}.frm-circled-icon .frmsvg.frm_svg32{width:32px !important;height:32px !important}.frm-circled-icon-large .frmsvg{width:24px}.frm-circled-icon .frmsvg use{color:var(--primary-500)}.frm-circled-icon-green .frmsvg use{color:var(--success-500)}.frm-border-icon{display:flex;align-items:center;justify-content:center;width:40px;height:40px;border:1px solid var(--grey-300);border-radius:var(--small-radius)}.frm-upgrade-message img{max-width:100%}.frm-inline-flex,#wpbody-content .frm-inline-flex{display:inline-flex}.frm-flex{display:flex}.frm-force-flex{display:flex !important}.frm_hidden,.js .frm-hide-js{display:none}.frm-flex-box{display:flex;gap:var(--gap-sm)}.frm-flex-col{display:flex;flex-direction:column}.frm-flex-full{flex:1}.frm-force-flex-center,.frm-flex-center{justify-content:center;align-items:center}.frm-flex-center{display:flex}.frm-force-flex-center{display:flex !important}.frm-shrink-0{flex-shrink:0}.frm-gap-0{gap:0 !important}.frm-gap-2xs{gap:var(--gap-2xs)}.frm-gap-xs{gap:var(--gap-xs)}.frm-gap-sm{gap:var(--gap-sm)}.frm-gap-md{gap:var(--gap-md)}.frm-gap-xl{gap:var(--gap-xl)}.frm-justify-start{justify-content:start !important}.frm-justify-center{justify-content:center !important}.frm-justify-between{justify-content:space-between}.frm-justify-end{justify-content:end}.frm-items-start{align-items:flex-start}.frm-items-center{align-items:center}.frm-items-stretch{align-items:stretch}.frm-self-normal{align-self:normal}#wpbody-content .frm-flex-wrap{flex-wrap:wrap}.frm-grow{flex-grow:1}.frm-order-first{order:-9999}.frm-order-last{order:9999}.frm-order-none{order:0}.frm-h-stack-sm,.frm-h-stack-xs,.frm-h-stack{display:flex !important;align-items:center}.frm-h-stack-sm>input[type=checkbox],.frm-h-stack-xs>input[type=checkbox],.frm-h-stack>input[type=checkbox],.frm-h-stack-sm>input[type=radio],.frm-h-stack-xs>input[type=radio],.frm-h-stack>input[type=radio]{margin:0 !important}.frm-h-stack{gap:var(--gap-2xs)}.frm-h-stack-xs{gap:var(--gap-xs)}.frm-h-stack-sm{gap:var(--gap-sm)}.frm-flex-row-reverse{flex-direction:row-reverse}.frm-info-modal a,.frm-info-modal ul,.frm-info-modal p,.frm-info-modal,.settings-lite-cta a,.settings-lite-cta ul,.settings-lite-cta{color:var(--grey-500);font-size:var(--text-md);box-shadow:none !important}.frm-info-modal h3,.settings-lite-cta h3{font-size:17px !important}.frm-green-icons .frmsvg{color:var(--green)}.frm-info-modal .postbox .inside,.settings-lite-cta .postbox .inside{padding:var(--gap-md);margin:0}.cta-inside a{color:var(--orange)}.info-modal-inside a.frm-standard-link{color:var(--primary-500)}.info-modal-inside a.frm-standard-link:hover{color:var(--primary-700)}.frm_no_p_margin>p{margin:0}.frm_spinner.frm-wait,.frm_spinner.spinner{float:left;visibility:hidden;margin:0 10px}.frm_visible_spinner.frm-wait,.frm_visible_spinner.spinner{visibility:visible;float:none}.frm_form_action_settings .frm_spinner.frm-wait,.frm_form_action_settings .frm_spinner.spinner{visibility:visible;float:none;vertical-align:bottom}.frm_form_action_settings .frm_loading{font-size:15px;text-align:center}.frm_ajax_settings_tab .frm-wait,.frm_ajax_settings_tab .spinner{visibility:visible;float:none;margin-top:20px}.wp-core-ui .frm_loading_button.button-primary.frm-button-primary,.frm_loading_button,.frm_loading_form.frm_button_submit{position:relative !important;opacity:.8;color:rgba(0,0,0,0) !important;text-shadow:none !important}.frm_loading_button:hover,.frm_loading_button:active,.frm_loading_button:focus,.frm_loading_form.frm_button_submit:hover,.frm_loading_form.frm_button_submit:active,.frm_loading_form.frm_button_submit:focus{cursor:not-allowed;color:rgba(0,0,0,0) !important;outline:none !important;box-shadow:none}.frm-wait{margin:20px;width:20px;height:20px;position:relative;display:inline-block}#frm-show-fields .frm-wait:only-child{position:absolute;left:50px;top:30px}.frm-wait::before,.frm_loading_button::before,.frm_loading_form.frm_button_submit::before{content:"";display:inline-block;position:absolute;background:rgba(0,0,0,0);border:1px solid #fff;border-top-color:rgba(0,0,0,0);border-left-color:rgba(0,0,0,0);border-radius:50%;box-sizing:border-box;top:50%;left:50%;margin-top:-10px;margin-left:-10px;width:20px;height:20px;animation:spin 2s linear infinite}.frm-wait::before{border-bottom-color:var(--primary-700);border-right-color:var(--primary-700)}.frm_loading_button.frm-button-secondary::before{border-bottom-color:var(--primary-500);border-right-color:var(--primary-500)}input[type=submit]:focus{outline:none !important}@keyframes spin{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}.frmsvg{fill:currentColor;width:18px;height:18px;vertical-align:middle}body.frm_preview_page .ui-widget-overlay{position:fixed;width:100%;height:100%;top:0;left:0;right:0;bottom:0;background:var(--grey-500);opacity:.5;z-index:2}#frm_testing_mode{border-radius:1rem;background-color:#fff;border-color:rgba(0,0,0,.1019607843);border-width:1px;border-style:solid;padding:16px 20px;margin-bottom:40px;position:relative}#frm_testing_mode h2{font-size:18px;font-weight:600;color:#000;margin-bottom:0}#frm_testing_mode label{font-size:12px;font-weight:600}#frm_testing_mode label span.frm_toggle_opt{color:var(--grey-800);font-weight:600}#frm_testing_mode label:not(:first-child){margin-left:var(--gap-xs)}#frm_testing_mode a.frm_button{margin-left:auto;border-radius:20px;font-size:14px}#frm_testing_mode hr{color:unset;background:var(--grey-200);height:1px;border:none}#frm_testing_mode>div:nth-of-type(2){display:flex;align-items:center}#frm_testing_mode .multiselect.dropdown-toggle:after{border:none}#frm_testing_mode .frmsvg{width:11px;height:11px;margin-right:var(--gap-2xs);position:relative;top:1px}#frm_testing_mode .frm_toggle_block{gap:var(--gap-xs)}#frm_testing_mode label:not(.frm_toggle_block){margin-right:2px}#frm_testing_mode select{width:auto !important;min-height:auto !important;outline:0;box-shadow:var(--box-shadow-xs);border-radius:var(--small-radius);border-width:1px;padding:5px 14px;border-color:var(--grey-300);color:var(--grey-800);font-size:var(--text-md);margin:0;line-height:var(--leading);appearance:none;background:rgba(0,0,0,0) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' fill='none'%3E%3Cpath stroke='%2398A2B3' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M12.708 8.959 10 11.875 7.292 8.96'/%3E%3C/svg%3E") no-repeat right 8px top 50%;padding-right:var(--gap-lg) !important}#frm_testing_mode select:focus{background-color:rgba(0,0,0,0) !important}#frm_testing_mode select,#frm_testing_mode .btn-group button.multiselect.dropdown-toggle{border-radius:var(--medium-radius);font-size:12px;font-weight:600;height:30px}#frm_testing_mode .btn-group button.multiselect.dropdown-toggle{padding-top:0;padding-bottom:0}#frm_testing_mode .multiselect-selected-text{position:relative;top:2px}#frm_testing_mode #frm_testmode_fill_in_empty_form_fields{background-color:var(--primary-500);color:#fff;padding:8px 18px}#frm_testing_mode .frm_help{vertical-align:top}#frm_testing_mode .frm-button-secondary:hover,#frm_testmode_disable_required_fields_modal .frm-button-secondary:hover,#frm_ai_autofill_error_modal .frm-button-secondary:hover{border-color:var(--grey-300) !important;color:var(--grey-800);background:var(--grey-50) !important;box-shadow:none !important;outline:none !important}#frm_testing_mode a,#frm_testmode_disable_required_fields_modal a,#frm_ai_autofill_error_modal a{text-decoration:none}#frm_testmode_disable_required_fields_modal p{font-size:16px}#frm_test_mode_pagination{display:inline-block;margin-left:var(--gap-xs)}#frm_test_mode_pagination input[type=button]{border:1px solid var(--grey-300);padding:8px 12px;border-radius:8px;font-size:12px;background-color:#fff}#frm_test_mode_pagination input[type=button].frm_test_mode_active_page{background-color:var(--primary-500);border-color:var(--primary-500);color:#fff}#frm_test_mode_pagination input[type=button]:not(.frm_noallow){cursor:pointer}#frm_testmode_start_over{position:absolute;right:20px;top:20px;background-color:#fff;color:var(--grey-800);border-radius:20px;padding:4px 12px;border-color:var(--grey-300);font-weight:600}#frm_testmode_start_over img{vertical-align:middle;position:relative;bottom:2px}.frm_noallow{opacity:.5}#frm_testmode_enabled_form_actions_container{vertical-align:middle;display:inline-block;max-width:200px}#frm_testmode_upgrade{border-radius:16px;padding:var(--gap-xs) var(--gap-sm);text-align:center;font-size:var(--text-xs);margin-top:var(--gap-sm);line-height:var(--text-xs);font-weight:500;text-decoration:none;display:block;margin-left:-20px;margin-right:-20px;margin-bottom:-16px;border-radius:0 0 16px 16px}.frm_warning_style:has(.frm-addon-button){display:flex;padding:var(--gap-sm);line-height:40px}.frm_warning_style .frm-addon-button,#frm_upgrade_modal a.frm-button-primary{text-decoration:none}#frm_upgrade_modal a.frm-button-primary{cursor:pointer}.frm-dialog{z-index:1001}.frm-dialog+.ui-widget-overlay{z-index:1000}@media(max-width: 1024px){#frm_testing_mode>div>label:not(#frm_quick_jump_label){width:100%;display:block !important;margin-left:0 !important}#frm_testing_mode>div>label:not(#frm_quick_jump_label){margin-top:var(--gap-sm)}#frm_testmode_fill_in_empty_form_fields{display:block}#frm_testing_mode>div:nth-of-type(2){flex-direction:column;align-items:normal}#frm_test_mode_pagination{margin-left:0}}
*/.tooltip{position:absolute;display:block;margin:0;font-style:normal;font-weight:400;line-height:1.5;text-align:left;text-align:start;text-decoration:none;text-shadow:none;text-transform:none;letter-spacing:normal;word-break:normal;word-spacing:normal;white-space:normal;line-break:auto;font-size:.875rem;word-wrap:break-word;opacity:0;z-index:9999999;pointer-events:none}.tooltip.show{opacity:.9}.tooltip .arrow{position:absolute;display:block;width:.8rem;height:.4rem;margin-left:0 !important}.tooltip .arrow::before{position:absolute;content:"";border-color:rgba(0,0,0,0);border-style:solid}.bs-tooltip-top,.bs-tooltip-auto[x-placement^=top]{padding:.4rem 0}.bs-tooltip-top .arrow,.bs-tooltip-auto[x-placement^=top] .arrow{bottom:0}.bs-tooltip-top .arrow::before,.bs-tooltip-auto[x-placement^=top] .arrow::before{top:0;border-width:.4rem .4rem 0;border-top-color:#000}.bs-tooltip-right,.bs-tooltip-auto[x-placement^=right]{padding:0 .4rem}.bs-tooltip-right .arrow,.bs-tooltip-auto[x-placement^=right] .arrow{left:0;width:.4rem;height:.8rem}.bs-tooltip-right .arrow::before,.bs-tooltip-auto[x-placement^=right] .arrow::before{right:0;border-width:.4rem .4rem .4rem 0;border-right-color:#000}.bs-tooltip-bottom,.bs-tooltip-auto[x-placement^=bottom]{padding:.4rem 0}.bs-tooltip-bottom .arrow,.bs-tooltip-auto[x-placement^=bottom] .arrow{top:0}.bs-tooltip-bottom .arrow::before,.bs-tooltip-auto[x-placement^=bottom] .arrow::before{bottom:0;border-width:0 .4rem .4rem;border-bottom-color:#000}.bs-tooltip-left,.bs-tooltip-auto[x-placement^=left]{padding:0 .4rem}.bs-tooltip-left .arrow,.bs-tooltip-auto[x-placement^=left] .arrow{right:0;width:.4rem;height:.8rem}.bs-tooltip-left .arrow::before,.bs-tooltip-auto[x-placement^=left] .arrow::before{left:0;border-width:.4rem 0 .4rem .4rem;border-left-color:#000}.tooltip-inner{max-width:200px;padding:.25rem .5rem;color:#fff;text-align:center;background-color:#000;border-radius:.25rem}.frm-dropdown-menu.show{display:block}.frm-single-settings .frm-dropdown-menu.show{background:#fff}.preview.dropdown .dropdown-menu{min-width:205px}.frm_clear{clear:both}.frm_clearfix::after{content:".";display:block;clear:both;visibility:hidden;line-height:0;height:0}.frm_clearfix{display:block}.frm_admin_progress{overflow:hidden;height:20px;margin-bottom:20px;background-color:#f5f5f5;border-radius:4px;box-shadow:inset 0 1px 2px rgba(0,0,0,.1)}.frm_admin_progress_bar{float:left;width:0;height:100%;font-size:12px;line-height:20px;color:#fff;text-align:center;box-shadow:inset 0 -1px 0 rgba(0,0,0,.15);transition:width .6s ease;background-color:#04a4cc}.tooltip.frm_tooltip{position:fixed;top:auto !important;bottom:0 !important;left:0 !important;max-width:none;width:100% !important;z-index:99999}.tooltip.frm_tooltip.bottom{padding:0}.frm_tooltip .tooltip-inner{max-width:none;min-height:40px !important;text-align:left;box-shadow:5px 5px 25px rgba(0,0,0,.5);padding:10px 40px;border-top-color:#ccc;background:var(--sidebar-color);color:var(--grey-700);border-radius:0;opacity:1;font-size:var(--text-sm)}#frm_custom_css_box{width:100%}h1 .fa-caret-down{font-size:18px}.caret{display:inline-block;width:19px;height:9px;margin-right:-8px;vertical-align:middle}.caret,.wp-admin .frm_wrap select,.frm_wrap .frm_form_builder select,.frm_wrap .ui-autocomplete-input{background:rgba(0,0,0,0) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' fill='none'%3E%3Cpath stroke='%2398A2B3' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M12.708 8.959 10 11.875 7.292 8.96'/%3E%3C/svg%3E") no-repeat right 8px top 50%;padding-right:var(--gap-lg) !important}.caret{padding-right:var(--gap-xs) !important;background-position-x:5px}.frm-btn-group .caret{float:right;margin-top:calc(var(--text-md)/2)}.dropdown{position:relative}.dropdown-toggle:focus{outline:0}.frm_wrap .ui-autocomplete,#frm_adv_info.frm-dropdown-menu,.frm-dropdown-menu{position:absolute;top:100%;left:0;z-index:1000;display:none;min-width:10rem;padding-left:4px;padding-right:4px;margin:var(--gap-xs) 0 0;text-align:left;list-style:none;background:none;background-color:#fff;background-clip:padding-box;border:1px solid var(--grey-100);border-radius:.25rem;box-shadow:var(--box-shadow-lg);max-height:200px;overflow-y:auto;overflow-x:hidden;font-size:var(--text-md);width:auto;min-width:160px}.frm6 .frm-dropdown-menu{min-width:100px;max-width:99%}#frm_bs_dropdown .frm-dropdown-menu{max-width:400px}.field_type_list .frm-dropdown-menu{min-width:150px !important}#frm_field_group_controls .frm-dropdown-menu,.frm-field-action-icons .frm-dropdown-menu{min-width:180px !important}.frm-field-action-icons .frm-dropdown-toggle svg,#frm_field_group_controls .frm-dropdown-toggle svg{color:#9ea9b8}.multiselect-container.frm-dropdown-menu,#search-submit .frm-dropdown-menu{min-width:200px !important}.preview .frm-dropdown-menu{min-width:230px !important}.frm-dropdown-menu.dropdown-menu-right{right:0;left:auto}.frm-dropdown-menu .divider{height:1px;margin:9px 0;overflow:hidden;background-color:#e5e5e5}.frm-dropdown-menu>.dropdown-item{margin:0}.frm-select-list-item,.frm_wrap .ui-autocomplete li>div,.multiselect-container button.multiselect-option,.frm-dropdown-menu>.dropdown-item>a,.frm-dropdown-menu .frm_dropdown_li{clear:both;font-weight:400;white-space:nowrap;text-decoration:none;border-radius:var(--small-radius)}.frm-dropdown-menu>.active>a,.frm-dropdown-menu>.active>a:hover,.frm-dropdown-menu>.active>a:focus{text-decoration:none;outline:0}.frm-select-list-item.disabled,.frm-dropdown-menu>.disabled>a,.frm-dropdown-menu>.disabled>a:hover,.frm-dropdown-menu>.disabled>a:focus{color:#999}.frm-select-list-item.disabled:hover,.frm-dropdown-menu>.disabled>a:hover,.frm-dropdown-menu>.disabled>a:focus{text-decoration:none;background-color:rgba(0,0,0,0);background-image:none;cursor:not-allowed}.open>.frm-dropdown-menu{display:block}.open>a{outline:0}.dropdown-header{display:block;padding:3px 10px;font-size:var(--text-xs);color:var(--grey-400)}.dropdown-backdrop{position:fixed;left:0;right:0;bottom:0;top:0;z-index:990}.dropdown-menu-right>.frm-dropdown-menu,.pull-right>.frm-dropdown-menu{right:0;left:auto}.navbar-fixed-bottom .dropdown .caret{border-top:0 dotted;border-bottom:4px solid #000;content:""}.navbar-fixed-bottom .dropdown .frm-dropdown-menu{top:auto;bottom:100%;margin-bottom:1px}.btn{border:1px solid #ddd;background:#fff;height:28px;line-height:var(--leading)}a.frm_option_icon::before{color:var(--primary-500);font-size:22px;width:22px;height:22px}a.frm_option_icon:focus::before,a.frm_option_icon:hover::before{color:var(--primary-700)}.frm_top_left .frm-dropdown-toggle{color:#999}.frm-card ol{margin-left:15px}.frm-dropdown-toggle{text-decoration:none}.frm-card .frm-dropdown-toggle{border:1px solid var(--grey-300);border-radius:var(--small-radius);font-size:13px;color:var(--grey-700);padding:7px 20px}.frm-dropdown-menu .frm_icon_font{vertical-align:middle;color:#5f6c72;margin-right:3px}.multiselect-container.frm-dropdown-menu{top:auto;left:auto;font-size:var(--text-sm);padding:4px;margin-bottom:3px}.multiselect-container{position:absolute;list-style-type:none;margin:0;padding:0;width:100%;max-width:250px}.multiselect-container button.multiselect-option{width:100%;text-align:left;border:none;margin-bottom:4px}.multiselect-container button.multiselect-option label{margin-left:5px}.accordion-container .multiselect-container label{padding:3px 19px 3px 7px}.frm-btn-group.btn-group>.btn-group:nth-child(2)>.multiselect.btn{border-top-left-radius:4px;border-bottom-left-radius:4px}.frm-btn-group.btn-group,.frm-btn-group.btn-group-vertical{display:block}.multiselect-option label{max-width:calc(100% - 22px);text-overflow:ellipsis;overflow:hidden;white-space:nowrap}#frm_field_multiselect_popup{background:#fff;height:48px;position:fixed;border-radius:4px;box-shadow:0 8px 24px rgba(40,47,54,.15);color:rgba(40,47,54,.85);font-size:13px;right:30px;bottom:10px;z-index:2}#frm_field_multiselect_popup>div{display:inline-block;line-height:48px;vertical-align:top}#frm_field_multiselect_popup.frm-unmergable>.frm-merge-fields-into-row,#frm_field_multiselect_popup.frm-unmergable>.frm-multiselect-popup-separator{display:none}#frm_field_multiselect_popup>div:not(.frm-multiselect-popup-separator){padding:0 20px;cursor:pointer}#frm_field_multiselect_popup>div:not(.frm-multiselect-popup-separator):hover{background:rgba(245,245,245,.9607843137)}.frm-builder-popup-heading{font-weight:600;font-size:11px;line-height:15px;text-transform:uppercase;color:rgba(40,47,54,.45);margin-bottom:7px}.frm-builder-popup-subheading{font-size:12px;line-height:16px;color:rgba(40,47,54,.45)}#frm_field_group_popup input[type=text]{height:30px;border-radius:3px;font-size:14px;padding:8px;color:#545f6e;border-color:rgba(40,47,54,.2)}.frm-multiselect-popup-separator{height:36px;width:1px;position:relative;top:6px;background:#c4c4c4}.frm-sortable-helper,.frm-multiselect-key-is-down li.form-field:not(.edit_field_type_divider){pointer-events:none}.frm-sortable-helper{z-index:99}.frm_code_list a.button{display:block;text-align:center;font-size:11px;overflow:hidden}#frm-navbarDrop+.frm_code_list.frm-full-hover{margin:var(--gap-xs) 0 0;min-width:300px;max-height:256px}.frm_code_list.frm-full-hover li{margin:0}.frm-select-list-item,.frm_wrap .ui-autocomplete li>div,.multiselect-container button.multiselect-option,.frm-dropdown-menu>.dropdown-item>a,.frm-dropdown-menu>.dropdown-item>a:visited,.frm-dropdown-menu>.dropdown-item>a:link,.frm-dropdown-menu .frm_dropdown_li,.frm_code_list.frm-full-hover a{display:flex;color:var(--grey-700);padding:5px 10px;font-size:var(--text-md);gap:var(--gap-xs);align-items:center}.multiselect-container button.multiselect-option.disabled{opacity:.5}.frm_code_list.frm-full-hover a span{max-width:83px;margin-right:var(--gap-xs);margin-left:auto}.frm_code_list.frm-full-hover a{border-radius:var(--small-radius)}.frm_code_list.frm-full-hover a:not(#frm-insert-condition),.frm_code_list.frm-full-hover a span{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.frm_code_list.frm-full-hover a:focus span:last-child{outline:1px solid var(--primary-500);outline-offset:var(--gap-2xs)}.frm_code_list.frm-full-hover.frmcenter a{display:block}#frm-layout-classes frm-full-hover a span{max-width:45%}.frm-select-list-item.active,.frm-select-list-item:hover,.frm_wrap .ui-autocomplete li div.ui-state-active,.frm_wrap .ui-autocomplete li.ui-state-focus,.multiselect-container button.multiselect-option.active,.multiselect-container button.multiselect-option:hover,.frm-dropdown-menu>.dropdown-item>a:hover,.frm_code_list.frm-full-hover a:hover span,.frm_code_list.frm-full-hover a:hover{background:var(--primary-25);color:var(--primary-500)}.frm-select-list-item .frmsvg,.frm-dropdown-menu>.dropdown-item>a .frmsvg{opacity:.8}.frm-select-list-item:hover .frmsvg,.frm-dropdown-menu>.dropdown-item>a:hover .frmsvg{opacity:1}.frm-dropdown-menu.frm_code_list>li>a{padding:3px 15px;width:300px}#frm_edit_box_content_modal .frm-with-search,.frm-dropdown-menu .frm-with-search{padding:var(--gap-xs) 10px 0}.frm-dropdown-menu .subsubsub{padding:0 10px}.frm_grid_container{overflow:visible}.frm_code_list.frm_grid_container{grid-gap:var(--gap-xs)}.frm_code_list.frm_grid_container li{width:auto;margin:0}.frm_code_list.frm_grid_container a{display:block;font-size:var(--text-md) !important;font-weight:500;text-align:center;color:var(--primary-500);background-color:var(--light-blue);border:1px solid var(--primary-300);border-radius:var(--small-radius);padding:10px 0;box-shadow:var(--box-shadow-sm)}.frm_code_list.frm_grid_container a:hover{background-color:var(--primary-500);color:#fff}.frm_code_list.frm_grid_container a:focus-visible{outline:2px solid var(--primary-500);outline-offset:-1px}.frm-single-settings .frm_code_list.frm-full-hover,#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover{padding:0;margin:var(--gap-xs) -10px 0}.frm-single-settings .frm_code_list.frm-full-hover>li>a,#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover>li>a{font-size:var(--text-md);color:var(--grey-900);padding:var(--gap-xs) 12px}.frm-single-settings .frm_code_list.frm-full-hover>li>a span,#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover>li>a span{margin:0}.frm-single-settings .frm_code_list.frm-full-hover>li>a span:first-child,#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover>li>a span:first-child{max-width:130px}.frm-single-settings .frm_code_list.frm-full-hover>li>a span:last-child,#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover>li>a span:last-child{max-width:120px;margin-left:auto}.frm-single-settings .frm_code_list.frm-full-hover>li>a:hover,#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover>li>a:hover{font-weight:500}.frm-single-settings .frm_code_list.frm-full-hover>li>a:hover,.frm-single-settings .frm_code_list.frm-full-hover>li>a:hover .frmsvg,.frm-single-settings .frm_code_list.frm-full-hover>li>a:hover span,#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover>li>a:hover,#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover>li>a:hover .frmsvg,#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover>li>a:hover span{color:var(--primary-500)}#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover{margin:var(--gap-xs) 0 0}#frm_builder_page #frm_adv_info .frm_code_list.frm-full-hover a .frmsvg{width:20px;height:20px}#post-body-content+.frm-right-panel h3.accordion-section-title{padding:7px 10px 8px 14px;font-size:var(--text-md);color:var(--grey-700)}.frm-with-line,.accordion-section-content h4{font-size:var(--text-md);font-weight:400;margin:20px -20px 10px;padding:0 20px;color:var(--grey-700);position:relative;border:none !important}.frm-with-line span,.accordion-section-content h4 span{background:#fff;padding:0 var(--gap-xs);position:relative;display:inline-block;z-index:2}.accordion-section-content h4 span{background:var(--sidebar-color)}.frm-right-panel .frm-with-line span{background:var(--sidebar-color) !important;margin-left:-4px}.frm-right-panel .frm-inline-modal .frm-with-line span{background:#fff !important}.frm-with-line::before,.accordion-section-content h4::before{content:"";display:block;position:absolute;border-bottom:1px solid var(--grey-300);left:0;width:100%;top:50%}.control-section .accordion-section-title::after,.customize-pane-child .accordion-section-title::after{top:15px}.accordion-container .frm-dropdown-menu{min-width:40px}.frm-btn-group .multiselect.dropdown-toggle{box-sizing:border-box;min-height:unset;cursor:pointer}.accordion-container .frm-dropdown-menu::before,.accordion-container .multiselect.dropdown-toggle::before{font-family:"s11-fp" !important}.frm-search input[name=s],.frm-search .dropdown-toggle,.frm-search input.frm-search-input{color:var(--grey-800);border-color:var(--grey-300);border-radius:var(--small-radius);box-shadow:var(--box-shadow-xs)}.frm-search input[type=search],.frm-search input[type=text]{padding-left:var(--gap-lg) !important}.frm-search .dropdown-toggle{width:100%;float:none;max-width:200px;background:rgba(0,0,0,0);padding:7px;padding-left:33px !important;min-height:32px;text-align:inherit;overflow:hidden;text-overflow:ellipsis}.frm-search #search-submit a{color:var(--grey-800)}.frm-search #search-submit .caret{opacity:.7}.frm-white-body .search-box input[name=s],#wpwrap .frm-search input[type=search]{flex:1;font-size:var(--text-md);line-height:var(--text-xl);padding:var(--gap-xs)}span.multiselect-selected-text{white-space:nowrap;display:inline-block;max-width:calc(90% - var(--gap-xs));text-overflow:ellipsis;overflow:hidden}.frm_pro_tip,.frm-cta{justify-content:space-between;align-items:center;gap:var(--gap-2xl);padding:var(--gap-xs) var(--gap-sm);border-radius:var(--small-radius);background:var(--primary-25)}.frm-cta.frm-cta-border{border:1px solid var(--primary-200)}.frm-cta.frm-cta-border .frm-cta-footer{background-color:#fff;padding:12px var(--gap-sm);border-top:1px solid var(--primary-200);border-bottom-left-radius:var(--small-radius);border-bottom-right-radius:var(--small-radius);margin-top:12px;margin-bottom:calc(-1*var(--gap-sm));margin-left:calc(-1*var(--gap-sm));margin-right:calc(-1*var(--gap-sm))}.frm-cta h4{font-weight:600;margin-top:0;margin-bottom:var(--gap-2xs)}.frm-cta-green{background-color:var(--success-25)}.frm-cta-green .frm-banner-title{gap:calc(var(--gap-2xs) + 1px);color:var(--grey-700)}.frm-cta-green.frm-cta-border{border-color:var(--success-100)}.frm-cta-green.frm-cta-border .frm-cta-footer{border-color:var(--success-100)}.frm-cta-red{background-color:var(--error-25)}.frm-cta-red.frm-cta-border{border-color:var(--error-100)}.frm-cta-icon{padding:3px 15px 3px 0;border-right:1px solid currentColor}#frm-upgrade-banner{gap:0}#frm-upgrade-banner .frm-cta-icon+.frm-cta-content{margin-right:auto;padding-left:15px}#frm-upgrade-banner.frm-gradient h4,#frm-upgrade-banner.frm-gradient p{color:currentColor}#frm-upgrade-banner.frm-gradient h4{font-size:16px;font-weight:600}#frm-upgrade-banner.frm-gradient p{font-size:14px}.frm-right-panel .inside .frm_pro_tip,.frm_pro_tip{color:var(--grey-700);background:#ffe7de;margin:0 auto;display:flex;gap:var(--gap-xs)}.frm_field_list .frm_pro_tip{margin:10px 15px;position:relative;width:calc(100% - 30px);box-sizing:border-box;font-size:14px}.frm_pro_tip .frmsvg,.frm_pro_tip i{color:var(--orange)}.frm-tip-info{flex:1;text-align:left}.frm-tip-cta{color:var(--orange)}.frm-gradient .frm-tip-cta,.frm-light-tip .frm-gradient .frm-tip-cta{color:currentColor;font-weight:700}.frm-tip-badge{font-size:9px;font-weight:700;text-transform:uppercase;color:#1e63d5;background-color:#fff;line-height:1;border-radius:4px;padding:3px 4px}.frm-light-tip .frm_pro_tip{background:var(--primary-25)}.frm-light-tip .frm_pro_tip .frmsvg,.frm-light-tip .frm_pro_tip i,.frm-light-tip .frm-tip-cta{color:var(--primary-500)}.nav-tab-wrapper .frm_pro_tip{float:right}.frm-gradient,.frm-upgrade-bar{background:linear-gradient(90deg, #388CF3, #1961D5, #8C7FD8) !important;color:#fff !important;border:0 !important}.frm-gradient.frm-button-primary:not([disabled]),.frm-gradient.frm-button-primary:not([disabled]):hover,.frm-gradient.frm-button-primary:not([disabled]):focus{background:linear-gradient(90deg, #1961D5, #816CFA) !important}.frm-upgrade-bar,.frm-gradient{position:relative}.frm-upgrade-bar::before,.frm-gradient::before{content:"";display:none;position:absolute;top:0;right:0;bottom:0;left:0;background-color:hsla(0,0%,100%,.1);z-index:0}.frm-upgrade-bar:hover::before,.frm-gradient:hover::before,.frm-gradient:focus::before{display:block}.frm-upgrade-bar-inner,.frm-gradient>*{position:relative;z-index:1}.frm-upgrade-bar{border-bottom:1px solid var(--sidebar-hover);padding:9px 0;font-size:12px;text-align:center}.frm-upgrade-bar a{color:currentColor !important;text-decoration:underline}.frm-upgrade-bar a:focus{outline:1px dotted var(--sidebar-hover)}.frm-upgrade-bar span{opacity:.9}.toplevel_page_formidable #wpbody-content>.error{margin:1px;padding:5px 12px}.frm_error_style,.frm_warning_style,.frm_note_style2,.frm_note_style,.frm_message,#post-body-content .frm_updated_message,div.frm_updated_message{border-radius:var(--small-radius);background-color:#d5f2dc;color:#1e561f;padding:var(--gap-sm) var(--gap-md);font-size:var(--text-sm);margin:var(--gap-sm) 0;text-align:left}.frm_note_style2{background:linear-gradient(90deg, #e9effa, #fcf6fe) padding-box,linear-gradient(90deg, #1961D5, #E8ABEF) border-box;border:1px solid rgba(0,0,0,0)}#frm_top_bar+.wrap>.frm_updated_message,#frm_top_bar+.wrap>.frm_warning_style{display:inline-block;width:100%;box-sizing:border-box}#post-body-content>.frm_updated_message{margin:5px 65px}#form_global_settings #post-body-content>.frm_updated_message,#form_global_settings #post-body-content>.frm_warning_style{margin:5px 25px}.frm_error_style{color:#973937;background-color:#ebcccc;clear:both}.frm_error_style a{text-decoration:underline;font-weight:600}.frm_error_style svg{opacity:.7}.frm_warning_style{color:#7a4d05;background-color:#fff2d2}.frm_warning_heading{font-weight:700;margin-bottom:4px}.frm_warning_style{position:relative;padding-right:calc(var(--gap-md) + 15px)}body.rtl .frm_warning_style{padding-right:var(--gap-md);padding-left:calc(var(--gap-md) + 15px)}.frm-warning-dismiss{position:absolute;top:10px;right:10px;display:flex;cursor:pointer;transition:opacity .2s ease-out}body.rtl .frm-warning-dismiss{left:10px;right:auto}.frm-warning-dismiss:hover{opacity:.8}.frm-warning-dismiss.frmsvg,.frm-warning-dismiss.frmsvg svg{width:15px;height:15px}.frm_note_style{background:rgba(188,224,253,.23);color:var(--grey-700)}.frm-banner-alert{text-align:left;margin:0;border-radius:0;padding:10px 0 10px 40px}.frm-banner-alert a{color:var(--primary-500);font-weight:400;text-decoration:none}.frm_updated_message ul,.frm_updated_message li,.frm_warning_style ul,.frm_warning_style li,.frm_error_style ul,.frm_error_style li{margin:0}.frm-inline-message{border:1px solid var(--primary-700);border-radius:var(--small-radius);color:var(--primary-700);background:#fff;text-align:center;padding:20px;font-size:var(--text-sm);line-height:var(--leading)}.frm-inline-message a{text-decoration:underline;font-weight:600;color:var(--primary-700)}.frm_pro_heading span{margin-top:10px}.frm_pro_heading .alignright{text-align:right}.frm-yes{color:var(--green);font-size:var(--text-xl)}.frm-nope{color:var(--grey-400);font-size:var(--text-xl)}.frm-modal:not(#frm-dismissable-cta) .postbox{max-height:600px;overflow:hidden;margin-bottom:0}.frm-modal .postbox .frm_modal_top,.frm-dialog .frm_common_modal .postbox>div:first-child,.frm-error-modal .frm_modal_top{padding:var(--gap-md) var(--gap-md) 0;position:relative}.frm-modal h2,.frm-modal .postbox .inside h2,.frm-modal .postbox .frm-modal-title,.frm-dialog .frm_common_modal .postbox>div:first-child>div:first-child,.frm-error-modal .frm-modal-title{display:inline-block;font-size:var(--text-lg);color:var(--grey-900);font-weight:600;margin:0;padding:0}.frm-modal h3{font-weight:500}.frm-inline-modal>a.dismiss,.frm-modal .postbox>a.dismiss,.frm-modal .postbox .frm-modal-title+div:last-child,.frm-dialog .frm_common_modal .postbox>div:first-child>div:last-child{position:absolute;top:19px;right:19px;display:flex;z-index:2}body.rtl .frm-inline-modal>a.dismiss,body.rtl .frm-modal .postbox>a.dismiss,body.rtl .frm-modal .postbox .frm-modal-title+div:last-child,body.rtl .frm-dialog .frm_common_modal .postbox>div:first-child>div:last-child{right:unset;left:30px}.frm-info-modal .postbox>a.dismiss,.frm-inline-modal>a.dismiss{right:13px;top:13px}.frm-modal .postbox .frm-modal-title+div:last-child a,.frm-modal a.dismiss .frmsvg,.frm_common_modal .frm_modal_top a .frmsvg{color:var(--grey-500)}.frm-modal .postbox .frm-modal-title+div:last-child a:hover,.frm-modal a.dismiss .frmsvg:hover,.frm_common_modal .frm_modal_top a .frmsvg:hover{color:var(--grey-700)}.frm-modal .frm_modal_content>div.inside,.frm_common_modal .frm_modal_content>div.inside{padding:var(--gap-md);margin:0;font-size:var(--text-sm);color:var(--grey-700)}.frm-modal p{color:var(--grey-900)}.frm_common_modal .postbox{display:flex;flex-direction:column}.frm-modal .postbox>div.inside .cta-inside{overflow-y:auto;height:auto}.frm_modal_footer{padding:0 var(--gap-md) var(--gap-sm);text-align:right}body.frm-body-with-open-modal{overflow-y:hidden}.frm-dialog{z-index:100;padding:0 !important;border-radius:16px;border:none;background-color:#fff;max-width:100% !important}.frm-dialog .postbox{background:rgba(0,0,0,0);box-shadow:none;border:none;line-height:var(--leading)}.frm-dialog input[type=text],.frm-dialog textarea{font-size:var(--text-md)}.frm-dialog textarea{height:75px}.frm-dialog button.frm-button-primary{margin-right:10px}.frm-dialog .frm-sub-label,.frm-sub-label{color:var(--grey);text-transform:none;padding-left:8px}h2 .frm-sub-label{font-size:var(--text-md)}.frm-views-editor-body .ui-widget-overlay,.frm-white-body .ui-widget-overlay,.toplevel_page_formidable .ui-widget-overlay,body[class*=formidable-payments] .ui-widget-overlay,body.plugins-php .ui-widget-overlay{position:fixed;width:100%;height:100%;top:0;left:0;right:0;bottom:0;background:var(--grey-500);opacity:.5;z-index:2}.frm-circled-icon{width:60px;height:60px;border-radius:50%;background-color:var(--primary-25)}.frm-circled-icon-large{width:80px;height:80px}.frm-circled-icon-green{background-color:var(--success-50)}.frm-circled-icon .frmsvg{width:21px;height:24px}.frm-circled-icon .frmsvg.frm_svg32{width:32px !important;height:32px !important}.frm-circled-icon-large .frmsvg{width:24px}.frm-circled-icon .frmsvg use{color:var(--primary-500)}.frm-circled-icon-green .frmsvg use{color:var(--success-500)}.frm-border-icon{display:flex;align-items:center;justify-content:center;width:40px;height:40px;border:1px solid var(--grey-300);border-radius:var(--small-radius)}.frm-upgrade-message img{max-width:100%}.frm-inline-flex,#wpbody-content .frm-inline-flex{display:inline-flex}.frm-flex{display:flex}.frm-force-flex{display:flex !important}.frm_hidden,.js .frm-hide-js{display:none}.frm-flex-box{display:flex;gap:var(--gap-sm)}.frm-flex-col{display:flex;flex-direction:column}.frm-flex-full{flex:1}.frm-force-flex-center,.frm-flex-center{justify-content:center;align-items:center}.frm-flex-center{display:flex}.frm-force-flex-center{display:flex !important}.frm-shrink-0{flex-shrink:0}.frm-gap-0{gap:0 !important}.frm-gap-2xs{gap:var(--gap-2xs)}.frm-gap-xs{gap:var(--gap-xs)}.frm-gap-sm{gap:var(--gap-sm)}.frm-gap-md{gap:var(--gap-md)}.frm-gap-xl{gap:var(--gap-xl)}.frm-justify-start{justify-content:start !important}.frm-justify-center{justify-content:center !important}.frm-justify-between{justify-content:space-between}.frm-justify-end{justify-content:end}.frm-items-start{align-items:flex-start}.frm-items-center{align-items:center}.frm-items-stretch{align-items:stretch}.frm-self-normal{align-self:normal}#wpbody-content .frm-flex-wrap{flex-wrap:wrap}.frm-grow{flex-grow:1}.frm-order-first{order:-9999}.frm-order-last{order:9999}.frm-order-none{order:0}.frm-h-stack-sm,.frm-h-stack-xs,.frm-h-stack{display:flex !important;align-items:center}.frm-h-stack-sm>input[type=checkbox],.frm-h-stack-xs>input[type=checkbox],.frm-h-stack>input[type=checkbox],.frm-h-stack-sm>input[type=radio],.frm-h-stack-xs>input[type=radio],.frm-h-stack>input[type=radio]{margin:0 !important}.frm-h-stack{gap:var(--gap-2xs)}.frm-h-stack-xs{gap:var(--gap-xs)}.frm-h-stack-sm{gap:var(--gap-sm)}.frm-flex-row-reverse{flex-direction:row-reverse}.frm-info-modal a,.frm-info-modal ul,.frm-info-modal p,.frm-info-modal,.settings-lite-cta a,.settings-lite-cta ul,.settings-lite-cta{color:var(--grey-500);font-size:var(--text-md);box-shadow:none !important}.frm-info-modal h3,.settings-lite-cta h3{font-size:17px !important}.frm-green-icons .frmsvg{color:var(--green)}.frm-info-modal .postbox .inside,.settings-lite-cta .postbox .inside{padding:var(--gap-md);margin:0}.cta-inside a{color:var(--orange)}.info-modal-inside a.frm-standard-link{color:var(--primary-500)}.info-modal-inside a.frm-standard-link:hover{color:var(--primary-700)}.frm_no_p_margin>p{margin:0}.frm_spinner.frm-wait,.frm_spinner.spinner{float:left;visibility:hidden;margin:0 10px}.frm_visible_spinner.frm-wait,.frm_visible_spinner.spinner{visibility:visible;float:none}.frm_form_action_settings .frm_spinner.frm-wait,.frm_form_action_settings .frm_spinner.spinner{visibility:visible;float:none;vertical-align:bottom}.frm_form_action_settings .frm_loading{font-size:15px;text-align:center}.frm_ajax_settings_tab .frm-wait,.frm_ajax_settings_tab .spinner{visibility:visible;float:none;margin-top:20px}.wp-core-ui .frm_loading_button.button-primary.frm-button-primary,.frm_loading_button,.frm_loading_form.frm_button_submit{position:relative !important;opacity:.8;color:rgba(0,0,0,0) !important;text-shadow:none !important}.frm_loading_button:hover,.frm_loading_button:active,.frm_loading_button:focus,.frm_loading_form.frm_button_submit:hover,.frm_loading_form.frm_button_submit:active,.frm_loading_form.frm_button_submit:focus{cursor:not-allowed;color:rgba(0,0,0,0) !important;outline:none !important;box-shadow:none}.frm-wait{margin:20px;width:20px;height:20px;position:relative;display:inline-block}#frm-show-fields .frm-wait:only-child{position:absolute;left:50px;top:30px}.frm-wait::before,.frm_loading_button::before,.frm_loading_form.frm_button_submit::before{content:"";display:inline-block;position:absolute;background:rgba(0,0,0,0);border:1px solid #fff;border-top-color:rgba(0,0,0,0);border-left-color:rgba(0,0,0,0);border-radius:50%;box-sizing:border-box;top:50%;left:50%;margin-top:-10px;margin-left:-10px;width:20px;height:20px;animation:spin 2s linear infinite}.frm-wait::before{border-bottom-color:var(--primary-700);border-right-color:var(--primary-700)}.frm_loading_button.frm-button-secondary::before{border-bottom-color:var(--primary-500);border-right-color:var(--primary-500)}input[type=submit]:focus{outline:none !important}@keyframes spin{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}.frmsvg{fill:currentColor;width:18px;height:18px;vertical-align:middle}body.frm_preview_page .ui-widget-overlay{position:fixed;width:100%;height:100%;top:0;left:0;right:0;bottom:0;background:var(--grey-500);opacity:.5;z-index:2}#frm_testing_mode{border-radius:1rem;background-color:#fff;border-color:rgba(0,0,0,.1019607843);border-width:1px;border-style:solid;padding:16px 20px;margin-bottom:40px;position:relative}#frm_testing_mode h2{font-size:18px;font-weight:600;color:#000;margin-bottom:0}#frm_testing_mode label{font-size:12px;font-weight:600}#frm_testing_mode label span.frm_toggle_opt{color:var(--grey-800);font-weight:600}#frm_testing_mode label:not(:first-child){margin-left:var(--gap-xs)}#frm_testing_mode a.frm_button{margin-left:auto;border-radius:20px;font-size:14px}#frm_testing_mode hr{color:unset;background:var(--grey-200);height:1px;border:none}#frm_testing_mode>div:nth-of-type(2){display:flex;align-items:center}#frm_testing_mode .multiselect.dropdown-toggle:after{border:none}#frm_testing_mode .frmsvg{width:11px;height:11px;margin-right:var(--gap-2xs);position:relative;top:1px}#frm_testing_mode .frm_toggle_block{gap:var(--gap-xs)}#frm_testing_mode label:not(.frm_toggle_block){margin-right:2px}#frm_testing_mode select{width:auto !important;min-height:auto !important;outline:0;box-shadow:var(--box-shadow-xs);border-radius:var(--small-radius);border-width:1px;padding:5px 14px;border-color:var(--grey-300);color:var(--grey-800);font-size:var(--text-md);margin:0;line-height:var(--leading);appearance:none;background:rgba(0,0,0,0) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' fill='none'%3E%3Cpath stroke='%2398A2B3' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M12.708 8.959 10 11.875 7.292 8.96'/%3E%3C/svg%3E") no-repeat right 8px top 50%;padding-right:var(--gap-lg) !important}#frm_testing_mode select:focus{background-color:rgba(0,0,0,0) !important}#frm_testing_mode select,#frm_testing_mode .btn-group button.multiselect.dropdown-toggle{border-radius:var(--medium-radius);font-size:12px;font-weight:600;height:30px}#frm_testing_mode .btn-group button.multiselect.dropdown-toggle{padding-top:0;padding-bottom:0}#frm_testing_mode .multiselect-selected-text{position:relative;top:2px}#frm_testing_mode #frm_testmode_fill_in_empty_form_fields{background-color:var(--primary-500);color:#fff;padding:8px 18px}#frm_testing_mode .frm_help{vertical-align:top}#frm_testing_mode .frm-button-secondary:hover,#frm_testmode_disable_required_fields_modal .frm-button-secondary:hover,#frm_ai_autofill_error_modal .frm-button-secondary:hover{border-color:var(--grey-300) !important;color:var(--grey-800);background:var(--grey-50) !important;box-shadow:none !important;outline:none !important}#frm_testing_mode a,#frm_testmode_disable_required_fields_modal a,#frm_ai_autofill_error_modal a{text-decoration:none}#frm_testmode_disable_required_fields_modal p{font-size:16px}#frm_test_mode_pagination{display:inline-block;margin-left:var(--gap-xs)}#frm_test_mode_pagination input[type=button]{border:1px solid var(--grey-300);padding:8px 12px;border-radius:8px;font-size:12px;background-color:#fff}#frm_test_mode_pagination input[type=button].frm_test_mode_active_page{background-color:var(--primary-500);border-color:var(--primary-500);color:#fff}#frm_test_mode_pagination input[type=button]:not(.frm_noallow){cursor:pointer}#frm_testmode_start_over{position:absolute;right:20px;top:20px;background-color:#fff;color:var(--grey-800);border-radius:20px;padding:4px 12px;border-color:var(--grey-300);font-weight:600}#frm_testmode_start_over img{vertical-align:middle;position:relative;bottom:2px}.frm_noallow{opacity:.5}#frm_testmode_enabled_form_actions_container{vertical-align:middle;display:inline-block;max-width:200px}#frm_testmode_upgrade{border-radius:16px;padding:var(--gap-xs) var(--gap-sm);text-align:center;font-size:var(--text-xs);margin-top:var(--gap-sm);line-height:var(--text-xs);font-weight:500;text-decoration:none;display:block;margin-left:-20px;margin-right:-20px;margin-bottom:-16px;border-radius:0 0 16px 16px}.frm_warning_style:has(.frm-addon-button){display:flex;padding:var(--gap-sm);line-height:40px}.frm_warning_style .frm-addon-button,#frm_upgrade_modal a.frm-button-primary{text-decoration:none}#frm_upgrade_modal a.frm-button-primary{cursor:pointer}.frm-dialog{z-index:1001}.frm-dialog+.ui-widget-overlay{z-index:1000}@media(max-width: 1024px){#frm_testing_mode>div>label:not(#frm_quick_jump_label){width:100%;display:block !important;margin-left:0 !important}#frm_testing_mode>div>label:not(#frm_quick_jump_label){margin-top:var(--gap-sm)}#frm_testmode_fill_in_empty_form_fields{display:block}#frm_testing_mode>div:nth-of-type(2){flex-direction:column;align-items:normal}#frm_test_mode_pagination{margin-left:0}}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

# First, let's look at the file to understand its structure
file_path="css/frm_testing_mode.css"
if [ -f "$file_path" ]; then
  echo "=== File exists, checking size ==="
  wc -l "$file_path"
  echo ""
  echo "=== First 100 characters of the file ==="
  head -c 100 "$file_path"
  echo ""
  echo ""
  echo "=== Checking for duplicate .tooltip patterns ==="
  grep -o "\.tooltip" "$file_path" | wc -l
else
  echo "File not found at $file_path"
fi

Repository: Strategy11/formidable-forms

Length of output: 198


🏁 Script executed:

# Let's check the git diff to see what changed on line 3
git diff HEAD~1 css/frm_testing_mode.css 2>/dev/null || echo "Git diff not available"

Repository: Strategy11/formidable-forms

Length of output: 198


🏁 Script executed:

# Let's check if there's a pattern of .tooltip appearing multiple times
rg "\.tooltip\s*\{" css/frm_testing_mode.css

Repository: Strategy11/formidable-forms

Length of output: 33982


Remove the stray closing comment delimiter at the start of the file.

The file begins with a malformed */ before the .tooltip CSS rules. This is a syntax error that should be removed. The CSS appears to be minified, but this stray closing comment marker is invalid and may cause parsing issues.

🧰 Tools
🪛 Biome (2.1.2)

[error] 3-3: Duplicate properties can lead to unexpected behavior and may override previous declarations unintentionally.

text-align is already defined here.

Remove or rename the duplicate property to ensure consistent styling.

(lint/suspicious/noDuplicateProperties)


[error] 3-3: Duplicate properties can lead to unexpected behavior and may override previous declarations unintentionally.

min-width is already defined here.

Remove or rename the duplicate property to ensure consistent styling.

(lint/suspicious/noDuplicateProperties)


[error] 3-3: Duplicate properties can lead to unexpected behavior and may override previous declarations unintentionally.

border-radius is already defined here.

Remove or rename the duplicate property to ensure consistent styling.

(lint/suspicious/noDuplicateProperties)

🤖 Prompt for AI Agents
In @css/frm_testing_mode.css at line 3, The file starts with a stray closing
comment delimiter ("*/") before the .tooltip rule which breaks CSS parsing;
remove that stray "*/" at the very start so the stylesheet begins with the
.tooltip selector (look for the leading "*/.tooltip" sequence) and verify there
are no other orphaned comment markers at the top of the file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants