From 1a9104b5f3e125c1c609fbdb708fbbb51990f546 Mon Sep 17 00:00:00 2001 From: "Alexey Mulyukin (alexprey)" Date: Tue, 14 Dec 2021 17:41:04 +0300 Subject: [PATCH] feat(#80): add support for self and trusted event modificators --- .../integration/events/event.markup.modificators.svelte | 2 +- test/svelte3/integration/events/events.spec.js | 2 +- typings.d.ts | 4 +++- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/test/svelte3/integration/events/event.markup.modificators.svelte b/test/svelte3/integration/events/event.markup.modificators.svelte index c652aa7..78deb39 100644 --- a/test/svelte3/integration/events/event.markup.modificators.svelte +++ b/test/svelte3/integration/events/event.markup.modificators.svelte @@ -1,6 +1,6 @@
-
\ No newline at end of file diff --git a/test/svelte3/integration/events/events.spec.js b/test/svelte3/integration/events/events.spec.js index 73f4891..4569737 100644 --- a/test/svelte3/integration/events/events.spec.js +++ b/test/svelte3/integration/events/events.spec.js @@ -25,7 +25,7 @@ describe('SvelteDoc v3 - Events', () => { expect(event.description).to.equal('Event fired when user clicked on button.'); expect(event.modificators).to.eql([ - 'once', 'preventDefault' + 'once', 'preventDefault', 'stopPropagation', 'passive', 'nonpassive', 'capture', 'self', 'trusted' ]); done(); diff --git a/typings.d.ts b/typings.d.ts index 131f8f5..875852a 100644 --- a/typings.d.ts +++ b/typings.d.ts @@ -301,7 +301,9 @@ export type SvelteEventModificator = | 'passive' | 'capture' | 'once' - | 'nonpassive'; + | 'nonpassive' + | 'self' + | 'trusted'; export interface SvelteEventItem extends ISvelteItem { /**