clinwiki-org / clinwiki

Crowd-source tool to annotate, rank and generally enhance the clarity and accuracy of clinical trial information.
https://www.clinwiki.org
MIT License
16 stars 16 forks source link

helper text crowd_values #1059

Open williamhoos opened 3 years ago

williamhoos commented 3 years ago

Should be done only after helper text for crowd_keys are complete

Written assuming mailmerge/handlebar support

New format of helper text with and without document count in CHECKBOX bucket list, creating new display name, maintaining current value for "on submit" "bucketTemplate" : "{{crowd_value}} ({{docCount}})"

Alternative template examples enabled: No counts "bucketTemplate" : "{{crowd_value}}"

Reverse order, no parenthesis "bucketTemplate" : "{{docCount}} {{crowd_value}}"

Adding helper text "bucketTemplate" : "{{crowd_value}} ({{docCount}}) [span class="mm-tooltip"][u][i class="fa fa-info-circle"][/u][span class="mm-tooltiptext mm-tooltip-tr"]{{crowd_value_helper_text}}[/span]" (note: using ] and [ to avoid html in issue comments here from > and < "

Would also support using crowd_value_description instead of crowd_value for display of bucketTemplate

mock-up image

williamhoos commented 3 years ago

the example mockup above is actually a ctgov field, not a crowd_key, so need to discuss basic support for non-crowd aggs. Should work to still set-up as a crowd_key and crowd_values, but need to confirm how the info will be pulled from combination of agg query to elastic and list of crowd_values (ie how a "missing" crowd_value table entry that is present in the ctgov data (and therefore the index) is merged into the list of values in the facet without error