mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-27 03:06:41 +00:00
Bigger touch target for mobile map history trace (#19569)
This commit is contained in:
parent
73460c7d8a
commit
4c314928c6
@ -20,6 +20,7 @@ import { loadPolyfillIfNeeded } from "../../resources/resize-observer.polyfill";
|
|||||||
import { HomeAssistant } from "../../types";
|
import { HomeAssistant } from "../../types";
|
||||||
import "../ha-icon-button";
|
import "../ha-icon-button";
|
||||||
import "./ha-entity-marker";
|
import "./ha-entity-marker";
|
||||||
|
import { isTouch } from "../../util/is_touch";
|
||||||
|
|
||||||
const getEntityId = (entity: string | HaMapEntity): string =>
|
const getEntityId = (entity: string | HaMapEntity): string =>
|
||||||
typeof entity === "string" ? entity : entity.entity_id;
|
typeof entity === "string" ? entity : entity.entity_id;
|
||||||
@ -282,7 +283,7 @@ export class HaMap extends ReactiveElement {
|
|||||||
this._mapPaths.push(
|
this._mapPaths.push(
|
||||||
Leaflet!
|
Leaflet!
|
||||||
.circleMarker(path.points[pointIndex].point, {
|
.circleMarker(path.points[pointIndex].point, {
|
||||||
radius: 3,
|
radius: isTouch ? 8 : 3,
|
||||||
color: path.color || darkPrimaryColor,
|
color: path.color || darkPrimaryColor,
|
||||||
opacity,
|
opacity,
|
||||||
fillOpacity: opacity,
|
fillOpacity: opacity,
|
||||||
@ -312,7 +313,7 @@ export class HaMap extends ReactiveElement {
|
|||||||
this._mapPaths.push(
|
this._mapPaths.push(
|
||||||
Leaflet!
|
Leaflet!
|
||||||
.circleMarker(path.points[pointIndex].point, {
|
.circleMarker(path.points[pointIndex].point, {
|
||||||
radius: 3,
|
radius: isTouch ? 8 : 3,
|
||||||
color: path.color || darkPrimaryColor,
|
color: path.color || darkPrimaryColor,
|
||||||
opacity,
|
opacity,
|
||||||
fillOpacity: opacity,
|
fillOpacity: opacity,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user