From 917872063e57a7528c97b34faa01187cb9fd2e98 Mon Sep 17 00:00:00 2001 From: Aydin Hassan Date: Fri, 16 Feb 2024 20:22:59 +0100 Subject: [PATCH 1/4] Add support steps to offline page --- assets/components/Icons/AppleLogo.vue | 3 + assets/components/Icons/LinuxLogo.vue | 3 + assets/components/Icons/WindowsLogo.vue | 10 ++ .../Website/Pages/Offline/SupportStep.vue | 38 +++++ .../Website/Pages/Offline/TerminalDisplay.vue | 5 +- .../Website/Pages/Offline/TerminalStep.vue | 2 +- .../components/Website/Pages/PageOffline.vue | 142 ++++++++++++++++++ assets/components/Website/WebNote.vue | 31 ++++ assets/img/cloud/apple.svg | 1 + .../img/svg => assets/img/cloud}/linux.svg | 0 .../img/svg => assets/img/cloud}/windows.svg | 0 public/img/svg/apple.svg | 1 - 12 files changed, 231 insertions(+), 5 deletions(-) create mode 100644 assets/components/Icons/AppleLogo.vue create mode 100644 assets/components/Icons/LinuxLogo.vue create mode 100644 assets/components/Icons/WindowsLogo.vue create mode 100644 assets/components/Website/Pages/Offline/SupportStep.vue create mode 100644 assets/components/Website/WebNote.vue create mode 100644 assets/img/cloud/apple.svg rename {public/img/svg => assets/img/cloud}/linux.svg (100%) rename {public/img/svg => assets/img/cloud}/windows.svg (100%) delete mode 100644 public/img/svg/apple.svg diff --git a/assets/components/Icons/AppleLogo.vue b/assets/components/Icons/AppleLogo.vue new file mode 100644 index 00000000..5785ebfc --- /dev/null +++ b/assets/components/Icons/AppleLogo.vue @@ -0,0 +1,3 @@ + \ No newline at end of file diff --git a/assets/components/Icons/LinuxLogo.vue b/assets/components/Icons/LinuxLogo.vue new file mode 100644 index 00000000..2bc2f685 --- /dev/null +++ b/assets/components/Icons/LinuxLogo.vue @@ -0,0 +1,3 @@ + \ No newline at end of file diff --git a/assets/components/Icons/WindowsLogo.vue b/assets/components/Icons/WindowsLogo.vue new file mode 100644 index 00000000..0301c66d --- /dev/null +++ b/assets/components/Icons/WindowsLogo.vue @@ -0,0 +1,10 @@ + \ No newline at end of file diff --git a/assets/components/Website/Pages/Offline/SupportStep.vue b/assets/components/Website/Pages/Offline/SupportStep.vue new file mode 100644 index 00000000..eafc7a84 --- /dev/null +++ b/assets/components/Website/Pages/Offline/SupportStep.vue @@ -0,0 +1,38 @@ + + diff --git a/assets/components/Website/Pages/Offline/TerminalDisplay.vue b/assets/components/Website/Pages/Offline/TerminalDisplay.vue index ca81ff42..0cfd2221 100644 --- a/assets/components/Website/Pages/Offline/TerminalDisplay.vue +++ b/assets/components/Website/Pages/Offline/TerminalDisplay.vue @@ -57,11 +57,10 @@ const clipboardAvailable = computed(() => { Copied! -
+
-
- {{ line }} +
{{ line }}
{{ line }} diff --git a/assets/components/Website/Pages/Offline/TerminalStep.vue b/assets/components/Website/Pages/Offline/TerminalStep.vue index ae3040c8..32e142a7 100644 --- a/assets/components/Website/Pages/Offline/TerminalStep.vue +++ b/assets/components/Website/Pages/Offline/TerminalStep.vue @@ -19,7 +19,7 @@ defineProps({ diff --git a/assets/components/Icons/LinuxLogo.vue b/assets/components/Icons/LinuxLogo.vue index 2bc2f685..72a80ee4 100644 --- a/assets/components/Icons/LinuxLogo.vue +++ b/assets/components/Icons/LinuxLogo.vue @@ -1,3 +1,441 @@ \ No newline at end of file + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/assets/components/Icons/SlackIcon.vue b/assets/components/Icons/SlackIcon.vue index 359cc451..ead6d7c2 100644 --- a/assets/components/Icons/SlackIcon.vue +++ b/assets/components/Icons/SlackIcon.vue @@ -1,12 +1,14 @@ \ No newline at end of file + + + + + + + + + + + diff --git a/assets/components/Icons/TwitterIcon.vue b/assets/components/Icons/TwitterIcon.vue index 005fc9ab..f72f0399 100644 --- a/assets/components/Icons/TwitterIcon.vue +++ b/assets/components/Icons/TwitterIcon.vue @@ -1,6 +1,8 @@ \ No newline at end of file + + + + + diff --git a/assets/components/Icons/WindowsLogo.vue b/assets/components/Icons/WindowsLogo.vue index 0301c66d..a6973448 100644 --- a/assets/components/Icons/WindowsLogo.vue +++ b/assets/components/Icons/WindowsLogo.vue @@ -1,10 +1,22 @@ \ No newline at end of file + + + + + + + + + diff --git a/assets/components/Online/LoginWithGitHubButton.vue b/assets/components/Online/LoginWithGitHubButton.vue index dcb0fb5e..ea0a365a 100644 --- a/assets/components/Online/LoginWithGitHubButton.vue +++ b/assets/components/Online/LoginWithGitHubButton.vue @@ -6,12 +6,12 @@ import { useStudentStore } from "../../stores/student"; const studentStore = useStudentStore(); const login = async () => { - await studentStore.startLogin(); + await studentStore.startLogin(); }; diff --git a/assets/components/Website/Pages/Offline/SupportStep.vue b/assets/components/Website/Pages/Offline/SupportStep.vue index eafc7a84..590845cf 100644 --- a/assets/components/Website/Pages/Offline/SupportStep.vue +++ b/assets/components/Website/Pages/Offline/SupportStep.vue @@ -2,37 +2,37 @@ import TerminalDisplay from "./TerminalDisplay.vue"; defineProps({ - step: { - type: Number, - }, - title: { - type: String, - }, - lines: { - type: Array, - required: false, - default: [] - }, + step: { + type: Number, + }, + title: { + type: String, + }, + lines: { + type: Array, + required: false, + default: () => [], + }, }); diff --git a/assets/components/Website/Pages/Offline/TerminalDisplay.vue b/assets/components/Website/Pages/Offline/TerminalDisplay.vue index 0cfd2221..1afe7604 100644 --- a/assets/components/Website/Pages/Offline/TerminalDisplay.vue +++ b/assets/components/Website/Pages/Offline/TerminalDisplay.vue @@ -57,10 +57,11 @@ const clipboardAvailable = computed(() => { Copied!
-
+
-
{{ line }} +
+ {{ line }}
{{ line }} diff --git a/assets/components/Website/Pages/PageHome.vue b/assets/components/Website/Pages/PageHome.vue index 110fc1cd..17955440 100644 --- a/assets/components/Website/Pages/PageHome.vue +++ b/assets/components/Website/Pages/PageHome.vue @@ -17,7 +17,7 @@ import TheWorkshops from "./Home/Section/TheWorkshops.vue"; import BuildYourOwn from "./Home/Section/BuildYourOwn.vue"; import { SparklesIcon } from "@heroicons/vue/24/solid"; -import {useStudentStore} from "../../../stores/student"; +import { useStudentStore } from "../../../stores/student"; const studentStore = useStudentStore(); @@ -171,7 +171,6 @@ onUnmounted(() => {
Log In with github -
@@ -255,7 +254,7 @@ onUnmounted(() => { type="text" placeholder="Type Something..." v-model="userInput" - class="w-full rounded-2xl p-5 font-work-sans text-base border-0 font-bold text-gray-900 focus:border-pink-500 focus:outline-none focus:ring focus:ring-pink-500" + class="w-full rounded-2xl border-0 p-5 font-work-sans text-base font-bold text-gray-900 focus:border-pink-500 focus:outline-none focus:ring focus:ring-pink-500" @keyup="userInputKeyup" /> diff --git a/assets/components/Website/Pages/PageOffline.vue b/assets/components/Website/Pages/PageOffline.vue index 82f67d46..e3db47d2 100644 --- a/assets/components/Website/Pages/PageOffline.vue +++ b/assets/components/Website/Pages/PageOffline.vue @@ -4,11 +4,10 @@ import PageSection from "./PageSection.vue"; import { CheckIcon } from "@heroicons/vue/24/solid"; import TerminalStep from "./Offline/TerminalStep.vue"; import { CogIcon } from "@heroicons/vue/24/outline"; -import TerminalDisplay from "./Offline/TerminalDisplay.vue"; import WindowsLogo from "../../Icons/WindowsLogo.vue"; import AppleLogo from "../../Icons/AppleLogo.vue"; import LinuxLogo from "../../Icons/LinuxLogo.vue"; -import {Tab, TabGroup, TabList, TabPanel, TabPanels, TransitionRoot} from "@headlessui/vue"; +import { Tab, TabGroup, TabList, TabPanel, TabPanels } from "@headlessui/vue"; import SupportStep from "./Offline/SupportStep.vue"; import WebNote from "../WebNote.vue"; @@ -49,32 +48,6 @@ const steps = [ lines: ["workshop-manager uninstall ", "//eg uninstall php8appreciate", "workshop-manager uninstall php8appreciate"], }, ]; - -const macSteps = [ - { - title: "Check your PHP version", - description: "If you have a PHP version less than 7.1, you will need to update it to at least 7.1, you can do so with the following commands:", - lines: [ - "/bin/bash -c \"$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)\"", - "brew install php" - ], - }, - { - title: "Check PHP School's bin directory is available in $PATH", - description: "After installing a workshop using the workshop manager you may find it's not available to run immediately. If this happens the simplest remedy is to make sure PHP School's workshop bin directory is available in the $PATH environment variable.\n" + - "\n" + - "You can check this with workshop-manager verify which will also provide the relevant details on how to resolve the issue.\n" + - "\n" + - "To learn more about the $PATH environment, click here.", - lines: [], - }, -]; - -const linux = [ - "sudo apt-get install software-properties-common", - "sudo add-apt-repository ppa:ondrej/php", - "sudo apt-get install php7.1" -]