import React from 'react' import SelectedVariable from './SelectedVariable' import colors from './variable-colors.yaml' console.log(colors.length); import R from 'ramda' function convertHex(hex,opacity){ let r = parseInt(hex.substring(0,2), 16), g = parseInt(hex.substring(2,4), 16), b = parseInt(hex.substring(4,6), 16), result =`rgba(${r},${g},${b},${opacity})` return result } const Variable = ({color, name, selectVariable}) =>
  • selectVariable(name)} >

    {name}

  • export default class Variables extends React.Component { render(){ let {variables, selectedTags, selectedVariable, selectVariable} = this.props console.log('variables prop in set.add(variable), new Set()), // get unique variable names // variableColors = [...variableSet].reduce((correspondance, v, i) => Object.assign(correspondance, {[v]: colors[i]}), {}) console.log('selectedVariable',selectedVariable) if (selectedVariable != null) return return } }