alinea
Version:
[](https://npmjs.org/package/alinea) [](https://packagephobia.com/result?p=alinea)
24 lines (23 loc) • 854 B
TypeScript
export type EntryLocation = {
entryId?: string;
i18nId?: string;
workspace?: string;
root?: string;
locale?: string;
};
export declare const navMatchers: {
readonly matchEntry: "/entry/*";
readonly matchEntryId: "/:action/:workspace/:root?/:entryId?";
readonly matchWorkspace: "/:action/:workspace";
readonly matchRoot: "/:action/:workspace/:root";
};
export declare function dashboardNav(defaults: Partial<EntryLocation>): {
matchEntry: "/entry/*";
matchEntryId: "/:action/:workspace/:root?/:entryId?";
matchWorkspace: "/:action/:workspace";
matchRoot: "/:action/:workspace/:root";
root: ({ entryId, i18nId, ...location }: EntryLocation) => string;
entry: (location: EntryLocation) => string;
draft: (location: EntryLocation) => string;
create: (location: EntryLocation) => string;
};