(format: string)
| 102 | }; |
| 103 | |
| 104 | function get_number_format_info(format: string) { |
| 105 | let info: { decimal_str: string, group_sep: string, precision?: number } = number_format_info[format as keyof typeof number_format_info]; |
| 106 | |
| 107 | if (!info) { |
| 108 | info = { decimal_str: ".", group_sep: "," }; |
| 109 | } |
| 110 | |
| 111 | // get the precision from the number format |
| 112 | info.precision = format.split(info.decimal_str).slice(1)[0].length; |
| 113 | |
| 114 | return info; |
| 115 | } |
| 116 | |
| 117 | function get_number_format(currency?: string): string { |
| 118 | return ( |
no outgoing calls
no test coverage detected