Skip to content

Commit

Permalink
Add logo to app
Browse files Browse the repository at this point in the history
  • Loading branch information
thoughtspile committed Dec 24, 2023
1 parent 7041155 commit a0ba471
Show file tree
Hide file tree
Showing 7 changed files with 33 additions and 21 deletions.
6 changes: 3 additions & 3 deletions ROADMAP.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@
- docs
- Aggregation
- custom aggregation
- Projection
- Column selection
- Column reordering

## Backlog

Expand All @@ -17,6 +14,9 @@
- tsv
- table
- custom date / number formatters
- Projection
- Column selection
- Column reordering
- Analysis
- Filters
- remove filter
Expand Down
16 changes: 16 additions & 0 deletions src/app/Logo.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
export function Logo() {
return (
<h1 class="Title">
<svg viewBox="0 -18 125 22">
<defs>
<linearGradient id="rainbow" x1="0" x2="100%" y1="0" y2="100%" gradientUnits="userSpaceOnUse" >
<stop stop-color="#01386a" offset="0%"/>
<stop stop-color="#66FFB3" offset="100%"/>
</linearGradient>
</defs>
<text fill="url(#rainbow)" x="-1%">HippoTable</text>
</svg>
A better way to analyze data
</h1>
);
}
6 changes: 6 additions & 0 deletions src/app/Uploader.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@
}
}

.ButtonGroup {
display: flex;
gap: 1rem;
flex-wrap: wrap;
}

.Button {
box-sizing: border-box;
border: none;
Expand Down
4 changes: 2 additions & 2 deletions src/app/Uploader.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { GitHubLogo } from './GitHubLogo';

export function Uploader() {
return (
<>
<div class={styles.ButtonGroup}>
<label class={`${styles.Button} ${styles.primary}`}>
<FaSolidUpload />&nbsp;Open CSV
<input type="file" accept=".csv,.tsv,text/csv" onInput={e => persistSource(e.currentTarget.files[0])} />
Expand All @@ -17,6 +17,6 @@ export function Uploader() {
<a href={GH_REPO} target="_blank" class={styles.Button}>
<GitHubLogo />&nbsp;Star on GitHub
</a>
</>
</div>
);
}
2 changes: 2 additions & 0 deletions src/app/Welcome.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,12 @@
min-height: 100vh;
display: flex;
align-items: center;
flex-direction: column;
justify-content: center;
gap: 1rem;
background: linear-gradient(to right, #FFA566, #FF1E66);
position: relative;
padding: 1rem;
}

.Spinner {
Expand Down
2 changes: 2 additions & 0 deletions src/app/Welcome.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import styles from './Welcome.module.css';
import { Spinner } from './ui/Spinner';
import { Show } from 'solid-js';
import { Uploader } from './Uploader';
import { Logo } from './Logo';

type WelcomeProps = {
loading: boolean;
Expand All @@ -11,6 +12,7 @@ export function Welcome(props: WelcomeProps) {
return (
<section class={styles.Welcome} classList={{ [styles.loading]: props.loading }}>
<Show when={!props.loading} fallback={<div class={styles.Spinner}><Spinner /></div>}>
<Logo />
<Uploader />
</Show>
</section>
Expand Down
18 changes: 2 additions & 16 deletions src/pages/index.astro
Original file line number Diff line number Diff line change
@@ -1,22 +1,12 @@
---
import { Logo } from '../app/Logo.tsx';
import { Uploader } from '../app/Uploader';
import Layout from '../layout.astro';
---

<Layout>
<section class="Landing">
<h1 class="Title">
<svg viewBox="0 -18 125 22">
<defs>
<linearGradient id="rainbow" x1="0" x2="100%" y1="0" y2="100%" gradientUnits="userSpaceOnUse" >
<stop stop-color="#01386a" offset="0%"/>
<stop stop-color="#66FFB3" offset="100%"/>
</linearGradient>
</defs>
<text fill="url(#rainbow)">HippoTable</text>
</svg>
A better way to analyze data
</h1>
<div class="Title"><Logo /></div>
<div class="actions"><Uploader client:load /></div>
<div class="CardContainer">
<div class="Card">
Expand Down Expand Up @@ -70,10 +60,6 @@ import Layout from '../layout.astro';
color: #01386a;
}

.Title svg {
margin-left: -1%;
}

.CardContainer {
display: flex;
flex-wrap: wrap;
Expand Down

0 comments on commit a0ba471

Please sign in to comment.