added gisoo theme part

master
A1Gard 3 weeks ago
parent 54035e8caa
commit 600273e0f6

@ -129,10 +129,10 @@
@endif
<div class="col-md-5 text-center">
@if($ext == 'mp4')
<video controls src="{{asset('upload/file/'.str_replace('_','.',$setting->key))}}?{{time()}}" class="img-fluid" style="max-height: 150px;max-width: 45%" ></video>
<video controls src="{{asset('upload/media/'.str_replace('_','.',$setting->key))}}?{{time()}}" style="max-height: 150px;max-width: 45%" ></video>
<br>
@elseif($ext == 'mp3')
<audio controls src="{{asset('upload/file/'.str_replace('_','.',$setting->key))}}?{{time()}}" class="img-fluid" style="max-height: 150px;max-width: 45%" ></audio>
<audio controls src="{{asset('upload/media/'.str_replace('_','.',$setting->key))}}?{{time()}}" class="img-fluid" style="max-height: 150px;max-width: 45%" ></audio>
<br>
@elseif(in_array($ext, ['svg','jpg','png','gif','webp'] ) )
<img src="{{asset('upload/images/'.str_replace('_','.',$setting->key))}}?{{time()}}"

@ -0,0 +1,3 @@
<section class='GisooVideo'>
<video src="{{asset('upload/media/'.$data->area_name.'.'.$data->part.'.mp4')}}" autoplay muted ></video>
</section>

@ -0,0 +1,10 @@
{
"name": "GisooVideo",
"version": "1.0",
"author": "xStack",
"email": "xshop@xstack.ir",
"license": "GPL-3.0-or-later",
"url": "https:\/\/xstack.ir",
"author_url": "https:\/\/4xmen.ir",
"packages": []
}

@ -0,0 +1,55 @@
<?php
namespace Resources\Views\Segments;
use App\Models\Part;
use App\Models\Setting;
class GisooVideo
{
public static function onAdd(Part $part = null)
{
$setting = new Setting();
$setting->section = 'theme';
$setting->key = $part->area_name . '_' . $part->part . '_mp4';
$setting->value = null;
$setting->type = 'FILE';
$setting->size = 12;
$setting->title = $part->area_name . ' ' . $part->part . ' video';
$setting->save();
$setting = new Setting();
$setting->section = 'theme';
$setting->key = $part->area_name . '_' . $part->part . '_deg';
$setting->value = 35;
$setting->size = 6;
$setting->type = 'NUMBER';
$setting->data = json_encode(['xmin' => -180, 'xmax' => 180, 'name' => 'gisso-deg-1', 'suffix' => 'deg']);
$setting->title = $part->area_name . ' ' . $part->part . ' angle 1';
$setting->save();
$setting = new Setting();
$setting->section = 'theme';
$setting->key = $part->area_name . '_' . $part->part . '_deg2';
$setting->value = 35;
$setting->size = 6;
$setting->type = 'NUMBER';
$setting->data = json_encode(['xmin' => -180, 'xmax' => 180, 'name' => 'gisso-deg-2', 'suffix' => 'deg']);
$setting->title = $part->area_name . ' ' . $part->part . ' angle 2';
$setting->save();
}
public static function onRemove(Part $part = null)
{
Setting::where('key', $part->area_name . '_' . $part->part . '_mp4')->first()?->delete();
Setting::where('key', $part->area_name . '_' . $part->part . '_deg')->first()?->delete();
Setting::where('key', $part->area_name . '_' . $part->part . '_deg2')->first()?->delete();
}
public static function onMount(Part $part = null)
{
return $part;
}
}

@ -0,0 +1,34 @@
.GisooVideo {
position: relative;
&:before{
position: absolute;
content: ' ';
background: #ffffff33;
backdrop-filter: blur(12px);
width: 45%;
right: -25%;
top: 0;
z-index: 70;
bottom: .5rem;
transform: skewX(var(--gisso-deg-1));
}
&:after{
position: absolute;
content: ' ';
background: #ffffff33;
backdrop-filter: blur(12px);
width: 45%;
left: -25%;
top: 0;
z-index: 70;
bottom: .5rem;
transform: skewX(var(--gisso-deg-2));
}
// scss
video{
position: relative;
width: 100%;
z-index: 60;
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 334 KiB

Loading…
Cancel
Save