mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-04-20 11:08:03 +08:00
mod: 无障碍语义适配
This commit is contained in:
@@ -10,6 +10,7 @@ class PBadge extends StatelessWidget {
|
||||
final String? size;
|
||||
final String? stack;
|
||||
final double? fs;
|
||||
final String? semanticsLabel;
|
||||
|
||||
const PBadge({
|
||||
super.key,
|
||||
@@ -22,6 +23,7 @@ class PBadge extends StatelessWidget {
|
||||
this.size = 'medium',
|
||||
this.stack = 'position',
|
||||
this.fs = 11,
|
||||
this.semanticsLabel,
|
||||
});
|
||||
|
||||
@override
|
||||
@@ -68,6 +70,7 @@ class PBadge extends StatelessWidget {
|
||||
child: Text(
|
||||
text!,
|
||||
style: TextStyle(fontSize: fs ?? fontSize, color: color),
|
||||
semanticsLabel: semanticsLabel,
|
||||
),
|
||||
);
|
||||
if (stack == 'position') {
|
||||
|
||||
Reference in New Issue
Block a user