Skip to content

Commit

Permalink
Lint fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
gucal committed Feb 6, 2024
1 parent f94faed commit bc3853e
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 13 deletions.
25 changes: 12 additions & 13 deletions components/doc/chart/accessibilitydoc.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,18 +13,17 @@ export function AccessibilityDoc() {
};

return (
<DocSectionText id="accessibility" label="Accessibility">
<h3>Screen Reader</h3>
<p>
Chart components internally use <i>canvas</i> element, refer to the{' '}
<a className="text-primary hover:underline font-medium" href="https://www.chartjs.org/docs/latest/general/accessibility.html">
Chart.js accessibility
</a>{' '}
guide for more information. The canvas element can be customized with <i>canvasProps</i> property to define aria roles and properties, in addition any content inside the component is directly passed as a child of the canvas to be
able to provide fallback content like a table.
</p>
<DocSectionCode code={code} hideToggleCode import hideCodeSandbox hideStackBlitz />
</DocSectionText>

<DocSectionText id="accessibility" label="Accessibility">
<h3>Screen Reader</h3>
<p>
Chart components internally use <i>canvas</i> element, refer to the{' '}
<a className="text-primary hover:underline font-medium" href="https://www.chartjs.org/docs/latest/general/accessibility.html">
Chart.js accessibility
</a>{' '}
guide for more information. The canvas element can be customized with <i>canvasProps</i> property to define aria roles and properties, in addition any content inside the component is directly passed as a child of the canvas to be able
to provide fallback content like a table.
</p>
<DocSectionCode code={code} hideToggleCode import hideCodeSandbox hideStackBlitz />
</DocSectionText>
);
}
1 change: 1 addition & 0 deletions components/lib/multiselect/MultiSelect.js
Original file line number Diff line number Diff line change
Expand Up @@ -912,6 +912,7 @@ export const MultiSelect = React.memo(
setTimeout(() => {
props.overlayVisible ? show() : hide();
}, 100);
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [props.overlayVisible]);

useUpdateEffect(() => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,13 @@ const useAnimatedFeatures = (animationRef, arrayLength, seconds = 10000) => {
clearAllIntervals();
setSelectedID(1);
}
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [animationRef, isVisible]);

useEffect(() => {
if (!hoveredID) null;
handleHover(hoveredID, 'onMouseEnter');
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [selectedID]);

return { selectedID, setHoveredID, handleClick, handleHover };
Expand Down
2 changes: 2 additions & 0 deletions components/templates/templateFeaturesAnimation/useVisible.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,11 @@ const useVisible = (element, rootMargin = 0.2) => {

return () => {
if (observer && element.current) {
// eslint-disable-next-line react-hooks/exhaustive-deps
observer.unobserve(element.current);
}
};
// eslint-disable-next-line react-hooks/exhaustive-deps
}, []);

return isVisible;
Expand Down

0 comments on commit bc3853e

Please sign in to comment.