feat: Add npm dependencies and update vendor paths

- Add package.json dependencies: jquery, jquery-ui, moment, daterangepicker, wavesurfer.js, air-datepicker
- Create scripts/setup-vendor.js to copy npm packages to public/assets/vendor
- Update view templates to use vendor paths instead of old /js/ or CDN URLs
- Clean up legacy commented-out scripts in master layout
This commit is contained in:
Mischa Spelt
2026-08-25 16:17:01 +02:00
parent e070c9f374
commit 7b9674110e
8454 changed files with 11623 additions and 27 deletions
Executable → Regular
View File
View File
Executable → Regular
View File
Executable → Regular
View File
View File
View File
View File
File diff suppressed because it is too large Load Diff
Executable → Regular
View File
View File
Executable → Regular
View File
View File
View File
View File
View File
View File
View File
View File
View File
+3 -18
View File
@@ -170,28 +170,13 @@
</div>
</div>
<div class="background_overlay"></div>
<!--js-->
<!--<script type="text/javascript" src="/js/jquery-1.12.4.min.js"></script>
<script type="text/javascript" src="/js/jquery-migrate-1.4.1.min.js"></script>
<script type="text/javascript" src="/js/jquery.ba-bbq.min.js"></script>
<script type="text/javascript" src="/js/jquery-ui-1.11.1.custom.min.js"></script>
<script type="text/javascript" src="/js/jquery.easing.1.3.js"></script>
<script type="text/javascript" src="/js/jquery.carouFredSel-6.2.1-packed.js"></script>
<script type="text/javascript" src="/js/jquery.touchSwipe.min.js"></script>
<script type="text/javascript" src="/js/jquery.mousewheel.min.js"></script>
<script type="text/javascript" src="/js/jquery.transit.min.js"></script>
<script type="text/javascript" src="/js/jquery.sliderControl.js"></script>
<script type="text/javascript" src="/js/jquery.timeago.js"></script>
<script type="text/javascript" src="/js/jquery.hint.js"></script>
<script type="text/javascript" src="/js/jquery.qtip.min.js"></script>
<script type="text/javascript" src="/js/jquery.blockUI.js"></script>
<script type="text/javascript" src="/js/odometer.min.js"></script>-->
<!-- Scripts -->
<script type="text/javascript" src="/js/main.js"></script>
<script type="text/javascript" src="/js/jquery-3.7.1.min.js"></script>
<script type="text/javascript" src="/assets/vendor/jquery/dist/jquery.min.js"></script>
<script type="text/javascript" src="/js/jquery.prettyPhoto.js"></script>
<script type="text/javascript" src="/js/jquery.carouFredSel-6.2.1.min.js"></script>
<script type="text/javascript" src="/js/functions.js"></script>
<script type="text/javascript" src="/js/wavesurfer.min.js"></script>
<script type="text/javascript" src="/assets/vendor/wavesurfer/wavesurfer.min.js"></script>
<script type="text/javascript">
$(window).resize(function () {
// Fix sticky for mobile menu indicator
View File
Executable → Regular
+2 -2
View File
@@ -136,8 +136,8 @@
@endpush
@push('scripts')
<script type="text/javascript" src="/js/jquery-3.7.1.min.js"></script>
<script type="text/javascript" src="/js/wavesurfer.min.js"></script>
<script type="text/javascript" src="/assets/vendor/jquery/dist/jquery.min.js"></script>
<script type="text/javascript" src="/assets/vendor/wavesurfer/wavesurfer.min.js"></script>
<script>
function updateOnAir() {
$.ajax({
View File
View File
View File
View File
View File
Executable → Regular
+3 -3
View File
@@ -9,9 +9,9 @@
@endsection
@push('scripts')
<script type="text/javascript" src="https://cdn.jsdelivr.net/momentjs/latest/moment.min.js"></script>
<script type="text/javascript" src="https://cdn.jsdelivr.net/npm/daterangepicker/daterangepicker.min.js"></script>
<link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/daterangepicker/daterangepicker.css" />
<script type="text/javascript" src="/assets/vendor/moment/moment.min.js"></script>
<script type="text/javascript" src="/assets/vendor/daterangepicker/daterangepicker.min.js"></script>
<link rel="stylesheet" type="text/css" href="/assets/vendor/daterangepicker/daterangepicker.css" />
<style>
.input-group-text svg {
width: 24px;
View File
View File
Executable → Regular
View File
View File
View File
View File
View File
View File
View File
View File
@@ -0,0 +1,91 @@
@foreach($content as $block)
@if($block->type == "headerRichA")
@php($block->image->url = isset($block->image->crops)
? $block->image->crops->{'16:9'}->{'1600'}
: $block->image->crop)
<a href="{{$block->image->url}}" class="post_image page_margin_top prettyPhoto" rel="prettyPhoto" title="{{$block->image->title}}">
<img src="{{$block->image->url}}" alt="{{$block->image->title}}">
</a>
<div class="sentence margin_top_10">
<span class="text">{{$block->image->title}}</span>
@if($block->image->author)
<span class="author">{{$block->image->author}}</span>
@endif
</div>
@elseif($block->type == "text")
<div class="text">{!!$block->text!!}</div>
@elseif($block->type == "intro")
<h3 class="excerpt">{{strip_tags($block->text)}}</h3>
@elseif($block->type == "quote")
<blockquote>
{!!$block->text!!}
<div class="author">{{$block->name}}</div>
</blockquote>
@elseif($block->type == "image")
<?php
if(isset($block->image->imageWide))
$image = $block->image->imageWide;
else if(isset($block->image->crop))
$image = $block->image->crop;
else if(isset($block->image->crops) && isset($block->image->crops->{'16:9'}))
foreach($block->image->crops->{'16:9'} as $image) break;
else if(isset($block->image->imageHigh))
$image = $block->image->imageHigh;
else $image = null;
?>
@if($image)
<a class="post_image page_margin_top prettyPhoto" rel="prettyPhoto" href="{{$image}}" title="{{$block->image->title}} &copy; {{$block->image->author}}">
<img src="{{$image}}" class="attachment-small-slider-thumb size-small-slider-thumb wp-post-image" alt="{{$block->image->title}}" title="" style="display: block;">
</a>
<div class="sentence">
@if($block->image->title)
<span class="text">{{$block->image->title}}</span>
@endif
@if($block->image->author)
<span class="author">{{$block->image->author}}</span>
@endif
</div>
@endif
@elseif($block->type == "video" || $block->type == "headerVideo")
@include('widgets/mediaplayer')
<video controls>
@foreach($block->video->streams as $stream)
<source src="{!!$stream->stream_url!!}" type="application/x-mpegurl" />
@endforeach
</video>
<span class="author">{{$block->video->author}}</span>
@elseif($block->type == "carousel")
<div class="horizontal_carousel_container gallery">
<ul class="horizontal_carousel visible-5 autoplay-1 scroll-1 navigation-1 easing-easeInOutQuint duration-750">
@foreach($block->items as $image)
<?php
if(isset($image->image->imageWide))
$img = $image->image->imageWide;
else if(isset($block->image->crop))
$image = $block->image->crop;
else if(isset($image->image->crops) && isset($image->image->crops->{'16:9'}))
foreach($image->image->crops->{'16:9'} as $img) break;
else if(isset($image->image->imageHigh))
$img = $image->image->imageHigh;
else $img = null;
?>
@if($img)
<li>
<a href="{{$img}}" class="post_image prettyPhoto" rel="prettyPhoto[gallery]" title="{{$image->image->title}} &copy; {{$image->image->author}}">
<img src="{{$img}}" alt="{{$image->image->title}}" title="{{$image->image->title}}">
</a>
</li>
@endif
@endforeach
</ul>
</div>
<<<<<<< /srv/www/nhgooi-dev/resources/views/partial/nh_story.blade.php
@elseif($block->type == "oembed")
<div class="oembed" data-url="{{$block->url}}">{{!$block->html!!}</div>
=======
@elseif($block->type == "oembed")
<div class="oembed" data-url="{{$block->url}}">{!!$block->html!!}</div>
>>>>>>> /tmp/nh_story.blade.php~other.QK7_yi
@endif
@endforeach
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
+3 -3
View File
@@ -73,12 +73,12 @@ $margin = 2;
border: solid {{$border}}px #03A6E0;
}
</style>
<link href="https://cdn.jsdelivr.net/npm/air-datepicker@3.5.0/air-datepicker.min.css" rel="stylesheet">
<link href="/assets/vendor/air-datepicker/air-datepicker.min.css" rel="stylesheet">
@endpush
@push('scripts')
<script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.30.1/moment.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/air-datepicker@3.5.0/air-datepicker.min.js"></script>
<script src="/assets/vendor/moment/moment.min.js"></script>
<script src="/assets/vendor/air-datepicker/air-datepicker.min.js"></script>
<script type="text/javascript">
var isMobile = window.screen.width <= 768;
var airdatepicker = new AirDatepicker('#custom_date', {
View File
Executable → Regular
View File
Executable → Regular
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File