You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<Example{...pageData}{...props}{...{"code":"import React from 'react';\nimport { CatalogTile, CatalogTileBadge } from '@patternfly/react-catalog-view-extension';\nimport CogIcon from '@patternfly/react-icons/dist/esm/icons/cog-icon';\nimport pfLogo6 from './pfLogo6.svg';\nimport '../../../../dist/css/react-catalog-view-extension.css';\n\nconst BasicFeaturedTile = () => (\n <CatalogTile\n id=\"simple-tile\"\n featured\n iconImg={pfLogo6}\n iconAlt=\"PatternFly logo\"\n badges={[\n <CatalogTileBadge title=\"Certified\">\n <CogIcon />\n </CatalogTileBadge>\n ]}\n title=\"Patternfly-React\"\n vendor=\"provided by Red Hat\"\n description={\n 'This is a very, very long description that should be truncated after three lines. ' +\n 'Three lines is the default for cards without a footer. Cards with a footer are truncated after one line. Truncation function use is deprecated; please pass in a maxDescriptionLength of -1 to override it. ' +\n 'This has changed from PatternFly 3.'\n }\n />\n)","title":"Basic featured tile","lang":"js"}}>
139
+
<Example{...pageData}{...props}{...{"code":"import React from 'react';\nimport { CatalogTile, CatalogTileBadge } from '@patternfly/react-catalog-view-extension';\nimport CogIcon from '@patternfly/react-icons/dist/esm/icons/cog-icon';\nimport pfLogo6 from './pfLogo6.svg';\nimport '../../../../dist/css/react-catalog-view-extension.css';\n\nconst BasicFeaturedTile = () => (\n <CatalogTile\n id=\"simple-tile\"\n featured\n iconImg={pfLogo6}\n iconAlt=\"PatternFly logo\"\n badges={[\n <CatalogTileBadge title=\"Certified\">\n <CogIcon />\n </CatalogTileBadge>\n ]}\n title=\"Patternfly-React\"\n vendor=\"provided by Red Hat\"\n description={\n 'This is a very, very long description that should be truncated after three lines. ' +\n 'Three lines is the default for cards without a footer. Cards with a footer are truncated after one line. Truncation function use is deprecated; please pass in a maxDescriptionLength of -1 to override it. ' +\n 'This has changed from PatternFly 3.'\n }\n />\n)","title":"Basic featured tile","lang":"js","className":""}}>
140
140
141
141
</Example>,
142
142
'Basic with footer': props=>
143
-
<Example{...pageData}{...props}{...{"code":"import React from 'react';\nimport { CatalogTile, CatalogTileBadge } from '@patternfly/react-catalog-view-extension';\nimport CogIcon from '@patternfly/react-icons/dist/esm/icons/cog-icon';\nimport OutlinedCheckCircleIcon from '@patternfly/react-icons/dist/esm/icons/outlined-check-circle-icon';\nimport pfLogo6 from './pfLogo6.svg';\n\nconst BasicWithFooter = () => (\n <CatalogTile\n id=\"simple-footer\"\n iconImg={pfLogo6}\n iconAlt=\"PatternFly logo\"\n badges={[\n <CatalogTileBadge title=\"Certified\">\n <CogIcon />\n </CatalogTileBadge>\n ]}\n title=\"Patternfly-React\"\n vendor=\"provided by Red Hat\"\n description={\n 'This is a very, very long description that should be truncated after one line. ' +\n 'Three lines is the default for cards without a footer. Cards with a footer are truncated after one line. Truncation function use is deprecated; please pass in a maxDescriptionLength of -1 to override it. ' +\n 'This has changed from PatternFly 3.'\n }\n footer={\n <span>\n <OutlinedCheckCircleIcon style={{color: 'var(--pf-v6-global--success-color--100)'}} /> Enabled\n </span>\n }\n />\n)","title":"Basic with footer","lang":"js"}}>
143
+
<Example{...pageData}{...props}{...{"code":"import React from 'react';\nimport { CatalogTile, CatalogTileBadge } from '@patternfly/react-catalog-view-extension';\nimport CogIcon from '@patternfly/react-icons/dist/esm/icons/cog-icon';\nimport OutlinedCheckCircleIcon from '@patternfly/react-icons/dist/esm/icons/outlined-check-circle-icon';\nimport pfLogo6 from './pfLogo6.svg';\n\nconst BasicWithFooter = () => (\n <CatalogTile\n id=\"simple-footer\"\n iconImg={pfLogo6}\n iconAlt=\"PatternFly logo\"\n badges={[\n <CatalogTileBadge title=\"Certified\">\n <CogIcon />\n </CatalogTileBadge>\n ]}\n title=\"Patternfly-React\"\n vendor=\"provided by Red Hat\"\n description={\n 'This is a very, very long description that should be truncated after one line. ' +\n 'Three lines is the default for cards without a footer. Cards with a footer are truncated after one line. Truncation function use is deprecated; please pass in a maxDescriptionLength of -1 to override it. ' +\n 'This has changed from PatternFly 3.'\n }\n footer={\n <span>\n <OutlinedCheckCircleIcon style={{color: 'var(--pf-v6-global--success-color--100)'}} /> Enabled\n </span>\n }\n />\n)","title":"Basic with footer","lang":"js","className":""}}>
144
144
145
145
</Example>,
146
146
'Link variant': props=>
147
-
<Example{...pageData}{...props}{...{"code":"import React from 'react';\nimport { CatalogTile, CatalogTileBadge } from '@patternfly/react-catalog-view-extension';\nimport CogIcon from '@patternfly/react-icons/dist/esm/icons/cog-icon';\nimport pfLogo6 from './pfLogo6.svg';\n\nconst LinkVariant = () => (\n <CatalogTile\n id=\"simple-link-variant\"\n iconImg={pfLogo6}\n iconAlt=\"PatternFly logo\"\n badges={[\n <CatalogTileBadge title=\"Certified\">\n <CogIcon />\n </CatalogTileBadge>\n ]}\n href=\"http://patternfly.org/v4\"\n title=\"Patternfly-React\"\n vendor=\"provided by Red Hat\"\n description={\n 'This is a very, very long description that should be truncated after three lines. ' +\n 'Three lines is the default for cards without a footer. Cards with a footer are truncated after one line. Truncation function use is deprecated; please pass in a maxDescriptionLength of -1 to override it. ' +\n 'This has changed from PatternFly 3.'\n }\n />\n)","title":"Link variant","lang":"js"}}>
147
+
<Example{...pageData}{...props}{...{"code":"import React from 'react';\nimport { CatalogTile, CatalogTileBadge } from '@patternfly/react-catalog-view-extension';\nimport CogIcon from '@patternfly/react-icons/dist/esm/icons/cog-icon';\nimport pfLogo6 from './pfLogo6.svg';\n\nconst LinkVariant = () => (\n <CatalogTile\n id=\"simple-link-variant\"\n iconImg={pfLogo6}\n iconAlt=\"PatternFly logo\"\n badges={[\n <CatalogTileBadge title=\"Certified\">\n <CogIcon />\n </CatalogTileBadge>\n ]}\n href=\"http://patternfly.org/v4\"\n title=\"Patternfly-React\"\n vendor=\"provided by Red Hat\"\n description={\n 'This is a very, very long description that should be truncated after three lines. ' +\n 'Three lines is the default for cards without a footer. Cards with a footer are truncated after one line. Truncation function use is deprecated; please pass in a maxDescriptionLength of -1 to override it. ' +\n 'This has changed from PatternFly 3.'\n }\n />\n)","title":"Link variant","lang":"js","className":""}}>
148
148
149
149
</Example>,
150
150
'With multiple icon badges': props=>
151
-
<Example{...pageData}{...props}{...{"code":"import React from 'react';\nimport { CatalogTile, CatalogTileBadge } from '@patternfly/react-catalog-view-extension';\nimport CogIcon from '@patternfly/react-icons/dist/esm/icons/cog-icon';\nimport OutlinedCheckCircleIcon from '@patternfly/react-icons/dist/esm/icons/outlined-check-circle-icon';\nimport pfLogo6 from './pfLogo6.svg';\n\nconst WithMultipleIconBadges = () => (\n <CatalogTile\n id=\"multiIcon\"\n iconImg={pfLogo6}\n iconAlt=\"PatternFly logo\"\n badges={[\n <CatalogTileBadge title=\"Certified\">\n <CogIcon />\n </CatalogTileBadge>,\n <CatalogTileBadge title=\"USDA Approved\">\n <OutlinedCheckCircleIcon style={{color: 'var(--pf-v6-global--success-color--100)'}} />\n </CatalogTileBadge>\n ]}\n title=\"Patternfly-React\"\n vendor=\"provided by Red Hat\"\n description={\n 'This is a very, very long description that should be truncated after three lines. ' +\n 'Three lines is the default for cards without a footer. Cards with a footer are truncated after one line. Truncation function use is deprecated; please pass in a maxDescriptionLength of -1 to override it. ' +\n 'This has changed from PatternFly 3.'\n }\n />\n)","title":"With multiple icon badges","lang":"js"}}>
151
+
<Example{...pageData}{...props}{...{"code":"import React from 'react';\nimport { CatalogTile, CatalogTileBadge } from '@patternfly/react-catalog-view-extension';\nimport CogIcon from '@patternfly/react-icons/dist/esm/icons/cog-icon';\nimport OutlinedCheckCircleIcon from '@patternfly/react-icons/dist/esm/icons/outlined-check-circle-icon';\nimport pfLogo6 from './pfLogo6.svg';\n\nconst WithMultipleIconBadges = () => (\n <CatalogTile\n id=\"multiIcon\"\n iconImg={pfLogo6}\n iconAlt=\"PatternFly logo\"\n badges={[\n <CatalogTileBadge title=\"Certified\">\n <CogIcon />\n </CatalogTileBadge>,\n <CatalogTileBadge title=\"USDA Approved\">\n <OutlinedCheckCircleIcon style={{color: 'var(--pf-v6-global--success-color--100)'}} />\n </CatalogTileBadge>\n ]}\n title=\"Patternfly-React\"\n vendor=\"provided by Red Hat\"\n description={\n 'This is a very, very long description that should be truncated after three lines. ' +\n 'Three lines is the default for cards without a footer. Cards with a footer are truncated after one line. Truncation function use is deprecated; please pass in a maxDescriptionLength of -1 to override it. ' +\n 'This has changed from PatternFly 3.'\n }\n />\n)","title":"With multiple icon badges","lang":"js","className":""}}>
152
152
153
153
</Example>,
154
154
'With text badge': props=>
155
-
<Example{...pageData}{...props}{...{"code":"import React from 'react';\nimport { CatalogTile } from '@patternfly/react-catalog-view-extension';\nimport pfLogo6 from './pfLogo6.svg';\n\nconst WithTextBadge = () => (\n <CatalogTile\n id=\"text-badge\"\n iconImg={pfLogo6}\n iconAlt=\"PatternFly logo\"\n badges={[\n 'Community'\n ]}\n title=\"Patternfly-React\"\n vendor=\"provided by Red Hat\"\n description={\n 'This is a very, very long description that should be truncated after three lines. ' +\n 'Three lines is the default for cards without a footer. Cards with a footer are truncated after one line. Truncation function use is deprecated; please pass in a maxDescriptionLength of -1 to override it. ' +\n 'This has changed from PatternFly 3.'\n }\n />\n)","title":"With text badge","lang":"js"}}>
155
+
<Example{...pageData}{...props}{...{"code":"import React from 'react';\nimport { CatalogTile } from '@patternfly/react-catalog-view-extension';\nimport pfLogo6 from './pfLogo6.svg';\n\nconst WithTextBadge = () => (\n <CatalogTile\n id=\"text-badge\"\n iconImg={pfLogo6}\n iconAlt=\"PatternFly logo\"\n badges={[\n 'Community'\n ]}\n title=\"Patternfly-React\"\n vendor=\"provided by Red Hat\"\n description={\n 'This is a very, very long description that should be truncated after three lines. ' +\n 'Three lines is the default for cards without a footer. Cards with a footer are truncated after one line. Truncation function use is deprecated; please pass in a maxDescriptionLength of -1 to override it. ' +\n 'This has changed from PatternFly 3.'\n }\n />\n)","title":"With text badge","lang":"js","className":""}}>
156
156
157
157
</Example>,
158
158
'With children instead of description': props=>
159
-
<Example{...pageData}{...props}{...{"code":"import React from 'react';\nimport { CatalogTile, CatalogTileBadge } from '@patternfly/react-catalog-view-extension';\nimport CogIcon from '@patternfly/react-icons/dist/esm/icons/cog-icon';\nimport pfLogo6 from './pfLogo6.svg';\n\nconst WithChildrenInsteadOfDescription = () => (\n <CatalogTile\n id=\"simple-with-children\"\n featured\n iconImg={pfLogo6}\n iconAlt=\"PatternFly logo\"\n badges={[\n <CatalogTileBadge title=\"Certified\">\n <CogIcon />\n </CatalogTileBadge>\n ]}\n title=\"Patternfly-React\"\n vendor=\"provided by Red Hat\"\n >\n This is a very, very long stetch of child text that should be not be truncated\n and illustrates how Flyers can add longer content to PatternFly 4 catalog tiles\n using the children prop. Cards usually truncate descriptions at three lines.\n Cards with a footer are truncated after one line. This has changed from PatternFly 3.\n Children can be of any length.\n </CatalogTile>\n)","title":"With children instead of description","lang":"js"}}>
159
+
<Example{...pageData}{...props}{...{"code":"import React from 'react';\nimport { CatalogTile, CatalogTileBadge } from '@patternfly/react-catalog-view-extension';\nimport CogIcon from '@patternfly/react-icons/dist/esm/icons/cog-icon';\nimport pfLogo6 from './pfLogo6.svg';\n\nconst WithChildrenInsteadOfDescription = () => (\n <CatalogTile\n id=\"simple-with-children\"\n featured\n iconImg={pfLogo6}\n iconAlt=\"PatternFly logo\"\n badges={[\n <CatalogTileBadge title=\"Certified\">\n <CogIcon />\n </CatalogTileBadge>\n ]}\n title=\"Patternfly-React\"\n vendor=\"provided by Red Hat\"\n >\n This is a very, very long stetch of child text that should be not be truncated\n and illustrates how Flyers can add longer content to PatternFly 4 catalog tiles\n using the children prop. Cards usually truncate descriptions at three lines.\n Cards with a footer are truncated after one line. This has changed from PatternFly 3.\n Children can be of any length.\n </CatalogTile>\n)","title":"With children instead of description","lang":"js","className":""}}>
0 commit comments