From 4516f67e1533cc981dd524868cb5c47b81200834 Mon Sep 17 00:00:00 2001 From: "Restyled.io" Date: Wed, 29 Sep 2021 04:44:55 +0000 Subject: [PATCH] Restyled by prettier --- content/docs/command-reference/exp/show.md | 3 +- src/components/DownloadButton/index.tsx | 70 +++++++++++----------- 2 files changed, 36 insertions(+), 37 deletions(-) diff --git a/content/docs/command-reference/exp/show.md b/content/docs/command-reference/exp/show.md index 00c113fc699..ba98f6d4fb1 100644 --- a/content/docs/command-reference/exp/show.md +++ b/content/docs/command-reference/exp/show.md @@ -115,7 +115,8 @@ metric or param. - `--show-json` - prints the command's output in easily parsable JSON format, instead of a human-readable table. -- `--show-csv` - prints the command's output in CSV format instead of a human-readable table. +- `--show-csv` - prints the command's output in CSV format instead of a + human-readable table. - `--precision ` - [round](https://docs.python.org/3/library/functions.html#round) decimal values diff --git a/src/components/DownloadButton/index.tsx b/src/components/DownloadButton/index.tsx index 9916965e11b..1621601928d 100644 --- a/src/components/DownloadButton/index.tsx +++ b/src/components/DownloadButton/index.tsx @@ -78,44 +78,42 @@ const getUserOS = (): OS => { return OSName } -const DownloadButtonDropdownItems: React.FC = ({ - onClick, - userOS -}) => { - return ( -
- {dropdownItems.map((os, index) => { - if (os === null) { +const DownloadButtonDropdownItems: React.FC = + ({ onClick, userOS }) => { + return ( +
+ {dropdownItems.map((os, index) => { + if (os === null) { + return ( +
+ ) + } + + const item = itemsByOs[os] + return ( -
+ onClick(os)} + > + {item.title} + ) - } - - const item = itemsByOs[os] - - return ( - onClick(os)} - > - {item.title} - - ) - })} -
- ) -} + })} +
+ ) + } const DownloadButton: React.FC = ({ openTop }) => { const userOS = useRef(getUserOS())