feat: 新增 AppLoadingIndicator 和 AppPressable 组件
- 新增 AppLoadingIndicator 加载指示器组件 - 新增 AppPressable 按压反馈组件 - 新增 AppSheetInputField 输入框组件 - 更新 AppButton 和其他共享组件
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
import '../../core/theme/design_tokens.dart';
|
||||
import 'app_loading_indicator.dart';
|
||||
|
||||
class AppButton extends StatelessWidget {
|
||||
const AppButton({
|
||||
@@ -47,13 +48,10 @@ class AppButton extends StatelessWidget {
|
||||
padding: const EdgeInsets.symmetric(horizontal: AppSpacing.xl),
|
||||
),
|
||||
child: isLoading
|
||||
? SizedBox(
|
||||
width: 18,
|
||||
height: 18,
|
||||
child: CircularProgressIndicator(
|
||||
strokeWidth: 2.2,
|
||||
color: AppColors.authSecondaryButtonText,
|
||||
),
|
||||
? const AppLoadingIndicator(
|
||||
variant: AppLoadingVariant.button,
|
||||
color: AppColors.authSecondaryButtonText,
|
||||
trackColor: AppColors.authSecondaryButtonBorder,
|
||||
)
|
||||
: Text(
|
||||
text,
|
||||
@@ -115,13 +113,10 @@ class AppButton extends StatelessWidget {
|
||||
),
|
||||
),
|
||||
child: isLoading
|
||||
? const SizedBox(
|
||||
width: 18,
|
||||
height: 18,
|
||||
child: CircularProgressIndicator(
|
||||
strokeWidth: 2.2,
|
||||
color: AppColors.authPrimaryButtonText,
|
||||
),
|
||||
? const AppLoadingIndicator(
|
||||
variant: AppLoadingVariant.button,
|
||||
color: AppColors.authPrimaryButtonText,
|
||||
trackColor: AppColors.blue400,
|
||||
)
|
||||
: Text(
|
||||
text,
|
||||
|
||||
Reference in New Issue
Block a user