@alveole/components 0.16.3 → 0.16.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Button.d.ts","sourceRoot":"","sources":["../../../src/ui/Button/Button.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAwB,MAAM,OAAO,CAAC;AAC7C,OAAO,
|
|
1
|
+
{"version":3,"file":"Button.d.ts","sourceRoot":"","sources":["../../../src/ui/Button/Button.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAwB,MAAM,OAAO,CAAC;AAC7C,OAAO,EAA0C,cAAc,EAA8B,IAAI,EAAE,MAAM,cAAc,CAAC;AACxH,OAAO,EAAO,QAAQ,EAAc,MAAM,YAAY,CAAC;AACvD,OAAO,EAAE,SAAS,EAAc,MAAM,eAAe,CAAC;AAOtD,MAAM,MAAM,WAAW,GAAG,IAAI,CAAC,cAAc,EAAE,UAAU,GAAG,OAAO,CAAC,GAAG;IACrE,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;IACjC,OAAO,EAAE,SAAS,GAAG,WAAW,GAAG,UAAU,GAAG,MAAM,CAAC;IACvD,SAAS,CAAC,EAAE,SAAS,CAAC,MAAM,CAAC,CAAC;IAC9B,OAAO,CAAC,EAAE,SAAS,CAAC,MAAM,CAAC,CAAC;IAC5B,cAAc,CAAC,EAAE,QAAQ,CAAC;IAC1B,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,IAAI,CAAC,EAAE,QAAQ,GAAG,QAAQ,CAAC;IAC3B,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB,CAAC;AAEF,eAAO,MAAM,MAAM;WAdV,MAAM;WACN,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI;aACvB,SAAS,GAAG,WAAW,GAAG,UAAU,GAAG,MAAM;gBAC1C,SAAS,CAAC,MAAM,CAAC;cACnB,SAAS,CAAC,MAAM,CAAC;qBACV,QAAQ;gBACb,OAAO;gBACP,OAAO;iBACN,OAAO;gBACR,OAAO;WACZ,QAAQ,GAAG,QAAQ;gBACd,OAAO;8BA8KnB,CAAC"}
|
package/dist/ui/Button/Button.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { ActivityIndicator, Pressable } from 'react-native';
|
|
3
|
+
import { ActivityIndicator, Platform, Pressable } from 'react-native';
|
|
4
4
|
import { Box, Typography } from '../../core';
|
|
5
5
|
import { LucideIcon } from '../LucideIcon';
|
|
6
6
|
import { useStyles } from './Button.styles';
|
|
@@ -138,5 +138,16 @@ export const Button = React.forwardRef(function Button(props, ref) {
|
|
|
138
138
|
}
|
|
139
139
|
return { size: iconSize };
|
|
140
140
|
};
|
|
141
|
-
|
|
141
|
+
// Fix la bordure sur iOS pour le bouton secondaire
|
|
142
|
+
const pressableStyle = Platform.OS === 'ios' && variant === 'secondary'
|
|
143
|
+
? {
|
|
144
|
+
borderWidth: 1,
|
|
145
|
+
borderColor: styles.secondaryContainer.borderColor,
|
|
146
|
+
borderTopLeftRadius: styles.container.borderTopLeftRadius,
|
|
147
|
+
borderBottomLeftRadius: styles.container.borderBottomLeftRadius,
|
|
148
|
+
borderTopRightRadius: styles.container.borderTopRightRadius,
|
|
149
|
+
borderBottomRightRadius: styles.container.borderBottomRightRadius,
|
|
150
|
+
}
|
|
151
|
+
: {};
|
|
152
|
+
return (_jsx(Pressable, { ref: ref, disabled: disabled, accessibilityRole: "button", ...(type === 'submit' ? { 'aria-selected': true } : {}), ...(fullWidth ? { style: { width: '100%' } } : {}), ...buttonProps, style: [pressableStyle], children: (state) => (_jsxs(Box, { style: [buttonContainerStyle(), style], hoverStyle: { ...buttonContainerHoverStyle(), ...hoverStyle }, ...containerProps, children: [startIcon && _jsx(LucideIcon, { name: startIcon, ...iconStyle({ hovered: !!state.hovered }) }), _jsx(Typography, { "user-select": false, style: textStyle({ hovered: !!state.hovered }), children: title }), isLoading ? (_jsx(ActivityIndicator, { size: "small", style: styles.buttonLoader })) : (endIcon && _jsx(LucideIcon, { name: endIcon, ...iconStyle({ hovered: !!state.hovered }) }))] })) }));
|
|
142
153
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ToolbarBottomNav.d.ts","sourceRoot":"","sources":["../../../src/ui/ToolbarBottomNav/ToolbarBottomNav.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,IAAI,QAAQ,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"ToolbarBottomNav.d.ts","sourceRoot":"","sources":["../../../src/ui/ToolbarBottomNav/ToolbarBottomNav.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,IAAI,QAAQ,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,MAAM,MAAM,qBAAqB,GAAG,KAAK,CAAC,cAAc,CAAC,OAAO,QAAQ,CAAC,CAAC;AAC1E,eAAO,MAAM,aAAa,KAAK,CAAC;AAEhC,eAAO,MAAM,gBAAgB,GAAI,OAAO,qBAAqB,4CAoB5D,CAAC"}
|
|
@@ -1,14 +1,16 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { Tabs as ExpoTabs } from 'expo-router';
|
|
3
3
|
import { useStyles } from './ToolbarBottomNav.styles';
|
|
4
|
+
import { useSafeAreaInsets } from 'react-native-safe-area-context';
|
|
4
5
|
export const TabItemHeight = 60;
|
|
5
6
|
export const ToolbarBottomNav = (props) => {
|
|
6
7
|
const { screenOptions, ...tabProps } = props;
|
|
7
8
|
const { tabBarActiveTintColor, tabBarInactiveTintColor, ...styles } = useStyles();
|
|
9
|
+
const { bottom } = useSafeAreaInsets();
|
|
8
10
|
return (_jsx(ExpoTabs, { screenOptions: {
|
|
9
11
|
headerShown: false,
|
|
10
12
|
...styles,
|
|
11
|
-
tabBarStyle: { ...styles.tabBarStyle, height: TabItemHeight },
|
|
13
|
+
tabBarStyle: { ...styles.tabBarStyle, height: TabItemHeight, marginBottom: bottom },
|
|
12
14
|
tabBarActiveTintColor: tabBarActiveTintColor.color,
|
|
13
15
|
tabBarInactiveTintColor: tabBarInactiveTintColor.color,
|
|
14
16
|
...screenOptions,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alveole/components",
|
|
3
|
-
"version": "0.16.
|
|
3
|
+
"version": "0.16.5",
|
|
4
4
|
"description": "Shared UI components.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -48,6 +48,7 @@
|
|
|
48
48
|
"@tamagui/tabs": "^1.129.0 <2.0.0",
|
|
49
49
|
"@tamagui/toast": "^1.129.0 <2.0.0",
|
|
50
50
|
"tamagui": "^1.129.0 <2.0.0",
|
|
51
|
+
"react-native-safe-area-context": "*",
|
|
51
52
|
"react": "*",
|
|
52
53
|
"react-native": "*",
|
|
53
54
|
"react-native-svg": "^15.0.0",
|