Skip to content

Commit

Permalink
Fine tuning the macro widget
Browse files Browse the repository at this point in the history
  • Loading branch information
cheton committed Mar 21, 2017
1 parent e97bc0d commit b7c8859
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 16 deletions.
14 changes: 0 additions & 14 deletions src/web/widgets/Macro/Macro.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,20 +39,6 @@ class Macro extends Component {
{modalState === MODAL_STATE_RUN_MACRO &&
<RunMacro {...this.props} />
}
<div className={styles.toolbar}>
<div className={styles.toolbarButtonGroup}>
<button
type="button"
className="btn btn-xs btn-default"
onClick={actions.openAddMacroModal}
>
{i18n._('New Macro')}
</button>
</div>
<div className={styles.toolbarRecords}>
{i18n._('Total: {{total}}', { total: macros.length })}
</div>
</div>
<div className={styles.tableContainer}>
<table className={styles.table}>
<tbody>
Expand Down
6 changes: 6 additions & 0 deletions src/web/widgets/Macro/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -228,6 +228,12 @@ class MacroWidget extends Component {
<Widget.Header className={this.props.sortable.handleClassName}>
<Widget.Title>{i18n._('Macro')}</Widget.Title>
<Widget.Controls className={this.props.sortable.filterClassName}>
<Widget.Button
title={i18n._('New Macro')}
onClick={actions.openAddMacroModal}
>
<i className="fa fa-plus" />
</Widget.Button>
<Widget.Button
title={minimized ? i18n._('Open') : i18n._('Close')}
onClick={(event, val) => this.setState({ minimized: !minimized })}
Expand Down
8 changes: 6 additions & 2 deletions src/web/widgets/Macro/index.styl
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@

display: block;
margin: 0;
padding: 8px 10px;
padding: 5px 10px;
background: #fafafa;

.toolbar-button-group {
Expand All @@ -42,6 +42,7 @@
}

.table-container {
min-height: 80px;
max-height: 180px;
overflow-x: auto;
overflow-y: scroll;
Expand Down Expand Up @@ -82,7 +83,10 @@
border-top-width: 0;
}

> tbody > tr:last-child > td {
> tbody > tr:first-child > td {
border-top-width: 0;
}
> tbody > tr:nth-child(1n+3) > td {
border-bottom-width: 0;
}

Expand Down

0 comments on commit b7c8859

Please sign in to comment.