feat(block2): profiles — your identity card + name/about (NIP-01 kind:0)
Drawer 'Profile' is now live. - commons_core: ProfileTransport + UserProfile + NostrProfileTransport (kind:0 publish/fetch), exposed as SocialSession.profile. Round-trip tested against the in-process relay (fast dart test). - app: ProfileStore (local name/about, keystore) + ProfileScreen — shows your shareable npub with copy, edits display name + 'about', saves locally and (when online) publishes kind:0 so peers can recognise you instead of a raw key. - Drawer 'Profile' -> /profile (gated like Market/Chat). - i18n en/es/pt. ProfileStore + profile transport covered by plain/dart tests. Analyzer clean (both packages).
This commit is contained in:
parent
abc2d37402
commit
30246f4292
19 changed files with 562 additions and 4 deletions
|
|
@ -361,6 +361,19 @@
|
|||
"locationFailed": "Couldn't get your location — check that location is on and the permission is granted",
|
||||
"queued": "Saved — we'll share these when you're connected"
|
||||
},
|
||||
"profile": {
|
||||
"title": "Your profile",
|
||||
"name": "Display name",
|
||||
"nameHint": "How others see you",
|
||||
"about": "About",
|
||||
"aboutHint": "A short line — what you grow, where",
|
||||
"yourId": "Your identity",
|
||||
"idHelp": "Share this so people can recognise you",
|
||||
"copy": "Copy",
|
||||
"copied": "Copied",
|
||||
"save": "Save",
|
||||
"saved": "Profile saved"
|
||||
},
|
||||
"chatList": {
|
||||
"title": "Messages",
|
||||
"empty": "No conversations yet. Message someone from the market."
|
||||
|
|
|
|||
|
|
@ -361,6 +361,19 @@
|
|||
"locationFailed": "No se pudo obtener tu ubicación — comprueba que la ubicación está activada y el permiso concedido",
|
||||
"queued": "Guardado — las compartiremos cuando tengas conexión"
|
||||
},
|
||||
"profile": {
|
||||
"title": "Tu perfil",
|
||||
"name": "Nombre",
|
||||
"nameHint": "Cómo te ven los demás",
|
||||
"about": "Sobre ti",
|
||||
"aboutHint": "Una línea — qué cultivas, dónde",
|
||||
"yourId": "Tu identidad",
|
||||
"idHelp": "Compártela para que te reconozcan",
|
||||
"copy": "Copiar",
|
||||
"copied": "Copiado",
|
||||
"save": "Guardar",
|
||||
"saved": "Perfil guardado"
|
||||
},
|
||||
"chatList": {
|
||||
"title": "Mensajes",
|
||||
"empty": "Aún no hay conversaciones. Escribe a alguien desde el mercado."
|
||||
|
|
|
|||
|
|
@ -357,6 +357,19 @@
|
|||
"locationFailed": "Não foi possível obter a tua localização — verifica se a localização está ativa e a permissão concedida",
|
||||
"queued": "Guardado — vamos partilhá-las quando tiveres ligação"
|
||||
},
|
||||
"profile": {
|
||||
"title": "O teu perfil",
|
||||
"name": "Nome",
|
||||
"nameHint": "Como os outros te veem",
|
||||
"about": "Sobre ti",
|
||||
"aboutHint": "Uma linha — o que cultivas, onde",
|
||||
"yourId": "A tua identidade",
|
||||
"idHelp": "Partilha-a para que te reconheçam",
|
||||
"copy": "Copiar",
|
||||
"copied": "Copiado",
|
||||
"save": "Guardar",
|
||||
"saved": "Perfil guardado"
|
||||
},
|
||||
"chatList": {
|
||||
"title": "Mensagens",
|
||||
"empty": "Ainda não há conversas. Escreve a alguém a partir do mercado."
|
||||
|
|
|
|||
|
|
@ -4,9 +4,9 @@
|
|||
/// To regenerate, run: `dart run slang`
|
||||
///
|
||||
/// Locales: 3
|
||||
/// Strings: 998 (332 per locale)
|
||||
/// Strings: 1031 (343 per locale)
|
||||
///
|
||||
/// Built on 2026-07-10 at 10:26 UTC
|
||||
/// Built on 2026-07-10 at 10:36 UTC
|
||||
|
||||
// coverage:ignore-file
|
||||
// ignore_for_file: type=lint, unused_import
|
||||
|
|
|
|||
|
|
@ -70,6 +70,7 @@ class Translations with BaseTranslations<AppLocale, Translations> {
|
|||
late final Translations$desiccant$en desiccant = Translations$desiccant$en.internal(_root);
|
||||
late final Translations$unit$en unit = Translations$unit$en.internal(_root);
|
||||
late final Translations$market$en market = Translations$market$en.internal(_root);
|
||||
late final Translations$profile$en profile = Translations$profile$en.internal(_root);
|
||||
late final Translations$chatList$en chatList = Translations$chatList$en.internal(_root);
|
||||
late final Translations$chat$en chat = Translations$chat$en.internal(_root);
|
||||
late final Translations$trust$en trust = Translations$trust$en.internal(_root);
|
||||
|
|
@ -1143,6 +1144,48 @@ class Translations$market$en {
|
|||
String get queued => 'Saved — we\'ll share these when you\'re connected';
|
||||
}
|
||||
|
||||
// Path: profile
|
||||
class Translations$profile$en {
|
||||
Translations$profile$en.internal(this._root);
|
||||
|
||||
final Translations _root; // ignore: unused_field
|
||||
|
||||
// Translations
|
||||
|
||||
/// en: 'Your profile'
|
||||
String get title => 'Your profile';
|
||||
|
||||
/// en: 'Display name'
|
||||
String get name => 'Display name';
|
||||
|
||||
/// en: 'How others see you'
|
||||
String get nameHint => 'How others see you';
|
||||
|
||||
/// en: 'About'
|
||||
String get about => 'About';
|
||||
|
||||
/// en: 'A short line — what you grow, where'
|
||||
String get aboutHint => 'A short line — what you grow, where';
|
||||
|
||||
/// en: 'Your identity'
|
||||
String get yourId => 'Your identity';
|
||||
|
||||
/// en: 'Share this so people can recognise you'
|
||||
String get idHelp => 'Share this so people can recognise you';
|
||||
|
||||
/// en: 'Copy'
|
||||
String get copy => 'Copy';
|
||||
|
||||
/// en: 'Copied'
|
||||
String get copied => 'Copied';
|
||||
|
||||
/// en: 'Save'
|
||||
String get save => 'Save';
|
||||
|
||||
/// en: 'Profile saved'
|
||||
String get saved => 'Profile saved';
|
||||
}
|
||||
|
||||
// Path: chatList
|
||||
class Translations$chatList$en {
|
||||
Translations$chatList$en.internal(this._root);
|
||||
|
|
@ -1985,6 +2028,17 @@ extension on Translations {
|
|||
'market.useLocation' => 'Use my approximate location',
|
||||
'market.locationFailed' => 'Couldn\'t get your location — check that location is on and the permission is granted',
|
||||
'market.queued' => 'Saved — we\'ll share these when you\'re connected',
|
||||
'profile.title' => 'Your profile',
|
||||
'profile.name' => 'Display name',
|
||||
'profile.nameHint' => 'How others see you',
|
||||
'profile.about' => 'About',
|
||||
'profile.aboutHint' => 'A short line — what you grow, where',
|
||||
'profile.yourId' => 'Your identity',
|
||||
'profile.idHelp' => 'Share this so people can recognise you',
|
||||
'profile.copy' => 'Copy',
|
||||
'profile.copied' => 'Copied',
|
||||
'profile.save' => 'Save',
|
||||
'profile.saved' => 'Profile saved',
|
||||
'chatList.title' => 'Messages',
|
||||
'chatList.empty' => 'No conversations yet. Message someone from the market.',
|
||||
'chat.title' => 'Chat',
|
||||
|
|
|
|||
|
|
@ -69,6 +69,7 @@ class TranslationsEs extends Translations with BaseTranslations<AppLocale, Trans
|
|||
@override late final _Translations$desiccant$es desiccant = _Translations$desiccant$es._(_root);
|
||||
@override late final _Translations$unit$es unit = _Translations$unit$es._(_root);
|
||||
@override late final _Translations$market$es market = _Translations$market$es._(_root);
|
||||
@override late final _Translations$profile$es profile = _Translations$profile$es._(_root);
|
||||
@override late final _Translations$chatList$es chatList = _Translations$chatList$es._(_root);
|
||||
@override late final _Translations$chat$es chat = _Translations$chat$es._(_root);
|
||||
@override late final _Translations$trust$es trust = _Translations$trust$es._(_root);
|
||||
|
|
@ -635,6 +636,26 @@ class _Translations$market$es extends Translations$market$en {
|
|||
@override String get queued => 'Guardado — las compartiremos cuando tengas conexión';
|
||||
}
|
||||
|
||||
// Path: profile
|
||||
class _Translations$profile$es extends Translations$profile$en {
|
||||
_Translations$profile$es._(TranslationsEs root) : this._root = root, super.internal(root);
|
||||
|
||||
final TranslationsEs _root; // ignore: unused_field
|
||||
|
||||
// Translations
|
||||
@override String get title => 'Tu perfil';
|
||||
@override String get name => 'Nombre';
|
||||
@override String get nameHint => 'Cómo te ven los demás';
|
||||
@override String get about => 'Sobre ti';
|
||||
@override String get aboutHint => 'Una línea — qué cultivas, dónde';
|
||||
@override String get yourId => 'Tu identidad';
|
||||
@override String get idHelp => 'Compártela para que te reconozcan';
|
||||
@override String get copy => 'Copiar';
|
||||
@override String get copied => 'Copiado';
|
||||
@override String get save => 'Guardar';
|
||||
@override String get saved => 'Perfil guardado';
|
||||
}
|
||||
|
||||
// Path: chatList
|
||||
class _Translations$chatList$es extends Translations$chatList$en {
|
||||
_Translations$chatList$es._(TranslationsEs root) : this._root = root, super.internal(root);
|
||||
|
|
@ -1337,6 +1358,17 @@ extension on TranslationsEs {
|
|||
'market.useLocation' => 'Usar mi ubicación aproximada',
|
||||
'market.locationFailed' => 'No se pudo obtener tu ubicación — comprueba que la ubicación está activada y el permiso concedido',
|
||||
'market.queued' => 'Guardado — las compartiremos cuando tengas conexión',
|
||||
'profile.title' => 'Tu perfil',
|
||||
'profile.name' => 'Nombre',
|
||||
'profile.nameHint' => 'Cómo te ven los demás',
|
||||
'profile.about' => 'Sobre ti',
|
||||
'profile.aboutHint' => 'Una línea — qué cultivas, dónde',
|
||||
'profile.yourId' => 'Tu identidad',
|
||||
'profile.idHelp' => 'Compártela para que te reconozcan',
|
||||
'profile.copy' => 'Copiar',
|
||||
'profile.copied' => 'Copiado',
|
||||
'profile.save' => 'Guardar',
|
||||
'profile.saved' => 'Perfil guardado',
|
||||
'chatList.title' => 'Mensajes',
|
||||
'chatList.empty' => 'Aún no hay conversaciones. Escribe a alguien desde el mercado.',
|
||||
'chat.title' => 'Chat',
|
||||
|
|
|
|||
|
|
@ -69,6 +69,7 @@ class TranslationsPt extends Translations with BaseTranslations<AppLocale, Trans
|
|||
@override late final _Translations$desiccant$pt desiccant = _Translations$desiccant$pt._(_root);
|
||||
@override late final _Translations$unit$pt unit = _Translations$unit$pt._(_root);
|
||||
@override late final _Translations$market$pt market = _Translations$market$pt._(_root);
|
||||
@override late final _Translations$profile$pt profile = _Translations$profile$pt._(_root);
|
||||
@override late final _Translations$chatList$pt chatList = _Translations$chatList$pt._(_root);
|
||||
@override late final _Translations$chat$pt chat = _Translations$chat$pt._(_root);
|
||||
@override late final _Translations$trust$pt trust = _Translations$trust$pt._(_root);
|
||||
|
|
@ -631,6 +632,26 @@ class _Translations$market$pt extends Translations$market$en {
|
|||
@override String get queued => 'Guardado — vamos partilhá-las quando tiveres ligação';
|
||||
}
|
||||
|
||||
// Path: profile
|
||||
class _Translations$profile$pt extends Translations$profile$en {
|
||||
_Translations$profile$pt._(TranslationsPt root) : this._root = root, super.internal(root);
|
||||
|
||||
final TranslationsPt _root; // ignore: unused_field
|
||||
|
||||
// Translations
|
||||
@override String get title => 'O teu perfil';
|
||||
@override String get name => 'Nome';
|
||||
@override String get nameHint => 'Como os outros te veem';
|
||||
@override String get about => 'Sobre ti';
|
||||
@override String get aboutHint => 'Uma linha — o que cultivas, onde';
|
||||
@override String get yourId => 'A tua identidade';
|
||||
@override String get idHelp => 'Partilha-a para que te reconheçam';
|
||||
@override String get copy => 'Copiar';
|
||||
@override String get copied => 'Copiado';
|
||||
@override String get save => 'Guardar';
|
||||
@override String get saved => 'Perfil guardado';
|
||||
}
|
||||
|
||||
// Path: chatList
|
||||
class _Translations$chatList$pt extends Translations$chatList$en {
|
||||
_Translations$chatList$pt._(TranslationsPt root) : this._root = root, super.internal(root);
|
||||
|
|
@ -1329,6 +1350,17 @@ extension on TranslationsPt {
|
|||
'market.useLocation' => 'Usar a minha localização aproximada',
|
||||
'market.locationFailed' => 'Não foi possível obter a tua localização — verifica se a localização está ativa e a permissão concedida',
|
||||
'market.queued' => 'Guardado — vamos partilhá-las quando tiveres ligação',
|
||||
'profile.title' => 'O teu perfil',
|
||||
'profile.name' => 'Nome',
|
||||
'profile.nameHint' => 'Como os outros te veem',
|
||||
'profile.about' => 'Sobre ti',
|
||||
'profile.aboutHint' => 'Uma linha — o que cultivas, onde',
|
||||
'profile.yourId' => 'A tua identidade',
|
||||
'profile.idHelp' => 'Partilha-a para que te reconheçam',
|
||||
'profile.copy' => 'Copiar',
|
||||
'profile.copied' => 'Copiado',
|
||||
'profile.save' => 'Guardar',
|
||||
'profile.saved' => 'Perfil guardado',
|
||||
'chatList.title' => 'Mensagens',
|
||||
'chatList.empty' => 'Ainda não há conversas. Escreve a alguém a partir do mercado.',
|
||||
'chat.title' => 'Conversa',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue