B
B
bio2016-08-28 10:53:02
JavaScript
bio, 2016-08-28 10:53:02

How to fill free space with quadrilaterals?

Hello!
There is a task in which the user can select areas of the page. The page will have a translucent overlay, and the selected area will be through.
This is how the "Send feedback" functionality is implemented in gmail.
53fbcb4e11.png
By assumption, blocks (div, canvas, svg) with a translucent background are "drawn" around the selected areas.
Tell me how to calculate the positioning of areas with a dark background. In which direction to dig?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
W
WQP, 2016-08-28
@WQP

For the black area, use one overlay that has a z-index less than the selected areas. At the same time, overlay and areas must be in the same block so that there is access inside the selected blocks

K
Karponter, 2016-09-09
@karponter

Look better towards SVG path, and masks.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question