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

KTable - Week 2 #649

Merged
merged 6 commits into from
Jun 5, 2024
Merged

KTable - Week 2 #649

merged 6 commits into from
Jun 5, 2024

Conversation

BabyElias
Copy link
Contributor

Description

  • Created child component KTableGridItem for use with KTable
  • Separated datatype into String, numeric,date and others. Added left alignment for numeric datatype within grid.
  • Added keyboard accessibility using arrow keys
  • Added sorting functionality

type: Array,
required: true,
},
caption: {
Copy link
Member

Choose a reason for hiding this comment

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

Regarding caption prop, this is good approach. In the final version, caption and any other strings will need to be received via prop from products, such as Kolibri, because KDS doesn't contain mechanism for translations.

KTableGridItem,
},
props: {
headers: {
Copy link
Member

Choose a reason for hiding this comment

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

No need to do it now, rather a note for when we're finalizing API (that is shortly before using the table in Kolibri) - I recommend documenting props, slots, and events with JSDocs comments.

Some examples

The documentation will then use these to auto-generate the bottom section of the documentation page https://design-system.learningequality.org/kimg/#props

export default {
name: 'KTableGridItem',
props: {
content: {
Copy link
Member

Choose a reason for hiding this comment

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

In the next iteration, I'd recommend using slot rather than content prop, since we will need to work with rich HTML content. This will make transitioning towards exposing scoped slots easier.

@MisRob
Copy link
Member

MisRob commented Jun 5, 2024

Looking great, @BabyElias! I left a few notes you can have a look later and will merge it now (but if you had any questions or things to chat about in more detail, we can still discuss here)

@MisRob MisRob merged commit 491fe19 into learningequality:gsoc-table Jun 5, 2024
7 of 8 checks passed
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