Skip to content

Add delete forever icon#1540

Merged
Rajesh-Nagarajan-11 merged 1 commit into
layer5io:masterfrom
indevi:dfor
May 12, 2026
Merged

Add delete forever icon#1540
Rajesh-Nagarajan-11 merged 1 commit into
layer5io:masterfrom
indevi:dfor

Conversation

@indevi
Copy link
Copy Markdown
Contributor

@indevi indevi commented May 12, 2026

Notes for Reviewers

This PR fixes #1491

Signed commits

  • Yes, I signed my commits.

Signed-off-by: Shivam Tyagi <tyagishivam.dev@gmail.com>
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a new DeleteForeverIcon component to the icon library, along with its corresponding export files. The reviewer suggested enhancing the component by wrapping it in React.forwardRef to allow consumers to access the underlying SVG element, which is a best practice for supporting integrations like tooltips.

Comment on lines +1 to +25
import { DEFAULT_FILL_NONE, DEFAULT_HEIGHT, DEFAULT_WIDTH } from '../../constants/constants';
import { IconProps } from '../types';

export const DeleteForeverIcon = ({
width = DEFAULT_WIDTH,
height = DEFAULT_HEIGHT,
fill = DEFAULT_FILL_NONE,
...props
}: IconProps): JSX.Element => {
return (
<svg
width={width}
height={height}
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 24 24"
data-testid="delete-forever-icon-svg"
{...props}
>
<path
d="M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6zm2.46-7.12 1.41-1.41L12 12.59l2.12-2.12 1.41 1.41L13.41 14l2.12 2.12-1.41 1.41L12 15.41l-2.12 2.12-1.41-1.41L10.59 14zM15.5 4l-1-1h-5l-1 1H5v2h14V4z"
fill={fill}
/>
</svg>
);
};
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

For components in an icon library, it is a best practice to use React.forwardRef to allow consumers to access the underlying SVG element. This is particularly important for integrations with other libraries (like tooltips) that require a ref to the DOM element. Additionally, ensure React is imported to support forwardRef and JSX.

import React from 'react';
import { DEFAULT_FILL_NONE, DEFAULT_HEIGHT, DEFAULT_WIDTH } from '../../constants/constants';
import { IconProps } from '../types';

export const DeleteForeverIcon = React.forwardRef<SVGSVGElement, IconProps>(({ 
  width = DEFAULT_WIDTH, 
  height = DEFAULT_HEIGHT, 
  fill = DEFAULT_FILL_NONE, 
  ...props 
}, ref): JSX.Element => {
  return (
    <svg
      width={width}
      height={height}
      xmlns="http://www.w3.org/2000/svg"
      viewBox="0 0 24 24"
      data-testid="delete-forever-icon-svg"
      ref={ref}
      {...props}
    >
      <path
        d="M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6zm2.46-7.12 1.41-1.41L12 12.59l2.12-2.12 1.41 1.41L13.41 14l2.12 2.12-1.41 1.41L12 15.41l-2.12 2.12-1.41-1.41L10.59 14zM15.5 4l-1-1h-5l-1 1H5v2h14V4z"
        fill={fill}
      />
    </svg>
  );
});

@Rajesh-Nagarajan-11 Rajesh-Nagarajan-11 merged commit 288cda2 into layer5io:master May 12, 2026
5 checks passed
@indevi indevi deleted the dfor branch May 12, 2026 13:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature] Add DeleteForeverIcon to Sistent

3 participants