defuddle 0.3.4 → 0.3.6

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/README.md CHANGED
@@ -129,7 +129,7 @@ Inline references and footnotes are converted to a standard format:
129
129
  ```html
130
130
  Inline reference<sup id="fnref:1"><a href="#fn:1">1</a></sup>.
131
131
 
132
- <div class="footnotes">
132
+ <div id="footnotes">
133
133
  <ol>
134
134
  <li class="footnote" id="fn:1">
135
135
  <p>
@@ -12,4 +12,3 @@ export declare const FOOTNOTE_LIST_SELECTORS: string;
12
12
  export declare const ALLOWED_EMPTY_ELEMENTS: Set<string>;
13
13
  export declare const ALLOWED_ATTRIBUTES: Set<string>;
14
14
  export declare const ALLOWED_ATTRIBUTES_DEBUG: Set<string>;
15
- export declare const SUPPORTED_LANGUAGES: Set<string>;
@@ -27,6 +27,7 @@ export declare class Defuddle {
27
27
  private removeHtmlComments;
28
28
  private stripUnwantedAttributes;
29
29
  private removeEmptyElements;
30
+ private stripExtraBrElements;
30
31
  private removeEmptyLines;
31
32
  private createFootnoteItem;
32
33
  private collectFootnotes;
@@ -0,0 +1,5 @@
1
+ export declare const codeBlockRules: {
2
+ selector: string;
3
+ element: string;
4
+ transform: (el: Element) => Element;
5
+ }[];
@@ -0,0 +1,5 @@
1
+ export declare const headingRules: {
2
+ selector: string;
3
+ element: string;
4
+ transform: (el: Element) => Element;
5
+ }[];
@@ -1,6 +1,6 @@
1
1
  import { MathData } from './math.base';
2
2
  export declare const createCleanMathEl: (mathData: MathData | null, latex: string | null, isBlock: boolean) => Element;
3
- export declare const mathStandardizationRules: {
3
+ export declare const mathRules: {
4
4
  selector: string;
5
5
  element: string;
6
6
  transform: (el: Element) => Element;
@@ -0,0 +1,2 @@
1
+ export type { MathData } from './math.base';
2
+ export { mathRules, createCleanMathEl } from './math.core';
@@ -1,7 +1,7 @@
1
1
  import { MathData } from './math.base';
2
2
  export declare const getLatexFromElement: (el: Element) => string | null;
3
3
  export declare const createCleanMathEl: (mathData: MathData | null, latex: string | null, isBlock: boolean) => Element;
4
- export declare const mathStandardizationRules: {
4
+ export declare const mathRules: {
5
5
  selector: string;
6
6
  element: string;
7
7
  transform: (el: Element) => Element;