Skip to content

Commit

Permalink
merge ui-qa-checklist into feat/taikoon-alt-networks
Browse files Browse the repository at this point in the history
  • Loading branch information
bearni95 committed May 9, 2024
2 parents 2d88ba1 + d6a7ee0 commit 36cc13d
Show file tree
Hide file tree
Showing 125 changed files with 18,331 additions and 1,570 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/bridge-ui-ci.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
name: Bridge UI Build and Checks

on:
workflow_call
on: workflow_call

jobs:
build:
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/bridge-ui.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ jobs:
needs: build-and-test
uses: ./.github/workflows/vercel-deploy.yml
with:
environment: 'preview'
flags: ''
environment: "preview"
flags: ""
secrets:
vercel_project_id: ${{ secrets.VERCEL_PROJECT_ID_BRIDGE_UI_HEKLA }}
vercel_org_id: ${{ secrets.VERCEL_ORG_ID }}
Expand All @@ -32,8 +32,8 @@ jobs:
needs: build-and-test
uses: ./.github/workflows/vercel-deploy.yml
with:
environment: 'preview'
flags: ''
environment: "preview"
flags: ""
secrets:
vercel_project_id: ${{ secrets.VERCEL_PROJECT_ID_BRIDGE_UI_INTERNAL }}
vercel_org_id: ${{ secrets.VERCEL_ORG_ID }}
Expand All @@ -44,8 +44,8 @@ jobs:
needs: build-and-test
uses: ./.github/workflows/vercel-deploy.yml
with:
environment: 'production'
flags: '--prod'
environment: "production"
flags: "--prod"
secrets:
vercel_project_id: ${{ secrets.VERCEL_PROJECT_ID_BRIDGE_UI_HEKLA }}
vercel_org_id: ${{ secrets.VERCEL_ORG_ID }}
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/guardians-ui-ci.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
name: Guardians UI Build and Checks

on:
workflow_call
on: workflow_call

jobs:
check-guardian-prover-health-check-ui:
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/guardians-ui.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ jobs:
needs: build-and-test
uses: ./.github/workflows/vercel-deploy.yml
with:
environment: 'preview'
flags: ''
environment: "preview"
flags: ""
secrets:
vercel_project_id: ${{ secrets.VERCEL_PROJECT_ID_GUARDIAN_UI_HEKLA }}
vercel_org_id: ${{ secrets.VERCEL_ORG_ID }}
Expand All @@ -32,8 +32,8 @@ jobs:
needs: build-and-test
uses: ./.github/workflows/vercel-deploy.yml
with:
environment: 'preview'
flags: ''
environment: "preview"
flags: ""
secrets:
vercel_project_id: ${{ secrets.VERCEL_PROJECT_ID_GUARDIAN_UI_INTERNAL }}
vercel_org_id: ${{ secrets.VERCEL_ORG_ID }}
Expand All @@ -44,8 +44,8 @@ jobs:
needs: build-and-test
uses: ./.github/workflows/vercel-deploy.yml
with:
environment: 'production'
flags: '--prod'
environment: "production"
flags: "--prod"
secrets:
vercel_project_id: ${{ secrets.VERCEL_PROJECT_ID_GUARDIAN_UI_HEKLA }}
vercel_org_id: ${{ secrets.VERCEL_ORG_ID }}
Expand Down
18 changes: 5 additions & 13 deletions .github/workflows/taikoon-ui-ci.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
name: Taikoon UI Build and Checks

on:
workflow_call
on: workflow_call

jobs:
build:
Expand All @@ -20,24 +19,17 @@ jobs:
- name: Install pnpm dependencies
uses: ./.github/actions/install-pnpm-dependencies

- name: Copy .env.example to .env
working-directory: ./packages/guardian-prover-health-check-ui
run: cp .env.example .env

- name: Export config to .env
working-directory: ./packages/guardian-prover-health-check-ui
run: pnpm export:config

- name: Frontend build
working-directory: ./packages/taikoon-ui
run: |
export PUBLIC_WALLETCONNECT_PROJECT_ID="fake_project_id"
export PUBLIC_IPFS_GATEWAY="https://ipfs.io/ipfs/"
export $(cat .env.example | xargs)
pnpm build
- name: Svelte check
working-directory: ./packages/taikoon-ui
run: pnpm svelte:check
run: |
export $(cat .env.example | xargs)
pnpm check
- name: Check formatting
working-directory: ./packages/taikoon-ui
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/taikoon-ui.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ jobs:
needs: build-and-test
uses: ./.github/workflows/vercel-deploy.yml
with:
environment: 'preview'
flags: ''
environment: "preview"
flags: ""
secrets:
vercel_project_id: ${{ secrets.VERCEL_PROJECT_ID_TAIKOON_UI_MAINNET }}
vercel_org_id: ${{ secrets.VERCEL_ORG_ID }}
Expand All @@ -32,8 +32,8 @@ jobs:
needs: build-and-test
uses: ./.github/workflows/vercel-deploy.yml
with:
environment: 'production'
flags: '--prod'
environment: "production"
flags: "--prod"
secrets:
vercel_project_id: ${{ secrets.VERCEL_PROJECT_ID_TAIKOON_UI_MAINNET }}
vercel_org_id: ${{ secrets.VERCEL_ORG_ID }}
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/vercel-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,18 +11,18 @@ on:
required: true
secrets:
vercel_project_id:
description: 'Vercel Project ID'
description: "Vercel Project ID"
required: true
vercel_org_id:
description: 'Vercel ORG ID'
description: "Vercel ORG ID"
required: true
vercel_token:
description: 'Vercel TOKEN'
description: "Vercel TOKEN"
required: true

env:
VERCEL_ORG_ID: ${{ secrets.vercel_org_id }}
VERCEL_PROJECT_ID: ${{ secrets.vercel_project_id }}
VERCEL_ORG_ID: ${{ secrets.vercel_org_id }}
VERCEL_PROJECT_ID: ${{ secrets.vercel_project_id }}

jobs:
build-deploy:
Expand Down
5 changes: 3 additions & 2 deletions packages/taikoon-ui/.env.example
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
PUBLIC_WALLETCONNECT_PROJECT_ID=
PUBLIC_IPFS_GATEWAY=
PUBLIC_WALLETCONNECT_PROJECT_ID=fake
PUBLIC_IPFS_GATEWAY=https://taikoons-fake-ipfs-gateway.vercel.app/ipfs/
PUBLIC_LAUNCH_DATE=2024-05-26T00:00:00
3 changes: 2 additions & 1 deletion packages/taikoon-ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,12 @@
"@sveltejs/kit": "^2.0.0",
"@sveltejs/vite-plugin-svelte": "^3.0.0",
"@types/eslint": "^8.56.0",
"@types/jest": "^29.5.12",
"@types/node": "^20.12.7",
"@typescript-eslint/eslint-plugin": "^7.0.0",
"@typescript-eslint/parser": "^7.0.0",
"convert-csv-to-json": "^2.44.0",
"dotenv": "^16.4.5",
"eslint": "^8.56.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-simple-import-sort": "^12.0.0",
Expand Down Expand Up @@ -65,7 +67,6 @@
"debug": "^4.3.4",
"minidenticons": "^4.2.1",
"postcss": "^8.4.38",
"svelte-countdown": "^1.1.2",
"tailwindcss": "^3.4.3",
"viem": "^2.9.29"
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
<script lang="ts">
import { Icons } from '$components/core/Icons';
import { classNames } from '$lib/util/classNames';
export let isHovered = false;
const ArrowIcon = Icons.ArrowRightFilled;
const wrapperClasses = classNames(
'bg-primary-content',
'rounded-full',
'w-[32px]',
'h-[32px]',
'flex',
'items-center',
'justify-center',
'overflow-hidden',
);
$: arrowsWrapper = classNames(
'w-full',
'h-full',
'relative',
'flex',
'items-center',
'justify-center',
'transition',
'transform',
isHovered ? 'translate-x-[100%]' : null,
'ease-in-out',
'duration-300',
);
const arrowClasses = classNames('absolute');
const leftArrowClasses = classNames(arrowClasses, 'left-[-100%]');
const rightArrowClasses = classNames(arrowClasses);
</script>

<div class={wrapperClasses}>
<div class={arrowsWrapper}>
<ArrowIcon size="32" class={leftArrowClasses} />
<ArrowIcon size="32" class={rightArrowClasses} />
</div>
</div>
1 change: 1 addition & 0 deletions packages/taikoon-ui/src/components/AnimatedArrow/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export { default as AnimatedArrow } from './AnimatedArrow.svelte';
Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@
<script>
import { getContext } from 'svelte';
const ctx = getContext('iconCtx') ?? {};
<script lang="ts">
export let size = 'full';
export let role = ctx.role || 'img';
export let ariaLabel = 'angle up solid';
export let title = {};
export let desc = {};
export let role = 'img';
export let ariaLabel = 'animated taikoon';
export let title = {
id: `animated-taikoon-title-${Math.random().toString(36).substring(7)}`,
title: ariaLabel,
};
export let desc = {
id: `animated-taikoon-desc-${Math.random().toString(36).substring(7)}`,
desc: 'An animated taikoon',
};
import { onDestroy, onMount } from 'svelte';
import { Theme, theme } from '../../stores/theme';
Expand All @@ -32,7 +36,7 @@
$: colorPairIndex = 0;
let animationIntervalId;
let animationIntervalId: any;
onMount(() => {
animationIntervalId = setInterval(() => {
primaryColor = colorPairs[colorPairIndex].primary;
Expand Down
28 changes: 6 additions & 22 deletions packages/taikoon-ui/src/components/Collection/Collection.svelte
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
<script lang="ts">
import { getContext } from 'svelte';
import { t } from 'svelte-i18n';
import { ResponsiveController } from '$components/core/ResponsiveController';
import { classNames } from '$lib/util/classNames';
import { InputBox } from '$ui/InputBox';
import { Select } from '$ui/Select';
import type { ITaikoonDetail } from '$stores/taikoonDetail';
import { NftRenderer } from '../NftRenderer';
import { filterFormWrapperClasses, taikoonsWrapperClasses, wrapperClasses } from './classes';
import { filterFormWrapperClasses, taikoonsWrapperClasses, titleClasses, wrapperClasses } from './classes';
import { default as TaikoonDetail } from './TaikoonDetail.svelte';
export let tokenIds: number[] = [];
let windowSize: 'sm' | 'md' | 'lg' = 'md';
export let title: string = 'The Collection';
export let isLoading = false;
const taikoonDetailState = getContext('taikoonDetail');
const taikoonDetailState = getContext<ITaikoonDetail>('taikoonDetail');
$: selectedTaikoonId = -1;
Expand All @@ -40,23 +40,7 @@
{/if}
<div class="flex flex-col w-full h-full">
<div class={filterFormWrapperClasses}>
<InputBox class="w-full" size="lg" placeholder={$t('content.collection.search.placeholder')} />

<Select
onSelect={(value) => {
console.warn(value);
}}
label={$t('content.collection.filter.latest')}
options={[
{
label: $t('content.collection.filter.latest'),
value: 'latest',
},
{
label: $t('content.collection.filter.oldest'),
value: 'oldest',
},
]} />
<div class={titleClasses}>{title}</div>
</div>
<div class={taikoonsWrapperClasses}>
{#each tokenIds as tokenId}
Expand Down
8 changes: 8 additions & 0 deletions packages/taikoon-ui/src/components/Collection/classes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ export const taikoonsWrapperClasses = classNames(
'gap-5',
'p-5',
'grid',
'xl:grid-cols-8',
'lg:grid-cols-6',
'md:grid-cols-4',
'grid-cols-3',
Expand Down Expand Up @@ -74,3 +75,10 @@ export const detailTitleClasses = classNames(
);

export const chipWrapperClasses = classNames('my-2', 'flex', 'flex-row', 'w-full', 'justify-start');

export const titleClasses = classNames(
'font-clash-grotesk',
'text-[57px]/[64px]',
'text-content-primary',
'font-semibold',
);
Loading

0 comments on commit 36cc13d

Please sign in to comment.