css icon indicating copy to clipboard operation
css copied to clipboard

CSS for Table

Open swasher opened this issue 2 years ago • 3 comments

Is there a way to get styled table using Primer CSS? I know, there is a component for React, but I do not use React, I'm using a Django.

swasher avatar Apr 10 '23 13:04 swasher

Not really. But there are some table styles as part of the Markdown comments. Like these:

Before After
Cell 1 Cell 2
Cell 1 Cell 2

You should get tables styled by adding a markdown-body class on a wrapper element. E.g.:

<div class="markdown-body">
    <table role="table">
        <thead>
            <tr>
                <th>Before</th>
                <th>After</th>
            </tr>
        </thead>
        <tbody>
            <tr>
                <td>Cell 1</td>
                <td>Cell 2</td>
            </tr>
            <tr>
                <td>Cell 1</td>
                <td>Cell 2</td>
            </tr>
        </tbody>
    </table>
</div>

simurai avatar Apr 11 '23 01:04 simurai

Hi! This issue has been marked as stale because it has been open with no activity for 180 days. You can comment on the issue or remove the stale label to keep it open. If you do nothing, this issue will be closed in 7 days.

github-actions[bot] avatar Oct 08 '23 01:10 github-actions[bot]

Instead of using Django's default templates, you can use it solely for creating APIs, and then employ React to build the frontend and interact with the API for backend functionality. This is the standard approach we follow to achieve the best framework for both frontend and backend.

I hope this helps!

Dhruv-Bajaj-code avatar Oct 23 '23 18:10 Dhruv-Bajaj-code

Hi! This issue has been marked as stale because it has been open with no activity for 180 days. You can comment on the issue or remove the stale label to keep it open. If you do nothing, this issue will be closed in 7 days.

github-actions[bot] avatar Apr 20 '24 19:04 github-actions[bot]