|
1 | | -import { IContextualMenuItem, IconButton, SpinnerSize, TextField } from "@fluentui/react"; |
| 1 | +import { IContextualMenuItem, SpinnerSize, TextField } from "@fluentui/react"; |
2 | 2 | import classNames from "classnames"; |
3 | 3 | import * as React from "react"; |
4 | 4 | import { useDispatch, useSelector } from "react-redux"; |
5 | 5 |
|
6 | 6 | import QueryFooter from "./QueryFooter"; |
| 7 | +import { TertiaryButton, TransparentIconButton } from "../Buttons"; |
7 | 8 | import LoadingIcon from "../Icons/LoadingIcon"; |
8 | 9 | import QueryDataSource from "../QueryPart/QueryDataSource"; |
9 | 10 | import QueryFilter from "../QueryPart/QueryFilter"; |
@@ -119,12 +120,10 @@ export default function Query(props: QueryProps) { |
119 | 120 | <i>Building new query...</i> |
120 | 121 | </h4> |
121 | 122 | </Tooltip> |
122 | | - <IconButton |
123 | | - ariaDescription="Expand view details" |
124 | | - ariaLabel="Expand" |
| 123 | + <TransparentIconButton |
125 | 124 | className={styles.expandButton} |
126 | 125 | disabled |
127 | | - iconProps={{ iconName: "ChevronDownMed" }} |
| 126 | + iconName="ChevronDownMed" |
128 | 127 | /> |
129 | 128 | </div> |
130 | 129 | <hr className={styles.divider}></hr> |
@@ -154,13 +153,11 @@ export default function Query(props: QueryProps) { |
154 | 153 | <Tooltip content={props.query.name}> |
155 | 154 | <h4>{props.query.name}</h4> |
156 | 155 | </Tooltip> |
157 | | - <IconButton |
158 | | - ariaDescription="Expand view details" |
159 | | - ariaLabel="Expand" |
| 156 | + <TransparentIconButton |
160 | 157 | className={styles.expandButton} |
161 | 158 | onClick={() => setIsExpanded(!isExpanded)} |
162 | | - iconProps={{ iconName: "ChevronDownMed" }} |
163 | | - data-testid="expand-button" |
| 159 | + iconName="ChevronDownMed" |
| 160 | + id="expand-button" |
164 | 161 | /> |
165 | 162 | </div> |
166 | 163 | {!isExpanded && <hr className={styles.divider}></hr>} |
@@ -214,13 +211,12 @@ export default function Query(props: QueryProps) { |
214 | 211 | } |
215 | 212 | /> |
216 | 213 | </div> |
217 | | - <IconButton |
218 | | - ariaDescription="Collapse view details" |
219 | | - ariaLabel="Collapse" |
| 214 | + <TertiaryButton |
220 | 215 | className={styles.collapseButton} |
221 | 216 | onClick={() => setIsExpanded(!isExpanded)} |
222 | | - iconProps={{ iconName: "ChevronUpMed" }} |
| 217 | + iconName="ChevronUpMed" |
223 | 218 | data-testid="collapse-button" |
| 219 | + title="Collapse query details" |
224 | 220 | /> |
225 | 221 | </div> |
226 | 222 | <QueryDataSource |
|
0 commit comments