We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
command
commandFor
1 parent 4ef3857 commit 7f14577Copy full SHA for 7f14577
1 file changed
src/types/component-props.ts
@@ -4,6 +4,17 @@ import type {ComponentChildren} from 'preact';
4
* Shared props for components that accept children.
5
*/
6
export interface BaseProps {
7
+ /**
8
+ * A command to invoke on `commandFor` target.
9
+ * Custom commands begin with `--` and fire a "command" event on the target.
10
+ */
11
+ command?: 'show-modal' | 'close' | 'show-popover' | 'hide-popover' | 'toggle-popover' | `--${string}` | null;
12
+
13
14
+ * ID of a DOM element or PUI component to invoke `command` on.
15
16
+ commandFor?: string | null;
17
18
/**
19
* Component contents.
20
0 commit comments