Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: community and developer pages #211

Merged
merged 45 commits into from
Apr 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
45 commits
Select commit Hold shift + click to select a range
517d594
Heading and Subhead components
tbenbow Apr 20, 2023
29bc3c5
PageSection responsive styling
tbenbow Apr 20, 2023
ab4344d
ImageSplit component
tbenbow Apr 20, 2023
3bd3037
Btn component
tbenbow Apr 20, 2023
2c82d74
Home layout and refine some components
tbenbow Apr 21, 2023
a11f442
Home page components and resources
tbenbow Apr 21, 2023
caec494
Remove unused hero component
tbenbow Apr 21, 2023
49be204
update gitignore
tbenbow Apr 22, 2023
9a381e6
Remove unused componemts
tbenbow Apr 22, 2023
2a2f14d
Add footer
tbenbow Apr 22, 2023
dcb4386
Update uno colors and button styles
tbenbow Apr 22, 2023
33a4e75
Update newsletter component
tbenbow Apr 22, 2023
c5f5c40
Update components on home page
tbenbow Apr 22, 2023
fed9ce8
Footer revisions and social links
tbenbow Apr 24, 2023
40fd159
More footer refinements
tbenbow Apr 24, 2023
3232a7e
Merge branch 'v3.x' into feat/home-layout
cwaring Apr 25, 2023
52f3860
Merge branch 'v3.x' into feat/home-layout
cwaring Apr 25, 2023
d567dd8
refactor: use switch
cwaring Apr 25, 2023
ad32ec0
ignore .output
cwaring Apr 25, 2023
1f202da
refactor: use object/array syntax for dyn class
cwaring Apr 25, 2023
50c2ee0
Add card type 2
tbenbow Apr 25, 2023
da12af5
Merge branch 'feat/home-layout' of github.com:ipfs/ipfs-website into …
tbenbow Apr 25, 2023
23debe6
Update script style of newsletter component
tbenbow Apr 25, 2023
be1d438
Add list links
tbenbow Apr 25, 2023
8b1dd93
Add footer constellations
tbenbow Apr 25, 2023
02ab3c4
Add excerpt attribute to card
tbenbow Apr 25, 2023
36e0110
Refactor image split component
tbenbow Apr 25, 2023
837b075
Footer formatting updates
tbenbow Apr 25, 2023
d834996
Update page section spacing
tbenbow Apr 25, 2023
2672d32
Use object syntax for dynamic class
tbenbow Apr 25, 2023
701def4
Repair page section
tbenbow Apr 25, 2023
d374279
Avoid undefined style in image split component
tbenbow Apr 25, 2023
b1f6c7e
Medium grid columns
tbenbow Apr 25, 2023
99b00db
Grid shouldn't have those props
tbenbow Apr 25, 2023
adbe613
add isExternal fn to AppLink
cwaring Apr 25, 2023
b50e9d9
fix: resolve merge conflict
cwaring Apr 25, 2023
a25af75
Connect section
tbenbow Apr 26, 2023
1f66ed7
Merge branch 'v3.x' into feat/community-page
tbenbow Apr 26, 2023
5157b5e
Community page wip
tbenbow Apr 27, 2023
6605b90
Developers page wip
tbenbow Apr 27, 2023
841d220
Merge branch 'v3.x' into feat/community-developer-pages
tbenbow Apr 27, 2023
9a06917
add carbon icons
cwaring Apr 27, 2023
479acec
Spacing updates
tbenbow Apr 27, 2023
dd83c72
Link updates
tbenbow Apr 27, 2023
ef5c24d
Merge branch 'feat/community-developer-pages' of github.com:ipfs/ipfs…
tbenbow Apr 27, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions assets/css/fonts.css
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,25 @@ h1, h2, h3, h4, h5, h6 {
}
p {
@apply text-lg;
}
p:not(:last-child) {
@apply mb-4;
}
Comment on lines 4 to +9
Copy link
Member

@cwaring cwaring Apr 27, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's scope the styles like this to their containers to save having to reset them. The .prose class should format copy nicely wherever we need it


main a:not(.btn) {
@apply underline;
}

.list-xl {
@apply text-xl list-disc pl-4;
}
.list-xl li {
@apply mb-8;
}
.list-xl li::marker {
@apply text-brand-teal;
}

@screen lg {
@apply ml-8;
}
4 changes: 4 additions & 0 deletions components/Btn.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ import type { AppLinkProps } from '@/components/AppLink.vue'

interface Props extends AppLinkProps {
primary?: boolean
outline?: boolean
full?: boolean
}
defineProps<Props>()
</script>
Expand All @@ -12,6 +14,8 @@ defineProps<Props>()
class="btn" :class="
{
'btn-primary': primary,
'btn-outline': outline,
'w-full text-center': full,
}"
>
<slot />
Expand Down
2 changes: 1 addition & 1 deletion components/Card2.vue
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ defineProps<Props>()
<div class="p-6 pt-4">
<p v-if="excerpt" class="inline-block text-base">
{{ excerpt }}...
<a class="text-brand-teal-dark underline" :href="link">Read more</a>
<span class="text-brand-teal-dark underline"><AppLink :href="link">Read more</AppLink></span>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

does AppLink not accept the classes here?

</p>
<slot />
<div v-if="category || tags" class="flex inline-flex mt-4 gap-1">
Expand Down
5 changes: 5 additions & 0 deletions components/CardSubhead.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<template>
<h3 class="text-2xl text-black mb-2">
<slot />
</h3>
</template>
104 changes: 80 additions & 24 deletions components/Footer.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>
<footer class="relative">
<div class="absolute -z-1 w-full h-full bg-gradient-to-r from-brand-dark to-brand-blue" />
<div class="absolute -z-1 w-full h-full bg-gradient-to-r from-brand-dark to-brand-blue-dark" />
<div class="absolute lg:overflow-visible overflow-x-hidden bottom-0 right-0">
<img src="/images/constellations-footer.svg" alt="">
</div>
Expand All @@ -15,53 +15,109 @@
<div class="lg:pl-8 pl-0 lg:mt-0 mt-8">
<div class="flex justify-between gap-4">
<div>
<Subhead bold small>
<Subhead bold small tight>
About
</Subhead>
<ul class="lg:text-sm text-xs leading-7">
<li><a href="https://protocol.ai/">About Protocol Labs</a></li>
<li><a href="https://blog.ipfs.tech/">Blog &amp; News</a></li>
<li><a href="https://ipfs.tech/media">Press</a></li>
<li><a href="https://github.com/ipfs/community/blob/master/code-of-conduct.md">Code of conduct</a></li>
<li><a href="https://github.com/ipfs/community/blob/master/CONTRIBUTING.md#security-issues">Security</a></li>
<li><a href="#">Browsers</a></li>
<li>
<AppLink href="https://protocol.ai/">
About Protocol Labs
</AppLink>
</li>
<li>
<AppLink href="https://blog.ipfs.tech/">
Blog &amp; News
</AppLink>
</li>
<li>
<AppLink href="https://ipfs.tech/media">
Press
</AppLink>
</li>
<li>
<AppLink href="https://github.com/ipfs/community/blob/master/code-of-conduct.md">
Code of conduct
</AppLink>
</li>
<li>
<AppLink href="https://github.com/ipfs/community/blob/master/CONTRIBUTING.md#security-issues">
Security
</AppLink>
</li>
<li>
<AppLink href="#">
Browsers
</AppLink>
</li>
</ul>
</div>
<div>
<Subhead bold small>
<Subhead bold small tight>
Community
</Subhead>
<ul class="mt-4 lg:text-sm text-xs leading-7">
<li><a href="#">Forums</a></li>
<li><a href="#">Office Hours</a></li>
<li><a href="#">Hackathons</a></li>
<li><a href="#">Developer Grants</a></li>
<li><a href="#">Accelerators</a></li>
<li>
<AppLink href="#">
Forums
</AppLink>
</li>
<li>
<AppLink href="#">
Office Hours
</AppLink>
</li>
<li>
<AppLink href="#">
Hackathons
</AppLink>
</li>
<li>
<AppLink href="#">
Developer Grants
</AppLink>
</li>
<li>
<AppLink href="#">
Accelerators
</AppLink>
</li>
</ul>
</div>
<div>
<Subhead bold small>
<Subhead bold small tight>
Resources
</Subhead>
<ul class="mt-4 lg:text-sm text-xs leading-7">
<li><a href="#">Specs</a></li>
<li><a href="#">Examples</a></li>
<li><a href="#">Research</a></li>
<li>
<AppLink href="">
Specs
</AppLink>
</li>
<li>
<AppLink href="">
Examples
</AppLink>
</li>
<li>
<AppLink href="">
Research
</AppLink>
</li>
</ul>
</div>
</div>
</div>
</div>
<div class="flex gap-4 justify-end mt-4">
<a href="http://twitter.com/ipfs">
<AppLink href="http://twitter.com/ipfs">
<img src="/images/social-twitter.svg" alt="Twitter logo" class="w-8">
</a>
<a href="https://github.com/ipfs">
</AppLink>
<AppLink href="https://github.com/ipfs">
<img src="/images/social-github.svg" alt="Github logo" class="w-8">
</a>
<a href="https://www.youtube.com/channel/UCdjsUXJ3QawK4O5L1kqqsew">
</AppLink>
<AppLink href="https://www.youtube.com/channel/UCdjsUXJ3QawK4O5L1kqqsew">
<img src="/images/social-youtube.svg" alt="Youtube logo" class="w-8">
</a>
</AppLink>
</div>
</div>
</footer>
Expand Down
3 changes: 2 additions & 1 deletion components/Heading.vue
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
<script setup lang="ts">
interface Props {
center?: boolean
tight?: boolean
}
defineProps<Props>()
</script>

<template>
<h2 class="text-4xl m-b-8" :class="{ 'text-center': center }">
<h2 class="text-4xl" :class="[{ 'text-center': center }, tight ? 'mb-2' : 'mb-8']">
<slot />
</h2>
</template>
4 changes: 2 additions & 2 deletions components/ListLink.vue
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ defineProps<Props>()

<template>
<li class="inline-block text-sm font-bold text-brand-teal-dark border-brand-teal-dark border-r-2 last:border-r-0 pr-3 mr-3 last:pr-0 last:mr-0">
<a :href="link">
<AppLink :href="link">
{{ label }}
</a>
</AppLink>
</li>
</template>
4 changes: 2 additions & 2 deletions components/NewsletterForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ function onSubmit() {

<template>
<div id="newsletter-form">
<Subhead bold small>
<Subhead bold small tight>
Stay informed
</Subhead>
<p class="text-sm mb-8 ">
Sign up for the IPFS Weekly newsletter (<a class="text-blueGreenLight hover:underline" href="https://blog.ipfs.tech/?tags=weekly">example</a>) for the latest on releases, upcoming developments, community events, and more.
Sign up for the IPFS Weekly newsletter (<span class="text-brand-teal underline"><AppLink href="https://blog.ipfs.tech/?tags=weekly">example</AppLink></span>) for the latest on releases, upcoming developments, community events, and more.
</p>
<form
id="mc-embedded-subscribe-form"
Expand Down
9 changes: 5 additions & 4 deletions components/PageSection.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ interface Props {
textWhite?: boolean
contentClasses?: string
tight?: boolean
bottomTight?: boolean
}
defineProps<Props>()
</script>
Expand All @@ -17,13 +18,13 @@ defineProps<Props>()
<section
:id="id" class="relative" :class="{ 'text-white': textWhite }"
>
<div v-if="darkGradient" class="absolute -z-1 w-full h-full bg-gradient-to-r from-brand-dark to-brand-blue" />
<div v-if="darkGradient" class="absolute -z-1 w-full h-full bg-gradient-to-r from-brand-dark to-brand-blue-dark" />
<div v-if="lightGradient" class="absolute -z-1 w-full h-full bg-gradient-to-b from-brand-teal-light to-white" />
<img v-if="background" :src="`./images/${background}`" alt="" class="absolute -z-1 w-full h-full object-cover">
<div :class="`absolute lg:overflow-visible overflow-x-hidden ${overlayPosition}`">
<img v-if="overlay" :src="`./images/${overlay}`" alt="">
<div v-if="overlay" class="absolute inset-0 lg:overflow-visible overflow-x-hidden">
<img :src="`./images/${overlay}`" :class="`absolute ${overlayPosition}`">
</div>
<div class="relative max-w-screen-xl mx-auto lg:p-x-32 px-7" :class="[tight ? 'lg:py-14 py-6' : 'lg:py-28 py-14']">
<div class="relative max-w-screen-xl mx-auto lg:p-x-32 px-7" :class="[tight ? 'lg:py-14 py-6' : 'lg:py-20 py-14', bottomTight ? 'lg:pb-0 pb-0' : 'lg:pb-28 pb-14']">
<slot />
</div>
</section>
Expand Down
4 changes: 3 additions & 1 deletion components/Subhead.vue
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
<script setup lang="ts">
interface Props {
center?: boolean
bold?: boolean
small?: boolean
tight?: boolean
}
defineProps<Props>()
</script>

<template>
<h3 :class="[bold ? 'font-bold' : 'font-normal', small ? 'text-lg mb-3' : 'text-2xl mb-13']">
<h3 :class="[bold ? 'font-bold' : 'font-normal', small ? 'text-lg' : 'text-2xl', tight ? 'mb-3' : 'mb-10', { 'text-center': center }]">
<slot />
</h3>
</template>
29 changes: 29 additions & 0 deletions components/ZebraCard.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<script setup lang="ts">
interface Props {
buttonLabel?: string
buttonLink?: string
}
defineProps<Props>()
</script>

<template>
<div class="zebra-card p-6 rounded-xl flex flex-col justify-between odd:bg-brand-blue even:border-1">
<div>
<slot />
</div>
<div class="flex-none pt-4">
<Btn v-if="buttonLabel" :href="buttonLink" outline full>
{{ buttonLabel }}
</Btn>
</div>
</div>
</template>

<style lang="postcss">
.zebra-card h3 {
@apply text-teal mb-6;
}
.zebra-card p {
@apply text-sm mb-4;
}
</style>
4 changes: 3 additions & 1 deletion layouts/default.vue
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,9 @@ export default {

<template>
<div class="flex flex-col min-h-screen font-sans">
<slot />
<main>
<slot />
</main>
<Footer />
</div>
</template>
Expand Down
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,11 @@
},
"devDependencies": {
"@antfu/eslint-config": "^0.38.5",
"@iconify-json/carbon": "^1.1.16",
"@nuxt/content": "^2.6.0",
"@nuxtjs/plausible": "^0.2.0",
"@unocss/nuxt": "^0.51.8",
"@unocss/preset-icons": "^0.51.8",
"@vueuse/nuxt": "^10.1.0",
"eslint": "^8.39.0",
"nuxt": "^3.4.2",
Expand Down
Loading