Split screen and print CSS completely, add print parent element.

This commit is contained in:
Ian Gulliver
2018-11-25 02:12:37 +00:00
parent ce3f7a683d
commit b31a5446aa
2 changed files with 241 additions and 206 deletions

View File

@@ -23,14 +23,7 @@ class PassMate {
this.addOverview(container);
this.addPages(container, 26 * 2 + 4);
this.addFrontPage(this.pages[1]);
this.addInstructions1(this.pages[2]);
this.addInstructions2(this.pages[3]);
this.addPasswordPages(
this.pages.slice(4, 4 + (26 * this.PAGES_PER_LETTER)),
this.PAGES_PER_LETTER,
this.PASSWORDS_PER_PAGE);
this.addProduct(container);
this.recoveryIn.innerText = this.SAFE_ALPHANUM.charAt(this.VERSION) + this.generateMasterPassword().join('');
this.derivePasswords();
@@ -118,6 +111,18 @@ class PassMate {
});
}
addProduct(container) {
let product = this.addElement('product', container);
this.addPages(product, 26 * 2 + 4);
this.addFrontPage(this.pages[1]);
this.addInstructions1(this.pages[2]);
this.addInstructions2(this.pages[3]);
this.addPasswordPages(
this.pages.slice(4, 4 + (26 * this.PAGES_PER_LETTER)),
this.PAGES_PER_LETTER,
this.PASSWORDS_PER_PAGE);
}
addPages(container, numPages) {
let numSheets = numPages / 4;
for (let sheetNum = 0; sheetNum < numSheets; ++sheetNum) {