Skip to content

Commit

Permalink
Merge pull request plotly#170 from plotly/mdn-update-yari
Browse files Browse the repository at this point in the history
Update component generation
  • Loading branch information
alexcjohnson committed Dec 15, 2020
1 parent 1b78f59 commit d0dafd3
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
5 changes: 4 additions & 1 deletion packages/dash-html-components/scripts/extract-attributes.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,10 @@ const attributeMap = supportedAttributes.reduce((map, reactAttribute) => {
* descriptions and supported elements.
*/
function extractAttributes($) {
const $table = $('#Attribute_list').next('table');
const $table = $('#Attribute_list').parent().find('table');
if($table.length !== 1) {
throw new Error('page structure changed at ' + htmlURL);
}
const attributes = {};

$table.find('tbody tr').each((i, row) => {
Expand Down
3 changes: 3 additions & 0 deletions packages/dash-html-components/scripts/generate-components.js
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,9 @@ function generatePropTypes(element, attributes) {
component_name: PropTypes.string,
}),
/**
* Dash-assigned callback that gets fired when the element is clicked.
*/
'setProps': PropTypes.func`
}

Expand Down

0 comments on commit d0dafd3

Please # to comment.