@xaui/native 0.9.1-alpha.20 → 0.9.1-alpha.22
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/{chunk-RMLFMRWL.js → chunk-2U6JR7BF.js} +5 -5
- package/dist/{chunk-N7C4UNUL.js → chunk-3JATAB7S.js} +23 -1
- package/dist/chunk-4MHJOWM4.cjs +364 -0
- package/dist/{chunk-2WMVDMFV.cjs → chunk-6HXWQ5AU.cjs} +2 -2
- package/dist/chunk-6WW4CSPY.cjs +82 -0
- package/dist/chunk-AHL33YAO.js +425 -0
- package/dist/{chunk-XHZBXYVU.js → chunk-AKXG43S4.js} +1 -1
- package/dist/{chunk-A4VD4MHK.cjs → chunk-BH5DSJVX.cjs} +100 -133
- package/dist/chunk-BNWS26PX.cjs +449 -0
- package/dist/chunk-DXGQ43IV.cjs +68 -0
- package/dist/{chunk-4EPS7UBO.js → chunk-FNQF4KQV.js} +20 -97
- package/dist/chunk-FTCTTBLG.js +449 -0
- package/dist/chunk-FVP5FUVS.js +68 -0
- package/dist/{chunk-BHTFIZTQ.cjs → chunk-GBPWTFTU.cjs} +11 -11
- package/dist/{chunk-MWXE7D4L.js → chunk-GG2WWCBK.js} +11 -11
- package/dist/{chunk-EVXZGNPA.cjs → chunk-HUZ4AUM2.cjs} +98 -98
- package/dist/chunk-I6PE5UUH.cjs +425 -0
- package/dist/{chunk-33QILJJH.cjs → chunk-IBEX4XGV.cjs} +11 -11
- package/dist/{chunk-WXAME7KB.js → chunk-KM2TI5IC.js} +126 -159
- package/dist/chunk-OGC4RKE3.js +364 -0
- package/dist/{chunk-JXLRHKCQ.js → chunk-OYZYWWJ6.js} +1 -1
- package/dist/{chunk-EXX6ATAS.js → chunk-PMO62QK4.js} +101 -101
- package/dist/{chunk-UBA6AEY6.cjs → chunk-RAWOJ3N3.cjs} +8 -8
- package/dist/{chunk-6ARON3XT.cjs → chunk-VDRRD6GM.cjs} +31 -110
- package/dist/{chunk-UVO4GFSW.cjs → chunk-YXVKQMCK.cjs} +23 -1
- package/dist/chunk-ZQ3JSWRO.js +82 -0
- package/dist/close-button.type-BUYuoSt2.d.ts +36 -0
- package/dist/close-button.type-CHsgZ3wO.d.cts +36 -0
- package/dist/components/alert/index.cjs +17 -0
- package/dist/components/alert/index.d.cts +169 -0
- package/dist/components/alert/index.d.ts +169 -0
- package/dist/components/alert/index.js +17 -0
- package/dist/components/button/index.cjs +6 -5
- package/dist/components/button/index.d.cts +193 -243
- package/dist/components/button/index.d.ts +193 -243
- package/dist/components/button/index.js +5 -4
- package/dist/components/card/index.cjs +19 -0
- package/dist/components/card/index.d.cts +620 -0
- package/dist/components/card/index.d.ts +620 -0
- package/dist/components/card/index.js +19 -0
- package/dist/components/chip/index.cjs +17 -0
- package/dist/components/chip/index.d.cts +608 -0
- package/dist/components/chip/index.d.ts +608 -0
- package/dist/components/chip/index.js +17 -0
- package/dist/components/typography/index.cjs +4 -4
- package/dist/components/typography/index.d.cts +4 -4
- package/dist/components/typography/index.d.ts +4 -4
- package/dist/components/typography/index.js +3 -3
- package/dist/components/view/index.cjs +3 -3
- package/dist/components/view/index.d.cts +7 -7
- package/dist/components/view/index.d.ts +7 -7
- package/dist/components/view/index.js +2 -2
- package/dist/{create-recipe-CPXFo2rk.d.ts → create-recipe-CbXika57.d.ts} +7 -1
- package/dist/{create-recipe-C0XXjuow.d.cts → create-recipe-jHlk434p.d.cts} +7 -1
- package/dist/icon.type-CF4KiMKl.d.cts +73 -0
- package/dist/icon.type-Dq4_qePa.d.ts +73 -0
- package/dist/index.cjs +49 -11
- package/dist/index.d.cts +9 -4
- package/dist/index.d.ts +9 -4
- package/dist/index.js +71 -33
- package/dist/{pressable-feedback.type-BwkKLQlX.d.ts → pressable-feedback.type-BA2C9sSz.d.cts} +4 -72
- package/dist/{pressable-feedback.type-1K8YEOb8.d.cts → pressable-feedback.type-Bs4dQlGj.d.ts} +4 -72
- package/dist/{style-props.type-B1BG5TCm.d.cts → style-props.type-CfnoGEP7.d.cts} +1 -1
- package/dist/{style-props.type-B1BG5TCm.d.ts → style-props.type-CfnoGEP7.d.ts} +1 -1
- package/dist/system/index.cjs +16 -6
- package/dist/system/index.d.cts +174 -98
- package/dist/system/index.d.ts +174 -98
- package/dist/system/index.js +20 -10
- package/dist/theme/index.cjs +2 -2
- package/dist/theme/index.d.cts +11 -11
- package/dist/theme/index.d.ts +11 -11
- package/dist/theme/index.js +1 -1
- package/package.json +31 -1
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import { ComponentType, ReactNode } from 'react';
|
|
2
|
+
import { ImageSourcePropType, StyleProp, ImageStyle } from 'react-native';
|
|
3
|
+
import { I as ImageStyleProps } from './style-props.type-CfnoGEP7.js';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* The props Lucide, Ionicons and `react-native-vector-icons` all accept — the shape
|
|
7
|
+
* `as` is handed. It is a convention rather than an interface anyone published, which is
|
|
8
|
+
* exactly why `Icon` exists: without it every call site computes the two values by hand.
|
|
9
|
+
*/
|
|
10
|
+
type IconComponentProps = {
|
|
11
|
+
size?: number;
|
|
12
|
+
color?: string;
|
|
13
|
+
};
|
|
14
|
+
/** What every form takes, and the only lever the two non-rendering ones have. */
|
|
15
|
+
type IconBase = {
|
|
16
|
+
/** Overrides what the surrounding slot asked for. */
|
|
17
|
+
size?: number;
|
|
18
|
+
/** A raw value (R7), never a token. Overrides the slot's. */
|
|
19
|
+
color?: string;
|
|
20
|
+
};
|
|
21
|
+
/**
|
|
22
|
+
* An icon component — `size` and `color` are injected into it.
|
|
23
|
+
*
|
|
24
|
+
* No style props and no `style`: we do not render this node, the third party does, and
|
|
25
|
+
* there is no published interface that says it would accept either. Wrapping it in a view
|
|
26
|
+
* to make them work would add a level of depth to every icon in the library.
|
|
27
|
+
*/
|
|
28
|
+
type IconAsProps = IconBase & {
|
|
29
|
+
as: ComponentType<IconComponentProps>;
|
|
30
|
+
children?: never;
|
|
31
|
+
source?: never;
|
|
32
|
+
};
|
|
33
|
+
/**
|
|
34
|
+
* A raw `react-native-svg` element, cloned with the resolved size and colour.
|
|
35
|
+
*
|
|
36
|
+
* No style props and no `style` either: the node is the caller's own element, and they can
|
|
37
|
+
* style it where they wrote it.
|
|
38
|
+
*/
|
|
39
|
+
type IconChildrenProps = IconBase & {
|
|
40
|
+
as?: never;
|
|
41
|
+
children: ReactNode;
|
|
42
|
+
source?: never;
|
|
43
|
+
};
|
|
44
|
+
/**
|
|
45
|
+
* An image, tinted with the resolved colour — **the one form that carries R14**, because
|
|
46
|
+
* it is the one where we render the node.
|
|
47
|
+
*/
|
|
48
|
+
type IconSourceProps = IconBase & ImageStyleProps & {
|
|
49
|
+
as?: never;
|
|
50
|
+
children?: never;
|
|
51
|
+
source: ImageSourcePropType;
|
|
52
|
+
style?: StyleProp<ImageStyle>;
|
|
53
|
+
};
|
|
54
|
+
/**
|
|
55
|
+
* Three forms, and the type says which one you are in.
|
|
56
|
+
*
|
|
57
|
+
* The union is what makes R14's boundary checkable rather than merely documented. When
|
|
58
|
+
* every form declared the style props, `<Icon as={Trash2} marginEnd={8} />` compiled and
|
|
59
|
+
* did nothing at all — the prop was dropped on the two forms that do not render the node,
|
|
60
|
+
* silently, and only a comment said so. Now it is a compile error that points at `size`
|
|
61
|
+
* and `color`, which are the levers those forms actually have.
|
|
62
|
+
*
|
|
63
|
+
* It also makes the three mutually exclusive, which they always were at runtime: `as`
|
|
64
|
+
* wins over children, and children over `source`.
|
|
65
|
+
*/
|
|
66
|
+
type IconProps = IconAsProps | IconChildrenProps | IconSourceProps;
|
|
67
|
+
/** What a component root publishes so the icons inside it need no props at all. */
|
|
68
|
+
type IconContextValue = {
|
|
69
|
+
size?: number;
|
|
70
|
+
color?: string;
|
|
71
|
+
};
|
|
72
|
+
|
|
73
|
+
export type { IconComponentProps as I, IconContextValue as a, IconProps as b };
|
package/dist/index.cjs
CHANGED
|
@@ -4,60 +4,63 @@
|
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
var _chunk6ARON3XTcjs = require('./chunk-6ARON3XT.cjs');
|
|
8
7
|
|
|
9
8
|
|
|
10
9
|
|
|
11
10
|
|
|
12
|
-
var _chunkUBA6AEY6cjs = require('./chunk-UBA6AEY6.cjs');
|
|
13
11
|
|
|
12
|
+
var _chunkGBPWTFTUcjs = require('./chunk-GBPWTFTU.cjs');
|
|
14
13
|
|
|
15
14
|
|
|
16
15
|
|
|
17
16
|
|
|
17
|
+
var _chunk4MHJOWM4cjs = require('./chunk-4MHJOWM4.cjs');
|
|
18
18
|
|
|
19
|
-
var _chunk33QILJJHcjs = require('./chunk-33QILJJH.cjs');
|
|
20
19
|
|
|
21
20
|
|
|
22
21
|
|
|
22
|
+
var _chunkVDRRD6GMcjs = require('./chunk-VDRRD6GM.cjs');
|
|
23
23
|
|
|
24
|
-
var _chunk2WMVDMFVcjs = require('./chunk-2WMVDMFV.cjs');
|
|
25
24
|
|
|
26
25
|
|
|
27
26
|
|
|
28
27
|
|
|
29
28
|
|
|
29
|
+
var _chunkBNWS26PXcjs = require('./chunk-BNWS26PX.cjs');
|
|
30
30
|
|
|
31
31
|
|
|
32
32
|
|
|
33
33
|
|
|
34
|
+
var _chunkI6PE5UUHcjs = require('./chunk-I6PE5UUH.cjs');
|
|
34
35
|
|
|
35
36
|
|
|
36
37
|
|
|
37
38
|
|
|
39
|
+
var _chunkRAWOJ3N3cjs = require('./chunk-RAWOJ3N3.cjs');
|
|
38
40
|
|
|
39
41
|
|
|
40
42
|
|
|
41
43
|
|
|
42
44
|
|
|
43
45
|
|
|
46
|
+
var _chunkIBEX4XGVcjs = require('./chunk-IBEX4XGV.cjs');
|
|
44
47
|
|
|
45
48
|
|
|
46
49
|
|
|
47
50
|
|
|
51
|
+
var _chunk6HXWQ5AUcjs = require('./chunk-6HXWQ5AU.cjs');
|
|
48
52
|
|
|
49
|
-
var _chunkA4VD4MHKcjs = require('./chunk-A4VD4MHK.cjs');
|
|
50
53
|
|
|
51
54
|
|
|
52
|
-
var
|
|
55
|
+
var _chunk6WW4CSPYcjs = require('./chunk-6WW4CSPY.cjs');
|
|
53
56
|
|
|
54
57
|
|
|
55
58
|
|
|
56
59
|
|
|
60
|
+
var _chunkDXGQ43IVcjs = require('./chunk-DXGQ43IV.cjs');
|
|
57
61
|
|
|
58
62
|
|
|
59
63
|
|
|
60
|
-
var _chunkEVXZGNPAcjs = require('./chunk-EVXZGNPA.cjs');
|
|
61
64
|
|
|
62
65
|
|
|
63
66
|
|
|
@@ -69,7 +72,20 @@ var _chunkEVXZGNPAcjs = require('./chunk-EVXZGNPA.cjs');
|
|
|
69
72
|
|
|
70
73
|
|
|
71
74
|
|
|
72
|
-
|
|
75
|
+
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
|
|
79
|
+
|
|
80
|
+
|
|
81
|
+
|
|
82
|
+
|
|
83
|
+
|
|
84
|
+
var _chunkBH5DSJVXcjs = require('./chunk-BH5DSJVX.cjs');
|
|
85
|
+
|
|
86
|
+
|
|
87
|
+
|
|
88
|
+
var _chunkYXVKQMCKcjs = require('./chunk-YXVKQMCK.cjs');
|
|
73
89
|
|
|
74
90
|
|
|
75
91
|
|
|
@@ -77,6 +93,14 @@ var _chunkBHTFIZTQcjs = require('./chunk-BHTFIZTQ.cjs');
|
|
|
77
93
|
|
|
78
94
|
|
|
79
95
|
var _chunk57SJ4LJFcjs = require('./chunk-57SJ4LJF.cjs');
|
|
96
|
+
|
|
97
|
+
|
|
98
|
+
|
|
99
|
+
|
|
100
|
+
|
|
101
|
+
|
|
102
|
+
|
|
103
|
+
var _chunkHUZ4AUM2cjs = require('./chunk-HUZ4AUM2.cjs');
|
|
80
104
|
require('./chunk-MC7SY2QH.cjs');
|
|
81
105
|
|
|
82
106
|
// src/hooks/use-controllable-state.ts
|
|
@@ -107,7 +131,7 @@ function useControllableState({
|
|
|
107
131
|
function useControlWarning(isControlled) {
|
|
108
132
|
const wasControlled = _react.useRef.call(void 0, isControlled);
|
|
109
133
|
if (wasControlled.current !== isControlled) {
|
|
110
|
-
|
|
134
|
+
_chunkBH5DSJVXcjs.warnDev.call(void 0,
|
|
111
135
|
`a component switched from ${wasControlled.current ? "controlled" : "uncontrolled"} to ${isControlled ? "controlled" : "uncontrolled"}. Decide for the life of the component: pass \`value\` always, or never. Passing \`undefined\` for a value you do control reads as "uncontrolled" here.`
|
|
112
136
|
);
|
|
113
137
|
wasControlled.current = isControlled;
|
|
@@ -117,7 +141,7 @@ function useControlWarning(isControlled) {
|
|
|
117
141
|
// src/hooks/use-merged-ref.ts
|
|
118
142
|
|
|
119
143
|
function useMergedRef(...refs) {
|
|
120
|
-
return _react.useMemo.call(void 0, () =>
|
|
144
|
+
return _react.useMemo.call(void 0, () => _chunkHUZ4AUM2cjs.mergeRefs.call(void 0, ...refs), refs);
|
|
121
145
|
}
|
|
122
146
|
|
|
123
147
|
// src/hooks/use-previous.ts
|
|
@@ -193,4 +217,18 @@ function usePrevious(value) {
|
|
|
193
217
|
|
|
194
218
|
|
|
195
219
|
|
|
196
|
-
|
|
220
|
+
|
|
221
|
+
|
|
222
|
+
|
|
223
|
+
|
|
224
|
+
|
|
225
|
+
|
|
226
|
+
|
|
227
|
+
|
|
228
|
+
|
|
229
|
+
|
|
230
|
+
|
|
231
|
+
|
|
232
|
+
|
|
233
|
+
|
|
234
|
+
exports.Alert = _chunk4MHJOWM4cjs.Alert; exports.Button = _chunkVDRRD6GMcjs.Button; exports.CARD_BACKGROUND = _chunkBNWS26PXcjs.CARD_BACKGROUND; exports.Card = _chunkBNWS26PXcjs.Card; exports.Chip = _chunkI6PE5UUHcjs.Chip; exports.CloseButton = _chunk6WW4CSPYcjs.CloseButton; exports.Column = _chunkIBEX4XGVcjs.Column; exports.FEEDBACK_OVERLAY = _chunkBH5DSJVXcjs.FEEDBACK_OVERLAY; exports.Grid = _chunkIBEX4XGVcjs.Grid; exports.HIGHLIGHT_DURATION = _chunkBH5DSJVXcjs.HIGHLIGHT_DURATION; exports.HIGHLIGHT_OPACITY = _chunkBH5DSJVXcjs.HIGHLIGHT_OPACITY; exports.Icon = _chunkDXGQ43IVcjs.Icon; exports.IconContext = _chunkDXGQ43IVcjs.IconContext; exports.PRESS_DURATION = _chunkBH5DSJVXcjs.PRESS_DURATION; exports.PRESS_SCALE = _chunkBH5DSJVXcjs.PRESS_SCALE; exports.Portal = _chunk6HXWQ5AUcjs.Portal; exports.PortalContext = _chunk6HXWQ5AUcjs.PortalContext; exports.PortalHost = _chunk6HXWQ5AUcjs.PortalHost; exports.PressableFeedback = _chunkBH5DSJVXcjs.PressableFeedback; exports.RIPPLE_CONFIRM_DURATION = _chunkBH5DSJVXcjs.RIPPLE_CONFIRM_DURATION; exports.RIPPLE_EXPAND_DURATION = _chunkBH5DSJVXcjs.RIPPLE_EXPAND_DURATION; exports.RIPPLE_FADE_IN = _chunkBH5DSJVXcjs.RIPPLE_FADE_IN; exports.RIPPLE_FADE_OUT = _chunkBH5DSJVXcjs.RIPPLE_FADE_OUT; exports.RIPPLE_FADE_OUT_DELAY = _chunkBH5DSJVXcjs.RIPPLE_FADE_OUT_DELAY; exports.RIPPLE_OPACITY = _chunkBH5DSJVXcjs.RIPPLE_OPACITY; exports.RIPPLE_START_SCALE = _chunkBH5DSJVXcjs.RIPPLE_START_SCALE; exports.Row = _chunkIBEX4XGVcjs.Row; exports.SCALE_REFERENCE_WIDTH = _chunkBH5DSJVXcjs.SCALE_REFERENCE_WIDTH; exports.Slot = _chunkHUZ4AUM2cjs.Slot; exports.Stack = _chunkIBEX4XGVcjs.Stack; exports.TextSpan = _chunkRAWOJ3N3cjs.TextSpan; exports.ThemeContext = _chunk57SJ4LJFcjs.ThemeContext; exports.Typography = _chunkRAWOJ3N3cjs.Typography; exports.XAUIProvider = _chunkGBPWTFTUcjs.XAUIProvider; exports.alertRecipe = _chunk4MHJOWM4cjs.alertRecipe; exports.buildRadius = _chunkGBPWTFTUcjs.buildRadius; exports.buildShadows = _chunkGBPWTFTUcjs.buildShadows; exports.buttonRecipe = _chunkVDRRD6GMcjs.buttonRecipe; exports.cardRecipe = _chunkBNWS26PXcjs.cardRecipe; exports.childrenToString = _chunkHUZ4AUM2cjs.childrenToString; exports.chipRecipe = _chunkI6PE5UUHcjs.chipRecipe; exports.closeButtonBase = _chunk6WW4CSPYcjs.closeButtonBase; exports.createRecipe = _chunkYXVKQMCKcjs.createRecipe; exports.createSlotContext = _chunkHUZ4AUM2cjs.createSlotContext; exports.createTheme = _chunkGBPWTFTUcjs.createTheme; exports.defaultTheme = _chunkGBPWTFTUcjs.defaultTheme; exports.deriveColors = _chunkGBPWTFTUcjs.deriveColors; exports.deriveTint = _chunk57SJ4LJFcjs.deriveTint; exports.markBackground = _chunkBNWS26PXcjs.markBackground; exports.markOverlay = _chunkBH5DSJVXcjs.markOverlay; exports.mergeProps = _chunkHUZ4AUM2cjs.mergeProps; exports.mergeRefs = _chunkHUZ4AUM2cjs.mergeRefs; exports.palette = _chunkGBPWTFTUcjs.palette; exports.pressScaleFor = _chunkBH5DSJVXcjs.pressScaleFor; exports.primitives = _chunkGBPWTFTUcjs.primitives; exports.radiusAxis = _chunkYXVKQMCKcjs.radiusAxis; exports.resolveAnimation = _chunkBH5DSJVXcjs.resolveAnimation; exports.resolveSlotAnimation = _chunkBH5DSJVXcjs.resolveSlotAnimation; exports.rippleRadiusFor = _chunkBH5DSJVXcjs.rippleRadiusFor; exports.sourceKeys = _chunkGBPWTFTUcjs.sourceKeys; exports.tokens = _chunkGBPWTFTUcjs.tokens; exports.typographyRecipe = _chunkRAWOJ3N3cjs.typographyRecipe; exports.useAlert = _chunk4MHJOWM4cjs.useAlert; exports.useButton = _chunkVDRRD6GMcjs.useButton; exports.useCard = _chunkBNWS26PXcjs.useCard; exports.useChip = _chunkI6PE5UUHcjs.useChip; exports.useColorMode = _chunk57SJ4LJFcjs.useColorMode; exports.useControllableState = useControllableState; exports.useFeedback = _chunkBH5DSJVXcjs.useFeedback; exports.useGrid = _chunkIBEX4XGVcjs.useGrid; exports.useIconContext = _chunkDXGQ43IVcjs.useIconContext; exports.useMergedRef = useMergedRef; exports.usePressState = _chunkBH5DSJVXcjs.usePressState; exports.usePrevious = usePrevious; exports.useStyleProps = _chunkHUZ4AUM2cjs.useStyleProps; exports.useThemeColor = _chunk57SJ4LJFcjs.useThemeColor; exports.useXAUITheme = _chunk57SJ4LJFcjs.useXAUITheme;
|
package/dist/index.d.cts
CHANGED
|
@@ -1,15 +1,20 @@
|
|
|
1
|
+
export { Alert, AlertCloseProps, AlertContentProps, AlertContextValue, AlertDescriptionProps, AlertIconProps, AlertProps, AlertSize, AlertSlot, AlertTitleProps, AlertVariant, alertRecipe, useAlert } from './components/alert/index.cjs';
|
|
1
2
|
export { Button, ButtonContextValue, ButtonIconProps, ButtonLabelProps, ButtonProps, ButtonSize, ButtonSlot, ButtonSpinnerProps, ButtonVariant, buttonRecipe, useButton } from './components/button/index.cjs';
|
|
3
|
+
export { CARD_BACKGROUND, Card, CardBackgroundProps, CardBodyProps, CardContextValue, CardDescriptionProps, CardFooterProps, CardHeaderProps, CardProps, CardSize, CardSlot, CardTitleProps, CardVariant, cardRecipe, markBackground, useCard } from './components/card/index.cjs';
|
|
4
|
+
export { Chip, ChipAvatarProps, ChipCloseProps, ChipContextValue, ChipDotProps, ChipIconProps, ChipLabelProps, ChipProps, ChipSize, ChipSlot, ChipVariant, chipRecipe, useChip } from './components/chip/index.cjs';
|
|
2
5
|
export { TextSpan, TextSpanProps, Typography, TypographyProps, TypographySlot, TypographyVariant, typographyRecipe } from './components/typography/index.cjs';
|
|
3
6
|
export { AxisProps, Column, ColumnProps, Grid, GridContextValue, GridItemProps, GridProps, Row, RowProps, Stack, StackItemProps, StackProps, useGrid } from './components/view/index.cjs';
|
|
4
7
|
import { RefCallback } from 'react';
|
|
5
8
|
import { PossibleRef } from './system/index.cjs';
|
|
6
|
-
export { AsChildProps, FEEDBACK_OVERLAY, HIGHLIGHT_DURATION, HIGHLIGHT_OPACITY, Icon, IconContext, MergeableProps, PRESS_DURATION, PRESS_SCALE, Portal, PortalContext, PortalHost, PortalHostProps, PortalMethods, PortalProps, PressableFeedback, PressableFeedbackHighlightProps, PressableFeedbackRippleProps, RIPPLE_CONFIRM_DURATION, RIPPLE_EXPAND_DURATION, RIPPLE_FADE_IN, RIPPLE_FADE_OUT, RIPPLE_FADE_OUT_DELAY, RIPPLE_OPACITY, RIPPLE_START_SCALE, SCALE_REFERENCE_WIDTH, Slot, SlotProps, childrenToString, createSlotContext, markOverlay, mergeProps, mergeRefs, pressScaleFor, resolveAnimation, resolveSlotAnimation, rippleRadiusFor, useFeedback, useIconContext, useStyleProps } from './system/index.cjs';
|
|
9
|
+
export { AsChildProps, CloseButton, CloseButtonSlots, FEEDBACK_OVERLAY, HIGHLIGHT_DURATION, HIGHLIGHT_OPACITY, Icon, IconContext, MergeableProps, PRESS_DURATION, PRESS_SCALE, Portal, PortalContext, PortalHost, PortalHostProps, PortalMethods, PortalProps, PressableFeedback, PressableFeedbackHighlightProps, PressableFeedbackRippleProps, RIPPLE_CONFIRM_DURATION, RIPPLE_EXPAND_DURATION, RIPPLE_FADE_IN, RIPPLE_FADE_OUT, RIPPLE_FADE_OUT_DELAY, RIPPLE_OPACITY, RIPPLE_START_SCALE, SCALE_REFERENCE_WIDTH, Slot, SlotProps, childrenToString, closeButtonBase, createSlotContext, markOverlay, mergeProps, mergeRefs, pressScaleFor, radiusAxis, resolveAnimation, resolveSlotAnimation, rippleRadiusFor, useFeedback, useIconContext, useStyleProps } from './system/index.cjs';
|
|
7
10
|
import { GestureResponderEvent } from 'react-native';
|
|
8
|
-
export {
|
|
9
|
-
export {
|
|
10
|
-
export {
|
|
11
|
+
export { C as CloseButtonProps } from './close-button.type-CHsgZ3wO.cjs';
|
|
12
|
+
export { I as IconComponentProps, a as IconContextValue, b as IconProps } from './icon.type-CF4KiMKl.cjs';
|
|
13
|
+
export { A as Axes, C as CompoundVariant, R as Recipe, b as RecipeConfig, a as ResolveArgs, d as ResolvedSelection, e as ResolvedStyles, S as Selection, f as SlotStyle, g as SlotStyles, h as StateName, i as States, j as StyleFn, T as TintArgs, V as VariantColors, k as VariantRole, l as VariantTokens, c as createRecipe } from './create-recipe-jHlk434p.cjs';
|
|
14
|
+
export { D as DirectionalStyleKey, I as ImageStyleProps, S as StyleProps, T as TextStyleProps, V as ViewStyleProps } from './style-props.type-CfnoGEP7.cjs';
|
|
11
15
|
export { ColorModePreference, PaletteFamily, PaletteShade, ThemeContext, XAUIProvider, XAUIProviderProps, XAUITint, buildRadius, buildShadows, createTheme, defaultTheme, deriveColors, deriveTint, palette, primitives, sourceKeys, tokens, useColorMode, useThemeColor, useXAUITheme } from './theme/index.cjs';
|
|
12
16
|
export { C as ColorMode, F as FontSizeKey, b as FontWeightKey, R as RadiusKey, S as Size, a as XAUIColors, c as XAUIDerivedColors, d as XAUIPrimitiveColors, e as XAUIRadius, f as XAUIShadow, g as XAUISourceColors, X as XAUITheme, h as XAUIThemeConfig, i as XAUIThemeSet } from './theme.type-C2gNHpEx.cjs';
|
|
17
|
+
export { A as AnimationConfig, a as AnimationProp, F as FeedbackContext, P as PressableFeedbackProps, R as RadiusStyle, b as ResolvedAnimation, c as RippleWave, S as SlotAnimation } from './pressable-feedback.type-BA2C9sSz.cjs';
|
|
13
18
|
import 'react-native-reanimated';
|
|
14
19
|
|
|
15
20
|
type ControllableStateOptions<T> = {
|
package/dist/index.d.ts
CHANGED
|
@@ -1,15 +1,20 @@
|
|
|
1
|
+
export { Alert, AlertCloseProps, AlertContentProps, AlertContextValue, AlertDescriptionProps, AlertIconProps, AlertProps, AlertSize, AlertSlot, AlertTitleProps, AlertVariant, alertRecipe, useAlert } from './components/alert/index.js';
|
|
1
2
|
export { Button, ButtonContextValue, ButtonIconProps, ButtonLabelProps, ButtonProps, ButtonSize, ButtonSlot, ButtonSpinnerProps, ButtonVariant, buttonRecipe, useButton } from './components/button/index.js';
|
|
3
|
+
export { CARD_BACKGROUND, Card, CardBackgroundProps, CardBodyProps, CardContextValue, CardDescriptionProps, CardFooterProps, CardHeaderProps, CardProps, CardSize, CardSlot, CardTitleProps, CardVariant, cardRecipe, markBackground, useCard } from './components/card/index.js';
|
|
4
|
+
export { Chip, ChipAvatarProps, ChipCloseProps, ChipContextValue, ChipDotProps, ChipIconProps, ChipLabelProps, ChipProps, ChipSize, ChipSlot, ChipVariant, chipRecipe, useChip } from './components/chip/index.js';
|
|
2
5
|
export { TextSpan, TextSpanProps, Typography, TypographyProps, TypographySlot, TypographyVariant, typographyRecipe } from './components/typography/index.js';
|
|
3
6
|
export { AxisProps, Column, ColumnProps, Grid, GridContextValue, GridItemProps, GridProps, Row, RowProps, Stack, StackItemProps, StackProps, useGrid } from './components/view/index.js';
|
|
4
7
|
import { RefCallback } from 'react';
|
|
5
8
|
import { PossibleRef } from './system/index.js';
|
|
6
|
-
export { AsChildProps, FEEDBACK_OVERLAY, HIGHLIGHT_DURATION, HIGHLIGHT_OPACITY, Icon, IconContext, MergeableProps, PRESS_DURATION, PRESS_SCALE, Portal, PortalContext, PortalHost, PortalHostProps, PortalMethods, PortalProps, PressableFeedback, PressableFeedbackHighlightProps, PressableFeedbackRippleProps, RIPPLE_CONFIRM_DURATION, RIPPLE_EXPAND_DURATION, RIPPLE_FADE_IN, RIPPLE_FADE_OUT, RIPPLE_FADE_OUT_DELAY, RIPPLE_OPACITY, RIPPLE_START_SCALE, SCALE_REFERENCE_WIDTH, Slot, SlotProps, childrenToString, createSlotContext, markOverlay, mergeProps, mergeRefs, pressScaleFor, resolveAnimation, resolveSlotAnimation, rippleRadiusFor, useFeedback, useIconContext, useStyleProps } from './system/index.js';
|
|
9
|
+
export { AsChildProps, CloseButton, CloseButtonSlots, FEEDBACK_OVERLAY, HIGHLIGHT_DURATION, HIGHLIGHT_OPACITY, Icon, IconContext, MergeableProps, PRESS_DURATION, PRESS_SCALE, Portal, PortalContext, PortalHost, PortalHostProps, PortalMethods, PortalProps, PressableFeedback, PressableFeedbackHighlightProps, PressableFeedbackRippleProps, RIPPLE_CONFIRM_DURATION, RIPPLE_EXPAND_DURATION, RIPPLE_FADE_IN, RIPPLE_FADE_OUT, RIPPLE_FADE_OUT_DELAY, RIPPLE_OPACITY, RIPPLE_START_SCALE, SCALE_REFERENCE_WIDTH, Slot, SlotProps, childrenToString, closeButtonBase, createSlotContext, markOverlay, mergeProps, mergeRefs, pressScaleFor, radiusAxis, resolveAnimation, resolveSlotAnimation, rippleRadiusFor, useFeedback, useIconContext, useStyleProps } from './system/index.js';
|
|
7
10
|
import { GestureResponderEvent } from 'react-native';
|
|
8
|
-
export {
|
|
9
|
-
export {
|
|
10
|
-
export {
|
|
11
|
+
export { C as CloseButtonProps } from './close-button.type-BUYuoSt2.js';
|
|
12
|
+
export { I as IconComponentProps, a as IconContextValue, b as IconProps } from './icon.type-Dq4_qePa.js';
|
|
13
|
+
export { A as Axes, C as CompoundVariant, R as Recipe, b as RecipeConfig, a as ResolveArgs, d as ResolvedSelection, e as ResolvedStyles, S as Selection, f as SlotStyle, g as SlotStyles, h as StateName, i as States, j as StyleFn, T as TintArgs, V as VariantColors, k as VariantRole, l as VariantTokens, c as createRecipe } from './create-recipe-CbXika57.js';
|
|
14
|
+
export { D as DirectionalStyleKey, I as ImageStyleProps, S as StyleProps, T as TextStyleProps, V as ViewStyleProps } from './style-props.type-CfnoGEP7.js';
|
|
11
15
|
export { ColorModePreference, PaletteFamily, PaletteShade, ThemeContext, XAUIProvider, XAUIProviderProps, XAUITint, buildRadius, buildShadows, createTheme, defaultTheme, deriveColors, deriveTint, palette, primitives, sourceKeys, tokens, useColorMode, useThemeColor, useXAUITheme } from './theme/index.js';
|
|
12
16
|
export { C as ColorMode, F as FontSizeKey, b as FontWeightKey, R as RadiusKey, S as Size, a as XAUIColors, c as XAUIDerivedColors, d as XAUIPrimitiveColors, e as XAUIRadius, f as XAUIShadow, g as XAUISourceColors, X as XAUITheme, h as XAUIThemeConfig, i as XAUIThemeSet } from './theme.type-C2gNHpEx.js';
|
|
17
|
+
export { A as AnimationConfig, a as AnimationProp, F as FeedbackContext, P as PressableFeedbackProps, R as RadiusStyle, b as ResolvedAnimation, c as RippleWave, S as SlotAnimation } from './pressable-feedback.type-Bs4dQlGj.js';
|
|
13
18
|
import 'react-native-reanimated';
|
|
14
19
|
|
|
15
20
|
type ControllableStateOptions<T> = {
|
package/dist/index.js
CHANGED
|
@@ -1,33 +1,67 @@
|
|
|
1
|
+
import {
|
|
2
|
+
XAUIProvider,
|
|
3
|
+
buildRadius,
|
|
4
|
+
buildShadows,
|
|
5
|
+
createTheme,
|
|
6
|
+
defaultTheme,
|
|
7
|
+
deriveColors,
|
|
8
|
+
palette,
|
|
9
|
+
primitives,
|
|
10
|
+
sourceKeys,
|
|
11
|
+
tokens
|
|
12
|
+
} from "./chunk-GG2WWCBK.js";
|
|
13
|
+
import {
|
|
14
|
+
Alert,
|
|
15
|
+
alertRecipe,
|
|
16
|
+
useAlert
|
|
17
|
+
} from "./chunk-OGC4RKE3.js";
|
|
1
18
|
import {
|
|
2
19
|
Button,
|
|
3
20
|
buttonRecipe,
|
|
4
|
-
useButton
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
21
|
+
useButton
|
|
22
|
+
} from "./chunk-FNQF4KQV.js";
|
|
23
|
+
import {
|
|
24
|
+
CARD_BACKGROUND,
|
|
25
|
+
Card,
|
|
26
|
+
cardRecipe,
|
|
27
|
+
markBackground,
|
|
28
|
+
useCard
|
|
29
|
+
} from "./chunk-FTCTTBLG.js";
|
|
30
|
+
import {
|
|
31
|
+
Chip,
|
|
32
|
+
chipRecipe,
|
|
33
|
+
useChip
|
|
34
|
+
} from "./chunk-AHL33YAO.js";
|
|
8
35
|
import {
|
|
9
36
|
TextSpan,
|
|
10
37
|
Typography,
|
|
11
38
|
typographyRecipe
|
|
12
|
-
} from "./chunk-
|
|
39
|
+
} from "./chunk-2U6JR7BF.js";
|
|
13
40
|
import {
|
|
14
41
|
Column,
|
|
15
42
|
Grid,
|
|
16
43
|
Row,
|
|
17
44
|
Stack,
|
|
18
45
|
useGrid
|
|
19
|
-
} from "./chunk-
|
|
46
|
+
} from "./chunk-OYZYWWJ6.js";
|
|
20
47
|
import {
|
|
21
48
|
Portal,
|
|
22
49
|
PortalContext,
|
|
23
50
|
PortalHost
|
|
24
|
-
} from "./chunk-
|
|
51
|
+
} from "./chunk-AKXG43S4.js";
|
|
52
|
+
import {
|
|
53
|
+
CloseButton,
|
|
54
|
+
closeButtonBase
|
|
55
|
+
} from "./chunk-ZQ3JSWRO.js";
|
|
56
|
+
import {
|
|
57
|
+
Icon,
|
|
58
|
+
IconContext,
|
|
59
|
+
useIconContext
|
|
60
|
+
} from "./chunk-FVP5FUVS.js";
|
|
25
61
|
import {
|
|
26
62
|
FEEDBACK_OVERLAY,
|
|
27
63
|
HIGHLIGHT_DURATION,
|
|
28
64
|
HIGHLIGHT_OPACITY,
|
|
29
|
-
Icon,
|
|
30
|
-
IconContext,
|
|
31
65
|
PRESS_DURATION,
|
|
32
66
|
PRESS_SCALE,
|
|
33
67
|
PressableFeedback,
|
|
@@ -45,31 +79,13 @@ import {
|
|
|
45
79
|
resolveSlotAnimation,
|
|
46
80
|
rippleRadiusFor,
|
|
47
81
|
useFeedback,
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
createRecipe
|
|
52
|
-
} from "./chunk-N7C4UNUL.js";
|
|
53
|
-
import {
|
|
54
|
-
Slot,
|
|
55
|
-
childrenToString,
|
|
56
|
-
createSlotContext,
|
|
57
|
-
mergeProps,
|
|
58
|
-
mergeRefs,
|
|
59
|
-
useStyleProps
|
|
60
|
-
} from "./chunk-EXX6ATAS.js";
|
|
82
|
+
usePressState,
|
|
83
|
+
warnDev
|
|
84
|
+
} from "./chunk-KM2TI5IC.js";
|
|
61
85
|
import {
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
createTheme,
|
|
66
|
-
defaultTheme,
|
|
67
|
-
deriveColors,
|
|
68
|
-
palette,
|
|
69
|
-
primitives,
|
|
70
|
-
sourceKeys,
|
|
71
|
-
tokens
|
|
72
|
-
} from "./chunk-MWXE7D4L.js";
|
|
86
|
+
createRecipe,
|
|
87
|
+
radiusAxis
|
|
88
|
+
} from "./chunk-3JATAB7S.js";
|
|
73
89
|
import {
|
|
74
90
|
ThemeContext,
|
|
75
91
|
deriveTint,
|
|
@@ -77,6 +93,14 @@ import {
|
|
|
77
93
|
useThemeColor,
|
|
78
94
|
useXAUITheme
|
|
79
95
|
} from "./chunk-A3EGFI6T.js";
|
|
96
|
+
import {
|
|
97
|
+
Slot,
|
|
98
|
+
childrenToString,
|
|
99
|
+
createSlotContext,
|
|
100
|
+
mergeProps,
|
|
101
|
+
mergeRefs,
|
|
102
|
+
useStyleProps
|
|
103
|
+
} from "./chunk-PMO62QK4.js";
|
|
80
104
|
import "./chunk-GGW42MY4.js";
|
|
81
105
|
|
|
82
106
|
// src/hooks/use-controllable-state.ts
|
|
@@ -130,7 +154,12 @@ function usePrevious(value) {
|
|
|
130
154
|
return previous.current;
|
|
131
155
|
}
|
|
132
156
|
export {
|
|
157
|
+
Alert,
|
|
133
158
|
Button,
|
|
159
|
+
CARD_BACKGROUND,
|
|
160
|
+
Card,
|
|
161
|
+
Chip,
|
|
162
|
+
CloseButton,
|
|
134
163
|
Column,
|
|
135
164
|
FEEDBACK_OVERLAY,
|
|
136
165
|
Grid,
|
|
@@ -159,29 +188,38 @@ export {
|
|
|
159
188
|
ThemeContext,
|
|
160
189
|
Typography,
|
|
161
190
|
XAUIProvider,
|
|
191
|
+
alertRecipe,
|
|
162
192
|
buildRadius,
|
|
163
193
|
buildShadows,
|
|
164
194
|
buttonRecipe,
|
|
195
|
+
cardRecipe,
|
|
165
196
|
childrenToString,
|
|
197
|
+
chipRecipe,
|
|
198
|
+
closeButtonBase,
|
|
166
199
|
createRecipe,
|
|
167
200
|
createSlotContext,
|
|
168
201
|
createTheme,
|
|
169
202
|
defaultTheme,
|
|
170
203
|
deriveColors,
|
|
171
204
|
deriveTint,
|
|
205
|
+
markBackground,
|
|
172
206
|
markOverlay,
|
|
173
207
|
mergeProps,
|
|
174
208
|
mergeRefs,
|
|
175
209
|
palette,
|
|
176
210
|
pressScaleFor,
|
|
177
211
|
primitives,
|
|
212
|
+
radiusAxis,
|
|
178
213
|
resolveAnimation,
|
|
179
214
|
resolveSlotAnimation,
|
|
180
215
|
rippleRadiusFor,
|
|
181
216
|
sourceKeys,
|
|
182
217
|
tokens,
|
|
183
218
|
typographyRecipe,
|
|
219
|
+
useAlert,
|
|
184
220
|
useButton,
|
|
221
|
+
useCard,
|
|
222
|
+
useChip,
|
|
185
223
|
useColorMode,
|
|
186
224
|
useControllableState,
|
|
187
225
|
useFeedback,
|
package/dist/{pressable-feedback.type-BwkKLQlX.d.ts → pressable-feedback.type-BA2C9sSz.d.cts}
RENAMED
|
@@ -1,75 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { I as ImageStyleProps, V as ViewStyleProps } from './style-props.type-B1BG5TCm.js';
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { PressableProps, StyleProp, ViewStyle } from 'react-native';
|
|
4
3
|
import { SharedValue } from 'react-native-reanimated';
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* The props Lucide, Ionicons and `react-native-vector-icons` all accept — the shape
|
|
8
|
-
* `as` is handed. It is a convention rather than an interface anyone published, which is
|
|
9
|
-
* exactly why `Icon` exists: without it every call site computes the two values by hand.
|
|
10
|
-
*/
|
|
11
|
-
type IconComponentProps = {
|
|
12
|
-
size?: number;
|
|
13
|
-
color?: string;
|
|
14
|
-
};
|
|
15
|
-
/** What every form takes, and the only lever the two non-rendering ones have. */
|
|
16
|
-
type IconBase = {
|
|
17
|
-
/** Overrides what the surrounding slot asked for. */
|
|
18
|
-
size?: number;
|
|
19
|
-
/** A raw value (R7), never a token. Overrides the slot's. */
|
|
20
|
-
color?: string;
|
|
21
|
-
};
|
|
22
|
-
/**
|
|
23
|
-
* An icon component — `size` and `color` are injected into it.
|
|
24
|
-
*
|
|
25
|
-
* No style props and no `style`: we do not render this node, the third party does, and
|
|
26
|
-
* there is no published interface that says it would accept either. Wrapping it in a view
|
|
27
|
-
* to make them work would add a level of depth to every icon in the library.
|
|
28
|
-
*/
|
|
29
|
-
type IconAsProps = IconBase & {
|
|
30
|
-
as: ComponentType<IconComponentProps>;
|
|
31
|
-
children?: never;
|
|
32
|
-
source?: never;
|
|
33
|
-
};
|
|
34
|
-
/**
|
|
35
|
-
* A raw `react-native-svg` element, cloned with the resolved size and colour.
|
|
36
|
-
*
|
|
37
|
-
* No style props and no `style` either: the node is the caller's own element, and they can
|
|
38
|
-
* style it where they wrote it.
|
|
39
|
-
*/
|
|
40
|
-
type IconChildrenProps = IconBase & {
|
|
41
|
-
as?: never;
|
|
42
|
-
children: ReactNode;
|
|
43
|
-
source?: never;
|
|
44
|
-
};
|
|
45
|
-
/**
|
|
46
|
-
* An image, tinted with the resolved colour — **the one form that carries R14**, because
|
|
47
|
-
* it is the one where we render the node.
|
|
48
|
-
*/
|
|
49
|
-
type IconSourceProps = IconBase & ImageStyleProps & {
|
|
50
|
-
as?: never;
|
|
51
|
-
children?: never;
|
|
52
|
-
source: ImageSourcePropType;
|
|
53
|
-
style?: StyleProp<ImageStyle>;
|
|
54
|
-
};
|
|
55
|
-
/**
|
|
56
|
-
* Three forms, and the type says which one you are in.
|
|
57
|
-
*
|
|
58
|
-
* The union is what makes R14's boundary checkable rather than merely documented. When
|
|
59
|
-
* every form declared the style props, `<Icon as={Trash2} marginEnd={8} />` compiled and
|
|
60
|
-
* did nothing at all — the prop was dropped on the two forms that do not render the node,
|
|
61
|
-
* silently, and only a comment said so. Now it is a compile error that points at `size`
|
|
62
|
-
* and `color`, which are the levers those forms actually have.
|
|
63
|
-
*
|
|
64
|
-
* It also makes the three mutually exclusive, which they always were at runtime: `as`
|
|
65
|
-
* wins over children, and children over `source`.
|
|
66
|
-
*/
|
|
67
|
-
type IconProps = IconAsProps | IconChildrenProps | IconSourceProps;
|
|
68
|
-
/** What a component root publishes so the icons inside it need no props at all. */
|
|
69
|
-
type IconContextValue = {
|
|
70
|
-
size?: number;
|
|
71
|
-
color?: string;
|
|
72
|
-
};
|
|
4
|
+
import { V as ViewStyleProps } from './style-props.type-CfnoGEP7.cjs';
|
|
73
5
|
|
|
74
6
|
type AnimationConfig = {
|
|
75
7
|
scale?: boolean;
|
|
@@ -192,4 +124,4 @@ type FeedbackContext = {
|
|
|
192
124
|
waves?: readonly [RippleWave, RippleWave];
|
|
193
125
|
};
|
|
194
126
|
|
|
195
|
-
export type { AnimationConfig as A, FeedbackContext as F,
|
|
127
|
+
export type { AnimationConfig as A, FeedbackContext as F, PressableFeedbackProps as P, RadiusStyle as R, SlotAnimation as S, AnimationProp as a, ResolvedAnimation as b, RippleWave as c };
|
package/dist/{pressable-feedback.type-1K8YEOb8.d.cts → pressable-feedback.type-Bs4dQlGj.d.ts}
RENAMED
|
@@ -1,75 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { I as ImageStyleProps, V as ViewStyleProps } from './style-props.type-B1BG5TCm.cjs';
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { PressableProps, StyleProp, ViewStyle } from 'react-native';
|
|
4
3
|
import { SharedValue } from 'react-native-reanimated';
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* The props Lucide, Ionicons and `react-native-vector-icons` all accept — the shape
|
|
8
|
-
* `as` is handed. It is a convention rather than an interface anyone published, which is
|
|
9
|
-
* exactly why `Icon` exists: without it every call site computes the two values by hand.
|
|
10
|
-
*/
|
|
11
|
-
type IconComponentProps = {
|
|
12
|
-
size?: number;
|
|
13
|
-
color?: string;
|
|
14
|
-
};
|
|
15
|
-
/** What every form takes, and the only lever the two non-rendering ones have. */
|
|
16
|
-
type IconBase = {
|
|
17
|
-
/** Overrides what the surrounding slot asked for. */
|
|
18
|
-
size?: number;
|
|
19
|
-
/** A raw value (R7), never a token. Overrides the slot's. */
|
|
20
|
-
color?: string;
|
|
21
|
-
};
|
|
22
|
-
/**
|
|
23
|
-
* An icon component — `size` and `color` are injected into it.
|
|
24
|
-
*
|
|
25
|
-
* No style props and no `style`: we do not render this node, the third party does, and
|
|
26
|
-
* there is no published interface that says it would accept either. Wrapping it in a view
|
|
27
|
-
* to make them work would add a level of depth to every icon in the library.
|
|
28
|
-
*/
|
|
29
|
-
type IconAsProps = IconBase & {
|
|
30
|
-
as: ComponentType<IconComponentProps>;
|
|
31
|
-
children?: never;
|
|
32
|
-
source?: never;
|
|
33
|
-
};
|
|
34
|
-
/**
|
|
35
|
-
* A raw `react-native-svg` element, cloned with the resolved size and colour.
|
|
36
|
-
*
|
|
37
|
-
* No style props and no `style` either: the node is the caller's own element, and they can
|
|
38
|
-
* style it where they wrote it.
|
|
39
|
-
*/
|
|
40
|
-
type IconChildrenProps = IconBase & {
|
|
41
|
-
as?: never;
|
|
42
|
-
children: ReactNode;
|
|
43
|
-
source?: never;
|
|
44
|
-
};
|
|
45
|
-
/**
|
|
46
|
-
* An image, tinted with the resolved colour — **the one form that carries R14**, because
|
|
47
|
-
* it is the one where we render the node.
|
|
48
|
-
*/
|
|
49
|
-
type IconSourceProps = IconBase & ImageStyleProps & {
|
|
50
|
-
as?: never;
|
|
51
|
-
children?: never;
|
|
52
|
-
source: ImageSourcePropType;
|
|
53
|
-
style?: StyleProp<ImageStyle>;
|
|
54
|
-
};
|
|
55
|
-
/**
|
|
56
|
-
* Three forms, and the type says which one you are in.
|
|
57
|
-
*
|
|
58
|
-
* The union is what makes R14's boundary checkable rather than merely documented. When
|
|
59
|
-
* every form declared the style props, `<Icon as={Trash2} marginEnd={8} />` compiled and
|
|
60
|
-
* did nothing at all — the prop was dropped on the two forms that do not render the node,
|
|
61
|
-
* silently, and only a comment said so. Now it is a compile error that points at `size`
|
|
62
|
-
* and `color`, which are the levers those forms actually have.
|
|
63
|
-
*
|
|
64
|
-
* It also makes the three mutually exclusive, which they always were at runtime: `as`
|
|
65
|
-
* wins over children, and children over `source`.
|
|
66
|
-
*/
|
|
67
|
-
type IconProps = IconAsProps | IconChildrenProps | IconSourceProps;
|
|
68
|
-
/** What a component root publishes so the icons inside it need no props at all. */
|
|
69
|
-
type IconContextValue = {
|
|
70
|
-
size?: number;
|
|
71
|
-
color?: string;
|
|
72
|
-
};
|
|
4
|
+
import { V as ViewStyleProps } from './style-props.type-CfnoGEP7.js';
|
|
73
5
|
|
|
74
6
|
type AnimationConfig = {
|
|
75
7
|
scale?: boolean;
|
|
@@ -192,4 +124,4 @@ type FeedbackContext = {
|
|
|
192
124
|
waves?: readonly [RippleWave, RippleWave];
|
|
193
125
|
};
|
|
194
126
|
|
|
195
|
-
export type { AnimationConfig as A, FeedbackContext as F,
|
|
127
|
+
export type { AnimationConfig as A, FeedbackContext as F, PressableFeedbackProps as P, RadiusStyle as R, SlotAnimation as S, AnimationProp as a, ResolvedAnimation as b, RippleWave as c };
|