From b3ebe1d2a806545493370cb70c4ed2bde098ae9a Mon Sep 17 00:00:00 2001 From: nate contino <nate.contino@raspberrypi.com> Date: Wed, 11 Dec 2024 13:24:38 +0000 Subject: [PATCH 1/4] Fix typos --- documentation/asciidoc/computers/raspberry-pi/boot-nvme.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/documentation/asciidoc/computers/raspberry-pi/boot-nvme.adoc b/documentation/asciidoc/computers/raspberry-pi/boot-nvme.adoc index 5660e7565..8212be3dc 100644 --- a/documentation/asciidoc/computers/raspberry-pi/boot-nvme.adoc +++ b/documentation/asciidoc/computers/raspberry-pi/boot-nvme.adoc @@ -1,6 +1,6 @@ == NVMe SSD boot -NVMe (Non-Volatile Memory express) is a standard for external storage access over a PCIe bus. You can connect NVMe drives via the PCIe slot on a IO Boards since Compute Module 4 and or Raspberry Pi 5 using an M.2 HAT+. With some additional configuration, you can boot from an NVMe drive. +NVMe (Non-Volatile Memory express) is a standard for external storage access over a PCIe bus. You can connect NVMe drives via the PCIe slot on Compute Module 4 IO Board, the M.2 slots on Compute Module 5 IO Board, and Raspberry Pi 5 using an M.2 HAT+. With some additional configuration, you can boot from an NVMe drive. === Prerequisites From cde77c749fff4782fe063dac5171b076fccabfd1 Mon Sep 17 00:00:00 2001 From: Andrew Scheller <andrew.scheller@raspberrypi.com> Date: Thu, 12 Dec 2024 00:50:00 +0000 Subject: [PATCH 2/4] Use same power-supply notation for Pi 4 and Pi 400 as Pi 5 and Pi 500 --- .../asciidoc/computers/raspberry-pi/introduction.adoc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/documentation/asciidoc/computers/raspberry-pi/introduction.adoc b/documentation/asciidoc/computers/raspberry-pi/introduction.adoc index 3642c520c..5e5d157d1 100644 --- a/documentation/asciidoc/computers/raspberry-pi/introduction.adoc +++ b/documentation/asciidoc/computers/raspberry-pi/introduction.adoc @@ -158,7 +158,7 @@ a| * 2.4/5GHz dual-band 802.11ac Wi-Fi (120Mb/s) * Bluetooth 5, Bluetooth Low Energy (BLE) * microSD card slot -* USB-C power (5V, 3A (15W)) +* USB-C power (5V 3A (15W)) ^.^a| .Raspberry Pi 5 image::images/5.jpg[alt="Raspberry Pi 5"] @@ -206,7 +206,7 @@ a| * 2.4/5GHz dual-band 802.11ac Wi-Fi (120Mb/s) * Bluetooth 5, Bluetooth Low Energy (BLE) * microSD card slot -* USB-C power (5V, 3A (15W)) +* USB-C power (5V 3A (15W)) ^.^a| .Raspberry Pi 500 image::images/500.png[alt="Raspberry Pi 500"] From 933935ddc88151a1408b2d15bc6466fc54f19992 Mon Sep 17 00:00:00 2001 From: Nate Contino <nate.contino@raspberrypi.com> Date: Thu, 12 Dec 2024 10:37:52 +0000 Subject: [PATCH 3/4] Allow theme toggle based on user browser preference even when cookies are not allowed --- jekyll-assets/scripts/theme.js | 25 +++++++++++-------------- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/jekyll-assets/scripts/theme.js b/jekyll-assets/scripts/theme.js index 87bb2df9a..49c9d754b 100644 --- a/jekyll-assets/scripts/theme.js +++ b/jekyll-assets/scripts/theme.js @@ -6,11 +6,11 @@ function toggleTheme() { var theme = localStorage.getItem('theme'); // if the theme has never been set, or is light, set the theme to the dark symbol in local storage to change it if (localStorage.getItem('theme') !== null && theme == '🌝' ) { - if (document.cookie.indexOf("cookiebanner_accepted") != -1) { + if (cookiePermission != -1) { localStorage.setItem('theme', '🌚'); } } else { - if (document.cookie.indexOf("cookiebanner_accepted") != -1) { + if (cookiePermission != -1) { // otherwise, the theme is currently set to dark, so set the theme to the light symbol in local storage to change it localStorage.setItem('theme', '🌝'); } @@ -25,17 +25,14 @@ function toggleTheme() { // from the site's perspective, we default to a dark theme, but toggle it to a light theme on load if the user doesn't ask for dark. // why do this? To prevent an annoying light 'flash' for dark theme users. light theme users don't really notice or care if there's a dark anti-flash. function initTheme() { - var cookiePermission = document.cookie.indexOf("cookiebanner_accepted"); - if (document.cookie.indexOf("cookiebanner_accepted") != -1) { - // fetch the theme from local storage (if it exists) - var theme = localStorage.getItem('theme'); - // if the theme has been set to light (null check to short circuit if not set) - if(theme !== null && theme === '🌝' - // if we can use matchMedia and the browser supports the dark color scheme - || (window.matchMedia && !window.matchMedia('(prefers-color-scheme: dark)').matches) - && theme !== '🌚') { - // toggles the theme from the default dark mode to the light version (which actually _shows_ by default to many users) - document.body.classList.toggle('light'); - } + // fetch the theme from local storage (if it exists) + var theme = localStorage.getItem('theme'); + // if the theme has been set to light (null check to short circuit if not set) + if(theme !== null && theme === '🌝' + // if we can use matchMedia and the browser supports the dark color scheme + || (window.matchMedia && !window.matchMedia('(prefers-color-scheme: dark)').matches) + && theme !== '🌚') { + // toggles the theme from the default dark mode to the light version (which actually _shows_ by default to many users) + document.body.classList.toggle('light'); } } \ No newline at end of file From 75f17e93b21fc76c1fc11691d99fb57063afc340 Mon Sep 17 00:00:00 2001 From: nate contino <nate.contino@raspberrypi.com> Date: Thu, 12 Dec 2024 10:38:58 +0000 Subject: [PATCH 4/4] Update boot-nvme.adoc --- documentation/asciidoc/computers/raspberry-pi/boot-nvme.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/documentation/asciidoc/computers/raspberry-pi/boot-nvme.adoc b/documentation/asciidoc/computers/raspberry-pi/boot-nvme.adoc index 8212be3dc..ac29d4d35 100644 --- a/documentation/asciidoc/computers/raspberry-pi/boot-nvme.adoc +++ b/documentation/asciidoc/computers/raspberry-pi/boot-nvme.adoc @@ -1,6 +1,6 @@ == NVMe SSD boot -NVMe (Non-Volatile Memory express) is a standard for external storage access over a PCIe bus. You can connect NVMe drives via the PCIe slot on Compute Module 4 IO Board, the M.2 slots on Compute Module 5 IO Board, and Raspberry Pi 5 using an M.2 HAT+. With some additional configuration, you can boot from an NVMe drive. +NVMe (Non-Volatile Memory express) is a standard for external storage access over a PCIe bus. You can connect NVMe drives via the PCIe slot on Compute Module 4 IO Board, the M.2 slot on Compute Module 5 IO Board, and Raspberry Pi 5 using an M.2 HAT+. With some additional configuration, you can boot from an NVMe drive. === Prerequisites