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

Write a better algorithm for "flattening" spanning cells #2

Open
shawnbot opened this issue Apr 2, 2015 · 0 comments
Open

Write a better algorithm for "flattening" spanning cells #2

shawnbot opened this issue Apr 2, 2015 · 0 comments
Assignees

Comments

@shawnbot
Copy link
Owner

shawnbot commented Apr 2, 2015

The current one for column headers works well for this table, but I need more examples. Also, there is currently zero support for data cells with colspan or rowspan attributes.

Tests should cover:

  • Spanning column headers. E.g. for this table the last three columns should be parsed as "Week Ending Mar 27", "Week Ending Mar 20", and "2015 Feb":

    image

  • Whitespace: <br> should be treated as space, whitespace trimmed from the left and right, and all other whitespace collapsed into single spaces.

  • Spanning data cells. If a <td> has colspan="2" then the resulting row object should have that cell's text value for both of the keys of the columns it spans. Likewise, if it has rowspan="2", then the following row should "inherit" this row's value for this column.

@shawnbot shawnbot self-assigned this Apr 2, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant