@seed-design/react 0.1.3 → 0.1.5
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/lib/components/ActionChip/ActionChip.d.ts +16 -0
- package/lib/components/ActionChip/ActionChip.d.ts.map +1 -1
- package/lib/components/ActionSheet/ActionSheet.d.ts +66 -0
- package/lib/components/ActionSheet/ActionSheet.d.ts.map +1 -1
- package/lib/components/Chip/Chip.cjs +39 -0
- package/lib/components/Chip/Chip.d.ts +19 -0
- package/lib/components/Chip/Chip.d.ts.map +1 -0
- package/lib/components/Chip/Chip.js +31 -0
- package/lib/components/Chip/Chip.namespace.cjs +12 -0
- package/lib/components/Chip/Chip.namespace.d.ts +2 -0
- package/lib/components/Chip/Chip.namespace.d.ts.map +1 -0
- package/lib/components/Chip/Chip.namespace.js +1 -0
- package/lib/components/Chip/index.cjs +15 -0
- package/lib/components/Chip/index.d.ts +3 -0
- package/lib/components/Chip/index.d.ts.map +1 -0
- package/lib/components/Chip/index.js +3 -0
- package/lib/components/ControlChip/ControlChip.cjs +1 -0
- package/lib/components/ControlChip/ControlChip.d.ts +19 -0
- package/lib/components/ControlChip/ControlChip.d.ts.map +1 -1
- package/lib/components/ControlChip/ControlChip.js +1 -0
- package/lib/components/ExtendedActionSheet/ExtendedActionSheet.d.ts +72 -0
- package/lib/components/ExtendedActionSheet/ExtendedActionSheet.d.ts.map +1 -1
- package/lib/components/MenuSheet/MenuSheet.cjs +119 -0
- package/lib/components/MenuSheet/MenuSheet.d.ts +42 -0
- package/lib/components/MenuSheet/MenuSheet.d.ts.map +1 -0
- package/lib/components/MenuSheet/MenuSheet.js +85 -0
- package/lib/components/MenuSheet/MenuSheet.namespace.cjs +20 -0
- package/lib/components/MenuSheet/MenuSheet.namespace.d.ts +2 -0
- package/lib/components/MenuSheet/MenuSheet.namespace.d.ts.map +1 -0
- package/lib/components/MenuSheet/MenuSheet.namespace.js +1 -0
- package/lib/components/MenuSheet/index.cjs +22 -0
- package/lib/components/MenuSheet/index.d.ts +3 -0
- package/lib/components/MenuSheet/index.d.ts.map +1 -0
- package/lib/components/MenuSheet/index.js +3 -0
- package/lib/components/index.cjs +23 -0
- package/lib/components/index.d.ts +2 -0
- package/lib/components/index.d.ts.map +1 -1
- package/lib/components/index.js +6 -0
- package/lib/index.cjs +23 -0
- package/lib/index.js +6 -0
- package/lib/utils/styled.cjs +10 -2
- package/lib/utils/styled.d.ts +5 -4
- package/lib/utils/styled.d.ts.map +1 -1
- package/lib/utils/styled.js +10 -3
- package/package.json +3 -3
- package/src/components/ActionChip/ActionChip.tsx +16 -0
- package/src/components/ActionSheet/ActionSheet.tsx +66 -0
- package/src/components/Chip/Chip.namespace.ts +10 -0
- package/src/components/Chip/Chip.tsx +57 -0
- package/src/components/Chip/index.ts +14 -0
- package/src/components/ControlChip/ControlChip.tsx +20 -0
- package/src/components/ExtendedActionSheet/ExtendedActionSheet.tsx +72 -0
- package/src/components/MenuSheet/MenuSheet.namespace.ts +26 -0
- package/src/components/MenuSheet/MenuSheet.tsx +172 -0
- package/src/components/MenuSheet/index.ts +28 -0
- package/src/components/index.ts +2 -0
- package/src/utils/styled.tsx +31 -6
|
@@ -1,7 +1,23 @@
|
|
|
1
1
|
import { ActionChipVariantProps } from '@seed-design/css/recipes/action-chip';
|
|
2
2
|
import { PrimitiveProps } from '@seed-design/react-primitive';
|
|
3
3
|
import type * as React from "react";
|
|
4
|
+
/**
|
|
5
|
+
* @deprecated ActionChip is deprecated. Use Chip.Button with variant="solid" instead.
|
|
6
|
+
*
|
|
7
|
+
* Migration guide:
|
|
8
|
+
* ```tsx
|
|
9
|
+
* // Before
|
|
10
|
+
* <ActionChip size="medium">Label</ActionChip>
|
|
11
|
+
*
|
|
12
|
+
* // After
|
|
13
|
+
* import { Chip } from "@seed-design/react";
|
|
14
|
+
* <Chip.Button size="medium" variant="solid">Label</Chip.Button>
|
|
15
|
+
* ```
|
|
16
|
+
*/
|
|
4
17
|
export interface ActionChipProps extends ActionChipVariantProps, PrimitiveProps, React.ButtonHTMLAttributes<HTMLButtonElement> {
|
|
5
18
|
}
|
|
19
|
+
/**
|
|
20
|
+
* @deprecated ActionChip is deprecated. Use Chip.Button with variant="solid" instead.
|
|
21
|
+
*/
|
|
6
22
|
export declare const ActionChip: React.ForwardRefExoticComponent<Omit<ActionChipProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
7
23
|
//# sourceMappingURL=ActionChip.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ActionChip.d.ts","sourceRoot":"","sources":["../../../src/components/ActionChip/ActionChip.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAc,KAAK,sBAAsB,EAAE,MAAM,sCAAsC,CAAC;AAC/F,OAAO,EAAa,KAAK,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC9E,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AAMpC,MAAM,WAAW,eACf,SAAQ,sBAAsB,EAC5B,cAAc,EACd,KAAK,CAAC,oBAAoB,CAAC,iBAAiB,CAAC;CAAG;AAEpD,eAAO,MAAM,UAAU,iJAGtB,CAAC"}
|
|
1
|
+
{"version":3,"file":"ActionChip.d.ts","sourceRoot":"","sources":["../../../src/components/ActionChip/ActionChip.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAc,KAAK,sBAAsB,EAAE,MAAM,sCAAsC,CAAC;AAC/F,OAAO,EAAa,KAAK,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC9E,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AAMpC;;;;;;;;;;;;GAYG;AACH,MAAM,WAAW,eACf,SAAQ,sBAAsB,EAC5B,cAAc,EACd,KAAK,CAAC,oBAAoB,CAAC,iBAAiB,CAAC;CAAG;AAEpD;;GAEG;AACH,eAAO,MAAM,UAAU,iJAGtB,CAAC"}
|
|
@@ -3,37 +3,103 @@ import { ActionSheetItemVariantProps } from '@seed-design/css/recipes/action-she
|
|
|
3
3
|
import { Dialog as DialogPrimitive } from '@seed-design/react-dialog';
|
|
4
4
|
import { PrimitiveProps } from '@seed-design/react-primitive';
|
|
5
5
|
import type * as React from "react";
|
|
6
|
+
/**
|
|
7
|
+
* @deprecated Use `MenuSheet` instead.
|
|
8
|
+
*/
|
|
6
9
|
export interface ActionSheetRootProps extends ActionSheetVariantProps, DialogPrimitive.RootProps {
|
|
7
10
|
}
|
|
11
|
+
/**
|
|
12
|
+
* @deprecated Use `MenuSheet` instead.
|
|
13
|
+
*/
|
|
8
14
|
export declare const ActionSheetRoot: React.ForwardRefExoticComponent<ActionSheetRootProps>;
|
|
15
|
+
/**
|
|
16
|
+
* @deprecated Use `MenuSheet` instead.
|
|
17
|
+
*/
|
|
9
18
|
export interface ActionSheetTriggerProps extends DialogPrimitive.TriggerProps {
|
|
10
19
|
}
|
|
20
|
+
/**
|
|
21
|
+
* @deprecated Use `MenuSheet` instead.
|
|
22
|
+
*/
|
|
11
23
|
export declare const ActionSheetTrigger: React.ForwardRefExoticComponent<DialogPrimitive.TriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
24
|
+
/**
|
|
25
|
+
* @deprecated Use `MenuSheet` instead.
|
|
26
|
+
*/
|
|
12
27
|
export interface ActionSheetPositionerProps extends DialogPrimitive.PositionerProps {
|
|
13
28
|
}
|
|
29
|
+
/**
|
|
30
|
+
* @deprecated Use `MenuSheet` instead.
|
|
31
|
+
*/
|
|
14
32
|
export declare const ActionSheetPositioner: React.ForwardRefExoticComponent<ActionSheetPositionerProps & React.RefAttributes<HTMLDivElement>>;
|
|
33
|
+
/**
|
|
34
|
+
* @deprecated Use `MenuSheet` instead.
|
|
35
|
+
*/
|
|
15
36
|
export interface ActionSheetBackdropProps extends DialogPrimitive.BackdropProps {
|
|
16
37
|
}
|
|
38
|
+
/**
|
|
39
|
+
* @deprecated Use `MenuSheet` instead.
|
|
40
|
+
*/
|
|
17
41
|
export declare const ActionSheetBackdrop: React.ForwardRefExoticComponent<ActionSheetBackdropProps & React.RefAttributes<HTMLDivElement>>;
|
|
42
|
+
/**
|
|
43
|
+
* @deprecated Use `MenuSheet` instead.
|
|
44
|
+
*/
|
|
18
45
|
export interface ActionSheetContentProps extends DialogPrimitive.ContentProps {
|
|
19
46
|
}
|
|
47
|
+
/**
|
|
48
|
+
* @deprecated Use `MenuSheet` instead.
|
|
49
|
+
*/
|
|
20
50
|
export declare const ActionSheetContent: React.ForwardRefExoticComponent<ActionSheetContentProps & React.RefAttributes<HTMLDivElement>>;
|
|
51
|
+
/**
|
|
52
|
+
* @deprecated Use `MenuSheet` instead.
|
|
53
|
+
*/
|
|
21
54
|
export interface ActionSheetHeaderProps extends PrimitiveProps, React.HTMLAttributes<HTMLDivElement> {
|
|
22
55
|
}
|
|
56
|
+
/**
|
|
57
|
+
* @deprecated Use `MenuSheet` instead.
|
|
58
|
+
*/
|
|
23
59
|
export declare const ActionSheetHeader: React.ForwardRefExoticComponent<ActionSheetHeaderProps & React.RefAttributes<HTMLDivElement>>;
|
|
60
|
+
/**
|
|
61
|
+
* @deprecated Use `MenuSheet` instead.
|
|
62
|
+
*/
|
|
24
63
|
export interface ActionSheetTitleProps extends DialogPrimitive.TitleProps {
|
|
25
64
|
}
|
|
65
|
+
/**
|
|
66
|
+
* @deprecated Use `MenuSheet` instead.
|
|
67
|
+
*/
|
|
26
68
|
export declare const ActionSheetTitle: React.ForwardRefExoticComponent<ActionSheetTitleProps & React.RefAttributes<HTMLHeadingElement>>;
|
|
69
|
+
/**
|
|
70
|
+
* @deprecated Use `MenuSheet` instead.
|
|
71
|
+
*/
|
|
27
72
|
export interface ActionSheetDescriptionProps extends DialogPrimitive.DescriptionProps {
|
|
28
73
|
}
|
|
74
|
+
/**
|
|
75
|
+
* @deprecated Use `MenuSheet` instead.
|
|
76
|
+
*/
|
|
29
77
|
export declare const ActionSheetDescription: React.ForwardRefExoticComponent<ActionSheetDescriptionProps & React.RefAttributes<HTMLParagraphElement>>;
|
|
78
|
+
/**
|
|
79
|
+
* @deprecated Use `MenuSheet` instead.
|
|
80
|
+
*/
|
|
30
81
|
export interface ActionSheetListProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
31
82
|
}
|
|
83
|
+
/**
|
|
84
|
+
* @deprecated Use `MenuSheet` instead.
|
|
85
|
+
*/
|
|
32
86
|
export declare const ActionSheetList: React.ForwardRefExoticComponent<ActionSheetListProps & React.RefAttributes<HTMLDivElement>>;
|
|
87
|
+
/**
|
|
88
|
+
* @deprecated Use `MenuSheet` instead.
|
|
89
|
+
*/
|
|
33
90
|
export interface ActionSheetItemProps extends PrimitiveProps, ActionSheetItemVariantProps, React.HTMLAttributes<HTMLButtonElement> {
|
|
34
91
|
}
|
|
92
|
+
/**
|
|
93
|
+
* @deprecated Use `MenuSheet` instead.
|
|
94
|
+
*/
|
|
35
95
|
export declare const ActionSheetItem: React.ForwardRefExoticComponent<ActionSheetItemProps & React.RefAttributes<HTMLButtonElement>>;
|
|
96
|
+
/**
|
|
97
|
+
* @deprecated Use `MenuSheet` instead.
|
|
98
|
+
*/
|
|
36
99
|
export interface ActionSheetCloseButtonProps extends DialogPrimitive.CloseButtonProps {
|
|
37
100
|
}
|
|
101
|
+
/**
|
|
102
|
+
* @deprecated Use `MenuSheet` instead.
|
|
103
|
+
*/
|
|
38
104
|
export declare const ActionSheetCloseButton: React.ForwardRefExoticComponent<ActionSheetCloseButtonProps & React.RefAttributes<HTMLDivElement>>;
|
|
39
105
|
//# sourceMappingURL=ActionSheet.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ActionSheet.d.ts","sourceRoot":"","sources":["../../../src/components/ActionSheet/ActionSheet.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAe,KAAK,uBAAuB,EAAE,MAAM,uCAAuC,CAAC;AAClG,OAAO,EAEL,KAAK,2BAA2B,EACjC,MAAM,4CAA4C,CAAC;AACpD,OAAO,EAAE,MAAM,IAAI,eAAe,EAAo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H,eAAO,MAAM,iBAAiB,+FAG7B,CAAC;AAIF;;GAEG;AACH,MAAM,WAAW,qBAAsB,SAAQ,eAAe,CAAC,UAAU;CAAG;AAE5E;;GAEG;AACH,eAAO,MAAM,gBAAgB,kGAG5B,CAAC;AAIF;;GAEG;AACH,MAAM,WAAW,2BAA4B,SAAQ,eAAe,CAAC,gBAAgB;CAAG;AAExF;;GAEG;AACH,eAAO,MAAM,sBAAsB,0GAGU,CAAC;AAI9C;;GAEG;AACH,MAAM,WAAW,oBAAqB,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;CAAG;AAErF;;GAEG;AACH,eAAO,MAAM,eAAe,6FAG3B,CAAC;AAIF;;GAEG;AACH,MAAM,WAAW,oBACf,SAAQ,cAAc,EACpB,2BAA2B,EAC3B,KAAK,CAAC,cAAc,CAAC,iBAAiB,CAAC;CAAG;AAE9C;;GAEG;AACH,eAAO,MAAM,eAAe,gGAE3B,CAAC;AAIF;;GAEG;AACH,MAAM,WAAW,2BAA4B,SAAQ,eAAe,CAAC,gBAAgB;CAAG;AAExF;;GAEG;AACH,eAAO,MAAM,sBAAsB,oGAGlC,CAAC"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
'use strict';
|
|
3
|
+
|
|
4
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
5
|
+
|
|
6
|
+
const chip = require('@seed-design/css/recipes/chip');
|
|
7
|
+
const reactPrimitive = require('@seed-design/react-primitive');
|
|
8
|
+
const createSlotRecipeContext = require('../../utils/createSlotRecipeContext.cjs');
|
|
9
|
+
const Icon = require('../Icon/Icon.cjs');
|
|
10
|
+
|
|
11
|
+
const { withProvider, withContext } = createSlotRecipeContext.createSlotRecipeContext(chip.chip);
|
|
12
|
+
const ChipRoot = Icon.withIconRequired(
|
|
13
|
+
withProvider(reactPrimitive.Primitive.button, "root"),
|
|
14
|
+
(props) => props.layout === "iconOnly"
|
|
15
|
+
);
|
|
16
|
+
ChipRoot.displayName = "Chip.Root";
|
|
17
|
+
const ChipLabel = withContext(reactPrimitive.Primitive.span, "label");
|
|
18
|
+
ChipLabel.displayName = "Chip.Label";
|
|
19
|
+
const ChipPrefixIcon = withContext(
|
|
20
|
+
reactPrimitive.Primitive.div,
|
|
21
|
+
"prefixIcon"
|
|
22
|
+
);
|
|
23
|
+
ChipPrefixIcon.displayName = "Chip.PrefixIcon";
|
|
24
|
+
const ChipPrefixAvatar = withContext(
|
|
25
|
+
reactPrimitive.Primitive.div,
|
|
26
|
+
"prefixAvatar"
|
|
27
|
+
);
|
|
28
|
+
ChipPrefixAvatar.displayName = "Chip.PrefixAvatar";
|
|
29
|
+
const ChipSuffixIcon = withContext(
|
|
30
|
+
reactPrimitive.Primitive.div,
|
|
31
|
+
"suffixIcon"
|
|
32
|
+
);
|
|
33
|
+
ChipSuffixIcon.displayName = "Chip.SuffixIcon";
|
|
34
|
+
|
|
35
|
+
exports.ChipLabel = ChipLabel;
|
|
36
|
+
exports.ChipPrefixAvatar = ChipPrefixAvatar;
|
|
37
|
+
exports.ChipPrefixIcon = ChipPrefixIcon;
|
|
38
|
+
exports.ChipRoot = ChipRoot;
|
|
39
|
+
exports.ChipSuffixIcon = ChipSuffixIcon;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { ChipVariantProps } from '@seed-design/css/recipes/chip';
|
|
2
|
+
import { PrimitiveProps } from '@seed-design/react-primitive';
|
|
3
|
+
import type * as React from "react";
|
|
4
|
+
export interface ChipRootProps extends PrimitiveProps, ChipVariantProps, React.ButtonHTMLAttributes<HTMLButtonElement> {
|
|
5
|
+
}
|
|
6
|
+
export declare const ChipRoot: React.ForwardRefExoticComponent<Omit<ChipRootProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
7
|
+
export interface ChipLabelProps extends PrimitiveProps, React.HTMLAttributes<HTMLSpanElement> {
|
|
8
|
+
}
|
|
9
|
+
export declare const ChipLabel: React.ForwardRefExoticComponent<ChipLabelProps & React.RefAttributes<HTMLSpanElement>>;
|
|
10
|
+
export interface ChipPrefixIconProps extends PrimitiveProps, React.HTMLAttributes<HTMLDivElement> {
|
|
11
|
+
}
|
|
12
|
+
export declare const ChipPrefixIcon: React.ForwardRefExoticComponent<ChipPrefixIconProps & React.RefAttributes<HTMLDivElement>>;
|
|
13
|
+
export interface ChipPrefixAvatarProps extends PrimitiveProps, React.HTMLAttributes<HTMLDivElement> {
|
|
14
|
+
}
|
|
15
|
+
export declare const ChipPrefixAvatar: React.ForwardRefExoticComponent<ChipPrefixAvatarProps & React.RefAttributes<HTMLDivElement>>;
|
|
16
|
+
export interface ChipSuffixIconProps extends PrimitiveProps, React.HTMLAttributes<HTMLDivElement> {
|
|
17
|
+
}
|
|
18
|
+
export declare const ChipSuffixIcon: React.ForwardRefExoticComponent<ChipSuffixIconProps & React.RefAttributes<HTMLDivElement>>;
|
|
19
|
+
//# sourceMappingURL=Chip.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Chip.d.ts","sourceRoot":"","sources":["../../../src/components/Chip/Chip.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAQ,KAAK,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AAC5E,OAAO,EAAa,KAAK,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC9E,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AAQpC,MAAM,WAAW,aACf,SAAQ,cAAc,EACpB,gBAAgB,EAChB,KAAK,CAAC,oBAAoB,CAAC,iBAAiB,CAAC;CAAG;AAEpD,eAAO,MAAM,QAAQ,+IAGpB,CAAC;AAKF,MAAM,WAAW,cAAe,SAAQ,cAAc,EAAE,KAAK,CAAC,cAAc,CAAC,eAAe,CAAC;CAAG;AAEhG,eAAO,MAAM,SAAS,wFAAwE,CAAC;AAK/F,MAAM,WAAW,mBAAoB,SAAQ,cAAc,EAAE,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;CAAG;AACpG,eAAO,MAAM,cAAc,4FAG1B,CAAC;AAKF,MAAM,WAAW,qBACf,SAAQ,cAAc,EACpB,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;CAAG;AAE3C,eAAO,MAAM,gBAAgB,8FAG5B,CAAC;AAKF,MAAM,WAAW,mBAAoB,SAAQ,cAAc,EAAE,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;CAAG;AACpG,eAAO,MAAM,cAAc,4FAG1B,CAAC"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
import { chip } from '@seed-design/css/recipes/chip';
|
|
3
|
+
import { Primitive } from '@seed-design/react-primitive';
|
|
4
|
+
import { createSlotRecipeContext } from '../../utils/createSlotRecipeContext.js';
|
|
5
|
+
import { withIconRequired } from '../Icon/Icon.js';
|
|
6
|
+
|
|
7
|
+
const { withProvider, withContext } = createSlotRecipeContext(chip);
|
|
8
|
+
const ChipRoot = withIconRequired(
|
|
9
|
+
withProvider(Primitive.button, "root"),
|
|
10
|
+
(props) => props.layout === "iconOnly"
|
|
11
|
+
);
|
|
12
|
+
ChipRoot.displayName = "Chip.Root";
|
|
13
|
+
const ChipLabel = withContext(Primitive.span, "label");
|
|
14
|
+
ChipLabel.displayName = "Chip.Label";
|
|
15
|
+
const ChipPrefixIcon = withContext(
|
|
16
|
+
Primitive.div,
|
|
17
|
+
"prefixIcon"
|
|
18
|
+
);
|
|
19
|
+
ChipPrefixIcon.displayName = "Chip.PrefixIcon";
|
|
20
|
+
const ChipPrefixAvatar = withContext(
|
|
21
|
+
Primitive.div,
|
|
22
|
+
"prefixAvatar"
|
|
23
|
+
);
|
|
24
|
+
ChipPrefixAvatar.displayName = "Chip.PrefixAvatar";
|
|
25
|
+
const ChipSuffixIcon = withContext(
|
|
26
|
+
Primitive.div,
|
|
27
|
+
"suffixIcon"
|
|
28
|
+
);
|
|
29
|
+
ChipSuffixIcon.displayName = "Chip.SuffixIcon";
|
|
30
|
+
|
|
31
|
+
export { ChipLabel, ChipPrefixAvatar, ChipPrefixIcon, ChipRoot, ChipSuffixIcon };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
4
|
+
|
|
5
|
+
const Chip = require('./Chip.cjs');
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
exports.Label = Chip.ChipLabel;
|
|
10
|
+
exports.PrefixAvatar = Chip.ChipPrefixAvatar;
|
|
11
|
+
exports.PrefixIcon = Chip.ChipPrefixIcon;
|
|
12
|
+
exports.SuffixIcon = Chip.ChipSuffixIcon;
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
export { ChipLabel as Label, ChipPrefixIcon as PrefixIcon, ChipPrefixAvatar as PrefixAvatar, ChipSuffixIcon as SuffixIcon, type ChipLabelProps as LabelProps, type ChipPrefixIconProps as PrefixIconProps, type ChipPrefixAvatarProps as PrefixAvatarProps, type ChipSuffixIconProps as SuffixIconProps, } from './Chip';
|
|
2
|
+
//# sourceMappingURL=Chip.namespace.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Chip.namespace.d.ts","sourceRoot":"","sources":["../../../src/components/Chip/Chip.namespace.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,IAAI,KAAK,EAClB,cAAc,IAAI,UAAU,EAC5B,gBAAgB,IAAI,YAAY,EAChC,cAAc,IAAI,UAAU,EAC5B,KAAK,cAAc,IAAI,UAAU,EACjC,KAAK,mBAAmB,IAAI,eAAe,EAC3C,KAAK,qBAAqB,IAAI,iBAAiB,EAC/C,KAAK,mBAAmB,IAAI,eAAe,GAC5C,MAAM,QAAQ,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { ChipLabel as Label, ChipPrefixAvatar as PrefixAvatar, ChipPrefixIcon as PrefixIcon, ChipSuffixIcon as SuffixIcon } from './Chip.js';
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
4
|
+
|
|
5
|
+
const Chip = require('./Chip.cjs');
|
|
6
|
+
const Chip_namespace = require('./Chip.namespace.cjs');
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
exports.ChipLabel = Chip.ChipLabel;
|
|
11
|
+
exports.ChipPrefixAvatar = Chip.ChipPrefixAvatar;
|
|
12
|
+
exports.ChipPrefixIcon = Chip.ChipPrefixIcon;
|
|
13
|
+
exports.ChipRoot = Chip.ChipRoot;
|
|
14
|
+
exports.ChipSuffixIcon = Chip.ChipSuffixIcon;
|
|
15
|
+
exports.Chip = Chip_namespace;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
export { ChipRoot, ChipLabel, ChipPrefixIcon, ChipPrefixAvatar, ChipSuffixIcon, type ChipRootProps, type ChipLabelProps, type ChipPrefixIconProps, type ChipPrefixAvatarProps, type ChipSuffixIconProps, } from './Chip';
|
|
2
|
+
export * as Chip from './Chip.namespace';
|
|
3
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Chip/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EACR,SAAS,EACT,cAAc,EACd,gBAAgB,EAChB,cAAc,EACd,KAAK,aAAa,EAClB,KAAK,cAAc,EACnB,KAAK,mBAAmB,EACxB,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,GACzB,MAAM,QAAQ,CAAC;AAEhB,OAAO,KAAK,IAAI,MAAM,kBAAkB,CAAC"}
|
|
@@ -1,9 +1,28 @@
|
|
|
1
1
|
import { ControlChipVariantProps } from '@seed-design/css/recipes/control-chip';
|
|
2
2
|
import { PrimitiveProps } from '@seed-design/react-primitive';
|
|
3
3
|
import type * as React from "react";
|
|
4
|
+
/**
|
|
5
|
+
* @deprecated ControlChipBaseProps is deprecated. Use ChipBaseProps from Chip instead.
|
|
6
|
+
*/
|
|
4
7
|
export interface ControlChipBaseProps extends PrimitiveProps, ControlChipVariantProps {
|
|
5
8
|
}
|
|
9
|
+
/**
|
|
10
|
+
* @deprecated ControlChipProps is deprecated. Use Chip.Toggle or Chip.Button instead.
|
|
11
|
+
*
|
|
12
|
+
* Migration guide:
|
|
13
|
+
* ```tsx
|
|
14
|
+
* // Before
|
|
15
|
+
* <ControlChip size="medium">Label</ControlChip>
|
|
16
|
+
*
|
|
17
|
+
* // After
|
|
18
|
+
* import { Chip } from "@seed-design/react";
|
|
19
|
+
* <Chip.Toggle size="medium" variant="outlineStrong">Label</Chip.Toggle>
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
6
22
|
export interface ControlChipProps extends ControlChipBaseProps, React.HTMLAttributes<HTMLButtonElement> {
|
|
7
23
|
}
|
|
24
|
+
/**
|
|
25
|
+
* @deprecated ControlChip is deprecated. Use Chip.Toggle or Chip.Button instead.
|
|
26
|
+
*/
|
|
8
27
|
export declare const ControlChip: React.ForwardRefExoticComponent<Omit<ControlChipProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
9
28
|
//# sourceMappingURL=ControlChip.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ControlChip.d.ts","sourceRoot":"","sources":["../../../src/components/ControlChip/ControlChip.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAe,KAAK,uBAAuB,EAAE,MAAM,uCAAuC,CAAC;AAClG,OAAO,EAAa,KAAK,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC9E,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AAMpC,MAAM,WAAW,oBAAqB,SAAQ,cAAc,EAAE,uBAAuB;CAAG;AAExF,MAAM,WAAW,gBACf,SAAQ,oBAAoB,EAC1B,KAAK,CAAC,cAAc,CAAC,iBAAiB,CAAC;CAAG;AAE9C,eAAO,MAAM,WAAW,kJAGvB,CAAC"}
|
|
1
|
+
{"version":3,"file":"ControlChip.d.ts","sourceRoot":"","sources":["../../../src/components/ControlChip/ControlChip.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAe,KAAK,uBAAuB,EAAE,MAAM,uCAAuC,CAAC;AAClG,OAAO,EAAa,KAAK,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC9E,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AAMpC;;GAEG;AACH,MAAM,WAAW,oBAAqB,SAAQ,cAAc,EAAE,uBAAuB;CAAG;AAExF;;;;;;;;;;;;GAYG;AACH,MAAM,WAAW,gBACf,SAAQ,oBAAoB,EAC1B,KAAK,CAAC,cAAc,CAAC,iBAAiB,CAAC;CAAG;AAE9C;;GAEG;AACH,eAAO,MAAM,WAAW,kJAGvB,CAAC"}
|
|
@@ -3,40 +3,112 @@ import { PrimitiveProps } from '@seed-design/react-primitive';
|
|
|
3
3
|
import { ExtendedActionSheetVariantProps } from '@seed-design/css/recipes/extended-action-sheet';
|
|
4
4
|
import { ExtendedActionSheetItemVariantProps } from '@seed-design/css/recipes/extended-action-sheet-item';
|
|
5
5
|
import type * as React from "react";
|
|
6
|
+
/**
|
|
7
|
+
* @deprecated Use `MenuSheet` instead.
|
|
8
|
+
*/
|
|
6
9
|
export interface ExtendedActionSheetRootProps extends ExtendedActionSheetVariantProps, DialogPrimitive.RootProps {
|
|
7
10
|
}
|
|
11
|
+
/**
|
|
12
|
+
* @deprecated Use `MenuSheet` instead.
|
|
13
|
+
*/
|
|
8
14
|
export declare const ExtendedActionSheetRoot: React.ForwardRefExoticComponent<ExtendedActionSheetRootProps>;
|
|
15
|
+
/**
|
|
16
|
+
* @deprecated Use `MenuSheet` instead.
|
|
17
|
+
*/
|
|
9
18
|
export interface ExtendedActionSheetTriggerProps extends DialogPrimitive.TriggerProps {
|
|
10
19
|
}
|
|
20
|
+
/**
|
|
21
|
+
* @deprecated Use `MenuSheet` instead.
|
|
22
|
+
*/
|
|
11
23
|
export declare const ExtendedActionSheetTrigger: React.ForwardRefExoticComponent<DialogPrimitive.TriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
24
|
+
/**
|
|
25
|
+
* @deprecated Use `MenuSheet` instead.
|
|
26
|
+
*/
|
|
12
27
|
export interface ExtendedActionSheetPositionerProps extends DialogPrimitive.PositionerProps {
|
|
13
28
|
}
|
|
29
|
+
/**
|
|
30
|
+
* @deprecated Use `MenuSheet` instead.
|
|
31
|
+
*/
|
|
14
32
|
export declare const ExtendedActionSheetPositioner: React.ForwardRefExoticComponent<ExtendedActionSheetPositionerProps & React.RefAttributes<HTMLDivElement>>;
|
|
33
|
+
/**
|
|
34
|
+
* @deprecated Use `MenuSheet` instead.
|
|
35
|
+
*/
|
|
15
36
|
export interface ExtendedActionSheetBackdropProps extends DialogPrimitive.BackdropProps {
|
|
16
37
|
}
|
|
38
|
+
/**
|
|
39
|
+
* @deprecated Use `MenuSheet` instead.
|
|
40
|
+
*/
|
|
17
41
|
export declare const ExtendedActionSheetBackdrop: React.ForwardRefExoticComponent<ExtendedActionSheetBackdropProps & React.RefAttributes<HTMLDivElement>>;
|
|
42
|
+
/**
|
|
43
|
+
* @deprecated Use `MenuSheet` instead.
|
|
44
|
+
*/
|
|
18
45
|
export interface ExtendedActionSheetContentProps extends DialogPrimitive.ContentProps {
|
|
19
46
|
}
|
|
47
|
+
/**
|
|
48
|
+
* @deprecated Use `MenuSheet` instead.
|
|
49
|
+
*/
|
|
20
50
|
export declare const ExtendedActionSheetContent: React.ForwardRefExoticComponent<ExtendedActionSheetContentProps & React.RefAttributes<HTMLDivElement>>;
|
|
51
|
+
/**
|
|
52
|
+
* @deprecated Use `MenuSheet` instead.
|
|
53
|
+
*/
|
|
21
54
|
export interface ExtendedActionSheetHeaderProps extends PrimitiveProps, React.HTMLAttributes<HTMLDivElement> {
|
|
22
55
|
}
|
|
56
|
+
/**
|
|
57
|
+
* @deprecated Use `MenuSheet` instead.
|
|
58
|
+
*/
|
|
23
59
|
export declare const ExtendedActionSheetHeader: React.ForwardRefExoticComponent<ExtendedActionSheetHeaderProps & React.RefAttributes<HTMLDivElement>>;
|
|
60
|
+
/**
|
|
61
|
+
* @deprecated Use `MenuSheet` instead.
|
|
62
|
+
*/
|
|
24
63
|
export interface ExtendedActionSheetTitleProps extends DialogPrimitive.TitleProps {
|
|
25
64
|
}
|
|
65
|
+
/**
|
|
66
|
+
* @deprecated Use `MenuSheet` instead.
|
|
67
|
+
*/
|
|
26
68
|
export declare const ExtendedActionSheetTitle: React.ForwardRefExoticComponent<ExtendedActionSheetTitleProps & React.RefAttributes<HTMLHeadingElement>>;
|
|
69
|
+
/**
|
|
70
|
+
* @deprecated Use `MenuSheet` instead.
|
|
71
|
+
*/
|
|
27
72
|
export interface ExtendedActionSheetListProps extends PrimitiveProps, React.HTMLAttributes<HTMLDivElement> {
|
|
28
73
|
}
|
|
74
|
+
/**
|
|
75
|
+
* @deprecated Use `MenuSheet` instead.
|
|
76
|
+
*/
|
|
29
77
|
export declare const ExtendedActionSheetList: React.ForwardRefExoticComponent<ExtendedActionSheetListProps & React.RefAttributes<HTMLDivElement>>;
|
|
78
|
+
/**
|
|
79
|
+
* @deprecated Use `MenuSheet` instead.
|
|
80
|
+
*/
|
|
30
81
|
export interface ExtendedActionSheetGroupProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
31
82
|
}
|
|
83
|
+
/**
|
|
84
|
+
* @deprecated Use `MenuSheet` instead.
|
|
85
|
+
*/
|
|
32
86
|
export declare const ExtendedActionSheetGroup: React.ForwardRefExoticComponent<ExtendedActionSheetGroupProps & React.RefAttributes<HTMLDivElement>>;
|
|
87
|
+
/**
|
|
88
|
+
* @deprecated Use `MenuSheet` instead.
|
|
89
|
+
*/
|
|
33
90
|
export interface ExtendedActionSheetItemProps extends PrimitiveProps, ExtendedActionSheetItemVariantProps, React.HTMLAttributes<HTMLButtonElement> {
|
|
34
91
|
}
|
|
92
|
+
/**
|
|
93
|
+
* @deprecated Use `MenuSheet` instead.
|
|
94
|
+
*/
|
|
35
95
|
export declare const ExtendedActionSheetItem: React.ForwardRefExoticComponent<ExtendedActionSheetItemProps & React.RefAttributes<HTMLButtonElement>>;
|
|
96
|
+
/**
|
|
97
|
+
* @deprecated Use `MenuSheet` instead.
|
|
98
|
+
*/
|
|
36
99
|
export interface ExtendedActionSheetFooterProps extends PrimitiveProps, React.HTMLAttributes<HTMLDivElement> {
|
|
37
100
|
}
|
|
101
|
+
/**
|
|
102
|
+
* @deprecated Use `MenuSheet` instead.
|
|
103
|
+
*/
|
|
38
104
|
export declare const ExtendedActionSheetFooter: React.ForwardRefExoticComponent<ExtendedActionSheetFooterProps & React.RefAttributes<HTMLDivElement>>;
|
|
105
|
+
/**
|
|
106
|
+
* @deprecated Use `MenuSheet` instead.
|
|
107
|
+
*/
|
|
39
108
|
export interface ExtendedActionSheetCloseButtonProps extends DialogPrimitive.CloseButtonProps {
|
|
40
109
|
}
|
|
110
|
+
/**
|
|
111
|
+
* @deprecated Use `MenuSheet` instead.
|
|
112
|
+
*/
|
|
41
113
|
export declare const ExtendedActionSheetCloseButton: React.ForwardRefExoticComponent<ExtendedActionSheetCloseButtonProps & React.RefAttributes<HTMLDivElement>>;
|
|
42
114
|
//# sourceMappingURL=ExtendedActionSheet.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ExtendedActionSheet.d.ts","sourceRoot":"","sources":["../../../src/components/ExtendedActionSheet/ExtendedActionSheet.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,IAAI,eAAe,EAAoB,MAAM,2BAA2B,CAAC;AACxF,OAAO,EAAa,KAAK,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC9E,OAAO,EAEL,KAAK,+BAA+B,EACrC,MAAM,gDAAgD,CAAC;AACxD,OAAO,EAEL,KAAK,mCAAmC,E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;AAItC;;GAEG;AACH,MAAM,WAAW,8BACf,SAAQ,cAAc,EACpB,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;CAAG;AAE3C;;GAEG;AACH,eAAO,MAAM,yBAAyB,uGAGI,CAAC;AAI3C;;GAEG;AACH,MAAM,WAAW,6BAA8B,SAAQ,eAAe,CAAC,UAAU;CAAG;AAEpF;;GAEG;AACH,eAAO,MAAM,wBAAwB,0GAGG,CAAC;AAIzC;;GAEG;AACH,MAAM,WAAW,4BACf,SAAQ,cAAc,EACpB,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;CAAG;AAE3C;;GAEG;AACH,eAAO,MAAM,uBAAuB,qGAGnC,CAAC;AAIF;;GAEG;AACH,MAAM,WAAW,6BAA8B,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;CAAG;AAE9F;;GAEG;AACH,eAAO,MAAM,wBAAwB,sGAGpC,CAAC;AAIF;;GAEG;AACH,MAAM,WAAW,4BACf,SAAQ,cAAc,EACpB,mCAAmC,EACnC,KAAK,CAAC,cAAc,CAAC,iBAAiB,CAAC;CAAG;AAE9C;;GAEG;AACH,eAAO,MAAM,uBAAuB,wGAGD,CAAC;AAIpC;;GAEG;AACH,MAAM,WAAW,8BACf,SAAQ,cAAc,EACpB,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;CAAG;AAE3C;;GAEG;AACH,eAAO,MAAM,yBAAyB,uGAGI,CAAC;AAI3C;;GAEG;AACH,MAAM,WAAW,mCAAoC,SAAQ,eAAe,CAAC,gBAAgB;CAAG;AAEhG;;GAEG;AACH,eAAO,MAAM,8BAA8B,4GAGE,CAAC"}
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
'use strict';
|
|
3
|
+
|
|
4
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
5
|
+
|
|
6
|
+
const jsxRuntime = require('react/jsx-runtime');
|
|
7
|
+
const reactDialog = require('@seed-design/react-dialog');
|
|
8
|
+
const reactPrimitive = require('@seed-design/react-primitive');
|
|
9
|
+
const menuSheet = require('@seed-design/css/recipes/menu-sheet');
|
|
10
|
+
const menuSheetItem = require('@seed-design/css/recipes/menu-sheet-item');
|
|
11
|
+
const React = require('react');
|
|
12
|
+
const createRecipeContext = require('../../utils/createRecipeContext.cjs');
|
|
13
|
+
const createSlotRecipeContext = require('../../utils/createSlotRecipeContext.cjs');
|
|
14
|
+
const createWithStateProps = require('../../utils/createWithStateProps.cjs');
|
|
15
|
+
|
|
16
|
+
function _interopNamespaceDefault(e) {
|
|
17
|
+
const n = Object.create(null, { [Symbol.toStringTag]: { value: 'Module' } });
|
|
18
|
+
if (e) {
|
|
19
|
+
for (const k in e) {
|
|
20
|
+
if (k !== 'default') {
|
|
21
|
+
const d = Object.getOwnPropertyDescriptor(e, k);
|
|
22
|
+
Object.defineProperty(n, k, d.get ? d : {
|
|
23
|
+
enumerable: true,
|
|
24
|
+
get: () => e[k]
|
|
25
|
+
});
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
n.default = e;
|
|
30
|
+
return Object.freeze(n);
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
const React__namespace = /*#__PURE__*/_interopNamespaceDefault(React);
|
|
34
|
+
|
|
35
|
+
const { withRootProvider, withContext } = createSlotRecipeContext.createSlotRecipeContext(menuSheet.menuSheet);
|
|
36
|
+
const {
|
|
37
|
+
withContext: withItemContext,
|
|
38
|
+
PropsProvider: ItemPropsProvider,
|
|
39
|
+
useProps: useItemProps
|
|
40
|
+
} = createRecipeContext.createRecipeContext(menuSheetItem.menuSheetItem);
|
|
41
|
+
const withStateProps = createWithStateProps.createWithStateProps([reactDialog.useDialogContext]);
|
|
42
|
+
const MenuSheetRoot = withRootProvider(reactDialog.Dialog.Root, {
|
|
43
|
+
defaultProps: {
|
|
44
|
+
lazyMount: true,
|
|
45
|
+
unmountOnExit: true
|
|
46
|
+
}
|
|
47
|
+
});
|
|
48
|
+
const MenuSheetTrigger = reactDialog.Dialog.Trigger;
|
|
49
|
+
const MenuSheetPositioner = withContext(
|
|
50
|
+
reactDialog.Dialog.Positioner,
|
|
51
|
+
"positioner"
|
|
52
|
+
);
|
|
53
|
+
const MenuSheetBackdrop = withContext(
|
|
54
|
+
reactDialog.Dialog.Backdrop,
|
|
55
|
+
"backdrop"
|
|
56
|
+
);
|
|
57
|
+
const MenuSheetContentBase = withContext(
|
|
58
|
+
reactDialog.Dialog.Content,
|
|
59
|
+
"content"
|
|
60
|
+
);
|
|
61
|
+
const MenuSheetContent = React__namespace.forwardRef(
|
|
62
|
+
({ labelAlign, children, ...props }, ref) => {
|
|
63
|
+
return /* @__PURE__ */ jsxRuntime.jsx(ItemPropsProvider, { value: React__namespace.useMemo(() => ({ labelAlign }), [labelAlign]), children: /* @__PURE__ */ jsxRuntime.jsx(MenuSheetContentBase, { ref, ...props, children }) });
|
|
64
|
+
}
|
|
65
|
+
);
|
|
66
|
+
const MenuSheetHeader = withContext(
|
|
67
|
+
withStateProps(reactPrimitive.Primitive.div),
|
|
68
|
+
"header"
|
|
69
|
+
);
|
|
70
|
+
const MenuSheetTitle = withContext(
|
|
71
|
+
withStateProps(reactPrimitive.Primitive.h2),
|
|
72
|
+
"title"
|
|
73
|
+
);
|
|
74
|
+
const MenuSheetList = withContext(
|
|
75
|
+
withStateProps(reactPrimitive.Primitive.div),
|
|
76
|
+
"list"
|
|
77
|
+
);
|
|
78
|
+
const MenuSheetGroupBase = withContext(
|
|
79
|
+
withStateProps(reactPrimitive.Primitive.div),
|
|
80
|
+
"group"
|
|
81
|
+
);
|
|
82
|
+
const MenuSheetGroup = React__namespace.forwardRef(
|
|
83
|
+
({ labelAlign: overriddenLabelAlign, children, ...props }, ref) => {
|
|
84
|
+
const parentProps = useItemProps();
|
|
85
|
+
const labelAlign = overriddenLabelAlign ?? parentProps?.labelAlign;
|
|
86
|
+
return /* @__PURE__ */ jsxRuntime.jsx(ItemPropsProvider, { value: React__namespace.useMemo(() => ({ labelAlign }), [labelAlign]), children: /* @__PURE__ */ jsxRuntime.jsx(MenuSheetGroupBase, { ref, ...props, children }) });
|
|
87
|
+
}
|
|
88
|
+
);
|
|
89
|
+
const MenuSheetItemBase = withItemContext(
|
|
90
|
+
withStateProps(reactPrimitive.Primitive.button)
|
|
91
|
+
);
|
|
92
|
+
const MenuSheetItem = React__namespace.forwardRef(
|
|
93
|
+
({ labelAlign: overriddenLabelAlign, ...props }, ref) => {
|
|
94
|
+
const parentProps = useItemProps();
|
|
95
|
+
const labelAlign = overriddenLabelAlign ?? parentProps?.labelAlign;
|
|
96
|
+
return /* @__PURE__ */ jsxRuntime.jsx(MenuSheetItemBase, { ref, labelAlign, ...props });
|
|
97
|
+
}
|
|
98
|
+
);
|
|
99
|
+
const MenuSheetFooter = withContext(
|
|
100
|
+
withStateProps(reactPrimitive.Primitive.div),
|
|
101
|
+
"footer"
|
|
102
|
+
);
|
|
103
|
+
const MenuSheetCloseButton = withContext(
|
|
104
|
+
reactDialog.Dialog.CloseButton,
|
|
105
|
+
"closeButton"
|
|
106
|
+
);
|
|
107
|
+
|
|
108
|
+
exports.MenuSheetBackdrop = MenuSheetBackdrop;
|
|
109
|
+
exports.MenuSheetCloseButton = MenuSheetCloseButton;
|
|
110
|
+
exports.MenuSheetContent = MenuSheetContent;
|
|
111
|
+
exports.MenuSheetFooter = MenuSheetFooter;
|
|
112
|
+
exports.MenuSheetGroup = MenuSheetGroup;
|
|
113
|
+
exports.MenuSheetHeader = MenuSheetHeader;
|
|
114
|
+
exports.MenuSheetItem = MenuSheetItem;
|
|
115
|
+
exports.MenuSheetList = MenuSheetList;
|
|
116
|
+
exports.MenuSheetPositioner = MenuSheetPositioner;
|
|
117
|
+
exports.MenuSheetRoot = MenuSheetRoot;
|
|
118
|
+
exports.MenuSheetTitle = MenuSheetTitle;
|
|
119
|
+
exports.MenuSheetTrigger = MenuSheetTrigger;
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { Dialog as DialogPrimitive } from '@seed-design/react-dialog';
|
|
2
|
+
import { PrimitiveProps } from '@seed-design/react-primitive';
|
|
3
|
+
import { MenuSheetVariantProps } from '@seed-design/css/recipes/menu-sheet';
|
|
4
|
+
import { MenuSheetItemVariantProps } from '@seed-design/css/recipes/menu-sheet-item';
|
|
5
|
+
import * as React from "react";
|
|
6
|
+
export interface MenuSheetRootProps extends MenuSheetVariantProps, DialogPrimitive.RootProps {
|
|
7
|
+
}
|
|
8
|
+
export declare const MenuSheetRoot: React.ForwardRefExoticComponent<MenuSheetRootProps>;
|
|
9
|
+
export interface MenuSheetTriggerProps extends DialogPrimitive.TriggerProps {
|
|
10
|
+
}
|
|
11
|
+
export declare const MenuSheetTrigger: React.ForwardRefExoticComponent<DialogPrimitive.TriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
12
|
+
export interface MenuSheetPositionerProps extends DialogPrimitive.PositionerProps {
|
|
13
|
+
}
|
|
14
|
+
export declare const MenuSheetPositioner: React.ForwardRefExoticComponent<MenuSheetPositionerProps & React.RefAttributes<HTMLDivElement>>;
|
|
15
|
+
export interface MenuSheetBackdropProps extends DialogPrimitive.BackdropProps {
|
|
16
|
+
}
|
|
17
|
+
export declare const MenuSheetBackdrop: React.ForwardRefExoticComponent<MenuSheetBackdropProps & React.RefAttributes<HTMLDivElement>>;
|
|
18
|
+
export interface MenuSheetContentProps extends DialogPrimitive.ContentProps, Pick<MenuSheetItemVariantProps, "labelAlign"> {
|
|
19
|
+
}
|
|
20
|
+
export declare const MenuSheetContent: React.ForwardRefExoticComponent<MenuSheetContentProps & React.RefAttributes<HTMLDivElement>>;
|
|
21
|
+
export interface MenuSheetHeaderProps extends PrimitiveProps, React.HTMLAttributes<HTMLDivElement> {
|
|
22
|
+
}
|
|
23
|
+
export declare const MenuSheetHeader: React.ForwardRefExoticComponent<MenuSheetHeaderProps & React.RefAttributes<HTMLDivElement>>;
|
|
24
|
+
export interface MenuSheetTitleProps extends DialogPrimitive.TitleProps {
|
|
25
|
+
}
|
|
26
|
+
export declare const MenuSheetTitle: React.ForwardRefExoticComponent<MenuSheetTitleProps & React.RefAttributes<HTMLHeadingElement>>;
|
|
27
|
+
export interface MenuSheetListProps extends PrimitiveProps, React.HTMLAttributes<HTMLDivElement> {
|
|
28
|
+
}
|
|
29
|
+
export declare const MenuSheetList: React.ForwardRefExoticComponent<MenuSheetListProps & React.RefAttributes<HTMLDivElement>>;
|
|
30
|
+
export interface MenuSheetGroupProps extends React.HTMLAttributes<HTMLDivElement>, Pick<MenuSheetItemVariantProps, "labelAlign"> {
|
|
31
|
+
}
|
|
32
|
+
export declare const MenuSheetGroup: React.ForwardRefExoticComponent<MenuSheetGroupProps & React.RefAttributes<HTMLDivElement>>;
|
|
33
|
+
export interface MenuSheetItemProps extends PrimitiveProps, MenuSheetItemVariantProps, React.HTMLAttributes<HTMLButtonElement> {
|
|
34
|
+
}
|
|
35
|
+
export declare const MenuSheetItem: React.ForwardRefExoticComponent<MenuSheetItemProps & React.RefAttributes<HTMLButtonElement>>;
|
|
36
|
+
export interface MenuSheetFooterProps extends PrimitiveProps, React.HTMLAttributes<HTMLDivElement> {
|
|
37
|
+
}
|
|
38
|
+
export declare const MenuSheetFooter: React.ForwardRefExoticComponent<MenuSheetFooterProps & React.RefAttributes<HTMLDivElement>>;
|
|
39
|
+
export interface MenuSheetCloseButtonProps extends DialogPrimitive.CloseButtonProps {
|
|
40
|
+
}
|
|
41
|
+
export declare const MenuSheetCloseButton: React.ForwardRefExoticComponent<MenuSheetCloseButtonProps & React.RefAttributes<HTMLDivElement>>;
|
|
42
|
+
//# sourceMappingURL=MenuSheet.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MenuSheet.d.ts","sourceRoot":"","sources":["../../../src/components/MenuSheet/MenuSheet.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,IAAI,eAAe,EAAoB,MAAM,2BAA2B,CAAC;AACxF,OAAO,EAAa,KAAK,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