@xaui/native 0.9.1-alpha.4 → 0.9.1-alpha.41
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-2EGR4LWD.js +145 -0
- package/dist/chunk-2NRZKJG7.js +531 -0
- package/dist/chunk-2PMXMKS5.js +67 -0
- package/dist/chunk-2XPG2243.js +586 -0
- package/dist/chunk-36PRYGAM.js +13 -0
- package/dist/chunk-3E7CDKFO.cjs +696 -0
- package/dist/chunk-3GFRSZYR.js +54 -0
- package/dist/chunk-423RQBOX.js +21 -0
- package/dist/chunk-4CUZZWFW.js +92 -0
- package/dist/chunk-4GTAZM2C.js +174 -0
- package/dist/chunk-4KFKWBN5.cjs +89 -0
- package/dist/{chunk-3QBT3Q65.cjs → chunk-57SJ4LJF.cjs} +7 -2
- package/dist/chunk-5R26NM4M.cjs +402 -0
- package/dist/chunk-5VKYNBNA.js +607 -0
- package/dist/chunk-64MXEVT3.js +66 -0
- package/dist/chunk-6DOLGZVV.cjs +147 -0
- package/dist/chunk-6L2TS2R3.cjs +92 -0
- package/dist/chunk-6UEZJRVI.js +669 -0
- package/dist/chunk-734MFAX4.js +27 -0
- package/dist/chunk-73RKQC5X.js +104 -0
- package/dist/chunk-7DPL3ZDS.cjs +21 -0
- package/dist/chunk-7EIHHOHP.cjs +42 -0
- package/dist/chunk-7GHM4GKL.cjs +119 -0
- package/dist/chunk-7YF5NAHQ.cjs +74 -0
- package/dist/{chunk-X2K2FX3W.js → chunk-A3EGFI6T.js} +6 -1
- package/dist/chunk-ABAGZTXZ.cjs +736 -0
- package/dist/{chunk-AW63PTQ4.cjs → chunk-ACAPTWE3.cjs} +85 -81
- package/dist/chunk-AMCSSOJT.cjs +104 -0
- package/dist/chunk-BA2DBSAN.js +102 -0
- package/dist/chunk-BRRXFOBY.js +431 -0
- package/dist/chunk-C5YLPCFC.cjs +293 -0
- package/dist/chunk-DA3OKXHV.cjs +700 -0
- package/dist/chunk-DD4276RF.js +366 -0
- package/dist/chunk-DG2I4PJG.js +701 -0
- package/dist/chunk-DHGLGSH6.js +661 -0
- package/dist/chunk-DIBUQ46Y.js +346 -0
- package/dist/chunk-EGLLDKN6.js +9 -0
- package/dist/chunk-EJQCQPET.cjs +9 -0
- package/dist/chunk-EKS3W46M.cjs +66 -0
- package/dist/chunk-EZEYMLO3.js +402 -0
- package/dist/chunk-F6CQ6CBI.cjs +112 -0
- package/dist/chunk-F6W3JQ7K.js +42 -0
- package/dist/chunk-FHUYHV6J.js +89 -0
- package/dist/chunk-FNEUOBCV.cjs +174 -0
- package/dist/chunk-G3CCT4EY.js +518 -0
- package/dist/chunk-G7P3ERYF.cjs +478 -0
- package/dist/chunk-GA6PBWNT.js +147 -0
- package/dist/chunk-GFUZ3MUT.cjs +455 -0
- package/dist/chunk-GGW43Q37.cjs +1 -0
- package/dist/chunk-GTR5X65M.cjs +27 -0
- package/dist/chunk-H4E4HDEP.cjs +13 -0
- package/dist/chunk-H7DS4IO7.js +198 -0
- package/dist/chunk-HDVVZG4S.cjs +198 -0
- package/dist/chunk-IKJVLJKT.js +151 -0
- package/dist/chunk-J3MB4PI5.cjs +531 -0
- package/dist/chunk-K72UDPVN.js +119 -0
- package/dist/chunk-KCMYU7WF.js +86 -0
- package/dist/chunk-LRN3RNDO.js +940 -0
- package/dist/chunk-LTX6TB5I.js +124 -0
- package/dist/chunk-LUPCPLND.cjs +145 -0
- package/dist/chunk-M63GFNKV.js +194 -0
- package/dist/chunk-N3KTZMPG.js +293 -0
- package/dist/chunk-NCTOTTVW.js +13 -0
- package/dist/chunk-NWGLP6JX.cjs +410 -0
- package/dist/chunk-R73XQK7X.cjs +314 -0
- package/dist/chunk-RU7JCMWC.cjs +881 -0
- package/dist/chunk-SNIHUKDA.cjs +184 -0
- package/dist/chunk-T5FV5F7A.cjs +607 -0
- package/dist/chunk-TDTUAIFF.cjs +153 -0
- package/dist/chunk-TJ74XVZN.cjs +431 -0
- package/dist/chunk-TK44VBIE.cjs +194 -0
- package/dist/chunk-UAWBAD4E.cjs +346 -0
- package/dist/chunk-UFTCTTKK.js +381 -0
- package/dist/chunk-VLKBESEV.cjs +407 -0
- package/dist/chunk-WDDXU3OH.cjs +67 -0
- package/dist/chunk-WFEMJCXO.cjs +13 -0
- package/dist/chunk-WHJTBTYM.js +0 -0
- package/dist/{chunk-2KXQATVL.js → chunk-WKCQ6VGW.js} +59 -55
- package/dist/chunk-XFPQFCEK.js +455 -0
- package/dist/chunk-XSQPVDFH.cjs +60 -0
- package/dist/chunk-XTC2SLFT.js +153 -0
- package/dist/chunk-XV735BSA.cjs +366 -0
- package/dist/chunk-XWNG2U4K.cjs +124 -0
- package/dist/chunk-YGYYJ3LQ.js +314 -0
- package/dist/chunk-YVHT2UVW.js +74 -0
- package/dist/chunk-ZFOOJK37.cjs +86 -0
- package/dist/close-button.type-BUYuoSt2.d.ts +36 -0
- package/dist/close-button.type-CHsgZ3wO.d.cts +36 -0
- package/dist/components/accordion/index.cjs +35 -0
- package/dist/components/accordion/index.d.cts +299 -0
- package/dist/components/accordion/index.d.ts +299 -0
- package/dist/components/accordion/index.js +35 -0
- package/dist/components/alert/index.cjs +20 -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 +20 -0
- package/dist/components/avatar/index.cjs +16 -0
- package/dist/components/avatar/index.d.cts +131 -0
- package/dist/components/avatar/index.d.ts +131 -0
- package/dist/components/avatar/index.js +16 -0
- package/dist/components/badge/index.cjs +15 -0
- package/dist/components/badge/index.d.cts +157 -0
- package/dist/components/badge/index.d.ts +157 -0
- package/dist/components/badge/index.js +15 -0
- package/dist/components/button/index.cjs +22 -0
- package/dist/components/button/index.d.cts +613 -0
- package/dist/components/button/index.d.ts +613 -0
- package/dist/components/button/index.js +22 -0
- package/dist/components/card/index.cjs +22 -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 +22 -0
- package/dist/components/checkbox/index.cjs +26 -0
- package/dist/components/checkbox/index.d.cts +1136 -0
- package/dist/components/checkbox/index.d.ts +1136 -0
- package/dist/components/checkbox/index.js +26 -0
- package/dist/components/chip/index.cjs +20 -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 +20 -0
- package/dist/components/divider/index.cjs +13 -0
- package/dist/components/divider/index.d.cts +117 -0
- package/dist/components/divider/index.d.ts +117 -0
- package/dist/components/divider/index.js +13 -0
- package/dist/components/field-group/index.cjs +27 -0
- package/dist/components/field-group/index.d.cts +270 -0
- package/dist/components/field-group/index.d.ts +270 -0
- package/dist/components/field-group/index.js +27 -0
- package/dist/components/input-otp/index.cjs +29 -0
- package/dist/components/input-otp/index.d.cts +325 -0
- package/dist/components/input-otp/index.d.ts +325 -0
- package/dist/components/input-otp/index.js +29 -0
- package/dist/components/menu/index.cjs +49 -0
- package/dist/components/menu/index.d.cts +351 -0
- package/dist/components/menu/index.d.ts +351 -0
- package/dist/components/menu/index.js +49 -0
- package/dist/components/popover/index.cjs +38 -0
- package/dist/components/popover/index.d.cts +254 -0
- package/dist/components/popover/index.d.ts +254 -0
- package/dist/components/popover/index.js +38 -0
- package/dist/components/radio/index.cjs +26 -0
- package/dist/components/radio/index.d.cts +1102 -0
- package/dist/components/radio/index.d.ts +1102 -0
- package/dist/components/radio/index.js +26 -0
- package/dist/components/select/index.cjs +50 -0
- package/dist/components/select/index.d.cts +498 -0
- package/dist/components/select/index.d.ts +498 -0
- package/dist/components/select/index.js +50 -0
- package/dist/components/skeleton/index.cjs +11 -0
- package/dist/components/skeleton/index.d.cts +111 -0
- package/dist/components/skeleton/index.d.ts +111 -0
- package/dist/components/skeleton/index.js +11 -0
- package/dist/components/spinner/index.cjs +17 -0
- package/dist/components/spinner/index.d.cts +104 -0
- package/dist/components/spinner/index.d.ts +104 -0
- package/dist/components/spinner/index.js +17 -0
- package/dist/components/switch/index.cjs +27 -0
- package/dist/components/switch/index.d.cts +1154 -0
- package/dist/components/switch/index.d.ts +1154 -0
- package/dist/components/switch/index.js +27 -0
- package/dist/components/tabs/index.cjs +33 -0
- package/dist/components/tabs/index.d.cts +261 -0
- package/dist/components/tabs/index.d.ts +261 -0
- package/dist/components/tabs/index.js +33 -0
- package/dist/components/text-area/index.cjs +14 -0
- package/dist/components/text-area/index.d.cts +73 -0
- package/dist/components/text-area/index.d.ts +73 -0
- package/dist/components/text-area/index.js +14 -0
- package/dist/components/text-field/index.cjs +25 -0
- package/dist/components/text-field/index.d.cts +205 -0
- package/dist/components/text-field/index.d.ts +205 -0
- package/dist/components/text-field/index.js +25 -0
- package/dist/components/typography/index.cjs +15 -0
- package/dist/components/typography/index.d.cts +116 -0
- package/dist/components/typography/index.d.ts +116 -0
- package/dist/components/typography/index.js +15 -0
- package/dist/components/view/index.cjs +17 -0
- package/dist/components/view/index.d.cts +152 -0
- package/dist/components/view/index.d.ts +152 -0
- package/dist/components/view/index.js +17 -0
- package/dist/create-recipe-BdVd2ffi.d.ts +114 -0
- package/dist/create-recipe-dC7wMfnj.d.cts +114 -0
- package/dist/icon.type-Kml72iSz.d.ts +73 -0
- package/dist/icon.type-d_i9ma-i.d.cts +73 -0
- package/dist/index.cjs +423 -5
- package/dist/index.d.cts +119 -4
- package/dist/index.d.ts +119 -4
- package/dist/index.js +445 -27
- package/dist/placement-DHa0Rrh1.d.cts +38 -0
- package/dist/placement-DHa0Rrh1.d.ts +38 -0
- package/dist/pressable-feedback.type-BA2C9sSz.d.cts +127 -0
- package/dist/pressable-feedback.type-Bs4dQlGj.d.ts +127 -0
- package/dist/style-props.type-CfnoGEP7.d.cts +31 -0
- package/dist/style-props.type-CfnoGEP7.d.ts +31 -0
- package/dist/system/index.cjs +73 -4
- package/dist/system/index.d.cts +379 -193
- package/dist/system/index.d.ts +379 -193
- package/dist/system/index.js +87 -18
- package/dist/text-field.type-0l73acce.d.ts +167 -0
- package/dist/text-field.type-DBh06DU5.d.cts +167 -0
- package/dist/theme/index.cjs +5 -3
- package/dist/theme/index.d.cts +55 -24
- package/dist/theme/index.d.ts +55 -24
- package/dist/theme/index.js +4 -2
- package/dist/{theme.type-C9bFJKFm.d.cts → theme.type-C2gNHpEx.d.cts} +1 -1
- package/dist/{theme.type-C9bFJKFm.d.ts → theme.type-C2gNHpEx.d.ts} +1 -1
- package/package.json +264 -18
- package/dist/chunk-ECDWSSHJ.js +0 -688
- package/dist/chunk-IYFGO523.cjs +0 -688
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
import * as react from 'react';
|
|
2
|
+
import { ReactNode } from 'react';
|
|
3
|
+
import { ViewProps, StyleProp, ViewStyle, View } from 'react-native';
|
|
4
|
+
import { V as ViewStyleProps } from '../../style-props.type-CfnoGEP7.cjs';
|
|
5
|
+
import { R as RadiusKey } from '../../theme.type-C2gNHpEx.cjs';
|
|
6
|
+
import { R as Recipe, a as StyleFn } from '../../create-recipe-dC7wMfnj.cjs';
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* The shape of what has not arrived yet.
|
|
10
|
+
*
|
|
11
|
+
* ```tsx
|
|
12
|
+
* <Skeleton width={140} height={20} />
|
|
13
|
+
* <Skeleton width={48} height={48} radius="full" />
|
|
14
|
+
*
|
|
15
|
+
* <Skeleton isLoading={!user} height={20} width={140}>
|
|
16
|
+
* <Typography>{user?.name}</Typography>
|
|
17
|
+
* </Skeleton>
|
|
18
|
+
* ```
|
|
19
|
+
*
|
|
20
|
+
* **One node and no slots.** A placeholder is a rectangle; there is nothing inside it to
|
|
21
|
+
* name. A paragraph of them is three of these in a `Column`, which is composition doing
|
|
22
|
+
* what a `lines={3}` prop would otherwise hard-code — including the last line being
|
|
23
|
+
* shorter, which is the only reason the paragraph reads as a paragraph.
|
|
24
|
+
*
|
|
25
|
+
* **It has no `size`, and that is the design.** Only the caller knows the shape of the
|
|
26
|
+
* thing that is missing, so R14's `width` and `height` are the whole sizing API — full
|
|
27
|
+
* React Native names and values, `width="60%"` as readily as `width={140}`. A `size`
|
|
28
|
+
* token here would be a scale of rectangles nobody's content happens to be.
|
|
29
|
+
*
|
|
30
|
+
* **`isLoading={false}` renders `children`**, which is what makes it a gate rather than a
|
|
31
|
+
* shape you mount and unmount around your own content.
|
|
32
|
+
*/
|
|
33
|
+
declare const Skeleton: react.ForwardRefExoticComponent<Omit<ViewProps, "style"> & {
|
|
34
|
+
radius?: RadiusKey;
|
|
35
|
+
color?: string;
|
|
36
|
+
isLoading?: boolean;
|
|
37
|
+
animation?: boolean;
|
|
38
|
+
children?: react.ReactNode;
|
|
39
|
+
style?: StyleProp<ViewStyle>;
|
|
40
|
+
} & Omit<ViewStyleProps, "color" | "pointerEvents" | "style" | "children" | "hitSlop" | "id" | "needsOffscreenAlphaCompositing" | "onLayout" | "removeClippedSubviews" | "testID" | "nativeID" | "collapsable" | "collapsableChildren" | "onBlur" | "onFocus" | "renderToHardwareTextureAndroid" | "focusable" | "tabIndex" | "shouldRasterizeIOS" | "isTVSelectable" | "hasTVPreferredFocus" | "tvParallaxShiftDistanceX" | "tvParallaxShiftDistanceY" | "tvParallaxTiltAngle" | "tvParallaxMagnification" | "onStartShouldSetResponder" | "onMoveShouldSetResponder" | "onResponderEnd" | "onResponderGrant" | "onResponderReject" | "onResponderMove" | "onResponderRelease" | "onResponderStart" | "onResponderTerminationRequest" | "onResponderTerminate" | "onStartShouldSetResponderCapture" | "onMoveShouldSetResponderCapture" | "onTouchStart" | "onTouchMove" | "onTouchEnd" | "onTouchCancel" | "onTouchEndCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerUp" | "onPointerUpCapture" | "accessible" | "accessibilityActions" | "accessibilityLabel" | "aria-label" | "accessibilityRole" | "accessibilityState" | "aria-busy" | "aria-checked" | "aria-disabled" | "aria-expanded" | "aria-selected" | "accessibilityHint" | "accessibilityValue" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "onAccessibilityAction" | "importantForAccessibility" | "aria-hidden" | "aria-modal" | "role" | "accessibilityLabelledBy" | "aria-labelledby" | "accessibilityLiveRegion" | "aria-live" | "screenReaderFocusable" | "accessibilityElementsHidden" | "accessibilityViewIsModal" | "onAccessibilityEscape" | "onAccessibilityTap" | "onMagicTap" | "accessibilityIgnoresInvertColors" | "accessibilityLanguage" | "accessibilityShowsLargeContentViewer" | "accessibilityLargeContentTitle" | "accessibilityRespondsToUserInteraction" | "radius" | "animation" | "isLoading"> & react.RefAttributes<View>>;
|
|
41
|
+
|
|
42
|
+
declare const skeletonRecipe: Recipe<"root", "default", {
|
|
43
|
+
readonly radius: Record<RadiusKey, StyleFn<"root">>;
|
|
44
|
+
}>;
|
|
45
|
+
|
|
46
|
+
type SkeletonSlot = 'root';
|
|
47
|
+
/**
|
|
48
|
+
* What the `Skeleton` itself understands. R14 — a name in here is the component's, so the
|
|
49
|
+
* style prop that shares it is not exposed: `color` is R7's tint.
|
|
50
|
+
*
|
|
51
|
+
* **No `variant`.** It had two — the neutral fill and that fill at half — sold as the two
|
|
52
|
+
* backgrounds a placeholder is drawn on. Measured, the second is *less* visible than the
|
|
53
|
+
* first on every surface in both modes, so it was never the answer to "this block reads as
|
|
54
|
+
* a hole"; and on a `secondary` `Card` in dark mode both resolve to the surface's own
|
|
55
|
+
* `#27272a` and vanish. A skeleton has to contrast with whatever is under it, and a fixed
|
|
56
|
+
* token cannot know what that is — two frozen values were never going to cover three
|
|
57
|
+
* surfaces times two modes. `color` is the way past it, and it is honest about being a
|
|
58
|
+
* raw value rather than a name that promises a system.
|
|
59
|
+
*
|
|
60
|
+
* **No `asChild`** (R12), because `children` is already taken and means the opposite of
|
|
61
|
+
* what the prop would need it to. Here it is the content the block stands in for — what
|
|
62
|
+
* renders once `isLoading` is `false` — while `asChild` hands `Slot` an element to merge
|
|
63
|
+
* the block's own styles into. One `children` with two meanings, disambiguated by a second
|
|
64
|
+
* prop, is the kind of API this library exists not to ship. Styling is the escape hatch
|
|
65
|
+
* instead, and R14 gives every `ViewStyle` key as a prop.
|
|
66
|
+
*/
|
|
67
|
+
type SkeletonOwnProps = {
|
|
68
|
+
/**
|
|
69
|
+
* The corner. `full` is the circle an avatar placeholder needs, and it is why this is a
|
|
70
|
+
* prop rather than the caller's `borderRadius` — a circle is a shape the vocabulary
|
|
71
|
+
* names, and it has to survive a theme redrawing every corner in the library.
|
|
72
|
+
*/
|
|
73
|
+
radius?: RadiusKey;
|
|
74
|
+
/**
|
|
75
|
+
* A raw tint (`'#7c3aed'`), never a token (R7). There is one thing to colour on a block,
|
|
76
|
+
* so it lands on the block.
|
|
77
|
+
*/
|
|
78
|
+
color?: string;
|
|
79
|
+
/**
|
|
80
|
+
* `false` swaps the block for `children`. It is the prop that makes the component a
|
|
81
|
+
* gate rather than a shape you mount and unmount around your own content:
|
|
82
|
+
*
|
|
83
|
+
* ```tsx
|
|
84
|
+
* <Skeleton isLoading={!user} height={20} width={140}>
|
|
85
|
+
* <Typography>{user?.name}</Typography>
|
|
86
|
+
* </Skeleton>
|
|
87
|
+
* ```
|
|
88
|
+
*
|
|
89
|
+
* @default true
|
|
90
|
+
*/
|
|
91
|
+
isLoading?: boolean;
|
|
92
|
+
/**
|
|
93
|
+
* `false` freezes the block at full opacity and mounts no worklet.
|
|
94
|
+
*
|
|
95
|
+
* A boolean rather than HeroUI's `'shimmer' | 'pulse' | 'none'`: a shimmer is a
|
|
96
|
+
* gradient sweeping across the block, a gradient needs `react-native-svg`, and that is
|
|
97
|
+
* an optional peer a component in the core cannot require. One animation, so there is
|
|
98
|
+
* nothing for a name to choose between.
|
|
99
|
+
*/
|
|
100
|
+
animation?: boolean;
|
|
101
|
+
/**
|
|
102
|
+
* What the block stands in for, rendered once `isLoading` is `false`. A skeleton with no
|
|
103
|
+
* children is a block that never resolves, which is the right thing for a placeholder
|
|
104
|
+
* whose content is mounted elsewhere.
|
|
105
|
+
*/
|
|
106
|
+
children?: ReactNode;
|
|
107
|
+
style?: StyleProp<ViewStyle>;
|
|
108
|
+
};
|
|
109
|
+
type SkeletonProps = Omit<ViewProps, 'style'> & SkeletonOwnProps & Omit<ViewStyleProps, keyof SkeletonOwnProps | keyof ViewProps>;
|
|
110
|
+
|
|
111
|
+
export { Skeleton, type SkeletonProps, type SkeletonSlot, skeletonRecipe };
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
import * as react from 'react';
|
|
2
|
+
import { ReactNode } from 'react';
|
|
3
|
+
import { ViewProps, StyleProp, ViewStyle, View } from 'react-native';
|
|
4
|
+
import { V as ViewStyleProps } from '../../style-props.type-CfnoGEP7.js';
|
|
5
|
+
import { R as RadiusKey } from '../../theme.type-C2gNHpEx.js';
|
|
6
|
+
import { R as Recipe, a as StyleFn } from '../../create-recipe-BdVd2ffi.js';
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* The shape of what has not arrived yet.
|
|
10
|
+
*
|
|
11
|
+
* ```tsx
|
|
12
|
+
* <Skeleton width={140} height={20} />
|
|
13
|
+
* <Skeleton width={48} height={48} radius="full" />
|
|
14
|
+
*
|
|
15
|
+
* <Skeleton isLoading={!user} height={20} width={140}>
|
|
16
|
+
* <Typography>{user?.name}</Typography>
|
|
17
|
+
* </Skeleton>
|
|
18
|
+
* ```
|
|
19
|
+
*
|
|
20
|
+
* **One node and no slots.** A placeholder is a rectangle; there is nothing inside it to
|
|
21
|
+
* name. A paragraph of them is three of these in a `Column`, which is composition doing
|
|
22
|
+
* what a `lines={3}` prop would otherwise hard-code — including the last line being
|
|
23
|
+
* shorter, which is the only reason the paragraph reads as a paragraph.
|
|
24
|
+
*
|
|
25
|
+
* **It has no `size`, and that is the design.** Only the caller knows the shape of the
|
|
26
|
+
* thing that is missing, so R14's `width` and `height` are the whole sizing API — full
|
|
27
|
+
* React Native names and values, `width="60%"` as readily as `width={140}`. A `size`
|
|
28
|
+
* token here would be a scale of rectangles nobody's content happens to be.
|
|
29
|
+
*
|
|
30
|
+
* **`isLoading={false}` renders `children`**, which is what makes it a gate rather than a
|
|
31
|
+
* shape you mount and unmount around your own content.
|
|
32
|
+
*/
|
|
33
|
+
declare const Skeleton: react.ForwardRefExoticComponent<Omit<ViewProps, "style"> & {
|
|
34
|
+
radius?: RadiusKey;
|
|
35
|
+
color?: string;
|
|
36
|
+
isLoading?: boolean;
|
|
37
|
+
animation?: boolean;
|
|
38
|
+
children?: react.ReactNode;
|
|
39
|
+
style?: StyleProp<ViewStyle>;
|
|
40
|
+
} & Omit<ViewStyleProps, "color" | "pointerEvents" | "style" | "children" | "hitSlop" | "id" | "needsOffscreenAlphaCompositing" | "onLayout" | "removeClippedSubviews" | "testID" | "nativeID" | "collapsable" | "collapsableChildren" | "onBlur" | "onFocus" | "renderToHardwareTextureAndroid" | "focusable" | "tabIndex" | "shouldRasterizeIOS" | "isTVSelectable" | "hasTVPreferredFocus" | "tvParallaxShiftDistanceX" | "tvParallaxShiftDistanceY" | "tvParallaxTiltAngle" | "tvParallaxMagnification" | "onStartShouldSetResponder" | "onMoveShouldSetResponder" | "onResponderEnd" | "onResponderGrant" | "onResponderReject" | "onResponderMove" | "onResponderRelease" | "onResponderStart" | "onResponderTerminationRequest" | "onResponderTerminate" | "onStartShouldSetResponderCapture" | "onMoveShouldSetResponderCapture" | "onTouchStart" | "onTouchMove" | "onTouchEnd" | "onTouchCancel" | "onTouchEndCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerUp" | "onPointerUpCapture" | "accessible" | "accessibilityActions" | "accessibilityLabel" | "aria-label" | "accessibilityRole" | "accessibilityState" | "aria-busy" | "aria-checked" | "aria-disabled" | "aria-expanded" | "aria-selected" | "accessibilityHint" | "accessibilityValue" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "onAccessibilityAction" | "importantForAccessibility" | "aria-hidden" | "aria-modal" | "role" | "accessibilityLabelledBy" | "aria-labelledby" | "accessibilityLiveRegion" | "aria-live" | "screenReaderFocusable" | "accessibilityElementsHidden" | "accessibilityViewIsModal" | "onAccessibilityEscape" | "onAccessibilityTap" | "onMagicTap" | "accessibilityIgnoresInvertColors" | "accessibilityLanguage" | "accessibilityShowsLargeContentViewer" | "accessibilityLargeContentTitle" | "accessibilityRespondsToUserInteraction" | "radius" | "animation" | "isLoading"> & react.RefAttributes<View>>;
|
|
41
|
+
|
|
42
|
+
declare const skeletonRecipe: Recipe<"root", "default", {
|
|
43
|
+
readonly radius: Record<RadiusKey, StyleFn<"root">>;
|
|
44
|
+
}>;
|
|
45
|
+
|
|
46
|
+
type SkeletonSlot = 'root';
|
|
47
|
+
/**
|
|
48
|
+
* What the `Skeleton` itself understands. R14 — a name in here is the component's, so the
|
|
49
|
+
* style prop that shares it is not exposed: `color` is R7's tint.
|
|
50
|
+
*
|
|
51
|
+
* **No `variant`.** It had two — the neutral fill and that fill at half — sold as the two
|
|
52
|
+
* backgrounds a placeholder is drawn on. Measured, the second is *less* visible than the
|
|
53
|
+
* first on every surface in both modes, so it was never the answer to "this block reads as
|
|
54
|
+
* a hole"; and on a `secondary` `Card` in dark mode both resolve to the surface's own
|
|
55
|
+
* `#27272a` and vanish. A skeleton has to contrast with whatever is under it, and a fixed
|
|
56
|
+
* token cannot know what that is — two frozen values were never going to cover three
|
|
57
|
+
* surfaces times two modes. `color` is the way past it, and it is honest about being a
|
|
58
|
+
* raw value rather than a name that promises a system.
|
|
59
|
+
*
|
|
60
|
+
* **No `asChild`** (R12), because `children` is already taken and means the opposite of
|
|
61
|
+
* what the prop would need it to. Here it is the content the block stands in for — what
|
|
62
|
+
* renders once `isLoading` is `false` — while `asChild` hands `Slot` an element to merge
|
|
63
|
+
* the block's own styles into. One `children` with two meanings, disambiguated by a second
|
|
64
|
+
* prop, is the kind of API this library exists not to ship. Styling is the escape hatch
|
|
65
|
+
* instead, and R14 gives every `ViewStyle` key as a prop.
|
|
66
|
+
*/
|
|
67
|
+
type SkeletonOwnProps = {
|
|
68
|
+
/**
|
|
69
|
+
* The corner. `full` is the circle an avatar placeholder needs, and it is why this is a
|
|
70
|
+
* prop rather than the caller's `borderRadius` — a circle is a shape the vocabulary
|
|
71
|
+
* names, and it has to survive a theme redrawing every corner in the library.
|
|
72
|
+
*/
|
|
73
|
+
radius?: RadiusKey;
|
|
74
|
+
/**
|
|
75
|
+
* A raw tint (`'#7c3aed'`), never a token (R7). There is one thing to colour on a block,
|
|
76
|
+
* so it lands on the block.
|
|
77
|
+
*/
|
|
78
|
+
color?: string;
|
|
79
|
+
/**
|
|
80
|
+
* `false` swaps the block for `children`. It is the prop that makes the component a
|
|
81
|
+
* gate rather than a shape you mount and unmount around your own content:
|
|
82
|
+
*
|
|
83
|
+
* ```tsx
|
|
84
|
+
* <Skeleton isLoading={!user} height={20} width={140}>
|
|
85
|
+
* <Typography>{user?.name}</Typography>
|
|
86
|
+
* </Skeleton>
|
|
87
|
+
* ```
|
|
88
|
+
*
|
|
89
|
+
* @default true
|
|
90
|
+
*/
|
|
91
|
+
isLoading?: boolean;
|
|
92
|
+
/**
|
|
93
|
+
* `false` freezes the block at full opacity and mounts no worklet.
|
|
94
|
+
*
|
|
95
|
+
* A boolean rather than HeroUI's `'shimmer' | 'pulse' | 'none'`: a shimmer is a
|
|
96
|
+
* gradient sweeping across the block, a gradient needs `react-native-svg`, and that is
|
|
97
|
+
* an optional peer a component in the core cannot require. One animation, so there is
|
|
98
|
+
* nothing for a name to choose between.
|
|
99
|
+
*/
|
|
100
|
+
animation?: boolean;
|
|
101
|
+
/**
|
|
102
|
+
* What the block stands in for, rendered once `isLoading` is `false`. A skeleton with no
|
|
103
|
+
* children is a block that never resolves, which is the right thing for a placeholder
|
|
104
|
+
* whose content is mounted elsewhere.
|
|
105
|
+
*/
|
|
106
|
+
children?: ReactNode;
|
|
107
|
+
style?: StyleProp<ViewStyle>;
|
|
108
|
+
};
|
|
109
|
+
type SkeletonProps = Omit<ViewProps, 'style'> & SkeletonOwnProps & Omit<ViewStyleProps, keyof SkeletonOwnProps | keyof ViewProps>;
|
|
110
|
+
|
|
111
|
+
export { Skeleton, type SkeletonProps, type SkeletonSlot, skeletonRecipe };
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
var _chunkXWNG2U4Kcjs = require('../../chunk-XWNG2U4K.cjs');
|
|
5
|
+
require('../../chunk-XSQPVDFH.cjs');
|
|
6
|
+
require('../../chunk-WFEMJCXO.cjs');
|
|
7
|
+
require('../../chunk-7EIHHOHP.cjs');
|
|
8
|
+
require('../../chunk-7DPL3ZDS.cjs');
|
|
9
|
+
require('../../chunk-EJQCQPET.cjs');
|
|
10
|
+
require('../../chunk-FNEUOBCV.cjs');
|
|
11
|
+
require('../../chunk-57SJ4LJF.cjs');
|
|
12
|
+
require('../../chunk-H4E4HDEP.cjs');
|
|
13
|
+
require('../../chunk-TK44VBIE.cjs');
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
exports.Spinner = _chunkXWNG2U4Kcjs.Spinner; exports.spinnerRecipe = _chunkXWNG2U4Kcjs.spinnerRecipe;
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
import * as react from 'react';
|
|
2
|
+
import * as react_native from 'react-native';
|
|
3
|
+
import { ViewProps, StyleProp, ViewStyle, View } from 'react-native';
|
|
4
|
+
import { V as ViewStyleProps } from '../../style-props.type-CfnoGEP7.cjs';
|
|
5
|
+
import { S as Size, X as XAUITheme } from '../../theme.type-C2gNHpEx.cjs';
|
|
6
|
+
import { R as Recipe, S as SlotStyles } from '../../create-recipe-dC7wMfnj.cjs';
|
|
7
|
+
|
|
8
|
+
type SpinnerSlot = 'root' | 'arc';
|
|
9
|
+
/**
|
|
10
|
+
* Seven names, and each one is **an ink** — a spinner has no fill for a variant to paint.
|
|
11
|
+
*
|
|
12
|
+
* That is what makes this a narrowing of §1 bis rather than a second vocabulary. On a
|
|
13
|
+
* `Chip`, `fg` means "the colour that reads *on* this variant's surface", which is why
|
|
14
|
+
* `primary` resolves to `accentForeground` — white. A spinner has no surface, so here a
|
|
15
|
+
* variant names the colour of the thing itself:
|
|
16
|
+
*
|
|
17
|
+
* - **`primary`** — `accent`. The brand, waiting.
|
|
18
|
+
* - **`secondary`** — the accent as it reads on the page rather than on a fill.
|
|
19
|
+
* - **`default`** — `foreground`. A spinner beside text, in the text's own ink.
|
|
20
|
+
* - **`tertiary`** — `muted`. The quiet one, for a refresh nobody is waiting on.
|
|
21
|
+
* - **`success` / `warning` / `danger`** — the three status families, for the wait whose
|
|
22
|
+
* outcome is already named: deleting is a `danger` wait.
|
|
23
|
+
*
|
|
24
|
+
* **No `ghost`**, because a spinner with no ink is not a spinner, and **no `-soft`
|
|
25
|
+
* slices**, because a soft slice is a fill softened and there is no fill here. Both are
|
|
26
|
+
* absences with a reason, which is the test §1 bis sets for narrowing the union.
|
|
27
|
+
*/
|
|
28
|
+
type SpinnerVariant = 'primary' | 'secondary' | 'default' | 'tertiary' | 'success' | 'warning' | 'danger';
|
|
29
|
+
type SpinnerSize = Size;
|
|
30
|
+
/**
|
|
31
|
+
* What the `Spinner` itself understands. R14 — a name in here is the component's, so the
|
|
32
|
+
* style prop that shares it is not exposed: `size` is the spinner's scale and never
|
|
33
|
+
* `ViewStyle`'s, and `color` is R7's tint.
|
|
34
|
+
*
|
|
35
|
+
* **No `asChild`**, and this is the one root in the library without one (R12). `Slot`
|
|
36
|
+
* merges a root's props into a single element, and that element keeps its own children —
|
|
37
|
+
* so a caller's element could become the track, but the arc is a second node it has no way
|
|
38
|
+
* to receive. Handing over the track alone would render a ring that never turns, silently.
|
|
39
|
+
* Styling is the escape hatch instead, and R14 gives every `ViewStyle` key as a prop.
|
|
40
|
+
*/
|
|
41
|
+
type SpinnerOwnProps = {
|
|
42
|
+
variant?: SpinnerVariant;
|
|
43
|
+
/** The diameter, and the thickness that goes with it. */
|
|
44
|
+
size?: SpinnerSize;
|
|
45
|
+
/**
|
|
46
|
+
* A raw tint (`'#7c3aed'`), never a token (R7). There is one thing to colour on a
|
|
47
|
+
* spinner, so it lands on the ring — and on the track behind it, at the same fraction
|
|
48
|
+
* the variant's own ink is faded to.
|
|
49
|
+
*/
|
|
50
|
+
color?: string;
|
|
51
|
+
/**
|
|
52
|
+
* `false` stops the rotation and mounts no worklet. The ring stays, so a list of rows
|
|
53
|
+
* switched off with `animation={false}` does not change height.
|
|
54
|
+
*
|
|
55
|
+
* A boolean rather than the `AnimationProp` union `PressableFeedback` takes: there is
|
|
56
|
+
* one animation here, so there is nothing for an object to switch off one at a time.
|
|
57
|
+
*/
|
|
58
|
+
animation?: boolean;
|
|
59
|
+
style?: StyleProp<ViewStyle>;
|
|
60
|
+
};
|
|
61
|
+
type SpinnerProps = Omit<ViewProps, 'style'> & SpinnerOwnProps & Omit<ViewStyleProps, keyof SpinnerOwnProps | keyof ViewProps>;
|
|
62
|
+
|
|
63
|
+
/**
|
|
64
|
+
* The wait, drawn.
|
|
65
|
+
*
|
|
66
|
+
* ```tsx
|
|
67
|
+
* <Spinner />
|
|
68
|
+
* <Spinner variant="danger" size="sm" />
|
|
69
|
+
* <Spinner color="#7c3aed" accessibilityLabel="Chargement des projets" />
|
|
70
|
+
* ```
|
|
71
|
+
*
|
|
72
|
+
* **Two rings and no slots.** The root is the track — the full circle, in the variant's
|
|
73
|
+
* ink at a fraction of its opacity — and its one child is the arc that turns over it,
|
|
74
|
+
* the same circle with a quarter missing. There is nothing between them for a slot to
|
|
75
|
+
* name, and the two are one figure rather than two parts.
|
|
76
|
+
*
|
|
77
|
+
* It is HeroUI's spinner drawn with borders instead of a gradient stroke. Theirs fades a
|
|
78
|
+
* single arc from opaque to 55%, which needs an SVG `linearGradient` and therefore
|
|
79
|
+
* `react-native-svg` — an optional peer, which a component in the fifteen-component core
|
|
80
|
+
* cannot require. Two circles of one ink at two opacities read as the same figure and
|
|
81
|
+
* cost two views.
|
|
82
|
+
*
|
|
83
|
+
* **`size` is the diameter**, and the only measurement a circle has. A spinner that filled
|
|
84
|
+
* its parent would be a progress bar, so R14's `width` is available and deliberately not
|
|
85
|
+
* what `size` means.
|
|
86
|
+
*/
|
|
87
|
+
declare const Spinner: react.ForwardRefExoticComponent<Omit<react_native.ViewProps, "style"> & {
|
|
88
|
+
variant?: SpinnerVariant;
|
|
89
|
+
size?: SpinnerSize;
|
|
90
|
+
color?: string;
|
|
91
|
+
animation?: boolean;
|
|
92
|
+
style?: StyleProp<ViewStyle>;
|
|
93
|
+
} & Omit<ViewStyleProps, "color" | "pointerEvents" | "style" | "children" | "size" | "hitSlop" | "id" | "needsOffscreenAlphaCompositing" | "onLayout" | "removeClippedSubviews" | "testID" | "nativeID" | "collapsable" | "collapsableChildren" | "onBlur" | "onFocus" | "renderToHardwareTextureAndroid" | "focusable" | "tabIndex" | "shouldRasterizeIOS" | "isTVSelectable" | "hasTVPreferredFocus" | "tvParallaxShiftDistanceX" | "tvParallaxShiftDistanceY" | "tvParallaxTiltAngle" | "tvParallaxMagnification" | "onStartShouldSetResponder" | "onMoveShouldSetResponder" | "onResponderEnd" | "onResponderGrant" | "onResponderReject" | "onResponderMove" | "onResponderRelease" | "onResponderStart" | "onResponderTerminationRequest" | "onResponderTerminate" | "onStartShouldSetResponderCapture" | "onMoveShouldSetResponderCapture" | "onTouchStart" | "onTouchMove" | "onTouchEnd" | "onTouchCancel" | "onTouchEndCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerUp" | "onPointerUpCapture" | "accessible" | "accessibilityActions" | "accessibilityLabel" | "aria-label" | "accessibilityRole" | "accessibilityState" | "aria-busy" | "aria-checked" | "aria-disabled" | "aria-expanded" | "aria-selected" | "accessibilityHint" | "accessibilityValue" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "onAccessibilityAction" | "importantForAccessibility" | "aria-hidden" | "aria-modal" | "role" | "accessibilityLabelledBy" | "aria-labelledby" | "accessibilityLiveRegion" | "aria-live" | "screenReaderFocusable" | "accessibilityElementsHidden" | "accessibilityViewIsModal" | "onAccessibilityEscape" | "onAccessibilityTap" | "onMagicTap" | "accessibilityIgnoresInvertColors" | "accessibilityLanguage" | "accessibilityShowsLargeContentViewer" | "accessibilityLargeContentTitle" | "accessibilityRespondsToUserInteraction" | "variant" | "animation"> & react.RefAttributes<View>>;
|
|
94
|
+
|
|
95
|
+
declare const spinnerRecipe: Recipe<"root" | "arc", SpinnerVariant, {
|
|
96
|
+
readonly size: {
|
|
97
|
+
readonly xs: (theme: XAUITheme) => SlotStyles<SpinnerSlot>;
|
|
98
|
+
readonly sm: (theme: XAUITheme) => SlotStyles<SpinnerSlot>;
|
|
99
|
+
readonly md: (theme: XAUITheme) => SlotStyles<SpinnerSlot>;
|
|
100
|
+
readonly lg: (theme: XAUITheme) => SlotStyles<SpinnerSlot>;
|
|
101
|
+
};
|
|
102
|
+
}>;
|
|
103
|
+
|
|
104
|
+
export { Spinner, type SpinnerProps, type SpinnerSize, type SpinnerSlot, type SpinnerVariant, spinnerRecipe };
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
import * as react from 'react';
|
|
2
|
+
import * as react_native from 'react-native';
|
|
3
|
+
import { ViewProps, StyleProp, ViewStyle, View } from 'react-native';
|
|
4
|
+
import { V as ViewStyleProps } from '../../style-props.type-CfnoGEP7.js';
|
|
5
|
+
import { S as Size, X as XAUITheme } from '../../theme.type-C2gNHpEx.js';
|
|
6
|
+
import { R as Recipe, S as SlotStyles } from '../../create-recipe-BdVd2ffi.js';
|
|
7
|
+
|
|
8
|
+
type SpinnerSlot = 'root' | 'arc';
|
|
9
|
+
/**
|
|
10
|
+
* Seven names, and each one is **an ink** — a spinner has no fill for a variant to paint.
|
|
11
|
+
*
|
|
12
|
+
* That is what makes this a narrowing of §1 bis rather than a second vocabulary. On a
|
|
13
|
+
* `Chip`, `fg` means "the colour that reads *on* this variant's surface", which is why
|
|
14
|
+
* `primary` resolves to `accentForeground` — white. A spinner has no surface, so here a
|
|
15
|
+
* variant names the colour of the thing itself:
|
|
16
|
+
*
|
|
17
|
+
* - **`primary`** — `accent`. The brand, waiting.
|
|
18
|
+
* - **`secondary`** — the accent as it reads on the page rather than on a fill.
|
|
19
|
+
* - **`default`** — `foreground`. A spinner beside text, in the text's own ink.
|
|
20
|
+
* - **`tertiary`** — `muted`. The quiet one, for a refresh nobody is waiting on.
|
|
21
|
+
* - **`success` / `warning` / `danger`** — the three status families, for the wait whose
|
|
22
|
+
* outcome is already named: deleting is a `danger` wait.
|
|
23
|
+
*
|
|
24
|
+
* **No `ghost`**, because a spinner with no ink is not a spinner, and **no `-soft`
|
|
25
|
+
* slices**, because a soft slice is a fill softened and there is no fill here. Both are
|
|
26
|
+
* absences with a reason, which is the test §1 bis sets for narrowing the union.
|
|
27
|
+
*/
|
|
28
|
+
type SpinnerVariant = 'primary' | 'secondary' | 'default' | 'tertiary' | 'success' | 'warning' | 'danger';
|
|
29
|
+
type SpinnerSize = Size;
|
|
30
|
+
/**
|
|
31
|
+
* What the `Spinner` itself understands. R14 — a name in here is the component's, so the
|
|
32
|
+
* style prop that shares it is not exposed: `size` is the spinner's scale and never
|
|
33
|
+
* `ViewStyle`'s, and `color` is R7's tint.
|
|
34
|
+
*
|
|
35
|
+
* **No `asChild`**, and this is the one root in the library without one (R12). `Slot`
|
|
36
|
+
* merges a root's props into a single element, and that element keeps its own children —
|
|
37
|
+
* so a caller's element could become the track, but the arc is a second node it has no way
|
|
38
|
+
* to receive. Handing over the track alone would render a ring that never turns, silently.
|
|
39
|
+
* Styling is the escape hatch instead, and R14 gives every `ViewStyle` key as a prop.
|
|
40
|
+
*/
|
|
41
|
+
type SpinnerOwnProps = {
|
|
42
|
+
variant?: SpinnerVariant;
|
|
43
|
+
/** The diameter, and the thickness that goes with it. */
|
|
44
|
+
size?: SpinnerSize;
|
|
45
|
+
/**
|
|
46
|
+
* A raw tint (`'#7c3aed'`), never a token (R7). There is one thing to colour on a
|
|
47
|
+
* spinner, so it lands on the ring — and on the track behind it, at the same fraction
|
|
48
|
+
* the variant's own ink is faded to.
|
|
49
|
+
*/
|
|
50
|
+
color?: string;
|
|
51
|
+
/**
|
|
52
|
+
* `false` stops the rotation and mounts no worklet. The ring stays, so a list of rows
|
|
53
|
+
* switched off with `animation={false}` does not change height.
|
|
54
|
+
*
|
|
55
|
+
* A boolean rather than the `AnimationProp` union `PressableFeedback` takes: there is
|
|
56
|
+
* one animation here, so there is nothing for an object to switch off one at a time.
|
|
57
|
+
*/
|
|
58
|
+
animation?: boolean;
|
|
59
|
+
style?: StyleProp<ViewStyle>;
|
|
60
|
+
};
|
|
61
|
+
type SpinnerProps = Omit<ViewProps, 'style'> & SpinnerOwnProps & Omit<ViewStyleProps, keyof SpinnerOwnProps | keyof ViewProps>;
|
|
62
|
+
|
|
63
|
+
/**
|
|
64
|
+
* The wait, drawn.
|
|
65
|
+
*
|
|
66
|
+
* ```tsx
|
|
67
|
+
* <Spinner />
|
|
68
|
+
* <Spinner variant="danger" size="sm" />
|
|
69
|
+
* <Spinner color="#7c3aed" accessibilityLabel="Chargement des projets" />
|
|
70
|
+
* ```
|
|
71
|
+
*
|
|
72
|
+
* **Two rings and no slots.** The root is the track — the full circle, in the variant's
|
|
73
|
+
* ink at a fraction of its opacity — and its one child is the arc that turns over it,
|
|
74
|
+
* the same circle with a quarter missing. There is nothing between them for a slot to
|
|
75
|
+
* name, and the two are one figure rather than two parts.
|
|
76
|
+
*
|
|
77
|
+
* It is HeroUI's spinner drawn with borders instead of a gradient stroke. Theirs fades a
|
|
78
|
+
* single arc from opaque to 55%, which needs an SVG `linearGradient` and therefore
|
|
79
|
+
* `react-native-svg` — an optional peer, which a component in the fifteen-component core
|
|
80
|
+
* cannot require. Two circles of one ink at two opacities read as the same figure and
|
|
81
|
+
* cost two views.
|
|
82
|
+
*
|
|
83
|
+
* **`size` is the diameter**, and the only measurement a circle has. A spinner that filled
|
|
84
|
+
* its parent would be a progress bar, so R14's `width` is available and deliberately not
|
|
85
|
+
* what `size` means.
|
|
86
|
+
*/
|
|
87
|
+
declare const Spinner: react.ForwardRefExoticComponent<Omit<react_native.ViewProps, "style"> & {
|
|
88
|
+
variant?: SpinnerVariant;
|
|
89
|
+
size?: SpinnerSize;
|
|
90
|
+
color?: string;
|
|
91
|
+
animation?: boolean;
|
|
92
|
+
style?: StyleProp<ViewStyle>;
|
|
93
|
+
} & Omit<ViewStyleProps, "color" | "pointerEvents" | "style" | "children" | "size" | "hitSlop" | "id" | "needsOffscreenAlphaCompositing" | "onLayout" | "removeClippedSubviews" | "testID" | "nativeID" | "collapsable" | "collapsableChildren" | "onBlur" | "onFocus" | "renderToHardwareTextureAndroid" | "focusable" | "tabIndex" | "shouldRasterizeIOS" | "isTVSelectable" | "hasTVPreferredFocus" | "tvParallaxShiftDistanceX" | "tvParallaxShiftDistanceY" | "tvParallaxTiltAngle" | "tvParallaxMagnification" | "onStartShouldSetResponder" | "onMoveShouldSetResponder" | "onResponderEnd" | "onResponderGrant" | "onResponderReject" | "onResponderMove" | "onResponderRelease" | "onResponderStart" | "onResponderTerminationRequest" | "onResponderTerminate" | "onStartShouldSetResponderCapture" | "onMoveShouldSetResponderCapture" | "onTouchStart" | "onTouchMove" | "onTouchEnd" | "onTouchCancel" | "onTouchEndCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerUp" | "onPointerUpCapture" | "accessible" | "accessibilityActions" | "accessibilityLabel" | "aria-label" | "accessibilityRole" | "accessibilityState" | "aria-busy" | "aria-checked" | "aria-disabled" | "aria-expanded" | "aria-selected" | "accessibilityHint" | "accessibilityValue" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "onAccessibilityAction" | "importantForAccessibility" | "aria-hidden" | "aria-modal" | "role" | "accessibilityLabelledBy" | "aria-labelledby" | "accessibilityLiveRegion" | "aria-live" | "screenReaderFocusable" | "accessibilityElementsHidden" | "accessibilityViewIsModal" | "onAccessibilityEscape" | "onAccessibilityTap" | "onMagicTap" | "accessibilityIgnoresInvertColors" | "accessibilityLanguage" | "accessibilityShowsLargeContentViewer" | "accessibilityLargeContentTitle" | "accessibilityRespondsToUserInteraction" | "variant" | "animation"> & react.RefAttributes<View>>;
|
|
94
|
+
|
|
95
|
+
declare const spinnerRecipe: Recipe<"root" | "arc", SpinnerVariant, {
|
|
96
|
+
readonly size: {
|
|
97
|
+
readonly xs: (theme: XAUITheme) => SlotStyles<SpinnerSlot>;
|
|
98
|
+
readonly sm: (theme: XAUITheme) => SlotStyles<SpinnerSlot>;
|
|
99
|
+
readonly md: (theme: XAUITheme) => SlotStyles<SpinnerSlot>;
|
|
100
|
+
readonly lg: (theme: XAUITheme) => SlotStyles<SpinnerSlot>;
|
|
101
|
+
};
|
|
102
|
+
}>;
|
|
103
|
+
|
|
104
|
+
export { Spinner, type SpinnerProps, type SpinnerSize, type SpinnerSlot, type SpinnerVariant, spinnerRecipe };
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import {
|
|
2
|
+
Spinner,
|
|
3
|
+
spinnerRecipe
|
|
4
|
+
} from "../../chunk-LTX6TB5I.js";
|
|
5
|
+
import "../../chunk-3GFRSZYR.js";
|
|
6
|
+
import "../../chunk-NCTOTTVW.js";
|
|
7
|
+
import "../../chunk-F6W3JQ7K.js";
|
|
8
|
+
import "../../chunk-423RQBOX.js";
|
|
9
|
+
import "../../chunk-EGLLDKN6.js";
|
|
10
|
+
import "../../chunk-4GTAZM2C.js";
|
|
11
|
+
import "../../chunk-A3EGFI6T.js";
|
|
12
|
+
import "../../chunk-36PRYGAM.js";
|
|
13
|
+
import "../../chunk-M63GFNKV.js";
|
|
14
|
+
export {
|
|
15
|
+
Spinner,
|
|
16
|
+
spinnerRecipe
|
|
17
|
+
};
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
var _chunkDA3OKXHVcjs = require('../../chunk-DA3OKXHV.cjs');
|
|
10
|
+
require('../../chunk-7EIHHOHP.cjs');
|
|
11
|
+
require('../../chunk-3E7CDKFO.cjs');
|
|
12
|
+
require('../../chunk-7DPL3ZDS.cjs');
|
|
13
|
+
require('../../chunk-EJQCQPET.cjs');
|
|
14
|
+
require('../../chunk-FNEUOBCV.cjs');
|
|
15
|
+
require('../../chunk-57SJ4LJF.cjs');
|
|
16
|
+
require('../../chunk-7GHM4GKL.cjs');
|
|
17
|
+
require('../../chunk-H4E4HDEP.cjs');
|
|
18
|
+
require('../../chunk-TK44VBIE.cjs');
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
exports.Switch = _chunkDA3OKXHVcjs.Switch; exports.SwitchLabel = _chunkDA3OKXHVcjs.SwitchLabel; exports.SwitchRoot = _chunkDA3OKXHVcjs.SwitchRoot; exports.SwitchThumb = _chunkDA3OKXHVcjs.SwitchThumb; exports.SwitchTrack = _chunkDA3OKXHVcjs.SwitchTrack; exports.switchRecipe = _chunkDA3OKXHVcjs.switchRecipe; exports.useSwitch = _chunkDA3OKXHVcjs.useSwitch;
|