Fit a pennant clip path to two photo frames
Admin ·
An inward notch that suits a wide banner can feel deeper on a square card. Build the shape once with percentage points, then use the preview frame to check its proportions before applying it to your page.
Set the center of the pennant notch
Choose Polygon and Harbor pennant. Choose Point 3, then set Point X to 65 and Point Y to 50. The notch starts at 65% of the width and halfway down the photo. Its two outside tips remain at 100% of the width, at Y 12% and Y 88%.
The CSS value is polygon(0% 12%, 100% 12%, 65% 50%, 100% 88%, 0% 88%). At a 300-pixel element width, the notch reaches 195 pixels from the left edge. Use Shift and Right Arrow to move the notch to 70%, or select the plus on an edge to insert a vertex halfway along it.
W3C CSS Masking, the clip-path propertyW3C CSS Shapes, basic shape functions
Compare the same outline in two frames
Return Point X to 65, then change Preview frame from Landscape to Square. The photo and shape change proportions while the five coordinates stay fixed. Check the preview against the aspect ratio of the actual component.
For a softer clipping edge, choose Inset and the Rounded preset. The four percentages start at top and continue clockwise. The 10% corner radius rounds the box. Compare it with Square, which uses a zero radius, or Pill, whose large pixel radius curves the ends.
Apply the rule to a real image block
Choose Polygon again and download clip-path.css. Add the .pennant class to the element you want to clip. At its vertical center, the content should disappear to the right of the 65% mark. Export format also lets you copy the property declaration or just its value.
Set your element’s width, height or aspect ratio alongside the clip rule. If the notch becomes too steep on a compact card, give that layout its own coordinates.
W3C CSS Masking, the clip-path propertyW3C CSS Shapes, basic shape functions
Common questions
When is the Even-odd fill rule useful?
It is useful for a polygon whose edges cross. A region is included when a ray from it crosses an odd number of edges. Use the preview to check which inner regions remain visible.
How are circle and ellipse percentages interpreted?
Ellipse radii use the width and height separately. A circle percentage uses a normalized diagonal, so the circle stays circular when you switch from a square to a wide box.