Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

expo-blur

Package Overview
Dependencies
Maintainers
18
Versions
93
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

expo-blur - npm Package Compare versions

Comparing version 8.0.0 to 8.1.0

.expo/tsconfig.jest.json

4

build/BlurView.android.d.ts
import PropTypes from 'prop-types';
import * as React from 'react';
import { BlurTint, Props } from './BlurView.types';
export default class BlurView extends React.Component<Props> {
import { BlurTint, BlurProps } from './BlurView.types';
export default class BlurView extends React.Component<BlurProps> {
static propTypes: {

@@ -6,0 +6,0 @@ tint: PropTypes.Validator<BlurTint>;

import PropTypes from 'prop-types';
import * as React from 'react';
import { BlurTint, ComponentOrHandle, Props } from './BlurView.types';
export default class BlurView extends React.Component<Props> {
import { BlurTint, ComponentOrHandle, BlurProps } from './BlurView.types';
export default class BlurView extends React.Component<BlurProps> {
static propTypes: {

@@ -6,0 +6,0 @@ tint: PropTypes.Validator<BlurTint>;

import { View } from 'react-native';
export declare type Props = {
export declare type BlurProps = {
tint: BlurTint;

@@ -4,0 +4,0 @@ intensity: number;

import PropTypes from 'prop-types';
import * as React from 'react';
import { BlurTint, Props } from './BlurView.types';
export default class BlurView extends React.Component<Props> {
import { BlurTint, BlurProps } from './BlurView.types';
export default class BlurView extends React.Component<BlurProps> {
static propTypes: {

@@ -6,0 +6,0 @@ hitSlop?: PropTypes.Validator<import("react-native").Insets | undefined> | undefined;

@@ -28,19 +28,10 @@ import PropTypes from 'prop-types';

function getBlurStyle({ intensity, tint }) {
const style = {
backgroundColor: getBackgroundColor(intensity, tint),
};
if (isBlurSupported()) {
let backdropFilter = `blur(${intensity * 0.25}px)`;
if (tint === 'dark') {
backdropFilter += ' brightness(50%)';
}
else if (tint === 'light') {
backdropFilter += ' brightness(150%)';
}
return {
backdropFilter,
};
style.backdropFilter = `blur(${intensity * 0.8}px)`;
}
else {
let backgroundColor = getBackgroundColor(intensity, tint);
return { backgroundColor };
}
return style;
}
//# sourceMappingURL=BlurView.web.js.map

@@ -5,7 +5,7 @@ export default function getBackgroundColor(intensity, tint) {

case 'dark':
return `rgba(0,0,0,${opacity * 0.5})`;
return `rgba(28,28,28,${opacity * 0.73})`;
case 'light':
return `rgba(255,255,255,${opacity * 0.7})`;
return `rgba(247,247,247,${opacity * 0.8})`;
case 'default':
return `rgba(255,255,255,${opacity * 0.4})`;
return `rgba(255,255,255,${opacity * 0.3})`;
}

@@ -12,0 +12,0 @@ throw new Error(`Unsupported tint provided: ${tint}`);

import BlurView from './BlurView';
export { BlurView };
export { BlurTint, BlurProps } from './BlurView.types';
{
"name": "expo-blur",
"version": "8.0.0",
"version": "8.1.0",
"description": "A component that renders a native blur view on iOS and falls back to a semi-transparent view on Android. A common usage of this is for navigation bars, tab bars, and modals.",

@@ -40,3 +40,3 @@ "main": "build/index.js",

"devDependencies": {
"expo-module-scripts": "~1.1.1"
"expo-module-scripts": "~1.2.0"
},

@@ -46,3 +46,3 @@ "unimodulePeerDependencies": {

},
"gitHead": "ec7878b9ce54f2537721218ae0fe4017e4004806"
"gitHead": "3ad68bbd9847ebc8a55272c263b17d998a92f64f"
}
import { View } from 'react-native';
export type Props = {
export type BlurProps = {
tint: BlurTint;

@@ -5,0 +5,0 @@ intensity: number;

@@ -7,9 +7,9 @@ import { BlurTint } from './BlurView.types';

case 'dark':
return `rgba(0,0,0,${opacity * 0.5})`;
return `rgba(28,28,28,${opacity * 0.73})`;
case 'light':
return `rgba(255,255,255,${opacity * 0.7})`;
return `rgba(247,247,247,${opacity * 0.8})`;
case 'default':
return `rgba(255,255,255,${opacity * 0.4})`;
return `rgba(255,255,255,${opacity * 0.3})`;
}
throw new Error(`Unsupported tint provided: ${tint}`);
}
import BlurView from './BlurView';
export { BlurView };
export { BlurTint, BlurProps } from './BlurView.types';

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