@primer/styled-react 0.0.0-20251205021328 → 0.0.0-20251205154953
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/dist/components/ActionList.js +89 -145
- package/dist/components/ActionMenu.js +15 -15
- package/dist/components/Autocomplete.js +18 -20
- package/dist/components/Avatar.js +13 -11
- package/dist/components/BaseStyles.js +28 -47
- package/dist/components/Box.js +18 -10
- package/dist/components/Breadcrumbs.js +22 -32
- package/dist/components/Button.js +41 -105
- package/dist/components/Checkbox.js +14 -12
- package/dist/components/CheckboxGroup.js +34 -36
- package/dist/components/CircleBadge.js +10 -10
- package/dist/components/CounterLabel.js +13 -11
- package/dist/components/DataTable.js +19 -27
- package/dist/components/Dialog.js +53 -79
- package/dist/components/Flash.js +9 -9
- package/dist/components/FormControl.js +15 -15
- package/dist/components/Header.js +36 -44
- package/dist/components/Heading.js +9 -9
- package/dist/components/IconButton.js +23 -36
- package/dist/components/Label.js +17 -22
- package/dist/components/Link.js +17 -22
- package/dist/components/LinkButton.js +9 -9
- package/dist/components/NavList.js +46 -65
- package/dist/components/Overlay.js +9 -9
- package/dist/components/PageHeader.js +62 -100
- package/dist/components/RadioGroup.js +34 -36
- package/dist/components/RelativeTime.js +11 -11
- package/dist/components/SegmentedControl.js +27 -25
- package/dist/components/Select.js +15 -20
- package/dist/components/Spinner.js +9 -9
- package/dist/components/StateLabel.js +13 -11
- package/dist/components/SubNav.js +23 -21
- package/dist/components/Text.js +17 -22
- package/dist/components/TextInput.js +25 -32
- package/dist/components/Textarea.js +17 -22
- package/dist/components/ThemeProvider.js +132 -185
- package/dist/components/Timeline.js +40 -38
- package/dist/components/ToggleSwitch.js +13 -11
- package/dist/components/Token.js +17 -22
- package/dist/components/Tooltip.js +14 -12
- package/dist/components/Truncate.js +9 -9
- package/dist/components/UnderlineNav.js +27 -39
- package/dist/components/UnderlinePanels.js +18 -23
- package/dist/components/deprecated/ActionList.js +34 -39
- package/dist/components/deprecated/DialogV1.js +28 -38
- package/dist/components/deprecated/Octicon.js +28 -35
- package/dist/components/deprecated/TabNav.js +24 -38
- package/dist/components/deprecated/Tooltip.js +20 -28
- package/dist/deprecated.js +7 -5
- package/dist/experimental.js +7 -5
- package/dist/index.js +48 -46
- package/dist/sx.js +7 -6
- package/dist/theme-get.js +8 -8
- package/package.json +7 -4
|
@@ -1,112 +1,48 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import { jsx } from
|
|
1
|
+
import { sx } from "../sx.js";
|
|
2
|
+
import styled from "styled-components";
|
|
3
|
+
import { Button } from "@primer/react";
|
|
4
|
+
import { forwardRef } from "react";
|
|
5
|
+
import { jsx } from "react/jsx-runtime";
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
componentId: "sc-vqy3e4-0"
|
|
7
|
+
//#region src/components/Button.tsx
|
|
8
|
+
const StyledButtonComponent = styled(Button).withConfig({ shouldForwardProp: (prop) => prop !== "sx" }).withConfig({
|
|
9
|
+
displayName: "Button__StyledButtonComponent",
|
|
10
|
+
componentId: "sc-vqy3e4-0"
|
|
12
11
|
})(["", ""], sx);
|
|
13
|
-
const ButtonComponent =
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
trailingVisual,
|
|
36
|
-
trailingAction
|
|
37
|
-
}, sx);
|
|
38
|
-
const {
|
|
39
|
-
color
|
|
40
|
-
} = sx;
|
|
41
|
-
if (color) style['--button-color'] = color;
|
|
42
|
-
}
|
|
43
|
-
return /*#__PURE__*/jsx(StyledButtonComponent, {
|
|
44
|
-
style: style,
|
|
45
|
-
sx: sxStyles,
|
|
46
|
-
ref: ref,
|
|
47
|
-
...props,
|
|
48
|
-
...(as ? {
|
|
49
|
-
forwardedAs: as
|
|
50
|
-
} : {})
|
|
51
|
-
});
|
|
12
|
+
const ButtonComponent = /* @__PURE__ */ forwardRef(({ as, sx: sx$1, style: propStyle, ...props }, ref) => {
|
|
13
|
+
const { block, size = "medium", leadingVisual, trailingVisual, trailingAction } = props;
|
|
14
|
+
let sxStyles = {};
|
|
15
|
+
const style = { ...propStyle || {} };
|
|
16
|
+
if (sx$1 !== null && Object.keys(sx$1 || {}).length > 0) {
|
|
17
|
+
sxStyles = generateCustomSxProp({
|
|
18
|
+
block,
|
|
19
|
+
size,
|
|
20
|
+
leadingVisual,
|
|
21
|
+
trailingVisual,
|
|
22
|
+
trailingAction
|
|
23
|
+
}, sx$1);
|
|
24
|
+
const { color } = sx$1;
|
|
25
|
+
if (color) style["--button-color"] = color;
|
|
26
|
+
}
|
|
27
|
+
return /* @__PURE__ */ jsx(StyledButtonComponent, {
|
|
28
|
+
style,
|
|
29
|
+
sx: sxStyles,
|
|
30
|
+
ref,
|
|
31
|
+
...props,
|
|
32
|
+
...as ? { forwardedAs: as } : {}
|
|
33
|
+
});
|
|
52
34
|
});
|
|
53
|
-
|
|
54
|
-
// This function is used to generate a custom cssSelector for the sxProp
|
|
55
|
-
|
|
56
|
-
// The usual sx prop can like this:
|
|
57
|
-
// sx={{
|
|
58
|
-
// [`@media (max-width: 768px)`]: {
|
|
59
|
-
// '& > ul': {
|
|
60
|
-
// backgroundColor: 'deeppink',
|
|
61
|
-
// },
|
|
62
|
-
// '&:hover': {
|
|
63
|
-
// backgroundColor: 'yellow',
|
|
64
|
-
// },
|
|
65
|
-
// },
|
|
66
|
-
// '&:hover': {
|
|
67
|
-
// backgroundColor: 'yellow',
|
|
68
|
-
// },
|
|
69
|
-
// '&': {
|
|
70
|
-
// width : 320px
|
|
71
|
-
// }
|
|
72
|
-
// }}
|
|
73
|
-
//*
|
|
74
|
-
/* What we want for Button styles is this:
|
|
75
|
-
sx={{
|
|
76
|
-
// [`@media (max-width: 768px)`]: {
|
|
77
|
-
// '&[data-attribute="something"] > ul': {
|
|
78
|
-
// backgroundColor: 'deeppink',
|
|
79
|
-
// },
|
|
80
|
-
// '&[data-attribute="something"]:hover': {
|
|
81
|
-
// backgroundColor: 'yellow',
|
|
82
|
-
// },
|
|
83
|
-
// },
|
|
84
|
-
// '&[data-attribute="something"]:hover': {
|
|
85
|
-
// backgroundColor: 'yellow',
|
|
86
|
-
// },
|
|
87
|
-
// '&[data-attribute="something"]': {
|
|
88
|
-
// width : 320px
|
|
89
|
-
// }
|
|
90
|
-
// }}
|
|
91
|
-
|
|
92
|
-
// We need to make sure we append the customCSSSelector to the original class selector. i.e & - > &[data-attribute="Icon"][data-size="small"]
|
|
93
|
-
*/
|
|
94
35
|
function generateCustomSxProp(props, providedSx) {
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
const customSxProp = {};
|
|
104
|
-
if (!providedSx) return customSxProp;else {
|
|
105
|
-
customSxProp[cssSelector] = providedSx;
|
|
106
|
-
return customSxProp;
|
|
107
|
-
}
|
|
36
|
+
const cssSelector = `&${`[data-size="${props.size}"]`}${props.block ? `[data-block="block"]` : ""}${props.leadingVisual || props.trailingVisual || props.trailingAction ? "" : "[data-no-visuals]"}`;
|
|
37
|
+
const customSxProp = {};
|
|
38
|
+
if (!providedSx) return customSxProp;
|
|
39
|
+
else {
|
|
40
|
+
customSxProp[cssSelector] = providedSx;
|
|
41
|
+
return customSxProp;
|
|
42
|
+
}
|
|
108
43
|
}
|
|
109
|
-
ButtonComponent.displayName =
|
|
44
|
+
ButtonComponent.displayName = "Button";
|
|
110
45
|
ButtonComponent.__SLOT__ = Button.__SLOT__;
|
|
111
46
|
|
|
112
|
-
|
|
47
|
+
//#endregion
|
|
48
|
+
export { ButtonComponent, generateCustomSxProp };
|
|
@@ -1,15 +1,17 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import { forwardRef } from
|
|
4
|
-
import { jsx } from
|
|
1
|
+
import { Box } from "./Box.js";
|
|
2
|
+
import { Checkbox } from "@primer/react";
|
|
3
|
+
import { forwardRef } from "react";
|
|
4
|
+
import { jsx } from "react/jsx-runtime";
|
|
5
5
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
6
|
+
//#region src/components/Checkbox.tsx
|
|
7
|
+
const Checkbox$1 = /* @__PURE__ */ forwardRef(function Checkbox$2(props, ref) {
|
|
8
|
+
return /* @__PURE__ */ jsx(Box, {
|
|
9
|
+
as: Checkbox,
|
|
10
|
+
ref,
|
|
11
|
+
...props
|
|
12
|
+
});
|
|
12
13
|
});
|
|
13
|
-
Checkbox.__SLOT__ = Checkbox
|
|
14
|
+
Checkbox$1.__SLOT__ = Checkbox.__SLOT__;
|
|
14
15
|
|
|
15
|
-
|
|
16
|
+
//#endregion
|
|
17
|
+
export { Checkbox$1 as Checkbox };
|
|
@@ -1,43 +1,41 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import { jsx } from 'react/jsx-runtime';
|
|
1
|
+
import Box_default from "./Box.js";
|
|
2
|
+
import { CheckboxGroup } from "@primer/react";
|
|
3
|
+
import { jsx } from "react/jsx-runtime";
|
|
5
4
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
5
|
+
//#region src/components/CheckboxGroup.tsx
|
|
6
|
+
const CheckboxGroupImpl = (props) => {
|
|
7
|
+
return /* @__PURE__ */ jsx(Box_default, {
|
|
8
|
+
as: CheckboxGroup,
|
|
9
|
+
...props
|
|
10
|
+
});
|
|
11
11
|
};
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
as: CheckboxGroup$1.Label,
|
|
18
|
-
...props
|
|
19
|
-
});
|
|
12
|
+
const CheckboxOrRadioGroupLabel = (props) => {
|
|
13
|
+
return /* @__PURE__ */ jsx(Box_default, {
|
|
14
|
+
as: CheckboxGroup.Label,
|
|
15
|
+
...props
|
|
16
|
+
});
|
|
20
17
|
};
|
|
21
|
-
const CheckboxOrRadioGroupCaption = props => {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
18
|
+
const CheckboxOrRadioGroupCaption = (props) => {
|
|
19
|
+
return /* @__PURE__ */ jsx(Box_default, {
|
|
20
|
+
as: CheckboxGroup.Caption,
|
|
21
|
+
...props
|
|
22
|
+
});
|
|
26
23
|
};
|
|
27
|
-
const CheckboxOrRadioGroupValidation = props => {
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
24
|
+
const CheckboxOrRadioGroupValidation = (props) => {
|
|
25
|
+
return /* @__PURE__ */ jsx(Box_default, {
|
|
26
|
+
as: CheckboxGroup.Validation,
|
|
27
|
+
...props
|
|
28
|
+
});
|
|
32
29
|
};
|
|
33
|
-
const CheckboxGroup = Object.assign(CheckboxGroupImpl, {
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
30
|
+
const CheckboxGroup$1 = Object.assign(CheckboxGroupImpl, {
|
|
31
|
+
Label: CheckboxOrRadioGroupLabel,
|
|
32
|
+
Caption: CheckboxOrRadioGroupCaption,
|
|
33
|
+
Validation: CheckboxOrRadioGroupValidation
|
|
37
34
|
});
|
|
38
|
-
CheckboxGroupImpl.__SLOT__ = CheckboxGroup
|
|
39
|
-
CheckboxOrRadioGroupLabel.__SLOT__ = CheckboxGroup
|
|
40
|
-
CheckboxOrRadioGroupCaption.__SLOT__ = CheckboxGroup
|
|
41
|
-
CheckboxOrRadioGroupValidation.__SLOT__ = CheckboxGroup
|
|
35
|
+
CheckboxGroupImpl.__SLOT__ = CheckboxGroup.__SLOT__;
|
|
36
|
+
CheckboxOrRadioGroupLabel.__SLOT__ = CheckboxGroup.Label.__SLOT__;
|
|
37
|
+
CheckboxOrRadioGroupCaption.__SLOT__ = CheckboxGroup.Caption.__SLOT__;
|
|
38
|
+
CheckboxOrRadioGroupValidation.__SLOT__ = CheckboxGroup.Validation.__SLOT__;
|
|
42
39
|
|
|
43
|
-
|
|
40
|
+
//#endregion
|
|
41
|
+
export { CheckboxGroup$1 as CheckboxGroup };
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import
|
|
2
|
-
import styled from
|
|
3
|
-
import
|
|
1
|
+
import sx_default from "../sx.js";
|
|
2
|
+
import styled from "styled-components";
|
|
3
|
+
import { CircleBadge } from "@primer/react";
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
})(["", ""], sx);
|
|
5
|
+
//#region src/components/CircleBadge.tsx
|
|
6
|
+
const CircleBadge$1 = styled(CircleBadge).withConfig({ shouldForwardProp: (prop) => prop !== "sx" }).withConfig({
|
|
7
|
+
displayName: "CircleBadge",
|
|
8
|
+
componentId: "sc-1u7lp3v-0"
|
|
9
|
+
})(["", ""], sx_default);
|
|
11
10
|
|
|
12
|
-
|
|
11
|
+
//#endregion
|
|
12
|
+
export { CircleBadge$1 as CircleBadge };
|
|
@@ -1,14 +1,16 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import { forwardRef } from
|
|
4
|
-
import { jsx } from
|
|
1
|
+
import { Box } from "./Box.js";
|
|
2
|
+
import { CounterLabel } from "@primer/react";
|
|
3
|
+
import { forwardRef } from "react";
|
|
4
|
+
import { jsx } from "react/jsx-runtime";
|
|
5
5
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
6
|
+
//#region src/components/CounterLabel.tsx
|
|
7
|
+
const CounterLabel$1 = /* @__PURE__ */ forwardRef(function CounterLabel$2(props, ref) {
|
|
8
|
+
return /* @__PURE__ */ jsx(Box, {
|
|
9
|
+
as: CounterLabel,
|
|
10
|
+
ref,
|
|
11
|
+
...props
|
|
12
|
+
});
|
|
12
13
|
});
|
|
13
14
|
|
|
14
|
-
|
|
15
|
+
//#endregion
|
|
16
|
+
export { CounterLabel$1 as CounterLabel };
|
|
@@ -1,32 +1,24 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
1
|
+
import { sx } from "../sx.js";
|
|
2
|
+
import styled from "styled-components";
|
|
3
|
+
import { jsx } from "react/jsx-runtime";
|
|
4
|
+
import { Table } from "@primer/react/experimental";
|
|
5
5
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
shouldForwardProp: prop => prop !== 'sx'
|
|
12
|
-
}).withConfig({
|
|
13
|
-
displayName: "DataTable__StyleDataTableContainer",
|
|
14
|
-
componentId: "sc-qy1ey2-0"
|
|
6
|
+
//#region src/components/DataTable.tsx
|
|
7
|
+
const { Container: PrimerDataTableContainer, ...rest } = Table;
|
|
8
|
+
const StyleDataTableContainer = styled(PrimerDataTableContainer).withConfig({ shouldForwardProp: (prop) => prop !== "sx" }).withConfig({
|
|
9
|
+
displayName: "DataTable__StyleDataTableContainer",
|
|
10
|
+
componentId: "sc-qy1ey2-0"
|
|
15
11
|
})(["", ""], sx);
|
|
16
|
-
function DataTableContainer({
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
...rest,
|
|
22
|
-
...(as ? {
|
|
23
|
-
forwardedAs: as
|
|
24
|
-
} : {})
|
|
25
|
-
});
|
|
12
|
+
function DataTableContainer({ as, ...rest$1 }) {
|
|
13
|
+
return /* @__PURE__ */ jsx(StyleDataTableContainer, {
|
|
14
|
+
...rest$1,
|
|
15
|
+
...as ? { forwardedAs: as } : {}
|
|
16
|
+
});
|
|
26
17
|
}
|
|
27
|
-
const Table = Object.assign(Table
|
|
28
|
-
|
|
29
|
-
|
|
18
|
+
const Table$1 = Object.assign(Table, {
|
|
19
|
+
Container: DataTableContainer,
|
|
20
|
+
...rest
|
|
30
21
|
});
|
|
31
22
|
|
|
32
|
-
|
|
23
|
+
//#endregion
|
|
24
|
+
export { Table$1 as Table };
|
|
@@ -1,90 +1,64 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import { forwardRef } from
|
|
5
|
-
import { jsx } from
|
|
1
|
+
import { sx } from "../sx.js";
|
|
2
|
+
import styled from "styled-components";
|
|
3
|
+
import { Dialog } from "@primer/react";
|
|
4
|
+
import { forwardRef } from "react";
|
|
5
|
+
import { jsx } from "react/jsx-runtime";
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
componentId: "sc-19zph8h-0"
|
|
7
|
+
//#region src/components/Dialog.tsx
|
|
8
|
+
const StyledDialog = styled(Dialog).withConfig({ shouldForwardProp: (prop) => prop !== "sx" }).withConfig({
|
|
9
|
+
displayName: "Dialog__StyledDialog",
|
|
10
|
+
componentId: "sc-19zph8h-0"
|
|
12
11
|
})(["", ""], sx);
|
|
13
|
-
const DialogImpl =
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
...(as ? {
|
|
20
|
-
forwardedAs: as
|
|
21
|
-
} : {}),
|
|
22
|
-
...props
|
|
23
|
-
});
|
|
12
|
+
const DialogImpl = /* @__PURE__ */ forwardRef(function Dialog$2({ as, ...props }, ref) {
|
|
13
|
+
return /* @__PURE__ */ jsx(StyledDialog, {
|
|
14
|
+
ref,
|
|
15
|
+
...as ? { forwardedAs: as } : {},
|
|
16
|
+
...props
|
|
17
|
+
});
|
|
24
18
|
});
|
|
25
|
-
const StyledDialogHeader = styled(Dialog
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
displayName: "Dialog__StyledDialogHeader",
|
|
29
|
-
componentId: "sc-19zph8h-1"
|
|
19
|
+
const StyledDialogHeader = styled(Dialog.Header).withConfig({ shouldForwardProp: (prop) => prop !== "sx" }).withConfig({
|
|
20
|
+
displayName: "Dialog__StyledDialogHeader",
|
|
21
|
+
componentId: "sc-19zph8h-1"
|
|
30
22
|
})(["", ""], sx);
|
|
31
|
-
const DialogHeader =
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
...(as ? {
|
|
38
|
-
forwardedAs: as
|
|
39
|
-
} : {}),
|
|
40
|
-
...props
|
|
41
|
-
});
|
|
23
|
+
const DialogHeader = /* @__PURE__ */ forwardRef(function DialogHeader$1({ as, ...props }, ref) {
|
|
24
|
+
return /* @__PURE__ */ jsx(StyledDialogHeader, {
|
|
25
|
+
ref,
|
|
26
|
+
...as ? { forwardedAs: as } : {},
|
|
27
|
+
...props
|
|
28
|
+
});
|
|
42
29
|
});
|
|
43
|
-
const StyledDialogBody = styled(Dialog
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
displayName: "Dialog__StyledDialogBody",
|
|
47
|
-
componentId: "sc-19zph8h-2"
|
|
30
|
+
const StyledDialogBody = styled(Dialog.Body).withConfig({ shouldForwardProp: (prop) => prop !== "sx" }).withConfig({
|
|
31
|
+
displayName: "Dialog__StyledDialogBody",
|
|
32
|
+
componentId: "sc-19zph8h-2"
|
|
48
33
|
})(["", ""], sx);
|
|
49
|
-
const DialogBody =
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
...(as ? {
|
|
56
|
-
forwardedAs: as
|
|
57
|
-
} : {}),
|
|
58
|
-
...props
|
|
59
|
-
});
|
|
34
|
+
const DialogBody = /* @__PURE__ */ forwardRef(function DialogBody$1({ as, ...props }, ref) {
|
|
35
|
+
return /* @__PURE__ */ jsx(StyledDialogBody, {
|
|
36
|
+
ref,
|
|
37
|
+
...as ? { forwardedAs: as } : {},
|
|
38
|
+
...props
|
|
39
|
+
});
|
|
60
40
|
});
|
|
61
|
-
const StyledDialogFooter = styled(Dialog
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
displayName: "Dialog__StyledDialogFooter",
|
|
65
|
-
componentId: "sc-19zph8h-3"
|
|
41
|
+
const StyledDialogFooter = styled(Dialog.Footer).withConfig({ shouldForwardProp: (prop) => prop !== "sx" }).withConfig({
|
|
42
|
+
displayName: "Dialog__StyledDialogFooter",
|
|
43
|
+
componentId: "sc-19zph8h-3"
|
|
66
44
|
})(["", ""], sx);
|
|
67
|
-
const DialogFooter =
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
...(as ? {
|
|
74
|
-
forwardedAs: as
|
|
75
|
-
} : {}),
|
|
76
|
-
...props
|
|
77
|
-
});
|
|
45
|
+
const DialogFooter = /* @__PURE__ */ forwardRef(function DialogFooter$1({ as, ...props }, ref) {
|
|
46
|
+
return /* @__PURE__ */ jsx(StyledDialogFooter, {
|
|
47
|
+
ref,
|
|
48
|
+
...as ? { forwardedAs: as } : {},
|
|
49
|
+
...props
|
|
50
|
+
});
|
|
78
51
|
});
|
|
79
|
-
DialogHeader.__SLOT__ = Dialog
|
|
80
|
-
DialogBody.__SLOT__ = Dialog
|
|
81
|
-
DialogFooter.__SLOT__ = Dialog
|
|
82
|
-
const Dialog = Object.assign(DialogImpl, {
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
52
|
+
DialogHeader.__SLOT__ = Dialog.Header.__SLOT__;
|
|
53
|
+
DialogBody.__SLOT__ = Dialog.Body.__SLOT__;
|
|
54
|
+
DialogFooter.__SLOT__ = Dialog.Footer.__SLOT__;
|
|
55
|
+
const Dialog$1 = Object.assign(DialogImpl, {
|
|
56
|
+
__SLOT__: Dialog["__SLOT__"],
|
|
57
|
+
Buttons: Dialog.Buttons,
|
|
58
|
+
Header: DialogHeader,
|
|
59
|
+
Body: DialogBody,
|
|
60
|
+
Footer: DialogFooter
|
|
88
61
|
});
|
|
89
62
|
|
|
90
|
-
|
|
63
|
+
//#endregion
|
|
64
|
+
export { Dialog$1 as Dialog };
|
package/dist/components/Flash.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import styled from
|
|
3
|
-
import
|
|
1
|
+
import { sx } from "../sx.js";
|
|
2
|
+
import styled from "styled-components";
|
|
3
|
+
import { Flash } from "@primer/react";
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
componentId: "sc-413izo-0"
|
|
5
|
+
//#region src/components/Flash.tsx
|
|
6
|
+
const Flash$1 = styled(Flash).withConfig({ shouldForwardProp: (prop) => prop !== "sx" }).withConfig({
|
|
7
|
+
displayName: "Flash",
|
|
8
|
+
componentId: "sc-413izo-0"
|
|
10
9
|
})(["", ""], sx);
|
|
11
10
|
|
|
12
|
-
|
|
11
|
+
//#endregion
|
|
12
|
+
export { Flash$1 as Flash };
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import styled from
|
|
3
|
-
import
|
|
1
|
+
import { sx } from "../sx.js";
|
|
2
|
+
import styled from "styled-components";
|
|
3
|
+
import { FormControl } from "@primer/react";
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
componentId: "sc-1642wfe-0"
|
|
5
|
+
//#region src/components/FormControl.tsx
|
|
6
|
+
const FormControlImpl = styled(FormControl).withConfig({ shouldForwardProp: (prop) => prop !== "sx" }).withConfig({
|
|
7
|
+
displayName: "FormControl__FormControlImpl",
|
|
8
|
+
componentId: "sc-1642wfe-0"
|
|
10
9
|
})(["", ""], sx);
|
|
11
|
-
const FormControl = Object.assign(FormControlImpl, {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
10
|
+
const FormControl$1 = Object.assign(FormControlImpl, {
|
|
11
|
+
__SLOT__: FormControl.__SLOT__,
|
|
12
|
+
Caption: FormControl.Caption,
|
|
13
|
+
LeadingVisual: FormControl.LeadingVisual,
|
|
14
|
+
Validation: FormControl.Validation,
|
|
15
|
+
Label: FormControl.Label
|
|
17
16
|
});
|
|
18
17
|
|
|
19
|
-
|
|
18
|
+
//#endregion
|
|
19
|
+
export { FormControl$1 as FormControl };
|