@syntrologie/adapt-nav 2.55.1 → 2.57.0
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/NavWidgetLit.d.ts.map +1 -1
- package/dist/cdn.js +2 -2
- package/dist/chunk-DIQ2BVJZ.js +4993 -0
- package/dist/chunk-DIQ2BVJZ.js.map +7 -0
- package/dist/{chunk-W6EW5675.js → chunk-PF77DHF4.js} +4 -8
- package/dist/chunk-PF77DHF4.js.map +7 -0
- package/dist/editor.js +1 -1
- package/dist/editor.js.map +2 -2
- package/dist/runtime.js +2 -2
- package/dist/schema.d.ts +92 -92
- package/dist/schema.js +31 -31
- package/dist/schema.js.map +1 -1
- package/package.json +2 -3
- package/dist/chunk-W6EW5675.js.map +0 -7
- package/dist/chunk-WFF4PBTJ.js +0 -775
- package/dist/chunk-WFF4PBTJ.js.map +0 -7
package/dist/schema.js
CHANGED
|
@@ -2,23 +2,23 @@ import {
|
|
|
2
2
|
AnchorIdZ,
|
|
3
3
|
AuthoringFieldsZ,
|
|
4
4
|
NotifyZ,
|
|
5
|
-
TriggerWhenZ
|
|
6
|
-
|
|
5
|
+
TriggerWhenZ,
|
|
6
|
+
external_exports
|
|
7
|
+
} from "./chunk-DIQ2BVJZ.js";
|
|
7
8
|
|
|
8
9
|
// src/schema.ts
|
|
9
|
-
|
|
10
|
-
var NavTipSchema = z.object({
|
|
10
|
+
var NavTipSchema = external_exports.object({
|
|
11
11
|
...AuthoringFieldsZ,
|
|
12
|
-
kind:
|
|
12
|
+
kind: external_exports.literal("nav:tip").describe(
|
|
13
13
|
"Compositional action type for a single navigation tip accordion item. Rendered by the adaptive-nav:tips widget."
|
|
14
14
|
),
|
|
15
|
-
config:
|
|
15
|
+
config: external_exports.object({
|
|
16
16
|
/** Unique identifier */
|
|
17
|
-
id:
|
|
17
|
+
id: external_exports.string().min(1, "ID is required"),
|
|
18
18
|
/** Accordion header text */
|
|
19
|
-
title:
|
|
19
|
+
title: external_exports.string().min(1, "Title is required").describe("Short label shown in the collapsed accordion header \u2014 keep to one line."),
|
|
20
20
|
/** Expanded body text */
|
|
21
|
-
description:
|
|
21
|
+
description: external_exports.string().min(1, "Description is required").describe(
|
|
22
22
|
"Expanded body text shown when the tip is opened. Explain the navigation goal or value."
|
|
23
23
|
),
|
|
24
24
|
/** Target anchor: route = where, selector = what to highlight */
|
|
@@ -26,15 +26,15 @@ var NavTipSchema = z.object({
|
|
|
26
26
|
"Optional anchor defining a route and CSS selector. The SDK can scroll to or highlight the target element when the tip is activated."
|
|
27
27
|
),
|
|
28
28
|
/** @deprecated Use anchor instead */
|
|
29
|
-
href:
|
|
29
|
+
href: external_exports.string().optional().describe(
|
|
30
30
|
"Deprecated. Use anchor instead. CTA link URL shown as a button in the expanded tip body."
|
|
31
31
|
),
|
|
32
32
|
/** Optional icon */
|
|
33
|
-
icon:
|
|
33
|
+
icon: external_exports.string().optional().describe('Optional icon shown in the accordion header \u2014 emoji or icon key (e.g. "\u{1F4CA}").'),
|
|
34
34
|
/** Whether to open in new tab */
|
|
35
|
-
external:
|
|
35
|
+
external: external_exports.boolean().default(false).describe("When true, the CTA link opens in a new browser tab."),
|
|
36
36
|
/** Category for grouping */
|
|
37
|
-
category:
|
|
37
|
+
category: external_exports.string().optional().describe(
|
|
38
38
|
"Optional grouping label. Tips with the same category are grouped under a shared section header in the accordion."
|
|
39
39
|
)
|
|
40
40
|
}).describe(
|
|
@@ -49,9 +49,9 @@ var NavTipSchema = z.object({
|
|
|
49
49
|
"Toast notification shown when triggerWhen transitions false \u2192 true. Required when triggerWhen is set \u2014 pass null to opt out of the toast."
|
|
50
50
|
),
|
|
51
51
|
/** AI-generated reasoning for why this tip was recommended */
|
|
52
|
-
rationale:
|
|
53
|
-
why:
|
|
54
|
-
confidence:
|
|
52
|
+
rationale: external_exports.object({
|
|
53
|
+
why: external_exports.string().describe("Human-readable explanation of why the AI recommended this tip."),
|
|
54
|
+
confidence: external_exports.number().optional().describe("Optional 0-1 confidence score from the recommendation model.")
|
|
55
55
|
}).optional().describe(
|
|
56
56
|
"Optional AI-generated rationale for why this tip was surfaced. Used for debugging and transparency \u2014 not shown to end users."
|
|
57
57
|
)
|
|
@@ -59,41 +59,41 @@ var NavTipSchema = z.object({
|
|
|
59
59
|
message: "notify is required when triggerWhen is present (use null to opt out of notifications)"
|
|
60
60
|
});
|
|
61
61
|
var NavLinkSchema = NavTipSchema;
|
|
62
|
-
var configSchema =
|
|
62
|
+
var configSchema = external_exports.object({
|
|
63
63
|
/** Display title for the nav widget */
|
|
64
|
-
title:
|
|
64
|
+
title: external_exports.string().optional().describe("Optional header text shown above the tips accordion."),
|
|
65
65
|
/** Expand behavior */
|
|
66
|
-
expandBehavior:
|
|
66
|
+
expandBehavior: external_exports.enum(["single", "multiple"]).default("single").describe(
|
|
67
67
|
'"single" collapses any open tip before expanding another; "multiple" allows any number open simultaneously.'
|
|
68
68
|
),
|
|
69
69
|
/** Color theme */
|
|
70
|
-
theme:
|
|
70
|
+
theme: external_exports.enum(["light", "dark", "auto"]).default("auto").describe(
|
|
71
71
|
`"auto" follows the user's OS preference; use "light" or "dark" to pin the theme.`
|
|
72
72
|
),
|
|
73
73
|
/** Navigation tips (compositional actions) */
|
|
74
|
-
actions:
|
|
74
|
+
actions: external_exports.array(NavTipSchema).default([]).describe(
|
|
75
75
|
"The navigation tips rendered by the accordion. Each item is a nav:tip compositional action."
|
|
76
76
|
)
|
|
77
77
|
}).describe(
|
|
78
78
|
"Props for the adaptive-nav:tips tile widget. Configures an accordion of contextual navigation tips with conditional visibility and toast notifications."
|
|
79
79
|
);
|
|
80
|
-
var scrollTargetsSchema =
|
|
81
|
-
|
|
80
|
+
var scrollTargetsSchema = external_exports.array(
|
|
81
|
+
external_exports.object({
|
|
82
82
|
anchorId: AnchorIdZ.describe("Target element identified by route and CSS selector."),
|
|
83
|
-
behavior:
|
|
83
|
+
behavior: external_exports.enum(["smooth", "instant", "auto"]).optional().describe(
|
|
84
84
|
'"smooth" animates the scroll; "instant" jumps; "auto" defers to browser default.'
|
|
85
85
|
),
|
|
86
|
-
block:
|
|
87
|
-
inline:
|
|
86
|
+
block: external_exports.enum(["start", "center", "end", "nearest"]).optional().describe("Vertical alignment of the element within the viewport after scrolling."),
|
|
87
|
+
inline: external_exports.enum(["start", "center", "end", "nearest"]).optional().describe("Horizontal alignment of the element within the viewport after scrolling.")
|
|
88
88
|
})
|
|
89
89
|
).optional().describe(
|
|
90
90
|
"List of scroll targets. Each entry scrolls the viewport to bring a specific element into view."
|
|
91
91
|
);
|
|
92
|
-
var navigationTargetsSchema =
|
|
93
|
-
|
|
94
|
-
url:
|
|
95
|
-
target:
|
|
96
|
-
trigger:
|
|
92
|
+
var navigationTargetsSchema = external_exports.array(
|
|
93
|
+
external_exports.object({
|
|
94
|
+
url: external_exports.string().describe("Destination URL to navigate to."),
|
|
95
|
+
target: external_exports.enum(["_self", "_blank"]).optional().describe('"_self" navigates in the same tab (default); "_blank" opens a new tab.'),
|
|
96
|
+
trigger: external_exports.string().optional().describe("Optional event name or element selector that triggers this navigation.")
|
|
97
97
|
})
|
|
98
98
|
).optional().describe("List of navigation targets defining URL destinations and how they are opened.");
|
|
99
99
|
function validateNavTip(data) {
|
package/dist/schema.js.map
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../src/schema.ts"],
|
|
4
4
|
"sourcesContent": ["/**\n * Adaptive Nav - Config Schema\n *\n * Zod schema for validating navigation tips accordion configuration.\n * Demonstrates compositional action pattern with per-item triggerWhen.\n */\n\nimport { AnchorIdZ, AuthoringFieldsZ, NotifyZ, TriggerWhenZ } from '@syntrologie/sdk-contracts';\nimport { z } from 'zod';\n\n// ============================================================================\n// Nav Tip Schema\n// ============================================================================\n\n/**\n * Schema for a single navigation tip (compositional action).\n */\nexport const NavTipSchema = z\n .object({\n ...AuthoringFieldsZ,\n kind: z\n .literal('nav:tip')\n .describe(\n 'Compositional action type for a single navigation tip accordion item. Rendered by the adaptive-nav:tips widget.'\n ),\n config: z\n .object({\n /** Unique identifier */\n id: z.string().min(1, 'ID is required'),\n /** Accordion header text */\n title: z\n .string()\n .min(1, 'Title is required')\n .describe('Short label shown in the collapsed accordion header \u2014 keep to one line.'),\n /** Expanded body text */\n description: z\n .string()\n .min(1, 'Description is required')\n .describe(\n 'Expanded body text shown when the tip is opened. Explain the navigation goal or value.'\n ),\n /** Target anchor: route = where, selector = what to highlight */\n anchor: AnchorIdZ.optional().describe(\n 'Optional anchor defining a route and CSS selector. The SDK can scroll to or highlight the target element when the tip is activated.'\n ),\n /** @deprecated Use anchor instead */\n href: z\n .string()\n .optional()\n .describe(\n 'Deprecated. Use anchor instead. CTA link URL shown as a button in the expanded tip body.'\n ),\n /** Optional icon */\n icon: z\n .string()\n .optional()\n .describe('Optional icon shown in the accordion header \u2014 emoji or icon key (e.g. \"\uD83D\uDCCA\").'),\n /** Whether to open in new tab */\n external: z\n .boolean()\n .default(false)\n .describe('When true, the CTA link opens in a new browser tab.'),\n /** Category for grouping */\n category: z\n .string()\n .optional()\n .describe(\n 'Optional grouping label. Tips with the same category are grouped under a shared section header in the accordion.'\n ),\n })\n .describe(\n 'Per-tip configuration including display text, optional link, and grouping metadata.'\n ),\n /** Per-item activation strategy (null = always show) */\n triggerWhen: TriggerWhenZ.describe(\n 'Conditional visibility strategy. When null or omitted, the tip is always shown. Use a rules strategy to reveal a tip based on behavior (e.g. after 3 link clicks).'\n ),\n /** Toast config when triggerWhen transitions false \u2192 true. Required when triggerWhen is set (use null to opt out). */\n notify: NotifyZ.describe(\n 'Toast notification shown when triggerWhen transitions false \u2192 true. Required when triggerWhen is set \u2014 pass null to opt out of the toast.'\n ),\n /** AI-generated reasoning for why this tip was recommended */\n rationale: z\n .object({\n why: z.string().describe('Human-readable explanation of why the AI recommended this tip.'),\n confidence: z\n .number()\n .optional()\n .describe('Optional 0-1 confidence score from the recommendation model.'),\n })\n .optional()\n .describe(\n 'Optional AI-generated rationale for why this tip was surfaced. Used for debugging and transparency \u2014 not shown to end users.'\n ),\n })\n .refine((data) => !data.triggerWhen || data.notify !== undefined, {\n message:\n 'notify is required when triggerWhen is present (use null to opt out of notifications)',\n });\n\nexport type NavTipSchemaType = z.infer<typeof NavTipSchema>;\n\n/** @deprecated Use NavTipSchema */\nexport const NavLinkSchema = NavTipSchema;\nexport type NavLinkSchemaType = NavTipSchemaType;\n\n// ============================================================================\n// Nav Config Schema\n// ============================================================================\n\n/**\n * Full configuration schema for adaptive-nav.\n */\nexport const configSchema = z\n .object({\n /** Display title for the nav widget */\n title: z.string().optional().describe('Optional header text shown above the tips accordion.'),\n /** Expand behavior */\n expandBehavior: z\n .enum(['single', 'multiple'])\n .default('single')\n .describe(\n '\"single\" collapses any open tip before expanding another; \"multiple\" allows any number open simultaneously.'\n ),\n /** Color theme */\n theme: z\n .enum(['light', 'dark', 'auto'])\n .default('auto')\n .describe(\n '\"auto\" follows the user\\'s OS preference; use \"light\" or \"dark\" to pin the theme.'\n ),\n /** Navigation tips (compositional actions) */\n actions: z\n .array(NavTipSchema)\n .default([])\n .describe(\n 'The navigation tips rendered by the accordion. Each item is a nav:tip compositional action.'\n ),\n })\n .describe(\n 'Props for the adaptive-nav:tips tile widget. Configures an accordion of contextual navigation tips with conditional visibility and toast notifications.'\n );\n\nexport type NavConfig = z.infer<typeof configSchema>;\n\n// ============================================================================\n// Navigation Action Schemas (merged from adaptive-navigation)\n// ============================================================================\n\n/**\n * Schema for scroll-to configurations.\n */\nexport const scrollTargetsSchema = z\n .array(\n z.object({\n anchorId: AnchorIdZ.describe('Target element identified by route and CSS selector.'),\n behavior: z\n .enum(['smooth', 'instant', 'auto'])\n .optional()\n .describe(\n '\"smooth\" animates the scroll; \"instant\" jumps; \"auto\" defers to browser default.'\n ),\n block: z\n .enum(['start', 'center', 'end', 'nearest'])\n .optional()\n .describe('Vertical alignment of the element within the viewport after scrolling.'),\n inline: z\n .enum(['start', 'center', 'end', 'nearest'])\n .optional()\n .describe('Horizontal alignment of the element within the viewport after scrolling.'),\n })\n )\n .optional()\n .describe(\n 'List of scroll targets. Each entry scrolls the viewport to bring a specific element into view.'\n );\n\n/**\n * Schema for navigation target configurations.\n */\nexport const navigationTargetsSchema = z\n .array(\n z.object({\n url: z.string().describe('Destination URL to navigate to.'),\n target: z\n .enum(['_self', '_blank'])\n .optional()\n .describe('\"_self\" navigates in the same tab (default); \"_blank\" opens a new tab.'),\n trigger: z\n .string()\n .optional()\n .describe('Optional event name or element selector that triggers this navigation.'),\n })\n )\n .optional()\n .describe('List of navigation targets defining URL destinations and how they are opened.');\n\n// ============================================================================\n// Validation Helpers\n// ============================================================================\n\n/**\n * Validate a nav tip action.\n */\nexport function validateNavTip(data: unknown) {\n return NavTipSchema.safeParse(data);\n}\n\n/** @deprecated Use validateNavTip */\nexport const validateNavLink = validateNavTip;\n\n/**\n * Validate the full nav config.\n */\nexport function validateNavConfig(data: unknown) {\n return configSchema.safeParse(data);\n}\n\n// ============================================================================\n// Unified Schema Export\n// ============================================================================\n\n/**\n * Action step schemas for unified JSON Schema generation.\n * The build script reads this array to merge adaptive actions into the\n * unified canvas-config.schema.json.\n */\nexport const actionStepSchemas = [{ defName: 'navTip', schema: NavTipSchema.innerType() }];\n\n// ============================================================================\n// Tile Widget Props Export\n// ============================================================================\n\n/**\n * Tile widget definitions for unified JSON Schema generation.\n * Maps widget IDs to their props validation schema so the build script\n * can inject if/then constraints on tile.props.\n */\nexport const tileWidgets = [\n { widget: 'adaptive-nav:tips', defName: 'navTipsProps', propsSchema: configSchema },\n];\n\n// ============================================================================\n// Capabilities Documentation (injected into JSON Schema for LLM prompts)\n// ============================================================================\n\nexport const CAPABILITIES_DOCUMENTATION = {\n packageId: 'adaptive-nav',\n plannerSummary:\n 'A tile with next-best-action guidance, helping direct the user to where they should go.',\n description:\n 'Navigation tips accordion widget with conditional item visibility and toast notifications.',\n whenToUse: [\n {\n goal: 'Show contextual navigation tips widget',\n action: 'Add a tile with widget: \"adaptive-nav:tips\"',\n },\n { goal: 'Scroll to an element on the page', action: 'navigation:scrollTo' },\n { goal: 'Navigate to a different URL', action: 'navigation:navigate' },\n ],\n conventions: [\n {\n name: 'Notify watchers',\n description:\n 'Tips with both triggerWhen and notify are registered as notify watchers. The runtime evaluates these continuously even when the drawer is closed. When triggerWhen transitions false \u2192 true, the widget publishes nav:tip_revealed which can trigger toast notifications via tile-level notifications rules.',\n },\n ],\n events: [\n {\n name: 'nav:toggled',\n when: 'User expands or collapses a tip',\n props: '{ instanceId, tipId, expanded }',\n },\n {\n name: 'nav:tip_clicked',\n when: \"User clicks a tip's CTA link\",\n props: '{ instanceId, href, external }',\n },\n {\n name: 'nav:tip_revealed',\n when: 'triggerWhen transitions false \u2192 true',\n props: '{ tipId, title, body, icon }',\n },\n ],\n};\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": ";;;;;;;;;AAiBO,IAAM,eAAe,iBACzB,OAAO;AAAA,EACN,GAAG;AAAA,EACH,MAAM,iBACH,QAAQ,SAAS,EACjB;AAAA,IACC;AAAA,EACF;AAAA,EACF,QAAQ,iBACL,OAAO;AAAA;AAAA,IAEN,IAAI,iBAAE,OAAO,EAAE,IAAI,GAAG,gBAAgB;AAAA;AAAA,IAEtC,OAAO,iBACJ,OAAO,EACP,IAAI,GAAG,mBAAmB,EAC1B,SAAS,8EAAyE;AAAA;AAAA,IAErF,aAAa,iBACV,OAAO,EACP,IAAI,GAAG,yBAAyB,EAChC;AAAA,MACC;AAAA,IACF;AAAA;AAAA,IAEF,QAAQ,UAAU,SAAS,EAAE;AAAA,MAC3B;AAAA,IACF;AAAA;AAAA,IAEA,MAAM,iBACH,OAAO,EACP,SAAS,EACT;AAAA,MACC;AAAA,IACF;AAAA;AAAA,IAEF,MAAM,iBACH,OAAO,EACP,SAAS,EACT,SAAS,0FAA8E;AAAA;AAAA,IAE1F,UAAU,iBACP,QAAQ,EACR,QAAQ,KAAK,EACb,SAAS,qDAAqD;AAAA;AAAA,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AAA,IACT;AAAA,IACA;AAAA,MACE,MAAM;AAAA,MACN,MAAM;AAAA,MACN,OAAO;AAAA,IACT;AAAA,IACA;AAAA,MACE,MAAM;AAAA,MACN,MAAM;AAAA,MACN,OAAO;AAAA,IACT;AAAA,EACF;AACF;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@syntrologie/adapt-nav",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.57.0",
|
|
4
4
|
"description": "Adaptive Navigation - Nav link widget, scroll-to and page navigation actions",
|
|
5
5
|
"license": "Proprietary",
|
|
6
6
|
"private": false,
|
|
@@ -49,8 +49,7 @@
|
|
|
49
49
|
"test:watch": "vitest"
|
|
50
50
|
},
|
|
51
51
|
"peerDependencies": {
|
|
52
|
-
"lit": "^3.0.0"
|
|
53
|
-
"zod": "^3.0.0"
|
|
52
|
+
"lit": "^3.0.0"
|
|
54
53
|
},
|
|
55
54
|
"devDependencies": {
|
|
56
55
|
"@open-wc/testing": "4.0.0",
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../src/ContactCardLit.ts", "../src/NavWidgetLit.ts", "../src/resolveNavTarget.ts", "../src/runtime.ts"],
|
|
4
|
-
"sourcesContent": ["/**\n * Adaptive Nav \u2014 ContactCardLit (`<syntro-contact-card>`)\n *\n * The human-handoff tile (iGlow, 2026-08-13): when a site's own chat widget\n * is suppressed for the concierge audience, this card replaces its FUNCTION \u2014\n * an always-reachable escape hatch to a real person. One deck card: heading,\n * model-authorable framing line, and a grid of one-tap channel pills.\n *\n * Trust contract: `channels` are ADMIN-PINNED config facts (real phone /\n * booking page from the customer's own site). The model may author only\n * `heading`/`framing` \u2014 never a destination. Device-action values (tel:,\n * sms:, mailto:) fire a real anchor click so the OS dialer/composer opens\n * with the destination VISIBLE; `book`/path values navigate same-origin via\n * pushState like every nav link. Anything else is dropped at render.\n *\n * Light DOM (like NavWidgetLit) so --sc-* theme tokens flow in without a\n * shadow boundary; styling via styleMap objects resolving from tokens with\n * px fallbacks only (host rem-base immunity, 2026-08-12). The canvas owns\n * the design vocabulary \u2014 every visual value here rides a --sc-* var.\n */\n\nimport { html, LitElement, nothing } from 'lit';\nimport { styleMap } from 'lit/directives/style-map.js';\n\nimport { navigateWithFrameworkRouter } from './runtime';\n\nconst DEVICE_ACTION_PROTOCOLS = new Set(['tel:', 'sms:', 'mailto:']);\n\nexport interface ContactChannel {\n kind: string;\n label: string;\n value: string;\n}\n\ntype ResolvedChannel = ContactChannel & { mode: 'device' | 'navigate' };\n\n/** Classify a pinned channel value; null = unsafe/unknown \u2192 dropped. */\nfunction resolveChannel(ch: ContactChannel): ResolvedChannel | null {\n if (!ch?.value || !ch.label) return null;\n const raw = ch.value.trim();\n if (raw.startsWith('/') && !raw.startsWith('//')) {\n return { ...ch, mode: 'navigate' };\n }\n try {\n const url = new URL(raw, window.location.origin);\n if (DEVICE_ACTION_PROTOCOLS.has(url.protocol)) return { ...ch, mode: 'device' };\n if (\n (url.protocol === 'http:' || url.protocol === 'https:') &&\n url.origin === window.location.origin\n ) {\n return { ...ch, mode: 'navigate' };\n }\n } catch {\n return null;\n }\n return null;\n}\n\nconst cardStyles = {\n display: 'flex',\n flexDirection: 'column',\n gap: 'var(--sc-contact-card-gap, 10px)',\n padding: 'var(--sc-contact-card-padding, 4px 2px)',\n fontFamily: 'var(--sc-font-family, system-ui)',\n};\n\nconst headingStyles = {\n margin: '0',\n fontSize: 'var(--sc-contact-heading-size, 15px)',\n fontWeight: '700',\n color: 'var(--sc-tile-title-color, inherit)',\n};\n\nconst framingStyles = {\n margin: '0',\n fontSize: 'var(--sc-contact-framing-size, 13px)',\n lineHeight: '1.35',\n opacity: '0.75',\n color: 'var(--sc-tile-text-color, inherit)',\n};\n\nconst gridStyles = {\n display: 'grid',\n gridTemplateColumns: 'repeat(auto-fit, minmax(var(--sc-contact-pill-min, 130px), 1fr))',\n gap: 'var(--sc-contact-grid-gap, 8px)',\n};\n\nconst pillStyles = {\n display: 'inline-flex',\n alignItems: 'center',\n justifyContent: 'center',\n gap: '6px',\n padding: 'var(--sc-contact-pill-padding, 10px 12px)',\n borderRadius: 'var(--sc-chip-border-radius, 9999px)',\n border: 'var(--sc-chip-border, 1px solid currentColor)',\n background: 'var(--sc-chip-background, transparent)',\n color: 'var(--sc-tile-title-color, inherit)',\n fontSize: 'var(--sc-contact-pill-size, 13px)',\n fontWeight: '600',\n cursor: 'pointer',\n minHeight: 'var(--sc-contact-pill-min-height, 40px)',\n};\n\nexport class ContactCardLit extends LitElement {\n static override properties = {\n heading: { type: String },\n framing: { type: String },\n channels: { type: Array },\n };\n\n heading = 'Talk to a person';\n framing = '';\n channels: ContactChannel[] = [];\n\n /**\n * Same-origin navigation seam. Framework-aware (Next/Nuxt/Angular routers)\n * with a FULL location.assign fallback \u2014 never bare pushState: on a\n * non-SPA host (WordPress \u2014 iglow) pushState changes the URL bar and loads\n * nothing. Injectable for tests.\n */\n navigate: (url: string) => void = (url) => {\n if (!navigateWithFrameworkRouter(url)) {\n window.location.assign(url);\n }\n };\n\n // Light DOM: inherit --sc-* tokens without a shadow boundary.\n override createRenderRoot(): HTMLElement {\n return this;\n }\n\n private _activate = (ch: ResolvedChannel): void => {\n if (ch.mode === 'device') {\n const a = document.createElement('a');\n a.href = ch.value.trim();\n a.style.display = 'none';\n document.body.appendChild(a);\n a.click();\n a.remove();\n return;\n }\n const resolved = new URL(ch.value.trim(), window.location.origin);\n this.navigate(resolved.toString());\n };\n\n override render() {\n const resolved = (this.channels ?? [])\n .map(resolveChannel)\n .filter((c): c is ResolvedChannel => c !== null);\n // Fail closed: no pinned channels \u2192 render NOTHING (a bare heading with\n // no actions reads as a broken card).\n if (resolved.length === 0) return nothing;\n return html`\n <div data-contact-card style=${styleMap(cardStyles)}>\n ${\n this.heading\n ? html`<h4 data-contact-heading style=${styleMap(headingStyles)}>${this.heading}</h4>`\n : nothing\n }\n ${\n this.framing\n ? html`<p data-contact-framing style=${styleMap(framingStyles)}>${this.framing}</p>`\n : nothing\n }\n <div data-contact-grid style=${styleMap(gridStyles)}>\n ${resolved.map(\n (ch) => html`\n <button\n type=\"button\"\n data-contact-pill=${ch.kind}\n style=${styleMap(pillStyles)}\n @click=${() => this._activate(ch)}\n >\n ${ch.label}\n </button>\n `\n )}\n </div>\n </div>\n `;\n }\n}\n\n/** Idempotent element registration \u2014 called by ContactCardMountable on first\n * mount (regression: a silently-dropped side-effect import shipped a bundle\n * where the element was never defined and the card rendered empty). */\nexport function registerContactCardLit(): void {\n if (typeof customElements !== 'undefined' && !customElements.get('syntro-contact-card')) {\n customElements.define('syntro-contact-card', ContactCardLit);\n }\n}\n\nregisterContactCardLit();\n", "/**\n * Adaptive Nav - NavWidgetLit Web Component\n *\n * Lit web component equivalent of NavWidget.tsx. Renders a collapsible\n * navigation tips accordion with per-item conditional visibility, framework-aware\n * navigation, and CSS variable theming.\n *\n * Decorator-free: uses `static override properties` (tsconfig has no\n * experimentalDecorators).\n *\n * Uses light DOM (createRenderRoot returns this) so host-page CSS variables\n * (--sc-*) are inherited without crossing a shadow boundary.\n */\n\nimport {\n normalizeRoute,\n renderIcon as renderEmojiIcon,\n routesMatch,\n} from '@syntrologie/sdk-contracts';\nimport { html, LitElement, nothing } from 'lit';\nimport { styleMap } from 'lit/directives/style-map.js';\nimport { unsafeHTML } from 'lit/directives/unsafe-html.js';\n\nimport { detectIsIframe, resolveNavTarget } from './resolveNavTarget';\nimport { navigateWithFrameworkRouter } from './runtime';\nimport type { NavConfig, NavTipAction, NavWidgetRuntime } from './types';\n\n// ============================================================================\n// Design system token fallbacks (inlined to avoid bundling @syntro/design-system\n// as a hard dep for this file; values match packages/design-system/src/tokens/colors.ts)\n// ============================================================================\n\nconst TOKEN_PURPLE_4 = '#6a59ce';\nconst TOKEN_SLATE_GREY_7 = '#677384';\nconst TOKEN_SLATE_GREY_8 = '#87919f';\n\n// ============================================================================\n// Emoji \u2192 Lucide SVG mapping is centralized in @syntrologie/sdk-contracts.\n// To add a new emoji, edit that package's icons.ts \u2014 every adaptive picks it\n// up automatically.\n// ============================================================================\n\nfunction escapeHtml(str: string): string {\n return str\n .replace(/&/g, '&')\n .replace(/</g, '<')\n .replace(/>/g, '>')\n .replace(/\"/g, '"')\n .replace(/'/g, ''');\n}\n\nfunction renderIcon(emoji: string): string {\n return renderEmojiIcon(emoji) || escapeHtml(emoji);\n}\n\n// (resolveNavTarget extracted to ./resolveNavTarget \u2014 also consumed by\n// NavWidget.tsx so both Lit and React variants share the routing decision)\n\n// ============================================================================\n// Route matching helper\n// ============================================================================\n\nfunction routeMatchesCurrent(routes: string[]): boolean {\n if (typeof window === 'undefined') return false;\n let canonicalCurrent: string;\n try {\n canonicalCurrent = normalizeRoute(window.location.pathname);\n } catch {\n return false;\n }\n return routes.some((route) => {\n // Preserve the existing `/**` prefix-match semantics. The literal\n // prefix portion goes through normalizeRoute so trailing slash,\n // query, hash, and case are handled the same as the current URL.\n if (route.endsWith('/**')) {\n const prefix = route.slice(0, -3);\n try {\n const canonicalPrefix = prefix ? normalizeRoute(prefix) : '';\n return canonicalCurrent.toLowerCase().startsWith(canonicalPrefix.toLowerCase());\n } catch {\n return false;\n }\n }\n try {\n return routesMatch(normalizeRoute(route), canonicalCurrent);\n } catch {\n return false;\n }\n });\n}\n\n// ============================================================================\n// Pulse animation helper\n// ============================================================================\n\nfunction pulseElement(el: HTMLElement): void {\n const keyframes: Keyframe[] = [\n { boxShadow: '0 0 0 0 rgba(13, 148, 136, 0.5)' },\n { boxShadow: '0 0 0 8px rgba(13, 148, 136, 0)' },\n ];\n el.animate(keyframes, { duration: 600, iterations: 3, easing: 'ease-out' });\n}\n\n// ============================================================================\n// Theme helpers\n// ============================================================================\n\ntype ResolvedTheme = 'light' | 'dark';\n\nfunction resolveTheme(theme: string | undefined): ResolvedTheme {\n if (theme === 'dark') return 'dark';\n if (theme === 'light') return 'light';\n // auto or undefined: detect system preference\n if (typeof window !== 'undefined') {\n return window.matchMedia?.('(prefers-color-scheme: dark)').matches ? 'dark' : 'light';\n }\n return 'light';\n}\n\n// ============================================================================\n// AnchorId type (matches sdk-contracts shape used in NavWidget.tsx)\n// ============================================================================\n\ninterface AnchorId {\n route: string | string[];\n selector: string;\n}\n\n/** Browser side effects used by navigation clicks. Injectable for host adapters and tests. */\nexport interface NavNavigationPort {\n open(url: string): void;\n fullNavigate(url: string): void;\n pushState(url: string): void;\n}\n\nconst browserNavigationPort: NavNavigationPort = {\n open(url) {\n window.open(url, '_blank', 'noopener,noreferrer');\n },\n fullNavigate(url) {\n window.location.href = url;\n },\n pushState(url) {\n window.history.pushState(null, '', url);\n window.dispatchEvent(new PopStateEvent('popstate'));\n },\n};\n\n// ============================================================================\n// NavWidgetLit \u2014 LitElement\n// ============================================================================\n\nexport class NavWidgetLit extends LitElement {\n // ---------- No shadow DOM \u2014 inherit host CSS variables --------------------\n\n override createRenderRoot() {\n return this;\n }\n\n // ---------- Reactive properties (no decorators) --------------------------\n\n static override properties = {\n // Public inputs\n config: { attribute: false },\n runtime: { attribute: false },\n instanceId: { type: String },\n\n // Internal reactive state\n _expandedIds: { state: true },\n _renderTick: { state: true },\n _hoveredId: { state: true },\n };\n\n // ---------- Public properties --------------------------------------------\n\n config: NavConfig = { expandBehavior: 'single', theme: 'auto', actions: [] };\n runtime: NavWidgetRuntime | undefined = undefined;\n instanceId: string = 'nav-widget';\n navigationPort: NavNavigationPort = browserNavigationPort;\n\n // ---------- Internal state -----------------------------------------------\n\n /** @internal */ _expandedIds: Set<string> = new Set();\n /** @internal */ _renderTick = 0;\n /** @internal */ _hoveredId: string | null = null;\n\n // ---------- Private subscriptions ----------------------------------------\n\n #contextUnsub: (() => void) | null = null;\n #accumulatorUnsub: (() => void) | null = null;\n\n // ---------- Lifecycle: connectedCallback ---------------------------------\n\n override connectedCallback(): void {\n super.connectedCallback();\n this.#subscribeRuntime();\n }\n\n // ---------- Lifecycle: disconnectedCallback ------------------------------\n\n override disconnectedCallback(): void {\n super.disconnectedCallback();\n this.#unsubscribeRuntime();\n }\n\n // ---------- Lifecycle: updated -------------------------------------------\n\n override updated(changed: Map<string, unknown>): void {\n if (changed.has('runtime')) {\n this.#unsubscribeRuntime();\n this.#subscribeRuntime();\n }\n }\n\n // ---------- Runtime subscriptions ----------------------------------------\n\n #subscribeRuntime(): void {\n if (!this.runtime) return;\n\n this.#contextUnsub = this.runtime.context.subscribe(() => {\n this._renderTick += 1;\n });\n\n if (this.runtime.accumulator?.subscribe) {\n this.#accumulatorUnsub = this.runtime.accumulator.subscribe(() => {\n this._renderTick += 1;\n });\n }\n }\n\n #unsubscribeRuntime(): void {\n this.#contextUnsub?.();\n this.#contextUnsub = null;\n this.#accumulatorUnsub?.();\n this.#accumulatorUnsub = null;\n }\n\n // ---------- Computed helpers (called on each render) ---------------------\n\n #getVisibleTips(): NavTipAction[] {\n // _renderTick is read here to ensure this re-runs when context/accumulator\n // notify (same pattern as useMemo with renderTick dep in React version).\n void this._renderTick;\n\n if (!this.runtime) return this.config.actions;\n\n return this.config.actions.filter((tip) => {\n if (!tip.triggerWhen) return true;\n try {\n const result = this.runtime!.evaluateSync<boolean>(tip.triggerWhen);\n return result.value;\n } catch {\n // Fail-closed: hide tip when strategy evaluation throws\n return false;\n }\n });\n }\n\n #getResolvedTheme(): ResolvedTheme {\n return resolveTheme(this.config.theme);\n }\n\n // ---------- Event handlers -----------------------------------------------\n\n #handleToggle(id: string): void {\n const wasExpanded = this._expandedIds.has(id);\n\n let next: Set<string>;\n if (this.config.expandBehavior === 'single') {\n // Emit collapse events for previously-expanded tips (single mode)\n for (const prevId of this._expandedIds) {\n if (prevId !== id) {\n this.#publishEvent('nav:toggled', {\n tipId: prevId,\n expanded: false,\n });\n }\n }\n next = wasExpanded ? new Set() : new Set([id]);\n } else {\n next = new Set(this._expandedIds);\n if (wasExpanded) {\n next.delete(id);\n } else {\n next.add(id);\n }\n }\n\n this.#publishEvent('nav:toggled', {\n tipId: id,\n expanded: !wasExpanded,\n });\n\n this._expandedIds = next;\n }\n\n #handleNavigate(href: string, external: boolean): void {\n // Reject dangerous URIs\n const normalized = href.trim().toLowerCase();\n if (normalized.startsWith('javascript:') || normalized.startsWith('data:')) return;\n\n this.#publishEvent('nav:tip_clicked', { href, external });\n\n // Also fire a standard custom event for host-page listeners\n this.dispatchEvent(\n new CustomEvent('nav-tip-clicked', {\n bubbles: true,\n detail: { href, external, instanceId: this.instanceId },\n })\n );\n\n // Routing decision is in resolveNavTarget (a pure helper). When mounted\n // in an iframe (canvas surface, partner embed, etc.), every nav escapes\n // via window.open \u2014 sandbox `allow-popups` lets it pop out to the user's\n // main browser. On the customer site (top-level window), normal cross-/\n // same-origin handling applies.\n const target = resolveNavTarget({\n href,\n external,\n windowOrigin: typeof window !== 'undefined' ? window.location.origin : '',\n isIframe: detectIsIframe(),\n });\n\n if (target.kind === 'open') {\n this.navigationPort.open(target.url);\n return;\n }\n if (target.kind === 'fullnav') {\n this.navigationPort.fullNavigate(target.url);\n return;\n }\n // kind === 'spa'\n target.url.search = window.location.search;\n if (!navigateWithFrameworkRouter(target.url.toString())) {\n this.navigationPort.pushState(target.url.toString());\n }\n }\n\n #handleFocusAnchor(anchor: AnchorId): void {\n const el = document.querySelector(anchor.selector);\n if (!(el instanceof HTMLElement)) return;\n\n this.#publishEvent('nav:tip_focused', {\n selector: anchor.selector,\n route: anchor.route,\n });\n\n this.dispatchEvent(\n new CustomEvent('nav-tip-focused', {\n bubbles: true,\n detail: { selector: anchor.selector, instanceId: this.instanceId },\n })\n );\n\n el.scrollIntoView({ behavior: 'smooth', block: 'center' });\n pulseElement(el);\n setTimeout(() => el.focus(), 400);\n }\n\n #publishEvent(name: string, props: Record<string, unknown>): void {\n this.runtime?.events.publish(name, {\n instanceId: this.instanceId,\n timestamp: Date.now(),\n ...props,\n });\n }\n\n // ---------- Tip item rendering -------------------------------------------\n\n #renderTipItem(tip: NavTipAction, index: number, total: number) {\n const { id, title, description, href, icon, external, anchor, category: _cat } = tip.config;\n const isExpanded = this._expandedIds.has(id);\n const isLast = index === total - 1;\n const isHovered = this._hoveredId === id;\n const theme = this.#getResolvedTheme();\n\n // Determine the effective href from anchor or legacy href\n const effectiveHref = anchor\n ? Array.isArray(anchor.route)\n ? anchor.route[0]\n : anchor.route\n : href;\n\n // Same-page check\n const isSamePage = anchor\n ? routeMatchesCurrent(Array.isArray(anchor.route) ? anchor.route : [anchor.route])\n : effectiveHref\n ? routeMatchesCurrent([effectiveHref])\n : false;\n const hasSelector = anchor?.selector && anchor.selector !== '*';\n const isFocusAction = isSamePage && hasSelector;\n const hasAction = !!effectiveHref || isFocusAction;\n\n const ctaLabel = isFocusAction ? 'Focus \\u2192' : external ? 'Go \\u2197' : 'Go \\u2192';\n\n // Item container styles\n const itemStyle = styleMap({\n borderRadius: 'var(--sc-content-border-radius, 8px)',\n overflow: 'hidden',\n transition: 'box-shadow 0.2s ease',\n backgroundColor: 'var(--sc-content-background)',\n border: 'var(--sc-content-border)',\n ...(isExpanded\n ? {\n boxShadow:\n theme === 'dark'\n ? '0 4px 12px rgba(0, 0, 0, 0.15)'\n : '0 4px 12px rgba(0, 0, 0, 0.08)',\n }\n : {}),\n ...(!isLast ? { borderBottom: 'var(--sc-content-item-divider, none)' } : {}),\n });\n\n // Header styles\n const headerStyle = styleMap({\n display: 'flex',\n alignItems: 'center',\n gap: '8px',\n width: '100%',\n padding: 'var(--sc-content-item-padding, 12px 16px)',\n border: 'none',\n cursor: 'pointer',\n fontSize: 'var(--sc-content-item-font-size, 15px)',\n fontWeight: '500',\n fontFamily: 'inherit',\n textAlign: 'left',\n transition: 'background-color 0.15s ease',\n backgroundColor: isHovered ? 'var(--sc-content-background-hover)' : 'transparent',\n color: 'var(--sc-content-text-color)',\n });\n\n // Chevron styles\n const chevronStyle = styleMap({\n fontSize: '20px',\n transition: 'transform 0.2s ease',\n marginLeft: 'auto',\n flexShrink: '0',\n color: 'var(--sc-content-chevron-color, currentColor)',\n transform: isExpanded ? 'rotate(90deg)' : 'rotate(0deg)',\n });\n\n // Body styles\n const bodyStyle = styleMap({\n overflow: 'hidden',\n transition: 'max-height 0.25s ease, padding-bottom 0.25s ease',\n padding: 'var(--sc-content-body-padding, 0 16px 12px 16px)',\n color: 'var(--sc-content-text-secondary-color)',\n maxHeight: isExpanded ? '500px' : '0',\n paddingBottom: isExpanded ? '16px' : '0',\n });\n\n // Description styles\n const descriptionStyle = styleMap({\n fontSize: 'var(--sc-content-body-font-size, 14px)',\n lineHeight: '1.5',\n margin: '0',\n });\n\n // CTA / link button styles\n const linkButtonStyle = styleMap({\n display: 'inline-flex',\n alignItems: 'center',\n gap: '4px',\n marginTop: '10px',\n padding: '6px 12px',\n borderRadius: '6px',\n textDecoration: 'none',\n fontSize: '13px',\n fontWeight: '500',\n cursor: 'pointer',\n border: 'none',\n transition: 'background-color 0.15s ease',\n backgroundColor: `var(--sc-color-primary, ${TOKEN_PURPLE_4})`,\n color: '#ffffff',\n });\n\n // Icon styles\n const iconStyle = styleMap({\n fontSize: '16px',\n flexShrink: '0',\n });\n\n // Anchor click handler\n const onLinkClick = (e: Event) => {\n e.preventDefault();\n e.stopPropagation();\n if (isFocusAction && anchor) {\n this.#handleFocusAnchor(anchor);\n } else if (effectiveHref) {\n this.#handleNavigate(effectiveHref, external ?? false);\n }\n };\n\n return html`\n <div\n style=${itemStyle}\n data-nav-tip-id=${id}\n >\n <button\n type=\"button\"\n style=${headerStyle}\n aria-expanded=${isExpanded}\n @click=${() => this.#handleToggle(id)}\n @mouseenter=${() => {\n this._hoveredId = id;\n }}\n @mouseleave=${() => {\n this._hoveredId = null;\n }}\n >\n ${icon ? html`<span style=${iconStyle}>${unsafeHTML(renderIcon(icon))}</span>` : nothing}\n <span>${title}</span>\n <span style=${chevronStyle}>${'\\u203A'}</span>\n </button>\n <div style=${bodyStyle} aria-hidden=${!isExpanded}>\n <p style=${descriptionStyle}>${description}</p>\n ${\n hasAction\n ? html`\n <a\n href=${effectiveHref || '#'}\n style=${linkButtonStyle}\n target=${external ? '_blank' : nothing}\n rel=${external ? 'noopener noreferrer' : nothing}\n @click=${onLinkClick}\n >${ctaLabel}</a>\n `\n : nothing\n }\n </div>\n </div>\n `;\n }\n\n // ---------- Render --------------------------------------------------------\n\n override render() {\n const visibleTips = this.#getVisibleTips();\n const theme = this.#getResolvedTheme();\n\n const containerStyle = styleMap({\n fontFamily: 'var(--sc-font-family, system-ui, -apple-system, sans-serif)',\n maxWidth: '100%',\n overflow: 'hidden',\n backgroundColor: 'transparent',\n color: 'inherit',\n });\n\n const accordionStyle = styleMap({\n display: 'flex',\n flexDirection: 'column',\n gap: 'var(--sc-content-item-gap, 6px)',\n });\n\n const categoryHeaderStyle = styleMap({\n fontSize: 'var(--sc-content-category-font-size, 12px)',\n fontWeight: '600',\n textTransform: 'uppercase',\n letterSpacing: '0.05em',\n padding: 'var(--sc-content-category-padding, 8px 4px 4px 4px)',\n color: theme === 'dark' ? TOKEN_SLATE_GREY_8 : TOKEN_SLATE_GREY_7,\n });\n\n const emptyStateStyle = styleMap({\n fontSize: '13px',\n padding: '16px',\n textAlign: 'center',\n color: theme === 'dark' ? TOKEN_SLATE_GREY_7 : TOKEN_SLATE_GREY_8,\n });\n\n // Empty state\n if (visibleTips.length === 0) {\n return html`\n <div\n style=${containerStyle}\n data-adaptive-id=${this.instanceId}\n data-adaptive-type=\"adaptive-nav\"\n >\n <div style=${emptyStateStyle}>\n You're all set for now! We'll share helpful tips here when they're relevant to what\n you're doing.\n </div>\n </div>\n `;\n }\n\n // Group by category\n const categoryGroups = new Map<string | undefined, NavTipAction[]>();\n for (const tip of visibleTips) {\n const cat = tip.config.category;\n if (!categoryGroups.has(cat)) {\n categoryGroups.set(cat, []);\n }\n categoryGroups.get(cat)!.push(tip);\n }\n\n const hasCategories = visibleTips.some((t) => t.config.category);\n\n return html`\n <div\n style=${containerStyle}\n data-adaptive-id=${this.instanceId}\n data-adaptive-type=\"adaptive-nav\"\n >\n <div style=${accordionStyle}>\n ${\n hasCategories\n ? Array.from(categoryGroups.entries()).map(\n ([category, items]) => html`\n ${\n category\n ? html`<div style=${categoryHeaderStyle} data-category-header=${category}>${category}</div>`\n : nothing\n }\n ${items.map((tip, idx) => this.#renderTipItem(tip, idx, items.length))}\n `\n )\n : visibleTips.map((tip, idx) => this.#renderTipItem(tip, idx, visibleTips.length))\n }\n </div>\n </div>\n `;\n }\n}\n\n// ============================================================================\n// Custom element registration\n// ============================================================================\n\nconst TAG_NAME = 'syntro-nav-tips';\n\nexport function registerNavWidgetLit(): void {\n if (typeof window === 'undefined') return;\n if (!customElements.get(TAG_NAME)) {\n customElements.define(TAG_NAME, NavWidgetLit);\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'syntro-nav-tips': NavWidgetLit;\n }\n}\n", "/**\n * Pure decision function for nav-tip click routing.\n *\n * Given an href, an `external` flag, the current window's origin, and whether\n * the SDK is mounted inside an iframe, returns the navigation action to take.\n *\n * Extracted from NavWidgetLit so both the Lit and React widget variants\n * share one decision matrix and so the routing logic can be unit-tested\n * without mutating window.location (jsdom doesn't allow redefining\n * origin/href).\n */\n\nexport type NavTarget =\n | { kind: 'open'; url: string }\n | { kind: 'fullnav'; url: string }\n | { kind: 'spa'; url: URL };\n\nexport interface ResolveNavTargetArgs {\n href: string;\n external: boolean;\n windowOrigin: string;\n /**\n * True when the SDK is mounted inside an iframe (window !== window.top, or\n * window.top access threw cross-origin). When true, every nav escapes via\n * window.open \u2014 the parent page's sandbox `allow-popups` lets the new\n * window pop out to the user's main browser.\n */\n isIframe: boolean;\n}\n\n/**\n * Decide what to do with a nav-tip click.\n *\n * Routing branches (in order):\n *\n * 1. **Iframe context** (`isIframe=true` OR opaque origin \"null\"):\n * always `window.open` the href as-is. Action-plan authors who want\n * cross-iframe nav must use absolute URLs (any host \u2014 customer's,\n * partner's, doesn't matter). The sandbox's `allow-popups` lets the\n * open() call escape to the user's main browser.\n *\n * 2. **Explicit external** (`external=true`): always opens in `_blank`.\n *\n * 3. **Cross-origin absolute href** (no iframe; URL parses to a different\n * origin): full `window.location.href` navigation.\n *\n * 4. **Same-origin** (most common \u2014 SDK on customer site, internal route):\n * SPA-style `pushState` (caller falls back to framework router).\n *\n * 5. **Parse failure**: full-nav fallback; browser does its best.\n */\nexport function resolveNavTarget(args: ResolveNavTargetArgs): NavTarget {\n const { href, external, windowOrigin, isIframe } = args;\n\n const isOpaqueOrigin = windowOrigin === 'null';\n if (isIframe || isOpaqueOrigin) {\n return { kind: 'open', url: href };\n }\n\n if (external) {\n return { kind: 'open', url: href };\n }\n\n let url: URL;\n try {\n url = new URL(href, windowOrigin);\n } catch {\n return { kind: 'fullnav', url: href };\n }\n\n if (url.origin !== windowOrigin) {\n return { kind: 'fullnav', url: url.toString() };\n }\n\n return { kind: 'spa', url };\n}\n\n/**\n * Helper: detect whether the current window is mounted in an iframe.\n * Cross-origin parent access can throw \u2014 treat that as \"in iframe.\"\n */\nexport function detectIsIframe(): boolean {\n if (typeof window === 'undefined') return false;\n try {\n return window !== window.top;\n } catch {\n return true;\n }\n}\n", "/**\n * Adaptive Nav - Runtime Module\n *\n * Runtime manifest for the navigation tips accordion adaptive.\n * Mounts the `<syntro-nav-tips>` Lit web component.\n * Includes widget-based nav tips and navigation action executors\n * (scrollTo, navigate) previously in adaptive-navigation.\n */\n\nimport { type MountPlumbing, stripMountPlumbing } from '@syntrologie/sdk-contracts';\n\nimport { registerContactCardLit } from './ContactCardLit';\nimport { registerNavWidgetLit } from './NavWidgetLit';\nimport type {\n ActionExecutor,\n ExecutorResult,\n NavConfig,\n NavigateAction,\n NavTipAction,\n NavWidgetRuntime,\n ScrollToAction,\n} from './types';\n\n// ============================================================================\n// Navigation Action Executors (merged from adaptive-navigation)\n// ============================================================================\n\n/**\n * Execute a scrollTo action\n */\nexport const executeScrollTo: ActionExecutor<ScrollToAction> = async (\n action,\n context\n): Promise<ExecutorResult> => {\n const anchorEl = context.resolveAnchor(action.anchorId);\n if (!anchorEl) {\n console.error(\n `[adaptive-nav] Anchor not found for scrollTo, skipping: ${action.anchorId.selector}`\n );\n return { cleanup: () => {} };\n }\n\n // Scroll to element\n anchorEl.scrollIntoView({\n behavior: action.behavior ?? 'smooth',\n block: action.block ?? 'center',\n inline: action.inline ?? 'nearest',\n });\n\n context.publishEvent('action.applied', {\n id: context.generateId(),\n kind: 'navigation:scrollTo',\n anchorId: action.anchorId,\n behavior: action.behavior ?? 'smooth',\n });\n\n // Auto-pulse the landing target unless the caller explicitly opts\n // out. A scroll without a visual landing cue leaves the visitor\n // wondering \"what just changed?\" \u2014 the pulse gives the destination\n // a brief glow so it reads as deliberate guidance. Same anchor; the\n // ActionEngine routes overlays:pulse to whichever adaptive owns it\n // (adaptive-overlays). Best-effort: if the runtime doesn't have the\n // overlays adaptive registered we silently skip, scroll still wins.\n if (action.pulse !== false && typeof context.applyAction === 'function') {\n void context\n .applyAction({\n kind: 'overlays:pulse',\n anchorId: action.anchorId,\n })\n .catch(() => {\n // pulse failure shouldn't fail the scroll\n });\n }\n\n return {\n cleanup: () => {\n // Optionally restore scroll position on revert\n },\n };\n};\n\n/**\n * Try to navigate using the host framework's native router.\n * Returns true if a framework router handled the navigation,\n * false if no framework was detected (caller should use pushState or location.href).\n *\n * Using the native router preserves SPA behavior (no full reload),\n * layout state, scroll position, and framework-specific features\n * (RSC streaming, view transitions, etc.).\n */\nexport function navigateWithFrameworkRouter(url: string): boolean {\n if (typeof window === 'undefined') return false;\n const w = window as any;\n\n // Next.js \u2014 window.next.router.push() triggers App Router navigation\n // with RSC fetch, layout preservation, and loading states\n try {\n const nextRouter = w.next?.router;\n if (nextRouter?.push) {\n nextRouter.push(url);\n return true;\n }\n } catch {\n /* fall through */\n }\n\n // Nuxt 3 \u2014 useRouter() isn't accessible from outside Vue, but\n // $nuxt.$router (Nuxt 2) or window.__NUXT__?.hooks (Nuxt 3) + navigateTo\n // aren't reliably exposed. Nuxt 2 exposes $nuxt.$router.push().\n try {\n if (w.$nuxt?.$router?.push) {\n w.$nuxt.$router.push(url);\n return true;\n }\n } catch {\n /* fall through */\n }\n\n // Angular \u2014 Angular Router isn't exposed on window by default.\n // The most reliable approach is to detect Angular and use location.href.\n if (w.ng || w.getAllAngularRootElements || document.querySelector('[ng-version]')) {\n window.location.href = url;\n return true;\n }\n\n // SvelteKit \u2014 goto() isn't on window, but __SVELTEKIT_DATA__ confirms the framework.\n if (w.__SVELTEKIT_DATA__ || document.body?.hasAttribute('data-sveltekit')) {\n window.location.href = url;\n return true;\n }\n\n // Astro (View Transitions) \u2014 no client-side router API exposed\n if (document.querySelector('[data-astro-transition-fallback]')) {\n window.location.href = url;\n return true;\n }\n\n return false;\n}\n\n/**\n * Check if a URL is same-origin as the current page.\n * Relative URLs (e.g. \"/dashboard\") are always same-origin.\n */\nfunction isSameOrigin(url: string): boolean {\n try {\n const parsed = new URL(url, window.location.origin);\n return parsed.origin === window.location.origin;\n } catch {\n // If URL parsing fails, fall back to full navigation\n return false;\n }\n}\n\n/**\n * Execute a navigate action\n */\nexport const executeNavigate: ActionExecutor<NavigateAction> = async (\n action,\n context\n): Promise<ExecutorResult> => {\n // Validate URL to prevent javascript: URLs\n const url = action.url.trim();\n if (url.toLowerCase().startsWith('javascript:')) {\n throw new Error('javascript: URLs are not allowed');\n }\n\n const target = action.target ?? '_self';\n\n context.publishEvent('action.applied', {\n id: context.generateId(),\n kind: 'navigation:navigate',\n url: action.url,\n target,\n });\n\n if (target === '_blank') {\n // Open in new tab\n window.open(url, '_blank', 'noopener,noreferrer');\n } else if (!action.forceFullNavigation && isSameOrigin(url)) {\n // Try the host framework's native router first (Next.js, Nuxt, Angular, etc.)\n // Falls back to pushState for vanilla SPAs, or location.href as last resort.\n if (!navigateWithFrameworkRouter(url)) {\n window.history.pushState(null, '', url);\n window.dispatchEvent(new PopStateEvent('popstate'));\n }\n } else {\n // Full navigation for cross-origin URLs or when explicitly requested\n window.location.href = url;\n }\n\n return {\n cleanup: () => {\n // Navigation cannot be reverted\n },\n };\n};\n\n// ============================================================================\n// Lit Mountable Widget\n// ============================================================================\n\n/**\n * NavWidgetLitMountable \u2014 Mounts the `<syntro-nav-tips>` Lit web component.\n * Self-registers the custom element on first use.\n */\nconst DEFAULT_NAV_CONFIG: NavConfig = {\n expandBehavior: 'single',\n theme: 'auto',\n actions: [],\n};\n\n/**\n * ContactCardMountable \u2014 mounts `<syntro-contact-card>` (adaptive-nav:contact-card).\n * The human-handoff tile: admin-pinned contact channels + model-authorable\n * heading/framing. See ContactCardLit for the trust contract.\n */\nexport const ContactCardMountable = {\n mount(container: HTMLElement, config?: (Record<string, unknown> & MountPlumbing) | null) {\n registerContactCardLit();\n const el = document.createElement('syntro-contact-card') as HTMLElement & {\n heading?: string;\n framing?: string;\n channels?: unknown;\n };\n const stripped = stripMountPlumbing<Record<string, unknown>>(config ?? null) ?? {};\n Object.assign(el, {\n heading: (stripped.heading as string) ?? 'Talk to a person',\n framing: (stripped.framing as string) ?? '',\n channels: stripped.channels ?? [],\n });\n container.appendChild(el);\n return () => el.remove();\n },\n};\n\nexport const NavWidgetLitMountable = {\n mount(\n container: HTMLElement,\n config?: (NavConfig & MountPlumbing & { runtime?: NavWidgetRuntime }) | null\n ) {\n registerNavWidgetLit();\n\n const el = document.createElement('syntro-nav-tips');\n\n const incoming = config ?? null;\n const stripped = stripMountPlumbing<NavConfig & { runtime?: NavWidgetRuntime }>(incoming);\n const runtime = incoming?.runtime as NavWidgetRuntime | undefined;\n const instanceId = incoming?.instanceId ?? 'nav-widget';\n const navConfig: NavConfig = incoming ? (stripped as NavConfig) : { ...DEFAULT_NAV_CONFIG };\n\n // Assign structured props as JS properties (not HTML attributes)\n Object.assign(el, {\n config: navConfig,\n runtime,\n instanceId,\n });\n\n container.appendChild(el);\n\n return () => el.remove();\n },\n};\n\n// ============================================================================\n// Executor Definitions for Registration\n// ============================================================================\n\n/**\n * All executors provided by this app.\n * These are registered with the runtime's ExecutorRegistry.\n */\nexport const executors = [\n { kind: 'navigation:scrollTo', executor: executeScrollTo },\n { kind: 'navigation:navigate', executor: executeNavigate },\n] as const;\n\n// ============================================================================\n// App Runtime Manifest\n// ============================================================================\n\n/**\n * Runtime manifest for adaptive-nav.\n *\n * Provides:\n * - Navigation action executors (scrollTo, navigate)\n * - Widget-based nav tips accordion using the Lit web component\n */\nexport const runtime = {\n id: 'adaptive-nav',\n version: '2.0.0',\n name: 'Navigation Tips',\n description: 'Navigation actions and accordion-based tips with per-item conditional visibility',\n\n /**\n * Navigation action executors (scrollTo, navigate).\n */\n executors,\n\n /**\n * Widget definitions for the runtime's WidgetRegistry.\n */\n widgets: [\n {\n id: 'adaptive-nav:contact-card',\n component: ContactCardMountable,\n metadata: {\n name: 'Contact Card',\n description:\n 'Human-handoff card: admin-pinned contact channels (text/call/email/book) as one-tap pills, with a model-authorable framing line',\n icon: '\\u{1F4DE}',\n },\n },\n {\n id: 'adaptive-nav:tips',\n component: NavWidgetLitMountable,\n metadata: {\n name: 'Navigation Tips',\n description: 'Accordion of contextual navigation tips with per-item visibility',\n icon: '\\u{1F9ED}',\n },\n },\n ],\n\n /**\n * Extract notify watcher entries from tile config props.\n * The runtime evaluates these continuously (even with drawer closed)\n * and publishes nav:tip_revealed when triggerWhen transitions false \u2192 true.\n */\n notifyWatchers(props: Record<string, unknown>) {\n const actions = (props.actions ?? []) as NavTipAction[];\n return actions\n .filter((a) => a.notify && a.triggerWhen)\n .map((a) => ({\n id: `nav:${a.config.id}`,\n strategy: a.triggerWhen!,\n eventName: 'nav:tip_revealed',\n eventProps: {\n tipId: a.config.id,\n title: a.notify!.title,\n body: a.notify!.body,\n icon: a.notify!.icon,\n },\n }));\n },\n};\n\nexport default runtime;\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;AAqBA,SAAS,MAAM,YAAY,eAAe;AAC1C,SAAS,gBAAgB;AAIzB,IAAM,0BAA0B,oBAAI,IAAI,CAAC,QAAQ,QAAQ,SAAS,CAAC;AA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W;AAAA,MACX,UAAU;AAAA,QACR,MAAM;AAAA,QACN,aACE;AAAA,QACF,MAAM;AAAA,MACR;AAAA,IACF;AAAA,IACA;AAAA,MACE,IAAI;AAAA,MACJ,WAAW;AAAA,MACX,UAAU;AAAA,QACR,MAAM;AAAA,QACN,aAAa;AAAA,QACb,MAAM;AAAA,MACR;AAAA,IACF;AAAA,EACF;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOA,eAAe,OAAgC;AAC7C,UAAM,UAAW,MAAM,WAAW,CAAC;AACnC,WAAO,QACJ,OAAO,CAAC,MAAM,EAAE,UAAU,EAAE,WAAW,EACvC,IAAI,CAAC,OAAO;AAAA,MACX,IAAI,OAAO,EAAE,OAAO,EAAE;AAAA,MACtB,UAAU,EAAE;AAAA,MACZ,WAAW;AAAA,MACX,YAAY;AAAA,QACV,OAAO,EAAE,OAAO;AAAA,QAChB,OAAO,EAAE,OAAQ;AAAA,QACjB,MAAM,EAAE,OAAQ;AAAA,QAChB,MAAM,EAAE,OAAQ;AAAA,MAClB;AAAA,IACF,EAAE;AAAA,EACN;AACF;AAEA,IAAO,kBAAQ;",
|
|
6
|
-
"names": ["html", "LitElement", "nothing", "styleMap", "renderIcon", "LitElement", "styleMap", "html", "nothing", "runtime"]
|
|
7
|
-
}
|