compact code blocks, more polite unsupported platform warnings

This commit is contained in:
Nikita Krupin committed 2022-01-12 12:57:30 -05:00
1 parent 93d9b941e6
commit 7a01751faa
2 files changed
+10 -13

No files matched your search

+6 -4
View File
@@ -75,7 +75,7 @@ export default {
let chrome = window.navigator.userAgent.match(/Chrome\/(\d+)/); let chrome = window.navigator.userAgent.match(/Chrome\/(\d+)/);
let chromeVersion = chrome ? chrome[1] : 0; let chromeVersion = chrome ? chrome[1] : 0;
if (chromeVersion < 70) { if (chromeVersion < 70) {
this.alert.html = `You are using <b style="background: #222; border-radius: .5rem; padding: .25rem .5rem;">${this.$ua._parsed.name} ${this.$ua._parsed.version}</b>. Please update to the latest version.`; this.alert.html = `<b style="background: #222; border-radius: .5rem; padding: .25rem .5rem;">${this.$ua._parsed.name} ${this.$ua._parsed.version}</b> is not supported. Consider updating to the latest version.`;
this.alert.show = true; this.alert.show = true;
} }
} }
@@ -85,7 +85,7 @@ export default {
let firefox = window.navigator.userAgent.match(/Firefox\/(\d+)/); let firefox = window.navigator.userAgent.match(/Firefox\/(\d+)/);
let firefoxVersion = firefox ? firefox[1] : 0; let firefoxVersion = firefox ? firefox[1] : 0;
if (firefoxVersion < 60) { if (firefoxVersion < 60) {
this.alert.html = `You are using <b style="background: #222; border-radius: .5rem; padding: .25rem .5rem;">${this.$ua._parsed.name} ${this.$ua._parsed.version}</b>. Please update to the latest version.`; this.alert.html = `<b style="background: #222; border-radius: .5rem; padding: .25rem .5rem;">${this.$ua._parsed.name} ${this.$ua._parsed.version}</b> is not supported. Consider updating to the latest version.`;
this.alert.show = true; this.alert.show = true;
} }
} }
@@ -98,7 +98,7 @@ export default {
// Win7 // Win7
if (window.navigator.userAgent.indexOf("Windows NT 6.1") > -1) { if (window.navigator.userAgent.indexOf("Windows NT 6.1") > -1) {
this.alert.html = `<b style="background: #222; border-radius: .5rem; padding: .25rem .5rem;">Windows 7</b> is not supported. Update Windows, or install Linux :)`; this.alert.html = `<b style="background: #222; border-radius: .5rem; padding: .25rem .5rem;">Windows 7</b> is not supported. Consider upgrading Windows, or installing Linux.`;
this.alert.show = true; this.alert.show = true;
} }
}, 1000); }, 1000);
@@ -177,7 +177,9 @@ body {
font-size: 2rem; font-size: 2rem;
} }
.topBar { .topBar {
width: calc(100vw - 2rem) !important; /* (2rem = mx-4) 1rem on left, 1rem on right */ width: calc(
100vw - 2rem
) !important; /* (2rem = mx-4) 1rem on left, 1rem on right */
padding: 0; padding: 0;
} }
} }
+4 -9
View File
@@ -3,9 +3,7 @@
<h1 class="primary--text">Basic Fetching Tutorial</h1> <h1 class="primary--text">Basic Fetching Tutorial</h1>
<span>Example to get votes of a given YouTube video ID:</span> <span>Example to get votes of a given YouTube video ID:</span>
<a href="https://youtube.com/watch?v=kxOuG8jMIgI" target="_blank" <a href="https://youtube.com/watch?v=kxOuG8jMIgI" target="_blank">kxOuG8jMIgI</a>
>kxOuG8jMIgI</a
>
<h2>Example Request:</h2> <h2>Example Request:</h2>
<span>Request URL:</span> <span>Request URL:</span>
@@ -47,12 +45,8 @@
</div> </div>
<br /> <br />
<v-alert border="left" color="orange" text type="info"> <v-alert border="left" color="orange" text type="info">
<span>An invalid YouTube ID will return status code 404 "Not Found".</span <span>An invalid YouTube ID will return status code 404 "Not Found".</span><br />
><br /> <span>An incorrectly formatted YouTube ID will return 400 "Bad Request".</span>
<span
>An incorrectly formatted YouTube ID will return 400 "Bad
Request".</span
>
</v-alert> </v-alert>
<a :href="endpointUrl" target="_blank" v-text="endpointUrl" /> <a :href="endpointUrl" target="_blank" v-text="endpointUrl" />
@@ -75,5 +69,6 @@ export default {
background: #353535; background: #353535;
border-radius: 0.5rem; border-radius: 0.5rem;
font-family: monospace; font-family: monospace;
line-height: 2rem;
} }
</style> </style>