diff --git a/source/components/rule/References.js b/source/components/rule/References.js index 483db7976..154366a63 100644 --- a/source/components/rule/References.js +++ b/source/components/rule/References.js @@ -1,62 +1,72 @@ -import React from 'react' -import R from 'ramda' -import './References.css' -import references from 'Règles/ressources/références/références.yaml' +import React from "react" +import R from "ramda" +import "./References.css" +import references from "Règles/ressources/références/références.yaml" export default class References extends React.Component { state = { showComplementary: false } - render(){ - let - {refs} = this.props, - {complementary, official} = - R.groupBy( ([name, link]) => - this.findRefKey(link) ? 'official' : 'complementary' + render() { + let { refs } = this.props, + { complementary, official } = R.groupBy( + ([name, link]) => (this.findRefKey(link) ? "official" : "complementary") )(R.toPairs(refs)), showComplementary = this.state.showComplementary, showComplementaryButton = !this.state.showComplementary && complementary - return