mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-20 15:18:08 +02:00
[Editor] Show hidden annotations once editing is finished
This commit is contained in:
parent
04c31a55d2
commit
ae3cee95a6
2 changed files with 55 additions and 0 deletions
|
@ -431,4 +431,41 @@ describe("ResetForm action", () => {
|
|||
});
|
||||
});
|
||||
});
|
||||
|
||||
describe("Ink widget and its popup after editing", () => {
|
||||
describe("annotation-caret-ink.pdf", () => {
|
||||
let pages;
|
||||
|
||||
beforeAll(async () => {
|
||||
pages = await loadAndWait(
|
||||
"annotation-caret-ink.pdf",
|
||||
"[data-annotation-id='25R']"
|
||||
);
|
||||
});
|
||||
|
||||
afterAll(async () => {
|
||||
await closePages(pages);
|
||||
});
|
||||
|
||||
it("must check that the annotation has a popup", async () => {
|
||||
await Promise.all(
|
||||
pages.map(async ([browserName, page]) => {
|
||||
await page.waitForFunction(
|
||||
`document.querySelector("[data-annotation-id='25R']").hidden === false`
|
||||
);
|
||||
await page.click("#editorFreeText");
|
||||
await page.waitForTimeout(10);
|
||||
await page.waitForFunction(
|
||||
`document.querySelector("[data-annotation-id='25R']").hidden === true`
|
||||
);
|
||||
await page.click("#editorFreeText");
|
||||
await page.waitForTimeout(10);
|
||||
await page.waitForFunction(
|
||||
`document.querySelector("[data-annotation-id='25R']").hidden === false`
|
||||
);
|
||||
})
|
||||
);
|
||||
});
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue