NativeScript / NativeScript/plugins
[@nativescript/google-maps] Marker info window on Angular
还没有人认领这个 Issue。
- 主要语言
- TypeScript
- 星标
- 206
- 派生
- 123
- 平均合并
- 2 天 1 小时
- 30 天内合并 PR
- 1
描述
Hi,
Can help advice how to set marker info window content on Angular?
Below is code that i try but not working
component.html
<MapView [lat]="dd.lat" [lng]="dd.lng"
[zoom]="dd.zoom" (ready)="onMapReady($event)" (markerTap)="onMarkerSelect($event)"
(markerInfoWindow)="initInfoWindow($event)" (markerInfoContents)="initInfoWindow($event)" (infoWindowTap)="onInfoWindowSelect($event)"></MapView>
component.ts
initInfoWindow(args) {
const info = new StackLayout();
info.width = 100;
info.height = 100;
info.backgroundColor = 'white';
const image = new Image();
image.src = 'https://camo.githubusercontent.com/3bd307204ac6237963e0448c00800a9df08f245d9e78fbbeb4191e625c834286/68747470733a2f2f64316c66797a356b7774387675392e636c6f756466726f6e742e6e65742f6e61746976657363726970742d6c6f676f2d323032312e706e67';
info.addChild(image);
const text = new Label();
text.text = "Custom Info Window";
info.addChild(text);
args.view = info;
}
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
从报告中显示的 component.html 中的 MapView 绑定和 component.ts 中的 initInfoWindow(args) 处理程序开始。检查插件的 marker 信息窗口 API,并确定为什么分配的自定义视图没有显示;完成的标准是 marker 信息窗口在 Angular 上渲染图像和标签内容。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- angular, typescript
- 领域
- mobile-dev
- Issue 类型
- 缺陷
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 活跃度
- 停滞
- 描述清晰度
- 需要澄清
- 新手友好度
- 25/100