DEV Community

AKSH DESAI
AKSH DESAI

Posted on

CSS Border-Radius Tutorial

Code

<!DOCTYPE html>
<html lang="en">

  <head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Box - Radius</title>

    <style>
    #box {
      border: 2px solid blue;
      width: 400px;
      /* padding: 25px; */
      /* border-top-left-radius: 30px;
        border-top-right-radius: 30px;
        border-bottom-left-radius: 30px;
        border-bottom-right-radius: 30px; */

      /* border-radius: 30px 100px; */

      border-radius: 100%;
    }

    #circle {
      border: 2px solid brown;
      width: 150px;
      height: 150px;
      border-radius: 50%;
      background-color: blueviolet;
      outline: 3px solid blue;
      outline-offset: 8px;
    }
  </style>
  </head>

  <body>
    <h1> Yahoo Baba Box Radius </h1>

    <div id="box">
      Lorem ipsum dolor sit amet consectetur adipisicing elit. Aspernatur eaque
      iusto soluta esse quis omnis? Debitis a fugit dicta natus.
      Lorem ipsum dolor sit amet consectetur adipisicing elit. Aspernatur eaque
      iusto soluta esse quis omnis? Debitis a fugit dicta natus.
      Lorem ipsum dolor sit amet consectetur adipisicing elit. Aspernatur eaque
      iusto soluta esse quis omnis? Debitis a fugit dicta natus.
    </div>

    <div id="circle">

    </div>
  </body>

  <script>
  let circle = document.getElementById("circle");
  circle.contentEditable = true;
</script>
</html>
Enter fullscreen mode Exit fullscreen mode

Output
Output

Thank You.
You can follow us on:
Youtube
Instagram

Tiugo image

Modular, Fast, and Built for Developers

CKEditor 5 gives you full control over your editing experience. A modular architecture means you get high performance, fewer re-renders and a setup that scales with your needs.

Start now

Top comments (0)

Image of Stellar post

Check out Episode 1: How a Hackathon Project Became a Web3 Startup πŸš€

Ever wondered what it takes to build a web3 startup from scratch? In the Stellar Dev Diaries series, we follow the journey of a team of developers building on the Stellar Network as they go from hackathon win to getting funded and launching on mainnet.

Read more

πŸ‘‹ Kindness is contagious

Explore a trove of insights in this engaging article, celebrated within our welcoming DEV Community. Developers from every background are invited to join and enhance our shared wisdom.

A genuine "thank you" can truly uplift someone’s day. Feel free to express your gratitude in the comments below!

On DEV, our collective exchange of knowledge lightens the road ahead and strengthens our community bonds. Found something valuable here? A small thank you to the author can make a big difference.

Okay