Repository navigation
Expand file tree
/
Copy pathupper.ts
More file actions
43 lines (42 loc) · 1.41 KB
/
Copy pathupper.ts
File metadata and controls
43 lines (42 loc) · 1.41 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
import * as Internal from '@app/internal/index.ts'
/**
* Convert text to uppercase.
* @description Uppercases a single string entry.
* @param input - String to convert
* @returns Uppercase string
*/
export default function upper(input: string): string
/**
* Convert a string vector to uppercase.
* @description Uppercases every string in a vector.
* @param input - Vector of strings to convert
* @returns Vector of uppercase strings
*/
export default function upper(input: string[]): string[]
/**
* Convert a string matrix to uppercase.
* @description Uppercases every string in a matrix.
* @param input - Matrix of strings to convert
* @returns Matrix of uppercase strings
*/
export default function upper(input: string[][]): string[][]
/**
* Convert text to uppercase.
* @description Uppercases every string entry.
* @param input - String, vector, or matrix of strings to convert
* @returns Uppercase strings matching the input shape
*/
export default function upper(
input: string | string[] | string[][]
): string | string[] | string[][]
/**
* Convert text to uppercase.
* @description Uppercases every string entry.
* @param input - String, vector, or matrix of strings to convert
* @returns Uppercase strings matching the input shape
*/
export default function upper(
input: string | string[] | string[][]
): string | string[] | string[][] {
return Internal.mapper(input, (value) => value.toUpperCase())
}