Is it possible to make a button inside a grid cell to look like a link?

1 Answer 660 Views
Button Grid Styling
Stavros
Top achievements
Rank 1
Iron
Stavros asked on 30 Sep 2021, 07:14 PM

Hello guys!

I have a button inside a grid cell that I am using to open a new tab in the tabstrip component.

The button displays a contract number

Is it possible to make this button look like a link?

Thank you!

1 Answer, 1 is accepted

Sort by
0
Hetali
Telerik team
answered on 01 Oct 2021, 08:32 PM

Hello Stavros,

To make the buttons in the Kendo UI Grid Cell look like a link, use the following CSS snippet:

<kendo-grid [data]="gridData">
  <kendo-grid-column field="ContractNumber">
    <ng-template kendoGridCellTemplate let-dataItem let-rowIndex="rowIndex">
      <button class="gridButton" kendoButton (click)="changeTabStrip(rowIndex)">
        {{dataItem.ContractNumber}}
      </button>
    </ng-template>
  </kendo-grid-column>
</kendo-grid>

.gridButton {
  background: none;
  border: none;
  color: blue;
  text-decoration: underline;
}

.gridButton:active,
.gridButton:focus,
.gridButton:hover {
  background: none;
  border: none;
  box-shadow: none;
}

In this StackBlitz example, the buttons in the Grid Cell look like a link.

I hope this helps. Please let me know if I can further assist you.

Regards,
Hetali
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

Tags
Button Grid Styling
Asked by
Stavros
Top achievements
Rank 1
Iron
Answers by
Hetali
Telerik team
Share this question
or