/** * Svelte action that shows/hides an element based on permissions * * Usage: * */ interface PermissionParams { /** Permission slug to check */ slug: string; /** User's current permissions */ permissions: string[]; /** If true, hide instead of removing from DOM */ hideOnly?: boolean; } export declare function permission(node: HTMLElement, params: PermissionParams): { update: (params: PermissionParams) => void; destroy: () => void; }; /** * Check if user has a specific permission */ export declare function hasPermission(permissions: string[], slug: string): boolean; /** * Check if user has all specified permissions */ export declare function hasAllPermissions(permissions: string[], slugs: string[]): boolean; /** * Check if user has any of the specified permissions */ export declare function hasAnyPermission(permissions: string[], slugs: string[]): boolean; export {}; //# sourceMappingURL=permission.d.ts.map