Rocky_Mountain_Vending/.pnpm-store/v10/files/b0/62e7b5edafc48e08164b070045aec20193511c70f0462e4d30621e522b93da3274a0f643dba7f5c16becb3690635e694872880d2471ae208ab5063d4ffb096
DMleadgen 46d973904b
Initial commit: Rocky Mountain Vending website
Next.js website for Rocky Mountain Vending company featuring:
- Product catalog with Stripe integration
- Service areas and parts pages
- Admin dashboard with Clerk authentication
- SEO optimized pages with JSON-LD structured data

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-12 16:22:15 -07:00

43 lines
No EOL
1.3 KiB
Text

// Copyright 2024 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
import * as Types from '../types/types.js';
const frames = new Map();
export function reset() {
frames.clear();
}
export function handleEvent(event) {
if (Types.Events.isTracingStartedInBrowser(event)) {
for (const frame of event.args.data?.frames ?? []) {
// The ID of a frame is stored under the `frame` key.
frames.set(frame.frame, frame);
}
return;
}
// CommitLoad events can contain an updated URL or Name for a frame.
if (Types.Events.isCommitLoad(event)) {
const frameData = event.args.data;
if (!frameData) {
return;
}
// We don't want to mutate the original object, hence why
// we set a new object from the new and existing values.
const frame = frames.get(frameData.frame);
if (!frame) {
return;
}
frames.set(frameData.frame, {
...frame,
url: frameData.url || frame.url,
name: frameData.name || frameData.name,
});
}
}
export async function finalize() {
}
export function data() {
return {
frames,
};
}
//# sourceMappingURL=PageFramesHandler.js.map