Skip to content

Commit

Permalink
fix(decision-table): use button instead of link in hints
Browse files Browse the repository at this point in the history
Closes #431
  • Loading branch information
barmac committed Nov 4, 2019
1 parent 7911b5c commit 2e73132
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -179,10 +179,10 @@ export default class AllowedValuesEditing extends Component {
{
!isNull(values)
&& <p class="dms-hint">
<a href="#" className="del-values"
<button type="button" className="del-values"
onClick={ this.handleRemovePredifinedValuesClick }>
Clear predefined values.
</a>
</button>
</p>
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,11 +122,11 @@ export default class InputEditor extends Component {
{
!editScript && (
<p className="dms-hint">
Enter simple <code>FEEL</code> expression or <a href="#"
Enter simple <code>FEEL</code> expression or <button type="button"
className="ref-make-script"
onClick={ this.makeScript }>
change to script
</a>.
</button>.
</p>
)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -195,9 +195,9 @@ export default class InputDateEdit extends Component {
value={ dates[0] } />

<p className="dms-hint">
<a href="#"
<button type="button"
className="use-today"
onClick={ this.onSetStartDateTodayClick }>Use today</a>.
onClick={ this.onSetStartDateTodayClick }>Use today</button>.
</p>
</div>

Expand All @@ -220,9 +220,9 @@ export default class InputDateEdit extends Component {
</ValidatedInput>

<p className="dms-hint">
<a href="#"
<button type="button"
className="use-today"
onClick={ this.onSetEndDateTodayClick }>Use today</a>.
onClick={ this.onSetEndDateTodayClick }>Use today</button>.
</p>
</div>
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,9 @@ export default class OutputDateEdit extends Component {
</ValidatedInput>

<p className="dms-hint">
Set date <a href="#"
Set date <button type="button"
className="use-today"
onClick={ this.onClick }>to today</a>.
onClick={ this.onClick }>to today</button>.
</p>
</div>

Expand Down
10 changes: 8 additions & 2 deletions packages/dmn-js-shared/assets/css/dmn-js-shared.css
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,18 @@
font-weight: bold;
}

p.dms-hint a {
p.dms-hint button {
color: #3960a2;
text-decoration: none;
display: inline;
border: none;
padding: 0;
cursor: pointer;
font: inherit;
background: none;
}

p.dms-hint a:hover {
p.dms-hint button:hover {
color: #4285f4;
}

Expand Down

0 comments on commit 2e73132

Please sign in to comment.