Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Manually add text for classification in react-image-annotate

Tags:

reactjs

I am planning to use react-image-annotate to annotate images by drawing polygons. But react-image-annotate by default only allows selecting a classification from a predefined list.

I wanted something like this library react-image-annotation where you can draw a bounding box and it shows you a field in which you can enter custom text.

The documentation says it is possible to build a custom form using RegionEditLabel, but there is no clear documentation for it.

like image 658
a_rahmanshah Avatar asked May 03 '26 08:05

a_rahmanshah


1 Answers

If you can live without polygons, the I think the react-picture-annotation might be your answer:

npmjs: react-picture-annotation

You can draw rectangles, and annotate them with any custom tag you want. I made a simple codesandbox based on the code from npmjs:

Codesandbox

You have to:

  • draw a shape
  • click on the square
  • type a name
  • click outside box to save
like image 175
DMcCallum83 Avatar answered May 05 '26 21:05

DMcCallum83



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!