Skip to content

Commit 549c924

Browse files
Init (#1)
1 parent a6fa9aa commit 549c924

22 files changed

+354
-14
lines changed

README.md

Lines changed: 29 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,38 @@
66
composer require rapidez/fullscreen-search
77
```
88

9+
To use the views from this package instead of the default ones, you'll need to publish the "core overwrite views" with the following command:
10+
```
11+
php artisan vendor:publish --provider="Rapidez\FullscreenSearch\FullscreenSearchServiceProvider" --tag=core-overwrites
12+
```
13+
914
## Configuration
1015

11-
You can publish the config with:
16+
Don't forget to add this to your config:
17+
18+
tailwind.config.js
19+
```
20+
'header-autocomplete-popup': '40',
21+
```
22+
23+
config/rapidez/frontend.php
1224
```
13-
php artisan vendor:publish --tag=rapidez-fullscreen-search-config
25+
'autocomplete' => [
26+
'additionals' => [
27+
'history' => [],
28+
'search-suggestions' => [],
29+
'categories' => [
30+
'defaultValues' => fn () => config('rapidez.models.category')::where('parent_id', config('rapidez.root_category_id'))
31+
->limit(config('rapidez.frontend.autocomplete.additionals.categories.size', config('rapidez.frontend.autocomplete.size', 4)))
32+
->get(),
33+
],
34+
'popular-products' => ['size' => 4],
35+
'products' => [
36+
'size' => 4,
37+
],
38+
],
39+
'size' => 4,
40+
],
1441
```
1542

1643
## Views

config/rapidez/fullscreen-search.php

Lines changed: 0 additions & 3 deletions
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@include('rapidez-fullscreen-search::layouts.partials.header.autocomplete')
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@include('rapidez-fullscreen-search::layouts.partials.header.autocomplete.all-results')
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@include('rapidez-fullscreen-search::layouts.partials.header.autocomplete.categories')
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@include('rapidez-fullscreen-search::layouts.partials.header.autocomplete.history')
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@include('rapidez-fullscreen-search::layouts.partials.header.autocomplete.no-results')
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@include('rapidez-fullscreen-search::layouts.partials.header.autocomplete.popular-products')
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@include('rapidez-fullscreen-search::layouts.partials.header.autocomplete.products')
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@include('rapidez-fullscreen-search::layouts.partials.header.autocomplete.results')

0 commit comments

Comments
 (0)