Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

131
Vistas
Connect two HTML elements with smooth edges

I want to draw a figure like this.
enter image description here

I have used the Canvas to draw the line but failed to draw custom lines.

<!DOCTYPE html>
 <html>
 <head>
 <meta charset=utf-8 />
 <title>Line Joining</title>
 </head>
 <body>
 <canvas id="DemoCanvas" width="400" height="400"></canvas>  
<script>
var canvas = document.getElementById('DemoCanvas');
if (canvas.getContext) 
{
   var ctx = canvas.getContext("2d");
   var lStart = 50;
   var lEnd = 200;
   var yStart = 20;
   ctx.beginPath();
   ctx.lineWidth = 25;

// Use a round corner.             
   ctx.beginPath();
   ctx.lineJoin = "round";
   ctx.moveTo(50, 140);
   ctx.lineTo(150, 140);
   ctx.lineTo(150, 260);
   ctx.stroke();

 }
</script>
</body>
</html>

I have also tried jQuery draggable and achieved results as figure below. enter image description here

Kindly suggest me how these type of figures can be drawn using HTML and jQuery/JavaScript

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda