Skip to content

Commit f0475d3

Browse files
committed
More icons
1 parent 63cb148 commit f0475d3

File tree

8 files changed

+34
-22
lines changed

8 files changed

+34
-22
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "jderobot-ide-interface",
3-
"version": "0.1.47",
3+
"version": "0.1.48",
44
"main": "dist/main.js",
55
"typings": "dist/index.d.ts",
66
"files": [

src/assets/index.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,5 @@ export { ReactComponent as ResetIcon } from "./reset.svg";
1818
export { ReactComponent as RenameIcon } from "./rename.svg";
1919
export { ReactComponent as SaveIcon } from "./save.svg";
2020
export { ReactComponent as SplashIcon } from "./logo_jderobot.svg";
21+
export { ReactComponent as MinusIcon } from "./minus.svg";
22+
export { ReactComponent as PlusIcon } from "./plus.svg";

src/assets/minus.svg

Lines changed: 4 additions & 0 deletions
Loading

src/assets/plus.svg

Lines changed: 5 additions & 0 deletions
Loading

src/components/FileEditor/FileEditor.tsx

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
11
import { useEffect, useRef, useState } from "react";
22

3-
import { SaveIcon } from "Assets";
3+
import { SaveIcon, MinusIcon, PlusIcon } from "Assets";
44
import { useError, useTheme } from "Utils";
55
import { CommsManager } from "jderobot-commsmanager";
66
import { Entry, EditorsEntry } from "Types";
77
import TextEditor from "./TextEditor";
88
import {
99
MenuButton,
10+
MenuButtonStroke,
1011
StyledButtonsContainer,
1112
StyledSeparatedButtonsContainer,
1213
} from "Components";
@@ -229,20 +230,20 @@ const FileEditor = ({
229230
>
230231
<SaveIcon viewBox="0 0 .9375 .9375" />
231232
</MenuButton>
232-
<MenuButton
233+
<MenuButtonStroke
233234
id="zoom-in-button"
234235
onClick={handleZoomIn}
235236
title="Increase Zoom"
236237
>
237-
+
238-
</MenuButton>
239-
<MenuButton
238+
<PlusIcon viewBox="0 0 20 20" />
239+
</MenuButtonStroke>
240+
<MenuButtonStroke
240241
id="zoom-out-button"
241242
title="Decrease Zoom"
242243
onClick={handleZoomOut}
243244
>
244-
-
245-
</MenuButton>
245+
<MinusIcon viewBox="0 0 20 20" />
246+
</MenuButtonStroke>
246247
{(() => {
247248
for (const editor of extraEditors) {
248249
if (editor.language === language) {

src/components/IdeInterface/IdeInterface.stories.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,7 @@ export const Main: Story = {
7979
api={api}
8080
extraEditors={[]}
8181
viewers={[gazeboViewer, terminalViewer]}
82+
statusBarComponents={{ extras: [] }}
8283
/>
8384
</div>
8485
),

src/components/Modals/Modal.styles.ts

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { BackIcon, CloseIcon } from "Assets";
1+
import { BackIcon, CloseIcon, MinusIcon } from "Assets";
22
import styled from "styled-components";
33

44
const primaryColor = "#666";
@@ -79,28 +79,26 @@ export const StyledModalTitlebar = styled.div<StyledModalTitlebarProps>`
7979
}
8080
`;
8181

82-
interface StyledModalCloseButtonProps {
82+
interface StyledModalButtonProps {
8383
color?: string;
8484
}
8585

86-
export const StyledModalCloseButton = styled(
87-
CloseIcon,
88-
)<StyledModalCloseButtonProps>`
86+
export const StyledModalCloseButton = styled(CloseIcon)<StyledModalButtonProps>`
8987
fill: ${(p) => p.color ?? primaryColor};
9088
margin-left: auto;
9189
`;
9290

93-
interface StyledModalBackButtonProps {
94-
color?: string;
95-
}
96-
97-
export const StyledModalBackButton = styled(
98-
BackIcon,
99-
)<StyledModalBackButtonProps>`
91+
export const StyledModalBackButton = styled(BackIcon)<StyledModalButtonProps>`
10092
fill: ${(p) => p.color ?? primaryColor};
10193
margin-right: auto;
10294
`;
10395

96+
export const StyledModalDeleteButton = styled(
97+
MinusIcon,
98+
)<StyledModalButtonProps>`
99+
stroke: ${(p) => p.color ?? primaryColor};
100+
`;
101+
104102
interface StyledModalRowProps {
105103
color?: string;
106104
buttonColor?: string;

src/components/Modals/Modal.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import {
55
StyledModalButtonRow,
66
StyledModalCloseButton,
77
StyledModalContent,
8+
StyledModalDeleteButton,
89
StyledModalDropArea,
910
StyledModalEditableList,
1011
StyledModalInput,
@@ -271,7 +272,7 @@ export const ModalEditableList = ({
271272
return (
272273
<div id={"project-" + entry} onClick={(e: any) => onSelect(e, entry)}>
273274
<label>{entry}</label>
274-
<StyledModalCloseButton
275+
<StyledModalDeleteButton
275276
viewBox="0 0 20 20"
276277
title="Delete"
277278
id={"delete-" + entry}
@@ -355,7 +356,7 @@ export const ModalInputDropArea = ({
355356
return (
356357
<StyledModalDropArea
357358
ref={areaRef}
358-
id={id + '-area'}
359+
id={id + "-area"}
359360
htmlFor={id}
360361
onDragOver={(e) => {
361362
e.preventDefault();

0 commit comments

Comments
 (0)