diff --git a/database/seeders/AreaSeeder.php b/database/seeders/AreaSeeder.php index 886bf2e..6d9cbaa 100644 --- a/database/seeders/AreaSeeder.php +++ b/database/seeders/AreaSeeder.php @@ -38,7 +38,7 @@ class AreaSeeder extends Seeder 'valid_segments' => json_encode( ["top", "slider", "header", "footer", "menu", "parallax", "other", "posts", "products", "attachments" - , "groups", "categories", "category", "group", "index", "ads"] + , "groups", "categories", "category", "group", "index", "ads", "galleries"] ), 'max' => 10, 'preview' => 'client.welcome', @@ -168,7 +168,7 @@ class AreaSeeder extends Seeder 'name' => 'group', 'valid_segments' => json_encode( ["top", "header", "footer", "menu", - "parallax", "other", "group", "ads",'posts_page'] + "parallax", "other", "group", "ads", 'posts_page'] ), 'max' => 6, 'preview' => 'client.group', diff --git a/resources/js/client.js b/resources/js/client.js index 48133b4..0eacb4b 100644 --- a/resources/js/client.js +++ b/resources/js/client.js @@ -9,4 +9,8 @@ import "./client-custom/confirm.js"; import "./client-custom/safeForm.js"; import "./client-custom/windowLoader.js"; import "../views/segments/preloader/PreloaderCircle/PreloaderCircle.js"; -import "../views/segments/posts_page/SimplePostListSideBar/SimplePostListSideBar.js"; +import "../views/segments/header/ParallaxHeaderPin/ParallaxHeaderPin.js"; +import "../views/segments/group/SubGroupsGrid/SubGroupsGrid.js"; +import "../views/segments/posts_page/SimplePostList/SimplePostList.js"; +import "../views/segments/gallery/GallaryGrid/GallaryGrid.js"; +import "../views/segments/galleries/GridGallery/GridGallery.js"; diff --git a/resources/sass/client.scss b/resources/sass/client.scss index 0c443bf..0af7213 100644 --- a/resources/sass/client.scss +++ b/resources/sass/client.scss @@ -21,4 +21,8 @@ $xshop-shadow:2px 2px 4px #777777; @import "client-custom/general"; @import "client-custom/zfix"; @import "../views/segments/preloader/PreloaderCircle/PreloaderCircle"; -@import "../views/segments/posts_page/SimplePostListSideBar/SimplePostListSideBar"; +@import "../views/segments/header/ParallaxHeaderPin/ParallaxHeaderPin"; +@import "../views/segments/group/SubGroupsGrid/SubGroupsGrid"; +@import "../views/segments/posts_page/SimplePostList/SimplePostList"; +@import "../views/segments/gallery/GallaryGrid/GallaryGrid"; +@import "../views/segments/galleries/GridGallery/GridGallery"; diff --git a/resources/views/client/post.blade.php b/resources/views/client/post.blade.php index b531131..81b78e0 100644 --- a/resources/views/client/post.blade.php +++ b/resources/views/client/post.blade.php @@ -1,3 +1,4 @@ + @extends('website.inc.website-layout') @section('title') diff --git a/resources/views/client/welcome.blade.php b/resources/views/client/welcome.blade.php index 8dc6aa1..d35ed59 100644 --- a/resources/views/client/welcome.blade.php +++ b/resources/views/client/welcome.blade.php @@ -1,7 +1,7 @@ @extends('website.inc.website-layout') @section('title') - welcome + {{config('app.name')}} - {{getSetting('subtitle')}} @endsection @section('content')
diff --git a/resources/views/segments/galleries/GridGallery/GridGallery.blade.php b/resources/views/segments/galleries/GridGallery/GridGallery.blade.php new file mode 100644 index 0000000..47efdb4 --- /dev/null +++ b/resources/views/segments/galleries/GridGallery/GridGallery.blade.php @@ -0,0 +1,22 @@ +
+
+

+ {{ getSetting($data->area->name.'_'.$data->part.'_title')}} +

+
+ @foreach(\App\Models\Gallery::where('status',1)->orderBy('id')->limit( getSetting($data->area->name.'_'.$data->part.'_limit'))->get() as $gallery) + + @endforeach +
+
+
diff --git a/resources/views/segments/galleries/GridGallery/GridGallery.js b/resources/views/segments/galleries/GridGallery/GridGallery.js new file mode 100644 index 0000000..e69de29 diff --git a/resources/views/segments/galleries/GridGallery/GridGallery.json b/resources/views/segments/galleries/GridGallery/GridGallery.json new file mode 100644 index 0000000..db8c43f --- /dev/null +++ b/resources/views/segments/galleries/GridGallery/GridGallery.json @@ -0,0 +1,10 @@ +{ + "name": "GridGallery", + "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": [] +} \ No newline at end of file diff --git a/resources/views/segments/galleries/GridGallery/GridGallery.php b/resources/views/segments/galleries/GridGallery/GridGallery.php new file mode 100644 index 0000000..f693ef9 --- /dev/null +++ b/resources/views/segments/galleries/GridGallery/GridGallery.php @@ -0,0 +1,39 @@ +section = 'theme'; + $setting->key = $part->area->name . '_' . $part->part.'_title'; + $setting->value = __('Galleries'); + $setting->type = 'TEXT'; + $setting->size = 6; + $setting->title = $part->area->name . ' ' . $part->part.' title'; + $setting->save(); + $setting = new Setting(); + $setting->section = 'theme'; + $setting->key = $part->area->name . '_' . $part->part.'_limit'; + $setting->value = 3; + $setting->size = 6; + $setting->type = 'NUMBER'; + $setting->data = json_encode(['xmin' => 2, 'xmax' => 6]); + $setting->title = $part->area->name . ' ' . $part->part. ' limit'; + $setting->save(); + } + public static function onRemove(Part $part = null) + { + Setting::where('key',$part->area->name . '_' . $part->part.'_title')->first()?->delete(); + Setting::where('key',$part->area->name . '_' . $part->part.'_limit')->first()?->delete(); + } + public static function onMount(Part $part = null) + { + return $part; + } +} diff --git a/resources/views/segments/galleries/GridGallery/GridGallery.scss b/resources/views/segments/galleries/GridGallery/GridGallery.scss new file mode 100644 index 0000000..1b2eb52 --- /dev/null +++ b/resources/views/segments/galleries/GridGallery/GridGallery.scss @@ -0,0 +1,46 @@ +.GridGallery { + margin-top: 3rem; + // scss + .gallery-grid{ + display: block; + position: relative; + overflow: hidden; + height: 25vh; + width: 100%; + border-radius: var(--xshop-border-radius); + img{ + position: absolute; + left: 0; + right: 0; + top: 0; + bottom: 0; + width: 100%; + height: 100%; + object-fit: cover; + border-radius: var(--xshop-border-radius); + } + h4{ + transition: 400ms; + position: absolute; + left: 10%; + right: 10%; + top: 10%; + bottom: 10%; + background: #ffffff77; + z-index: 3; + display: flex; + align-items: center; + justify-content: center; + backdrop-filter: blur(5px); + opacity: 0; + color: var(--xshop-text); + border-radius: var(--xshop-border-radius); + } + + &:hover{ + h4{ + opacity: 1; + } + } + } +} diff --git a/resources/views/segments/galleries/GridGallery/screenshot.png b/resources/views/segments/galleries/GridGallery/screenshot.png new file mode 100644 index 0000000..0222e62 Binary files /dev/null and b/resources/views/segments/galleries/GridGallery/screenshot.png differ diff --git a/resources/views/segments/gallery/GallaryGrid/GallaryGrid.scss b/resources/views/segments/gallery/GallaryGrid/GallaryGrid.scss index b2d6ac1..7311aa9 100644 --- a/resources/views/segments/gallery/GallaryGrid/GallaryGrid.scss +++ b/resources/views/segments/gallery/GallaryGrid/GallaryGrid.scss @@ -1,4 +1,7 @@ .GallaryGrid { // scss + img{ + border-radius: var(--xshop-border-radius); + } }