Skip to content

Commit

Permalink
update misc. colors and dropdowns/inputs (#181)
Browse files Browse the repository at this point in the history
Help on Shannon's PR

Co-authored-by: Claire Olmstead <olmsteadclaire@gmail.com>
  • Loading branch information
claireclark1 and claireclark1 authored Oct 9, 2024
1 parent 16af4b3 commit 55f7e52
Show file tree
Hide file tree
Showing 9 changed files with 31 additions and 280 deletions.
7 changes: 6 additions & 1 deletion src/components/DropDownMenu.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,12 @@

<div>
<label class="label mb-3.5 block" for={id}>{label}</label>
<select {...$$restProps} {id} bind:value on:change={onChange} class="bg-white text-teal-dark">
<select
{...$$restProps}
{id}
bind:value
on:change={onChange}
>
{#if placeholder !== ''}
<option class="text-disabled" value={null} disabled selected>{placeholder}</option>
{/if}
Expand Down
5 changes: 2 additions & 3 deletions src/components/FAQItem.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,13 @@
>
<slot name="question" />
<svg
class="w-8 ml-12 h-8 shrink-0 transform rounded btn-primary p-1 transition-transform duration-300 {isOpen
? 'rotate-180'
: ''}"
class="w-8 ml-12 h-8 shrink-0 transform bg-black p-1 transition-transform duration-300 {isOpen ? 'rotate-180' : ''}"
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 20 20"
fill="currentColor"
>
<path
class="text-white"
fill-rule="evenodd"
d="M6.293 9.293a1 1 0 011.414 0L10 11.586l2.293-2.293a1 1 0 111.414 1.414l-3 3a1 1 0 01-1.414 0l-3-3a1 1 0 010-1.414z"
clip-rule="evenodd"
Expand Down
3 changes: 1 addition & 2 deletions src/components/Nav.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@
};
</script>

<div class="fixed flex h-screen w-[126px] min-w-[126px] flex-col items-center justify-center sidebar-bg">
{url}
<div class="sidebar-bg fixed flex h-screen w-[126px] min-w-[126px] flex-col items-center justify-center">
<div class="flex w-[100%] flex-col">
<NavItem href="/" isActive={url === '/'} onClick={() => (url = '/')}>Home</NavItem>
{#if $isLoggedIn === true}
Expand Down
2 changes: 1 addition & 1 deletion src/components/NavItem.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
{href}
on:click={onClick}
class={` flex h-[100px] items-center justify-center text-sm font-bold ${
isActive && 'text-teal-light shadow-blue-border'
isActive && 'bg-cream text-teal shadow-blue-border'
}`}
{target}
>
Expand Down
2 changes: 1 addition & 1 deletion src/components/ProviderLogin.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import { pageContent } from '$lib/stores/pageContentStore';
</script>

<div id="provider-login" class="column w-single-block">
<div id="provider-login" class="column content-block w-single-block">
<BlockSection title="Provider Login">
<LoginForm />
</BlockSection>
Expand Down
243 changes: 0 additions & 243 deletions src/components/Wave.svelte

This file was deleted.

4 changes: 0 additions & 4 deletions src/routes/+layout.svelte
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<script lang="ts">
import Header from '../components/Header.svelte';
import Nav from '../components/Nav.svelte';
import Wave from '../components/Wave.svelte';
import { logInPromise, dotApi, storeChainInfo } from '$lib/stores';
import { getToken } from '$lib/polkadotApi';
import { getBlockNumber, getEpoch } from '$lib/connections';
Expand All @@ -26,9 +25,6 @@
</script>

<div>
<div class="fixed right-0 top-[10%] z-[-1] w-[100%] opacity-60">
<Wave />
</div>
<div class="flex">
<Nav />
<div class="m-6 w-[100%] pl-[126px]">
Expand Down
40 changes: 19 additions & 21 deletions src/style/app.css
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,7 @@
line-height: 24px;
font-weight: 400;

background-color: #FEFAF3;
color: #18465E;
background-color: #fefaf3;

font-synthesis: none;
text-rendering: optimizeLegibility;
Expand All @@ -23,12 +22,20 @@

/* */
@layer components {
.sidebar-bg {
@apply bg-flan;
}

.btn-primary {
@apply flex h-10 w-[225px] items-center justify-center rounded-full bg-teal-light text-base font-bold text-white disabled:bg-disabled;
@apply flex h-10 w-[225px] items-center justify-center rounded-full bg-teal text-base font-bold text-white hover:text-white hover:opacity-75 disabled:bg-disabled;
}

.btn-primary:disabled {
@apply hover:opacity-100;
}

.btn-no-fill {
@apply text-sm text-white underline;
@apply text-sm underline hover:text-bright-blue;
}

.action-card {
Expand Down Expand Up @@ -79,16 +86,16 @@
}

.data-value-lg {
@apply font-data text-lg text-teal-light;
@apply font-data text-lg text-teal;
}

.data-value-2xl {
@apply font-data text-2xl text-teal-light;
@apply font-data text-2xl text-teal;
}

/* layout */
.content-block {
@apply rounded-md bg-white p-7 text-teal-dark drop-shadow-lg;
@apply rounded-md bg-white p-7 drop-shadow-lg;
}

.break-anywhere {
Expand All @@ -98,31 +105,18 @@

@layer base {
body {
@apply text-teal-dark;
min-height: 100vh;
}

button {
@apply select-none;
}

.btn-primary {
@apply bg-teal-light;
}

.btn-primary:hover {
@apply opacity-75;
}

.sidebar-bg {
@apply bg-flan;
}

input,
[type='text'],
[type='number'],
select {
@apply h-[30px] w-[320px] overflow-ellipsis rounded-md border-none py-0 pl-2 text-sm text-black outline-none disabled:text-disabled disabled:opacity-85;
@apply h-[30px] w-[320px] overflow-ellipsis rounded-md border-none bg-white py-0 pl-2 text-sm text-black outline-none outline outline-1 outline-gray-3 disabled:text-disabled disabled:opacity-85;
}

select {
Expand All @@ -132,4 +126,8 @@
::placeholder {
@apply text-disabled !important;
}

a {
@apply hover:text-bright-blue;
}
}
5 changes: 1 addition & 4 deletions tailwind.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,9 @@ export default {
success: '#27AE60',
warning: '#F99A2A',
error: '#EB5757',
'teal-dark': '#18465E',
'teal-light': '#55B1AB',

teal: '#55B1AB',
divider: '#504D4D',
overlay: 'rgba(57, 52, 52, 0.75)',

},
width: {
modal: '480px',
Expand Down

0 comments on commit 55f7e52

Please sign in to comment.