Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 0 additions & 22 deletions .babelrc

This file was deleted.

39 changes: 0 additions & 39 deletions .eslintrc

This file was deleted.

2 changes: 1 addition & 1 deletion .github/CODEOWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
# Each line is a file pattern followed by one or more owners.

# These owners will be the default owners for everything in the repo.
* @902seanryan @aberkie @corinnejean
* @pbs/springroll-game-reviewers
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,6 @@
docs
components
node_modules
*.log
*.log
# OSX
.DS_Store
2 changes: 1 addition & 1 deletion .prettierrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ module.exports = {
tabWidth: 2,
useTabs: false,
proseWrap: 'preserve',
parser: 'babel',
parser: 'typescript',
printWidth: 80,
arrowParens: 'avoid'
};
35 changes: 0 additions & 35 deletions Bellhop.d.ts

This file was deleted.

6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [3.7.0] - Unreleased

### Changed

- Converted Bellhop project to Typescript [ticket](https://pbskids.atlassian.net/browse/SR-38)

## [3.6.0] - 2024-10-25

### Changed
Expand Down
34 changes: 34 additions & 0 deletions dist/Bellhop.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
import { BellhopEventDispatcher, BellhopEvent } from './BellhopEventDispatcher';
type DebugCallback = (opts: {
isChild: boolean;
received: boolean;
message: unknown;
}) => void;
type RespondData = object | string | number | boolean | (() => unknown) | (() => Promise<unknown>);
export declare class Bellhop extends BellhopEventDispatcher {
id: string;
connected: boolean;
isChild: boolean;
connecting: boolean;
debug: boolean | DebugCallback;
origin: string | null;
supported: boolean;
_sendLater: Array<{
type: string;
data: unknown;
}>;
iframe: HTMLIFrameElement | null;
receive: (message: MessageEvent) => void;
constructor(id?: string | number);
private onConnectionReceived;
connect(iframe?: HTMLIFrameElement, origin?: string): void;
disconnect(): void;
send(type: string, data?: unknown): void;
fetch(event: string, callback: (e: BellhopEvent) => void, data?: unknown, runOnce?: boolean): void;
respond(event: string, data?: RespondData, runOnce?: boolean): void;
logDebugMessage(received: boolean | undefined, message: unknown): void;
destroy(): void;
get target(): Window | null;
}
export {};
//# sourceMappingURL=Bellhop.d.ts.map
1 change: 1 addition & 0 deletions dist/Bellhop.d.ts.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions dist/Bellhop.spec.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
export {};
//# sourceMappingURL=Bellhop.spec.d.ts.map
1 change: 1 addition & 0 deletions dist/Bellhop.spec.d.ts.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 14 additions & 0 deletions dist/BellhopEventDispatcher.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
export interface BellhopEvent {
type: string;
data: unknown;
}
export declare class BellhopEventDispatcher {
private _listeners;
constructor();
on(name: string, callback: (event: BellhopEvent) => void, priority?: number): void;
private listenerSorter;
off(name: string, callback?: (event: BellhopEvent) => void): void;
trigger(event: BellhopEvent | string, data?: unknown): void;
destroy(): void;
}
//# sourceMappingURL=BellhopEventDispatcher.d.ts.map
1 change: 1 addition & 0 deletions dist/BellhopEventDispatcher.d.ts.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading