add spotlight
This commit is contained in:
1 parent
c7ceaf6556
commit
651b730233
7 files changed
+154
-3
No files matched your search
@@ -4,7 +4,6 @@
|
|||||||
|
|
||||||
use App\Modules\Makeable;
|
use App\Modules\Makeable;
|
||||||
use App\Modules\ModuleContract;
|
use App\Modules\ModuleContract;
|
||||||
use Illuminate\Database\Eloquent\SoftDeletes;
|
|
||||||
|
|
||||||
class IncomingLetterModule implements ModuleContract
|
class IncomingLetterModule implements ModuleContract
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -16,6 +16,7 @@
|
|||||||
use Illuminate\Session\Middleware\AuthenticateSession;
|
use Illuminate\Session\Middleware\AuthenticateSession;
|
||||||
use Illuminate\Session\Middleware\StartSession;
|
use Illuminate\Session\Middleware\StartSession;
|
||||||
use Illuminate\View\Middleware\ShareErrorsFromSession;
|
use Illuminate\View\Middleware\ShareErrorsFromSession;
|
||||||
|
use pxlrbt\FilamentSpotlight\SpotlightPlugin;
|
||||||
|
|
||||||
class AdminPanelProvider extends PanelProvider
|
class AdminPanelProvider extends PanelProvider
|
||||||
{
|
{
|
||||||
@@ -51,6 +52,9 @@ public function panel(Panel $panel): Panel
|
|||||||
->spa()
|
->spa()
|
||||||
->authMiddleware([
|
->authMiddleware([
|
||||||
Authenticate::class,
|
Authenticate::class,
|
||||||
|
])
|
||||||
|
->plugins([
|
||||||
|
SpotlightPlugin::make(),
|
||||||
]);
|
]);
|
||||||
|
|
||||||
return $panel;
|
return $panel;
|
||||||
|
|||||||
+2
-1
@@ -10,7 +10,8 @@
|
|||||||
"laravel/framework": "^11.9",
|
"laravel/framework": "^11.9",
|
||||||
"laravel/tinker": "^2.9",
|
"laravel/tinker": "^2.9",
|
||||||
"phpoffice/phpspreadsheet": "^3.3",
|
"phpoffice/phpspreadsheet": "^3.3",
|
||||||
"phpoffice/phpword": "^1.3"
|
"phpoffice/phpword": "^1.3",
|
||||||
|
"pxlrbt/filament-spotlight": "^1.3"
|
||||||
},
|
},
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
"barryvdh/laravel-ide-helper": "^3.2",
|
"barryvdh/laravel-ide-helper": "^3.2",
|
||||||
|
|||||||
Generated
+141
-1
@@ -4,7 +4,7 @@
|
|||||||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
||||||
"This file is @generated automatically"
|
"This file is @generated automatically"
|
||||||
],
|
],
|
||||||
"content-hash": "2c5e3e156b6775d0bb4507a50ddce50a",
|
"content-hash": "55801972ed58a124b181945f6488dd4e",
|
||||||
"packages": [
|
"packages": [
|
||||||
{
|
{
|
||||||
"name": "anourvalar/eloquent-serialize",
|
"name": "anourvalar/eloquent-serialize",
|
||||||
@@ -4857,6 +4857,72 @@
|
|||||||
},
|
},
|
||||||
"time": "2024-06-10T01:18:23+00:00"
|
"time": "2024-06-10T01:18:23+00:00"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "pxlrbt/filament-spotlight",
|
||||||
|
"version": "v1.3.0",
|
||||||
|
"source": {
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://github.com/pxlrbt/filament-spotlight.git",
|
||||||
|
"reference": "85e6f0073d521f2eeb1c6af2554b354f1085e23b"
|
||||||
|
},
|
||||||
|
"dist": {
|
||||||
|
"type": "zip",
|
||||||
|
"url": "https://api.github.com/repos/pxlrbt/filament-spotlight/zipball/85e6f0073d521f2eeb1c6af2554b354f1085e23b",
|
||||||
|
"reference": "85e6f0073d521f2eeb1c6af2554b354f1085e23b",
|
||||||
|
"shasum": ""
|
||||||
|
},
|
||||||
|
"require": {
|
||||||
|
"filament/filament": "^3.0.0-stable",
|
||||||
|
"php": "^8.0",
|
||||||
|
"wire-elements/spotlight": "^2.0"
|
||||||
|
},
|
||||||
|
"require-dev": {
|
||||||
|
"laravel/pint": "^1.10"
|
||||||
|
},
|
||||||
|
"type": "library",
|
||||||
|
"extra": {
|
||||||
|
"laravel": {
|
||||||
|
"providers": [
|
||||||
|
"pxlrbt\\FilamentSpotlight\\SpotlightServiceProvider"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"autoload": {
|
||||||
|
"psr-4": {
|
||||||
|
"pxlrbt\\FilamentSpotlight\\": "src/"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"notification-url": "https://packagist.org/downloads/",
|
||||||
|
"license": [
|
||||||
|
"MIT"
|
||||||
|
],
|
||||||
|
"authors": [
|
||||||
|
{
|
||||||
|
"name": "Dennis Koch",
|
||||||
|
"email": "info@pixelarbeit.de"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"description": "Spotlight for Filament Admin",
|
||||||
|
"keywords": [
|
||||||
|
"alfred",
|
||||||
|
"filament",
|
||||||
|
"laravel",
|
||||||
|
"laravel-filament",
|
||||||
|
"spotlight",
|
||||||
|
"wire-elements"
|
||||||
|
],
|
||||||
|
"support": {
|
||||||
|
"issues": "https://github.com/pxlrbt/filament-spotlight/issues",
|
||||||
|
"source": "https://github.com/pxlrbt/filament-spotlight/tree/v1.3.0"
|
||||||
|
},
|
||||||
|
"funding": [
|
||||||
|
{
|
||||||
|
"url": "https://github.com/pxlrbt",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"time": "2024-11-18T14:17:47+00:00"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "ralouphie/getallheaders",
|
"name": "ralouphie/getallheaders",
|
||||||
"version": "3.0.3",
|
"version": "3.0.3",
|
||||||
@@ -7901,6 +7967,80 @@
|
|||||||
"source": "https://github.com/webmozarts/assert/tree/1.11.0"
|
"source": "https://github.com/webmozarts/assert/tree/1.11.0"
|
||||||
},
|
},
|
||||||
"time": "2022-06-03T18:03:27+00:00"
|
"time": "2022-06-03T18:03:27+00:00"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "wire-elements/spotlight",
|
||||||
|
"version": "2.0.1",
|
||||||
|
"source": {
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://github.com/wire-elements/spotlight.git",
|
||||||
|
"reference": "1d64ebdc9ea56761f6be0e5554765ce498fb16a8"
|
||||||
|
},
|
||||||
|
"dist": {
|
||||||
|
"type": "zip",
|
||||||
|
"url": "https://api.github.com/repos/wire-elements/spotlight/zipball/1d64ebdc9ea56761f6be0e5554765ce498fb16a8",
|
||||||
|
"reference": "1d64ebdc9ea56761f6be0e5554765ce498fb16a8",
|
||||||
|
"shasum": ""
|
||||||
|
},
|
||||||
|
"require": {
|
||||||
|
"illuminate/contracts": "^8.0|^9.0|^10.0|^11.0",
|
||||||
|
"livewire/livewire": "^3.0",
|
||||||
|
"php": "^8.1",
|
||||||
|
"spatie/laravel-package-tools": "^1.4.3"
|
||||||
|
},
|
||||||
|
"require-dev": {
|
||||||
|
"brianium/paratest": "^6.2|^7.4",
|
||||||
|
"nunomaduro/collision": "^5.3|^8.0",
|
||||||
|
"orchestra/testbench": "^6.15|^7.0|^8.0|^9.0",
|
||||||
|
"phpunit/phpunit": "^9.3|^10.5",
|
||||||
|
"vimeo/psalm": "^4.4|^5.22"
|
||||||
|
},
|
||||||
|
"type": "library",
|
||||||
|
"extra": {
|
||||||
|
"laravel": {
|
||||||
|
"providers": [
|
||||||
|
"LivewireUI\\Spotlight\\SpotlightServiceProvider"
|
||||||
|
],
|
||||||
|
"aliases": {
|
||||||
|
"Spotlight": "LivewireUI\\Spotlight\\SpotlightFacade"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"autoload": {
|
||||||
|
"psr-4": {
|
||||||
|
"LivewireUI\\Spotlight\\": "src",
|
||||||
|
"LivewireUI\\Spotlight\\Database\\Factories\\": "database/factories"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"notification-url": "https://packagist.org/downloads/",
|
||||||
|
"license": [
|
||||||
|
"MIT"
|
||||||
|
],
|
||||||
|
"authors": [
|
||||||
|
{
|
||||||
|
"name": "Philo Hermans",
|
||||||
|
"email": "support@wire-elements.dev",
|
||||||
|
"role": "Developer"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"description": "Livewire component that provides Spotlight/Alfred-like functionality to your Laravel application.",
|
||||||
|
"homepage": "https://github.com/wire-elements/spotlight",
|
||||||
|
"keywords": [
|
||||||
|
"laravel",
|
||||||
|
"livewire-ui",
|
||||||
|
"spotlight"
|
||||||
|
],
|
||||||
|
"support": {
|
||||||
|
"issues": "https://github.com/wire-elements/spotlight/issues",
|
||||||
|
"source": "https://github.com/wire-elements/spotlight/tree/2.0.1"
|
||||||
|
},
|
||||||
|
"funding": [
|
||||||
|
{
|
||||||
|
"url": "https://github.com/livewire-ui",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"time": "2024-03-02T12:10:01+00:00"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"packages-dev": [
|
"packages-dev": [
|
||||||
|
|||||||
@@ -0,0 +1,5 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
'placeholder' => 'What do you want to do?',
|
||||||
|
];
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
.right-5{right:1.25rem}.ml-1{margin-left:.25rem}.appearance-none{-webkit-appearance:none;-moz-appearance:none;appearance:none}.border-gray-800{--tw-border-opacity:1;border-color:rgb(31 41 55/var(--tw-border-opacity))}.bg-gray-700{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity))}.bg-gray-800{--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity))}.bg-gray-900{--tw-bg-opacity:1;background-color:rgb(17 24 39/var(--tw-bg-opacity))}.pt-16{padding-top:4rem}.text-gray-300{--tw-text-opacity:1;color:rgb(209 213 219/var(--tw-text-opacity))}.placeholder-gray-500::-moz-placeholder{--tw-placeholder-opacity:1;color:rgb(107 114 128/var(--tw-placeholder-opacity))}.placeholder-gray-500::placeholder{--tw-placeholder-opacity:1;color:rgb(107 114 128/var(--tw-placeholder-opacity))}.opacity-25{opacity:.25}.opacity-75{opacity:.75}.duration-150,.transition-opacity{transition-duration:.15s}[x-cloak=""]{display:none!important}.hover\:bg-gray-800:hover{--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity))}.focus\:border-0:focus{border-width:0}.focus\:border-transparent:focus{border-color:transparent}.focus\:shadow-none:focus{--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}@media (min-width:640px){.sm\:pt-24{padding-top:6rem}}
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
(()=>{var e,t={794:(e,t,n)=>{n(27)},27:(e,t,n)=>{"use strict";function s(e){return Array.isArray?Array.isArray(e):"[object Array]"===d(e)}n.r(t);const i=1/0;function r(e){return null==e?"":function(e){if("string"==typeof e)return e;let t=e+"";return"0"==t&&1/e==-i?"-0":t}(e)}function c(e){return"string"==typeof e}function o(e){return"number"==typeof e}function h(e){return!0===e||!1===e||function(e){return a(e)&&null!==e}(e)&&"[object Boolean]"==d(e)}function a(e){return"object"==typeof e}function l(e){return null!=e}function u(e){return!e.trim().length}function d(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":Object.prototype.toString.call(e)}const p=e=>`Missing ${e} property in key`,g=e=>`Property 'weight' in key '${e}' must be a positive integer`,f=Object.prototype.hasOwnProperty;class m{constructor(e){this._keys=[],this._keyMap={};let t=0;e.forEach((e=>{let n=y(e);t+=n.weight,this._keys.push(n),this._keyMap[n.id]=n,t+=n.weight})),this._keys.forEach((e=>{e.weight/=t}))}get(e){return this._keyMap[e]}keys(){return this._keys}toJSON(){return JSON.stringify(this._keys)}}function y(e){let t=null,n=null,i=null,r=1,o=null;if(c(e)||s(e))i=e,t=M(e),n=x(e);else{if(!f.call(e,"name"))throw new Error(p("name"));const s=e.name;if(i=s,f.call(e,"weight")&&(r=e.weight,r<=0))throw new Error(g(s));t=M(s),n=x(s),o=e.getFn}return{path:t,id:n,weight:r,src:i,getFn:o}}function M(e){return s(e)?e:e.split(".")}function x(e){return s(e)?e.join("."):e}var v={isCaseSensitive:!1,includeScore:!1,keys:[],shouldSort:!0,sortFn:(e,t)=>e.score===t.score?e.idx<t.idx?-1:1:e.score<t.score?-1:1,includeMatches:!1,findAllMatches:!1,minMatchCharLength:1,location:0,threshold:.6,distance:100,...{useExtendedSearch:!1,getFn:function(e,t){let n=[],i=!1;const a=(e,t,u)=>{if(l(e))if(t[u]){const d=e[t[u]];if(!l(d))return;if(u===t.length-1&&(c(d)||o(d)||h(d)))n.push(r(d));else if(s(d)){i=!0;for(let e=0,n=d.length;e<n;e+=1)a(d[e],t,u+1)}else t.length&&a(d,t,u+1)}else n.push(e)};return a(e,c(t)?t.split("."):t,0),i?n:n[0]},ignoreLocation:!1,ignoreFieldNorm:!1,fieldNormWeight:1}};const w=/[^ ]+/g;class k{constructor({getFn:e=v.getFn,fieldNormWeight:t=v.fieldNormWeight}={}){this.norm=function(e=1,t=3){const n=new Map,s=Math.pow(10,t);return{get(t){const i=t.match(w).length;if(n.has(i))return n.get(i);const r=1/Math.pow(i,.5*e),c=parseFloat(Math.round(r*s)/s);return n.set(i,c),c},clear(){n.clear()}}}(t,3),this.getFn=e,this.isCreated=!1,this.setIndexRecords()}setSources(e=[]){this.docs=e}setIndexRecords(e=[]){this.records=e}setKeys(e=[]){this.keys=e,this._keysMap={},e.forEach(((e,t)=>{this._keysMap[e.id]=t}))}create(){!this.isCreated&&this.docs.length&&(this.isCreated=!0,c(this.docs[0])?this.docs.forEach(((e,t)=>{this._addString(e,t)})):this.docs.forEach(((e,t)=>{this._addObject(e,t)})),this.norm.clear())}add(e){const t=this.size();c(e)?this._addString(e,t):this._addObject(e,t)}removeAt(e){this.records.splice(e,1);for(let t=e,n=this.size();t<n;t+=1)this.records[t].i-=1}getValueForItemAtKeyId(e,t){return e[this._keysMap[t]]}size(){return this.records.length}_addString(e,t){if(!l(e)||u(e))return;let n={v:e,i:t,n:this.norm.get(e)};this.records.push(n)}_addObject(e,t){let n={i:t,$:{}};this.keys.forEach(((t,i)=>{let r=t.getFn?t.getFn(e):this.getFn(e,t.path);if(l(r))if(s(r)){let e=[];const t=[{nestedArrIndex:-1,value:r}];for(;t.length;){const{nestedArrIndex:n,value:i}=t.pop();if(l(i))if(c(i)&&!u(i)){let t={v:i,i:n,n:this.norm.get(i)};e.push(t)}else s(i)&&i.forEach(((e,n)=>{t.push({nestedArrIndex:n,value:e})}))}n.$[i]=e}else if(c(r)&&!u(r)){let e={v:r,n:this.norm.get(r)};n.$[i]=e}})),this.records.push(n)}toJSON(){return{keys:this.keys,records:this.records}}}function L(e,t,{getFn:n=v.getFn,fieldNormWeight:s=v.fieldNormWeight}={}){const i=new k({getFn:n,fieldNormWeight:s});return i.setKeys(e.map(y)),i.setSources(t),i.create(),i}function S(e,{errors:t=0,currentLocation:n=0,expectedLocation:s=0,distance:i=v.distance,ignoreLocation:r=v.ignoreLocation}={}){const c=t/e.length;if(r)return c;const o=Math.abs(s-n);return i?c+o/i:o?1:c}const I=32;function C(e,t,n,{location:s=v.location,distance:i=v.distance,threshold:r=v.threshold,findAllMatches:c=v.findAllMatches,minMatchCharLength:o=v.minMatchCharLength,includeMatches:h=v.includeMatches,ignoreLocation:a=v.ignoreLocation}={}){if(t.length>I)throw new Error(`Pattern length exceeds max of ${I}.`);const l=t.length,u=e.length,d=Math.max(0,Math.min(s,u));let p=r,g=d;const f=o>1||h,m=f?Array(u):[];let y;for(;(y=e.indexOf(t,g))>-1;){let e=S(t,{currentLocation:y,expectedLocation:d,distance:i,ignoreLocation:a});if(p=Math.min(e,p),g=y+l,f){let e=0;for(;e<l;)m[y+e]=1,e+=1}}g=-1;let M=[],x=1,w=l+u;const k=1<<l-1;for(let s=0;s<l;s+=1){let r=0,o=w;for(;r<o;){S(t,{errors:s,currentLocation:d+o,expectedLocation:d,distance:i,ignoreLocation:a})<=p?r=o:w=o,o=Math.floor((w-r)/2+r)}w=o;let h=Math.max(1,d-o+1),y=c?u:Math.min(d+o,u)+l,v=Array(y+2);v[y+1]=(1<<s)-1;for(let r=y;r>=h;r-=1){let c=r-1,o=n[e.charAt(c)];if(f&&(m[c]=+!!o),v[r]Line truncated
|
||||||
Reference in new issue
Block a user