parser.d.ts 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. import Input from './input';
  2. import Node from './node';
  3. import Root from './root';
  4. export default class Parser {
  5. input: Input;
  6. pos: number;
  7. root: Root;
  8. spaces: string;
  9. semicolon: boolean;
  10. private current;
  11. private tokens;
  12. constructor(input: Input);
  13. tokenize(): void;
  14. loop(): void;
  15. comment(token: any): void;
  16. emptyRule(token: any): void;
  17. word(): void;
  18. rule(tokens: any): void;
  19. decl(tokens: any): void;
  20. atrule(token: any): void;
  21. end(token: any): void;
  22. endFile(): void;
  23. init(node: Node, line?: number, column?: number): void;
  24. raw(node: any, prop: any, tokens: any): void;
  25. spacesFromEnd(tokens: any): string;
  26. spacesFromStart(tokens: any): string;
  27. stringFrom(tokens: any, from: any): string;
  28. colon(tokens: any): number | boolean;
  29. unclosedBracket(bracket: any): void;
  30. unknownWord(start: any): void;
  31. unexpectedClose(token: any): void;
  32. unclosedBlock(): void;
  33. doubleColon(token: any): void;
  34. unnamedAtrule(node: any, token: any): void;
  35. precheckMissedSemicolon(tokens: any): void;
  36. checkMissedSemicolon(tokens: any): void;
  37. }