Comfy-Org / Comfy-Org/ComfyUI_frontend

[Feature Request]: Change Pin Icon

Open
#4,763 7 comments 2 reactions 0 assignees View on GitHub
area:litegraph area:ui enhancement
Dominant language
TypeScript
Stars
2k
Forks
699
Avg merge
1d 7h
Merged PRs (30d)
490

Description

## Ref

- #120.
- Comfy-Org/ComfyUI_frontend#831

## Possible Implementation

The PrimeIcons font is already loaded with icons mapped to unicode sequences:

```javascript
ctx.textAlign = "left";
ctx.fillText(
title,
title_height,
LiteGraph.NODE_TITLE_TEXT_Y - title_height
);
if (node22.pinned) {
ctx.font = `${this.title_text_font.split(" ")[0]} PrimeIcons`
ctx.fillText(
"\uea25",
title_height + ctx.measureText(title).width + 8,
LiteGraph.NODE_TITLE_TEXT_Y - title_height
)
}
```

## Comparison

![Selection_312](https://github.com/user-attachments/assets/aae59a64-5726-4251-87f3-be5658c12132)

![Selection_313](https://github.com/user-attachments/assets/236b972e-dfa7-4113-8e4f-f152513ab05e)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.