generated from spatie/package-skeleton-laravel
-
Notifications
You must be signed in to change notification settings - Fork 39
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
21 changed files
with
480 additions
and
385 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,39 +1,40 @@ | ||
@php | ||
$chartId = $this->getChartId(); | ||
$heading = $this->getHeading(); | ||
$pollingInterval = $this->getPollingInterval(); | ||
$contentHeight = $this->getContentHeight(); | ||
$subheading = $this->getSubheading(); | ||
$filters = $this->getFilters(); | ||
$indicatorsCount = $this->indicatorsCount(); | ||
$filterForm = $this->form; | ||
$readyToLoad = $this->readyToLoad; | ||
$getCachedOptions = $this->getCachedOptions(); | ||
$indicatorsCount = $this->getIndicatorsCount(); | ||
$darkMode = $this->getDarkMode(); | ||
$width = 'xs'; | ||
$pollingInterval = $this->getPollingInterval(); | ||
$chartId = $this->getChartId(); | ||
$chartOptions = $this->getOptions(); | ||
$filterFormAccessible = $this->getFilterFormAccessible(); | ||
$loadingIndicator = $this->getLoadingIndicator(); | ||
$footer = $this->getFooter(); | ||
$contentHeight = $this->getContentHeight(); | ||
$deferLoading = $this->getDeferLoading(); | ||
$darkModeEnabled = $this->getDarkMode(); | ||
$footer = $this->getFooter(); | ||
$readyToLoad = $this->readyToLoad; | ||
@endphp | ||
<x-filament::widget class="filament-widgets-chart-widget filament-apex-charts-widget"> | ||
<x-filament::card class="filament-apex-charts-card" x-data="{ dropdownOpen: false }" | ||
@apexhcharts-dropdown.window="dropdownOpen = event.detail.open"> | ||
|
||
<x-filament::widget class="filament-widgets-chart-widget"> | ||
<x-filament::card> | ||
<x-filament-apex-charts::header :$heading :$subheading :$filters :$indicatorsCount :$width | ||
:$filterFormAccessible> | ||
<x-slot:filterForm> | ||
{{ $this->form }} | ||
</x-slot:filterForm> | ||
</x-filament-apex-charts::header> | ||
|
||
<x-filament-apex-charts::widget-content :chartId="$chartId" :pollingInterval="$pollingInterval" :deferLoading="$deferLoading"> | ||
<x-filament-apex-charts::chart :$chartId :$chartOptions :$contentHeight :$pollingInterval :$loadingIndicator | ||
:$darkMode :$deferLoading :$readyToLoad /> | ||
|
||
@if ($heading || $filters || ($filterForm && $filterFormAccessible)) | ||
<x-filament-apex-charts::header :heading="$heading" :filters="$filters" | ||
filterForm="{{ $filterFormAccessible ? $filterForm : null }}" :indicatorsCount="$indicatorsCount" /> | ||
@endif | ||
|
||
<x-filament-apex-charts::chart :chartId="$chartId" :contentHeight="$contentHeight" :pollingInterval="$pollingInterval" :readyToLoad="$readyToLoad" | ||
:getCachedOptions="$getCachedOptions" :loadingIndicator="$loadingIndicator" :darkModeEnabled="$darkModeEnabled" /> | ||
|
||
@if ($footer) | ||
<div class="relative"> | ||
{!! $footer !!} | ||
</div> | ||
@endif | ||
</x-filament-apex-charts::widget-content> | ||
@if ($footer) | ||
<div class="relative"> | ||
{!! $footer !!} | ||
</div> | ||
@endif | ||
|
||
</x-filament::card> | ||
|
||
</x-filament::widget> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,39 +1,48 @@ | ||
<div> | ||
@if ($heading) | ||
<div class="flex items-center justify-between gap-8 py-2"> | ||
@props(['heading', 'subheading', 'filters', 'indicatorsCount', 'width', 'filterFormAccessible']) | ||
<div class="filament-apex-charts-header"> | ||
@if ($heading || $subheading || $filters || $filterFormAccessible) | ||
<div class="sm:flex justify-between gap-4 py-2 relative"> | ||
|
||
<x-filament::card.heading> | ||
{!! $heading !!} | ||
</x-filament::card.heading> | ||
<div> | ||
@if ($heading) | ||
<x-filament::card.heading class="filament-apex-charts-heading"> | ||
{!! $heading !!} | ||
</x-filament::card.heading> | ||
@endif | ||
|
||
<div class="relative h-10"> | ||
@if ($subheading) | ||
<div class="filament-apex-charts-subheading text-sm text-gray-600 dark:text-gray-300"> | ||
{!! $subheading !!} | ||
</div> | ||
@endif | ||
</div> | ||
|
||
<div> | ||
@if ($filters) | ||
<select wire:model="filter" @class([ | ||
'apex-charts-single-filter w-full text-gray-900 border-gray-300 block h-10 transition duration-75 rounded-lg shadow-sm focus:border-primary-500 focus:ring-1 focus:ring-inset focus:ring-primary-500', | ||
'dark:bg-gray-700 dark:border-gray-600 dark:text-gray-200 dark:focus:border-primary-500' => config( | ||
'filament.dark_mode'), | ||
]) wire:loading.class="animate-pulse"> | ||
@foreach ($filters as $value => $label) | ||
<option value="{{ $value }}"> | ||
{{ $label }} | ||
</option> | ||
@endforeach | ||
</select> | ||
@endif | ||
</div> | ||
|
||
<div class="flex items-center justify-between gap-4"> | ||
@if ($filters) | ||
<select wire:model="filter" @class([ | ||
'text-gray-900 border-gray-300 block h-10 transition duration-75 rounded-lg shadow-sm focus:border-primary-500 focus:ring-1 focus:ring-inset focus:ring-primary-500', | ||
'dark:bg-gray-700 dark:border-gray-600 dark:text-gray-200 dark:focus:border-primary-500' => config( | ||
'filament.dark_mode'), | ||
]) wire:loading.class="animate-pulse"> | ||
@foreach ($filters as $value => $label) | ||
<option value="{{ $value }}"> | ||
{{ $label }} | ||
</option> | ||
@endforeach | ||
</select> | ||
@endif | ||
@if ($filterFormAccessible) | ||
<div> | ||
|
||
<x-filament-apex-charts::filter-form :$indicatorsCount :$width> | ||
{{ $filterForm }} | ||
</x-filament-apex-charts::filter-form> | ||
|
||
@if ($filterForm) | ||
<x-filament-apex-charts::filter-form width="xs" darkMode="{{ config('filament.dark_mode') }}" | ||
:indicatorsCount="$indicatorsCount"> | ||
{!! $filterForm !!} | ||
</x-filament-apex-charts::filter-form> | ||
@endif | ||
</div> | ||
</div> | ||
@endif | ||
|
||
</div> | ||
|
||
<x-filament::hr class="py-2" /> | ||
@endif | ||
</div> |
19 changes: 0 additions & 19 deletions
19
resources/views/widgets/components/widget-content.blade.php
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.