mirror of
https://github.com/jzillmann/pdf-to-markdown.git
synced 2024-11-21 23:33:31 +01:00
Summary for detect footnotes
This commit is contained in:
parent
55506576f5
commit
a76dac6428
@ -78,6 +78,7 @@ export default class DebugView extends React.Component {
|
||||
}
|
||||
|
||||
parseResult.content = parseResult.content.filter((elem, i) => pageNr == -1 || i == pageNr);
|
||||
const summaryComponent = lastTransformation.createSummaryView(parseResult.summary);
|
||||
const pageComponents = parseResult.content.map(page => lastTransformation.createPageView(page, this.state.modificationsOnly));
|
||||
const showModificationCheckbox = lastTransformation.showModificationCheckbox();
|
||||
|
||||
@ -152,6 +153,7 @@ export default class DebugView extends React.Component {
|
||||
</tbody>
|
||||
</table>
|
||||
<hr/>
|
||||
{ summaryComponent }
|
||||
{ pageComponents }
|
||||
</div>
|
||||
);
|
||||
|
@ -1,3 +1,4 @@
|
||||
import React from 'react';
|
||||
import ToPdfViewTransformation from './ToPdfViewTransformation.jsx';
|
||||
import TextItem from '../TextItem.jsx';
|
||||
import ParseResult from '../ParseResult.jsx';
|
||||
@ -11,6 +12,14 @@ export default class DetectFootnotes extends ToPdfViewTransformation {
|
||||
super("Detect Footnotes");
|
||||
}
|
||||
|
||||
createSummaryView(summary) {
|
||||
return <div>
|
||||
Detected
|
||||
{ ' ' + summary.footnotes + ' ' } footnotes.
|
||||
</div>;
|
||||
}
|
||||
|
||||
|
||||
transform(parseResult:ParseResult) {
|
||||
|
||||
var nextFooterNumber = 1;
|
||||
|
@ -21,6 +21,10 @@ export default class Transformation {
|
||||
return false;
|
||||
}
|
||||
|
||||
createSummaryView(summary) { // eslint-disable-line no-unused-vars
|
||||
return null;
|
||||
}
|
||||
|
||||
createPageView(page, modificationsOnly) { // eslint-disable-line no-unused-vars
|
||||
throw new TypeError("Do not call abstract method foo from child.");
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user