react-native-mantine 0.8.0 → 0.10.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/lib/commonjs/components/Button/index.js +52 -17
- package/lib/commonjs/components/Button/index.js.map +1 -1
- package/lib/commonjs/components/Code/index.js +3 -1
- package/lib/commonjs/components/Code/index.js.map +1 -1
- package/lib/commonjs/components/Gradient/Gradient.js +70 -0
- package/lib/commonjs/components/Gradient/Gradient.js.map +1 -0
- package/lib/commonjs/components/Gradient/index.js +19 -0
- package/lib/commonjs/components/Gradient/index.js.map +1 -0
- package/lib/commonjs/components/Modal/index.js +33 -3
- package/lib/commonjs/components/Modal/index.js.map +1 -1
- package/lib/commonjs/components/Paper/index.js +1 -76
- package/lib/commonjs/components/Paper/index.js.map +1 -1
- package/lib/commonjs/components/Switch/index.js +6 -2
- package/lib/commonjs/components/Switch/index.js.map +1 -1
- package/lib/commonjs/components/Text/index.js +27 -8
- package/lib/commonjs/components/Text/index.js.map +1 -1
- package/lib/commonjs/components/ThemeIcon/index.js +6 -4
- package/lib/commonjs/components/ThemeIcon/index.js.map +1 -1
- package/lib/commonjs/components/Title/index.js +7 -3
- package/lib/commonjs/components/Title/index.js.map +1 -1
- package/lib/commonjs/components/index.js +33 -22
- package/lib/commonjs/components/index.js.map +1 -1
- package/lib/commonjs/theme/create-theme.js +3 -5
- package/lib/commonjs/theme/create-theme.js.map +1 -1
- package/lib/commonjs/theme/default-theme.js +168 -21
- package/lib/commonjs/theme/default-theme.js.map +1 -1
- package/lib/commonjs/theme/functions/attach-functions.js +7 -1
- package/lib/commonjs/theme/functions/attach-functions.js.map +1 -1
- package/lib/commonjs/theme/functions/fns/breakpoints.js +69 -0
- package/lib/commonjs/theme/functions/fns/breakpoints.js.map +1 -0
- package/lib/commonjs/theme/functions/fns/darken.js +25 -0
- package/lib/commonjs/theme/functions/fns/darken.js.map +1 -0
- package/lib/commonjs/theme/functions/fns/dimmed.js +19 -0
- package/lib/commonjs/theme/functions/fns/dimmed.js.map +1 -0
- package/lib/commonjs/theme/functions/fns/gradient/gradient.js +78 -0
- package/lib/commonjs/theme/functions/fns/gradient/gradient.js.map +1 -0
- package/lib/commonjs/theme/functions/fns/helpers.js +1 -2
- package/lib/commonjs/theme/functions/fns/helpers.js.map +1 -1
- package/lib/commonjs/theme/functions/fns/index.js +15 -0
- package/lib/commonjs/theme/functions/fns/index.js.map +1 -1
- package/lib/commonjs/theme/functions/fns/lighten.js +24 -0
- package/lib/commonjs/theme/functions/fns/lighten.js.map +1 -0
- package/lib/commonjs/theme/functions/fns/primary-shade.js +18 -0
- package/lib/commonjs/theme/functions/fns/primary-shade.js.map +1 -0
- package/lib/commonjs/theme/functions/fns/shadow.js +107 -0
- package/lib/commonjs/theme/functions/fns/shadow.js.map +1 -0
- package/lib/commonjs/theme/functions/fns/theme-color/theme-color.js +3 -2
- package/lib/commonjs/theme/functions/fns/theme-color/theme-color.js.map +1 -1
- package/lib/commonjs/theme/functions/fns/variant.js +7 -6
- package/lib/commonjs/theme/functions/fns/variant.js.map +1 -1
- package/lib/commonjs/theme/index.js +14 -0
- package/lib/commonjs/theme/index.js.map +1 -1
- package/lib/commonjs/theme/theme-provider.js +10 -3
- package/lib/commonjs/theme/theme-provider.js.map +1 -1
- package/lib/commonjs/theme/utils/to-rgba.js +57 -0
- package/lib/commonjs/theme/utils/to-rgba.js.map +1 -0
- package/lib/module/components/Button/index.js +53 -18
- package/lib/module/components/Button/index.js.map +1 -1
- package/lib/module/components/Code/index.js +3 -1
- package/lib/module/components/Code/index.js.map +1 -1
- package/lib/module/components/Gradient/Gradient.js +64 -0
- package/lib/module/components/Gradient/Gradient.js.map +1 -0
- package/lib/module/components/Gradient/index.js +4 -0
- package/lib/module/components/Gradient/index.js.map +1 -0
- package/lib/module/components/Modal/index.js +35 -5
- package/lib/module/components/Modal/index.js.map +1 -1
- package/lib/module/components/Paper/index.js +1 -76
- package/lib/module/components/Paper/index.js.map +1 -1
- package/lib/module/components/Switch/index.js +6 -2
- package/lib/module/components/Switch/index.js.map +1 -1
- package/lib/module/components/Text/index.js +27 -8
- package/lib/module/components/Text/index.js.map +1 -1
- package/lib/module/components/ThemeIcon/index.js +6 -4
- package/lib/module/components/ThemeIcon/index.js.map +1 -1
- package/lib/module/components/Title/index.js +7 -3
- package/lib/module/components/Title/index.js.map +1 -1
- package/lib/module/components/index.js +1 -0
- package/lib/module/components/index.js.map +1 -1
- package/lib/module/theme/create-theme.js +3 -5
- package/lib/module/theme/create-theme.js.map +1 -1
- package/lib/module/theme/default-theme.js +168 -21
- package/lib/module/theme/default-theme.js.map +1 -1
- package/lib/module/theme/functions/attach-functions.js +7 -1
- package/lib/module/theme/functions/attach-functions.js.map +1 -1
- package/lib/module/theme/functions/fns/breakpoints.js +64 -0
- package/lib/module/theme/functions/fns/breakpoints.js.map +1 -0
- package/lib/module/theme/functions/fns/darken.js +22 -0
- package/lib/module/theme/functions/fns/darken.js.map +1 -0
- package/lib/module/theme/functions/fns/dimmed.js +15 -0
- package/lib/module/theme/functions/fns/dimmed.js.map +1 -0
- package/lib/module/theme/functions/fns/gradient/gradient.js +74 -0
- package/lib/module/theme/functions/fns/gradient/gradient.js.map +1 -0
- package/lib/module/theme/functions/fns/helpers.js +1 -2
- package/lib/module/theme/functions/fns/helpers.js.map +1 -1
- package/lib/module/theme/functions/fns/index.js +15 -0
- package/lib/module/theme/functions/fns/index.js.map +1 -1
- package/lib/module/theme/functions/fns/lighten.js +21 -0
- package/lib/module/theme/functions/fns/lighten.js.map +1 -0
- package/lib/module/theme/functions/fns/primary-shade.js +14 -0
- package/lib/module/theme/functions/fns/primary-shade.js.map +1 -0
- package/lib/module/theme/functions/fns/shadow.js +103 -0
- package/lib/module/theme/functions/fns/shadow.js.map +1 -0
- package/lib/module/theme/functions/fns/theme-color/theme-color.js +3 -2
- package/lib/module/theme/functions/fns/theme-color/theme-color.js.map +1 -1
- package/lib/module/theme/functions/fns/variant.js +7 -6
- package/lib/module/theme/functions/fns/variant.js.map +1 -1
- package/lib/module/theme/index.js +2 -0
- package/lib/module/theme/index.js.map +1 -1
- package/lib/module/theme/theme-provider.js +10 -3
- package/lib/module/theme/theme-provider.js.map +1 -1
- package/lib/module/theme/utils/to-rgba.js +53 -0
- package/lib/module/theme/utils/to-rgba.js.map +1 -0
- package/lib/typescript/commonjs/src/components/Button/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/Code/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/Gradient/Gradient.d.ts +32 -0
- package/lib/typescript/commonjs/src/components/Gradient/Gradient.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Gradient/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/components/Gradient/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Modal/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/Paper/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/Switch/index.d.ts +3 -3
- package/lib/typescript/commonjs/src/components/Switch/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/Text/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/ThemeIcon/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/Title/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/index.d.ts +1 -0
- package/lib/typescript/commonjs/src/components/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/theme/create-theme.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/theme/default-theme.d.ts +34 -3
- package/lib/typescript/commonjs/src/theme/default-theme.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/theme/functions/attach-functions.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/theme/functions/fns/breakpoints.d.ts +15 -0
- package/lib/typescript/commonjs/src/theme/functions/fns/breakpoints.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/theme/functions/fns/darken.d.ts +8 -0
- package/lib/typescript/commonjs/src/theme/functions/fns/darken.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/theme/functions/fns/dimmed.d.ts +9 -0
- package/lib/typescript/commonjs/src/theme/functions/fns/dimmed.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/theme/functions/fns/gradient/gradient.d.ts +13 -0
- package/lib/typescript/commonjs/src/theme/functions/fns/gradient/gradient.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/theme/functions/fns/helpers.d.ts +1 -2
- package/lib/typescript/commonjs/src/theme/functions/fns/helpers.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/theme/functions/fns/index.d.ts +16 -1
- package/lib/typescript/commonjs/src/theme/functions/fns/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/theme/functions/fns/lighten.d.ts +8 -0
- package/lib/typescript/commonjs/src/theme/functions/fns/lighten.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/theme/functions/fns/primary-shade.d.ts +7 -0
- package/lib/typescript/commonjs/src/theme/functions/fns/primary-shade.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/theme/functions/fns/shadow.d.ts +24 -0
- package/lib/typescript/commonjs/src/theme/functions/fns/shadow.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/theme/functions/fns/theme-color/theme-color.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/theme/functions/fns/variant.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/theme/index.d.ts +4 -0
- package/lib/typescript/commonjs/src/theme/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/theme/theme-provider.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/theme/utils/to-rgba.d.ts +9 -0
- package/lib/typescript/commonjs/src/theme/utils/to-rgba.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Button/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/Code/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/Gradient/Gradient.d.ts +32 -0
- package/lib/typescript/module/src/components/Gradient/Gradient.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Gradient/index.d.ts +3 -0
- package/lib/typescript/module/src/components/Gradient/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Modal/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/Paper/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/Switch/index.d.ts +3 -3
- package/lib/typescript/module/src/components/Switch/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/Text/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/ThemeIcon/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/Title/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/index.d.ts +1 -0
- package/lib/typescript/module/src/components/index.d.ts.map +1 -1
- package/lib/typescript/module/src/theme/create-theme.d.ts.map +1 -1
- package/lib/typescript/module/src/theme/default-theme.d.ts +34 -3
- package/lib/typescript/module/src/theme/default-theme.d.ts.map +1 -1
- package/lib/typescript/module/src/theme/functions/attach-functions.d.ts.map +1 -1
- package/lib/typescript/module/src/theme/functions/fns/breakpoints.d.ts +15 -0
- package/lib/typescript/module/src/theme/functions/fns/breakpoints.d.ts.map +1 -0
- package/lib/typescript/module/src/theme/functions/fns/darken.d.ts +8 -0
- package/lib/typescript/module/src/theme/functions/fns/darken.d.ts.map +1 -0
- package/lib/typescript/module/src/theme/functions/fns/dimmed.d.ts +9 -0
- package/lib/typescript/module/src/theme/functions/fns/dimmed.d.ts.map +1 -0
- package/lib/typescript/module/src/theme/functions/fns/gradient/gradient.d.ts +13 -0
- package/lib/typescript/module/src/theme/functions/fns/gradient/gradient.d.ts.map +1 -0
- package/lib/typescript/module/src/theme/functions/fns/helpers.d.ts +1 -2
- package/lib/typescript/module/src/theme/functions/fns/helpers.d.ts.map +1 -1
- package/lib/typescript/module/src/theme/functions/fns/index.d.ts +16 -1
- package/lib/typescript/module/src/theme/functions/fns/index.d.ts.map +1 -1
- package/lib/typescript/module/src/theme/functions/fns/lighten.d.ts +8 -0
- package/lib/typescript/module/src/theme/functions/fns/lighten.d.ts.map +1 -0
- package/lib/typescript/module/src/theme/functions/fns/primary-shade.d.ts +7 -0
- package/lib/typescript/module/src/theme/functions/fns/primary-shade.d.ts.map +1 -0
- package/lib/typescript/module/src/theme/functions/fns/shadow.d.ts +24 -0
- package/lib/typescript/module/src/theme/functions/fns/shadow.d.ts.map +1 -0
- package/lib/typescript/module/src/theme/functions/fns/theme-color/theme-color.d.ts.map +1 -1
- package/lib/typescript/module/src/theme/functions/fns/variant.d.ts.map +1 -1
- package/lib/typescript/module/src/theme/index.d.ts +4 -0
- package/lib/typescript/module/src/theme/index.d.ts.map +1 -1
- package/lib/typescript/module/src/theme/theme-provider.d.ts.map +1 -1
- package/lib/typescript/module/src/theme/utils/to-rgba.d.ts +9 -0
- package/lib/typescript/module/src/theme/utils/to-rgba.d.ts.map +1 -0
- package/package.json +1 -1
- package/src/components/Button/index.tsx +61 -21
- package/src/components/Code/index.tsx +3 -1
- package/src/components/Gradient/Gradient.tsx +71 -0
- package/src/components/Gradient/index.tsx +2 -0
- package/src/components/Modal/index.tsx +33 -3
- package/src/components/Paper/index.tsx +1 -63
- package/src/components/Switch/index.tsx +10 -6
- package/src/components/Text/index.tsx +28 -16
- package/src/components/ThemeIcon/index.tsx +6 -4
- package/src/components/Title/index.tsx +7 -3
- package/src/components/index.tsx +1 -0
- package/src/theme/create-theme.ts +3 -5
- package/src/theme/default-theme.ts +179 -91
- package/src/theme/functions/attach-functions.ts +6 -0
- package/src/theme/functions/fns/breakpoints.ts +62 -0
- package/src/theme/functions/fns/darken.ts +16 -0
- package/src/theme/functions/fns/dimmed.ts +16 -0
- package/src/theme/functions/fns/gradient/gradient.ts +63 -0
- package/src/theme/functions/fns/helpers.ts +1 -2
- package/src/theme/functions/fns/index.ts +15 -0
- package/src/theme/functions/fns/lighten.ts +15 -0
- package/src/theme/functions/fns/primary-shade.ts +17 -0
- package/src/theme/functions/fns/shadow.ts +100 -0
- package/src/theme/functions/fns/theme-color/theme-color.ts +3 -2
- package/src/theme/functions/fns/variant.ts +6 -5
- package/src/theme/index.tsx +4 -0
- package/src/theme/theme-provider.tsx +8 -3
- package/src/theme/theme.d.ts +11 -1
- package/src/theme/utils/to-rgba.ts +69 -0
|
@@ -4,12 +4,12 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports._DEFAULT_THEME = exports.DEFAULT_THEME = exports.DEFAULT_COLORS = void 0;
|
|
7
|
+
var _reactNative = require("react-native");
|
|
7
8
|
var _attachFunctions = require("./functions/attach-functions.js");
|
|
8
9
|
const DEFAULT_COLORS = exports.DEFAULT_COLORS = {
|
|
9
|
-
dark: ['#
|
|
10
|
-
gray: ['#
|
|
11
|
-
|
|
12
|
-
red: ['#ffeaea', '#fcd4d4', '#f3a8a8', '#eb7877', '#e4504f', '#e13735', '#e02928', '#c71c1c', '#b21518', '#9c0711'],
|
|
10
|
+
dark: ['#C1C2C5', '#A6A7AB', '#909296', '#5c5f66', '#373A40', '#2C2E33', '#25262b', '#1A1B1E', '#141517', '#101113'],
|
|
11
|
+
gray: ['#f8f9fa', '#f1f3f5', '#e9ecef', '#dee2e6', '#ced4da', '#adb5bd', '#868e96', '#495057', '#343a40', '#212529'],
|
|
12
|
+
red: ['#fff5f5', '#ffe3e3', '#ffc9c9', '#ffa8a8', '#ff8787', '#ff6b6b', '#fa5252', '#f03e3e', '#e03131', '#c92a2a'],
|
|
13
13
|
pink: ['#fff0f6', '#ffdeeb', '#fcc2d7', '#faa2c1', '#f783ac', '#f06595', '#e64980', '#d6336c', '#c2255c', '#a61e4d'],
|
|
14
14
|
grape: ['#f8f0fc', '#f3d9fa', '#eebefa', '#e599f7', '#da77f2', '#cc5de8', '#be4bdb', '#ae3ec9', '#9c36b5', '#862e9c'],
|
|
15
15
|
violet: ['#f3f0ff', '#e5dbff', '#d0bfff', '#b197fc', '#9775fa', '#845ef7', '#7950f2', '#7048e8', '#6741d9', '#5f3dc4'],
|
|
@@ -17,27 +17,82 @@ const DEFAULT_COLORS = exports.DEFAULT_COLORS = {
|
|
|
17
17
|
blue: ['#e7f5ff', '#d0ebff', '#a5d8ff', '#74c0fc', '#4dabf7', '#339af0', '#228be6', '#1c7ed6', '#1971c2', '#1864ab'],
|
|
18
18
|
cyan: ['#e3fafc', '#c5f6fa', '#99e9f2', '#66d9e8', '#3bc9db', '#22b8cf', '#15aabf', '#1098ad', '#0c8599', '#0b7285'],
|
|
19
19
|
teal: ['#e6fcf5', '#c3fae8', '#96f2d7', '#63e6be', '#38d9a9', '#20c997', '#12b886', '#0ca678', '#099268', '#087f5b'],
|
|
20
|
-
green: ['#
|
|
20
|
+
green: ['#ebfbee', '#d3f9d8', '#b2f2bb', '#8ce99a', '#69db7c', '#51cf66', '#40c057', '#37b24d', '#2f9e44', '#2b8a3e'],
|
|
21
21
|
lime: ['#f4fce3', '#e9fac8', '#d8f5a2', '#c0eb75', '#a9e34b', '#94d82d', '#82c91e', '#74b816', '#66a80f', '#5c940d'],
|
|
22
22
|
yellow: ['#fff9db', '#fff3bf', '#ffec99', '#ffe066', '#ffd43b', '#fcc419', '#fab005', '#f59f00', '#f08c00', '#e67700'],
|
|
23
|
-
orange: ['#
|
|
24
|
-
secondary: ['#f4f4f5', '#e7e7e7', '#cccccc', '#afafaf', '#989898', '#898989', '#818181', '#6f6f6f', '#616164', '#545459']
|
|
23
|
+
orange: ['#fff4e6', '#ffe8cc', '#ffd8a8', '#ffc078', '#ffa94d', '#ff922b', '#fd7e14', '#f76707', '#e8590c', '#d9480f']
|
|
25
24
|
};
|
|
26
25
|
const tintColorLight = '#2f95dc';
|
|
27
26
|
const tintColorDark = '#fff';
|
|
28
27
|
const _DEFAULT_THEME = exports._DEFAULT_THEME = {
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
28
|
+
// Font configuration matches Mantine web as closely as possible
|
|
29
|
+
// Web: '-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji'
|
|
30
|
+
// React Native maps to platform-specific system fonts
|
|
31
|
+
fontFamily: _reactNative.Platform.select({
|
|
32
|
+
ios: 'System',
|
|
33
|
+
// San Francisco (equivalent to -apple-system)
|
|
34
|
+
android: 'Roboto',
|
|
35
|
+
// Android system font
|
|
36
|
+
default: 'System'
|
|
37
|
+
}),
|
|
38
|
+
// Bold font family - iOS/Android don't always render fontWeight properly
|
|
39
|
+
// so we need separate font families for different weights
|
|
40
|
+
fontFamilyBold: _reactNative.Platform.select({
|
|
41
|
+
ios: 'System',
|
|
42
|
+
// iOS handles bold via fontWeight with System font
|
|
43
|
+
android: 'Roboto-Bold',
|
|
44
|
+
// Android needs explicit bold font family
|
|
45
|
+
default: 'System'
|
|
46
|
+
}),
|
|
47
|
+
// SemiBold font family
|
|
48
|
+
fontFamilySemiBold: _reactNative.Platform.select({
|
|
49
|
+
ios: 'System',
|
|
50
|
+
// iOS handles semibold via fontWeight with System font
|
|
51
|
+
android: 'Roboto-Medium',
|
|
52
|
+
// Android medium is equivalent to semibold
|
|
53
|
+
default: 'System'
|
|
54
|
+
}),
|
|
55
|
+
// Input font family - separate for form inputs
|
|
56
|
+
fontFamilyInput: _reactNative.Platform.select({
|
|
57
|
+
ios: 'System',
|
|
58
|
+
android: 'Roboto',
|
|
59
|
+
default: 'System'
|
|
60
|
+
}),
|
|
61
|
+
// Web: 'ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, Liberation Mono, Courier New, monospace'
|
|
62
|
+
fontFamilyMonospace: _reactNative.Platform.select({
|
|
63
|
+
ios: 'Menlo',
|
|
64
|
+
// iOS monospace font
|
|
65
|
+
android: 'monospace',
|
|
66
|
+
// Android monospace font
|
|
67
|
+
default: 'monospace'
|
|
68
|
+
}),
|
|
69
|
+
fontWeights: {
|
|
70
|
+
thin: '100',
|
|
71
|
+
extralight: '200',
|
|
72
|
+
light: '300',
|
|
73
|
+
normal: '400',
|
|
74
|
+
medium: '500',
|
|
75
|
+
semibold: '600',
|
|
76
|
+
bold: '700',
|
|
77
|
+
extrabold: '800',
|
|
78
|
+
black: '900'
|
|
79
|
+
},
|
|
33
80
|
localColor: '#1F2863',
|
|
34
|
-
primaryShade:
|
|
81
|
+
primaryShade: {
|
|
82
|
+
light: 6,
|
|
83
|
+
dark: 8
|
|
84
|
+
},
|
|
35
85
|
colors: DEFAULT_COLORS,
|
|
36
86
|
primaryColor: 'blue',
|
|
37
87
|
secondaryColor: 'black',
|
|
38
88
|
secondaryBgColor: 'white',
|
|
39
89
|
white: '#ffffff',
|
|
40
90
|
black: '#000000',
|
|
91
|
+
defaultGradient: {
|
|
92
|
+
from: 'blue',
|
|
93
|
+
to: 'cyan',
|
|
94
|
+
deg: 45
|
|
95
|
+
},
|
|
41
96
|
light: {
|
|
42
97
|
text: '#000',
|
|
43
98
|
background: '#fdfdfd',
|
|
@@ -58,13 +113,89 @@ const _DEFAULT_THEME = exports._DEFAULT_THEME = {
|
|
|
58
113
|
},
|
|
59
114
|
components: {},
|
|
60
115
|
other: {},
|
|
61
|
-
shadows: {
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
116
|
+
shadows: _reactNative.Platform.select({
|
|
117
|
+
ios: {
|
|
118
|
+
xs: {
|
|
119
|
+
shadowColor: '#000',
|
|
120
|
+
shadowOffset: {
|
|
121
|
+
width: 0,
|
|
122
|
+
height: 1
|
|
123
|
+
},
|
|
124
|
+
shadowOpacity: 0.05,
|
|
125
|
+
shadowRadius: 1
|
|
126
|
+
},
|
|
127
|
+
sm: {
|
|
128
|
+
shadowColor: '#000',
|
|
129
|
+
shadowOffset: {
|
|
130
|
+
width: 0,
|
|
131
|
+
height: 1
|
|
132
|
+
},
|
|
133
|
+
shadowOpacity: 0.1,
|
|
134
|
+
shadowRadius: 2
|
|
135
|
+
},
|
|
136
|
+
md: {
|
|
137
|
+
shadowColor: '#000',
|
|
138
|
+
shadowOffset: {
|
|
139
|
+
width: 0,
|
|
140
|
+
height: 2
|
|
141
|
+
},
|
|
142
|
+
shadowOpacity: 0.15,
|
|
143
|
+
shadowRadius: 4
|
|
144
|
+
},
|
|
145
|
+
lg: {
|
|
146
|
+
shadowColor: '#000',
|
|
147
|
+
shadowOffset: {
|
|
148
|
+
width: 0,
|
|
149
|
+
height: 4
|
|
150
|
+
},
|
|
151
|
+
shadowOpacity: 0.2,
|
|
152
|
+
shadowRadius: 8
|
|
153
|
+
},
|
|
154
|
+
xl: {
|
|
155
|
+
shadowColor: '#000',
|
|
156
|
+
shadowOffset: {
|
|
157
|
+
width: 0,
|
|
158
|
+
height: 8
|
|
159
|
+
},
|
|
160
|
+
shadowOpacity: 0.25,
|
|
161
|
+
shadowRadius: 16
|
|
162
|
+
}
|
|
163
|
+
},
|
|
164
|
+
android: {
|
|
165
|
+
xs: {
|
|
166
|
+
elevation: 1
|
|
167
|
+
},
|
|
168
|
+
sm: {
|
|
169
|
+
elevation: 2
|
|
170
|
+
},
|
|
171
|
+
md: {
|
|
172
|
+
elevation: 4
|
|
173
|
+
},
|
|
174
|
+
lg: {
|
|
175
|
+
elevation: 8
|
|
176
|
+
},
|
|
177
|
+
xl: {
|
|
178
|
+
elevation: 12
|
|
179
|
+
}
|
|
180
|
+
},
|
|
181
|
+
default: {
|
|
182
|
+
xs: {
|
|
183
|
+
elevation: 1
|
|
184
|
+
},
|
|
185
|
+
sm: {
|
|
186
|
+
elevation: 2
|
|
187
|
+
},
|
|
188
|
+
md: {
|
|
189
|
+
elevation: 4
|
|
190
|
+
},
|
|
191
|
+
lg: {
|
|
192
|
+
elevation: 8
|
|
193
|
+
},
|
|
194
|
+
xl: {
|
|
195
|
+
elevation: 12
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
}),
|
|
68
199
|
fontSizes: {
|
|
69
200
|
xs: 12,
|
|
70
201
|
sm: 14,
|
|
@@ -87,9 +218,25 @@ const _DEFAULT_THEME = exports._DEFAULT_THEME = {
|
|
|
87
218
|
lg: 20,
|
|
88
219
|
xl: 24
|
|
89
220
|
},
|
|
221
|
+
breakpoints: {
|
|
222
|
+
xs: 576,
|
|
223
|
+
sm: 768,
|
|
224
|
+
md: 992,
|
|
225
|
+
lg: 1200,
|
|
226
|
+
xl: 1408
|
|
227
|
+
},
|
|
90
228
|
headings: {
|
|
91
|
-
|
|
92
|
-
|
|
229
|
+
// Headings use bold font family for proper weight rendering on iOS/Android
|
|
230
|
+
// On Android, using Roboto-Bold ensures proper bold rendering
|
|
231
|
+
fontFamily: _reactNative.Platform.select({
|
|
232
|
+
ios: 'System',
|
|
233
|
+
// San Francisco (equivalent to -apple-system)
|
|
234
|
+
android: 'Roboto-Bold',
|
|
235
|
+
// Android needs explicit bold font family
|
|
236
|
+
default: 'System'
|
|
237
|
+
}),
|
|
238
|
+
fontWeight: '700',
|
|
239
|
+
// Matches Mantine web heading weight
|
|
93
240
|
sizes: {
|
|
94
241
|
h1: {
|
|
95
242
|
fontSize: 34,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"names":["_reactNative","require","_attachFunctions","DEFAULT_COLORS","exports","dark","gray","red","pink","grape","violet","indigo","blue","cyan","teal","green","lime","yellow","orange","tintColorLight","tintColorDark","_DEFAULT_THEME","fontFamily","Platform","select","ios","android","default","fontFamilyBold","fontFamilySemiBold","fontFamilyInput","fontFamilyMonospace","fontWeights","thin","extralight","light","normal","medium","semibold","bold","extrabold","black","localColor","primaryShade","colors","primaryColor","secondaryColor","secondaryBgColor","white","defaultGradient","from","to","deg","text","background","backgroundSecondary","backgroundThird","tint","tabIconDefault","tabIconSelected","components","other","shadows","xs","shadowColor","shadowOffset","width","height","shadowOpacity","shadowRadius","sm","md","lg","xl","elevation","fontSizes","defaultRadius","radius","spacing","breakpoints","headings","fontWeight","sizes","h1","fontSize","lineHeight","undefined","h2","h3","h4","h5","h6","window","primaryBgColor","primaryTextColor","DEFAULT_THEME","attachFunctions"],"sourceRoot":"../../../src","sources":["theme/default-theme.ts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C1BC,GAAG,EAAE,QAAQ;MAAE;MACfC,OAAO,EAAE,aAAa;MAAE;MACxBC,OAAO,EAAE;IACX,CAAC,CAAC;IACFsD,UAAU,EAAE,KAAK;IAAE;IACnBC,KAAK,EAAE;MACLC,EAAE,EAAE;QAAEC,QAAQ,EAAE,EAAE;QAAEC,UAAU,EAAE,GAAG;QAAEJ,UAAU,EAAEK;MAAU,CAAC;MAC5DC,EAAE,EAAE;QAAEH,QAAQ,EAAE,EAAE;QAAEC,UAAU,EAAE,IAAI;QAAEJ,UAAU,EAAEK;MAAU,CAAC;MAC7DE,EAAE,EAAE;QAAEJ,QAAQ,EAAE,EAAE;QAAEC,UAAU,EAAE,GAAG;QAAEJ,UAAU,EAAEK;MAAU,CAAC;MAC5DG,EAAE,EAAE;QAAEL,QAAQ,EAAE,EAAE;QAAEC,UAAU,EAAE,IAAI;QAAEJ,UAAU,EAAEK;MAAU,CAAC;MAC7DI,EAAE,EAAE;QAAEN,QAAQ,EAAE,EAAE;QAAEC,UAAU,EAAE,GAAG;QAAEJ,UAAU,EAAEK;MAAU,CAAC;MAC5DK,EAAE,EAAE;QAAEP,QAAQ,EAAE,EAAE;QAAEC,UAAU,EAAE,GAAG;QAAEJ,UAAU,EAAEK;MAAU;IAC7D;EACF,CAAC;EACDM,MAAM,EAAE;IACN1B,KAAK,EAAE,GAAG;IACVC,MAAM,EAAE;EACV,CAAC;EACD0B,cAAc,EAAE,OAAO;EACvBC,gBAAgB,EAAE;AACpB,CAAC;AAEM,MAAMC,aAAa,GAAA3F,OAAA,CAAA2F,aAAA,GAAG,IAAAC,gCAAe,EAAC3E,cAAc,CAAC","ignoreList":[]}
|
|
@@ -18,12 +18,18 @@ function attachFunctions(themeBase) {
|
|
|
18
18
|
color,
|
|
19
19
|
shade
|
|
20
20
|
}),
|
|
21
|
+
shadow: _index.fns.shadow,
|
|
21
22
|
fontStyles: _index.fns.fontStyles(themeBase),
|
|
22
23
|
inputFontStyles: _index.fns.inputFontStyles(themeBase),
|
|
23
24
|
focusStyles: _index.fns.focusStyles(themeBase),
|
|
24
25
|
placeholderStyles: _index.fns.placeholderStyles(themeBase),
|
|
25
26
|
cover: _index.fns.cover(themeBase),
|
|
26
|
-
hover: _index.fns.hover(themeBase)
|
|
27
|
+
hover: _index.fns.hover(themeBase),
|
|
28
|
+
lighten: _index.fns.lighten,
|
|
29
|
+
darken: _index.fns.darken,
|
|
30
|
+
dimmed: _index.fns.dimmed(themeBase),
|
|
31
|
+
largerThan: _index.fns.largerThan(themeBase),
|
|
32
|
+
smallerThan: _index.fns.smallerThan(themeBase)
|
|
27
33
|
},
|
|
28
34
|
activeStyles: _index.fns.activeStyles(themeBase)
|
|
29
35
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_index","require","attachFunctions","themeBase","fn","radius","fns","rgba","size","variant","themeColor","color","shade","theme","fontStyles","inputFontStyles","focusStyles","placeholderStyles","cover","hover","activeStyles"],"sourceRoot":"../../../../src","sources":["theme/functions/attach-functions.ts"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AAEO,SAASC,eAAeA,CAACC,SAAc,EAAO;EACnD,OAAO;IACL,GAAGA,SAAS;IACZC,EAAE,EAAE;MACFC,MAAM,EAAEC,UAAG,CAACD,MAAM,CAACF,SAAS,CAAC;MAC7BI,IAAI,EAAED,UAAG,CAACC,IAAI,CAACJ,SAAS,CAAC;MACzBK,IAAI,EAAEF,UAAG,CAACE,IAAI,CAACL,SAAS,CAAC;MACzBM,OAAO,EAAEH,UAAG,CAACG,OAAO,CAACN,SAAS,CAAC;MAC/BO,UAAU,EAAEA,CAACC,KAAa,EAAEC,KAAc,KACxCN,UAAG,CAACI,UAAU,CAAC;QAAEG,KAAK,EAAEV,SAAS;QAAEQ,KAAK;QAAEC;MAAM,CAAC,CAAC;MACpDE,
|
|
1
|
+
{"version":3,"names":["_index","require","attachFunctions","themeBase","fn","radius","fns","rgba","size","variant","themeColor","color","shade","theme","shadow","fontStyles","inputFontStyles","focusStyles","placeholderStyles","cover","hover","lighten","darken","dimmed","largerThan","smallerThan","activeStyles"],"sourceRoot":"../../../../src","sources":["theme/functions/attach-functions.ts"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AAEO,SAASC,eAAeA,CAACC,SAAc,EAAO;EACnD,OAAO;IACL,GAAGA,SAAS;IACZC,EAAE,EAAE;MACFC,MAAM,EAAEC,UAAG,CAACD,MAAM,CAACF,SAAS,CAAC;MAC7BI,IAAI,EAAED,UAAG,CAACC,IAAI,CAACJ,SAAS,CAAC;MACzBK,IAAI,EAAEF,UAAG,CAACE,IAAI,CAACL,SAAS,CAAC;MACzBM,OAAO,EAAEH,UAAG,CAACG,OAAO,CAACN,SAAS,CAAC;MAC/BO,UAAU,EAAEA,CAACC,KAAa,EAAEC,KAAc,KACxCN,UAAG,CAACI,UAAU,CAAC;QAAEG,KAAK,EAAEV,SAAS;QAAEQ,KAAK;QAAEC;MAAM,CAAC,CAAC;MACpDE,MAAM,EAAER,UAAG,CAACQ,MAAM;MAClBC,UAAU,EAAET,UAAG,CAACS,UAAU,CAACZ,SAAS,CAAC;MACrCa,eAAe,EAAEV,UAAG,CAACU,eAAe,CAACb,SAAS,CAAC;MAC/Cc,WAAW,EAAEX,UAAG,CAACW,WAAW,CAACd,SAAS,CAAC;MACvCe,iBAAiB,EAAEZ,UAAG,CAACY,iBAAiB,CAACf,SAAS,CAAC;MACnDgB,KAAK,EAAEb,UAAG,CAACa,KAAK,CAAChB,SAAS,CAAC;MAC3BiB,KAAK,EAAEd,UAAG,CAACc,KAAK,CAACjB,SAAS,CAAC;MAC3BkB,OAAO,EAAEf,UAAG,CAACe,OAAO;MACpBC,MAAM,EAAEhB,UAAG,CAACgB,MAAM;MAClBC,MAAM,EAAEjB,UAAG,CAACiB,MAAM,CAACpB,SAAS,CAAC;MAC7BqB,UAAU,EAAElB,UAAG,CAACkB,UAAU,CAACrB,SAAS,CAAC;MACrCsB,WAAW,EAAEnB,UAAG,CAACmB,WAAW,CAACtB,SAAS;IACxC,CAAC;IACDuB,YAAY,EAAEpB,UAAG,CAACoB,YAAY,CAACvB,SAAS;EAC1C,CAAC;AACH","ignoreList":[]}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.largerThan = largerThan;
|
|
7
|
+
exports.smallerThan = smallerThan;
|
|
8
|
+
var _reactNative = require("react-native");
|
|
9
|
+
/**
|
|
10
|
+
* Default breakpoint values in pixels
|
|
11
|
+
* These match Mantine web but converted to pixels (1em = 16px)
|
|
12
|
+
*/
|
|
13
|
+
const DEFAULT_BREAKPOINTS = {
|
|
14
|
+
xs: 576,
|
|
15
|
+
// 36em * 16
|
|
16
|
+
sm: 768,
|
|
17
|
+
// 48em * 16
|
|
18
|
+
md: 992,
|
|
19
|
+
// 62em * 16
|
|
20
|
+
lg: 1200,
|
|
21
|
+
// 75em * 16
|
|
22
|
+
xl: 1408 // 88em * 16
|
|
23
|
+
};
|
|
24
|
+
/**
|
|
25
|
+
* Get breakpoint value from theme or default
|
|
26
|
+
*/
|
|
27
|
+
function getBreakpointValue(breakpoint, theme) {
|
|
28
|
+
if (typeof breakpoint === 'number') {
|
|
29
|
+
return breakpoint;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
// Check if theme has breakpoints defined
|
|
33
|
+
if (theme.breakpoints && theme.breakpoints[breakpoint]) {
|
|
34
|
+
const value = theme.breakpoints[breakpoint];
|
|
35
|
+
return typeof value === 'number' ? value : Number(value);
|
|
36
|
+
}
|
|
37
|
+
return DEFAULT_BREAKPOINTS[breakpoint];
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
/**
|
|
41
|
+
* Returns true if current screen width is larger than the specified breakpoint
|
|
42
|
+
* @param theme - The Mantine theme
|
|
43
|
+
* @returns A function that takes a breakpoint and returns a boolean
|
|
44
|
+
*/
|
|
45
|
+
function largerThan(theme) {
|
|
46
|
+
return breakpoint => {
|
|
47
|
+
const {
|
|
48
|
+
width
|
|
49
|
+
} = _reactNative.Dimensions.get('window');
|
|
50
|
+
const breakpointValue = getBreakpointValue(breakpoint, theme);
|
|
51
|
+
return width >= breakpointValue;
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
/**
|
|
56
|
+
* Returns true if current screen width is smaller than the specified breakpoint
|
|
57
|
+
* @param theme - The Mantine theme
|
|
58
|
+
* @returns A function that takes a breakpoint and returns a boolean
|
|
59
|
+
*/
|
|
60
|
+
function smallerThan(theme) {
|
|
61
|
+
return breakpoint => {
|
|
62
|
+
const {
|
|
63
|
+
width
|
|
64
|
+
} = _reactNative.Dimensions.get('window');
|
|
65
|
+
const breakpointValue = getBreakpointValue(breakpoint, theme);
|
|
66
|
+
return width < breakpointValue;
|
|
67
|
+
};
|
|
68
|
+
}
|
|
69
|
+
//# sourceMappingURL=breakpoints.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_reactNative","require","DEFAULT_BREAKPOINTS","xs","sm","md","lg","xl","getBreakpointValue","breakpoint","theme","breakpoints","value","Number","largerThan","width","Dimensions","get","breakpointValue","smallerThan"],"sourceRoot":"../../../../../src","sources":["theme/functions/fns/breakpoints.ts"],"mappings":";;;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AAGA;AACA;AACA;AACA;AACA,MAAMC,mBAAmB,GAAG;EAC1BC,EAAE,EAAE,GAAG;EAAE;EACTC,EAAE,EAAE,GAAG;EAAE;EACTC,EAAE,EAAE,GAAG;EAAE;EACTC,EAAE,EAAE,IAAI;EAAE;EACVC,EAAE,EAAE,IAAI,CAAE;AACZ,CAAC;AAID;AACA;AACA;AACA,SAASC,kBAAkBA,CACzBC,UAA6B,EAC7BC,KAAmB,EACX;EACR,IAAI,OAAOD,UAAU,KAAK,QAAQ,EAAE;IAClC,OAAOA,UAAU;EACnB;;EAEA;EACA,IAAIC,KAAK,CAACC,WAAW,IAAID,KAAK,CAACC,WAAW,CAACF,UAAU,CAAC,EAAE;IACtD,MAAMG,KAAK,GAAGF,KAAK,CAACC,WAAW,CAACF,UAAU,CAAC;IAC3C,OAAO,OAAOG,KAAK,KAAK,QAAQ,GAAGA,KAAK,GAAGC,MAAM,CAACD,KAAK,CAAC;EAC1D;EAEA,OAAOV,mBAAmB,CAACO,UAAU,CAAqC;AAC5E;;AAEA;AACA;AACA;AACA;AACA;AACO,SAASK,UAAUA,CAACJ,KAAmB,EAAE;EAC9C,OAAQD,UAA6B,IAAc;IACjD,MAAM;MAAEM;IAAM,CAAC,GAAGC,uBAAU,CAACC,GAAG,CAAC,QAAQ,CAAC;IAC1C,MAAMC,eAAe,GAAGV,kBAAkB,CAACC,UAAU,EAAEC,KAAK,CAAC;IAC7D,OAAOK,KAAK,IAAIG,eAAe;EACjC,CAAC;AACH;;AAEA;AACA;AACA;AACA;AACA;AACO,SAASC,WAAWA,CAACT,KAAmB,EAAE;EAC/C,OAAQD,UAA6B,IAAc;IACjD,MAAM;MAAEM;IAAM,CAAC,GAAGC,uBAAU,CAACC,GAAG,CAAC,QAAQ,CAAC;IAC1C,MAAMC,eAAe,GAAGV,kBAAkB,CAACC,UAAU,EAAEC,KAAK,CAAC;IAC7D,OAAOK,KAAK,GAAGG,eAAe;EAChC,CAAC;AACH","ignoreList":[]}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.darken = darken;
|
|
7
|
+
var _toRgba = require("../../utils/to-rgba.js");
|
|
8
|
+
/**
|
|
9
|
+
* Darkens a color by reducing its RGB values
|
|
10
|
+
* @param color - The color to darken (hex or rgb/rgba string)
|
|
11
|
+
* @param alpha - The amount to darken (0-1, where 1 is completely black)
|
|
12
|
+
* @returns rgba color string
|
|
13
|
+
*/
|
|
14
|
+
function darken(color, alpha) {
|
|
15
|
+
const {
|
|
16
|
+
r,
|
|
17
|
+
g,
|
|
18
|
+
b,
|
|
19
|
+
a
|
|
20
|
+
} = (0, _toRgba.toRgba)(color);
|
|
21
|
+
const f = 1 - alpha;
|
|
22
|
+
const dark = input => Math.round(input * f);
|
|
23
|
+
return `rgba(${dark(r)}, ${dark(g)}, ${dark(b)}, ${a})`;
|
|
24
|
+
}
|
|
25
|
+
//# sourceMappingURL=darken.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_toRgba","require","darken","color","alpha","r","g","b","a","toRgba","f","dark","input","Math","round"],"sourceRoot":"../../../../../src","sources":["theme/functions/fns/darken.ts"],"mappings":";;;;;;AAAA,IAAAA,OAAA,GAAAC,OAAA;AAEA;AACA;AACA;AACA;AACA;AACA;AACO,SAASC,MAAMA,CAACC,KAAa,EAAEC,KAAa,EAAU;EAC3D,MAAM;IAAEC,CAAC;IAAEC,CAAC;IAAEC,CAAC;IAAEC;EAAE,CAAC,GAAG,IAAAC,cAAM,EAACN,KAAK,CAAC;EACpC,MAAMO,CAAC,GAAG,CAAC,GAAGN,KAAK;EAEnB,MAAMO,IAAI,GAAIC,KAAa,IAAKC,IAAI,CAACC,KAAK,CAACF,KAAK,GAAGF,CAAC,CAAC;EAErD,OAAO,QAAQC,IAAI,CAACN,CAAC,CAAC,KAAKM,IAAI,CAACL,CAAC,CAAC,KAAKK,IAAI,CAACJ,CAAC,CAAC,KAAKC,CAAC,GAAG;AACzD","ignoreList":[]}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.dimmed = dimmed;
|
|
7
|
+
/**
|
|
8
|
+
* Returns a dimmed text color based on the current color scheme
|
|
9
|
+
* Used for secondary text and less prominent UI elements
|
|
10
|
+
* @param theme - The Mantine theme
|
|
11
|
+
* @returns A function that returns the dimmed color
|
|
12
|
+
*/
|
|
13
|
+
function dimmed(theme) {
|
|
14
|
+
return () => {
|
|
15
|
+
const colorScheme = theme.currentMode || 'light';
|
|
16
|
+
return colorScheme === 'dark' ? theme.colors.dark?.[2] || '#909296' : theme.colors.gray?.[6] || '#868e96';
|
|
17
|
+
};
|
|
18
|
+
}
|
|
19
|
+
//# sourceMappingURL=dimmed.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["dimmed","theme","colorScheme","currentMode","colors","dark","gray"],"sourceRoot":"../../../../../src","sources":["theme/functions/fns/dimmed.ts"],"mappings":";;;;;;AAEA;AACA;AACA;AACA;AACA;AACA;AACO,SAASA,MAAMA,CAACC,KAAmB,EAAE;EAC1C,OAAO,MAAM;IACX,MAAMC,WAAW,GAAGD,KAAK,CAACE,WAAW,IAAI,OAAO;IAChD,OAAOD,WAAW,KAAK,MAAM,GACzBD,KAAK,CAACG,MAAM,CAACC,IAAI,GAAG,CAAC,CAAC,IAAI,SAAS,GACnCJ,KAAK,CAACG,MAAM,CAACE,IAAI,GAAG,CAAC,CAAC,IAAI,SAAS;EACzC,CAAC;AACH","ignoreList":[]}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.gradient = gradient;
|
|
7
|
+
exports.linearGradientCSS = linearGradientCSS;
|
|
8
|
+
var _themeColor = require("../theme-color/theme-color.js");
|
|
9
|
+
var _primaryShade = require("../primary-shade.js");
|
|
10
|
+
/**
|
|
11
|
+
* Converts degrees to start/end coordinates for LinearGradient
|
|
12
|
+
* 0deg = bottom to top, 90deg = left to right, 180deg = top to bottom, 270deg = right to left
|
|
13
|
+
*/
|
|
14
|
+
function degToCoordinates(deg) {
|
|
15
|
+
const angle = (deg % 360 + 360) % 360; // Normalize to 0-360
|
|
16
|
+
const radians = angle * Math.PI / 180;
|
|
17
|
+
|
|
18
|
+
// Calculate end point on unit circle
|
|
19
|
+
const endX = Math.cos(radians - Math.PI / 2);
|
|
20
|
+
const endY = Math.sin(radians - Math.PI / 2);
|
|
21
|
+
|
|
22
|
+
// Normalize to 0-1 range
|
|
23
|
+
const start = {
|
|
24
|
+
x: (1 - endX) / 2,
|
|
25
|
+
y: (1 - endY) / 2
|
|
26
|
+
};
|
|
27
|
+
const end = {
|
|
28
|
+
x: (1 + endX) / 2,
|
|
29
|
+
y: (1 + endY) / 2
|
|
30
|
+
};
|
|
31
|
+
return {
|
|
32
|
+
start,
|
|
33
|
+
end
|
|
34
|
+
};
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* Creates a gradient configuration for use with expo-linear-gradient
|
|
39
|
+
* Returns gradient colors and coordinates based on theme gradient settings
|
|
40
|
+
*/
|
|
41
|
+
function gradient(theme) {
|
|
42
|
+
return payload => {
|
|
43
|
+
const merged = {
|
|
44
|
+
from: payload?.from || theme.defaultGradient?.from || theme.primaryColor,
|
|
45
|
+
to: payload?.to || theme.defaultGradient?.to || theme.primaryColor,
|
|
46
|
+
deg: payload?.deg ?? theme.defaultGradient?.deg ?? 45
|
|
47
|
+
};
|
|
48
|
+
const primaryShade = (0, _primaryShade.getPrimaryShade)(theme);
|
|
49
|
+
const fromColor = (0, _themeColor.themeColor)({
|
|
50
|
+
theme,
|
|
51
|
+
color: merged.from,
|
|
52
|
+
shade: primaryShade
|
|
53
|
+
});
|
|
54
|
+
const toColor = (0, _themeColor.themeColor)({
|
|
55
|
+
theme,
|
|
56
|
+
color: merged.to,
|
|
57
|
+
shade: primaryShade
|
|
58
|
+
});
|
|
59
|
+
const {
|
|
60
|
+
start,
|
|
61
|
+
end
|
|
62
|
+
} = degToCoordinates(merged.deg);
|
|
63
|
+
return {
|
|
64
|
+
colors: [fromColor, toColor],
|
|
65
|
+
start,
|
|
66
|
+
end
|
|
67
|
+
};
|
|
68
|
+
};
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* Legacy function for web compatibility - returns CSS gradient string
|
|
73
|
+
* Not used in React Native but kept for API compatibility
|
|
74
|
+
*/
|
|
75
|
+
function linearGradientCSS(deg, ...colors) {
|
|
76
|
+
return `linear-gradient(${deg}deg, ${colors.join(', ')})`;
|
|
77
|
+
}
|
|
78
|
+
//# sourceMappingURL=gradient.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_themeColor","require","_primaryShade","degToCoordinates","deg","angle","radians","Math","PI","endX","cos","endY","sin","start","x","y","end","gradient","theme","payload","merged","from","defaultGradient","primaryColor","to","primaryShade","getPrimaryShade","fromColor","themeColor","color","shade","toColor","colors","linearGradientCSS","join"],"sourceRoot":"../../../../../../src","sources":["theme/functions/fns/gradient/gradient.ts"],"mappings":";;;;;;;AAEA,IAAAA,WAAA,GAAAC,OAAA;AACA,IAAAC,aAAA,GAAAD,OAAA;AAEA;AACA;AACA;AACA;AACA,SAASE,gBAAgBA,CAACC,GAAW,EAAsE;EACzG,MAAMC,KAAK,GAAG,CAAED,GAAG,GAAG,GAAG,GAAI,GAAG,IAAI,GAAG,CAAC,CAAC;EACzC,MAAME,OAAO,GAAID,KAAK,GAAGE,IAAI,CAACC,EAAE,GAAI,GAAG;;EAEvC;EACA,MAAMC,IAAI,GAAGF,IAAI,CAACG,GAAG,CAACJ,OAAO,GAAGC,IAAI,CAACC,EAAE,GAAG,CAAC,CAAC;EAC5C,MAAMG,IAAI,GAAGJ,IAAI,CAACK,GAAG,CAACN,OAAO,GAAGC,IAAI,CAACC,EAAE,GAAG,CAAC,CAAC;;EAE5C;EACA,MAAMK,KAAK,GAAG;IACZC,CAAC,EAAE,CAAC,CAAC,GAAGL,IAAI,IAAI,CAAC;IACjBM,CAAC,EAAE,CAAC,CAAC,GAAGJ,IAAI,IAAI;EAClB,CAAC;EACD,MAAMK,GAAG,GAAG;IACVF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4B,MAAM,CAACE,IAAI,CAAC,IAAI,CAAC,GAAG;AAC3D","ignoreList":[]}
|
|
@@ -10,12 +10,11 @@ const fontStyles = theme => () => ({
|
|
|
10
10
|
|
|
11
11
|
/**
|
|
12
12
|
* Returns font styles specifically for input components
|
|
13
|
-
* Uses fontFamilyInput if available, otherwise falls back to fontFamily
|
|
14
13
|
*/
|
|
15
14
|
exports.fontStyles = fontStyles;
|
|
16
15
|
const inputFontStyles = theme => () => {
|
|
17
16
|
return {
|
|
18
|
-
fontFamily: theme.
|
|
17
|
+
fontFamily: theme.fontFamily
|
|
19
18
|
};
|
|
20
19
|
};
|
|
21
20
|
exports.inputFontStyles = inputFontStyles;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["fontStyles","theme","fontFamily","exports","inputFontStyles","
|
|
1
|
+
{"version":3,"names":["fontStyles","theme","fontFamily","exports","inputFontStyles","focusStyles","_theme","placeholderStyles","opacity","cover","offset","position","top","right","bottom","left","hover","styles","activeStyles","transform","scale"],"sourceRoot":"../../../../../src","sources":["theme/functions/fns/helpers.ts"],"mappings":";;;;;;AAEO,MAAMA,UAAU,GAAIC,KAAmB,IAAK,OAAO;EACxDC,UAAU,EAAED,KAAK,CAACC;AACpB,CAAC,CAAC;;AAEF;AACA;AACA;AAFAC,OAAA,CAAAH,UAAA,GAAAA,UAAA;AAGO,MAAMI,eAAe,GAAIH,KAAmB,IAAK,MAAM;EAC5D,OAAO;IACLC,UAAU,EAAED,KAAK,CAACC;EACpB,CAAC;AACH,CAAC;AAACC,OAAA,CAAAC,eAAA,GAAAA,eAAA;AAEK,MAAMC,WAAW,GAAIC,MAAoB,IAAK,OAAO;EAC1D;EACA;EACA;AAAA,CACD,CAAC;AAACH,OAAA,CAAAE,WAAA,GAAAA,WAAA;AAEI,MAAME,iBAAiB,GAAID,MAAoB,IAAK,OAAO;EAChE;EACAE,OAAO,EAAE;AACX,CAAC,CAAC;AAACL,OAAA,CAAAI,iBAAA,GAAAA,iBAAA;AAEI,MAAME,KAAK,GACfH,MAAoB,IACrB,CAACI,MAAc,GAAG,CAAC,MAAM;EACvBC,QAAQ,EAAE,UAAmB;EAC7BC,GAAG,EAAEF,MAAM;EACXG,KAAK,EAAEH,MAAM;EACbI,MAAM,EAAEJ,MAAM;EACdK,IAAI,EAAEL;AACR,CAAC,CAAC;AAACP,OAAA,CAAAM,KAAA,GAAAA,KAAA;AAEE,MAAMO,KAAK,GAAIV,MAAoB,IAAMW,MAAW,KAAM;EAC/D;EACA;EACA,GAAGA;AACL,CAAC,CAAC;AAACd,OAAA,CAAAa,KAAA,GAAAA,KAAA;AAEI,MAAME,YAAY,GAAIZ,MAAoB,KAAM;EACrD;EACAE,OAAO,EAAE,GAAG;EACZW,SAAS,EAAE,CAAC;IAAEC,KAAK,EAAE;EAAK,CAAC;AAC7B,CAAC,CAAC;AAACjB,OAAA,CAAAe,YAAA,GAAAA,YAAA","ignoreList":[]}
|
|
@@ -9,6 +9,13 @@ var _rgba = require("./rgba.js");
|
|
|
9
9
|
var _size = require("./size.js");
|
|
10
10
|
var _themeColor = require("./theme-color/theme-color.js");
|
|
11
11
|
var _variant = require("./variant.js");
|
|
12
|
+
var _primaryShade = require("./primary-shade.js");
|
|
13
|
+
var _shadow = require("./shadow.js");
|
|
14
|
+
var _gradient = require("./gradient/gradient.js");
|
|
15
|
+
var _lighten = require("./lighten.js");
|
|
16
|
+
var _darken = require("./darken.js");
|
|
17
|
+
var _dimmed = require("./dimmed.js");
|
|
18
|
+
var _breakpoints = require("./breakpoints.js");
|
|
12
19
|
var helpers = _interopRequireWildcard(require("./helpers.js"));
|
|
13
20
|
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
|
|
14
21
|
const fns = exports.fns = {
|
|
@@ -17,6 +24,14 @@ const fns = exports.fns = {
|
|
|
17
24
|
size: _size.size,
|
|
18
25
|
variant: _variant.variant,
|
|
19
26
|
themeColor: _themeColor.themeColor,
|
|
27
|
+
getPrimaryShade: _primaryShade.getPrimaryShade,
|
|
28
|
+
shadow: _shadow.shadow,
|
|
29
|
+
gradient: _gradient.gradient,
|
|
30
|
+
lighten: _lighten.lighten,
|
|
31
|
+
darken: _darken.darken,
|
|
32
|
+
dimmed: _dimmed.dimmed,
|
|
33
|
+
largerThan: _breakpoints.largerThan,
|
|
34
|
+
smallerThan: _breakpoints.smallerThan,
|
|
20
35
|
...helpers
|
|
21
36
|
};
|
|
22
37
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_radius","require","_rgba","_size","_themeColor","_variant","helpers","_interopRequireWildcard","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","fns","exports","radius","rgba","size","variant","themeColor"],"sourceRoot":"../../../../../src","sources":["theme/functions/fns/index.ts"],"mappings":";;;;;;AAAA,IAAAA,OAAA,GAAAC,OAAA;AACA,IAAAC,KAAA,GAAAD,OAAA;AACA,IAAAE,KAAA,GAAAF,OAAA;AACA,IAAAG,WAAA,GAAAH,OAAA;AACA,IAAAI,QAAA,GAAAJ,OAAA;AACA,IAAAK,OAAA,GAAAC,uBAAA,
|
|
1
|
+
{"version":3,"names":["_radius","require","_rgba","_size","_themeColor","_variant","_primaryShade","_shadow","_gradient","_lighten","_darken","_dimmed","_breakpoints","helpers","_interopRequireWildcard","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","fns","exports","radius","rgba","size","variant","themeColor","getPrimaryShade","shadow","gradient","lighten","darken","dimmed","largerThan","smallerThan"],"sourceRoot":"../../../../../src","sources":["theme/functions/fns/index.ts"],"mappings":";;;;;;AAAA,IAAAA,OAAA,GAAAC,OAAA;AACA,IAAAC,KAAA,GAAAD,OAAA;AACA,IAAAE,KAAA,GAAAF,OAAA;AACA,IAAAG,WAAA,GAAAH,OAAA;AACA,IAAAI,QAAA,GAAAJ,OAAA;AACA,IAAAK,aAAA,GAAAL,OAAA;AACA,IAAAM,OAAA,GAAAN,OAAA;AACA,IAAAO,SAAA,GAAAP,OAAA;AACA,IAAAQ,QAAA,GAAAR,OAAA;AACA,IAAAS,OAAA,GAAAT,OAAA;AACA,IAAAU,OAAA,GAAAV,OAAA;AACA,IAAAW,YAAA,GAAAX,OAAA;AACA,IAAAY,OAAA,GAAAC,uBAAA,CAAAb,OAAA;AAAqC,SAAAa,wBAAAC,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAH,uBAAA,YAAAA,CAAAC,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CAAA,GAAAD,CAAA,QAAAG,CAAA,CAAAK,GAAA,CAAAX,CAAA,UAAAM,CAAA,CAAAM,GAAA,CAAAZ,CAAA,GAAAM,CAAA,CAAAO,GAAA,CAAAb,CAAA,EAAAQ,CAAA,gBAAAP,CAAA,IAAAD,CAAA,gBAAAC,CAAA,OAAAa,cAAA,CAAAC,IAAA,CAAAf,CAAA,EAAAC,CAAA,OAAAM,CAAA,IAAAD,CAAA,GAAAU,MAAA,CAAAC,cAAA,KAAAD,MAAA,CAAAE,wBAAA,CAAAlB,CAAA,EAAAC,CAAA,OAAAM,CAAA,CAAAK,GAAA,IAAAL,CAAA,CAAAM,GAAA,IAAAP,CAAA,CAAAE,CAAA,EAAAP,CAAA,EAAAM,CAAA,IAAAC,CAAA,CAAAP,CAAA,IAAAD,CAAA,CAAAC,CAAA,WAAAO,CAAA,KAAAR,CAAA,EAAAC,CAAA;AAE9B,MAAMkB,GAAG,GAAAC,OAAA,CAAAD,GAAA,GAAG;EACjBE,MAAM,EAANA,cAAM;EACNC,IAAI,EAAJA,UAAI;EACJC,IAAI,EAAJA,UAAI;EACJC,OAAO,EAAPA,gBAAO;EACPC,UAAU,EAAVA,sBAAU;EACVC,eAAe,EAAfA,6BAAe;EACfC,MAAM,EAANA,cAAM;EACNC,QAAQ,EAARA,kBAAQ;EACRC,OAAO,EAAPA,gBAAO;EACPC,MAAM,EAANA,cAAM;EACNC,MAAM,EAANA,cAAM;EACNC,UAAU,EAAVA,uBAAU;EACVC,WAAW,EAAXA,wBAAW;EACX,GAAGnC;AACL,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.lighten = lighten;
|
|
7
|
+
var _toRgba = require("../../utils/to-rgba.js");
|
|
8
|
+
/**
|
|
9
|
+
* Lightens a color by mixing it with white
|
|
10
|
+
* @param color - The color to lighten (hex or rgb/rgba string)
|
|
11
|
+
* @param alpha - The amount to lighten (0-1, where 1 is completely white)
|
|
12
|
+
* @returns rgba color string
|
|
13
|
+
*/
|
|
14
|
+
function lighten(color, alpha) {
|
|
15
|
+
const {
|
|
16
|
+
r,
|
|
17
|
+
g,
|
|
18
|
+
b,
|
|
19
|
+
a
|
|
20
|
+
} = (0, _toRgba.toRgba)(color);
|
|
21
|
+
const light = input => Math.round(input + (255 - input) * alpha);
|
|
22
|
+
return `rgba(${light(r)}, ${light(g)}, ${light(b)}, ${a})`;
|
|
23
|
+
}
|
|
24
|
+
//# sourceMappingURL=lighten.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_toRgba","require","lighten","color","alpha","r","g","b","a","toRgba","light","input","Math","round"],"sourceRoot":"../../../../../src","sources":["theme/functions/fns/lighten.ts"],"mappings":";;;;;;AAAA,IAAAA,OAAA,GAAAC,OAAA;AAEA;AACA;AACA;AACA;AACA;AACA;AACO,SAASC,OAAOA,CAACC,KAAa,EAAEC,KAAa,EAAU;EAC5D,MAAM;IAAEC,CAAC;IAAEC,CAAC;IAAEC,CAAC;IAAEC;EAAE,CAAC,GAAG,IAAAC,cAAM,EAACN,KAAK,CAAC;EAEpC,MAAMO,KAAK,GAAIC,KAAa,IAAKC,IAAI,CAACC,KAAK,CAACF,KAAK,GAAG,CAAC,GAAG,GAAGA,KAAK,IAAIP,KAAK,CAAC;EAE1E,OAAO,QAAQM,KAAK,CAACL,CAAC,CAAC,KAAKK,KAAK,CAACJ,CAAC,CAAC,KAAKI,KAAK,CAACH,CAAC,CAAC,KAAKC,CAAC,GAAG;AAC5D","ignoreList":[]}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.getPrimaryShade = getPrimaryShade;
|
|
7
|
+
/**
|
|
8
|
+
* Returns the appropriate primary shade based on the current color scheme
|
|
9
|
+
* Matches Mantine web implementation
|
|
10
|
+
*/
|
|
11
|
+
function getPrimaryShade(theme, colorScheme) {
|
|
12
|
+
if (typeof theme.primaryShade === 'number') {
|
|
13
|
+
return theme.primaryShade;
|
|
14
|
+
}
|
|
15
|
+
const scheme = colorScheme || theme.currentMode || 'light';
|
|
16
|
+
return theme.primaryShade[scheme];
|
|
17
|
+
}
|
|
18
|
+
//# sourceMappingURL=primary-shade.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["getPrimaryShade","theme","colorScheme","primaryShade","scheme","currentMode"],"sourceRoot":"../../../../../src","sources":["theme/functions/fns/primary-shade.ts"],"mappings":";;;;;;AAEA;AACA;AACA;AACA;AACO,SAASA,eAAeA,CAC7BC,KAAmB,EACnBC,WAA8B,EACtB;EACR,IAAI,OAAOD,KAAK,CAACE,YAAY,KAAK,QAAQ,EAAE;IAC1C,OAAOF,KAAK,CAACE,YAAY;EAC3B;EAEA,MAAMC,MAAM,GAAGF,WAAW,IAAID,KAAK,CAACI,WAAW,IAAI,OAAO;EAC1D,OAAOJ,KAAK,CAACE,YAAY,CAACC,MAAM,CAAC;AACnC","ignoreList":[]}
|