:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.
Python ab-testingai-analyticsanalyticscdpdata-warehouseexperimentsfeature-flagsjavascriptproduct-analyticspythonreactsession-replaysurveystypescriptweb-analytics
feat(quill): add TableEmpty primitive for table empty states (#65066)
Adam Leithd9ad08afe331
diff --git a/frontend/snapshots.yml b/frontend/snapshots.ymlindex 4c5c76090053..76d2701152c0 100644--- a/frontend/snapshots.yml+++ b/frontend/snapshots.yml@@ -4109,7 +4109,7 @@ snapshots:lemon-ui-visual-image-diff-viewer--small-image--light:hash: v1.k794b7964.ed31587820d0216f2281ec8e610da8cb9fe8cb45f9c13e0280f17771cf84994a.spusB2C8AKwu5Tv0KOr8pkjDxgEZw5jcOlEikYAzKWImcp-apps-actions--list--light:- hash: v1.k794b7964.96ff0e9c7c9e0fdcc4576950311b685a1027d39c670a59ebe5119f6aee820dbb.rQkip0f1OKHkt8FT2p953iGZxe2SMW-fSueCnWN1XIw+ hash: v1.k794b7964.780ee2787e03d18e28952f15ba1063d3561bf506c3f27370e111aa00b6840480.kyd4ZfOZOnVnvs4zzuHttn7iaRk1OSRVc4UGm-myJEAmcp-apps-actions--multi-step--light:hash: v1.k794b7964.d337199f83a8416e91c20175f60dfe52b0a445270b34efea8c2c2ee14620d7a1.ARITfWNtggFg_eKCPLLur4JoSqx0Zx2nYvMg8TvoK3gmcp-apps-actions--simple--light:@@ -4119,15 +4119,15 @@ snapshots:mcp-apps-ai-observability--empty--light:hash: v1.k794b7964.142f371a27cf39712117a43bdfbd712d2a8a14966fd593b03096e7f26251a3cc.i-3gjDyAAdVus9xh-3EgnJSLzPOYYpqbmLmcNb6Sz-wmcp-apps-ai-observability--multi-model--light:- hash: v1.k794b7964.bd74a05ef6957675b900871ba6aca20b04f8ad9ee2ddb05849d9482d78abb400.mY68t21eDHQSYpXFgsyOoesxnWPZ2cqmJR-hHRs9ulo+ hash: v1.k794b7964.8d7b111f362b6382b7ab0f8b2faa9896a414b3410378070a6da3fff8df8c4617.X8hju5T08Nzt0NX65InDdmyuCNi6g111Jd27Mk7_OOUmcp-apps-ai-observability--single-model--light:- hash: v1.k794b7964.ff510efb5620f51ec10f951f5f8ebdbb3f903e512b677251b412d0dc227ad047.57AE7qogywNRSSIKGMJXy8E8YvD8aAV_2zJa1nKkeZ8+ hash: v1.k794b7964.d9666eafee0eb265527f39de0189f04df01fc001ae7ff2d8f30e7f4eb8bf78b8.tKK0r3f4eUdwxXF1CNsBMdifJyq5jKOGjlgBgjGq9oImcp-apps-cohorts--calculating--light:hash: v1.k794b7964.ccc89a2389eb15f76a817d88dd26ff03f20210f23eed40183436261a92504399.pXD51hUgUtFpzTJd-iaVQJ5d1SRr2Ifr_1geD9qwPwYmcp-apps-cohorts--dynamic--light:hash: v1.k794b7964.d76eb7a46408f957fbe3110f8f2cae3476af6966e8bbcf2aa4b45ff5ed6428b0.8GHvx1vMpvHvssDcbkZoHMWvnUQCS_idgnNbkKmXT7omcp-apps-cohorts--list--light:- hash: v1.k794b7964.7e6363d616aabde2fa6db252c233d4b7e651dd3ed0be35e55d51264b4e994438.7k8-ggET0l7Q1xUgeTCbh-Gy0s8rDpdVjFHER1HvBcA+ hash: v1.k794b7964.055d227fe3eafe82ebbf2474e06b81537e40b4e5ded9ddfdf1bdaabee5ae5219.1icZdzBnGISqBikNHqlcqgQtlYsD4sySjazHd218-hgmcp-apps-cohorts--static--light:hash: v1.k794b7964.7a0889e7d21c79da2f04c4a187ab6d2b63158edd0e8737cda5a6254197eb3822.Qz8oGpJlwUIi5k43JRBxSAAJo-2fB-qceXOSk8SqTWImcp-apps-email-template--plain-text-fallback--light:@@ -4141,7 +4141,7 @@ snapshots:mcp-apps-error-tracking--error-details--light:hash: v1.k794b7964.8ee3b6226ad1f401fc48aa2583b312f73013c093c46ddee3b9dc46472e731079.ZKE8Hc8oEny6YA-_0V4lb1WuQIBKhz0ab5ZIlRZE8QYmcp-apps-error-tracking--list--light:- hash: v1.k794b7964.d63364a23688f1cbfbd4125311af21c5c944218f15855ebd5f1f3a42c57124de.urMEJeE8zDtt0lQb-cQh0ID1l6N3_4MONXn7Buvtinc+ hash: v1.k794b7964.a13e49936f5d76437853d424d895f1b85721ed78b9fd757a92ad52603e5f3a9c.dTJPFO3ehqlGJaqugjvbwwoCFBZIuWR7bTLdFCnTbK8mcp-apps-error-tracking--python-stack-trace--light:hash: v1.k794b7964.d80733b9a543cc59a61a99b8515eaf35fa17b95a4d7d282c469c5ddf49be5cb5.2hXi52twI4RVs4FegK34kQf5bGN26uKyur7GeBeXuREmcp-apps-error-tracking--resolved--light:@@ -4151,23 +4151,23 @@ snapshots:mcp-apps-error-tracking--with-external-links--light:hash: v1.k794b7964.1c438b81ddecf6cd51016c53d57b3a80c7a60aab20f69a4629f52d9366452c72.alkUqUY-JcNO_PquFIaJSqBh0hBs4BbMf4NNbwjkHI4mcp-apps-experiments--completed--light:- hash: v1.k794b7964.bfd4a7b3ac2f1a3a9a9a29f9602fba1eb910c2cf9b33e75f0d6df0b92eb11eae.244SoUGyqjlf_ukxREHG27uMYSlsrRt_AeImgQWGNW8+ hash: v1.k794b7964.3ca416adde36359603e91e578bd21cbb6e6f7591ec714b01b238c1be7c4e6b16.zcsJMCqHzsQbmRSEk2sNm5Al4-GGWV3oXLfmzMpKd6Umcp-apps-experiments--draft--light:- hash: v1.k794b7964.e23d9123ba65760e4c85a44532cdcb8c155db210594a455afe2c7f65a4989a63.MW_QgBxff7Npf9-yA38VTqloshv16DphYiys77sauYQ+ hash: v1.k794b7964.cab299172819b5734979578ea079a09e0284b46261a4d5488d7e20ab8ab19512.XqNSWnK-HfhUqTbWpMFq8UUZu4Uc6UJAA1FLaP6mMHEmcp-apps-experiments--list--light:- hash: v1.k794b7964.8ebcbb30f2731f69b120ef09175e17d2a61aa82e545cc00ad079cdb02ea76eeb.NqKbMtNmtz3e8VpRXB7i_XVXlIjdsPyx1vltHelq8OQ+ hash: v1.k794b7964.40bd9bc7d43e74ed28706715dfec390a4250a4dc4a966a7580379c9a1a8fe0eb.gQANaHDKe6QOO3bq9F9w2itrbKemByDyISXPAUktMD4mcp-apps-experiments--results--light:- hash: v1.k794b7964.81a12df77704d578c8d6f7d811d905f93107c8eb4fe946d627ba7873a84e3c0c.fqY3wqHh4u1avDKnzu7OGc3E2vaHoUmkXp5dNt0qXwg+ hash: v1.k794b7964.b9a97e7cfdfb1d45686e1cb673af92ec44b1a43a01aff8e7f9b6b1bcc5c28f55.mAtZ-_ue2F7MsuTxBE6cWlB15IeO-EtJul1jxkDCluUmcp-apps-experiments--running--light:- hash: v1.k794b7964.f034a24590fa0d531fc0546ad458c2bd741a48e414112e9275dbb8226275fc1e.vHfrxPwVqECykBZdnEGIxRWz_ZJ1ZfvQKBcaNc-bang+ hash: v1.k794b7964.bace41ea6ab40cf1a59b52cc012efa30d43cb801876c9e5337c69358baa3d3b6.k6CFBF4vp0ooKcJu9O3sFqWJP_YgMoJHBDT-Hw-C_WMmcp-apps-feature-flags--boolean-flag--light:hash: v1.k794b7964.f3ee0e724e30f350166b5a87d46cd36ba9f982735aa9d7e322aeaf28bc4c9b1c.KzlRVALZdoWS2mlKcnTJRTOo4SmFvIZzKhj6SodWt3Imcp-apps-feature-flags--flag-list--light:- hash: v1.k794b7964.c48895aafa7996c129094b6b0bba6a1d60decc29ac6c94a0c871e8ad01db2a96.l4UNTX6NOhKO2BoLmc_GKN67WtUHmCis0oTHb-m0_t4+ hash: v1.k794b7964.1e43c59de291c5481b541e08e0d19d1eb07801f6d60fafb47a4303ff174c3da2.7LSDsKi9to178G2XNT9NhPujfzlrpflYQyfk-_m_Brkmcp-apps-feature-flags--inactive-flag--light:hash: v1.k794b7964.0ea041efd8df37c742028aa46ff65a4036840f462fe1f3cde4da318552f57e61.tD2LfrilewqSsRK4Gtu2nKFDPoyUaDERRF5vN6ht1oMmcp-apps-feature-flags--multivariate-flag--light:- hash: v1.k794b7964.790d580b2ac65c61fd760376aa71cde4f9de9ef48048c3c9f8c6f4b652c2ca7d.HFZ1pVLSBmrHAU4f4gdB5JfRgGUEYUTZMOuwFpOr6Ig+ hash: v1.k794b7964.f81b6888f54e5102954aed2bd5654747ddd361066f0433c1ba33ece932bad613.maE80v3PvIp8PWYjpm16UTlCJtc3emF84UjDmP530qQmcp-apps-feature-flags--testing-matched--light:hash: v1.k794b7964.09249f0d06bf5ef94eaddfcd5a97b97943ed42cae7097741dd3989418ec11f50.ROO2zs_uTFgPB7eI8fwi2GIwSo_HHTlhAal5XWBmz7Ymcp-apps-feature-flags--testing-no-match--light:@@ -4177,15 +4177,15 @@ snapshots:mcp-apps-funnels--three-step--light:hash: v1.k794b7964.ea34a8cf895551499ca3bacabcde98ea445e2caea7fdc5b9f75de7d1d6dd8e6b.UfvafB3BxwBsJ8t1xHzxTmm5sRu0_xMGrAp6e4ldb5Ymcp-apps-insight-actors--event-counts--light:- hash: v1.k794b7964.f3ff99b4ec1920b2df7c65cb407482896b99b2ea34d4bfbb4cad722b05d25f9a.6K2QCgM8Znsuz_zMA2jTZW884aJ29-cvc1OWldMEzgc+ hash: v1.k794b7964.f0b17778c7d50e26542186c2a6758796a67334f35a1269cbe10e3269cec66b87.qSfkrh0qKHklQNE_y-fxq5ZSlGUoK6N16jfxvKHvZrAmcp-apps-insight-actors--with-recordings--light:- hash: v1.k794b7964.af9ec36dd0d406f45eec2bf3fafb8dbe63b0eba139c5fff4b33e83cf24668f8e.hQ3brX3MIHwfCM95Re7Ti6Z8bsY2zq-He2uM63uuvUw+ hash: v1.k794b7964.6bc38bc90689750e45b0eefa5974ce2e0fee05f581a64552835accca3914ded3.5ZInU5bxqbu_rkPp-prY1W5D2hsW8hn21EAwNfRjf_gmcp-apps-lifecycle--grouped--light:hash: v1.k794b7964.5c33ba0a4dbe6cf279197eadea244d7b9838b99d80b8ba2b899df7ca881e066b.GNSIWjjq4NaJTgY9UUDYIXoxNuzz74X5yRL5TuFPO_Ymcp-apps-lifecycle--stacked--light:hash: v1.k794b7964.6d00ea357f1a270a0b0a6a4d61339c00a298f946d4f7a8fe9ed70b289aa3b60b.6ijtbv39zAumhoMFY5BSCxCkLHO9rYpeBUjUykvvgK8mcp-apps-retention-actors--daily--light:- hash: v1.k794b7964.0a701acbd2d9dac54c345d22841a6d92b6c2b3728421e8fa5fd574a769514e04.Rhb4Qb0bfRbA3ZB2_4f4WM5507JnwCgoox1RbE9y8Ks+ hash: v1.k794b7964.98ed364bc169b666ee69ff6e44c7fa385360df9410875c5ee3cd85ff2e53104f.-p5rL3gbD8LRZ-kriXkNM3NHeYm8nf0v0VfVq5XWZFsmcp-apps-stickiness--multiple-series--light:hash: v1.k794b7964.9ffcba3452bbcd678c11f0d873b02a32a97ad071d5fc55f2c00681df9bdc7141.0G-r5IrknmUdR0cBBeCfTQjKKC2nBiE3-F4F0PgX9FQmcp-apps-stickiness--single-series--light:@@ -4197,9 +4197,9 @@ snapshots:mcp-apps-surveys--draft-multi-question--light:hash: v1.k794b7964.3bc65ee531d96f097f879099aea773797b4a0f7388522b5558d16832ff25e20c.yCVcDShukwPldlWmDSxnB6id2U6W1znLrneypeCl9RImcp-apps-surveys--list--light:- hash: v1.k794b7964.d74c2774a1e3a73e7d34e0332ef1bcbb3b61a5442b89797447e23f5d56b033c2.qta1-W4_vRyunnAG5t1wzZKyzWUqS54HvnKvfvznYnA+ hash: v1.k794b7964.a038d8668b289f1fdd1fc6793e9de3a28207c22ae12271f71e05769163baba83.7aAN-WBraQDc9xv3J42dUvO_1mJLEqJDEfQideY8sLQmcp-apps-surveys--stats--light:- hash: v1.k794b7964.da67b48f277665016d143ea09d4471ca6f01f3b8a6d22e7fe0f3dc51b075e92a.l81wzNlVna0bTrWF2HHg1RkJaB7vXRpAIdMbNylhzCw+ hash: v1.k794b7964.50ebbffe0817c92d431f7398c6a266e43f2e5b4a84ba7264284be6468a07d498.8FDJduexLk3r96zjs0y_Mf9vlGw-BN8-dhILqG67AcQmcp-apps-trends--area-chart--light:hash: v1.k794b7964.fea141e4555bf7c84c7df7d28f440f1967cf46eed78c9df63daa191b42156569.osoYKiT_8UiEIKvjzLfRzJxA6gY3cT4eD1g66S-kD5Qmcp-apps-trends--bar-value-few-series--light:@@ -4219,7 +4219,7 @@ snapshots:mcp-apps-workflows--draft-state--light:hash: v1.k794b7964.4cbfe20c626f0f7912dbd47b41a152c9c30f92d12a3f599476fb10043d7f7e70.9NI9FaMch59lt8xO3Xhp9ruHKLyDcvupNp20dZrR8_Ymcp-apps-workflows--list--light:- hash: v1.k794b7964.aa8890b9b9c20fd7e5bfbe8858de357738b93bf229942971b73fc3b079c9ffb4.UizlIi3nxAIDkWlK_Iya7uTfSMZX8vD3fivDElOQSxU+ hash: v1.k794b7964.be90744e325436d750fce312670f5c51a56c644dc3a3bf19530ef9048949c582.d3khUwRyG0RQam6nQxhrXKPacHNSmMrWPN_TOwaMoEQposthog-3000-keyboard-shortcut--default--dark:hash: v1.k794b7964.78f41f0eab095582f8e27fb796736e5b01098073616a33595dd9972320bbcda5.Dqmf5fCfJnCU8gmgz_Lg0Cnp7NMmLbR47vcbxnTO520posthog-3000-keyboard-shortcut--default--light:@@ -5797,21 +5797,21 @@ snapshots:scenes-app-marketing-analytics-cell-actions--source-cell-action-unmapped--light:hash: v1.k794b7964.4ebf2f848b10c8b2859630215a9be1ff91fb825fc334005207556310261d3a5c.UcqJY3dqyJNbi3x7oYaZ2rEu95LAEdbGmMyEpI-Wlgcscenes-app-mcp-analytics--dashboard--dark:- hash: v1.k794b7964.c25b8e1693844d8f9d2b6e8c08a06bea95ea0a6ff0575e468c03004eabcd41f4.kgv_UP8c-JuwxoLHEYC5xFD08QcECeL5ThgVof5i0VU+ hash: v1.k794b7964.4292b8f6b3204ee0b10809e9db9cff5678c8bee801ba569fb9d22dd452b8a8bb.kgliIkb6GeE4lfxM9ZvokOg9m-DDDV-fpILZFytqWuEscenes-app-mcp-analytics--dashboard--light:- hash: v1.k794b7964.e80fca14f66bcb1dff0d8645f852c51d5b0131a676e246d52ee938ce8bf1205e.zUCTZ71CfSoVdfgE-isvw_ymFWq8OoRQ0y_lv_z2HWY+ hash: v1.k794b7964.49dd989e2726543d470320570c24c2f9b0a50e90d4129741eed06500f183d36d.YbgjXggvlwzgtDVKbyXNS2m6w3TuGQKGF4dq91VGQqQscenes-app-mcp-analytics--intent-clustering--dark:- hash: v1.k794b7964.81d4c896ec102bd79537c025cb4ee78b2feaaaf8401a3006086af07faeee8fce.yHdrL8SIGaWXnpRDQa2Z50wdyvKeIdckMceuGfyWd7Q+ hash: v1.k794b7964.4bf359b5089b714711c176bdbd5e454857e35935027ca46c161215957bcdff63.tuUCfVazgJFLRYPnMr4rBr_bdCHDOR4WINf5P7PHyCUscenes-app-mcp-analytics--intent-clustering--light:- hash: v1.k794b7964.e8afe54e6c6ac3d0a18404a894e2c6be786c4bb58b3319cb4957248779d16512.7pPTDjFoPUJ9Qhle_VtMRf3WWNEnSqnx4NqhYII5u9I+ hash: v1.k794b7964.eb1ee241dbc73a7253676466dff7c5261819f9076291a25d62c51f598dd9b97f.xRtze8s71MHoqaBCL6XlrDDX--gFjajvG_pT6YCuB90scenes-app-mcp-analytics--sessions--dark:hash: v1.k794b7964.277463ad445565d14f2549a063a4f8c0c23a81af419bfafc9eefc65577fb0834.woelvjefGWPDW4Acae_sP2fA7YidrA7tkhfvC8u_AQ4scenes-app-mcp-analytics--sessions--light:hash: v1.k794b7964.bbe32ae76ef1ed9053d24d860933bc0bf1cca54ed3f601effaf515b8d9a6cd21.saYknnP-f1-BwcwRczq_p6CgUmnH8cmE8YJ_9XpN2Pkscenes-app-mcp-analytics--tool-quality--dark:- hash: v1.k794b7964.d2757a520322fef89d0c9132c4e6674682d2412f7f53bd13408b1d9b2f695c8e.2STiQWuPVur5p9FeZeo2Hm8Ozc954bUiNhberVgEWaU+ hash: v1.k794b7964.5b9e93282f8acb490cc1a994629d482c6b26958f5593d9bc0cf899ddf130aa23.ugxwut5_c5IGrho2rIygMeLWnCO7OJO2642TbxtgUckscenes-app-mcp-analytics--tool-quality--light:- hash: v1.k794b7964.edf70234f94442e3741467f5fd4bb7820914cbb2cd8482e0bfd24d1fa2a2864f.IpuKCVssCeT7n_iG8HH8ApmKEY_I4s85jEkYkrUDl1U+ hash: v1.k794b7964.5df4e4023360a80eb6a7774b5a4b11689d70f0d2cd539b1df61cd8d761b6ce6b.rPhR2yrPuM2b6kqQRtSVnjrZ8hm8k59qyKRVBUFKUNgscenes-app-mcp-analytics-dashboard-cards--daily-calls-and-errors--dark:hash: v1.k794b7964.921f819d1e55f6b1df74b8d4990bba635aa6f7db8ab7a75a232009bbac5f2e43.qy4SEtXqEIFBeEw5gzgTLCCbKUL61bV7pvuMq_cdTzAscenes-app-mcp-analytics-dashboard-cards--daily-calls-and-errors--light:@@ -5825,9 +5825,9 @@ snapshots:scenes-app-mcp-analytics-dashboard-cards--error-rate-by-tool--light:hash: v1.k794b7964.6316d94634f57953534f1f850f7e4b2996a1d8352764079f95b5854b5eda290d.ewSfhCd5QZsVhibDpQTGKyFK6swQn_gxQuNmPmWHS-Mscenes-app-mcp-analytics-dashboard-cards--flagged-sessions--dark:- hash: v1.k794b7964.37e85662ee40e1f94bb57b4fd77c76597ece70a6f17058a454635fde2bdeb3be.i019UVgAa48DZSAgEdHhYseiA0vJ4CULAVN_wkw5Ilk+ hash: v1.k794b7964.a643773309bbe015dbad6d2b0a9714d668d2be594fc811c92fecf2938f9bb69c.hXXVcF5bGNe4xlcjSiZhbt4upstcVZLQggLZ947PdI4scenes-app-mcp-analytics-dashboard-cards--flagged-sessions--light:- hash: v1.k794b7964.52a1b29f817077e0d8452260716e950f063e206bd90d35c7be58ba72e93f13de.awEggL6KzFFucKT1Dd055i2oacGHM1WnHCSYHOwxQIo+ hash: v1.k794b7964.1fc4aa2b1af4e2350dcf08445ed27f288245d6d4b5c556ffd79660262ab94964.acTG62SpX_gAoM0rfPK8SfUFhCFYqYyF4irVU9ZwyAgscenes-app-mcp-analytics-dashboard-cards--key-metrics--dark:hash: v1.k794b7964.30a761d8a47452414e6f158ad50484885f81394fb58c075ff1f2e66c36c1fe6e.bV_JfGaoE60VA3pGReyVwyQ23zmdaaflqKtTyQVTeq4scenes-app-mcp-analytics-dashboard-cards--key-metrics--light:diff --git a/packages/quill/packages/components/src/data-table.stories.tsx b/packages/quill/packages/components/src/data-table.stories.tsxindex 79290063f259..a4168e0aeb96 100644--- a/packages/quill/packages/components/src/data-table.stories.tsx+++ b/packages/quill/packages/components/src/data-table.stories.tsx@@ -1,18 +1,8 @@import type { Meta, StoryObj } from '@storybook/react'import { type ColumnDef } from '@tanstack/react-table'-import { FolderPlus } from 'lucide-react'import * as React from 'react'-import {- Badge,- Button,- Empty as QuillEmpty,- EmptyContent,- EmptyDescription,- EmptyHeader,- EmptyMedia,- EmptyTitle,-} from '@posthog/quill-primitives'+import { Badge } from '@posthog/quill-primitives'import { DataTable } from './data-table'@@ -185,49 +175,3 @@ export const FullWidthPaginated: Story = {),}-// Default empty state — minimal and generic.-export const Empty: Story = {- render: () => (- <DataTable columns={columns} data={[]} className="max-w-2xl rounded-md border border-[var(--border)]" />- ),-}--// Empty + paginated — the pager is suppressed when there are no rows, so only-// the empty state shows (no "0–0 of 0" pager).-export const EmptyPaginated: Story = {- render: () => (- <DataTable- columns={columns}- data={[]}- pageSize={10}- pageSizeOptions={[10, 25, 50]}- className="max-w-2xl rounded-md border border-[var(--border)]"- />- ),-}--// Override the empty slot with app-specific copy and actions.-export const EmptyCustom: Story = {- render: () => (- <DataTable- columns={columns}- data={[]}- className="max-w-2xl rounded-md border border-[var(--border)]"- empty={- <QuillEmpty>- <EmptyHeader>- <EmptyMedia variant="icon">- <FolderPlus />- </EmptyMedia>- <EmptyTitle>No projects yet</EmptyTitle>- <EmptyDescription>Get started by creating or importing a project.</EmptyDescription>- </EmptyHeader>- <EmptyContent className="flex-row justify-center gap-2">- <Button variant="primary">Create project</Button>- <Button variant="outline">Import</Button>- </EmptyContent>- </QuillEmpty>- }- />- ),-}diff --git a/packages/quill/packages/components/src/date-time-picker.tsx b/packages/quill/packages/components/src/date-time-picker.tsxindex 0f388f6ea3bd..529cdac1869b 100644--- a/packages/quill/packages/components/src/date-time-picker.tsx+++ b/packages/quill/packages/components/src/date-time-picker.tsx@@ -606,7 +606,7 @@ export function DateTimePicker({return (<divclassName={cn(- 'bg-card text-foreground rounded-lg shadow-md ring-1 ring-foreground/10',+ 'bg-card text-foreground rounded-lg shadow-md ring-1 ring-foreground/10 overflow-hidden',compact ? 'w-[15rem]' : 'w-[15rem] lg:w-full max-w-[42rem]',className)}diff --git a/packages/quill/packages/primitives/AGENTS.md b/packages/quill/packages/primitives/AGENTS.mdindex 6c7adaa6883c..deb91efead9f 100644--- a/packages/quill/packages/primitives/AGENTS.md+++ b/packages/quill/packages/primitives/AGENTS.md@@ -734,6 +734,43 @@ const range = getPaginationRange(pageCount, pageIndex)Compose `Table > TableHeader/TableBody/TableFooter > TableRow > TableHead/TableCell`. Per-cell options on `TableHead`/`TableCell`: `sticky="left" | "right"` (frozen column), `align="left" | "center" | "right"` (horizontal), `valign="top" | "middle" | "bottom"` (vertical), `expand` (absorb leftover width). `align` also positions an inline-flex header Button. On `Table`: `stickyHeader` (or `"page"`) for a sticky header, `fullWidth` to fill the container — pair `fullWidth` with `expand` on one column to choose which one stretches.+**Backgrounds: transparent by default, opaque when sticky.** Plain cells and headers are transparent, so a `Table` inherits whatever surface it sits on (inside a `Card`, a tinted panel). Sticky parts (`stickyHeader`, `stickyHeader="page"`, `sticky="left"/"right"`) get an opaque background automatically — they'd otherwise bleed scrolled-under content — so you don't add `bg-background` yourself. It defaults to the app background; if the table sits on a different surface, override the inherited `--quill-table-sticky-bg` custom property on the `Table` so the frozen cells match — e.g. inside a `Card`, `className="[--quill-table-sticky-bg:var(--card)]"`.++**Empty state — use `TableEmpty`, not a hand-rolled cell.** Drop `TableEmpty` in where a `TableBody` would go; it renders its own `tbody > tr > td` with a full-span `colSpan` (defaults huge, browsers clamp to the real column count) and centers its content. Put `<Empty>` or plain text inside — no manual `colSpan`, no `h-full`. To make it fill the body area, give the `Table` a height (e.g. `className="h-full"` with a height-bounded container); otherwise it sizes to its content. Don't put an `<Empty>` (a `div`) as a direct child of `Table` — that's invalid table markup and the browser hoists it out of the grid.++```tsx+<Table fullWidth className="h-full">+ <TableHeader>{/* … */}</TableHeader>+ <TableEmpty>+ <Empty>+ <EmptyHeader>+ <EmptyMedia variant="icon">+ <InboxIcon />+ </EmptyMedia>+ <EmptyTitle>No members yet</EmptyTitle>+ <EmptyDescription>Invite teammates to start collaborating.</EmptyDescription>+ </EmptyHeader>+ <EmptyContent>+ <Button>Invite member</Button>+ </EmptyContent>+ </Empty>+ </TableEmpty>+</Table>+```++**Table in a Card — let the table own the edges.** A `Table` sits flush inside a `Card` because its cells are transparent (they inherit the card surface). Put `gap-0 pb-0` on the `Card` and `p-0` on the `CardContent` so the table reaches the card's rounded edges with no double padding, and use `fullWidth` on the `Table`. For an empty/loading table that should fill a tall card, build the height chain `Card min-h-* → CardContent flex-1 → Table h-full` so `TableEmpty` stretches to the body area.++```tsx+<Card className="gap-0 pb-0">+ <CardHeader>+ <CardTitle>Members</CardTitle>+ </CardHeader>+ <CardContent className="p-0">+ <Table fullWidth>{/* … */}</Table>+ </CardContent>+</Card>+```+### Menubar```tsxdiff --git a/packages/quill/packages/primitives/src/index.ts b/packages/quill/packages/primitives/src/index.tsindex b593ea35a5e1..7d960a9d17d9 100644--- a/packages/quill/packages/primitives/src/index.ts+++ b/packages/quill/packages/primitives/src/index.ts@@ -242,7 +242,17 @@ export {} from './toast'export { Spinner } from './spinner'export { Switch } from './switch'-export { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption } from './table'+export {+ Table,+ TableHeader,+ TableBody,+ TableFooter,+ TableHead,+ TableRow,+ TableCell,+ TableEmpty,+ TableCaption,+} from './table'export { Tabs, TabsContent, TabsList, TabsTrigger } from './tabs'export { Text, textVariants } from './text'export { Textarea } from './textarea'diff --git a/packages/quill/packages/primitives/src/table.css b/packages/quill/packages/primitives/src/table.cssindex 6f2dcb7769d4..d3ed0a569bf7 100644--- a/packages/quill/packages/primitives/src/table.css+++ b/packages/quill/packages/primitives/src/table.css@@ -125,21 +125,19 @@right-aligned, or an interactive button — gets it consistently. */.quill-table__head {height: 2.05rem;- padding-inline: 0.75rem;+ padding-inline: 1rem;font-size: var(--text-xxs, 0.625rem);font-weight: 500;color: var(--muted-foreground);text-transform: uppercase;letter-spacing: 0.05em;white-space: nowrap;- background-color: var(--background);border-bottom: 1px solid var(--border);}.quill-table__cell {padding-block: 0.5rem;- padding-inline: 0.75rem;- background-color: var(--background);+ padding-inline: 1rem;border-bottom: 1px solid var(--border);}@@ -147,6 +145,28 @@border-bottom: none;}+ /* Full-span empty cell. height:100% claims the lone body row's height (which+ fills a height-bounded Table), and the inner flex column resolves that+ height so children — including Empty's own flex-1 — stretch and center.+ With an auto-height table it collapses to its content instead. */+ .quill-table__empty {+ height: 100%;+ }++ /* Empty already sits inside the table's own border, so drop its dashed frame. */+ .quill-table__empty [data-slot='empty'] {+ border: none;+ }++ .quill-table__empty-inner {+ display: flex;+ flex-direction: column;+ align-items: center;+ justify-content: center;+ width: 100%;+ height: 100%;+ }+.quill-table__row:hover .quill-table__cell {background-color: color-mix(in oklab, var(--muted) 40%, var(--background));}@@ -223,11 +243,19 @@generic viewport-edge shadows above still signal off-screen overflow.========================================================================= */+ /* Sticky cells get an opaque background or scrolled-under content bleeds+ through; plain cells stay transparent. The background is inherited, so set+ `--quill-table-sticky-bg` on the Table (or any ancestor) to match a+ non-default surface, e.g. `var(--card)` inside a Card; it falls back to the+ app background. The fallback lives here (not as a re-declaration on+ `.quill-table`) so an override on the outer container still inherits down. */+/* --- Sticky header --- */.quill-table[data-sticky-header] .quill-table__head {position: sticky;top: var(--quill-table-sticky-top, 0);z-index: 2;+ background-color: var(--quill-table-sticky-bg, var(--background));}/* --- Sticky columns — sticky="left" | "right" on TableHead / TableCell.@@ -237,6 +265,7 @@.quill-table__cell[data-sticky] {position: sticky;z-index: 1;+ background-color: var(--quill-table-sticky-bg, var(--background));}.quill-table__head[data-sticky='left'],diff --git a/packages/quill/packages/primitives/src/table.stories.tsx b/packages/quill/packages/primitives/src/table.stories.tsxindex c7a29c8ff1a4..2961c7f259c2 100644--- a/packages/quill/packages/primitives/src/table.stories.tsx+++ b/packages/quill/packages/primitives/src/table.stories.tsx@@ -1,9 +1,10 @@import type { Meta, StoryObj } from '@storybook/react'-import { ChevronsUpDown, MoreHorizontal } from 'lucide-react'+import { ChevronsUpDown, Inbox, MoreHorizontal, Plus } from 'lucide-react'import * as React from 'react'import { Badge } from './badge'import { Button } from './button'+import { Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptyTitle } from './empty'import {DropdownMenu,DropdownMenuContent,@@ -12,7 +13,18 @@ import {DropdownMenuTrigger,} from './dropdown-menu'import { ItemContent, ItemDescription, ItemTitle } from './item'-import { Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow } from './table'+import {+ Table,+ TableBody,+ TableCaption,+ TableCell,+ TableEmpty,+ TableFooter,+ TableHead,+ TableHeader,+ TableRow,+} from './table'+import { Card, CardContent, CardHeader, CardTitle } from './card'const meta = {title: 'Primitives/Table',@@ -140,7 +152,7 @@ const tasks = [export const CellLayout: Story = {render: () => (- <Table fullWidth className="rounded-md border border-[var(--border)]">+ <Table fullWidth className="rounded-md border border-(--border)"><TableHeader><TableRow><TableHead expand>Task</TableHead>@@ -182,7 +194,7 @@ const members = [export const FullWidth: Story = {render: () => (- <Table fullWidth className="rounded-md border border-[var(--border)]">+ <Table fullWidth className="rounded-md border border-(--border)"><TableHeader><TableRow><TableHead expand>Member</TableHead>@@ -249,7 +261,7 @@ const manyRows = Array.from({ length: 40 }, (_, i) => ({export const StickyHeader: Story = {render: () => (- <Table stickyHeader className="h-72 max-w-2xl rounded-md border border-[var(--border)]">+ <Table stickyHeader className="h-72 max-w-2xl rounded-md border border-(--border)"><TableHeader><TableRow><TableHead>ID</TableHead>@@ -289,7 +301,7 @@ const wideColumns = [export const StickyColumn: Story = {render: () => (- <Table className="max-w-xl rounded-md border border-[var(--border)]">+ <Table className="max-w-xl rounded-md border border-(--border)"><TableHeader><TableRow><TableHead sticky="left">Region</TableHead>@@ -320,7 +332,7 @@ export const StickyColumn: Story = {export const StickyHeaderAndFirstColumn: Story = {render: () => (- <Table stickyHeader className="h-72 max-w-xl rounded-md border border-[var(--border)]">+ <Table stickyHeader className="h-72 max-w-xl rounded-md border border-(--border)"><TableHeader><TableRow><TableHead sticky="left">User</TableHead>@@ -351,7 +363,7 @@ export const StickyHeaderAndFirstColumn: Story = {export const StickyHeaderAndSecondColumn: Story = {render: () => (- <Table stickyHeader className="h-72 max-w-xl rounded-md border border-[var(--border)]">+ <Table stickyHeader className="h-72 max-w-xl rounded-md border border-(--border)"><TableHeader><TableRow><TableHead className="whitespace-nowrap">ID</TableHead>@@ -397,10 +409,10 @@ const pageRows = Array.from({ length: 60 }, (_, i) => ({export const PageStickyHeader: Story = {render: () => (<div className="max-w-2xl">- <p className="mb-4 text-sm text-[var(--muted-foreground)]">+ <p className="mb-4 text-sm text-(--muted-foreground)">Scroll the page — the header sticks to the window once it reaches the top.</p>- <Table stickyHeader="page" className="rounded-md border border-[var(--border)]">+ <Table stickyHeader="page" className="rounded-md border border-(--border)"><TableHeader><TableRow><TableHead>Order</TableHead>@@ -426,52 +438,13 @@ export const PageStickyHeader: Story = {),} satisfies Story-// Any column can be frozen, not just the first. Here the 3rd column (Status)-// is sticky="left"; scrolling right slides the Order/Customer columns under it.-export const StickyNonFirstColumn: Story = {- render: () => (- <Table className="max-w-xl rounded-md border border-[var(--border)]">- <TableHeader>- <TableRow>- <TableHead className="whitespace-nowrap">Order</TableHead>- <TableHead className="whitespace-nowrap">Customer</TableHead>- <TableHead sticky="left" className="whitespace-nowrap">- Status- </TableHead>- {wideColumns.map((q) => (- <TableHead key={q} className="text-right whitespace-nowrap">- {q}- </TableHead>- ))}- </TableRow>- </TableHeader>- <TableBody>- {pageRows.slice(0, 8).map((row, r) => (- <TableRow key={row.id}>- <TableCell className="font-medium whitespace-nowrap">{row.id}</TableCell>- <TableCell className="whitespace-nowrap">{row.customer}</TableCell>- <TableCell sticky="left" className="whitespace-nowrap">- <StatusBadge status={row.status} />- </TableCell>- {wideColumns.map((q, c) => (- <TableCell key={q} className="text-right">- ${(r + 1) * (c + 1) * 100}- </TableCell>- ))}- </TableRow>- ))}- </TableBody>- </Table>- ),-} satisfies Story-// Interactive headers: the whole label is a quill Button (label + sort// icon) with normal button hover — the seam for sorting, column menus, etc. The// button aligns with plain headers and doesn't shift layout; the non-interactive// "#" header stays plain text.export const InteractiveHeaders: Story = {render: () => (- <Table className="max-w-2xl rounded-md border border-[var(--border)]">+ <Table className="max-w-2xl rounded-md border border-(--border)"><TableHeader><TableRow><TableHead className="w-10">#</TableHead>@@ -531,7 +504,7 @@ function ActionsMenu({ label }: { label: string }): React.ReactElement {// `ml-auto`, opening the dummy dropdown menu.export const CellActions: Story = {render: () => (- <Table className="max-w-2xl rounded-md border border-[var(--border)]">+ <Table className="max-w-2xl rounded-md border border-(--border)"><TableHeader><TableRow><TableHead>Name</TableHead>@@ -561,7 +534,7 @@ export const CellActions: Story = {// each row.export const RowActions: Story = {render: () => (- <Table className="max-w-2xl rounded-md border border-[var(--border)]">+ <Table className="max-w-2xl rounded-md border border-(--border)"><TableHeader><TableRow><TableHead>Name</TableHead>@@ -587,3 +560,221 @@ export const RowActions: Story = {</Table>),} satisfies Story++// Empty state: TableEmpty renders the full-span cell for you (no manual colSpan,+// no height juggling) and centers its content. Give the Table a height (here a+// fixed `h-80`) and the empty cell fills the body.+export const EmptyState: Story = {+ render: () => (+ <Table fullWidth className="h-80 rounded-md border border-(--border)">+ <TableHeader>+ <TableRow>+ <TableHead expand>Table Empty</TableHead>+ <TableHead>Role</TableHead>+ <TableHead>Status</TableHead>+ </TableRow>+ </TableHeader>+ <TableEmpty>+ <Empty>+ <EmptyHeader>+ <EmptyMedia variant="icon">+ <Inbox />+ </EmptyMedia>+ <EmptyTitle>No members yet</EmptyTitle>+ <EmptyDescription>Invite teammates to start collaborating.</EmptyDescription>+ </EmptyHeader>+ <EmptyContent>+ <Button variant="primary">+ <Plus />+ Invite member+ </Button>+ </EmptyContent>+ </Empty>+ </TableEmpty>+ </Table>+ ),+} satisfies Story++// Table flush inside a Card: `gap-0 pb-0` on the Card + `p-0` on CardContent let+// the transparent cells reach the card's rounded edges with no double padding.+export const InCard: Story = {+ render: () => (+ <Card className="gap-0 pb-0">+ <CardHeader>+ <CardTitle>Table in Card</CardTitle>+ </CardHeader>+ <CardContent className="p-0">++ <Table fullWidth>+ <TableHeader>+ <TableRow>+ <TableHead>Name</TableHead>+ <TableHead>Email</TableHead>+ <TableHead>Role</TableHead>+ <TableHead className="w-0">+ <span className="sr-only">Actions</span>+ </TableHead>+ </TableRow>+ </TableHeader>+ <TableBody>+ {manyRows.slice(0, 6).map((row) => (+ <TableRow key={row.id} className="group/row">+ <TableCell className="font-medium">{row.name}</TableCell>+ <TableCell>{row.email}</TableCell>+ <TableCell>{row.role}</TableCell>+ <TableCell className="w-0 text-right">+ <ActionsMenu label={`Actions for ${row.name}`} />+ </TableCell>+ </TableRow>+ ))}+ </TableBody>+ </Table>+ </CardContent>+ </Card>+ ),+} satisfies Story++// Same flush card, with `min-h-120` on the Card + `flex-1` on CardContent so a+// short table still fills a taller card body.+export const InCardMinHeight: Story = {+ render: () => (+ <Card className="gap-0 pb-0 min-h-120">+ <CardHeader>+ <CardTitle>Table in Card</CardTitle>+ </CardHeader>+ <CardContent className="p-0">++ <Table fullWidth>+ <TableHeader>+ <TableRow>+ <TableHead>Name</TableHead>+ <TableHead>Email</TableHead>+ <TableHead>Role</TableHead>+ <TableHead className="w-0">+ <span className="sr-only">Actions</span>+ </TableHead>+ </TableRow>+ </TableHeader>+ <TableBody>+ {manyRows.slice(0, 6).map((row) => (+ <TableRow key={row.id} className="group/row">+ <TableCell className="font-medium">{row.name}</TableCell>+ <TableCell>{row.email}</TableCell>+ <TableCell>{row.role}</TableCell>+ <TableCell className="w-0 text-right">+ <ActionsMenu label={`Actions for ${row.name}`} />+ </TableCell>+ </TableRow>+ ))}+ </TableBody>+ </Table>+ </CardContent>+ </Card>+ ),+} satisfies Story+++// Sticky header inside a Card: a definite height (`h-96`, not `max-h-*` — the+// scroll viewport needs a resolved height) makes the body scroll, and+// `stickyHeader` freezes the header. Because the table sits on the card surface+// (not the app background), override `--quill-table-sticky-bg` to `var(--card)`+// so the frozen header matches — here via a Tailwind arbitrary property.+export const InCardStickyHeader: Story = {+ render: () => (+ <Card className="gap-0 pb-0">+ <CardHeader>+ <CardTitle>Table in Card</CardTitle>+ </CardHeader>+ <CardContent className="p-0">+ <Table fullWidth stickyHeader className="h-96 [--quill-table-sticky-bg:var(--card)]">+ <TableHeader>+ <TableRow>+ <TableHead expand>Name</TableHead>+ <TableHead>Email</TableHead>+ <TableHead>Role</TableHead>+ </TableRow>+ </TableHeader>+ <TableBody>+ {manyRows.map((row) => (+ <TableRow key={row.id}>+ <TableCell className="font-medium">{row.name}</TableCell>+ <TableCell>{row.email}</TableCell>+ <TableCell>{row.role}</TableCell>+ </TableRow>+ ))}+ </TableBody>+ </Table>+ </CardContent>+ </Card>+ ),+} satisfies Story++// Same empty cell, dropped inside a Card. The height comes from the chain Card+// min-h → CardContent flex-1 → Table h-full. Simplest form is just muted text.+export const InCardEmptyText: Story = {+ render: () => (+ <Card className="min-h-120 gap-0 pb-0">+ <CardHeader>+ <CardTitle>Table in Card Empty Text</CardTitle>+ </CardHeader>+ <CardContent className="flex-1 p-0">+ <Table fullWidth className="h-full">+ <TableHeader>+ <TableRow>+ <TableHead expand>Member</TableHead>+ <TableHead>Role</TableHead>+ <TableHead>Status</TableHead>+ </TableRow>+ </TableHeader>+ <TableEmpty>+ <Empty>+ <EmptyHeader>+ <EmptyDescription>No data for the selected period.</EmptyDescription>+ </EmptyHeader>+ </Empty>+ </TableEmpty>+ </Table>+ </CardContent>+ </Card>+ ),+} satisfies Story++// Empty state: the full Empty block (icon, title, description, action) inside+// TableEmpty — same primitive, richer content, still centered and stretched.+export const InCardEmptyBlock: Story = {+ render: () => (+ <Card className="min-h-120 gap-0 pb-0">+ <CardHeader>+ <CardTitle>Members</CardTitle>+ </CardHeader>+ <CardContent className="flex-1 p-0">+ <Table fullWidth className="h-full">+ <TableHeader>+ <TableRow>+ <TableHead expand>Member</TableHead>+ <TableHead>Role</TableHead>+ <TableHead>Status</TableHead>+ </TableRow>+ </TableHeader>+ <TableEmpty>+ <Empty>+ <EmptyHeader>+ <EmptyMedia variant="icon">+ <Inbox />+ </EmptyMedia>+ <EmptyTitle>No members yet</EmptyTitle>+ <EmptyDescription>Invite teammates to start collaborating.</EmptyDescription>+ </EmptyHeader>+ <EmptyContent>+ <Button variant="primary">+ <Plus />+ Invite member+ </Button>+ </EmptyContent>+ </Empty>+ </TableEmpty>+ </Table>+ </CardContent>+ </Card>+ ),+} satisfies Storydiff --git a/packages/quill/packages/primitives/src/table.tsx b/packages/quill/packages/primitives/src/table.tsxindex 0fb6b6ff5ff2..589c3cd9f508 100644--- a/packages/quill/packages/primitives/src/table.tsx+++ b/packages/quill/packages/primitives/src/table.tsx@@ -193,6 +193,25 @@ const TableCell = React.forwardRef<HTMLTableCellElement, React.ComponentProps<'t})+// Full-span empty state. Renders its own tbody + row + cell so it drops in+// alongside TableHeader where a TableBody would go. `colSpan` defaults huge and+// browsers clamp it to the real column count, so callers rarely set it. The cell+// stretches to the table's body height (give the Table a height to fill it) and+// centers its content — drop in `<Empty>` or plain text, no `h-full` needed.+const TableEmpty = React.forwardRef<HTMLTableCellElement, React.ComponentProps<'td'>>(+ function TableEmpty({ className, colSpan = 1000, children, ...props }, ref) {+ return (+ <tbody data-slot="table-empty">+ <tr>+ <td ref={ref} colSpan={colSpan} className={cn('quill-table__empty', className)} {...props}>+ <div className="quill-table__empty-inner">{children}</div>+ </td>+ </tr>+ </tbody>+ )+ }+)+const TableCaption = React.forwardRef<HTMLTableCaptionElement, React.ComponentProps<'caption'>>(function TableCaption({ className, ...props },ref@@ -207,6 +226,7 @@ TableFooter.displayName = 'TableFooter'TableRow.displayName = 'TableRow'TableHead.displayName = 'TableHead'TableCell.displayName = 'TableCell'+TableEmpty.displayName = 'TableEmpty'TableCaption.displayName = 'TableCaption'-export { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableCaption }+export { Table, TableHeader, TableBody, TableFooter, TableHead, TableRow, TableCell, TableEmpty, TableCaption }