Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@cloudquery/plugin-config-ui-connector

Package Overview
Dependencies
Maintainers
0
Versions
37
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@cloudquery/plugin-config-ui-connector - npm Package Compare versions

Comparing version 0.0.5 to 0.0.6

29

dist/index.d.ts
/**
* Type of the message handler for the CloudQuery Cloud App form.
* @public
*/
export declare type FormMessageHandler = MessageHandler<FormMessageType, FormMessagePayload, PluginUiMessageType, PluginUiMessagePayload>;
/**
* Type representing the payload structure for form messages.

@@ -12,3 +18,3 @@ *

initialValues: {
migrateMode: string | undefined;
migrateMode: 'forced' | 'safe' | undefined;
envs: Array<{

@@ -20,3 +26,3 @@ name: string;

tables: string[] | undefined;
writeMode: string | undefined;
writeMode: 'append' | 'overwrite' | 'overwrite-delete-stale' | undefined;
} | undefined;

@@ -57,3 +63,3 @@ };

*/
export declare function getPluginUiMessageHandler(): MessageHandler<"height_changed" | "validation_passed" | "validation_failed" | "open_url", PluginUiMessagePayload, "init" | "validate" | "submit_failed", FormMessagePayload>;
export declare function getPluginUiMessageHandler(): MessageHandler<"height_changed" | "validation_passed" | "validation_failed" | "open_url" | "ready" | "show_submit_button", PluginUiMessagePayload, "init" | "validate" | "submit_failed", FormMessagePayload>;

@@ -136,3 +142,3 @@ /**

values: {
migrateMode?: string;
migrateMode?: 'forced' | 'safe';
envs: Array<{

@@ -144,3 +150,3 @@ name: string;

tables?: string[];
writeMode?: string;
writeMode?: 'append' | 'overwrite' | 'overwrite-delete-stale';
};

@@ -166,2 +172,13 @@ };

};
/**
* Payload for the 'ready' message type.
*/
ready: {
hideSubmitButton?: boolean;
};
/**
* Payload for the 'show_submit_button' message type.
* This message type has no associated payload.
*/
show_submit_button: void;
};

@@ -182,4 +199,4 @@

*/
export declare const pluginUiMessageTypes: readonly ["height_changed", "validation_passed", "validation_failed", "open_url"];
export declare const pluginUiMessageTypes: readonly ["height_changed", "validation_passed", "validation_failed", "open_url", "ready", "show_submit_button"];
export { }

@@ -1,1 +0,1 @@

!function(e,s){if("object"==typeof exports&&"object"==typeof module)module.exports=s();else if("function"==typeof define&&define.amd)define([],s);else{var t=s();for(var a in t)("object"==typeof exports?exports:e)[a]=t[a]}}(this,(()=>(()=>{"use strict";var e={d:(s,t)=>{for(var a in t)e.o(t,a)&&!e.o(s,a)&&Object.defineProperty(s,a,{enumerable:!0,get:t[a]})},o:(e,s)=>Object.prototype.hasOwnProperty.call(e,s),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},s={};e.r(s),e.d(s,{MessageHandler:()=>i,formMessageTypes:()=>n,getPluginUiMessageHandler:()=>o,pluginUiMessageTypes:()=>a});const t="plugin-ui-connector-iframe",a=["height_changed","validation_passed","validation_failed","open_url"],n=["init","validate","submit_failed"];class i{constructor(e,s,t){this.callbacks=new Map,this.sendMessageTypes=new Set,this.receiveMessageTypes=new Set,this.sendMessageTypes=new Set(e),this.receiveMessageTypes=new Set(s),this.sendMessageWindow=t,window.addEventListener("message",this.handleMessage.bind(this))}sendMessage(e,s){if(!this.sendMessageTypes.has(e))throw new Error(`Unknown send message type: ${String(e)}`);this.sendMessageWindow.postMessage({type:e,payload:s,id:t},"*")}subscribeToMessage(e,s){if(!this.receiveMessageTypes.has(e))throw new Error(`Unknown receive message type: ${String(e)}`);const t=this.callbacks.get(e);return t?t.push(s):this.callbacks.set(e,[s]),()=>{const t=this.callbacks.get(e);t&&this.callbacks.set(e,t.filter((e=>e!==s)))}}subscribeToMessageOnce(e,s){const t=a=>{s(a);const n=this.callbacks.get(e);n&&this.callbacks.set(e,n.filter((e=>e!==t)))};return this.subscribeToMessage(e,t)}handleMessage(e){const{id:s}=e.data;if(s!==t)return;const a=e.data.type,n=this.callbacks.get(a);if(n)for(const s of n)s(e.data.payload)}}function o(){return new i(a,n,window.parent)}return s})()));
!function(e,s){if("object"==typeof exports&&"object"==typeof module)module.exports=s();else if("function"==typeof define&&define.amd)define([],s);else{var t=s();for(var a in t)("object"==typeof exports?exports:e)[a]=t[a]}}(this,(()=>(()=>{"use strict";var e={d:(s,t)=>{for(var a in t)e.o(t,a)&&!e.o(s,a)&&Object.defineProperty(s,a,{enumerable:!0,get:t[a]})},o:(e,s)=>Object.prototype.hasOwnProperty.call(e,s),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},s={};e.r(s),e.d(s,{MessageHandler:()=>i,formMessageTypes:()=>n,getPluginUiMessageHandler:()=>o,pluginUiMessageTypes:()=>a});const t="plugin-ui-connector-iframe",a=["height_changed","validation_passed","validation_failed","open_url","ready","show_submit_button"],n=["init","validate","submit_failed"];class i{constructor(e,s,t){this.callbacks=new Map,this.sendMessageTypes=new Set,this.receiveMessageTypes=new Set,this.sendMessageTypes=new Set(e),this.receiveMessageTypes=new Set(s),this.sendMessageWindow=t,window.addEventListener("message",this.handleMessage.bind(this))}sendMessage(e,s){if(!this.sendMessageTypes.has(e))throw new Error(`Unknown send message type: ${String(e)}`);this.sendMessageWindow.postMessage({type:e,payload:s,id:t},"*")}subscribeToMessage(e,s){if(!this.receiveMessageTypes.has(e))throw new Error(`Unknown receive message type: ${String(e)}`);const t=this.callbacks.get(e);return t?t.push(s):this.callbacks.set(e,[s]),()=>{const t=this.callbacks.get(e);t&&this.callbacks.set(e,t.filter((e=>e!==s)))}}subscribeToMessageOnce(e,s){const t=a=>{s(a);const n=this.callbacks.get(e);n&&this.callbacks.set(e,n.filter((e=>e!==t)))};return this.subscribeToMessage(e,t)}handleMessage(e){const{id:s}=e.data;if(s!==t)return;const a=e.data.type,n=this.callbacks.get(a);if(n)for(const s of n)s(e.data.payload)}}function o(){return new i(a,n,window.parent)}return s})()));
{
"name": "@cloudquery/plugin-config-ui-connector",
"description": "Plugin configuration UI connector for CloudQuery Cloud App",
"version": "0.0.5",
"version": "0.0.6",
"private": false,

@@ -6,0 +6,0 @@ "main": "./dist/index.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc