-
Notifications
You must be signed in to change notification settings - Fork 46
Feat: new expandable table component #354
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
base: next
Are you sure you want to change the base?
Conversation
|
PinkProject ID: Note Appwrite has a Discord community with over 16 000 members. |
The preview deployment is ready. 🟢 Open Preview | Open Build Logs Last updated at: 2025-08-17 19:13:58 CET |
Uh oh! @HarshMN2345, the image you shared is missing helpful alt text. Check your pull request body. Alt text is an invisible description that helps screen readers describe images to blind or low-vision users. If you are using markdown to display images, add your alt text inside the brackets of the markdown image. Learn more about alt text at Basic writing and formatting syntax: images on GitHub Docs. |
🚀 Previews available on pkg.vc!📦
|
Uh oh! @HarshMN2345, the image you shared is missing helpful alt text. Check your pull request body. Alt text is an invisible description that helps screen readers describe images to blind or low-vision users. If you are using markdown to display images, add your alt text inside the brackets of the markdown image. Learn more about alt text at Basic writing and formatting syntax: images on GitHub Docs. |
1 similar comment
Uh oh! @HarshMN2345, the image you shared is missing helpful alt text. Check your pull request body. Alt text is an invisible description that helps screen readers describe images to blind or low-vision users. If you are using markdown to display images, add your alt text inside the brackets of the markdown image. Learn more about alt text at Basic writing and formatting syntax: images on GitHub Docs. |
Uh oh! @HarshMN2345, the image you shared is missing helpful alt text. Check your pull request body. Alt text is an invisible description that helps screen readers describe images to blind or low-vision users. If you are using markdown to display images, add your alt text inside the brackets of the markdown image. Learn more about alt text at Basic writing and formatting syntax: images on GitHub Docs. |
columns: ExpandableTableColumn[]; | ||
gridTemplateColumns: string; | ||
childGridTemplate: string; | ||
alignment: (align?: 'left' | 'center' | 'right') => string; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why do we need a function at root level?
it returns the same value of the column's align
, right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, but we still need to map left-> flex-start and so on to maintain alignment,so both header and child cells use a single source.
otherwise need to add like this
justify-content: {col.align === 'right' ? 'flex-end' : col.align === 'center' ? 'center' : 'flex-start'}
unregister: (id: string) => void; | ||
columns: ExpandableTableColumn[]; | ||
gridTemplateColumns: string; | ||
childGridTemplate: string; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this for summary slot layout? If so, why do we insist it to be a grid? Does Layout.Stack
not suffice with justifyContent
in the slot from the user's side?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, this is for the summary slot. childGridTemplate makes summary rows stay aligned with the table columns and inherit the same styling and responsiveness. With Layout.Stack we’d have to recreate all that styling manually again
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the ✨ Finishing touches🧪 Generate unit tests
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Uh oh! @HarshMN2345, the image you shared is missing helpful alt text. Check your pull request body. Alt text is an invisible description that helps screen readers describe images to blind or low-vision users. If you are using markdown to display images, add your alt text inside the brackets of the markdown image. Learn more about alt text at Basic writing and formatting syntax: images on GitHub Docs. |
const rowId = getContext<string>('rowId'); | ||
|
||
$: columnIndex = root.columns.findIndex((c) => c.id === column); | ||
$: justify = root.alignment(root.columns[columnIndex]?.align); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we don't need the root.alignment
method. see - v2/pink-sb/src/lib/table/cell/Base.svelte
pointer-events: none; | ||
} | ||
|
||
:global(.child-row) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
does this expect the end user to always have a div or other element have this class? 🤔
7582698
to
7a84c31
Compare
Uh oh! @HarshMN2345, the image you shared is missing helpful alt text. Check your pull request body. Alt text is an invisible description that helps screen readers describe images to blind or low-vision users. If you are using markdown to display images, add your alt text inside the brackets of the markdown image. Learn more about alt text at Basic writing and formatting syntax: images on GitHub Docs. |
What does this PR do?
Introduces a new ExpandableTable component
Test Plan
Related PRs and Issues
(If this PR is related to any other PR or resolves any issue or related to any issue link all related PR and issues here.)
Have you read the Contributing Guidelines on issues?
yes