mirror of
https://github.com/revanced/revanced-website.git
synced 2025-05-10 11:24:27 +02:00
chore: Merge dev
to main
(#282)
This commit is contained in:
commit
098f610b5c
@ -18,7 +18,8 @@ function makeStore(): Readable<RouterEvent> {
|
|||||||
return derived(page, ($page) => {
|
return derived(page, ($page) => {
|
||||||
return { navigating: false, target_url: $page.url };
|
return { navigating: false, target_url: $page.url };
|
||||||
});
|
});
|
||||||
} else {
|
}
|
||||||
|
|
||||||
// On client.
|
// On client.
|
||||||
let current = new URL(location.href);
|
let current = new URL(location.href);
|
||||||
|
|
||||||
@ -35,7 +36,6 @@ function makeStore(): Readable<RouterEvent> {
|
|||||||
|
|
||||||
return { navigating, target_url: current };
|
return { navigating, target_url: current };
|
||||||
});
|
});
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Do not subscribe to it outside of components!
|
// Do not subscribe to it outside of components!
|
||||||
|
@ -9,8 +9,7 @@ import type {
|
|||||||
DonationPlatform,
|
DonationPlatform,
|
||||||
CryptoWallet,
|
CryptoWallet,
|
||||||
Social,
|
Social,
|
||||||
About,
|
About
|
||||||
CompatiblePackage
|
|
||||||
} from '$lib/types';
|
} from '$lib/types';
|
||||||
|
|
||||||
export type ContributorsData = { contributables: Contributable[] };
|
export type ContributorsData = { contributables: Contributable[] };
|
||||||
@ -41,20 +40,21 @@ async function patches(): Promise<PatchesData> {
|
|||||||
const json = await get_json('v4/patches/list');
|
const json = await get_json('v4/patches/list');
|
||||||
const packagesWithCount: { [key: string]: number } = {};
|
const packagesWithCount: { [key: string]: number } = {};
|
||||||
|
|
||||||
json.forEach((patch) => {
|
for (const patch of json) {
|
||||||
if (!patch.compatiblePackages) return;
|
if (!patch.compatiblePackages) continue;
|
||||||
|
|
||||||
patch.compatiblePackages = Object.keys(patch.compatiblePackages).map((name) => ({
|
patch.compatiblePackages = Object.keys(patch.compatiblePackages).map((name) => ({
|
||||||
name,
|
name,
|
||||||
versions: patch.compatiblePackages[name]
|
versions: patch.compatiblePackages[name]
|
||||||
}));
|
}));
|
||||||
});
|
}
|
||||||
|
|
||||||
// gets packages and patch count
|
// gets packages and patch count
|
||||||
for (let i = 0; i < json.length; i++) {
|
for (const { compatiblePackages } of json) {
|
||||||
json[i].compatiblePackages?.forEach((pkg: CompatiblePackage) => {
|
if (!compatiblePackages) continue;
|
||||||
|
for (const pkg of compatiblePackages) {
|
||||||
packagesWithCount[pkg.name] = (packagesWithCount[pkg.name] || 0) + 1;
|
packagesWithCount[pkg.name] = (packagesWithCount[pkg.name] || 0) + 1;
|
||||||
});
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// sort packages by patch count to get most relevant apps on top
|
// sort packages by patch count to get most relevant apps on top
|
||||||
|
@ -12,7 +12,7 @@ function set_status_url(apiUrl: string) {
|
|||||||
.then((data) => {
|
.then((data) => {
|
||||||
if (data?.status) {
|
if (data?.status) {
|
||||||
localStorage.setItem(STATUS_KEY, data.status);
|
localStorage.setItem(STATUS_KEY, data.status);
|
||||||
console.log('status is now ' + localStorage.getItem(STATUS_KEY));
|
console.log('Status is now:', localStorage.getItem(STATUS_KEY));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -28,10 +28,6 @@
|
|||||||
margin-bottom: 2rem;
|
margin-bottom: 2rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.hero {
|
|
||||||
padding-bottom: 9rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.hero-text {
|
.hero-text {
|
||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
@ -202,17 +202,10 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
#nav-container {
|
#nav-container {
|
||||||
|
top: 0;
|
||||||
position: sticky;
|
position: sticky;
|
||||||
z-index: 666;
|
z-index: 666;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
|
||||||
&:has(.nav-buttons > li:first-child.selected) {
|
|
||||||
margin-bottom: 2.65rem;
|
|
||||||
|
|
||||||
&:has(.banner) {
|
|
||||||
margin-bottom: 1.5rem;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
nav {
|
nav {
|
||||||
|
@ -13,7 +13,7 @@
|
|||||||
{#if status == 404}
|
{#if status == 404}
|
||||||
<p>This page received a cease and desist letter from a multi-billion dollar tech company.</p>
|
<p>This page received a cease and desist letter from a multi-billion dollar tech company.</p>
|
||||||
<br />
|
<br />
|
||||||
<Button type="filled" href="/">Return Home</Button>
|
<Button type="filled" href="/">Return home</Button>
|
||||||
{:else}
|
{:else}
|
||||||
<p>
|
<p>
|
||||||
{$page.error?.message}
|
{$page.error?.message}
|
||||||
@ -23,6 +23,9 @@
|
|||||||
|
|
||||||
<style>
|
<style>
|
||||||
section {
|
section {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
width: fit-content;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
margin-top: 10rem;
|
margin-top: 10rem;
|
||||||
}
|
}
|
||||||
|
@ -142,16 +142,15 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
.hide-on-scroll {
|
.hide-on-scroll.hidden {
|
||||||
transition: opacity 0.5s var(--bezier-one);
|
z-index: -2;
|
||||||
z-index: -999;
|
|
||||||
|
|
||||||
&.hidden {
|
|
||||||
height: 0;
|
height: 0;
|
||||||
opacity: 0;
|
opacity: 0;
|
||||||
|
overflow: hidden;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
main {
|
main {
|
||||||
|
padding-block: 2rem;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
gap: 1.5rem;
|
gap: 1.5rem;
|
||||||
|
@ -106,7 +106,7 @@
|
|||||||
{/if}
|
{/if}
|
||||||
</Query>
|
</Query>
|
||||||
<Button type="tonal" href="https://github.com/revanced/revanced-manager" target="_blank">
|
<Button type="tonal" href="https://github.com/revanced/revanced-manager" target="_blank">
|
||||||
View Source
|
View source
|
||||||
</Button>
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
<div class="screenshot">
|
<div class="screenshot">
|
||||||
|
@ -74,7 +74,13 @@
|
|||||||
{/if}
|
{/if}
|
||||||
{#if patch.compatiblePackages[0].versions.length > 1}
|
{#if patch.compatiblePackages[0].versions.length > 1}
|
||||||
<li class="button">
|
<li class="button">
|
||||||
<Button type="text" on:click={() => (showAllVersions = !showAllVersions)}>
|
<Button
|
||||||
|
type="text"
|
||||||
|
on:click={(e) => {
|
||||||
|
e.stopPropagation();
|
||||||
|
showAllVersions = !showAllVersions;
|
||||||
|
}}
|
||||||
|
>
|
||||||
<div
|
<div
|
||||||
class="expand-arrow"
|
class="expand-arrow"
|
||||||
style:transform={showAllVersions ? 'rotate(90deg)' : 'rotate(-90deg)'}
|
style:transform={showAllVersions ? 'rotate(90deg)' : 'rotate(-90deg)'}
|
||||||
@ -93,7 +99,7 @@
|
|||||||
<span transition:fade={{ easing: quintOut, duration: 1000 }}>
|
<span transition:fade={{ easing: quintOut, duration: 1000 }}>
|
||||||
<div class="options" transition:slide={{ easing: quintOut, duration: 500 }}>
|
<div class="options" transition:slide={{ easing: quintOut, duration: 500 }}>
|
||||||
{#each options as option}
|
{#each options as option}
|
||||||
<div class="option">
|
<div class="option" on:click|stopPropagation>
|
||||||
<h5 id="option-title">{option.title}</h5>
|
<h5 id="option-title">{option.title}</h5>
|
||||||
<h5>
|
<h5>
|
||||||
<pre id="option-description">{option.description}</pre>
|
<pre id="option-description">{option.description}</pre>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user