@hackplan/polaris
Version:
Shopify’s product component library
21 lines (20 loc) • 1.05 kB
TypeScript
import { ClientApplication } from '@shopify/app-bridge';
import { Button, ButtonGroup } from '@shopify/app-bridge/actions';
import { ActionGroupDescriptor } from '../components/Page/components/Header/components/ActionGroup';
import { AppBridgeTarget, ComplexAction } from '../types';
export declare function generateRedirect(appBridge: ClientApplication<{}>, url?: string, target?: AppBridgeTarget, external?: boolean): (() => void) | undefined;
export declare function transformActions(appBridge: ClientApplication<{}>, { primaryAction, secondaryActions, }: {
primaryAction?: ComplexAction;
secondaryActions?: ComplexAction[];
}): {
primary?: Button.Button;
secondary?: Button.Button[];
};
export declare function transformActions(appBridge: ClientApplication<{}>, { primaryAction, secondaryActions, actionGroups, }: {
primaryAction?: ComplexAction;
secondaryActions?: ComplexAction[];
actionGroups?: ActionGroupDescriptor[];
}): {
primary?: Button.Button;
secondary?: (Button.Button | ButtonGroup.ButtonGroup)[];
};