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

@sajari/react-sdk-utils

Package Overview
Dependencies
Maintainers
5
Versions
60
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@sajari/react-sdk-utils - npm Package Compare versions

Comparing version 1.3.3 to 1.3.4

6

CHANGELOG.md
# Change Log
## 1.3.4
### Patch Changes
- [`65fd3fe2`](https://github.com/sajari/sdk-react/commit/65fd3fe2af94f27daa0d89ee9eab708e275ebbea) [#375](https://github.com/sajari/sdk-react/pull/375) Thanks [@sampotts](https://github.com/sampotts)! - Add more modal width options
## 1.3.3

@@ -4,0 +10,0 @@

4

dist/react-sdk-utils.cjs.development.js

@@ -457,2 +457,6 @@ 'use strict';

},
maxWidth: {
'7xl': '80rem',
'screen-2xl': '1536px'
},
minWidth: {

@@ -459,0 +463,0 @@ 'max-content': 'max-content'

2

dist/react-sdk-utils.cjs.production.min.js

@@ -1,2 +0,2 @@

"use strict";function e(e){return e&&"object"==typeof e&&"default"in e?e.default:e}var r=require("react"),t=e(r),n=require("@emotion/core"),i=e(require("@emotion/is-prop-valid")),o=e(require("@emotion/styled")),u=require("emotion-theming"),a=e(require("@emotion/cache"));function c(){return(c=Object.assign||function(e){for(var r=1;r<arguments.length;r++){var t=arguments[r];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])}return e}).apply(this,arguments)}function s(e){return null==e}function f(e){return"string"==typeof e}function l(e){return"number"==typeof e&&!Number.isNaN(e)}function p(e){return Array.isArray(e)}var d=function(e){var r=typeof e;return null!==e&&("object"===r||"function"===r)&&!p(e)},m=function(e){return p(e)&&0===e.length},v=function(e){return d(e)&&0===Object.keys(e).length},x=function(e){return!!s(e)||(p(e)?m(e):d(e)?v(e):!!f(e)&&""===e.trim())};function h(){return"undefined"==typeof window}function y(e){var r=/(?:\.(\d+))?(?:[eE]([+-]?\d+))?$/.exec(e.toString());return r?Math.max(0,(r[1]?r[1].length:0)-(r[2]?+r[2]:0)):0}function b(e,r){return parseFloat(e.toFixed(r))}function g(e,r){var t=r.neutral,n=void 0===t||t,i=r.language,o=void 0===i?h()?"en-US":navigator.language:i,u=function(e,r){if(null==e)return{};var t,n,i={},o=Object.keys(e);for(n=0;n<o.length;n++)r.indexOf(t=o[n])>=0||(i[t]=e[t]);return i}(r,["neutral","language"]);return l(e)?new Intl.NumberFormat(n?o.split("-")[0]:o,u).format(e):e}function w(e){for(var r=arguments.length,t=new Array(r>1?r-1:0),n=1;n<r;n++)t[n-1]=arguments[n];if(!d(e)||!t.length)return e;var i=t.shift();return i&&d(i)?(Object.keys(i).forEach((function(r){var t=e[r],n=i[r];e[r]=Array.isArray(t)&&Array.isArray(n)?t.concat(n):d(t)&&d(n)?w(c({},t),n):n})),e):e}function O(e,r){void 0===e&&(e=null),e&&("function"==typeof e?e(r):e.current=r)}function j(e,r){if(null!=e)try{O(e,r)}catch(e){throw new Error("Cannot assign value to ref")}}function A(e,r,t){return f(r)?e.split(r).join(t):Object.entries(r).reduce((function(e,r){return A(e,r[0],r[1])}),e)}var S={theme:{backdropFilter:{none:"none","blur-1":"blur(0.25rem)","blur-2":"blur(0.5rem)","blur-3":"blur(0.75rem)","blur-4":"blur(1rem)","blur-5":"blur(1.25rem)","blur-6":"blur(1.5rem)"},truncate:{lines:{2:"2",3:"3",4:"4",5:"5"}},extend:{backgroundOpacity:{95:.95},borderRadius:{inherit:"inherit"},boxShadow:{menu:"inset 0 0 0 1px rgba(0, 0, 0, 0.1), 0 1px 5px rgba(0, 0, 0, 0.1), inset 0 -1px 0 rgba(0, 0, 0, 0.1)"},fontSize:{"code-inline":"0.9375em"},fontFamily:{inherit:"inherit"},lineHeight:{inherit:"inherit"},minWidth:{"max-content":"max-content"},spacing:{"(screen-8)":"calc(100vh - 2rem)","(screen-12)":"calc(100vh - 3rem)","(screen-16)":"calc(100vh - 4rem)","(screen-20)":"calc(100vh - 5rem)"}}},plugins:[require("@tailwindcss/ui"),require("tailwindcss-filters"),require("tailwindcss-truncate-multiline")()]},E=["letter-spacing"],M=a({stylisPlugins:function(e,r,t){var n=t[0];switch(e){case 1:return r+" !important";case 3:return"@font-face"===n||n.startsWith("@")&&n.includes("keyframes")?A(r," !important",""):r;default:return r}},prefix:function(e){return!E.includes(e)}}),P={color:{primary:{base:"#667eea".toString(),text:"#fff".toString(),active:"#5a67d8".toString()}}};exports.ThemeProvider=function(e){var t=e.theme,i=e.importantStyles,o=void 0!==i&&i,a=e.children;return r.createElement(u.ThemeProvider,{theme:w(P,void 0===t?P:t)},o?r.createElement(n.CacheProvider,{value:M},a):a)},exports.__DEV__=!1,exports.assignRef=j,exports.callAllHandlers=function(){for(var e=arguments.length,r=new Array(e),t=0;t<e;t++)r[t]=arguments[t];return function(e){r.some((function(r){return r&&r(e),e&&e.defaultPrevented}))}},exports.clamp=function(e,r,t){return void 0===e&&(e=0),void 0===r&&(r=0),void 0===t&&(t=255),Math.min(Math.max(e,r),t)},exports.cleanChildren=function(e){return r.Children.toArray(e).filter((function(e){return r.isValidElement(e)}))},exports.closest=function(e,r){var t=r.reduce((function(r,t){return Math.abs(t-e)<Math.abs(r-e)?t:r}));return[r.indexOf(t),t]},exports.createContext=function(e){void 0===e&&(e={});var t=e.strict,n=void 0===t||t,i=e.errorMessage,o=void 0===i?"useContext must be inside a Provider with a value":i,u=e.name,a=r.createContext(void 0);return a.displayName=u,[a.Provider,function(){var e=r.useContext(a);if(!e&&n)throw new Error(o);return e},a]},exports.decodeHTML=function(e){if(void 0===e&&(e=""),h())return e;var r=document.createElement("textarea");return r.innerHTML=e,r.value},exports.filterObject=function(e,r,t){return void 0===t&&(t=!1),Object.keys(e).filter((function(e){return t?!r.includes(e):r.includes(e)})).reduce((function(r,t){var n;return Object.assign(r,((n={})[t]=e[t],n))}),{})},exports.filterProps=function(e){return s(e)?{}:Object.entries(e).reduce((function(e,r){var t,n=r[0],o=r[1];return i(n)?c({},e,((t={})[n]=o,t)):e}),{})},exports.formatNumber=g,exports.formatPrice=function(e,r){var t=e,n=function(t){var n=Number(t);return l(n)?g(n,c({style:"currency"},r)):e.toString()};if(!Array.isArray(t))return n(t);var i=t.map(Number),o=Math.min.apply(Math,i),u=Math.max.apply(Math,i);return o===u?n(o):n(o)+"–"+n(u)},exports.forwardRefWithAs=function(e){return t.forwardRef(e)},exports.getDecimalPlaces=y,exports.getStylesObject=function(e,r){return r?{}:e},exports.groupBy=function(e,r){return e.reduce((function(e,t){var n;return c({},e,((n={})[t[r]]=(e[t[r]]||[]).concat(t),n))}),{})},exports.inferStylesObjectKeys=function(e){return e},exports.isArray=p,exports.isBoolean=function(e){return"boolean"==typeof e},exports.isEmpty=x,exports.isEmptyArray=m,exports.isEmptyObject=v,exports.isFunction=function(e){return"function"==typeof e},exports.isNullOrUndefined=s,exports.isNumber=l,exports.isObject=d,exports.isSSR=h,exports.isString=f,exports.isValidURL=function(e,r){return void 0===r&&(r=!1),!(!e||x(e)||(!r||!e.startsWith("/"))&&null===function(e){void 0===e&&(e="");try{return new URL(e)}catch(e){return null}}(e))},exports.mapStyles=function(e){return Object.entries(e).reduce((function(e,r){var t;return Object.assign(e,((t={})[r[0]]=n.css(r[1]),t))}),{})},exports.merge=w,exports.mergeRefs=function(){for(var e=arguments.length,r=new Array(e),t=0;t<e;t++)r[t]=arguments[t];return function(e){r.forEach((function(r){return r&&j(r,e)}))}},exports.noop=function(){},exports.pluralize=function(e,r,t){return 1===e?r:t},exports.replaceAll=A,exports.round=b,exports.roundToStep=function(e,r){var t=y(r);return b(Math.round(e/r)*r,t)},exports.setRef=O,exports.styled=o,exports.tailwindConfig=S,exports.useDebounce=function(e,t,n){void 0===t&&(t=50),void 0===n&&(n={isImmediate:!1});var i=r.useRef();return function(){for(var r=this,o=arguments.length,u=new Array(o),a=0;a<o;a++)u[a]=arguments[a];i.current&&clearTimeout(i.current);var c=function(){i.current=void 0,n.isImmediate||e.apply(r,u)},s=n.isImmediate&&void 0===i.current;i.current=setTimeout(c,t),s&&e.apply(this,u)}},exports.useTheme=function(){return u.useTheme()};
"use strict";function e(e){return e&&"object"==typeof e&&"default"in e?e.default:e}var r=require("react"),t=e(r),n=require("@emotion/core"),i=e(require("@emotion/is-prop-valid")),o=e(require("@emotion/styled")),u=require("emotion-theming"),a=e(require("@emotion/cache"));function c(){return(c=Object.assign||function(e){for(var r=1;r<arguments.length;r++){var t=arguments[r];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])}return e}).apply(this,arguments)}function s(e){return null==e}function l(e){return"string"==typeof e}function f(e){return"number"==typeof e&&!Number.isNaN(e)}function p(e){return Array.isArray(e)}var d=function(e){var r=typeof e;return null!==e&&("object"===r||"function"===r)&&!p(e)},m=function(e){return p(e)&&0===e.length},v=function(e){return d(e)&&0===Object.keys(e).length},x=function(e){return!!s(e)||(p(e)?m(e):d(e)?v(e):!!l(e)&&""===e.trim())};function h(){return"undefined"==typeof window}function y(e){var r=/(?:\.(\d+))?(?:[eE]([+-]?\d+))?$/.exec(e.toString());return r?Math.max(0,(r[1]?r[1].length:0)-(r[2]?+r[2]:0)):0}function b(e,r){return parseFloat(e.toFixed(r))}function g(e,r){var t=r.neutral,n=void 0===t||t,i=r.language,o=void 0===i?h()?"en-US":navigator.language:i,u=function(e,r){if(null==e)return{};var t,n,i={},o=Object.keys(e);for(n=0;n<o.length;n++)r.indexOf(t=o[n])>=0||(i[t]=e[t]);return i}(r,["neutral","language"]);return f(e)?new Intl.NumberFormat(n?o.split("-")[0]:o,u).format(e):e}function w(e){for(var r=arguments.length,t=new Array(r>1?r-1:0),n=1;n<r;n++)t[n-1]=arguments[n];if(!d(e)||!t.length)return e;var i=t.shift();return i&&d(i)?(Object.keys(i).forEach((function(r){var t=e[r],n=i[r];e[r]=Array.isArray(t)&&Array.isArray(n)?t.concat(n):d(t)&&d(n)?w(c({},t),n):n})),e):e}function O(e,r){void 0===e&&(e=null),e&&("function"==typeof e?e(r):e.current=r)}function j(e,r){if(null!=e)try{O(e,r)}catch(e){throw new Error("Cannot assign value to ref")}}function A(e,r,t){return l(r)?e.split(r).join(t):Object.entries(r).reduce((function(e,r){return A(e,r[0],r[1])}),e)}var S={theme:{backdropFilter:{none:"none","blur-1":"blur(0.25rem)","blur-2":"blur(0.5rem)","blur-3":"blur(0.75rem)","blur-4":"blur(1rem)","blur-5":"blur(1.25rem)","blur-6":"blur(1.5rem)"},truncate:{lines:{2:"2",3:"3",4:"4",5:"5"}},extend:{backgroundOpacity:{95:.95},borderRadius:{inherit:"inherit"},boxShadow:{menu:"inset 0 0 0 1px rgba(0, 0, 0, 0.1), 0 1px 5px rgba(0, 0, 0, 0.1), inset 0 -1px 0 rgba(0, 0, 0, 0.1)"},fontSize:{"code-inline":"0.9375em"},fontFamily:{inherit:"inherit"},lineHeight:{inherit:"inherit"},maxWidth:{"7xl":"80rem","screen-2xl":"1536px"},minWidth:{"max-content":"max-content"},spacing:{"(screen-8)":"calc(100vh - 2rem)","(screen-12)":"calc(100vh - 3rem)","(screen-16)":"calc(100vh - 4rem)","(screen-20)":"calc(100vh - 5rem)"}}},plugins:[require("@tailwindcss/ui"),require("tailwindcss-filters"),require("tailwindcss-truncate-multiline")()]},E=["letter-spacing"],M=a({stylisPlugins:function(e,r,t){var n=t[0];switch(e){case 1:return r+" !important";case 3:return"@font-face"===n||n.startsWith("@")&&n.includes("keyframes")?A(r," !important",""):r;default:return r}},prefix:function(e){return!E.includes(e)}}),P={color:{primary:{base:"#667eea".toString(),text:"#fff".toString(),active:"#5a67d8".toString()}}};exports.ThemeProvider=function(e){var t=e.theme,i=e.importantStyles,o=void 0!==i&&i,a=e.children;return r.createElement(u.ThemeProvider,{theme:w(P,void 0===t?P:t)},o?r.createElement(n.CacheProvider,{value:M},a):a)},exports.__DEV__=!1,exports.assignRef=j,exports.callAllHandlers=function(){for(var e=arguments.length,r=new Array(e),t=0;t<e;t++)r[t]=arguments[t];return function(e){r.some((function(r){return r&&r(e),e&&e.defaultPrevented}))}},exports.clamp=function(e,r,t){return void 0===e&&(e=0),void 0===r&&(r=0),void 0===t&&(t=255),Math.min(Math.max(e,r),t)},exports.cleanChildren=function(e){return r.Children.toArray(e).filter((function(e){return r.isValidElement(e)}))},exports.closest=function(e,r){var t=r.reduce((function(r,t){return Math.abs(t-e)<Math.abs(r-e)?t:r}));return[r.indexOf(t),t]},exports.createContext=function(e){void 0===e&&(e={});var t=e.strict,n=void 0===t||t,i=e.errorMessage,o=void 0===i?"useContext must be inside a Provider with a value":i,u=e.name,a=r.createContext(void 0);return a.displayName=u,[a.Provider,function(){var e=r.useContext(a);if(!e&&n)throw new Error(o);return e},a]},exports.decodeHTML=function(e){if(void 0===e&&(e=""),h())return e;var r=document.createElement("textarea");return r.innerHTML=e,r.value},exports.filterObject=function(e,r,t){return void 0===t&&(t=!1),Object.keys(e).filter((function(e){return t?!r.includes(e):r.includes(e)})).reduce((function(r,t){var n;return Object.assign(r,((n={})[t]=e[t],n))}),{})},exports.filterProps=function(e){return s(e)?{}:Object.entries(e).reduce((function(e,r){var t,n=r[0],o=r[1];return i(n)?c({},e,((t={})[n]=o,t)):e}),{})},exports.formatNumber=g,exports.formatPrice=function(e,r){var t=e,n=function(t){var n=Number(t);return f(n)?g(n,c({style:"currency"},r)):e.toString()};if(!Array.isArray(t))return n(t);var i=t.map(Number),o=Math.min.apply(Math,i),u=Math.max.apply(Math,i);return o===u?n(o):n(o)+"–"+n(u)},exports.forwardRefWithAs=function(e){return t.forwardRef(e)},exports.getDecimalPlaces=y,exports.getStylesObject=function(e,r){return r?{}:e},exports.groupBy=function(e,r){return e.reduce((function(e,t){var n;return c({},e,((n={})[t[r]]=(e[t[r]]||[]).concat(t),n))}),{})},exports.inferStylesObjectKeys=function(e){return e},exports.isArray=p,exports.isBoolean=function(e){return"boolean"==typeof e},exports.isEmpty=x,exports.isEmptyArray=m,exports.isEmptyObject=v,exports.isFunction=function(e){return"function"==typeof e},exports.isNullOrUndefined=s,exports.isNumber=f,exports.isObject=d,exports.isSSR=h,exports.isString=l,exports.isValidURL=function(e,r){return void 0===r&&(r=!1),!(!e||x(e)||(!r||!e.startsWith("/"))&&null===function(e){void 0===e&&(e="");try{return new URL(e)}catch(e){return null}}(e))},exports.mapStyles=function(e){return Object.entries(e).reduce((function(e,r){var t;return Object.assign(e,((t={})[r[0]]=n.css(r[1]),t))}),{})},exports.merge=w,exports.mergeRefs=function(){for(var e=arguments.length,r=new Array(e),t=0;t<e;t++)r[t]=arguments[t];return function(e){r.forEach((function(r){return r&&j(r,e)}))}},exports.noop=function(){},exports.pluralize=function(e,r,t){return 1===e?r:t},exports.replaceAll=A,exports.round=b,exports.roundToStep=function(e,r){var t=y(r);return b(Math.round(e/r)*r,t)},exports.setRef=O,exports.styled=o,exports.tailwindConfig=S,exports.useDebounce=function(e,t,n){void 0===t&&(t=50),void 0===n&&(n={isImmediate:!1});var i=r.useRef();return function(){for(var r=this,o=arguments.length,u=new Array(o),a=0;a<o;a++)u[a]=arguments[a];i.current&&clearTimeout(i.current);var c=function(){i.current=void 0,n.isImmediate||e.apply(r,u)},s=n.isImmediate&&void 0===i.current;i.current=setTimeout(c,t),s&&e.apply(this,u)}},exports.useTheme=function(){return u.useTheme()};
//# sourceMappingURL=react-sdk-utils.cjs.production.min.js.map

@@ -39,2 +39,6 @@ var tailwind_config = {

},
maxWidth: {
'7xl': '80rem',
'screen-2xl': '1536px'
},
minWidth: {

@@ -41,0 +45,0 @@ 'max-content': 'max-content'

{
"name": "@sajari/react-sdk-utils",
"version": "1.3.3",
"version": "1.3.4",
"description": "Shared utils for the Sajari React packages.",

@@ -5,0 +5,0 @@ "sideEffects": false,

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