Skip to content

Commit 6f215b1

Browse files
committed
Merge branch 'release/v3.4.1'
2 parents 361a009 + 6d120e1 commit 6f215b1

File tree

4 files changed

+43
-60
lines changed

4 files changed

+43
-60
lines changed

Diff for: app/media/styles/common.less

+5
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,11 @@ dd {
117117
.text-muted {
118118
color: #777;
119119
}
120+
.text-truncate {
121+
overflow: hidden;
122+
text-overflow: ellipsis;
123+
white-space: nowrap;
124+
}
120125

121126
.inline-buttons button {
122127
margin: 0 5px 5px 0;

Diff for: app/media/styles/modules/inspect.less

+2-12
Original file line numberDiff line numberDiff line change
@@ -36,18 +36,8 @@
3636
}
3737

3838
.inspect-stats-block {
39-
& {
40-
width: auto;
41-
}
42-
43-
td,
44-
th {
45-
padding: 1px 5px;
46-
white-space: nowrap;
47-
}
48-
49-
tr {
50-
cursor: pointer;
39+
.ant-row {
40+
padding-top: 2px;
5141
}
5242
}
5343

Diff for: app/modules/inspect/containers/stats-page.jsx

+35-47
Original file line numberDiff line numberDiff line change
@@ -206,59 +206,47 @@ class MemoryStatisticsPage extends React.PureComponent {
206206

207207
renderTopFiles() {
208208
return (
209-
<Card title="Top 5 Files" className="block ">
210-
<table className="inspect-stats-block">
211-
<tbody>
212-
{this.props.memory.topFiles.map(({ flash, path }) => (
213-
<tr key={path} onClick={::this.handleMemoryClick}>
214-
<td className="text-right">
215-
<b>{formatSize(flash)}</b>
216-
</td>
217-
<td>
218-
<Tooltip title={path} overlayStyle={{ maxWidth: 400 }}>
219-
{limitPathLength(path, 35)}
220-
</Tooltip>
221-
</td>
222-
</tr>
223-
))}
224-
</tbody>
225-
</table>
209+
<Card title="Top 5 Files" className="inspect-stats-block">
210+
{this.props.memory.topFiles.map(({ flash, path }) => (
211+
<Row gutter={10} key={path} onClick={::this.handleMemoryClick}>
212+
<Col xs={6} lg={4} className="text-right text-nowrap">
213+
<b>{formatSize(flash)}</b>
214+
</Col>
215+
<Col xs={18} lg={20} className="text-truncate">
216+
<Tooltip title={path} overlayStyle={{ maxWidth: 400 }}>
217+
{limitPathLength(path, 35)}
218+
</Tooltip>
219+
</Col>
220+
</Row>
221+
))}
226222
</Card>
227223
);
228224
}
229225

230226
renderTopSymbols() {
231227
return (
232-
<Card title="Top 5 Symbols" className="block">
233-
<table className="inspect-stats-block">
234-
<tbody>
235-
{this.props.memory.topSymbols.map((symbol) => (
236-
<tr key={symbol.displayName} onClick={::this.handleSymbolsClick}>
237-
<td className="text-right">
238-
<b>{formatSize(symbol.size)}</b>
239-
</td>
240-
<td>
241-
<div
242-
style={{ overflow: 'hidden', whiteSpace: 'nowrap', width: '100%' }}
243-
>
244-
<Tooltip
245-
title={`${symbol.type} -> ${
246-
symbol.file ? `${symbol.file}:${symbol.line}` : 'unknown'
247-
}`}
248-
overlayStyle={{ maxWidth: 400 }}
249-
>
250-
<Icon
251-
title={SYMBOL_NAME_BY_TYPE[symbol.type]}
252-
type={SYMBOL_ICON_BY_TYPE[symbol.type]}
253-
/>{' '}
254-
{symbol.displayName}
255-
</Tooltip>
256-
</div>
257-
</td>
258-
</tr>
259-
))}
260-
</tbody>
261-
</table>
228+
<Card title="Top 5 Symbols" className="inspect-stats-block">
229+
{this.props.memory.topSymbols.map((symbol) => (
230+
<Row gutter={10} key={symbol.displayName} onClick={::this.handleSymbolsClick}>
231+
<Col xs={6} lg={4} className="text-right text-nowrap">
232+
<b>{formatSize(symbol.size)}</b>
233+
</Col>
234+
<Col xs={18} lg={20} className="text-truncate">
235+
<Tooltip
236+
title={`${symbol.type} -> ${
237+
symbol.file ? `${symbol.file}:${symbol.line}` : 'unknown'
238+
}`}
239+
overlayStyle={{ maxWidth: 400 }}
240+
>
241+
<Icon
242+
title={SYMBOL_NAME_BY_TYPE[symbol.type]}
243+
type={SYMBOL_ICON_BY_TYPE[symbol.type]}
244+
/>{' '}
245+
{symbol.displayName + symbol.displayName}
246+
</Tooltip>
247+
</Col>
248+
</Row>
249+
))}
262250
</Card>
263251
);
264252
}

Diff for: package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "platformio-home",
3-
"version": "3.4.0",
3+
"version": "3.4.1",
44
"description": "PlatformIO Home",
55
"repository": {
66
"type": "git",

0 commit comments

Comments
 (0)