Skip to content

fix: Woo functionality based on API key Verification Failed or Expired#1849

Merged
subodhr258 merged 1 commit intodevelopfrom
fix/api-key-woo
May 6, 2026
Merged

fix: Woo functionality based on API key Verification Failed or Expired#1849
subodhr258 merged 1 commit intodevelopfrom
fix/api-key-woo

Conversation

@subodhr258
Copy link
Copy Markdown
Collaborator

This pull request introduces improvements to the video editor's extensibility and user experience, especially around add-on layers (such as WooCommerce) and API key status handling. The changes enable dynamic registration and display of new layer types, enhance the UI to support custom icons, and prevent user confusion by accurately reflecting API key verification status.

Extensibility and Add-on Layer Support:

  • pages/video-editor/VideoJSPlayer.js: Allows dynamic registration of add-on layer types via the global window.godamVideoEditorConfig.layerOptions, enabling external plugins to inject new layer types.
  • pages/video-editor/VideoJSPlayer.js: Updates the layer indicator to display either a custom icon image (iconUrl) for add-on layers or the default SVG icon, improving visual support for third-party integrations.
  • pages/video-editor/style.scss: Adds styling for add-on layer icons rendered as images, ensuring consistent sizing and alignment with existing icons.

Layer Activation and UI Controls:

API Key Status Handling:

  • admin/class-rtgodam-transcoder-admin.php: Improves the logic for showing the expired API key notice by checking the runtime status from rtgodam_user_data instead of the persistent status, ensuring that transient verification failures (such as temporary server issues) do not incorrectly trigger the notice.

Recording

Woo.API.Key.verification.mov

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 6, 2026

🔍 WordPress Plugin Check Report

⚠️ Status: Passed with warnings

📊 Report

🎯 Total Issues ❌ Errors ⚠️ Warnings
14 0 14

⚠️ Warnings (14)

📁 composer.json (1 warning)
📍 Line 🔖 Check 💬 Message
0 missing_composer_json_file The "/vendor" directory using composer exists, but "composer.json" file is missing.
📁 readme.txt (2 warnings)
📍 Line 🔖 Check 💬 Message
0 mismatched_plugin_name Plugin name "GoDAM - Organize WordPress Media Library & File Manager with Unlimited Folders for Images, Videos & more" is different from the name declared in plugin header "GoDAM".
0 trademarked_term The plugin name includes a restricted term. Your chosen plugin name - "GoDAM - Organize WordPress Media Library & File Manager with Unlimited Folders for Images, Videos & more" - contains the restricted term "wordpress" which cannot be used at all in your plugin name.
📁 assets/build/css/main.css (1 warning)
📍 Line 🔖 Check 💬 Message
0 EnqueuedStylesScope This style is being loaded in all contexts.
📁 assets/src/libs/analytics.min.js (5 warnings)
📍 Line 🔖 Check 💬 Message
0 EnqueuedScriptsScope This script is being loaded in all frontend contexts.
0 NonBlockingScripts.NoStrategy This script on http://localhost:8880 (with handle analytics-library) is loaded in the footer. Consider a defer or async script loading strategy instead.
0 NonBlockingScripts.NoStrategy This script on http://localhost:8880/2026/05/06/hello-world/ (with handle analytics-library) is loaded in the footer. Consider a defer or async script loading strategy instead.
0 NonBlockingScripts.NoStrategy This script on http://localhost:8880/sample-page/ (with handle analytics-library) is loaded in the footer. Consider a defer or async script loading strategy instead.
0 NonBlockingScripts.NoStrategy This script on http://localhost:8880/demo-attachment-post/ (with handle analytics-library) is loaded in the footer. Consider a defer or async script loading strategy instead.
📁 assets/build/js/main.min.js (5 warnings)
📍 Line 🔖 Check 💬 Message
0 EnqueuedScriptsScope This script is being loaded in all frontend contexts.
0 NonBlockingScripts.NoStrategy This script on http://localhost:8880 (with handle rtgodam-script) is loaded in the footer. Consider a defer or async script loading strategy instead.
0 NonBlockingScripts.NoStrategy This script on http://localhost:8880/2026/05/06/hello-world/ (with handle rtgodam-script) is loaded in the footer. Consider a defer or async script loading strategy instead.
0 NonBlockingScripts.NoStrategy This script on http://localhost:8880/sample-page/ (with handle rtgodam-script) is loaded in the footer. Consider a defer or async script loading strategy instead.
0 NonBlockingScripts.NoStrategy This script on http://localhost:8880/demo-attachment-post/ (with handle rtgodam-script) is loaded in the footer. Consider a defer or async script loading strategy instead.

🤖 Generated by WordPress Plugin Check Action • Learn more about Plugin Check

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR improves the video editor’s extensibility for add-on layer types (e.g., WooCommerce) and refines API key status handling so transient verification failures don’t incorrectly surface as “expired” UX.

Changes:

  • Extends video editor layer type support by merging PHP-filtered window.godamVideoEditorConfig.layerOptions into the layer type registry.
  • Updates the layer indicator UI to render add-on layer icons via iconUrl (image) when provided, with matching SCSS styling.
  • Adjusts admin “expired API key” notice logic to suppress the expired banner when the runtime status is verification_failed.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

File Description
pages/video-editor/VideoJSPlayer.js Merges add-on layer type options and renders either SVG icons or iconUrl images in the seeker layer indicator.
pages/video-editor/style.scss Adds sizing/alignment rules for add-on layer icon <img> rendering in the seeker indicator.
pages/video-editor/components/SidebarLayers.js Disables sidebar layer selection controls when the relevant integration/plugin is inactive.
admin/class-rtgodam-transcoder-admin.php Uses cached runtime user-data status to avoid showing an “expired” banner during transient verification failures.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread pages/video-editor/components/SidebarLayers.js
@subodhr258 subodhr258 merged commit b4c7e8c into develop May 6, 2026
7 checks passed
@subodhr258 subodhr258 deleted the fix/api-key-woo branch May 6, 2026 15:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants