
So i'm stealing code borrowing an example from the CSS Wizardry wiki, for the "Fill Radio Buttons to the Left" section. I've made a couple of tweaks, namely: 1: As I will be doing this for numerous sections of my character sheet (Every skill has the same setup), i've couched the binder loop in another foreach, that will contain my 'types'. 2: I've added a "0" to the example. 3: The test fire of this system is inside a repeating section. I *suspect* that it's this one that's causing my problem? The Sheet Worker code now reads: <script type="text/worker">
const dotTypes = ["membertemp"];
const dotValues = ["0","1","2","3","4","5"];
dotTypes.forEach(function(type) {
dotValues.forEach(function(value) {
console.log(`${type}-${value} Bind`);
on(`clicked:${type}-${value}`, function() {
console.log(`clicked:${type}-${value}`);
setAttrs({
type: value
});
console.log(type + ": "+ value);
});
});
});
</script> (the console.logs have obviously been added to try and debug) And the corresponding repeating section reads as: <fieldset class="repeating_memberships" name="repeating_memberships">
<input type="text" name="attr_membername">
<input type="number" name= "attr_memberrank" value="1">
<div class="dots">
<input type="hidden" name="attr_membertemp" class="dot" value="1" />
<button type="action" name="act_membertemp-0" class="dot">
<span class="checked"></span>
</button>
<button type="action" name="act_membertemp-1" class="dot gt-0">
<span class="checked"></span>
</button>
<button type="action" name="act_membertemp-2" class="dot gt-0 gt-1">
<span class="checked"></span>
</button>
<button type="action" name="act_membertemp-3" class="dot gt-0 gt-1 gt-2">
<span class="checked"></span>
</button>
<button type="action" name="act_membertemp-4" class="dot gt-0 gt-1 gt-2 gt-3">
<span class="checked"></span>
</button>
<button type="action" name="act_membertemp-5" class="dot gt-0 gt-1 gt-2 gt-3 gt-4">
<span class="checked"></span>
</button>
</div>
</fieldset> I see the "bind" messages scroll through, but the buttons are nonresponsive. I tried changing the binding string to clicked:repeating_memberships:${type}-${value}, but that also did not produce a reaction on button click. What have I messed up here?