diff --git a/docs/data/charts/axis/AxisCustomization.tsx b/docs/data/charts/axis/AxisCustomization.tsx deleted file mode 100644 index 6210abae0b24b..0000000000000 --- a/docs/data/charts/axis/AxisCustomization.tsx +++ /dev/null @@ -1,82 +0,0 @@ -import * as React from 'react'; -import Box from '@mui/material/Box'; -import ChartsUsageDemo from 'docsx/src/modules/components/ChartsUsageDemo'; -import { ScatterChart } from '@mui/x-charts/ScatterChart'; -import { Chance } from 'chance'; - -const chance = new Chance(42); - -const data = Array.from({ length: 200 }, () => ({ - x: chance.floating({ min: -25, max: 25 }), - y: chance.floating({ min: -25, max: 25 }), -})).map((d, index) => ({ ...d, id: index })); - -const defaultXAxis = { - disableLine: false, - disableTicks: false, - fontSize: 12, - label: 'My axis', - tickSize: 6, -}; - -type DefaultXAxis = typeof defaultXAxis; -type DefaultXAxisKey = keyof DefaultXAxis; - -export default function AxisCustomization() { - return ( - ( - - - - )} - getCode={({ props }: { props: DefaultXAxis }) => - [ - `import { ScatterChart } from '@mui/x-charts/ScatterChart';`, - '', - ` - props[prop as DefaultXAxisKey] !== - defaultXAxis[prop as DefaultXAxisKey], - ) - .map( - (prop) => - ` ${prop}: ${ - typeof props[prop as DefaultXAxisKey] === 'string' - ? `"${props[prop as DefaultXAxisKey]}"` - : props[prop as DefaultXAxisKey] - },`, - ), - ' }}', - '/>', - ].join('\n') - } - /> - ); -} diff --git a/docs/data/charts/axis/AxisCustomization.js b/docs/data/charts/axis/AxisCustomizationNoSnap.js similarity index 97% rename from docs/data/charts/axis/AxisCustomization.js rename to docs/data/charts/axis/AxisCustomizationNoSnap.js index 47daece6e102e..c5d485e2286f7 100644 --- a/docs/data/charts/axis/AxisCustomization.js +++ b/docs/data/charts/axis/AxisCustomizationNoSnap.js @@ -18,8 +18,7 @@ const defaultXAxis = { label: 'My axis', tickSize: 6, }; - -export default function AxisCustomization() { +export default function AxisCustomizationNoSnap() { return (