# Custom Button is too small

**URL:** <https://discourse.nodered.org/t/custom-button-is-too-small/21555>\
**Category:** Dashboard\
**Created:** [11 February 2020 16:59 UTC](https://discourse.nodered.org/t/custom-button-is-too-small/21555 "2020-02-11T16:59:41Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![tobi-coder](https://avatars.discourse-cdn.com/v4/letter/t/977dab/32.png) [@tobi-coder](https://discourse.nodered.org/u/tobi-coder)\
**Post date:** [11 February 2020 16:59 UTC](https://discourse.nodered.org/t/custom-button-is-too-small/21555/1 "2020-02-11T16:59:41Z")

</div>

I'm very new to the dashboard and try to create a custom button using a ui template with this code:

```auto
<button
	class="md-raised md-button md-ink-ripple" type="button"
	ng-transclude="" ng-click="send({payload:'play_mysonos',topic:'SRF 1'});"
	ng-style="{'background-color':me.item.getText(), 'color':me.item.getColor(), 'z-index':1, 'padding':'0px'}"
	style="z-index: 1; padding: 0px; background-image: url('http://cdn-radiotime-logos.tunein.com/s17465q.png');
		background-size: 90% 90%; background-repeat: no-repeat;background-position: center;">
</button>

```

Everything works well except of the fact, that the button is to small ! See this screenshot: [Screenshot](https://discourse.nodered.org/uploads/short-url/zAov8Tx5M0puZdMPlWxIl7OE33z.png)

Can somebody explain me the reason? Thank you!

---

<div class="post-metadata">

**Author:** ![hotNipi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/hotnipi/32/383_2.png) [@hotNipi](https://discourse.nodered.org/u/hotNipi)\
**Post date:** [11 February 2020 18:09 UTC](https://discourse.nodered.org/t/custom-button-is-too-small/21555/2 "2020-02-11T18:09:46Z")

</div>

Probably what affects the size is the outer div with class `nr-dashboard-template`

```auto
.nr-dashboard-template {
  padding: 3px 6px;
}

```

Try to override this and see if it helps

---

<div class="post-metadata">

**Author:** ![tobi-coder](https://avatars.discourse-cdn.com/v4/letter/t/977dab/32.png) [@tobi-coder](https://discourse.nodered.org/u/tobi-coder)\
**Post date:** [14 February 2020 16:22 UTC](https://discourse.nodered.org/t/custom-button-is-too-small/21555/3 "2020-02-14T16:22:51Z")

</div>

Thank you very much. That solved the problem!

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [28 February 2020 16:23 UTC](https://discourse.nodered.org/t/custom-button-is-too-small/21555/4 "2020-02-28T16:23:04Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
