point-click-components 0.3.4 → 0.3.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/point-click-components.d.ts +19 -0
- package/dist/point-click-components.js +3096 -3088
- package/package.json +1 -1
|
@@ -25,6 +25,7 @@ import { ReactNode } from 'react';
|
|
|
25
25
|
import { Reducer } from 'react';
|
|
26
26
|
import { RoomData } from 'point-click-lib';
|
|
27
27
|
import { SerializedStyles } from '@emotion/react';
|
|
28
|
+
import { SetStateAction } from 'react';
|
|
28
29
|
import { SoundValue } from 'point-click-lib';
|
|
29
30
|
import { SpriteData } from 'point-click-lib';
|
|
30
31
|
import { StaticFrameParamsS } from 'point-click-lib';
|
|
@@ -169,6 +170,12 @@ export declare type GameRunnerOptions = Partial<GameRuntimeOptions> & {
|
|
|
169
170
|
maxCameraMove?: number;
|
|
170
171
|
};
|
|
171
172
|
|
|
173
|
+
export declare const GameToggle: ({ controlling }: GameToggleProps) => JSX.Element;
|
|
174
|
+
|
|
175
|
+
declare interface GameToggleProps {
|
|
176
|
+
controlling: 'paused' | 'sound off' | 'highlights on';
|
|
177
|
+
}
|
|
178
|
+
|
|
172
179
|
export declare type GetImageAsset = {
|
|
173
180
|
(id: string): ImageAsset | undefined;
|
|
174
181
|
};
|
|
@@ -467,6 +474,18 @@ export declare const useLocalSavedGame: () => {
|
|
|
467
474
|
|
|
468
475
|
export declare const usePlayerInventory: () => ItemData[];
|
|
469
476
|
|
|
477
|
+
/**
|
|
478
|
+
* Returns a `setState` function that can be set as the `ref` of an element to
|
|
479
|
+
* identify that element as the container for a game screen component.
|
|
480
|
+
*
|
|
481
|
+
* Sets up a resizeObserver to adjust the watch the size of the containing element and
|
|
482
|
+
* set the screen size to fit the container, allowing for a responsive layout.
|
|
483
|
+
*
|
|
484
|
+
* The container element should be styled with `overflow: hidden` so it does not extend
|
|
485
|
+
* to accomodate its children.
|
|
486
|
+
*/
|
|
487
|
+
export declare const useResizeContainer: () => Dispatch<SetStateAction<HTMLElement | null>>;
|
|
488
|
+
|
|
470
489
|
export declare const useRoomRender: () => {
|
|
471
490
|
roomData: {
|
|
472
491
|
id: string;
|