ruelluna/canvas-pointer

A Filament field that allows users to click and point markers on an image.

1.0.4 2024-10-15 06:56 UTC

This package is auto-updated.

Last update: 2024-11-15 07:14:41 UTC


README

Latest Version on Packagist GitHub Tests Action Status GitHub Code Style Action Status Total Downloads

I have used it for a client that needs visual reprensentations to where the pains are located in the body. What is your use case? This field will produce a base-64 image. If you're saving this to your table, I recommend making a BLOB column or convert it to an actual image file.

Installation

You can install the package via composer:

composer require ruelluna/canvas-pointer

Usage

CanvasPointerField::make('body-points')
    ->pointRadius(15) // default is 5
    ->imageUrl('your image source')
    ->width(800) // required
    ->height(800) // required
    ->label('Select body parts that are in pain'),

Todos

  • Automatically detect height and width
  • Table Column Component
  • Entry Component
  • npm Konva dependency

Changelog

Please see CHANGELOG for more information on what has changed recently.

Contributing

Please see CONTRIBUTING for details.

Security Vulnerabilities

Please review our security policy on how to report security vulnerabilities.

Credits

License

The MIT License (MIT). Please see License File for more information.