@tamagui/web 1.138.5 → 1.139.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/helpers/getSplitStyles.cjs +32 -19
- package/dist/cjs/helpers/getSplitStyles.js +57 -19
- package/dist/cjs/helpers/getSplitStyles.js.map +2 -2
- package/dist/cjs/helpers/getSplitStyles.native.js +31 -19
- package/dist/cjs/helpers/getSplitStyles.native.js.map +1 -1
- package/dist/cjs/helpers/nativeOnlyProps.cjs +55 -0
- package/dist/cjs/helpers/nativeOnlyProps.js +50 -0
- package/dist/cjs/helpers/nativeOnlyProps.js.map +6 -0
- package/dist/cjs/helpers/nativeOnlyProps.native.js +58 -0
- package/dist/cjs/helpers/nativeOnlyProps.native.js.map +1 -0
- package/dist/cjs/helpers/propMapper.cjs +6 -4
- package/dist/cjs/helpers/propMapper.js +6 -4
- package/dist/cjs/helpers/propMapper.js.map +1 -1
- package/dist/cjs/helpers/propMapper.native.js +9 -4
- package/dist/cjs/helpers/propMapper.native.js.map +1 -1
- package/dist/cjs/interfaces/TamaguiComponentPropsBaseBase.cjs +16 -0
- package/dist/cjs/interfaces/TamaguiComponentPropsBaseBase.js +14 -0
- package/dist/cjs/interfaces/TamaguiComponentPropsBaseBase.js.map +6 -0
- package/dist/cjs/interfaces/TamaguiComponentPropsBaseBase.native.js +19 -0
- package/dist/cjs/interfaces/TamaguiComponentPropsBaseBase.native.js.map +1 -0
- package/dist/esm/helpers/getSplitStyles.js +57 -19
- package/dist/esm/helpers/getSplitStyles.js.map +2 -2
- package/dist/esm/helpers/getSplitStyles.mjs +32 -20
- package/dist/esm/helpers/getSplitStyles.mjs.map +1 -1
- package/dist/esm/helpers/getSplitStyles.native.js +31 -20
- package/dist/esm/helpers/getSplitStyles.native.js.map +1 -1
- package/dist/esm/helpers/nativeOnlyProps.js +34 -0
- package/dist/esm/helpers/nativeOnlyProps.js.map +6 -0
- package/dist/esm/helpers/nativeOnlyProps.mjs +32 -0
- package/dist/esm/helpers/nativeOnlyProps.mjs.map +1 -0
- package/dist/esm/helpers/nativeOnlyProps.native.js +32 -0
- package/dist/esm/helpers/nativeOnlyProps.native.js.map +1 -0
- package/dist/esm/helpers/propMapper.js +6 -4
- package/dist/esm/helpers/propMapper.js.map +1 -1
- package/dist/esm/helpers/propMapper.mjs +6 -4
- package/dist/esm/helpers/propMapper.mjs.map +1 -1
- package/dist/esm/helpers/propMapper.native.js +9 -4
- package/dist/esm/helpers/propMapper.native.js.map +1 -1
- package/dist/esm/interfaces/TamaguiComponentPropsBaseBase.js +1 -0
- package/dist/esm/interfaces/TamaguiComponentPropsBaseBase.js.map +6 -0
- package/dist/esm/interfaces/TamaguiComponentPropsBaseBase.mjs +2 -0
- package/dist/esm/interfaces/TamaguiComponentPropsBaseBase.mjs.map +1 -0
- package/dist/esm/interfaces/TamaguiComponentPropsBaseBase.native.js +2 -0
- package/dist/esm/interfaces/TamaguiComponentPropsBaseBase.native.js.map +1 -0
- package/package.json +12 -12
- package/src/helpers/getSplitStyles.tsx +72 -15
- package/src/helpers/propMapper.ts +11 -6
- package/src/types.tsx +4 -1
- package/types/helpers/getSplitStyles.d.ts +1 -0
- package/types/helpers/getSplitStyles.d.ts.map +1 -1
- package/types/helpers/nativeOnlyProps.d.ts.map +1 -0
- package/types/helpers/propMapper.d.ts.map +1 -1
- package/types/interfaces/TamaguiComponentPropsBaseBase.d.ts.map +1 -0
- package/types/types.d.ts +2 -1
- package/types/types.d.ts.map +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tamagui/web",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.139.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"source": "src/index.ts",
|
|
6
6
|
"main": "dist/cjs",
|
|
@@ -28,16 +28,16 @@
|
|
|
28
28
|
"reset.css"
|
|
29
29
|
],
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@tamagui/compose-refs": "1.
|
|
32
|
-
"@tamagui/constants": "1.
|
|
33
|
-
"@tamagui/helpers": "1.
|
|
34
|
-
"@tamagui/is-equal-shallow": "1.
|
|
35
|
-
"@tamagui/normalize-css-color": "1.
|
|
36
|
-
"@tamagui/timer": "1.
|
|
37
|
-
"@tamagui/types": "1.
|
|
38
|
-
"@tamagui/use-did-finish-ssr": "1.
|
|
39
|
-
"@tamagui/use-event": "1.
|
|
40
|
-
"@tamagui/use-force-update": "1.
|
|
31
|
+
"@tamagui/compose-refs": "1.139.0",
|
|
32
|
+
"@tamagui/constants": "1.139.0",
|
|
33
|
+
"@tamagui/helpers": "1.139.0",
|
|
34
|
+
"@tamagui/is-equal-shallow": "1.139.0",
|
|
35
|
+
"@tamagui/normalize-css-color": "1.139.0",
|
|
36
|
+
"@tamagui/timer": "1.139.0",
|
|
37
|
+
"@tamagui/types": "1.139.0",
|
|
38
|
+
"@tamagui/use-did-finish-ssr": "1.139.0",
|
|
39
|
+
"@tamagui/use-event": "1.139.0",
|
|
40
|
+
"@tamagui/use-force-update": "1.139.0"
|
|
41
41
|
},
|
|
42
42
|
"peerDependencies": {
|
|
43
43
|
"react": "*",
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
"react-native": "*"
|
|
46
46
|
},
|
|
47
47
|
"devDependencies": {
|
|
48
|
-
"@tamagui/build": "1.
|
|
48
|
+
"@tamagui/build": "1.139.0",
|
|
49
49
|
"@testing-library/react": "^16.1.0",
|
|
50
50
|
"csstype": "^3.0.10",
|
|
51
51
|
"react": "*",
|
|
@@ -78,6 +78,11 @@ export type SplitStyleResult = ReturnType<typeof getSplitStyles>
|
|
|
78
78
|
|
|
79
79
|
let conf: TamaguiInternalConfig
|
|
80
80
|
|
|
81
|
+
// WeakMap to track original token values for style objects
|
|
82
|
+
// Used to preserve '$8' style tokens instead of resolved 'var(--t-space-8)'
|
|
83
|
+
// for context prop propagation to children (issues #3670, #3676)
|
|
84
|
+
export const styleOriginalValues = new WeakMap<object, Record<string, any>>()
|
|
85
|
+
|
|
81
86
|
type StyleSplitter = (
|
|
82
87
|
props: { [key: string]: any },
|
|
83
88
|
staticConfig: StaticConfig,
|
|
@@ -619,7 +624,7 @@ export const getSplitStyles: StyleSplitter = (
|
|
|
619
624
|
|
|
620
625
|
const disablePropMap = isMediaOrPseudo || !isStyleLikeKey
|
|
621
626
|
|
|
622
|
-
propMapper(keyInit, valInit, styleState, disablePropMap, (key, val) => {
|
|
627
|
+
propMapper(keyInit, valInit, styleState, disablePropMap, (key, val, originalVal) => {
|
|
623
628
|
const isStyledContextProp = styledContext && key in styledContext
|
|
624
629
|
|
|
625
630
|
if (!isHOC && disablePropMap && !isStyledContextProp && !isMediaOrPseudo) {
|
|
@@ -646,7 +651,7 @@ export const getSplitStyles: StyleSplitter = (
|
|
|
646
651
|
(!isHOC && isValidStyleKey(key, validStyles, accept)) ||
|
|
647
652
|
(process.env.TAMAGUI_TARGET === 'native' && isAndroid && key === 'elevation')
|
|
648
653
|
) {
|
|
649
|
-
mergeStyle(styleState, key, val, 1)
|
|
654
|
+
mergeStyle(styleState, key, val, 1, false, originalVal)
|
|
650
655
|
return
|
|
651
656
|
}
|
|
652
657
|
|
|
@@ -755,6 +760,7 @@ export const getSplitStyles: StyleSplitter = (
|
|
|
755
760
|
|
|
756
761
|
const importance = descriptor.priority
|
|
757
762
|
|
|
763
|
+
const pseudoOriginalValues = styleOriginalValues.get(pseudoStyleObject)
|
|
758
764
|
for (const pkey in pseudoStyleObject) {
|
|
759
765
|
const val = pseudoStyleObject[pkey]
|
|
760
766
|
// when disabled ensure the default value is set for future animations to align
|
|
@@ -771,7 +777,14 @@ export const getSplitStyles: StyleSplitter = (
|
|
|
771
777
|
pseudos[key] ||= {}
|
|
772
778
|
pseudos[key][pkey] = val
|
|
773
779
|
}
|
|
774
|
-
mergeStyle(
|
|
780
|
+
mergeStyle(
|
|
781
|
+
styleState,
|
|
782
|
+
pkey,
|
|
783
|
+
val,
|
|
784
|
+
importance,
|
|
785
|
+
false,
|
|
786
|
+
pseudoOriginalValues?.[pkey]
|
|
787
|
+
)
|
|
775
788
|
}
|
|
776
789
|
|
|
777
790
|
if (process.env.NODE_ENV === 'development' && debug === 'verbose') {
|
|
@@ -933,6 +946,7 @@ export const getSplitStyles: StyleSplitter = (
|
|
|
933
946
|
styleState.style ||= {}
|
|
934
947
|
const scheme = mediaKeyShort
|
|
935
948
|
const oppositeScheme = getOppositeScheme(mediaKeyShort)
|
|
949
|
+
const themeOriginalValues = styleOriginalValues.get(mediaStyle)
|
|
936
950
|
|
|
937
951
|
for (const subKey in mediaStyle) {
|
|
938
952
|
let val = extractValueFromDynamic(mediaStyle[subKey], scheme)
|
|
@@ -946,7 +960,14 @@ export const getSplitStyles: StyleSplitter = (
|
|
|
946
960
|
val,
|
|
947
961
|
oppositeVal,
|
|
948
962
|
})
|
|
949
|
-
mergeStyle(
|
|
963
|
+
mergeStyle(
|
|
964
|
+
styleState,
|
|
965
|
+
subKey,
|
|
966
|
+
mediaStyle[subKey],
|
|
967
|
+
priority,
|
|
968
|
+
false,
|
|
969
|
+
themeOriginalValues?.[subKey]
|
|
970
|
+
)
|
|
950
971
|
}
|
|
951
972
|
} else if (
|
|
952
973
|
!(themeName === mediaKeyShort || themeName.startsWith(mediaKeyShort))
|
|
@@ -1034,7 +1055,9 @@ export const getSplitStyles: StyleSplitter = (
|
|
|
1034
1055
|
}
|
|
1035
1056
|
}
|
|
1036
1057
|
|
|
1037
|
-
|
|
1058
|
+
const mediaOriginalValues = styleOriginalValues.get(mediaStyle)
|
|
1059
|
+
|
|
1060
|
+
function mergeMediaStyle(key: string, val: any, originalVal?: any) {
|
|
1038
1061
|
styleState.style ||= {}
|
|
1039
1062
|
const didMerge = mergeMediaByImportance(
|
|
1040
1063
|
styleState,
|
|
@@ -1043,7 +1066,8 @@ export const getSplitStyles: StyleSplitter = (
|
|
|
1043
1066
|
val,
|
|
1044
1067
|
mediaState[mediaKeyShort],
|
|
1045
1068
|
importanceBump,
|
|
1046
|
-
debug
|
|
1069
|
+
debug,
|
|
1070
|
+
originalVal
|
|
1047
1071
|
)
|
|
1048
1072
|
if (didMerge && key === 'fontFamily') {
|
|
1049
1073
|
styleState.fontFamily = mediaStyle.fontFamily as string
|
|
@@ -1058,11 +1082,18 @@ export const getSplitStyles: StyleSplitter = (
|
|
|
1058
1082
|
if (subKey[0] === '$') {
|
|
1059
1083
|
if (!isActivePlatform(subKey)) continue
|
|
1060
1084
|
if (!isActiveTheme(subKey, themeName)) continue
|
|
1085
|
+
const subOriginalValues = styleOriginalValues.get(
|
|
1086
|
+
mediaStyle[subKey] as object
|
|
1087
|
+
)
|
|
1061
1088
|
for (const subSubKey in mediaStyle[subKey]) {
|
|
1062
|
-
mergeMediaStyle(
|
|
1089
|
+
mergeMediaStyle(
|
|
1090
|
+
subSubKey,
|
|
1091
|
+
mediaStyle[subKey][subSubKey],
|
|
1092
|
+
subOriginalValues?.[subSubKey]
|
|
1093
|
+
)
|
|
1063
1094
|
}
|
|
1064
1095
|
} else {
|
|
1065
|
-
mergeMediaStyle(subKey, mediaStyle[subKey])
|
|
1096
|
+
mergeMediaStyle(subKey, mediaStyle[subKey], mediaOriginalValues?.[subKey])
|
|
1066
1097
|
}
|
|
1067
1098
|
}
|
|
1068
1099
|
}
|
|
@@ -1447,7 +1478,8 @@ function mergeStyle(
|
|
|
1447
1478
|
key: string,
|
|
1448
1479
|
val: any,
|
|
1449
1480
|
importance: number,
|
|
1450
|
-
disableNormalize = false
|
|
1481
|
+
disableNormalize = false,
|
|
1482
|
+
originalVal?: any
|
|
1451
1483
|
) {
|
|
1452
1484
|
const { viewProps, styleProps, staticConfig, usedKeys } = styleState
|
|
1453
1485
|
|
|
@@ -1458,12 +1490,16 @@ function mergeStyle(
|
|
|
1458
1490
|
|
|
1459
1491
|
// Track context overrides for pseudo/media styles (issues #3670, #3676)
|
|
1460
1492
|
// When a style sets a key that's in context props, update overriddenContextProps
|
|
1461
|
-
// so it propagates to children.
|
|
1493
|
+
// so it propagates to children. Use the original token value (like '$8')
|
|
1494
|
+
// instead of the resolved CSS variable (like 'var(--t-space-8)')
|
|
1495
|
+
// so children's functional variants can look up token values.
|
|
1462
1496
|
const contextProps =
|
|
1463
1497
|
staticConfig.context?.props || staticConfig.parentStaticConfig?.context?.props
|
|
1464
1498
|
if (contextProps && key in contextProps) {
|
|
1465
1499
|
styleState.overriddenContextProps ||= {}
|
|
1466
|
-
|
|
1500
|
+
// Priority: 1) originalVal from propMapper, 2) tracked original from variant resolution, 3) val
|
|
1501
|
+
const originalFromState = styleState.originalContextPropValues?.[key]
|
|
1502
|
+
styleState.overriddenContextProps[key] = originalVal ?? originalFromState ?? val
|
|
1467
1503
|
}
|
|
1468
1504
|
|
|
1469
1505
|
if (key in stylePropsTransform) {
|
|
@@ -1498,6 +1534,7 @@ export const getSubStyle = (
|
|
|
1498
1534
|
): TextStyle => {
|
|
1499
1535
|
const { staticConfig, conf, styleProps } = styleState
|
|
1500
1536
|
const styleOut: TextStyle = {}
|
|
1537
|
+
let originalValues: Record<string, any> | undefined
|
|
1501
1538
|
|
|
1502
1539
|
for (let key in styleIn) {
|
|
1503
1540
|
const val = styleIn[key]
|
|
@@ -1508,7 +1545,12 @@ export const getSubStyle = (
|
|
|
1508
1545
|
continue
|
|
1509
1546
|
}
|
|
1510
1547
|
|
|
1511
|
-
propMapper(key, val, styleState, false, (skey, sval) => {
|
|
1548
|
+
propMapper(key, val, styleState, false, (skey, sval, originalVal) => {
|
|
1549
|
+
// Track original values for context prop propagation
|
|
1550
|
+
if (originalVal !== undefined) {
|
|
1551
|
+
originalValues ||= {}
|
|
1552
|
+
originalValues[skey] = originalVal
|
|
1553
|
+
}
|
|
1512
1554
|
// pseudo inside media
|
|
1513
1555
|
if (skey in validPseudoKeys) {
|
|
1514
1556
|
sval = getSubStyle(styleState, skey, sval, avoidMergeTransform)
|
|
@@ -1539,6 +1581,11 @@ export const getSubStyle = (
|
|
|
1539
1581
|
fixStyles(styleOut)
|
|
1540
1582
|
}
|
|
1541
1583
|
|
|
1584
|
+
// Store original values in WeakMap instead of on the object itself
|
|
1585
|
+
if (originalValues) {
|
|
1586
|
+
styleOriginalValues.set(styleOut, originalValues)
|
|
1587
|
+
}
|
|
1588
|
+
|
|
1542
1589
|
return styleOut
|
|
1543
1590
|
}
|
|
1544
1591
|
|
|
@@ -1644,7 +1691,8 @@ function mergeMediaByImportance(
|
|
|
1644
1691
|
value: any,
|
|
1645
1692
|
isSizeMedia: boolean,
|
|
1646
1693
|
importanceBump?: number,
|
|
1647
|
-
debugProp?: DebugProp
|
|
1694
|
+
debugProp?: DebugProp,
|
|
1695
|
+
originalVal?: any
|
|
1648
1696
|
) {
|
|
1649
1697
|
const usedKeys = styleState.usedKeys
|
|
1650
1698
|
let importance = getMediaImportanceIfMoreImportant(
|
|
@@ -1671,11 +1719,20 @@ function mergeMediaByImportance(
|
|
|
1671
1719
|
if (isDisabled) {
|
|
1672
1720
|
return false
|
|
1673
1721
|
}
|
|
1722
|
+
// For pseudo inside media, value is an object with subkeys
|
|
1723
|
+
const pseudoOriginalValues = styleOriginalValues.get(value as object)
|
|
1674
1724
|
for (const subKey in value) {
|
|
1675
|
-
mergeStyle(
|
|
1725
|
+
mergeStyle(
|
|
1726
|
+
styleState,
|
|
1727
|
+
subKey,
|
|
1728
|
+
value[subKey],
|
|
1729
|
+
importance,
|
|
1730
|
+
false,
|
|
1731
|
+
pseudoOriginalValues?.[subKey]
|
|
1732
|
+
)
|
|
1676
1733
|
}
|
|
1677
1734
|
} else {
|
|
1678
|
-
mergeStyle(styleState, key, value, importance)
|
|
1735
|
+
mergeStyle(styleState, key, value, importance, false, originalVal)
|
|
1679
1736
|
}
|
|
1680
1737
|
|
|
1681
1738
|
return true
|
|
@@ -62,6 +62,9 @@ export const propMapper: PropMapper = (key, value, styleState, disabled, map) =>
|
|
|
62
62
|
}
|
|
63
63
|
}
|
|
64
64
|
|
|
65
|
+
// Capture original value before resolution (for context prop tracking)
|
|
66
|
+
const originalValue = value
|
|
67
|
+
|
|
65
68
|
if (value != null) {
|
|
66
69
|
if (value[0] === '$') {
|
|
67
70
|
value = getTokenForKey(key, value, styleProps, styleState)
|
|
@@ -81,10 +84,10 @@ export const propMapper: PropMapper = (key, value, styleState, disabled, map) =>
|
|
|
81
84
|
const max = expanded.length
|
|
82
85
|
for (let i = 0; i < max; i++) {
|
|
83
86
|
const [nkey, nvalue] = expanded[i]
|
|
84
|
-
map(nkey, nvalue)
|
|
87
|
+
map(nkey, nvalue, originalValue)
|
|
85
88
|
}
|
|
86
89
|
} else {
|
|
87
|
-
map(key, value)
|
|
90
|
+
map(key, value, originalValue)
|
|
88
91
|
}
|
|
89
92
|
}
|
|
90
93
|
}
|
|
@@ -233,15 +236,17 @@ const resolveTokensAndVariants: StyleResolver<Object> = (
|
|
|
233
236
|
}
|
|
234
237
|
|
|
235
238
|
// Track context overrides for any key that's in context props (issues #3670, #3676)
|
|
236
|
-
//
|
|
239
|
+
// Store the ORIGINAL token value (like '$8') before resolution so that
|
|
240
|
+
// children's functional variants can look up token values
|
|
237
241
|
if (staticConfig) {
|
|
238
242
|
const contextProps =
|
|
239
243
|
staticConfig.context?.props || staticConfig.parentStaticConfig?.context?.props
|
|
240
244
|
if (contextProps && subKey in contextProps) {
|
|
241
|
-
|
|
242
|
-
styleState.overriddenContextProps = {}
|
|
243
|
-
}
|
|
245
|
+
styleState.overriddenContextProps ||= {}
|
|
244
246
|
styleState.overriddenContextProps[subKey] = val
|
|
247
|
+
// Also track the original token value separately
|
|
248
|
+
styleState.originalContextPropValues ||= {}
|
|
249
|
+
styleState.originalContextPropValues[subKey] = val
|
|
245
250
|
}
|
|
246
251
|
}
|
|
247
252
|
|
package/src/types.tsx
CHANGED
|
@@ -2504,6 +2504,9 @@ export type GetStyleState = {
|
|
|
2504
2504
|
flatTransforms?: Record<string, any>
|
|
2505
2505
|
// Track style values that override context props (for issues #3670, #3676)
|
|
2506
2506
|
overriddenContextProps?: Record<string, any>
|
|
2507
|
+
// Track original token values (like '$8') before they get resolved to CSS vars
|
|
2508
|
+
// This is used to preserve token strings in overriddenContextProps
|
|
2509
|
+
originalContextPropValues?: Record<string, any>
|
|
2507
2510
|
}
|
|
2508
2511
|
|
|
2509
2512
|
export type StyleResolver<Response = PropMappedValue> = (
|
|
@@ -2519,7 +2522,7 @@ export type PropMapper = (
|
|
|
2519
2522
|
value: any,
|
|
2520
2523
|
state: GetStyleState,
|
|
2521
2524
|
disabled: boolean,
|
|
2522
|
-
map: (key: string, val: any) => void
|
|
2525
|
+
map: (key: string, val: any, originalVal?: any) => void
|
|
2523
2526
|
) => void
|
|
2524
2527
|
|
|
2525
2528
|
export type GenericVariantDefinitions = {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { AllGroupContexts, ComponentContextI, DebugProp, GetStyleResult, GetStyleState, SplitStyleProps, StaticConfig, TamaguiComponentState, TextStyle, ThemeParsed } from '../types';
|
|
2
2
|
export type SplitStyles = ReturnType<typeof getSplitStyles>;
|
|
3
3
|
export type SplitStyleResult = ReturnType<typeof getSplitStyles>;
|
|
4
|
+
export declare const styleOriginalValues: WeakMap<object, Record<string, any>>;
|
|
4
5
|
type StyleSplitter = (props: {
|
|
5
6
|
[key: string]: any;
|
|
6
7
|
}, staticConfig: StaticConfig, theme: ThemeParsed, themeName: string, componentState: TamaguiComponentState, styleProps: SplitStyleProps, parentSplitStyles?: GetStyleResult | null, context?: ComponentContextI, groupContext?: AllGroupContexts | null, elementType?: string, startedUnhydrated?: boolean, debug?: DebugProp) => null | GetStyleResult;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getSplitStyles.d.ts","sourceRoot":"","sources":["../../src/helpers/getSplitStyles.tsx"],"names":[],"mappings":"AAoCA,OAAO,KAAK,EACV,gBAAgB,EAEhB,iBAAiB,EACjB,SAAS,EACT,cAAc,EACd,aAAa,EAIb,eAAe,EACf,YAAY,EAEZ,qBAAqB,EAErB,SAAS,EACT,WAAW,EA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S,MAAM,EACf,sBAAsB,OAAO,KAC5B,SAwDF,CAAA;AAQD,eAAO,MAAM,cAAc,EAAE,aAY5B,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"nativeOnlyProps.d.ts","sourceRoot":"","sources":["../../src/helpers/nativeOnlyProps.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA6B3B,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"propMapper.d.ts","sourceRoot":"","sources":["../../src/helpers/propMapper.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EACV,aAAa,EACb,UAAU,EAEV,eAAe,EAEf,qBAAqB,EAGtB,MAAM,UAAU,CAAA;AAQjB,eAAO,MAAM,UAAU,EAAE,
|
|
1
|
+
{"version":3,"file":"propMapper.d.ts","sourceRoot":"","sources":["../../src/helpers/propMapper.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EACV,aAAa,EACb,UAAU,EAEV,eAAe,EAEf,qBAAqB,EAGtB,MAAM,UAAU,CAAA;AAQjB,eAAO,MAAM,UAAU,EAAE,UAuExB,CAAA;AAoGD,wBAAgB,+BAA+B,CAAC,KAAK,EAAE,GAAG,EAAE,IAAI,EAAE,qBAAqB,sBAkBtF;AAiKD,eAAO,MAAM,cAAc,GACzB,KAAK,MAAM,EACX,OAAO,MAAM,EACb,YAAY,eAAe,EAC3B,YAAY,OAAO,CAAC,aAAa,CAAC,QAsInC,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TamaguiComponentPropsBaseBase.d.ts","sourceRoot":"","sources":["../../src/interfaces/TamaguiComponentPropsBaseBase.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,UAAU,EAAE,IAAI,EAAE,MAAM,UAAU,CAAA;AAEtE,MAAM,MAAM,6BAA6B,GAAG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AA;CACjC,CAAA;AAED,MAAM,WAAW,MAAM;IACrB,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,KAAK,CAAC,EAAE,MAAM,CAAA;CACf"}
|
package/types/types.d.ts
CHANGED
|
@@ -1498,9 +1498,10 @@ export type GetStyleState = {
|
|
|
1498
1498
|
debug?: DebugProp;
|
|
1499
1499
|
flatTransforms?: Record<string, any>;
|
|
1500
1500
|
overriddenContextProps?: Record<string, any>;
|
|
1501
|
+
originalContextPropValues?: Record<string, any>;
|
|
1501
1502
|
};
|
|
1502
1503
|
export type StyleResolver<Response = PropMappedValue> = (key: string, value: any, props: SplitStyleProps, state: GetStyleState, parentVariantKey: string) => Response;
|
|
1503
|
-
export type PropMapper = (key: string, value: any, state: GetStyleState, disabled: boolean, map: (key: string, val: any) => void) => void;
|
|
1504
|
+
export type PropMapper = (key: string, value: any, state: GetStyleState, disabled: boolean, map: (key: string, val: any, originalVal?: any) => void) => void;
|
|
1504
1505
|
export type GenericVariantDefinitions = {
|
|
1505
1506
|
[key: string]: {
|
|
1506
1507
|
[key: string]: ((a: any, b: any) => any) | {
|