refactor(trust): ego-centric trust replaces the global Duniter membership
The global membership rule (curated bootstrap referents + sigQty/stepMax parameters) solved sybil-proof identity for a UBI — a problem this app doesn't have — and its screen leaked graph jargon (npub roots, parameter steppers). Trust is now computed from the user's own position only: you vouch / vouched by people you know (distance <=2) / vouched by N. - TrustCubit: drop networkMember tier, referents and params; keep the circle rule and the 365-day vouch expiry (renewable, self-pruning). - Delete TrustReferents, WotSettings, TrustNetworkScreen and the bundled referents asset; unwire injector/bootstrap/app/chat. - New 'Your people' screen (/your-people, from the profile): who you vouch for (revocable) and who vouches for you, names via ProfileCache. - i18n: wot.* removed, yourPeople.* added (en/es/pt/ast); trust.member removed. Kind 30777 events on relays stay fully compatible — only the interpretation changes.
This commit is contained in:
parent
4af90876f4
commit
dc7b2eee27
25 changed files with 595 additions and 863 deletions
|
|
@ -22,7 +22,7 @@ class ProfileScreen extends StatefulWidget {
|
|||
required this.connection,
|
||||
required this.profileStore,
|
||||
required this.accounts,
|
||||
this.trustNetworkEnabled = false,
|
||||
this.yourPeopleEnabled = false,
|
||||
super.key,
|
||||
});
|
||||
|
||||
|
|
@ -33,8 +33,8 @@ class ProfileScreen extends StatefulWidget {
|
|||
final ProfileStore profileStore;
|
||||
final SocialAccountStore accounts;
|
||||
|
||||
/// Whether to offer the "Network of trust" entry (needs the WoT services).
|
||||
final bool trustNetworkEnabled;
|
||||
/// Whether to offer the "Your people" entry (needs the social layer).
|
||||
final bool yourPeopleEnabled;
|
||||
|
||||
@override
|
||||
State<ProfileScreen> createState() => _ProfileScreenState();
|
||||
|
|
@ -210,16 +210,17 @@ class _ProfileScreenState extends State<ProfileScreen> {
|
|||
onSwitch: (a) => _switchTo(a),
|
||||
onNew: _newIdentity,
|
||||
),
|
||||
if (widget.trustNetworkEnabled) ...[
|
||||
if (widget.yourPeopleEnabled) ...[
|
||||
const SizedBox(height: 12),
|
||||
const Divider(),
|
||||
ListTile(
|
||||
key: const Key('profile.trustNetwork'),
|
||||
key: const Key('profile.yourPeople'),
|
||||
contentPadding: EdgeInsets.zero,
|
||||
leading: const Icon(Icons.hub_outlined, color: seedGreen),
|
||||
title: Text(t.wot.open),
|
||||
leading:
|
||||
const Icon(Icons.people_alt_outlined, color: seedGreen),
|
||||
title: Text(t.yourPeople.title),
|
||||
trailing: const Icon(Icons.chevron_right, color: seedMuted),
|
||||
onTap: () => context.push('/trust'),
|
||||
onTap: () => context.push('/your-people'),
|
||||
),
|
||||
],
|
||||
],
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue