Commit 94c8577
authored
Development (#132)
This pull request updates the documentation and changelog for the
`ThemedNumberInput` and `ThemedDurationInput` Flutter widgets,
clarifying their behavior, edge cases, and usage patterns. It also
documents several recent bug fixes and improvements, including memory
management, input validation, cursor handling, and enhanced visual
feedback for step buttons. The changes provide comprehensive examples,
testing guidance, and detailed explanations of widget parameters and
behaviors.
**Documentation and Behavior Clarifications:**
* Expanded and clarified the documentation for `ThemedNumberInput` and
`ThemedDurationInput` in
`.claude-plugin/skills/number-duration-inputs/SKILL.md`, including:
- Clearer explanations of button disabling at min/max, cursor behavior
after step actions, and the distinction between button gating and
keyboard input for min/max.
[[1]](diffhunk://#diff-a386dd0ac15caaea86790a023d92a41226e4e9e00c5c1d99393b236576a9db45L13-R13)
[[2]](diffhunk://#diff-a386dd0ac15caaea86790a023d92a41226e4e9e00c5c1d99393b236576a9db45L44-R78)
[[3]](diffhunk://#diff-a386dd0ac15caaea86790a023d92a41226e4e9e00c5c1d99393b236576a9db45L108-R125)
[[4]](diffhunk://#diff-a386dd0ac15caaea86790a023d92a41226e4e9e00c5c1d99393b236576a9db45L121-R138)
[[5]](diffhunk://#diff-a386dd0ac15caaea86790a023d92a41226e4e9e00c5c1d99393b236576a9db45R148-R161)
- Added a new "Gotchas & Edge Cases" section covering input parsing,
cursor movement, focus node responsibility, and decimal separator
effects.
- Improved parameter descriptions and added more usage examples and
testing patterns.
[[1]](diffhunk://#diff-a386dd0ac15caaea86790a023d92a41226e4e9e00c5c1d99393b236576a9db45L162-R194)
[[2]](diffhunk://#diff-a386dd0ac15caaea86790a023d92a41226e4e9e00c5c1d99393b236576a9db45L174-R214)
[[3]](diffhunk://#diff-a386dd0ac15caaea86790a023d92a41226e4e9e00c5c1d99393b236576a9db45L197-R226)
[[4]](diffhunk://#diff-a386dd0ac15caaea86790a023d92a41226e4e9e00c5c1d99393b236576a9db45L209-R238)
[[5]](diffhunk://#diff-a386dd0ac15caaea86790a023d92a41226e4e9e00c5c1d99393b236576a9db45L226-L227)
[[6]](diffhunk://#diff-a386dd0ac15caaea86790a023d92a41226e4e9e00c5c1d99393b236576a9db45L240-L241)
**Bug Fixes and Improvements (as documented in `CHANGELOG.md`):**
* Fixed `ThemedNumberInput` memory leak by properly disposing of its
`TextEditingController`.
* Fixed `inputRegExp` parameter being ignored; custom regex is now
correctly applied to input filtering.
* Fixed unsafe `onChanged` calls for unparseable input; such input is
now ignored, preserving the last valid value.
* Fixed cursor position after step button tap; cursor now moves to the
end of the number as expected.
* Improved step button UX: buttons show 0.4 opacity and ignore taps at
boundaries, with new `prefixIconDisabled`/`suffixIconDisabled` support
in `ThemedTextInput`.
**Testing and Examples:**
* Added comprehensive widget tests and example patterns for
`ThemedNumberInput`, covering rendering, keyboard and button
interactions, cursor behavior, locale formatting, lifecycle, and edge
cases.
[[1]](diffhunk://#diff-06572a96a58dc510037d5efa622f9bec8519bc1beab13c9f251e97e657a9d4edR3-R15)
[[2]](diffhunk://#diff-a386dd0ac15caaea86790a023d92a41226e4e9e00c5c1d99393b236576a9db45L254-R424)
**Version and Example Updates:**
* Bumped plugin version to `7.5.26` in `.claude-plugin/plugin.json`.
* Updated example view state in `example/lib/views/inputs/src/text.dart`
to include new fields for testing.
* Updated the changelog to reflect all fixes, improvements, and new
documentation.9 files changed
Lines changed: 998 additions & 101 deletions
File tree
- .claude-plugin
- skills/number-duration-inputs
- example
- lib/views/inputs/src
- lib/src/inputs/src/general
- test/widgets
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
| 4 | + | |
5 | 5 | | |
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
3 | 16 | | |
4 | 17 | | |
5 | 18 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
12 | 17 | | |
13 | 18 | | |
14 | 19 | | |
| |||
147 | 152 | | |
148 | 153 | | |
149 | 154 | | |
150 | | - | |
151 | | - | |
152 | | - | |
153 | | - | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
154 | 162 | | |
155 | 163 | | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
156 | 173 | | |
157 | | - | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
158 | 218 | | |
159 | | - | |
160 | 219 | | |
161 | | - | |
162 | | - | |
163 | | - | |
164 | | - | |
| 220 | + | |
| 221 | + | |
165 | 222 | | |
166 | 223 | | |
| 224 | + | |
| 225 | + | |
167 | 226 | | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
168 | 278 | | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
169 | 289 | | |
170 | | - | |
171 | | - | |
172 | | - | |
173 | | - | |
174 | | - | |
175 | | - | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
176 | 317 | | |
177 | 318 | | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
| 333 | + | |
| 334 | + | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
178 | 339 | | |
179 | 340 | | |
180 | 341 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
390 | 390 | | |
391 | 391 | | |
392 | 392 | | |
393 | | - | |
| 393 | + | |
394 | 394 | | |
395 | 395 | | |
396 | 396 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
| 10 | + | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
| 13 | + | |
14 | 14 | | |
15 | 15 | | |
16 | | - | |
| 16 | + | |
17 | 17 | | |
18 | 18 | | |
19 | | - | |
| 19 | + | |
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| |||
130 | 130 | | |
131 | 131 | | |
132 | 132 | | |
133 | | - | |
| 133 | + | |
| 134 | + | |
134 | 135 | | |
135 | 136 | | |
136 | 137 | | |
| |||
155 | 156 | | |
156 | 157 | | |
157 | 158 | | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
158 | 165 | | |
159 | 166 | | |
160 | 167 | | |
| |||
167 | 174 | | |
168 | 175 | | |
169 | 176 | | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
170 | 186 | | |
171 | 187 | | |
172 | 188 | | |
173 | 189 | | |
174 | | - | |
175 | 190 | | |
176 | 191 | | |
177 | 192 | | |
| |||
208 | 223 | | |
209 | 224 | | |
210 | 225 | | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
211 | 233 | | |
212 | 234 | | |
213 | 235 | | |
| |||
218 | 240 | | |
219 | 241 | | |
220 | 242 | | |
| 243 | + | |
221 | 244 | | |
222 | | - | |
| 245 | + | |
| 246 | + | |
223 | 247 | | |
224 | | - | |
225 | | - | |
226 | | - | |
227 | 248 | | |
228 | 249 | | |
229 | 250 | | |
| 251 | + | |
230 | 252 | | |
231 | | - | |
| 253 | + | |
| 254 | + | |
232 | 255 | | |
233 | | - | |
234 | | - | |
235 | | - | |
236 | 256 | | |
237 | 257 | | |
238 | 258 | | |
| |||
242 | 262 | | |
243 | 263 | | |
244 | 264 | | |
245 | | - | |
| 265 | + | |
246 | 266 | | |
247 | 267 | | |
248 | 268 | | |
249 | | - | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
250 | 273 | | |
251 | 274 | | |
252 | 275 | | |
253 | | - | |
254 | | - | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
255 | 279 | | |
256 | 280 | | |
257 | 281 | | |
| |||
0 commit comments