-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
started replace the table with a grid
- Loading branch information
1 parent
a023a07
commit 86c0b6f
Showing
10 changed files
with
944 additions
and
162 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
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
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
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,24 @@ | ||
import {Signal} from "../../types/types"; | ||
import SignalCard from "../signal-card/SignalCard"; | ||
|
||
export interface MainGridProps { | ||
data: Signal[] | ||
} | ||
|
||
const MainGrid = ({data} : MainGridProps) => { | ||
return ( | ||
<div className="overflow-x-auto"> | ||
<div className="grid grid-cols-1 sm:grid-cols-2 md:grid-cols-3 lg:grid-cols-4 gap-6 p-6"> | ||
{ | ||
data.map(it => <SignalCard key={ | ||
it.symbol | ||
} | ||
data={it}/>) | ||
} </div> | ||
</div> | ||
) | ||
|
||
|
||
} | ||
|
||
export default MainGrid; |
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,26 @@ | ||
import {Signal} from "../../types/types"; | ||
|
||
export interface SignalCardProps { | ||
data: Signal | ||
} | ||
|
||
const SignalCard = ({data} : SignalCardProps) => { | ||
return ( | ||
|
||
|
||
<div className="bg-[var(--color-secondary)] text-[var(--primary-text)] rounded-xl p-6 shadow-lg hover:shadow-xl transition hover:bg-[var(--hover-bg)] hover:text-[var(--hover-text)]"> | ||
<h2 className="font-bold text-2xl mb-4 text-[var(--highlight)]"> | ||
{ | ||
data.symbol | ||
} </h2> | ||
<p className="text-lg mb-2"> | ||
<strong className="text-[var(--secondary-text)]">Time:</strong> | ||
{" "} | ||
{ | ||
data.signalTime | ||
} </p> | ||
</div> | ||
) | ||
} | ||
|
||
export default SignalCard; |
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 |
---|---|---|
@@ -1,3 +1,7 @@ | ||
@tailwind base; | ||
@tailwind components; | ||
@tailwind utilities; | ||
|
||
* { | ||
margin: 0; | ||
padding: 0; | ||
|
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 |
---|---|---|
@@ -1,12 +1,14 @@ | ||
import "./index.css" | ||
import { StrictMode } from "react"; | ||
import { createRoot } from "react-dom/client"; | ||
import {StrictMode} from "react"; | ||
import {createRoot} from "react-dom/client"; | ||
import TradingSignals from "./components/TradingSignals.tsx"; | ||
import GetSignalsService from "./service/GetSignals.ts"; | ||
import axiosClient from "./ApiConf.ts"; | ||
|
||
createRoot(document.getElementById("root")!).render( | ||
<StrictMode> | ||
<TradingSignals signalsService={new GetSignalsService(axiosClient)} /> | ||
</StrictMode> | ||
createRoot(document.getElementById("root")!).render ( | ||
<StrictMode> | ||
<TradingSignals signalsService={ | ||
new GetSignalsService(axiosClient) | ||
}/> | ||
</StrictMode> | ||
); |
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
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,13 @@ | ||
import { Config } from 'tailwindcss'; | ||
|
||
const config: Config = { | ||
content: [ | ||
"./src/**/*.{js,jsx,ts,tsx}", | ||
], | ||
theme: { | ||
extend: {}, | ||
}, | ||
plugins: [], | ||
}; | ||
|
||
export default config; |
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