This commit is contained in:
2026-02-21 23:57:03 +01:00
commit 2d9e3a6044
26 changed files with 6716 additions and 0 deletions

5
frontend/index.tsx Normal file
View File

@@ -0,0 +1,5 @@
import { definePlugin } from '@steambrew/client';
export default definePlugin(() => {
console.log('.rip Extension: Frontend plugin initializing...');
});

16
frontend/settings.tsx Normal file
View File

@@ -0,0 +1,16 @@
import { BindPluginSettings } from '@steambrew/client';
type CheckBox = true | false;
type EnumerateInternal<N extends number, Acc extends number[] = []> = Acc['length'] extends N ? Acc[number] : EnumerateInternal<N, [...Acc, Acc['length']]>;
type Enumerate<Min extends number, Max extends number> = Exclude<EnumerateInternal<Max>, EnumerateInternal<Min>> | Max;
type NumberTextInput<Min extends number, Max extends number> = Min | Enumerate<Min, Max>;
type DropDown<T extends readonly any[]> = T[number];
interface SettingsProps {
doFrontEndCall: CheckBox;
overrideWebkitDocument: CheckBox;
numberTextInput: NumberTextInput<1, 100>;
frontEndMessage: DropDown<['hello', 'hi', 'hello again', false, 69]>;
}
export let PluginSettings: SettingsProps = BindPluginSettings();

9
frontend/tsconfig.json Normal file
View File

@@ -0,0 +1,9 @@
{
"extends": "../tsconfig.json",
"compilerOptions": {
"jsxFactory": "window.SP_REACT.createElement",
"jsxFragmentFactory": "window.SP_REACT.Fragment"
},
"include": ["."],
"exclude": ["node_modules", "../webkit"]
}