@utilix-tech/sdk 0.68.0 → 0.70.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -28,6 +28,8 @@
28
28
  * - package-json-dependency-auditor (auditDependencyRanges)
29
29
  * - regex-groups (analyzeRegexGroups)
30
30
  * - svg-sprite-symbol-extractor (extractSvgSpriteSymbols)
31
+ * - git-commit-trailer-parser (parseCommitTrailers)
32
+ * - markdown-footnote-extractor (extractMarkdownFootnotes)
31
33
  */
32
34
  type RegexFlag = 'g' | 'i' | 'm' | 's' | 'u';
33
35
  declare const ALL_FLAGS: RegexFlag[];
@@ -571,12 +573,63 @@ interface SvgSpriteResult {
571
573
  declare function extractSvgSpriteSymbols(svg: string): SvgSpriteResult | {
572
574
  error: string;
573
575
  };
576
+ interface CommitTrailer {
577
+ key: string;
578
+ value: string;
579
+ }
580
+ interface CommitTrailerResult {
581
+ trailers: CommitTrailer[];
582
+ body: string;
583
+ hasTrailers: boolean;
584
+ }
585
+ /**
586
+ * Parse a commit message's trailer block (Co-authored-by, Signed-off-by,
587
+ * Fixes, Reviewed-by, etc.) per git's RFC 822-style trailer convention
588
+ * (see `git-interpret-trailers`): the last paragraph of the message, where
589
+ * every line is either a `Key: value` pair or an indented continuation of
590
+ * the previous trailer's value. If the last paragraph doesn't consist
591
+ * entirely of trailer-shaped lines, no trailers are returned and the whole
592
+ * message is treated as body. This does not implement git's 25%-of-lines
593
+ * heuristic for a mixed last paragraph; it requires every line to match.
594
+ */
595
+ declare function parseCommitTrailers(message: string): CommitTrailerResult | {
596
+ error: string;
597
+ };
598
+ interface MarkdownFootnoteDefinition {
599
+ label: string;
600
+ text: string;
601
+ }
602
+ interface MarkdownFootnoteReference {
603
+ label: string;
604
+ count: number;
605
+ }
606
+ interface MarkdownFootnoteResult {
607
+ definitionCount: number;
608
+ referenceCount: number;
609
+ definitions: MarkdownFootnoteDefinition[];
610
+ references: MarkdownFootnoteReference[];
611
+ unresolvedReferences: string[];
612
+ unusedDefinitions: string[];
613
+ }
614
+ /**
615
+ * Extract every Markdown-Extra-style footnote reference (`[^label]`) and
616
+ * definition (`[^label]: text`, with 4-space/tab-indented continuation
617
+ * lines) from a document, then flag references with no matching definition
618
+ * and definitions that are never referenced. A `[^label]` occurring inside
619
+ * a definition's own continuation lines is not counted as a separate
620
+ * reference, since that text is part of the definition itself.
621
+ */
622
+ declare function extractMarkdownFootnotes(markdown: string): MarkdownFootnoteResult | {
623
+ error: string;
624
+ };
574
625
 
575
626
  declare const code_ALL_FLAGS: typeof ALL_FLAGS;
576
627
  type code_ApiEndpoint = ApiEndpoint;
577
628
  type code_ApiInfo = ApiInfo;
578
629
  declare const code_CHEATSHEET: typeof CHEATSHEET;
579
630
  type code_CheatsheetEntry = CheatsheetEntry;
631
+ type code_CommitTrailer = CommitTrailer;
632
+ type code_CommitTrailerResult = CommitTrailerResult;
580
633
  type code_ConventionalCommitFinding = ConventionalCommitFinding;
581
634
  type code_ConventionalCommitFooter = ConventionalCommitFooter;
582
635
  type code_ConventionalCommitOptions = ConventionalCommitOptions;
@@ -614,6 +667,9 @@ type code_HtmlMinifyResult = HtmlMinifyResult;
614
667
  type code_JsMinifyOptions = JsMinifyOptions;
615
668
  type code_JsMinifyResult = JsMinifyResult;
616
669
  declare const code_MIME_TABLE: typeof MIME_TABLE;
670
+ type code_MarkdownFootnoteDefinition = MarkdownFootnoteDefinition;
671
+ type code_MarkdownFootnoteReference = MarkdownFootnoteReference;
672
+ type code_MarkdownFootnoteResult = MarkdownFootnoteResult;
617
673
  type code_MatchResult = MatchResult;
618
674
  type code_MimeEntry = MimeEntry;
619
675
  type code_MimeLookupResult = MimeLookupResult;
@@ -655,6 +711,7 @@ declare const code_detectOperationType: typeof detectOperationType;
655
711
  declare const code_detectRedos: typeof detectRedos;
656
712
  declare const code_envToExport: typeof envToExport;
657
713
  declare const code_envToJson: typeof envToJson;
714
+ declare const code_extractMarkdownFootnotes: typeof extractMarkdownFootnotes;
658
715
  declare const code_extractSvgSpriteSymbols: typeof extractSvgSpriteSymbols;
659
716
  declare const code_formatCss: typeof formatCss;
660
717
  declare const code_formatGql: typeof formatGql;
@@ -673,6 +730,7 @@ declare const code_minifyHtml: typeof minifyHtml;
673
730
  declare const code_minifyJs: typeof minifyJs;
674
731
  declare const code_minifySql: typeof minifySql;
675
732
  declare const code_normalizeRef: typeof normalizeRef;
733
+ declare const code_parseCommitTrailers: typeof parseCommitTrailers;
676
734
  declare const code_parseDockerImage: typeof parseDockerImage;
677
735
  declare const code_parseEnv: typeof parseEnv;
678
736
  declare const code_parseGitCommand: typeof parseGitCommand;
@@ -694,7 +752,7 @@ declare const code_validateEnvKey: typeof validateEnvKey;
694
752
  declare const code_validatePackageExports: typeof validatePackageExports;
695
753
  declare const code_validateTsconfig: typeof validateTsconfig;
696
754
  declare namespace code {
697
- export { code_ALL_FLAGS as ALL_FLAGS, type code_ApiEndpoint as ApiEndpoint, type code_ApiInfo as ApiInfo, code_CHEATSHEET as CHEATSHEET, type code_CheatsheetEntry as CheatsheetEntry, type code_ConventionalCommitFinding as ConventionalCommitFinding, type code_ConventionalCommitFooter as ConventionalCommitFooter, type code_ConventionalCommitOptions as ConventionalCommitOptions, type code_ConventionalCommitParsed as ConventionalCommitParsed, type code_ConventionalCommitResult as ConventionalCommitResult, type code_ConventionalCommitSeverity as ConventionalCommitSeverity, type code_CssResult as CssResult, code_DEFAULT_COMMIT_TYPES as DEFAULT_COMMIT_TYPES, type code_DependencyAuditDuplicate as DependencyAuditDuplicate, type code_DependencyAuditEntry as DependencyAuditEntry, type code_DependencyAuditIssue as DependencyAuditIssue, type code_DependencyAuditResult as DependencyAuditResult, type code_DependencyRangeType as DependencyRangeType, type code_DependencySection as DependencySection, type code_DockerImageRef as DockerImageRef, type code_EditorConfigIssue as EditorConfigIssue, type code_EditorConfigProperty as EditorConfigProperty, type code_EditorConfigSection as EditorConfigSection, type code_EditorConfigValidationResult as EditorConfigValidationResult, type code_EnvEntry as EnvEntry, type code_EnvParseResult as EnvParseResult, type code_ExportsIssue as ExportsIssue, type code_ExportsShape as ExportsShape, type code_ExportsValidationResult as ExportsValidationResult, type code_GitCommandConfig as GitCommandConfig, type code_GitCommandResult as GitCommandResult, type code_GitOperation as GitOperation, type code_GithubUrlInfo as GithubUrlInfo, type code_GithubUrlType as GithubUrlType, type code_GitignoreTestResult as GitignoreTestResult, type code_GqlFormatResult as GqlFormatResult, type code_HtmlFormatResult as HtmlFormatResult, type code_HtmlMinifyOptions as HtmlMinifyOptions, type code_HtmlMinifyResult as HtmlMinifyResult, type code_JsMinifyOptions as JsMinifyOptions, type code_JsMinifyResult as JsMinifyResult, code_MIME_TABLE as MIME_TABLE, type code_MatchResult as MatchResult, type code_MimeEntry as MimeEntry, type code_MimeLookupResult as MimeLookupResult, code_OPERATIONS as OPERATIONS, type code_ParsedSpec as ParsedSpec, type code_RedosFinding as RedosFinding, type code_RedosResult as RedosResult, type code_RedosSeverity as RedosSeverity, type code_RegexBackreferenceInfo as RegexBackreferenceInfo, type code_RegexError as RegexError, type code_RegexFlag as RegexFlag, type code_RegexGroupAnalysis as RegexGroupAnalysis, type code_RegexGroupInfo as RegexGroupInfo, type code_RegexGroupIssue as RegexGroupIssue, type code_RegexMatch as RegexMatch, type code_RegexResult as RegexResult, type code_RegexSuccess as RegexSuccess, code_SQL_DEFAULT_OPTIONS as SQL_DEFAULT_OPTIONS, type code_Segment as Segment, type code_SpecVersion as SpecVersion, type code_SqlDialect as SqlDialect, type code_SqlFormatOptions as SqlFormatOptions, type code_SvgSpriteResult as SvgSpriteResult, type code_SvgSpriteSymbol as SvgSpriteSymbol, type code_TestPatternResult as TestPatternResult, type code_TsconfigIssue as TsconfigIssue, type code_TsconfigValidationResult as TsconfigValidationResult, code_analyzeRegexGroups as analyzeRegexGroups, code_auditDependencyRanges as auditDependencyRanges, code_buildDockerPull as buildDockerPull, code_buildDockerRun as buildDockerRun, code_buildGitCommand as buildGitCommand, code_collapseHtmlWhitespace as collapseHtmlWhitespace, code_collapseJsWhitespace as collapseJsWhitespace, code_countProperties as countProperties, code_countRules as countRules, code_detectDialect as detectDialect, code_detectOperationType as detectOperationType, code_detectRedos as detectRedos, code_envToExport as envToExport, code_envToJson as envToJson, code_extractSvgSpriteSymbols as extractSvgSpriteSymbols, code_formatCss as formatCss, code_formatGql as formatGql, code_formatHtml as formatHtml, code_formatSql as formatSql, code_getEndpointsByTag as getEndpointsByTag, code_getHtmlStats as getHtmlStats, code_getJsStats as getJsStats, code_getMethodColor as getMethodColor, code_isValidTag as isValidTag, code_lintConventionalCommit as lintConventionalCommit, code_lookupMime as lookupMime, code_minifyCss as minifyCss, code_minifyGql as minifyGql, code_minifyHtml as minifyHtml, code_minifyJs as minifyJs, code_minifySql as minifySql, code_normalizeRef as normalizeRef, code_parseDockerImage as parseDockerImage, code_parseEnv as parseEnv, code_parseGitCommand as parseGitCommand, code_parseGithubUrl as parseGithubUrl, code_parseSpec as parseSpec, code_removeConsoleCalls as removeConsoleCalls, code_removeEmptyAttributes as removeEmptyAttributes, code_removeHtmlComments as removeHtmlComments, code_removeJsComments as removeJsComments, code_removeRedundantAttributes as removeRedundantAttributes, code_searchCheatsheet as searchCheatsheet, code_searchEndpoints as searchEndpoints, code_splitStatements as splitStatements, code_testGitignorePatterns as testGitignorePatterns, code_testPattern as testPattern, code_testRegex as testRegex, code_validateEditorConfig as validateEditorConfig, code_validateEnvKey as validateEnvKey, code_validatePackageExports as validatePackageExports, code_validateTsconfig as validateTsconfig };
755
+ export { code_ALL_FLAGS as ALL_FLAGS, type code_ApiEndpoint as ApiEndpoint, type code_ApiInfo as ApiInfo, code_CHEATSHEET as CHEATSHEET, type code_CheatsheetEntry as CheatsheetEntry, type code_CommitTrailer as CommitTrailer, type code_CommitTrailerResult as CommitTrailerResult, type code_ConventionalCommitFinding as ConventionalCommitFinding, type code_ConventionalCommitFooter as ConventionalCommitFooter, type code_ConventionalCommitOptions as ConventionalCommitOptions, type code_ConventionalCommitParsed as ConventionalCommitParsed, type code_ConventionalCommitResult as ConventionalCommitResult, type code_ConventionalCommitSeverity as ConventionalCommitSeverity, type code_CssResult as CssResult, code_DEFAULT_COMMIT_TYPES as DEFAULT_COMMIT_TYPES, type code_DependencyAuditDuplicate as DependencyAuditDuplicate, type code_DependencyAuditEntry as DependencyAuditEntry, type code_DependencyAuditIssue as DependencyAuditIssue, type code_DependencyAuditResult as DependencyAuditResult, type code_DependencyRangeType as DependencyRangeType, type code_DependencySection as DependencySection, type code_DockerImageRef as DockerImageRef, type code_EditorConfigIssue as EditorConfigIssue, type code_EditorConfigProperty as EditorConfigProperty, type code_EditorConfigSection as EditorConfigSection, type code_EditorConfigValidationResult as EditorConfigValidationResult, type code_EnvEntry as EnvEntry, type code_EnvParseResult as EnvParseResult, type code_ExportsIssue as ExportsIssue, type code_ExportsShape as ExportsShape, type code_ExportsValidationResult as ExportsValidationResult, type code_GitCommandConfig as GitCommandConfig, type code_GitCommandResult as GitCommandResult, type code_GitOperation as GitOperation, type code_GithubUrlInfo as GithubUrlInfo, type code_GithubUrlType as GithubUrlType, type code_GitignoreTestResult as GitignoreTestResult, type code_GqlFormatResult as GqlFormatResult, type code_HtmlFormatResult as HtmlFormatResult, type code_HtmlMinifyOptions as HtmlMinifyOptions, type code_HtmlMinifyResult as HtmlMinifyResult, type code_JsMinifyOptions as JsMinifyOptions, type code_JsMinifyResult as JsMinifyResult, code_MIME_TABLE as MIME_TABLE, type code_MarkdownFootnoteDefinition as MarkdownFootnoteDefinition, type code_MarkdownFootnoteReference as MarkdownFootnoteReference, type code_MarkdownFootnoteResult as MarkdownFootnoteResult, type code_MatchResult as MatchResult, type code_MimeEntry as MimeEntry, type code_MimeLookupResult as MimeLookupResult, code_OPERATIONS as OPERATIONS, type code_ParsedSpec as ParsedSpec, type code_RedosFinding as RedosFinding, type code_RedosResult as RedosResult, type code_RedosSeverity as RedosSeverity, type code_RegexBackreferenceInfo as RegexBackreferenceInfo, type code_RegexError as RegexError, type code_RegexFlag as RegexFlag, type code_RegexGroupAnalysis as RegexGroupAnalysis, type code_RegexGroupInfo as RegexGroupInfo, type code_RegexGroupIssue as RegexGroupIssue, type code_RegexMatch as RegexMatch, type code_RegexResult as RegexResult, type code_RegexSuccess as RegexSuccess, code_SQL_DEFAULT_OPTIONS as SQL_DEFAULT_OPTIONS, type code_Segment as Segment, type code_SpecVersion as SpecVersion, type code_SqlDialect as SqlDialect, type code_SqlFormatOptions as SqlFormatOptions, type code_SvgSpriteResult as SvgSpriteResult, type code_SvgSpriteSymbol as SvgSpriteSymbol, type code_TestPatternResult as TestPatternResult, type code_TsconfigIssue as TsconfigIssue, type code_TsconfigValidationResult as TsconfigValidationResult, code_analyzeRegexGroups as analyzeRegexGroups, code_auditDependencyRanges as auditDependencyRanges, code_buildDockerPull as buildDockerPull, code_buildDockerRun as buildDockerRun, code_buildGitCommand as buildGitCommand, code_collapseHtmlWhitespace as collapseHtmlWhitespace, code_collapseJsWhitespace as collapseJsWhitespace, code_countProperties as countProperties, code_countRules as countRules, code_detectDialect as detectDialect, code_detectOperationType as detectOperationType, code_detectRedos as detectRedos, code_envToExport as envToExport, code_envToJson as envToJson, code_extractMarkdownFootnotes as extractMarkdownFootnotes, code_extractSvgSpriteSymbols as extractSvgSpriteSymbols, code_formatCss as formatCss, code_formatGql as formatGql, code_formatHtml as formatHtml, code_formatSql as formatSql, code_getEndpointsByTag as getEndpointsByTag, code_getHtmlStats as getHtmlStats, code_getJsStats as getJsStats, code_getMethodColor as getMethodColor, code_isValidTag as isValidTag, code_lintConventionalCommit as lintConventionalCommit, code_lookupMime as lookupMime, code_minifyCss as minifyCss, code_minifyGql as minifyGql, code_minifyHtml as minifyHtml, code_minifyJs as minifyJs, code_minifySql as minifySql, code_normalizeRef as normalizeRef, code_parseCommitTrailers as parseCommitTrailers, code_parseDockerImage as parseDockerImage, code_parseEnv as parseEnv, code_parseGitCommand as parseGitCommand, code_parseGithubUrl as parseGithubUrl, code_parseSpec as parseSpec, code_removeConsoleCalls as removeConsoleCalls, code_removeEmptyAttributes as removeEmptyAttributes, code_removeHtmlComments as removeHtmlComments, code_removeJsComments as removeJsComments, code_removeRedundantAttributes as removeRedundantAttributes, code_searchCheatsheet as searchCheatsheet, code_searchEndpoints as searchEndpoints, code_splitStatements as splitStatements, code_testGitignorePatterns as testGitignorePatterns, code_testPattern as testPattern, code_testRegex as testRegex, code_validateEditorConfig as validateEditorConfig, code_validateEnvKey as validateEnvKey, code_validatePackageExports as validatePackageExports, code_validateTsconfig as validateTsconfig };
698
756
  }
699
757
 
700
- export { type RegexFlag as $, ALL_FLAGS as A, type GitCommandResult as B, CHEATSHEET as C, DEFAULT_COMMIT_TYPES as D, type EditorConfigIssue as E, type GitOperation as F, type GitCommandConfig as G, type GithubUrlInfo as H, type GithubUrlType as I, type GitignoreTestResult as J, type GqlFormatResult as K, type HtmlFormatResult as L, type HtmlMinifyOptions as M, type HtmlMinifyResult as N, type JsMinifyOptions as O, type JsMinifyResult as P, MIME_TABLE as Q, type MatchResult as R, type MimeEntry as S, type MimeLookupResult as T, OPERATIONS as U, type ParsedSpec as V, type RedosFinding as W, type RedosResult as X, type RedosSeverity as Y, type RegexBackreferenceInfo as Z, type RegexError as _, type ApiEndpoint as a, testRegex as a$, type RegexGroupAnalysis as a0, type RegexGroupInfo as a1, type RegexGroupIssue as a2, type RegexMatch as a3, type RegexResult as a4, type RegexSuccess as a5, SQL_DEFAULT_OPTIONS as a6, type Segment as a7, type SpecVersion as a8, type SqlDialect as a9, getHtmlStats as aA, getJsStats as aB, getMethodColor as aC, isValidTag as aD, lintConventionalCommit as aE, lookupMime as aF, minifyCss as aG, minifyGql as aH, minifyHtml as aI, minifyJs as aJ, minifySql as aK, normalizeRef as aL, parseDockerImage as aM, parseEnv as aN, parseGitCommand as aO, parseGithubUrl as aP, parseSpec as aQ, removeConsoleCalls as aR, removeEmptyAttributes as aS, removeHtmlComments as aT, removeJsComments as aU, removeRedundantAttributes as aV, searchCheatsheet as aW, searchEndpoints as aX, splitStatements as aY, testGitignorePatterns as aZ, testPattern as a_, type SqlFormatOptions as aa, type SvgSpriteResult as ab, type SvgSpriteSymbol as ac, type TestPatternResult as ad, type TsconfigIssue as ae, type TsconfigValidationResult as af, analyzeRegexGroups as ag, auditDependencyRanges as ah, buildDockerPull as ai, buildDockerRun as aj, buildGitCommand as ak, collapseHtmlWhitespace as al, collapseJsWhitespace as am, countProperties as an, countRules as ao, detectDialect as ap, detectOperationType as aq, detectRedos as ar, envToExport as as, envToJson as at, extractSvgSpriteSymbols as au, formatCss as av, formatGql as aw, formatHtml as ax, formatSql as ay, getEndpointsByTag as az, type ApiInfo as b, validateEditorConfig as b0, validateEnvKey as b1, validatePackageExports as b2, validateTsconfig as b3, code as c, type CheatsheetEntry as d, type ConventionalCommitFinding as e, type ConventionalCommitFooter as f, type ConventionalCommitOptions as g, type ConventionalCommitParsed as h, type ConventionalCommitResult as i, type ConventionalCommitSeverity as j, type CssResult as k, type DependencyAuditDuplicate as l, type DependencyAuditEntry as m, type DependencyAuditIssue as n, type DependencyAuditResult as o, type DependencyRangeType as p, type DependencySection as q, type DockerImageRef as r, type EditorConfigProperty as s, type EditorConfigSection as t, type EditorConfigValidationResult as u, type EnvEntry as v, type EnvParseResult as w, type ExportsIssue as x, type ExportsShape as y, type ExportsValidationResult as z };
758
+ export { type RedosFinding as $, ALL_FLAGS as A, type ExportsShape as B, CHEATSHEET as C, DEFAULT_COMMIT_TYPES as D, type EditorConfigIssue as E, type ExportsValidationResult as F, type GitCommandConfig as G, type GitCommandResult as H, type GitOperation as I, type GithubUrlInfo as J, type GithubUrlType as K, type GitignoreTestResult as L, type GqlFormatResult as M, type HtmlFormatResult as N, type HtmlMinifyOptions as O, type HtmlMinifyResult as P, type JsMinifyOptions as Q, type JsMinifyResult as R, MIME_TABLE as S, type MarkdownFootnoteDefinition as T, type MarkdownFootnoteReference as U, type MarkdownFootnoteResult as V, type MatchResult as W, type MimeEntry as X, type MimeLookupResult as Y, OPERATIONS as Z, type ParsedSpec as _, type ApiEndpoint as a, removeJsComments as a$, type RedosResult as a0, type RedosSeverity as a1, type RegexBackreferenceInfo as a2, type RegexError as a3, type RegexFlag as a4, type RegexGroupAnalysis as a5, type RegexGroupInfo as a6, type RegexGroupIssue as a7, type RegexMatch as a8, type RegexResult as a9, extractSvgSpriteSymbols as aA, formatCss as aB, formatGql as aC, formatHtml as aD, formatSql as aE, getEndpointsByTag as aF, getHtmlStats as aG, getJsStats as aH, getMethodColor as aI, isValidTag as aJ, lintConventionalCommit as aK, lookupMime as aL, minifyCss as aM, minifyGql as aN, minifyHtml as aO, minifyJs as aP, minifySql as aQ, normalizeRef as aR, parseCommitTrailers as aS, parseDockerImage as aT, parseEnv as aU, parseGitCommand as aV, parseGithubUrl as aW, parseSpec as aX, removeConsoleCalls as aY, removeEmptyAttributes as aZ, removeHtmlComments as a_, type RegexSuccess as aa, SQL_DEFAULT_OPTIONS as ab, type Segment as ac, type SpecVersion as ad, type SqlDialect as ae, type SqlFormatOptions as af, type SvgSpriteResult as ag, type SvgSpriteSymbol as ah, type TestPatternResult as ai, type TsconfigIssue as aj, type TsconfigValidationResult as ak, analyzeRegexGroups as al, auditDependencyRanges as am, buildDockerPull as an, buildDockerRun as ao, buildGitCommand as ap, collapseHtmlWhitespace as aq, collapseJsWhitespace as ar, countProperties as as, countRules as at, detectDialect as au, detectOperationType as av, detectRedos as aw, envToExport as ax, envToJson as ay, extractMarkdownFootnotes as az, type ApiInfo as b, removeRedundantAttributes as b0, searchCheatsheet as b1, searchEndpoints as b2, splitStatements as b3, testGitignorePatterns as b4, testPattern as b5, testRegex as b6, validateEditorConfig as b7, validateEnvKey as b8, validatePackageExports as b9, validateTsconfig as ba, code as c, type CheatsheetEntry as d, type CommitTrailer as e, type CommitTrailerResult as f, type ConventionalCommitFinding as g, type ConventionalCommitFooter as h, type ConventionalCommitOptions as i, type ConventionalCommitParsed as j, type ConventionalCommitResult as k, type ConventionalCommitSeverity as l, type CssResult as m, type DependencyAuditDuplicate as n, type DependencyAuditEntry as o, type DependencyAuditIssue as p, type DependencyAuditResult as q, type DependencyRangeType as r, type DependencySection as s, type DockerImageRef as t, type EditorConfigProperty as u, type EditorConfigSection as v, type EditorConfigValidationResult as w, type EnvEntry as x, type EnvParseResult as y, type ExportsIssue as z };
@@ -28,6 +28,8 @@
28
28
  * - package-json-dependency-auditor (auditDependencyRanges)
29
29
  * - regex-groups (analyzeRegexGroups)
30
30
  * - svg-sprite-symbol-extractor (extractSvgSpriteSymbols)
31
+ * - git-commit-trailer-parser (parseCommitTrailers)
32
+ * - markdown-footnote-extractor (extractMarkdownFootnotes)
31
33
  */
32
34
  type RegexFlag = 'g' | 'i' | 'm' | 's' | 'u';
33
35
  declare const ALL_FLAGS: RegexFlag[];
@@ -571,12 +573,63 @@ interface SvgSpriteResult {
571
573
  declare function extractSvgSpriteSymbols(svg: string): SvgSpriteResult | {
572
574
  error: string;
573
575
  };
576
+ interface CommitTrailer {
577
+ key: string;
578
+ value: string;
579
+ }
580
+ interface CommitTrailerResult {
581
+ trailers: CommitTrailer[];
582
+ body: string;
583
+ hasTrailers: boolean;
584
+ }
585
+ /**
586
+ * Parse a commit message's trailer block (Co-authored-by, Signed-off-by,
587
+ * Fixes, Reviewed-by, etc.) per git's RFC 822-style trailer convention
588
+ * (see `git-interpret-trailers`): the last paragraph of the message, where
589
+ * every line is either a `Key: value` pair or an indented continuation of
590
+ * the previous trailer's value. If the last paragraph doesn't consist
591
+ * entirely of trailer-shaped lines, no trailers are returned and the whole
592
+ * message is treated as body. This does not implement git's 25%-of-lines
593
+ * heuristic for a mixed last paragraph; it requires every line to match.
594
+ */
595
+ declare function parseCommitTrailers(message: string): CommitTrailerResult | {
596
+ error: string;
597
+ };
598
+ interface MarkdownFootnoteDefinition {
599
+ label: string;
600
+ text: string;
601
+ }
602
+ interface MarkdownFootnoteReference {
603
+ label: string;
604
+ count: number;
605
+ }
606
+ interface MarkdownFootnoteResult {
607
+ definitionCount: number;
608
+ referenceCount: number;
609
+ definitions: MarkdownFootnoteDefinition[];
610
+ references: MarkdownFootnoteReference[];
611
+ unresolvedReferences: string[];
612
+ unusedDefinitions: string[];
613
+ }
614
+ /**
615
+ * Extract every Markdown-Extra-style footnote reference (`[^label]`) and
616
+ * definition (`[^label]: text`, with 4-space/tab-indented continuation
617
+ * lines) from a document, then flag references with no matching definition
618
+ * and definitions that are never referenced. A `[^label]` occurring inside
619
+ * a definition's own continuation lines is not counted as a separate
620
+ * reference, since that text is part of the definition itself.
621
+ */
622
+ declare function extractMarkdownFootnotes(markdown: string): MarkdownFootnoteResult | {
623
+ error: string;
624
+ };
574
625
 
575
626
  declare const code_ALL_FLAGS: typeof ALL_FLAGS;
576
627
  type code_ApiEndpoint = ApiEndpoint;
577
628
  type code_ApiInfo = ApiInfo;
578
629
  declare const code_CHEATSHEET: typeof CHEATSHEET;
579
630
  type code_CheatsheetEntry = CheatsheetEntry;
631
+ type code_CommitTrailer = CommitTrailer;
632
+ type code_CommitTrailerResult = CommitTrailerResult;
580
633
  type code_ConventionalCommitFinding = ConventionalCommitFinding;
581
634
  type code_ConventionalCommitFooter = ConventionalCommitFooter;
582
635
  type code_ConventionalCommitOptions = ConventionalCommitOptions;
@@ -614,6 +667,9 @@ type code_HtmlMinifyResult = HtmlMinifyResult;
614
667
  type code_JsMinifyOptions = JsMinifyOptions;
615
668
  type code_JsMinifyResult = JsMinifyResult;
616
669
  declare const code_MIME_TABLE: typeof MIME_TABLE;
670
+ type code_MarkdownFootnoteDefinition = MarkdownFootnoteDefinition;
671
+ type code_MarkdownFootnoteReference = MarkdownFootnoteReference;
672
+ type code_MarkdownFootnoteResult = MarkdownFootnoteResult;
617
673
  type code_MatchResult = MatchResult;
618
674
  type code_MimeEntry = MimeEntry;
619
675
  type code_MimeLookupResult = MimeLookupResult;
@@ -655,6 +711,7 @@ declare const code_detectOperationType: typeof detectOperationType;
655
711
  declare const code_detectRedos: typeof detectRedos;
656
712
  declare const code_envToExport: typeof envToExport;
657
713
  declare const code_envToJson: typeof envToJson;
714
+ declare const code_extractMarkdownFootnotes: typeof extractMarkdownFootnotes;
658
715
  declare const code_extractSvgSpriteSymbols: typeof extractSvgSpriteSymbols;
659
716
  declare const code_formatCss: typeof formatCss;
660
717
  declare const code_formatGql: typeof formatGql;
@@ -673,6 +730,7 @@ declare const code_minifyHtml: typeof minifyHtml;
673
730
  declare const code_minifyJs: typeof minifyJs;
674
731
  declare const code_minifySql: typeof minifySql;
675
732
  declare const code_normalizeRef: typeof normalizeRef;
733
+ declare const code_parseCommitTrailers: typeof parseCommitTrailers;
676
734
  declare const code_parseDockerImage: typeof parseDockerImage;
677
735
  declare const code_parseEnv: typeof parseEnv;
678
736
  declare const code_parseGitCommand: typeof parseGitCommand;
@@ -694,7 +752,7 @@ declare const code_validateEnvKey: typeof validateEnvKey;
694
752
  declare const code_validatePackageExports: typeof validatePackageExports;
695
753
  declare const code_validateTsconfig: typeof validateTsconfig;
696
754
  declare namespace code {
697
- export { code_ALL_FLAGS as ALL_FLAGS, type code_ApiEndpoint as ApiEndpoint, type code_ApiInfo as ApiInfo, code_CHEATSHEET as CHEATSHEET, type code_CheatsheetEntry as CheatsheetEntry, type code_ConventionalCommitFinding as ConventionalCommitFinding, type code_ConventionalCommitFooter as ConventionalCommitFooter, type code_ConventionalCommitOptions as ConventionalCommitOptions, type code_ConventionalCommitParsed as ConventionalCommitParsed, type code_ConventionalCommitResult as ConventionalCommitResult, type code_ConventionalCommitSeverity as ConventionalCommitSeverity, type code_CssResult as CssResult, code_DEFAULT_COMMIT_TYPES as DEFAULT_COMMIT_TYPES, type code_DependencyAuditDuplicate as DependencyAuditDuplicate, type code_DependencyAuditEntry as DependencyAuditEntry, type code_DependencyAuditIssue as DependencyAuditIssue, type code_DependencyAuditResult as DependencyAuditResult, type code_DependencyRangeType as DependencyRangeType, type code_DependencySection as DependencySection, type code_DockerImageRef as DockerImageRef, type code_EditorConfigIssue as EditorConfigIssue, type code_EditorConfigProperty as EditorConfigProperty, type code_EditorConfigSection as EditorConfigSection, type code_EditorConfigValidationResult as EditorConfigValidationResult, type code_EnvEntry as EnvEntry, type code_EnvParseResult as EnvParseResult, type code_ExportsIssue as ExportsIssue, type code_ExportsShape as ExportsShape, type code_ExportsValidationResult as ExportsValidationResult, type code_GitCommandConfig as GitCommandConfig, type code_GitCommandResult as GitCommandResult, type code_GitOperation as GitOperation, type code_GithubUrlInfo as GithubUrlInfo, type code_GithubUrlType as GithubUrlType, type code_GitignoreTestResult as GitignoreTestResult, type code_GqlFormatResult as GqlFormatResult, type code_HtmlFormatResult as HtmlFormatResult, type code_HtmlMinifyOptions as HtmlMinifyOptions, type code_HtmlMinifyResult as HtmlMinifyResult, type code_JsMinifyOptions as JsMinifyOptions, type code_JsMinifyResult as JsMinifyResult, code_MIME_TABLE as MIME_TABLE, type code_MatchResult as MatchResult, type code_MimeEntry as MimeEntry, type code_MimeLookupResult as MimeLookupResult, code_OPERATIONS as OPERATIONS, type code_ParsedSpec as ParsedSpec, type code_RedosFinding as RedosFinding, type code_RedosResult as RedosResult, type code_RedosSeverity as RedosSeverity, type code_RegexBackreferenceInfo as RegexBackreferenceInfo, type code_RegexError as RegexError, type code_RegexFlag as RegexFlag, type code_RegexGroupAnalysis as RegexGroupAnalysis, type code_RegexGroupInfo as RegexGroupInfo, type code_RegexGroupIssue as RegexGroupIssue, type code_RegexMatch as RegexMatch, type code_RegexResult as RegexResult, type code_RegexSuccess as RegexSuccess, code_SQL_DEFAULT_OPTIONS as SQL_DEFAULT_OPTIONS, type code_Segment as Segment, type code_SpecVersion as SpecVersion, type code_SqlDialect as SqlDialect, type code_SqlFormatOptions as SqlFormatOptions, type code_SvgSpriteResult as SvgSpriteResult, type code_SvgSpriteSymbol as SvgSpriteSymbol, type code_TestPatternResult as TestPatternResult, type code_TsconfigIssue as TsconfigIssue, type code_TsconfigValidationResult as TsconfigValidationResult, code_analyzeRegexGroups as analyzeRegexGroups, code_auditDependencyRanges as auditDependencyRanges, code_buildDockerPull as buildDockerPull, code_buildDockerRun as buildDockerRun, code_buildGitCommand as buildGitCommand, code_collapseHtmlWhitespace as collapseHtmlWhitespace, code_collapseJsWhitespace as collapseJsWhitespace, code_countProperties as countProperties, code_countRules as countRules, code_detectDialect as detectDialect, code_detectOperationType as detectOperationType, code_detectRedos as detectRedos, code_envToExport as envToExport, code_envToJson as envToJson, code_extractSvgSpriteSymbols as extractSvgSpriteSymbols, code_formatCss as formatCss, code_formatGql as formatGql, code_formatHtml as formatHtml, code_formatSql as formatSql, code_getEndpointsByTag as getEndpointsByTag, code_getHtmlStats as getHtmlStats, code_getJsStats as getJsStats, code_getMethodColor as getMethodColor, code_isValidTag as isValidTag, code_lintConventionalCommit as lintConventionalCommit, code_lookupMime as lookupMime, code_minifyCss as minifyCss, code_minifyGql as minifyGql, code_minifyHtml as minifyHtml, code_minifyJs as minifyJs, code_minifySql as minifySql, code_normalizeRef as normalizeRef, code_parseDockerImage as parseDockerImage, code_parseEnv as parseEnv, code_parseGitCommand as parseGitCommand, code_parseGithubUrl as parseGithubUrl, code_parseSpec as parseSpec, code_removeConsoleCalls as removeConsoleCalls, code_removeEmptyAttributes as removeEmptyAttributes, code_removeHtmlComments as removeHtmlComments, code_removeJsComments as removeJsComments, code_removeRedundantAttributes as removeRedundantAttributes, code_searchCheatsheet as searchCheatsheet, code_searchEndpoints as searchEndpoints, code_splitStatements as splitStatements, code_testGitignorePatterns as testGitignorePatterns, code_testPattern as testPattern, code_testRegex as testRegex, code_validateEditorConfig as validateEditorConfig, code_validateEnvKey as validateEnvKey, code_validatePackageExports as validatePackageExports, code_validateTsconfig as validateTsconfig };
755
+ export { code_ALL_FLAGS as ALL_FLAGS, type code_ApiEndpoint as ApiEndpoint, type code_ApiInfo as ApiInfo, code_CHEATSHEET as CHEATSHEET, type code_CheatsheetEntry as CheatsheetEntry, type code_CommitTrailer as CommitTrailer, type code_CommitTrailerResult as CommitTrailerResult, type code_ConventionalCommitFinding as ConventionalCommitFinding, type code_ConventionalCommitFooter as ConventionalCommitFooter, type code_ConventionalCommitOptions as ConventionalCommitOptions, type code_ConventionalCommitParsed as ConventionalCommitParsed, type code_ConventionalCommitResult as ConventionalCommitResult, type code_ConventionalCommitSeverity as ConventionalCommitSeverity, type code_CssResult as CssResult, code_DEFAULT_COMMIT_TYPES as DEFAULT_COMMIT_TYPES, type code_DependencyAuditDuplicate as DependencyAuditDuplicate, type code_DependencyAuditEntry as DependencyAuditEntry, type code_DependencyAuditIssue as DependencyAuditIssue, type code_DependencyAuditResult as DependencyAuditResult, type code_DependencyRangeType as DependencyRangeType, type code_DependencySection as DependencySection, type code_DockerImageRef as DockerImageRef, type code_EditorConfigIssue as EditorConfigIssue, type code_EditorConfigProperty as EditorConfigProperty, type code_EditorConfigSection as EditorConfigSection, type code_EditorConfigValidationResult as EditorConfigValidationResult, type code_EnvEntry as EnvEntry, type code_EnvParseResult as EnvParseResult, type code_ExportsIssue as ExportsIssue, type code_ExportsShape as ExportsShape, type code_ExportsValidationResult as ExportsValidationResult, type code_GitCommandConfig as GitCommandConfig, type code_GitCommandResult as GitCommandResult, type code_GitOperation as GitOperation, type code_GithubUrlInfo as GithubUrlInfo, type code_GithubUrlType as GithubUrlType, type code_GitignoreTestResult as GitignoreTestResult, type code_GqlFormatResult as GqlFormatResult, type code_HtmlFormatResult as HtmlFormatResult, type code_HtmlMinifyOptions as HtmlMinifyOptions, type code_HtmlMinifyResult as HtmlMinifyResult, type code_JsMinifyOptions as JsMinifyOptions, type code_JsMinifyResult as JsMinifyResult, code_MIME_TABLE as MIME_TABLE, type code_MarkdownFootnoteDefinition as MarkdownFootnoteDefinition, type code_MarkdownFootnoteReference as MarkdownFootnoteReference, type code_MarkdownFootnoteResult as MarkdownFootnoteResult, type code_MatchResult as MatchResult, type code_MimeEntry as MimeEntry, type code_MimeLookupResult as MimeLookupResult, code_OPERATIONS as OPERATIONS, type code_ParsedSpec as ParsedSpec, type code_RedosFinding as RedosFinding, type code_RedosResult as RedosResult, type code_RedosSeverity as RedosSeverity, type code_RegexBackreferenceInfo as RegexBackreferenceInfo, type code_RegexError as RegexError, type code_RegexFlag as RegexFlag, type code_RegexGroupAnalysis as RegexGroupAnalysis, type code_RegexGroupInfo as RegexGroupInfo, type code_RegexGroupIssue as RegexGroupIssue, type code_RegexMatch as RegexMatch, type code_RegexResult as RegexResult, type code_RegexSuccess as RegexSuccess, code_SQL_DEFAULT_OPTIONS as SQL_DEFAULT_OPTIONS, type code_Segment as Segment, type code_SpecVersion as SpecVersion, type code_SqlDialect as SqlDialect, type code_SqlFormatOptions as SqlFormatOptions, type code_SvgSpriteResult as SvgSpriteResult, type code_SvgSpriteSymbol as SvgSpriteSymbol, type code_TestPatternResult as TestPatternResult, type code_TsconfigIssue as TsconfigIssue, type code_TsconfigValidationResult as TsconfigValidationResult, code_analyzeRegexGroups as analyzeRegexGroups, code_auditDependencyRanges as auditDependencyRanges, code_buildDockerPull as buildDockerPull, code_buildDockerRun as buildDockerRun, code_buildGitCommand as buildGitCommand, code_collapseHtmlWhitespace as collapseHtmlWhitespace, code_collapseJsWhitespace as collapseJsWhitespace, code_countProperties as countProperties, code_countRules as countRules, code_detectDialect as detectDialect, code_detectOperationType as detectOperationType, code_detectRedos as detectRedos, code_envToExport as envToExport, code_envToJson as envToJson, code_extractMarkdownFootnotes as extractMarkdownFootnotes, code_extractSvgSpriteSymbols as extractSvgSpriteSymbols, code_formatCss as formatCss, code_formatGql as formatGql, code_formatHtml as formatHtml, code_formatSql as formatSql, code_getEndpointsByTag as getEndpointsByTag, code_getHtmlStats as getHtmlStats, code_getJsStats as getJsStats, code_getMethodColor as getMethodColor, code_isValidTag as isValidTag, code_lintConventionalCommit as lintConventionalCommit, code_lookupMime as lookupMime, code_minifyCss as minifyCss, code_minifyGql as minifyGql, code_minifyHtml as minifyHtml, code_minifyJs as minifyJs, code_minifySql as minifySql, code_normalizeRef as normalizeRef, code_parseCommitTrailers as parseCommitTrailers, code_parseDockerImage as parseDockerImage, code_parseEnv as parseEnv, code_parseGitCommand as parseGitCommand, code_parseGithubUrl as parseGithubUrl, code_parseSpec as parseSpec, code_removeConsoleCalls as removeConsoleCalls, code_removeEmptyAttributes as removeEmptyAttributes, code_removeHtmlComments as removeHtmlComments, code_removeJsComments as removeJsComments, code_removeRedundantAttributes as removeRedundantAttributes, code_searchCheatsheet as searchCheatsheet, code_searchEndpoints as searchEndpoints, code_splitStatements as splitStatements, code_testGitignorePatterns as testGitignorePatterns, code_testPattern as testPattern, code_testRegex as testRegex, code_validateEditorConfig as validateEditorConfig, code_validateEnvKey as validateEnvKey, code_validatePackageExports as validatePackageExports, code_validateTsconfig as validateTsconfig };
698
756
  }
699
757
 
700
- export { type RegexFlag as $, ALL_FLAGS as A, type GitCommandResult as B, CHEATSHEET as C, DEFAULT_COMMIT_TYPES as D, type EditorConfigIssue as E, type GitOperation as F, type GitCommandConfig as G, type GithubUrlInfo as H, type GithubUrlType as I, type GitignoreTestResult as J, type GqlFormatResult as K, type HtmlFormatResult as L, type HtmlMinifyOptions as M, type HtmlMinifyResult as N, type JsMinifyOptions as O, type JsMinifyResult as P, MIME_TABLE as Q, type MatchResult as R, type MimeEntry as S, type MimeLookupResult as T, OPERATIONS as U, type ParsedSpec as V, type RedosFinding as W, type RedosResult as X, type RedosSeverity as Y, type RegexBackreferenceInfo as Z, type RegexError as _, type ApiEndpoint as a, testRegex as a$, type RegexGroupAnalysis as a0, type RegexGroupInfo as a1, type RegexGroupIssue as a2, type RegexMatch as a3, type RegexResult as a4, type RegexSuccess as a5, SQL_DEFAULT_OPTIONS as a6, type Segment as a7, type SpecVersion as a8, type SqlDialect as a9, getHtmlStats as aA, getJsStats as aB, getMethodColor as aC, isValidTag as aD, lintConventionalCommit as aE, lookupMime as aF, minifyCss as aG, minifyGql as aH, minifyHtml as aI, minifyJs as aJ, minifySql as aK, normalizeRef as aL, parseDockerImage as aM, parseEnv as aN, parseGitCommand as aO, parseGithubUrl as aP, parseSpec as aQ, removeConsoleCalls as aR, removeEmptyAttributes as aS, removeHtmlComments as aT, removeJsComments as aU, removeRedundantAttributes as aV, searchCheatsheet as aW, searchEndpoints as aX, splitStatements as aY, testGitignorePatterns as aZ, testPattern as a_, type SqlFormatOptions as aa, type SvgSpriteResult as ab, type SvgSpriteSymbol as ac, type TestPatternResult as ad, type TsconfigIssue as ae, type TsconfigValidationResult as af, analyzeRegexGroups as ag, auditDependencyRanges as ah, buildDockerPull as ai, buildDockerRun as aj, buildGitCommand as ak, collapseHtmlWhitespace as al, collapseJsWhitespace as am, countProperties as an, countRules as ao, detectDialect as ap, detectOperationType as aq, detectRedos as ar, envToExport as as, envToJson as at, extractSvgSpriteSymbols as au, formatCss as av, formatGql as aw, formatHtml as ax, formatSql as ay, getEndpointsByTag as az, type ApiInfo as b, validateEditorConfig as b0, validateEnvKey as b1, validatePackageExports as b2, validateTsconfig as b3, code as c, type CheatsheetEntry as d, type ConventionalCommitFinding as e, type ConventionalCommitFooter as f, type ConventionalCommitOptions as g, type ConventionalCommitParsed as h, type ConventionalCommitResult as i, type ConventionalCommitSeverity as j, type CssResult as k, type DependencyAuditDuplicate as l, type DependencyAuditEntry as m, type DependencyAuditIssue as n, type DependencyAuditResult as o, type DependencyRangeType as p, type DependencySection as q, type DockerImageRef as r, type EditorConfigProperty as s, type EditorConfigSection as t, type EditorConfigValidationResult as u, type EnvEntry as v, type EnvParseResult as w, type ExportsIssue as x, type ExportsShape as y, type ExportsValidationResult as z };
758
+ export { type RedosFinding as $, ALL_FLAGS as A, type ExportsShape as B, CHEATSHEET as C, DEFAULT_COMMIT_TYPES as D, type EditorConfigIssue as E, type ExportsValidationResult as F, type GitCommandConfig as G, type GitCommandResult as H, type GitOperation as I, type GithubUrlInfo as J, type GithubUrlType as K, type GitignoreTestResult as L, type GqlFormatResult as M, type HtmlFormatResult as N, type HtmlMinifyOptions as O, type HtmlMinifyResult as P, type JsMinifyOptions as Q, type JsMinifyResult as R, MIME_TABLE as S, type MarkdownFootnoteDefinition as T, type MarkdownFootnoteReference as U, type MarkdownFootnoteResult as V, type MatchResult as W, type MimeEntry as X, type MimeLookupResult as Y, OPERATIONS as Z, type ParsedSpec as _, type ApiEndpoint as a, removeJsComments as a$, type RedosResult as a0, type RedosSeverity as a1, type RegexBackreferenceInfo as a2, type RegexError as a3, type RegexFlag as a4, type RegexGroupAnalysis as a5, type RegexGroupInfo as a6, type RegexGroupIssue as a7, type RegexMatch as a8, type RegexResult as a9, extractSvgSpriteSymbols as aA, formatCss as aB, formatGql as aC, formatHtml as aD, formatSql as aE, getEndpointsByTag as aF, getHtmlStats as aG, getJsStats as aH, getMethodColor as aI, isValidTag as aJ, lintConventionalCommit as aK, lookupMime as aL, minifyCss as aM, minifyGql as aN, minifyHtml as aO, minifyJs as aP, minifySql as aQ, normalizeRef as aR, parseCommitTrailers as aS, parseDockerImage as aT, parseEnv as aU, parseGitCommand as aV, parseGithubUrl as aW, parseSpec as aX, removeConsoleCalls as aY, removeEmptyAttributes as aZ, removeHtmlComments as a_, type RegexSuccess as aa, SQL_DEFAULT_OPTIONS as ab, type Segment as ac, type SpecVersion as ad, type SqlDialect as ae, type SqlFormatOptions as af, type SvgSpriteResult as ag, type SvgSpriteSymbol as ah, type TestPatternResult as ai, type TsconfigIssue as aj, type TsconfigValidationResult as ak, analyzeRegexGroups as al, auditDependencyRanges as am, buildDockerPull as an, buildDockerRun as ao, buildGitCommand as ap, collapseHtmlWhitespace as aq, collapseJsWhitespace as ar, countProperties as as, countRules as at, detectDialect as au, detectOperationType as av, detectRedos as aw, envToExport as ax, envToJson as ay, extractMarkdownFootnotes as az, type ApiInfo as b, removeRedundantAttributes as b0, searchCheatsheet as b1, searchEndpoints as b2, splitStatements as b3, testGitignorePatterns as b4, testPattern as b5, testRegex as b6, validateEditorConfig as b7, validateEnvKey as b8, validatePackageExports as b9, validateTsconfig as ba, code as c, type CheatsheetEntry as d, type CommitTrailer as e, type CommitTrailerResult as f, type ConventionalCommitFinding as g, type ConventionalCommitFooter as h, type ConventionalCommitOptions as i, type ConventionalCommitParsed as j, type ConventionalCommitResult as k, type ConventionalCommitSeverity as l, type CssResult as m, type DependencyAuditDuplicate as n, type DependencyAuditEntry as o, type DependencyAuditIssue as p, type DependencyAuditResult as q, type DependencyRangeType as r, type DependencySection as s, type DockerImageRef as t, type EditorConfigProperty as u, type EditorConfigSection as v, type EditorConfigValidationResult as w, type EnvEntry as x, type EnvParseResult as y, type ExportsIssue as z };
package/dist/index.cjs CHANGED
@@ -8581,6 +8581,7 @@ __export(units_exports, {
8581
8581
  calculateSavingsGoal: () => calculateSavingsGoal,
8582
8582
  calculateSimpleInterest: () => calculateSimpleInterest,
8583
8583
  calculateTax: () => calculateTax,
8584
+ calculateTaxEquivalentYield: () => calculateTaxEquivalentYield,
8584
8585
  calculateTimeValue: () => calculateTimeValue,
8585
8586
  calculateTipSplit: () => calculateTipSplit,
8586
8587
  calculateVideoBitrate: () => calculateVideoBitrate,
@@ -11037,6 +11038,45 @@ function calculateLoanRefinance(currentBalance, currentRatePercent, currentRemai
11037
11038
  totalInterestSavings: round2(current.totalInterest - refinanced.totalInterest)
11038
11039
  };
11039
11040
  }
11041
+ function calculateTaxEquivalentYield(inputYieldPercent, federalTaxRatePercent, stateTaxRatePercent = 0, direction) {
11042
+ if (!Number.isFinite(inputYieldPercent) || inputYieldPercent < 0) {
11043
+ return { error: "Yield must be zero or a positive number" };
11044
+ }
11045
+ if (!Number.isFinite(federalTaxRatePercent) || federalTaxRatePercent < 0 || federalTaxRatePercent >= 100) {
11046
+ return { error: "Federal tax rate must be a percentage between 0 and 100 (exclusive of 100)" };
11047
+ }
11048
+ if (!Number.isFinite(stateTaxRatePercent) || stateTaxRatePercent < 0 || stateTaxRatePercent >= 100) {
11049
+ return { error: "State tax rate must be a percentage between 0 and 100 (exclusive of 100)" };
11050
+ }
11051
+ if (direction !== "tax-free-to-taxable" && direction !== "taxable-to-tax-free") {
11052
+ return { error: 'Direction must be "tax-free-to-taxable" or "taxable-to-tax-free"' };
11053
+ }
11054
+ const combinedTaxRatePercent = federalTaxRatePercent + stateTaxRatePercent;
11055
+ if (combinedTaxRatePercent >= 100) {
11056
+ return { error: "Combined federal and state tax rate must be less than 100%" };
11057
+ }
11058
+ const round6 = (n) => Math.round(n * 1e6) / 1e6;
11059
+ const combinedRateDecimal = combinedTaxRatePercent / 100;
11060
+ let taxFreeYield;
11061
+ let taxableYield;
11062
+ if (direction === "tax-free-to-taxable") {
11063
+ taxFreeYield = inputYieldPercent;
11064
+ taxableYield = taxFreeYield / (1 - combinedRateDecimal);
11065
+ } else {
11066
+ taxableYield = inputYieldPercent;
11067
+ taxFreeYield = taxableYield * (1 - combinedRateDecimal);
11068
+ }
11069
+ return {
11070
+ direction,
11071
+ inputYield: round6(inputYieldPercent),
11072
+ federalTaxRatePercent: round6(federalTaxRatePercent),
11073
+ stateTaxRatePercent: round6(stateTaxRatePercent),
11074
+ combinedTaxRatePercent: round6(combinedTaxRatePercent),
11075
+ taxFreeYield: round6(taxFreeYield),
11076
+ taxableYield: round6(taxableYield),
11077
+ yieldDifference: round6(taxableYield - taxFreeYield)
11078
+ };
11079
+ }
11040
11080
 
11041
11081
  // src/tools/network.ts
11042
11082
  var network_exports = {};
@@ -14547,7 +14587,9 @@ __export(api_exports, {
14547
14587
  generateCors: () => generateCors,
14548
14588
  generateCspHeader: () => generateCspHeader,
14549
14589
  generateFullHeader: () => generateFullHeader,
14590
+ generateHotp: () => generateHotp,
14550
14591
  generateMetaHtml: () => generateMetaHtml,
14592
+ generateTotp: () => generateTotp,
14551
14593
  getParam: () => getParam,
14552
14594
  getStats: () => getStats,
14553
14595
  isValidUrl: () => isValidUrl,
@@ -15826,6 +15868,75 @@ function generateMetaHtml(tags) {
15826
15868
  }
15827
15869
  return lines.join("\n");
15828
15870
  }
15871
+ var OTP_ALG_TO_NODE_HASH = {
15872
+ SHA1: "sha1",
15873
+ SHA256: "sha256",
15874
+ SHA512: "sha512"
15875
+ };
15876
+ function decodeBase32Secret(secret) {
15877
+ const alphabet = "ABCDEFGHIJKLMNOPQRSTUVWXYZ234567";
15878
+ const cleaned = secret.toUpperCase().replace(/[\s=]/g, "");
15879
+ if (!cleaned) {
15880
+ return { error: "Secret must not be empty" };
15881
+ }
15882
+ const bytes = [];
15883
+ let buffer = 0;
15884
+ let bitsLeft = 0;
15885
+ for (const char of cleaned) {
15886
+ const val = alphabet.indexOf(char);
15887
+ if (val === -1) {
15888
+ return { error: `Invalid base32 character '${char}' in secret` };
15889
+ }
15890
+ buffer = buffer << 5 | val;
15891
+ bitsLeft += 5;
15892
+ if (bitsLeft >= 8) {
15893
+ bitsLeft -= 8;
15894
+ bytes.push(buffer >> bitsLeft & 255);
15895
+ }
15896
+ }
15897
+ return Buffer.from(bytes);
15898
+ }
15899
+ function hotpFromCounter(keyBytes, counter, digits, algorithm) {
15900
+ const counterBuffer = Buffer.alloc(8);
15901
+ counterBuffer.writeUInt32BE(Math.floor(counter / 4294967296), 0);
15902
+ counterBuffer.writeUInt32BE(counter % 4294967296, 4);
15903
+ const hmac = crypto.createHmac(OTP_ALG_TO_NODE_HASH[algorithm], keyBytes).update(counterBuffer).digest();
15904
+ const offset = hmac[hmac.length - 1] & 15;
15905
+ const binCode = (hmac[offset] & 127) << 24 | (hmac[offset + 1] & 255) << 16 | (hmac[offset + 2] & 255) << 8 | hmac[offset + 3] & 255;
15906
+ const code = (binCode % 10 ** digits).toString().padStart(digits, "0");
15907
+ return code;
15908
+ }
15909
+ function generateHotp(secret, counter, options = {}) {
15910
+ const digits = options.digits ?? 6;
15911
+ const algorithm = options.algorithm ?? "SHA1";
15912
+ if (!Number.isInteger(counter) || counter < 0) {
15913
+ return { error: "Counter must be a non-negative whole number" };
15914
+ }
15915
+ if (!Number.isInteger(digits) || digits < 6 || digits > 8) {
15916
+ return { error: "Digits must be an integer between 6 and 8" };
15917
+ }
15918
+ if (!(algorithm in OTP_ALG_TO_NODE_HASH)) {
15919
+ return { error: "Algorithm must be one of SHA1, SHA256, SHA512" };
15920
+ }
15921
+ const keyBytes = decodeBase32Secret(secret);
15922
+ if ("error" in keyBytes) return keyBytes;
15923
+ return { code: hotpFromCounter(keyBytes, counter, digits, algorithm), counter, digits, algorithm };
15924
+ }
15925
+ function generateTotp(secret, options = {}) {
15926
+ const periodSeconds = options.periodSeconds ?? 30;
15927
+ const timestamp = options.timestamp ?? Math.floor(Date.now() / 1e3);
15928
+ if (!Number.isFinite(periodSeconds) || periodSeconds <= 0) {
15929
+ return { error: "Period must be a positive number of seconds" };
15930
+ }
15931
+ if (!Number.isFinite(timestamp) || timestamp < 0) {
15932
+ return { error: "Timestamp must be a non-negative number of seconds" };
15933
+ }
15934
+ const counter = Math.floor(timestamp / periodSeconds);
15935
+ const hotp = generateHotp(secret, counter, options);
15936
+ if ("error" in hotp) return hotp;
15937
+ const secondsRemaining = periodSeconds - timestamp % periodSeconds;
15938
+ return { ...hotp, periodSeconds, secondsRemaining };
15939
+ }
15829
15940
 
15830
15941
  // src/tools/code.ts
15831
15942
  var code_exports = {};
@@ -15850,6 +15961,7 @@ __export(code_exports, {
15850
15961
  detectRedos: () => detectRedos,
15851
15962
  envToExport: () => envToExport2,
15852
15963
  envToJson: () => envToJson2,
15964
+ extractMarkdownFootnotes: () => extractMarkdownFootnotes,
15853
15965
  extractSvgSpriteSymbols: () => extractSvgSpriteSymbols,
15854
15966
  formatCss: () => formatCss,
15855
15967
  formatGql: () => formatGql,
@@ -15868,6 +15980,7 @@ __export(code_exports, {
15868
15980
  minifyJs: () => minifyJs,
15869
15981
  minifySql: () => minifySql,
15870
15982
  normalizeRef: () => normalizeRef,
15983
+ parseCommitTrailers: () => parseCommitTrailers,
15871
15984
  parseDockerImage: () => parseDockerImage,
15872
15985
  parseEnv: () => parseEnv2,
15873
15986
  parseGitCommand: () => parseGitCommand,
@@ -19451,6 +19564,93 @@ function extractSvgSpriteSymbols(svg) {
19451
19564
  }
19452
19565
  return { symbolCount: symbols.length, symbols, skippedCount };
19453
19566
  }
19567
+ var TRAILER_LINE_REGEX = /^([A-Za-z][A-Za-z0-9-]*): (.+)$/;
19568
+ var TRAILER_CONTINUATION_REGEX = /^[ \t]+\S/;
19569
+ function parseCommitTrailers(message) {
19570
+ const lines = message.replace(/\r\n/g, "\n").split("\n");
19571
+ while (lines.length > 0 && lines[lines.length - 1].trim() === "") lines.pop();
19572
+ if (lines.length === 0) return { error: "Empty input" };
19573
+ let start = 0;
19574
+ for (let i = lines.length - 1; i >= 0; i--) {
19575
+ if (lines[i].trim() === "") {
19576
+ start = i + 1;
19577
+ break;
19578
+ }
19579
+ }
19580
+ const paragraph = lines.slice(start);
19581
+ const trailers = [];
19582
+ let valid = true;
19583
+ for (const line of paragraph) {
19584
+ const m = line.match(TRAILER_LINE_REGEX);
19585
+ if (m) {
19586
+ trailers.push({ key: m[1], value: m[2].trim() });
19587
+ } else if (TRAILER_CONTINUATION_REGEX.test(line) && trailers.length > 0) {
19588
+ trailers[trailers.length - 1].value += " " + line.trim();
19589
+ } else {
19590
+ valid = false;
19591
+ break;
19592
+ }
19593
+ }
19594
+ if (!valid || trailers.length === 0) {
19595
+ return { trailers: [], body: lines.join("\n").trim(), hasTrailers: false };
19596
+ }
19597
+ const body = lines.slice(0, start).join("\n").trim();
19598
+ return { trailers, body, hasTrailers: true };
19599
+ }
19600
+ var FOOTNOTE_DEFINITION_LINE_REGEX = /^\[\^([^\]]+)\]:\s?(.*)$/;
19601
+ var FOOTNOTE_CONTINUATION_REGEX = /^(?: {4}|\t)/;
19602
+ var FOOTNOTE_REFERENCE_REGEX = /\[\^([^\]]+)\]/g;
19603
+ function extractMarkdownFootnotes(markdown) {
19604
+ const trimmed = markdown.trim();
19605
+ if (!trimmed) return { error: "Empty input" };
19606
+ if (!trimmed.includes("[^")) return { error: "No footnote references or definitions found" };
19607
+ const lines = markdown.replace(/\r\n/g, "\n").split("\n");
19608
+ const definitions = [];
19609
+ const definedLabels = /* @__PURE__ */ new Set();
19610
+ const consumed = new Array(lines.length).fill(false);
19611
+ let i = 0;
19612
+ while (i < lines.length) {
19613
+ const match = lines[i].match(FOOTNOTE_DEFINITION_LINE_REGEX);
19614
+ if (!match) {
19615
+ i++;
19616
+ continue;
19617
+ }
19618
+ const label = match[1];
19619
+ const textLines = [match[2]];
19620
+ consumed[i] = true;
19621
+ let j = i + 1;
19622
+ while (j < lines.length && (FOOTNOTE_CONTINUATION_REGEX.test(lines[j]) || lines[j].trim() === "" && j + 1 < lines.length && FOOTNOTE_CONTINUATION_REGEX.test(lines[j + 1]))) {
19623
+ textLines.push(lines[j].trim() === "" ? "" : lines[j].replace(FOOTNOTE_CONTINUATION_REGEX, ""));
19624
+ consumed[j] = true;
19625
+ j++;
19626
+ }
19627
+ if (!definedLabels.has(label)) {
19628
+ definedLabels.add(label);
19629
+ definitions.push({ label, text: textLines.join("\n").trim() });
19630
+ }
19631
+ i = j;
19632
+ }
19633
+ const referenceScanText = lines.filter((_, idx) => !consumed[idx]).join("\n");
19634
+ const refOrder = [];
19635
+ const refCounts = /* @__PURE__ */ new Map();
19636
+ for (const m of referenceScanText.matchAll(FOOTNOTE_REFERENCE_REGEX)) {
19637
+ const label = m[1];
19638
+ if (!refCounts.has(label)) {
19639
+ refCounts.set(label, 0);
19640
+ refOrder.push(label);
19641
+ }
19642
+ refCounts.set(label, (refCounts.get(label) ?? 0) + 1);
19643
+ }
19644
+ const references = refOrder.map((label) => ({ label, count: refCounts.get(label) ?? 0 }));
19645
+ const referencedSet = new Set(refOrder);
19646
+ const unresolvedReferences = refOrder.filter((label) => !definedLabels.has(label));
19647
+ const unusedDefinitions = definitions.filter((d) => !referencedSet.has(d.label)).map((d) => d.label);
19648
+ const referenceCount = refOrder.reduce((sum, label) => sum + (refCounts.get(label) ?? 0), 0);
19649
+ if (definitions.length === 0 && references.length === 0) {
19650
+ return { error: "No footnote references or definitions found" };
19651
+ }
19652
+ return { definitionCount: definitions.length, referenceCount, definitions, references, unresolvedReferences, unusedDefinitions };
19653
+ }
19454
19654
 
19455
19655
  // src/tools/color.ts
19456
19656
  var color_exports = {};
package/dist/index.d.cts CHANGED
@@ -5,10 +5,10 @@ export { t as text } from './text-DWUcY8H1.cjs';
5
5
  export { d as data } from './data-26TALa9U.cjs';
6
6
  export { g as generators } from './generators-DAXXrMvG.cjs';
7
7
  export { t as time } from './time-KqJjdqII.cjs';
8
- export { u as units } from './units-DPefgzmH.cjs';
8
+ export { u as units } from './units-BT8P27G0.cjs';
9
9
  export { n as network } from './network-BmqYmfqY.cjs';
10
- export { a as api } from './api-DmTNE4c1.cjs';
11
- export { c as code } from './code-DB-5ZfG4.cjs';
10
+ export { a as api } from './api-C8rImfka.cjs';
11
+ export { c as code } from './code-CoeD4Fmq.cjs';
12
12
  export { c as color } from './color-tPwZCr9H.cjs';
13
13
  export { c as css } from './css-Cf7AMGM-.cjs';
14
14
  export { m as misc } from './misc-CA3N198T.cjs';
package/dist/index.d.ts CHANGED
@@ -5,10 +5,10 @@ export { t as text } from './text-DWUcY8H1.js';
5
5
  export { d as data } from './data-26TALa9U.js';
6
6
  export { g as generators } from './generators-DAXXrMvG.js';
7
7
  export { t as time } from './time-KqJjdqII.js';
8
- export { u as units } from './units-DPefgzmH.js';
8
+ export { u as units } from './units-BT8P27G0.js';
9
9
  export { n as network } from './network-BmqYmfqY.js';
10
- export { a as api } from './api-DmTNE4c1.js';
11
- export { c as code } from './code-DB-5ZfG4.js';
10
+ export { a as api } from './api-C8rImfka.js';
11
+ export { c as code } from './code-CoeD4Fmq.js';
12
12
  export { c as color } from './color-tPwZCr9H.js';
13
13
  export { c as css } from './css-Cf7AMGM-.js';
14
14
  export { m as misc } from './misc-CA3N198T.js';
package/dist/index.js CHANGED
@@ -1,8 +1,8 @@
1
1
  export { media_exports as media } from './chunk-226EH3ZI.js';
2
- export { units_exports as units } from './chunk-4HNHEOJL.js';
2
+ export { units_exports as units } from './chunk-653HDWXW.js';
3
3
  export { network_exports as network } from './chunk-ACGCCOCK.js';
4
- export { api_exports as api } from './chunk-52ZDKSIX.js';
5
- export { code_exports as code } from './chunk-COL3IM7U.js';
4
+ export { api_exports as api } from './chunk-4S63T7Y4.js';
5
+ export { code_exports as code } from './chunk-DAD2ZOTJ.js';
6
6
  export { color_exports as color } from './chunk-BPVAB4P2.js';
7
7
  export { css_exports as css } from './chunk-6YPV2AB5.js';
8
8
  export { misc_exports as misc } from './chunk-GX7H6TAX.js';