@oyerinde/caliper 0.1.4 → 0.2.1

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/bridge.js ADDED
@@ -0,0 +1 @@
1
+ export { CALIPER_METHODS, CaliperActionResultSchema, CaliperAgentStateSchema, CaliperBridge, CaliperGetContextPayloadSchema, CaliperInspectPayloadSchema, CaliperMeasurePayloadSchema, CaliperSelectPayloadSchema, CaliperWalkAndMeasurePayloadSchema, CaliperWalkDomPayloadSchema, dispatchCaliperIntent } from './chunk-L47FGEH6.js';
@@ -0,0 +1,34 @@
1
+ 'use strict';
2
+
3
+ /**
4
+ * @name @oyerinde/caliper
5
+ * @author Daniel Oyerinde
6
+ * @license MIT
7
+ *
8
+ * Caliper - Browser Measurement Tool
9
+ *
10
+ * This source code is licensed under the MIT license found in the
11
+ * LICENSE file in the root directory of this source tree.
12
+ */
13
+
14
+ // ../agent-bridge/src/index.server.ts
15
+ function CaliperBridge(_config) {
16
+ return {
17
+ name: "agent-bridge-stub",
18
+ install: () => {
19
+ },
20
+ dispose: () => {
21
+ }
22
+ };
23
+ }
24
+ async function dispatchCaliperIntent(_intent) {
25
+ return {
26
+ success: false,
27
+ method: "UNKNOWN",
28
+ error: "Agent bridge is not available in SSR environment",
29
+ timestamp: Date.now()
30
+ };
31
+ }
32
+
33
+ exports.CaliperBridge = CaliperBridge;
34
+ exports.dispatchCaliperIntent = dispatchCaliperIntent;
@@ -0,0 +1,31 @@
1
+ /**
2
+ * @name @oyerinde/caliper
3
+ * @author Daniel Oyerinde
4
+ * @license MIT
5
+ *
6
+ * Caliper - Browser Measurement Tool
7
+ *
8
+ * This source code is licensed under the MIT license found in the
9
+ * LICENSE file in the root directory of this source tree.
10
+ */
11
+
12
+ // ../agent-bridge/src/index.server.ts
13
+ function CaliperBridge(_config) {
14
+ return {
15
+ name: "agent-bridge-stub",
16
+ install: () => {
17
+ },
18
+ dispose: () => {
19
+ }
20
+ };
21
+ }
22
+ async function dispatchCaliperIntent(_intent) {
23
+ return {
24
+ success: false,
25
+ method: "UNKNOWN",
26
+ error: "Agent bridge is not available in SSR environment",
27
+ timestamp: Date.now()
28
+ };
29
+ }
30
+
31
+ export { CaliperBridge, dispatchCaliperIntent };