colour.js 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136
  1. /*
  2. * Copyright 2012 The Closure Compiler Authors.
  3. *
  4. * Licensed under the Apache License, Version 2.0 (the "License");
  5. * you may not use this file except in compliance with the License.
  6. * You may obtain a copy of the License at
  7. *
  8. * http://www.apache.org/licenses/LICENSE-2.0
  9. *
  10. * Unless required by applicable law or agreed to in writing, software
  11. * distributed under the License is distributed on an "AS IS" BASIS,
  12. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. * See the License for the specific language governing permissions and
  14. * limitations under the License.
  15. */
  16. /**
  17. * @fileoverview Definitions for colour.js.
  18. * @externs
  19. * @author Daniel Wirtz <dcode@dcode.io>
  20. */
  21. var colour = function() {};
  22. /**
  23. * @type {string}
  24. */
  25. colour.mode;
  26. /**
  27. * @type {boolean}
  28. */
  29. colour.headless;
  30. /**
  31. * @param {string} str
  32. * @returns {function(this:String)}
  33. */
  34. colour.color = function(str) {};
  35. /**
  36. * @type {Object.<string,Object.<string,*>>}
  37. */
  38. colour.themes;
  39. /**
  40. * @param {string} name
  41. * @param {function(string):string} map
  42. */
  43. colour.addSequencer = function(name, map) {};
  44. /**
  45. * @param {Object.<string,*>} theme
  46. * @returns {Object.<string,*>|Error|undefined}
  47. */
  48. colour.setTheme = function (theme) {};
  49. /**
  50. * @returns {boolean}
  51. */
  52. colour.uninstall = function() {};
  53. /**
  54. * @returns {boolean}
  55. */
  56. colour.install = function() {};
  57. /**
  58. * @name String.prototype.bold
  59. * @type {string}
  60. */
  61. // String.prototype.bold;
  62. /**
  63. * @type {string}
  64. */
  65. String.prototype.italic;
  66. /**
  67. * @type {string}
  68. */
  69. String.prototype.underline;
  70. /**
  71. * @type {string}
  72. */
  73. String.prototype.inverse;
  74. /**
  75. * @type {string}
  76. */
  77. String.prototype.strikethrough;
  78. /**
  79. * @type {string}
  80. */
  81. String.prototype.white;
  82. /**
  83. * @type {string}
  84. */
  85. String.prototype.grey;
  86. /**
  87. * @type {string}
  88. */
  89. String.prototype.black;
  90. /**
  91. * @type {string}
  92. */
  93. String.prototype.blue;
  94. /**
  95. * @type {string}
  96. */
  97. String.prototype.cyan;
  98. /**
  99. * @type {string}
  100. */
  101. String.prototype.green;
  102. /**
  103. * @type {string}
  104. */
  105. String.prototype.magenta;
  106. /**
  107. * @type {string}
  108. */
  109. String.prototype.red;
  110. /**
  111. * @type {string}
  112. */
  113. String.prototype.yellow;