diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml index 2c027dc87f..706da5d138 100644 --- a/.github/FUNDING.yml +++ b/.github/FUNDING.yml @@ -1,5 +1,5 @@ # These are supported funding model platforms -# github: liangping +github: ping-pub issuehunt: ping-pub # Replace with a single IssueHunt username diff --git a/.github/workflows/config-check.yaml b/.github/workflows/config-check.yaml new file mode 100644 index 0000000000..a9bad362ac --- /dev/null +++ b/.github/workflows/config-check.yaml @@ -0,0 +1,21 @@ + +name: Config Checker + +on: + # push: + # branches: [ master ] + pull_request: + # branches: [ master ] + paths: + - 'chains/mainnet/**' + - 'chains/testnet/**' + +jobs: + deploy: + name: Check Blockchain Config + runs-on: ubuntu-latest + steps: + - name: Git Checkout Latest + uses: actions/checkout@v3 + - name: Check Chain Configs + uses: ping-pub/ping-dashboard-config-checker@v1.0 \ No newline at end of file diff --git a/.github/workflows/docker.yaml b/.github/workflows/docker.yaml index 10a87f84d5..ce1e3034b7 100644 --- a/.github/workflows/docker.yaml +++ b/.github/workflows/docker.yaml @@ -1,32 +1,51 @@ -name: Build docker image +name: docker on: push: - tags: - - "*" + branches: + - 'master-backup' jobs: docker: runs-on: ubuntu-latest steps: - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v1 - - - name: Login to GitHub Container Registry + - name: Checkout + uses: actions/checkout@v2 +# - +# name: Set up QEMU +# uses: docker/setup-qemu-action@v1 +# - +# name: Set up Docker Buildx +# uses: docker/setup-buildx-action@v1 + - name: Install + run: yarn install + - name: Build + run: yarn run vue-cli-service build + - name: Login to DockerHub uses: docker/login-action@v1 with: - registry: ghcr.io - username: ${{ github.repository_owner }} - password: ${{ secrets.GITHUB_TOKEN }} - - - name: Get version - id: get_version - uses: battila7/get-version-action@v2 - + username: ${{ secrets.DOCKERHUB_USERNAME }} + password: ${{ secrets.DOCKERHUB_TOKEN }} + - name: Docker meta + id: meta + uses: docker/metadata-action@v3 + with: + # list of Docker images to use as base name for tags + images: | + yaoling/wallet + # generate Docker tags based on the following events/attributes + tags: | + type=sha + type=schedule + type=ref,event=branch + type=ref,event=pr + type=semver,pattern={{version}} + type=semver,pattern={{major}}.{{minor}} + type=semver,pattern={{major}} - name: Build and push - id: docker_build uses: docker/build-push-action@v2 with: - push: true - platforms: linux/amd64 - tags: ghcr.io/nibiruchain/explorer:latest,ghcr.io/nibiruchain/explorer:${{ steps.get_version.outputs.version-without-v }} \ No newline at end of file + context: . + push: ${{ github.event_name != 'pull_request' }} + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} \ No newline at end of file diff --git a/.github/workflows/mainnet-deploy.yaml.disabled b/.github/workflows/mainnet-deploy.yaml.disabled new file mode 100644 index 0000000000..0b69f65c88 --- /dev/null +++ b/.github/workflows/mainnet-deploy.yaml.disabled @@ -0,0 +1,28 @@ + +name: Deploy to ping.pub + +on: + push: + branches: [ master2 ] + # pull_request: + # branches: [ master ] + +jobs: + deploy: + name: Ping deploy + runs-on: mainnet + steps: + - name: Environment + run: export NODE_OPTIONS="--max_old_space_size=4096" + + - name: Git Checkout Latest + uses: actions/checkout@v3 + + - name: Install + run: yarn install --ignore-engines + + - name: Build + run: yarn build + + - name: Deploy + run: cp -rf ./dist/* /var/www/html/ \ No newline at end of file diff --git a/.github/workflows/testnet-deploy.yaml b/.github/workflows/testnet-deploy.yaml new file mode 100644 index 0000000000..55391d0122 --- /dev/null +++ b/.github/workflows/testnet-deploy.yaml @@ -0,0 +1,27 @@ + +name: Testnet Deploy + +on: + push: + branches: [ testnet ] + pull_request: + branches: [ testnet ] + +jobs: + deploy: + name: Ping deploy + runs-on: testnet + steps: + - name: print + run: echo ${GITHUB_REF#refs/heads/} + - name: Git Checkout Latest + uses: actions/checkout@v2 + + - name: Install + run: yarn install + + - name: Build + run: yarn run vue-cli-service build + + - name: Deploy + run: cp -rf ./dist/* /var/www/html/ \ No newline at end of file diff --git a/README.md b/README.md index 342d5900e3..925638dae5 100644 --- a/README.md +++ b/README.md @@ -2,39 +2,40 @@ ![Ping Wallet](./public/logo.svg) -

Ping Dashboard

+

Nibiru Explorer

-**Ping Dashboard is not only an explorer but also a wallet and more ... 🛠** +**Nibiru Explorer is not only an explorer but also a wallet and more ... 🛠** [![version](https://img.shields.io/github/tag/ping-pub/explorer.svg)](https://github.com/ping-pub/explorer/releases/latest) [![GitHub](https://img.shields.io/github/license/ping-pub/explorer.svg)](https://github.com/ping-pub/explorer/blob/master/LICENSE) [![Twitter URL](https://img.shields.io/twitter/url/https/twitter.com/bukotsunikki.svg?style=social&label=Follow%20%40ping_pub)](https://twitter.com/ping_pub) [![https://discord.gg/CmjYVSr6GW](https://img.shields.io/badge/discord-join-7289DA.svg?logo=discord&longCache=true&style=flat)](https://discord.gg/CmjYVSr6GW) - -`Ping Dashboard` is a light explorer for Cosmos-based Blockchains. https://ping.pub . +`Nibiru Explorer` is a light explorer for Cosmos-based Blockchains. https://ping.pub . + +## What sets Nibiru Explorer apart from other explorers? -## What sets Ping Dashboard apart from other explorers? -**Ping Dashboard** stands out by providing a real-time exploration of blockchain data without relying on caching or pre-processing. It exclusively fetches data from the Cosmos full node via LCD/RPC endpoints, ensuring a truly authentic experience. This approach is referred to as the "Light Explorer." +**Nibiru Explorer** stands out by providing a real-time exploration of blockchain data without relying on caching or pre-processing. It exclusively fetches data from the Cosmos full node via LCD/RPC endpoints, ensuring a truly authentic experience. This approach is referred to as the "Light Explorer." ## Are you interested in listing your blockchain on https://ping.pub? To make this repository clean, please submit your request to https://github.com/ping-pub/ping.pub.git +## Why does Nibiru Explorer rely on official/trusted third-party public LCD/RPC servers? -## Why does Ping Dashboard rely on official/trusted third-party public LCD/RPC servers? There are two primary reasons for this choice: - - Trust: In a decentralized system, it is crucial to avoid relying solely on a single entity. By utilizing official/trusted third-party public LCD/RPC servers, Ping Dashboard ensures that the data is sourced from a network of trusted participants. - - Limited Resources: As Ping Dashboard plans to list hundreds of Cosmos-based blockchains in the future, it is impractical for the Ping team to operate validators or full nodes for all of them. Leveraging trusted third-party servers allows for more efficient resource allocation. +- Trust: In a decentralized system, it is crucial to avoid relying solely on a single entity. By utilizing official/trusted third-party public LCD/RPC servers, Nibiru Explorer ensures that the data is sourced from a network of trusted participants. +- Limited Resources: As Nibiru Explorer plans to list hundreds of Cosmos-based blockchains in the future, it is impractical for the Ping team to operate validators or full nodes for all of them. Leveraging trusted third-party servers allows for more efficient resource allocation. ## Donation Your donation will help us make better products. Thanks in advance. - - Address for ERC20: USDC, USDT, ETH +- Address for ERC20: USDC, USDT, ETH + ``` 0x88BFec573Dd3E4b7d2E6BfD4D0D6B11F843F8aa1 ``` @@ -49,8 +50,6 @@ Your donation will help us make better products. Thanks in advance. You can hire us by submiting an issue and fund the issue on [IssueHunter](https://issuehunt.io/r/ping-pub/explorer) - ## Contributors Developers: @liangping @dingyiming - diff --git a/chains/mainnet/cosmos.json b/chains/mainnet/cosmos.json deleted file mode 100644 index 286d73895e..0000000000 --- a/chains/mainnet/cosmos.json +++ /dev/null @@ -1,54 +0,0 @@ -{ - "chain_name": "cosmos", - "registry_name": "cosmoshub", - "api": [ - { - "provider": "notional", - "address": "https://api-cosmoshub-ia.cosmosia.notional.ventures" - }, - { - "provider": "blockapsis", - "address": "https://lcd-cosmoshub.blockapsis.com:443" - }, - { - "provider": "WhisperNode🤐", - "address": "https://lcd-cosmoshub.whispernode.com:443" - }, - { "provider": "pupmos", "address": "https://api-cosmoshub.pupmos.network" }, - { - "provider": "publicnode", - "address": "https://cosmos-rest.publicnode.com" - }, - { "provider": "staketab", "address": "https://cosmos-rest.staketab.org" }, - { "provider": "nodestake", "address": "https://api.cosmos.nodestake.top" }, - { - "provider": "Golden Ratio Staking", - "address": "https://rest-cosmoshub.goldenratiostaking.net" - } - ], - "rpc": [ - { "provider": "icycro", "address": "https://cosmos-rpc.icycro.org" }, - { - "provider": "dragonstake", - "address": "https://rpc.cosmos.dragonstake.io" - }, - { - "provider": "Golden Ratio Staking", - "address": "https://rpc-cosmoshub.goldenratiostaking.net" - } - ], - "sdk_version": "0.45.1", - "coin_type": "118", - "min_tx_fee": "800", - "addr_prefix": "cosmos", - "logo": "/logos/cosmos.svg", - "assets": [ - { - "base": "uatom", - "symbol": "ATOM", - "exponent": "6", - "coingecko_id": "cosmos", - "logo": "/logos/cosmos.svg" - } - ] -} diff --git a/chains/mainnet/nibiru.json b/chains/mainnet/nibiru.json new file mode 100644 index 0000000000..f25d99d070 --- /dev/null +++ b/chains/mainnet/nibiru.json @@ -0,0 +1,31 @@ +{ + "chain_name": "nibiru", + "registry_name": "cataclysm-1", + "api": [ + { + "address": "https://lcd.nibiru.fi", + "provider": "Nibiru Foundation" + } + ], + "rpc": [ + { + "address": "https://rpc.nibiru.fi", + "provider": "Nibiru Foundation" + } + ], + "sdk_version": "0.45.5", + "coin_type": "118", + "min_tx_fee": "2500", + "addr_prefix": "nibi", + "logo": "/logos/nibiru.png", + "theme_color": "#F294C0", + "assets": [ + { + "base": "unibi", + "symbol": "NIBI", + "exponent": "6", + "coingecko_id": "nibiru", + "logo": "/logos/nibiru.png" + } + ] +} diff --git a/chains/mainnet/nibirudevnet.json b/chains/mainnet/nibirudevnet.json new file mode 100644 index 0000000000..dd29a63538 --- /dev/null +++ b/chains/mainnet/nibirudevnet.json @@ -0,0 +1,31 @@ +{ + "chain_name": "nibirudevnet", + "registry_name": "nibiru-devnet1", + "api": [ + { + "address": "https://lcd.devnet-1.nibiru.fi", + "provider": "Nibiru Foundation" + } + ], + "rpc": [ + { + "address": "https://rpc.devnet-1.nibiru.fi", + "provider": "Nibiru Foundation" + } + ], + "sdk_version": "0.45.5", + "coin_type": "118", + "min_tx_fee": "2500", + "addr_prefix": "nibi", + "logo": "/logos/nibiru.png", + "theme_color": "#F294C0", + "assets": [ + { + "base": "unibi", + "symbol": "NIBI", + "exponent": "6", + "coingecko_id": "nibiru", + "logo": "/logos/nibiru.png" + } + ] +} diff --git a/chains/mainnet/nibirudevnet2.json b/chains/mainnet/nibirudevnet2.json new file mode 100644 index 0000000000..0a34fb70e3 --- /dev/null +++ b/chains/mainnet/nibirudevnet2.json @@ -0,0 +1,31 @@ +{ + "chain_name": "nibirudevnet2", + "registry_name": "nibiru-devnet2", + "api": [ + { + "address": "https://lcd.devnet-2.nibiru.fi", + "provider": "Nibiru Foundation" + } + ], + "rpc": [ + { + "address": "https://rpc.devnet-2.nibiru.fi", + "provider": "Nibiru Foundation" + } + ], + "sdk_version": "0.45.5", + "coin_type": "118", + "min_tx_fee": "2500", + "addr_prefix": "nibi", + "logo": "/logos/nibiru.png", + "theme_color": "#F294C0", + "assets": [ + { + "base": "unibi", + "symbol": "NIBI", + "exponent": "6", + "coingecko_id": "nibiru", + "logo": "/logos/nibiru.png" + } + ] +} diff --git a/chains/mainnet/nibirutestnet.json b/chains/mainnet/nibirutestnet.json new file mode 100644 index 0000000000..36711a34c0 --- /dev/null +++ b/chains/mainnet/nibirutestnet.json @@ -0,0 +1,31 @@ +{ + "chain_name": "nibirutestnet1", + "registry_name": "nibiru-testnet1", + "api": [ + { + "address": "https://lcd.testnet-1.nibiru.fi", + "provider": "Nibiru Foundation" + } + ], + "rpc": [ + { + "address": "https://rpc.testnet-1.nibiru.fi", + "provider": "Nibiru Foundation" + } + ], + "sdk_version": "0.45.5", + "coin_type": "118", + "min_tx_fee": "2500", + "addr_prefix": "nibi", + "logo": "/logos/nibiru.png", + "theme_color": "#F294C0", + "assets": [ + { + "base": "unibi", + "symbol": "NIBI", + "exponent": "6", + "coingecko_id": "nibiru", + "logo": "/logos/nibiru.png" + } + ] +} diff --git a/chains/mainnet/nibirutestnet2.json b/chains/mainnet/nibirutestnet2.json new file mode 100644 index 0000000000..a3ddfdf2dc --- /dev/null +++ b/chains/mainnet/nibirutestnet2.json @@ -0,0 +1,31 @@ +{ + "chain_name": "nibirutestnet2", + "registry_name": "nibiru-testnet2", + "api": [ + { + "address": "https://lcd.testnet-2.nibiru.fi", + "provider": "Nibiru Foundation" + } + ], + "rpc": [ + { + "address": "https://rpc.testnet-2.nibiru.fi", + "provider": "Nibiru Foundation" + } + ], + "sdk_version": "0.45.5", + "coin_type": "118", + "min_tx_fee": "2500", + "addr_prefix": "nibi", + "logo": "/logos/nibiru.png", + "theme_color": "#F294C0", + "assets": [ + { + "base": "unibi", + "symbol": "NIBI", + "exponent": "6", + "coingecko_id": "nibiru", + "logo": "/logos/nibiru.png" + } + ] +} diff --git a/chains/mainnet/osmosis.json b/chains/mainnet/osmosis.json deleted file mode 100644 index cbf7cbe5f4..0000000000 --- a/chains/mainnet/osmosis.json +++ /dev/null @@ -1,47 +0,0 @@ -{ - "chain_name": "osmosis", - "coingecko": "osmosis", - "api": [ - "https://lcd.osmosis.zone", - "https://api-osmosis-ia.cosmosia.notional.ventures", - "https://osmosis-api.polkachu.com", - "https://lcd-osmosis.blockapsis.com" - ], - "rpc": [ - "https://rpc.osmosis.zone", - "https://rpc-osmosis-ia.cosmosia.notional.ventures:443", - "https://osmosis-rpc.polkachu.com:443", - "https://osmosis.validator.network:443", - "https://rpc-osmosis.blockapsis.com:443" - ], - "snapshot_provider": "", - "sdk_version": "0.46.1", - "coin_type": "118", - "min_tx_fee": "800", - "addr_prefix": "osmo", - "logo": "/logos/osmosis.svg", - "theme_color": "#812cd6", - "assets": [ - { - "base": "uosmo", - "symbol": "OSMO", - "exponent": "6", - "coingecko_id": "osmosis", - "logo": "/logos/osmosis.svg" - }, - { - "base": "uion", - "symbol": "ION", - "exponent": "6", - "coingecko_id": "ion", - "logo": "/logos/osmosis.svg" - }, - { - "base": "usomm", - "symbol": "SOMM", - "exponent": "6", - "coingecko_id": "somm", - "logo": "" - } - ] -} diff --git a/env.d.ts b/env.d.ts index 11f02fe2a0..f18e837985 100644 --- a/env.d.ts +++ b/env.d.ts @@ -1 +1,3 @@ /// + +declare module '@personaxyz/ad-sdk'; \ No newline at end of file diff --git a/index.html b/index.html index 5f4e2cc711..9ad473d342 100644 --- a/index.html +++ b/index.html @@ -1,27 +1,20 @@ - - - + - Nibiru Dashboard + Nibiru Explorer + - @@ -35,12 +28,8 @@ > -
-
@@ -49,5 +38,9 @@
+ diff --git a/package.json b/package.json index 1f17d4ff6d..540de99b82 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,5 @@ { - "name": "ping.pub", + "name": "nibiru-explorer", "version": "3.0.0", "private": true, "target": "", @@ -13,13 +13,15 @@ }, "dependencies": { "@chenfengyuan/vue-countdown": "2", - "@cosmjs/crypto": "^0.29.5", - "@cosmjs/encoding": "^0.29.5", + "@cosmjs/crypto": "^0.32.3", + "@cosmjs/encoding": "^0.32.3", + "@cosmjs/stargate": "^0.32.3", "@iconify/vue": "^4.1.0", "@intlify/unplugin-vue-i18n": "^0.8.2", "@leapwallet/cosmos-snap-provider": "^0.1.20", "@leapwallet/name-matcha": "^1.1.0", "@osmonauts/lcd": "^0.8.0", + "@personaxyz/ad-sdk": "0.0.21", "@ping-pub/chain-registry-client": "^0.0.25", "@vitejs/plugin-vue-jsx": "^3.0.0", "@vueuse/core": "^9.12.0", @@ -63,6 +65,7 @@ "npm-run-all": "^4.1.5", "prettier": "^2.7.1", "sass": "^1.58.0", + "shiki": "^1.0.0-beta.0", "typescript": "~4.9.5", "unplugin-auto-import": "^0.13.0", "unplugin-vue-components": "^0.23.0", diff --git a/public/favicon.ico b/public/favicon.ico index 78586f5096..ef242a96ba 100644 Binary files a/public/favicon.ico and b/public/favicon.ico differ diff --git a/public/favicon.svg b/public/favicon.svg new file mode 100644 index 0000000000..346fc33d4d --- /dev/null +++ b/public/favicon.svg @@ -0,0 +1,31 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/loader.css b/public/loader.css index df91cafc48..c3a9a13462 100644 --- a/public/loader.css +++ b/public/loader.css @@ -4,14 +4,8 @@ .loading-logo { position: absolute; - inset-block-start: 25%; - inset-inline-start: calc(50% - 500px); -} - -@media only screen and (max-width: 480px) and (orientation: portrait) { - .loading-logo { - display: none; - } + inset-block-start: 40%; + inset-inline-start: calc(50% - 75px); } .pre-loading { diff --git a/public/logo.svg b/public/logo.svg index 272f464cb3..a620f52a3e 100644 --- a/public/logo.svg +++ b/public/logo.svg @@ -1,213 +1,82 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + diff --git a/public/logos/side.jpeg b/public/logos/side.jpeg deleted file mode 100644 index edd46d282a..0000000000 Binary files a/public/logos/side.jpeg and /dev/null differ diff --git a/public/widget-test.html b/public/widget-test.html deleted file mode 100644 index cbe6515e6a..0000000000 --- a/public/widget-test.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - Widget Test - - - -
-
- -
-
- - -
-
- - diff --git a/src/assets/images/welldone-logo.svg b/src/assets/images/welldone-logo.svg new file mode 100644 index 0000000000..915c31be43 --- /dev/null +++ b/src/assets/images/welldone-logo.svg @@ -0,0 +1,17 @@ + + + + + + + + + + + + + + + + + diff --git a/src/assets/logo.svg b/src/assets/logo.svg index 272f464cb3..a620f52a3e 100644 --- a/src/assets/logo.svg +++ b/src/assets/logo.svg @@ -1,213 +1,82 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + diff --git a/src/components/ChainSummary.vue b/src/components/ChainSummary.vue index d7f728f25e..53edb036be 100644 --- a/src/components/ChainSummary.vue +++ b/src/components/ChainSummary.vue @@ -30,7 +30,7 @@ const addFavor = (e: Event) => { class="bg-base-100 hover:bg-gray-100 dark:hover:bg-[#373f59] rounded shadow flex items-center px-3 py-3 cursor-pointer" >
- conf logo +
{{ conf?.prettyName || props.name }} diff --git a/src/components/ProposalListItem.vue b/src/components/ProposalListItem.vue index edef554f32..98b521064e 100644 --- a/src/components/ProposalListItem.vue +++ b/src/components/ProposalListItem.vue @@ -9,7 +9,7 @@ import { select } from '@/components/dynamic/index'; import type { PaginatedProposals } from '@/types'; import ProposalProcess from './ProposalProcess.vue'; import type { PropType } from 'vue'; -import { ref } from 'vue'; +import { computed, ref } from 'vue'; const dialog = useTxDialog(); defineProps({ proposals: { type: Object as PropType }, @@ -38,12 +38,15 @@ const voterStatusMap: Record = { }; const proposalInfo = ref(); + +function metaItem(metadata: string|undefined): { title: string; summary: string } { + return metadata ? JSON.parse(metadata) : {} +} +