Skip to content

Commit

Permalink
docs: Add useInternalPreviewUrl
Browse files Browse the repository at this point in the history
  • Loading branch information
pboivin committed Oct 1, 2023
1 parent 9dffb50 commit 5c7ecca
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 1 deletion.
12 changes: 12 additions & 0 deletions config/filament-peek.php
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,18 @@

'closeModalWithEscapeKey' => true,

/*
|--------------------------------------------------------------------------
| Use Internal Preview URL
|--------------------------------------------------------------------------
|
| Set this to `true` to render all Blade previews through an internal URL.
| This improves the isolation of the iframe in the context of the page.
|
*/

'useInternalPreviewUrl' => false,

/*
|--------------------------------------------------------------------------
| Builder Editor
Expand Down
1 change: 1 addition & 0 deletions docs/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ Here are the main options you can configure:
| `allowIframeOverflow` | `bool` | Allow the iframe dimensions to go beyond the capacity of the available preview modal area. |
| `allowIframePointerEvents` | `bool` | Allow all pointer events within the iframe. By default, only scrolling is allowed. (Does not apply when using a preview URL. See [Pointer Events](./page-previews.md#preview-pointer-events)) |
| `closeModalWithEscapeKey` | `bool` | Close the preview modal by pressing the Escape key. (Does not apply to Builder previews.) |
| `useInternalPreviewUrl` | `bool` | Render Blade previews through an internal URL. |
| `builderEditor` | `array` | Options related to the Editor sidebar in [Builder Previews](./builder-previews.md). |

Builder Editor options:
Expand Down
1 change: 0 additions & 1 deletion routes/web.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
use Illuminate\Support\Facades\Route;
use Pboivin\FilamentPeek\CachedPreview;

// @todo: Document config
if (config('filament-peek.useInternalPreviewUrl', false)) {
Route::prefix('filament-peek')->group(function () {
Route::get('preview', function () {
Expand Down

0 comments on commit 5c7ecca

Please sign in to comment.