react-grab 0.0.70 → 0.0.71
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/{chunk-UIOO5VVO.js → chunk-HJLMLJJA.js} +184 -102
- package/dist/{chunk-3OWWYY5I.cjs → chunk-RPPUX2ZU.cjs} +184 -102
- package/dist/{core-CnnkNbYQ.d.cts → core-Dm5hxkI3.d.cts} +1 -17
- package/dist/{core-CnnkNbYQ.d.ts → core-Dm5hxkI3.d.ts} +1 -17
- package/dist/core.cjs +7 -7
- package/dist/core.d.cts +1 -1
- package/dist/core.d.ts +1 -1
- package/dist/core.js +1 -1
- package/dist/index.cjs +8 -8
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.global.js +26 -26
- package/dist/index.js +2 -2
- package/dist/styles.css +1 -1
- package/package.json +1 -1
|
@@ -55,16 +55,6 @@ interface Theme {
|
|
|
55
55
|
*/
|
|
56
56
|
enabled?: boolean;
|
|
57
57
|
};
|
|
58
|
-
/**
|
|
59
|
-
* Text labels that appear after successful operations (like "Copied!" messages)
|
|
60
|
-
*/
|
|
61
|
-
successLabels?: {
|
|
62
|
-
/**
|
|
63
|
-
* Whether to show success feedback labels
|
|
64
|
-
* @default true
|
|
65
|
-
*/
|
|
66
|
-
enabled?: boolean;
|
|
67
|
-
};
|
|
68
58
|
/**
|
|
69
59
|
* The crosshair cursor overlay that helps with precise element targeting
|
|
70
60
|
*/
|
|
@@ -84,17 +74,12 @@ interface ReactGrabState {
|
|
|
84
74
|
targetElement: Element | null;
|
|
85
75
|
dragBounds: DragRect | null;
|
|
86
76
|
}
|
|
87
|
-
type SuccessLabelType = "copy" | "input-submit";
|
|
88
77
|
type ElementLabelVariant = "hover" | "processing" | "success";
|
|
89
78
|
interface InputModeContext {
|
|
90
79
|
x: number;
|
|
91
80
|
y: number;
|
|
92
81
|
targetElement: Element | null;
|
|
93
82
|
}
|
|
94
|
-
interface SuccessLabelContext {
|
|
95
|
-
x: number;
|
|
96
|
-
y: number;
|
|
97
|
-
}
|
|
98
83
|
interface CrosshairContext {
|
|
99
84
|
x: number;
|
|
100
85
|
y: number;
|
|
@@ -171,7 +156,6 @@ interface Options {
|
|
|
171
156
|
onCopyError?: (error: Error) => void;
|
|
172
157
|
onStateChange?: (state: ReactGrabState) => void;
|
|
173
158
|
onInputModeChange?: (isInputMode: boolean, context: InputModeContext) => void;
|
|
174
|
-
onSuccessLabel?: (text: string, type: SuccessLabelType, context: SuccessLabelContext) => void;
|
|
175
159
|
onSelectionBox?: (visible: boolean, bounds: OverlayBounds | null, element: Element | null) => void;
|
|
176
160
|
onDragBox?: (visible: boolean, bounds: OverlayBounds | null) => void;
|
|
177
161
|
onGrabbedBox?: (bounds: OverlayBounds, element: Element) => void;
|
|
@@ -285,4 +269,4 @@ declare const generateSnippet: (elements: Element[], options?: GenerateSnippetOp
|
|
|
285
269
|
|
|
286
270
|
declare const init: (rawOptions?: Options) => ReactGrabAPI;
|
|
287
271
|
|
|
288
|
-
export { type AgentContext as A, type CrosshairContext as C, DEFAULT_THEME as D, type ElementLabelVariant as E, type GrabbedBox as G, type InputModeContext as I, type Options as O, type ReactGrabAPI as R, type
|
|
272
|
+
export { type AgentContext as A, type CrosshairContext as C, DEFAULT_THEME as D, type ElementLabelVariant as E, type GrabbedBox as G, type InputModeContext as I, type Options as O, type ReactGrabAPI as R, type Theme as T, getElementContext as a, generateSnippet as b, type ReactGrabState as c, type OverlayBounds as d, type DragRect as e, type Rect as f, getStack as g, type DeepPartial as h, init as i, type ElementLabelContext as j, type AgentSession as k, type AgentProvider as l, type AgentSessionStorage as m, type AgentOptions as n, type ReactGrabRendererProps as o };
|
|
@@ -55,16 +55,6 @@ interface Theme {
|
|
|
55
55
|
*/
|
|
56
56
|
enabled?: boolean;
|
|
57
57
|
};
|
|
58
|
-
/**
|
|
59
|
-
* Text labels that appear after successful operations (like "Copied!" messages)
|
|
60
|
-
*/
|
|
61
|
-
successLabels?: {
|
|
62
|
-
/**
|
|
63
|
-
* Whether to show success feedback labels
|
|
64
|
-
* @default true
|
|
65
|
-
*/
|
|
66
|
-
enabled?: boolean;
|
|
67
|
-
};
|
|
68
58
|
/**
|
|
69
59
|
* The crosshair cursor overlay that helps with precise element targeting
|
|
70
60
|
*/
|
|
@@ -84,17 +74,12 @@ interface ReactGrabState {
|
|
|
84
74
|
targetElement: Element | null;
|
|
85
75
|
dragBounds: DragRect | null;
|
|
86
76
|
}
|
|
87
|
-
type SuccessLabelType = "copy" | "input-submit";
|
|
88
77
|
type ElementLabelVariant = "hover" | "processing" | "success";
|
|
89
78
|
interface InputModeContext {
|
|
90
79
|
x: number;
|
|
91
80
|
y: number;
|
|
92
81
|
targetElement: Element | null;
|
|
93
82
|
}
|
|
94
|
-
interface SuccessLabelContext {
|
|
95
|
-
x: number;
|
|
96
|
-
y: number;
|
|
97
|
-
}
|
|
98
83
|
interface CrosshairContext {
|
|
99
84
|
x: number;
|
|
100
85
|
y: number;
|
|
@@ -171,7 +156,6 @@ interface Options {
|
|
|
171
156
|
onCopyError?: (error: Error) => void;
|
|
172
157
|
onStateChange?: (state: ReactGrabState) => void;
|
|
173
158
|
onInputModeChange?: (isInputMode: boolean, context: InputModeContext) => void;
|
|
174
|
-
onSuccessLabel?: (text: string, type: SuccessLabelType, context: SuccessLabelContext) => void;
|
|
175
159
|
onSelectionBox?: (visible: boolean, bounds: OverlayBounds | null, element: Element | null) => void;
|
|
176
160
|
onDragBox?: (visible: boolean, bounds: OverlayBounds | null) => void;
|
|
177
161
|
onGrabbedBox?: (bounds: OverlayBounds, element: Element) => void;
|
|
@@ -285,4 +269,4 @@ declare const generateSnippet: (elements: Element[], options?: GenerateSnippetOp
|
|
|
285
269
|
|
|
286
270
|
declare const init: (rawOptions?: Options) => ReactGrabAPI;
|
|
287
271
|
|
|
288
|
-
export { type AgentContext as A, type CrosshairContext as C, DEFAULT_THEME as D, type ElementLabelVariant as E, type GrabbedBox as G, type InputModeContext as I, type Options as O, type ReactGrabAPI as R, type
|
|
272
|
+
export { type AgentContext as A, type CrosshairContext as C, DEFAULT_THEME as D, type ElementLabelVariant as E, type GrabbedBox as G, type InputModeContext as I, type Options as O, type ReactGrabAPI as R, type Theme as T, getElementContext as a, generateSnippet as b, type ReactGrabState as c, type OverlayBounds as d, type DragRect as e, type Rect as f, getStack as g, type DeepPartial as h, init as i, type ElementLabelContext as j, type AgentSession as k, type AgentProvider as l, type AgentSessionStorage as m, type AgentOptions as n, type ReactGrabRendererProps as o };
|
package/dist/core.cjs
CHANGED
|
@@ -1,30 +1,30 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkRPPUX2ZU_cjs = require('./chunk-RPPUX2ZU.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
Object.defineProperty(exports, "DEFAULT_THEME", {
|
|
8
8
|
enumerable: true,
|
|
9
|
-
get: function () { return
|
|
9
|
+
get: function () { return chunkRPPUX2ZU_cjs.DEFAULT_THEME; }
|
|
10
10
|
});
|
|
11
11
|
Object.defineProperty(exports, "formatElementInfo", {
|
|
12
12
|
enumerable: true,
|
|
13
|
-
get: function () { return
|
|
13
|
+
get: function () { return chunkRPPUX2ZU_cjs.getElementContext; }
|
|
14
14
|
});
|
|
15
15
|
Object.defineProperty(exports, "generateSnippet", {
|
|
16
16
|
enumerable: true,
|
|
17
|
-
get: function () { return
|
|
17
|
+
get: function () { return chunkRPPUX2ZU_cjs.generateSnippet; }
|
|
18
18
|
});
|
|
19
19
|
Object.defineProperty(exports, "getStack", {
|
|
20
20
|
enumerable: true,
|
|
21
|
-
get: function () { return
|
|
21
|
+
get: function () { return chunkRPPUX2ZU_cjs.getStack; }
|
|
22
22
|
});
|
|
23
23
|
Object.defineProperty(exports, "init", {
|
|
24
24
|
enumerable: true,
|
|
25
|
-
get: function () { return
|
|
25
|
+
get: function () { return chunkRPPUX2ZU_cjs.init; }
|
|
26
26
|
});
|
|
27
27
|
Object.defineProperty(exports, "isInstrumentationActive", {
|
|
28
28
|
enumerable: true,
|
|
29
|
-
get: function () { return
|
|
29
|
+
get: function () { return chunkRPPUX2ZU_cjs.Ee; }
|
|
30
30
|
});
|
package/dist/core.d.cts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { A as AgentContext,
|
|
1
|
+
export { A as AgentContext, l as AgentProvider, k as AgentSession, m as AgentSessionStorage, D as DEFAULT_THEME, O as Options, d as OverlayBounds, R as ReactGrabAPI, o as ReactGrabRendererProps, a as formatElementInfo, b as generateSnippet, g as getStack, i as init } from './core-Dm5hxkI3.cjs';
|
|
2
2
|
export { isInstrumentationActive } from 'bippy';
|
|
3
3
|
import 'bippy/source';
|
package/dist/core.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { A as AgentContext,
|
|
1
|
+
export { A as AgentContext, l as AgentProvider, k as AgentSession, m as AgentSessionStorage, D as DEFAULT_THEME, O as Options, d as OverlayBounds, R as ReactGrabAPI, o as ReactGrabRendererProps, a as formatElementInfo, b as generateSnippet, g as getStack, i as init } from './core-Dm5hxkI3.js';
|
|
2
2
|
export { isInstrumentationActive } from 'bippy';
|
|
3
3
|
import 'bippy/source';
|
package/dist/core.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { DEFAULT_THEME, getElementContext as formatElementInfo, generateSnippet, getStack, init, Ee as isInstrumentationActive } from './chunk-
|
|
1
|
+
export { DEFAULT_THEME, getElementContext as formatElementInfo, generateSnippet, getStack, init, Ee as isInstrumentationActive } from './chunk-HJLMLJJA.js';
|
package/dist/index.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkRPPUX2ZU_cjs = require('./chunk-RPPUX2ZU.cjs');
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* @license MIT
|
|
@@ -31,7 +31,7 @@ if (typeof window !== "undefined") {
|
|
|
31
31
|
if (window.__REACT_GRAB__) {
|
|
32
32
|
globalApi = window.__REACT_GRAB__;
|
|
33
33
|
} else {
|
|
34
|
-
globalApi =
|
|
34
|
+
globalApi = chunkRPPUX2ZU_cjs.init();
|
|
35
35
|
window.__REACT_GRAB__ = globalApi;
|
|
36
36
|
window.dispatchEvent(
|
|
37
37
|
new CustomEvent("react-grab:init", { detail: globalApi })
|
|
@@ -41,27 +41,27 @@ if (typeof window !== "undefined") {
|
|
|
41
41
|
|
|
42
42
|
Object.defineProperty(exports, "DEFAULT_THEME", {
|
|
43
43
|
enumerable: true,
|
|
44
|
-
get: function () { return
|
|
44
|
+
get: function () { return chunkRPPUX2ZU_cjs.DEFAULT_THEME; }
|
|
45
45
|
});
|
|
46
46
|
Object.defineProperty(exports, "formatElementInfo", {
|
|
47
47
|
enumerable: true,
|
|
48
|
-
get: function () { return
|
|
48
|
+
get: function () { return chunkRPPUX2ZU_cjs.getElementContext; }
|
|
49
49
|
});
|
|
50
50
|
Object.defineProperty(exports, "generateSnippet", {
|
|
51
51
|
enumerable: true,
|
|
52
|
-
get: function () { return
|
|
52
|
+
get: function () { return chunkRPPUX2ZU_cjs.generateSnippet; }
|
|
53
53
|
});
|
|
54
54
|
Object.defineProperty(exports, "getStack", {
|
|
55
55
|
enumerable: true,
|
|
56
|
-
get: function () { return
|
|
56
|
+
get: function () { return chunkRPPUX2ZU_cjs.getStack; }
|
|
57
57
|
});
|
|
58
58
|
Object.defineProperty(exports, "init", {
|
|
59
59
|
enumerable: true,
|
|
60
|
-
get: function () { return
|
|
60
|
+
get: function () { return chunkRPPUX2ZU_cjs.init; }
|
|
61
61
|
});
|
|
62
62
|
Object.defineProperty(exports, "isInstrumentationActive", {
|
|
63
63
|
enumerable: true,
|
|
64
|
-
get: function () { return
|
|
64
|
+
get: function () { return chunkRPPUX2ZU_cjs.Ee; }
|
|
65
65
|
});
|
|
66
66
|
exports.getGlobalApi = getGlobalApi;
|
|
67
67
|
exports.setGlobalApi = setGlobalApi;
|
package/dist/index.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { R as ReactGrabAPI } from './core-
|
|
2
|
-
export { A as AgentContext,
|
|
1
|
+
import { R as ReactGrabAPI } from './core-Dm5hxkI3.cjs';
|
|
2
|
+
export { A as AgentContext, n as AgentOptions, l as AgentProvider, k as AgentSession, m as AgentSessionStorage, C as CrosshairContext, D as DEFAULT_THEME, h as DeepPartial, e as DragRect, j as ElementLabelContext, E as ElementLabelVariant, G as GrabbedBox, I as InputModeContext, O as Options, d as OverlayBounds, c as ReactGrabState, f as Rect, T as Theme, a as formatElementInfo, b as generateSnippet, g as getStack, i as init } from './core-Dm5hxkI3.cjs';
|
|
3
3
|
export { isInstrumentationActive } from 'bippy';
|
|
4
4
|
import 'bippy/source';
|
|
5
5
|
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { R as ReactGrabAPI } from './core-
|
|
2
|
-
export { A as AgentContext,
|
|
1
|
+
import { R as ReactGrabAPI } from './core-Dm5hxkI3.js';
|
|
2
|
+
export { A as AgentContext, n as AgentOptions, l as AgentProvider, k as AgentSession, m as AgentSessionStorage, C as CrosshairContext, D as DEFAULT_THEME, h as DeepPartial, e as DragRect, j as ElementLabelContext, E as ElementLabelVariant, G as GrabbedBox, I as InputModeContext, O as Options, d as OverlayBounds, c as ReactGrabState, f as Rect, T as Theme, a as formatElementInfo, b as generateSnippet, g as getStack, i as init } from './core-Dm5hxkI3.js';
|
|
3
3
|
export { isInstrumentationActive } from 'bippy';
|
|
4
4
|
import 'bippy/source';
|
|
5
5
|
|