aboutsummaryrefslogtreecommitdiff
path: root/src/background/clients/ConsoleFrameClient.ts
diff options
context:
space:
mode:
Diffstat (limited to 'src/background/clients/ConsoleFrameClient.ts')
-rw-r--r--src/background/clients/ConsoleFrameClient.ts15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/background/clients/ConsoleFrameClient.ts b/src/background/clients/ConsoleFrameClient.ts
new file mode 100644
index 0000000..170566d
--- /dev/null
+++ b/src/background/clients/ConsoleFrameClient.ts
@@ -0,0 +1,15 @@
+import * as messages from "../../shared/messages";
+
+export default interface ConsoleFrameClient {
+ resize(tabId: number, width: number, height: number): Promise<void>;
+}
+
+export class ConsoleFrameClientImpl implements ConsoleFrameClient {
+ async resize(tabId: number, width: number, height: number): Promise<void> {
+ await browser.tabs.sendMessage(tabId, {
+ type: messages.CONSOLE_RESIZE,
+ width,
+ height,
+ });
+ }
+}