Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
47 commits
Select commit Hold shift + click to select a range
f343dd3
renamed `ChatEventMaker` to `IChatEventMaker`
myckhel Nov 5, 2021
8764098
renamed `delivery` to `delivered`
myckhel Nov 5, 2021
ca6a849
changed chat bottom ui
myckhel Nov 13, 2021
bd95699
changed chat top ui
myckhel Nov 13, 2021
55c6307
updated chat-system dep
myckhel Nov 13, 2021
24068eb
updated chat-system dep
myckhel Nov 13, 2021
cf8d953
yarn v2 support
myckhel Dec 28, 2021
f2a689f
php v8.1 support
myckhel Dec 28, 2021
01ae1aa
memoised some components
myckhel Dec 28, 2021
bec8f7f
implemented list reverse
myckhel Dec 28, 2021
89e8143
composer 2.1.4
myckhel Dec 29, 2021
55fdaf3
optimized `ListView`
myckhel Dec 29, 2021
381069d
optimized `useRootMemoSelector`
myckhel Dec 29, 2021
3476ec4
set yarn path
myckhel Dec 29, 2021
09b8dbf
ignored `yarn/cache`
myckhel Dec 29, 2021
c8b0e59
set procfile server to swoole
myckhel Dec 29, 2021
1e2b921
added ext-redis to composer
myckhel Dec 29, 2021
272bced
added `predis/predis` to composer
myckhel Dec 29, 2021
15e0686
clear local storage on logout
myckhel Jan 5, 2022
005f485
added `RenderHeader` to infinite
myckhel Jan 5, 2022
3273d3b
added worker to Procfile
myckhel Jan 5, 2022
72a3dc0
Upgraded to laravel 9 (#2)
myckhel Apr 23, 2022
3e603fc
handled chat_system changes
myckhel Nov 20, 2022
9d8683c
Merge branch 'dep' of https://github.com/myckhel/chat-system-example …
myckhel Dec 13, 2022
e3ee0b9
bumped composer deps
myckhel Dec 13, 2022
79e1755
fixed storage link
myckhel Dec 13, 2022
b46661c
bumped inerthia
myckhel Dec 13, 2022
6cde52d
bumped vite, eslint
myckhel Dec 13, 2022
dbb7e6b
bumped tailwind
myckhel Dec 13, 2022
f6dbbf6
bumped composer php
myckhel Dec 13, 2022
7b8e77d
converted to official laravel vite
myckhel Dec 17, 2022
8c9afb7
configured vite eslint
myckhel Dec 17, 2022
d0a54d4
bumped to react 18
myckhel Dec 17, 2022
8d1b0ef
removed windmill
myckhel Dec 17, 2022
b2a5693
bumped to laravel v10
myckhel Jun 29, 2023
994a228
updated dependencies
myckhel Jan 4, 2025
e9a70f3
migrated to binkode repo (#4)
myckhel Jan 5, 2025
3369e9a
add AGENTS.md to define project purpose, rules, and conventions
myckhel Feb 12, 2026
98ab31b
refactor: migrate from @inertiajs/inertia-react to @inertiajs/react
myckhel Feb 12, 2026
e071b12
feat: enhance chat UI with improved scrollbar and user interaction el…
myckhel Feb 12, 2026
ee48f9f
feat: enhance login page with improved layout and account selection
myckhel Feb 12, 2026
6deedbf
feat: implement new chat modal and enhance conversation handling
myckhel Feb 12, 2026
d037bf1
fix: specify exact version for binkode/laravel-chat-system in compose…
myckhel Feb 12, 2026
a467b1a
refactor: remove local path repository configuration from composer.json
myckhel Feb 12, 2026
a60f4d7
fix: update binkode/laravel-chat-system version to dev-master in comp…
myckhel Feb 12, 2026
340a971
fix: update binkode/laravel-chat-system reference in composer.lock an…
myckhel Feb 12, 2026
2635ede
fix: revert binkode/laravel-chat-system version to ^1.0 in composer.j…
myckhel Feb 18, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -45,5 +45,12 @@ PUSHER_APP_KEY=
PUSHER_APP_SECRET=
PUSHER_APP_CLUSTER=mt1

VITE_APP_URL=

VITE_PUSHER_APP_CLUSTER=mt1
VITE_PUSHER_APP_KEY=

MIX_PUSHER_APP_KEY="${PUSHER_APP_KEY}"
MIX_PUSHER_APP_CLUSTER="${PUSHER_APP_CLUSTER}"

OCTANE_SERVER=frankenphp
49 changes: 0 additions & 49 deletions .eslintrc.js

This file was deleted.

35 changes: 35 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
{
"parser": "@babel/eslint-parser",
"root": true,
"extends": ["react-app", "prettier"],
"env": {
"node": true,
"browser": true
},
"parserOptions": {
"ecmaVersion": 2020,
"requireConfigFile": false,
"ecmaFeatures": {
"legacyDecorators": true,
"jsx": true
}
},
"settings": {
"react": {
"version": "17"
}
},
"globals": { "Echo": true, "Pusher": true, "route": true },
"rules": {
"no-eval": 0,
"react-hooks/exhaustive-deps": 0,
"array-callback-return": 0,
"no-extend-native": 0,
"no-shadow": 0,
"camelcase": 0,
"import/no-cycle": "error",
"react/jsx-uses-react": 0,
"react/react-in-jsx-scope": 0,
"jest/no-commented-out-tests": 0
}
}
2 changes: 1 addition & 1 deletion .gitattributes
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
* text=auto
* text=auto eol=lf
*.css linguist-vendored
*.scss linguist-vendored
*.js linguist-vendored
Expand Down
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/.phpunit.cache
/node_modules
/public/hot
/public/storage
Expand All @@ -14,3 +15,6 @@ npm-debug.log
yarn-error.log
rr
.rr.yaml
.yarn/cache
public/resources/js/assets
frankenphp
2 changes: 1 addition & 1 deletion .gitmodules
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[submodule "laravel-chat-system"]
path = packages/laravel-chat-system
url = https://github.com/myckhel/laravel-chat-system.git
url = https://github.com/binkode/laravel-chat-system.git
Binary file added .yarn/install-state.gz
Binary file not shown.
934 changes: 934 additions & 0 deletions .yarn/releases/yarn-4.6.0.cjs

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions .yarnrc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
compressionLevel: mixed

enableGlobalCache: false

nodeLinker: node-modules

yarnPath: .yarn/releases/yarn-4.6.0.cjs
57 changes: 57 additions & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
# AGENTS.md

## Purpose
This is a Laravel testing application for the `binkode/laravel-chat-system` package. Use these rules to keep changes focused on exercising the package without turning this app into a production template.

## Project Facts (Source of Truth)
- App type: Laravel application used as a test harness
- Primary dependency under test: `binkode/laravel-chat-system`
- Frontend stack: Inertia + React + Vite
- PHP version target: as defined by the app `composer.json`
- Test framework: PHPUnit (via `composer test` or `php artisan test`)

## Non-Negotiable Rules
- Keep changes minimal and test-focused; do not refactor unrelated app code.
- Do not change package public APIs in `packages/` from this app unless explicitly asked.
- Avoid breaking changes to routes, auth, or Inertia setup used by tests/demos.
- No new dependencies unless required by the task and approved.
- Update docs when app usage or setup changes.

## Safe Change Boundaries
- Prefer changes in:
- `resources/` (views, JS, CSS)
- `routes/` (web and API routes)
- `tests/`
- `config/` (only when required to exercise package features)
- Avoid touching `vendor/` and lockfiles unless explicitly requested.

## Testing Rules
- Favor Laravel HTTP fakes for external calls.
- Add or update tests when behavior changes.
- Preferred test command: `php artisan test`.
- If tests cannot run, report why and what would be needed.

## Coding Conventions
- Match existing Laravel and project style (PSR-12 for PHP, standard React/Vite conventions).
- Keep controllers thin; push logic into app services only when necessary for test clarity.
- For frontend, keep components small and focused on demoing package features.

## Definition of Done
- App still boots and renders the chat system UI.
- Tests pass or a clear blocker is documented.
- Docs updated if setup or usage changed.

## High-Signal Prompt Template
```md
Task: <one clear outcome>
Context: <feature/bug + why it matters>
Scope: <files allowed to change>
Constraints: <no new deps, keep app as test harness, etc.>
Acceptance Criteria:
- <observable behavior 1>
- <observable behavior 2>
Tests:
- <exact command, usually `php artisan test`>
Deliverable:
- <changed files + rationale + any risks>
```
3 changes: 2 additions & 1 deletion Procfile
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
web: vendor/bin/heroku-php-apache2 public/
web: php artisan octane:start --server=swoole --host=0.0.0.0 --port=$PORT
worker: php artisan queue:work redis --queue=chat,chat-event --sleep=3 --tries=3 --daemon
51 changes: 21 additions & 30 deletions app/Exceptions/Handler.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,35 +7,26 @@

class Handler extends ExceptionHandler
{
/**
* A list of the exception types that are not reported.
*
* @var array
*/
protected $dontReport = [
//
];
/**
* A list of the inputs that are never flashed for validation exceptions.
*
* @var array
*/
protected $dontFlash = [
'current_password',
'password',
'password_confirmation',
];

/**
* A list of the inputs that are never flashed for validation exceptions.
*
* @var array
*/
protected $dontFlash = [
'current_password',
'password',
'password_confirmation',
];

/**
* Register the exception handling callbacks for the application.
*
* @return void
*/
public function register()
{
$this->reportable(function (Throwable $e) {
//
});
}
/**
* Register the exception handling callbacks for the application.
*
* @return void
*/
public function register()
{
$this->reportable(function (Throwable $e) {
//
});
}
}
112 changes: 56 additions & 56 deletions app/Http/Kernel.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,63 +7,63 @@

class Kernel extends HttpKernel
{
/**
* The application's global HTTP middleware stack.
*
* These middleware are run during every request to your application.
*
* @var array
*/
protected $middleware = [
// \App\Http\Middleware\TrustHosts::class,
\App\Http\Middleware\TrustProxies::class,
\Fruitcake\Cors\HandleCors::class,
\App\Http\Middleware\PreventRequestsDuringMaintenance::class,
\Illuminate\Foundation\Http\Middleware\ValidatePostSize::class,
\App\Http\Middleware\TrimStrings::class,
\Illuminate\Foundation\Http\Middleware\ConvertEmptyStringsToNull::class,
];
/**
* The application's global HTTP middleware stack.
*
* These middleware are run during every request to your application.
*
* @var array
*/
protected $middleware = [
// \App\Http\Middleware\TrustHosts::class,
\App\Http\Middleware\TrustProxies::class,
\App\Http\Middleware\PreventRequestsDuringMaintenance::class,
\Illuminate\Foundation\Http\Middleware\ValidatePostSize::class,
\App\Http\Middleware\TrimStrings::class,
\Illuminate\Foundation\Http\Middleware\ConvertEmptyStringsToNull::class,
];

/**
* The application's route middleware groups.
*
* @var array
*/
protected $middlewareGroups = [
'web' => [
\App\Http\Middleware\EncryptCookies::class,
\Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse::class,
\Illuminate\Session\Middleware\StartSession::class,
// \Illuminate\Session\Middleware\AuthenticateSession::class,
\Illuminate\View\Middleware\ShareErrorsFromSession::class,
\App\Http\Middleware\VerifyCsrfToken::class,
\Illuminate\Routing\Middleware\SubstituteBindings::class,
\App\Http\Middleware\HandleInertiaRequests::class,
],
/**
* The application's route middleware groups.
*
* @var array
*/
protected $middlewareGroups = [
'web' => [
\App\Http\Middleware\EncryptCookies::class,
\Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse::class,
\Illuminate\Session\Middleware\StartSession::class,
// \Illuminate\Session\Middleware\AuthenticateSession::class,
\Illuminate\View\Middleware\ShareErrorsFromSession::class,
\App\Http\Middleware\VerifyCsrfToken::class,
\Illuminate\Routing\Middleware\SubstituteBindings::class,
\App\Http\Middleware\HandleInertiaRequests::class,
],

'api' => [
EnsureFrontendRequestsAreStateful::class,
'throttle:api',
\Illuminate\Routing\Middleware\SubstituteBindings::class,
],
];
'api' => [
EnsureFrontendRequestsAreStateful::class,
\Illuminate\Routing\Middleware\ThrottleRequests::class . ':api',
\Illuminate\Routing\Middleware\SubstituteBindings::class,
],
];

/**
* The application's route middleware.
*
* These middleware may be assigned to groups or used individually.
*
* @var array
*/
protected $routeMiddleware = [
'auth' => \App\Http\Middleware\Authenticate::class,
'auth.basic' => \Illuminate\Auth\Middleware\AuthenticateWithBasicAuth::class,
'cache.headers' => \Illuminate\Http\Middleware\SetCacheHeaders::class,
'can' => \Illuminate\Auth\Middleware\Authorize::class,
'guest' => \App\Http\Middleware\RedirectIfAuthenticated::class,
'password.confirm' => \Illuminate\Auth\Middleware\RequirePassword::class,
'signed' => \Illuminate\Routing\Middleware\ValidateSignature::class,
'throttle' => \Illuminate\Routing\Middleware\ThrottleRequests::class,
'verified' => \Illuminate\Auth\Middleware\EnsureEmailIsVerified::class,
];
/**
* The application's route middleware.
*
* These middleware may be assigned to groups or used individually.
*
* @var array
*/
protected $middlewareAliases = [
'auth' => \App\Http\Middleware\Authenticate::class,
'auth.basic' => \Illuminate\Auth\Middleware\AuthenticateWithBasicAuth::class,
'cache.headers' => \Illuminate\Http\Middleware\SetCacheHeaders::class,
'can' => \Illuminate\Auth\Middleware\Authorize::class,
'guest' => \App\Http\Middleware\RedirectIfAuthenticated::class,
'password.confirm' => \Illuminate\Auth\Middleware\RequirePassword::class,
'precognitive' => \Illuminate\Foundation\Http\Middleware\HandlePrecognitiveRequests::class,
'signed' => \Illuminate\Routing\Middleware\ValidateSignature::class,
'throttle' => \Illuminate\Routing\Middleware\ThrottleRequests::class,
'verified' => \Illuminate\Auth\Middleware\EnsureEmailIsVerified::class,
];
}
Loading