fliggy-mobile / fbutton Goto Github PK
View Code? Open in Web Editor NEWFrom then on, developers only need to master one Button component, which is enough.
License: Other
From then on, developers only need to master one Button component, which is enough.
License: Other
1.1.0中,strokeWidth和strokeColor设置无效,copy你的代码直接使用也是,在loading状态下有效果!
Error: Cannot run with sound null safety, because the following dependencies
don't support null safety:
The example app compiles and runs under linux as a desktop app. It might be better to claim this on the page at pub dev: https://pub.dev/packages/fbutton
情景是白色背景的FButton,不设置highlightColor会有几率出现点击后出现自动填充颜色
你好,我在给FButton设置了height属性,text文字无法正常显示
appBar: AppBar(
actions: _topBarActions,
bottom: PreferredSize(
preferredSize: Size.fromHeight(44.0),
child: ListTile(
leading: Image.asset("images/holder.png"),
trailing: FButton(
text: "编辑资料",
width: 120,
height: 28.0,
effect: true,
textColor: Colors.white,
color: Color.fromARGB(0, 0, 0, 0),
strokeWidth: 1,
corner: FButtonCorner.all(2.0),
strokeColor: Colors.white,
onPressed: () {},
),
),
),
)
经过多次测试,当我设置了height属性后,文字就丢失了。
v 1.1.0
loading状态下loadingText
没有显示
查看源码发现是由于_buildTextLayer
没有使用方法入参text
导致的
Text _buildTextLayer(String text, Color _textColor, ThemeData themeData) {
return Text(
widget.text ?? "",
style: widget.style ??
TextStyle(
color: _textColor,
fontWeight: widget.fontWeight,
height: widget.fontHeight,
fontSize: widget.fontSize ?? themeData.textTheme.button.fontSize,
fontStyle:
widget.fontStyle ?? themeData.textTheme.button.fontStyle),
);
}
Fbutton 在web上使用,限制高度为40后,文字显示不全
Hey,
As I've mentioned in my previous request to add the long-press support I like the button a lot. However, I will probably stop using it in an app I've been working on. There a problem with scrolling performance if your button is in a sliver, a scroll view or a list view. The scrolling becomes choppy even on the 2 years old iPhone Xs Max.
I don't have time to do the profiling but it would be great if you look into it.
After updating to "null safety", the "FCorner" class is not recognized: I get this error: The getter 'FCorner' isn't defined for the class 'DefaultButton'.
Hi,
Thank you for a cool button widget.
Would it be possible to add more gestures like a long press etc.?
Cheers,
mat
同时设置gradient和disabledColor,onPressed为null时不会变成disabledColor的颜色
my simple code:
FButton(
text: "开始",
style: ButtonTextNormal,
color: PrimaryPink,
height: 48,
alignment: Alignment.center,
corner: FCorner.all(8),
onPressed: () {
Get.to(() => const LoginPage());
},
)
always throw exception Null check operator used on a null value
======== Exception caught by gesture ===============================================================
The following _CastError was thrown while handling a gesture:
Null check operator used on a null value
When the exception was thrown, this was the stack:
#0 _FButton.build.<anonymous closure> (package:fbutton_nullsafety/fbutton_nullsafety.dart:450:38)
#1 FControlState._updateState (package:fcontrol_nullsafety/fcontrol.dart:438:35)
#2 FControlState._controlGestureHandlerForState (package:fcontrol_nullsafety/fcontrol.dart:431:5)
#3 FControlState.build.<anonymous closure> (package:fcontrol_nullsafety/fcontrol.dart:264:11)
#4 TapGestureRecognizer.handleTapDown.<anonymous closure> (package:flutter/src/gestures/tap.dart:581:61)
#5 GestureRecognizer.invokeCallback (package:flutter/src/gestures/recognizer.dart:198:24)
#6 TapGestureRecognizer.handleTapDown (package:flutter/src/gestures/tap.dart:581:11)
#7 BaseTapGestureRecognizer._checkDown (package:flutter/src/gestures/tap.dart:287:5)
#8 BaseTapGestureRecognizer.acceptGesture (package:flutter/src/gestures/tap.dart:265:7)
#9 GestureArenaManager._resolveByDefault (package:flutter/src/gestures/arena.dart:251:25)
#10 GestureArenaManager._tryToResolveArena.<anonymous closure> (package:flutter/src/gestures/arena.dart:232:31)
(elided 10 frames from dart:async)
Handler: "onTapDown"
Recognizer: TapGestureRecognizer#54356
debugOwner: GestureDetector
state: possible
button: 1
====================================================================================================
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.