Skip to content

Commit

Permalink
[docs] Remove See Slots Section text from Material UI slots description
Browse files Browse the repository at this point in the history
  • Loading branch information
hbjORbj committed Feb 21, 2023
1 parent a72a53c commit cd609e7
Show file tree
Hide file tree
Showing 14 changed files with 15 additions and 15 deletions.
2 changes: 1 addition & 1 deletion docs/translations/api-docs/alert/alert.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"role": "The ARIA role attribute of the element.",
"severity": "The severity of the alert. This defines the color and icon used.",
"slotProps": "The extra props for the slot components. You can override the existing props or add new ones.<br>This prop is an alias for the <code>componentsProps</code> prop, which will be deprecated in the future.",
"slots": "The components used for each slot inside.<br>This prop is an alias for the <code>components</code> prop, which will be deprecated in the future. See <a href=\"#slots\">Slots API</a> below for more details.",
"slots": "The components used for each slot inside.<br>This prop is an alias for the <code>components</code> prop, which will be deprecated in the future.",
"sx": "The system prop that allows defining system overrides as well as additional CSS styles. See the <a href=\"/system/getting-started/the-sx-prop/\">`sx` page</a> for more details.",
"variant": "The variant to use."
},
Expand Down
2 changes: 1 addition & 1 deletion docs/translations/api-docs/backdrop/backdrop.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"invisible": "If <code>true</code>, the backdrop is invisible. It can be used when rendering a popover or a custom select component.",
"open": "If <code>true</code>, the component is shown.",
"slotProps": "The extra props for the slot components. You can override the existing props or add new ones.<br>This prop is an alias for the <code>componentsProps</code> prop, which will be deprecated in the future.",
"slots": "The components used for each slot inside.<br>This prop is an alias for the <code>components</code> prop, which will be deprecated in the future. See <a href=\"#slots\">Slots API</a> below for more details.",
"slots": "The components used for each slot inside.<br>This prop is an alias for the <code>components</code> prop, which will be deprecated in the future.",
"sx": "The system prop that allows defining system overrides as well as additional CSS styles. See the <a href=\"/system/getting-started/the-sx-prop/\">`sx` page</a> for more details.",
"TransitionComponent": "The component used for the transition. <a href=\"/material-ui/transitions/#transitioncomponent-prop\">Follow this guide</a> to learn more about the requirements for this component.",
"transitionDuration": "The duration for the transition, in milliseconds. You may specify a single timeout for all transitions, or individually with an object."
Expand Down
2 changes: 1 addition & 1 deletion docs/translations/api-docs/badge/badge.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"overlap": "Wrapped shape the badge should overlap.",
"showZero": "Controls whether the badge is hidden when <code>badgeContent</code> is zero.",
"slotProps": "The props used for each slot inside the Badge.",
"slots": "The components used for each slot inside the Badge. Either a string to use a HTML element or a component. See <a href=\"#slots\">Slots API</a> below for more details.",
"slots": "The components used for each slot inside the Badge. Either a string to use a HTML element or a component.",
"sx": "The system prop that allows defining system overrides as well as additional CSS styles. See the <a href=\"/system/getting-started/the-sx-prop/\">`sx` page</a> for more details.",
"variant": "The variant to use."
},
Expand Down
2 changes: 1 addition & 1 deletion docs/translations/api-docs/filled-input/filled-input.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"required": "If <code>true</code>, the <code>input</code> element is required. The prop defaults to the value (<code>false</code>) inherited from the parent FormControl component.",
"rows": "Number of rows to display when multiline option is set to true.",
"slotProps": "The extra props for the slot components. You can override the existing props or add new ones.<br>This prop is an alias for the <code>componentsProps</code> prop, which will be deprecated in the future.",
"slots": "The components used for each slot inside.<br>This prop is an alias for the <code>components</code> prop, which will be deprecated in the future. See <a href=\"#slots\">Slots API</a> below for more details.",
"slots": "The components used for each slot inside.<br>This prop is an alias for the <code>components</code> prop, which will be deprecated in the future.",
"startAdornment": "Start <code>InputAdornment</code> for this component.",
"sx": "The system prop that allows defining system overrides as well as additional CSS styles. See the <a href=\"/system/getting-started/the-sx-prop/\">`sx` page</a> for more details.",
"type": "Type of the <code>input</code> element. It should be <a href=\"https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#Form_%3Cinput%3E_types\">a valid HTML5 input type</a>.",
Expand Down
2 changes: 1 addition & 1 deletion docs/translations/api-docs/input-base/input-base.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"rows": "Number of rows to display when multiline option is set to true.",
"size": "The size of the component.",
"slotProps": "The extra props for the slot components. You can override the existing props or add new ones.<br>This prop is an alias for the <code>componentsProps</code> prop, which will be deprecated in the future.",
"slots": "The components used for each slot inside.<br>This prop is an alias for the <code>components</code> prop, which will be deprecated in the future. See <a href=\"#slots\">Slots API</a> below for more details.",
"slots": "The components used for each slot inside.<br>This prop is an alias for the <code>components</code> prop, which will be deprecated in the future.",
"startAdornment": "Start <code>InputAdornment</code> for this component.",
"sx": "The system prop that allows defining system overrides as well as additional CSS styles. See the <a href=\"/system/getting-started/the-sx-prop/\">`sx` page</a> for more details.",
"type": "Type of the <code>input</code> element. It should be <a href=\"https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#Form_%3Cinput%3E_types\">a valid HTML5 input type</a>.",
Expand Down
2 changes: 1 addition & 1 deletion docs/translations/api-docs/input/input.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
"required": "If <code>true</code>, the <code>input</code> element is required. The prop defaults to the value (<code>false</code>) inherited from the parent FormControl component.",
"rows": "Number of rows to display when multiline option is set to true.",
"slotProps": "The extra props for the slot components. You can override the existing props or add new ones.<br>This prop is an alias for the <code>componentsProps</code> prop, which will be deprecated in the future.",
"slots": "The components used for each slot inside.<br>This prop is an alias for the <code>components</code> prop, which will be deprecated in the future. See <a href=\"#slots\">Slots API</a> below for more details.",
"slots": "The components used for each slot inside.<br>This prop is an alias for the <code>components</code> prop, which will be deprecated in the future.",
"startAdornment": "Start <code>InputAdornment</code> for this component.",
"sx": "The system prop that allows defining system overrides as well as additional CSS styles. See the <a href=\"/system/getting-started/the-sx-prop/\">`sx` page</a> for more details.",
"type": "Type of the <code>input</code> element. It should be <a href=\"https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#Form_%3Cinput%3E_types\">a valid HTML5 input type</a>.",
Expand Down
2 changes: 1 addition & 1 deletion docs/translations/api-docs/list-item/list-item.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"secondaryAction": "The element to display at the end of ListItem.",
"selected": "Use to apply selected styling.",
"slotProps": "The extra props for the slot components. You can override the existing props or add new ones.<br>This prop is an alias for the <code>componentsProps</code> prop, which will be deprecated in the future.",
"slots": "The components used for each slot inside.<br>This prop is an alias for the <code>components</code> prop, which will be deprecated in the future. See <a href=\"#slots\">Slots API</a> below for more details.",
"slots": "The components used for each slot inside.<br>This prop is an alias for the <code>components</code> prop, which will be deprecated in the future.",
"sx": "The system prop that allows defining system overrides as well as additional CSS styles. See the <a href=\"/system/getting-started/the-sx-prop/\">`sx` page</a> for more details."
},
"classDescriptions": {
Expand Down
2 changes: 1 addition & 1 deletion docs/translations/api-docs/modal/modal.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"onClose": "Callback fired when the component requests to be closed. The <code>reason</code> parameter can optionally be used to control the response to <code>onClose</code>.<br><br><strong>Signature:</strong><br><code>function(event: object, reason: string) =&gt; void</code><br><em>event:</em> The event source of the callback.<br><em>reason:</em> Can be: <code>&quot;escapeKeyDown&quot;</code>, <code>&quot;backdropClick&quot;</code>.",
"open": "If <code>true</code>, the component is shown.",
"slotProps": "The props used for each slot inside the Modal.",
"slots": "The components used for each slot inside the Modal. Either a string to use a HTML element or a component. See <a href=\"#slots\">Slots API</a> below for more details.",
"slots": "The components used for each slot inside the Modal. Either a string to use a HTML element or a component.",
"sx": "The system prop that allows defining system overrides as well as additional CSS styles. See the <a href=\"/system/getting-started/the-sx-prop/\">`sx` page</a> for more details."
},
"classDescriptions": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"readOnly": "It prevents the user from changing the value of the field (not from interacting with the field).",
"required": "If <code>true</code>, the <code>input</code> element is required. The prop defaults to the value (<code>false</code>) inherited from the parent FormControl component.",
"rows": "Number of rows to display when multiline option is set to true.",
"slots": "The components used for each slot inside.<br>This prop is an alias for the <code>components</code> prop, which will be deprecated in the future. See <a href=\"#slots\">Slots API</a> below for more details.",
"slots": "The components used for each slot inside.<br>This prop is an alias for the <code>components</code> prop, which will be deprecated in the future.",
"startAdornment": "Start <code>InputAdornment</code> for this component.",
"sx": "The system prop that allows defining system overrides as well as additional CSS styles. See the <a href=\"/system/getting-started/the-sx-prop/\">`sx` page</a> for more details.",
"type": "Type of the <code>input</code> element. It should be <a href=\"https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#Form_%3Cinput%3E_types\">a valid HTML5 input type</a>.",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"selected": "If <code>true</code> the pagination item is selected.",
"shape": "The shape of the pagination item.",
"size": "The size of the component.",
"slots": "The components used for each slot inside.<br>This prop is an alias for the <code>components</code> prop, which will be deprecated in the future. See <a href=\"#slots\">Slots API</a> below for more details.",
"slots": "The components used for each slot inside.<br>This prop is an alias for the <code>components</code> prop, which will be deprecated in the future.",
"sx": "The system prop that allows defining system overrides as well as additional CSS styles. See the <a href=\"/system/getting-started/the-sx-prop/\">`sx` page</a> for more details.",
"type": "The type of pagination item.",
"variant": "The variant to use."
Expand Down
2 changes: 1 addition & 1 deletion docs/translations/api-docs/popper/popper.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"popperOptions": "Options provided to the <a href=\"https://popper.js.org/docs/v2/constructors/#options\"><code>Popper.js</code></a> instance.",
"popperRef": "A ref that points to the used popper instance.",
"slotProps": "The props used for each slot inside the Popper.",
"slots": "The components used for each slot inside the Popper. Either a string to use a HTML element or a component. See <a href=\"#slots\">Slots API</a> below for more details.",
"slots": "The components used for each slot inside the Popper. Either a string to use a HTML element or a component.",
"sx": "The system prop that allows defining system overrides as well as additional CSS styles. See the <a href=\"/system/getting-started/the-sx-prop/\">`sx` page</a> for more details.",
"transition": "Help supporting a react-transition-group/Transition component."
},
Expand Down
2 changes: 1 addition & 1 deletion docs/translations/api-docs/slider/slider.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"scale": "A transformation function, to change the scale of the slider.<br><br><strong>Signature:</strong><br><code>function(x: any) =&gt; any</code><br>",
"size": "The size of the slider.",
"slotProps": "The props used for each slot inside the Slider.",
"slots": "The components used for each slot inside the Slider. Either a string to use a HTML element or a component. See <a href=\"#slots\">Slots API</a> below for more details.",
"slots": "The components used for each slot inside the Slider. Either a string to use a HTML element or a component.",
"step": "The granularity with which the slider can step through values. (A &quot;discrete&quot; slider.) The <code>min</code> prop serves as the origin for the valid values. We recommend (max - min) to be evenly divisible by the step.<br>When step is <code>null</code>, the thumb can only be slid onto marks provided with the <code>marks</code> prop.",
"sx": "The system prop that allows defining system overrides as well as additional CSS styles. See the <a href=\"/system/getting-started/the-sx-prop/\">`sx` page</a> for more details.",
"tabIndex": "Tab index attribute of the hidden <code>input</code> element.",
Expand Down
2 changes: 1 addition & 1 deletion docs/translations/api-docs/tooltip/tooltip.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"PopperComponent": "The component used for the popper.",
"PopperProps": "Props applied to the <a href=\"/material-ui/api/popper/\"><code>Popper</code></a> element.",
"slotProps": "The extra props for the slot components. You can override the existing props or add new ones.<br>This prop is an alias for the <code>componentsProps</code> prop, which will be deprecated in the future.",
"slots": "The components used for each slot inside.<br>This prop is an alias for the <code>components</code> prop, which will be deprecated in the future. See <a href=\"#slots\">Slots API</a> below for more details.",
"slots": "The components used for each slot inside.<br>This prop is an alias for the <code>components</code> prop, which will be deprecated in the future.",
"sx": "The system prop that allows defining system overrides as well as additional CSS styles. See the <a href=\"/system/getting-started/the-sx-prop/\">`sx` page</a> for more details.",
"title": "Tooltip title. Zero-length titles string, undefined, null and false are never displayed.",
"TransitionComponent": "The component used for the transition. <a href=\"/material-ui/transitions/#transitioncomponent-prop\">Follow this guide</a> to learn more about the requirements for this component.",
Expand Down
4 changes: 2 additions & 2 deletions packages/api-docs-builder/ApiBuilders/ComponentApiBuilder.ts
Original file line number Diff line number Diff line change
Expand Up @@ -421,11 +421,11 @@ const attachTranslations = (reactApi: ReactApi) => {

if (propName === 'classes') {
description += ' See <a href="#css">CSS API</a> below for more details.';
} else if (propName === 'slots') {
description += ' See <a href="#slots">Slots API</a> below for more details.';
} else if (propName === 'sx') {
description +=
' See the <a href="/system/getting-started/the-sx-prop/">`sx` page</a> for more details.';
} else if (propName === 'slots' && !reactApi.apiPathname.startsWith('/material-ui')) {
description += ' See <a href="#slots">Slots API</a> below for more details.';
}
translations.propDescriptions[propName] = description.replace(/\n@default.*$/, '');
}
Expand Down

0 comments on commit cd609e7

Please sign in to comment.