@webority/mobile-ui 0.150.0 → 0.153.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/canvas-kit/kit.js +10 -10
- package/dist/canvas-kit/manifest.json +139 -17
- package/dist/canvas-kit/release.json +6 -6
- package/lib/commonjs/components/AppBar/AppBar.js +1 -1
- package/lib/commonjs/components/AsyncBlock/AsyncBlock.js +1 -1
- package/lib/commonjs/components/Avatar/Avatar.js +1 -1
- package/lib/commonjs/components/Banner/Banner.js +1 -1
- package/lib/commonjs/components/BottomNavigation/BottomNavigation.js +1 -1
- package/lib/commonjs/components/Button/Button.js +1 -1
- package/lib/commonjs/components/Calendar/calendarStyles.js +1 -1
- package/lib/commonjs/components/DatePicker/DatePicker.js +1 -1
- package/lib/commonjs/components/FilePicker/FilePicker.js +1 -1
- package/lib/commonjs/components/ImageGallery/ImageGallery.js +1 -1
- package/lib/commonjs/components/NonModalBottomSheet/NonModalBottomSheet.js +1 -0
- package/lib/commonjs/components/NonModalBottomSheet/index.js +1 -0
- package/lib/commonjs/components/OptionSheet/OptionSheet.js +1 -1
- package/lib/commonjs/components/OptionSheet/optionAccessors.js +1 -1
- package/lib/commonjs/components/Repeater/Repeater.js +1 -1
- package/lib/commonjs/components/Toast/Toast.js +1 -1
- package/lib/commonjs/components/WheelPicker/Wheel.js +1 -1
- package/lib/commonjs/components/WheelPicker/WheelPicker.js +1 -1
- package/lib/commonjs/components/index.js +1 -1
- package/lib/commonjs/index.js +1 -1
- package/lib/commonjs/theme/tokens.generated.js +1 -1
- package/lib/module/components/AppBar/AppBar.js +1 -1
- package/lib/module/components/AsyncBlock/AsyncBlock.js +1 -1
- package/lib/module/components/Avatar/Avatar.js +1 -1
- package/lib/module/components/Banner/Banner.js +1 -1
- package/lib/module/components/BottomNavigation/BottomNavigation.js +1 -1
- package/lib/module/components/Button/Button.js +1 -1
- package/lib/module/components/Calendar/calendarStyles.js +1 -1
- package/lib/module/components/DatePicker/DatePicker.js +1 -1
- package/lib/module/components/FilePicker/FilePicker.js +1 -1
- package/lib/module/components/ImageGallery/ImageGallery.js +1 -1
- package/lib/module/components/NonModalBottomSheet/NonModalBottomSheet.js +1 -0
- package/lib/module/components/NonModalBottomSheet/index.js +1 -0
- package/lib/module/components/OptionSheet/OptionSheet.js +1 -1
- package/lib/module/components/OptionSheet/optionAccessors.js +1 -1
- package/lib/module/components/Repeater/Repeater.js +1 -1
- package/lib/module/components/Toast/Toast.js +1 -1
- package/lib/module/components/WheelPicker/Wheel.js +1 -1
- package/lib/module/components/WheelPicker/WheelPicker.js +1 -1
- package/lib/module/components/index.js +1 -1
- package/lib/module/index.js +1 -1
- package/lib/module/theme/tokens.generated.js +1 -1
- package/lib/typescript/commonjs/components/AsyncBlock/AsyncBlock.d.ts +2 -2
- package/lib/typescript/commonjs/components/Avatar/Avatar.d.ts +5 -3
- package/lib/typescript/commonjs/components/Button/Button.d.ts +7 -2
- package/lib/typescript/commonjs/components/NonModalBottomSheet/NonModalBottomSheet.d.ts +52 -0
- package/lib/typescript/commonjs/components/NonModalBottomSheet/index.d.ts +3 -0
- package/lib/typescript/commonjs/components/OptionSheet/OptionSheet.d.ts +6 -1
- package/lib/typescript/commonjs/components/OptionSheet/optionAccessors.d.ts +1 -0
- package/lib/typescript/commonjs/components/WheelPicker/Wheel.d.ts +4 -0
- package/lib/typescript/commonjs/components/WheelPicker/WheelPicker.d.ts +2 -0
- package/lib/typescript/commonjs/components/index.d.ts +2 -0
- package/lib/typescript/commonjs/index.d.ts +1 -1
- package/lib/typescript/module/components/AsyncBlock/AsyncBlock.d.ts +2 -2
- package/lib/typescript/module/components/Avatar/Avatar.d.ts +5 -3
- package/lib/typescript/module/components/Button/Button.d.ts +7 -2
- package/lib/typescript/module/components/NonModalBottomSheet/NonModalBottomSheet.d.ts +52 -0
- package/lib/typescript/module/components/NonModalBottomSheet/index.d.ts +3 -0
- package/lib/typescript/module/components/OptionSheet/OptionSheet.d.ts +6 -1
- package/lib/typescript/module/components/OptionSheet/optionAccessors.d.ts +1 -0
- package/lib/typescript/module/components/WheelPicker/Wheel.d.ts +4 -0
- package/lib/typescript/module/components/WheelPicker/WheelPicker.d.ts +2 -0
- package/lib/typescript/module/components/index.d.ts +2 -0
- package/lib/typescript/module/index.d.ts +1 -1
- package/package.json +7 -7
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";import{Fragment,useCallback,useMemo}from"react";import{StyleSheet,useWindowDimensions,View}from"react-native";import{useReducedMotion}from"../../hooks/useReducedMotion.js";import{useTheme}from"../../theme/index.js";import{assertValidValue}from"../../utils/assertValidValue.js";import{Chip}from"../Chip/index.js";import{Text}from"../Text/index.js";import{WHEEL_CENTER_OFFSET,WHEEL_VISIBLE_ITEMS,Wheel}from"./Wheel.js";import{jsx as _jsx,jsxs as _jsxs}from"react/jsx-runtime";const BASE_ITEM_HEIGHT=40,MAX_FONT_SCALE=1.5,DEFAULT_COLUMN_WIDTH=64,MAX_DURATION_MINUTES=1439;export const DEFAULT_WHEEL_PICKER_LABELS=Object.freeze({hours:"Hours",minutes:"Minutes",hourUnit:"hr",minuteUnit:"min",hourOne:"hour",hourMany:"hours",minuteOne:"minute",minuteMany:"minutes",value:"Value"});const range=(e,t,i=1)=>{const
|
|
1
|
+
"use strict";import{Fragment,useCallback,useMemo}from"react";import{StyleSheet,useWindowDimensions,View}from"react-native";import{useReducedMotion}from"../../hooks/useReducedMotion.js";import{useTheme}from"../../theme/index.js";import{assertValidValue}from"../../utils/assertValidValue.js";import{Chip}from"../Chip/index.js";import{Text}from"../Text/index.js";import{WHEEL_CENTER_OFFSET,WHEEL_VISIBLE_ITEMS,Wheel}from"./Wheel.js";import{jsx as _jsx,jsxs as _jsxs}from"react/jsx-runtime";const BASE_ITEM_HEIGHT=40,MAX_FONT_SCALE=1.5,DEFAULT_COLUMN_WIDTH=64,MAX_DURATION_MINUTES=1439;export const DEFAULT_WHEEL_PICKER_LABELS=Object.freeze({hours:"Hours",minutes:"Minutes",hourUnit:"hr",minuteUnit:"min",hourOne:"hour",hourMany:"hours",minuteOne:"minute",minuteMany:"minutes",value:"Value",typeAction:"Type a value",typeEditor:"Type a number"});const range=(e,t,i=1)=>{const o=[];for(let s=e;s<=t;s+=i)o.push(s);return o},plural=(e,t,i)=>`${e} ${1===e?t:i}`,formatPreset=(e,t,i)=>{const o=Math.floor(e/60),s=e%60;return 0===o?`${s} ${i}`:0===s?`${o} ${t}`:`${o} ${t} ${s} ${i}`},toItem=e=>"object"==typeof e?e:{value:e,label:String(e)},WheelPicker=e=>{const{haptic:t,disabled:i,testID:o,style:s,labels:n}=e;assertValidValue("WheelPicker","mode",e.mode,["columns","list","duration"]);const a=useTheme(),r=useReducedMotion(),{fontScale:l}=useWindowDimensions(),u=Math.min(Math.max(l,1),1.5),m=Math.round(40*u),d=useMemo(()=>buildStyles(a,m),[a,m]),h="list"===e.mode?e.items:void 0,c=useMemo(()=>h?.map(toItem),[h]),p="duration"===e.mode?e.minuteStep??1:1,b="duration"===e.mode?Math.max(0,Math.min(1439,Math.floor(e.maxMinutes??1/0))):0,y=Math.floor(b/60),f=useMemo(()=>({...DEFAULT_WHEEL_PICKER_LABELS,...n}),[n]),x="duration"===e.mode?e.presets:void 0;for(const e of x??[])if(!Number.isInteger(e)||e<0||e>b||e%p!==0)throw new Error(`WheelPicker preset ${e} must be a whole number of minutes from 0 to ${b} in steps of ${p}.`);const M=useCallback(e=>{const t=e===y?b%60:59;return Math.floor(t/p)*p},[y,b,p]),E="duration"===e.mode?e.value:0,_=useMemo(()=>{const e=Number.isFinite(E)?E:0,t=Math.max(0,Math.min(b,e)),i=Math.floor(t/60),o=Math.round(t%60/p)*p;return{hour:i,minute:Math.min(M(i),o)}},[E,b,p,M]),g=useMemo(()=>"duration"===e.mode?range(0,y).map(e=>({value:e,label:String(e),accessibilityLabel:plural(e,f.hourOne,f.hourMany)})):[],[e.mode,y,f]),j=M(_.hour),v=useMemo(()=>"duration"===e.mode?range(0,j,p).map(e=>({value:e,label:String(e).padStart(2,"0"),accessibilityLabel:plural(e,f.minuteOne,f.minuteMany)})):[],[e.mode,j,p,f]),S=useMemo(()=>"list"===e.mode?[{key:"list",label:e.label??f.value,items:c??[],value:e.value??"",width:e.width}]:"duration"===e.mode?[{key:"hours",label:f.hours,items:g,value:_.hour,unit:f.hourUnit,gapAfter:a.space.md},{key:"minutes",label:f.minutes,items:v,value:_.minute,unit:f.minuteUnit}]:e.columns,[e,c,g,v,_,f,a.space.md]),w="list"===e.mode?e.onChange:void 0,I="duration"===e.mode?e.onChange:void 0,L="list"===e.mode||"duration"===e.mode?void 0:e.onChange,T=useCallback((e,t)=>{const i=e.items[t];if(i)if(w)w(i.value);else if(I){const t=Number(i.value);"hours"===e.key?I(60*t+Math.min(_.minute,M(t))):I(60*_.hour+t)}else L?.(e.key,i.value)},[w,I,L,_,M]),C=useCallback(e=>{I?.(e)},[I]),W=60*_.hour+_.minute,A=_jsxs(View,{style:[d.wheels,s],testID:o,children:[_jsxs(View,{pointerEvents:"none",style:d.selectionBand,children:[_jsx(View,{style:d.bandLine}),_jsx(View,{style:d.bandLine})]}),S.map(o=>{if(0===o.items.length)return null;const s=o.items.findIndex(e=>e.value===o.value);return _jsxs(Fragment,{children:[_jsx(Wheel,{label:o.label,items:o.items,selectedIndex:Math.max(0,s),onIndexChange:e=>T(o,e),itemHeight:m,width:o.width??("list"===e.mode?void 0:64),theme:a,haptic:t,disabled:i,reducedMotion:r,typeable:"duration"===e.mode,typeAction:f.typeAction,typeEditor:f.typeEditor,testID:o.testID}),o.unit?_jsx(Text,{variant:"body",weight:"semibold",color:"secondary",style:d.unit,maxFontSizeMultiplier:1.5,numberOfLines:1,accessible:!1,importantForAccessibility:"no","aria-hidden":!0,children:o.unit}):null,o.separator?_jsx(Text,{variant:"h2",weight:"bold",style:d.separator,maxFontSizeMultiplier:1.5,accessible:!1,importantForAccessibility:"no","aria-hidden":!0,children:o.separator}):null,o.gapAfter?_jsx(View,{style:{width:o.gapAfter}}):null]},o.key)})]});return x&&0!==x.length?_jsxs(View,{children:[A,_jsx(View,{style:d.presets,children:x.map(e=>_jsx(Chip,{label:formatPreset(e,f.hourUnit,f.minuteUnit),size:"sm",selected:e===W,disabled:i,onPress:()=>C(e)},e))})]}):A},buildStyles=(e,t)=>StyleSheet.create({wheels:{flexDirection:"row",alignItems:"center",justifyContent:"center",height:t*WHEEL_VISIBLE_ITEMS,position:"relative"},selectionBand:{position:"absolute",left:0,right:0,top:t*WHEEL_CENTER_OFFSET,height:t,justifyContent:"space-between"},bandLine:{height:2*StyleSheet.hairlineWidth,backgroundColor:e.colors.primary,opacity:.85},separator:{paddingHorizontal:e.space.xs},unit:{paddingLeft:e.space.xs},presets:{flexDirection:"row",flexWrap:"wrap",justifyContent:"center",gap:e.space.xs,paddingTop:e.space.sm}});export{WheelPicker};export default WheelPicker;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";export{Accordion,AccordionGroup}from"./Accordion/index.js";export{AmountSlider,DEFAULT_AMOUNT_SLIDER_LABELS}from"./AmountSlider/index.js";export{AnimatePresence}from"./AnimatePresence/index.js";export{AppBar,DEFAULT_APP_BAR_LABELS}from"./AppBar/index.js";export{AppLockOverlay,DEFAULT_APP_LOCK_OVERLAY_LABELS}from"./AppLockOverlay/index.js";export{AsyncBlock,DEFAULT_ASYNC_BLOCK_LABELS}from"./AsyncBlock/index.js";export{AuthedImage,authedImageCacheStats,clearAuthedImageCache,getAuthedImageCacheLimit,setAuthedImageCacheLimit}from"./AuthedImage/index.js";export{Autocomplete,DEFAULT_AUTOCOMPLETE_LABELS}from"./Autocomplete/index.js";export{Avatar,AvatarGroup,avatarToneColors,DEFAULT_AVATAR_LABELS}from"./Avatar/index.js";export{Badge,DEFAULT_BADGE_LABELS}from"./Badge/index.js";export{Banner,DEFAULT_BANNER_LABELS}from"./Banner/index.js";export{BarChart}from"./BarChart/index.js";export{BottomNavigation,DEFAULT_BOTTOM_NAVIGATION_LABELS}from"./BottomNavigation/index.js";export{BottomSheet,DEFAULT_BOTTOM_SHEET_LABELS,useBottomSheet}from"./BottomSheet/index.js";export{Box,Row,Spacer,Stack}from"./Box/index.js";export{Button,buttonLabelInk}from"./Button/index.js";export{Calendar,DEFAULT_CALENDAR_LABELS}from"./Calendar/index.js";export{Card,DEFAULT_CARD_LABELS}from"./Card/index.js";export{Carousel,DEFAULT_CAROUSEL_LABELS}from"./Carousel/index.js";export{Checkbox}from"./Checkbox/index.js";export{Chip}from"./Chip/index.js";export{ChoiceGroup}from"./ChoiceGroup/index.js";export{Composer,DEFAULT_COMPOSER_LABELS}from"./Composer/index.js";export{Confetti}from"./Confetti/index.js";export{ConfirmHost,confirm}from"./Confirm/index.js";export{DatePicker,DEFAULT_DATE_PICKER_LABELS}from"./DatePicker/index.js";export{DateRangePicker,DEFAULT_DATE_RANGE_PICKER_LABELS}from"./DateRangePicker/index.js";export{DateSeparator,DEFAULT_DATE_SEPARATOR_LABELS,dayLabel}from"./DateSeparator/index.js";export{cleanDecimalText,DEFAULT_DECIMAL_INPUT_LABELS,DecimalInput,isUnclearDecimalComma,parseDecimalText,pointDecimalText}from"./DecimalInput/index.js";export{Descriptions}from"./Descriptions/index.js";export{Dialog}from"./Dialog/index.js";export{Divider}from"./Divider/index.js";export{DEFAULT_DRAWER_LABELS,Drawer}from"./Drawer/index.js";export{EmptyState}from"./EmptyState/index.js";export{DEFAULT_ERROR_BOUNDARY_LABELS,ErrorBoundary,useErrorHandler,withErrorBoundary}from"./ErrorBoundary/index.js";export{DEFAULT_FILE_PICKER_LABELS,FilePicker,formatFileSize}from"./FilePicker/index.js";export{FileViewer}from"./FileViewer/index.js";export{FilterChipRow}from"./FilterChipRow/index.js";export{DEFAULT_FLOATING_ACTION_BUTTON_GROUP_LABELS,FloatingActionButton,FloatingActionButtonGroup}from"./FloatingActionButton/index.js";export{DEFAULT_FORCE_UPDATE_DIALOG_LABELS,ForceUpdateDialog}from"./ForceUpdateDialog/index.js";export{DEFAULT_FORM_FIELD_LABELS,FormField}from"./FormField/index.js";export{IconBadge}from"./IconBadge/index.js";export{IconButton}from"./IconButton/index.js";export{DEFAULT_IMAGE_GALLERY_LABELS,ImageGallery}from"./ImageGallery/index.js";export{DEFAULT_INLINE_SELECT_LABELS,InlineSelect}from"./InlineSelect/index.js";export{DEFAULT_INPUT_LABELS,Input}from"./Input/index.js";export{KeyboardAwareScrollView}from"./KeyboardAwareScrollView/index.js";export{DEFAULT_KEYBOARD_TOOLBAR_LABELS,KeyboardToolbar}from"./KeyboardToolbar/index.js";export{ListItem}from"./ListItem/index.js";export{ListSection}from"./ListSection/index.js";export{DEFAULT_LOADER_OVERLAY_LABELS,LoaderOverlay,loader,useLoader}from"./LoaderOverlay/index.js";export{Markdown}from"./Markdown/index.js";export{DEFAULT_MENU_LABELS,Menu}from"./Menu/index.js";export{DEFAULT_MESSAGE_BUBBLE_LABELS,MessageBubble}from"./MessageBubble/index.js";export{DEFAULT_MESSAGE_LIST_LABELS,MessageList}from"./MessageList/index.js";export{DEFAULT_MODAL_LABELS,MODAL_DISMISS_GRACE_MS,Modal}from"./Modal/index.js";export{DEFAULT_NUMBER_INPUT_LABELS,NumberInput}from"./NumberInput/index.js";export{DEFAULT_ONBOARDING_PAGER_LABELS,OnboardingPager}from"./OnboardingPager/index.js";export{DEFAULT_OPTION_SHEET_LABELS,OptionSheet}from"./OptionSheet/index.js";export{DEFAULT_OTP_INPUT_LABELS,DEFAULT_OTP_RESEND_ROW_LABELS,OTPInput,OTPResendRow}from"./OTPInput/index.js";export{DEFAULT_PAGED_LIST_FOOTER_LABELS,PagedListFooter}from"./PagedListFooter/index.js";export{DEFAULT_PERMISSION_PROMPT_LABELS,PermissionPrompt,usePermissionPrompt}from"./PermissionPrompt/index.js";export{ALL_CALLING_CODES,DEFAULT_CALLING_CODES,DEFAULT_PHONE_NUMBER_INPUT_LABELS,formatE164,PhoneNumberInput,parseE164}from"./PhoneNumberInput/index.js";export{DEFAULT_PICKER_TRIGGER_LABELS,PickerTrigger}from"./PickerTrigger/index.js";export{DEFAULT_PROFILE_COMPLETION_LABELS,ProfileCompletion}from"./ProfileCompletion/index.js";export{DEFAULT_PROFILE_PICKER_LABELS,ProfilePicker}from"./ProfilePicker/index.js";export{DEFAULT_PROGRESS_BAR_LABELS,ProgressBar}from"./ProgressBar/index.js";export{ProgressRing}from"./ProgressRing/index.js";export{Radio,RadioDot,RadioGroup}from"./Radio/index.js";export{DEFAULT_RATING_LABELS,Rating}from"./Rating/index.js";export{DEFAULT_REPEATER_LABELS,Repeater}from"./Repeater/index.js";export{applyMarkdownAction,DEFAULT_RICH_TEXT_EDITOR_LABELS,RichTextEditor}from"./RichTextEditor/index.js";export{DEFAULT_SCANNER_OVERLAY_LABELS,ScannerOverlay}from"./ScannerOverlay/index.js";export{Screen}from"./Screen/index.js";export{DEFAULT_SEARCH_BAR_LABELS,SearchBar,useRecentSearches}from"./SearchBar/index.js";export{DEFAULT_SECTION_HEADER_LABELS,SectionHeader}from"./SectionHeader/index.js";export{SegmentedControl}from"./SegmentedControl/index.js";export{DEFAULT_SELECT_LABELS,Select}from"./Select/index.js";export{DEFAULT_SIGNATURE_PAD_LABELS,SignaturePad}from"./SignaturePad/index.js";export{DEFAULT_SKELETON_LABELS,Skeleton,SkeletonCircle,SkeletonClockProvider,SkeletonContent,SkeletonList,SkeletonProvider,SkeletonSkip,SkeletonText,useSkeletonClock,useSkeletonDefaults}from"./Skeleton/index.js";export{Slider}from"./Slider/index.js";export{DEFAULT_SLIDER_FIELD_LABELS,SliderField}from"./SliderField/index.js";export{DEFAULT_SLIDE_TO_CONFIRM_LABELS,SlideToConfirm}from"./SlideToConfirm/index.js";export{DEFAULT_SORTABLE_LIST_LABELS,SortableList}from"./SortableList/index.js";export{DEFAULT_SPARKLINE_LABELS,Sparkline}from"./Sparkline/index.js";export{DEFAULT_SPINNER_LABELS,Spinner}from"./Spinner/index.js";export{SquircleImage}from"./SquircleImage/index.js";export{SquircleView}from"./SquircleView/index.js";export{StatTile}from"./StatTile/index.js";export{StatusBadge}from"./StatusBadge/index.js";export{defineStatusMap}from"./StatusBadge/statusMap.js";export{Stepper}from"./Stepper/index.js";export{Swipeable}from"./Swipeable/index.js";export{Switch}from"./Switch/index.js";export{Tabs}from"./Tabs/index.js";export{TagInput}from"./TagInput/index.js";export{Text}from"./Text/index.js";export{TextInkContext,useTextInk}from"./Text/textInk.js";export{Timeline}from"./Timeline/index.js";export{DEFAULT_TIME_PICKER_LABELS,TimePicker}from"./TimePicker/index.js";export{DEFAULT_TOAST_LABELS,Toast,ToastHost,ToastProvider,toast,useToast}from"./Toast/index.js";export{DEFAULT_TOOLTIP_LABELS,Tooltip}from"./Tooltip/index.js";export{DEFAULT_TOUR_LABELS,Tour}from"./Tour/index.js";export{DEFAULT_TYPING_INDICATOR_LABELS,TypingIndicator}from"./TypingIndicator/index.js";export{DEFAULT_WHEEL_PICKER_LABELS,WheelPicker}from"./WheelPicker/index.js";export{ZoomableImage}from"./ZoomableImage/index.js";
|
|
1
|
+
"use strict";export{Accordion,AccordionGroup}from"./Accordion/index.js";export{AmountSlider,DEFAULT_AMOUNT_SLIDER_LABELS}from"./AmountSlider/index.js";export{AnimatePresence}from"./AnimatePresence/index.js";export{AppBar,DEFAULT_APP_BAR_LABELS}from"./AppBar/index.js";export{AppLockOverlay,DEFAULT_APP_LOCK_OVERLAY_LABELS}from"./AppLockOverlay/index.js";export{AsyncBlock,DEFAULT_ASYNC_BLOCK_LABELS}from"./AsyncBlock/index.js";export{AuthedImage,authedImageCacheStats,clearAuthedImageCache,getAuthedImageCacheLimit,setAuthedImageCacheLimit}from"./AuthedImage/index.js";export{Autocomplete,DEFAULT_AUTOCOMPLETE_LABELS}from"./Autocomplete/index.js";export{Avatar,AvatarGroup,avatarToneColors,DEFAULT_AVATAR_LABELS}from"./Avatar/index.js";export{Badge,DEFAULT_BADGE_LABELS}from"./Badge/index.js";export{Banner,DEFAULT_BANNER_LABELS}from"./Banner/index.js";export{BarChart}from"./BarChart/index.js";export{BottomNavigation,DEFAULT_BOTTOM_NAVIGATION_LABELS}from"./BottomNavigation/index.js";export{BottomSheet,DEFAULT_BOTTOM_SHEET_LABELS,useBottomSheet}from"./BottomSheet/index.js";export{Box,Row,Spacer,Stack}from"./Box/index.js";export{Button,buttonLabelInk}from"./Button/index.js";export{Calendar,DEFAULT_CALENDAR_LABELS}from"./Calendar/index.js";export{Card,DEFAULT_CARD_LABELS}from"./Card/index.js";export{Carousel,DEFAULT_CAROUSEL_LABELS}from"./Carousel/index.js";export{Checkbox}from"./Checkbox/index.js";export{Chip}from"./Chip/index.js";export{ChoiceGroup}from"./ChoiceGroup/index.js";export{Composer,DEFAULT_COMPOSER_LABELS}from"./Composer/index.js";export{Confetti}from"./Confetti/index.js";export{ConfirmHost,confirm}from"./Confirm/index.js";export{DatePicker,DEFAULT_DATE_PICKER_LABELS}from"./DatePicker/index.js";export{DateRangePicker,DEFAULT_DATE_RANGE_PICKER_LABELS}from"./DateRangePicker/index.js";export{DateSeparator,DEFAULT_DATE_SEPARATOR_LABELS,dayLabel}from"./DateSeparator/index.js";export{cleanDecimalText,DEFAULT_DECIMAL_INPUT_LABELS,DecimalInput,isUnclearDecimalComma,parseDecimalText,pointDecimalText}from"./DecimalInput/index.js";export{Descriptions}from"./Descriptions/index.js";export{Dialog}from"./Dialog/index.js";export{Divider}from"./Divider/index.js";export{DEFAULT_DRAWER_LABELS,Drawer}from"./Drawer/index.js";export{EmptyState}from"./EmptyState/index.js";export{DEFAULT_ERROR_BOUNDARY_LABELS,ErrorBoundary,useErrorHandler,withErrorBoundary}from"./ErrorBoundary/index.js";export{DEFAULT_FILE_PICKER_LABELS,FilePicker,formatFileSize}from"./FilePicker/index.js";export{FileViewer}from"./FileViewer/index.js";export{FilterChipRow}from"./FilterChipRow/index.js";export{DEFAULT_FLOATING_ACTION_BUTTON_GROUP_LABELS,FloatingActionButton,FloatingActionButtonGroup}from"./FloatingActionButton/index.js";export{DEFAULT_FORCE_UPDATE_DIALOG_LABELS,ForceUpdateDialog}from"./ForceUpdateDialog/index.js";export{DEFAULT_FORM_FIELD_LABELS,FormField}from"./FormField/index.js";export{IconBadge}from"./IconBadge/index.js";export{IconButton}from"./IconButton/index.js";export{DEFAULT_IMAGE_GALLERY_LABELS,ImageGallery}from"./ImageGallery/index.js";export{DEFAULT_INLINE_SELECT_LABELS,InlineSelect}from"./InlineSelect/index.js";export{DEFAULT_INPUT_LABELS,Input}from"./Input/index.js";export{KeyboardAwareScrollView}from"./KeyboardAwareScrollView/index.js";export{DEFAULT_KEYBOARD_TOOLBAR_LABELS,KeyboardToolbar}from"./KeyboardToolbar/index.js";export{ListItem}from"./ListItem/index.js";export{ListSection}from"./ListSection/index.js";export{DEFAULT_LOADER_OVERLAY_LABELS,LoaderOverlay,loader,useLoader}from"./LoaderOverlay/index.js";export{Markdown}from"./Markdown/index.js";export{DEFAULT_MENU_LABELS,Menu}from"./Menu/index.js";export{DEFAULT_MESSAGE_BUBBLE_LABELS,MessageBubble}from"./MessageBubble/index.js";export{DEFAULT_MESSAGE_LIST_LABELS,MessageList}from"./MessageList/index.js";export{DEFAULT_MODAL_LABELS,MODAL_DISMISS_GRACE_MS,Modal}from"./Modal/index.js";export{DEFAULT_NON_MODAL_BOTTOM_SHEET_LABELS,NonModalBottomSheet}from"./NonModalBottomSheet/index.js";export{DEFAULT_NUMBER_INPUT_LABELS,NumberInput}from"./NumberInput/index.js";export{DEFAULT_ONBOARDING_PAGER_LABELS,OnboardingPager}from"./OnboardingPager/index.js";export{DEFAULT_OPTION_SHEET_LABELS,OptionSheet}from"./OptionSheet/index.js";export{DEFAULT_OTP_INPUT_LABELS,DEFAULT_OTP_RESEND_ROW_LABELS,OTPInput,OTPResendRow}from"./OTPInput/index.js";export{DEFAULT_PAGED_LIST_FOOTER_LABELS,PagedListFooter}from"./PagedListFooter/index.js";export{DEFAULT_PERMISSION_PROMPT_LABELS,PermissionPrompt,usePermissionPrompt}from"./PermissionPrompt/index.js";export{ALL_CALLING_CODES,DEFAULT_CALLING_CODES,DEFAULT_PHONE_NUMBER_INPUT_LABELS,formatE164,PhoneNumberInput,parseE164}from"./PhoneNumberInput/index.js";export{DEFAULT_PICKER_TRIGGER_LABELS,PickerTrigger}from"./PickerTrigger/index.js";export{DEFAULT_PROFILE_COMPLETION_LABELS,ProfileCompletion}from"./ProfileCompletion/index.js";export{DEFAULT_PROFILE_PICKER_LABELS,ProfilePicker}from"./ProfilePicker/index.js";export{DEFAULT_PROGRESS_BAR_LABELS,ProgressBar}from"./ProgressBar/index.js";export{ProgressRing}from"./ProgressRing/index.js";export{Radio,RadioDot,RadioGroup}from"./Radio/index.js";export{DEFAULT_RATING_LABELS,Rating}from"./Rating/index.js";export{DEFAULT_REPEATER_LABELS,Repeater}from"./Repeater/index.js";export{applyMarkdownAction,DEFAULT_RICH_TEXT_EDITOR_LABELS,RichTextEditor}from"./RichTextEditor/index.js";export{DEFAULT_SCANNER_OVERLAY_LABELS,ScannerOverlay}from"./ScannerOverlay/index.js";export{Screen}from"./Screen/index.js";export{DEFAULT_SEARCH_BAR_LABELS,SearchBar,useRecentSearches}from"./SearchBar/index.js";export{DEFAULT_SECTION_HEADER_LABELS,SectionHeader}from"./SectionHeader/index.js";export{SegmentedControl}from"./SegmentedControl/index.js";export{DEFAULT_SELECT_LABELS,Select}from"./Select/index.js";export{DEFAULT_SIGNATURE_PAD_LABELS,SignaturePad}from"./SignaturePad/index.js";export{DEFAULT_SKELETON_LABELS,Skeleton,SkeletonCircle,SkeletonClockProvider,SkeletonContent,SkeletonList,SkeletonProvider,SkeletonSkip,SkeletonText,useSkeletonClock,useSkeletonDefaults}from"./Skeleton/index.js";export{Slider}from"./Slider/index.js";export{DEFAULT_SLIDER_FIELD_LABELS,SliderField}from"./SliderField/index.js";export{DEFAULT_SLIDE_TO_CONFIRM_LABELS,SlideToConfirm}from"./SlideToConfirm/index.js";export{DEFAULT_SORTABLE_LIST_LABELS,SortableList}from"./SortableList/index.js";export{DEFAULT_SPARKLINE_LABELS,Sparkline}from"./Sparkline/index.js";export{DEFAULT_SPINNER_LABELS,Spinner}from"./Spinner/index.js";export{SquircleImage}from"./SquircleImage/index.js";export{SquircleView}from"./SquircleView/index.js";export{StatTile}from"./StatTile/index.js";export{StatusBadge}from"./StatusBadge/index.js";export{defineStatusMap}from"./StatusBadge/statusMap.js";export{Stepper}from"./Stepper/index.js";export{Swipeable}from"./Swipeable/index.js";export{Switch}from"./Switch/index.js";export{Tabs}from"./Tabs/index.js";export{TagInput}from"./TagInput/index.js";export{Text}from"./Text/index.js";export{TextInkContext,useTextInk}from"./Text/textInk.js";export{Timeline}from"./Timeline/index.js";export{DEFAULT_TIME_PICKER_LABELS,TimePicker}from"./TimePicker/index.js";export{DEFAULT_TOAST_LABELS,Toast,ToastHost,ToastProvider,toast,useToast}from"./Toast/index.js";export{DEFAULT_TOOLTIP_LABELS,Tooltip}from"./Tooltip/index.js";export{DEFAULT_TOUR_LABELS,Tour}from"./Tour/index.js";export{DEFAULT_TYPING_INDICATOR_LABELS,TypingIndicator}from"./TypingIndicator/index.js";export{DEFAULT_WHEEL_PICKER_LABELS,WheelPicker}from"./WheelPicker/index.js";export{ZoomableImage}from"./ZoomableImage/index.js";
|
package/lib/module/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";export{PHONE_CHROME_INSETS}from"./canvasKit/index.js";export{Accordion,AccordionGroup,ALL_CALLING_CODES,AmountSlider,AnimatePresence,AppBar,AppLockOverlay,AsyncBlock,AuthedImage,Autocomplete,Avatar,AvatarGroup,authedImageCacheStats,Badge,Banner,BarChart,BottomNavigation,BottomSheet,Box,Button,buttonLabelInk,Calendar,Card,Carousel,Checkbox,Chip,ChoiceGroup,Composer,Confetti,ConfirmHost,clearAuthedImageCache,confirm,DatePicker,DateRangePicker,DateSeparator,DEFAULT_CALLING_CODES,DecimalInput,Descriptions,Dialog,Divider,Drawer,defineStatusMap,EmptyState,ErrorBoundary,FilePicker,FileViewer,FilterChipRow,FloatingActionButton,FloatingActionButtonGroup,ForceUpdateDialog,FormField,formatE164,formatFileSize,getAuthedImageCacheLimit,IconBadge,IconButton,ImageGallery,InlineSelect,Input,KeyboardAwareScrollView,KeyboardToolbar,ListItem,ListSection,LoaderOverlay,loader,Markdown,Menu,MessageBubble,MessageList,MODAL_DISMISS_GRACE_MS,Modal,NumberInput,OnboardingPager,OptionSheet,OTPInput,OTPResendRow,PagedListFooter,PermissionPrompt,PhoneNumberInput,PickerTrigger,ProfileCompletion,ProfilePicker,ProgressBar,ProgressRing,Radio,RadioDot,RadioGroup,Rating,Repeater,RichTextEditor,Row,ScannerOverlay,Screen,SearchBar,SectionHeader,SegmentedControl,Select,SignaturePad,Skeleton,SkeletonCircle,SkeletonClockProvider,SkeletonContent,SkeletonList,SkeletonProvider,SkeletonSkip,SkeletonText,Slider,SliderField,SlideToConfirm,SortableList,Spacer,Sparkline,Spinner,SquircleImage,SquircleView,Stack,StatTile,StatusBadge,Stepper,Swipeable,Switch,setAuthedImageCacheLimit,Tabs,TagInput,Text,TextInkContext,Timeline,TimePicker,Toast,ToastHost,ToastProvider,Tooltip,Tour,TypingIndicator,toast,useBottomSheet,useErrorHandler,useRecentSearches,useTextInk,useToast,WheelPicker,withErrorBoundary,ZoomableImage}from"./components/index.js";export{AppIcon}from"./components/AppIcon/index.js";export{HookFormField,useHookFormField}from"./form/index.js";export{useDebounce,useFieldChain,useReducedMotion,useRefreshControl,useScrollDirection}from"./hooks/index.js";export{NetworkStatusBanner}from"./network/index.js";export{fontFor,KitThemeBridge,lightTheme,makeStyles,radiusOf,ThemeProvider,useTheme,useThemeMode}from"./theme/index.js";export{announce,isHapticsEnabled,setHapticImplementation,setHapticsEnabled,triggerHaptic}from"./utils/index.js";
|
|
1
|
+
"use strict";export{PHONE_CHROME_INSETS}from"./canvasKit/index.js";export{Accordion,AccordionGroup,ALL_CALLING_CODES,AmountSlider,AnimatePresence,AppBar,AppLockOverlay,AsyncBlock,AuthedImage,Autocomplete,Avatar,AvatarGroup,authedImageCacheStats,Badge,Banner,BarChart,BottomNavigation,BottomSheet,Box,Button,buttonLabelInk,Calendar,Card,Carousel,Checkbox,Chip,ChoiceGroup,Composer,Confetti,ConfirmHost,clearAuthedImageCache,confirm,DatePicker,DateRangePicker,DateSeparator,DEFAULT_CALLING_CODES,DecimalInput,Descriptions,Dialog,Divider,Drawer,defineStatusMap,EmptyState,ErrorBoundary,FilePicker,FileViewer,FilterChipRow,FloatingActionButton,FloatingActionButtonGroup,ForceUpdateDialog,FormField,formatE164,formatFileSize,getAuthedImageCacheLimit,IconBadge,IconButton,ImageGallery,InlineSelect,Input,KeyboardAwareScrollView,KeyboardToolbar,ListItem,ListSection,LoaderOverlay,loader,Markdown,Menu,MessageBubble,MessageList,MODAL_DISMISS_GRACE_MS,Modal,NonModalBottomSheet,NumberInput,OnboardingPager,OptionSheet,OTPInput,OTPResendRow,PagedListFooter,PermissionPrompt,PhoneNumberInput,PickerTrigger,ProfileCompletion,ProfilePicker,ProgressBar,ProgressRing,Radio,RadioDot,RadioGroup,Rating,Repeater,RichTextEditor,Row,ScannerOverlay,Screen,SearchBar,SectionHeader,SegmentedControl,Select,SignaturePad,Skeleton,SkeletonCircle,SkeletonClockProvider,SkeletonContent,SkeletonList,SkeletonProvider,SkeletonSkip,SkeletonText,Slider,SliderField,SlideToConfirm,SortableList,Spacer,Sparkline,Spinner,SquircleImage,SquircleView,Stack,StatTile,StatusBadge,Stepper,Swipeable,Switch,setAuthedImageCacheLimit,Tabs,TagInput,Text,TextInkContext,Timeline,TimePicker,Toast,ToastHost,ToastProvider,Tooltip,Tour,TypingIndicator,toast,useBottomSheet,useErrorHandler,useRecentSearches,useTextInk,useToast,WheelPicker,withErrorBoundary,ZoomableImage}from"./components/index.js";export{AppIcon}from"./components/AppIcon/index.js";export{HookFormField,useHookFormField}from"./form/index.js";export{useDebounce,useFieldChain,useReducedMotion,useRefreshControl,useScrollDirection}from"./hooks/index.js";export{NetworkStatusBanner}from"./network/index.js";export{fontFor,KitThemeBridge,lightTheme,makeStyles,radiusOf,ThemeProvider,useTheme,useThemeMode}from"./theme/index.js";export{announce,isHapticsEnabled,setHapticImplementation,setHapticsEnabled,triggerHaptic}from"./utils/index.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";export const COLOR_NAMES=["bg","bg-subtle","bg-muted","surface","surface-inverse","surface-dark","surface-dark-border","on-surface-dark","on-surface-dark-muted","surface-ink","text","text-body","text-muted","text-subtle","text-inverse","link","border","border-subtle","field-bg","field-border","field-border-focus","focus-ring","scrim","on-scrim","thumb","primary","primary-hover","primary-soft","primary-text","on-primary","primary-wash","primary-wash-strong","neutral","neutral-hover","neutral-text","on-neutral","success","success-soft","success-text","on-success","warning","warning-soft","warning-text","on-warning","danger","danger-soft","danger-border","danger-text","offline-fill","online-fill","on-danger","info","info-soft","info-text","on-info","primary-pressed","switch-thumb","on-neutral-strong","text-disabled","surface-pressed","surface-hover","surface-selected","surface-disabled","skeleton","skeleton-highlight","glass-fill","glass-border","on-glass","glass-badge","field-bg-focus","field-bg-disabled","field-border-error","field-label","field-text","field-text-disabled","field-placeholder","field-placeholder-disabled","field-icon","field-icon-focus","field-icon-disabled","field-caret","field-message","avatar-1","avatar-2","avatar-3","avatar-4","avatar-5","avatar-6","avatar-7","avatar-8"];export const SPACE_NAMES=["none","xxs","xs","sm","md","lg","xl","2xl","3xl","4xl"];export const RADIUS_NAMES=["none","sm","md","lg","xl","pill"];export const TEXT_NAMES=["xs","sm","base","lg","xl","2xl","3xl","4xl","5xl","6xl","7xl","8xl"];export const WEIGHT_NAMES=["normal","medium","semibold","bold"];export const LEADING_NAMES=["heading","body","display"];export const LETTER_SPACING_NAMES=["tight","normal","wide"];export const FONT_NAMES=["ui","display","mono"];export const SHADOW_NAMES=["card","elevated","popover","modal","drawer"];export const DURATION_NAMES=["instant","fast","default","slow","slower"];export const EASE_NAMES=["in-out","accelerate","decelerate","sharp"];export const SIZE_NAMES=["border"];export const COMPONENT_KINDS={field:{radius:"radius","padding-x":"space","padding-y":"space","min-height":"px",text:"text",icon:"px","label-text":"text","label-gap":"space","message-text":"text","message-gap":"space"},press:{opacity:"number"},disabled:{opacity:"number"},button:{"padding-x":"space","padding-y":"space","min-height":"px",text:"text",radius:"radius",icon:"px","badge-icon":"px"},input:{"multiline-min-height":"px"},"search-bar":{radius:"radius"},"empty-state":{icon:"px","illustration-size":"px","title-text":"text","description-text":"text","padding-y":"space","title-gap":"space","description-gap":"space"},"list-item":{"padding-y":"space","title-text":"text","subtitle-text":"text","min-height":"px"},badge:{text:"text","min-width":"px",height:"px","padding-x":"space","dot-size":"px","border-width":"px","anchor-offset":"px"},chip:{"padding-x":"space","padding-y":"space",text:"text","min-height":"px","close-size":"px","close-text":"text",gap:"space",icon:"px"},checkbox:{"box-size":"px","label-gap":"space"},radio:{outer:"px",inner:"px","label-gap":"space"},switch:{"track-width":"px","track-height":"px","thumb-size":"px",padding:"space"},"otp-input":{cell:"px",text:"text",radius:"radius",gap:"space"},"segmented-control":{height:"px",text:"text","padding-x":"space",icon:"px","track-padding":"space","underline-height":"px","pill-inset":"space"},tabs:{text:"text","padding-y":"space","padding-x":"space","scrollable-padding-x":"space",icon:"px","icon-gap":"space","track-padding":"space","underline-height":"px","pill-inset":"space","disabled-opacity":"number","badge-gap":"space"},slider:{"track-height":"px","thumb-diameter":"px"},"floating-action-button":{diameter:"px",icon:"px",text:"text","label-padding-x":"space","edge-offset":"space","bottom-offset":"space","secondary-gap":"space","stagger-ms":"ms"},dialog:{"icon-wrapper-size":"px","action-button-min-height":"px"},toast:{"icon-circle-size":"px","icon-glyph-text":"text","tint-bar-width":"px","action-min-height":"px"},banner:{"tint-bar-width":"px"},screen:{gutter:"space"}};export const lightTokens={mode:"light",colors:{bg:"#ffffff","bg-subtle":"#f8f8fb","bg-muted":"#f1f1f5",surface:"#ffffff","surface-inverse":"#0f0f1a","surface-dark":"#071437","surface-dark-border":"#2a3553","on-surface-dark":"#ffffff","on-surface-dark-muted":"#babdc7","surface-ink":"#0b0e16",text:"#252f4a","text-body":"#0f0f1a","text-muted":"#52525b","text-subtle":"#62626b","text-inverse":"#ffffff",link:"#5b5bd6",border:"#e5e5ec","border-subtle":"#efeff3","field-bg":"#f9fbfc","field-border":"#ebedf3","field-border-focus":"#bed2f9","focus-ring":"#5b5bd6",scrim:"#0f0f1a80","on-scrim":"#ffffff",thumb:"#ffffff",primary:"#5b5bd6","primary-hover":"#4f4fbf","primary-soft":"#eeeefc","primary-text":"#4f4fd3","on-primary":"#ffffff","primary-wash":"#5b5bd614","primary-wash-strong":"#5b5bd633",neutral:"#f4f4f8","neutral-hover":"#e9e9f0","neutral-text":"#52525b","on-neutral":"#0f0f1a",success:"#18864f","success-soft":"#e8faee","success-text":"#147042","on-success":"#ffffff",warning:"#f59e0b","warning-soft":"#fff8e6","warning-text":"#8f5c06","on-warning":"#0f0f1a",danger:"#e12c32","danger-soft":"#ffeaef","danger-border":"#e5484d","danger-text":"#bc1b20","offline-fill":"#e82646","online-fill":"#04b440","on-danger":"#ffffff",info:"#1b6ef5","info-soft":"#e9f3ff","info-text":"#0958d9","on-info":"#ffffff","primary-pressed":"#4040a8","switch-thumb":"#ffffff","on-neutral-strong":"#ffffff","text-disabled":"#b4b4bb","surface-pressed":"#0f0f1a0f","surface-hover":"#0f0f1a0a","surface-selected":"#5b5bd61a","surface-disabled":"#f1f1f5",skeleton:"#ebedf3","skeleton-highlight":"#f5f6fa","glass-fill":"#ffffff47","glass-border":"#ffffff73","on-glass":"#0f0f1a","glass-badge":"#ffffff","field-bg-focus":"#ffffff","field-bg-disabled":"#f5f6fa","field-border-error":"#fdbfce","field-label":"#242f4a","field-text":"#252f4a","field-text-disabled":"#7a8197","field-placeholder":"#626d8b","field-placeholder-disabled":"#7a8197","field-icon":"#7a849f","field-icon-focus":"#4b5675","field-icon-disabled":"#c4cada","field-caret":"#5b8dee","field-message":"#d81736","avatar-1":"#5b5bd6","avatar-2":"#0a7979","avatar-3":"#a45a05","avatar-4":"#cd226e","avatar-5":"#2462eb","avatar-6":"#7c3aed","avatar-7":"#047c57","avatar-8":"#d42222"},space:{none:0,xxs:2,xs:4,sm:8,md:12,lg:16,xl:24,"2xl":32,"3xl":48,"4xl":64},radius:{none:0,sm:6,md:10,lg:14,xl:20,pill:9999},text:{xs:{size:11},sm:{size:13},base:{size:15},lg:{size:17},xl:{size:20},"2xl":{size:24},"3xl":{size:30},"4xl":{size:36},"5xl":{size:45},"6xl":{size:57},"7xl":{size:64},"8xl":{size:72}},weight:{normal:"400",medium:"500",semibold:"600",bold:"700"},leading:{heading:1.2,body:1.4,display:1.2},"letter-spacing":{tight:-.2,normal:0,wide:.4},font:{ui:{},display:{},mono:{}},shadow:{card:{shadowColor:"#000000",shadowOffset:{width:0,height:2},shadowOpacity:.059,shadowRadius:4,elevation:2},elevated:{shadowColor:"#000000",shadowOffset:{width:0,height:4},shadowOpacity:.078,shadowRadius:8,elevation:4},popover:{shadowColor:"#000000",shadowOffset:{width:0,height:8},shadowOpacity:.102,shadowRadius:16,elevation:8},modal:{shadowColor:"#000000",shadowOffset:{width:0,height:12},shadowOpacity:.141,shadowRadius:24,elevation:12},drawer:{shadowColor:"#000000",shadowOffset:{width:0,height:12},shadowOpacity:.141,shadowRadius:24,elevation:12}},motion:{duration:{instant:80,fast:160,default:240,slow:360,slower:500},ease:{"in-out":[.4,0,.2,1],accelerate:[.4,0,1,1],decelerate:[0,0,.2,1],sharp:[.4,0,.6,1]}},size:{border:1},components:{field:{sm:{radius:"md","padding-x":"sm","padding-y":"sm","min-height":38,text:"sm",icon:14,"label-text":"xs","label-gap":"xs","message-text":"xs","message-gap":"xxs"},md:{radius:"md","padding-x":"md","padding-y":"md","min-height":44,text:"base",icon:16,"label-text":"sm","label-gap":"xs","message-text":"sm","message-gap":"xxs"},lg:{radius:"md","padding-x":"lg","padding-y":"lg","min-height":52,text:"lg",icon:18,"label-text":"base","label-gap":"xs","message-text":"base","message-gap":"xxs"}},press:{opacity:.85},disabled:{opacity:.55},button:{xs:{"padding-x":"sm","padding-y":"xs","min-height":28,text:"xs",radius:"md",icon:14,"badge-icon":11},sm:{"padding-x":"md","padding-y":"xs","min-height":34,text:"sm",radius:"md",icon:16,"badge-icon":16},md:{"padding-x":"lg","padding-y":"sm","min-height":44,text:"base",radius:"md",icon:18,"badge-icon":18},lg:{"padding-x":"xl","padding-y":"md","min-height":50,text:"lg",radius:"lg",icon:20,"badge-icon":20},xl:{"padding-x":"2xl","padding-y":"md","min-height":58,text:"xl",radius:"lg",icon:22,"badge-icon":22}},input:{sm:{"multiline-min-height":72},md:{"multiline-min-height":92},lg:{"multiline-min-height":110}},"search-bar":{sm:{radius:"pill"},md:{radius:"pill"},lg:{radius:"pill"}},"empty-state":{sm:{icon:48,"illustration-size":96,"title-text":"lg","description-text":"sm","padding-y":"lg","title-gap":"md","description-gap":"xs"},md:{icon:64,"illustration-size":160,"title-text":"xl","description-text":"base","padding-y":"xl","title-gap":"md","description-gap":"xs"},lg:{icon:80,"illustration-size":240,"title-text":"2xl","description-text":"lg","padding-y":"2xl","title-gap":"md","description-gap":"xs"}},"list-item":{sm:{"padding-y":"sm","title-text":"sm","subtitle-text":"xs","min-height":44},md:{"padding-y":"md","title-text":"base","subtitle-text":"sm","min-height":56},lg:{"padding-y":"lg","title-text":"lg","subtitle-text":"base","min-height":72}},badge:{sm:{text:"xs","min-width":16,height:16,"padding-x":"xs","dot-size":8},md:{text:"sm","min-width":20,height:20,"padding-x":"sm","dot-size":10},"border-width":1.5,"anchor-offset":4},chip:{sm:{"padding-x":"sm","padding-y":"xs",text:"xs","min-height":26,"close-size":16,"close-text":"xs",gap:"xs",icon:14},md:{"padding-x":"md","padding-y":"xs",text:"sm","min-height":32,"close-size":18,"close-text":"sm",gap:"sm",icon:16}},checkbox:{sm:{"box-size":16},md:{"box-size":20},lg:{"box-size":24},"label-gap":"sm"},radio:{sm:{outer:16,inner:8},md:{outer:20,inner:10},lg:{outer:24,inner:12},"label-gap":"sm"},switch:{sm:{"track-width":42,"track-height":26,"thumb-size":22,padding:"xxs"},md:{"track-width":51,"track-height":31,"thumb-size":27,padding:"xxs"},lg:{"track-width":60,"track-height":36,"thumb-size":32,padding:"xxs"}},"otp-input":{sm:{cell:36,text:"base",radius:"sm",gap:"sm"},md:{cell:48,text:"xl",radius:"md",gap:"sm"},lg:{cell:56,text:"2xl",radius:"lg",gap:"md"}},"segmented-control":{sm:{height:32,text:"sm","padding-x":"sm",icon:14},md:{height:40,text:"base","padding-x":"md",icon:16},lg:{height:48,text:"lg","padding-x":"lg",icon:18},"track-padding":"xs","underline-height":2,"pill-inset":"xs"},tabs:{sm:{text:"sm","padding-y":"sm","padding-x":"xs","scrollable-padding-x":"md",icon:16},md:{text:"base","padding-y":"md","padding-x":"sm","scrollable-padding-x":"lg",icon:18},lg:{text:"lg","padding-y":"lg","padding-x":"md","scrollable-padding-x":"xl",icon:20},"icon-gap":"xs","track-padding":"xs","underline-height":2,"pill-inset":"xs","disabled-opacity":.45,"badge-gap":"xs"},slider:{sm:{"track-height":4,"thumb-diameter":24},md:{"track-height":6,"thumb-diameter":28},lg:{"track-height":8,"thumb-diameter":32}},"floating-action-button":{sm:{diameter:40,icon:18,text:"sm","label-padding-x":"md"},md:{diameter:56,icon:22,text:"base","label-padding-x":"lg"},lg:{diameter:72,icon:28,text:"lg","label-padding-x":"xl"},"edge-offset":"xl","bottom-offset":"xl","secondary-gap":"lg","stagger-ms":50},dialog:{"icon-wrapper-size":48,"action-button-min-height":44},toast:{"icon-circle-size":28,"icon-glyph-text":"lg","tint-bar-width":0,"action-min-height":30},banner:{"tint-bar-width":0},screen:{gutter:"lg"}}};export const darkTokens={mode:"dark",colors:{bg:"#0b0b12","bg-subtle":"#13131c","bg-muted":"#1c1c26",surface:"#1c1c26","surface-inverse":"#fafafa","surface-dark":"#071437","surface-dark-border":"#2a3553","on-surface-dark":"#ffffff","on-surface-dark-muted":"#babdc7","surface-ink":"#0b0e16",text:"#e2e2e2","text-body":"#fafafa","text-muted":"#b4b4bb","text-subtle":"#919199","text-inverse":"#0f0f1a",link:"#9292ee",border:"#27272f","border-subtle":"#1c1c26","field-bg":"#13131c","field-border":"#27272f","field-border-focus":"#3d5fb0","focus-ring":"#7c7ce8",scrim:"#000000a6","on-scrim":"#ffffff",thumb:"#3a3e49",primary:"#7c7ce8","primary-hover":"#9292ee","primary-soft":"#1f1f3d","primary-text":"#8989ea","on-primary":"#0f0f1a","primary-wash":"#7c7ce814","primary-wash-strong":"#7c7ce833",neutral:"#1f1f26","neutral-hover":"#2a2a33","neutral-text":"#b4b4bb","on-neutral":"#fafafa",success:"#30c780","success-soft":"#04b4402e","success-text":"#30c780","on-success":"#0f0f1a",warning:"#fbbf24","warning-soft":"#dfa0002e","warning-text":"#fbbf24","on-warning":"#0f0f1a",danger:"#f87171","danger-soft":"#e826462e","danger-border":"#f87171","danger-text":"#f87171","offline-fill":"#e82646","online-fill":"#04b440","on-danger":"#0f0f1a",info:"#60a5fa","info-soft":"#056ee92e","info-text":"#60a5fa","on-info":"#0f0f1a","primary-pressed":"#a8a8f2","switch-thumb":"#ffffff","on-neutral-strong":"#0f0f1a","text-disabled":"#52525b","surface-pressed":"#ffffff14","surface-hover":"#ffffff0d","surface-selected":"#7c7ce82e","surface-disabled":"#1c1c26",skeleton:"#1c1c26","skeleton-highlight":"#27272f","glass-fill":"#ffffff47","glass-border":"#ffffff73","on-glass":"#0f0f1a","glass-badge":"#ffffff","field-bg-focus":"#0b0b12","field-bg-disabled":"#1c1c26","field-border-error":"#8a2f42","field-label":"#e4e6ee","field-text":"#fafafa","field-text-disabled":"#71717a","field-placeholder":"#84848d","field-placeholder-disabled":"#71717a","field-icon":"#8b8b95","field-icon-focus":"#d4d4db","field-icon-disabled":"#52525b","field-caret":"#7c9ef0","field-message":"#f87171","avatar-1":"#8b8bee","avatar-2":"#2dd4bf","avatar-3":"#fcd34d","avatar-4":"#f472b6","avatar-5":"#60a5fa","avatar-6":"#a78bfa","avatar-7":"#34d399","avatar-8":"#f87171"},space:{none:0,xxs:2,xs:4,sm:8,md:12,lg:16,xl:24,"2xl":32,"3xl":48,"4xl":64},radius:{none:0,sm:6,md:10,lg:14,xl:20,pill:9999},text:{xs:{size:11},sm:{size:13},base:{size:15},lg:{size:17},xl:{size:20},"2xl":{size:24},"3xl":{size:30},"4xl":{size:36},"5xl":{size:45},"6xl":{size:57},"7xl":{size:64},"8xl":{size:72}},weight:{normal:"400",medium:"500",semibold:"600",bold:"700"},leading:{heading:1.2,body:1.4,display:1.2},"letter-spacing":{tight:-.2,normal:0,wide:.4},font:{ui:{},display:{},mono:{}},shadow:{card:{shadowColor:"#000000",shadowOffset:{width:0,height:2},shadowOpacity:.4,shadowRadius:4,elevation:2},elevated:{shadowColor:"#000000",shadowOffset:{width:0,height:4},shadowOpacity:.502,shadowRadius:8,elevation:4},popover:{shadowColor:"#000000",shadowOffset:{width:0,height:8},shadowOpacity:.549,shadowRadius:16,elevation:8},modal:{shadowColor:"#000000",shadowOffset:{width:0,height:12},shadowOpacity:.6,shadowRadius:24,elevation:12},drawer:{shadowColor:"#000000",shadowOffset:{width:0,height:12},shadowOpacity:.6,shadowRadius:24,elevation:12}},motion:{duration:{instant:80,fast:160,default:240,slow:360,slower:500},ease:{"in-out":[.4,0,.2,1],accelerate:[.4,0,1,1],decelerate:[0,0,.2,1],sharp:[.4,0,.6,1]}},size:{border:1},components:{field:{sm:{radius:"md","padding-x":"sm","padding-y":"sm","min-height":38,text:"sm",icon:14,"label-text":"xs","label-gap":"xs","message-text":"xs","message-gap":"xxs"},md:{radius:"md","padding-x":"md","padding-y":"md","min-height":44,text:"base",icon:16,"label-text":"sm","label-gap":"xs","message-text":"sm","message-gap":"xxs"},lg:{radius:"md","padding-x":"lg","padding-y":"lg","min-height":52,text:"lg",icon:18,"label-text":"base","label-gap":"xs","message-text":"base","message-gap":"xxs"}},press:{opacity:.85},disabled:{opacity:.55},button:{xs:{"padding-x":"sm","padding-y":"xs","min-height":28,text:"xs",radius:"md",icon:14,"badge-icon":11},sm:{"padding-x":"md","padding-y":"xs","min-height":34,text:"sm",radius:"md",icon:16,"badge-icon":16},md:{"padding-x":"lg","padding-y":"sm","min-height":44,text:"base",radius:"md",icon:18,"badge-icon":18},lg:{"padding-x":"xl","padding-y":"md","min-height":50,text:"lg",radius:"lg",icon:20,"badge-icon":20},xl:{"padding-x":"2xl","padding-y":"md","min-height":58,text:"xl",radius:"lg",icon:22,"badge-icon":22}},input:{sm:{"multiline-min-height":72},md:{"multiline-min-height":92},lg:{"multiline-min-height":110}},"search-bar":{sm:{radius:"pill"},md:{radius:"pill"},lg:{radius:"pill"}},"empty-state":{sm:{icon:48,"illustration-size":96,"title-text":"lg","description-text":"sm","padding-y":"lg","title-gap":"md","description-gap":"xs"},md:{icon:64,"illustration-size":160,"title-text":"xl","description-text":"base","padding-y":"xl","title-gap":"md","description-gap":"xs"},lg:{icon:80,"illustration-size":240,"title-text":"2xl","description-text":"lg","padding-y":"2xl","title-gap":"md","description-gap":"xs"}},"list-item":{sm:{"padding-y":"sm","title-text":"sm","subtitle-text":"xs","min-height":44},md:{"padding-y":"md","title-text":"base","subtitle-text":"sm","min-height":56},lg:{"padding-y":"lg","title-text":"lg","subtitle-text":"base","min-height":72}},badge:{sm:{text:"xs","min-width":16,height:16,"padding-x":"xs","dot-size":8},md:{text:"sm","min-width":20,height:20,"padding-x":"sm","dot-size":10},"border-width":1.5,"anchor-offset":4},chip:{sm:{"padding-x":"sm","padding-y":"xs",text:"xs","min-height":26,"close-size":16,"close-text":"xs",gap:"xs",icon:14},md:{"padding-x":"md","padding-y":"xs",text:"sm","min-height":32,"close-size":18,"close-text":"sm",gap:"sm",icon:16}},checkbox:{sm:{"box-size":16},md:{"box-size":20},lg:{"box-size":24},"label-gap":"sm"},radio:{sm:{outer:16,inner:8},md:{outer:20,inner:10},lg:{outer:24,inner:12},"label-gap":"sm"},switch:{sm:{"track-width":42,"track-height":26,"thumb-size":22,padding:"xxs"},md:{"track-width":51,"track-height":31,"thumb-size":27,padding:"xxs"},lg:{"track-width":60,"track-height":36,"thumb-size":32,padding:"xxs"}},"otp-input":{sm:{cell:36,text:"base",radius:"sm",gap:"sm"},md:{cell:48,text:"xl",radius:"md",gap:"sm"},lg:{cell:56,text:"2xl",radius:"lg",gap:"md"}},"segmented-control":{sm:{height:32,text:"sm","padding-x":"sm",icon:14},md:{height:40,text:"base","padding-x":"md",icon:16},lg:{height:48,text:"lg","padding-x":"lg",icon:18},"track-padding":"xs","underline-height":2,"pill-inset":"xs"},tabs:{sm:{text:"sm","padding-y":"sm","padding-x":"xs","scrollable-padding-x":"md",icon:16},md:{text:"base","padding-y":"md","padding-x":"sm","scrollable-padding-x":"lg",icon:18},lg:{text:"lg","padding-y":"lg","padding-x":"md","scrollable-padding-x":"xl",icon:20},"icon-gap":"xs","track-padding":"xs","underline-height":2,"pill-inset":"xs","disabled-opacity":.45,"badge-gap":"xs"},slider:{sm:{"track-height":4,"thumb-diameter":24},md:{"track-height":6,"thumb-diameter":28},lg:{"track-height":8,"thumb-diameter":32}},"floating-action-button":{sm:{diameter:40,icon:18,text:"sm","label-padding-x":"md"},md:{diameter:56,icon:22,text:"base","label-padding-x":"lg"},lg:{diameter:72,icon:28,text:"lg","label-padding-x":"xl"},"edge-offset":"xl","bottom-offset":"xl","secondary-gap":"lg","stagger-ms":50},dialog:{"icon-wrapper-size":48,"action-button-min-height":44},toast:{"icon-circle-size":28,"icon-glyph-text":"lg","tint-bar-width":0,"action-min-height":30},banner:{"tint-bar-width":0},screen:{gutter:"lg"}}};
|
|
1
|
+
"use strict";export const COLOR_NAMES=["bg","bg-subtle","bg-muted","surface","surface-inverse","surface-dark","surface-dark-border","on-surface-dark","on-surface-dark-muted","surface-ink","text","text-body","text-muted","text-subtle","text-inverse","link","border","border-subtle","field-bg","field-border","field-border-focus","focus-ring","scrim","on-scrim","thumb","primary","primary-hover","primary-soft","primary-text","on-primary","primary-wash","primary-wash-strong","neutral","neutral-hover","neutral-text","on-neutral","success","success-soft","success-text","on-success","warning","warning-soft","warning-text","on-warning","danger","danger-soft","danger-border","danger-text","offline-fill","online-fill","on-danger","info","info-soft","info-text","on-info","primary-pressed","switch-thumb","on-neutral-strong","text-disabled","surface-pressed","surface-hover","surface-selected","surface-disabled","skeleton","skeleton-highlight","glass-fill","glass-border","on-glass","glass-badge","field-bg-focus","field-bg-disabled","field-border-error","field-label","field-text","field-text-disabled","field-placeholder","field-placeholder-disabled","field-icon","field-icon-focus","field-icon-disabled","field-caret","field-message","avatar-1","avatar-2","avatar-3","avatar-4","avatar-5","avatar-6","avatar-7","avatar-8"];export const SPACE_NAMES=["none","xxs","xs","sm","md","lg","xl","2xl","3xl","4xl"];export const RADIUS_NAMES=["none","sm","md","lg","xl","pill"];export const TEXT_NAMES=["xs","sm","base","lg","xl","2xl","3xl","4xl","5xl","6xl","7xl","8xl"];export const WEIGHT_NAMES=["normal","medium","semibold","bold"];export const LEADING_NAMES=["heading","body","display"];export const LETTER_SPACING_NAMES=["tight","normal","wide"];export const FONT_NAMES=["ui","display","mono"];export const SHADOW_NAMES=["card","elevated","popover","modal","drawer"];export const DURATION_NAMES=["instant","fast","default","slow","slower"];export const EASE_NAMES=["in-out","accelerate","decelerate","sharp"];export const SIZE_NAMES=["border"];export const COMPONENT_KINDS={field:{radius:"radius","padding-x":"space","padding-y":"space","min-height":"px",text:"text",icon:"px","label-text":"text","label-gap":"space","message-text":"text","message-gap":"space"},press:{opacity:"number"},disabled:{opacity:"number"},button:{"padding-x":"space","padding-y":"space","min-height":"px",text:"text",radius:"radius",icon:"px","badge-icon":"px"},input:{"multiline-min-height":"px"},"search-bar":{radius:"radius"},"empty-state":{icon:"px","illustration-size":"px","title-text":"text","description-text":"text","padding-y":"space","title-gap":"space","description-gap":"space"},"list-item":{"padding-y":"space","title-text":"text","subtitle-text":"text","min-height":"px"},badge:{text:"text","min-width":"px",height:"px","padding-x":"space","dot-size":"px","border-width":"px","anchor-offset":"px"},chip:{"padding-x":"space","padding-y":"space",text:"text","min-height":"px","close-size":"px","close-text":"text",gap:"space",icon:"px"},checkbox:{"box-size":"px","label-gap":"space"},radio:{outer:"px",inner:"px","label-gap":"space"},switch:{"track-width":"px","track-height":"px","thumb-size":"px",padding:"space"},"otp-input":{cell:"px",text:"text",radius:"radius",gap:"space"},"segmented-control":{height:"px",text:"text","padding-x":"space",icon:"px","track-padding":"space","underline-height":"px","pill-inset":"space"},tabs:{text:"text","padding-y":"space","padding-x":"space","scrollable-padding-x":"space",icon:"px","icon-gap":"space","track-padding":"space","underline-height":"px","pill-inset":"space","disabled-opacity":"number","badge-gap":"space"},slider:{"track-height":"px","thumb-diameter":"px"},"floating-action-button":{diameter:"px",icon:"px",text:"text","label-padding-x":"space","edge-offset":"space","bottom-offset":"space","secondary-gap":"space","stagger-ms":"ms"},dialog:{"icon-wrapper-size":"px","action-button-min-height":"px"},toast:{"icon-circle-size":"px","icon-glyph-text":"text","tint-bar-width":"px","action-min-height":"px"},banner:{"tint-bar-width":"px"},screen:{gutter:"space"}};export const lightTokens={mode:"light",colors:{bg:"#ffffff","bg-subtle":"#f8f8fb","bg-muted":"#f1f1f5",surface:"#ffffff","surface-inverse":"#0f0f1a","surface-dark":"#071437","surface-dark-border":"#2a3553","on-surface-dark":"#ffffff","on-surface-dark-muted":"#babdc7","surface-ink":"#0b0e16",text:"#252f4a","text-body":"#0f0f1a","text-muted":"#52525b","text-subtle":"#62626b","text-inverse":"#ffffff",link:"#4f46e5",border:"#e5e5ec","border-subtle":"#efeff3","field-bg":"#f9fbfc","field-border":"#ebedf3","field-border-focus":"#bed2f9","focus-ring":"#4f46e5",scrim:"#0f0f1a80","on-scrim":"#ffffff",thumb:"#ffffff",primary:"#4f46e5","primary-hover":"#4338ca","primary-soft":"#e0e7ff","primary-text":"#4f46e5","on-primary":"#ffffff","primary-wash":"#4f46e514","primary-wash-strong":"#4f46e533",neutral:"#f4f4f8","neutral-hover":"#e9e9f0","neutral-text":"#52525b","on-neutral":"#0f0f1a",success:"#18864f","success-soft":"#e8faee","success-text":"#147042","on-success":"#ffffff",warning:"#f59e0b","warning-soft":"#fff8e6","warning-text":"#8f5c06","on-warning":"#0f0f1a",danger:"#e12c32","danger-soft":"#ffeaef","danger-border":"#e5484d","danger-text":"#bc1b20","offline-fill":"#e82646","online-fill":"#04b440","on-danger":"#ffffff",info:"#1b6ef5","info-soft":"#e9f3ff","info-text":"#0958d9","on-info":"#ffffff","primary-pressed":"#3730a3","switch-thumb":"#ffffff","on-neutral-strong":"#ffffff","text-disabled":"#b4b4bb","surface-pressed":"#0f0f1a0f","surface-hover":"#0f0f1a0a","surface-selected":"#4f46e51a","surface-disabled":"#f1f1f5",skeleton:"#ebedf3","skeleton-highlight":"#f5f6fa","glass-fill":"#ffffff47","glass-border":"#ffffff73","on-glass":"#0f0f1a","glass-badge":"#ffffff","field-bg-focus":"#ffffff","field-bg-disabled":"#f5f6fa","field-border-error":"#fdbfce","field-label":"#242f4a","field-text":"#252f4a","field-text-disabled":"#7a8197","field-placeholder":"#626d8b","field-placeholder-disabled":"#7a8197","field-icon":"#7a849f","field-icon-focus":"#4b5675","field-icon-disabled":"#c4cada","field-caret":"#5b8dee","field-message":"#d81736","avatar-1":"#4f46e5","avatar-2":"#0a7979","avatar-3":"#a45a05","avatar-4":"#cd226e","avatar-5":"#2462eb","avatar-6":"#7c3aed","avatar-7":"#047c57","avatar-8":"#d42222"},space:{none:0,xxs:2,xs:4,sm:8,md:12,lg:16,xl:24,"2xl":32,"3xl":48,"4xl":64},radius:{none:0,sm:6,md:10,lg:14,xl:20,pill:9999},text:{xs:{size:11},sm:{size:13},base:{size:15},lg:{size:17},xl:{size:20},"2xl":{size:24},"3xl":{size:30},"4xl":{size:36},"5xl":{size:45},"6xl":{size:57},"7xl":{size:64},"8xl":{size:72}},weight:{normal:"400",medium:"500",semibold:"600",bold:"700"},leading:{heading:1.2,body:1.4,display:1.2},"letter-spacing":{tight:-.2,normal:0,wide:.4},font:{ui:{},display:{},mono:{}},shadow:{card:{shadowColor:"#000000",shadowOffset:{width:0,height:2},shadowOpacity:.059,shadowRadius:4,elevation:2},elevated:{shadowColor:"#000000",shadowOffset:{width:0,height:4},shadowOpacity:.078,shadowRadius:8,elevation:4},popover:{shadowColor:"#000000",shadowOffset:{width:0,height:8},shadowOpacity:.102,shadowRadius:16,elevation:8},modal:{shadowColor:"#000000",shadowOffset:{width:0,height:12},shadowOpacity:.141,shadowRadius:24,elevation:12},drawer:{shadowColor:"#000000",shadowOffset:{width:0,height:12},shadowOpacity:.141,shadowRadius:24,elevation:12}},motion:{duration:{instant:80,fast:160,default:240,slow:360,slower:500},ease:{"in-out":[.4,0,.2,1],accelerate:[.4,0,1,1],decelerate:[0,0,.2,1],sharp:[.4,0,.6,1]}},size:{border:1},components:{field:{sm:{radius:"md","padding-x":"sm","padding-y":"sm","min-height":38,text:"sm",icon:14,"label-text":"xs","label-gap":"xs","message-text":"xs","message-gap":"xxs"},md:{radius:"md","padding-x":"md","padding-y":"md","min-height":44,text:"base",icon:16,"label-text":"sm","label-gap":"xs","message-text":"sm","message-gap":"xxs"},lg:{radius:"md","padding-x":"lg","padding-y":"lg","min-height":52,text:"lg",icon:18,"label-text":"base","label-gap":"xs","message-text":"base","message-gap":"xxs"}},press:{opacity:.85},disabled:{opacity:.55},button:{xs:{"padding-x":"sm","padding-y":"xs","min-height":28,text:"xs",radius:"md",icon:14,"badge-icon":11},sm:{"padding-x":"md","padding-y":"xs","min-height":34,text:"sm",radius:"md",icon:16,"badge-icon":16},md:{"padding-x":"lg","padding-y":"sm","min-height":44,text:"base",radius:"md",icon:18,"badge-icon":18},lg:{"padding-x":"xl","padding-y":"md","min-height":50,text:"lg",radius:"lg",icon:20,"badge-icon":20},xl:{"padding-x":"2xl","padding-y":"md","min-height":58,text:"xl",radius:"lg",icon:22,"badge-icon":22}},input:{sm:{"multiline-min-height":72},md:{"multiline-min-height":92},lg:{"multiline-min-height":110}},"search-bar":{sm:{radius:"pill"},md:{radius:"pill"},lg:{radius:"pill"}},"empty-state":{sm:{icon:48,"illustration-size":96,"title-text":"lg","description-text":"sm","padding-y":"lg","title-gap":"md","description-gap":"xs"},md:{icon:64,"illustration-size":160,"title-text":"xl","description-text":"base","padding-y":"xl","title-gap":"md","description-gap":"xs"},lg:{icon:80,"illustration-size":240,"title-text":"2xl","description-text":"lg","padding-y":"2xl","title-gap":"md","description-gap":"xs"}},"list-item":{sm:{"padding-y":"sm","title-text":"sm","subtitle-text":"xs","min-height":44},md:{"padding-y":"md","title-text":"base","subtitle-text":"sm","min-height":56},lg:{"padding-y":"lg","title-text":"lg","subtitle-text":"base","min-height":72}},badge:{sm:{text:"xs","min-width":16,height:16,"padding-x":"xs","dot-size":8},md:{text:"sm","min-width":20,height:20,"padding-x":"sm","dot-size":10},"border-width":1.5,"anchor-offset":4},chip:{sm:{"padding-x":"sm","padding-y":"xs",text:"xs","min-height":26,"close-size":16,"close-text":"xs",gap:"xs",icon:14},md:{"padding-x":"md","padding-y":"xs",text:"sm","min-height":32,"close-size":18,"close-text":"sm",gap:"sm",icon:16}},checkbox:{sm:{"box-size":16},md:{"box-size":20},lg:{"box-size":24},"label-gap":"sm"},radio:{sm:{outer:16,inner:8},md:{outer:20,inner:10},lg:{outer:24,inner:12},"label-gap":"sm"},switch:{sm:{"track-width":42,"track-height":26,"thumb-size":22,padding:"xxs"},md:{"track-width":51,"track-height":31,"thumb-size":27,padding:"xxs"},lg:{"track-width":60,"track-height":36,"thumb-size":32,padding:"xxs"}},"otp-input":{sm:{cell:36,text:"base",radius:"sm",gap:"sm"},md:{cell:48,text:"xl",radius:"md",gap:"sm"},lg:{cell:56,text:"2xl",radius:"lg",gap:"md"}},"segmented-control":{sm:{height:32,text:"sm","padding-x":"sm",icon:14},md:{height:40,text:"base","padding-x":"md",icon:16},lg:{height:48,text:"lg","padding-x":"lg",icon:18},"track-padding":"xs","underline-height":2,"pill-inset":"xs"},tabs:{sm:{text:"sm","padding-y":"sm","padding-x":"xs","scrollable-padding-x":"md",icon:16},md:{text:"base","padding-y":"md","padding-x":"sm","scrollable-padding-x":"lg",icon:18},lg:{text:"lg","padding-y":"lg","padding-x":"md","scrollable-padding-x":"xl",icon:20},"icon-gap":"xs","track-padding":"xs","underline-height":2,"pill-inset":"xs","disabled-opacity":.45,"badge-gap":"xs"},slider:{sm:{"track-height":4,"thumb-diameter":24},md:{"track-height":6,"thumb-diameter":28},lg:{"track-height":8,"thumb-diameter":32}},"floating-action-button":{sm:{diameter:40,icon:18,text:"sm","label-padding-x":"md"},md:{diameter:56,icon:22,text:"base","label-padding-x":"lg"},lg:{diameter:72,icon:28,text:"lg","label-padding-x":"xl"},"edge-offset":"xl","bottom-offset":"xl","secondary-gap":"lg","stagger-ms":50},dialog:{"icon-wrapper-size":48,"action-button-min-height":44},toast:{"icon-circle-size":28,"icon-glyph-text":"lg","tint-bar-width":0,"action-min-height":30},banner:{"tint-bar-width":0},screen:{gutter:"lg"}}};export const darkTokens={mode:"dark",colors:{bg:"#0b0b12","bg-subtle":"#13131c","bg-muted":"#1c1c26",surface:"#1c1c26","surface-inverse":"#fafafa","surface-dark":"#071437","surface-dark-border":"#2a3553","on-surface-dark":"#ffffff","on-surface-dark-muted":"#babdc7","surface-ink":"#0b0e16",text:"#e2e2e2","text-body":"#fafafa","text-muted":"#b4b4bb","text-subtle":"#919199","text-inverse":"#0f0f1a",link:"#9292ee",border:"#27272f","border-subtle":"#1c1c26","field-bg":"#13131c","field-border":"#27272f","field-border-focus":"#3d5fb0","focus-ring":"#7c7ce8",scrim:"#000000a6","on-scrim":"#ffffff",thumb:"#3a3e49",primary:"#7c7ce8","primary-hover":"#9292ee","primary-soft":"#1f1f3d","primary-text":"#8989ea","on-primary":"#0f0f1a","primary-wash":"#7c7ce814","primary-wash-strong":"#7c7ce833",neutral:"#1f1f26","neutral-hover":"#2a2a33","neutral-text":"#b4b4bb","on-neutral":"#fafafa",success:"#30c780","success-soft":"#04b4402e","success-text":"#30c780","on-success":"#0f0f1a",warning:"#fbbf24","warning-soft":"#dfa0002e","warning-text":"#fbbf24","on-warning":"#0f0f1a",danger:"#f87171","danger-soft":"#e826462e","danger-border":"#f87171","danger-text":"#f87171","offline-fill":"#e82646","online-fill":"#04b440","on-danger":"#0f0f1a",info:"#60a5fa","info-soft":"#056ee92e","info-text":"#60a5fa","on-info":"#0f0f1a","primary-pressed":"#a8a8f2","switch-thumb":"#ffffff","on-neutral-strong":"#0f0f1a","text-disabled":"#52525b","surface-pressed":"#ffffff14","surface-hover":"#ffffff0d","surface-selected":"#7c7ce82e","surface-disabled":"#1c1c26",skeleton:"#1c1c26","skeleton-highlight":"#27272f","glass-fill":"#ffffff47","glass-border":"#ffffff73","on-glass":"#0f0f1a","glass-badge":"#ffffff","field-bg-focus":"#0b0b12","field-bg-disabled":"#1c1c26","field-border-error":"#8a2f42","field-label":"#e4e6ee","field-text":"#fafafa","field-text-disabled":"#71717a","field-placeholder":"#84848d","field-placeholder-disabled":"#71717a","field-icon":"#8b8b95","field-icon-focus":"#d4d4db","field-icon-disabled":"#52525b","field-caret":"#7c9ef0","field-message":"#f87171","avatar-1":"#8b8bee","avatar-2":"#2dd4bf","avatar-3":"#fcd34d","avatar-4":"#f472b6","avatar-5":"#60a5fa","avatar-6":"#a78bfa","avatar-7":"#34d399","avatar-8":"#f87171"},space:{none:0,xxs:2,xs:4,sm:8,md:12,lg:16,xl:24,"2xl":32,"3xl":48,"4xl":64},radius:{none:0,sm:6,md:10,lg:14,xl:20,pill:9999},text:{xs:{size:11},sm:{size:13},base:{size:15},lg:{size:17},xl:{size:20},"2xl":{size:24},"3xl":{size:30},"4xl":{size:36},"5xl":{size:45},"6xl":{size:57},"7xl":{size:64},"8xl":{size:72}},weight:{normal:"400",medium:"500",semibold:"600",bold:"700"},leading:{heading:1.2,body:1.4,display:1.2},"letter-spacing":{tight:-.2,normal:0,wide:.4},font:{ui:{},display:{},mono:{}},shadow:{card:{shadowColor:"#000000",shadowOffset:{width:0,height:2},shadowOpacity:.4,shadowRadius:4,elevation:2},elevated:{shadowColor:"#000000",shadowOffset:{width:0,height:4},shadowOpacity:.502,shadowRadius:8,elevation:4},popover:{shadowColor:"#000000",shadowOffset:{width:0,height:8},shadowOpacity:.549,shadowRadius:16,elevation:8},modal:{shadowColor:"#000000",shadowOffset:{width:0,height:12},shadowOpacity:.6,shadowRadius:24,elevation:12},drawer:{shadowColor:"#000000",shadowOffset:{width:0,height:12},shadowOpacity:.6,shadowRadius:24,elevation:12}},motion:{duration:{instant:80,fast:160,default:240,slow:360,slower:500},ease:{"in-out":[.4,0,.2,1],accelerate:[.4,0,1,1],decelerate:[0,0,.2,1],sharp:[.4,0,.6,1]}},size:{border:1},components:{field:{sm:{radius:"md","padding-x":"sm","padding-y":"sm","min-height":38,text:"sm",icon:14,"label-text":"xs","label-gap":"xs","message-text":"xs","message-gap":"xxs"},md:{radius:"md","padding-x":"md","padding-y":"md","min-height":44,text:"base",icon:16,"label-text":"sm","label-gap":"xs","message-text":"sm","message-gap":"xxs"},lg:{radius:"md","padding-x":"lg","padding-y":"lg","min-height":52,text:"lg",icon:18,"label-text":"base","label-gap":"xs","message-text":"base","message-gap":"xxs"}},press:{opacity:.85},disabled:{opacity:.55},button:{xs:{"padding-x":"sm","padding-y":"xs","min-height":28,text:"xs",radius:"md",icon:14,"badge-icon":11},sm:{"padding-x":"md","padding-y":"xs","min-height":34,text:"sm",radius:"md",icon:16,"badge-icon":16},md:{"padding-x":"lg","padding-y":"sm","min-height":44,text:"base",radius:"md",icon:18,"badge-icon":18},lg:{"padding-x":"xl","padding-y":"md","min-height":50,text:"lg",radius:"lg",icon:20,"badge-icon":20},xl:{"padding-x":"2xl","padding-y":"md","min-height":58,text:"xl",radius:"lg",icon:22,"badge-icon":22}},input:{sm:{"multiline-min-height":72},md:{"multiline-min-height":92},lg:{"multiline-min-height":110}},"search-bar":{sm:{radius:"pill"},md:{radius:"pill"},lg:{radius:"pill"}},"empty-state":{sm:{icon:48,"illustration-size":96,"title-text":"lg","description-text":"sm","padding-y":"lg","title-gap":"md","description-gap":"xs"},md:{icon:64,"illustration-size":160,"title-text":"xl","description-text":"base","padding-y":"xl","title-gap":"md","description-gap":"xs"},lg:{icon:80,"illustration-size":240,"title-text":"2xl","description-text":"lg","padding-y":"2xl","title-gap":"md","description-gap":"xs"}},"list-item":{sm:{"padding-y":"sm","title-text":"sm","subtitle-text":"xs","min-height":44},md:{"padding-y":"md","title-text":"base","subtitle-text":"sm","min-height":56},lg:{"padding-y":"lg","title-text":"lg","subtitle-text":"base","min-height":72}},badge:{sm:{text:"xs","min-width":16,height:16,"padding-x":"xs","dot-size":8},md:{text:"sm","min-width":20,height:20,"padding-x":"sm","dot-size":10},"border-width":1.5,"anchor-offset":4},chip:{sm:{"padding-x":"sm","padding-y":"xs",text:"xs","min-height":26,"close-size":16,"close-text":"xs",gap:"xs",icon:14},md:{"padding-x":"md","padding-y":"xs",text:"sm","min-height":32,"close-size":18,"close-text":"sm",gap:"sm",icon:16}},checkbox:{sm:{"box-size":16},md:{"box-size":20},lg:{"box-size":24},"label-gap":"sm"},radio:{sm:{outer:16,inner:8},md:{outer:20,inner:10},lg:{outer:24,inner:12},"label-gap":"sm"},switch:{sm:{"track-width":42,"track-height":26,"thumb-size":22,padding:"xxs"},md:{"track-width":51,"track-height":31,"thumb-size":27,padding:"xxs"},lg:{"track-width":60,"track-height":36,"thumb-size":32,padding:"xxs"}},"otp-input":{sm:{cell:36,text:"base",radius:"sm",gap:"sm"},md:{cell:48,text:"xl",radius:"md",gap:"sm"},lg:{cell:56,text:"2xl",radius:"lg",gap:"md"}},"segmented-control":{sm:{height:32,text:"sm","padding-x":"sm",icon:14},md:{height:40,text:"base","padding-x":"md",icon:16},lg:{height:48,text:"lg","padding-x":"lg",icon:18},"track-padding":"xs","underline-height":2,"pill-inset":"xs"},tabs:{sm:{text:"sm","padding-y":"sm","padding-x":"xs","scrollable-padding-x":"md",icon:16},md:{text:"base","padding-y":"md","padding-x":"sm","scrollable-padding-x":"lg",icon:18},lg:{text:"lg","padding-y":"lg","padding-x":"md","scrollable-padding-x":"xl",icon:20},"icon-gap":"xs","track-padding":"xs","underline-height":2,"pill-inset":"xs","disabled-opacity":.45,"badge-gap":"xs"},slider:{sm:{"track-height":4,"thumb-diameter":24},md:{"track-height":6,"thumb-diameter":28},lg:{"track-height":8,"thumb-diameter":32}},"floating-action-button":{sm:{diameter:40,icon:18,text:"sm","label-padding-x":"md"},md:{diameter:56,icon:22,text:"base","label-padding-x":"lg"},lg:{diameter:72,icon:28,text:"lg","label-padding-x":"xl"},"edge-offset":"xl","bottom-offset":"xl","secondary-gap":"lg","stagger-ms":50},dialog:{"icon-wrapper-size":48,"action-button-min-height":44},toast:{"icon-circle-size":28,"icon-glyph-text":"lg","tint-bar-width":0,"action-min-height":30},banner:{"tint-bar-width":0},screen:{gutter:"lg"}}};
|
|
@@ -12,7 +12,7 @@ export interface AsyncBlockLabels {
|
|
|
12
12
|
}
|
|
13
13
|
export declare const DEFAULT_ASYNC_BLOCK_LABELS: Readonly<AsyncBlockLabels>;
|
|
14
14
|
export interface AsyncBlockProps<T> {
|
|
15
|
-
/** The request's data state: one of the
|
|
15
|
+
/** The request's data state: one of the five members of DataState; idle (a skipped query) draws nothing. */
|
|
16
16
|
state: DataState<T>;
|
|
17
17
|
/** Called only in the "data" state, with the loaded data. */
|
|
18
18
|
children: (data: T) => React.ReactNode;
|
|
@@ -46,6 +46,6 @@ export interface AsyncBlockProps<T> {
|
|
|
46
46
|
* flex layout (a list inside lost its `flex: 1`), so only the placeholder
|
|
47
47
|
* states carry `style` and `testID`.
|
|
48
48
|
*/
|
|
49
|
-
export declare function AsyncBlock<T>({ state, children, empty, errorVariant, skeleton, errorTitle, offlineTitle, labels: labelOverrides, style, testID, }: AsyncBlockProps<T>): React.ReactElement;
|
|
49
|
+
export declare function AsyncBlock<T>({ state, children, empty, errorVariant, skeleton, errorTitle, offlineTitle, labels: labelOverrides, style, testID, }: AsyncBlockProps<T>): React.ReactElement | null;
|
|
50
50
|
export default AsyncBlock;
|
|
51
51
|
//# sourceMappingURL=AsyncBlock.d.ts.map
|
|
@@ -27,10 +27,11 @@ export type AvatarShape = "circle" | "square" | "rounded";
|
|
|
27
27
|
/**
|
|
28
28
|
* Presence dots (`online`, `offline`, `busy`, `away`) and identity states
|
|
29
29
|
* (`verified`: green ring with a check seal at the status corner, `pending`:
|
|
30
|
-
* amber ring, no seal
|
|
31
|
-
* the picture, so switching between them
|
|
30
|
+
* amber ring, no seal, `rejected`: red ring with a cross seal). The ring states
|
|
31
|
+
* keep the avatar's footprint and inset the picture, so switching between them
|
|
32
|
+
* never reflows a layout.
|
|
32
33
|
*/
|
|
33
|
-
export type AvatarStatus = "online" | "offline" | "busy" | "away" | "verified" | "pending" | null;
|
|
34
|
+
export type AvatarStatus = "online" | "offline" | "busy" | "away" | "verified" | "pending" | "rejected" | null;
|
|
34
35
|
export type AvatarStatusPosition = "topRight" | "bottomRight";
|
|
35
36
|
/**
|
|
36
37
|
* Theme colour of the initials disc: a soft tint of the tone behind initials
|
|
@@ -51,6 +52,7 @@ export interface AvatarLabels {
|
|
|
51
52
|
avatarOf: (name: string) => string;
|
|
52
53
|
verified: string;
|
|
53
54
|
pendingVerification: string;
|
|
55
|
+
rejected: string;
|
|
54
56
|
groupOf: (count: number) => string;
|
|
55
57
|
moreCount: (count: number) => string;
|
|
56
58
|
moreAvatars: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type ForwardRefExoticComponent, type RefAttributes } from "react";
|
|
2
|
-
import type { HostInstance, PressableProps, StyleProp, TextStyle, ViewStyle } from "react-native";
|
|
2
|
+
import type { GestureResponderEvent, HostInstance, PressableProps, StyleProp, TextStyle, ViewStyle } from "react-native";
|
|
3
3
|
import type { PressAnimationPreset } from "../../hooks/usePressAnimation";
|
|
4
4
|
import type { GradientDefinition, Theme } from "../../theme/types";
|
|
5
5
|
import type { FillVariant, Size, Tone } from "../../types/vocabulary";
|
|
@@ -25,9 +25,14 @@ export interface ButtonLabels {
|
|
|
25
25
|
loading: string;
|
|
26
26
|
}
|
|
27
27
|
export declare const DEFAULT_BUTTON_LABELS: Readonly<ButtonLabels>;
|
|
28
|
-
export interface ButtonProps extends Omit<PressableProps, "style" | "children"> {
|
|
28
|
+
export interface ButtonProps extends Omit<PressableProps, "style" | "children" | "onPress"> {
|
|
29
29
|
/** The label, and the button's accessible name unless `accessibilityLabel` is set. */
|
|
30
30
|
label: string;
|
|
31
|
+
/**
|
|
32
|
+
* Runs on press. When it returns a promise, the button is busy until the promise settles: a press in
|
|
33
|
+
* that time is dropped, and a rejection clears the busy state and is then rethrown.
|
|
34
|
+
*/
|
|
35
|
+
onPress?: ((event: GestureResponderEvent) => unknown) | null | undefined;
|
|
31
36
|
variant?: ButtonVariant | undefined;
|
|
32
37
|
tone?: ButtonTone | undefined;
|
|
33
38
|
size?: ButtonSize | undefined;
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* NonModalBottomSheet: a bottom sheet with snap points and no scrim. It is drawn
|
|
3
|
+
* inside its parent, which must be positioned and sized, so the screen behind it
|
|
4
|
+
* stays live. Render it after the screen content: it is read after the content.
|
|
5
|
+
*
|
|
6
|
+
* USAGE:
|
|
7
|
+
*
|
|
8
|
+
* const [open, setOpen] = useState(false);
|
|
9
|
+
* <View style={{ flex: 1 }}>
|
|
10
|
+
* <YourScreen />
|
|
11
|
+
* <NonModalBottomSheet open={open} onClose={() => setOpen(false)} snapPoints={["25%", "50%"]}>
|
|
12
|
+
* <YourContent />
|
|
13
|
+
* </NonModalBottomSheet>
|
|
14
|
+
* </View>
|
|
15
|
+
*/
|
|
16
|
+
import type React from "react";
|
|
17
|
+
import type { StyleProp, ViewStyle } from "react-native";
|
|
18
|
+
/** A snap point: a height in dp, or a percentage of the host height up to 100%. */
|
|
19
|
+
export type NonModalSnapPoint = number | `${number}%`;
|
|
20
|
+
export interface NonModalBottomSheetLabels {
|
|
21
|
+
dragHandle: string;
|
|
22
|
+
}
|
|
23
|
+
export declare const DEFAULT_NON_MODAL_BOTTOM_SHEET_LABELS: Readonly<NonModalBottomSheetLabels>;
|
|
24
|
+
export interface NonModalBottomSheetProps {
|
|
25
|
+
/** Opens and closes the sheet. A drag close calls `onClose`, and the parent sets `open` to false. */
|
|
26
|
+
open: boolean;
|
|
27
|
+
/** Called after the person drags the sheet closed. */
|
|
28
|
+
onClose: () => void;
|
|
29
|
+
/** The heights the sheet rests at, in any order (they are sorted ascending). */
|
|
30
|
+
snapPoints: NonModalSnapPoint[];
|
|
31
|
+
/** The snap point at rest (the smallest is 0). Changing it moves an open sheet. */
|
|
32
|
+
snapIndex?: number | undefined;
|
|
33
|
+
/** Fires for a drag or an accessibility move, never for a prop change. */
|
|
34
|
+
onSnapChange?: ((index: number) => void) | undefined;
|
|
35
|
+
/** Defaults to true. */
|
|
36
|
+
enablePanDownToClose?: boolean | undefined;
|
|
37
|
+
/** Wraps children in a ScrollView between the header and the footer. Defaults to false. */
|
|
38
|
+
scrollable?: boolean | undefined;
|
|
39
|
+
title?: string | undefined;
|
|
40
|
+
header?: React.ReactNode | undefined;
|
|
41
|
+
footer?: React.ReactNode | undefined;
|
|
42
|
+
labels?: Partial<NonModalBottomSheetLabels> | undefined;
|
|
43
|
+
handleIndicatorStyle?: StyleProp<ViewStyle> | undefined;
|
|
44
|
+
containerStyle?: StyleProp<ViewStyle> | undefined;
|
|
45
|
+
children?: React.ReactNode | undefined;
|
|
46
|
+
accessibilityLabel?: string | undefined;
|
|
47
|
+
testID?: string | undefined;
|
|
48
|
+
}
|
|
49
|
+
declare const NonModalBottomSheet: React.FC<NonModalBottomSheetProps>;
|
|
50
|
+
export { NonModalBottomSheet };
|
|
51
|
+
export default NonModalBottomSheet;
|
|
52
|
+
//# sourceMappingURL=NonModalBottomSheet.d.ts.map
|
|
@@ -8,7 +8,8 @@
|
|
|
8
8
|
* or tick icon / multi checkbox) and the multi-select Done footer. The Modal
|
|
9
9
|
* owns the open/close animations, the scrim and the dismissal; selection STATE
|
|
10
10
|
* stays with the caller; the sheet marks the rows of `value` and reports every
|
|
11
|
-
* tap on an enabled row through `onChange(value, option)
|
|
11
|
+
* tap on an enabled row through `onChange(value, option)`, except a row with
|
|
12
|
+
* its own action, which runs it and closes the sheet.
|
|
12
13
|
*
|
|
13
14
|
* Also the home of the canonical option types (`SelectValue`, `SelectOption`)
|
|
14
15
|
* and accessor signatures shared by every option-picking component. Select
|
|
@@ -24,6 +25,8 @@ export interface SelectOption {
|
|
|
24
25
|
description?: string | undefined;
|
|
25
26
|
disabled?: boolean | undefined;
|
|
26
27
|
icon?: React.ReactNode | undefined;
|
|
28
|
+
/** Runs when the row is tapped, then the sheet closes; `onChange` does not fire for this row. */
|
|
29
|
+
onPress?: (() => void) | undefined;
|
|
27
30
|
}
|
|
28
31
|
/** A titled group of options; the sheet lists groups in order under a header row each. */
|
|
29
32
|
export interface OptionSheetSection<T = SelectOption> {
|
|
@@ -105,6 +108,8 @@ export interface OptionSheetProps<T = SelectOption> {
|
|
|
105
108
|
* are untouched, so the caller passes a matching icon. Default: none.
|
|
106
109
|
*/
|
|
107
110
|
destructiveOf?: ((option: T) => boolean) | undefined;
|
|
111
|
+
/** The action a row runs on tap. Default: reads the option's `onPress`. A row with one runs it and closes the sheet; `onChange` does not fire for it. */
|
|
112
|
+
getOptionAction?: ((option: T) => (() => void) | undefined) | undefined;
|
|
108
113
|
/** The selected value, or the selected values in multi mode. Marks those rows. */
|
|
109
114
|
value?: SelectValue | ReadonlyArray<SelectValue> | undefined;
|
|
110
115
|
/** Tap on an enabled option, with its value and option. Caller updates state and (for single-select) closes. */
|
|
@@ -5,4 +5,5 @@ export declare const selectOptionValue: (o: unknown) => SelectValue;
|
|
|
5
5
|
export declare const selectOptionDescription: (o: unknown) => string | undefined;
|
|
6
6
|
export declare const selectOptionDisabled: (o: unknown) => boolean;
|
|
7
7
|
export declare const selectOptionIcon: (o: unknown) => React.ReactNode;
|
|
8
|
+
export declare const selectOptionAction: (o: unknown) => (() => void) | undefined;
|
|
8
9
|
//# sourceMappingURL=optionAccessors.d.ts.map
|
|
@@ -23,6 +23,10 @@ interface WheelProps {
|
|
|
23
23
|
reducedMotion: boolean;
|
|
24
24
|
/** Tapping the selected value opens an inline number field for it. */
|
|
25
25
|
typeable?: boolean | undefined;
|
|
26
|
+
/** Name of the screen reader action that opens the typed entry. */
|
|
27
|
+
typeAction?: string | undefined;
|
|
28
|
+
/** Spoken when the typed entry opens. */
|
|
29
|
+
typeEditor?: string | undefined;
|
|
26
30
|
testID?: string | undefined;
|
|
27
31
|
}
|
|
28
32
|
/**
|
|
@@ -61,6 +61,8 @@ export interface WheelPickerLabels {
|
|
|
61
61
|
minuteOne: string;
|
|
62
62
|
minuteMany: string;
|
|
63
63
|
value: string;
|
|
64
|
+
typeAction: string;
|
|
65
|
+
typeEditor: string;
|
|
64
66
|
}
|
|
65
67
|
export declare const DEFAULT_WHEEL_PICKER_LABELS: Readonly<WheelPickerLabels>;
|
|
66
68
|
/** Hours and minutes, up to 23 h 59 min, with the value as a whole number of minutes. */
|
|
@@ -110,6 +110,8 @@ export type { MessageListLabels, MessageListProps, MessageRenderInfo } from "./M
|
|
|
110
110
|
export { DEFAULT_MESSAGE_LIST_LABELS, MessageList } from "./MessageList";
|
|
111
111
|
export type { ModalLabels, ModalPresentation, ModalProps } from "./Modal";
|
|
112
112
|
export { DEFAULT_MODAL_LABELS, MODAL_DISMISS_GRACE_MS, Modal } from "./Modal";
|
|
113
|
+
export type { NonModalBottomSheetLabels, NonModalBottomSheetProps, NonModalSnapPoint } from "./NonModalBottomSheet";
|
|
114
|
+
export { DEFAULT_NON_MODAL_BOTTOM_SHEET_LABELS, NonModalBottomSheet } from "./NonModalBottomSheet";
|
|
113
115
|
export type { NumberInputLabels, NumberInputProps, NumberInputRef, NumberInputSize, NumberInputVariant } from "./NumberInput";
|
|
114
116
|
export { DEFAULT_NUMBER_INPUT_LABELS, NumberInput } from "./NumberInput";
|
|
115
117
|
export type { OnboardingPage, OnboardingPagerLabels, OnboardingPagerProps, } from "./OnboardingPager";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export { PHONE_CHROME_INSETS } from "./canvasKit";
|
|
2
2
|
export type * from "./components";
|
|
3
|
-
export { Accordion, AccordionGroup, ALL_CALLING_CODES, AmountSlider, AnimatePresence, AppBar, AppLockOverlay, AsyncBlock, AuthedImage, Autocomplete, Avatar, AvatarGroup, authedImageCacheStats, Badge, Banner, BarChart, BottomNavigation, BottomSheet, Box, Button, buttonLabelInk, Calendar, Card, Carousel, Checkbox, Chip, ChoiceGroup, Composer, Confetti, ConfirmHost, clearAuthedImageCache, confirm, DatePicker, DateRangePicker, DateSeparator, DEFAULT_CALLING_CODES, DecimalInput, Descriptions, Dialog, Divider, Drawer, defineStatusMap, EmptyState, ErrorBoundary, FilePicker, FileViewer, FilterChipRow, FloatingActionButton, FloatingActionButtonGroup, ForceUpdateDialog, FormField, formatE164, formatFileSize, getAuthedImageCacheLimit, IconBadge, IconButton, ImageGallery, InlineSelect, Input, KeyboardAwareScrollView, KeyboardToolbar, ListItem, ListSection, LoaderOverlay, loader, Markdown, Menu, MessageBubble, MessageList, MODAL_DISMISS_GRACE_MS, Modal, NumberInput, OnboardingPager, OptionSheet, OTPInput, OTPResendRow, PagedListFooter, PermissionPrompt, PhoneNumberInput, PickerTrigger, ProfileCompletion, ProfilePicker, ProgressBar, ProgressRing, Radio, RadioDot, RadioGroup, Rating, Repeater, RichTextEditor, Row, ScannerOverlay, Screen, SearchBar, SectionHeader, SegmentedControl, Select, SignaturePad, Skeleton, SkeletonCircle, SkeletonClockProvider, SkeletonContent, SkeletonList, SkeletonProvider, SkeletonSkip, SkeletonText, Slider, SliderField, SlideToConfirm, SortableList, Spacer, Sparkline, Spinner, SquircleImage, SquircleView, Stack, StatTile, StatusBadge, Stepper, Swipeable, Switch, setAuthedImageCacheLimit, Tabs, TagInput, Text, TextInkContext, Timeline, TimePicker, Toast, ToastHost, ToastProvider, Tooltip, Tour, TypingIndicator, toast, useBottomSheet, useErrorHandler, useRecentSearches, useTextInk, useToast, WheelPicker, withErrorBoundary, ZoomableImage, } from "./components";
|
|
3
|
+
export { Accordion, AccordionGroup, ALL_CALLING_CODES, AmountSlider, AnimatePresence, AppBar, AppLockOverlay, AsyncBlock, AuthedImage, Autocomplete, Avatar, AvatarGroup, authedImageCacheStats, Badge, Banner, BarChart, BottomNavigation, BottomSheet, Box, Button, buttonLabelInk, Calendar, Card, Carousel, Checkbox, Chip, ChoiceGroup, Composer, Confetti, ConfirmHost, clearAuthedImageCache, confirm, DatePicker, DateRangePicker, DateSeparator, DEFAULT_CALLING_CODES, DecimalInput, Descriptions, Dialog, Divider, Drawer, defineStatusMap, EmptyState, ErrorBoundary, FilePicker, FileViewer, FilterChipRow, FloatingActionButton, FloatingActionButtonGroup, ForceUpdateDialog, FormField, formatE164, formatFileSize, getAuthedImageCacheLimit, IconBadge, IconButton, ImageGallery, InlineSelect, Input, KeyboardAwareScrollView, KeyboardToolbar, ListItem, ListSection, LoaderOverlay, loader, Markdown, Menu, MessageBubble, MessageList, MODAL_DISMISS_GRACE_MS, Modal, NonModalBottomSheet, NumberInput, OnboardingPager, OptionSheet, OTPInput, OTPResendRow, PagedListFooter, PermissionPrompt, PhoneNumberInput, PickerTrigger, ProfileCompletion, ProfilePicker, ProgressBar, ProgressRing, Radio, RadioDot, RadioGroup, Rating, Repeater, RichTextEditor, Row, ScannerOverlay, Screen, SearchBar, SectionHeader, SegmentedControl, Select, SignaturePad, Skeleton, SkeletonCircle, SkeletonClockProvider, SkeletonContent, SkeletonList, SkeletonProvider, SkeletonSkip, SkeletonText, Slider, SliderField, SlideToConfirm, SortableList, Spacer, Sparkline, Spinner, SquircleImage, SquircleView, Stack, StatTile, StatusBadge, Stepper, Swipeable, Switch, setAuthedImageCacheLimit, Tabs, TagInput, Text, TextInkContext, Timeline, TimePicker, Toast, ToastHost, ToastProvider, Tooltip, Tour, TypingIndicator, toast, useBottomSheet, useErrorHandler, useRecentSearches, useTextInk, useToast, WheelPicker, withErrorBoundary, ZoomableImage, } from "./components";
|
|
4
4
|
export type { AppIconColor, AppIconName, AppIconProps, AppIconSize, CuratedIconName, IconName, IconsaxShadowedName, IconVariant, SlotIcon, SlotIconRef, SlotIconState, SlotNode, } from "./components/AppIcon";
|
|
5
5
|
export { AppIcon } from "./components/AppIcon";
|
|
6
6
|
export type { FormCompletion, HookFieldProps, HookFormFieldProps, UseFormCompletionOptions } from "./form";
|
|
@@ -12,7 +12,7 @@ export interface AsyncBlockLabels {
|
|
|
12
12
|
}
|
|
13
13
|
export declare const DEFAULT_ASYNC_BLOCK_LABELS: Readonly<AsyncBlockLabels>;
|
|
14
14
|
export interface AsyncBlockProps<T> {
|
|
15
|
-
/** The request's data state: one of the
|
|
15
|
+
/** The request's data state: one of the five members of DataState; idle (a skipped query) draws nothing. */
|
|
16
16
|
state: DataState<T>;
|
|
17
17
|
/** Called only in the "data" state, with the loaded data. */
|
|
18
18
|
children: (data: T) => React.ReactNode;
|
|
@@ -46,6 +46,6 @@ export interface AsyncBlockProps<T> {
|
|
|
46
46
|
* flex layout (a list inside lost its `flex: 1`), so only the placeholder
|
|
47
47
|
* states carry `style` and `testID`.
|
|
48
48
|
*/
|
|
49
|
-
export declare function AsyncBlock<T>({ state, children, empty, errorVariant, skeleton, errorTitle, offlineTitle, labels: labelOverrides, style, testID, }: AsyncBlockProps<T>): React.ReactElement;
|
|
49
|
+
export declare function AsyncBlock<T>({ state, children, empty, errorVariant, skeleton, errorTitle, offlineTitle, labels: labelOverrides, style, testID, }: AsyncBlockProps<T>): React.ReactElement | null;
|
|
50
50
|
export default AsyncBlock;
|
|
51
51
|
//# sourceMappingURL=AsyncBlock.d.ts.map
|
|
@@ -27,10 +27,11 @@ export type AvatarShape = "circle" | "square" | "rounded";
|
|
|
27
27
|
/**
|
|
28
28
|
* Presence dots (`online`, `offline`, `busy`, `away`) and identity states
|
|
29
29
|
* (`verified`: green ring with a check seal at the status corner, `pending`:
|
|
30
|
-
* amber ring, no seal
|
|
31
|
-
* the picture, so switching between them
|
|
30
|
+
* amber ring, no seal, `rejected`: red ring with a cross seal). The ring states
|
|
31
|
+
* keep the avatar's footprint and inset the picture, so switching between them
|
|
32
|
+
* never reflows a layout.
|
|
32
33
|
*/
|
|
33
|
-
export type AvatarStatus = "online" | "offline" | "busy" | "away" | "verified" | "pending" | null;
|
|
34
|
+
export type AvatarStatus = "online" | "offline" | "busy" | "away" | "verified" | "pending" | "rejected" | null;
|
|
34
35
|
export type AvatarStatusPosition = "topRight" | "bottomRight";
|
|
35
36
|
/**
|
|
36
37
|
* Theme colour of the initials disc: a soft tint of the tone behind initials
|
|
@@ -51,6 +52,7 @@ export interface AvatarLabels {
|
|
|
51
52
|
avatarOf: (name: string) => string;
|
|
52
53
|
verified: string;
|
|
53
54
|
pendingVerification: string;
|
|
55
|
+
rejected: string;
|
|
54
56
|
groupOf: (count: number) => string;
|
|
55
57
|
moreCount: (count: number) => string;
|
|
56
58
|
moreAvatars: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type ForwardRefExoticComponent, type RefAttributes } from "react";
|
|
2
|
-
import type { HostInstance, PressableProps, StyleProp, TextStyle, ViewStyle } from "react-native";
|
|
2
|
+
import type { GestureResponderEvent, HostInstance, PressableProps, StyleProp, TextStyle, ViewStyle } from "react-native";
|
|
3
3
|
import type { PressAnimationPreset } from "../../hooks/usePressAnimation.js";
|
|
4
4
|
import type { GradientDefinition, Theme } from "../../theme/types.js";
|
|
5
5
|
import type { FillVariant, Size, Tone } from "../../types/vocabulary.js";
|
|
@@ -25,9 +25,14 @@ export interface ButtonLabels {
|
|
|
25
25
|
loading: string;
|
|
26
26
|
}
|
|
27
27
|
export declare const DEFAULT_BUTTON_LABELS: Readonly<ButtonLabels>;
|
|
28
|
-
export interface ButtonProps extends Omit<PressableProps, "style" | "children"> {
|
|
28
|
+
export interface ButtonProps extends Omit<PressableProps, "style" | "children" | "onPress"> {
|
|
29
29
|
/** The label, and the button's accessible name unless `accessibilityLabel` is set. */
|
|
30
30
|
label: string;
|
|
31
|
+
/**
|
|
32
|
+
* Runs on press. When it returns a promise, the button is busy until the promise settles: a press in
|
|
33
|
+
* that time is dropped, and a rejection clears the busy state and is then rethrown.
|
|
34
|
+
*/
|
|
35
|
+
onPress?: ((event: GestureResponderEvent) => unknown) | null | undefined;
|
|
31
36
|
variant?: ButtonVariant | undefined;
|
|
32
37
|
tone?: ButtonTone | undefined;
|
|
33
38
|
size?: ButtonSize | undefined;
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* NonModalBottomSheet: a bottom sheet with snap points and no scrim. It is drawn
|
|
3
|
+
* inside its parent, which must be positioned and sized, so the screen behind it
|
|
4
|
+
* stays live. Render it after the screen content: it is read after the content.
|
|
5
|
+
*
|
|
6
|
+
* USAGE:
|
|
7
|
+
*
|
|
8
|
+
* const [open, setOpen] = useState(false);
|
|
9
|
+
* <View style={{ flex: 1 }}>
|
|
10
|
+
* <YourScreen />
|
|
11
|
+
* <NonModalBottomSheet open={open} onClose={() => setOpen(false)} snapPoints={["25%", "50%"]}>
|
|
12
|
+
* <YourContent />
|
|
13
|
+
* </NonModalBottomSheet>
|
|
14
|
+
* </View>
|
|
15
|
+
*/
|
|
16
|
+
import type React from "react";
|
|
17
|
+
import type { StyleProp, ViewStyle } from "react-native";
|
|
18
|
+
/** A snap point: a height in dp, or a percentage of the host height up to 100%. */
|
|
19
|
+
export type NonModalSnapPoint = number | `${number}%`;
|
|
20
|
+
export interface NonModalBottomSheetLabels {
|
|
21
|
+
dragHandle: string;
|
|
22
|
+
}
|
|
23
|
+
export declare const DEFAULT_NON_MODAL_BOTTOM_SHEET_LABELS: Readonly<NonModalBottomSheetLabels>;
|
|
24
|
+
export interface NonModalBottomSheetProps {
|
|
25
|
+
/** Opens and closes the sheet. A drag close calls `onClose`, and the parent sets `open` to false. */
|
|
26
|
+
open: boolean;
|
|
27
|
+
/** Called after the person drags the sheet closed. */
|
|
28
|
+
onClose: () => void;
|
|
29
|
+
/** The heights the sheet rests at, in any order (they are sorted ascending). */
|
|
30
|
+
snapPoints: NonModalSnapPoint[];
|
|
31
|
+
/** The snap point at rest (the smallest is 0). Changing it moves an open sheet. */
|
|
32
|
+
snapIndex?: number | undefined;
|
|
33
|
+
/** Fires for a drag or an accessibility move, never for a prop change. */
|
|
34
|
+
onSnapChange?: ((index: number) => void) | undefined;
|
|
35
|
+
/** Defaults to true. */
|
|
36
|
+
enablePanDownToClose?: boolean | undefined;
|
|
37
|
+
/** Wraps children in a ScrollView between the header and the footer. Defaults to false. */
|
|
38
|
+
scrollable?: boolean | undefined;
|
|
39
|
+
title?: string | undefined;
|
|
40
|
+
header?: React.ReactNode | undefined;
|
|
41
|
+
footer?: React.ReactNode | undefined;
|
|
42
|
+
labels?: Partial<NonModalBottomSheetLabels> | undefined;
|
|
43
|
+
handleIndicatorStyle?: StyleProp<ViewStyle> | undefined;
|
|
44
|
+
containerStyle?: StyleProp<ViewStyle> | undefined;
|
|
45
|
+
children?: React.ReactNode | undefined;
|
|
46
|
+
accessibilityLabel?: string | undefined;
|
|
47
|
+
testID?: string | undefined;
|
|
48
|
+
}
|
|
49
|
+
declare const NonModalBottomSheet: React.FC<NonModalBottomSheetProps>;
|
|
50
|
+
export { NonModalBottomSheet };
|
|
51
|
+
export default NonModalBottomSheet;
|
|
52
|
+
//# sourceMappingURL=NonModalBottomSheet.d.ts.map
|
|
@@ -8,7 +8,8 @@
|
|
|
8
8
|
* or tick icon / multi checkbox) and the multi-select Done footer. The Modal
|
|
9
9
|
* owns the open/close animations, the scrim and the dismissal; selection STATE
|
|
10
10
|
* stays with the caller; the sheet marks the rows of `value` and reports every
|
|
11
|
-
* tap on an enabled row through `onChange(value, option)
|
|
11
|
+
* tap on an enabled row through `onChange(value, option)`, except a row with
|
|
12
|
+
* its own action, which runs it and closes the sheet.
|
|
12
13
|
*
|
|
13
14
|
* Also the home of the canonical option types (`SelectValue`, `SelectOption`)
|
|
14
15
|
* and accessor signatures shared by every option-picking component. Select
|
|
@@ -24,6 +25,8 @@ export interface SelectOption {
|
|
|
24
25
|
description?: string | undefined;
|
|
25
26
|
disabled?: boolean | undefined;
|
|
26
27
|
icon?: React.ReactNode | undefined;
|
|
28
|
+
/** Runs when the row is tapped, then the sheet closes; `onChange` does not fire for this row. */
|
|
29
|
+
onPress?: (() => void) | undefined;
|
|
27
30
|
}
|
|
28
31
|
/** A titled group of options; the sheet lists groups in order under a header row each. */
|
|
29
32
|
export interface OptionSheetSection<T = SelectOption> {
|
|
@@ -105,6 +108,8 @@ export interface OptionSheetProps<T = SelectOption> {
|
|
|
105
108
|
* are untouched, so the caller passes a matching icon. Default: none.
|
|
106
109
|
*/
|
|
107
110
|
destructiveOf?: ((option: T) => boolean) | undefined;
|
|
111
|
+
/** The action a row runs on tap. Default: reads the option's `onPress`. A row with one runs it and closes the sheet; `onChange` does not fire for it. */
|
|
112
|
+
getOptionAction?: ((option: T) => (() => void) | undefined) | undefined;
|
|
108
113
|
/** The selected value, or the selected values in multi mode. Marks those rows. */
|
|
109
114
|
value?: SelectValue | ReadonlyArray<SelectValue> | undefined;
|
|
110
115
|
/** Tap on an enabled option, with its value and option. Caller updates state and (for single-select) closes. */
|