feat(ratings): Wallapop-style ratings in chat and offer detail
- SocialSession grows a ratings transport (fifth interface on the one shared channel). - PeerRatingCubit: count, locale-aware average, and circleCount — how many ratings come from your own circle (reuses the ego-centric trust rule), the signal that makes strangers' review-stuffing irrelevant. - Chat: slim rating strip under the trust banner; you can rate only someone you've talked with (soft anchor until the signed bilateral exchange form lands). Sheet with 5 stars + optional comment, pre-filled for editing, with a take-back action. - Offer detail: author's stars under their name, with 'N from people you know' when your circle rated them; nothing shown when unrated. - i18n ratings.* (en/es/pt/ast); tests for cubit and sheet.
This commit is contained in:
parent
acdacf1821
commit
1926e3bd98
18 changed files with 873 additions and 12 deletions
|
|
@ -550,6 +550,14 @@
|
|||
"revokeConfirm": "¿Dexar d'avalar a esta persona?",
|
||||
"offline": "Ensin conexón — vuelvi tentalo cuando teas en llinia"
|
||||
},
|
||||
"ratings": {
|
||||
"rate": "Valorar a esta persona",
|
||||
"edit": "Editar la to valoración",
|
||||
"commentHint": "¿Qué tal foi? (opcional)",
|
||||
"fromYourCircle": "{n} de xente que conoces",
|
||||
"retract": "Quitar la to valoración",
|
||||
"saved": "Valoración guardada"
|
||||
},
|
||||
"notifications": {
|
||||
"newMessageFrom": "Mensaxe nuevu de {name}"
|
||||
},
|
||||
|
|
|
|||
|
|
@ -553,6 +553,14 @@
|
|||
"revokeConfirm": "Stop vouching for this person?",
|
||||
"offline": "You're offline — try again when you're connected"
|
||||
},
|
||||
"ratings": {
|
||||
"rate": "Rate this person",
|
||||
"edit": "Edit your rating",
|
||||
"commentHint": "How did it go? (optional)",
|
||||
"fromYourCircle": "{n} from people you know",
|
||||
"retract": "Remove your rating",
|
||||
"saved": "Rating saved"
|
||||
},
|
||||
"notifications": {
|
||||
"newMessageFrom": "New message from {name}"
|
||||
},
|
||||
|
|
|
|||
|
|
@ -552,6 +552,14 @@
|
|||
"revokeConfirm": "¿Dejar de avalar a esta persona?",
|
||||
"offline": "Sin conexión — inténtalo cuando estés en línea"
|
||||
},
|
||||
"ratings": {
|
||||
"rate": "Valorar a esta persona",
|
||||
"edit": "Editar tu valoración",
|
||||
"commentHint": "¿Qué tal fue? (opcional)",
|
||||
"fromYourCircle": "{n} de gente que conoces",
|
||||
"retract": "Quitar tu valoración",
|
||||
"saved": "Valoración guardada"
|
||||
},
|
||||
"notifications": {
|
||||
"newMessageFrom": "Nuevo mensaje de {name}"
|
||||
},
|
||||
|
|
|
|||
|
|
@ -549,6 +549,14 @@
|
|||
"revokeConfirm": "Deixar de avalizar esta pessoa?",
|
||||
"offline": "Sem ligação — tenta novamente quando estiveres em linha"
|
||||
},
|
||||
"ratings": {
|
||||
"rate": "Avaliar esta pessoa",
|
||||
"edit": "Editar a tua avaliação",
|
||||
"commentHint": "Como correu? (opcional)",
|
||||
"fromYourCircle": "{n} de pessoas que conheces",
|
||||
"retract": "Remover a tua avaliação",
|
||||
"saved": "Avaliação guardada"
|
||||
},
|
||||
"notifications": {
|
||||
"newMessageFrom": "Nova mensagem de {name}"
|
||||
},
|
||||
|
|
|
|||
|
|
@ -4,9 +4,9 @@
|
|||
/// To regenerate, run: `dart run slang`
|
||||
///
|
||||
/// Locales: 4
|
||||
/// Strings: 1816 (454 per locale)
|
||||
/// Strings: 1840 (460 per locale)
|
||||
///
|
||||
/// Built on 2026-07-11 at 10:58 UTC
|
||||
/// Built on 2026-07-11 at 11:11 UTC
|
||||
|
||||
// coverage:ignore-file
|
||||
// ignore_for_file: type=lint, unused_import
|
||||
|
|
|
|||
|
|
@ -77,6 +77,7 @@ class TranslationsAst extends Translations with BaseTranslations<AppLocale, Tran
|
|||
@override late final _Translations$chat$ast chat = _Translations$chat$ast._(_root);
|
||||
@override late final _Translations$trust$ast trust = _Translations$trust$ast._(_root);
|
||||
@override late final _Translations$yourPeople$ast yourPeople = _Translations$yourPeople$ast._(_root);
|
||||
@override late final _Translations$ratings$ast ratings = _Translations$ratings$ast._(_root);
|
||||
@override late final _Translations$notifications$ast notifications = _Translations$notifications$ast._(_root);
|
||||
@override late final _Translations$plantare$ast plantare = _Translations$plantare$ast._(_root);
|
||||
@override late final _Translations$sale$ast sale = _Translations$sale$ast._(_root);
|
||||
|
|
@ -806,6 +807,21 @@ class _Translations$yourPeople$ast extends Translations$yourPeople$en {
|
|||
@override String get offline => 'Ensin conexón — vuelvi tentalo cuando teas en llinia';
|
||||
}
|
||||
|
||||
// Path: ratings
|
||||
class _Translations$ratings$ast extends Translations$ratings$en {
|
||||
_Translations$ratings$ast._(TranslationsAst root) : this._root = root, super.internal(root);
|
||||
|
||||
final TranslationsAst _root; // ignore: unused_field
|
||||
|
||||
// Translations
|
||||
@override String get rate => 'Valorar a esta persona';
|
||||
@override String get edit => 'Editar la to valoración';
|
||||
@override String get commentHint => '¿Qué tal foi? (opcional)';
|
||||
@override String fromYourCircle({required Object n}) => '${n} de xente que conoces';
|
||||
@override String get retract => 'Quitar la to valoración';
|
||||
@override String get saved => 'Valoración guardada';
|
||||
}
|
||||
|
||||
// Path: notifications
|
||||
class _Translations$notifications$ast extends Translations$notifications$en {
|
||||
_Translations$notifications$ast._(TranslationsAst root) : this._root = root, super.internal(root);
|
||||
|
|
@ -1627,6 +1643,12 @@ extension on TranslationsAst {
|
|||
'yourPeople.revoke' => 'Dexar d\'avalar',
|
||||
'yourPeople.revokeConfirm' => '¿Dexar d\'avalar a esta persona?',
|
||||
'yourPeople.offline' => 'Ensin conexón — vuelvi tentalo cuando teas en llinia',
|
||||
'ratings.rate' => 'Valorar a esta persona',
|
||||
'ratings.edit' => 'Editar la to valoración',
|
||||
'ratings.commentHint' => '¿Qué tal foi? (opcional)',
|
||||
'ratings.fromYourCircle' => ({required Object n}) => '${n} de xente que conoces',
|
||||
'ratings.retract' => 'Quitar la to valoración',
|
||||
'ratings.saved' => 'Valoración guardada',
|
||||
'notifications.newMessageFrom' => ({required Object name}) => 'Mensaxe nuevu de ${name}',
|
||||
'plantare.title' => 'Plantares',
|
||||
'plantare.help' => 'Un Plantare ye\'l compromisu de reproducir una semilla y devolver una parte — asina una variedá sigue viaxando de mano en mano. Nun ye una venta.',
|
||||
|
|
|
|||
|
|
@ -78,6 +78,7 @@ class Translations with BaseTranslations<AppLocale, Translations> {
|
|||
late final Translations$chat$en chat = Translations$chat$en.internal(_root);
|
||||
late final Translations$trust$en trust = Translations$trust$en.internal(_root);
|
||||
late final Translations$yourPeople$en yourPeople = Translations$yourPeople$en.internal(_root);
|
||||
late final Translations$ratings$en ratings = Translations$ratings$en.internal(_root);
|
||||
late final Translations$notifications$en notifications = Translations$notifications$en.internal(_root);
|
||||
late final Translations$plantare$en plantare = Translations$plantare$en.internal(_root);
|
||||
late final Translations$sale$en sale = Translations$sale$en.internal(_root);
|
||||
|
|
@ -1505,6 +1506,33 @@ class Translations$yourPeople$en {
|
|||
String get offline => 'You\'re offline — try again when you\'re connected';
|
||||
}
|
||||
|
||||
// Path: ratings
|
||||
class Translations$ratings$en {
|
||||
Translations$ratings$en.internal(this._root);
|
||||
|
||||
final Translations _root; // ignore: unused_field
|
||||
|
||||
// Translations
|
||||
|
||||
/// en: 'Rate this person'
|
||||
String get rate => 'Rate this person';
|
||||
|
||||
/// en: 'Edit your rating'
|
||||
String get edit => 'Edit your rating';
|
||||
|
||||
/// en: 'How did it go? (optional)'
|
||||
String get commentHint => 'How did it go? (optional)';
|
||||
|
||||
/// en: '{n} from people you know'
|
||||
String fromYourCircle({required Object n}) => '${n} from people you know';
|
||||
|
||||
/// en: 'Remove your rating'
|
||||
String get retract => 'Remove your rating';
|
||||
|
||||
/// en: 'Rating saved'
|
||||
String get saved => 'Rating saved';
|
||||
}
|
||||
|
||||
// Path: notifications
|
||||
class Translations$notifications$en {
|
||||
Translations$notifications$en.internal(this._root);
|
||||
|
|
@ -2525,6 +2553,12 @@ extension on Translations {
|
|||
'yourPeople.revoke' => 'Stop vouching',
|
||||
'yourPeople.revokeConfirm' => 'Stop vouching for this person?',
|
||||
'yourPeople.offline' => 'You\'re offline — try again when you\'re connected',
|
||||
'ratings.rate' => 'Rate this person',
|
||||
'ratings.edit' => 'Edit your rating',
|
||||
'ratings.commentHint' => 'How did it go? (optional)',
|
||||
'ratings.fromYourCircle' => ({required Object n}) => '${n} from people you know',
|
||||
'ratings.retract' => 'Remove your rating',
|
||||
'ratings.saved' => 'Rating saved',
|
||||
'notifications.newMessageFrom' => ({required Object name}) => 'New message from ${name}',
|
||||
'plantare.title' => 'Plantares',
|
||||
'plantare.help' => 'A Plantare is a promise to reproduce a seed and return some — how a variety keeps travelling from hand to hand. It\'s not a sale.',
|
||||
|
|
|
|||
|
|
@ -77,6 +77,7 @@ class TranslationsEs extends Translations with BaseTranslations<AppLocale, Trans
|
|||
@override late final _Translations$chat$es chat = _Translations$chat$es._(_root);
|
||||
@override late final _Translations$trust$es trust = _Translations$trust$es._(_root);
|
||||
@override late final _Translations$yourPeople$es yourPeople = _Translations$yourPeople$es._(_root);
|
||||
@override late final _Translations$ratings$es ratings = _Translations$ratings$es._(_root);
|
||||
@override late final _Translations$notifications$es notifications = _Translations$notifications$es._(_root);
|
||||
@override late final _Translations$plantare$es plantare = _Translations$plantare$es._(_root);
|
||||
@override late final _Translations$sale$es sale = _Translations$sale$es._(_root);
|
||||
|
|
@ -808,6 +809,21 @@ class _Translations$yourPeople$es extends Translations$yourPeople$en {
|
|||
@override String get offline => 'Sin conexión — inténtalo cuando estés en línea';
|
||||
}
|
||||
|
||||
// Path: ratings
|
||||
class _Translations$ratings$es extends Translations$ratings$en {
|
||||
_Translations$ratings$es._(TranslationsEs root) : this._root = root, super.internal(root);
|
||||
|
||||
final TranslationsEs _root; // ignore: unused_field
|
||||
|
||||
// Translations
|
||||
@override String get rate => 'Valorar a esta persona';
|
||||
@override String get edit => 'Editar tu valoración';
|
||||
@override String get commentHint => '¿Qué tal fue? (opcional)';
|
||||
@override String fromYourCircle({required Object n}) => '${n} de gente que conoces';
|
||||
@override String get retract => 'Quitar tu valoración';
|
||||
@override String get saved => 'Valoración guardada';
|
||||
}
|
||||
|
||||
// Path: notifications
|
||||
class _Translations$notifications$es extends Translations$notifications$en {
|
||||
_Translations$notifications$es._(TranslationsEs root) : this._root = root, super.internal(root);
|
||||
|
|
@ -1631,6 +1647,12 @@ extension on TranslationsEs {
|
|||
'yourPeople.revoke' => 'Dejar de avalar',
|
||||
'yourPeople.revokeConfirm' => '¿Dejar de avalar a esta persona?',
|
||||
'yourPeople.offline' => 'Sin conexión — inténtalo cuando estés en línea',
|
||||
'ratings.rate' => 'Valorar a esta persona',
|
||||
'ratings.edit' => 'Editar tu valoración',
|
||||
'ratings.commentHint' => '¿Qué tal fue? (opcional)',
|
||||
'ratings.fromYourCircle' => ({required Object n}) => '${n} de gente que conoces',
|
||||
'ratings.retract' => 'Quitar tu valoración',
|
||||
'ratings.saved' => 'Valoración guardada',
|
||||
'notifications.newMessageFrom' => ({required Object name}) => 'Nuevo mensaje de ${name}',
|
||||
'plantare.title' => 'Plantares',
|
||||
'plantare.help' => 'Un Plantare es el compromiso de reproducir una semilla y devolver una parte — así una variedad sigue viajando de mano en mano. No es una venta.',
|
||||
|
|
|
|||
|
|
@ -77,6 +77,7 @@ class TranslationsPt extends Translations with BaseTranslations<AppLocale, Trans
|
|||
@override late final _Translations$chat$pt chat = _Translations$chat$pt._(_root);
|
||||
@override late final _Translations$trust$pt trust = _Translations$trust$pt._(_root);
|
||||
@override late final _Translations$yourPeople$pt yourPeople = _Translations$yourPeople$pt._(_root);
|
||||
@override late final _Translations$ratings$pt ratings = _Translations$ratings$pt._(_root);
|
||||
@override late final _Translations$notifications$pt notifications = _Translations$notifications$pt._(_root);
|
||||
@override late final _Translations$plantare$pt plantare = _Translations$plantare$pt._(_root);
|
||||
@override late final _Translations$sale$pt sale = _Translations$sale$pt._(_root);
|
||||
|
|
@ -805,6 +806,21 @@ class _Translations$yourPeople$pt extends Translations$yourPeople$en {
|
|||
@override String get offline => 'Sem ligação — tenta novamente quando estiveres em linha';
|
||||
}
|
||||
|
||||
// Path: ratings
|
||||
class _Translations$ratings$pt extends Translations$ratings$en {
|
||||
_Translations$ratings$pt._(TranslationsPt root) : this._root = root, super.internal(root);
|
||||
|
||||
final TranslationsPt _root; // ignore: unused_field
|
||||
|
||||
// Translations
|
||||
@override String get rate => 'Avaliar esta pessoa';
|
||||
@override String get edit => 'Editar a tua avaliação';
|
||||
@override String get commentHint => 'Como correu? (opcional)';
|
||||
@override String fromYourCircle({required Object n}) => '${n} de pessoas que conheces';
|
||||
@override String get retract => 'Remover a tua avaliação';
|
||||
@override String get saved => 'Avaliação guardada';
|
||||
}
|
||||
|
||||
// Path: notifications
|
||||
class _Translations$notifications$pt extends Translations$notifications$en {
|
||||
_Translations$notifications$pt._(TranslationsPt root) : this._root = root, super.internal(root);
|
||||
|
|
@ -1625,6 +1641,12 @@ extension on TranslationsPt {
|
|||
'yourPeople.revoke' => 'Deixar de avalizar',
|
||||
'yourPeople.revokeConfirm' => 'Deixar de avalizar esta pessoa?',
|
||||
'yourPeople.offline' => 'Sem ligação — tenta novamente quando estiveres em linha',
|
||||
'ratings.rate' => 'Avaliar esta pessoa',
|
||||
'ratings.edit' => 'Editar a tua avaliação',
|
||||
'ratings.commentHint' => 'Como correu? (opcional)',
|
||||
'ratings.fromYourCircle' => ({required Object n}) => '${n} de pessoas que conheces',
|
||||
'ratings.retract' => 'Remover a tua avaliação',
|
||||
'ratings.saved' => 'Avaliação guardada',
|
||||
'notifications.newMessageFrom' => ({required Object name}) => 'Nova mensagem de ${name}',
|
||||
'plantare.title' => 'Plantares',
|
||||
'plantare.help' => 'Um Plantare é o compromisso de reproduzir uma semente e devolver uma parte — assim uma variedade continua a viajar de mão em mão. Não é uma venda.',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue