Is it possible to create your own caption tag like the one shown on the screenshot?

enter image description here

    1 answer 1

    In the maps API, you cannot customize the appearance of the label label, but you can customize the entire label layout. Through the iconLayout option you can set your html-layout. To shift the label relative to the point, it is necessary in the html-layout to make an offset in a certain direction through absolutely positioning or css-transform. In the example below, the usual pos: abs is used.

    Example in the sandbox: https://tech.yandex.ru/maps/jsbox/2.1/placemark_shape

    • And in the link that you gave detailed description of how to create a label with styles. And you say that the idea of ​​the author can not be implemented. Or am I misunderstanding something? - Raz Galstyan
    • Well, maybe I did not quite put it right. The map API has a caption entity (label label) for the standard label layout. It can not be customized - only the text set. But you can customize the appearance of the entire label. - vsesh
    • Just as it is not clear the question of the author, there are numbers that mean? And who sets them up? - Raz Galstyan
    • As I understand it, the question is about the ability to display the label label in a certain way. Content is not so important. - vsesh
    • Numbers mean cost. In this case, "M" means Million. A "units" is the number of apartments in the house. Set the cost when generating json-descriptions of objects. - Albert Alexandrov