Skip to content

Commit e000698

Browse files
tojoqkjeapostrophe
authored andcommitted
Add #:wrap to checkbox-group
1 parent 8d9c0f7 commit e000698

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

web-server-lib/web-server/formlets/input.rkt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,8 @@
5555
(#:attributes
5656
(-> any/c (listof (list/c symbol? string?)))
5757
#:checked? (any/c . -> . boolean?)
58-
#:display (any/c . -> . pretty-xexpr/c))
58+
#:display (any/c . -> . pretty-xexpr/c)
59+
#:wrap (any/c any/c . -> . xexpr-forest/c))
5960
(serial-formlet/c (listof any/c)))]
6061
[submit (->* ((or/c bytes? string?))
6162
(#:attributes (listof (list/c symbol? string?)))

web-server-lib/web-server/formlets/unsafe/input.rkt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -206,12 +206,14 @@
206206
(define (checkbox-group l
207207
#:attributes [attrs (λ (x) null)]
208208
#:checked? [checked? (λ (x) #f)]
209-
#:display [display (λ (x) x)])
209+
#:display [display (λ (x) x)]
210+
#:wrap [wrap (λ (x y) (list x y))])
210211
(input-group l
211212
#:kind "checkbox"
212213
#:attributes attrs
213214
#:checked? checked?
214-
#:display display))
215+
#:display display
216+
#:wrap wrap))
215217

216218
(define (submit value
217219
#:attributes [attrs null])

0 commit comments

Comments
 (0)