home.blade.php 2.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. {{-- resources/views/pages/home.blade.php
  2. WikiPāli 首页:顶部导航(logo + 旧版入口 + 语言切换)+ 品牌 hero + 2×2 分流卡片。
  3. 卡片数据全部来自 PageIndexController 传入的 $cards,模板不硬编码栏目文案。
  4. --}}
  5. @extends('layouts.base')
  6. @section('title', __('home.title'))
  7. @push('styles')
  8. @vite(['resources/css/home.css'])
  9. @endpush
  10. @section('body-class', 'home-page')
  11. @section('page')
  12. <main class="home">
  13. {{-- 顶部导航:左 logo,右 旧版入口 + 语言切换 --}}
  14. <nav class="home-nav">
  15. <div class="home-nav__inner">
  16. <a class="home-nav__brand" href="/" aria-label="WikiPāli">
  17. <img src="{{ asset('assets/images/wikipali_logo_dark.svg') }}" alt="WikiPāli" class="home-nav__logo" />
  18. </a>
  19. <div class="home-nav__actions">
  20. <a class="home-nav__legacy"
  21. href="{{ config('mint.server.dashboard_base_path') }}/"
  22. target="_blank"
  23. rel="noopener">
  24. {{ __('home.legacy') }}
  25. </a>
  26. <div class="home-nav__lang">
  27. <x-language-switcher />
  28. </div>
  29. </div>
  30. </div>
  31. </nav>
  32. {{-- 品牌 Hero:站名 + 一行说明,居中 --}}
  33. <header class="home-hero">
  34. <h1 class="home-hero__title">{{ __('home.hero_title') }}</h1>
  35. <p class="home-hero__lead">{{ __('home.hero_lead') }}</p>
  36. </header>
  37. {{-- 四张分流卡片,2×2 网格 --}}
  38. <div class="home-grid">
  39. @foreach ($cards as $card)
  40. <x-home.card
  41. :slug="$card['slug']"
  42. :eyebrow="$card['eyebrow']"
  43. :title="$card['title']"
  44. :lead="$card['lead']"
  45. :icon="$card['icon']"
  46. :tint="$card['tint']"
  47. :href="$card['href']"
  48. :cta="$card['cta']"
  49. :available="$card['available']" />
  50. @endforeach
  51. </div>
  52. {{-- Footer:版权 + 备案号(ICP / 公安备案),参考 typhoon 模板 --}}
  53. <footer class="home-footer">
  54. <div class="home-footer__inner">
  55. <span class="home-footer__item">© {{ now()->year }} WikiPāli</span>
  56. @if (!empty(config('mint.app.icp_code')))
  57. <span class="home-footer__item">
  58. <span>ICP备案号:</span>
  59. <a href="https://beian.miit.gov.cn/" target="_blank" rel="noreferrer">{{ config('mint.app.icp_code') }}</a>
  60. </span>
  61. <span class="home-footer__item">
  62. <img src="{{ asset('assets/images/logo_mps.png') }}" alt="公安备案" class="home-footer__icon" />
  63. @if (empty(config('mint.app.mps_code')))
  64. <span>滇公网安备[审批中]号</span>
  65. @else
  66. <span>{{ config('mint.app.mps_code') }}</span>
  67. @endif
  68. </span>
  69. @endif
  70. </div>
  71. </footer>
  72. </main>
  73. @endsection