1 | // magic javascript to add additional empty selectors |
2 | // when last one is filled by user. |
3 | // only tested with a ComboBox itemRenderer |
4 | |
5 | set needsJQuery; |
6 | int n = l(list)+1; |
7 | out.add(hjs("var \*name*/_n = " + n + ";")); |
8 | for i to n: |
9 | out.add(renderInput(name + "_" + i, r.itemRenderer, _get(list, i))); |
10 | out.add(hjs("\*name*/_\*n-1*/")); |
download show line numbers debug dex old transpilations
Travelled to 7 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt, xrpafgyirdlv
No comments. add comment
Snippet ID: | #1029603 |
Snippet name: | magic javascript for FlexibleLengthList [dev.] |
Eternal ID of this version: | #1029603/1 |
Text MD5: | fae5bc242b3df179e539d99963096919 |
Author: | stefan |
Category: | javax / html |
Type: | JavaX (incomplete) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2020-08-27 15:31:09 |
Source code size: | 403 bytes / 10 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 153 / 189 |
Referenced in: | [show references] |