Search code examples
csslinear-gradients

CSS Triangle with 3 Colors


Respected, I Have 3 Colors in my Laravel blade template, And I want to generate a triangle with them, exactly in

This shape


Solution

  • If the shape is only what you want you can do this.

    div{
      display: inline-block;
      border-left: 150px solid red;
      border-top: 150px solid red;
      border-right: 150px solid green;
      border-bottom: 150px solid blue;
    }
    <div></div>