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,IAAI,CAAC,MAAM,CAAC;YACpC,KAAK,IAAI,CAAC,SAAS;YACnB,UAAU;gBAAE,KAAK,SAAS,QAAQ,CAAC,GAAG;gBAAE,KAAK,SAAS,QAAQ,CAAC,GAAG;YAAC;QACrE;QAEA,OAAO,WAAW,CAAC,SAAS,IAAM;YAChC,MAAM,aAAa,IAAI,OAAO,IAAI,CAAC,UAAU,CAAC;gBAC5C,SAAS,SAAS,aAAa;YACjC;YACA,WAAW,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE;QAClC;IACF;AACF;;;AHjCA,MAAM,6BAAO,IAAI,CAAA,GAAA,yCAAI,AAAD;AACpB,MAAM,gCAAU,IAAI,CAAA,GAAA,yCAAO,AAAD;AAE1B,IAAI,kCAAY,IAAI,CAAA,GAAA,yCAAQ,EAAE;AAC9B,gCAAU,SAAS,CAAC;AACpB,gCAAU,SAAS,CAAC","sources":["src/index.ts","src/User.ts","src/Company.ts","src/CustomMap.ts"],"sourcesContent":["import { User } from \"./User\";\nimport { Company } from \"./Company\";\nimport { CustomMap } from \"./CustomMap\";\n\nconst user = new User();\nconst company = new Company();\n\nlet customMap = new CustomMap(\"map\");\ncustomMap.addMarker(user);\ncustomMap.addMarker(company);","import { faker } from \"@faker-js/faker\";\n\nexport class User {\n username: string;\n location: {\n lat: number;\n lng: number;\n };\n\n constructor() {\n this.username = faker.internet.userName();\n this.location = {\n lat: parseInt(faker.address.latitude()),\n lng: parseInt(faker.address.longitude()),\n };\n }\n\n markerContent(): string {\n return `User Name: ${this.username} `;\n }\n}\n","import { faker } from \"@faker-js/faker\";\n\nexport class Company {\n companyName: string;\n companyPhrase: string;\n location: {\n lat: number;\n lng: number;\n };\n color: string = \"blue\"\n\n constructor() {\n this.companyName = faker.company.name();\n this.companyPhrase = faker.company.catchPhrase();\n this.location = {\n lat: Number(faker.address.latitude()),\n lng: Number(faker.address.longitude()),\n };\n }\n\n markerContent(): string {\n return `\n <div>\n <h1>Company Name: ${this.companyName},</h1>\n <h3>Catchphrase: ${this.companyPhrase},</h3>\n </div>\n `;\n }\n}\n","import { User } from \"./User\";\nimport { Company } from \"./Company\";\n\nexport interface Mappable {\n location: {\n lat: number;\n lng: number;\n };\n markerContent(): string;\n}\n\nexport class CustomMap {\n private googleMap: google.maps.Map;\n\n constructor(divId: string) {\n this.googleMap = new google.maps.Map(\n document.getElementById(divId) as HTMLElement,\n {\n center: { lat: 40.7127, lng: -73.9872 },\n zoom: 1,\n }\n );\n }\n\n addMarker(mappable: Mappable): void {\n const marker = new google.maps.Marker({\n map: this.googleMap,\n position: { lat: mappable.location.lat, lng: mappable.location.lng },\n });\n\n marker.addListener(\"click\", () => {\n const infowindow = new google.maps.InfoWindow({\n content: mappable.markerContent(),\n });\n infowindow.open(this.googleMap, marker);\n });\n }\n}\n"],"names":[],"version":3,"file":"index.js.map"}