=== Video Slider for YouTube ===
Contributors: mariuskopatschek
Tags: youtube, video slider, video gallery, youtube channel, gdpr
Requires at least: 6.2
Tested up to: 7.1
Requires PHP: 7.4
Stable tag: 2.1.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Fast, privacy-friendly video sliders for YouTube. Show the newest videos of a channel or playlist automatically – no API key, no slowdown.

== Description ==

Video Slider for YouTube shows YouTube videos as a slider, a player with playlist, a grid or a single video – without slowing down your website and without connecting your visitors to Google before they click play.

**Three ways to pick videos**

* **Channel** – the newest videos of any channel appear automatically. Choose videos, Shorts or both.
* **Playlist** – any public playlist, also from other channels.
* **Your own list** – paste links to any videos.

**Four layouts**

* Slider with swipe support, arrows and page dots – optionally moving on by itself
* Large player with a playlist beside it and a soft ambient glow
* Grid with a large lead video
* Single video

**Make it yours**

* Four styles to start from: Modern, Classic, Minimal and Cinema
* Any accent color, light or dark scheme, corner radius, spacing
* Image formats 16:9, 4:3, 1:1 and 9:16 for Shorts
* Title below or on the image, hover effects
* Play button in three colors, four shapes (circle, rounded square, wide or just the triangle) and four triangle styles
* Play in place or open videos in a lightbox, with the next video starting automatically
* Show dates, view counts and a “New” badge for fresh videos
* Hide single videos or filter by words in the title

**Fast by design**

Video lists are loaded in the background about once an hour and cached. Pages never wait for YouTube. The YouTube player is only loaded when a visitor clicks play, so a page with ten videos loads as fast as a page with none.

**Privacy-friendly**

* Thumbnails are copied to your own website. Before clicking play, visitors do not connect to Google at all.
* Videos play from youtube-nocookie.com, YouTube’s privacy-enhanced mode.
* Optional notice before playing, with an “always play” choice that is remembered in the visitor’s browser without a cookie.

**Easy to use**

* A guided editor in four steps with a live preview – for desktop, tablet and phone widths. On smaller screens the preview stays in view while you change settings.
* Shows on which pages each gallery is used.
* Privacy check with a text suggestion for your privacy policy.
* Help and status page: frequently asked questions, last refresh and a one-click refresh.
* “Video Slider” block for the block editor, shortcode for page builders.
* No YouTube API key and no Google account needed.

**Pro version**

Everything above is free, without limits on galleries. An optional Pro version adds a coverflow layout, galleries as tabs, several channels in one gallery, up to 200 videos via your own YouTube API key, a mini player, a call-to-action button, video SEO, click statistics without cookies, and an Elementor widget and Divi module. The free version works fully on its own.

== Installation ==

1. Install and activate the plugin.
2. Open **Video Slider** in the admin menu.
3. Edit the “Default” gallery: enter a channel (for example `@channelname`), a playlist link or a list of video links.
4. Add the **Video Slider** block to a page, or paste the shortcode shown next to the gallery, for example `[vsfy_videos gallery="default"]`.

== Frequently Asked Questions ==

= Do I need a YouTube API key? =

No. The plugin uses the public video feeds that YouTube offers for every channel and playlist.

= Why at most 15 videos per channel or playlist? =

The public feeds contain the 15 newest entries. To show older videos, add them as your own list.

= Does it slow down my website? =

No. All data is loaded in the background (WP-Cron) and cached. Visitors only download the thumbnails from your own server; the YouTube player loads after a click.

= Is it GDPR compliant? =

The plugin is built to avoid data transfers to Google until a visitor actively clicks play, and it can show a notice before playing. Whether this is sufficient for your website depends on your situation – please check with your privacy advisor and mention YouTube in your privacy policy.

= A new video does not show up yet. =

Video lists refresh every hour. Use **Video Slider → Help & status → Refresh now** to update immediately. If WP-Cron is disabled on your site, the plugin refreshes itself in the background after a page view once its data is older than two hours – visitors do not wait for it.

= Can I use it with page builders? =

Yes. Use the shortcode `[vsfy_videos gallery="…"]`. You can override settings per use, for example `[vsfy_videos gallery="default" layout="grid" count="3"]`, or show any channel, playlist or videos without creating a gallery: `[vsfy_videos channel="@channelname"]`, `[vsfy_videos playlist="https://www.youtube.com/playlist?list=…"]`, `[vsfy_videos ids="https://youtu.be/…, https://youtu.be/…"]`.

= Can I change the colors in my theme? =

Yes, under Video Slider → Design: pick a style, any accent color, corners, spacing and more – with a live preview. In CSS you can fine-tune everything through the custom properties `--vsfy-accent`, `--vsfy-ink`, `--vsfy-radius`, `--vsfy-gap` and `--vsfy-ratio`.

= Can I hide single videos of a channel? =

Yes. In the gallery, open “Filter and hide videos” and click the videos you do not want to show. You can also show only videos whose title contains certain words, or leave out videos with certain words.

= Is there a Pro version? =

Yes, optional. See **Video Slider → Pro** in your admin area for what it adds. Your galleries and settings stay as they are when you upgrade. If Pro is removed later, galleries that use Pro features fall back to a free layout or show a short hint to editors – visitors never see an error.

= I used “NR Video Slider” or “Video Slider Rich” before. What happens? =

On activation, the plugin imports their channel or video list into the “Default” gallery. Their shortcodes `[nr_videos]` and `[Rich_Web_Video]` then show that gallery, so existing pages keep working. These two shortcodes are only registered when such an import took place and no other plugin uses them. For new content, use `[vsfy_videos]`.

== External services ==

This plugin connects to YouTube, a service provided by Google LLC, to show videos. No API key or account is used.

**From your server (in the background, about once an hour, and when you save a gallery):**

* `https://www.youtube.com/feeds/videos.xml` – loads the list of videos (ID, title, date, view count) of the channels and playlists you configured. Sent: the channel or playlist ID.
* `https://www.youtube.com/oembed` – loads the title of videos you added as your own list. Sent: the video URL.
* `https://www.youtube.com/@…` – only when you enter a channel by its @handle or URL: loads the channel page once to find the channel ID. Sent: the handle.
* `https://i.ytimg.com` – downloads video thumbnails to your uploads folder (unless “Serve thumbnails from this website” is turned off). Sent: the video ID.

These requests come from your server and contain no data about your visitors. If WP-Cron is disabled, the refresh is started by a background request from your site to its own admin-ajax.php.

**From your visitors’ browsers:**

* `https://www.youtube-nocookie.com` – only after a visitor clicks play: the YouTube player is loaded. YouTube receives the visitor’s IP address and browser data.
* `https://i.ytimg.com` – only if you turn off “Serve thumbnails from this website”: thumbnails are loaded directly from YouTube.

**In the admin area only:** the live preview and the gallery overview may load thumbnails directly from `https://i.ytimg.com` while local copies do not exist yet. Visitors are not affected.

YouTube Terms of Service: https://www.youtube.com/t/terms
Google Privacy Policy: https://policies.google.com/privacy

== Screenshots ==

1. Slider layout: the newest videos of a channel, with view counts, a “New” badge and a subscribe button.
2. Player with playlist: one large player with a soft ambient glow, the other videos beside it.
3. The guided gallery editor in four steps, with live preview.
4. Design: start from a style, pick any color and adjust shapes, play button and effects – the preview updates right away.
5. Privacy: how the data flows, the privacy check and a ready-to-paste text for your privacy policy.
6. All galleries at a glance, with layout, source and where each gallery is used.

== Changelog ==

= 2.1.0 =
* Initial release.
* Guided gallery editor with live preview, design options with four styles, privacy check, help and status page.
* Sources: channel, playlist or your own list of videos; hide single videos or filter by title.
* Layouts: slider, player with playlist, grid, single video; lightbox, ambient glow, next video plays automatically.
* View counts and “New” badge.
* Play button with three colors, four shapes and four triangle styles.
* Local thumbnails and optional notice before playing.
* Block for the block editor.
* Imports settings from “NR Video Slider” and videos from “Video Slider Rich”; their shortcodes keep working.
* Works without WP-Cron: refreshes itself in the background when WP-Cron is disabled.
* If YouTube does not answer when a new gallery is first loaded, it tries again after 5, 15 and 30 minutes instead of waiting an hour.
* German translations (informal and formal).

== Upgrade Notice ==

= 2.1.0 =
First public release.
