Skip to content

Commit

Permalink
Add ariaLabel method to Typescript (#6582)
Browse files Browse the repository at this point in the history
  • Loading branch information
melloware authored May 6, 2024
1 parent 6a990b3 commit 0bdb6d2
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions components/lib/api/api.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -729,6 +729,14 @@ export declare function localeOption(key: string, locale: string): any;
*/
export declare function localeOptions(locale: string): object;

/**
* Finds an ARIA label in the locale by key and replaces options if provided.
* @param {string} ariaKey - Key of the ARIA label to look up in the locale.
* @param {Object} options - JSON options like { page: 2, user: "John", role: "Admin" }.
* @returns {string} The ARIA label with replaced values.
*/
export declare function ariaLabel(ariaKey: string, options: any): string;

// Locale Options
export interface LocaleOptions {
/**
Expand Down

0 comments on commit 0bdb6d2

Please sign in to comment.