Giter VIP home page Giter VIP logo

ordinals-explorer's Introduction

Hiro Ordinals Explorer

โžก๏ธ https://ordinals.hiro.so ๐ŸŒ

Ordinals Explorer

Overview

The Ordinals Explorer is a Next.js (app router) project that uses the Hiro Ordinals API.

There are two main parts of this project:

  • The explorer app/(explorer) โ€” A frontend for exploring ordinal inscriptions
  • The preview API app/(preview) โ€” An endpoint to render a specific ordinal inscription

Development

cp .env.sample .env.local
npm install
npm run dev

Open http://localhost:3000 with your browser to see the result.

Bugs and feature requests

If you encounter a bug or have a feature request, we encourage you to follow the steps below:

  1. Search for existing issues: Before submitting a new issue, please search existing and closed issues to check if a similar problem or feature request has already been reported.
  2. Open a new issue: If it hasn't been addressed, please open a new issue. Choose the appropriate issue template and provide as much detail as possible, including steps to reproduce the bug or a clear description of the requested feature.
  3. Evaluation SLA: Our team reads and evaluates all the issues and pull requests. We are avaliable Monday to Friday and we make a best effort to respond within 7 business days.

Please do not use the issue tracker for personal support requests or to ask for the status of a transaction. You'll find help at the #support Discord channel.

Contribute

Development of this product happens in the open on GitHub, and we are grateful to the community for contributing bugfixes and improvements. Read below to learn how you can take part in improving the product.

Code of Conduct

Please read our Code of conduct since we expect project participants to adhere to it.

Contributing Guide

Read our contributing guide to learn about our development process, how to propose bugfixes and improvements, and how to build and test your changes.

Community

Join our community and stay connected with the latest updates and discussions:

ordinals-explorer's People

Contributors

hugocaillard avatar janniks avatar kyranjamie avatar lgalabru avatar smcclellan avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

ordinals-explorer's Issues

Hiro Ordinals API mime type query param documentation and implementation mismatch

Describe the bug
Documentation states mime_type query param for /inscriptions endpoint is array of mime types, which produces 400 Bad Request error: querystring/mime_type/0 must match pattern \"^\\w+\\/[-.\\w]+(?:\\+[-.\\w]+)?$\"

To Reproduce
Steps to reproduce the behavior:

  1. Go to https://docs.hiro.so/ordinals/list-of-inscriptions
  2. Click on 'Show optional parameters' on the right
  3. Scroll down to 'mime_type -- query' and click on 'Add item'
  4. Add two valid mime types, such as image/jpeg and image/png
  5. Scroll down and click execute. See error response
{
  "statusCode": 400,
  "error": "Bad Request",
  "message": "querystring/mime_type/0 must match pattern \"^\\w+\\/[-.\\w]+(?:\\+[-.\\w]+)?$\""
}

Expected behavior
Return 200 success

Screenshots
If applicable, add screenshots or consol.log to help explain your problem.
Screenshot 2023-11-11 203343

Desktop (please complete the following information):

  • OS: Windows 11
  • Browser Opera (Chromium)
  • Version 104.0.4944.36

use iframes only for content types that are not media

Could we only use iframes when displaying content that is not image/*, video/*, audio/* or text/plain? This would make the explorer much faster.

There could still be attacks from payloads that masquerade as "safe" media, so we should probably put this out for discussion.

Ordinal explorer: "Coinbase height" is poorly understood add explainer

image

Is your feature request related to a problem? Please describe.
Many users do not know that "coinbase" means "block reward". They may wonder what coinbase.com (the centralized exchange) has to do with the inscription ๐Ÿ˜„.

Describe the solution you'd like
In this case I think "Coinbase block height" would be more descriptive . Additionally it could be helpful to have a little "i" or "?" to explain that it is the the block reward that created the inscribed sat.

Describe alternatives you've considered
You could just show "block" but then there could be confusion about "what block". The block the sat was inscribed or the sats birthblock? In this case it is about its birth.

Additional context
image

This is how it is displayed on an other explorer.

Improve text inscriptions

Improve textual/json rendering: add some smart logic to render text more readable, centered, no-breaks, etc.

  • Improve long text snippets
  • Improve text size if cutoff

Only a portion of ordinals displayed for a wallet address, all 73 expected.

Describe the bug
Only 8 ordinals returned of the 73 on an address. Is this related to an indexing error?

Transaction ID n.a.
Address bc1p04vqcelrdtm8kjp23redj9h073n7mp778tx03pe3sh2tzsw9gyys63q34t
Block# n.a.
Time stamp n.a.

To Reproduce
The user noticed their Leather doesn't show all the inscriptions which is also apparent from the ordinals explorer: https://ordinals.hiro.so/address/bc1p04vqcelrdtm8kjp23redj9h073n7mp778tx03pe3sh2tzsw9gyys63q34t (8 ordinal inscriptions displayed).

When compared to:

https://www.ord.io/bc1p04vqcelrdtm8kjp23redj9h073n7mp778tx03pe3sh2tzsw9gyys63q34t (73 inscriptions shown)

Expected behavior
We expect all 73 inscriptions to be displayed.

Screenshots
Hiro explorer
image

Ord
image

Open repo publicly

So folks in the wider community can file issues and see the source code (which they'd appreciate given the Bitcoin ethos!)

Support for Advanced Search i.e. "Crying Robot"

Our search is limited to specifics of an inscription vs a description of the inscription itself. Providing an advanced 'human readable' search would help people find the content they're looking for more easily.

Tradeoff appears to be technical difficulty i.e. providing meta-tag representations of each ordinal.

Reduce iframe usage

Remove iframes for "safe" content-types: reduces total API requests; this could be released as a component for frontends to use, e.g. wallets, marketplaces

Display the date and time of Satoshi generation in Ordinals Explorer.

Feature requests are not requests for improvements to a problem, but suggestions for building a better UX.

I always have a hard time finding something worthwhile from a lot of Ordinals.
The valuable thing, in my case, is which satoshi are Inscribed.
More specifically, I want to find Ordinals that are tied to old satoshi.

Main point of the request
Is it possible to use Hiro's Ordinals Explorer to display the generation date and time of the Satoshi that the Digital Artifact is tied to?

Alternatives
Currently, I have to research on Ordinals.com from the ID, but Hiro's Ordinals Explorer is all uppercase, so it doesn't hit the search. my request can be replaced by correcting the ID to its original mixed-case string. I am not sure how to do this. However, the user experience would be slightly impaired by having to search and look it up.

Additional context
image

Traffic acquisition / redirection

Context

Some developers forked this explorer and deployed it to https:// ordinalscan net.
Beside a few CSS adjustments, the only feature that I see, that could have been motivating this move, is this Trade button
Screenshot 2023-09-20 at 12 09 40

redirecting traffic to partners.

Hypothesis

If we had a similar button, that would be set dynamically, do we think that it would be easier to conduct partnership with other actors in the ecosystem?
Our goal with this product is to build a very good explorer, and we very probably won't cross the line, and add features that would turn this product into a marketplace.
Clear boundaries are defined, we focus on exploration, and we let marketplaces do what they do best, and focus on the trading experience.

Feature

When the explorer is opened using a URL that looks like https://ordinals.hiro.so/?redirect_url=https://unisat.io/inscription&name=Unisat (or so) then on the inscriptions pages we display a call to action button "Open on Unisat".
With that, partners are redirecting their users when they want them to browse, and know that they will be back for trading on their website.

Hiro Explorer is missing additional inscriptions on satoshi ordinal page

Describe the bug
On https://ordinals.hiro.so/sat/1446791433368094 it only displays one inscription for this sat. However, there should be two since this API call returns two https://api.hiro.so/ordinals/v1/sats/1446791433368094/inscriptions

Transaction ID
a1c934dd35d5a3abeeba21ac026997e6eb9a0205a173ae32a999fc5b0818d66a

Address
bc1pgu7lvmsnw037v6g4693quckk8asz7mdh3rac4laftxzpv5e039uqc4h8qj

Block#
777530

Time stamp
FEBRUARY 20, 2023 AT 2:15:27 PM

To Reproduce
Steps to reproduce the behavior:

  1. Go to https://ordinals.hiro.so/sat/1446791433368094

Expected behavior
It should display two inscriptions but it's only showing one.

Support for /content/[inscriptionId]

Inscriptions specifically HTML ones might utilize and might be intended to be viewed at the /content route in the ordinal explorer. This allows for viewing the inscription as a full HTML page. The route is part of the ordinal protocol and to fully support all html inscriptions you need to have this API route.

Lets take for example this HTML inscription I inscribed as an example for this issue. This inscription navigates to another inscription in this case the first inscribed Bitcoin Whitepaper. This recursion and navigation is fully supported in the ord explorer 0.5.1

https://ordinals.com/content/e0e10f332c1410151388c99b7b657be34839b4d01ff008f43e22623f55218f2di0

This also works in the ord explorer under the /inscription/[inscriptionId] route. You can open up the PDF inside the inscription by clicking the button.

https://ordinals.com/inscription/e0e10f332c1410151388c99b7b657be34839b4d01ff008f43e22623f55218f2di0

However this inscription is currently broken on your explorer under the same route because /content/[inscriptionId] has not been implemented as a route in your domain.

You can see here when the button is pressed to open the whitepaper you get a 404.

https://ordinals.hiro.so/inscription/e0e10f332c1410151388c99b7b657be34839b4d01ff008f43e22623f55218f2di0

HTML for example inscription:

<!DOCTYPE html>
<html>
  <head>
    <title>Navigate to WhitePaper</title>
  </head>
  <body
    style="
      display: flex;
      align-items: center;
      justify-content: center;
      height: 100vh;
      margin: 0;
      padding: 0;
    "
  >
    <button
      onclick="window.location.href='/content/85b10531435304cbe47d268106b58b57a4416c76573d4b50fa544432597ad670i0'"
    >
      Goto Bitcoin WhitePaper
    </button>
  </body>
</html>

Refine loading spinner

  • research some design ideas to make it more on brand
  • add delay to only show if loading is over x ms

Experiment with infinite scroll in Explorer

Right now, users have to click on 'Next' in order to view the next page of inscriptions. By testing an infinite scroll, we can help users browse inscriptions without interruption.

Tradeoff is the footer may become difficult to reach, and we lose the option of having different sections on the homepage.

Add tooltips

  • add tooltips to fields on sat page & inscription page
  • add tooltips to filters

BRC-20 Display in the Ordinals Explorer

User stories:

  • I want to view a full or partial list of BRC-20 tokens
  • I want to understand the time a BRC-20 token was deployed
  • I want to understand the total supply of a BRC-20 token
  • I want to understand the number of BRC-20 tokens minted (against supply)
  • I want to search for BRC-20 tokens by name

Nice to have additions:

  • #90
  • I want to understand the time a BRC-20 token was completed
  • I want to understand if a BRC-20-syntax inscription is valid BRC-20

Rewrite og:image

Better og:image: add renders for any content type to og:image

Add npm ordinals helpers

Add helper methods and libraries: take some of our helper methods from the backend/frontend and package them into an e.g. @ordinals/common package

Add BRC-20 specific features

The latest inscriptions are dominated by them but there's no way to parse through the data (e.g. how many of each ticker is getting minted per day, by how many addresses, etc...there are lots of possibilities).

The creator of BRC-20, Domo, asked in a chat if we were working on explorer-related enhancements, so he could provide ideas as well (though we'll need to open source this repo to make that easy?).

A starting point could be UniSat's page here: https://unisat.io/brc20

Screenshot 2023-05-28 at 21 53 21

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.