Socket
Socket
Sign inDemoInstall

@fower/store

Package Overview
Dependencies
Maintainers
1
Versions
40
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@fower/store - npm Package Compare versions

Comparing version 1.31.0 to 1.32.0

6

dist/store.cjs.development.js

@@ -170,7 +170,3 @@ 'use strict';

this.composeAtom = function (atomName, cssObject) {
if (_this.compositions.get(atomName)) {
console.log("composed atom \"" + atomName + "\" is existed");
} else {
_this.compositions.set(atomName, cssObject);
}
_this.compositions.set(atomName, cssObject);
};

@@ -177,0 +173,0 @@ }

2

dist/store.cjs.production.min.js

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

"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e,t=(e=require("deepmerge"))&&"object"==typeof e&&"default"in e?e.default:e,o=require("@fower/utils");function n(){return(n=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var o=arguments[t];for(var n in o)Object.prototype.hasOwnProperty.call(o,n)&&(e[n]=o[n])}return e}).apply(this,arguments)}var i=function(){function e(){var e=this;this.config={unit:"px",inline:!1,important:!1,mode:{currentMode:"light",autoDarkMode:{enabled:!1,mappings:{white:"black",black:"white",50:"900",100:"800",200:"700",300:"600",400:"500",500:"400",600:"300",700:"200",800:"100",900:"50"}},modeList:["light","dark"],classPrefix:""},prefix:"",pseudos:["active","checked","disabled","enabled","default","empty","focus","focus-within","invalid","hover","link","visited","first-child","last-child","after","before","placeholder","selection"],theme:{breakpoints:{}},plugins:[]},this.atomCache=new Map,this.getAtomIds=function(){return Array.from(e.atomCache.keys())},this.compositions=new Map,this.getConfig=function(){return e.config},this.setConfig=function(o,i){void 0===i&&(i="deepmerge"),e.config="replace"===i?o:"merge"===i?n({},e.config,o):t(e.config,o)},this.getTheme=function(){return e.config.theme},this.setTheme=function(o){e.config.theme=t(e.config.theme||{},o)},this.getMode=function(){var t;return(null==(t=e.config.mode)?void 0:t.currentMode)||""},this.setMode=function(t){if(o.isBrowser){var n=e.config.mode.currentMode;n&&document.documentElement.classList.remove(n),t&&document.documentElement.classList.add(t),localStorage.setItem("fower-mode",t),e.setConfig({mode:{currentMode:t}})}},this.use=function(){var t;(t=e.config.plugins).push.apply(t,arguments)},this.addAtom=function(t,o){var n={isMatch:function(e){return"string"==typeof t?e===t:t instanceof RegExp&&t.test(e)},handleAtom:"function"==typeof o?o:function(e){return e.style=o,e}};return e.use(n),n},this.composeAtom=function(t,o){e.compositions.get(t)?console.log('composed atom "'+t+'" is existed'):e.compositions.set(t,o)}}var i;return(i=[{key:"theme",get:function(){return this.config.theme}}])&&function(e,t){for(var o=0;o<t.length;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(e.prototype,i),e}(),r=new i;globalThis.__fower_store__=r,exports.Store=i,exports.store=r;
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e,t=(e=require("deepmerge"))&&"object"==typeof e&&"default"in e?e.default:e,n=require("@fower/utils");function o(){return(o=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(e[o]=n[o])}return e}).apply(this,arguments)}var i=function(){function e(){var e=this;this.config={unit:"px",inline:!1,important:!1,mode:{currentMode:"light",autoDarkMode:{enabled:!1,mappings:{white:"black",black:"white",50:"900",100:"800",200:"700",300:"600",400:"500",500:"400",600:"300",700:"200",800:"100",900:"50"}},modeList:["light","dark"],classPrefix:""},prefix:"",pseudos:["active","checked","disabled","enabled","default","empty","focus","focus-within","invalid","hover","link","visited","first-child","last-child","after","before","placeholder","selection"],theme:{breakpoints:{}},plugins:[]},this.atomCache=new Map,this.getAtomIds=function(){return Array.from(e.atomCache.keys())},this.compositions=new Map,this.getConfig=function(){return e.config},this.setConfig=function(n,i){void 0===i&&(i="deepmerge"),e.config="replace"===i?n:"merge"===i?o({},e.config,n):t(e.config,n)},this.getTheme=function(){return e.config.theme},this.setTheme=function(n){e.config.theme=t(e.config.theme||{},n)},this.getMode=function(){var t;return(null==(t=e.config.mode)?void 0:t.currentMode)||""},this.setMode=function(t){if(n.isBrowser){var o=e.config.mode.currentMode;o&&document.documentElement.classList.remove(o),t&&document.documentElement.classList.add(t),localStorage.setItem("fower-mode",t),e.setConfig({mode:{currentMode:t}})}},this.use=function(){var t;(t=e.config.plugins).push.apply(t,arguments)},this.addAtom=function(t,n){var o={isMatch:function(e){return"string"==typeof t?e===t:t instanceof RegExp&&t.test(e)},handleAtom:"function"==typeof n?n:function(e){return e.style=n,e}};return e.use(o),o},this.composeAtom=function(t,n){e.compositions.set(t,n)}}var i;return(i=[{key:"theme",get:function(){return this.config.theme}}])&&function(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}(e.prototype,i),e}(),r=new i;globalThis.__fower_store__=r,exports.Store=i,exports.store=r;
//# sourceMappingURL=store.cjs.production.min.js.map

@@ -164,7 +164,3 @@ import deepmerge from 'deepmerge';

this.composeAtom = function (atomName, cssObject) {
if (_this.compositions.get(atomName)) {
console.log("composed atom \"" + atomName + "\" is existed");
} else {
_this.compositions.set(atomName, cssObject);
}
_this.compositions.set(atomName, cssObject);
};

@@ -171,0 +167,0 @@ }

{
"name": "@fower/store",
"version": "1.31.0",
"version": "1.32.0",
"license": "MIT",

@@ -24,7 +24,7 @@ "main": "dist/index.js",

"dependencies": {
"@fower/types": "^1.31.0",
"@fower/utils": "^1.31.0",
"@fower/types": "^1.32.0",
"@fower/utils": "^1.32.0",
"deepmerge": "^4.2.2"
},
"gitHead": "4031b8cbff3b4a419d2129a389a92036183c9a1e"
"gitHead": "7d3be0bbe70399e3946db2e76b1c03595a3b84e1"
}

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc