Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhancement: PTable #1236

Merged
merged 3 commits into from
Apr 24, 2024

Conversation

znicholasbrown
Copy link
Contributor

This PR makes several improvements to PTable, including:

  • adding a border to that matches the row divider
  • removing the p-background class from PTableHead
  • tightening row and header vertical padding
  • expanding column definitions to include min and max attributes; these help us better enforce column width definitions and prevent table blowouts
  • truncating headers and cells
  • adding title attributes to headers and cells
  • swapping font-semibold for font-bold in header labels (semibold text doesn't provide a very clear distinction between headers and content)

Before:
Screenshot 2024-04-24 at 12 09 48 PM

After:
Screenshot 2024-04-24 at 12 09 45 PM

@znicholasbrown znicholasbrown requested a review from a team as a code owner April 24, 2024 16:13
Copy link

netlify bot commented Apr 24, 2024

Deploy Preview for prefect-design ready!

Name Link
🔨 Latest commit 3014493
🔍 Latest deploy log https://app.netlify.com/sites/prefect-design/deploys/66292fba0ead9c0008aeeb1d
😎 Deploy Preview https://deploy-preview-1236--prefect-design.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@@ -12,7 +12,7 @@
</template>

<template v-for="column in visibleColumns" :key="column">
<PTableHeader :style="getColumnStyle(column)">
<PTableHeader :style="getColumnStyle(column)" :title="column.label">
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because of the way these slots are implemented, these title attributes will always work off the passed label and won't display any custom content - I think this is fine but open to pushback if that's not a clear devex.

@znicholasbrown znicholasbrown changed the title Enhancement: PTable header row color and body border Enhancement: PTable Apr 24, 2024
@znicholasbrown znicholasbrown merged commit 71bbbc7 into main Apr 24, 2024
6 checks passed
@znicholasbrown znicholasbrown deleted the nicholas/enhancement/p-table-styles-2024-04-24 branch April 24, 2024 16:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants