@@ -395,7 +395,6 @@ addPopups <- function(
395
395
expandLimits(pts $ lat , pts $ lng )
396
396
}
397
397
398
- # ' options for specify popup realted options
399
398
# ' @param className a CSS class name set on an element
400
399
# ' @param
401
400
# ' maxWidth,minWidth,maxHeight,autoPan,keepInView,closeButton,zoomAnimation,closeOnClick
@@ -437,8 +436,17 @@ clearPopups <- function(map) {
437
436
invokeMethod(map , NULL , ' clearPopups' )
438
437
}
439
438
440
- # ' Helper Function to create a safe label
441
- # ' @describeIn map-layers Create a label with sanitized text/html
439
+ # ' Sanitize textual labels
440
+ # '
441
+ # ' This is a helper function used internally to HTML-escape user-provided
442
+ # ' labels. It prevents strings from unintentionally being treated as HTML when
443
+ # ' they are intended to be plaintext.
444
+ # '
445
+ # ' @param label A vector or list of plain characters or HTML (marked by
446
+ # ' \code{\link[htmltools]{HTML}}), or a formula that resolves to such a value.
447
+ # ' @param data A data frame over which the formua is evaluated.
448
+ # '
449
+ # ' @keywords internal
442
450
# ' @export
443
451
safeLabel <- function (label , data ) {
444
452
if (is.null(label )) {
@@ -453,8 +461,6 @@ safeLabel <- function(label, data) {
453
461
label
454
462
}
455
463
456
- # ' Extra options for marker and polygon labels
457
- # '
458
464
# ' @param
459
465
# ' noHide,direction,offset,textsize,textOnly,style
460
466
# ' label options; see \url{https://github.com/Leaflet/Leaflet.label#options}
0 commit comments