From 5240ea2a44ff901cbb640445a686b2fda11e8767 Mon Sep 17 00:00:00 2001 From: Julink Date: Wed, 31 Jul 2024 13:23:12 +0200 Subject: [PATCH] feat: added setAddr record for linea address when registering by default --- .../pages/profile/[name]/registration/RegistrationPoh.tsx | 1 + .../profile/[name]/registration/steps/Profile/Profile.tsx | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/linea-ens-app/src/components/pages/profile/[name]/registration/RegistrationPoh.tsx b/packages/linea-ens-app/src/components/pages/profile/[name]/registration/RegistrationPoh.tsx index f72cb364a..c80d2979e 100644 --- a/packages/linea-ens-app/src/components/pages/profile/[name]/registration/RegistrationPoh.tsx +++ b/packages/linea-ens-app/src/components/pages/profile/[name]/registration/RegistrationPoh.tsx @@ -162,6 +162,7 @@ const RegistrationPoh = ({ nameDetails, isLoading }: Props) => { if (item.queue.includes('profile') && reverseRecord) { const recordsWithoutEth = item.records.filter((record) => record.key !== 'eth') const newRecords: ProfileRecord[] = [ + { key: 'linea', group: 'address', type: 'addr', value: address! }, { key: 'eth', group: 'address', type: 'addr', value: address! }, ...recordsWithoutEth, ] diff --git a/packages/linea-ens-app/src/components/pages/profile/[name]/registration/steps/Profile/Profile.tsx b/packages/linea-ens-app/src/components/pages/profile/[name]/registration/steps/Profile/Profile.tsx index f6cd9fbf6..fcb1b8f99 100644 --- a/packages/linea-ens-app/src/components/pages/profile/[name]/registration/steps/Profile/Profile.tsx +++ b/packages/linea-ens-app/src/components/pages/profile/[name]/registration/steps/Profile/Profile.tsx @@ -310,7 +310,9 @@ const Profile = ({ name, callback, registrationData, resolverExists }: Props) => key={field.id} recordKey={field.key} group={field.group} - disabled={field.key === 'eth' && registrationData.reverseRecord} + disabled={ + (field.key === 'eth' || field.key === 'linea') && registrationData.reverseRecord + } label={labelForRecord(field)} secondaryLabel={secondaryLabelForRecord(field)} placeholder={placeholderForRecord(field)}