-
-
Save ashikka/2ae1053e10d028eb80235d79e77df618 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React from "react"; | |
| import "./styles.css"; | |
| import { PanelController } from "./controllers/PanelController.jsx"; | |
| import Unsplash from "./panels/Unsplash"; | |
| import { entrypoints } from "uxp"; | |
| const unsplashController = new PanelController(() => <Unsplash />, { | |
| id: "unsplashController", | |
| menuItems: [ | |
| { | |
| id: "reload1", | |
| label: "Reload Plugin", | |
| enabled: true, | |
| checked: false, | |
| oninvoke: () => location.reload(), | |
| }, | |
| ], | |
| }); | |
| entrypoints.setup({ | |
| plugin: { | |
| create(plugin) { | |
| /*optional */ console.log("created", plugin); | |
| }, | |
| destroy() { | |
| /*optional */ console.log("destroyed"); | |
| }, | |
| }, | |
| panels: { | |
| unsplashController: unsplashController, | |
| }, | |
| }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment