@airplane/views
Version:
A React library for building Airplane views. Views components are optimized in style and functionality to produce internal apps that are easy to build and maintain.
19 lines (18 loc) • 754 B
TypeScript
/// <reference types="react" />
import { CommonStylingProps } from "../../components/styling.types";
import { TextPropsBase } from "../../components/text/Text.types";
import { NavigateParams } from "../../routing";
export type PropsBase = {
/**
* Either a string URL to navigate to when the button is clicked, or a task or view to
* navigate to in the form of { task: "task_slug" } or { view: "view_slug" }. You can
* also provide optional params.
*/
href: string | NavigateParams;
/**
* Whether the href URL should open in a new tab.
* @default true
*/
newTab?: boolean;
} & CommonStylingProps;
export type Props = PropsBase & TextPropsBase & Omit<JSX.IntrinsicElements["a"], keyof PropsBase | "ref">;