Skip to content

Conversation

@boaz0
Copy link
Member

@boaz0 boaz0 commented Nov 16, 2018

This is still work in progress. Hopefully it will be ready by next week.

@patternfly-build
Copy link
Collaborator

PatternFly-React preview: https://927-pr-patternfly-react-patternfly.surge.sh

@coveralls
Copy link

coveralls commented Nov 16, 2018

Pull Request Test Coverage Report for Build 3448

  • 16 of 16 (100.0%) changed or added relevant lines in 4 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.05%) to 82.185%

Totals Coverage Status
Change from base Build 3442: 0.05%
Covered Lines: 3984
Relevant Lines: 4585

💛 - Coveralls

@tlabaj tlabaj requested review from dlabaj and jschuler November 16, 2018 19:00
@tlabaj tlabaj added the PF4 label Nov 16, 2018
@jschuler
Copy link
Collaborator

Thanks for starting this @boaz1337 , there is an issue that was assigned to me #867 but I had not started yet so this is good. Can you just go over the description and notes in that issue? Thanks! @LHinson

@rachael-phillips
Copy link
Contributor

Hi @boaz1337! I thought I would follow up here, and ask for an update. Where are we at on this issue right now?

@boaz0
Copy link
Member Author

boaz0 commented Nov 26, 2018

Hi @rachael-phillips
I am working on adding expandable data list and data list with checkbox and action in the next days. Probably push it by the end of the week.

@rachael-phillips
Copy link
Contributor

Thank you for the update, @boaz1337 !

@boaz0 boaz0 changed the title [WIP] feat(DataList): Add simple data list feat(DataList): Add simple data list Nov 30, 2018
dlabaj
dlabaj previously approved these changes Nov 30, 2018
import React from 'react';
import { css } from '@patternfly/react-styles';
import PropTypes from 'prop-types';
import styles from '@patternfly/patternfly-next/components/DataList/styles.css';
Copy link
Collaborator

Choose a reason for hiding this comment

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

Not an issue in your code, but i think this css should have a more specific name, will address with Core

Copy link
Collaborator

Choose a reason for hiding this comment

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


const DataList = ({ children, className, 'aria-label': ariaLabel, ...props }) => {
return (
<ul className={css(styles.dataList, boxShStyles.boxShadowMd, className)} role="list" aria-label={ariaLabel} {...props}>
Copy link
Collaborator

Choose a reason for hiding this comment

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

Ideally this box shadow class is rolled into the data list class so we wouldn't have to import it. Also addressing with Core

Copy link
Collaborator

Choose a reason for hiding this comment

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


const DataListAction = ({ className, ...props }) => (
<div className={css(styles.dataListAction, className)} {...props}>
<Button variant="plain" aria-label="Actions">
Copy link
Collaborator

Choose a reason for hiding this comment

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

I think we want to get this through a prop, can default to Actions perhaps

Copy link
Collaborator

Choose a reason for hiding this comment

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

Also needs aria-labelledby
aria-labelledby="{title_cell_id} {data_list_action_id}"
See:
https://pf-next.com/components/DataList/examples/

Copy link
Member Author

Choose a reason for hiding this comment

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

No problem but just wanted to hear your opinion.
It seems like Dropdown is more suitable here than Button?
What do you think?

Copy link
Contributor

Choose a reason for hiding this comment

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

If we use the Dropdown in the example, I assume then it would show a menu on click? If that's the case, then I think a Dropdown would be better.

Also, does this implementation allow the consumer to use a single action button if that's what their design calls for?

Copy link
Member Author

Choose a reason for hiding this comment

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

@jgiardino - yeah that's what I thought. I will change the implementation to use Dropdown.
Also, I will work on the case when there is a single action.

Thanks for your help!

@jgiardino
Copy link
Contributor

I just reviewed this with JAWS, and the controls are announced as expected. Great job on this! I expected all the combinations of aria-label and aria-labelledby to be a challenge to implement.

Copy link
Member

@christiemolloy christiemolloy left a comment

Choose a reason for hiding this comment

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

This looks spot on to the example we have in Core !
In Data List with modifiers, example 3, can you make that expandable functionality work?

jschuler
jschuler previously approved these changes Dec 4, 2018
Signed-off-by: Boaz Shuster <boaz.shuster.github@gmail.com>
@boaz0
Copy link
Member Author

boaz0 commented Dec 6, 2018

Hi @christiemolloy

I updated the examples as you suggested.

Thanks.

@christiemolloy
Copy link
Member

@boaz1337 this looks awesome! thanks for updating that

@jschuler jschuler merged commit cd25279 into patternfly:master Dec 7, 2018
@rachael-phillips rachael-phillips added this to the 1.0.0-alpha.6 milestone Dec 7, 2018
@boaz0 boaz0 deleted the datalist branch December 13, 2018 22:00
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.

9 participants