/googlemaps.infobubble/google.maps.infobubble.d.ts

https://github.com/deavon/DefinitelyTyped · TypeScript · 108 lines · 25 code · 24 blank · 59 comment · 1 complexity · 03235a83212a89fe03e5a2d7aa119ae4 MD5 · raw file

  1. // Type definitions for CSS3 InfoBubble with tabs for Google Maps API V3
  2. // Project: http://google-maps-utility-library-v3.googlecode.com/svn/trunk/infobubble/src/
  3. // Definitions by: Johan Nilsson <https://github.com/Dashue>
  4. // Definitions: https://github.com/borisyankov/DefinitelyTyped
  5. /// <reference path="../googlemaps/google.maps.d.ts" />
  6. /**
  7. * @name CSS3 InfoBubble with tabs for Google Maps API V3
  8. * @version 0.8
  9. * @author Luke Mahe
  10. * @fileoverview
  11. * This library is a CSS Infobubble with tabs. It uses css3 rounded corners and
  12. * drop shadows and animations. It also allows tabs
  13. */
  14. /*
  15. The MIT License
  16. Copyright (c) 2014 https://github.com/Dashue
  17. Permission is hereby granted, free of charge, to any person obtaining a copy
  18. of this software and associated documentation files (the "Software"), to deal
  19. in the Software without restriction, including without limitation the rights
  20. to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
  21. copies of the Software, and to permit persons to whom the Software is
  22. furnished to do so, subject to the following conditions:
  23. The above copyright notice and this permission notice shall be included in
  24. all copies or substantial portions of the Software.
  25. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  26. IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  27. FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
  28. AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
  29. LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
  30. OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  31. THE SOFTWARE.
  32. */
  33. declare module google.maps.infobubble {
  34. export interface InfoBubble {
  35. /**
  36. * Closes the infobubble
  37. */
  38. close(): void;
  39. /**
  40. * Checks if the infobubble is currently open
  41. */
  42. isOpen(): boolean;
  43. /**
  44. * Opens the infobubble
  45. * @map The google map object
  46. * @marker The marker used for anchoring the infobubble to
  47. */
  48. open(map: google.maps.Map, marker: google.maps.Marker) : void;
  49. /**
  50. * Returns the position of the InfoBubble
  51. */
  52. getPosition(): google.maps.LatLng;
  53. }
  54. export interface InfoBubbleOptions {
  55. /**
  56. * Percentage from the bottom left corner of the infobubble
  57. */
  58. arrowPosition?: number;
  59. arrowSize?: number;
  60. /**
  61. * 0: Middle, 1: Left, 2: Right
  62. */
  63. arrowStyle?: number;
  64. backgroundColor?: string;
  65. borderColor?: string;
  66. borderRadius?: number;
  67. borderWidth?: number;
  68. disableAnimation?: boolean;
  69. disableAutoPan?: boolean;
  70. maxHeight?: number;
  71. maxWidth?: number;
  72. minHeight?: number;
  73. minWidth?: number;
  74. padding?: number;
  75. /**
  76. * 0: None, 1: Right, 2: Under
  77. */
  78. shadowStyle?: number;
  79. }
  80. }