slib_lang_exists_tmp=yes

slib_title=Chemical components
slib_parms=4\
 , chemical equation\
 , [optional] the word <span class="tt">htmlbuttons</span> followed by a space and one number\
 , [optional] the word <span class="tt">shuffle</span>\
 , [optional] a list of words to be appended, enclosed in brackets. Some words are magical: \
 <span class="tt">extra</span> expands to '+,->' ; <span class="tt">redox_extra</span> expands to 'H^+_aq,OH^-_aq,H2O,e^-'.

slib_out= Outputs a matrix of the reactives in the first line, and the products in \
the second line. <br/>If the parameter <span class="tt">htmlbuttons</span> is specified, the output \
is some code to make clickable buttons; then, the number refers to a reply \
field which will receive the results of the buttons' events. <br/>If the \
parameter <span class="tt">shuffle</span> is specified, the buttons are shuffled. <br/>These buttons \
can be made active if the following javascript code is added in the page: \
<pre style="color:green;">\
&lt;script type="text/javascript"&gt;\
function getInput(n){\
  f=window.document.forms[0];\
  for(i=0; i&lt;f.elements.length; i=i+1){\
    if (f.elements[i].name=="reply"+n) { \
      return f.elements[i];\
    }\
  }\
  return null;\
}\
function appendToInput(n,msg){\
  var i=getInput(n);\
  i.value=i.value+msg+' ';\
  i.focus();\
}\
&lt;/script&gt;\
</pre>

slib_comment=use the syntax accepted by the command chemeq
