refactor: rename internal Fai* design system + fai_ helpers to chain
Some checks failed
Security / Security check (push) Failing after 2s
Some checks failed
Security / Security check (push) Failing after 2s
The Studio design system, widgets and helpers carried a Fai* / fai_ prefix (FaiSpace, FaiColors, FaiTheme, FaiLog, 17 fai_*.dart files, the faiBinary* l10n keys). Studio is the Ch∆In product, so rename them to Chain* / chain_ — carefully preserving English fail/failure/failed. Also fix stale references: the 'fai' binary in l10n strings -> 'chain', FAI_* env vars (FAI_BIN/DATA_DIR/MODULES_DIR/TODAY/BOOTSTRAP_TOKEN) -> CHAIN_*, fai_platform -> fai_chain, fai_hub -> chain_hub. Vendor security-hook tooling (FAI_BANNED_TERMS_FILE) + the .fai bundle ext left. flutter analyze + test: clean (20 passed). Signed-off-by: flemming-it <stefan.a.flemming@googlemail.com>
This commit is contained in:
parent
68d23ab7dd
commit
891acd2ba2
52 changed files with 1225 additions and 1225 deletions
|
|
@ -16,9 +16,9 @@
|
|||
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
import '../widgets/fai_error_box.dart';
|
||||
import '../widgets/chain_error_box.dart';
|
||||
import '../theme/tokens.dart';
|
||||
import 'fai_log.dart';
|
||||
import 'chain_log.dart';
|
||||
|
||||
/// Show [error] as a SnackBar with a copy affordance.
|
||||
///
|
||||
|
|
@ -41,7 +41,7 @@ void showFaiErrorSnack(
|
|||
}) {
|
||||
// Fire-and-forget log write. If the disk's full or the dir
|
||||
// is read-only the UI still surfaces the error.
|
||||
FaiLog.instance.error(source, error, context: title);
|
||||
ChainLog.instance.error(source, error, context: title);
|
||||
final messenger = ScaffoldMessenger.maybeOf(context);
|
||||
if (messenger == null) {
|
||||
// No Scaffold above — the caller is likely showing the
|
||||
|
|
@ -60,8 +60,8 @@ void showFaiErrorSnack(
|
|||
padding: EdgeInsets.zero,
|
||||
content: Padding(
|
||||
padding: const EdgeInsets.symmetric(
|
||||
horizontal: FaiSpace.sm,
|
||||
vertical: FaiSpace.xs,
|
||||
horizontal: ChainSpace.sm,
|
||||
vertical: ChainSpace.xs,
|
||||
),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
|
|
@ -75,9 +75,9 @@ void showFaiErrorSnack(
|
|||
fontWeight: FontWeight.w600,
|
||||
),
|
||||
),
|
||||
const SizedBox(height: FaiSpace.xs),
|
||||
const SizedBox(height: ChainSpace.xs),
|
||||
],
|
||||
FaiErrorBox(error: error, isError: true),
|
||||
ChainErrorBox(error: error, isError: true),
|
||||
],
|
||||
),
|
||||
),
|
||||
|
|
@ -94,14 +94,14 @@ Future<void> showFaiErrorDialog(
|
|||
Object error, {
|
||||
String? title,
|
||||
}) async {
|
||||
FaiLog.instance.error(source, error);
|
||||
ChainLog.instance.error(source, error);
|
||||
return showDialog<void>(
|
||||
context: context,
|
||||
builder: (ctx) => AlertDialog(
|
||||
title: title == null ? null : Text(title),
|
||||
content: SizedBox(
|
||||
width: 480,
|
||||
child: FaiErrorBox(error: error, isError: true, maxHeight: 240),
|
||||
child: ChainErrorBox(error: error, isError: true, maxHeight: 240),
|
||||
),
|
||||
actions: [
|
||||
TextButton(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue