In 3.9.x, ESLint changed how many spaces are expected on a trailing
parens following a return. Previously it expected:
```
01234567890
return (
<div>
</div>
);
01234567890
^~~~~~~~ It previously expected 5 spaces here
01234567890
return (
<div>
</div>
);
01234567890
^~~~~~~~~~ Now it wants 3
```
Until we're ready to explicitly make that change, we're going to pin to
3.5.x (which expects 5 spaces in the example above.
This populates the /mappings with data found in the LayoutStore. It uses
the ID for the layout as the mappings Name and pulls the Measurement
from there as well.
The JSON encoder was very upset with the ,string struct tag option. It
spat out the error:
json: invalid use of ,string struct tag, trying to unmarshal
"18aed9a7-dc83-406e-a4dc-40d53049541a" into string
The documentation appears to be incomplete on this struct tag option,
and removing it fixes this error.
I and Name were added to support react-grid-layout. They were added to
the chronograf types, but not to the protobuf definitions, so the only
layouts that could make use of them were the canned variety. This allows
layouts' I and Name to be persisted as well.
Somehow an unused FlashMessages snuck in during the rebase. Also there
were places where Mappings was expecting a *string, but we were passing
a string. I believe this is because the autogenerated code creates
*string, and I modified it to use strings at one point. Everywhere
should use *string now.
React-grid-layout uses an "i" parameter in the JSON describing a layout
as an identifier. This is used to bind DOM elements' keys to Cells from
the API. Also, we need a "Name" to describe what each graph is to a
user.
Also, react-grid-layout specified widths and heights in terms of units
of the grid that it establishes. In order to have this properly
configured, the extents of this grid need to be spelled out when
creating a ReactGridLayout, hence the addition of "cols" and
"rowHeight" props to that component.
Finally, react-grid-layout incorporates some of its own styles. To
support this, some modifications needed to be made to the webpack config
to allow us to pull in includes from node_modules.