-
Notifications
You must be signed in to change notification settings - Fork 0
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
Chanatpakorn/web 14 home members #19
Merged
Merged
Changes from 2 commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
40c619f
feat:fetch octokit
ChanatpakornS db5c7aa
feat: members
ChanatpakornS 5a6587a
feat: desktop animation and ring
ChanatpakornS 9b76810
refactor: home animation
ChanatpakornS 5ff868f
refactor: camel case
ChanatpakornS d3c77da
refactor: del console log
ChanatpakornS File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
<script lang="ts"> | ||
import ProfileCard from "./ProfileCard.svelte"; | ||
import type { OrgMember } from "./types.ts"; | ||
export let OrgMembers: OrgMember[]; | ||
</script> | ||
|
||
<section> | ||
<div | ||
class="mb-20 flex flex-col items-center justify-center gap-4 px-8 text-center" | ||
> | ||
<div class="w-3/4"> | ||
<p class="text-4xl font-medium text-white">Members</p> | ||
<div class="mt-6 flex w-full flex-col justify-center lg:my-20"> | ||
<div class="inline-flex flex-wrap justify-center"> | ||
{#if !OrgMembers || OrgMembers.length === 0} | ||
<p>No Public Members found...</p> | ||
{:else} | ||
{#each OrgMembers as member} | ||
<ProfileCard | ||
username={member.login} | ||
avatarURL={member.avatar_url} | ||
profileURL={member.html_url} | ||
/> | ||
{/each} | ||
{/if} | ||
</div> | ||
</div> | ||
</div> | ||
<a href="https://github.com/orgs/isd-sgcu/people"> | ||
<button | ||
class="item-center rounded-lg border border-[#807F7E] bg-transparent px-4 py-2 font-normal text-[#807F7E] duration-100 hover:bg-[#807F7E] hover:text-primary" | ||
> | ||
All members | ||
</button> | ||
</a> | ||
</div> | ||
</section> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
<script lang="ts"> | ||
export let username: string; | ||
export let avatarURL: string; | ||
export let profileURL: string; | ||
</script> | ||
|
||
<div> | ||
<div class="mx-2 my-4 inline-block"> | ||
<a class="no-underline" title={username} href={profileURL}> | ||
<div | ||
id="profile" | ||
class="rounded bg-[#232428] p-2 text-white duration-200 hover:scale-110" | ||
> | ||
<div class="flex flex-row items-center"> | ||
<img | ||
id="image-profile" | ||
alt={username} | ||
class="mr-2 h-8 w-8 rounded-full" | ||
src={avatarURL} | ||
/> | ||
<p class="text-sm"> | ||
@ {username} | ||
</p> | ||
</div> | ||
</div> | ||
</a> | ||
</div> | ||
</div> | ||
|
||
<style lang="post-css"> | ||
#image-profile { | ||
width: 30px; | ||
height: 30px; | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
import type { Endpoints } from "@octokit/types"; | ||
|
||
export type OrgMember = | ||
Endpoints["GET /orgs/{org}/public_members"]["response"]["data"][number]; | ||
|
||
export type GitHubUser = Pick<OrgMember, "avatar_url" | "login" | "html_url">; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
prop name should be camelCase