Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Change run picker menu to use three dots and update stop timeseries icon [PT-187736835] #161

Merged
merged 1 commit into from
Jul 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/mobile-app/components/run-picker.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ export const RunPicker: React.FC<IProps> = ({ runs, onRunSelect, onRunUpload, on
<div className={css.icon}><Icon name="upload" /></div><div className={css.text}>Upload</div></div> : undefined}
</div>
<div className={css.menuContainer}>
<MenuComponent>
<MenuComponent icon="more">
{onRunEdit ? <MenuItemComponent icon={"create"} onClick={onRunEdit.bind(null, run)}>Edit</MenuItemComponent> : undefined}
{onRunUpload ? <MenuItemComponent icon={"upload"} onClick={onRunUpload.bind(null, run)}>Upload</MenuItemComponent> : undefined}
{onRunDelete ? <MenuItemComponent icon={"delete"} onClick={onRunDelete.bind(null, run)}>Delete</MenuItemComponent> : undefined}
Expand Down
4 changes: 4 additions & 0 deletions src/shared/components/data-table-field.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,10 @@ $headerBorder: #fff;
&.record {
background-color: $sensorGreenLight1;
}
&.timeSeriesStop {
background-color: #fff;
border: 4px solid #00a80a;
}
&:hover:not(.disabled) {
cursor: pointer;
}
Expand Down
1 change: 1 addition & 0 deletions src/shared/components/data-table-field.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -461,6 +461,7 @@ export const DataTableField: React.FC<FieldProps> = props => {
[css.refresh]: !sensorFieldsBlank,
[css.record]: sensorFieldsBlank,
[css.disabled]: buttonDisabled,
[css.timeSeriesStop]: iconName === "stopDataTrial",
});
const refreshBtnCell = <td key="refreshBtn" className={`${css.refreshSensorReadingColumn} ${css.readOnly}`}>
{
Expand Down
4 changes: 3 additions & 1 deletion src/shared/components/icon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import RecordDataTrial from "../icons/record-data-trial.svg";
import ReRecordDataTrial from "../icons/re-record-data-trial.svg";
import StopDataTrial from "../icons/stop-data-trial.svg";
import DeleteDataTrial from "../icons/delete-data-trial.svg";
import More from "../icons/more-button.svg";

const Icons = {
label: Label,
Expand All @@ -44,7 +45,8 @@ const Icons = {
recordDataTrial: RecordDataTrial,
reRecordDataTrial: ReRecordDataTrial,
stopDataTrial: StopDataTrial,
deleteDataTrial: DeleteDataTrial
deleteDataTrial: DeleteDataTrial,
more: More
};
export type IconName = keyof typeof Icons;

Expand Down
5 changes: 5 additions & 0 deletions src/shared/icons/more-button.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/shared/icons/stop-data-trial.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading