感谢您访问我的主页,不妨给个关注。
欢迎光临我的点卡小铺:点卡系统,如果需要更多内容,欢迎与我联系
基于ChatGPT的一款效率助手,支持公众号、网页版以及浏览器插件,https://www.ai-text.top
Flutter自定义块样式输入框,实现在输入框中自定义加入任意 TextSpan,并可获得加入的 TextSpan对象。通过此组件可以快速实现@功能值绑定,隐藏域值绑定
License: Apache License 2.0
感谢您访问我的主页,不妨给个关注。
欢迎光临我的点卡小铺:点卡系统,如果需要更多内容,欢迎与我联系
基于ChatGPT的一款效率助手,支持公众号、网页版以及浏览器插件,https://www.ai-text.top
感谢作者,做了一个很有用的插件
特别建议,把使用文档完善完善,因为这样能提高很大的沟通效率
在开发的过程中, 有遇到两个会让程序挂掉的bug,
======== Exception caught by widgets library =======================================================
The following assertion was thrown building Scrollable(axisDirection: down, physics: null, restorationId: null, dirty, dependencies: [_InheritedTheme, MediaQuery, _EffectiveTickerMode, ScrollConfiguration, _LocalizationsScope-[GlobalKey#59f39]], state: ScrollableState#20ccf(position: ScrollPositionWithSingleContext#825d9(offset: 0.0, range: 0.0..0.0, viewport: 19.0, ScrollableState, BouncingScrollPhysics -> RangeMaintainingScrollPhysics, IdleScrollActivity#9da3b, ScrollDirection.idle), effective physics: BouncingScrollPhysics -> RangeMaintainingScrollPhysics)):
'dart:ui/text.dart': Failed assertion: line 1544: '<optimized out>': is not true.
The relevant error-causing widget was:
CustomEditableText-[LabeledGlobalKey<EditableTextState>#3cd19] file:///Users/danhang/work/application/extend-package/FlutterTextSpanField/lib/text_span_field.dart:1010:43
When the exception was thrown, this was the stack:
#2 TextRange.textInside (dart:ui/text.dart:1544:12)
#3 TextSpanBuilder._buildTextSpanWidget (package:text_span_field/text_span_builder.dart:249:86)
#4 TextSpanBuilder.buildSpan (package:text_span_field/text_span_builder.dart:279:33)
#5 _EditableTextSpan.buildTextSpan (package:text_span_field/custom/custom_editable_text.dart:129:34)
#6 EditableTextState.build.<anonymous closure> (package:flutter/src/widgets/editable_text.dart:2445:27)
...
====================================================================================================
======== Exception caught by rendering library =====================================================
A RenderFlex overflowed by 99896 pixels on the bottom.
The relevant error-causing widget was:
Column file:///Users/danhang/work/application/extend-package/FlutterTextSpanField/example/lib/main.dart:79:20
====================================================================================================
======== Exception caught by scheduler library =====================================================
The method 'findRenderObject' was called on null.
Receiver: null
Tried calling: findRenderObject()
====================================================================================================
======== Exception caught by scheduler library =====================================================
The method 'findRenderObject' was called on null.
Receiver: null
Tried calling: findRenderObject()
====================================================================================================
很好用的组件.
希望添加输入@时触发选择好友的功能
Is there any change this library getting null safety support?
输入[微笑]会显示微笑图片会计划搞不
hi, 感谢大佬实现的这个组件.
但我在使用的过程中有点问题,就是那个删除整体那一块,除了使用删除按钮来定义回调,对textField自带的删除键删除是无效的是吗
➜ mac flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 2.2.3, on Mac OS X 10.15.6 19G2005 darwin-x64, locale zh-Hans-CN)
[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
[✓] Xcode - develop for iOS and macOS
[✓] Chrome - develop for the web
[✓] Android Studio (version 4.1)
[✓] IntelliJ IDEA Community Edition (version 2020.3.3)
[✓] VS Code (version 1.59.1)
[✓] Connected device (3 available)
• No issues found!
@多个用户,再清理之后,会出现抛异常
Performing hot restart...
Syncing files to device wenbo...
Restarted application in 711ms.
flutter: -- @张三
flutter: @张三 -- @张三@张三
flutter: @张三@张三 --
======== Exception caught by foundation library ====================================================
The following RangeError was thrown while dispatching notifications for TextEditingController:
RangeError (index): Invalid value: Only valid value is 0: 1
When the exception was thrown, this was the stack:
#0 List.[] (dart:core-patch/growable_array.dart:177:60)
#1 List.removeAt (dart:core-patch/growable_array.dart:23:22)
#2 TextSpanBuilder._deleteLimit.<anonymous closure> (package:text_span_field/text_span_builder.dart:135:56)
#3 List.forEach (dart:core-patch/growable_array.dart:313:8)
#4 TextSpanBuilder._deleteLimit (package:text_span_field/text_span_builder.dart:135:17)
...
The TextEditingController sending notification was: TextEditingController#6a99f(TextEditingValue(text: ┤├, selection: TextSelection(baseOffset: 0, extentOffset: 0, affinity: TextAffinity.downstream, isDirectional: false), composing: TextRange(start: -1, end: -1)))
====================================================================================================
======== Exception caught by widgets library =======================================================
Value not in range: 3
The relevant error-causing widget was:
CustomEditableText-[LabeledGlobalKey<EditableTextState>#04546] file:///Users/supermonkey/Project/flutter_lib/FlutterTextSpanField/lib/text_span_field.dart:1010:43
====================================================================================================
======== Exception caught by rendering library =====================================================
A RenderFlex overflowed by 99636 pixels on the bottom.
The relevant error-causing widget was:
Column file:///Users/supermonkey/Project/flutter_lib/FlutterTextSpanField/example/lib/main.dart:79:20
====================================================================================================
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.