chore(deps): added adminlte vendored items

(this might not be entirely necessary unless we're changing everything adminlte publishes)

Signed-off-by: miguel456 <me@nogueira.codes>
This commit is contained in:
2023-02-26 02:15:25 +00:00
parent 0695262e73
commit 25fe13f091
66 changed files with 3354 additions and 0 deletions

View File

@@ -0,0 +1,26 @@
<div {{ $attributes->merge(['class' => $makeAlertClass()]) }}>
{{-- Dismiss button --}}
@isset($dismissable)
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">
&times;
</button>
@endisset
{{-- Alert header --}}
@if(! empty($title) || ! empty($icon))
<h5>
@if(! empty($icon))
<i class="icon {{ $icon }}"></i>
@endif
@if(! empty($title))
{{ $title }}
@endif
</h5>
@endif
{{-- Alert content --}}
{{ $slot }}
</div>

View File

@@ -0,0 +1,14 @@
<div {{ $attributes->merge(['class' => $makeCalloutClass()]) }}>
{{-- Callout title --}}
@if(! empty($title) || ! empty($icon))
<h5 @isset($titleClass) class="{{ $titleClass }}" @endisset>
@isset($icon) <i class="{{ $icon }} mr-2"></i> @endisset
@isset($title) {{ $title }} @endisset
</h5>
@endif
{{-- Callout content --}}
{{ $slot }}
</div>

View File

@@ -0,0 +1,62 @@
<div {{ $attributes->merge(['class' => $makeCardClass()]) }}>
{{-- Card header --}}
@if(! $isCardHeaderEmpty(isset($toolsSlot)))
<div class="{{ $makeCardHeaderClass() }}">
{{-- Title --}}
<h3 class="{{ $makeCardTitleClass() }}">
@isset($icon)<i class="{{ $icon }} mr-1"></i>@endisset
@isset($title){{ $title }}@endisset
</h3>
{{-- Tools --}}
<div class="card-tools">
{{-- Extra tools slot --}}
@isset($toolsSlot)
{{ $toolsSlot }}
@endisset
{{-- Default tools --}}
@isset($maximizable)
<x-adminlte-button theme="tool" data-card-widget="maximize" icon="fas fa-lg fa-expand"/>
@endisset
@if($collapsible === 'collapsed')
<x-adminlte-button theme="tool" data-card-widget="collapse" icon="fas fa-lg fa-plus"/>
@elseif(isset($collapsible))
<x-adminlte-button theme="tool" data-card-widget="collapse" icon="fas fa-lg fa-minus"/>
@endif
@isset($removable)
<x-adminlte-button theme="tool" data-card-widget="remove" icon="fas fa-lg fa-times"/>
@endisset
</div>
</div>
@endif
{{-- Card body --}}
@if(! $slot->isEmpty())
<div class="{{ $makeCardBodyClass() }}">
{{ $slot }}
</div>
@endif
{{-- Card footer --}}
@isset($footerSlot)
<div class="{{ $makeCardFooterClass() }}">
{{ $footerSlot }}
</div>
@endisset
{{-- Card overlay --}}
@if($disabled)
<div class="overlay">
<i class="fas fa-2x fa-ban text-gray"></i>
</div>
@endif
</div>

View File

@@ -0,0 +1,102 @@
<div {{ $attributes->merge(['class' => $makeBoxClass()]) }}>
{{-- Box icon --}}
@isset($icon)
<span class="{{ $makeIconClass() }}">
<i class="{{ $icon }}"></i>
</span>
@endisset
{{-- Box content --}}
<div class="info-box-content">
{{-- Box title --}}
@isset($title)
<span class="info-box-text">{{ $title }}</span>
@endisset
{{-- Box short text --}}
@isset($text)
<span class="info-box-number">{{ $text }}</span>
@endisset
{{-- Box progress bar --}}
@if(isset($progress) && isset($attributes['id']))
<x-adminlte-progress value="{{ $progress }}" theme="{{ $progressTheme }}"
id="progress-{{ $attributes['id'] }}"/>
@elseif(isset($progress))
<x-adminlte-progress value="{{ $progress }}" theme="{{ $progressTheme }}"/>
@endif
{{-- Box long description --}}
@isset($description)
<span class="progress-description">{{ $description }}</span>
@endisset
</div>
</div>
{{-- Register Javascript utility class for this component --}}
@once
@push('js')
<script>
class _AdminLTE_InfoBox {
/**
* Constructor.
*
* target: The id of the target info box.
*/
constructor(target)
{
this.target = target;
}
/**
* Update the info box.
*
* data: An object with the new data.
*/
update(data)
{
// Check if target and data exists.
let t = $(`#${this.target}`);
if (t.length <= 0 || ! data) {
return;
}
// Update available data.
if (data.title) {
t.find('.info-box-text').html(data.title);
}
if (data.text) {
t.find('.info-box-number').html(data.text);
}
if (data.icon) {
t.find('.info-box-icon i').attr('class', data.icon);
}
if (data.description) {
t.find('.progress-description').html(data.description);
}
// Update progress bar.
if (data.progress) {
let pBar = new _AdminLTE_Progress(`progress-${this.target}`);
pBar.setValue(data.progress);
}
}
}
</script>
@endpush
@endonce

View File

@@ -0,0 +1,32 @@
<div {{ $attributes->merge(['class' => "col-{$size}"]) }}>
<div class="description-block">
{{-- Icon --}}
@isset($icon)
<i class="{{ $icon }}"></i>
@endisset
{{-- Header --}}
@isset($title)
<h5 class="description-header">
@if(! empty($url))
<a href="{{ $url }}">{{ $title }}</a>
@else
{{ $title }}
@endif
</h5>
@endisset
{{-- Text --}}
@isset($text)
<p class="description-text">
<span class="{{ $makeTextWrapperClass() }}">
{{ $text }}
</span>
</p>
@endisset
</div>
</div>

View File

@@ -0,0 +1,28 @@
<div {{ $attributes->merge(['class' => "p-0 col-{$size}"]) }}>
<span class="nav-link">
{{-- Icon --}}
@isset($icon)
<i class="{{ $icon }}"></i>
@endisset
{{-- Header --}}
@isset($title)
@if(! empty($url))
<a href="{{ $url }}">{{ $title }}</a>
@else
{{ $title }}
@endif
@endisset
{{-- Text --}}
@isset($text)
<span class="{{ $makeTextWrapperClass() }}">
{{ $text }}
</span>
@endisset
</span>
</div>

View File

@@ -0,0 +1,40 @@
<div {{ $attributes->merge(['class' => $makeCardClass()]) }}>
{{-- Profile header --}}
<div class="{{ $makeHeaderClass() }}" style="{{ $makeHeaderStyle() }}">
{{-- User image --}}
<div class="widget-user-image">
@if(isset($img))
<img class="img-circle elevation-2" src="{{ $img }}" alt="User avatar: {{ $name }}">
@elseif($layoutType === 'modern')
<div class="img-circle elevation-2 d-flex bg-dark" style="width:90px;height:90px;">
<i class="fas fa-3x fa-user text-silver m-auto"></i>
</div>
@elseif($layoutType === 'classic')
<div class="img-circle elevation-2 float-left d-flex bg-dark" style="width:65px;height:65px;">
<i class="fas fa-2x fa-user text-silver m-auto"></i>
</div>
@endisset
</div>
{{-- User name --}}
@isset($name)
<h3 class="widget-user-username mb-0">{{ $name }}</h3>
@endisset
{{-- User description --}}
@isset($desc)
<h5 class="widget-user-desc">{{ $desc }}</h5>
@endisset
</div>
{{-- Profile footer / Profile Items --}}
@if(! $slot->isEmpty())
<div class="{{ $makeFooterClass() }}">
<div class="row">{{ $slot }}</div>
</div>
@endif
</div>

View File

@@ -0,0 +1,85 @@
<div {{ $attributes->merge(['class' => $makeProgressClass()]) }}>
{{-- Progress bar --}}
<div class="{{ $makeProgressBarClass() }}" role="progressbar"
aria-valuenow="{{ $value }}" aria-valuemin="0" aria-valuemax="100"
style="{{ $makeProgressBarStyle() }}">
{{-- Progress bar label --}}
@isset($withLabel)
{{ $value }}%
@else
<span class="sr-only">{{ $value }}% Progress</span>
@endisset
</div>
</div>
{{-- Register Javascript utility class for this component --}}
@once
@push('js')
<script>
class _AdminLTE_Progress {
/**
* Constructor.
*
* target: The id of the target progress bar.
*/
constructor(target)
{
this.target = target;
}
/**
* Get the current progress bar value.
*/
getValue()
{
// Check if target exists.
let t = $(`#${this.target}`);
if (t.length <= 0) {
return;
}
// Return the progress bar current value (casted to number).
return +(t.find('.progress-bar').attr('aria-valuenow'));
}
/**
* Set the new progress bar value.
*/
setValue(value)
{
// Check if target exists.
let t = $(`#${this.target}`);
if (t.length <= 0) {
return;
}
// Update progress bar.
value = +value;
t.find('.progress-bar').css('width', value + '%')
.attr('aria-valuenow', value);
if (t.find('span.sr-only').length > 0) {
t.find('span.sr-only').text(value + '% Progress');
} else {
t.find('.progress-bar').text(value + '%');
}
}
}
</script>
@endpush
@endonce

View File

@@ -0,0 +1,113 @@
<div {{ $attributes->merge(['class' => $makeBoxClass()]) }}>
{{-- Box title and description --}}
<div class="inner">
@isset($title)
<h3>{{ $title }}</h3>
@endisset
@isset($text)
<h5>{{ $text }}</h5>
@endisset
</div>
{{-- Box icon --}}
@isset($icon)
<div class="icon">
<i class="{{ $icon }}"></i>
</div>
@endisset
{{-- Box link --}}
@isset($url)
<a href="{{ $url }}" class="small-box-footer">
@if(! empty($urlText))
{{ $urlText }}
@endif
<i class="fas fa-lg fa-arrow-circle-right"></i>
</a>
@endisset
{{-- Box overlay --}}
<div class="{{ $makeOverlayClass() }}">
<i class="fas fa-2x fa-spin fa-sync-alt text-gray"></i>
</div>
</div>
{{-- Register Javascript utility class for this component --}}
@once
@push('js')
<script>
class _AdminLTE_SmallBox {
/**
* Constructor.
*
* target: The id of the target small box.
*/
constructor(target)
{
this.target = target;
}
/**
* Update the small box.
*
* data: An object with the new data.
*/
update(data)
{
// Check if target and data exists.
let t = $(`#${this.target}`);
if (t.length <= 0 || ! data) {
return;
}
// Update available data.
if (data.title) {
t.find('.inner h3').html(data.title);
}
if (data.text) {
t.find('.inner h5').html(data.text);
}
if (data.icon) {
t.find('.icon i').attr('class', data.icon);
}
if (data.url) {
t.find('.small-box-footer').attr('href', data.url);
}
}
/**
* Toggle the loading animation of the small box.
*/
toggleLoading()
{
// Check if target exists.
let t = $(`#${this.target}`);
if (t.length <= 0) {
return;
}
// Toggle the loading overlay.
t.find('.overlay').toggleClass('d-none');
}
}
</script>
@endpush
@endonce