Plugin packaging and docs
This commit is contained in:
@@ -12,7 +12,7 @@ import Checkbox from '../form/input/Checkbox';
|
||||
import Switch from '../form/switch/Switch';
|
||||
import { useToast } from '../ui/toast/ToastContainer';
|
||||
import { integrationApi, SiteIntegration } from '../../services/integration.api';
|
||||
import { fetchAPI } from '../../services/api';
|
||||
import { fetchAPI, API_BASE_URL } from '../../services/api';
|
||||
import {
|
||||
CheckCircleIcon,
|
||||
AlertIcon,
|
||||
@@ -171,8 +171,8 @@ export default function WordPressIntegrationForm({
|
||||
};
|
||||
|
||||
const handleDownloadPlugin = () => {
|
||||
// Use the backend API endpoint for plugin download
|
||||
const pluginUrl = `/api/plugins/igny8-wp-bridge/download/`;
|
||||
// Use the backend API endpoint for plugin download (must use full API URL, not relative)
|
||||
const pluginUrl = `${API_BASE_URL}/plugins/igny8-wp-bridge/download/`;
|
||||
window.open(pluginUrl, '_blank');
|
||||
toast.success('Plugin download started');
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user