@bitcobblers/wod-wiki-ui 0.56.2208 → 0.57.2213

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.
@@ -1,4 +1,4 @@
1
- export { A as AttachmentUrlResolver, B as ButtonAction, a as CursorFocusState, b as CustomCompletionSource, d as DefaultFrontmatterWidget, E as EditorDialect, e as EditorPresetOptions, f as EditorSection, g as EditorSectionSubtype, h as EditorSectionType, i as EmbedType, F as FrontmatterCatalogEntry, j as FrontmatterRefDiagnostic, k as FrontmatterReferenceProvider, l as FrontmatterReferenceRef, m as FrontmatterReferenceResolution, n as FrontmatterSuggestionCatalog, G as GeometryListener, o as INTERNAL_FRONTMATTER_KEYS, N as NavigationHook, p as NestedCompletionOptions, x as OverlayAction, y as QueryBlockPreviewOptions, z as RuntimePanelEntry, H as SectionIdentity, J as SectionRect, K as SectionState, W as WidgetConfig, L as WidgetProps, P as WidgetRegistry, U as activeCursorSection, V as addRuntimePanel, X as attachmentUrlFacet, Y as autocompleteTooltipTheme, Z as configureOverlayActions, _ as cursorFocusExtension, $ as customCompletionSources, a0 as dispatchAddRuntimePanel, a1 as dispatchExpandRuntimePanel, a2 as dispatchGutterHighlights, a3 as dispatchRemoveRuntimePanel, a4 as editingQuerySectionsField, a5 as editingWidgetsField, a6 as editorFocusField, a7 as editorFocusTracker, a8 as editorPreset, a9 as editorTheme, aa as embedPreviewDecorations, ab as expandRuntimePanel, ad as fenceCompletion, ae as findQueryBlockSection, af as findWorkoutErrors, ag as forceSectionParse, aj as frontmatterDebugMode, ak as frontmatterDetailed, al as frontmatterKeymap, am as frontmatterPreview, an as frontmatterPreviewField, ao as frontmatterReferenceIndex, ap as frontmatterSource, aq as frontmatterSuggestions, ar as frontmatterVisibility, as as getCursorFocusState, at as getOverlayActions, au as gutterHighlightsField, av as gutterUnified, aw as handleFenceAutoWrap, ax as handleSmartUrlPaste, ay as inlineButtonDecoration, az as insertMarkdownLinkCommand, aA as isEditorFocused, aB as isInternalFrontmatterKey, aC as isNavigableUrl, aD as lineIdsExtension, aE as linkOpen, aF as linkPreview, aG as markdownSyntaxHiding, aH as markdownTablePreview, aI as navigationFacet, aJ as nestedCompletion, aK as nestedCompletionOptions, aN as previewDecorations, aO as queryBlockPreview, aP as referenceIndexReload, aQ as registeredSectionWidgets, aR as removeRuntimePanel, aS as resolveCodeLanguage, aT as runtimePanelField, aU as saveBlockQuerySource, aV as sectionAtPos, aW as sectionField, aX as sectionGeometry, aY as sectionIdentity, aZ as sectionIdentityHistory, a_ as sectionMove, a$ as sectionRestore, b0 as sectionSaved, b1 as sessionQueryFence, b2 as sessionQueryInsert, b3 as sessionQueryWql, b4 as setEditorFocused, b5 as setFrontmatterDetailed, b6 as setFrontmatterSource, b7 as setGutterHighlights, b8 as setQuerySourceEditing, b9 as slashBlockCompletion, ba as smartIncrement, bb as toggleInlineMarkdown, bc as toggleWidgetEdit, bd as urlAtPos, be as widgetBlockPreview, bf as wodAutoWrap, bg as wodAutocompletion, bh as wodCompletionSource, bi as wodEditorKeymap, bj as wodLinter, bk as wodOverlayPanel, bl as workoutLintSource, bm as wrapInTimeFence } from '../index-CfljPEK3.cjs';
1
+ export { A as AttachmentUrlResolver, B as ButtonAction, a as CursorFocusState, b as CustomCompletionSource, d as DefaultFrontmatterWidget, E as EditorDialect, e as EditorPresetOptions, f as EditorSection, g as EditorSectionSubtype, h as EditorSectionType, i as EmbedType, F as FrontmatterCatalogEntry, j as FrontmatterRefDiagnostic, k as FrontmatterReferenceProvider, l as FrontmatterReferenceRef, m as FrontmatterReferenceResolution, n as FrontmatterSuggestionCatalog, G as GeometryListener, o as INTERNAL_FRONTMATTER_KEYS, N as NavigationHook, p as NestedCompletionOptions, x as OverlayAction, y as QueryBlockPreviewOptions, z as RuntimePanelEntry, H as SectionIdentity, J as SectionRect, K as SectionState, W as WidgetConfig, L as WidgetProps, P as WidgetRegistry, U as activeCursorSection, V as addRuntimePanel, X as affiliateTagFacet, Y as applyAmazonAffiliateTag, Z as attachmentUrlFacet, _ as autocompleteTooltipTheme, $ as configureOverlayActions, a0 as cursorFocusExtension, a1 as customCompletionSources, a2 as dispatchAddRuntimePanel, a3 as dispatchExpandRuntimePanel, a4 as dispatchGutterHighlights, a5 as dispatchRemoveRuntimePanel, a6 as editingQuerySectionsField, a7 as editingWidgetsField, a8 as editorFocusField, a9 as editorFocusTracker, aa as editorPreset, ab as editorTheme, ac as embedPreviewDecorations, ad as expandRuntimePanel, af as fenceCompletion, ag as findQueryBlockSection, ah as findWorkoutErrors, ai as forceSectionParse, al as frontmatterDebugMode, am as frontmatterDetailed, an as frontmatterKeymap, ao as frontmatterPreview, ap as frontmatterPreviewField, aq as frontmatterReferenceIndex, ar as frontmatterSource, as as frontmatterSuggestions, at as frontmatterVisibility, au as getCursorFocusState, av as getOverlayActions, aw as gutterHighlightsField, ax as gutterUnified, ay as handleFenceAutoWrap, az as handleSmartUrlPaste, aA as inlineButtonDecoration, aB as insertMarkdownLinkCommand, aC as isAmazonRetailHost, aD as isEditorFocused, aE as isInternalFrontmatterKey, aF as isNavigableUrl, aG as lineIdsExtension, aH as linkOpen, aI as linkPreview, aJ as markdownSyntaxHiding, aK as markdownTablePreview, aL as navigationFacet, aM as nestedCompletion, aN as nestedCompletionOptions, aQ as previewDecorations, aR as queryBlockPreview, aS as referenceIndexReload, aT as registeredSectionWidgets, aU as removeRuntimePanel, aV as resolveCodeLanguage, aW as runtimePanelField, aX as saveBlockQuerySource, aY as sectionAtPos, aZ as sectionField, a_ as sectionGeometry, a$ as sectionIdentity, b0 as sectionIdentityHistory, b1 as sectionMove, b2 as sectionRestore, b3 as sectionSaved, b4 as sessionQueryFence, b5 as sessionQueryInsert, b6 as sessionQueryWql, b7 as setEditorFocused, b8 as setFrontmatterDetailed, b9 as setFrontmatterSource, ba as setGutterHighlights, bb as setQuerySourceEditing, bc as slashBlockCompletion, bd as smartIncrement, be as toggleInlineMarkdown, bf as toggleWidgetEdit, bg as urlAtPos, bh as widgetBlockPreview, bi as wodAutoWrap, bj as wodAutocompletion, bk as wodCompletionSource, bl as wodEditorKeymap, bm as wodLinter, bn as wodOverlayPanel, bo as workoutLintSource, bp as wrapInTimeFence } from '../index-DUNwBTpa.cjs';
2
2
  export { blockContentId } from '@bitcobblers/wod-wiki-core';
3
3
  import '@codemirror/state';
4
4
  import '@codemirror/view';
@@ -1,4 +1,4 @@
1
- export { A as AttachmentUrlResolver, B as ButtonAction, a as CursorFocusState, b as CustomCompletionSource, d as DefaultFrontmatterWidget, E as EditorDialect, e as EditorPresetOptions, f as EditorSection, g as EditorSectionSubtype, h as EditorSectionType, i as EmbedType, F as FrontmatterCatalogEntry, j as FrontmatterRefDiagnostic, k as FrontmatterReferenceProvider, l as FrontmatterReferenceRef, m as FrontmatterReferenceResolution, n as FrontmatterSuggestionCatalog, G as GeometryListener, o as INTERNAL_FRONTMATTER_KEYS, N as NavigationHook, p as NestedCompletionOptions, x as OverlayAction, y as QueryBlockPreviewOptions, z as RuntimePanelEntry, H as SectionIdentity, J as SectionRect, K as SectionState, W as WidgetConfig, L as WidgetProps, P as WidgetRegistry, U as activeCursorSection, V as addRuntimePanel, X as attachmentUrlFacet, Y as autocompleteTooltipTheme, Z as configureOverlayActions, _ as cursorFocusExtension, $ as customCompletionSources, a0 as dispatchAddRuntimePanel, a1 as dispatchExpandRuntimePanel, a2 as dispatchGutterHighlights, a3 as dispatchRemoveRuntimePanel, a4 as editingQuerySectionsField, a5 as editingWidgetsField, a6 as editorFocusField, a7 as editorFocusTracker, a8 as editorPreset, a9 as editorTheme, aa as embedPreviewDecorations, ab as expandRuntimePanel, ad as fenceCompletion, ae as findQueryBlockSection, af as findWorkoutErrors, ag as forceSectionParse, aj as frontmatterDebugMode, ak as frontmatterDetailed, al as frontmatterKeymap, am as frontmatterPreview, an as frontmatterPreviewField, ao as frontmatterReferenceIndex, ap as frontmatterSource, aq as frontmatterSuggestions, ar as frontmatterVisibility, as as getCursorFocusState, at as getOverlayActions, au as gutterHighlightsField, av as gutterUnified, aw as handleFenceAutoWrap, ax as handleSmartUrlPaste, ay as inlineButtonDecoration, az as insertMarkdownLinkCommand, aA as isEditorFocused, aB as isInternalFrontmatterKey, aC as isNavigableUrl, aD as lineIdsExtension, aE as linkOpen, aF as linkPreview, aG as markdownSyntaxHiding, aH as markdownTablePreview, aI as navigationFacet, aJ as nestedCompletion, aK as nestedCompletionOptions, aN as previewDecorations, aO as queryBlockPreview, aP as referenceIndexReload, aQ as registeredSectionWidgets, aR as removeRuntimePanel, aS as resolveCodeLanguage, aT as runtimePanelField, aU as saveBlockQuerySource, aV as sectionAtPos, aW as sectionField, aX as sectionGeometry, aY as sectionIdentity, aZ as sectionIdentityHistory, a_ as sectionMove, a$ as sectionRestore, b0 as sectionSaved, b1 as sessionQueryFence, b2 as sessionQueryInsert, b3 as sessionQueryWql, b4 as setEditorFocused, b5 as setFrontmatterDetailed, b6 as setFrontmatterSource, b7 as setGutterHighlights, b8 as setQuerySourceEditing, b9 as slashBlockCompletion, ba as smartIncrement, bb as toggleInlineMarkdown, bc as toggleWidgetEdit, bd as urlAtPos, be as widgetBlockPreview, bf as wodAutoWrap, bg as wodAutocompletion, bh as wodCompletionSource, bi as wodEditorKeymap, bj as wodLinter, bk as wodOverlayPanel, bl as workoutLintSource, bm as wrapInTimeFence } from '../index-CfljPEK3.js';
1
+ export { A as AttachmentUrlResolver, B as ButtonAction, a as CursorFocusState, b as CustomCompletionSource, d as DefaultFrontmatterWidget, E as EditorDialect, e as EditorPresetOptions, f as EditorSection, g as EditorSectionSubtype, h as EditorSectionType, i as EmbedType, F as FrontmatterCatalogEntry, j as FrontmatterRefDiagnostic, k as FrontmatterReferenceProvider, l as FrontmatterReferenceRef, m as FrontmatterReferenceResolution, n as FrontmatterSuggestionCatalog, G as GeometryListener, o as INTERNAL_FRONTMATTER_KEYS, N as NavigationHook, p as NestedCompletionOptions, x as OverlayAction, y as QueryBlockPreviewOptions, z as RuntimePanelEntry, H as SectionIdentity, J as SectionRect, K as SectionState, W as WidgetConfig, L as WidgetProps, P as WidgetRegistry, U as activeCursorSection, V as addRuntimePanel, X as affiliateTagFacet, Y as applyAmazonAffiliateTag, Z as attachmentUrlFacet, _ as autocompleteTooltipTheme, $ as configureOverlayActions, a0 as cursorFocusExtension, a1 as customCompletionSources, a2 as dispatchAddRuntimePanel, a3 as dispatchExpandRuntimePanel, a4 as dispatchGutterHighlights, a5 as dispatchRemoveRuntimePanel, a6 as editingQuerySectionsField, a7 as editingWidgetsField, a8 as editorFocusField, a9 as editorFocusTracker, aa as editorPreset, ab as editorTheme, ac as embedPreviewDecorations, ad as expandRuntimePanel, af as fenceCompletion, ag as findQueryBlockSection, ah as findWorkoutErrors, ai as forceSectionParse, al as frontmatterDebugMode, am as frontmatterDetailed, an as frontmatterKeymap, ao as frontmatterPreview, ap as frontmatterPreviewField, aq as frontmatterReferenceIndex, ar as frontmatterSource, as as frontmatterSuggestions, at as frontmatterVisibility, au as getCursorFocusState, av as getOverlayActions, aw as gutterHighlightsField, ax as gutterUnified, ay as handleFenceAutoWrap, az as handleSmartUrlPaste, aA as inlineButtonDecoration, aB as insertMarkdownLinkCommand, aC as isAmazonRetailHost, aD as isEditorFocused, aE as isInternalFrontmatterKey, aF as isNavigableUrl, aG as lineIdsExtension, aH as linkOpen, aI as linkPreview, aJ as markdownSyntaxHiding, aK as markdownTablePreview, aL as navigationFacet, aM as nestedCompletion, aN as nestedCompletionOptions, aQ as previewDecorations, aR as queryBlockPreview, aS as referenceIndexReload, aT as registeredSectionWidgets, aU as removeRuntimePanel, aV as resolveCodeLanguage, aW as runtimePanelField, aX as saveBlockQuerySource, aY as sectionAtPos, aZ as sectionField, a_ as sectionGeometry, a$ as sectionIdentity, b0 as sectionIdentityHistory, b1 as sectionMove, b2 as sectionRestore, b3 as sectionSaved, b4 as sessionQueryFence, b5 as sessionQueryInsert, b6 as sessionQueryWql, b7 as setEditorFocused, b8 as setFrontmatterDetailed, b9 as setFrontmatterSource, ba as setGutterHighlights, bb as setQuerySourceEditing, bc as slashBlockCompletion, bd as smartIncrement, be as toggleInlineMarkdown, bf as toggleWidgetEdit, bg as urlAtPos, bh as widgetBlockPreview, bi as wodAutoWrap, bj as wodAutocompletion, bk as wodCompletionSource, bl as wodEditorKeymap, bm as wodLinter, bn as wodOverlayPanel, bo as workoutLintSource, bp as wrapInTimeFence } from '../index-DUNwBTpa.js';
2
2
  export { blockContentId } from '@bitcobblers/wod-wiki-core';
3
3
  import '@codemirror/state';
4
4
  import '@codemirror/view';
@@ -1,3 +1,3 @@
1
- export { DefaultFrontmatterWidget, INTERNAL_FRONTMATTER_KEYS, activeCursorSection, addRuntimePanel, attachmentUrlFacet, autocompleteTooltipTheme, blockContentId, configureOverlayActions, cursorFocusExtension, customCompletionSources, dispatchAddRuntimePanel, dispatchExpandRuntimePanel, dispatchGutterHighlights, dispatchRemoveRuntimePanel, editingQuerySectionsField, editingWidgetsField, editorFocusField, editorFocusTracker, editorPreset, editorTheme, embedPreviewDecorations, expandRuntimePanel, fenceCompletion, findQueryBlockSection, findWorkoutErrors, forceSectionParse, frontmatterDebugMode, frontmatterDetailed, frontmatterKeymap, frontmatterPreview, frontmatterPreviewField, frontmatterReferenceIndex, frontmatterSource, frontmatterSuggestions, frontmatterVisibility, getCursorFocusState, getOverlayActions, gutterHighlightsField, gutterUnified, handleFenceAutoWrap, handleSmartUrlPaste, inlineButtonDecoration, insertMarkdownLinkCommand, isEditorFocused, isInternalFrontmatterKey, isNavigableUrl, lineIdsExtension, linkOpen, linkPreview, markdownSyntaxHiding, markdownTablePreview, navigationFacet, nestedCompletion, nestedCompletionOptions, previewDecorations, queryBlockPreview, referenceIndexReload, registeredSectionWidgets, removeRuntimePanel, resolveCodeLanguage, runtimePanelField, saveBlockQuerySource, sectionAtPos, sectionField, sectionGeometry, sectionIdentity, sectionIdentityHistory, sectionMove, sectionRestore, sectionSaved, sessionQueryFence, sessionQueryInsert, sessionQueryWql, setEditorFocused, setFrontmatterDetailed, setFrontmatterSource, setGutterHighlights, setQuerySourceEditing, slashBlockCompletion, smartIncrement, toggleInlineMarkdown, toggleWidgetEdit, urlAtPos, widgetBlockPreview, wodAutoWrap, wodAutocompletion, wodCompletionSource, wodEditorKeymap, wodLinter, wodOverlayPanel, workoutLintSource, wrapInTimeFence } from '../chunk-3NJIIKMT.mjs';
1
+ export { DefaultFrontmatterWidget, INTERNAL_FRONTMATTER_KEYS, activeCursorSection, addRuntimePanel, affiliateTagFacet, applyAmazonAffiliateTag, attachmentUrlFacet, autocompleteTooltipTheme, blockContentId, configureOverlayActions, cursorFocusExtension, customCompletionSources, dispatchAddRuntimePanel, dispatchExpandRuntimePanel, dispatchGutterHighlights, dispatchRemoveRuntimePanel, editingQuerySectionsField, editingWidgetsField, editorFocusField, editorFocusTracker, editorPreset, editorTheme, embedPreviewDecorations, expandRuntimePanel, fenceCompletion, findQueryBlockSection, findWorkoutErrors, forceSectionParse, frontmatterDebugMode, frontmatterDetailed, frontmatterKeymap, frontmatterPreview, frontmatterPreviewField, frontmatterReferenceIndex, frontmatterSource, frontmatterSuggestions, frontmatterVisibility, getCursorFocusState, getOverlayActions, gutterHighlightsField, gutterUnified, handleFenceAutoWrap, handleSmartUrlPaste, inlineButtonDecoration, insertMarkdownLinkCommand, isAmazonRetailHost, isEditorFocused, isInternalFrontmatterKey, isNavigableUrl, lineIdsExtension, linkOpen, linkPreview, markdownSyntaxHiding, markdownTablePreview, navigationFacet, nestedCompletion, nestedCompletionOptions, previewDecorations, queryBlockPreview, referenceIndexReload, registeredSectionWidgets, removeRuntimePanel, resolveCodeLanguage, runtimePanelField, saveBlockQuerySource, sectionAtPos, sectionField, sectionGeometry, sectionIdentity, sectionIdentityHistory, sectionMove, sectionRestore, sectionSaved, sessionQueryFence, sessionQueryInsert, sessionQueryWql, setEditorFocused, setFrontmatterDetailed, setFrontmatterSource, setGutterHighlights, setQuerySourceEditing, slashBlockCompletion, smartIncrement, toggleInlineMarkdown, toggleWidgetEdit, urlAtPos, widgetBlockPreview, wodAutoWrap, wodAutocompletion, wodCompletionSource, wodEditorKeymap, wodLinter, wodOverlayPanel, workoutLintSource, wrapInTimeFence } from '../chunk-W23ZR6NQ.mjs';
2
2
  //# sourceMappingURL=index.mjs.map
3
3
  //# sourceMappingURL=index.mjs.map
@@ -44,6 +44,27 @@ declare function isNavigableUrl(url: string): boolean;
44
44
  declare function urlAtPos(view: EditorView, pos: number): string | null;
45
45
  declare const linkOpen: Extension;
46
46
 
47
+ /**
48
+ * Optional Amazon Associates tag injected into outbound Amazon retail links
49
+ * rendered by editor link pills, tables, and Ctrl+Click navigation.
50
+ * When unset or empty, link URLs are left untouched.
51
+ */
52
+ declare const affiliateTagFacet: Facet<string | null | undefined, string | null>;
53
+ /**
54
+ * Returns `true` for Amazon retail hostnames (e.g. `amazon.com`,
55
+ * `www.amazon.co.uk`, `smile.amazon.de`), excluding shortlink domains
56
+ * (`amzn.to`, `a.co`) and non-retail subdomains (`aws.amazon.com`).
57
+ */
58
+ declare function isAmazonRetailHost(hostname: string): boolean;
59
+ /**
60
+ * Injects or replaces the Amazon Associates `tag` query parameter on outbound
61
+ * Amazon retail URLs when `associateTag` is non-empty.
62
+ *
63
+ * Shortlinks (e.g. `amzn.to`) and non-Amazon URLs are returned unchanged.
64
+ * Never mutates the underlying Markdown source.
65
+ */
66
+ declare function applyAmazonAffiliateTag(url: string, associateTag?: string | null): string;
67
+
47
68
  declare function findWorkoutErrors(content: string, offsetInDoc: number): Diagnostic[];
48
69
  declare function workoutLintSource(view: EditorView): Diagnostic[];
49
70
  declare const wodLinter: _codemirror_state.Extension;
@@ -551,4 +572,4 @@ interface EditorPresetOptions {
551
572
  }
552
573
  declare function editorPreset(optionsOrDialect?: string | EditorPresetOptions): Extension[];
553
574
 
554
- export { customCompletionSources as $, type AttachmentUrlResolver as A, type ButtonAction as B, type CategorizedMetrics as C, DEFAULT_OUTPUT_FILTERS as D, type EditorDialect as E, type FrontmatterCatalogEntry as F, type GeometryListener as G, type SectionIdentity as H, type InlineMetricEditPayload as I, type SectionRect as J, type SectionState as K, type WidgetProps as L, MetricBadge as M, type NavigationHook as N, type OutputFilterInput as O, type WidgetRegistry as P, type QueryExecutor as Q, type RowPrHighlight as R, type SessionTableSortSpec as S, TONE_CLASS as T, activeCursorSection as U, addRuntimePanel as V, type WidgetConfig as W, attachmentUrlFacet as X, autocompleteTooltipTheme as Y, configureOverlayActions as Z, cursorFocusExtension as _, type CursorFocusState as a, sectionRestore as a$, dispatchAddRuntimePanel as a0, dispatchExpandRuntimePanel as a1, dispatchGutterHighlights as a2, dispatchRemoveRuntimePanel as a3, editingQuerySectionsField as a4, editingWidgetsField as a5, editorFocusField as a6, editorFocusTracker as a7, editorPreset as a8, editorTheme as a9, isEditorFocused as aA, isInternalFrontmatterKey as aB, isNavigableUrl as aC, lineIdsExtension as aD, linkOpen as aE, linkPreview as aF, markdownSyntaxHiding as aG, markdownTablePreview as aH, navigationFacet as aI, nestedCompletion as aJ, nestedCompletionOptions as aK, normalizeOutputFilter as aL, presentBadges as aM, previewDecorations as aN, queryBlockPreview as aO, referenceIndexReload as aP, registeredSectionWidgets as aQ, removeRuntimePanel as aR, resolveCodeLanguage as aS, runtimePanelField as aT, saveBlockQuerySource as aU, sectionAtPos as aV, sectionField as aW, sectionGeometry as aX, sectionIdentity as aY, sectionIdentityHistory as aZ, sectionMove as a_, embedPreviewDecorations as aa, expandRuntimePanel as ab, extractMetricsByCategory as ac, fenceCompletion as ad, findQueryBlockSection as ae, findWorkoutErrors as af, forceSectionParse as ag, formatClockTime as ah, formatMMSS as ai, frontmatterDebugMode as aj, frontmatterDetailed as ak, frontmatterKeymap as al, frontmatterPreview as am, frontmatterPreviewField as an, frontmatterReferenceIndex as ao, frontmatterSource as ap, frontmatterSuggestions as aq, frontmatterVisibility as ar, getCursorFocusState as as, getOverlayActions as at, gutterHighlightsField as au, gutterUnified as av, handleFenceAutoWrap as aw, handleSmartUrlPaste as ax, inlineButtonDecoration as ay, insertMarkdownLinkCommand as az, type CustomCompletionSource as b, sectionSaved as b0, sessionQueryFence as b1, sessionQueryInsert as b2, sessionQueryWql as b3, setEditorFocused as b4, setFrontmatterDetailed as b5, setFrontmatterSource as b6, setGutterHighlights as b7, setQuerySourceEditing as b8, slashBlockCompletion as b9, smartIncrement as ba, toggleInlineMarkdown as bb, toggleWidgetEdit as bc, urlAtPos as bd, widgetBlockPreview as be, wodAutoWrap as bf, wodAutocompletion as bg, wodCompletionSource as bh, wodEditorKeymap as bi, wodLinter as bj, wodOverlayPanel as bk, workoutLintSource as bl, wrapInTimeFence as bm, DEFAULT_PRIMARY_FILTER as c, DefaultFrontmatterWidget as d, type EditorPresetOptions as e, type EditorSection as f, type EditorSectionSubtype as g, type EditorSectionType as h, type EmbedType as i, type FrontmatterRefDiagnostic as j, type FrontmatterReferenceProvider as k, type FrontmatterReferenceRef as l, type FrontmatterReferenceResolution as m, type FrontmatterSuggestionCatalog as n, INTERNAL_FRONTMATTER_KEYS as o, type NestedCompletionOptions as p, OUTPUT_TYPE_CLASS as q, OUTPUT_TYPE_DOT as r, OutputFilterPills as s, type OutputFilterPreset as t, type OutputStatementRow as u, OutputStatementsTable as v, type OutputStatementsTableProps as w, type OverlayAction as x, type QueryBlockPreviewOptions as y, type RuntimePanelEntry as z };
575
+ export { configureOverlayActions as $, type AttachmentUrlResolver as A, type ButtonAction as B, type CategorizedMetrics as C, DEFAULT_OUTPUT_FILTERS as D, type EditorDialect as E, type FrontmatterCatalogEntry as F, type GeometryListener as G, type SectionIdentity as H, type InlineMetricEditPayload as I, type SectionRect as J, type SectionState as K, type WidgetProps as L, MetricBadge as M, type NavigationHook as N, type OutputFilterInput as O, type WidgetRegistry as P, type QueryExecutor as Q, type RowPrHighlight as R, type SessionTableSortSpec as S, TONE_CLASS as T, activeCursorSection as U, addRuntimePanel as V, type WidgetConfig as W, affiliateTagFacet as X, applyAmazonAffiliateTag as Y, attachmentUrlFacet as Z, autocompleteTooltipTheme as _, type CursorFocusState as a, sectionIdentity as a$, cursorFocusExtension as a0, customCompletionSources as a1, dispatchAddRuntimePanel as a2, dispatchExpandRuntimePanel as a3, dispatchGutterHighlights as a4, dispatchRemoveRuntimePanel as a5, editingQuerySectionsField as a6, editingWidgetsField as a7, editorFocusField as a8, editorFocusTracker as a9, inlineButtonDecoration as aA, insertMarkdownLinkCommand as aB, isAmazonRetailHost as aC, isEditorFocused as aD, isInternalFrontmatterKey as aE, isNavigableUrl as aF, lineIdsExtension as aG, linkOpen as aH, linkPreview as aI, markdownSyntaxHiding as aJ, markdownTablePreview as aK, navigationFacet as aL, nestedCompletion as aM, nestedCompletionOptions as aN, normalizeOutputFilter as aO, presentBadges as aP, previewDecorations as aQ, queryBlockPreview as aR, referenceIndexReload as aS, registeredSectionWidgets as aT, removeRuntimePanel as aU, resolveCodeLanguage as aV, runtimePanelField as aW, saveBlockQuerySource as aX, sectionAtPos as aY, sectionField as aZ, sectionGeometry as a_, editorPreset as aa, editorTheme as ab, embedPreviewDecorations as ac, expandRuntimePanel as ad, extractMetricsByCategory as ae, fenceCompletion as af, findQueryBlockSection as ag, findWorkoutErrors as ah, forceSectionParse as ai, formatClockTime as aj, formatMMSS as ak, frontmatterDebugMode as al, frontmatterDetailed as am, frontmatterKeymap as an, frontmatterPreview as ao, frontmatterPreviewField as ap, frontmatterReferenceIndex as aq, frontmatterSource as ar, frontmatterSuggestions as as, frontmatterVisibility as at, getCursorFocusState as au, getOverlayActions as av, gutterHighlightsField as aw, gutterUnified as ax, handleFenceAutoWrap as ay, handleSmartUrlPaste as az, type CustomCompletionSource as b, sectionIdentityHistory as b0, sectionMove as b1, sectionRestore as b2, sectionSaved as b3, sessionQueryFence as b4, sessionQueryInsert as b5, sessionQueryWql as b6, setEditorFocused as b7, setFrontmatterDetailed as b8, setFrontmatterSource as b9, setGutterHighlights as ba, setQuerySourceEditing as bb, slashBlockCompletion as bc, smartIncrement as bd, toggleInlineMarkdown as be, toggleWidgetEdit as bf, urlAtPos as bg, widgetBlockPreview as bh, wodAutoWrap as bi, wodAutocompletion as bj, wodCompletionSource as bk, wodEditorKeymap as bl, wodLinter as bm, wodOverlayPanel as bn, workoutLintSource as bo, wrapInTimeFence as bp, DEFAULT_PRIMARY_FILTER as c, DefaultFrontmatterWidget as d, type EditorPresetOptions as e, type EditorSection as f, type EditorSectionSubtype as g, type EditorSectionType as h, type EmbedType as i, type FrontmatterRefDiagnostic as j, type FrontmatterReferenceProvider as k, type FrontmatterReferenceRef as l, type FrontmatterReferenceResolution as m, type FrontmatterSuggestionCatalog as n, INTERNAL_FRONTMATTER_KEYS as o, type NestedCompletionOptions as p, OUTPUT_TYPE_CLASS as q, OUTPUT_TYPE_DOT as r, OutputFilterPills as s, type OutputFilterPreset as t, type OutputStatementRow as u, OutputStatementsTable as v, type OutputStatementsTableProps as w, type OverlayAction as x, type QueryBlockPreviewOptions as y, type RuntimePanelEntry as z };
@@ -44,6 +44,27 @@ declare function isNavigableUrl(url: string): boolean;
44
44
  declare function urlAtPos(view: EditorView, pos: number): string | null;
45
45
  declare const linkOpen: Extension;
46
46
 
47
+ /**
48
+ * Optional Amazon Associates tag injected into outbound Amazon retail links
49
+ * rendered by editor link pills, tables, and Ctrl+Click navigation.
50
+ * When unset or empty, link URLs are left untouched.
51
+ */
52
+ declare const affiliateTagFacet: Facet<string | null | undefined, string | null>;
53
+ /**
54
+ * Returns `true` for Amazon retail hostnames (e.g. `amazon.com`,
55
+ * `www.amazon.co.uk`, `smile.amazon.de`), excluding shortlink domains
56
+ * (`amzn.to`, `a.co`) and non-retail subdomains (`aws.amazon.com`).
57
+ */
58
+ declare function isAmazonRetailHost(hostname: string): boolean;
59
+ /**
60
+ * Injects or replaces the Amazon Associates `tag` query parameter on outbound
61
+ * Amazon retail URLs when `associateTag` is non-empty.
62
+ *
63
+ * Shortlinks (e.g. `amzn.to`) and non-Amazon URLs are returned unchanged.
64
+ * Never mutates the underlying Markdown source.
65
+ */
66
+ declare function applyAmazonAffiliateTag(url: string, associateTag?: string | null): string;
67
+
47
68
  declare function findWorkoutErrors(content: string, offsetInDoc: number): Diagnostic[];
48
69
  declare function workoutLintSource(view: EditorView): Diagnostic[];
49
70
  declare const wodLinter: _codemirror_state.Extension;
@@ -551,4 +572,4 @@ interface EditorPresetOptions {
551
572
  }
552
573
  declare function editorPreset(optionsOrDialect?: string | EditorPresetOptions): Extension[];
553
574
 
554
- export { customCompletionSources as $, type AttachmentUrlResolver as A, type ButtonAction as B, type CategorizedMetrics as C, DEFAULT_OUTPUT_FILTERS as D, type EditorDialect as E, type FrontmatterCatalogEntry as F, type GeometryListener as G, type SectionIdentity as H, type InlineMetricEditPayload as I, type SectionRect as J, type SectionState as K, type WidgetProps as L, MetricBadge as M, type NavigationHook as N, type OutputFilterInput as O, type WidgetRegistry as P, type QueryExecutor as Q, type RowPrHighlight as R, type SessionTableSortSpec as S, TONE_CLASS as T, activeCursorSection as U, addRuntimePanel as V, type WidgetConfig as W, attachmentUrlFacet as X, autocompleteTooltipTheme as Y, configureOverlayActions as Z, cursorFocusExtension as _, type CursorFocusState as a, sectionRestore as a$, dispatchAddRuntimePanel as a0, dispatchExpandRuntimePanel as a1, dispatchGutterHighlights as a2, dispatchRemoveRuntimePanel as a3, editingQuerySectionsField as a4, editingWidgetsField as a5, editorFocusField as a6, editorFocusTracker as a7, editorPreset as a8, editorTheme as a9, isEditorFocused as aA, isInternalFrontmatterKey as aB, isNavigableUrl as aC, lineIdsExtension as aD, linkOpen as aE, linkPreview as aF, markdownSyntaxHiding as aG, markdownTablePreview as aH, navigationFacet as aI, nestedCompletion as aJ, nestedCompletionOptions as aK, normalizeOutputFilter as aL, presentBadges as aM, previewDecorations as aN, queryBlockPreview as aO, referenceIndexReload as aP, registeredSectionWidgets as aQ, removeRuntimePanel as aR, resolveCodeLanguage as aS, runtimePanelField as aT, saveBlockQuerySource as aU, sectionAtPos as aV, sectionField as aW, sectionGeometry as aX, sectionIdentity as aY, sectionIdentityHistory as aZ, sectionMove as a_, embedPreviewDecorations as aa, expandRuntimePanel as ab, extractMetricsByCategory as ac, fenceCompletion as ad, findQueryBlockSection as ae, findWorkoutErrors as af, forceSectionParse as ag, formatClockTime as ah, formatMMSS as ai, frontmatterDebugMode as aj, frontmatterDetailed as ak, frontmatterKeymap as al, frontmatterPreview as am, frontmatterPreviewField as an, frontmatterReferenceIndex as ao, frontmatterSource as ap, frontmatterSuggestions as aq, frontmatterVisibility as ar, getCursorFocusState as as, getOverlayActions as at, gutterHighlightsField as au, gutterUnified as av, handleFenceAutoWrap as aw, handleSmartUrlPaste as ax, inlineButtonDecoration as ay, insertMarkdownLinkCommand as az, type CustomCompletionSource as b, sectionSaved as b0, sessionQueryFence as b1, sessionQueryInsert as b2, sessionQueryWql as b3, setEditorFocused as b4, setFrontmatterDetailed as b5, setFrontmatterSource as b6, setGutterHighlights as b7, setQuerySourceEditing as b8, slashBlockCompletion as b9, smartIncrement as ba, toggleInlineMarkdown as bb, toggleWidgetEdit as bc, urlAtPos as bd, widgetBlockPreview as be, wodAutoWrap as bf, wodAutocompletion as bg, wodCompletionSource as bh, wodEditorKeymap as bi, wodLinter as bj, wodOverlayPanel as bk, workoutLintSource as bl, wrapInTimeFence as bm, DEFAULT_PRIMARY_FILTER as c, DefaultFrontmatterWidget as d, type EditorPresetOptions as e, type EditorSection as f, type EditorSectionSubtype as g, type EditorSectionType as h, type EmbedType as i, type FrontmatterRefDiagnostic as j, type FrontmatterReferenceProvider as k, type FrontmatterReferenceRef as l, type FrontmatterReferenceResolution as m, type FrontmatterSuggestionCatalog as n, INTERNAL_FRONTMATTER_KEYS as o, type NestedCompletionOptions as p, OUTPUT_TYPE_CLASS as q, OUTPUT_TYPE_DOT as r, OutputFilterPills as s, type OutputFilterPreset as t, type OutputStatementRow as u, OutputStatementsTable as v, type OutputStatementsTableProps as w, type OverlayAction as x, type QueryBlockPreviewOptions as y, type RuntimePanelEntry as z };
575
+ export { configureOverlayActions as $, type AttachmentUrlResolver as A, type ButtonAction as B, type CategorizedMetrics as C, DEFAULT_OUTPUT_FILTERS as D, type EditorDialect as E, type FrontmatterCatalogEntry as F, type GeometryListener as G, type SectionIdentity as H, type InlineMetricEditPayload as I, type SectionRect as J, type SectionState as K, type WidgetProps as L, MetricBadge as M, type NavigationHook as N, type OutputFilterInput as O, type WidgetRegistry as P, type QueryExecutor as Q, type RowPrHighlight as R, type SessionTableSortSpec as S, TONE_CLASS as T, activeCursorSection as U, addRuntimePanel as V, type WidgetConfig as W, affiliateTagFacet as X, applyAmazonAffiliateTag as Y, attachmentUrlFacet as Z, autocompleteTooltipTheme as _, type CursorFocusState as a, sectionIdentity as a$, cursorFocusExtension as a0, customCompletionSources as a1, dispatchAddRuntimePanel as a2, dispatchExpandRuntimePanel as a3, dispatchGutterHighlights as a4, dispatchRemoveRuntimePanel as a5, editingQuerySectionsField as a6, editingWidgetsField as a7, editorFocusField as a8, editorFocusTracker as a9, inlineButtonDecoration as aA, insertMarkdownLinkCommand as aB, isAmazonRetailHost as aC, isEditorFocused as aD, isInternalFrontmatterKey as aE, isNavigableUrl as aF, lineIdsExtension as aG, linkOpen as aH, linkPreview as aI, markdownSyntaxHiding as aJ, markdownTablePreview as aK, navigationFacet as aL, nestedCompletion as aM, nestedCompletionOptions as aN, normalizeOutputFilter as aO, presentBadges as aP, previewDecorations as aQ, queryBlockPreview as aR, referenceIndexReload as aS, registeredSectionWidgets as aT, removeRuntimePanel as aU, resolveCodeLanguage as aV, runtimePanelField as aW, saveBlockQuerySource as aX, sectionAtPos as aY, sectionField as aZ, sectionGeometry as a_, editorPreset as aa, editorTheme as ab, embedPreviewDecorations as ac, expandRuntimePanel as ad, extractMetricsByCategory as ae, fenceCompletion as af, findQueryBlockSection as ag, findWorkoutErrors as ah, forceSectionParse as ai, formatClockTime as aj, formatMMSS as ak, frontmatterDebugMode as al, frontmatterDetailed as am, frontmatterKeymap as an, frontmatterPreview as ao, frontmatterPreviewField as ap, frontmatterReferenceIndex as aq, frontmatterSource as ar, frontmatterSuggestions as as, frontmatterVisibility as at, getCursorFocusState as au, getOverlayActions as av, gutterHighlightsField as aw, gutterUnified as ax, handleFenceAutoWrap as ay, handleSmartUrlPaste as az, type CustomCompletionSource as b, sectionIdentityHistory as b0, sectionMove as b1, sectionRestore as b2, sectionSaved as b3, sessionQueryFence as b4, sessionQueryInsert as b5, sessionQueryWql as b6, setEditorFocused as b7, setFrontmatterDetailed as b8, setFrontmatterSource as b9, setGutterHighlights as ba, setQuerySourceEditing as bb, slashBlockCompletion as bc, smartIncrement as bd, toggleInlineMarkdown as be, toggleWidgetEdit as bf, urlAtPos as bg, widgetBlockPreview as bh, wodAutoWrap as bi, wodAutocompletion as bj, wodCompletionSource as bk, wodEditorKeymap as bl, wodLinter as bm, wodOverlayPanel as bn, workoutLintSource as bo, wrapInTimeFence as bp, DEFAULT_PRIMARY_FILTER as c, DefaultFrontmatterWidget as d, type EditorPresetOptions as e, type EditorSection as f, type EditorSectionSubtype as g, type EditorSectionType as h, type EmbedType as i, type FrontmatterRefDiagnostic as j, type FrontmatterReferenceProvider as k, type FrontmatterReferenceRef as l, type FrontmatterReferenceResolution as m, type FrontmatterSuggestionCatalog as n, INTERNAL_FRONTMATTER_KEYS as o, type NestedCompletionOptions as p, OUTPUT_TYPE_CLASS as q, OUTPUT_TYPE_DOT as r, OutputFilterPills as s, type OutputFilterPreset as t, type OutputStatementRow as u, OutputStatementsTable as v, type OutputStatementsTableProps as w, type OverlayAction as x, type QueryBlockPreviewOptions as y, type RuntimePanelEntry as z };
package/dist/index.cjs CHANGED
@@ -490,9 +490,6 @@ function WqlBars({ result, unit: unitProp }) {
490
490
  ] }) });
491
491
  }
492
492
  var MAX_ROWS = 12;
493
- function formatValue(v, unit) {
494
- return `${v.toLocaleString()}${unit ? ` ${unit}` : ""}`;
495
- }
496
493
  function WqlTable({ result, unit: unitProp }) {
497
494
  const shape = useChartShape(result);
498
495
  const unit = result.series[0]?.unit ?? unitProp ?? "";
@@ -500,14 +497,14 @@ function WqlTable({ result, unit: unitProp }) {
500
497
  if (shape.kind === "scalar") {
501
498
  return {
502
499
  head: ["Metric", "Value"],
503
- body: [[result.series[0]?.label ?? "scalar", formatValue(shape.value, unit)]],
500
+ body: [[result.series[0]?.label ?? "scalar", formatTimeseriesTooltipValue(shape.value, unit)]],
504
501
  more: 0
505
502
  };
506
503
  }
507
504
  if (shape.kind === "bars") {
508
505
  const all = result.series.map((s) => [
509
506
  s.label,
510
- formatValue(s.points[0]?.value ?? 0, unit)
507
+ formatTimeseriesTooltipValue(s.points[0]?.value ?? 0, unit)
511
508
  ]);
512
509
  return {
513
510
  head: ["Series", "Value"],
@@ -528,7 +525,7 @@ function WqlTable({ result, unit: unitProp }) {
528
525
  formatTimestamp(ts),
529
526
  ...result.series.map((s) => {
530
527
  const v = seriesMap.get(s.label)?.get(ts);
531
- return v !== void 0 ? formatValue(v, unit) : "\u2014";
528
+ return v !== void 0 ? formatTimeseriesTooltipValue(v, unit) : "\u2014";
532
529
  })
533
530
  ]);
534
531
  return { head, body, more: Math.max(0, timestamps.length - MAX_ROWS) };
@@ -7159,7 +7156,7 @@ var lineIdsExtension = view.ViewPlugin.fromClass(
7159
7156
  if (!label) label = timestamp;
7160
7157
  }
7161
7158
  id = label.toLowerCase().replace(/[^\w]+/g, "-");
7162
- } else if (/^```(time|log)/.test(trimmed)) {
7159
+ } else if (/^```(time|wod|whiteboard|log)/i.test(trimmed)) {
7163
7160
  id = `workout-line-${i}`;
7164
7161
  }
7165
7162
  if (id && line.from >= view$1.viewport.from && line.to <= view$1.viewport.to) {
@@ -7179,6 +7176,33 @@ var lineIdsExtension = view.ViewPlugin.fromClass(
7179
7176
  decorations: (v) => v.decorations
7180
7177
  }
7181
7178
  );
7179
+ var affiliateTagFacet = state.Facet.define({
7180
+ combine(values2) {
7181
+ for (let i = values2.length - 1; i >= 0; i--) {
7182
+ const trimmed = values2[i]?.trim();
7183
+ if (trimmed) return trimmed;
7184
+ }
7185
+ return null;
7186
+ }
7187
+ });
7188
+ var AMAZON_RETAIL_HOST_RE = /^(?:www\.|smile\.|m\.)?amazon\.[a-z]{2,3}(?:\.[a-z]{2})?$/i;
7189
+ function isAmazonRetailHost(hostname) {
7190
+ return AMAZON_RETAIL_HOST_RE.test(hostname);
7191
+ }
7192
+ function applyAmazonAffiliateTag(url, associateTag) {
7193
+ const tag = associateTag?.trim();
7194
+ if (!tag || !/^https?:\/\//i.test(url)) return url;
7195
+ try {
7196
+ const parsed = new URL(url);
7197
+ if (!isAmazonRetailHost(parsed.hostname)) return url;
7198
+ parsed.searchParams.set("tag", tag);
7199
+ return parsed.toString();
7200
+ } catch {
7201
+ return url;
7202
+ }
7203
+ }
7204
+
7205
+ // src/extensions/link-open.ts
7182
7206
  var navigationFacet = state.Facet.define({
7183
7207
  combine(values2) {
7184
7208
  return values2.length > 0 ? values2[values2.length - 1] : null;
@@ -7269,12 +7293,13 @@ var ctrlClickPlugin = view.ViewPlugin.fromClass(
7269
7293
  if (!url) return;
7270
7294
  e.preventDefault();
7271
7295
  e.stopPropagation();
7296
+ const resolvedUrl = applyAmazonAffiliateTag(url, view.state.facet(affiliateTagFacet));
7272
7297
  const navHook = view.state.facet(navigationFacet);
7273
7298
  if (navHook) {
7274
- navHook(url, view);
7299
+ navHook(resolvedUrl, view);
7275
7300
  } else if (typeof window !== "undefined") {
7276
- const isInternal = url.startsWith("/") || url.startsWith("#");
7277
- window.open(url, isInternal ? "_self" : "_blank", isInternal ? void 0 : "noopener,noreferrer");
7301
+ const isInternal = resolvedUrl.startsWith("/") || resolvedUrl.startsWith("#");
7302
+ window.open(resolvedUrl, isInternal ? "_self" : "_blank", isInternal ? void 0 : "noopener,noreferrer");
7278
7303
  }
7279
7304
  };
7280
7305
  view.dom.addEventListener("mousedown", this.handler, true);
@@ -10831,11 +10856,12 @@ function appendFormattedCellContent(container, rawText, view) {
10831
10856
  } else if (match[2] !== void 0 && match[3] !== void 0) {
10832
10857
  const label = match[2];
10833
10858
  const url = match[3];
10859
+ const isExternal = /^https?:\/\//i.test(url);
10860
+ const resolvedUrl = isExternal ? applyAmazonAffiliateTag(url, view.state.facet(affiliateTagFacet)) : url;
10834
10861
  const a = document.createElement("a");
10835
- a.href = url;
10862
+ a.href = resolvedUrl;
10836
10863
  a.textContent = label;
10837
10864
  a.className = "cm-table-cell-link underline underline-offset-2";
10838
- const isExternal = /^https?:\/\//i.test(url);
10839
10865
  if (isExternal) {
10840
10866
  a.target = "_blank";
10841
10867
  a.rel = "noopener noreferrer";
@@ -11293,7 +11319,8 @@ function openLinkEditPopover(anchorEl, view, match) {
11293
11319
  openBtn.addEventListener("click", (e) => {
11294
11320
  e.preventDefault();
11295
11321
  e.stopPropagation();
11296
- const targetUrl = urlInput.value.trim() || match.url;
11322
+ const rawUrl = urlInput.value.trim() || match.url;
11323
+ const targetUrl = applyAmazonAffiliateTag(rawUrl, view.state.facet(affiliateTagFacet));
11297
11324
  closeActiveLinkPopover();
11298
11325
  const navHook = view.state.facet(navigationFacet);
11299
11326
  if (!isExternalHttpUrl(targetUrl) && navHook) {
@@ -11380,21 +11407,23 @@ function openLinkEditPopover(anchorEl, view, match) {
11380
11407
  labelInput.select();
11381
11408
  }
11382
11409
  var LinkPillWidget = class extends view.WidgetType {
11383
- constructor(label, url, from, to, readOnly) {
11410
+ constructor(label, url, from, to, readOnly, affiliateTag) {
11384
11411
  super();
11385
11412
  this.label = label;
11386
11413
  this.url = url;
11387
11414
  this.from = from;
11388
11415
  this.to = to;
11389
11416
  this.readOnly = readOnly;
11417
+ this.affiliateTag = affiliateTag;
11390
11418
  }
11391
11419
  label;
11392
11420
  url;
11393
11421
  from;
11394
11422
  to;
11395
11423
  readOnly;
11424
+ affiliateTag;
11396
11425
  eq(other) {
11397
- return this.label === other.label && this.url === other.url && this.from === other.from && this.to === other.to && this.readOnly === other.readOnly;
11426
+ return this.label === other.label && this.url === other.url && this.from === other.from && this.to === other.to && this.readOnly === other.readOnly && this.affiliateTag === other.affiliateTag;
11398
11427
  }
11399
11428
  toDOM(view) {
11400
11429
  const isExternal = isExternalHttpUrl(this.url);
@@ -11421,9 +11450,10 @@ var LinkPillWidget = class extends view.WidgetType {
11421
11450
  });
11422
11451
  }
11423
11452
  pill.appendChild(label);
11453
+ const resolvedUrl = isExternal ? applyAmazonAffiliateTag(this.url, this.affiliateTag) : this.url;
11424
11454
  const open = document.createElement("a");
11425
11455
  open.className = "cm-link-pill-open";
11426
- open.href = this.url;
11456
+ open.href = resolvedUrl;
11427
11457
  if (isExternal) {
11428
11458
  open.target = "_blank";
11429
11459
  open.rel = "noopener noreferrer";
@@ -11435,11 +11465,11 @@ var LinkPillWidget = class extends view.WidgetType {
11435
11465
  if (navHook) {
11436
11466
  e.preventDefault();
11437
11467
  e.stopPropagation();
11438
- navHook(this.url, view);
11468
+ navHook(resolvedUrl, view);
11439
11469
  }
11440
11470
  });
11441
11471
  }
11442
- open.title = this.url;
11472
+ open.title = resolvedUrl;
11443
11473
  open.appendChild(createLinkArrowIcon(isExternal));
11444
11474
  pill.appendChild(open);
11445
11475
  return pill;
@@ -11573,7 +11603,8 @@ function buildLinkDecos(state$1) {
11573
11603
  link.url,
11574
11604
  link.from,
11575
11605
  link.to,
11576
- state$1.readOnly
11606
+ state$1.readOnly,
11607
+ state$1.facet(affiliateTagFacet)
11577
11608
  )
11578
11609
  })
11579
11610
  );
@@ -18270,13 +18301,13 @@ function editorPreset(optionsOrDialect = "markdown") {
18270
18301
  }
18271
18302
 
18272
18303
  // src/version.ts
18273
- var VERSION = "0.56.2208";
18274
- var GIT_SHA = "49c50a2";
18275
- var BUILD_TIME = "2026-11-12T17:10:33.737Z";
18304
+ var VERSION = "0.57.2213";
18305
+ var GIT_SHA = "567cd1e";
18306
+ var BUILD_TIME = "2026-11-12T22:26:23.724Z";
18276
18307
  var SEMVER = {
18277
- version: "0.56.2208",
18278
- gitSha: "49c50a2",
18279
- buildTime: "2026-11-12T17:10:33.737Z"
18308
+ version: "0.57.2213",
18309
+ gitSha: "567cd1e",
18310
+ buildTime: "2026-11-12T22:26:23.724Z"
18280
18311
  };
18281
18312
 
18282
18313
  Object.defineProperty(exports, "CONTENT_GROUPING_DIMENSIONS", {
@@ -18354,6 +18385,8 @@ exports.WqlTimeseries = WqlTimeseries;
18354
18385
  exports.ZoneDistribution = ZoneDistribution;
18355
18386
  exports.activeCursorSection = activeCursorSection;
18356
18387
  exports.addRuntimePanel = addRuntimePanel;
18388
+ exports.affiliateTagFacet = affiliateTagFacet;
18389
+ exports.applyAmazonAffiliateTag = applyAmazonAffiliateTag;
18357
18390
  exports.attachmentUrlFacet = attachmentUrlFacet;
18358
18391
  exports.autocompleteTooltipTheme = autocompleteTooltipTheme;
18359
18392
  exports.bindTokenParamIntoWql = bindTokenParamIntoWql;
@@ -18417,6 +18450,7 @@ exports.hashCode = hashCode;
18417
18450
  exports.inlineButtonDecoration = inlineButtonDecoration;
18418
18451
  exports.insertMarkdownLinkCommand = insertMarkdownLinkCommand;
18419
18452
  exports.invalidateSuggestions = invalidateSuggestions;
18453
+ exports.isAmazonRetailHost = isAmazonRetailHost;
18420
18454
  exports.isEditorFocused = isEditorFocused;
18421
18455
  exports.isInternalFrontmatterKey = isInternalFrontmatterKey;
18422
18456
  exports.isNavigableUrl = isNavigableUrl;