aboutsummaryrefslogtreecommitdiff
path: root/src/frontend/app/components/Stops/ConsolidatedCirculationListSkeleton.tsx
blob: c99b88367d9c461dbe8d8907ad97fc9f582f97b5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
import React from "react";
import Skeleton, { SkeletonTheme } from "react-loading-skeleton";
import "react-loading-skeleton/dist/skeleton.css";
import "./ConsolidatedCirculationList.css";

export const ConsolidatedCirculationListSkeleton: React.FC = () => {
  return (
    <SkeletonTheme
      baseColor="var(--skeleton-base)"
      highlightColor="var(--skeleton-highlight)"
    >
      <>
        <div className="consolidated-circulation-caption">
          <Skeleton width="60%" style={{ maxWidth: "300px" }} />
        </div>

        {[1, 2, 3, 4, 5].map((i) => (
          <div
            key={i}
            className="consolidated-circulation-card"
            style={{ marginBottom: "0.75rem" }}
          >
            <div className="card-row main">
              <div className="line-info">
                <Skeleton width={40} height={28} borderRadius={4} />
              </div>

              <div className="route-info">
                <Skeleton width="80%" height={18} />
              </div>

              <div className="eta-badge">
                <Skeleton width={50} height={40} borderRadius={12} />
              </div>
            </div>

            <div className="card-row meta">
              <Skeleton width={90} height={20} borderRadius={999} />
              <Skeleton width={70} height={20} borderRadius={999} />
              <Skeleton width={60} height={20} borderRadius={999} />
            </div>
          </div>
        ))}
      </>
    </SkeletonTheme>
  );
};