rechtspilot-ui 1.4.0 → 1.4.2

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.
@@ -1 +1 @@
1
- Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require(`./chunks-native.cjs`);let t=require(`react`);t=e.Y(t,1);let n=require(`react-native`),r=require(`react/jsx-runtime`),i=require(`react-native-safe-area-context`);var a=({size:i=20,color:a=e.q.primary[600],style:o})=>{let s=t.default.useRef(new n.Animated.Value(0)).current;t.default.useEffect(()=>{let e=()=>{s.setValue(0),n.Animated.timing(s,{toValue:1,duration:1e3,easing:n.Easing.linear,useNativeDriver:!0}).start(()=>e())};e()},[s]);let c=s.interpolate({inputRange:[0,1],outputRange:[`0deg`,`360deg`]});return(0,r.jsx)(n.View,{style:[{width:i,height:i},o],children:(0,r.jsx)(n.Animated.View,{style:{width:i,height:i,borderRadius:i/2,borderWidth:2,borderColor:`transparent`,borderTopColor:a,transform:[{rotate:c}]}})})},o=t=>{let n={alignItems:`center`,borderRadius:12,borderWidth:1,flexDirection:`row`,height:48,justifyContent:`center`,paddingHorizontal:16},r={fontFamily:e.J.body.fontFamily,fontSize:15,fontWeight:`500`,textAlign:`center`};switch(t){case`primary`:return{container:{...n,backgroundColor:e.q.primary[500],borderColor:e.q.neutral[`800-A16`]},text:{...r,color:e.q.primary[900]}};case`secondary`:return{container:{...n,backgroundColor:e.q.primary[900],borderColor:e.q.neutral[`800-A16`]},text:{...r,color:e.q.white}};case`tertiary`:return{container:{...n,backgroundColor:e.q.neutral[`800-A04`],borderColor:e.q.neutral[`800-A08`]},text:{...r,color:e.q.primary[900]}};case`destructive`:return{container:{...n,backgroundColor:e.q.fg.accent.error,borderColor:e.q.fg.accent.error},text:{...r,color:e.q.white}};case`destructiveSubtle`:return{container:{...n,backgroundColor:e.q.cream,borderColor:e.q.palePeach},text:{...r,color:e.q.fg.accent.error}}}};function s({variant:t=`primary`,fullWidth:i=!1,children:s,loading:c=!1,disabled:l=!1,onPress:u,...d}){let f=o(t);return(0,r.jsxs)(n.TouchableOpacity,{style:n.StyleSheet.flatten([f.container,i&&{width:`100%`},(l||c)&&{opacity:.4}]),onPress:u,disabled:l||c,activeOpacity:.7,...d,children:[typeof s==`string`?(0,r.jsx)(n.Text,{style:f.text,children:s}):s,c&&(0,r.jsx)(a,{size:16,color:t===`secondary`?e.q.primary[600]:t===`destructiveSubtle`?e.q.fg.accent.error:e.q.white})]})}var c={sm:32,md:40,lg:48},l={base:{backgroundColor:e.q.sf.base},primary:{backgroundColor:e.q.primary[`600-A08`]},outline:{borderWidth:1,borderColor:e.q.sf.base}},u={base:{backgroundColor:e.q.neutral[`800-A08`]},primary:{backgroundColor:e.q.primary[50]},outline:{backgroundColor:e.q.sf.tertiaryHover}};function d({children:e,size:t=`md`,variant:i=`base`,disabled:a=!1,hitSlop:o=10,...s}){let d=c[t],f={width:d,height:d,borderRadius:d/2,alignItems:`center`,justifyContent:`center`};return(0,r.jsx)(n.Pressable,{accessibilityRole:`button`,...s,style:({pressed:e})=>[f,l[i],e&&u[i],a&&{opacity:.4}],disabled:a,hitSlop:o,children:e})}var f=n.StyleSheet.create({container:{marginBottom:8},fieldContainer:{height:49,paddingHorizontal:12,borderRadius:12,flexDirection:`row`,alignItems:`center`,backgroundColor:e.q.bg.secondary,borderWidth:2,borderColor:e.q.bg.tertiary},fieldContainerError:{borderColor:e.q.fg.accent.error},fieldContainerFocused:{borderColor:e.q.fg.base},fieldContainerFocusedError:{borderColor:e.q.fg.accent.error},formGroup:{position:`relative`,paddingVertical:14,width:`100%`,height:`100%`,justifyContent:`center`},input:{width:`100%`,paddingTop:4,backgroundColor:`transparent`,fontFamily:e.J.body.fontFamily,fontSize:15,fontWeight:`500`,color:e.q.primary[900],paddingBottom:0},label:{position:`absolute`,left:0,fontFamily:e.J.body.fontFamily,fontSize:15,fontWeight:`500`,color:e.q.fg.tertiary},currencyPrefix:{fontFamily:e.J.body.fontFamily,fontSize:15,fontWeight:`400`,color:e.q.fg.secondary,marginRight:4,alignSelf:`center`},labelFloating:{top:2,fontSize:12,color:e.q.fg.secondary},labelNormal:{top:`50%`,transform:[{translateY:-7.5}]},helper:{marginTop:4,fontSize:12,paddingHorizontal:4},helperError:{color:e.q.fg.accent.error},helperNormal:{color:e.q.fg.secondary}});function p({label:i,value:a=``,onChange:o,error:s,helperText:c,placeholder:l,secureTextEntry:u=!1,keyboardType:d,autoCapitalize:p=`sentences`,editable:m=!0,multiline:h=!1,numberOfLines:g=1,currency:_=!1,...v}){let[y,b]=(0,t.useState)(!1),x=a.length>0,S=y||x||_,C=[f.fieldContainer,s&&f.fieldContainerError,y&&!s&&f.fieldContainerFocused,y&&s&&f.fieldContainerFocusedError],w=[f.label,S?f.labelFloating:f.labelNormal],T=n.StyleSheet.flatten([f.input,h&&{height:g*20,textAlignVertical:`top`}]);return(0,r.jsxs)(n.View,{style:f.container,children:[(0,r.jsxs)(n.View,{style:C,children:[_&&(0,r.jsx)(n.Text,{style:f.currencyPrefix,children:`€`}),(0,r.jsxs)(n.View,{style:f.formGroup,children:[(0,r.jsx)(n.TextInput,{style:T,value:a,onChangeText:o,onFocus:()=>b(!0),onBlur:()=>b(!1),placeholder:S?l:``,placeholderTextColor:e.q.fg.tertiary,secureTextEntry:u,keyboardType:d??(_?`numeric`:`default`),autoCapitalize:p,editable:m,multiline:h,numberOfLines:g,...v}),(0,r.jsx)(n.Text,{style:w,children:i})]})]}),(s||c)&&(0,r.jsx)(n.Text,{style:[f.helper,s?f.helperError:f.helperNormal],children:s||c})]})}function m({label:i,value:a,onChange:o,options:s,error:c,disabled:l=!1}){let[u,d]=(0,t.useState)(!1);(0,t.useEffect)(()=>{s.length===1&&!a&&o(s[0].value)},[s,a]);let f=s.find(e=>e.value===a),p=c?e.q.fg.accent.error:u?e.q.fg.base:e.q.bg.tertiary;return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)(n.View,{style:h.container,children:[(0,r.jsxs)(n.Pressable,{style:[h.trigger,{borderColor:p},l&&h.triggerDisabled],onPress:()=>d(!0),disabled:l,accessibilityRole:`combobox`,accessibilityLabel:i,accessibilityState:{expanded:u,disabled:l},children:[(0,r.jsxs)(n.View,{style:h.triggerContent,children:[(0,r.jsx)(n.Text,{style:[h.labelText,f&&h.labelFloating],children:i}),f&&(0,r.jsx)(n.Text,{style:h.valueText,numberOfLines:1,children:f.text})]}),(0,r.jsx)(e.K,{direction:`down`,color:e.q.fg.secondary,size:`small`})]}),c&&(0,r.jsx)(n.Text,{style:h.errorText,children:c})]}),(0,r.jsx)(n.Modal,{visible:u,transparent:!0,animationType:`fade`,onRequestClose:()=>d(!1),children:(0,r.jsx)(n.Pressable,{style:h.backdrop,onPress:()=>d(!1),children:(0,r.jsxs)(n.View,{style:h.sheet,children:[(0,r.jsx)(n.View,{style:h.sheetHandle}),(0,r.jsx)(n.ScrollView,{bounces:!1,children:s.map(e=>{let t=e.value===a;return(0,r.jsx)(n.Pressable,{style:[h.option,t&&h.optionActive],onPress:()=>{o(e.value),d(!1)},accessibilityRole:`menuitem`,accessibilityState:{selected:t},children:(0,r.jsx)(n.Text,{style:[h.optionText,t&&h.optionTextActive],children:e.text})},e.value)})})]})})})]})}var h=n.StyleSheet.create({container:{marginBottom:8},trigger:{height:50,paddingHorizontal:12,borderRadius:12,flexDirection:`row`,alignItems:`center`,backgroundColor:e.q.bg.secondary,borderWidth:2},triggerDisabled:{opacity:.4},triggerContent:{flex:1,justifyContent:`center`},labelText:{fontFamily:e.J.body.fontFamily,fontSize:15,color:e.q.fg.tertiary},labelFloating:{fontSize:12,color:e.q.fg.secondary,marginBottom:2},valueText:{fontFamily:e.J.body.fontFamily,fontSize:15,fontWeight:`500`,color:e.q.primary[900]},errorText:{marginTop:4,fontSize:12,paddingHorizontal:4,color:e.q.fg.accent.error,fontFamily:e.J.body.fontFamily},backdrop:{flex:1,backgroundColor:`rgba(0,0,0,0.4)`,justifyContent:`flex-end`},sheet:{backgroundColor:e.q.bg.base,borderTopLeftRadius:16,borderTopRightRadius:16,paddingBottom:32,maxHeight:`70%`},sheetHandle:{width:36,height:4,borderRadius:2,backgroundColor:e.q.border.default,alignSelf:`center`,marginTop:8,marginBottom:8},option:{paddingVertical:16,paddingHorizontal:20,borderBottomWidth:1,borderBottomColor:e.q.border.default},optionActive:{backgroundColor:e.q.primary[50]},optionText:{fontFamily:e.J.body.fontFamily,fontSize:15,color:e.q.fg.base},optionTextActive:{color:e.q.primary[900],fontWeight:`500`}}),g={heading:20,title:16,label:13,body:15,caption:12};function _({variant:t=`body`,color:i,style:a,...o}){return(0,r.jsx)(n.Text,{style:[e.J[t],{fontSize:g[t]},i?{color:i}:void 0,a],...o})}function v({open:t,onClose:a,onGoBack:o,title:s,children:c,footer:l}){let u=(0,i.useSafeAreaInsets)();return(0,r.jsx)(n.Modal,{visible:t,animationType:`slide`,presentationStyle:`pageSheet`,onRequestClose:a,children:(0,r.jsx)(n.KeyboardAvoidingView,{style:y.flex,behavior:n.Platform.OS===`ios`?`padding`:void 0,children:(0,r.jsxs)(n.View,{style:[y.container,{paddingTop:Math.max(u.top,16)}],children:[(0,r.jsxs)(n.View,{style:y.header,children:[(0,r.jsx)(n.View,{style:y.headerSide,children:o&&(0,r.jsx)(d,{variant:`base`,size:`md`,accessibilityLabel:`Go back`,onPress:o,children:(0,r.jsx)(e.K,{color:e.q.fg.secondary,direction:`left`})})}),s?(0,r.jsx)(_,{variant:`heading`,style:y.headerTitle,children:s}):(0,r.jsx)(n.View,{style:y.flex}),(0,r.jsx)(n.View,{style:[y.headerSide,y.headerSideRight],children:(0,r.jsx)(d,{variant:`base`,size:`md`,accessibilityLabel:`Close`,onPress:a,children:(0,r.jsx)(e.G,{color:e.q.fg.secondary,size:`small`})})})]}),(0,r.jsx)(n.ScrollView,{style:y.flex,contentContainerStyle:y.body,children:c}),l&&(0,r.jsx)(n.View,{style:y.footer,children:l})]})})})}var y=n.StyleSheet.create({flex:{flex:1},container:{flex:1,backgroundColor:e.q.bg.base},header:{flexDirection:`row`,alignItems:`center`,paddingHorizontal:8,paddingBottom:8,minHeight:52},headerSide:{flex:1},headerSideRight:{alignItems:`flex-end`},headerTitle:{flex:2,textAlign:`center`},body:{paddingHorizontal:20,paddingBottom:20},footer:{paddingHorizontal:20,paddingVertical:24,borderTopWidth:1,borderTopColor:e.q.border.default}}),b=()=>{let[e,n]=(0,t.useState)(window.innerWidth<=768),r=(0,t.useRef)(window.innerWidth);return(0,t.useEffect)(()=>{let e=()=>{let e=window.innerWidth;e<=768&&r.current>768?n(!0):e>768&&r.current<=768&&n(!1),r.current=e};return window.addEventListener(`resize`,e),()=>window.removeEventListener(`resize`,e)},[]),e},x=1,S=1e6,C=0;function w(){return C=(C+1)%(2**53-1),C.toString()}var T=new Map,E=e=>{if(T.has(e))return;let t=setTimeout(()=>{T.delete(e),A({type:`REMOVE_TOAST`,toastId:e})},S);T.set(e,t)},D=(e,t)=>{switch(t.type){case`ADD_TOAST`:return{...e,toasts:[t.toast,...e.toasts].slice(0,x)};case`UPDATE_TOAST`:return{...e,toasts:e.toasts.map(e=>e.id===t.toast.id?{...e,...t.toast}:e)};case`DISMISS_TOAST`:{let{toastId:n}=t;return n?E(n):e.toasts.forEach(e=>{E(e.id)}),{...e,toasts:e.toasts.map(e=>e.id===n||n===void 0?{...e,open:!1}:e)}}case`REMOVE_TOAST`:return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(e=>e.id!==t.toastId)}}},O=[],k={toasts:[]};function A(e){k=D(k,e),O.forEach(e=>{e(k)})}function j({...e}){let t=w(),n=e=>A({type:`UPDATE_TOAST`,toast:{...e,id:t}}),r=()=>A({type:`DISMISS_TOAST`,toastId:t});return A({type:`ADD_TOAST`,toast:{...e,id:t,open:!0,onOpenChange:e=>{e||r()}}}),{id:t,dismiss:r,update:n}}function M(){let[e,n]=t.useState(k);return t.useEffect(()=>(O.push(n),()=>{let e=O.indexOf(n);e>-1&&O.splice(e,1)}),[e]),{...e,toast:j,dismiss:e=>A({type:`DISMISS_TOAST`,toastId:e})}}exports.Button=s,exports.IconButton=d,exports.Input=p,exports.Select=m,exports.Sheet=v,exports.Spinner=a,exports.Text=_,exports.colors=e.q,Object.defineProperty(exports,`icons`,{enumerable:!0,get:function(){return e.t}}),exports.typography=e.J,exports.useIsMobile=b,exports.useToast=M;
1
+ Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require(`./chunks-native.cjs`);let t=require(`react`);t=e.Y(t,1);let n=require(`react-native`),r=require(`react-native-svg`),i=require(`react/jsx-runtime`),a=require(`react-native-safe-area-context`);function o({size:a=24,color:o=e.q.fg.primary,trackColor:s=e.q.neutral[`800-A08`],style:c}){let l=(0,t.useRef)(new n.Animated.Value(0)).current;(0,t.useEffect)(()=>{let e=n.Animated.loop(n.Animated.timing(l,{toValue:1,duration:1e3,easing:n.Easing.linear,useNativeDriver:!0}));return e.start(),()=>e.stop()},[l]);let u=l.interpolate({inputRange:[0,1],outputRange:[`0deg`,`360deg`]});return(0,i.jsx)(n.Animated.View,{style:[{width:a,height:a,transform:[{rotate:u}]},c],children:(0,i.jsxs)(r.Svg,{width:a,height:a,viewBox:`0 0 24 24`,fill:`none`,children:[(0,i.jsx)(r.Circle,{cx:`12`,cy:`12`,r:`8`,stroke:s,strokeWidth:3,fill:`none`}),(0,i.jsx)(r.Path,{d:`M12 4C16.4183 4 20 7.58172 20 12C20 14.1304 19.1672 16.0663 17.8095 17.5`,stroke:o,strokeWidth:3,strokeLinecap:`round`,fill:`none`})]})})}var s=t=>{let n={alignItems:`center`,borderRadius:12,borderWidth:1,flexDirection:`row`,height:48,justifyContent:`center`,paddingHorizontal:16},r={fontFamily:e.J.body.fontFamily,fontSize:15,fontWeight:`500`,textAlign:`center`};switch(t){case`primary`:return{container:{...n,backgroundColor:e.q.primary[500],borderColor:e.q.neutral[`800-A16`]},text:{...r,color:e.q.primary[900]}};case`secondary`:return{container:{...n,backgroundColor:e.q.primary[900],borderColor:e.q.neutral[`800-A16`]},text:{...r,color:e.q.white}};case`tertiary`:return{container:{...n,backgroundColor:e.q.neutral[`800-A04`],borderColor:e.q.neutral[`800-A08`]},text:{...r,color:e.q.primary[900]}};case`destructive`:return{container:{...n,backgroundColor:e.q.fg.accent.error,borderColor:e.q.fg.accent.error},text:{...r,color:e.q.white}};case`destructiveSubtle`:return{container:{...n,backgroundColor:e.q.cream,borderColor:e.q.palePeach},text:{...r,color:e.q.fg.accent.error}}}};function c({variant:t=`primary`,fullWidth:r=!1,children:a,loading:c=!1,disabled:l=!1,onPress:u,...d}){let f=s(t);return(0,i.jsxs)(n.TouchableOpacity,{style:n.StyleSheet.flatten([f.container,r&&{width:`100%`},(l||c)&&{opacity:.4}]),onPress:u,disabled:l||c,activeOpacity:.7,...d,children:[typeof a==`string`?(0,i.jsx)(n.Text,{style:f.text,children:a}):a,c&&(0,i.jsx)(o,{size:16,color:t===`secondary`?e.q.primary[600]:t===`destructiveSubtle`?e.q.fg.accent.error:e.q.white})]})}var l={sm:32,md:40,lg:48},u={base:{backgroundColor:e.q.sf.base},primary:{backgroundColor:e.q.primary[`600-A08`]},outline:{borderWidth:1,borderColor:e.q.sf.base}},d={base:{backgroundColor:e.q.neutral[`800-A08`]},primary:{backgroundColor:e.q.primary[50]},outline:{backgroundColor:e.q.sf.tertiaryHover}};function f({children:e,size:t=`md`,variant:r=`base`,disabled:a=!1,hitSlop:o=10,...s}){let c=l[t],f={width:c,height:c,borderRadius:c/2,alignItems:`center`,justifyContent:`center`};return(0,i.jsx)(n.Pressable,{accessibilityRole:`button`,...s,style:({pressed:e})=>[f,u[r],e&&d[r],a&&{opacity:.4}],disabled:a,hitSlop:o,children:e})}var p=n.StyleSheet.create({container:{marginBottom:8},fieldContainer:{height:49,paddingHorizontal:12,borderRadius:12,flexDirection:`row`,alignItems:`center`,backgroundColor:e.q.bg.secondary,borderWidth:2,borderColor:e.q.bg.tertiary},fieldContainerError:{borderColor:e.q.fg.accent.error},fieldContainerFocused:{borderColor:e.q.fg.base},fieldContainerFocusedError:{borderColor:e.q.fg.accent.error},formGroup:{position:`relative`,paddingVertical:14,width:`100%`,height:`100%`,justifyContent:`center`},input:{width:`100%`,paddingTop:4,backgroundColor:`transparent`,fontFamily:e.J.body.fontFamily,fontSize:15,fontWeight:`500`,color:e.q.primary[900],paddingBottom:0},label:{position:`absolute`,left:0,fontFamily:e.J.body.fontFamily,fontSize:15,fontWeight:`500`,color:e.q.fg.tertiary},currencyPrefix:{fontFamily:e.J.body.fontFamily,fontSize:15,fontWeight:`400`,color:e.q.fg.secondary,marginRight:4,alignSelf:`center`},labelFloating:{top:2,fontSize:12,color:e.q.fg.secondary},labelNormal:{top:`50%`,transform:[{translateY:-7.5}]},helper:{marginTop:4,fontSize:12,paddingHorizontal:4},helperError:{color:e.q.fg.accent.error},helperNormal:{color:e.q.fg.secondary}});function m({label:r,value:a=``,onChange:o,error:s,helperText:c,placeholder:l,secureTextEntry:u=!1,keyboardType:d,autoCapitalize:f=`sentences`,editable:m=!0,multiline:h=!1,numberOfLines:g=1,currency:_=!1,...v}){let[y,b]=(0,t.useState)(!1),x=a.length>0,S=y||x||_,C=[p.fieldContainer,s&&p.fieldContainerError,y&&!s&&p.fieldContainerFocused,y&&s&&p.fieldContainerFocusedError],w=[p.label,S?p.labelFloating:p.labelNormal],T=n.StyleSheet.flatten([p.input,h&&{height:g*20,textAlignVertical:`top`}]);return(0,i.jsxs)(n.View,{style:p.container,children:[(0,i.jsxs)(n.View,{style:C,children:[_&&(0,i.jsx)(n.Text,{style:p.currencyPrefix,children:`€`}),(0,i.jsxs)(n.View,{style:p.formGroup,children:[(0,i.jsx)(n.TextInput,{style:T,value:a,onChangeText:o,onFocus:()=>b(!0),onBlur:()=>b(!1),placeholder:S?l:``,placeholderTextColor:e.q.fg.tertiary,secureTextEntry:u,keyboardType:d??(_?`numeric`:`default`),autoCapitalize:f,editable:m,multiline:h,numberOfLines:g,...v}),(0,i.jsx)(n.Text,{style:w,children:r})]})]}),(s||c)&&(0,i.jsx)(n.Text,{style:[p.helper,s?p.helperError:p.helperNormal],children:s||c})]})}function h({label:r,value:a,onChange:o,options:s,error:c,disabled:l=!1}){let[u,d]=(0,t.useState)(!1);(0,t.useEffect)(()=>{s.length===1&&!a&&o(s[0].value)},[s,a]);let f=s.find(e=>e.value===a),p=c?e.q.fg.accent.error:u?e.q.fg.base:e.q.bg.tertiary;return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(n.View,{style:g.container,children:[(0,i.jsxs)(n.Pressable,{style:[g.trigger,{borderColor:p},l&&g.triggerDisabled],onPress:()=>d(!0),disabled:l,accessibilityRole:`combobox`,accessibilityLabel:r,accessibilityState:{expanded:u,disabled:l},children:[(0,i.jsxs)(n.View,{style:g.triggerContent,children:[(0,i.jsx)(n.Text,{style:[g.labelText,f&&g.labelFloating],children:r}),f&&(0,i.jsx)(n.Text,{style:g.valueText,numberOfLines:1,children:f.text})]}),(0,i.jsx)(e.K,{direction:`down`,color:e.q.fg.secondary,size:`small`})]}),c&&(0,i.jsx)(n.Text,{style:g.errorText,children:c})]}),(0,i.jsx)(n.Modal,{visible:u,transparent:!0,animationType:`fade`,onRequestClose:()=>d(!1),children:(0,i.jsx)(n.Pressable,{style:g.backdrop,onPress:()=>d(!1),children:(0,i.jsxs)(n.View,{style:g.sheet,children:[(0,i.jsx)(n.View,{style:g.sheetHandle}),(0,i.jsx)(n.ScrollView,{bounces:!1,children:s.map(e=>{let t=e.value===a;return(0,i.jsx)(n.Pressable,{style:[g.option,t&&g.optionActive],onPress:()=>{o(e.value),d(!1)},accessibilityRole:`menuitem`,accessibilityState:{selected:t},children:(0,i.jsx)(n.Text,{style:[g.optionText,t&&g.optionTextActive],children:e.text})},e.value)})})]})})})]})}var g=n.StyleSheet.create({container:{marginBottom:8},trigger:{height:50,paddingHorizontal:12,borderRadius:12,flexDirection:`row`,alignItems:`center`,backgroundColor:e.q.bg.secondary,borderWidth:2},triggerDisabled:{opacity:.4},triggerContent:{flex:1,justifyContent:`center`},labelText:{fontFamily:e.J.body.fontFamily,fontSize:15,color:e.q.fg.tertiary},labelFloating:{fontSize:12,color:e.q.fg.secondary,marginBottom:2},valueText:{fontFamily:e.J.body.fontFamily,fontSize:15,fontWeight:`500`,color:e.q.primary[900]},errorText:{marginTop:4,fontSize:12,paddingHorizontal:4,color:e.q.fg.accent.error,fontFamily:e.J.body.fontFamily},backdrop:{flex:1,backgroundColor:`rgba(0,0,0,0.4)`,justifyContent:`flex-end`},sheet:{backgroundColor:e.q.bg.base,borderTopLeftRadius:16,borderTopRightRadius:16,paddingBottom:32,maxHeight:`70%`},sheetHandle:{width:36,height:4,borderRadius:2,backgroundColor:e.q.border.default,alignSelf:`center`,marginTop:8,marginBottom:8},option:{paddingVertical:16,paddingHorizontal:20,borderBottomWidth:1,borderBottomColor:e.q.border.default},optionActive:{backgroundColor:e.q.primary[50]},optionText:{fontFamily:e.J.body.fontFamily,fontSize:15,color:e.q.fg.base},optionTextActive:{color:e.q.primary[900],fontWeight:`500`}}),_={heading:20,title:16,label:13,body:15,caption:12};function v({variant:t=`body`,color:r,style:a,...o}){return(0,i.jsx)(n.Text,{style:[e.J[t],{fontSize:_[t]},r?{color:r}:void 0,a],...o})}function y({open:t,onClose:r,onGoBack:o,title:s,children:c,footer:l}){let u=(0,a.useSafeAreaInsets)();return(0,i.jsx)(n.Modal,{visible:t,animationType:`slide`,presentationStyle:`pageSheet`,onRequestClose:r,children:(0,i.jsx)(n.KeyboardAvoidingView,{style:b.flex,behavior:n.Platform.OS===`ios`?`padding`:void 0,children:(0,i.jsxs)(n.View,{style:[b.container,{paddingTop:Math.max(u.top,16)}],children:[(0,i.jsxs)(n.View,{style:b.header,children:[(0,i.jsx)(n.View,{style:b.headerSide,children:o&&(0,i.jsx)(f,{variant:`base`,size:`md`,accessibilityLabel:`Go back`,onPress:o,children:(0,i.jsx)(e.K,{color:e.q.fg.secondary,direction:`left`})})}),s?(0,i.jsx)(v,{variant:`heading`,style:b.headerTitle,children:s}):(0,i.jsx)(n.View,{style:b.flex}),(0,i.jsx)(n.View,{style:[b.headerSide,b.headerSideRight],children:(0,i.jsx)(f,{variant:`base`,size:`md`,accessibilityLabel:`Close`,onPress:r,children:(0,i.jsx)(e.G,{color:e.q.fg.secondary,size:`small`})})})]}),(0,i.jsx)(n.ScrollView,{style:b.flex,contentContainerStyle:b.body,children:c}),l&&(0,i.jsx)(n.View,{style:b.footer,children:l})]})})})}var b=n.StyleSheet.create({flex:{flex:1},container:{flex:1,backgroundColor:e.q.bg.base},header:{flexDirection:`row`,alignItems:`center`,paddingHorizontal:8,paddingBottom:8,minHeight:52},headerSide:{flex:1},headerSideRight:{alignItems:`flex-end`},headerTitle:{flex:2,textAlign:`center`},body:{paddingHorizontal:20,paddingBottom:20},footer:{paddingHorizontal:20,paddingVertical:24,borderTopWidth:1,borderTopColor:e.q.border.default}}),x=()=>{let[e,n]=(0,t.useState)(window.innerWidth<=768),r=(0,t.useRef)(window.innerWidth);return(0,t.useEffect)(()=>{let e=()=>{let e=window.innerWidth;e<=768&&r.current>768?n(!0):e>768&&r.current<=768&&n(!1),r.current=e};return window.addEventListener(`resize`,e),()=>window.removeEventListener(`resize`,e)},[]),e},S=1,C=1e6,w=0;function T(){return w=(w+1)%(2**53-1),w.toString()}var E=new Map,D=e=>{if(E.has(e))return;let t=setTimeout(()=>{E.delete(e),j({type:`REMOVE_TOAST`,toastId:e})},C);E.set(e,t)},O=(e,t)=>{switch(t.type){case`ADD_TOAST`:return{...e,toasts:[t.toast,...e.toasts].slice(0,S)};case`UPDATE_TOAST`:return{...e,toasts:e.toasts.map(e=>e.id===t.toast.id?{...e,...t.toast}:e)};case`DISMISS_TOAST`:{let{toastId:n}=t;return n?D(n):e.toasts.forEach(e=>{D(e.id)}),{...e,toasts:e.toasts.map(e=>e.id===n||n===void 0?{...e,open:!1}:e)}}case`REMOVE_TOAST`:return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(e=>e.id!==t.toastId)}}},k=[],A={toasts:[]};function j(e){A=O(A,e),k.forEach(e=>{e(A)})}function M({...e}){let t=T(),n=e=>j({type:`UPDATE_TOAST`,toast:{...e,id:t}}),r=()=>j({type:`DISMISS_TOAST`,toastId:t});return j({type:`ADD_TOAST`,toast:{...e,id:t,open:!0,onOpenChange:e=>{e||r()}}}),{id:t,dismiss:r,update:n}}function N(){let[e,n]=t.useState(A);return t.useEffect(()=>(k.push(n),()=>{let e=k.indexOf(n);e>-1&&k.splice(e,1)}),[e]),{...e,toast:M,dismiss:e=>j({type:`DISMISS_TOAST`,toastId:e})}}exports.Button=c,exports.IconButton=f,exports.Input=m,exports.Select=h,exports.Sheet=y,exports.Spinner=o,exports.Text=v,exports.colors=e.q,Object.defineProperty(exports,`icons`,{enumerable:!0,get:function(){return e.t}}),exports.typography=e.J,exports.useIsMobile=x,exports.useToast=N;
@@ -1,43 +1,57 @@
1
1
  import { G as e, J as t, K as n, q as r, t as i } from "./chunks-native.js";
2
2
  import * as a from "react";
3
- import o, { useEffect as s, useRef as c, useState as l } from "react";
4
- import { Animated as u, Easing as d, KeyboardAvoidingView as f, Modal as p, Platform as m, Pressable as h, ScrollView as g, StyleSheet as _, Text as v, TextInput as y, TouchableOpacity as b, View as x } from "react-native";
5
- import { Fragment as S, jsx as C, jsxs as w } from "react/jsx-runtime";
6
- import { useSafeAreaInsets as T } from "react-native-safe-area-context";
3
+ import { useEffect as o, useRef as s, useState as c } from "react";
4
+ import { Animated as l, Easing as u, KeyboardAvoidingView as d, Modal as f, Platform as p, Pressable as m, ScrollView as h, StyleSheet as g, Text as _, TextInput as v, TouchableOpacity as y, View as b } from "react-native";
5
+ import { Circle as x, Path as S, Svg as C } from "react-native-svg";
6
+ import { Fragment as w, jsx as T, jsxs as E } from "react/jsx-runtime";
7
+ import { useSafeAreaInsets as D } from "react-native-safe-area-context";
7
8
  //#region src/components/Spinner/Spinner.native.tsx
8
- var E = ({ size: e = 20, color: t = r.primary[600], style: n }) => {
9
- let i = o.useRef(new u.Value(0)).current;
10
- o.useEffect(() => {
11
- let e = () => {
12
- i.setValue(0), u.timing(i, {
13
- toValue: 1,
14
- duration: 1e3,
15
- easing: d.linear,
16
- useNativeDriver: !0
17
- }).start(() => e());
18
- };
19
- e();
20
- }, [i]);
21
- let a = i.interpolate({
9
+ function O({ size: e = 24, color: t = r.fg.primary, trackColor: n = r.neutral["800-A08"], style: i }) {
10
+ let a = s(new l.Value(0)).current;
11
+ o(() => {
12
+ let e = l.loop(l.timing(a, {
13
+ toValue: 1,
14
+ duration: 1e3,
15
+ easing: u.linear,
16
+ useNativeDriver: !0
17
+ }));
18
+ return e.start(), () => e.stop();
19
+ }, [a]);
20
+ let c = a.interpolate({
22
21
  inputRange: [0, 1],
23
22
  outputRange: ["0deg", "360deg"]
24
23
  });
25
- return /* @__PURE__ */ C(x, {
24
+ return /* @__PURE__ */ T(l.View, {
26
25
  style: [{
27
26
  width: e,
28
- height: e
29
- }, n],
30
- children: /* @__PURE__ */ C(u.View, { style: {
27
+ height: e,
28
+ transform: [{ rotate: c }]
29
+ }, i],
30
+ children: /* @__PURE__ */ E(C, {
31
31
  width: e,
32
32
  height: e,
33
- borderRadius: e / 2,
34
- borderWidth: 2,
35
- borderColor: "transparent",
36
- borderTopColor: t,
37
- transform: [{ rotate: a }]
38
- } })
33
+ viewBox: "0 0 24 24",
34
+ fill: "none",
35
+ children: [/* @__PURE__ */ T(x, {
36
+ cx: "12",
37
+ cy: "12",
38
+ r: "8",
39
+ stroke: n,
40
+ strokeWidth: 3,
41
+ fill: "none"
42
+ }), /* @__PURE__ */ T(S, {
43
+ d: "M12 4C16.4183 4 20 7.58172 20 12C20 14.1304 19.1672 16.0663 17.8095 17.5",
44
+ stroke: t,
45
+ strokeWidth: 3,
46
+ strokeLinecap: "round",
47
+ fill: "none"
48
+ })]
49
+ })
39
50
  });
40
- }, D = (e) => {
51
+ }
52
+ //#endregion
53
+ //#region src/components/Button/Button.native.tsx
54
+ var k = (e) => {
41
55
  let n = {
42
56
  alignItems: "center",
43
57
  borderRadius: 12,
@@ -110,10 +124,10 @@ var E = ({ size: e = 20, color: t = r.primary[600], style: n }) => {
110
124
  };
111
125
  }
112
126
  };
113
- function O({ variant: e = "primary", fullWidth: t = !1, children: n, loading: i = !1, disabled: a = !1, onPress: o, ...s }) {
114
- let c = D(e);
115
- return /* @__PURE__ */ w(b, {
116
- style: _.flatten([
127
+ function A({ variant: e = "primary", fullWidth: t = !1, children: n, loading: i = !1, disabled: a = !1, onPress: o, ...s }) {
128
+ let c = k(e);
129
+ return /* @__PURE__ */ E(y, {
130
+ style: g.flatten([
117
131
  c.container,
118
132
  t && { width: "100%" },
119
133
  (a || i) && { opacity: .4 }
@@ -122,10 +136,10 @@ function O({ variant: e = "primary", fullWidth: t = !1, children: n, loading: i
122
136
  disabled: a || i,
123
137
  activeOpacity: .7,
124
138
  ...s,
125
- children: [typeof n == "string" ? /* @__PURE__ */ C(v, {
139
+ children: [typeof n == "string" ? /* @__PURE__ */ T(_, {
126
140
  style: c.text,
127
141
  children: n
128
- }) : n, i && /* @__PURE__ */ C(E, {
142
+ }) : n, i && /* @__PURE__ */ T(O, {
129
143
  size: 16,
130
144
  color: e === "secondary" ? r.primary[600] : e === "destructiveSubtle" ? r.fg.accent.error : r.white
131
145
  })]
@@ -133,37 +147,37 @@ function O({ variant: e = "primary", fullWidth: t = !1, children: n, loading: i
133
147
  }
134
148
  //#endregion
135
149
  //#region src/components/IconButton/IconButton.native.tsx
136
- var k = {
150
+ var j = {
137
151
  sm: 32,
138
152
  md: 40,
139
153
  lg: 48
140
- }, A = {
154
+ }, M = {
141
155
  base: { backgroundColor: r.sf.base },
142
156
  primary: { backgroundColor: r.primary["600-A08"] },
143
157
  outline: {
144
158
  borderWidth: 1,
145
159
  borderColor: r.sf.base
146
160
  }
147
- }, j = {
161
+ }, N = {
148
162
  base: { backgroundColor: r.neutral["800-A08"] },
149
163
  primary: { backgroundColor: r.primary[50] },
150
164
  outline: { backgroundColor: r.sf.tertiaryHover }
151
165
  };
152
- function M({ children: e, size: t = "md", variant: n = "base", disabled: r = !1, hitSlop: i = 10, ...a }) {
153
- let o = k[t], s = {
166
+ function P({ children: e, size: t = "md", variant: n = "base", disabled: r = !1, hitSlop: i = 10, ...a }) {
167
+ let o = j[t], s = {
154
168
  width: o,
155
169
  height: o,
156
170
  borderRadius: o / 2,
157
171
  alignItems: "center",
158
172
  justifyContent: "center"
159
173
  };
160
- return /* @__PURE__ */ C(h, {
174
+ return /* @__PURE__ */ T(m, {
161
175
  accessibilityRole: "button",
162
176
  ...a,
163
177
  style: ({ pressed: e }) => [
164
178
  s,
165
- A[n],
166
- e && j[n],
179
+ M[n],
180
+ e && N[n],
167
181
  r && { opacity: .4 }
168
182
  ],
169
183
  disabled: r,
@@ -173,7 +187,7 @@ function M({ children: e, size: t = "md", variant: n = "base", disabled: r = !1,
173
187
  }
174
188
  //#endregion
175
189
  //#region src/components/Input/Input.native.tsx
176
- var N = _.create({
190
+ var F = g.create({
177
191
  container: { marginBottom: 8 },
178
192
  fieldContainer: {
179
193
  height: 49,
@@ -238,117 +252,117 @@ var N = _.create({
238
252
  helperError: { color: r.fg.accent.error },
239
253
  helperNormal: { color: r.fg.secondary }
240
254
  });
241
- function P({ label: e, value: t = "", onChange: n, error: i, helperText: a, placeholder: o, secureTextEntry: s = !1, keyboardType: c, autoCapitalize: u = "sentences", editable: d = !0, multiline: f = !1, numberOfLines: p = 1, currency: m = !1, ...h }) {
242
- let [g, b] = l(!1), S = t.length > 0, T = g || S || m, E = [
243
- N.fieldContainer,
244
- i && N.fieldContainerError,
245
- g && !i && N.fieldContainerFocused,
246
- g && i && N.fieldContainerFocusedError
247
- ], D = [N.label, T ? N.labelFloating : N.labelNormal], O = _.flatten([N.input, f && {
255
+ function I({ label: e, value: t = "", onChange: n, error: i, helperText: a, placeholder: o, secureTextEntry: s = !1, keyboardType: l, autoCapitalize: u = "sentences", editable: d = !0, multiline: f = !1, numberOfLines: p = 1, currency: m = !1, ...h }) {
256
+ let [y, x] = c(!1), S = t.length > 0, C = y || S || m, w = [
257
+ F.fieldContainer,
258
+ i && F.fieldContainerError,
259
+ y && !i && F.fieldContainerFocused,
260
+ y && i && F.fieldContainerFocusedError
261
+ ], D = [F.label, C ? F.labelFloating : F.labelNormal], O = g.flatten([F.input, f && {
248
262
  height: p * 20,
249
263
  textAlignVertical: "top"
250
264
  }]);
251
- return /* @__PURE__ */ w(x, {
252
- style: N.container,
253
- children: [/* @__PURE__ */ w(x, {
254
- style: E,
255
- children: [m && /* @__PURE__ */ C(v, {
256
- style: N.currencyPrefix,
265
+ return /* @__PURE__ */ E(b, {
266
+ style: F.container,
267
+ children: [/* @__PURE__ */ E(b, {
268
+ style: w,
269
+ children: [m && /* @__PURE__ */ T(_, {
270
+ style: F.currencyPrefix,
257
271
  children: "€"
258
- }), /* @__PURE__ */ w(x, {
259
- style: N.formGroup,
260
- children: [/* @__PURE__ */ C(y, {
272
+ }), /* @__PURE__ */ E(b, {
273
+ style: F.formGroup,
274
+ children: [/* @__PURE__ */ T(v, {
261
275
  style: O,
262
276
  value: t,
263
277
  onChangeText: n,
264
- onFocus: () => b(!0),
265
- onBlur: () => b(!1),
266
- placeholder: T ? o : "",
278
+ onFocus: () => x(!0),
279
+ onBlur: () => x(!1),
280
+ placeholder: C ? o : "",
267
281
  placeholderTextColor: r.fg.tertiary,
268
282
  secureTextEntry: s,
269
- keyboardType: c ?? (m ? "numeric" : "default"),
283
+ keyboardType: l ?? (m ? "numeric" : "default"),
270
284
  autoCapitalize: u,
271
285
  editable: d,
272
286
  multiline: f,
273
287
  numberOfLines: p,
274
288
  ...h
275
- }), /* @__PURE__ */ C(v, {
289
+ }), /* @__PURE__ */ T(_, {
276
290
  style: D,
277
291
  children: e
278
292
  })]
279
293
  })]
280
- }), (i || a) && /* @__PURE__ */ C(v, {
281
- style: [N.helper, i ? N.helperError : N.helperNormal],
294
+ }), (i || a) && /* @__PURE__ */ T(_, {
295
+ style: [F.helper, i ? F.helperError : F.helperNormal],
282
296
  children: i || a
283
297
  })]
284
298
  });
285
299
  }
286
300
  //#endregion
287
301
  //#region src/components/Select/Select.native.tsx
288
- function F({ label: e, value: t, onChange: i, options: a, error: o, disabled: c = !1 }) {
289
- let [u, d] = l(!1);
290
- s(() => {
302
+ function L({ label: e, value: t, onChange: i, options: a, error: s, disabled: l = !1 }) {
303
+ let [u, d] = c(!1);
304
+ o(() => {
291
305
  a.length === 1 && !t && i(a[0].value);
292
306
  }, [a, t]);
293
- let f = a.find((e) => e.value === t), m = o ? r.fg.accent.error : u ? r.fg.base : r.bg.tertiary;
294
- return /* @__PURE__ */ w(S, { children: [/* @__PURE__ */ w(x, {
295
- style: I.container,
296
- children: [/* @__PURE__ */ w(h, {
307
+ let p = a.find((e) => e.value === t), g = s ? r.fg.accent.error : u ? r.fg.base : r.bg.tertiary;
308
+ return /* @__PURE__ */ E(w, { children: [/* @__PURE__ */ E(b, {
309
+ style: R.container,
310
+ children: [/* @__PURE__ */ E(m, {
297
311
  style: [
298
- I.trigger,
299
- { borderColor: m },
300
- c && I.triggerDisabled
312
+ R.trigger,
313
+ { borderColor: g },
314
+ l && R.triggerDisabled
301
315
  ],
302
316
  onPress: () => d(!0),
303
- disabled: c,
317
+ disabled: l,
304
318
  accessibilityRole: "combobox",
305
319
  accessibilityLabel: e,
306
320
  accessibilityState: {
307
321
  expanded: u,
308
- disabled: c
322
+ disabled: l
309
323
  },
310
- children: [/* @__PURE__ */ w(x, {
311
- style: I.triggerContent,
312
- children: [/* @__PURE__ */ C(v, {
313
- style: [I.labelText, f && I.labelFloating],
324
+ children: [/* @__PURE__ */ E(b, {
325
+ style: R.triggerContent,
326
+ children: [/* @__PURE__ */ T(_, {
327
+ style: [R.labelText, p && R.labelFloating],
314
328
  children: e
315
- }), f && /* @__PURE__ */ C(v, {
316
- style: I.valueText,
329
+ }), p && /* @__PURE__ */ T(_, {
330
+ style: R.valueText,
317
331
  numberOfLines: 1,
318
- children: f.text
332
+ children: p.text
319
333
  })]
320
- }), /* @__PURE__ */ C(n, {
334
+ }), /* @__PURE__ */ T(n, {
321
335
  direction: "down",
322
336
  color: r.fg.secondary,
323
337
  size: "small"
324
338
  })]
325
- }), o && /* @__PURE__ */ C(v, {
326
- style: I.errorText,
327
- children: o
339
+ }), s && /* @__PURE__ */ T(_, {
340
+ style: R.errorText,
341
+ children: s
328
342
  })]
329
- }), /* @__PURE__ */ C(p, {
343
+ }), /* @__PURE__ */ T(f, {
330
344
  visible: u,
331
345
  transparent: !0,
332
346
  animationType: "fade",
333
347
  onRequestClose: () => d(!1),
334
- children: /* @__PURE__ */ C(h, {
335
- style: I.backdrop,
348
+ children: /* @__PURE__ */ T(m, {
349
+ style: R.backdrop,
336
350
  onPress: () => d(!1),
337
- children: /* @__PURE__ */ w(x, {
338
- style: I.sheet,
339
- children: [/* @__PURE__ */ C(x, { style: I.sheetHandle }), /* @__PURE__ */ C(g, {
351
+ children: /* @__PURE__ */ E(b, {
352
+ style: R.sheet,
353
+ children: [/* @__PURE__ */ T(b, { style: R.sheetHandle }), /* @__PURE__ */ T(h, {
340
354
  bounces: !1,
341
355
  children: a.map((e) => {
342
356
  let n = e.value === t;
343
- return /* @__PURE__ */ C(h, {
344
- style: [I.option, n && I.optionActive],
357
+ return /* @__PURE__ */ T(m, {
358
+ style: [R.option, n && R.optionActive],
345
359
  onPress: () => {
346
360
  i(e.value), d(!1);
347
361
  },
348
362
  accessibilityRole: "menuitem",
349
363
  accessibilityState: { selected: n },
350
- children: /* @__PURE__ */ C(v, {
351
- style: [I.optionText, n && I.optionTextActive],
364
+ children: /* @__PURE__ */ T(_, {
365
+ style: [R.optionText, n && R.optionTextActive],
352
366
  children: e.text
353
367
  })
354
368
  }, e.value);
@@ -358,7 +372,7 @@ function F({ label: e, value: t, onChange: i, options: a, error: o, disabled: c
358
372
  })
359
373
  })] });
360
374
  }
361
- var I = _.create({
375
+ var R = g.create({
362
376
  container: { marginBottom: 8 },
363
377
  trigger: {
364
378
  height: 50,
@@ -434,18 +448,18 @@ var I = _.create({
434
448
  color: r.primary[900],
435
449
  fontWeight: "500"
436
450
  }
437
- }), L = {
451
+ }), z = {
438
452
  heading: 20,
439
453
  title: 16,
440
454
  label: 13,
441
455
  body: 15,
442
456
  caption: 12
443
457
  };
444
- function R({ variant: e = "body", color: n, style: r, ...i }) {
445
- return /* @__PURE__ */ C(v, {
458
+ function B({ variant: e = "body", color: n, style: r, ...i }) {
459
+ return /* @__PURE__ */ T(_, {
446
460
  style: [
447
461
  t[e],
448
- { fontSize: L[e] },
462
+ { fontSize: z[e] },
449
463
  n ? { color: n } : void 0,
450
464
  r
451
465
  ],
@@ -454,48 +468,48 @@ function R({ variant: e = "body", color: n, style: r, ...i }) {
454
468
  }
455
469
  //#endregion
456
470
  //#region src/components/Sheet/Sheet.native.tsx
457
- function z({ open: t, onClose: i, onGoBack: a, title: o, children: s, footer: c }) {
458
- let l = T();
459
- return /* @__PURE__ */ C(p, {
471
+ function V({ open: t, onClose: i, onGoBack: a, title: o, children: s, footer: c }) {
472
+ let l = D();
473
+ return /* @__PURE__ */ T(f, {
460
474
  visible: t,
461
475
  animationType: "slide",
462
476
  presentationStyle: "pageSheet",
463
477
  onRequestClose: i,
464
- children: /* @__PURE__ */ C(f, {
465
- style: B.flex,
466
- behavior: m.OS === "ios" ? "padding" : void 0,
467
- children: /* @__PURE__ */ w(x, {
468
- style: [B.container, { paddingTop: Math.max(l.top, 16) }],
478
+ children: /* @__PURE__ */ T(d, {
479
+ style: H.flex,
480
+ behavior: p.OS === "ios" ? "padding" : void 0,
481
+ children: /* @__PURE__ */ E(b, {
482
+ style: [H.container, { paddingTop: Math.max(l.top, 16) }],
469
483
  children: [
470
- /* @__PURE__ */ w(x, {
471
- style: B.header,
484
+ /* @__PURE__ */ E(b, {
485
+ style: H.header,
472
486
  children: [
473
- /* @__PURE__ */ C(x, {
474
- style: B.headerSide,
475
- children: a && /* @__PURE__ */ C(M, {
487
+ /* @__PURE__ */ T(b, {
488
+ style: H.headerSide,
489
+ children: a && /* @__PURE__ */ T(P, {
476
490
  variant: "base",
477
491
  size: "md",
478
492
  accessibilityLabel: "Go back",
479
493
  onPress: a,
480
- children: /* @__PURE__ */ C(n, {
494
+ children: /* @__PURE__ */ T(n, {
481
495
  color: r.fg.secondary,
482
496
  direction: "left"
483
497
  })
484
498
  })
485
499
  }),
486
- o ? /* @__PURE__ */ C(R, {
500
+ o ? /* @__PURE__ */ T(B, {
487
501
  variant: "heading",
488
- style: B.headerTitle,
502
+ style: H.headerTitle,
489
503
  children: o
490
- }) : /* @__PURE__ */ C(x, { style: B.flex }),
491
- /* @__PURE__ */ C(x, {
492
- style: [B.headerSide, B.headerSideRight],
493
- children: /* @__PURE__ */ C(M, {
504
+ }) : /* @__PURE__ */ T(b, { style: H.flex }),
505
+ /* @__PURE__ */ T(b, {
506
+ style: [H.headerSide, H.headerSideRight],
507
+ children: /* @__PURE__ */ T(P, {
494
508
  variant: "base",
495
509
  size: "md",
496
510
  accessibilityLabel: "Close",
497
511
  onPress: i,
498
- children: /* @__PURE__ */ C(e, {
512
+ children: /* @__PURE__ */ T(e, {
499
513
  color: r.fg.secondary,
500
514
  size: "small"
501
515
  })
@@ -503,13 +517,13 @@ function z({ open: t, onClose: i, onGoBack: a, title: o, children: s, footer: c
503
517
  })
504
518
  ]
505
519
  }),
506
- /* @__PURE__ */ C(g, {
507
- style: B.flex,
508
- contentContainerStyle: B.body,
520
+ /* @__PURE__ */ T(h, {
521
+ style: H.flex,
522
+ contentContainerStyle: H.body,
509
523
  children: s
510
524
  }),
511
- c && /* @__PURE__ */ C(x, {
512
- style: B.footer,
525
+ c && /* @__PURE__ */ T(b, {
526
+ style: H.footer,
513
527
  children: c
514
528
  })
515
529
  ]
@@ -517,7 +531,7 @@ function z({ open: t, onClose: i, onGoBack: a, title: o, children: s, footer: c
517
531
  })
518
532
  });
519
533
  }
520
- var B = _.create({
534
+ var H = g.create({
521
535
  flex: { flex: 1 },
522
536
  container: {
523
537
  flex: 1,
@@ -546,33 +560,33 @@ var B = _.create({
546
560
  borderTopWidth: 1,
547
561
  borderTopColor: r.border.default
548
562
  }
549
- }), V = () => {
550
- let [e, t] = l(window.innerWidth <= 768), n = c(window.innerWidth);
551
- return s(() => {
563
+ }), U = () => {
564
+ let [e, t] = c(window.innerWidth <= 768), n = s(window.innerWidth);
565
+ return o(() => {
552
566
  let e = () => {
553
567
  let e = window.innerWidth;
554
568
  e <= 768 && n.current > 768 ? t(!0) : e > 768 && n.current <= 768 && t(!1), n.current = e;
555
569
  };
556
570
  return window.addEventListener("resize", e), () => window.removeEventListener("resize", e);
557
571
  }, []), e;
558
- }, H = 1, U = 1e6, W = 0;
559
- function G() {
560
- return W = (W + 1) % (2 ** 53 - 1), W.toString();
572
+ }, W = 1, G = 1e6, K = 0;
573
+ function q() {
574
+ return K = (K + 1) % (2 ** 53 - 1), K.toString();
561
575
  }
562
- var K = /* @__PURE__ */ new Map(), q = (e) => {
563
- if (K.has(e)) return;
576
+ var J = /* @__PURE__ */ new Map(), Y = (e) => {
577
+ if (J.has(e)) return;
564
578
  let t = setTimeout(() => {
565
- K.delete(e), Z({
579
+ J.delete(e), $({
566
580
  type: "REMOVE_TOAST",
567
581
  toastId: e
568
582
  });
569
- }, U);
570
- K.set(e, t);
571
- }, J = (e, t) => {
583
+ }, G);
584
+ J.set(e, t);
585
+ }, X = (e, t) => {
572
586
  switch (t.type) {
573
587
  case "ADD_TOAST": return {
574
588
  ...e,
575
- toasts: [t.toast, ...e.toasts].slice(0, H)
589
+ toasts: [t.toast, ...e.toasts].slice(0, W)
576
590
  };
577
591
  case "UPDATE_TOAST": return {
578
592
  ...e,
@@ -583,8 +597,8 @@ var K = /* @__PURE__ */ new Map(), q = (e) => {
583
597
  };
584
598
  case "DISMISS_TOAST": {
585
599
  let { toastId: n } = t;
586
- return n ? q(n) : e.toasts.forEach((e) => {
587
- q(e.id);
600
+ return n ? Y(n) : e.toasts.forEach((e) => {
601
+ Y(e.id);
588
602
  }), {
589
603
  ...e,
590
604
  toasts: e.toasts.map((e) => e.id === n || n === void 0 ? {
@@ -601,24 +615,24 @@ var K = /* @__PURE__ */ new Map(), q = (e) => {
601
615
  toasts: e.toasts.filter((e) => e.id !== t.toastId)
602
616
  };
603
617
  }
604
- }, Y = [], X = { toasts: [] };
605
- function Z(e) {
606
- X = J(X, e), Y.forEach((e) => {
607
- e(X);
618
+ }, Z = [], Q = { toasts: [] };
619
+ function $(e) {
620
+ Q = X(Q, e), Z.forEach((e) => {
621
+ e(Q);
608
622
  });
609
623
  }
610
- function Q({ ...e }) {
611
- let t = G(), n = (e) => Z({
624
+ function ee({ ...e }) {
625
+ let t = q(), n = (e) => $({
612
626
  type: "UPDATE_TOAST",
613
627
  toast: {
614
628
  ...e,
615
629
  id: t
616
630
  }
617
- }), r = () => Z({
631
+ }), r = () => $({
618
632
  type: "DISMISS_TOAST",
619
633
  toastId: t
620
634
  });
621
- return Z({
635
+ return $({
622
636
  type: "ADD_TOAST",
623
637
  toast: {
624
638
  ...e,
@@ -634,19 +648,19 @@ function Q({ ...e }) {
634
648
  update: n
635
649
  };
636
650
  }
637
- function $() {
638
- let [e, t] = a.useState(X);
639
- return a.useEffect(() => (Y.push(t), () => {
640
- let e = Y.indexOf(t);
641
- e > -1 && Y.splice(e, 1);
651
+ function te() {
652
+ let [e, t] = a.useState(Q);
653
+ return a.useEffect(() => (Z.push(t), () => {
654
+ let e = Z.indexOf(t);
655
+ e > -1 && Z.splice(e, 1);
642
656
  }), [e]), {
643
657
  ...e,
644
- toast: Q,
645
- dismiss: (e) => Z({
658
+ toast: ee,
659
+ dismiss: (e) => $({
646
660
  type: "DISMISS_TOAST",
647
661
  toastId: e
648
662
  })
649
663
  };
650
664
  }
651
665
  //#endregion
652
- export { O as Button, M as IconButton, P as Input, F as Select, z as Sheet, E as Spinner, R as Text, r as colors, i as icons, t as typography, V as useIsMobile, $ as useToast };
666
+ export { A as Button, P as IconButton, I as Input, L as Select, V as Sheet, O as Spinner, B as Text, r as colors, i as icons, t as typography, U as useIsMobile, te as useToast };
@@ -1,9 +1,9 @@
1
- import { default as React } from 'react';
2
- import { ViewStyle } from 'react-native';
3
- interface SpinnerProps {
1
+ import { StyleProp, ViewStyle } from 'react-native';
2
+ type SpinnerProps = {
4
3
  size?: number;
5
4
  color?: string;
6
- style?: ViewStyle;
7
- }
8
- declare const Spinner: React.FC<SpinnerProps>;
9
- export default Spinner;
5
+ trackColor?: string;
6
+ style?: StyleProp<ViewStyle>;
7
+ };
8
+ export default function Spinner({ size, color, trackColor, style, }: SpinnerProps): import("react/jsx-runtime").JSX.Element;
9
+ export {};