affix-tokens.d.ts 532 B

12345678910111213141516171819202122
  1. import { PatternError } from '../errors.js';
  2. export type AffixToken = {
  3. char: '%';
  4. width: number;
  5. style: 'percent' | 'permille';
  6. } | {
  7. char: '¤';
  8. width: number;
  9. currency: 'default' | 'iso-code' | 'full-name' | 'narrow';
  10. } | {
  11. char: '*';
  12. width: number;
  13. pad: string;
  14. } | {
  15. char: '+' | '-';
  16. width: number;
  17. } | {
  18. char: "'";
  19. width: number;
  20. str: string;
  21. };
  22. export declare function parseAffixToken(src: string, pos: number, onError: (err: PatternError) => void): AffixToken | null;