@sproutsocial/racine 14.3.0 → 15.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +40 -0
- package/__flow__/Card/Card.flow.js +1 -17
- package/__flow__/Card/CardTypes.flow.js +66 -0
- package/__flow__/Card/index.flow.js +2 -1
- package/__flow__/EnumIconNames.flow.js +1 -1
- package/__flow__/IconViewBoxes.js +2 -0
- package/__flow__/index.flow.js +1 -1
- package/__flow__/systemProps/{background.js → background.flow.js} +1 -1
- package/__flow__/systemProps/{border.js → border.flow.js} +1 -1
- package/__flow__/systemProps/{color.js → color.flow.js} +2 -2
- package/__flow__/systemProps/{custom.js → custom.flow.js} +1 -1
- package/__flow__/systemProps/{flexbox.js → flexbox.flow.js} +1 -1
- package/__flow__/systemProps/{grid.js → grid.flow.js} +1 -1
- package/__flow__/systemProps/index.flow.js +16 -0
- package/__flow__/systemProps/{layout.js → layout.flow.js} +1 -1
- package/__flow__/systemProps/{position.js → position.flow.js} +1 -1
- package/__flow__/systemProps/{shadow.js → shadow.flow.js} +1 -1
- package/__flow__/systemProps/{space.js → space.flow.js} +1 -1
- package/__flow__/systemProps/{systemProps.js → systemProps.flow.js} +13 -13
- package/__flow__/systemProps/{typography.js → typography.flow.js} +1 -1
- package/__flow__/systemProps/{variant.js → variant.flow.js} +1 -1
- package/__flow__/types/shared.flow.js +5 -1
- package/commonjs/Card/Card.js +71 -26
- package/commonjs/Card/CardTypes.flow.js +6 -0
- package/commonjs/Card/index.flow.js +11 -0
- package/commonjs/Card/index.js +23 -1
- package/commonjs/Card/styles.js +102 -22
- package/commonjs/Card/subComponents.js +48 -0
- package/commonjs/Card/utils.js +56 -0
- package/commonjs/Icon/Icon.js +1 -0
- package/commonjs/IconViewBoxes.js +2 -0
- package/commonjs/Loader/styles.js +17 -12
- package/commonjs/index.flow.js +125 -125
- package/commonjs/systemProps/index.flow.js +159 -0
- package/commonjs/systemProps/{systemProps.js → systemProps.flow.js} +12 -12
- package/commonjs/types/shared.flow.js +6 -1
- package/commonjs/utils/index.js +15 -0
- package/dist/icon.svg +1 -1
- package/dist/iconList.js +1 -1
- package/dist/types/Avatar/Avatar.d.ts +2 -2
- package/dist/types/Avatar/Avatar.d.ts.map +1 -1
- package/dist/types/Badge/Badge.d.ts +2 -1
- package/dist/types/Badge/Badge.d.ts.map +1 -1
- package/dist/types/Banner/Banner.d.ts +2 -1
- package/dist/types/Banner/Banner.d.ts.map +1 -1
- package/dist/types/Banner/styles.d.ts +3 -2
- package/dist/types/Banner/styles.d.ts.map +1 -1
- package/dist/types/Box/Box.d.ts +1 -1
- package/dist/types/Box/Box.d.ts.map +1 -1
- package/dist/types/Breadcrumb/Breadcrumb.d.ts +3 -2
- package/dist/types/Breadcrumb/Breadcrumb.d.ts.map +1 -1
- package/dist/types/Button/Button.d.ts +2 -1
- package/dist/types/Button/Button.d.ts.map +1 -1
- package/dist/types/Card/Card.d.ts +16 -2
- package/dist/types/Card/Card.d.ts.map +1 -1
- package/dist/types/Card/CardTypes.d.ts +48 -11
- package/dist/types/Card/CardTypes.d.ts.map +1 -1
- package/dist/types/Card/__tests__/CardTypes.d.ts +2 -0
- package/dist/types/Card/__tests__/CardTypes.d.ts.map +1 -0
- package/dist/types/Card/index.d.ts +1 -0
- package/dist/types/Card/index.d.ts.map +1 -1
- package/dist/types/Card/styles.d.ts +13 -6
- package/dist/types/Card/styles.d.ts.map +1 -1
- package/dist/types/Card/subComponents.d.ts +17 -0
- package/dist/types/Card/subComponents.d.ts.map +1 -0
- package/dist/types/Card/utils.d.ts +16 -0
- package/dist/types/Card/utils.d.ts.map +1 -0
- package/dist/types/CharacterCounter/CharacterCounter.d.ts +1 -1
- package/dist/types/ChartLegend/ChartLegend.d.ts +2 -1
- package/dist/types/ChartLegend/ChartLegend.d.ts.map +1 -1
- package/dist/types/Checkbox/Checkbox.d.ts +1 -1
- package/dist/types/Checkbox/styles.d.ts +4 -4
- package/dist/types/Checkbox/styles.d.ts.map +1 -1
- package/dist/types/Collapsible/Collapsible.d.ts +4 -3
- package/dist/types/Collapsible/Collapsible.d.ts.map +1 -1
- package/dist/types/Collapsible/styles.d.ts +1 -1
- package/dist/types/DatePicker/DateRangePicker/DateRangePicker.d.ts +2 -1
- package/dist/types/DatePicker/DateRangePicker/DateRangePicker.d.ts.map +1 -1
- package/dist/types/DatePicker/DateRangePicker/StatefulDateRangePicker.d.ts +2 -1
- package/dist/types/DatePicker/DateRangePicker/StatefulDateRangePicker.d.ts.map +1 -1
- package/dist/types/DatePicker/SingleDatePicker/StatefulSingleDatePicker.d.ts +2 -1
- package/dist/types/DatePicker/SingleDatePicker/StatefulSingleDatePicker.d.ts.map +1 -1
- package/dist/types/DatePicker/common.d.ts +2 -1
- package/dist/types/DatePicker/common.d.ts.map +1 -1
- package/dist/types/DatePicker/styles.d.ts +1 -1
- package/dist/types/Drawer/Drawer.d.ts +2 -2
- package/dist/types/Drawer/SlideTransition.d.ts +1 -1
- package/dist/types/Drawer/SlideTransition.d.ts.map +1 -1
- package/dist/types/Drawer/styles.d.ts +1 -1
- package/dist/types/Drawer/styles.d.ts.map +1 -1
- package/dist/types/EmptyState/EmptyState.d.ts +2 -1
- package/dist/types/EmptyState/EmptyState.d.ts.map +1 -1
- package/dist/types/EnumIconNames.d.ts +1 -1
- package/dist/types/EnumIconNames.d.ts.map +1 -1
- package/dist/types/Fieldset/Fieldset.d.ts +4 -3
- package/dist/types/Fieldset/Fieldset.d.ts.map +1 -1
- package/dist/types/Fieldset/styles.d.ts +1 -1
- package/dist/types/Fieldset/styles.d.ts.map +1 -1
- package/dist/types/FormField/FormField.d.ts +2 -1
- package/dist/types/FormField/FormField.d.ts.map +1 -1
- package/dist/types/Icon/Icon.d.ts +4 -2
- package/dist/types/Icon/Icon.d.ts.map +1 -1
- package/dist/types/Image/Image.d.ts +1 -1
- package/dist/types/Indicator/Indicator.d.ts +1 -1
- package/dist/types/Input/Input.d.ts +2 -2
- package/dist/types/KeyboardKey/KeyboardKey.d.ts +1 -1
- package/dist/types/Label/Label.d.ts +1 -1
- package/dist/types/Link/Link.d.ts +2 -1
- package/dist/types/Link/Link.d.ts.map +1 -1
- package/dist/types/Link/styles.d.ts +2 -1
- package/dist/types/Link/styles.d.ts.map +1 -1
- package/dist/types/Listbox/Listbox.d.ts +11 -10
- package/dist/types/Listbox/Listbox.d.ts.map +1 -1
- package/dist/types/Listbox/ListboxTypes.d.ts +1 -1
- package/dist/types/Listbox/ListboxTypes.d.ts.map +1 -1
- package/dist/types/Loader/Loader.d.ts +1 -1
- package/dist/types/Loader/styles.d.ts.map +1 -1
- package/dist/types/LoaderButton/LoaderButton.d.ts +2 -1
- package/dist/types/LoaderButton/LoaderButton.d.ts.map +1 -1
- package/dist/types/Menu/Menu.d.ts +14 -13
- package/dist/types/Menu/Menu.d.ts.map +1 -1
- package/dist/types/Menu/MenuTypes.d.ts +1 -1
- package/dist/types/Menu/MenuTypes.d.ts.map +1 -1
- package/dist/types/Menu/styles.d.ts +2 -2
- package/dist/types/Menu/styles.d.ts.map +1 -1
- package/dist/types/Menu/utils/descendants.d.ts +1 -1
- package/dist/types/Menu/utils/descendants.d.ts.map +1 -1
- package/dist/types/Message/Message.d.ts +8 -8
- package/dist/types/Message/styles.d.ts +5 -5
- package/dist/types/Message/styles.d.ts.map +1 -1
- package/dist/types/Modal/Modal.d.ts +5 -5
- package/dist/types/Modal/styles.d.ts +5 -5
- package/dist/types/Modal/styles.d.ts.map +1 -1
- package/dist/types/Numeral/Numeral.d.ts +2 -1
- package/dist/types/Numeral/Numeral.d.ts.map +1 -1
- package/dist/types/Numeral/styles.d.ts +3 -2
- package/dist/types/Numeral/styles.d.ts.map +1 -1
- package/dist/types/OverflowList/OverflowList.d.ts +2 -1
- package/dist/types/OverflowList/OverflowList.d.ts.map +1 -1
- package/dist/types/OverflowList/styles.d.ts +2 -1
- package/dist/types/OverflowList/styles.d.ts.map +1 -1
- package/dist/types/PartnerLogo/PartnerLogo.d.ts +2 -1
- package/dist/types/PartnerLogo/PartnerLogo.d.ts.map +1 -1
- package/dist/types/Popout/Popout.d.ts +3 -2
- package/dist/types/Popout/Popout.d.ts.map +1 -1
- package/dist/types/Popout/PopoutTypes.d.ts +1 -1
- package/dist/types/Popout/PopoutTypes.d.ts.map +1 -1
- package/dist/types/Radio/Radio.d.ts +1 -1
- package/dist/types/Radio/styles.d.ts +2 -1
- package/dist/types/Radio/styles.d.ts.map +1 -1
- package/dist/types/SegmentedControl/SegmentedControl.d.ts +3 -2
- package/dist/types/SegmentedControl/SegmentedControl.d.ts.map +1 -1
- package/dist/types/SegmentedControl/styles.d.ts +3 -3
- package/dist/types/SegmentedControl/styles.d.ts.map +1 -1
- package/dist/types/Select/Select.d.ts +1 -1
- package/dist/types/Skeleton/Skeleton.d.ts +1 -1
- package/dist/types/Skeleton/Skeleton.d.ts.map +1 -1
- package/dist/types/SpotIllustration/SpotIllustration.d.ts +2 -1
- package/dist/types/SpotIllustration/SpotIllustration.d.ts.map +1 -1
- package/dist/types/Stack/Stack.d.ts +2 -1
- package/dist/types/Stack/Stack.d.ts.map +1 -1
- package/dist/types/Switch/Switch.d.ts +1 -1
- package/dist/types/Table/Table.d.ts +8 -7
- package/dist/types/Table/Table.d.ts.map +1 -1
- package/dist/types/TableCell/TableCell.d.ts +1 -1
- package/dist/types/TableCell/TableCellTypes.d.ts +1 -1
- package/dist/types/TableCell/TableCellTypes.d.ts.map +1 -1
- package/dist/types/TableHeaderCell/TableHeaderCell.d.ts +2 -2
- package/dist/types/TableHeaderCell/TableHeaderCell.d.ts.map +1 -1
- package/dist/types/TableRowAccordion/TableRowAccordion.d.ts +1 -1
- package/dist/types/Tabs/Tabs.d.ts +2 -2
- package/dist/types/Tabs/styles.d.ts +2 -1
- package/dist/types/Tabs/styles.d.ts.map +1 -1
- package/dist/types/Text/Text.d.ts +2 -1
- package/dist/types/Text/Text.d.ts.map +1 -1
- package/dist/types/Textarea/Textarea.d.ts +1 -1
- package/dist/types/ThemeProvider/index.d.ts +1 -1
- package/dist/types/ThemeProvider/index.d.ts.map +1 -1
- package/dist/types/Toast/Toast.d.ts +2 -1
- package/dist/types/Toast/Toast.d.ts.map +1 -1
- package/dist/types/Toast/styles.d.ts +3 -3
- package/dist/types/Toast/styles.d.ts.map +1 -1
- package/dist/types/ToggleHint/ToggleHint.d.ts +2 -2
- package/dist/types/ToggleHint/ToggleHint.d.ts.map +1 -1
- package/dist/types/Token/Token.d.ts +2 -1
- package/dist/types/Token/Token.d.ts.map +1 -1
- package/dist/types/TokenInput/TokenInput.d.ts +1 -1
- package/dist/types/Tooltip/Tooltip.d.ts +2 -1
- package/dist/types/Tooltip/Tooltip.d.ts.map +1 -1
- package/dist/types/Tooltip/TooltipTypes.d.ts +1 -1
- package/dist/types/Tooltip/TooltipTypes.d.ts.map +1 -1
- package/dist/types/Tooltip/styles.d.ts +1 -1
- package/dist/types/Tooltip/styles.d.ts.map +1 -1
- package/dist/types/systemProps/index.d.ts +3 -79
- package/dist/types/systemProps/index.d.ts.map +1 -1
- package/dist/types/types/styled-components.d.ts +3 -3
- package/dist/types/types/styled-components.d.ts.map +1 -1
- package/dist/types/utils/index.d.ts +2 -0
- package/dist/types/utils/index.d.ts.map +1 -1
- package/dist/types/utils/innerText.d.ts.map +1 -1
- package/icons/hand-sparkle-outline.svg +6 -0
- package/icons/hand-sparkle.svg +3 -0
- package/lib/Card/Card.js +73 -28
- package/lib/Card/CardTypes.flow.js +1 -0
- package/lib/Card/index.flow.js +2 -1
- package/lib/Card/index.js +1 -0
- package/lib/Card/styles.js +96 -20
- package/lib/Card/subComponents.js +37 -0
- package/lib/Card/utils.js +46 -0
- package/lib/Icon/Icon.js +1 -0
- package/lib/IconViewBoxes.js +2 -0
- package/lib/Loader/styles.js +17 -12
- package/lib/index.flow.js +1 -1
- package/lib/systemProps/index.flow.js +14 -0
- package/lib/systemProps/index.js +1 -45
- package/lib/systemProps/systemProps.flow.js +14 -0
- package/lib/types/shared.flow.js +1 -0
- package/lib/utils/index.js +13 -0
- package/package.json +14 -11
- package/__flow__/systemProps/index.js +0 -16
- package/lib/systemProps/systemProps.js +0 -14
- /package/commonjs/systemProps/{background.js → background.flow.js} +0 -0
- /package/commonjs/systemProps/{border.js → border.flow.js} +0 -0
- /package/commonjs/systemProps/{color.js → color.flow.js} +0 -0
- /package/commonjs/systemProps/{custom.js → custom.flow.js} +0 -0
- /package/commonjs/systemProps/{flexbox.js → flexbox.flow.js} +0 -0
- /package/commonjs/systemProps/{grid.js → grid.flow.js} +0 -0
- /package/commonjs/systemProps/{layout.js → layout.flow.js} +0 -0
- /package/commonjs/systemProps/{position.js → position.flow.js} +0 -0
- /package/commonjs/systemProps/{shadow.js → shadow.flow.js} +0 -0
- /package/commonjs/systemProps/{space.js → space.flow.js} +0 -0
- /package/commonjs/systemProps/{typography.js → typography.flow.js} +0 -0
- /package/commonjs/systemProps/{variant.js → variant.flow.js} +0 -0
- /package/lib/systemProps/{background.js → background.flow.js} +0 -0
- /package/lib/systemProps/{border.js → border.flow.js} +0 -0
- /package/lib/systemProps/{color.js → color.flow.js} +0 -0
- /package/lib/systemProps/{custom.js → custom.flow.js} +0 -0
- /package/lib/systemProps/{flexbox.js → flexbox.flow.js} +0 -0
- /package/lib/systemProps/{grid.js → grid.flow.js} +0 -0
- /package/lib/systemProps/{layout.js → layout.flow.js} +0 -0
- /package/lib/systemProps/{position.js → position.flow.js} +0 -0
- /package/lib/systemProps/{shadow.js → shadow.flow.js} +0 -0
- /package/lib/systemProps/{space.js → space.flow.js} +0 -0
- /package/lib/systemProps/{typography.js → typography.flow.js} +0 -0
- /package/lib/systemProps/{variant.js → variant.flow.js} +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,45 @@
|
|
|
1
1
|
# Change Log
|
|
2
2
|
|
|
3
|
+
## 15.0.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 5fc0ef75: Exports `Card` subcomponents from the root for easier importing
|
|
8
|
+
|
|
9
|
+
## 15.0.0
|
|
10
|
+
|
|
11
|
+
### Major Changes
|
|
12
|
+
|
|
13
|
+
- 03601450: Introducing the new and improved Card component!
|
|
14
|
+
|
|
15
|
+
**Breaking changes**
|
|
16
|
+
|
|
17
|
+
- Replace `buttonProps` with relevant button props at surface level
|
|
18
|
+
- `tabindex`
|
|
19
|
+
- `disabled`
|
|
20
|
+
- `selected`
|
|
21
|
+
|
|
22
|
+
**Features**
|
|
23
|
+
|
|
24
|
+
- [x] Simplify markup
|
|
25
|
+
- [x] Fine tune styling
|
|
26
|
+
- [x] Add layout utility subcomponents to simplify common use cases
|
|
27
|
+
- [x] Improve component API and developer experience
|
|
28
|
+
- [x] Improve testing
|
|
29
|
+
- [x] TypeScript
|
|
30
|
+
- [x] Color contrast and keyboard accessible
|
|
31
|
+
- [x] Improve docs to better inform implementation
|
|
32
|
+
|
|
33
|
+
### Minor Changes
|
|
34
|
+
|
|
35
|
+
- 8e990d95: `Loader` component updated with accessible visual contrast
|
|
36
|
+
|
|
37
|
+
| Mode | Old | New |
|
|
38
|
+
| ---------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
39
|
+
| Dark |
|
|
40
|
+
|  |  |
|
|
41
|
+
| Light |  |  |
|
|
42
|
+
|
|
3
43
|
## 14.3.0
|
|
4
44
|
|
|
5
45
|
### Minor Changes
|
|
@@ -1,21 +1,5 @@
|
|
|
1
1
|
// @flow
|
|
2
2
|
import * as React from 'react';
|
|
3
|
-
import type {
|
|
4
|
-
import type { TypeBoxProps } from "../Box/index.flow";
|
|
5
|
-
type TypeChildrenlessButtonProps = {
|
|
6
|
-
...TypeButtonProps,
|
|
7
|
-
children?: void | null,
|
|
8
|
-
...
|
|
9
|
-
};
|
|
10
|
-
export type TypeCardProps = {
|
|
11
|
-
...TypeBoxProps,
|
|
12
|
-
onClick?: () => void,
|
|
13
|
-
href?: string,
|
|
14
|
-
children: React.Node,
|
|
15
|
-
/** Label describing the action that will be performed when the user interacts with the card */
|
|
16
|
-
ariaLabel: string,
|
|
17
|
-
buttonProps?: TypeChildrenlessButtonProps,
|
|
18
|
-
...
|
|
19
|
-
};
|
|
3
|
+
import type { TypeCardProps } from "./CardTypes.flow";
|
|
20
4
|
declare var Card: React.StatelessFunctionalComponent<TypeCardProps>;
|
|
21
5
|
declare export default typeof Card;
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
// @flow
|
|
2
|
+
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import type { TypeIconProps } from "../Icon/index.flow";
|
|
5
|
+
import type { TypeStyledComponentsCommonProps, TypePropsWithChildren } from "../types/index.flow";
|
|
6
|
+
import type { TypeBorderSystemProps, TypeColorSystemProps, TypeFlexboxSystemProps, TypeGridSystemProps, TypeLayoutSystemProps, TypePositionSystemProps, TypeSpaceSystemProps } from "../systemProps/index.flow";
|
|
7
|
+
export type TypeSharedCardSystemProps = TypePropsWithChildren<{|
|
|
8
|
+
...TypeStyledComponentsCommonProps,
|
|
9
|
+
...TypeBorderSystemProps,
|
|
10
|
+
...TypeColorSystemProps,
|
|
11
|
+
...TypeFlexboxSystemProps,
|
|
12
|
+
...TypeGridSystemProps,
|
|
13
|
+
...TypeLayoutSystemProps,
|
|
14
|
+
...TypePositionSystemProps,
|
|
15
|
+
...TypeSpaceSystemProps,
|
|
16
|
+
key?: React.Key,
|
|
17
|
+
|}>;
|
|
18
|
+
export type TypeCardStyleProps = {|
|
|
19
|
+
elevation?: 'low' | 'medium' | 'high',
|
|
20
|
+
disabled?: boolean,
|
|
21
|
+
compositionalComponents?: boolean,
|
|
22
|
+
selected?: boolean,
|
|
23
|
+
|};
|
|
24
|
+
export type TypeCardStyleTransientProps = {|
|
|
25
|
+
$elevation?: 'low' | 'medium' | 'high',
|
|
26
|
+
$disabled?: boolean,
|
|
27
|
+
$compositionalComponents?: boolean,
|
|
28
|
+
$selected?: boolean,
|
|
29
|
+
|};
|
|
30
|
+
export type TypeStyledCard = {
|
|
31
|
+
...TypeSharedCardSystemProps,
|
|
32
|
+
...TypeCardStyleTransientProps,
|
|
33
|
+
...
|
|
34
|
+
};
|
|
35
|
+
export type TypeCardStyles = {|
|
|
36
|
+
...TypeSharedCardSystemProps,
|
|
37
|
+
...$Diff<TypeCardStyleProps, {|
|
|
38
|
+
compositionalComponents: any
|
|
39
|
+
|}>,
|
|
40
|
+
|};
|
|
41
|
+
declare type TypeOnClick = (event: SyntheticMouseEvent<HTMLElement> | SyntheticMouseEvent<HTMLElement>) => void;
|
|
42
|
+
export type TypeCardConditions = {|
|
|
43
|
+
role: 'link' | 'button' | 'checkbox' | 'presentation',
|
|
44
|
+
href?: string,
|
|
45
|
+
onClick?: TypeOnClick,
|
|
46
|
+
selected?: boolean,
|
|
47
|
+
|};
|
|
48
|
+
export type TypeCardProps = {
|
|
49
|
+
...TypeCardConditions,
|
|
50
|
+
...TypeCardStyles,
|
|
51
|
+
$elevation?: void,
|
|
52
|
+
$disabled?: void,
|
|
53
|
+
$compositionalComponents?: void,
|
|
54
|
+
$selected?: void,
|
|
55
|
+
...
|
|
56
|
+
};
|
|
57
|
+
export type TypeCardArea = {
|
|
58
|
+
...TypeSharedCardSystemProps,
|
|
59
|
+
$divider?: 'top' | 'bottom',
|
|
60
|
+
...
|
|
61
|
+
};
|
|
62
|
+
export type TypeStyledSelectedIcon = {
|
|
63
|
+
...TypeIconProps,
|
|
64
|
+
$selected: $PropertyType<TypeCardStyleTransientProps, '$selected'>,
|
|
65
|
+
...
|
|
66
|
+
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
// @flow
|
|
2
|
-
export type EnumIconNames = "active-listener" | "add-item" | "add-keyword" | "add-team-member" | "add-variable" | "address-card-outline" | "address-card-solid" | "adobe-experience-manager" | "ads" | "advocacy-outline" | "advocacy" | "android" | "apple" | "approval-indicator-outline" | "approval-indicator" | "archive" | "arrow-down-line" | "arrow-down" | "arrow-left-line" | "arrow-left" | "arrow-right-line" | "arrow-right" | "arrow-up-line" | "arrow-up" | "arrows" | "asset-library-outline" | "asset-library" | "assign" | "atom" | "audio" | "back-to-top" | "bambu-icon-outline" | "bambu-icon" | "barcode" | "basketball" | "bell-outline" | "bigcommerce" | "bitly" | "bold" | "book" | "bookmark" | "bot" | "browser" | "business" | "calendar-outline" | "calendar" | "camera-outline" | "camera-story" | "camera" | "campaign" | "canva" | "carousel" | "cart-plus-outline" | "cart-plus" | "check" | "chevron-down-filled" | "chevron-down" | "chevron-left" | "chevron-right" | "chevron-up-down-filled" | "chevron-up-filled" | "chevron-up" | "circle-check-outline" | "circle-check" | "circle" | "circle+" | "circles" | "circlex" | "click-to-view" | "clicks" | "clipboard-outline" | "clipboard" | "clock" | "closed-captioning" | "cloud" | "code" | "columns" | "comment-ai-outline" | "comment-ai" | "comment-alt-outline" | "comment-alt" | "comment-lines-alt-outline" | "comment" | "compact-density" | "compact-indicator" | "comparison" | "competitor" | "compose" | "content-suggestions" | "credit-card" | "crop" | "crown" | "dashboard" | "deconstructed-negative-sentiment" | "deconstructed-neutral-sentiment" | "deconstructed-positive-sentiment" | "discovery" | "dislike-outline" | "dislike" | "dm-link-outline" | "dm-link" | "dotdotdot" | "download" | "drafts-outline" | "drafts" | "dropbox" | "duplicate-outline" | "duplicate" | "emoji-outline" | "emoji" | "empty-image" | "engagement-per-post" | "engagements" | "error" | "exchange-alt" | "expanded-indicator" | "export" | "extended-circles" | "external-link-alt" | "external-link" | "extreme-negative-sentiment" | "eye-outline" | "eye-slash-outline" | "eye-slash" | "eye" | "facebook-audience-network" | "facebook-branded-content-outline" | "facebook-branded-content" | "facebook-groups" | "facebook" | "fb-reactions-angry" | "fb-reactions-haha" | "fb-reactions-like" | "fb-reactions-love" | "fb-reactions-sad" | "fb-reactions-wow" | "feedly" | "feeds" | "female" | "file-chart-line" | "file-edit" | "file-times-solid" | "filter" | "flag-outline" | "flag" | "flat-negative-sentiment-outline" | "flat-negative-sentiment" | "flat-neutral-sentiment-outline" | "flat-neutral-sentiment" | "flat-positive-sentiment-outline" | "flat-positive-sentiment" | "folder-open" | "folder" | "follow-outline" | "follow" | "follower-increase" | "following" | "font" | "full-access" | "gear" | "gears" | "github" | "glassdoor" | "glasses" | "globe" | "google-analytics-color" | "google-business-messages" | "google-drive" | "google-my-business" | "grip" | "h1" | "h2" | "h3" | "h4" | "hamburger" | "hashtag" | "headset" | "heart-outline" | "heart" | "heartbeat" | "help-alt" | "help" | "hiking" | "history" | "home" | "hourglass" | "hubspot" | "image-caption" | "image" | "images" | "impressions-per-post" | "impressions" | "inactive-listener" | "inbox-action" | "inbox-views" | "inbox" | "indicator" | "industry" | "info" | "instagram" | "internal-activity-outline" | "internal-activity" | "italic" | "key" | "keyboard" | "laptop-phone" | "large-density" | "lift" | "like-outline" | "like" | "link" | "linkedin-audience-network" | "linkedin" | "list-ol" | "listening" | "lists" | "location-outline" | "location" | "lock" | "magic-wand" | "male" | "marketo" | "mention" | "message-preview-outline" | "message-preview" | "message" | "messages-outline" | "messages" | "messenger" | "metric-table" | "microsoft-dynamics" | "minus" | "mobile" | "monitor" | "moon" | "negative-sentiment" | "neutral-positive-sentiment" | "neutral-sentiment" | "new-trend" | "newspaper" | "no-access" | "notepad" | "notifications-publishing-outline" | "notifications-publishing" | "notifications" | "offline" | "online" | "paid-promotion-outline" | "paid-promotion" | "paid" | "paint" | "palette" | "paperclip" | "pause" | "pencil-outline" | "pencil" | "person" | "phone" | "pinterest-boards-outline" | "pinterest-boards" | "pinterest" | "play-circle" | "play" | "plug" | "plus" | "positive-sentiment" | "power-up-outline" | "power-up" | "profile-connect" | "profile-disconnect" | "publishing-outline" | "publishing" | "puzzle-piece" | "qr-code" | "queue" | "recommendation" | "reddit-alien" | "reddit" | "reels-outline" | "reels" | "referrals" | "refresh" | "rejected" | "reply-outline" | "reply" | "reporting-period" | "reporting" | "reports-home" | "reports" | "retweet" | "route" | "rss" | "sales" | "salesforce-cloud" | "salesforce" | "save-assets" | "saved-messages" | "saved-reply-outline" | "saved-reply" | "search" | "send-again-outline" | "send-again" | "sent-message-outline" | "sent-message" | "share" | "shopify" | "shopping-bag-outline" | "shopping-bag" | "show-navigation" | "slack" | "small-density" | "smiley" | "some-access" | "sparkles" | "spike-alert" | "star-half-alt-solid" | "star-of-life" | "star-outline" | "star" | "sticky-note-outline" | "sticky-note" | "stories" | "story" | "suggestions" | "sun" | "tag-outline" | "tag" | "targeting-outline" | "targeting" | "tasks-check" | "tasks-outline" | "tasks" | "team-conversation-outline" | "team-conversation" | "team-sprout-outline" | "team-sprout" | "team" | "text-asset" | "text" | "tiktok" | "times" | "tools" | "trash-can-outline" | "trash-can" | "trend-down" | "trend-neutral" | "trend-up" | "trends" | "triangle-black" | "triangle" | "tripadvisor-circle-outline" | "tripadvisor-circle" | "tripadvisor" | "trophy-outline" | "tumblr" | "twitter-audience-network" | "twitter" | "underline" | "unfollow-outline" | "unfollow" | "unlink" | "unlock" | "upload" | "user-circle" | "users" | "verified" | "video-camera-story" | "video-camera" | "vip" | "weight" | "whatsapp" | "window-maximize" | "window-minimize" | "window-regular" | "window-restore" | "woocommerce" | "x" | "yelp-full-star" | "yelp-half-star" | "yelp" | "youtube" | "zendesk";
|
|
2
|
+
export type EnumIconNames = "active-listener" | "add-item" | "add-keyword" | "add-team-member" | "add-variable" | "address-card-outline" | "address-card-solid" | "adobe-experience-manager" | "ads" | "advocacy-outline" | "advocacy" | "android" | "apple" | "approval-indicator-outline" | "approval-indicator" | "archive" | "arrow-down-line" | "arrow-down" | "arrow-left-line" | "arrow-left" | "arrow-right-line" | "arrow-right" | "arrow-up-line" | "arrow-up" | "arrows" | "asset-library-outline" | "asset-library" | "assign" | "atom" | "audio" | "back-to-top" | "bambu-icon-outline" | "bambu-icon" | "barcode" | "basketball" | "bell-outline" | "bigcommerce" | "bitly" | "bold" | "book" | "bookmark" | "bot" | "browser" | "business" | "calendar-outline" | "calendar" | "camera-outline" | "camera-story" | "camera" | "campaign" | "canva" | "carousel" | "cart-plus-outline" | "cart-plus" | "check" | "chevron-down-filled" | "chevron-down" | "chevron-left" | "chevron-right" | "chevron-up-down-filled" | "chevron-up-filled" | "chevron-up" | "circle-check-outline" | "circle-check" | "circle" | "circle+" | "circles" | "circlex" | "click-to-view" | "clicks" | "clipboard-outline" | "clipboard" | "clock" | "closed-captioning" | "cloud" | "code" | "columns" | "comment-ai-outline" | "comment-ai" | "comment-alt-outline" | "comment-alt" | "comment-lines-alt-outline" | "comment" | "compact-density" | "compact-indicator" | "comparison" | "competitor" | "compose" | "content-suggestions" | "credit-card" | "crop" | "crown" | "dashboard" | "deconstructed-negative-sentiment" | "deconstructed-neutral-sentiment" | "deconstructed-positive-sentiment" | "discovery" | "dislike-outline" | "dislike" | "dm-link-outline" | "dm-link" | "dotdotdot" | "download" | "drafts-outline" | "drafts" | "dropbox" | "duplicate-outline" | "duplicate" | "emoji-outline" | "emoji" | "empty-image" | "engagement-per-post" | "engagements" | "error" | "exchange-alt" | "expanded-indicator" | "export" | "extended-circles" | "external-link-alt" | "external-link" | "extreme-negative-sentiment" | "eye-outline" | "eye-slash-outline" | "eye-slash" | "eye" | "facebook-audience-network" | "facebook-branded-content-outline" | "facebook-branded-content" | "facebook-groups" | "facebook" | "fb-reactions-angry" | "fb-reactions-haha" | "fb-reactions-like" | "fb-reactions-love" | "fb-reactions-sad" | "fb-reactions-wow" | "feedly" | "feeds" | "female" | "file-chart-line" | "file-edit" | "file-times-solid" | "filter" | "flag-outline" | "flag" | "flat-negative-sentiment-outline" | "flat-negative-sentiment" | "flat-neutral-sentiment-outline" | "flat-neutral-sentiment" | "flat-positive-sentiment-outline" | "flat-positive-sentiment" | "folder-open" | "folder" | "follow-outline" | "follow" | "follower-increase" | "following" | "font" | "full-access" | "gear" | "gears" | "github" | "glassdoor" | "glasses" | "globe" | "google-analytics-color" | "google-business-messages" | "google-drive" | "google-my-business" | "grip" | "h1" | "h2" | "h3" | "h4" | "hamburger" | "hand-sparkle-outline" | "hand-sparkle" | "hashtag" | "headset" | "heart-outline" | "heart" | "heartbeat" | "help-alt" | "help" | "hiking" | "history" | "home" | "hourglass" | "hubspot" | "image-caption" | "image" | "images" | "impressions-per-post" | "impressions" | "inactive-listener" | "inbox-action" | "inbox-views" | "inbox" | "indicator" | "industry" | "info" | "instagram" | "internal-activity-outline" | "internal-activity" | "italic" | "key" | "keyboard" | "laptop-phone" | "large-density" | "lift" | "like-outline" | "like" | "link" | "linkedin-audience-network" | "linkedin" | "list-ol" | "listening" | "lists" | "location-outline" | "location" | "lock" | "magic-wand" | "male" | "marketo" | "mention" | "message-preview-outline" | "message-preview" | "message" | "messages-outline" | "messages" | "messenger" | "metric-table" | "microsoft-dynamics" | "minus" | "mobile" | "monitor" | "moon" | "negative-sentiment" | "neutral-positive-sentiment" | "neutral-sentiment" | "new-trend" | "newspaper" | "no-access" | "notepad" | "notifications-publishing-outline" | "notifications-publishing" | "notifications" | "offline" | "online" | "paid-promotion-outline" | "paid-promotion" | "paid" | "paint" | "palette" | "paperclip" | "pause" | "pencil-outline" | "pencil" | "person" | "phone" | "pinterest-boards-outline" | "pinterest-boards" | "pinterest" | "play-circle" | "play" | "plug" | "plus" | "positive-sentiment" | "power-up-outline" | "power-up" | "profile-connect" | "profile-disconnect" | "publishing-outline" | "publishing" | "puzzle-piece" | "qr-code" | "queue" | "recommendation" | "reddit-alien" | "reddit" | "reels-outline" | "reels" | "referrals" | "refresh" | "rejected" | "reply-outline" | "reply" | "reporting-period" | "reporting" | "reports-home" | "reports" | "retweet" | "route" | "rss" | "sales" | "salesforce-cloud" | "salesforce" | "save-assets" | "saved-messages" | "saved-reply-outline" | "saved-reply" | "search" | "send-again-outline" | "send-again" | "sent-message-outline" | "sent-message" | "share" | "shopify" | "shopping-bag-outline" | "shopping-bag" | "show-navigation" | "slack" | "small-density" | "smiley" | "some-access" | "sparkles" | "spike-alert" | "star-half-alt-solid" | "star-of-life" | "star-outline" | "star" | "sticky-note-outline" | "sticky-note" | "stories" | "story" | "suggestions" | "sun" | "tag-outline" | "tag" | "targeting-outline" | "targeting" | "tasks-check" | "tasks-outline" | "tasks" | "team-conversation-outline" | "team-conversation" | "team-sprout-outline" | "team-sprout" | "team" | "text-asset" | "text" | "tiktok" | "times" | "tools" | "trash-can-outline" | "trash-can" | "trend-down" | "trend-neutral" | "trend-up" | "trends" | "triangle-black" | "triangle" | "tripadvisor-circle-outline" | "tripadvisor-circle" | "tripadvisor" | "trophy-outline" | "tumblr" | "twitter-audience-network" | "twitter" | "underline" | "unfollow-outline" | "unfollow" | "unlink" | "unlock" | "upload" | "user-circle" | "users" | "verified" | "video-camera-story" | "video-camera" | "vip" | "weight" | "whatsapp" | "window-maximize" | "window-minimize" | "window-regular" | "window-restore" | "woocommerce" | "x" | "yelp-full-star" | "yelp-half-star" | "yelp" | "youtube" | "zendesk";
|
|
@@ -174,6 +174,8 @@ module.exports = {
|
|
|
174
174
|
"h3": "0 0 16 16",
|
|
175
175
|
"h4": "0 0 16 16",
|
|
176
176
|
"hamburger": "0 0 16 18",
|
|
177
|
+
"hand-sparkle-outline": "0 0 18 18",
|
|
178
|
+
"hand-sparkle": "0 0 18 18",
|
|
177
179
|
"hashtag": "0 0 16 16",
|
|
178
180
|
"headset": "0 0 16 16",
|
|
179
181
|
"heart-outline": "0 0 16 16",
|
package/__flow__/index.flow.js
CHANGED
|
@@ -6,7 +6,7 @@ export type { EnumIllustrationNames } from "./EnumIllustrationNames.flow";
|
|
|
6
6
|
export type { EnumLogoNames } from "./EnumLogoNames.flow";
|
|
7
7
|
|
|
8
8
|
/* Theme and related types */
|
|
9
|
-
export * from "./systemProps";
|
|
9
|
+
export * from "./systemProps/index.flow";
|
|
10
10
|
export { default as theme } from "./themes/light/theme.flow";
|
|
11
11
|
export { default as darkTheme } from "./themes/dark/theme.flow";
|
|
12
12
|
export { sproutLightTheme, sproutDarkTheme } from "./themes/extendedThemes/sproutTheme/index.flow";
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import { background } from 'styled-system';
|
|
4
4
|
import type { Property$BackgroundImage, Property$BackgroundPosition, Property$Background, Property$BackgroundRepeat, Property$BackgroundSize } from 'csstype';
|
|
5
|
-
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow
|
|
5
|
+
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow";
|
|
6
6
|
|
|
7
7
|
// https://styled-system.com/table#background
|
|
8
8
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import { border } from 'styled-system';
|
|
4
4
|
import type { Property$BorderBottomColor, Property$BorderBottomLeftRadius, Property$BorderBottom, Property$BorderBottomRightRadius, Property$BorderBottomStyle, Property$BorderBottomWidth, Property$BorderColor, Property$BorderLeftColor, Property$BorderLeft, Property$BorderLeftStyle, Property$BorderLeftWidth, Property$Border, Property$BorderRadius, Property$BorderRightColor, Property$BorderRight, Property$BorderRightStyle, Property$BorderRightWidth, Property$BorderStyle, Property$BorderTopColor, Property$BorderTopLeftRadius, Property$BorderTop, Property$BorderTopRightRadius, Property$BorderTopStyle, Property$BorderTopWidth, Property$BorderWidth } from 'csstype';
|
|
5
|
-
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow
|
|
5
|
+
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow";
|
|
6
6
|
|
|
7
7
|
// https://styled-system.com/table#border
|
|
8
8
|
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
import { color } from 'styled-system';
|
|
4
4
|
import type { Property$BackgroundColor, Property$Color, Property$Opacity } from 'csstype';
|
|
5
|
-
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow
|
|
5
|
+
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow";
|
|
6
6
|
|
|
7
7
|
// https://styled-system.com/table#color
|
|
8
8
|
|
|
9
|
-
type TypeBackgroundColorSystemProp = TypeResponsiveBaseSystemProp<Property$BackgroundColor>;
|
|
9
|
+
export type TypeBackgroundColorSystemProp = TypeResponsiveBaseSystemProp<Property$BackgroundColor>;
|
|
10
10
|
export type TypeColorSystemProps = $ReadOnly<{|
|
|
11
11
|
backgroundColor?: TypeBackgroundColorSystemProp,
|
|
12
12
|
bg?: TypeBackgroundColorSystemProp,
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import { compose, system } from 'styled-system';
|
|
4
4
|
import type { Property$Cursor, Property$WhiteSpace } from 'csstype';
|
|
5
|
-
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow
|
|
5
|
+
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow";
|
|
6
6
|
|
|
7
7
|
// https://styled-system.com/custom-props
|
|
8
8
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import { flexbox } from 'styled-system';
|
|
4
4
|
import type { Property$AlignItems, Property$AlignContent, Property$JustifyContent, Property$JustifyItems, Property$FlexWrap, Property$FlexDirection, Property$Flex, Property$FlexBasis, Property$JustifySelf, Property$AlignSelf, Property$Gap, Property$ColumnGap, Property$RowGap, Globals } from 'csstype';
|
|
5
|
-
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow
|
|
5
|
+
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow";
|
|
6
6
|
|
|
7
7
|
// https://styled-system.com/table#flexbox
|
|
8
8
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import { grid } from 'styled-system';
|
|
4
4
|
import type { Property$GridArea, Property$GridAutoColumns, Property$GridAutoFlow, Property$GridAutoRows, Property$GridColumn, Property$GridColumnGap, Property$GridGap, Property$GridRow, Property$GridRowGap, Property$GridTemplateAreas, Property$GridTemplateColumns, Property$GridTemplateRows } from 'csstype';
|
|
5
|
-
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow
|
|
5
|
+
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow";
|
|
6
6
|
|
|
7
7
|
// https://styled-system.com/table#grid-layout
|
|
8
8
|
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
// @flow strict-local
|
|
2
|
+
|
|
3
|
+
export * from "./types.flow";
|
|
4
|
+
export * from "./background.flow";
|
|
5
|
+
export * from "./border.flow";
|
|
6
|
+
export * from "./color.flow";
|
|
7
|
+
export * from "./custom.flow";
|
|
8
|
+
export * from "./flexbox.flow";
|
|
9
|
+
export * from "./grid.flow";
|
|
10
|
+
export * from "./layout.flow";
|
|
11
|
+
export * from "./position.flow";
|
|
12
|
+
export * from "./shadow.flow";
|
|
13
|
+
export * from "./space.flow";
|
|
14
|
+
export * from "./systemProps.flow";
|
|
15
|
+
export * from "./typography.flow";
|
|
16
|
+
export * from "./variant.flow";
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import { layout } from 'styled-system';
|
|
4
4
|
import type { Property$Display, Property$Height, Property$MaxHeight, Property$MaxWidth, Property$MinHeight, Property$MinWidth, Property$Overflow, Property$OverflowX, Property$OverflowY, Property$VerticalAlign, Property$Width } from 'csstype';
|
|
5
|
-
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow
|
|
5
|
+
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow";
|
|
6
6
|
|
|
7
7
|
// https://styled-system.com/table#layout
|
|
8
8
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import { position } from 'styled-system';
|
|
4
4
|
import type { Property$Bottom, Property$Left, Property$Position, Property$Right, Property$Top, Property$ZIndex } from 'csstype';
|
|
5
|
-
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow
|
|
5
|
+
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow";
|
|
6
6
|
|
|
7
7
|
// https://styled-system.com/table#position
|
|
8
8
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import { shadow } from 'styled-system';
|
|
4
4
|
import type { Property$BoxShadow, Property$TextShadow } from 'csstype';
|
|
5
|
-
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow
|
|
5
|
+
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow";
|
|
6
6
|
|
|
7
7
|
// https://styled-system.com/table#shadow
|
|
8
8
|
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
import { space } from 'styled-system';
|
|
5
5
|
import type { Property$Margin, Property$MarginBottom, Property$MarginLeft, Property$MarginRight, Property$MarginTop, Property$Padding, Property$PaddingBottom, Property$PaddingLeft, Property$PaddingRight, Property$PaddingTop } from 'csstype';
|
|
6
|
-
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow
|
|
6
|
+
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow";
|
|
7
7
|
|
|
8
8
|
// https://styled-system.com/table#space
|
|
9
9
|
// prettier-ignore
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
// @flow strict-local
|
|
2
2
|
import { compose } from 'styled-system';
|
|
3
|
-
import { backgroundSystemProps, type TypeBackgroundSystemProps } from "./background";
|
|
4
|
-
import { borderSystemProps, type TypeBorderSystemProps } from "./border";
|
|
5
|
-
import { colorSystemProps, type TypeColorSystemProps } from "./color";
|
|
6
|
-
import { customSystemProps, type TypeCustomSystemProps } from "./custom";
|
|
7
|
-
import { flexboxSystemProps, type TypeFlexboxSystemProps } from "./flexbox";
|
|
8
|
-
import { gridSystemProps, type TypeGridSystemProps } from "./grid";
|
|
9
|
-
import { layoutSystemProps, type TypeLayoutSystemProps } from "./layout";
|
|
10
|
-
import { positionSystemProps, type TypePositionSystemProps } from "./position";
|
|
11
|
-
import { shadowSystemProps, type TypeShadowSystemProps } from "./shadow";
|
|
12
|
-
import { spaceSystemProps, type TypeSpaceSystemProps } from "./space";
|
|
13
|
-
import { typographySystemProps, type TypeTypographySystemProps } from "./typography";
|
|
14
|
-
import { variantSystemProps, type TypeVariantSystemProps } from "./variant";
|
|
15
|
-
import type { StyledSystemStyleFn } from "./types.flow
|
|
3
|
+
import { backgroundSystemProps, type TypeBackgroundSystemProps } from "./background.flow";
|
|
4
|
+
import { borderSystemProps, type TypeBorderSystemProps } from "./border.flow";
|
|
5
|
+
import { colorSystemProps, type TypeColorSystemProps } from "./color.flow";
|
|
6
|
+
import { customSystemProps, type TypeCustomSystemProps } from "./custom.flow";
|
|
7
|
+
import { flexboxSystemProps, type TypeFlexboxSystemProps } from "./flexbox.flow";
|
|
8
|
+
import { gridSystemProps, type TypeGridSystemProps } from "./grid.flow";
|
|
9
|
+
import { layoutSystemProps, type TypeLayoutSystemProps } from "./layout.flow";
|
|
10
|
+
import { positionSystemProps, type TypePositionSystemProps } from "./position.flow";
|
|
11
|
+
import { shadowSystemProps, type TypeShadowSystemProps } from "./shadow.flow";
|
|
12
|
+
import { spaceSystemProps, type TypeSpaceSystemProps } from "./space.flow";
|
|
13
|
+
import { typographySystemProps, type TypeTypographySystemProps } from "./typography.flow";
|
|
14
|
+
import { variantSystemProps, type TypeVariantSystemProps } from "./variant.flow";
|
|
15
|
+
import type { StyledSystemStyleFn } from "./types.flow";
|
|
16
16
|
export type TypeSystemProps = $ReadOnly<{|
|
|
17
17
|
...TypeCustomSystemProps,
|
|
18
18
|
...TypeVariantSystemProps,
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import { typography } from 'styled-system';
|
|
4
4
|
import type { Property$FontFamily, Property$FontSize, Property$FontStyle, Property$FontWeight, Property$LetterSpacing, Property$LineHeight, Property$TextAlign } from 'csstype';
|
|
5
5
|
import typeof { fontWeights as TypeofFontWeights } from "../themes/light/theme.flow";
|
|
6
|
-
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow
|
|
6
|
+
import type { StyledSystemStyleFn, TypeResponsiveBaseSystemProp } from "./types.flow";
|
|
7
7
|
|
|
8
8
|
// https://styled-system.com/table#typography
|
|
9
9
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// @flow strict-local
|
|
2
2
|
import { compose, variant } from 'styled-system';
|
|
3
3
|
import type { TypeTypography } from "../types/theme.flow";
|
|
4
|
-
import type { TypeResponsiveBaseSystemProp } from "./types.flow
|
|
4
|
+
import type { TypeResponsiveBaseSystemProp } from "./types.flow";
|
|
5
5
|
|
|
6
6
|
// https://styled-system.com/variants
|
|
7
7
|
|
package/commonjs/Card/Card.js
CHANGED
|
@@ -1,45 +1,90 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
'no babel-plugin-flow-react-proptypes';
|
|
3
2
|
|
|
4
3
|
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
|
6
5
|
value: true
|
|
7
6
|
});
|
|
8
7
|
exports.default = void 0;
|
|
9
|
-
var
|
|
8
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
10
9
|
var _styles = require("./styles");
|
|
11
|
-
var
|
|
10
|
+
var _utils = require("./utils");
|
|
11
|
+
var _subComponents = require("./subComponents");
|
|
12
|
+
var _excluded = ["children", "disabled", "elevation", "href", "onClick", "role", "selected"];
|
|
12
13
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
13
14
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
14
15
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
16
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
17
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
18
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
19
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
|
20
|
+
function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0) { ; } } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
|
|
21
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
15
22
|
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
16
23
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
24
|
+
/**
|
|
25
|
+
* @link https://seeds.sproutsocial.com/components/card/
|
|
26
|
+
*
|
|
27
|
+
* Avoid nesting interactive content inside a Card with role='button'.
|
|
28
|
+
*
|
|
29
|
+
* Interactive content: "a", "audio", "button", "embed", "iframe", "img", "input", "label", "select", "textarea", "video"
|
|
30
|
+
* @see https://html.spec.whatwg.org/multipage/dom.html#interactive-content
|
|
31
|
+
*
|
|
32
|
+
* @example
|
|
33
|
+
* <Card role="button" onClick={_onClick}>
|
|
34
|
+
* <Button>Click me</Button>
|
|
35
|
+
* </Card>
|
|
36
|
+
*/
|
|
37
|
+
|
|
17
38
|
var Card = function Card(_ref) {
|
|
18
|
-
var
|
|
39
|
+
var children = _ref.children,
|
|
40
|
+
_ref$disabled = _ref.disabled,
|
|
41
|
+
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
42
|
+
elevation = _ref.elevation,
|
|
19
43
|
href = _ref.href,
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
_ref$
|
|
23
|
-
|
|
24
|
-
_ref$border = _ref.border,
|
|
25
|
-
border = _ref$border === void 0 ? 500 : _ref$border,
|
|
26
|
-
_ref$borderColor = _ref.borderColor,
|
|
27
|
-
borderColor = _ref$borderColor === void 0 ? 'container.border.base' : _ref$borderColor,
|
|
28
|
-
_ref$color = _ref.color,
|
|
29
|
-
color = _ref$color === void 0 ? 'text.body' : _ref$color,
|
|
30
|
-
_ref$bg = _ref.bg,
|
|
31
|
-
bg = _ref$bg === void 0 ? 'container.background.base' : _ref$bg,
|
|
44
|
+
onClick = _ref.onClick,
|
|
45
|
+
_ref$role = _ref.role,
|
|
46
|
+
role = _ref$role === void 0 ? 'presentation' : _ref$role,
|
|
47
|
+
selected = _ref.selected,
|
|
32
48
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
49
|
+
var _useState = (0, _react.useState)(false),
|
|
50
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
51
|
+
hasSubComponent = _useState2[0],
|
|
52
|
+
setHasSubComponent = _useState2[1];
|
|
53
|
+
var containerRef = (0, _react.useRef)(null);
|
|
54
|
+
var checkedConditions = role === 'checkbox' ? selected : undefined;
|
|
55
|
+
var handleClickConditions = function handleClickConditions(e) {
|
|
56
|
+
return role === 'link' ? (0, _utils.navigateTo)({
|
|
57
|
+
e: e,
|
|
58
|
+
href: href,
|
|
59
|
+
ref: containerRef
|
|
60
|
+
}) : onClick === null || onClick === void 0 ? void 0 : onClick(e);
|
|
61
|
+
};
|
|
62
|
+
var handleKeyDown = function handleKeyDown(e) {
|
|
63
|
+
return (0, _utils.onKeyDown)({
|
|
64
|
+
e: e,
|
|
65
|
+
href: href,
|
|
66
|
+
onClick: onClick,
|
|
67
|
+
ref: containerRef,
|
|
68
|
+
role: role
|
|
69
|
+
});
|
|
70
|
+
};
|
|
71
|
+
return /*#__PURE__*/_react.default.createElement(_styles.StyledCard, _extends({
|
|
72
|
+
tabIndex: 0,
|
|
73
|
+
role: role,
|
|
74
|
+
onClick: handleClickConditions,
|
|
75
|
+
onKeyDown: handleKeyDown,
|
|
76
|
+
$elevation: elevation,
|
|
77
|
+
ref: containerRef,
|
|
78
|
+
$selected: selected,
|
|
79
|
+
"aria-checked": checkedConditions,
|
|
80
|
+
$disabled: disabled,
|
|
81
|
+
"aria-disabled": disabled && disabled,
|
|
82
|
+
$compositionalComponents: hasSubComponent
|
|
83
|
+
}, rest), /*#__PURE__*/_react.default.createElement(_subComponents.SelectedIcon, {
|
|
84
|
+
$selected: selected
|
|
85
|
+
}), /*#__PURE__*/_react.default.createElement(_utils.SubComponentContext.Provider, {
|
|
86
|
+
value: setHasSubComponent
|
|
87
|
+
}, children));
|
|
43
88
|
};
|
|
44
89
|
var _default = Card;
|
|
45
90
|
exports.default = _default;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
+
var React = _interopRequireWildcard(require("react"));
|
|
5
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
6
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
@@ -13,4 +13,15 @@ Object.keys(_Card).forEach(function (key) {
|
|
|
13
13
|
return _Card[key];
|
|
14
14
|
}
|
|
15
15
|
});
|
|
16
|
+
});
|
|
17
|
+
var _CardTypes = require("./CardTypes.flow");
|
|
18
|
+
Object.keys(_CardTypes).forEach(function (key) {
|
|
19
|
+
if (key === "default" || key === "__esModule") return;
|
|
20
|
+
if (key in exports && exports[key] === _CardTypes[key]) return;
|
|
21
|
+
Object.defineProperty(exports, key, {
|
|
22
|
+
enumerable: true,
|
|
23
|
+
get: function get() {
|
|
24
|
+
return _CardTypes[key];
|
|
25
|
+
}
|
|
26
|
+
});
|
|
16
27
|
});
|
package/commonjs/Card/index.js
CHANGED
|
@@ -4,7 +4,10 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
var _exportNames = {
|
|
7
|
-
Card: true
|
|
7
|
+
Card: true,
|
|
8
|
+
CardHeader: true,
|
|
9
|
+
CardContent: true,
|
|
10
|
+
CardFooter: true
|
|
8
11
|
};
|
|
9
12
|
Object.defineProperty(exports, "Card", {
|
|
10
13
|
enumerable: true,
|
|
@@ -12,8 +15,27 @@ Object.defineProperty(exports, "Card", {
|
|
|
12
15
|
return _Card.default;
|
|
13
16
|
}
|
|
14
17
|
});
|
|
18
|
+
Object.defineProperty(exports, "CardContent", {
|
|
19
|
+
enumerable: true,
|
|
20
|
+
get: function get() {
|
|
21
|
+
return _subComponents.CardContent;
|
|
22
|
+
}
|
|
23
|
+
});
|
|
24
|
+
Object.defineProperty(exports, "CardFooter", {
|
|
25
|
+
enumerable: true,
|
|
26
|
+
get: function get() {
|
|
27
|
+
return _subComponents.CardFooter;
|
|
28
|
+
}
|
|
29
|
+
});
|
|
30
|
+
Object.defineProperty(exports, "CardHeader", {
|
|
31
|
+
enumerable: true,
|
|
32
|
+
get: function get() {
|
|
33
|
+
return _subComponents.CardHeader;
|
|
34
|
+
}
|
|
35
|
+
});
|
|
15
36
|
exports.default = void 0;
|
|
16
37
|
var _Card = _interopRequireDefault(require("./Card"));
|
|
38
|
+
var _subComponents = require("./subComponents");
|
|
17
39
|
var _CardTypes = require("./CardTypes");
|
|
18
40
|
Object.keys(_CardTypes).forEach(function (key) {
|
|
19
41
|
if (key === "default" || key === "__esModule") return;
|