JSFiddle - React, Tailwind, and code Playground

HTML

<script src="//api-maps.yandex.ru/2.1/?lang=ru-RU"></script>
<div id="map"></div>

CSS

html, body, #map {
            width: 100%;
            height: 100%;
            margin: 0;
            padding: 0;
        }

        .placemark_layout_container { 
            position: relative;
            font-family: Georgia;
            font-size: 40px;
            text-align: center;
            font-weight: bold;
        }

        .square_layout {
            position: absolute;
            left: -23px;
            top: -23px;
            width: 46px;
            height: 46px;
            line-height: 46px;
            border: 2px solid #218703;
            background-color: #F8FDF7;
            color: #218703;
        }

JavaScript

ymaps.ready(function () {
    var map = new ymaps.Map('map', {
        center: [55.7, 37.6],
        zoom: 10,
        controls: []
    });

    // Создание метки с квадратной активной областью.
    var squareLayout = ymaps.templateLayoutFactory.createClass('<div class="placemark_layout_container"><div class="square_layout">$</div></div>', {
    
        build: function () {
            squareLayout.superclass.build.call(this);

            // вызов jQuery или domEvent.manager
            this._events = ymaps.domEvent.manager.group(this.getElement());
            this._events.add('contextmenu', function () {
                alert('1'); 
            });
        },
        
        clear: function () {
            this._events.removeAll();
            squareLayout.superclass.clear.call(this);
        }
    });

    var squarePlacemark = new ymaps.Placemark(
        [55.725118, 37.682145], {
            hintContent: 'Метка с прямоугольным HTML макетом'
        }, {
            iconLayout: squareLayout,
            // Метка будет находится над слоем событий. 
            // Больше про активные области
            // http://api.yandex.ru/maps/doc/jsapi/2.1/dg/concepts/about-hotspots.xml
            // и
            // http://api.yandex.ru/maps/jsbox/2.1/placemark_shape
            iconPane: 'overlaps'
        }
    );
    map.geoObjects.add(squarePlacemark);
});