fix(anatomy): name both D11 pick sites, restore the spy in afterEach
This commit is contained in:
1 parent
706c056646
commit
d01019d6c7
2 files changed
+8
-4
No files matched your search
@@ -17,7 +17,10 @@ let sheet: SheetIndex
|
||||
beforeAll(async () => {
|
||||
sheet = await loadTestSheet()
|
||||
})
|
||||
afterEach(cleanup)
|
||||
afterEach(() => {
|
||||
cleanup()
|
||||
vi.restoreAllMocks()
|
||||
})
|
||||
|
||||
/** The composed view, or a test failure naming why it is missing. */
|
||||
function svgOf(index: SheetIndex, viewId: string): SVGSVGElement {
|
||||
@@ -110,7 +113,6 @@ describe('AnatomyCanvas', () => {
|
||||
const name = hip.getAttribute('data-anno-name-fr')
|
||||
expect(name).toBeTruthy()
|
||||
expect(container.textContent).toContain(name)
|
||||
vi.restoreAllMocks()
|
||||
})
|
||||
|
||||
it('applies the states right after the build, on both elements of a point', async () => {
|
||||
|
||||
@@ -69,8 +69,10 @@ id or a class.
|
||||
|
||||
An access (kind `detail_trigger`) never hides another annotation (D11). On the
|
||||
editor, the catalogue and the bilan, the page reads every element under the
|
||||
pointer (`elementsFromPoint`, bounded to the canvas, `anatomy/annotationPick.ts`)
|
||||
and takes the first annotation that is not an access; an access answers only
|
||||
pointer (`elementsFromPoint`, bounded to the canvas) and takes the first
|
||||
annotation that is not an access (`anatomy/annotationPick.ts` for the catalogue
|
||||
and the bilan; the editor applies the same rule in `editor/annotations/press.ts`,
|
||||
`Hit.access` and `pressTarget`, bounded by the viewport); an access answers only
|
||||
where no other annotation lies. The same pick drives the click and the tooltip.
|
||||
The paint order of the core is unchanged. The access labels (Part 6) are page
|
||||
buttons over the drawing, outside the layer. The canvas sets and removes
|
||||
|
||||
Reference in new issue
Block a user