Skip to content

Commit

Permalink
Wire up some more
Browse files Browse the repository at this point in the history
  • Loading branch information
oleavr committed Sep 24, 2024
1 parent 23618dd commit e6c69a6
Show file tree
Hide file tree
Showing 5 changed files with 38 additions and 21 deletions.
3 changes: 2 additions & 1 deletion apps/tracer/src/App.css
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
display: flex;
flex: 1;
flex-direction: column;
white-space: nowrap;
}

.editor-area section {
Expand Down Expand Up @@ -66,7 +67,7 @@
}

.bottom-tabs .bp5-tab-list {
padding-left: 5px;
padding-left: 10px;
}

.bottom-tabs .bp5-tab:focus {
Expand Down
2 changes: 1 addition & 1 deletion apps/tracer/src/DisassemblyView.css
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@

a.disassembly-menu-open {
background-color: #ef6456;
}
}
7 changes: 6 additions & 1 deletion apps/tracer/src/DisassemblyView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -104,9 +104,14 @@ export default function DisassemblyView({ target }: DisassemblyViewProps = {}) {
target.classList.add("disassembly-menu-open");
}, [handleAddressMenuClose, addressMenu]);

if (isLoading) {
return (
<Spinner className="disassembly-view" />
);
}

return (
<div className="disassembly-view" onContextMenu={handleContextMenu}>
{isLoading ? (<Spinner className="disassembly-view" />) : undefined}
{r2Output.map((line, i) => <div key={i} dangerouslySetInnerHTML={{ __html: line }} />)}
</div>
);
Expand Down
25 changes: 17 additions & 8 deletions apps/tracer/src/EventView.css
Original file line number Diff line number Diff line change
Expand Up @@ -13,30 +13,39 @@
}

.event-item {
padding-top: 2px;
display: grid;
grid-template-columns: min-content;
white-space: nowrap;
}

.event-summary {
grid-row: 1;
grid-column: 1;
}

.event-details {
grid-row: 2;
grid-column: 1;
padding-right: 24px !important;
}

.event-timestamp {
padding: 0 10px;
color: #555;
margin-left: 5px;
margin-right: 5px;
vertical-align: middle;
text-align: right;
}

.event-message {
min-height: 0;
text-align: left;
font-size: 12px;
font-weight: bold;
white-space: pre-line;
}

.event-message:focus {
outline: 0;
}

.event-highlighted {
.event-highlighted .event-summary {
background-color: #ef6456;
}

Expand Down Expand Up @@ -74,4 +83,4 @@

.event-dismiss {
margin-top: 10px;
}
}
22 changes: 12 additions & 10 deletions apps/tracer/src/EventView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -74,16 +74,18 @@ export default function EventView({ events, highlightedIndex = null, onActivate,
ref={isHighlighted ? highlightedRef : undefined}
className={eventClasses.join(" ")}
>
<span className="event-timestamp">{timestampStr} ms</span>
<span className={"event-indent " + colorClass}>{INDENT.repeat(depth)}</span>
<Button
className={"event-message " + colorClass}
minimal={true}
alignText="left"
onClick={() => onActivate(targetId, i)}
>
{message}
</Button>
<div className="event-summary">
<span className="event-timestamp">{timestampStr} ms</span>
<span className={"event-indent " + colorClass}>{INDENT.repeat(depth)}</span>
<Button
className={"event-message " + colorClass}
minimal={true}
alignText="left"
onClick={() => onActivate(targetId, i)}
>
{message}
</Button>
</div>
{isHighlighted ? (
<Card className="event-details" interactive={true} compact={true}>
<table>
Expand Down

0 comments on commit e6c69a6

Please sign in to comment.