@primer/styled-react 0.1.0 → 0.3.0
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/README.md +18 -0
- package/dist/components/ActionList.d.ts +44 -0
- package/dist/components/ActionList.d.ts.map +1 -0
- package/dist/components/ActionList.js +163 -0
- package/dist/components/ActionMenu.d.ts +13 -0
- package/dist/components/ActionMenu.d.ts.map +1 -0
- package/dist/components/ActionMenu.js +19 -0
- package/dist/components/Autocomplete.d.ts +17 -0
- package/dist/components/Autocomplete.d.ts.map +1 -0
- package/dist/components/Autocomplete.js +25 -0
- package/dist/components/Avatar.d.ts +13 -0
- package/dist/components/Avatar.d.ts.map +1 -0
- package/dist/components/Avatar.js +14 -0
- package/dist/components/BaseStyles.d.ts +17 -0
- package/dist/components/BaseStyles.d.ts.map +1 -0
- package/dist/components/BaseStyles.js +51 -0
- package/dist/components/Box.d.ts +19 -0
- package/dist/components/Box.d.ts.map +1 -0
- package/dist/components/Box.js +15 -0
- package/dist/components/Breadcrumbs.d.ts +18 -0
- package/dist/components/Breadcrumbs.d.ts.map +1 -0
- package/dist/components/Breadcrumbs.js +38 -0
- package/dist/components/Button.d.ts +12 -0
- package/dist/components/Button.d.ts.map +1 -0
- package/dist/components/Button.js +112 -0
- package/dist/components/Checkbox.d.ts +5 -0
- package/dist/components/Checkbox.d.ts.map +1 -0
- package/dist/components/Checkbox.js +15 -0
- package/dist/components/CheckboxGroup.d.ts +34 -0
- package/dist/components/CheckboxGroup.d.ts.map +1 -0
- package/dist/components/CheckboxGroup.js +43 -0
- package/dist/components/CircleBadge.d.ts +8 -0
- package/dist/components/CircleBadge.d.ts.map +1 -0
- package/dist/components/CircleBadge.js +12 -0
- package/dist/components/CounterLabel.d.ts +10 -0
- package/dist/components/CounterLabel.d.ts.map +1 -0
- package/dist/components/CounterLabel.js +14 -0
- package/dist/components/DataTable.d.ts +11 -0
- package/dist/components/DataTable.d.ts.map +1 -0
- package/dist/components/DataTable.js +32 -0
- package/dist/components/Dialog.d.ts +30 -0
- package/dist/components/Dialog.d.ts.map +1 -0
- package/dist/components/Dialog.js +90 -0
- package/dist/components/Flash.d.ts +8 -0
- package/dist/components/Flash.d.ts.map +1 -0
- package/dist/components/Flash.js +12 -0
- package/dist/components/FormControl.d.ts +13 -0
- package/dist/components/FormControl.d.ts.map +1 -0
- package/dist/components/FormControl.js +19 -0
- package/dist/components/Header.d.ts +11 -0
- package/dist/components/Header.d.ts.map +1 -0
- package/dist/components/Header.js +52 -0
- package/dist/components/Heading.d.ts +8 -0
- package/dist/components/Heading.d.ts.map +1 -0
- package/dist/components/Heading.js +12 -0
- package/dist/components/IconButton.d.ts +10 -0
- package/dist/components/IconButton.d.ts.map +1 -0
- package/dist/components/IconButton.js +40 -0
- package/dist/components/Label.d.ts +9 -0
- package/dist/components/Label.d.ts.map +1 -0
- package/dist/components/Label.js +26 -0
- package/dist/components/Link.d.ts +7 -0
- package/dist/components/Link.d.ts.map +1 -0
- package/dist/components/Link.js +26 -0
- package/dist/components/LinkButton.d.ts +8 -0
- package/dist/components/LinkButton.d.ts.map +1 -0
- package/dist/components/LinkButton.js +12 -0
- package/dist/components/NavList.d.ts +30 -0
- package/dist/components/NavList.d.ts.map +1 -0
- package/dist/components/NavList.js +74 -0
- package/dist/components/Overlay.d.ts +8 -0
- package/dist/components/Overlay.d.ts.map +1 -0
- package/dist/components/Overlay.js +12 -0
- package/dist/components/PageHeader.d.ts +31 -0
- package/dist/components/PageHeader.d.ts.map +1 -0
- package/dist/components/PageHeader.js +109 -0
- package/dist/components/PageLayout.d.ts +23 -0
- package/dist/components/PageLayout.d.ts.map +1 -0
- package/dist/components/PageLayout.js +43 -0
- package/dist/components/RadioGroup.d.ts +34 -0
- package/dist/components/RadioGroup.d.ts.map +1 -0
- package/dist/components/RadioGroup.js +43 -0
- package/dist/components/RelativeTime.d.ts +6 -0
- package/dist/components/RelativeTime.d.ts.map +1 -0
- package/dist/components/RelativeTime.js +14 -0
- package/dist/components/SegmentedControl.d.ts +19 -0
- package/dist/components/SegmentedControl.d.ts.map +1 -0
- package/dist/components/SegmentedControl.js +31 -0
- package/dist/components/Select.d.ts +8 -0
- package/dist/components/Select.d.ts.map +1 -0
- package/dist/components/Select.js +24 -0
- package/dist/components/Spinner.d.ts +5 -0
- package/dist/components/Spinner.d.ts.map +1 -0
- package/dist/components/Spinner.js +12 -0
- package/dist/components/StateLabel.d.ts +9 -0
- package/dist/components/StateLabel.d.ts.map +1 -0
- package/dist/components/StateLabel.js +14 -0
- package/dist/components/SubNav.d.ts +10 -0
- package/dist/components/SubNav.d.ts.map +1 -0
- package/dist/components/SubNav.js +26 -0
- package/dist/components/Text.d.ts +15 -0
- package/dist/components/Text.d.ts.map +1 -0
- package/dist/components/Text.js +26 -0
- package/dist/components/TextInput.d.ts +15 -0
- package/dist/components/TextInput.d.ts.map +1 -0
- package/dist/components/TextInput.js +38 -0
- package/dist/components/Textarea.d.ts +9 -0
- package/dist/components/Textarea.d.ts.map +1 -0
- package/dist/components/Textarea.js +26 -0
- package/dist/components/ThemeProvider.d.ts +30 -0
- package/dist/components/ThemeProvider.d.ts.map +1 -0
- package/dist/components/ThemeProvider.js +203 -0
- package/dist/components/Timeline.d.ts +26 -0
- package/dist/components/Timeline.d.ts.map +1 -0
- package/dist/components/Timeline.js +47 -0
- package/dist/components/ToggleSwitch.d.ts +6 -0
- package/dist/components/ToggleSwitch.d.ts.map +1 -0
- package/dist/components/ToggleSwitch.js +14 -0
- package/dist/components/Token.d.ts +8 -0
- package/dist/components/Token.d.ts.map +1 -0
- package/dist/components/Token.js +26 -0
- package/dist/components/Tooltip.d.ts +7 -0
- package/dist/components/Tooltip.d.ts.map +1 -0
- package/dist/components/Tooltip.js +15 -0
- package/dist/components/Truncate.d.ts +7 -0
- package/dist/components/Truncate.d.ts.map +1 -0
- package/dist/components/Truncate.js +12 -0
- package/dist/components/UnderlineNav.d.ts +11 -0
- package/dist/components/UnderlineNav.d.ts.map +1 -0
- package/dist/components/UnderlineNav.js +45 -0
- package/dist/components/UnderlinePanels.d.ts +14 -0
- package/dist/components/UnderlinePanels.d.ts.map +1 -0
- package/dist/components/UnderlinePanels.js +28 -0
- package/dist/components/deprecated/ActionList.d.ts +23 -0
- package/dist/components/deprecated/ActionList.d.ts.map +1 -0
- package/dist/components/deprecated/ActionList.js +49 -0
- package/dist/components/deprecated/DialogV1.d.ts +11 -0
- package/dist/components/deprecated/DialogV1.d.ts.map +1 -0
- package/dist/components/deprecated/DialogV1.js +44 -0
- package/dist/components/deprecated/Octicon.d.ts +17 -0
- package/dist/components/deprecated/Octicon.d.ts.map +1 -0
- package/dist/components/deprecated/Octicon.js +39 -0
- package/dist/components/deprecated/TabNav.d.ts +9 -0
- package/dist/components/deprecated/TabNav.d.ts.map +1 -0
- package/dist/components/deprecated/TabNav.js +44 -0
- package/dist/components/deprecated/Tooltip.d.ts +13 -0
- package/dist/components/deprecated/Tooltip.d.ts.map +1 -0
- package/dist/components/deprecated/Tooltip.js +32 -0
- package/dist/components.json +138 -0
- package/dist/deprecated.d.ts +5 -1
- package/dist/deprecated.d.ts.map +1 -1
- package/dist/deprecated.js +5 -1
- package/dist/experimental.d.ts +5 -1
- package/dist/experimental.d.ts.map +1 -1
- package/dist/experimental.js +5 -1
- package/dist/index.d.ts +48 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +47 -1
- package/dist/polymorphic.d.ts +39 -0
- package/dist/polymorphic.d.ts.map +1 -0
- package/dist/styled-props.d.ts +4 -0
- package/dist/styled-props.d.ts.map +1 -0
- package/dist/sx.d.ts +26 -0
- package/dist/sx.d.ts.map +1 -0
- package/dist/sx.js +8 -0
- package/dist/theme-get.d.ts +2 -0
- package/dist/theme-get.d.ts.map +1 -0
- package/dist/theme-get.js +10 -0
- package/package.json +34 -14
- package/dist/__tests__/exports.test.d.ts +0 -2
- package/dist/__tests__/exports.test.d.ts.map +0 -1
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
{
|
|
2
|
+
"components": [
|
|
3
|
+
"ActionList",
|
|
4
|
+
"ActionMenu",
|
|
5
|
+
"Autocomplete",
|
|
6
|
+
"Avatar",
|
|
7
|
+
"BaseStyles",
|
|
8
|
+
"Box",
|
|
9
|
+
"Breadcrumb",
|
|
10
|
+
"Breadcrumbs",
|
|
11
|
+
"Button",
|
|
12
|
+
"Checkbox",
|
|
13
|
+
"CheckboxGroup",
|
|
14
|
+
"CircleBadge",
|
|
15
|
+
"CounterLabel",
|
|
16
|
+
"Details",
|
|
17
|
+
"Dialog",
|
|
18
|
+
"Flash",
|
|
19
|
+
"FormControl",
|
|
20
|
+
"Header",
|
|
21
|
+
"Heading",
|
|
22
|
+
"IconButton",
|
|
23
|
+
"Label",
|
|
24
|
+
"Link",
|
|
25
|
+
"LinkButton",
|
|
26
|
+
"NavList",
|
|
27
|
+
"Octicon",
|
|
28
|
+
"Overlay",
|
|
29
|
+
"PageHeader",
|
|
30
|
+
"PageLayout",
|
|
31
|
+
"ProgressBar",
|
|
32
|
+
"RadioGroup",
|
|
33
|
+
"RelativeTime",
|
|
34
|
+
"SegmentedControl",
|
|
35
|
+
"Select",
|
|
36
|
+
"Spinner",
|
|
37
|
+
"StateLabel",
|
|
38
|
+
"SubNav",
|
|
39
|
+
"Table",
|
|
40
|
+
"TabNav",
|
|
41
|
+
"Text",
|
|
42
|
+
"Textarea",
|
|
43
|
+
"TextInput",
|
|
44
|
+
"ThemeProvider",
|
|
45
|
+
"Timeline",
|
|
46
|
+
"ToggleSwitch",
|
|
47
|
+
"Token",
|
|
48
|
+
"Tooltip",
|
|
49
|
+
"Truncate",
|
|
50
|
+
"UnderlineNav",
|
|
51
|
+
"UnderlinePanels"
|
|
52
|
+
],
|
|
53
|
+
"types": [
|
|
54
|
+
"ActionListDividerProps",
|
|
55
|
+
"ActionListGroupProps",
|
|
56
|
+
"ActionListItemProps",
|
|
57
|
+
"ActionListLeadingVisualProps",
|
|
58
|
+
"ActionListLinkItemProps",
|
|
59
|
+
"ActionListProps",
|
|
60
|
+
"ActionListTrailingActionProps",
|
|
61
|
+
"ActionListTrailingVisualProps",
|
|
62
|
+
"AutocompleteOverlayProps",
|
|
63
|
+
"AvatarProps",
|
|
64
|
+
"BaseStylesProps",
|
|
65
|
+
"BetterSystemStyleObject",
|
|
66
|
+
"BoxProps",
|
|
67
|
+
"BreadcrumbsItemProps",
|
|
68
|
+
"BreadcrumbsProps",
|
|
69
|
+
"ButtonProps",
|
|
70
|
+
"CheckboxGroupProps",
|
|
71
|
+
"CheckboxProps",
|
|
72
|
+
"CounterLabelProps",
|
|
73
|
+
"DataTableContainerProps",
|
|
74
|
+
"DialogHeaderProps",
|
|
75
|
+
"DialogProps",
|
|
76
|
+
"FormControlProps",
|
|
77
|
+
"HeaderProps",
|
|
78
|
+
"IconButtonProps",
|
|
79
|
+
"LabelProps",
|
|
80
|
+
"LinkButtonProps",
|
|
81
|
+
"LinkProps",
|
|
82
|
+
"NavListProps",
|
|
83
|
+
"OcticonProps",
|
|
84
|
+
"PageHeaderActionsProps",
|
|
85
|
+
"PageHeaderProps",
|
|
86
|
+
"PageHeaderTitleProps",
|
|
87
|
+
"PageLayoutProps",
|
|
88
|
+
"RadioGroupProps",
|
|
89
|
+
"RelativeTimeProps",
|
|
90
|
+
"SegmentedControlButtonProps",
|
|
91
|
+
"SegmentedControlIconButtonProps",
|
|
92
|
+
"SegmentedControlProps",
|
|
93
|
+
"SelectProps",
|
|
94
|
+
"SpinnerProps",
|
|
95
|
+
"StateLabelProps",
|
|
96
|
+
"SubNavLinkProps",
|
|
97
|
+
"SubNavProps",
|
|
98
|
+
"SxProp",
|
|
99
|
+
"TableActionsProps",
|
|
100
|
+
"TableBodyProps",
|
|
101
|
+
"TableCellProps",
|
|
102
|
+
"TableHeaderProps",
|
|
103
|
+
"TableHeadProps",
|
|
104
|
+
"TableProps",
|
|
105
|
+
"TableRowProps",
|
|
106
|
+
"TableSubtitleProps",
|
|
107
|
+
"TableTitleProps",
|
|
108
|
+
"TabNavLinkProps",
|
|
109
|
+
"TabNavProps",
|
|
110
|
+
"TextareaProps",
|
|
111
|
+
"TextInputActionProps",
|
|
112
|
+
"TextInputProps",
|
|
113
|
+
"TextProps",
|
|
114
|
+
"ThemeProviderProps",
|
|
115
|
+
"TimelineBadgeProps",
|
|
116
|
+
"TimelineBodyProps",
|
|
117
|
+
"TimelineBreakProps",
|
|
118
|
+
"TimelineItemProps",
|
|
119
|
+
"TimelineProps",
|
|
120
|
+
"ToggleSwitchProps",
|
|
121
|
+
"TokenProps",
|
|
122
|
+
"TooltipProps",
|
|
123
|
+
"TruncateProps",
|
|
124
|
+
"UnderlineNavItemProps",
|
|
125
|
+
"UnderlineNavProps",
|
|
126
|
+
"UnderlinePanelsPanelProps",
|
|
127
|
+
"UnderlinePanelsProps",
|
|
128
|
+
"UnderlinePanelsTabProps"
|
|
129
|
+
],
|
|
130
|
+
"utilities": [
|
|
131
|
+
"merge",
|
|
132
|
+
"sx",
|
|
133
|
+
"theme",
|
|
134
|
+
"themeGet",
|
|
135
|
+
"useColorSchemeVar",
|
|
136
|
+
"useTheme"
|
|
137
|
+
]
|
|
138
|
+
}
|
package/dist/deprecated.d.ts
CHANGED
|
@@ -1,2 +1,6 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { TabNav, type TabNavProps, type TabNavLinkProps } from './components/deprecated/TabNav';
|
|
2
|
+
export { Dialog, type DialogProps, type DialogHeaderProps } from './components/deprecated/DialogV1';
|
|
3
|
+
export { Octicon, type OcticonProps } from './components/deprecated/Octicon';
|
|
4
|
+
export { Tooltip, type TooltipProps } from './components/deprecated/Tooltip';
|
|
5
|
+
export { ActionList, type ActionListProps, type ActionListItemProps, type ActionListGroupProps, } from './components/deprecated/ActionList';
|
|
2
6
|
//# sourceMappingURL=deprecated.d.ts.map
|
package/dist/deprecated.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deprecated.d.ts","sourceRoot":"","sources":["../src/deprecated.
|
|
1
|
+
{"version":3,"file":"deprecated.d.ts","sourceRoot":"","sources":["../src/deprecated.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAC,MAAM,EAAE,KAAK,WAAW,EAAE,KAAK,eAAe,EAAC,MAAM,gCAAgC,CAAA;AAC7F,OAAO,EAAC,MAAM,EAAE,KAAK,WAAW,EAAE,KAAK,iBAAiB,EAAC,MAAM,kCAAkC,CAAA;AACjG,OAAO,EAAC,OAAO,EAAE,KAAK,YAAY,EAAC,MAAM,iCAAiC,CAAA;AAC1E,OAAO,EAAC,OAAO,EAAE,KAAK,YAAY,EAAC,MAAM,iCAAiC,CAAA;AAC1E,OAAO,EACL,UAAU,EACV,KAAK,eAAe,EACpB,KAAK,mBAAmB,EACxB,KAAK,oBAAoB,GAC1B,MAAM,oCAAoC,CAAA"}
|
package/dist/deprecated.js
CHANGED
|
@@ -1 +1,5 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { TabNav } from './components/deprecated/TabNav.js';
|
|
2
|
+
export { Dialog } from './components/deprecated/DialogV1.js';
|
|
3
|
+
export { default as Octicon } from './components/deprecated/Octicon.js';
|
|
4
|
+
export { Tooltip } from './components/deprecated/Tooltip.js';
|
|
5
|
+
export { ActionList } from './components/deprecated/ActionList.js';
|
package/dist/experimental.d.ts
CHANGED
|
@@ -1,2 +1,6 @@
|
|
|
1
|
-
export { Dialog } from '
|
|
1
|
+
export { Dialog, type DialogProps } from './components/Dialog';
|
|
2
|
+
export { PageHeader, type PageHeaderProps, type PageHeaderActionsProps, type PageHeaderTitleProps, } from './components/PageHeader';
|
|
3
|
+
export { Tooltip, type TooltipProps } from './components/Tooltip';
|
|
4
|
+
export { UnderlinePanels, type UnderlinePanelsProps, type UnderlinePanelsTabProps, type UnderlinePanelsPanelProps, } from './components/UnderlinePanels';
|
|
5
|
+
export { Table, type DataTableContainerProps, type TableProps, type TableHeadProps, type TableBodyProps, type TableRowProps, type TableHeaderProps, type TableCellProps, type TableTitleProps, type TableSubtitleProps, type TableActionsProps, } from './components/DataTable';
|
|
2
6
|
//# sourceMappingURL=experimental.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"experimental.d.ts","sourceRoot":"","sources":["../src/experimental.
|
|
1
|
+
{"version":3,"file":"experimental.d.ts","sourceRoot":"","sources":["../src/experimental.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAC,MAAM,EAAE,KAAK,WAAW,EAAC,MAAM,qBAAqB,CAAA;AAC5D,OAAO,EACL,UAAU,EACV,KAAK,eAAe,EACpB,KAAK,sBAAsB,EAC3B,KAAK,oBAAoB,GAC1B,MAAM,yBAAyB,CAAA;AAEhC,OAAO,EAAC,OAAO,EAAE,KAAK,YAAY,EAAC,MAAM,sBAAsB,CAAA;AAE/D,OAAO,EACL,eAAe,EACf,KAAK,oBAAoB,EACzB,KAAK,uBAAuB,EAC5B,KAAK,yBAAyB,GAC/B,MAAM,8BAA8B,CAAA;AAErC,OAAO,EACL,KAAK,EACL,KAAK,uBAAuB,EAC5B,KAAK,UAAU,EACf,KAAK,cAAc,EACnB,KAAK,cAAc,EACnB,KAAK,aAAa,EAClB,KAAK,gBAAgB,EACrB,KAAK,cAAc,EACnB,KAAK,eAAe,EACpB,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,GACvB,MAAM,wBAAwB,CAAA"}
|
package/dist/experimental.js
CHANGED
|
@@ -1 +1,5 @@
|
|
|
1
|
-
export { Dialog } from '
|
|
1
|
+
export { Dialog } from './components/Dialog.js';
|
|
2
|
+
export { PageHeader } from './components/PageHeader.js';
|
|
3
|
+
export { Tooltip } from './components/Tooltip.js';
|
|
4
|
+
export { UnderlinePanels } from './components/UnderlinePanels.js';
|
|
5
|
+
export { Table } from './components/DataTable.js';
|
package/dist/index.d.ts
CHANGED
|
@@ -1,2 +1,49 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { Box, type BoxProps } from './components/Box';
|
|
2
|
+
export { Details } from '@primer/react';
|
|
3
|
+
export { ProgressBar } from '@primer/react';
|
|
4
|
+
export { ThemeProvider, useTheme, useColorSchemeVar, type ThemeProviderProps } from './components/ThemeProvider';
|
|
5
|
+
export { BaseStyles, type BaseStylesProps } from './components/BaseStyles';
|
|
6
|
+
export { theme } from '@primer/react';
|
|
7
|
+
export { get as themeGet } from './theme-get';
|
|
8
|
+
export { ActionList, type ActionListProps, type ActionListItemProps, type ActionListLinkItemProps, type ActionListGroupProps, type ActionListDividerProps, type ActionListLeadingVisualProps, type ActionListTrailingVisualProps, type ActionListTrailingActionProps, } from './components/ActionList';
|
|
9
|
+
export { ActionMenu } from './components/ActionMenu';
|
|
10
|
+
export { Autocomplete, type AutocompleteOverlayProps } from './components/Autocomplete';
|
|
11
|
+
export { Avatar, type AvatarProps } from './components/Avatar';
|
|
12
|
+
export { Breadcrumbs, Breadcrumb, type BreadcrumbsProps, type BreadcrumbsItemProps } from './components/Breadcrumbs';
|
|
13
|
+
export { ButtonComponent as Button, type ButtonComponentProps as ButtonProps } from './components/Button';
|
|
14
|
+
export { Checkbox, type CheckboxProps } from './components/Checkbox';
|
|
15
|
+
export { CheckboxGroup, type CheckboxGroupProps } from './components/CheckboxGroup';
|
|
16
|
+
export { CircleBadge } from './components/CircleBadge';
|
|
17
|
+
export { CounterLabel, type CounterLabelProps } from './components/CounterLabel';
|
|
18
|
+
export { Dialog, type DialogProps } from './components/Dialog';
|
|
19
|
+
export { Flash } from './components/Flash';
|
|
20
|
+
export { FormControl, type FormControlProps } from './components/FormControl';
|
|
21
|
+
export { Header, type HeaderProps } from './components/Header';
|
|
22
|
+
export { Heading } from './components/Heading';
|
|
23
|
+
export { IconButton, type IconButtonProps } from './components/IconButton';
|
|
24
|
+
export { Label, type LabelProps } from './components/Label';
|
|
25
|
+
export { Link, type LinkProps } from './components/Link';
|
|
26
|
+
export { LinkButton, type LinkButtonProps } from './components/LinkButton';
|
|
27
|
+
export { NavList, type NavListProps } from './components/NavList';
|
|
28
|
+
export { Overlay } from './components/Overlay';
|
|
29
|
+
export { PageLayout, type PageLayoutProps } from './components/PageLayout';
|
|
30
|
+
export { PageHeader, type PageHeaderProps, type PageHeaderActionsProps, type PageHeaderTitleProps, } from './components/PageHeader';
|
|
31
|
+
export { RadioGroup, type RadioGroupProps } from './components/RadioGroup';
|
|
32
|
+
export { RelativeTime, type RelativeTimeProps } from './components/RelativeTime';
|
|
33
|
+
export { SegmentedControl, type SegmentedControlProps, type SegmentedControlButtonProps, type SegmentedControlIconButtonProps, } from './components/SegmentedControl';
|
|
34
|
+
export { Select, type SelectProps } from './components/Select';
|
|
35
|
+
export { Spinner, type SpinnerProps } from './components/Spinner';
|
|
36
|
+
export { StateLabel, type StateLabelProps } from './components/StateLabel';
|
|
37
|
+
export { SubNav, type SubNavProps, type SubNavLinkProps } from './components/SubNav';
|
|
38
|
+
export { Text, type TextProps } from './components/Text';
|
|
39
|
+
export { Textarea, type TextareaProps } from './components/Textarea';
|
|
40
|
+
export { TextInput, type TextInputProps, type TextInputActionProps } from './components/TextInput';
|
|
41
|
+
export { Timeline, type TimelineProps, type TimelineItemProps, type TimelineBadgeProps, type TimelineBodyProps, type TimelineBreakProps, } from './components/Timeline';
|
|
42
|
+
export { ToggleSwitch, type ToggleSwitchProps } from './components/ToggleSwitch';
|
|
43
|
+
export { Tooltip, type TooltipProps } from './components/Tooltip';
|
|
44
|
+
export { Token, type TokenProps } from './components/Token';
|
|
45
|
+
export { Truncate, type TruncateProps } from './components/Truncate';
|
|
46
|
+
export { UnderlineNav, type UnderlineNavProps, type UnderlineNavItemProps } from './components/UnderlineNav';
|
|
47
|
+
export { merge, sx, type SxProp } from './sx';
|
|
48
|
+
export { type BetterSystemStyleObject } from './sx';
|
|
2
49
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.tsx"],"names":[],"mappings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|
|
1
|
+
"use client";
|
|
2
|
+
export { default as Box } from './components/Box.js';
|
|
3
|
+
export { Details, ProgressBar, theme } from '@primer/react';
|
|
4
|
+
export { ThemeProvider, useColorSchemeVar, useTheme } from './components/ThemeProvider.js';
|
|
5
|
+
export { BaseStyles } from './components/BaseStyles.js';
|
|
6
|
+
export { get as themeGet } from './theme-get.js';
|
|
7
|
+
export { ActionList } from './components/ActionList.js';
|
|
8
|
+
export { ActionMenu } from './components/ActionMenu.js';
|
|
9
|
+
export { Autocomplete } from './components/Autocomplete.js';
|
|
10
|
+
export { Avatar } from './components/Avatar.js';
|
|
11
|
+
export { Breadcrumb, Breadcrumbs } from './components/Breadcrumbs.js';
|
|
12
|
+
export { ButtonComponent as Button } from './components/Button.js';
|
|
13
|
+
export { Checkbox } from './components/Checkbox.js';
|
|
14
|
+
export { CheckboxGroup } from './components/CheckboxGroup.js';
|
|
15
|
+
export { CircleBadge } from './components/CircleBadge.js';
|
|
16
|
+
export { CounterLabel } from './components/CounterLabel.js';
|
|
17
|
+
export { Dialog } from './components/Dialog.js';
|
|
18
|
+
export { Flash } from './components/Flash.js';
|
|
19
|
+
export { FormControl } from './components/FormControl.js';
|
|
20
|
+
export { Header } from './components/Header.js';
|
|
21
|
+
export { Heading } from './components/Heading.js';
|
|
22
|
+
export { IconButton } from './components/IconButton.js';
|
|
23
|
+
export { Label } from './components/Label.js';
|
|
24
|
+
export { Link } from './components/Link.js';
|
|
25
|
+
export { LinkButton } from './components/LinkButton.js';
|
|
26
|
+
export { NavList } from './components/NavList.js';
|
|
27
|
+
export { Overlay } from './components/Overlay.js';
|
|
28
|
+
export { PageLayout } from './components/PageLayout.js';
|
|
29
|
+
export { PageHeader } from './components/PageHeader.js';
|
|
30
|
+
export { RadioGroup } from './components/RadioGroup.js';
|
|
31
|
+
export { RelativeTime } from './components/RelativeTime.js';
|
|
32
|
+
export { SegmentedControl } from './components/SegmentedControl.js';
|
|
33
|
+
export { Select } from './components/Select.js';
|
|
34
|
+
export { Spinner } from './components/Spinner.js';
|
|
35
|
+
export { StateLabel } from './components/StateLabel.js';
|
|
36
|
+
export { SubNav } from './components/SubNav.js';
|
|
37
|
+
export { Text } from './components/Text.js';
|
|
38
|
+
export { Textarea } from './components/Textarea.js';
|
|
39
|
+
export { TextInput } from './components/TextInput.js';
|
|
40
|
+
export { Timeline } from './components/Timeline.js';
|
|
41
|
+
export { ToggleSwitch } from './components/ToggleSwitch.js';
|
|
42
|
+
export { Tooltip } from './components/Tooltip.js';
|
|
43
|
+
export { Token } from './components/Token.js';
|
|
44
|
+
export { Truncate } from './components/Truncate.js';
|
|
45
|
+
export { UnderlineNav } from './components/UnderlineNav.js';
|
|
46
|
+
export { default as sx } from './sx.js';
|
|
47
|
+
export { default as merge } from 'deepmerge';
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file is originally from `@radix-ui/react-polymorphic` before the package
|
|
3
|
+
* was deprecated. The original source for this lived in the URL below.
|
|
4
|
+
*
|
|
5
|
+
* @see https://github.com/radix-ui/primitives/blob/17ffcb7aaa42cbd36b3c210ba86d7d73d218e5be/packages/react/polymorphic/src/polymorphic.ts
|
|
6
|
+
*/
|
|
7
|
+
import * as React from 'react';
|
|
8
|
+
import type { JSX } from 'react';
|
|
9
|
+
type Merge<P1 = {}, P2 = {}> = Omit<P1, keyof P2> & P2;
|
|
10
|
+
/**
|
|
11
|
+
* Infers the OwnProps if E is a ForwardRefExoticComponentWithAs
|
|
12
|
+
*/
|
|
13
|
+
type OwnProps<E> = E extends ForwardRefComponent<any, infer P> ? P : {};
|
|
14
|
+
/**
|
|
15
|
+
* Infers the JSX.IntrinsicElement if E is a ForwardRefExoticComponentWithAs
|
|
16
|
+
*/
|
|
17
|
+
type IntrinsicElement<E> = E extends ForwardRefComponent<infer I, any> ? I : never;
|
|
18
|
+
type ForwardRefExoticComponent<E, OwnProps> = React.ForwardRefExoticComponent<Merge<E extends React.ElementType ? React.ComponentPropsWithRef<E> : never, OwnProps & {
|
|
19
|
+
as?: E;
|
|
20
|
+
}>>;
|
|
21
|
+
interface ForwardRefComponent<IntrinsicElementString, OwnProps = {}> extends ForwardRefExoticComponent<IntrinsicElementString, OwnProps> {
|
|
22
|
+
/**
|
|
23
|
+
* When `as` prop is passed, use this overload.
|
|
24
|
+
* Merges original own props (without DOM props) and the inferred props
|
|
25
|
+
* from `as` element with the own props taking precedence.
|
|
26
|
+
*
|
|
27
|
+
* We explicitly avoid `React.ElementType` and manually narrow the prop types
|
|
28
|
+
* so that events are typed when using JSX.IntrinsicElements.
|
|
29
|
+
*/
|
|
30
|
+
<As = IntrinsicElementString>(props: As extends '' ? {
|
|
31
|
+
as: keyof JSX.IntrinsicElements;
|
|
32
|
+
} : As extends React.ComponentType<infer P> ? Merge<P, OwnProps & {
|
|
33
|
+
as: As;
|
|
34
|
+
}> : As extends keyof JSX.IntrinsicElements ? Merge<JSX.IntrinsicElements[As], OwnProps & {
|
|
35
|
+
as: As;
|
|
36
|
+
}> : never): React.ReactElement | null;
|
|
37
|
+
}
|
|
38
|
+
export type { ForwardRefComponent, OwnProps, IntrinsicElement, Merge };
|
|
39
|
+
//# sourceMappingURL=polymorphic.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"polymorphic.d.ts","sourceRoot":"","sources":["../src/polymorphic.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,EAAC,GAAG,EAAC,MAAM,OAAO,CAAA;AAK9B,KAAK,KAAK,CAAC,EAAE,GAAG,EAAE,EAAE,EAAE,GAAG,EAAE,IAAI,IAAI,CAAC,EAAE,EAAE,MAAM,EAAE,CAAC,GAAG,EAAE,CAAA;AAEtD;;GAEG;AACH,KAAK,QAAQ,CAAC,CAAC,IAAI,CAAC,SAAS,mBAAmB,CAAC,GAAG,EAAE,MAAM,CAAC,CAAC,GAAG,CAAC,GAAG,EAAE,CAA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ographyProps } from 'styled-system';
|
|
2
|
+
import type { SxProp } from './sx';
|
|
3
|
+
export type StyledProps = SxProp & SpaceProps & ColorProps & TypographyProps & LayoutProps & FlexboxProps & GridProps & BackgroundProps & BorderProps & PositionProps & ShadowProps;
|
|
4
|
+
//# sourceMappingURL=styled-props.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"styled-props.d.ts","sourceRoot":"","sources":["../src/styled-props.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,eAAe,EACf,WAAW,EACX,UAAU,EACV,YAAY,EACZ,SAAS,EACT,WAAW,EACX,aAAa,EACb,WAAW,EACX,UAAU,EACV,eAAe,EAChB,MAAM,eAAe,CAAA;AACtB,OAAO,KAAK,EAAC,MAAM,EAAC,MAAM,MAAM,CAAA;AAEhC,MAAM,MAAM,WAAW,GAAG,MAAM,GAC9B,UAAU,GACV,UAAU,GACV,eAAe,GACf,WAAW,GACX,YAAY,GACZ,SAAS,GACT,eAAe,GACf,WAAW,GACX,aAAa,GACb,WAAW,CAAA"}
|
package/dist/sx.d.ts
ADDED
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import type { SystemCssProperties, SystemStyleObject } from '@styled-system/css';
|
|
2
|
+
import type { ThemeColorPaths, ThemeShadowPaths } from '@primer/react';
|
|
3
|
+
import type { ColorProps, BorderColorProps, ShadowProps } from 'styled-system';
|
|
4
|
+
import merge from 'deepmerge';
|
|
5
|
+
export type BetterCssProperties = {
|
|
6
|
+
[K in keyof SystemCssProperties]: K extends keyof ColorProps ? ThemeColorPaths | SystemCssProperties[K] : K extends keyof BorderColorProps ? ThemeColorPaths | SystemCssProperties[K] : K extends keyof ShadowProps ? ThemeShadowPaths | SystemCssProperties[K] : SystemCssProperties[K];
|
|
7
|
+
};
|
|
8
|
+
export type CSSCustomProperties = {
|
|
9
|
+
[key: `--${string}`]: string | number;
|
|
10
|
+
};
|
|
11
|
+
type CSSSelectorObject = {
|
|
12
|
+
[cssSelector: string]: SystemStyleObject | CSSCustomProperties;
|
|
13
|
+
};
|
|
14
|
+
export type BetterSystemStyleObject = BetterCssProperties | SystemStyleObject | CSSCustomProperties | CSSSelectorObject;
|
|
15
|
+
export interface SxProp {
|
|
16
|
+
/**
|
|
17
|
+
* @deprecated The `sx` prop is deprecated. Replace with a `div` or
|
|
18
|
+
* appropriate HTML element instead, with a CSS class for styling.
|
|
19
|
+
* @see https://github.com/primer/react/blob/main/contributor-docs/migration-from-box.md
|
|
20
|
+
* */
|
|
21
|
+
sx?: BetterSystemStyleObject;
|
|
22
|
+
}
|
|
23
|
+
declare const sx: (props: SxProp) => import("@styled-system/css").CssFunctionReturnType;
|
|
24
|
+
export default sx;
|
|
25
|
+
export { merge, sx };
|
|
26
|
+
//# sourceMappingURL=sx.d.ts.map
|
package/dist/sx.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sx.d.ts","sourceRoot":"","sources":["../src/sx.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,mBAAmB,EAAE,iBAAiB,EAAC,MAAM,oBAAoB,CAAA;AAE9E,OAAO,KAAK,EAAC,eAAe,EAAE,gBAAgB,EAAC,MAAM,eAAe,CAAA;AACpE,OAAO,KAAK,EAAC,UAAU,EAAE,gBAAgB,EAAE,WAAW,EAAC,MAAM,eAAe,CAAA;AAC5E,OAAO,KAAK,MAAM,WAAW,CAAA;AAE7B,MAAM,MAAM,mBAAmB,GAAG;KAC/B,CAAC,IAAI,MAAM,mBAAmB,GAAG,CAAC,SAAS,MAAM,UAAU,GACxD,eAAe,GAAG,mBAAmB,CAAC,CAAC,CAAC,GACxC,CAAC,SAAS,MAAM,gBAAgB,GAC9B,eAAe,GAAG,mBAAmB,CAAC,CAAC,CAAC,GACxC,CAAC,SAAS,MAAM,WAAW,GACzB,gBAAgB,GAAG,mBAAmB,CAAC,CAAC,CAAC,GACzC,mBAAmB,CAAC,CAAC,CAAC;CAC/B,CAAA;AAGD,MAAM,MAAM,mBAAmB,GAAG;IAChC,CAAC,GAAG,EAAE,KAAK,MAAM,EAAE,GAAG,MAAM,GAAG,MAAM,CAAA;CACtC,CAAA;AAED,KAAK,iBAAiB,GAAG;IACvB,CAAC,WAAW,EAAE,MAAM,GAAG,iBAAiB,GAAG,mBAAmB,CAAA;CAC/D,CAAA;AAED,MAAM,MAAM,uBAAuB,GAAG,mBAAmB,GAAG,iBAAiB,GAAG,mBAAmB,GAAG,iBAAiB,CAAA;AAEvH,MAAM,WAAW,MAAM;IACrB;;;;SAIK;IACL,EAAE,CAAC,EAAE,uBAAuB,CAAA;CAC7B;AAED,QAAA,MAAM,EAAE,GAAI,OAAO,MAAM,uDAAkB,CAAA;AAE3C,eAAe,EAAE,CAAA;AAEjB,OAAO,EAAC,KAAK,EAAE,EAAE,EAAC,CAAA"}
|
package/dist/sx.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"theme-get.d.ts","sourceRoot":"","sources":["../src/theme-get.ts"],"names":[],"mappings":"AAOA,eAAO,MAAM,GAAG,GAAI,KAAK,MAAM,wBAAsC,CAAA"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { themeGet } from '@styled-system/theme-get';
|
|
2
|
+
import * as styledSystem from 'styled-system';
|
|
3
|
+
import { theme } from '@primer/react';
|
|
4
|
+
|
|
5
|
+
const {
|
|
6
|
+
get: getKey
|
|
7
|
+
} = styledSystem;
|
|
8
|
+
const get = key => themeGet(key, getKey(theme, key));
|
|
9
|
+
|
|
10
|
+
export { get };
|
package/package.json
CHANGED
|
@@ -1,46 +1,66 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@primer/styled-react",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"exports": {
|
|
6
6
|
".": {
|
|
7
|
-
"types": "dist/index.d.ts",
|
|
8
|
-
"default": "dist/index.js"
|
|
7
|
+
"types": "./dist/index.d.ts",
|
|
8
|
+
"default": "./dist/index.js"
|
|
9
9
|
},
|
|
10
10
|
"./deprecated": {
|
|
11
|
-
"types": "dist/deprecated.d.ts",
|
|
12
|
-
"default": "dist/deprecated.js"
|
|
11
|
+
"types": "./dist/deprecated.d.ts",
|
|
12
|
+
"default": "./dist/deprecated.js"
|
|
13
13
|
},
|
|
14
14
|
"./experimental": {
|
|
15
|
-
"types": "dist/experimental.d.ts",
|
|
16
|
-
"default": "dist/experimental.js"
|
|
17
|
-
}
|
|
15
|
+
"types": "./dist/experimental.d.ts",
|
|
16
|
+
"default": "./dist/experimental.js"
|
|
17
|
+
},
|
|
18
|
+
"./components.json": "./dist/components.json"
|
|
18
19
|
},
|
|
19
20
|
"files": [
|
|
20
21
|
"README.md",
|
|
21
22
|
"dist"
|
|
22
23
|
],
|
|
24
|
+
"repository": {
|
|
25
|
+
"type": "git",
|
|
26
|
+
"url": "git+https://github.com/primer/react.git"
|
|
27
|
+
},
|
|
23
28
|
"scripts": {
|
|
24
29
|
"build": "script/build",
|
|
25
30
|
"clean": "rimraf dist",
|
|
31
|
+
"lint:npm": "publint --types",
|
|
26
32
|
"type-check": "tsc --noEmit"
|
|
27
33
|
},
|
|
34
|
+
"dependencies": {
|
|
35
|
+
"@styled-system/css": "^5.1.5",
|
|
36
|
+
"@styled-system/props": "^5.1.5",
|
|
37
|
+
"@styled-system/theme-get": "^5.1.2",
|
|
38
|
+
"@types/styled-system": "^5.1.23",
|
|
39
|
+
"@types/styled-system__css": "^5.0.16",
|
|
40
|
+
"@types/styled-system__theme-get": "^5.0.1",
|
|
41
|
+
"styled-system": "^5.1.5"
|
|
42
|
+
},
|
|
28
43
|
"devDependencies": {
|
|
29
|
-
"@babel/preset-
|
|
30
|
-
"@
|
|
31
|
-
"@
|
|
44
|
+
"@babel/preset-react": "^7.28.5",
|
|
45
|
+
"@babel/preset-typescript": "^7.28.5",
|
|
46
|
+
"@primer/react": "^38.1.0",
|
|
47
|
+
"@rollup/plugin-babel": "^6.1.0",
|
|
32
48
|
"@types/react": "18.3.11",
|
|
33
49
|
"@types/react-dom": "18.3.1",
|
|
50
|
+
"@types/styled-components": "^5.1.26",
|
|
51
|
+
"@vitejs/plugin-react": "^4.3.3",
|
|
52
|
+
"babel-plugin-styled-components": "2.1.4",
|
|
53
|
+
"publint": "^0.3.15",
|
|
34
54
|
"react": "18.3.1",
|
|
35
55
|
"react-dom": "18.3.1",
|
|
36
56
|
"rimraf": "^6.0.1",
|
|
37
|
-
"rollup": "4.
|
|
57
|
+
"rollup": "4.52.5",
|
|
38
58
|
"rollup-plugin-typescript2": "^0.36.0",
|
|
39
59
|
"styled-components": "5.3.11",
|
|
40
|
-
"typescript": "^5.
|
|
60
|
+
"typescript": "^5.9.2"
|
|
41
61
|
},
|
|
42
62
|
"peerDependencies": {
|
|
43
|
-
"@primer/react": "^
|
|
63
|
+
"@primer/react": "^38.0.0",
|
|
44
64
|
"@types/react": "18.x || 19.x",
|
|
45
65
|
"@types/react-dom": "18.x || 19.x",
|
|
46
66
|
"@types/react-is": "18.x || 19.x",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"exports.test.d.ts","sourceRoot":"","sources":["../../src/__tests__/exports.test.ts"],"names":[],"mappings":""}
|