Skip to content
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

Revert "update ui" #7

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
107 changes: 0 additions & 107 deletions src/App.css
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,6 @@
pointer-events: none;
}

@font-face {
font-family: 'Virgil';
src: url('https://excalidraw.com/Virgil.woff2') format('woff2');
}

@media (prefers-reduced-motion: no-preference) {
.App-logo {
animation: App-logo-spin infinite 20s linear;
Expand Down Expand Up @@ -41,105 +36,3 @@
transform: rotate(360deg);
}
}

.skeleton-card {
background-color: #fff;
border-radius: 8px;
border: 1px solid #e0e0e0;
overflow: hidden;
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
transition: transform 0.3s, box-shadow 0.3s;
max-width: 100%;
width: 100%;
}

.skeleton-card-content {
display: flex;
flex-direction: column;
align-items: center;
}

.skeleton-card-image {
width: 100%;
object-fit: cover;
border-radius: 4px;
display: block;
height: 150px;
background-color: #ccc;
margin-bottom: 10px;
animation: skeleton-line 1.5s infinite;
}

.skeleton-card-description {
width: 100%;
height: 40px;
background-color: #ccc;
border-radius: 5px;
animation: skeleton-line 1.5s infinite;
}

@keyframes skeleton-line {
0% {
background-position: left;
}
100% {
background-position: right;
}
}

.skeleton-grid {
display: grid;
grid-template-columns: repeat(4, 1fr); /* Adjust the number of columns as needed */
grid-gap: 20px;
padding: 20px;
}

/* Skeleton Text */
.skeleton-card-text {
width: 80%;
height: 20px;
background-color: #ddd;
border-radius: 4px;
position: relative;
overflow: hidden;
margin: 0;
color: #36454F;
font-weight: 500;
padding: 5px;
}

/* Animation to make skeleton "run" (pulse effect) */
.skeleton-image::before,
.skeleton-card-description::before {
content: '';
position: absolute;
top: 0;
left: -100%;
width: 200%;
height: 100%;
background: linear-gradient(
to right,
rgba(255, 255, 255, 0) 0%,
rgba(255, 255, 255, 0.5) 50%,
rgba(255, 255, 255, 0) 100%
);
animation: loading 2.0s infinite;
}

/* Keyframes for pulsing animation */
@keyframes loading {
0% {
left: -100%;
}
50% {
left: 0;
}
100% {
left: 100%;
}
}

.ehsaandraw {
font-family: 'Cascadia', sans-serif;
font-size: 24px;
}
4 changes: 1 addition & 3 deletions src/component/CardList/CardList.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
import React from "react";
import EhsaanDrawPicture from "../../assets/EhsaanDrawPicture.png";
import { Trash2 } from "lucide-react";
import ExcaliDrawCard from "../ExcalidrawCard/ExcaliDrawCard";

const CardList = ({ values, handleDelete, handleEdit, id }) => {

return (
<div
style={{
Expand Down Expand Up @@ -56,7 +55,6 @@ const CardList = ({ values, handleDelete, handleEdit, id }) => {
padding: "20px",
}}
>
<ExcaliDrawCard key={item.id} sceneData={item.scenes1} />
<img
src={EhsaanDrawPicture}
style={{
Expand Down
25 changes: 0 additions & 25 deletions src/component/ExcalidrawCard/ExcaliDrawCard.js

This file was deleted.

16 changes: 4 additions & 12 deletions src/component/MainScreen/MainScreen.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,8 @@ import EditPage from "../Edit Page/EditScreen";
import { useGithub } from "../../context";
import toast from "react-hot-toast";
import { SquarePlus } from "lucide-react";
import SkeletonGrid from "../Skeleton/Skeleton";


import '../../App.css'

const MainApplication = () => {
const [isLoading, setIsLoading] = useState(false);
const [open, setOpen] = useState(false);
const [userName, setUserName] = useState("");
const [scenes, setScenes] = useState([]);
Expand Down Expand Up @@ -55,14 +50,12 @@ const MainApplication = () => {

useEffect(() => {
const getData = async () => {
setIsLoading(true);
const appdataRef = collection(database, "users", `${githubId}/scenes`);
const docSnap = await getDocs(appdataRef);
const fetchedValues = docSnap.docs.map((doc) => ({
...doc.data(),
id: doc.id,
}));
setIsLoading(false);
setValues(fetchedValues);
setFilteredValues(fetchedValues); // Initialize filtered data
};
Expand Down Expand Up @@ -123,18 +116,18 @@ const MainApplication = () => {
color: "#fff",
}}
>
<h1 class = "ehsaandraw"
<h1
style={{
marginLeft: "70px",
color: "#000", // Set text color to white for a dark background
// textShadow: "2px 2px 8px #444", // Subtle shadow effect for better readability
textShadow: "2px 2px 8px #444", // Subtle shadow effect for better readability
fontSize: "3rem", // Increase text size for emphasis
fontWeight: "bold", // Bold font for better visibility
letterSpacing: "2px", // Adds spacing between letters for a clean look
margin:0
}}
>
EhsaanDraw
Ehsaan Draw
</h1>
</div>
<div
Expand Down Expand Up @@ -337,14 +330,13 @@ const MainApplication = () => {
marginLeft: "10px",
}}
>
{isLoading ? <SkeletonGrid /> :
<CardList
id={id}
values={filteredValues}
handleDelete={handleDelete}
handleEdit={handleEdit}
scenes={scenes}
/> }
/>
</div>
</div>
);
Expand Down
26 changes: 0 additions & 26 deletions src/component/Skeleton/Skeleton.js

This file was deleted.