diff --git a/.changeset/spotty-snakes-sing.md b/.changeset/spotty-snakes-sing.md new file mode 100644 index 0000000000..19ae86ed55 --- /dev/null +++ b/.changeset/spotty-snakes-sing.md @@ -0,0 +1,5 @@ +--- +'@leafygreen-ui/icon': minor +--- + +Add `Colon` and `TimeSeriesCollection` icons. diff --git a/packages/icon/README.md b/packages/icon/README.md index 1633407aa3..6be5327e8d 100644 --- a/packages/icon/README.md +++ b/packages/icon/README.md @@ -47,13 +47,13 @@ const SomeComponent = () => ; ## Properties -| Prop | Type | Description | Default | -| ------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------- | -| `glyph` (Required) | `'ActivityFeed'`, `'AddFile'`, `'AllProducts'`, `'Apps'`, `'Array'`, `'ArrowDown'`, `'ArrowLeft'`, `'ArrowRight'`, `'ArrowUp'`, `'Beaker'`, `'Bell'`, `'Biometric'`, `'Building'`, `'Bulb'`, `'Calendar'`, `'CaretDown'`, `'CaretLeft'`, `'CaretRight'`, `'CaretUp'`, `'ChartFilled'`, `'Charts'`, `'Checkmark'`, `'CheckmarkWithCircle'`, `'ChevronDown'`,, `'ChevronLeft'` `'ChevronRight'`,`'ChevronUp'`, `'Clock'`,`'ClockWithArrow'`, `'Clone'`, `'Cloud'`, `'Code'`, `'CodeBlock'`, `'Connect'`,`'Copy'`,`'CreditCard'`, `'CurlyBraces'`, `'Dashboard'`, `'Database'`, `'Diagram'`, `'Diagram2'`, `'Diagram3'`, `'Disconnect'`, `'Download'`, `'Drag'`, `'Edit'`, `'Ellipsis'`, `'Email'`, `'Export'`, `'Favorite'`, `'Federation'`, `'File'`, `'Filter'`,`'Folder'`, `'FullScreenEnter'`, `'FullScreenExit'`, `'Guage'`, `'GlobeAmericas'`, `'GovernmentBuilding'`, `'Highlight'`, `'Home'`, `'Import'`, `'ImportantWithCircle'`, `'InfoWithCircle'`, `'InviteUser'`, `'Key'`, `'Laptop'`, `'Link'`, `'List'`, `'Lock'`, `'LogIn'`, `'LogOut'`, `'MagnifyingGlass'`, `'Megaphone'`, `'Menu'`, `'Minus'`, `'Mobile'`, `'MultiDirectionArrow'`, `'MultiLayers'`, `'NavCollapse'`, `'NavExpand'`, `'NoFilter'`, `'NotAllowed'`, `'Note'`, `'OpenNewTab'`, `'Pause'`, `'Person'`, `'PersonGroup'`, `'PersonWithLock'`, `'Pin'`, `'Play'`, `'Plus'`, `'PlusWithCircle'`, `'QuestionMarkWithCircle'`, `'Read'`, `'Redo'`, `'Refresh'`,`'Relationship'`, `'ReplicaSet'`,`'Resize'`, `'Return'`, `'Save'`, `'Serverless'`, `'Settings'`, `'ShardedCluster'`, `'Shell'`, `'SMS'`,`'SortAscending'`, `'SortDescending'`, `'SortHorizontal'`, `'SortVertical'`,`'Sparkle'`, `'SplitHorizontal'`, `'SplitVertical'`, `'Stitch'`, `'Support'`, `'Sweep'`, `'Table'`, `'Tag'`, `'ThumbsDown'`, `'ThumbsUp'`, `'TimeSeries'`, `'Trash'`, `'Undo'`, `'University'`, `'Unlock'`, `'Unsorted'`, `'UpDownCarets'`, `'Upload'`, `'VerticalEllipsis'`, `'Visibility'`, `'VisibilityOff'`, `'Warning'`, `'Wizard'`, `'Wrench'`, `'Write'`,`'X'`, `'XWithCircle'` | Specifies the glyph to use. | | -| `size` | `'small'`, `'default'`, `'large'`, `'xlarge'`, `number` | The height and width of the glyph's viewBox. This can be any `number` or one of the following `'small'`, `'default'`, `'large'`, `'xlarge'` | `'default'` | -| `fill` | `string` | The fill color that is passed to the glyph. By default, the glyph will inherit its fill from the CSS color property of its nearest ancestor. | | -| `title` | `string`, `boolean`, `null` | Renders a title tag with the passed string within the SVG element for screen reader accessibility. Setting this value to `false` will entirely unset the title.
If title is `undefined` or `null`, a human-readable title will be generated based on the glyph's name. | | -| ... | `SVGR.ComponentProps` | All other props will be spread on the `svg` element | | +| Prop | Type | Description | Default | +| ------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------- | +| `glyph` (Required) | `'ActivityFeed'`, `'AddFile'`, `'AllProducts'`, `'Apps'`, `'Array'`, `'ArrowDown'`, `'ArrowLeft'`, `'ArrowRight'`, `'ArrowUp'`, `'Beaker'`, `'Bell'`, `'Biometric'`, `'Building'`, `'Bulb'`, `'Calendar'`, `'CaretDown'`, `'CaretLeft'`, `'CaretRight'`, `'CaretUp'`, `'ChartFilled'`, `'Charts'`, `'Checkmark'`, `'CheckmarkWithCircle'`, `'ChevronDown'`,, `'ChevronLeft'` `'ChevronRight'`,`'ChevronUp'`, `'Clock'`,`'ClockWithArrow'`, `'Clone'`, `'Cloud'`, `'Code'`, `'CodeBlock'`, `'Colon'`, `'Connect'`,`'Copy'`,`'CreditCard'`, `'CurlyBraces'`, `'Dashboard'`, `'Database'`, `'Diagram'`, `'Diagram2'`, `'Diagram3'`, `'Disconnect'`, `'Download'`, `'Drag'`, `'Edit'`, `'Ellipsis'`, `'Email'`, `'Export'`, `'Favorite'`, `'Federation'`, `'File'`, `'Filter'`,`'Folder'`, `'FullScreenEnter'`, `'FullScreenExit'`, `'Guage'`, `'GlobeAmericas'`, `'GovernmentBuilding'`, `'Highlight'`, `'Home'`, `'Import'`, `'ImportantWithCircle'`, `'InfoWithCircle'`, `'InviteUser'`, `'Key'`, `'Laptop'`, `'Link'`, `'List'`, `'Lock'`, `'LogIn'`, `'LogOut'`, `'MagnifyingGlass'`, `'Megaphone'`, `'Menu'`, `'Minus'`, `'Mobile'`, `'MultiDirectionArrow'`, `'MultiLayers'`, `'NavCollapse'`, `'NavExpand'`, `'NoFilter'`, `'NotAllowed'`, `'Note'`, `'OpenNewTab'`, `'Pause'`, `'Person'`, `'PersonGroup'`, `'PersonWithLock'`, `'Pin'`, `'Play'`, `'Plus'`, `'PlusWithCircle'`, `'QuestionMarkWithCircle'`, `'Read'`, `'Redo'`, `'Refresh'`,`'Relationship'`, `'ReplicaSet'`,`'Resize'`, `'Return'`, `'Save'`, `'Serverless'`, `'Settings'`, `'ShardedCluster'`, `'Shell'`, `'SMS'`,`'SortAscending'`, `'SortDescending'`, `'SortHorizontal'`, `'SortVertical'`,`'Sparkle'`, `'SplitHorizontal'`, `'SplitVertical'`, `'Stitch'`, `'Support'`, `'Sweep'`, `'Table'`, `'Tag'`, `'ThumbsDown'`, `'ThumbsUp'`, `'TimeSeries'`, `'TimeSeriesCollection'`, `'Trash'`, `'Undo'`, `'University'`, `'Unlock'`, `'Unsorted'`, `'UpDownCarets'`, `'Upload'`, `'VerticalEllipsis'`, `'Visibility'`, `'VisibilityOff'`, `'Warning'`, `'Wizard'`, `'Wrench'`, `'Write'`,`'X'`, `'XWithCircle'` | Specifies the glyph to use. | | +| `size` | `'small'`, `'default'`, `'large'`, `'xlarge'`, `number` | The height and width of the glyph's viewBox. This can be any `number` or one of the following `'small'`, `'default'`, `'large'`, `'xlarge'` | `'default'` | +| `fill` | `string` | The fill color that is passed to the glyph. By default, the glyph will inherit its fill from the CSS color property of its nearest ancestor. | | +| `title` | `string`, `boolean`, `null` | Renders a title tag with the passed string within the SVG element for screen reader accessibility. Setting this value to `false` will entirely unset the title.
If title is `undefined` or `null`, a human-readable title will be generated based on the glyph's name. | | +| ... | `SVGR.ComponentProps` | All other props will be spread on the `svg` element | | # createIconComponent diff --git a/packages/icon/src/generated/Colon.tsx b/packages/icon/src/generated/Colon.tsx new file mode 100644 index 0000000000..849791925d --- /dev/null +++ b/packages/icon/src/generated/Colon.tsx @@ -0,0 +1,45 @@ +/** +* This is a generated file. Do not modify it manually. +* +* @script ./node_modules/.bin/ts-node packages/icon/scripts/build.ts +* @checksum 7f32401256260ec3b5cbee7348a1663c +*/ +import * as React from "react"; +import PropTypes from 'prop-types'; +import { css, cx } from '@leafygreen-ui/emotion'; +import { generateAccessibleProps, sizeMap } from '../glyphCommon'; +import { LGGlyph } from '../types'; +export interface ColonProps extends LGGlyph.ComponentProps {} +const Colon = ({ + className, + size = 16, + title, + ['aria-label']: ariaLabel, + ['aria-labelledby']: ariaLabelledby, + fill, + role = 'img', + ...props +}: ColonProps) => { + const fillStyle = css` + color: ${fill}; + `; + const noFlexShrink = css` + flex-shrink: 0; + `; + const accessibleProps = generateAccessibleProps(role, 'Colon', { + title, + ['aria-label']: ariaLabel, + ['aria-labelledby']: ariaLabelledby + }); + return ; +}; +Colon.displayName = 'Colon'; +Colon.isGlyph = true; +Colon.propTypes = { + fill: PropTypes.string, + size: PropTypes.oneOfType([PropTypes.number, PropTypes.string]), + className: PropTypes.string +}; +export default Colon; \ No newline at end of file diff --git a/packages/icon/src/generated/TimeSeriesCollection.tsx b/packages/icon/src/generated/TimeSeriesCollection.tsx new file mode 100644 index 0000000000..99e1b70251 --- /dev/null +++ b/packages/icon/src/generated/TimeSeriesCollection.tsx @@ -0,0 +1,45 @@ +/** +* This is a generated file. Do not modify it manually. +* +* @script ./node_modules/.bin/ts-node packages/icon/scripts/build.ts +* @checksum 49eef07057b19edf94e1e4502386a268 +*/ +import * as React from "react"; +import PropTypes from 'prop-types'; +import { css, cx } from '@leafygreen-ui/emotion'; +import { generateAccessibleProps, sizeMap } from '../glyphCommon'; +import { LGGlyph } from '../types'; +export interface TimeSeriesCollectionProps extends LGGlyph.ComponentProps {} +const TimeSeriesCollection = ({ + className, + size = 16, + title, + ['aria-label']: ariaLabel, + ['aria-labelledby']: ariaLabelledby, + fill, + role = 'img', + ...props +}: TimeSeriesCollectionProps) => { + const fillStyle = css` + color: ${fill}; + `; + const noFlexShrink = css` + flex-shrink: 0; + `; + const accessibleProps = generateAccessibleProps(role, 'TimeSeriesCollection', { + title, + ['aria-label']: ariaLabel, + ['aria-labelledby']: ariaLabelledby + }); + return ; +}; +TimeSeriesCollection.displayName = 'TimeSeriesCollection'; +TimeSeriesCollection.isGlyph = true; +TimeSeriesCollection.propTypes = { + fill: PropTypes.string, + size: PropTypes.oneOfType([PropTypes.number, PropTypes.string]), + className: PropTypes.string +}; +export default TimeSeriesCollection; \ No newline at end of file diff --git a/packages/icon/src/glyphs/Colon.svg b/packages/icon/src/glyphs/Colon.svg new file mode 100644 index 0000000000..483118473a --- /dev/null +++ b/packages/icon/src/glyphs/Colon.svg @@ -0,0 +1,4 @@ + + + + diff --git a/packages/icon/src/glyphs/TimeSeriesCollection.svg b/packages/icon/src/glyphs/TimeSeriesCollection.svg new file mode 100644 index 0000000000..33cd6b13d9 --- /dev/null +++ b/packages/icon/src/glyphs/TimeSeriesCollection.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/packages/icon/src/glyphs/index.ts b/packages/icon/src/glyphs/index.ts index c8dfc58549..0993bf1844 100644 --- a/packages/icon/src/glyphs/index.ts +++ b/packages/icon/src/glyphs/index.ts @@ -35,6 +35,7 @@ import Clone from './Clone.svg'; import Cloud from './Cloud.svg'; import Code from './Code.svg'; import CodeBlock from './CodeBlock.svg'; +import Colon from './Colon.svg'; import Connect from './Connect.svg'; import Copy from './Copy.svg'; import CreditCard from './CreditCard.svg'; @@ -123,6 +124,7 @@ import Tag from './Tag.svg'; import ThumbsDown from './ThumbsDown.svg'; import ThumbsUp from './ThumbsUp.svg'; import TimeSeries from './TimeSeries.svg'; +import TimeSeriesCollection from './TimeSeriesCollection.svg'; import Trash from './Trash.svg'; import Undo from './Undo.svg'; import University from './University.svg'; @@ -174,6 +176,7 @@ const _glyphs = { Cloud, Code, CodeBlock, + Colon, Connect, Copy, CreditCard, @@ -262,6 +265,7 @@ const _glyphs = { ThumbsDown, ThumbsUp, TimeSeries, + TimeSeriesCollection, Trash, Undo, University,