@tamagui/button 1.113.0 → 1.113.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.
@@ -8,233 +8,205 @@ import { SizableText, wrapChildrenInText } from "@tamagui/text";
8
8
  import { createStyledContext, getVariableValue, spacedChildren, styled, useProps } from "@tamagui/web";
9
9
  import { useContext } from "react";
10
10
  var ButtonContext = createStyledContext({
11
- // keeping these here means they work with styled() passing down color to text
12
- color: void 0,
13
- ellipse: void 0,
14
- fontFamily: void 0,
15
- fontSize: void 0,
16
- fontStyle: void 0,
17
- fontWeight: void 0,
18
- letterSpacing: void 0,
19
- maxFontSizeMultiplier: void 0,
20
- size: void 0,
21
- textAlign: void 0,
22
- variant: void 0
23
- }),
24
- BUTTON_NAME = "Button",
25
- ButtonFrame = styled(ThemeableStack, {
26
- name: BUTTON_NAME,
27
- tag: "button",
28
- context: ButtonContext,
29
- role: "button",
30
- focusable: !0,
31
- variants: {
32
- unstyled: {
33
- false: {
34
- size: "$true",
35
- justifyContent: "center",
36
- alignItems: "center",
37
- flexWrap: "nowrap",
38
- flexDirection: "row",
39
- cursor: "pointer",
40
- hoverTheme: !0,
41
- pressTheme: !0,
42
- backgrounded: !0,
43
- borderWidth: 1,
44
- borderColor: "transparent",
45
- focusVisibleStyle: {
46
- outlineColor: "$outlineColor",
47
- outlineStyle: "solid",
48
- outlineWidth: 2
49
- }
11
+ // keeping these here means they work with styled() passing down color to text
12
+ color: void 0,
13
+ ellipse: void 0,
14
+ fontFamily: void 0,
15
+ fontSize: void 0,
16
+ fontStyle: void 0,
17
+ fontWeight: void 0,
18
+ letterSpacing: void 0,
19
+ maxFontSizeMultiplier: void 0,
20
+ size: void 0,
21
+ textAlign: void 0,
22
+ variant: void 0
23
+ }), BUTTON_NAME = "Button", ButtonFrame = styled(ThemeableStack, {
24
+ name: BUTTON_NAME,
25
+ tag: "button",
26
+ context: ButtonContext,
27
+ role: "button",
28
+ focusable: !0,
29
+ variants: {
30
+ unstyled: {
31
+ false: {
32
+ size: "$true",
33
+ justifyContent: "center",
34
+ alignItems: "center",
35
+ flexWrap: "nowrap",
36
+ flexDirection: "row",
37
+ cursor: "pointer",
38
+ hoverTheme: !0,
39
+ pressTheme: !0,
40
+ backgrounded: !0,
41
+ borderWidth: 1,
42
+ borderColor: "transparent",
43
+ focusVisibleStyle: {
44
+ outlineColor: "$outlineColor",
45
+ outlineStyle: "solid",
46
+ outlineWidth: 2
50
47
  }
51
- },
52
- variant: {
53
- outlined: {
48
+ }
49
+ },
50
+ variant: {
51
+ outlined: {
52
+ backgroundColor: "transparent",
53
+ borderWidth: 2,
54
+ borderColor: "$borderColor",
55
+ hoverStyle: {
54
56
  backgroundColor: "transparent",
55
- borderWidth: 2,
56
- borderColor: "$borderColor",
57
- hoverStyle: {
58
- backgroundColor: "transparent",
59
- borderColor: "$borderColorHover"
60
- },
61
- pressStyle: {
62
- backgroundColor: "transparent",
63
- borderColor: "$borderColorPress"
64
- },
65
- focusVisibleStyle: {
66
- backgroundColor: "transparent",
67
- borderColor: "$borderColorFocus"
68
- }
69
- }
70
- },
71
- size: {
72
- "...size": getButtonSized,
73
- ":number": getButtonSized
74
- },
75
- disabled: {
76
- true: {
77
- pointerEvents: "none"
57
+ borderColor: "$borderColorHover"
58
+ },
59
+ pressStyle: {
60
+ backgroundColor: "transparent",
61
+ borderColor: "$borderColorPress"
62
+ },
63
+ focusVisibleStyle: {
64
+ backgroundColor: "transparent",
65
+ borderColor: "$borderColorFocus"
78
66
  }
79
67
  }
80
68
  },
81
- defaultVariants: {
82
- unstyled: process.env.TAMAGUI_HEADLESS === "1"
69
+ size: {
70
+ "...size": getButtonSized,
71
+ ":number": getButtonSized
72
+ },
73
+ disabled: {
74
+ true: {
75
+ pointerEvents: "none"
76
+ }
83
77
  }
84
- }),
85
- ButtonText = styled(SizableText, {
86
- name: "Button",
87
- context: ButtonContext,
88
- variants: {
89
- unstyled: {
90
- false: {
91
- userSelect: "none",
92
- cursor: "pointer",
93
- // flexGrow 1 leads to inconsistent native style where text pushes to start of view
94
- flexGrow: 0,
95
- flexShrink: 1,
96
- ellipse: !0,
97
- color: "$color"
98
- }
78
+ },
79
+ defaultVariants: {
80
+ unstyled: process.env.TAMAGUI_HEADLESS === "1"
81
+ }
82
+ }), ButtonText = styled(SizableText, {
83
+ name: "Button",
84
+ context: ButtonContext,
85
+ variants: {
86
+ unstyled: {
87
+ false: {
88
+ userSelect: "none",
89
+ cursor: "pointer",
90
+ // flexGrow 1 leads to inconsistent native style where text pushes to start of view
91
+ flexGrow: 0,
92
+ flexShrink: 1,
93
+ ellipse: !0,
94
+ color: "$color"
99
95
  }
100
- },
101
- defaultVariants: {
102
- unstyled: process.env.TAMAGUI_HEADLESS === "1"
103
96
  }
104
- }),
105
- ButtonIcon = function (props) {
106
- var {
107
- children,
108
- scaleIcon = 1
109
- } = props,
110
- {
111
- size,
112
- color
113
- } = useContext(ButtonContext),
114
- iconSize = (typeof size == "number" ? size * 0.5 : getFontSize(size)) * scaleIcon,
115
- getThemedIcon = useGetThemedIcon({
116
- size: iconSize,
117
- color
118
- });
119
- return getThemedIcon(children);
120
97
  },
121
- ButtonComponent = ButtonFrame.styleable(function (props, ref) {
122
- var {
123
- props: buttonProps
124
- } = useButton(props);
125
- return /* @__PURE__ */_jsx(ButtonFrame, {
126
- ...buttonProps,
127
- ref
128
- });
129
- }),
130
- buttonStaticConfig = {
131
- inlineProps: /* @__PURE__ */new Set([
98
+ defaultVariants: {
99
+ unstyled: process.env.TAMAGUI_HEADLESS === "1"
100
+ }
101
+ }), ButtonIcon = function(props) {
102
+ var { children, scaleIcon = 1 } = props, { size, color } = useContext(ButtonContext), iconSize = (typeof size == "number" ? size * 0.5 : getFontSize(size)) * scaleIcon, getThemedIcon = useGetThemedIcon({
103
+ size: iconSize,
104
+ color
105
+ });
106
+ return getThemedIcon(children);
107
+ }, ButtonComponent = ButtonFrame.styleable(function(props, ref) {
108
+ var { props: buttonProps } = useButton(props);
109
+ return /* @__PURE__ */ _jsx(ButtonFrame, {
110
+ ...buttonProps,
111
+ ref
112
+ });
113
+ }), buttonStaticConfig = {
114
+ inlineProps: /* @__PURE__ */ new Set([
132
115
  // text props go here (can't really optimize them, but we never fully extract button anyway)
133
116
  // may be able to remove this entirely, as the compiler / runtime have gotten better
134
- "color", "fontWeight", "fontSize", "fontFamily", "fontStyle", "letterSpacing", "textAlign", "unstyled"])
135
- },
136
- Button2 = withStaticProperties(ButtonComponent, {
137
- Text: ButtonText,
138
- Icon: ButtonIcon
139
- });
117
+ "color",
118
+ "fontWeight",
119
+ "fontSize",
120
+ "fontFamily",
121
+ "fontStyle",
122
+ "letterSpacing",
123
+ "textAlign",
124
+ "unstyled"
125
+ ])
126
+ }, Button2 = withStaticProperties(ButtonComponent, {
127
+ Text: ButtonText,
128
+ Icon: ButtonIcon
129
+ });
140
130
  function useButton(param) {
141
- var {
142
- textProps,
143
- ...propsIn
144
- } = param,
145
- {
146
- Text = Button2.Text
147
- } = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {
148
- Text: Button2.Text
131
+ var { textProps, ...propsIn } = param, { Text = Button2.Text } = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {
132
+ Text: Button2.Text
133
+ }, isNested = useContext(ButtonNestingContext), propsActive = useProps(propsIn, {
134
+ noNormalize: !0,
135
+ noExpand: !0
136
+ }), { icon, iconAfter, space, spaceFlex, scaleIcon = 1, scaleSpace = 0.66, separator, noTextWrap, fontFamily, fontSize, fontWeight, fontStyle, letterSpacing, tag, ellipse, maxFontSizeMultiplier, ...restProps } = propsActive, size = propsActive.size || (propsActive.unstyled ? void 0 : "$true"), color = propsActive.color, iconSize = (typeof size == "number" ? size * 0.5 : getFontSize(size, {
137
+ font: fontFamily?.[0] === "$" ? fontFamily : void 0
138
+ })) * scaleIcon, getThemedIcon = useGetThemedIcon({
139
+ size: iconSize,
140
+ color
141
+ }), [themedIcon, themedIconAfter] = [
142
+ icon,
143
+ iconAfter
144
+ ].map(getThemedIcon), spaceSize = space ?? getVariableValue(iconSize) * scaleSpace, contents = noTextWrap ? [
145
+ propsIn.children
146
+ ] : wrapChildrenInText(Text, {
147
+ children: propsIn.children,
148
+ fontFamily,
149
+ fontSize,
150
+ textProps,
151
+ fontWeight,
152
+ fontStyle,
153
+ letterSpacing,
154
+ ellipse,
155
+ maxFontSizeMultiplier
156
+ }, Text === ButtonText && propsActive.unstyled !== !0 ? {
157
+ unstyled: process.env.TAMAGUI_HEADLESS === "1",
158
+ size
159
+ } : void 0), inner = spacedChildren({
160
+ // a bit arbitrary but scaling to font size is necessary so long as button does
161
+ space: spaceSize,
162
+ spaceFlex,
163
+ ensureKeys: !0,
164
+ separator,
165
+ direction: propsActive.flexDirection === "column" || propsActive.flexDirection === "column-reverse" ? "vertical" : "horizontal",
166
+ // for keys to stay the same we keep indices as similar a possible
167
+ // so even if icons are undefined we still pass them
168
+ children: [
169
+ themedIcon,
170
+ ...contents,
171
+ themedIconAfter
172
+ ]
173
+ }), props = {
174
+ size,
175
+ ...propsIn.disabled && {
176
+ // in rnw - false still has keyboard tabIndex, undefined = not actually focusable
177
+ focusable: void 0,
178
+ // even with tabIndex unset, it will keep focusVisibleStyle on web so disable it here
179
+ focusVisibleStyle: {
180
+ borderColor: "$background"
181
+ }
149
182
  },
150
- isNested = useContext(ButtonNestingContext),
151
- propsActive = useProps(propsIn, {
152
- noNormalize: !0,
153
- noExpand: !0
154
- }),
155
- {
156
- icon,
157
- iconAfter,
158
- space,
159
- spaceFlex,
160
- scaleIcon = 1,
161
- scaleSpace = 0.66,
162
- separator,
163
- noTextWrap,
164
- fontFamily,
165
- fontSize,
166
- fontWeight,
167
- fontStyle,
168
- letterSpacing,
169
- tag,
170
- ellipse,
171
- maxFontSizeMultiplier,
172
- ...restProps
173
- } = propsActive,
174
- size = propsActive.size || (propsActive.unstyled ? void 0 : "$true"),
175
- color = propsActive.color,
176
- iconSize = (typeof size == "number" ? size * 0.5 : getFontSize(size, {
177
- font: fontFamily?.[0] === "$" ? fontFamily : void 0
178
- })) * scaleIcon,
179
- getThemedIcon = useGetThemedIcon({
180
- size: iconSize,
181
- color
182
- }),
183
- [themedIcon, themedIconAfter] = [icon, iconAfter].map(getThemedIcon),
184
- spaceSize = space ?? getVariableValue(iconSize) * scaleSpace,
185
- contents = noTextWrap ? [propsIn.children] : wrapChildrenInText(Text, {
186
- children: propsIn.children,
187
- fontFamily,
188
- fontSize,
189
- textProps,
190
- fontWeight,
191
- fontStyle,
192
- letterSpacing,
193
- ellipse,
194
- maxFontSizeMultiplier
195
- }, Text === ButtonText && propsActive.unstyled !== !0 ? {
196
- unstyled: process.env.TAMAGUI_HEADLESS === "1",
197
- size
198
- } : void 0),
199
- inner = spacedChildren({
200
- // a bit arbitrary but scaling to font size is necessary so long as button does
201
- space: spaceSize,
202
- spaceFlex,
203
- ensureKeys: !0,
204
- separator,
205
- direction: propsActive.flexDirection === "column" || propsActive.flexDirection === "column-reverse" ? "vertical" : "horizontal",
206
- // for keys to stay the same we keep indices as similar a possible
207
- // so even if icons are undefined we still pass them
208
- children: [themedIcon, ...contents, themedIconAfter]
209
- }),
210
- props = {
211
- size,
212
- ...(propsIn.disabled && {
213
- // in rnw - false still has keyboard tabIndex, undefined = not actually focusable
214
- focusable: void 0,
215
- // even with tabIndex unset, it will keep focusVisibleStyle on web so disable it here
216
- focusVisibleStyle: {
217
- borderColor: "$background"
218
- }
219
- }),
220
- // fixes SSR issue + DOM nesting issue of not allowing button in button
221
- tag: tag ?? (isNested ? "span" :
183
+ // fixes SSR issue + DOM nesting issue of not allowing button in button
184
+ tag: tag ?? (isNested ? "span" : (
222
185
  // defaults to <a /> when accessibilityRole = link
223
186
  // see https://github.com/tamagui/tamagui/issues/505
224
- propsActive.accessibilityRole === "link" || propsActive.role === "link" ? "a" : "button"),
225
- ...restProps,
226
- children: /* @__PURE__ */_jsx(ButtonNestingContext.Provider, {
227
- value: !0,
228
- children: inner
229
- }),
230
- // forces it to be a runtime pressStyle so it passes through context text colors
231
- disableClassName: !0
232
- };
187
+ propsActive.accessibilityRole === "link" || propsActive.role === "link" ? "a" : "button"
188
+ )),
189
+ ...restProps,
190
+ children: /* @__PURE__ */ _jsx(ButtonNestingContext.Provider, {
191
+ value: !0,
192
+ children: inner
193
+ }),
194
+ // forces it to be a runtime pressStyle so it passes through context text colors
195
+ disableClassName: !0
196
+ };
233
197
  return {
234
198
  spaceSize,
235
199
  isNested,
236
200
  props
237
201
  };
238
202
  }
239
- export { Button2 as Button, ButtonContext, ButtonFrame, ButtonIcon, ButtonText, buttonStaticConfig, useButton };
240
- //# sourceMappingURL=Button.native.js.map
203
+ export {
204
+ Button2 as Button,
205
+ ButtonContext,
206
+ ButtonFrame,
207
+ ButtonIcon,
208
+ ButtonText,
209
+ buttonStaticConfig,
210
+ useButton
211
+ };
212
+ //# sourceMappingURL=Button.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":["jsx","_jsx","getFontSize","getButtonSized","withStaticProperties","useGetThemedIcon","ButtonNestingContext","ThemeableStack","SizableText","wrapChildrenInText","createStyledContext","getVariableValue","spacedChildren","styled","useProps","useContext","ButtonContext","color","ellipse","fontFamily","fontSize","fontStyle","fontWeight","letterSpacing","maxFontSizeMultiplier","size","textAlign","variant","BUTTON_NAME","ButtonFrame","name","tag","context","role","focusable","variants","unstyled","false","justifyContent","alignItems","flexWrap","flexDirection","cursor","hoverTheme","pressTheme","backgrounded","borderWidth","borderColor","focusVisibleStyle","outlineColor","outlineStyle","outlineWidth","outlined","backgroundColor","hoverStyle","pressStyle","disabled","true","pointerEvents","defaultVariants","process","env","TAMAGUI_HEADLESS","ButtonText","userSelect","flexGrow","flexShrink","ButtonIcon","props","children","scaleIcon","iconSize","getThemedIcon","ButtonComponent","styleable","ref","buttonProps","useButton","buttonStaticConfig","inlineProps","Set","Button2","Text","Icon","param","textProps","propsIn","arguments","length","isNested","propsActive","noNormalize","noExpand","icon","iconAfter","space","spaceFlex","scaleSpace","separator","noTextWrap","restProps","font","themedIcon","themedIconAfter","map","spaceSize","contents","inner","ensureKeys","direction","accessibilityRole","Provider","value","disableClassName","Button"],"sources":["../../src/Button.tsx"],"sourcesContent":[null],"mappings":"AAAA,SAASA,GAAA,IAAAC,IAAA,QAAmB;AAC5B,SAASC,WAAA,4BAAsB;AAC/B,SAASC,cAAA,mCAA4B;AACrC,SAASC,oBAAA,QAAwB;AACjC,SAASC,gBAAA,QAAsB,0BAAsB;AAErD,SAASC,oBAAa,EAAAC,cAAA,QAA0B;AAEhD,SAAAC,WAAA,EAAAC,kBAAA;AAAA,SACEC,mBAAA,EAAAC,gBAAA,EAAAC,cAAA,EAAAC,MAAA,EAAAC,QAAA;AAAA,SACAC,UAAA;AAAA,IACAC,aAAA,GAAAN,mBAAA;IACA;IACAO,KAAA;IAAAC,OACK;IAEPC,UAAS;IAgLEC,QAAA;IA5KJC,SAAM;IAOXC,UAAA;IAEAC,aAAO;IACPC,qBAAS;IACTC,IAAA,QAAY;IACZC,SAAA,EAAU;IACVC,OAAA,OAAW;EAAA,EACX;EAAAC,WAAY;EAAAC,WAAA,GAAAhB,MAAA,CAAAN,cAAA;IACZuB,IAAA,EAAAF,WAAe;IACfG,GAAA;IACAC,OAAM,EAAAhB,aAAA;IACNiB,IAAA,UAAW;IACXC,SAAS;IACVC,QAyCK;MAGJC,QAAM;QACNC,KAAK;UACLZ,IAAS;UACHa,cAAA;UACNC,UAAW;UAEXC,QAAU;UACRC,aAAU;UACRC,MAAO;UACLC,UAAM;UACNC,UAAA;UACAC,YAAY;UACZC,WAAU;UACVC,WAAA,eAAe;UACfC,iBAAQ;YACRC,YAAY;YACZC,YAAY;YACZC,YAAc;UACd;QAAa;MACA;MAEMxB,OACjB;QAAcyB,QACd;UAAcC,eACd,EAAc;UAChBP,WAAA;UACFC,WAAA;UACFO,UAAA;YAEAD,eAAS;YACPN,WAAU;UACR;UACAQ,UAAA;YACAF,eAAa;YAEbN,WAAY;UAAA;UACOC,iBACJ;YACfK,eAAA;YAEA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
+ "names": ["getFontSize", "getButtonSized", "withStaticProperties", "useGetThemedIcon", "ButtonNestingContext", "ThemeableStack", "SizableText", "wrapChildrenInText", "createStyledContext", "getVariableValue", "spacedChildren", "styled", "useProps", "useContext", "ButtonContext", "color", "undefined", "ellipse", "fontFamily", "fontSize", "fontStyle", "fontWeight", "letterSpacing", "maxFontSizeMultiplier", "size", "textAlign", "variant", "BUTTON_NAME", "ButtonFrame", "name", "tag", "context", "role", "focusable", "variants", "unstyled", "false", "justifyContent", "alignItems", "flexWrap", "flexDirection", "cursor", "hoverTheme", "pressTheme", "backgrounded", "borderWidth", "borderColor", "focusVisibleStyle", "outlineColor", "outlineStyle", "outlineWidth", "outlined", "backgroundColor", "hoverStyle", "pressStyle", "disabled", "true", "pointerEvents", "defaultVariants", "process", "env", "TAMAGUI_HEADLESS", "ButtonText", "userSelect", "flexGrow", "flexShrink", "ButtonIcon", "props", "children", "scaleIcon", "iconSize", "getThemedIcon", "ButtonComponent", "styleable", "ref", "buttonProps", "useButton", "buttonStaticConfig", "inlineProps", "Set", "Button", "Text", "Icon", "textProps", "propsIn", "isNested", "propsActive", "noNormalize", "noExpand", "icon", "iconAfter", "space", "spaceFlex", "scaleSpace", "separator", "noTextWrap", "restProps", "font", "themedIcon", "themedIconAfter", "map", "spaceSize", "contents", "inner", "ensureKeys", "direction", "accessibilityRole", "Provider", "value", "disableClassName"]
6
+ }
@@ -2,9 +2,9 @@ import { getDefaultTamaguiConfig } from "@tamagui/config-default";
2
2
  import { createTamagui } from "@tamagui/core";
3
3
  import { describe, expect, test } from "vitest";
4
4
  var conf = createTamagui(getDefaultTamaguiConfig());
5
- describe("Button", function () {
6
- test("123", function () {
5
+ describe("Button", function() {
6
+ test("123", function() {
7
7
  expect(!0).toBeTruthy();
8
8
  });
9
9
  });
10
- //# sourceMappingURL=Button.test.native.js.map
10
+ //# sourceMappingURL=Button.test.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":["getDefaultTamaguiConfig","createTamagui","describe","expect","test","conf","toBeTruthy"],"sources":["../../src/Button.test.tsx"],"sourcesContent":[null],"mappings":"AAAA,SAASA,uBAAA,QAA+B;AACxC,SAASC,aAAA,QAAqB;AAC9B,SAASC,QAAA,EAAUC,MAAA,EAAQC,IAAA,QAAY;AAEvC,IAAAC,IAAM,GAAAJ,aAAO,CAAAD,uBAAc,GAAwB;AAEnDE,QAAA,CAAS,UAAU,YAAM;EACvBE,IAAA,CAAK,OAAO,YAAM;IAChBD,MAAA,CAAO,EAAI,EAAEG,UAAA,CAAW;EAC1B,CAAC;AAWH,CAAC","ignoreList":[]}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/Users/n8/tamagui/code/ui/button/src/Button.test.tsx"],
4
+ "mappings": "AAAA,SAASA,+BAA+B;AACxC,SAASC,qBAAqB;AAC9B,SAASC,UAAUC,QAAQC,YAAY;AAEvC,IAAMC,OAAOJ,cAAcD,wBAAAA,CAAAA;AAE3BE,SAAS,UAAU,WAAA;AACjBE,OAAK,OAAO,WAAA;AACVD,WAAO,EAAA,EAAMG,WAAU;EACzB,CAAA;AAWF,CAAA;",
5
+ "names": ["getDefaultTamaguiConfig", "createTamagui", "describe", "expect", "test", "conf", "toBeTruthy"]
6
+ }
@@ -1,2 +1,2 @@
1
- export * from "./Button.native.js";
2
- //# sourceMappingURL=index.native.js.map
1
+ export * from "./Button";
2
+ //# sourceMappingURL=index.js.map
@@ -1 +1,6 @@
1
- {"version":3,"names":[],"sources":["../../src/index.ts"],"sourcesContent":[null],"mappings":"AAAA,cAAc","ignoreList":[]}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/Users/n8/tamagui/code/ui/button/src/index.ts"],
4
+ "mappings": "AAAA,cAAc;",
5
+ "names": []
6
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tamagui/button",
3
- "version": "1.113.0",
3
+ "version": "1.113.2",
4
4
  "sideEffects": [
5
5
  "*.css"
6
6
  ],
@@ -33,16 +33,16 @@
33
33
  }
34
34
  },
35
35
  "dependencies": {
36
- "@tamagui/font-size": "1.113.0",
37
- "@tamagui/get-button-sized": "1.113.0",
38
- "@tamagui/helpers": "1.113.0",
39
- "@tamagui/helpers-tamagui": "1.113.0",
40
- "@tamagui/stacks": "1.113.0",
41
- "@tamagui/text": "1.113.0",
42
- "@tamagui/web": "1.113.0"
36
+ "@tamagui/font-size": "1.113.2",
37
+ "@tamagui/get-button-sized": "1.113.2",
38
+ "@tamagui/helpers": "1.113.2",
39
+ "@tamagui/helpers-tamagui": "1.113.2",
40
+ "@tamagui/stacks": "1.113.2",
41
+ "@tamagui/text": "1.113.2",
42
+ "@tamagui/web": "1.113.2"
43
43
  },
44
44
  "devDependencies": {
45
- "@tamagui/build": "1.113.0",
45
+ "@tamagui/build": "1.113.2",
46
46
  "react": "^18.2.0 || ^19.0.0",
47
47
  "vitest": "2.1.1"
48
48
  },