@wordpress/widget-dashboard
Version:
Stateless rendering engine for widget dashboards: the WidgetDashboard compound component and its grid-settings kit.
12 lines • 636 B
TypeScript
import type { WidgetAction, WidgetHostLinks } from '@wordpress/widget-primitives';
/**
* Resolves the in-app route path of a link action. `download` (any value
* but `false`) and `openInNewTab` keep the plain anchor: both mean a new
* document.
*
* @param {WidgetHostLinks | undefined} links The host's `links` capability.
* @param {WidgetAction} action The action whose target to resolve.
* @return {string | null} The in-app route path, or `null`.
*/
export declare function getActionRoute(links: WidgetHostLinks | undefined, action: WidgetAction): string | null;
//# sourceMappingURL=get-action-route.d.ts.map