@autono/pinbox-toolbar 0.1.0
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/README.md +44 -0
- package/dist/index-ZR3JBQu-.d.ts +206 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +2 -0
- package/dist/options-CNqXqkp9.d.ts +14 -0
- package/dist/options-DSrJgbJh.js +169 -0
- package/dist/plugins/next.d.ts +31 -0
- package/dist/plugins/next.js +31 -0
- package/dist/plugins/vite.d.ts +11 -0
- package/dist/plugins/vite.js +98 -0
- package/dist/react.d.ts +11 -0
- package/dist/react.js +28 -0
- package/dist/src-BoLg81_j.js +1992 -0
- package/dist/svelte.d.ts +11 -0
- package/dist/svelte.js +18 -0
- package/dist/toolbar.iife.js +2002 -0
- package/dist/vue.d.ts +39 -0
- package/dist/vue.js +48 -0
- package/package.json +84 -0
package/dist/svelte.d.ts
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { _ as applyHubEvent, a as HubEvent, b as upsertPin, c as WebSocketLike, d as PinboxToolbarElement, f as Draft, g as appendThreadMessage, h as UiStatus, i as ConnectionState, l as HubError, m as ToolbarState, n as PinboxConfig, o as HubTransport, p as Store, r as defineToolbarElement, s as TransportOptions, t as Pinbox, u as StorageLike, v as createStore, x as CaptureResult, y as deriveUiStatus } from "./index-ZR3JBQu-.js";
|
|
2
|
+
import { Action } from "svelte/action";
|
|
3
|
+
//#region src/svelte.d.ts
|
|
4
|
+
/**
|
|
5
|
+
* `<div use:pinbox={{ endpoint }} />` — creates + configures the element BEFORE insertion
|
|
6
|
+
* (its transport starts in connectedCallback) and removes it when the node is destroyed.
|
|
7
|
+
* Config forwards once; re-create the node to change endpoints.
|
|
8
|
+
*/
|
|
9
|
+
declare const pinbox: Action<HTMLElement, PinboxConfig>;
|
|
10
|
+
//#endregion
|
|
11
|
+
export { type CaptureResult, type ConnectionState, type Draft, HubError, type HubEvent, HubTransport, Pinbox, PinboxConfig, PinboxToolbarElement, type StorageLike, type Store, type ToolbarState, type TransportOptions, type UiStatus, type WebSocketLike, appendThreadMessage, applyHubEvent, createStore, defineToolbarElement, deriveUiStatus, pinbox, upsertPin };
|
package/dist/svelte.js
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { a as HubError, c as createStore, i as HubTransport, l as deriveUiStatus, n as defineToolbarElement, o as appendThreadMessage, r as PinboxToolbarElement, s as applyHubEvent, t as Pinbox, u as upsertPin } from "./src-BoLg81_j.js";
|
|
2
|
+
//#region src/svelte.ts
|
|
3
|
+
/**
|
|
4
|
+
* `<div use:pinbox={{ endpoint }} />` — creates + configures the element BEFORE insertion
|
|
5
|
+
* (its transport starts in connectedCallback) and removes it when the node is destroyed.
|
|
6
|
+
* Config forwards once; re-create the node to change endpoints.
|
|
7
|
+
*/
|
|
8
|
+
const pinbox = (node, config) => {
|
|
9
|
+
defineToolbarElement();
|
|
10
|
+
const el = document.createElement(PinboxToolbarElement.tagName);
|
|
11
|
+
el.configure(config);
|
|
12
|
+
node.appendChild(el);
|
|
13
|
+
return { destroy: () => {
|
|
14
|
+
el.remove();
|
|
15
|
+
} };
|
|
16
|
+
};
|
|
17
|
+
//#endregion
|
|
18
|
+
export { HubError, HubTransport, Pinbox, PinboxToolbarElement, appendThreadMessage, applyHubEvent, createStore, defineToolbarElement, deriveUiStatus, pinbox, upsertPin };
|