plugin updates

This commit is contained in:
Tony Volpe
2024-06-17 15:33:26 -04:00
parent 3751a5a1a6
commit e4e274a9a7
2674 changed files with 0 additions and 507851 deletions

View File

@@ -1,27 +0,0 @@
type ContentEmbedInfoResponse = {
success: boolean;
data?: {
// Empty if user doesn't have permissions or plugin already activated
activateAjaxUrl?: string;
message: string;
};
};
export function startInstall(nonce: string) {
const formData = new FormData();
const ajaxUrl = (window as any).ajaxurl;
formData.append('_wpnonce', nonce);
formData.append('action', 'content_embed_install');
return fetch(ajaxUrl, {
method: 'POST',
body: formData,
keepalive: true,
}).then<ContentEmbedInfoResponse>(res => res.json());
}
export function startActivation(requestUrl: string) {
return fetch(requestUrl, {
method: 'POST',
keepalive: true,
}).then<ContentEmbedInfoResponse>(res => res.json());
}