Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file removed build/1dc35d25e61d819a9c357074014867ab.ttf
Binary file not shown.
Binary file removed build/25a32416abee198dd821b0b17a198a8f.eot
Binary file not shown.
53 changes: 27 additions & 26 deletions build/bundle.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion build/bundle.js.map

Large diffs are not rendered by default.

Binary file removed build/c8ddf1e5e5bf3682bc7bebf30f394148.woff
Binary file not shown.
685 changes: 0 additions & 685 deletions build/d7c639084f684d66a1bc66855d193ed8.svg

This file was deleted.

Binary file removed build/e6cf7c6ec7c2d6f670ae9d762604cb0b.woff2
Binary file not shown.
10 changes: 5 additions & 5 deletions i18n/query.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@

"weekday": "Weekday",
"weekday_hint": "on {weekday}",
"author": "Author",
"author": "Author (plays 1, 2, and 3)",
"author_n": "Author",
"author_n_hint": "for author {author_1}",
"author_1": "Author (overture)",
Expand All @@ -59,7 +59,7 @@
"title_2_hint": "where the second title is {title_2}",
"title_3": "Third title",
"title_3_hint": "where the third title is {title_3}",
"genre": "Genre",
"genre": "Genre (pièces 1, 2 et 3)",
"genre_n": "Genre",
"genre_n_hint": "for the {genre} genre",
"genre_1": "Genre (overture)",
Expand Down Expand Up @@ -97,7 +97,7 @@
"filter_button_all": "Utiliser tous les filtres",
"filter_button_clear_all": "Supprimer les filtres",
"sum_receipts": "Somme des recettes",
"sum_receipts_weighted": "Somme recette (pondérée)",
"sum_receipts_weighted": "Somme recette",
"performances_days": "Représentations / jour",
"mean_receipts_day": "Moyenne des recettes / jour",
"mean_receipts_day_weighted": "Moyenne recette/jour (pondérée)",
Expand Down Expand Up @@ -125,7 +125,7 @@
"day": "Jour",
"weekday": "Jour de la semaine",
"weekday_hint": "pour le {weekday}",
"author": "Auteur",
"author": "Auteur (pièces 1, 2 et 3)",
"author_n": "Auteur",
"author_n_hint": "pour l'auteur {author_1}",
"author_1": "Auteur de la première pièce",
Expand All @@ -143,7 +143,7 @@
"title_2_hint": "dont la 2e pièce est {title_2}",
"title_3": "Troisième pièce",
"title_3_hint": "dont la 3e pièce est {title_3}",
"genre": "Genre",
"genre": "Genre (pièces 1, 2 et 3)",
"genre_n": "Genre",
"genre_n_hint": "des {genre}s",
"genre_1": "Genre de la première pièce",
Expand Down
4 changes: 2 additions & 2 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
</head>
<!-- development index.html, with configuration for local or remote analytics api server -->
<!-- <body data-analytics="http://localhost:3000/api/cfrp"> -->
<body data-analytics="http://cfrp.herokuapp.com/api/cfrp">
<script src="build/bundle.js?890cc72"></script>
<body data-analytics="http://cfrp-staging.herokuapp.com/api/cfrp">
<script src="build/bundle.js?00f59b5"></script>
</body>
</html>
56 changes: 30 additions & 26 deletions js/query/filter.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,33 +59,37 @@ Filter.render = function(modal_state, query_state, dim, axis, lang) {
var sel_values = modal_state.filter_selection[dim] || []

values.forEach( (d, i) => {
if (strMatch(d, query_state.filter_state.search)) {
var attrs = { type: 'checkbox',
id: d,
name: d,
'ev-event': hg.sendChange(modal_state.channels.toggleFilterValue, { dim: dim, value: d } ) }

if(sel_values.indexOf(d) > -1 || modal_state.selectAll[dim]) {
attrs.checked = true;
}
cbs.push(
// TODO. virtual-dom doesn't match changes in <input checked ... /> properly
// a parallel issue for Mithril: https://github.com/lhorie/mithril.js/issues/691
// one workaround is to cache-bust the entire list with a key:
h('li.custom-checkbox',
{
key: unique_key++,
'ev-click': hg.send(modal_state.channels.toggleFilterValue, { dim: dim, value: d } )
},
[
h('input', attrs),
h('label' + (attrs.checked ? '.selected-filter': ''), [
h('span.custom-input', h('span.custom-input')),
h('span', formatter(d))
])
]
if (d !== "" && d !== "0" && d !== 0) {
debugger;
if (strMatch(d, query_state.filter_state.search)) {
var attrs = { type: 'checkbox',
id: d,
name: d,
'ev-event': hg.sendChange(modal_state.channels.toggleFilterValue, { dim: dim, value: d } ) }

if(sel_values.indexOf(d) > -1 || modal_state.selectAll[dim]) {
attrs.checked = true;
}

cbs.push(
// TODO. virtual-dom doesn't match changes in <input checked ... /> properly
// a parallel issue for Mithril: https://github.com/lhorie/mithril.js/issues/691
// one workaround is to cache-bust the entire list with a key:
h('li.custom-checkbox',
{
key: unique_key++,
'ev-click': hg.send(modal_state.channels.toggleFilterValue, { dim: dim, value: d } )
},
[
h('input', attrs),
h('label' + (attrs.checked ? '.selected-filter': ''), [
h('span.custom-input', h('span.custom-input')),
h('span', formatter(d))
])
]
)
)
)
}
}
})

Expand Down