noodleware/notey

A lightweight Laravel package for adding notes and comments to any model with a Livewire-powered UI.

v1.0.0 2025-03-04 23:29 UTC

This package is auto-updated.

Last update: 2025-07-05 00:21:56 UTC


README

Notey is a simple Laravel package that allows you to add notes to any model using a polymorphic relationship.

Installation

To install Notey, use Composer:

composer require noodleware/notey

Run the migration to create the necessary database table:

php artisan migrate

This will create one table:

  • notes: Stores all notes via a polymorphic relationship.

Publish the package assets:

php artisan vendor:publish --tag=notey

Styling Considerations

After publishing assets, you must include the Notey base stylesheet in your application:

<link rel="stylesheet" href="{{ asset('vendor/notey/notey.css') }}">

Usage

There are two ways to include Notey in your application:

1. Full Component (Pre-styled Card)

To include the fully styled notes component:

<x-notey::notes :model="$model" />

2. Separate Components (For Custom Styling)

You can load the list and form separately to have more control over styling:

<livewire:note-list :model="$model" />
<livewire:note-form :model="$model" />

This allows you to integrate the notes section into your layout while maintaining full control over its appearance.

License

This package is open-source under the MIT License.