🏷️ link interface added

This commit is contained in:
Paul Valerie GOMA 2025-07-21 10:50:08 +02:00
parent 08c3f55db2
commit 996f20136a

View File

@ -0,0 +1,46 @@
import type { RouteLocationRaw } from "vue-router";
/**
* Interface representing a navigational link component.
* This can be used for both internal routing (via `to`) and external links (via `href`).
*/
export default interface ILink {
/**
* The text label displayed for the link.
*/
label: string;
/**
* Internal route destination using Vue Router's RouteLocationRaw.
* Optional used for client-side navigation.
*/
to?: RouteLocationRaw;
/**
* External URL for the link.
* Optional used for standard anchor navigation.
*/
href?: string;
/**
* Optional icon name or path to be displayed alongside the label.
*/
icon?: string;
/**
* Specifies where to open the linked document (e.g., "_blank", "_self").
* Optional applies to external links.
*/
target?: string;
/**
* If true, the link is disabled and not clickable.
*/
disabled?: boolean;
/**
* If true, the icon is displayed on the right side of the label.
* Defaults to false (icon on the left).
*/
iconRight?: boolean;
}