@buoy-gg/route-events 7.0.41 → 7.0.43
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 +11 -64
- package/lib/commonjs/RouteObserver.js +1 -54
- package/lib/commonjs/RouteParser.js +1 -314
- package/lib/commonjs/RouteTracker.js +1 -112
- package/lib/commonjs/RouteTracker.web.js +1 -12
- package/lib/commonjs/browserRouteRegistry.js +1 -30
- package/lib/commonjs/browserRoutes.js +1 -96
- package/lib/commonjs/components/NavigationStack.js +2 -572
- package/lib/commonjs/components/ReactNavigationRoutes.js +1 -836
- package/lib/commonjs/components/ReactNavigationRoutes.web.js +1 -12
- package/lib/commonjs/components/RouteEventDetail.js +1 -97
- package/lib/commonjs/components/RouteEventExpandedContent.js +1 -204
- package/lib/commonjs/components/RouteEventItemCompact.js +1 -191
- package/lib/commonjs/components/RouteEventsModalWithTabs.js +1 -734
- package/lib/commonjs/components/RouteEventsTimeline.js +1 -107
- package/lib/commonjs/components/RouteFilterViewV2.js +1 -42
- package/lib/commonjs/components/RoutesSitemap.js +2 -1035
- package/lib/commonjs/expoRouterStore.js +1 -121
- package/lib/commonjs/expoRouterStore.web.js +1 -44
- package/lib/commonjs/hooks/useRouteEvents.js +1 -57
- package/lib/commonjs/index.js +1 -168
- package/lib/commonjs/preset.js +1 -69
- package/lib/commonjs/stores/navigationStackStore.js +1 -45
- package/lib/commonjs/stores/routeEventStore.js +1 -136
- package/lib/commonjs/sync/routeEventsSyncAdapter.js +1 -275
- package/lib/commonjs/useNavigationStack.js +1 -408
- package/lib/commonjs/useNavigationStack.web.js +1 -32
- package/lib/commonjs/useRouteObserver.js +1 -73
- package/lib/commonjs/useRouteObserverReactNavigation.js +1 -109
- package/lib/commonjs/useRouteSitemap.js +1 -255
- package/lib/commonjs/utils/routeTemplate.js +1 -79
- package/lib/commonjs/utils/safeReactNavigation.js +1 -194
- package/lib/commonjs/utils/safeReactNavigation.web.js +1 -36
- package/lib/commonjs/utils/testIDs.js +1 -63
- package/lib/module/RouteObserver.js +1 -49
- package/lib/module/RouteParser.js +1 -309
- package/lib/module/RouteTracker.js +1 -109
- package/lib/module/RouteTracker.web.js +1 -8
- package/lib/module/browserRouteRegistry.js +1 -24
- package/lib/module/browserRoutes.js +1 -92
- package/lib/module/components/NavigationStack.js +2 -568
- package/lib/module/components/ReactNavigationRoutes.js +1 -832
- package/lib/module/components/ReactNavigationRoutes.web.js +1 -3
- package/lib/module/components/RouteEventDetail.js +1 -93
- package/lib/module/components/RouteEventExpandedContent.js +1 -200
- package/lib/module/components/RouteEventItemCompact.js +1 -187
- package/lib/module/components/RouteEventsModalWithTabs.js +1 -731
- package/lib/module/components/RouteEventsTimeline.js +1 -103
- package/lib/module/components/RouteFilterViewV2.js +1 -38
- package/lib/module/components/RoutesSitemap.js +2 -1033
- package/lib/module/expoRouterStore.js +1 -114
- package/lib/module/expoRouterStore.web.js +1 -37
- package/lib/module/hooks/useRouteEvents.js +1 -54
- package/lib/module/index.js +1 -70
- package/lib/module/preset.js +1 -66
- package/lib/module/stores/navigationStackStore.js +1 -41
- package/lib/module/stores/routeEventStore.js +1 -128
- package/lib/module/sync/routeEventsSyncAdapter.js +1 -273
- package/lib/module/useNavigationStack.js +1 -404
- package/lib/module/useNavigationStack.web.js +1 -28
- package/lib/module/useRouteObserver.js +1 -70
- package/lib/module/useRouteObserverReactNavigation.js +1 -106
- package/lib/module/useRouteSitemap.js +1 -250
- package/lib/module/utils/routeTemplate.js +1 -73
- package/lib/module/utils/safeReactNavigation.js +1 -185
- package/lib/module/utils/safeReactNavigation.web.js +1 -27
- package/lib/module/utils/testIDs.js +1 -55
- package/lib/web/index.mjs +4 -5
- package/package.json +6 -11
- package/lib/typescript/RouteObserver.d.ts.map +0 -1
- package/lib/typescript/RouteParser.d.ts.map +0 -1
- package/lib/typescript/RouteTracker.d.ts.map +0 -1
- package/lib/typescript/RouteTracker.web.d.ts.map +0 -1
- package/lib/typescript/browserRouteRegistry.d.ts.map +0 -1
- package/lib/typescript/browserRoutes.d.ts.map +0 -1
- package/lib/typescript/components/NavigationStack.d.ts.map +0 -1
- package/lib/typescript/components/ReactNavigationRoutes.d.ts.map +0 -1
- package/lib/typescript/components/ReactNavigationRoutes.web.d.ts.map +0 -1
- package/lib/typescript/components/RouteEventDetail.d.ts.map +0 -1
- package/lib/typescript/components/RouteEventExpandedContent.d.ts.map +0 -1
- package/lib/typescript/components/RouteEventItemCompact.d.ts.map +0 -1
- package/lib/typescript/components/RouteEventsModalWithTabs.d.ts.map +0 -1
- package/lib/typescript/components/RouteEventsTimeline.d.ts.map +0 -1
- package/lib/typescript/components/RouteFilterViewV2.d.ts.map +0 -1
- package/lib/typescript/components/RoutesSitemap.d.ts.map +0 -1
- package/lib/typescript/expoRouterStore.d.ts.map +0 -1
- package/lib/typescript/expoRouterStore.web.d.ts.map +0 -1
- package/lib/typescript/hooks/useRouteEvents.d.ts.map +0 -1
- package/lib/typescript/index.d.ts.map +0 -1
- package/lib/typescript/preset.d.ts.map +0 -1
- package/lib/typescript/stores/navigationStackStore.d.ts.map +0 -1
- package/lib/typescript/stores/routeEventStore.d.ts.map +0 -1
- package/lib/typescript/sync/routeEventsSyncAdapter.d.ts.map +0 -1
- package/lib/typescript/useNavigationStack.d.ts.map +0 -1
- package/lib/typescript/useNavigationStack.web.d.ts.map +0 -1
- package/lib/typescript/useRouteObserver.d.ts.map +0 -1
- package/lib/typescript/useRouteObserverReactNavigation.d.ts.map +0 -1
- package/lib/typescript/useRouteSitemap.d.ts.map +0 -1
- package/lib/typescript/utils/routeTemplate.d.ts.map +0 -1
- package/lib/typescript/utils/safeReactNavigation.d.ts.map +0 -1
- package/lib/typescript/utils/safeReactNavigation.web.d.ts.map +0 -1
- package/lib/typescript/utils/testIDs.d.ts.map +0 -1
|
@@ -1,107 +1 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.RouteEventsTimeline = RouteEventsTimeline;
|
|
7
|
-
var _react = require("react");
|
|
8
|
-
var _reactNative = require("react-native");
|
|
9
|
-
var _sharedUi = require("@buoy-gg/shared-ui");
|
|
10
|
-
var _RouteEventItemCompact = require("./RouteEventItemCompact");
|
|
11
|
-
var _jsxRuntime = require("react/jsx-runtime");
|
|
12
|
-
/**
|
|
13
|
-
* RouteEventsTimeline - Chronological timeline of route navigation events
|
|
14
|
-
*
|
|
15
|
-
* Shows events in the order they happened (most recent first),
|
|
16
|
-
* providing a clear history of navigation actions.
|
|
17
|
-
*
|
|
18
|
-
* Tapping a row opens the full-screen detail view (parity with the Events
|
|
19
|
-
* tool) via onSelectEvent — rows no longer expand inline.
|
|
20
|
-
*/
|
|
21
|
-
|
|
22
|
-
function RouteEventsTimeline({
|
|
23
|
-
events,
|
|
24
|
-
visitCounts,
|
|
25
|
-
onNavigate,
|
|
26
|
-
onSelectEvent
|
|
27
|
-
}) {
|
|
28
|
-
const handleItemPress = (0, _react.useCallback)(index => {
|
|
29
|
-
const event = events[index];
|
|
30
|
-
if (!event) return;
|
|
31
|
-
onSelectEvent(event, visitCounts.get(event) || 1);
|
|
32
|
-
}, [events, visitCounts, onSelectEvent]);
|
|
33
|
-
if (events.length === 0) {
|
|
34
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
|
|
35
|
-
style: styles.emptyState,
|
|
36
|
-
testID: "buoy-routes-empty",
|
|
37
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Navigation, {
|
|
38
|
-
size: 48,
|
|
39
|
-
color: _sharedUi.night.color.textTertiary
|
|
40
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
|
41
|
-
style: styles.emptyTitle,
|
|
42
|
-
testID: "buoy-routes-empty-title",
|
|
43
|
-
children: "No events yet"
|
|
44
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
|
45
|
-
style: styles.emptySubtitle,
|
|
46
|
-
testID: "buoy-routes-empty-subtitle",
|
|
47
|
-
children: "Navigation events will appear here"
|
|
48
|
-
})]
|
|
49
|
-
});
|
|
50
|
-
}
|
|
51
|
-
return (
|
|
52
|
-
/*#__PURE__*/
|
|
53
|
-
// Virtualized — the previous ScrollView + map mounted ALL events (at
|
|
54
|
-
// the 500-event cap that measured 32.8 JS FPS during an idle dwell,
|
|
55
|
-
// tool-bench 2026-07-06).
|
|
56
|
-
(0, _jsxRuntime.jsx)(_reactNative.FlatList, {
|
|
57
|
-
testID: "buoy-routes-timeline",
|
|
58
|
-
contentContainerStyle: styles.listContent,
|
|
59
|
-
data: events
|
|
60
|
-
// STABLE content keys — index-based keys remount every row when a new
|
|
61
|
-
// event prepends (measured 4 JS FPS during automation, which emits
|
|
62
|
-
// route events on every bounce; tool-bench 2026-07-06).
|
|
63
|
-
,
|
|
64
|
-
keyExtractor: event => `${event.timestamp}-${event.pathname}`,
|
|
65
|
-
renderItem: ({
|
|
66
|
-
item: event,
|
|
67
|
-
index
|
|
68
|
-
}) => /*#__PURE__*/(0, _jsxRuntime.jsx)(_RouteEventItemCompact.RouteEventItemCompact, {
|
|
69
|
-
event: event,
|
|
70
|
-
visitNumber: visitCounts.get(event) || 1,
|
|
71
|
-
isExpanded: false,
|
|
72
|
-
index: index,
|
|
73
|
-
onPress: handleItemPress,
|
|
74
|
-
onNavigate: onNavigate
|
|
75
|
-
}),
|
|
76
|
-
showsVerticalScrollIndicator: true,
|
|
77
|
-
..._sharedUi.EVENT_LIST_PRESET
|
|
78
|
-
})
|
|
79
|
-
);
|
|
80
|
-
}
|
|
81
|
-
const styles = _reactNative.StyleSheet.create({
|
|
82
|
-
listContent: {
|
|
83
|
-
paddingVertical: 8
|
|
84
|
-
},
|
|
85
|
-
emptyState: {
|
|
86
|
-
flex: 1,
|
|
87
|
-
justifyContent: "center",
|
|
88
|
-
alignItems: "center",
|
|
89
|
-
padding: 32
|
|
90
|
-
},
|
|
91
|
-
emptyTitle: {
|
|
92
|
-
color: _sharedUi.night.color.text,
|
|
93
|
-
fontSize: 16,
|
|
94
|
-
fontWeight: "600",
|
|
95
|
-
marginTop: 16,
|
|
96
|
-
marginBottom: 8,
|
|
97
|
-
fontFamily: _sharedUi.monoFont,
|
|
98
|
-
letterSpacing: 0.5,
|
|
99
|
-
textTransform: "uppercase"
|
|
100
|
-
},
|
|
101
|
-
emptySubtitle: {
|
|
102
|
-
color: _sharedUi.night.color.textSecondary,
|
|
103
|
-
fontSize: 14,
|
|
104
|
-
textAlign: "center",
|
|
105
|
-
fontFamily: _sharedUi.monoFont
|
|
106
|
-
}
|
|
107
|
-
});
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.RouteEventsTimeline=RouteEventsTimeline;var _react=require("react");var _reactNative=require("react-native");var _sharedUi=require("@buoy-gg/shared-ui");var _RouteEventItemCompact=require("./RouteEventItemCompact");var _jsxRuntime=require("react/jsx-runtime");function RouteEventsTimeline({events:r,visitCounts:i,onNavigate:n,onSelectEvent:o}){const a=(0,_react.useCallback)(e=>{const t=r[e];if(!t)return;o(t,i.get(t)||1)},[r,i,o]);if(r.length===0){return(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.emptyState,testID:"buoy-routes-empty",children:[(0,_jsxRuntime.jsx)(_sharedUi.Navigation,{size:48,color:_sharedUi.night.color.textTertiary}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.emptyTitle,testID:"buoy-routes-empty-title",children:"No events yet"}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.emptySubtitle,testID:"buoy-routes-empty-subtitle",children:"Navigation events will appear here"})]})}return(0,_jsxRuntime.jsx)(_reactNative.FlatList,{testID:"buoy-routes-timeline",contentContainerStyle:styles.listContent,data:r,keyExtractor:e=>`${e.timestamp}-${e.pathname}`,renderItem:({item:e,index:t})=>(0,_jsxRuntime.jsx)(_RouteEventItemCompact.RouteEventItemCompact,{event:e,visitNumber:i.get(e)||1,isExpanded:false,index:t,onPress:a,onNavigate:n}),showsVerticalScrollIndicator:true,..._sharedUi.EVENT_LIST_PRESET})}const styles=_reactNative.StyleSheet.create({listContent:{paddingVertical:8},emptyState:{flex:1,justifyContent:"center",alignItems:"center",padding:32},emptyTitle:{color:_sharedUi.night.color.text,fontSize:16,fontWeight:"600",marginTop:16,marginBottom:8,fontFamily:_sharedUi.monoFont,letterSpacing:.5,textTransform:"uppercase"},emptySubtitle:{color:_sharedUi.night.color.textSecondary,fontSize:14,textAlign:"center",fontFamily:_sharedUi.monoFont}});
|
|
@@ -1,42 +1 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.RouteFilterViewV2 = RouteFilterViewV2;
|
|
7
|
-
var _sharedUi = require("@buoy-gg/shared-ui");
|
|
8
|
-
var _jsxRuntime = require("react/jsx-runtime");
|
|
9
|
-
function RouteFilterViewV2({
|
|
10
|
-
ignoredPatterns,
|
|
11
|
-
onTogglePattern,
|
|
12
|
-
onAddPattern,
|
|
13
|
-
availablePathnames = []
|
|
14
|
-
}) {
|
|
15
|
-
const filterConfig = {
|
|
16
|
-
addFilterSection: {
|
|
17
|
-
enabled: true,
|
|
18
|
-
placeholder: "Enter pattern (e.g., /_sitemap)",
|
|
19
|
-
title: "ACTIVE FILTERS",
|
|
20
|
-
icon: _sharedUi.Filter
|
|
21
|
-
},
|
|
22
|
-
availableItemsSection: {
|
|
23
|
-
enabled: true,
|
|
24
|
-
title: "AVAILABLE ROUTES FROM EVENTS",
|
|
25
|
-
emptyMessage: "No routes available. Routes from navigation events will appear here.",
|
|
26
|
-
items: availablePathnames
|
|
27
|
-
},
|
|
28
|
-
howItWorksSection: {
|
|
29
|
-
enabled: true,
|
|
30
|
-
title: "HOW FILTERS WORK",
|
|
31
|
-
description: "Filtered routes will not appear in the route events list. Patterns match if the route contains the specified text.",
|
|
32
|
-
examples: ["• /_sitemap → filters /_sitemap routes", "• /api → filters /api/users, /api/posts", "• [id] → filters all routes with [id] param"],
|
|
33
|
-
icon: _sharedUi.Filter
|
|
34
|
-
},
|
|
35
|
-
onPatternToggle: onTogglePattern,
|
|
36
|
-
onPatternAdd: onAddPattern,
|
|
37
|
-
activePatterns: ignoredPatterns
|
|
38
|
-
};
|
|
39
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.DynamicFilterView, {
|
|
40
|
-
...filterConfig
|
|
41
|
-
});
|
|
42
|
-
}
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.RouteFilterViewV2=RouteFilterViewV2;var _sharedUi=require("@buoy-gg/shared-ui");var _jsxRuntime=require("react/jsx-runtime");function RouteFilterViewV2({ignoredPatterns:e,onTogglePattern:t,onAddPattern:i,availablePathnames:r=[]}){const a={addFilterSection:{enabled:true,placeholder:"Enter pattern (e.g., /_sitemap)",title:"ACTIVE FILTERS",icon:_sharedUi.Filter},availableItemsSection:{enabled:true,title:"AVAILABLE ROUTES FROM EVENTS",emptyMessage:"No routes available. Routes from navigation events will appear here.",items:r},howItWorksSection:{enabled:true,title:"HOW FILTERS WORK",description:"Filtered routes will not appear in the route events list. Patterns match if the route contains the specified text.",examples:["\u2022 /_sitemap \u2192 filters /_sitemap routes","\u2022 /api \u2192 filters /api/users, /api/posts","\u2022 [id] \u2192 filters all routes with [id] param"],icon:_sharedUi.Filter},onPatternToggle:t,onPatternAdd:i,activePatterns:e};return(0,_jsxRuntime.jsx)(_sharedUi.DynamicFilterView,{...a})}
|