fix: conditionally hide dot menu in DocumentControls (#4075)

This commit is contained in:
Patrik
2023-11-09 12:01:58 -05:00
committed by GitHub
parent 7059a71243
commit cef4cbb0ee
2 changed files with 14 additions and 3 deletions

View File

@@ -179,6 +179,12 @@ describe('access control', () => {
await page.goto(readOnlyUrl.edit(existingDoc.id))
await expect(page.locator('#field-name')).toBeDisabled()
})
test('should not render dot menu popup when `create` and `delete` access control is set to false', async () => {
await page.goto(readOnlyUrl.edit(existingDoc.id))
await wait(1000)
await expect(page.locator('.collection-edit .doc-controls .doc-controls__popup')).toBeHidden()
})
})
describe('readVersions', () => {