Git Product home page Git Product logo

ibc-visualizer's Issues

Handle connection errors

Right now if no chain is running the app just displays a black screen to the user. Let's catch connection errors and inform the user they need to make a chain available at the relevant location.

Display data in tables

Whenever we have a group of data, it would be nice to show it in a table to make the information reasier to process.

Example to show the idea:

Bildschirmfoto 2020-11-30 um 10 58 36

We don't need the borders, just the table layout.

Show title/height when list of connections is empty

In the code

      <div>
        {connectionsResponse?.connections?.length ? (
          <>
            <span className={style.title}>Connections / client</span>
            <HeightData height={connectionsResponse.height} />
            <div>
              {clientIds.map((clientId) => (
                <div key={clientId} className="flex flex-col items-start">
                  <div className={style.subtitle}>Client {clientId}</div>
                  {connectionsResponse.connections?.map((connection) => (
                    <Link
                      to={`${pathConnections}/${connection.id}`}
                      key={connection.id}
                      className={`${style.button} mt-2 block`}
                    >
                      Connection {ellideMiddle(connection.id ?? "–", 20)}
                    </Link>
                  ))}
                </div>
              ))}
            </div>
            {connectionsResponse.pagination?.nextKey?.length ? (
              <button onClick={loadMoreConnections}>Load more</button>
            ) : null}
          </>
        ) : (
          <span>No connections found</span>
        )}
      </div>

the title and height is not shown when the list of connections is empty. I think we need two checks here

  • If connectionsResponse is set: show title, height and list (elements or "No connections found").
  • If connectionsResponse is not set: show text "Loading data …"

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.