Rocky_Mountain_Vending/.pnpm-store/v10/files/ea/54cfd089595393a39a7eabcea065a5ca949b347e47883333fb160cd2f6dabc926265c83708b703fddb426c3e8fe0d20c32c16c417e5b5eba9f5aae0c2ad71a
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

1 line
No EOL
6.1 KiB
Text

{"version":3,"file":"console-integration.js","sources":["../../../src/logs/console-integration.ts"],"sourcesContent":["import { getClient } from '../currentScopes';\nimport { DEBUG_BUILD } from '../debug-build';\nimport { addConsoleInstrumentationHandler } from '../instrument/console';\nimport { defineIntegration } from '../integration';\nimport { SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN } from '../semanticAttributes';\nimport type { ConsoleLevel } from '../types-hoist/instrument';\nimport type { IntegrationFn } from '../types-hoist/integration';\nimport { CONSOLE_LEVELS, debug } from '../utils/debug-logger';\nimport { isPrimitive } from '../utils/is';\nimport { normalize } from '../utils/normalize';\nimport { GLOBAL_OBJ } from '../utils/worldwide';\nimport { _INTERNAL_captureLog } from './exports';\n\ninterface CaptureConsoleOptions {\n levels: ConsoleLevel[];\n}\n\ntype GlobalObjectWithUtil = typeof GLOBAL_OBJ & {\n util: {\n format: (...args: unknown[]) => string;\n };\n};\n\nconst INTEGRATION_NAME = 'ConsoleLogs';\n\nconst DEFAULT_ATTRIBUTES = {\n [SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN]: 'auto.console.logging',\n};\n\nconst _consoleLoggingIntegration = ((options: Partial<CaptureConsoleOptions> = {}) => {\n const levels = options.levels || CONSOLE_LEVELS;\n\n return {\n name: INTEGRATION_NAME,\n setup(client) {\n const { enableLogs, _experiments, normalizeDepth = 3, normalizeMaxBreadth = 1_000 } = client.getOptions();\n // eslint-disable-next-line deprecation/deprecation\n const shouldEnableLogs = enableLogs ?? _experiments?.enableLogs;\n if (!shouldEnableLogs) {\n DEBUG_BUILD && debug.warn('`enableLogs` is not enabled, ConsoleLogs integration disabled');\n return;\n }\n\n addConsoleInstrumentationHandler(({ args, level }) => {\n if (getClient() !== client || !levels.includes(level)) {\n return;\n }\n\n if (level === 'assert') {\n if (!args[0]) {\n const followingArgs = args.slice(1);\n const assertionMessage =\n followingArgs.length > 0\n ? `Assertion failed: ${formatConsoleArgs(followingArgs, normalizeDepth, normalizeMaxBreadth)}`\n : 'Assertion failed';\n _INTERNAL_captureLog({ level: 'error', message: assertionMessage, attributes: DEFAULT_ATTRIBUTES });\n }\n return;\n }\n\n const isLevelLog = level === 'log';\n _INTERNAL_captureLog({\n level: isLevelLog ? 'info' : level,\n message: formatConsoleArgs(args, normalizeDepth, normalizeMaxBreadth),\n severityNumber: isLevelLog ? 10 : undefined,\n attributes: DEFAULT_ATTRIBUTES,\n });\n });\n },\n };\n}) satisfies IntegrationFn;\n\n/**\n * Captures calls to the `console` API as logs in Sentry. Requires the `enableLogs` option to be enabled.\n *\n * @experimental This feature is experimental and may be changed or removed in future versions.\n *\n * By default the integration instruments `console.debug`, `console.info`, `console.warn`, `console.error`,\n * `console.log`, `console.trace`, and `console.assert`. You can use the `levels` option to customize which\n * levels are captured.\n *\n * @example\n *\n * ```ts\n * import * as Sentry from '@sentry/browser';\n *\n * Sentry.init({\n * enableLogs: true,\n * integrations: [Sentry.consoleLoggingIntegration({ levels: ['error', 'warn'] })],\n * });\n * ```\n */\nexport const consoleLoggingIntegration = defineIntegration(_consoleLoggingIntegration);\n\nfunction formatConsoleArgs(values: unknown[], normalizeDepth: number, normalizeMaxBreadth: number): string {\n return 'util' in GLOBAL_OBJ && typeof (GLOBAL_OBJ as GlobalObjectWithUtil).util.format === 'function'\n ? (GLOBAL_OBJ as GlobalObjectWithUtil).util.format(...values)\n : safeJoinConsoleArgs(values, normalizeDepth, normalizeMaxBreadth);\n}\n\nfunction safeJoinConsoleArgs(values: unknown[], normalizeDepth: number, normalizeMaxBreadth: number): string {\n return values\n .map(value =>\n isPrimitive(value) ? String(value) : JSON.stringify(normalize(value, normalizeDepth, normalizeMaxBreadth)),\n )\n .join(' ');\n}\n"],"names":[],"mappings":";;;;;;;;;;;AAuBA,MAAM,gBAAA,GAAmB,aAAa;;AAEtC,MAAM,qBAAqB;AAC3B,EAAE,CAAC,gCAAgC,GAAG,sBAAsB;AAC5D,CAAC;;AAED,MAAM,0BAAA,IAA8B,CAAC,OAAO,GAAmC,EAAE,KAAK;AACtF,EAAE,MAAM,MAAA,GAAS,OAAO,CAAC,MAAA,IAAU,cAAc;;AAEjD,EAAE,OAAO;AACT,IAAI,IAAI,EAAE,gBAAgB;AAC1B,IAAI,KAAK,CAAC,MAAM,EAAE;AAClB,MAAM,MAAM,EAAE,UAAU,EAAE,YAAY,EAAE,iBAAiB,CAAC,EAAE,mBAAA,GAAsB,MAAM,GAAI,MAAM,CAAC,UAAU,EAAE;AAC/G;AACA,MAAM,MAAM,gBAAA,GAAmB,cAAc,YAAY,EAAE,UAAU;AACrE,MAAM,IAAI,CAAC,gBAAgB,EAAE;AAC7B,QAAQ,eAAe,KAAK,CAAC,IAAI,CAAC,+DAA+D,CAAC;AAClG,QAAQ;AACR;;AAEA,MAAM,gCAAgC,CAAC,CAAC,EAAE,IAAI,EAAE,KAAA,EAAO,KAAK;AAC5D,QAAQ,IAAI,SAAS,OAAO,MAAA,IAAU,CAAC,MAAM,CAAC,QAAQ,CAAC,KAAK,CAAC,EAAE;AAC/D,UAAU;AACV;;AAEA,QAAQ,IAAI,KAAA,KAAU,QAAQ,EAAE;AAChC,UAAU,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE;AACxB,YAAY,MAAM,gBAAgB,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC;AAC/C,YAAY,MAAM,gBAAA;AAClB,cAAc,aAAa,CAAC,MAAA,GAAS;AACrC,kBAAkB,CAAC,kBAAkB,EAAE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