Socket
Socket
Sign inDemoInstall

@tamagui/web

Package Overview
Dependencies
Maintainers
1
Versions
795
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@tamagui/web - npm Package Compare versions

Comparing version 1.112.25-1728362181133 to 1.112.25-1728365940312

2

dist/cjs/createVariable.js

@@ -51,2 +51,4 @@ var __defProp = Object.defineProperty;

function getVariable(nameOrVariable, group = "size") {
if (nameOrVariable?.dynamic)
return nameOrVariable;
if (setDidGetVariableValue(!0), isVariable(nameOrVariable))

@@ -53,0 +55,0 @@ return variableToString(nameOrVariable);

@@ -55,2 +55,4 @@ "use strict";

var group = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "size", _tokens_group;
if (nameOrVariable != null && nameOrVariable.dynamic)
return nameOrVariable;
if (setDidGetVariableValue(!0), isVariable(nameOrVariable))

@@ -57,0 +59,0 @@ return variableToString(nameOrVariable);

4

dist/cjs/hooks/useTheme.js

@@ -149,3 +149,3 @@ var __create = Object.create;

const next = createState(themeState);
next.state?.name !== themeState.state?.name && (setThemeState(next), themeManager.notify());
next.state?.name !== themeState.state?.name && (setThemeState(next), console.error = preventWarnSetState, themeManager.notify(), console.error = ogLog);
}

@@ -219,3 +219,3 @@ if (import_constants.isServer || (import_react.default.useLayoutEffect(() => {

themeManager2 = prev.themeManager;
const forceChange = force, next = themeManager2.getState(props, parentManager), nextState = getShouldUpdateTheme(
const forceChange = force || !!keys?.length, next = themeManager2.getState(props, parentManager), nextState = getShouldUpdateTheme(
themeManager2,

@@ -222,0 +222,0 @@ next,

@@ -195,3 +195,3 @@ "use strict";

var _next_state, _themeState_state, next = createState(themeState);
((_next_state = next.state) === null || _next_state === void 0 ? void 0 : _next_state.name) !== ((_themeState_state = themeState.state) === null || _themeState_state === void 0 ? void 0 : _themeState_state.name) && (setThemeState(next), themeManager.notify());
((_next_state = next.state) === null || _next_state === void 0 ? void 0 : _next_state.name) !== ((_themeState_state = themeState.state) === null || _themeState_state === void 0 ? void 0 : _themeState_state.name) && (setThemeState(next), console.error = preventWarnSetState, themeManager.notify(), console.error = ogLog);
}

@@ -280,3 +280,3 @@ if (import_constants.isServer || (import_react.default.useLayoutEffect(function() {

themeManager2 = prev.themeManager;
var forceChange = force, next2 = themeManager2.getState(props, parentManager), nextState = getShouldUpdateTheme(themeManager2, next2, prev.state, forceChange);
var forceChange = force || !!(keys != null && keys.length), next2 = themeManager2.getState(props, parentManager), nextState = getShouldUpdateTheme(themeManager2, next2, prev.state, forceChange);
nextState ? (state2 = nextState, !prev.isNewTheme && !isRoot ? themeManager2 = getNewThemeManager() : themeManager2.updateState(nextState)) : prev.isNewTheme && parentManager && !next2 && (themeManager2 = parentManager);

@@ -283,0 +283,0 @@ } else

@@ -25,2 +25,4 @@ import { isWeb } from "@tamagui/constants";

function getVariable(nameOrVariable, group = "size") {
if (nameOrVariable?.dynamic)
return nameOrVariable;
if (setDidGetVariableValue(!0), isVariable(nameOrVariable))

@@ -27,0 +29,0 @@ return variableToString(nameOrVariable);

@@ -33,2 +33,3 @@ import { isWeb } from "@tamagui/constants";

_tokens_group;
if (nameOrVariable?.dynamic) return nameOrVariable;
if (setDidGetVariableValue(!0), isVariable(nameOrVariable)) return variableToString(nameOrVariable);

@@ -35,0 +36,0 @@ var tokens = getConfig().tokensParsed,

@@ -123,3 +123,3 @@ import React from "react";

const next = createState(themeState);
next.state?.name !== themeState.state?.name && (setThemeState(next), themeManager.notify());
next.state?.name !== themeState.state?.name && (setThemeState(next), console.error = preventWarnSetState, themeManager.notify(), console.error = ogLog);
}

@@ -193,3 +193,3 @@ if (isServer || (React.useLayoutEffect(() => {

themeManager2 = prev.themeManager;
const forceChange = force, next = themeManager2.getState(props, parentManager), nextState = getShouldUpdateTheme(
const forceChange = force || !!keys?.length, next = themeManager2.getState(props, parentManager), nextState = getShouldUpdateTheme(
themeManager2,

@@ -196,0 +196,0 @@ next,

@@ -198,3 +198,3 @@ import React from "react";

next = createState(themeState);
((_next_state = next.state) === null || _next_state === void 0 ? void 0 : _next_state.name) !== ((_themeState_state = themeState.state) === null || _themeState_state === void 0 ? void 0 : _themeState_state.name) && (setThemeState(next), themeManager.notify());
((_next_state = next.state) === null || _next_state === void 0 ? void 0 : _next_state.name) !== ((_themeState_state = themeState.state) === null || _themeState_state === void 0 ? void 0 : _themeState_state.name) && (setThemeState(next), console.error = preventWarnSetState, themeManager.notify(), console.error = ogLog);
}

@@ -272,3 +272,3 @@ if (isServer || (React.useLayoutEffect(function () {

themeManager2 = prev.themeManager;
var forceChange = force,
var forceChange = force || !!keys?.length,
next2 = themeManager2.getState(props, parentManager),

@@ -275,0 +275,0 @@ nextState = getShouldUpdateTheme(themeManager2, next2, prev.state, forceChange);

{
"name": "@tamagui/web",
"version": "1.112.25-1728362181133",
"version": "1.112.25-1728365940312",
"source": "src/index.ts",

@@ -30,14 +30,14 @@ "main": "dist/cjs",

"dependencies": {
"@tamagui/compose-refs": "1.112.25-1728362181133",
"@tamagui/constants": "1.112.25-1728362181133",
"@tamagui/helpers": "1.112.25-1728362181133",
"@tamagui/normalize-css-color": "1.112.25-1728362181133",
"@tamagui/timer": "1.112.25-1728362181133",
"@tamagui/types": "1.112.25-1728362181133",
"@tamagui/use-did-finish-ssr": "1.112.25-1728362181133",
"@tamagui/use-event": "1.112.25-1728362181133",
"@tamagui/use-force-update": "1.112.25-1728362181133"
"@tamagui/compose-refs": "1.112.25-1728365940312",
"@tamagui/constants": "1.112.25-1728365940312",
"@tamagui/helpers": "1.112.25-1728365940312",
"@tamagui/normalize-css-color": "1.112.25-1728365940312",
"@tamagui/timer": "1.112.25-1728365940312",
"@tamagui/types": "1.112.25-1728365940312",
"@tamagui/use-did-finish-ssr": "1.112.25-1728365940312",
"@tamagui/use-event": "1.112.25-1728365940312",
"@tamagui/use-force-update": "1.112.25-1728365940312"
},
"devDependencies": {
"@tamagui/build": "1.112.25-1728362181133",
"@tamagui/build": "1.112.25-1728365940312",
"@testing-library/react": "^16.0.1",

@@ -44,0 +44,0 @@ "csstype": "^3.0.10",

@@ -66,2 +66,6 @@ import { isWeb } from '@tamagui/constants'

) {
// dynamic color-like
if (nameOrVariable?.dynamic) {
return nameOrVariable
}
setDidGetVariableValue(true)

@@ -68,0 +72,0 @@ if (isVariable(nameOrVariable)) {

@@ -18,3 +18,3 @@ import type { TokenCategories } from './types';

export declare function isVariable(v: Variable | any): v is Variable;
export declare function getVariable(nameOrVariable: Variable | string | any, group?: TokenCategories): string;
export declare function getVariable(nameOrVariable: Variable | string | any, group?: TokenCategories): any;
export declare const setDidGetVariableValue: (val: boolean) => boolean;

@@ -21,0 +21,0 @@ export declare const didGetVariableValue: () => boolean;

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc