-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
14 changed files
with
235 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import * as React from 'react'; | ||
import ApiPage from 'docs/src/modules/components/ApiPage'; | ||
import mapApiPageTranslations from 'docs/src/modules/utils/mapApiPageTranslations'; | ||
import jsonPageContent from './bar-label.json'; | ||
|
||
export default function Page(props) { | ||
const { descriptions, pageContent } = props; | ||
return <ApiPage descriptions={descriptions} pageContent={pageContent} />; | ||
} | ||
|
||
Page.getInitialProps = () => { | ||
const req = require.context( | ||
'docsx/translations/api-docs/charts/bar-label', | ||
false, | ||
/\.\/bar-label.*.json$/, | ||
); | ||
const descriptions = mapApiPageTranslations(req); | ||
|
||
return { | ||
descriptions, | ||
pageContent: jsonPageContent, | ||
}; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
{ | ||
"props": { | ||
"height": { "type": { "name": "number" }, "required": true }, | ||
"value": { "type": { "name": "number" }, "required": true }, | ||
"width": { "type": { "name": "number" }, "required": true }, | ||
"barLabel": { "type": { "name": "union", "description": "'value'<br>| func" } }, | ||
"slotProps": { "type": { "name": "object" }, "default": "{}" }, | ||
"slots": { | ||
"type": { "name": "object" }, | ||
"default": "{}", | ||
"additionalInfo": { "slotsApi": true } | ||
} | ||
}, | ||
"name": "BarLabel", | ||
"imports": [ | ||
"import { BarLabel } from '@mui/x-charts/BarChart';", | ||
"import { BarLabel } from '@mui/x-charts';" | ||
], | ||
"slots": [ | ||
{ | ||
"name": "barLabel", | ||
"description": "The component that renders the bar label.", | ||
"default": "BarLabelComponent", | ||
"class": null | ||
} | ||
], | ||
"classes": [ | ||
{ | ||
"key": "faded", | ||
"className": "MuiBarLabel-faded", | ||
"description": "Styles applied to the root element if it is faded.", | ||
"isGlobal": false | ||
}, | ||
{ | ||
"key": "highlighted", | ||
"className": "MuiBarLabel-highlighted", | ||
"description": "Styles applied to the root element if it is highlighted.", | ||
"isGlobal": false | ||
}, | ||
{ | ||
"key": "root", | ||
"className": "MuiBarLabel-root", | ||
"description": "Styles applied to the root element.", | ||
"isGlobal": false | ||
} | ||
], | ||
"muiName": "MuiBarLabel", | ||
"filename": "/packages/x-charts/src/BarChart/BarLabel/BarLabel.tsx", | ||
"inheritance": null, | ||
"demos": "<ul><li><a href=\"/x/react-charts/bars/\">Charts - Bars</a></li></ul>", | ||
"cssComponent": false | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 25 additions & 0 deletions
25
docs/translations/api-docs/charts/bar-label/bar-label.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
{ | ||
"componentDescription": "", | ||
"propDescriptions": { | ||
"barLabel": { "description": "The bar label type or formatter." }, | ||
"height": { "description": "The height of the bar." }, | ||
"slotProps": { "description": "The props used for each component slot." }, | ||
"slots": { "description": "Overridable component slots." }, | ||
"value": { "description": "The value of the data point." }, | ||
"width": { "description": "The width of the bar." } | ||
}, | ||
"classDescriptions": { | ||
"faded": { | ||
"description": "Styles applied to {{nodeName}} if {{conditions}}.", | ||
"nodeName": "the root element", | ||
"conditions": "it is faded" | ||
}, | ||
"highlighted": { | ||
"description": "Styles applied to {{nodeName}} if {{conditions}}.", | ||
"nodeName": "the root element", | ||
"conditions": "it is highlighted" | ||
}, | ||
"root": { "description": "Styles applied to the root element." } | ||
}, | ||
"slotDescriptions": { "barLabel": "The component that renders the bar label." } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters