@@ -106,10 +110,10 @@ export const SimpleUDT = () => {
showReset={!!filter}
placeholder={t('udt.search_placeholder')}
onFilter={filter => {
- push(`/sudt/${typeHash}?${new URLSearchParams({ filter })}`)
+ push(`${udtLinkPrefix}/${typeHash}?${new URLSearchParams({ filter })}`)
}}
onReset={() => {
- push(`/sudt/${typeHash}`)
+ push(`${udtLinkPrefix}/${typeHash}`)
}}
/>
@@ -122,7 +126,7 @@ export const SimpleUDT = () => {
{filterList.map(f => (
{f.title}
@@ -141,7 +145,7 @@ export const SimpleUDT = () => {
{data => (
- {
onPageChange={setPage}
filterNoResult={filterNoResult}
id={typeHash}
+ isInscription={isInscription}
/>
)}
-
+
)
}
-export default SimpleUDT
+export default UDT
diff --git a/src/pages/SimpleUDT/state.ts b/src/pages/UDT/state.ts
similarity index 53%
rename from src/pages/SimpleUDT/state.ts
rename to src/pages/UDT/state.ts
index 89e1c867f..31bbb2fe5 100644
--- a/src/pages/SimpleUDT/state.ts
+++ b/src/pages/UDT/state.ts
@@ -1,4 +1,4 @@
-import { UDT } from '../../models/UDT'
+import { UDT, OmigaInscriptionCollection, MintStatus } from '../../models/UDT'
export const defaultUDTInfo: UDT = {
symbol: '',
@@ -18,4 +18,13 @@ export const defaultUDTInfo: UDT = {
codeHash: '',
hashType: '',
},
+ udtType: 'sudt',
+}
+
+export const defaultOmigaInscriptionInfo: OmigaInscriptionCollection = {
+ ...defaultUDTInfo,
+ mintStatus: MintStatus.Closed,
+ mintLimit: '0',
+ expectedSupply: '0',
+ inscriptionInfoId: '',
}
diff --git a/src/pages/SimpleUDT/styled.tsx b/src/pages/UDT/styled.tsx
similarity index 91%
rename from src/pages/SimpleUDT/styled.tsx
rename to src/pages/UDT/styled.tsx
index e8d0da257..b22efbeda 100644
--- a/src/pages/SimpleUDT/styled.tsx
+++ b/src/pages/UDT/styled.tsx
@@ -15,7 +15,7 @@ export const SUDTContentPanel = styled.div`
padding: 20px;
}
`
-export const SimpleUDTContentPanel = styled.div`
+export const UDTContentPanel = styled.div`
display: flex;
flex-direction: column;
align-items: center;
@@ -28,7 +28,7 @@ export const SimpleUDTContentPanel = styled.div`
}
`
-export const SimpleUDTPendingRewardTitlePanel = styled.div`
+export const UDTPendingRewardTitlePanel = styled.div`
display: flex;
flex-direction: row;
@@ -54,7 +54,7 @@ export const SimpleUDTPendingRewardTitlePanel = styled.div`
}
`
-export const SimpleUDTLockScriptController = styled.div`
+export const UDTLockScriptController = styled.div`
font-size: 16px;
font-weight: 600;
margin-top: 15px;
@@ -102,11 +102,11 @@ export const TypeScriptController = styled(SimpleButton)`
}
`
-export const SimpleUDTTransactionsPanel = styled.div`
+export const UDTTransactionsPanel = styled.div`
width: 100%;
`
-export const SimpleUDTTransactionsPagination = styled.div`
+export const UDTTransactionsPagination = styled.div`
margin-top: 4px;
width: 100%;
`
diff --git a/src/pages/SimpleUDT/styles.module.scss b/src/pages/UDT/styles.module.scss
similarity index 97%
rename from src/pages/SimpleUDT/styles.module.scss
rename to src/pages/UDT/styles.module.scss
index ef8eb0d61..3c9a02ff8 100644
--- a/src/pages/SimpleUDT/styles.module.scss
+++ b/src/pages/UDT/styles.module.scss
@@ -1,6 +1,6 @@
@import '../../styles/variables.module';
-.simpleUDTOverviewCard:not(
+.udtOverviewCard:not(
[_='This `:not` selector is used to increase the specificity of the selector and serves no other purpose.']
) {
padding-bottom: 20px;
@@ -47,6 +47,10 @@
}
}
+.noneName {
+ color: #999;
+}
+
.openInNew {
cursor: pointer;
margin-left: 4px;
diff --git a/src/routes/index.tsx b/src/routes/index.tsx
index ff7e4c08e..d2766f2d8 100644
--- a/src/routes/index.tsx
+++ b/src/routes/index.tsx
@@ -12,7 +12,7 @@ const Transaction = lazy(() => import('../pages/Transaction'))
const TransactionList = lazy(() => import('../pages/TransactionList'))
const Address = lazy(() => import('../pages/Address'))
const ScriptPage = lazy(() => import('../pages/Script'))
-const SimpleUDT = lazy(() => import('../pages/SimpleUDT'))
+const UDT = lazy(() => import('../pages/UDT'))
const NftCollections = lazy(() => import('../pages/NftCollections'))
const NftCollectionInfo = lazy(() => import('../pages/NftCollectionInfo'))
const NftInfo = lazy(() => import('../pages/NftInfo'))
@@ -94,7 +94,13 @@ const routes: RouteProps[] = [
},
{
path: '/sudt/:hash',
- component: SimpleUDT,
+ component: UDT,
+ },
+ {
+ path: '/inscription/:hash',
+ render: routeProps => {
+ return
+ },
},
{
path: '/nft-collections',
@@ -116,6 +122,12 @@ const routes: RouteProps[] = [
path: '/tokens',
component: Tokens,
},
+ {
+ path: '/inscriptions',
+ render: routeProps => {
+ return
+ },
+ },
{
path: '/charts',
component: StatisticsChart,
diff --git a/src/services/ExplorerService/fetcher.ts b/src/services/ExplorerService/fetcher.ts
index 240b10a69..75081b631 100644
--- a/src/services/ExplorerService/fetcher.ts
+++ b/src/services/ExplorerService/fetcher.ts
@@ -12,7 +12,7 @@ import { Script } from '../../models/Script'
import { Block } from '../../models/Block'
import { Transaction } from '../../models/Transaction'
import { Address } from '../../models/Address'
-import { UDT } from '../../models/UDT'
+import { OmigaInscriptionCollection, UDT } from '../../models/UDT'
async function v1Get
(...args: Parameters) {
return requesterV1.get(...args).then(res => toCamelcase>(res.data))
@@ -172,7 +172,7 @@ export const apiFetcher = {
| Response.Wrapper
| Response.Wrapper
| Response.Wrapper
- | Response.Wrapper
+ | Response.Wrapper
| Response.Wrapper