@thenamespace/ens-components 1.5.0 → 1.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -4,6 +4,9 @@ Production-ready React components for ENS name registration, record editing, and
4
4
 
5
5
  [![npm](https://img.shields.io/npm/v/@thenamespace/ens-components)](https://www.npmjs.com/package/@thenamespace/ens-components)
6
6
 
7
+ Record editing and onchain/offchain subname flows support native `.eth` names and
8
+ DNS names imported into ENS, such as `example.com`. The `.eth` registration form is limited to `.eth` registrations.
9
+
7
10
  ## Install
8
11
 
9
12
  ```bash
@@ -75,13 +78,13 @@ Full `.eth` name registration flow: search → commit → wait → register.
75
78
  ```tsx
76
79
  <EnsNameRegistrationForm
77
80
  isTestnet={false}
78
- onNameRegistered={(name) => console.log("Registered:", name)}
81
+ onNameRegistered={name => console.log("Registered:", name)}
79
82
  />
80
83
  ```
81
84
 
82
- | Prop | Type | Description |
83
- |------|------|-------------|
84
- | `isTestnet` | `boolean` | Use Sepolia testnet contracts |
85
+ | Prop | Type | Description |
86
+ | ------------------ | ------------------------ | -------------------------------------- |
87
+ | `isTestnet` | `boolean` | Use Sepolia testnet contracts |
85
88
  | `onNameRegistered` | `(name: string) => void` | Callback after successful registration |
86
89
 
87
90
  ---
@@ -95,16 +98,16 @@ Edit all resolver records for an ENS name — addresses, text records, contentha
95
98
  name="alice.eth"
96
99
  existingRecords={{ texts: [], addresses: [] }}
97
100
  isTestnet={false}
98
- onRecordsSaved={(records) => console.log(records)}
101
+ onRecordsSaved={records => console.log(records)}
99
102
  />
100
103
  ```
101
104
 
102
- | Prop | Type | Description |
103
- |------|------|-------------|
104
- | `name` | `string` | The ENS name to edit |
105
- | `existingRecords` | `EnsRecords` | Current on-chain records to pre-populate |
106
- | `isTestnet` | `boolean` | Use Sepolia testnet contracts |
107
- | `onRecordsSaved` | `(records: EnsRecords) => void` | Callback after records are saved |
105
+ | Prop | Type | Description |
106
+ | ----------------- | ------------------------------- | --------------------------------------------------------- |
107
+ | `name` | `string` | ENS name to edit (`.eth` or a DNS name imported into ENS) |
108
+ | `existingRecords` | `EnsRecords` | Current on-chain records to pre-populate |
109
+ | `isTestnet` | `boolean` | Use Sepolia testnet contracts |
110
+ | `onRecordsSaved` | `(records: EnsRecords) => void` | Callback after records are saved |
108
111
 
109
112
  ---
110
113
 
@@ -116,15 +119,15 @@ Mint an onchain subname from a Namespace listing.
116
119
  <SubnameMintForm
117
120
  parentName="alice.eth"
118
121
  isTestnet={false}
119
- onSubnameMinted={(subname) => console.log("Minted:", subname)}
122
+ onSubnameMinted={subname => console.log("Minted:", subname)}
120
123
  />
121
124
  ```
122
125
 
123
- | Prop | Type | Description |
124
- |------|------|-------------|
125
- | `parentName` | `string` | Parent ENS name with an active listing |
126
- | `isTestnet` | `boolean` | Use Sepolia testnet contracts |
127
- | `onSubnameMinted` | `(subname: string) => void` | Callback after mint |
126
+ | Prop | Type | Description |
127
+ | ----------------- | --------------------------- | -------------------------------------------------------------- |
128
+ | `parentName` | `string` | ENS parent (`.eth` or ENS-imported DNS) with an active listing |
129
+ | `isTestnet` | `boolean` | Use Sepolia testnet contracts |
130
+ | `onSubnameMinted` | `(subname: string) => void` | Callback after mint |
128
131
 
129
132
  ---
130
133
 
@@ -137,16 +140,16 @@ Create or update an offchain subname through the Namespace API.
137
140
  name="alice.eth"
138
141
  apiKeyOrToken="YOUR_NAMESPACE_API_KEY"
139
142
  isTestnet={false}
140
- onSubnameSaved={(subname) => console.log("Saved:", subname)}
143
+ onSubnameSaved={subname => console.log("Saved:", subname)}
141
144
  />
142
145
  ```
143
146
 
144
- | Prop | Type | Description |
145
- |------|------|-------------|
146
- | `name` | `string` | Parent ENS name |
147
- | `apiKeyOrToken` | `string` | Namespace API key or SIWE token |
148
- | `isTestnet` | `boolean` | Use Sepolia testnet contracts |
149
- | `onSubnameSaved` | `(subname: string) => void` | Callback after save |
147
+ | Prop | Type | Description |
148
+ | ---------------- | --------------------------- | -------------------------------------------- |
149
+ | `name` | `string` | Parent ENS name (`.eth` or ENS-imported DNS) |
150
+ | `apiKeyOrToken` | `string` | Namespace API key or SIWE token |
151
+ | `isTestnet` | `boolean` | Use Sepolia testnet contracts |
152
+ | `onSubnameSaved` | `(subname: string) => void` | Callback after save |
150
153
 
151
154
  ---
152
155
 
@@ -182,7 +185,7 @@ Components use CSS variables that can be overridden:
182
185
 
183
186
  ```css
184
187
  :root {
185
- --ns-color-primary: #5A4BFF;
188
+ --ns-color-primary: #5a4bff;
186
189
  --ns-color-bg: #ffffff;
187
190
  --ns-color-fg: #111111;
188
191
  --ns-radius-md: 12px;