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

@loadsmart/miranda-react

Package Overview
Dependencies
Maintainers
22
Versions
310
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@loadsmart/miranda-react - npm Package Compare versions

Comparing version 1.3.0 to 1.4.0

dist/components/Layout/Stack.d.ts

2

dist/components/Layout/Layout.d.ts
import Box from './Box';
import Group from './Group';
import Stack from './Stack';
declare const Layout: {

@@ -7,3 +8,4 @@ (): null;

Group: typeof Group;
Stack: typeof Stack;
};
export default Layout;

2

dist/index.js

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

"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react"),r=require("@loadsmart/miranda-wc");function t(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var n=t(e);function o(e,r){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&r.indexOf(n)<0&&(t[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)r.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(t[n[o]]=e[n[o]])}return t}const l=e.forwardRef((function(r,t){const{children:l,leading:a,trailing:u,onClick:i}=r,d=o(r,["children","leading","trailing","onClick"]),c=e.useRef(),s=e.useCallback((e=>{null==i||i(e)}),[i]),f=e.useCallback((e=>{var r,n;null!=e&&(c.current=e),null!=t&&(n=e,"function"==typeof(r=t)?r(n):r.current=n)}),[]);return e.useEffect((function(){if(null==c.current)return;const e=c.current;return e.addEventListener("click",s),function(){e.removeEventListener("click",s)}}),[]),n.default.createElement("m-button",Object.assign({},d,{ref:f,role:"button"}),null!=a&&n.default.createElement("span",{slot:"leading"},a),l,null!=u&&n.default.createElement("span",{slot:"trailing"},u))}));function a(e){var{padding:t=r.defaultBoxProps.padding,backgroundColor:l,borderRadius:a=r.defaultBoxProps.borderRadius,borderWidth:u=r.defaultBoxProps.borderWidth,borderColor:i=r.defaultBoxProps.borderColor,textAlign:d=r.defaultBoxProps.textAlign,children:c}=e,s=o(e,["padding","backgroundColor","borderRadius","borderWidth","borderColor","textAlign","children"]);const f={padding:t,"background-color":l,"border-radius":a,"border-width":u,"border-color":i,"text-align":d};return n.default.createElement("m-box",Object.assign({},f,s),c)}function u(e){var{gap:t=r.defaultGroupProps.gap,align:l=r.defaultGroupProps.align,justify:a=r.defaultGroupProps.justify,children:u}=e,i=o(e,["gap","align","justify","children"]);return n.default.createElement("m-group",Object.assign({gap:t,align:l,justify:a},i),u)}const i=()=>null;i.Box=a,i.Group=u,exports.Box=a,exports.Button=l,exports.Group=u,exports.Layout=i,exports.Text=function(e){var{children:r}=e,t=o(e,["children"]);return n.default.createElement("m-text",Object.assign({},t),r)};
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react"),r=require("@loadsmart/miranda-wc");function t(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var n=t(e);function o(e,r){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&r.indexOf(n)<0&&(t[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)r.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(t[n[o]]=e[n[o]])}return t}const a=e.forwardRef((function(r,t){const{children:a,leading:l,trailing:u,onClick:i}=r,d=o(r,["children","leading","trailing","onClick"]),c=e.useRef(),s=e.useCallback((e=>{null==i||i(e)}),[i]),f=e.useCallback((e=>{var r,n;null!=e&&(c.current=e),null!=t&&(n=e,"function"==typeof(r=t)?r(n):r.current=n)}),[]);return e.useEffect((function(){if(null==c.current)return;const e=c.current;return e.addEventListener("click",s),function(){e.removeEventListener("click",s)}}),[]),n.default.createElement("m-button",Object.assign({},d,{ref:f,role:"button"}),null!=l&&n.default.createElement("span",{slot:"leading"},l),a,null!=u&&n.default.createElement("span",{slot:"trailing"},u))}));function l(e){var{padding:t=r.defaultBoxProps.padding,backgroundColor:a,borderRadius:l=r.defaultBoxProps.borderRadius,borderWidth:u=r.defaultBoxProps.borderWidth,borderColor:i=r.defaultBoxProps.borderColor,textAlign:d=r.defaultBoxProps.textAlign,children:c}=e,s=o(e,["padding","backgroundColor","borderRadius","borderWidth","borderColor","textAlign","children"]);const f={padding:t,"background-color":a,"border-radius":l,"border-width":u,"border-color":i,"text-align":d};return n.default.createElement("m-box",Object.assign({},f,s),c)}function u(e){var{gap:t=r.defaultGroupProps.gap,align:a=r.defaultGroupProps.align,justify:l=r.defaultGroupProps.justify,children:u}=e,i=o(e,["gap","align","justify","children"]);return n.default.createElement("m-group",Object.assign({gap:t,align:a,justify:l},i),u)}const i=()=>null;i.Box=l,i.Group=u,i.Stack=function(e){var{gap:t=r.defaultStackProps.gap,align:a=r.defaultStackProps.align,justify:l=r.defaultStackProps.justify,children:u}=e,i=o(e,["gap","align","justify","children"]);return n.default.createElement("m-stack",Object.assign({gap:t,align:a,justify:l},i),u)},exports.Box=l,exports.Button=a,exports.Group=u,exports.Layout=i,exports.Text=function(e){var{children:r}=e,t=o(e,["children"]);return n.default.createElement("m-text",Object.assign({},t),r)};
//# sourceMappingURL=index.js.map
{
"name": "@loadsmart/miranda-react",
"version": "1.3.0",
"version": "1.4.0",
"description": "React component library based on Miranda Web Components",

@@ -5,0 +5,0 @@ "main": "dist",

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