@ethlete/core 5.0.0-next.13 → 5.0.0-next.15

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/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # @ethlete/core
2
2
 
3
+ ## 5.0.0-next.15
4
+
5
+ ### Patch Changes
6
+
7
+ - [#2995](https://github.com/ethlete-io/ethdk/pull/2995) [`05da5f2`](https://github.com/ethlete-io/ethdk/commit/05da5f2c9ac78907f8be5003690332eea1f99ff8) Thanks [@github-actions](https://github.com/apps/github-actions)! - Fix `injectRoute`, `injectUrl` and the `injectRouterState` based signals (`injectPathParams`, `injectQueryParams`, `injectRouteData`, etc.) returning the previous route when read synchronously inside a component constructor during navigation. They now read the already committed router state instead of waiting for the `NavigationEnd` event.
8
+
9
+ ## 5.0.0-next.14
10
+
11
+ ### Minor Changes
12
+
13
+ - [`7dcbb8e`](https://github.com/ethlete-io/ethdk/commit/7dcbb8e3f3823728bc370fb89d1a89ee831e779b) Thanks [@TomTomB](https://github.com/TomTomB)! - Add utils for converting between markdown and html
14
+
3
15
  ## 5.0.0-next.13
4
16
 
5
17
  ### Patch Changes
@@ -2326,21 +2326,29 @@ const injectIsRouterInitialized = memoizeSignal(() => {
2326
2326
  */
2327
2327
  const injectUrl = memoizeSignal(() => {
2328
2328
  const event = injectRouterEvent();
2329
- return linkedSignal({
2330
- source: event,
2331
- computation: (curr, prev) => {
2332
- if (curr instanceof NavigationEnd) {
2333
- return curr.urlAfterRedirects;
2334
- }
2335
- else if (curr instanceof NavigationSkipped) {
2336
- return curr.url;
2337
- }
2338
- else if (prev?.value) {
2339
- return prev.value;
2340
- }
2341
- return createInitialRoute();
2342
- },
2343
- }).asReadonly();
2329
+ const router = inject(Router);
2330
+ // Captured once for reads that happen before the router has committed any
2331
+ // navigation (SSR / initial load), where `router.url` isn't reliable yet.
2332
+ const initialRoute = createInitialRoute();
2333
+ return computed(() => {
2334
+ // We depend on `event` and `currentNavigation` only to get re-evaluated
2335
+ // around each navigation, but we read the *committed* url straight from the
2336
+ // router. The router commits `currentUrlTree` before it activates components,
2337
+ // so `router.url` is already correct inside a child component's constructor —
2338
+ // unlike the NavigationEnd event, which only reaches this signal *after*
2339
+ // activation.
2340
+ event();
2341
+ const currentNavigation = router.currentNavigation();
2342
+ // Before the very first navigation the router url isn't populated yet (e.g.
2343
+ // SSR / a deep link read before the initial navigation runs), so fall back
2344
+ // to the browser location captured at startup. `navigated` flips only at
2345
+ // NavigationEnd, so we also check for an in-flight navigation to stay correct
2346
+ // during the initial navigation's component construction.
2347
+ if (router.navigated || currentNavigation !== null) {
2348
+ return router.url;
2349
+ }
2350
+ return initialRoute;
2351
+ });
2344
2352
  });
2345
2353
  /**
2346
2354
  * Inject the current route
@@ -2375,19 +2383,15 @@ const createRouterState = (router) => {
2375
2383
  const injectRouterState = memoizeSignal(() => {
2376
2384
  const event = injectRouterEvent();
2377
2385
  const router = inject(Router);
2378
- const routerState = signal(createRouterState(router), ...(ngDevMode ? [{ debugName: "routerState" }] : /* istanbul ignore next */ []));
2379
- effect(() => {
2380
- const e = event();
2381
- untracked(() => {
2382
- if (e instanceof NavigationEnd && e.id === -1) {
2383
- return;
2384
- }
2385
- else {
2386
- routerState.set(createRouterState(router));
2387
- }
2388
- });
2389
- });
2390
- return computed(() => routerState(), { equal });
2386
+ // We only depend on `event` to get re-evaluated on every router event, but we
2387
+ // read the *committed* snapshot straight from the router. The router commits
2388
+ // `routerState` before it activates components (and emits ActivationStart
2389
+ // before NavigationEnd), so this is already correct inside a child component's
2390
+ // constructor — unlike an effect, which only flushes after construction.
2391
+ return computed(() => {
2392
+ event();
2393
+ return createRouterState(router);
2394
+ }, { equal });
2391
2395
  });
2392
2396
  /** Inject a signal containing the current route fragment (the part after the # inside the url if present) */
2393
2397
  const injectFragment = (config) => {
@@ -2563,6 +2567,201 @@ const createLogger = (config) => {
2563
2567
  };
2564
2568
  };
2565
2569
 
2570
+ const escapeHtml = (str) => str.replace(/&/g, '&amp;').replace(/</g, '&lt;').replace(/>/g, '&gt;').replace(/"/g, '&quot;');
2571
+ const unescapeHtml = (str) => str
2572
+ .replace(/&amp;/g, '&')
2573
+ .replace(/&lt;/g, '<')
2574
+ .replace(/&gt;/g, '>')
2575
+ .replace(/&quot;/g, '"')
2576
+ .replace(/&#39;/g, "'")
2577
+ .replace(/&nbsp;/g, ' ');
2578
+ const stripTags = (str) => str.replace(/<[^>]+>/g, '');
2579
+ const parseTableRow = (line) => line
2580
+ .split('|')
2581
+ .slice(1, -1)
2582
+ .map((cell) => cell.trim());
2583
+ const isTableSeparatorLine = (line) => /^\|?(\s*:?-+:?\s*\|)+\s*$/.test(line);
2584
+ const makePlaceholder = (kind, idx) => `\u{E000}${kind}${idx}\u{E001}`;
2585
+ const placeholderRe = (kind) => new RegExp(`\u{E000}${kind}(\\d+)\u{E001}`, 'gu');
2586
+ const isPlaceholder = (kind, str) => new RegExp(`^\u{E000}${kind}\\d+\u{E001}$`, 'u').test(str);
2587
+ const processInline = (text) => {
2588
+ const inlineCodes = [];
2589
+ text = text.replace(/`([^`]+)`/g, (_, code) => {
2590
+ const idx = inlineCodes.push(`<code>${escapeHtml(code)}</code>`) - 1;
2591
+ return makePlaceholder('IC', idx);
2592
+ });
2593
+ // Bold + italic — *** before ** before *
2594
+ text = text.replace(/\*\*\*(.+?)\*\*\*/g, '<strong><em>$1</em></strong>');
2595
+ text = text.replace(/\*\*(.+?)\*\*/g, '<strong>$1</strong>');
2596
+ text = text.replace(/__(.+?)__/g, '<strong>$1</strong>');
2597
+ text = text.replace(/\*(.+?)\*/g, '<em>$1</em>');
2598
+ text = text.replace(/~~(.+?)~~/g, '<del>$1</del>');
2599
+ // Images before links (order matters)
2600
+ text = text.replace(/!\[([^\]]*)\]\(([^)]+)\)/g, '<img src="$2" alt="$1">');
2601
+ text = text.replace(/\[([^\]]+)\]\(([^)]+)\)/g, '<a href="$2">$1</a>');
2602
+ return text.replace(placeholderRe('IC'), (_, i) => inlineCodes[+i] ?? '');
2603
+ };
2604
+ /**
2605
+ * Converts a markdown string to HTML.
2606
+ * Covers headings, bold, italic, strikethrough, inline code, fenced code blocks,
2607
+ * links, images, block quotes, unordered/ordered lists, tables, horizontal rules, and paragraphs.
2608
+ */
2609
+ const markdownToHtml = (markdown) => {
2610
+ if (!markdown)
2611
+ return '';
2612
+ let text = markdown.replace(/\r\n/g, '\n').replace(/\r/g, '\n');
2613
+ // Extract fenced code blocks before any other processing
2614
+ const codeBlocks = [];
2615
+ text = text.replace(/```(\w*)\n([\s\S]*?)```/g, (_, lang, code) => {
2616
+ const langAttr = lang ? ` class="language-${lang}"` : '';
2617
+ const idx = codeBlocks.push(`<pre><code${langAttr}>${escapeHtml(code.trim())}</code></pre>`) - 1;
2618
+ return makePlaceholder('CODE', idx);
2619
+ });
2620
+ const html = text
2621
+ .split(/\n\n+/)
2622
+ .map((block) => {
2623
+ const trimmed = block.trim();
2624
+ if (!trimmed)
2625
+ return '';
2626
+ if (isPlaceholder('CODE', trimmed))
2627
+ return trimmed;
2628
+ // Heading
2629
+ const headingMatch = trimmed.match(/^(#{1,6})\s+(.+)$/);
2630
+ if (headingMatch?.[1] && headingMatch?.[2]) {
2631
+ const level = headingMatch[1].length;
2632
+ return `<h${level}>${processInline(headingMatch[2].trim())}</h${level}>`;
2633
+ }
2634
+ // Horizontal rule
2635
+ if (/^(---|\*\*\*|___)\s*$/.test(trimmed))
2636
+ return '<hr>';
2637
+ // Table (GFM)
2638
+ const tableLines = trimmed.split('\n');
2639
+ if (tableLines.length >= 2 && /\|/.test(tableLines[0] ?? '') && isTableSeparatorLine(tableLines[1] ?? '')) {
2640
+ const headers = parseTableRow(tableLines[0] ?? '');
2641
+ const thead = `<thead><tr>${headers.map((h) => `<th>${processInline(h)}</th>`).join('')}</tr></thead>`;
2642
+ const bodyRows = tableLines.slice(2);
2643
+ const tbody = bodyRows.length > 0
2644
+ ? `<tbody>${bodyRows
2645
+ .map((row) => `<tr>${parseTableRow(row)
2646
+ .map((cell) => `<td>${processInline(cell)}</td>`)
2647
+ .join('')}</tr>`)
2648
+ .join('')}</tbody>`
2649
+ : '';
2650
+ return `<table>${thead}${tbody}</table>`;
2651
+ }
2652
+ // Blockquote
2653
+ if (/^> /.test(trimmed)) {
2654
+ const content = trimmed
2655
+ .split('\n')
2656
+ .map((l) => l.replace(/^>\s?/, ''))
2657
+ .join('<br>');
2658
+ return `<blockquote>${processInline(content)}</blockquote>`;
2659
+ }
2660
+ // Unordered list
2661
+ if (/^[-*+]\s/.test(trimmed)) {
2662
+ const items = trimmed
2663
+ .split('\n')
2664
+ .filter((l) => /^[-*+]\s/.test(l))
2665
+ .map((l) => `<li>${processInline(l.replace(/^[-*+]\s+/, '').trim())}</li>`)
2666
+ .join('');
2667
+ return `<ul>${items}</ul>`;
2668
+ }
2669
+ // Ordered list
2670
+ if (/^\d+\.\s/.test(trimmed)) {
2671
+ const items = trimmed
2672
+ .split('\n')
2673
+ .filter((l) => /^\d+\.\s/.test(l))
2674
+ .map((l) => `<li>${processInline(l.replace(/^\d+\.\s+/, '').trim())}</li>`)
2675
+ .join('');
2676
+ return `<ol>${items}</ol>`;
2677
+ }
2678
+ // Paragraph — single newlines within a block become <br>
2679
+ return `<p>${trimmed
2680
+ .split('\n')
2681
+ .map((l) => processInline(l))
2682
+ .join('<br>')}</p>`;
2683
+ })
2684
+ .filter(Boolean)
2685
+ .join('\n');
2686
+ return html.replace(placeholderRe('CODE'), (_, i) => codeBlocks[+i] ?? '');
2687
+ };
2688
+ /**
2689
+ * Converts an HTML string to markdown.
2690
+ * Covers headings, bold, italic, strikethrough, inline code, fenced code blocks,
2691
+ * links, images, block quotes, unordered/ordered lists, tables, horizontal rules, and paragraphs.
2692
+ */
2693
+ const htmlToMarkdown = (html) => {
2694
+ if (!html)
2695
+ return '';
2696
+ let md = html;
2697
+ // Code blocks — process before inline code
2698
+ md = md.replace(/<pre[^>]*><code[^>]*class="language-([^"]+)"[^>]*>([\s\S]*?)<\/code><\/pre>/gi, (_, lang, code) => `\n\`\`\`${lang}\n${unescapeHtml(code.trim())}\n\`\`\`\n`);
2699
+ md = md.replace(/<pre[^>]*><code[^>]*>([\s\S]*?)<\/code><\/pre>/gi, (_, code) => `\n\`\`\`\n${unescapeHtml(code.trim())}\n\`\`\`\n`);
2700
+ md = md.replace(/<pre[^>]*>([\s\S]*?)<\/pre>/gi, (_, code) => `\n\`\`\`\n${unescapeHtml(code.trim())}\n\`\`\`\n`);
2701
+ // Headings
2702
+ for (let i = 6; i >= 1; i--) {
2703
+ md = md.replace(new RegExp(`<h${i}[^>]*>([\\s\\S]*?)<\\/h${i}>`, 'gi'), (_, content) => `\n${'#'.repeat(i)} ${stripTags(content).trim()}\n`);
2704
+ }
2705
+ // Bold + italic (combined before individual)
2706
+ md = md.replace(/<strong[^>]*><em[^>]*>([\s\S]*?)<\/em><\/strong>/gi, '***$1***');
2707
+ md = md.replace(/<em[^>]*><strong[^>]*>([\s\S]*?)<\/strong><\/em>/gi, '***$1***');
2708
+ md = md.replace(/<(strong|b)[^>]*>([\s\S]*?)<\/\1>/gi, '**$2**');
2709
+ md = md.replace(/<(em|i)[^>]*>([\s\S]*?)<\/\1>/gi, '*$2*');
2710
+ md = md.replace(/<(del|s|strike)[^>]*>([\s\S]*?)<\/\1>/gi, '~~$2~~');
2711
+ // Inline code
2712
+ md = md.replace(/<code[^>]*>([\s\S]*?)<\/code>/gi, (_, code) => `\`${unescapeHtml(code)}\``);
2713
+ // Links and images
2714
+ md = md.replace(/<a[^>]+href="([^"]*)"[^>]*>([\s\S]*?)<\/a>/gi, '[$2]($1)');
2715
+ md = md.replace(/<img[^>]+src="([^"]*)"[^>]*alt="([^"]*)"[^>]*\/?>/gi, '![$2]($1)');
2716
+ md = md.replace(/<img[^>]+alt="([^"]*)"[^>]*src="([^"]*)"[^>]*\/?>/gi, '![$1]($2)');
2717
+ md = md.replace(/<img[^>]+src="([^"]*)"[^>]*\/?>/gi, '![]($1)');
2718
+ // Block quotes
2719
+ md = md.replace(/<blockquote[^>]*>([\s\S]*?)<\/blockquote>/gi, (_, content) => {
2720
+ return (stripTags(content)
2721
+ .trim()
2722
+ .split('\n')
2723
+ .map((line) => `> ${line.trim()}`)
2724
+ .join('\n') + '\n');
2725
+ });
2726
+ // Lists
2727
+ md = md.replace(/<ul[^>]*>([\s\S]*?)<\/ul>/gi, (_, content) => {
2728
+ return ('\n' +
2729
+ content.replace(/<li[^>]*>([\s\S]*?)<\/li>/gi, (_m, item) => `- ${stripTags(item).trim()}\n`));
2730
+ });
2731
+ md = md.replace(/<ol[^>]*>([\s\S]*?)<\/ol>/gi, (_, content) => {
2732
+ let n = 1;
2733
+ return ('\n' +
2734
+ content.replace(/<li[^>]*>([\s\S]*?)<\/li>/gi, (_m, item) => `${n++}. ${stripTags(item).trim()}\n`));
2735
+ });
2736
+ // Tables
2737
+ md = md.replace(/<table[^>]*>([\s\S]*?)<\/table>/gi, (_, tableContent) => {
2738
+ const extractCells = (row) => [...row.matchAll(/<t[hd][^>]*>([\s\S]*?)<\/t[hd]>/gi)].map((m) => stripTags(m[1] ?? '').trim());
2739
+ const theadMatch = tableContent.match(/<thead[^>]*>([\s\S]*?)<\/thead>/i);
2740
+ const firstTrMatch = tableContent.match(/<tr[^>]*>([\s\S]*?)<\/tr>/i);
2741
+ const headerCells = theadMatch
2742
+ ? extractCells(theadMatch[1] ?? '')
2743
+ : firstTrMatch
2744
+ ? extractCells(firstTrMatch[1] ?? '')
2745
+ : [];
2746
+ if (headerCells.length === 0)
2747
+ return '';
2748
+ const separator = headerCells.map(() => '---').join(' | ');
2749
+ const bodySource = theadMatch
2750
+ ? tableContent.replace(theadMatch[0], '')
2751
+ : tableContent.replace(firstTrMatch?.[0] ?? '', '');
2752
+ const bodyRows = [...bodySource.matchAll(/<tr[^>]*>([\s\S]*?)<\/tr>/gi)].map((m) => extractCells(m[1] ?? '').join(' | '));
2753
+ const lines = [`| ${headerCells.join(' | ')} |`, `| ${separator} |`, ...bodyRows.map((r) => `| ${r} |`)];
2754
+ return `\n${lines.join('\n')}\n`;
2755
+ });
2756
+ // Block elements
2757
+ md = md.replace(/<p[^>]*>([\s\S]*?)<\/p>/gi, (_, content) => `\n${stripTags(content).trim()}\n`);
2758
+ md = md.replace(/<br\s*\/?>/gi, '\n');
2759
+ md = md.replace(/<hr\s*\/?>/gi, '\n---\n');
2760
+ return unescapeHtml(stripTags(md))
2761
+ .replace(/\n{3,}/g, '\n\n')
2762
+ .trim();
2763
+ };
2764
+
2566
2765
  const clamp = (value, min = 0, max = 100) => {
2567
2766
  return Math.max(min, Math.min(max, value));
2568
2767
  };
@@ -4750,6 +4949,18 @@ const normalizeMatchType = (matchType) => {
4750
4949
  }
4751
4950
  };
4752
4951
 
4952
+ class HtmlToMarkdownPipe {
4953
+ constructor() {
4954
+ this.transform = htmlToMarkdown;
4955
+ }
4956
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.13", ngImport: i0, type: HtmlToMarkdownPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
4957
+ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "21.2.13", ngImport: i0, type: HtmlToMarkdownPipe, isStandalone: true, name: "htmlToMarkdown" }); }
4958
+ }
4959
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.13", ngImport: i0, type: HtmlToMarkdownPipe, decorators: [{
4960
+ type: Pipe,
4961
+ args: [{ name: 'htmlToMarkdown' }]
4962
+ }] });
4963
+
4753
4964
  class InferMimeTypePipe {
4754
4965
  constructor() {
4755
4966
  this.transform = inferMimeType;
@@ -4963,6 +5174,18 @@ const inferMimeType = (srcset) => {
4963
5174
  return null;
4964
5175
  };
4965
5176
 
5177
+ class MarkdownToHtmlPipe {
5178
+ constructor() {
5179
+ this.transform = markdownToHtml;
5180
+ }
5181
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.13", ngImport: i0, type: MarkdownToHtmlPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
5182
+ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "21.2.13", ngImport: i0, type: MarkdownToHtmlPipe, isStandalone: true, name: "markdownToHtml" }); }
5183
+ }
5184
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.13", ngImport: i0, type: MarkdownToHtmlPipe, decorators: [{
5185
+ type: Pipe,
5186
+ args: [{ name: 'markdownToHtml' }]
5187
+ }] });
5188
+
4966
5189
  class ToArrayPipe {
4967
5190
  constructor() {
4968
5191
  this.transform = toArray;
@@ -6199,13 +6422,24 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.13", ngImpo
6199
6422
 
6200
6423
  class ColorInteractiveStylesComponent {
6201
6424
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.13", ngImport: i0, type: ColorInteractiveStylesComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
6202
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.13", type: ColorInteractiveStylesComponent, isStandalone: true, selector: "et-color-interactive-styles", ngImport: i0, template: '', isInline: true, styles: [":where(.et-color-interactive:hover:not(:has(.et-color-interactive-exclude:hover))),:where(.et-color-interactive-container:hover) :where(.et-color-interactive){--et-theme-color-primary-rgb: var(--et-color-primary-hover, var(--et-color-primary));--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var(--et-color-on-primary-hover, var(--et-color-on-primary));--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-hover, var(--et-color-primary-ink, var(--et-color-primary-hover, var(--et-color-primary))) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}:where(.et-color-interactive:focus-visible){--et-theme-color-primary-rgb: var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary)));--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var( --et-color-on-primary-focus, var(--et-color-on-primary-hover, var(--et-color-on-primary)) );--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-focus, var( --et-color-primary-ink-hover, var(--et-color-primary-ink, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary)))) ) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}:where(.et-color-interactive:active:not(:has(.et-color-interactive-exclude:hover))),:where(.et-color-interactive-container:active) :where(.et-color-interactive){--et-theme-color-primary-rgb: var( --et-color-primary-active, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary))) );--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var( --et-color-on-primary-active, var(--et-color-on-primary-focus, var(--et-color-on-primary-hover, var(--et-color-on-primary))) );--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-active, var( --et-color-primary-ink-focus, var( --et-color-primary-ink-hover, var( --et-color-primary-ink, var( --et-color-primary-active, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary))) ) ) ) ) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}:where(.et-color-interactive--has-focus:has(:focus-visible)){--et-theme-color-primary-rgb: var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary)));--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var( --et-color-on-primary-focus, var(--et-color-on-primary-hover, var(--et-color-on-primary)) );--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-focus, var( --et-color-primary-ink-hover, var(--et-color-primary-ink, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary)))) ) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}:where(.et-color-interactive[disabled]),:where(.et-color-interactive[aria-disabled=true]){--et-theme-color-primary-rgb: var( --et-color-primary-disabled, var( --et-color-primary-active, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary))) ) );--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var( --et-color-on-primary-disabled, var( --et-color-on-primary-active, var(--et-color-on-primary-focus, var(--et-color-on-primary-hover, var(--et-color-on-primary))) ) );--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-disabled, var( --et-color-primary-ink-active, var( --et-color-primary-ink-focus, var( --et-color-primary-ink-hover, var( --et-color-primary-ink, var( --et-color-primary-disabled, var( --et-color-primary-active, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary))) ) ) ) ) ) ) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
6425
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.13", type: ColorInteractiveStylesComponent, isStandalone: true, selector: "et-color-interactive-styles", ngImport: i0, template: '', isInline: true, styles: [":where(.et-color-interactive){--et-theme-color-primary-rgb: var(--et-color-primary);--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var(--et-color-on-primary);--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var(--et-color-primary-ink, var(--et-color-primary));--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}:where(.et-color-interactive:hover:not(:has(.et-color-interactive-exclude:hover))),:where(.et-color-interactive-container:hover) :where(.et-color-interactive){--et-theme-color-primary-rgb: var(--et-color-primary-hover, var(--et-color-primary));--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var(--et-color-on-primary-hover, var(--et-color-on-primary));--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-hover, var(--et-color-primary-ink, var(--et-color-primary-hover, var(--et-color-primary))) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}:where(.et-color-interactive:focus-visible){--et-theme-color-primary-rgb: var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary)));--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var( --et-color-on-primary-focus, var(--et-color-on-primary-hover, var(--et-color-on-primary)) );--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-focus, var( --et-color-primary-ink-hover, var(--et-color-primary-ink, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary)))) ) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}:where(.et-color-interactive:active:not(:has(.et-color-interactive-exclude:hover))),:where(.et-color-interactive-container:active) :where(.et-color-interactive){--et-theme-color-primary-rgb: var( --et-color-primary-active, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary))) );--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var( --et-color-on-primary-active, var(--et-color-on-primary-focus, var(--et-color-on-primary-hover, var(--et-color-on-primary))) );--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-active, var( --et-color-primary-ink-focus, var( --et-color-primary-ink-hover, var( --et-color-primary-ink, var( --et-color-primary-active, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary))) ) ) ) ) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}:where(.et-color-interactive--has-focus:has(:focus-visible)){--et-theme-color-primary-rgb: var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary)));--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var( --et-color-on-primary-focus, var(--et-color-on-primary-hover, var(--et-color-on-primary)) );--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-focus, var( --et-color-primary-ink-hover, var(--et-color-primary-ink, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary)))) ) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}:where(.et-color-interactive[disabled]),:where(.et-color-interactive[aria-disabled=true]){--et-theme-color-primary-rgb: var( --et-color-primary-disabled, var( --et-color-primary-active, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary))) ) );--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var( --et-color-on-primary-disabled, var( --et-color-on-primary-active, var(--et-color-on-primary-focus, var(--et-color-on-primary-hover, var(--et-color-on-primary))) ) );--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-disabled, var( --et-color-primary-ink-active, var( --et-color-primary-ink-focus, var( --et-color-primary-ink-hover, var( --et-color-primary-ink, var( --et-color-primary-disabled, var( --et-color-primary-active, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary))) ) ) ) ) ) ) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
6203
6426
  }
6204
6427
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.13", ngImport: i0, type: ColorInteractiveStylesComponent, decorators: [{
6205
6428
  type: Component,
6206
- args: [{ selector: 'et-color-interactive-styles', template: '', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, styles: [":where(.et-color-interactive:hover:not(:has(.et-color-interactive-exclude:hover))),:where(.et-color-interactive-container:hover) :where(.et-color-interactive){--et-theme-color-primary-rgb: var(--et-color-primary-hover, var(--et-color-primary));--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var(--et-color-on-primary-hover, var(--et-color-on-primary));--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-hover, var(--et-color-primary-ink, var(--et-color-primary-hover, var(--et-color-primary))) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}:where(.et-color-interactive:focus-visible){--et-theme-color-primary-rgb: var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary)));--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var( --et-color-on-primary-focus, var(--et-color-on-primary-hover, var(--et-color-on-primary)) );--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-focus, var( --et-color-primary-ink-hover, var(--et-color-primary-ink, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary)))) ) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}:where(.et-color-interactive:active:not(:has(.et-color-interactive-exclude:hover))),:where(.et-color-interactive-container:active) :where(.et-color-interactive){--et-theme-color-primary-rgb: var( --et-color-primary-active, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary))) );--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var( --et-color-on-primary-active, var(--et-color-on-primary-focus, var(--et-color-on-primary-hover, var(--et-color-on-primary))) );--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-active, var( --et-color-primary-ink-focus, var( --et-color-primary-ink-hover, var( --et-color-primary-ink, var( --et-color-primary-active, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary))) ) ) ) ) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}:where(.et-color-interactive--has-focus:has(:focus-visible)){--et-theme-color-primary-rgb: var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary)));--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var( --et-color-on-primary-focus, var(--et-color-on-primary-hover, var(--et-color-on-primary)) );--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-focus, var( --et-color-primary-ink-hover, var(--et-color-primary-ink, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary)))) ) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}:where(.et-color-interactive[disabled]),:where(.et-color-interactive[aria-disabled=true]){--et-theme-color-primary-rgb: var( --et-color-primary-disabled, var( --et-color-primary-active, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary))) ) );--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var( --et-color-on-primary-disabled, var( --et-color-on-primary-active, var(--et-color-on-primary-focus, var(--et-color-on-primary-hover, var(--et-color-on-primary))) ) );--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-disabled, var( --et-color-primary-ink-active, var( --et-color-primary-ink-focus, var( --et-color-primary-ink-hover, var( --et-color-primary-ink, var( --et-color-primary-disabled, var( --et-color-primary-active, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary))) ) ) ) ) ) ) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}\n"] }]
6429
+ args: [{ selector: 'et-color-interactive-styles', template: '', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, styles: [":where(.et-color-interactive){--et-theme-color-primary-rgb: var(--et-color-primary);--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var(--et-color-on-primary);--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var(--et-color-primary-ink, var(--et-color-primary));--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}:where(.et-color-interactive:hover:not(:has(.et-color-interactive-exclude:hover))),:where(.et-color-interactive-container:hover) :where(.et-color-interactive){--et-theme-color-primary-rgb: var(--et-color-primary-hover, var(--et-color-primary));--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var(--et-color-on-primary-hover, var(--et-color-on-primary));--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-hover, var(--et-color-primary-ink, var(--et-color-primary-hover, var(--et-color-primary))) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}:where(.et-color-interactive:focus-visible){--et-theme-color-primary-rgb: var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary)));--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var( --et-color-on-primary-focus, var(--et-color-on-primary-hover, var(--et-color-on-primary)) );--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-focus, var( --et-color-primary-ink-hover, var(--et-color-primary-ink, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary)))) ) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}:where(.et-color-interactive:active:not(:has(.et-color-interactive-exclude:hover))),:where(.et-color-interactive-container:active) :where(.et-color-interactive){--et-theme-color-primary-rgb: var( --et-color-primary-active, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary))) );--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var( --et-color-on-primary-active, var(--et-color-on-primary-focus, var(--et-color-on-primary-hover, var(--et-color-on-primary))) );--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-active, var( --et-color-primary-ink-focus, var( --et-color-primary-ink-hover, var( --et-color-primary-ink, var( --et-color-primary-active, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary))) ) ) ) ) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}:where(.et-color-interactive--has-focus:has(:focus-visible)){--et-theme-color-primary-rgb: var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary)));--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var( --et-color-on-primary-focus, var(--et-color-on-primary-hover, var(--et-color-on-primary)) );--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-focus, var( --et-color-primary-ink-hover, var(--et-color-primary-ink, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary)))) ) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}:where(.et-color-interactive[disabled]),:where(.et-color-interactive[aria-disabled=true]){--et-theme-color-primary-rgb: var( --et-color-primary-disabled, var( --et-color-primary-active, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary))) ) );--et-theme-color-primary-solid: rgb(var(--et-theme-color-primary-rgb));--et-theme-color-on-primary-rgb: var( --et-color-on-primary-disabled, var( --et-color-on-primary-active, var(--et-color-on-primary-focus, var(--et-color-on-primary-hover, var(--et-color-on-primary))) ) );--et-theme-color-on-primary-solid: rgb(var(--et-theme-color-on-primary-rgb));--et-theme-color-ink-rgb: var( --et-color-primary-ink-disabled, var( --et-color-primary-ink-active, var( --et-color-primary-ink-focus, var( --et-color-primary-ink-hover, var( --et-color-primary-ink, var( --et-color-primary-disabled, var( --et-color-primary-active, var(--et-color-primary-focus, var(--et-color-primary-hover, var(--et-color-primary))) ) ) ) ) ) ) );--et-theme-color-ink-solid: rgb(var(--et-theme-color-ink-rgb))}\n"] }]
6207
6430
  }] });
6208
6431
 
6432
+ /**
6433
+ * Cascades hover/active-driven color DOWN to descendants explicitly marked with
6434
+ * `ColorInteractiveDirective` — this element does not color itself. Use it when a wrapper should
6435
+ * expand a nested control's hit/visual area (e.g. clicking a checkbox's label should light up the
6436
+ * checkbox itself), never to give a wrapper its own interactive coloring — that's
6437
+ * `ColorInteractiveDirective`.
6438
+ *
6439
+ * Does nothing unless at least one descendant carries `ColorInteractiveDirective` — check for
6440
+ * that before adding this. It was mistakenly added to a component with no such descendant once
6441
+ * already, where it did nothing but was confusing to read.
6442
+ */
6209
6443
  class ColorInteractiveContainerDirective {
6210
6444
  constructor() {
6211
6445
  this.styleManager = injectStyleManager();
@@ -6224,6 +6458,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.13", ngImpo
6224
6458
  }]
6225
6459
  }], ctorParameters: () => [] });
6226
6460
 
6461
+ /**
6462
+ * Marks a descendant as NOT counting toward an ancestor's `ColorInteractiveDirective`
6463
+ * `:hover`/`:active` reaction (via the `:has()` guard in color-interactive-styles.component.css).
6464
+ * Use it for content that's incidentally inside an interactive ancestor but isn't part of what
6465
+ * makes that ancestor interactive — e.g. a hint/error block sitting inside a form field's frame.
6466
+ *
6467
+ * This only suppresses the ancestor's OWN reaction to hovering/pressing the excluded element — it
6468
+ * has no effect on custom-property inheritance into descendants past the excluded element. If
6469
+ * what you actually need is "stop my own cosmetic styling from reacting to a parent's unrelated
6470
+ * interaction," this is the wrong tool; that's the class of bug `ColorInteractiveHasFocusDirective`
6471
+ * used to have (see its own comment).
6472
+ */
6227
6473
  class ColorInteractiveExcludeDirective {
6228
6474
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.13", ngImport: i0, type: ColorInteractiveExcludeDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
6229
6475
  static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.13", type: ColorInteractiveExcludeDirective, isStandalone: true, selector: "[etColorInteractiveExclude]", host: { classAttribute: "et-color-interactive-exclude" }, ngImport: i0 }); }
@@ -6238,24 +6484,52 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.13", ngImpo
6238
6484
  }]
6239
6485
  }] });
6240
6486
 
6487
+ /**
6488
+ * Tints `--et-theme-color-primary-*` etc. only when a descendant genuinely has `:focus-visible`
6489
+ * (`:has(:focus-visible)`) — never on mouse `:hover`/`:active`. Use this for a wrapper (like a
6490
+ * form field's frame) that should show the theme color while its control is focused, but must
6491
+ * NOT react to incidental mouse interaction with unrelated nested widgets (a toolbar button, a
6492
+ * rendered link) that happen to live inside the same wrapper.
6493
+ *
6494
+ * Deliberately does NOT also carry `ColorInteractiveDirective`'s `et-color-interactive` class:
6495
+ * that class's plain `:hover`/`:active` rules locally override the same (inheriting)
6496
+ * `--et-theme-color-primary-rgb`, so anything bubbling up from ANYWHERE in the subtree would
6497
+ * leak the transient hover/press color into every descendant reading it for unrelated cosmetics —
6498
+ * exactly the bug this directive's only consumer (form-field) shipped once, before the two
6499
+ * behaviors were split apart. If you need the plain hover/active reaction too, add
6500
+ * `ColorInteractiveDirective` explicitly and make sure you actually want both.
6501
+ */
6241
6502
  class ColorInteractiveHasFocusDirective {
6242
6503
  constructor() {
6243
6504
  this.styleManager = injectStyleManager();
6244
6505
  this.styleManager.mount(ColorInteractiveStylesComponent);
6245
6506
  }
6246
6507
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.13", ngImport: i0, type: ColorInteractiveHasFocusDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
6247
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.13", type: ColorInteractiveHasFocusDirective, isStandalone: true, selector: "[etColorInteractiveHasFocus]", host: { classAttribute: "et-color-interactive et-color-interactive--has-focus" }, ngImport: i0 }); }
6508
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.13", type: ColorInteractiveHasFocusDirective, isStandalone: true, selector: "[etColorInteractiveHasFocus]", host: { classAttribute: "et-color-interactive--has-focus" }, ngImport: i0 }); }
6248
6509
  }
6249
6510
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.13", ngImport: i0, type: ColorInteractiveHasFocusDirective, decorators: [{
6250
6511
  type: Directive,
6251
6512
  args: [{
6252
6513
  selector: '[etColorInteractiveHasFocus]',
6253
6514
  host: {
6254
- class: 'et-color-interactive et-color-interactive--has-focus',
6515
+ class: 'et-color-interactive--has-focus',
6255
6516
  },
6256
6517
  }]
6257
6518
  }], ctorParameters: () => [] });
6258
6519
 
6520
+ /**
6521
+ * Makes an element react to ITS OWN `:hover`/`:active`/`:focus-visible`/`[disabled]` by tinting
6522
+ * `--et-theme-color-primary-*`/`-on-primary-*`/`-ink-*` with the current color theme. Use this on
6523
+ * a single, self-contained interactive element — a button, a checkbox, a segmented button.
6524
+ *
6525
+ * Do NOT apply this to a wrapper that also contains OTHER, independently-interactive elements
6526
+ * (e.g. a toolbar with its own buttons, or a form-field's control slot). These are ordinary
6527
+ * inheriting CSS custom properties, so a descendant reading them for its own cosmetics (a caret
6528
+ * color, a link color) gets swept along whenever ANYTHING inside the wrapper is hovered or
6529
+ * clicked — not just when the wrapper itself is the thing being interacted with. That exact bug
6530
+ * shipped once already; see ColorInteractiveContainerDirective/ColorInteractiveHasFocusDirective
6531
+ * for the shapes that avoid it.
6532
+ */
6259
6533
  class ColorInteractiveDirective {
6260
6534
  constructor() {
6261
6535
  this.styleManager = injectStyleManager();
@@ -6714,6 +6988,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.13", ngImpo
6714
6988
  args: [{ selector: 'et-surface-interactive-styles', template: '', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, styles: [":where(.et-surface-interactive){--et-surface-interaction-rgb: var(--et-surface-interaction);--et-surface-interaction-solid: rgb(var(--et-surface-interaction-rgb))}:where(.et-surface-interactive:hover){--et-surface-interaction-rgb: var(--et-surface-interaction-hover, var(--et-surface-interaction));--et-surface-interaction-solid: rgb(var(--et-surface-interaction-rgb))}:where(.et-surface-interactive:focus-visible){--et-surface-interaction-rgb: var( --et-surface-interaction-focus, var(--et-surface-interaction-hover, var(--et-surface-interaction)) );--et-surface-interaction-solid: rgb(var(--et-surface-interaction-rgb))}:where(.et-surface-interactive:active){--et-surface-interaction-rgb: var( --et-surface-interaction-active, var(--et-surface-interaction-focus, var(--et-surface-interaction-hover, var(--et-surface-interaction))) );--et-surface-interaction-solid: rgb(var(--et-surface-interaction-rgb))}:where(.et-surface-interactive[disabled]),:where(.et-surface-interactive[aria-disabled=true]){--et-surface-interaction-rgb: var( --et-surface-interaction-disabled, var( --et-surface-interaction-active, var(--et-surface-interaction-focus, var(--et-surface-interaction-hover, var(--et-surface-interaction))) ) );--et-surface-interaction-solid: rgb(var(--et-surface-interaction-rgb))}\n"] }]
6715
6989
  }] });
6716
6990
 
6991
+ /**
6992
+ * Same shape as `ColorInteractiveDirective` — reacts to its own `:hover`/`:focus-visible`/
6993
+ * `:active`/`[disabled]` — but drives `--et-surface-interaction-*`, a neutral/muted tint, instead
6994
+ * of the ambient color theme. Use it for chrome-level interaction feedback that shouldn't borrow
6995
+ * the page's brand color (a tab trigger's hover state, a toggle button that should look neutral
6996
+ * until it's actually active — see `ButtonDirective`'s `mutedUntilPressed`).
6997
+ *
6998
+ * Has no container/exclude/has-focus variants: it has no descendant-cascading CSS at all, so
6999
+ * applying it to a wrapper with independently-interactive children is safe by construction —
7000
+ * unlike `ColorInteractiveDirective`, there's no bubbling-leak failure mode to worry about here.
7001
+ */
6717
7002
  class SurfaceInteractiveDirective {
6718
7003
  constructor() {
6719
7004
  this.styleManager = injectStyleManager();
@@ -6736,5 +7021,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.13", ngImpo
6736
7021
  * Generated bundle index. Do not edit.
6737
7022
  */
6738
7023
 
6739
- export { ANIMATABLE_TOKEN, ANIMATED_IF_TOKEN, ANIMATED_LIFECYCLE_TOKEN, AT_LEAST_ONE_REQUIRED, AnimatableDirective, AnimatedIfDirective, AnimatedLifecycleDirective, AnimatedOverlayDirective, BOUNDARY_ELEMENT_TOKEN, BREAKPOINT_INSTANCE_TOKEN, BREAKPOINT_ORDER, COLOR_PROVIDER, ClickOutsideDirective, ColorInteractiveContainerDirective, ColorInteractiveDirective, ColorInteractiveExcludeDirective, ColorInteractiveHasFocusDirective, DEFAULT_MULTI_INSTANCE_RELS, DEFAULT_MULTI_INSTANCE_TAGS, DEFAULT_VIEWPORT_CONFIG, DISABLE_LOGGER_PARAM, DragHandleDirective, ET_DISABLE_SCROLL_TOP, ET_DISABLE_SCROLL_TOP_AS_RETURN_ROUTE, ET_DISABLE_SCROLL_TOP_ON_PATH_PARAM_CHANGE, ET_PROPERTY_REMOVED, FOCUSABLE_SELECTOR, FOCUS_VISIBLE_TRACKER_TOKEN, IS_ARRAY_NOT_EMPTY, IS_EMAIL, InferMimeTypePipe, IsArrayNotEmpty, IsEmail, jsonLd as JsonLD, KeyPressManager, MUST_MATCH, MustMatch, NormalizeGameResultTypePipe, NormalizeMatchParticipantsPipe, NormalizeMatchScorePipe, NormalizeMatchStatePipe, NormalizeMatchTypePipe, PropsDirective, ProvideColorDirective, ProvideSurfaceDirective, RUNTIME_ERROR_NO_DATA, RepeatDirective, ResizeHandlesComponent, RuntimeError, SEO_DIRECTIVE_TOKEN, SURFACE_PROVIDER, SURFACE_TYPE, ScrollObserverDirective, ScrollObserverEndDirective, ScrollObserverStartDirective, SeoDirective, StructuredDataComponent, SurfaceInteractiveDirective, ToArrayPipe, TypedQueryList, ValidateAtLeastOneRequired, Validators, applyAlternateBinding, applyAlternateLanguagesBindings, applyArticleBindings, applyAuthorBinding, applyCanonicalBinding, applyCenteredPosition, applyDescriptionBinding, applyHeadBinding, applyHeadTitleBinding, applyHostListener, applyHostListeners, applyInitialFocus, applyKeywordsBinding, applyLinkBinding, applyMetaBinding, applyNextBinding, applyOgBinding, applyOpenGraphBindings, applyPrevBinding, applyResourceHintsBindings, applyRobotsBinding, applySocialMediaBindings, applyStructuredDataBinding, applyTwitterCardBindings, areScrollStatesEqual, bindProps, boolBreakpointTransform, booleanBreakpointAttribute, boundingClientRectToElementRect, breakpointTransformBase, buildElementSignal, buildSignalEffects, canUseSessionMemory, clamp, clone, cloneFormGroup, computedTillFalsy, computedTillTruthy, controlValueSignal, controlValueSignalWithPrevious, createAnchoredPositionCleanup, createArrayPropertyBinding, createAutoSessionMemoryKey, createBulkPropertyBinding, createCanAnimateSignal, createComponentId, createCssColorThemeName, createCssSurfaceName, createDependencyStash, createDestroy, createDocumentElementSignal, createElementDictionary, createElementDimensions, createEmptyElementSignal, createFlipAnimation, createFlipAnimationGroup, createHostProps, createIsRenderedSignal, createLogger, createOverlayRuntimeRef, createPropHandlers, createPropertyBinding, createProps, createProvider, createRootProvider, createRootThemeCss, createRxHostListener, createSessionMemory, createSetup, createStaticProvider, createStaticRootProvider, createSwatchCss, createTailwindColorThemes, createTailwindCssVar, createTailwindRgbVar, createThemeStyle, createUserConsentProvider, deferredSignal, deleteCookie, easeElastic, easeIn, easeInOut, easeLinear, easeOut, easeOutBack, easeOutBackStrong, elementCanScroll, equal, firstElementSignal, focusElement, forceReflow, formatRuntimeError, fromNextFrame, getCookie, getDomain, getElementScrollCoordinates, getFocusableElements, getFormGroupValue, getGroupMatchPoints, getGroupMatchScore, getHeadingElement, getKnockoutMatchScore, getMatchScoreSubLine, getObjectProperty, getScrollContainerTarget, getScrollItemTarget, getScrollSnapTarget, hasCookie, inferMimeType, injectAngularRootElement, injectBoundaryElement, injectBreakpointInput, injectBreakpointIsMatched, injectBreakpointObserver, injectCanHover, injectColorThemes, injectColorThemesPrefix, injectCurrentBreakpoint, injectDeviceInputType, injectDisplayOrientation, injectErrorTheme, injectFocusVisibleTracker, injectFragment, injectHasPrecisionInput, injectHasTouchInput, injectHostElement, injectIs2Xl, injectIsLandscape, injectIsLg, injectIsMd, injectIsPortrait, injectIsRouterInitialized, injectIsSm, injectIsXl, injectIsXs, injectLinkStore, injectLinkStoreConfig, injectLocale, injectMediaQueryIsMatched, injectMetaConfig, injectMetaStore, injectObserveBreakpoint, injectObserveMediaQuery, injectOverlayRuntime, injectPathParam, injectPathParamChanges, injectPathParams, injectQueryParam, injectQueryParamChanges, injectQueryParams, injectRenderer, injectRoute, injectRouteData, injectRouteDataItem, injectRouteTitle, injectRouterEvent, injectRouterState, injectScrollbarDimensions, injectStructuredDataConfig, injectStructuredDataStore, injectStyleManager, injectSuccessTheme, injectSurfaceContextTracker, injectSurfaceThemes, injectSurfaceThemesPrefix, injectTemplateRef, injectTitleConfig, injectTitleStore, injectUrl, injectViewportConfig, injectViewportDimensions, injectViewportSize, injectWarningTheme, isArray, isElementSignal, isElementVisible, isFocusable, isGroupMatch, isHTMLElement, isKnockoutMatch, isObject, maybeSignalValue, memoizeSignal, nextFrame, normalizeGameResultType, normalizeMatchParticipant, normalizeMatchParticipants, normalizeMatchScore, normalizeMatchState, normalizeMatchType, numberBreakpointAttribute, numberBreakpointTransform, previousSignalValue, provideBoundaryElement, provideBreakpointInstance, provideBreakpointObserver, provideColorThemes, provideColorThemesWithTailwind4, provideFocusVisibleTracker, provideLinkStore, provideLinkStoreConfig, provideLocale, provideMetaConfig, provideMetaStore, provideOverlayRuntime, provideRenderer, provideStructuredDataConfig, provideStructuredDataStore, provideStyleManager, provideSurfaceContextTracker, provideSurfaceThemesWithTailwind4, provideTitleConfig, provideTitleStore, provideViewportConfig, resolveSurfaceByElevation, round, routerDisableScrollTop, scrollToElement, setBackdropStyles, setBaseElementStyles, setCookie, setInputSignal, setupFocusTrap, setupPositioning, setupScrollRestoration, signalAnimatedNumber, signalAttributes, signalClasses, signalElementChildren, signalElementDimensions, signalElementIntersection, signalElementLastScrollDirection, signalElementMutations, signalElementScrollState, signalHostAttributes, signalHostClasses, signalHostElementDimensions, signalHostElementIntersection, signalHostElementLastScrollDirection, signalHostElementMutations, signalHostElementScrollState, signalHostStyles, signalIsRendered, signalStyles, switchQueryListChanges, syncSignal, templateComputed, toArray, toArrayTrackByFn, toStringBinding, transformOrReturn, typedBreakpointTransform, unbindProps, useCursorDragScroll, writeScrollbarSizeToCssVariables, writeViewportSizeToCssVariables, ɵProvideColorThemes, ɵProvideColorThemesPrefix, ɵProvideSurfaceThemes, ɵProvideSurfaceThemesPrefix };
7024
+ export { ANIMATABLE_TOKEN, ANIMATED_IF_TOKEN, ANIMATED_LIFECYCLE_TOKEN, AT_LEAST_ONE_REQUIRED, AnimatableDirective, AnimatedIfDirective, AnimatedLifecycleDirective, AnimatedOverlayDirective, BOUNDARY_ELEMENT_TOKEN, BREAKPOINT_INSTANCE_TOKEN, BREAKPOINT_ORDER, COLOR_PROVIDER, ClickOutsideDirective, ColorInteractiveContainerDirective, ColorInteractiveDirective, ColorInteractiveExcludeDirective, ColorInteractiveHasFocusDirective, DEFAULT_MULTI_INSTANCE_RELS, DEFAULT_MULTI_INSTANCE_TAGS, DEFAULT_VIEWPORT_CONFIG, DISABLE_LOGGER_PARAM, DragHandleDirective, ET_DISABLE_SCROLL_TOP, ET_DISABLE_SCROLL_TOP_AS_RETURN_ROUTE, ET_DISABLE_SCROLL_TOP_ON_PATH_PARAM_CHANGE, ET_PROPERTY_REMOVED, FOCUSABLE_SELECTOR, FOCUS_VISIBLE_TRACKER_TOKEN, HtmlToMarkdownPipe, IS_ARRAY_NOT_EMPTY, IS_EMAIL, InferMimeTypePipe, IsArrayNotEmpty, IsEmail, jsonLd as JsonLD, KeyPressManager, MUST_MATCH, MarkdownToHtmlPipe, MustMatch, NormalizeGameResultTypePipe, NormalizeMatchParticipantsPipe, NormalizeMatchScorePipe, NormalizeMatchStatePipe, NormalizeMatchTypePipe, PropsDirective, ProvideColorDirective, ProvideSurfaceDirective, RUNTIME_ERROR_NO_DATA, RepeatDirective, ResizeHandlesComponent, RuntimeError, SEO_DIRECTIVE_TOKEN, SURFACE_PROVIDER, SURFACE_TYPE, ScrollObserverDirective, ScrollObserverEndDirective, ScrollObserverStartDirective, SeoDirective, StructuredDataComponent, SurfaceInteractiveDirective, ToArrayPipe, TypedQueryList, ValidateAtLeastOneRequired, Validators, applyAlternateBinding, applyAlternateLanguagesBindings, applyArticleBindings, applyAuthorBinding, applyCanonicalBinding, applyCenteredPosition, applyDescriptionBinding, applyHeadBinding, applyHeadTitleBinding, applyHostListener, applyHostListeners, applyInitialFocus, applyKeywordsBinding, applyLinkBinding, applyMetaBinding, applyNextBinding, applyOgBinding, applyOpenGraphBindings, applyPrevBinding, applyResourceHintsBindings, applyRobotsBinding, applySocialMediaBindings, applyStructuredDataBinding, applyTwitterCardBindings, areScrollStatesEqual, bindProps, boolBreakpointTransform, booleanBreakpointAttribute, boundingClientRectToElementRect, breakpointTransformBase, buildElementSignal, buildSignalEffects, canUseSessionMemory, clamp, clone, cloneFormGroup, computedTillFalsy, computedTillTruthy, controlValueSignal, controlValueSignalWithPrevious, createAnchoredPositionCleanup, createArrayPropertyBinding, createAutoSessionMemoryKey, createBulkPropertyBinding, createCanAnimateSignal, createComponentId, createCssColorThemeName, createCssSurfaceName, createDependencyStash, createDestroy, createDocumentElementSignal, createElementDictionary, createElementDimensions, createEmptyElementSignal, createFlipAnimation, createFlipAnimationGroup, createHostProps, createIsRenderedSignal, createLogger, createOverlayRuntimeRef, createPropHandlers, createPropertyBinding, createProps, createProvider, createRootProvider, createRootThemeCss, createRxHostListener, createSessionMemory, createSetup, createStaticProvider, createStaticRootProvider, createSwatchCss, createTailwindColorThemes, createTailwindCssVar, createTailwindRgbVar, createThemeStyle, createUserConsentProvider, deferredSignal, deleteCookie, easeElastic, easeIn, easeInOut, easeLinear, easeOut, easeOutBack, easeOutBackStrong, elementCanScroll, equal, firstElementSignal, focusElement, forceReflow, formatRuntimeError, fromNextFrame, getCookie, getDomain, getElementScrollCoordinates, getFocusableElements, getFormGroupValue, getGroupMatchPoints, getGroupMatchScore, getHeadingElement, getKnockoutMatchScore, getMatchScoreSubLine, getObjectProperty, getScrollContainerTarget, getScrollItemTarget, getScrollSnapTarget, hasCookie, htmlToMarkdown, inferMimeType, injectAngularRootElement, injectBoundaryElement, injectBreakpointInput, injectBreakpointIsMatched, injectBreakpointObserver, injectCanHover, injectColorThemes, injectColorThemesPrefix, injectCurrentBreakpoint, injectDeviceInputType, injectDisplayOrientation, injectErrorTheme, injectFocusVisibleTracker, injectFragment, injectHasPrecisionInput, injectHasTouchInput, injectHostElement, injectIs2Xl, injectIsLandscape, injectIsLg, injectIsMd, injectIsPortrait, injectIsRouterInitialized, injectIsSm, injectIsXl, injectIsXs, injectLinkStore, injectLinkStoreConfig, injectLocale, injectMediaQueryIsMatched, injectMetaConfig, injectMetaStore, injectObserveBreakpoint, injectObserveMediaQuery, injectOverlayRuntime, injectPathParam, injectPathParamChanges, injectPathParams, injectQueryParam, injectQueryParamChanges, injectQueryParams, injectRenderer, injectRoute, injectRouteData, injectRouteDataItem, injectRouteTitle, injectRouterEvent, injectRouterState, injectScrollbarDimensions, injectStructuredDataConfig, injectStructuredDataStore, injectStyleManager, injectSuccessTheme, injectSurfaceContextTracker, injectSurfaceThemes, injectSurfaceThemesPrefix, injectTemplateRef, injectTitleConfig, injectTitleStore, injectUrl, injectViewportConfig, injectViewportDimensions, injectViewportSize, injectWarningTheme, isArray, isElementSignal, isElementVisible, isFocusable, isGroupMatch, isHTMLElement, isKnockoutMatch, isObject, markdownToHtml, maybeSignalValue, memoizeSignal, nextFrame, normalizeGameResultType, normalizeMatchParticipant, normalizeMatchParticipants, normalizeMatchScore, normalizeMatchState, normalizeMatchType, numberBreakpointAttribute, numberBreakpointTransform, previousSignalValue, provideBoundaryElement, provideBreakpointInstance, provideBreakpointObserver, provideColorThemes, provideColorThemesWithTailwind4, provideFocusVisibleTracker, provideLinkStore, provideLinkStoreConfig, provideLocale, provideMetaConfig, provideMetaStore, provideOverlayRuntime, provideRenderer, provideStructuredDataConfig, provideStructuredDataStore, provideStyleManager, provideSurfaceContextTracker, provideSurfaceThemesWithTailwind4, provideTitleConfig, provideTitleStore, provideViewportConfig, resolveSurfaceByElevation, round, routerDisableScrollTop, scrollToElement, setBackdropStyles, setBaseElementStyles, setCookie, setInputSignal, setupFocusTrap, setupPositioning, setupScrollRestoration, signalAnimatedNumber, signalAttributes, signalClasses, signalElementChildren, signalElementDimensions, signalElementIntersection, signalElementLastScrollDirection, signalElementMutations, signalElementScrollState, signalHostAttributes, signalHostClasses, signalHostElementDimensions, signalHostElementIntersection, signalHostElementLastScrollDirection, signalHostElementMutations, signalHostElementScrollState, signalHostStyles, signalIsRendered, signalStyles, switchQueryListChanges, syncSignal, templateComputed, toArray, toArrayTrackByFn, toStringBinding, transformOrReturn, typedBreakpointTransform, unbindProps, useCursorDragScroll, writeScrollbarSizeToCssVariables, writeViewportSizeToCssVariables, ɵProvideColorThemes, ɵProvideColorThemesPrefix, ɵProvideSurfaceThemes, ɵProvideSurfaceThemesPrefix };
6740
7025
  //# sourceMappingURL=ethlete-core.mjs.map