@loadsmart/miranda-react
Advanced tools
Comparing version 1.21.2 to 1.22.0
@@ -12,2 +12,3 @@ export * from './components/Banner'; | ||
export * from './components/RadioGroup'; | ||
export * from './components/Tabs'; | ||
export * from './components/Tag'; | ||
@@ -14,0 +15,0 @@ export * from './components/Text'; |
@@ -6,3 +6,3 @@ "use strict";var n=require("react/jsx-runtime"),e=require("react"),i=require("@loadsmart/miranda-wc");function t(n){var e=Object.create(null);return n&&Object.keys(n).forEach((function(i){if("default"!==i){var t=Object.getOwnPropertyDescriptor(n,i);Object.defineProperty(e,i,t.get?t:{enumerable:!0,get:function(){return n[i]}})}})),e.default=n,Object.freeze(e)}var r=t(e);function s(n,e){var i={};for(var t in n)Object.prototype.hasOwnProperty.call(n,t)&&e.indexOf(t)<0&&(i[t]=n[t]);if(null!=n&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(t=Object.getOwnPropertySymbols(n);r<t.length;r++)e.indexOf(t[r])<0&&Object.prototype.propertyIsEnumerable.call(n,t[r])&&(i[t[r]]=n[t[r]])}return i} | ||
* SPDX-License-Identifier: BSD-3-Clause | ||
*/const a=new Set(["children","localName","ref","style","className"]),l=new WeakMap,o=(n,e,i,t,r)=>{const s=null==r?void 0:r[e];void 0!==s?i!==t&&((n,e,i)=>{let t=l.get(n);void 0===t&&l.set(n,t=new Map);let r=t.get(e);void 0!==i?void 0===r?(t.set(e,r={handleEvent:i}),n.addEventListener(e,r)):r.handleEvent=i:void 0!==r&&(t.delete(e),n.removeEventListener(e,r))})(n,s,i):n[e]=i},c=(n,i,t,r,l)=>{const c=new Set(Object.keys(null!=r?r:{}));class d extends e.Component{constructor(){super(...arguments),this._element=null}_updateElement(n){if(null!==this._element)for(const e in this._elementProps)o(this._element,e,this.props[e],n?n[e]:void 0,r)}componentDidMount(){this._updateElement()}componentDidUpdate(n){this._updateElement(n)}render(){const n=this.props,{__forwardedRef:r}=n,l=s(n,["__forwardedRef"]);void 0!==this._ref&&this._userRef===r||(this._ref=n=>{null===this._element&&(this._element=n),null!==r&&((n,e)=>{"function"==typeof n?n(e):n.current=e})(r,n),this._userRef=r}),this._elementProps={};const o={ref:this._ref};for(const[n,e]of Object.entries(l))c.has(n)||!a.has(n)&&!(n in HTMLElement.prototype)&&n in t.prototype?this._elementProps[n]=e:o["className"===n?"class":n]=e;return e.createElement(i,o)}}d.displayName=null!=l?l:t.name;const g=e.forwardRef(((n,i)=>e.createElement(d,Object.assign(Object.assign({},n),{__forwardedRef:i}),n.children)));return g.displayName=d.displayName,g},d=c(0,"m-banner-action-primary",i.BannerActionPrimary);function g(e){const{leading:i,trailing:t,children:r}=e,a=s(e,["leading","trailing","children"]);return n.jsxs(d,Object.assign({},a,{children:[null!=i&&n.jsx("span",Object.assign({slot:"leading"},{children:i})),r,null!=t&&n.jsx("span",Object.assign({slot:"trailing"},{children:t}))]}))}function u(e){var i=s(e,[]);return n.jsx("m-banner-actions",Object.assign({},i))}g.displayName="BannerActionPrimary",u.displayName="BannerActions";const h=c(0,"m-banner-action-secondary",i.BannerActionSecondary);function p(e){const{leading:i,trailing:t,children:r}=e,a=s(e,["leading","trailing","children"]);return n.jsxs(h,Object.assign({},a,{children:[null!=i&&n.jsx("span",Object.assign({slot:"leading"},{children:i})),r,null!=t&&n.jsx("span",Object.assign({slot:"trailing"},{children:t}))]}))}function j(e){var i=s(e,[]);return n.jsx("m-banner-description",Object.assign({},i))}function m(e){var i=s(e,[]);return n.jsx("m-banner-icon",Object.assign({},i))}function b(e){var i=s(e,[]);return n.jsx("m-banner-title",Object.assign({},i))}p.displayName="BannerActionSecondary",j.displayName="BannerDescription",m.displayName="BannerIcon",b.displayName="BannerTitle";const f=c(0,"m-banner",i.Banner,{onDismiss:"m-dismiss"},"WiredBanner");function x(e){return n.jsx(f,Object.assign({},e))}x.displayName="Banner",x.ActionPrimary=g,x.Actions=u,x.ActionSecondary=p,x.Description=j,x.Icon=m,x.Title=b;const O=c(0,"m-button",i.Button);const y=c(0,"m-card",i.Card);function v(e){var{children:i}=e,t=s(e,["children"]);return n.jsx(y,Object.assign({},t,{children:i}))}v.Title=function(e){var{children:i,leading:t}=e,r=s(e,["children","leading"]);return n.jsxs("m-card-title",Object.assign({},r,{slot:"title"},{children:[null!=t&&n.jsx("span",Object.assign({slot:"leading"},{children:t})),i]}))},v.Subtitle=function(e){var{children:i}=e,t=s(e,["children"]);return n.jsx("m-card-subtitle",Object.assign({},t,{slot:"subtitle"},{children:i}))},v.Body=function(e){var{children:i}=e,t=s(e,["children"]);return n.jsx("m-card-body",Object.assign({slot:"body"},t,{children:i}))};const S=c(0,"m-checkbox",i.Checkbox,{onChange:"m-change"},"WiredCheckbox");const P=c(0,"m-dialog-action-primary",i.DialogActionPrimary,{},"WiredDialogActionPrimary");const D=c(0,"m-dialog-action-secondary",i.DialogActionSecondary,{},"WiredDialogActionSecondary");const w=c(0,"m-dialog-action-tertiary",i.DialogActionTertiary,{},"WiredDialogActionTertiary");const A=c(0,"m-dialog-actions",i.DialogActions,{},"WiredDialogActions");const C=c(0,"m-dialog-body",i.DialogBody,{},"WiredDialogActions");const G=c(0,"m-dialog-close",i.DialogClose,{onClose:"m-close"},"WiredDialogClose");const _=c(0,"m-dialog-footer",i.DialogFooter,{},"WiredDialogFooter");const B=c(0,"m-dialog-header",i.DialogHeader,{},"WiredDialogHeader");const W=c(0,"m-dialog",i.Dialog,{onClose:"m-close",onOpening:"m-opening",onOpened:"m-opened",onClosing:"m-closing",onClosed:"m-closed"},"WiredDialog");function T(e){return n.jsx(W,Object.assign({},e))}T.ActionPrimary=function(e){const{leading:i,trailing:t,children:r}=e,a=s(e,["leading","trailing","children"]);return n.jsxs(P,Object.assign({},a,{children:[null!=i&&n.jsx("span",Object.assign({slot:"leading"},{children:i})),r,null!=t&&n.jsx("span",Object.assign({slot:"trailing"},{children:t}))]}))},T.ActionSecondary=function(e){const{leading:i,trailing:t,children:r}=e,a=s(e,["leading","trailing","children"]);return n.jsxs(D,Object.assign({},a,{children:[null!=i&&n.jsx("span",Object.assign({slot:"leading"},{children:i})),r,null!=t&&n.jsx("span",Object.assign({slot:"trailing"},{children:t}))]}))},T.ActionTertiary=function(e){const{leading:i,trailing:t,children:r}=e,a=s(e,["leading","trailing","children"]);return n.jsxs(w,Object.assign({},a,{children:[null!=i&&n.jsx("span",Object.assign({slot:"leading"},{children:i})),r,null!=t&&n.jsx("span",Object.assign({slot:"trailing"},{children:t}))]}))},T.Actions=function(e){var i=s(e,[]);return n.jsx(A,Object.assign({},i))},T.Body=function(e){var i=s(e,[]);return n.jsx(C,Object.assign({},i))},T.Footer=function(e){var i=s(e,[]);return n.jsx(_,Object.assign({},i))},T.Close=function(e){return n.jsx(G,Object.assign({},e))},T.Header=function(e){var i=s(e,[]);return n.jsx(B,Object.assign({},i))};const E=c(0,"m-divider",i.Divider,{},"WiredDivider");const N=c(0,"m-field",i.Field);function k(e){var{children:i}=e,t=s(e,["children"]);return n.jsx(N,Object.assign({},t,{children:i}))}k.Label=function(e){var{children:i}=e,t=s(e,["children"]);return n.jsx("m-field-label",Object.assign({},t,{slot:"label"},{children:i}))},k.Hint=function(e){var{children:i,leading:t}=e,r=s(e,["children","leading"]);return n.jsxs("m-field-hint",Object.assign({},r,{slot:"hint"},{children:[null!=t&&n.jsx("span",Object.assign({slot:"leading"},{children:t})),i]}))};const R=c(0,"m-box",i.Box);function I(e){return n.jsx(R,Object.assign({},e))}const L=c(0,"m-group",i.Group);function F(e){var{gap:t=i.defaultGroupProps.gap,align:r=i.defaultGroupProps.align,justify:a=i.defaultGroupProps.justify,children:l}=e,o=s(e,["gap","align","justify","children"]);return n.jsx(L,Object.assign({gap:t,align:r,justify:a},o,{children:l}))}const H=c(0,"m-stack",i.Stack);function M(e){var{gap:t=i.defaultStackProps.gap,align:r=i.defaultStackProps.align,justify:a=i.defaultStackProps.justify,children:l}=e,o=s(e,["gap","align","justify","children"]);return n.jsx(H,Object.assign({gap:t,align:r,justify:a},o,{children:l}))}const q=c(0,"m-grid",i.Grid);function V(e){var{gap:t=i.defaultGridProps.gap,rowGap:r,columnGap:a,minColumnWidth:l=i.defaultGridProps.minColumnWidth,children:o}=e,c=s(e,["gap","rowGap","columnGap","minColumnWidth","children"]);const d={gap:t,"row-gap":r,"column-gap":a,"min-column-width":l};return n.jsx(q,Object.assign({},d,c,{children:o}))}function Z(e){var{gap:t=i.defaultSidebarProps.gap,sideWidth:r=i.defaultSidebarProps.sideWidth,minContentWidth:a=i.defaultSidebarProps.minContentWidth,reversed:l=i.defaultSidebarProps.reversed,children:o}=e,c=s(e,["gap","sideWidth","minContentWidth","reversed","children"]);const d=Object.assign({gap:t,"side-width":r,"min-content-width":a},l&&{reversed:l});return n.jsx("m-sidebar",Object.assign({},d,c,{children:o}))}Z.Side=function(e){var{children:i}=e,t=s(e,["children"]);return n.jsx(I,Object.assign({slot:"sidebar"},t,{children:i}))},Z.Content=function(e){var{children:i}=e,t=s(e,["children"]);return n.jsx(I,Object.assign({slot:"content"},t,{children:i}))};const z=c(0,"m-switcher",i.Switcher);function U(e){var{gap:t=i.defaultSwitcherProps.gap,rowGap:r,columnGap:a,threshold:l=i.defaultSwitcherProps.threshold,limit:o,children:c}=e,d=s(e,["gap","rowGap","columnGap","threshold","limit","children"]);const g={gap:t,"row-gap":r,"column-gap":a,threshold:l,limit:o};return n.jsx(z,Object.assign({},g,d,{children:c}))}const J=()=>null;J.Box=I,J.Group=F,J.Stack=M,J.Grid=V,J.Sidebar=Z,J.Switcher=U;const K=c(0,"m-progress-bar",i.ProgressBar);const Q=c(0,"m-progress-bar-countdown",i.ProgressBarCountdown);const X=c(0,"m-radio-group",i.RadioGroup,{onChange:"m-change"}),Y=c(0,"m-radio",i.Radio);const $=c(0,"m-tag",i.Tag);const nn=c(0,"m-text",i.Text);const en=c(0,"m-text-field",i.TextField,{onInput:"input",onChange:"change",onClear:"m-clear"});const tn=c(0,"m-toggle",i.Toggle);function rn(e){const{children:i,leading:t}=e,r=s(e,["children","leading"]);return n.jsxs(tn,Object.assign({},r,{children:[null!=t&&n.jsx("span",Object.assign({slot:"leading"},{children:t})),i]}))}const sn=c(0,"m-toggle-group",i.ToggleGroup,{onChange:"m-change"});Object.defineProperty(exports,"DIALOG_SIZES",{enumerable:!0,get:function(){return i.DIALOG_SIZES}}),Object.defineProperty(exports,"DIALOG_VARIANTS",{enumerable:!0,get:function(){return i.DIALOG_VARIANTS}}),exports.Banner=x,exports.Box=I,exports.Button=function(e){const{leading:i,trailing:t,children:r}=e,a=s(e,["leading","trailing","children"]);return n.jsxs(O,Object.assign({},a,{children:[null!=i&&n.jsx("span",Object.assign({slot:"leading"},{children:i})),r,null!=t&&n.jsx("span",Object.assign({slot:"trailing"},{children:t}))]}))},exports.Card=v,exports.Checkbox=function(e){const{children:i,leading:t}=e,r=s(e,["children","leading"]);return n.jsxs(S,Object.assign({},r,{children:[null!=t&&n.jsx("span",Object.assign({slot:"leading"},{children:t})),i]}))},exports.Dialog=T,exports.Divider=function(e){return n.jsx(E,Object.assign({},e))},exports.Field=k,exports.Grid=V,exports.Group=F,exports.Layout=J,exports.ProgressBar=function(e){return n.jsx(K,Object.assign({},e))},exports.ProgressBarCountdown=function(e){return n.jsx(Q,Object.assign({},e))},exports.Radio=function(e){const{children:i,leading:t}=e,r=s(e,["children","leading"]);return n.jsxs(Y,Object.assign({},r,{children:[null!=t&&n.jsx("span",Object.assign({slot:"leading"},{children:t})),i]}))},exports.RadioGroup=X,exports.Sidebar=Z,exports.Stack=M,exports.Switcher=U,exports.Tag=function(e){const{leading:i,children:t}=e,r=s(e,["leading","children"]);return n.jsxs($,Object.assign({},r,{children:[null!=i&&n.jsx("span",Object.assign({slot:"leading"},{children:i})),t]}))},exports.Text=function(e){var{children:i}=e,t=s(e,["children"]);return n.jsx(nn,Object.assign({},t,{children:i}))},exports.TextField=function(e){var{leading:i,trailing:t}=e,r=s(e,["leading","trailing"]);return n.jsxs(en,Object.assign({},r,{children:[null!=i&&n.jsx("div",Object.assign({slot:"leading"},{children:i})),null!=t&&n.jsx("div",Object.assign({slot:"trailing"},{children:t}))]}))},exports.Toggle=rn,exports.ToggleGroup=function(e){const{value:i,options:t,children:a,disabled:l}=e,o=s(e,["value","options","children","disabled"]),c=r.useRef(null);return r.useEffect((function(){null!=c.current&&(c.current.value=i)}),[i]),n.jsx(sn,Object.assign({ref:c,disabled:l},o,{children:null!=a?a:(t||[]).map((function(e){const{label:i,value:t}=e,r=s(e,["label","value"]);return n.jsx(rn,Object.assign({},r,{disabled:Boolean(l||e.disabled),value:t},{children:i}),t)}))}))}; | ||
*/const a=new Set(["children","localName","ref","style","className"]),l=new WeakMap,o=(n,e,i,t,r)=>{const s=null==r?void 0:r[e];void 0!==s?i!==t&&((n,e,i)=>{let t=l.get(n);void 0===t&&l.set(n,t=new Map);let r=t.get(e);void 0!==i?void 0===r?(t.set(e,r={handleEvent:i}),n.addEventListener(e,r)):r.handleEvent=i:void 0!==r&&(t.delete(e),n.removeEventListener(e,r))})(n,s,i):n[e]=i},c=(n,i,t,r,l)=>{const c=new Set(Object.keys(null!=r?r:{}));class d extends e.Component{constructor(){super(...arguments),this._element=null}_updateElement(n){if(null!==this._element)for(const e in this._elementProps)o(this._element,e,this.props[e],n?n[e]:void 0,r)}componentDidMount(){this._updateElement()}componentDidUpdate(n){this._updateElement(n)}render(){const n=this.props,{__forwardedRef:r}=n,l=s(n,["__forwardedRef"]);void 0!==this._ref&&this._userRef===r||(this._ref=n=>{null===this._element&&(this._element=n),null!==r&&((n,e)=>{"function"==typeof n?n(e):n.current=e})(r,n),this._userRef=r}),this._elementProps={};const o={ref:this._ref};for(const[n,e]of Object.entries(l))c.has(n)||!a.has(n)&&!(n in HTMLElement.prototype)&&n in t.prototype?this._elementProps[n]=e:o["className"===n?"class":n]=e;return e.createElement(i,o)}}d.displayName=null!=l?l:t.name;const g=e.forwardRef(((n,i)=>e.createElement(d,Object.assign(Object.assign({},n),{__forwardedRef:i}),n.children)));return g.displayName=d.displayName,g},d=c(0,"m-banner-action-primary",i.BannerActionPrimary);function g(e){const{leading:i,trailing:t,children:r}=e,a=s(e,["leading","trailing","children"]);return n.jsxs(d,Object.assign({},a,{children:[null!=i&&n.jsx("span",Object.assign({slot:"leading"},{children:i})),r,null!=t&&n.jsx("span",Object.assign({slot:"trailing"},{children:t}))]}))}function u(e){var i=s(e,[]);return n.jsx("m-banner-actions",Object.assign({},i))}g.displayName="BannerActionPrimary",u.displayName="BannerActions";const h=c(0,"m-banner-action-secondary",i.BannerActionSecondary);function p(e){const{leading:i,trailing:t,children:r}=e,a=s(e,["leading","trailing","children"]);return n.jsxs(h,Object.assign({},a,{children:[null!=i&&n.jsx("span",Object.assign({slot:"leading"},{children:i})),r,null!=t&&n.jsx("span",Object.assign({slot:"trailing"},{children:t}))]}))}function j(e){var i=s(e,[]);return n.jsx("m-banner-description",Object.assign({},i))}function b(e){var i=s(e,[]);return n.jsx("m-banner-icon",Object.assign({},i))}function m(e){var i=s(e,[]);return n.jsx("m-banner-title",Object.assign({},i))}p.displayName="BannerActionSecondary",j.displayName="BannerDescription",b.displayName="BannerIcon",m.displayName="BannerTitle";const f=c(0,"m-banner",i.Banner,{onDismiss:"m-dismiss"},"WiredBanner");function x(e){return n.jsx(f,Object.assign({},e))}x.displayName="Banner",x.ActionPrimary=g,x.Actions=u,x.ActionSecondary=p,x.Description=j,x.Icon=b,x.Title=m;const O=c(0,"m-button",i.Button);const y=c(0,"m-card",i.Card);function v(e){var{children:i}=e,t=s(e,["children"]);return n.jsx(y,Object.assign({},t,{children:i}))}v.Title=function(e){var{children:i,leading:t}=e,r=s(e,["children","leading"]);return n.jsxs("m-card-title",Object.assign({},r,{slot:"title"},{children:[null!=t&&n.jsx("span",Object.assign({slot:"leading"},{children:t})),i]}))},v.Subtitle=function(e){var{children:i}=e,t=s(e,["children"]);return n.jsx("m-card-subtitle",Object.assign({},t,{slot:"subtitle"},{children:i}))},v.Body=function(e){var{children:i}=e,t=s(e,["children"]);return n.jsx("m-card-body",Object.assign({slot:"body"},t,{children:i}))};const P=c(0,"m-checkbox",i.Checkbox,{onChange:"m-change"},"WiredCheckbox");const S=c(0,"m-dialog-action-primary",i.DialogActionPrimary,{},"WiredDialogActionPrimary");const D=c(0,"m-dialog-action-secondary",i.DialogActionSecondary,{},"WiredDialogActionSecondary");const w=c(0,"m-dialog-action-tertiary",i.DialogActionTertiary,{},"WiredDialogActionTertiary");const A=c(0,"m-dialog-actions",i.DialogActions,{},"WiredDialogActions");const C=c(0,"m-dialog-body",i.DialogBody,{},"WiredDialogActions");const G=c(0,"m-dialog-close",i.DialogClose,{onClose:"m-close"},"WiredDialogClose");const T=c(0,"m-dialog-footer",i.DialogFooter,{},"WiredDialogFooter");const _=c(0,"m-dialog-header",i.DialogHeader,{},"WiredDialogHeader");const B=c(0,"m-dialog",i.Dialog,{onClose:"m-close",onOpening:"m-opening",onOpened:"m-opened",onClosing:"m-closing",onClosed:"m-closed"},"WiredDialog");function W(e){return n.jsx(B,Object.assign({},e))}W.ActionPrimary=function(e){const{leading:i,trailing:t,children:r}=e,a=s(e,["leading","trailing","children"]);return n.jsxs(S,Object.assign({},a,{children:[null!=i&&n.jsx("span",Object.assign({slot:"leading"},{children:i})),r,null!=t&&n.jsx("span",Object.assign({slot:"trailing"},{children:t}))]}))},W.ActionSecondary=function(e){const{leading:i,trailing:t,children:r}=e,a=s(e,["leading","trailing","children"]);return n.jsxs(D,Object.assign({},a,{children:[null!=i&&n.jsx("span",Object.assign({slot:"leading"},{children:i})),r,null!=t&&n.jsx("span",Object.assign({slot:"trailing"},{children:t}))]}))},W.ActionTertiary=function(e){const{leading:i,trailing:t,children:r}=e,a=s(e,["leading","trailing","children"]);return n.jsxs(w,Object.assign({},a,{children:[null!=i&&n.jsx("span",Object.assign({slot:"leading"},{children:i})),r,null!=t&&n.jsx("span",Object.assign({slot:"trailing"},{children:t}))]}))},W.Actions=function(e){var i=s(e,[]);return n.jsx(A,Object.assign({},i))},W.Body=function(e){var i=s(e,[]);return n.jsx(C,Object.assign({},i))},W.Footer=function(e){var i=s(e,[]);return n.jsx(T,Object.assign({},i))},W.Close=function(e){return n.jsx(G,Object.assign({},e))},W.Header=function(e){var i=s(e,[]);return n.jsx(_,Object.assign({},i))};const E=c(0,"m-divider",i.Divider,{},"WiredDivider");const N=c(0,"m-field",i.Field);function k(e){var{children:i}=e,t=s(e,["children"]);return n.jsx(N,Object.assign({},t,{children:i}))}k.Label=function(e){var{children:i}=e,t=s(e,["children"]);return n.jsx("m-field-label",Object.assign({},t,{slot:"label"},{children:i}))},k.Hint=function(e){var{children:i,leading:t}=e,r=s(e,["children","leading"]);return n.jsxs("m-field-hint",Object.assign({},r,{slot:"hint"},{children:[null!=t&&n.jsx("span",Object.assign({slot:"leading"},{children:t})),i]}))};const R=c(0,"m-box",i.Box);function I(e){return n.jsx(R,Object.assign({},e))}const L=c(0,"m-group",i.Group);function F(e){var{gap:t=i.defaultGroupProps.gap,align:r=i.defaultGroupProps.align,justify:a=i.defaultGroupProps.justify,children:l}=e,o=s(e,["gap","align","justify","children"]);return n.jsx(L,Object.assign({gap:t,align:r,justify:a},o,{children:l}))}const H=c(0,"m-stack",i.Stack);function M(e){var{gap:t=i.defaultStackProps.gap,align:r=i.defaultStackProps.align,justify:a=i.defaultStackProps.justify,children:l}=e,o=s(e,["gap","align","justify","children"]);return n.jsx(H,Object.assign({gap:t,align:r,justify:a},o,{children:l}))}const q=c(0,"m-grid",i.Grid);function V(e){var{gap:t=i.defaultGridProps.gap,rowGap:r,columnGap:a,minColumnWidth:l=i.defaultGridProps.minColumnWidth,children:o}=e,c=s(e,["gap","rowGap","columnGap","minColumnWidth","children"]);const d={gap:t,"row-gap":r,"column-gap":a,"min-column-width":l};return n.jsx(q,Object.assign({},d,c,{children:o}))}function Z(e){var{gap:t=i.defaultSidebarProps.gap,sideWidth:r=i.defaultSidebarProps.sideWidth,minContentWidth:a=i.defaultSidebarProps.minContentWidth,reversed:l=i.defaultSidebarProps.reversed,children:o}=e,c=s(e,["gap","sideWidth","minContentWidth","reversed","children"]);const d=Object.assign({gap:t,"side-width":r,"min-content-width":a},l&&{reversed:l});return n.jsx("m-sidebar",Object.assign({},d,c,{children:o}))}Z.Side=function(e){var{children:i}=e,t=s(e,["children"]);return n.jsx(I,Object.assign({slot:"sidebar"},t,{children:i}))},Z.Content=function(e){var{children:i}=e,t=s(e,["children"]);return n.jsx(I,Object.assign({slot:"content"},t,{children:i}))};const z=c(0,"m-switcher",i.Switcher);function U(e){var{gap:t=i.defaultSwitcherProps.gap,rowGap:r,columnGap:a,threshold:l=i.defaultSwitcherProps.threshold,limit:o,children:c}=e,d=s(e,["gap","rowGap","columnGap","threshold","limit","children"]);const g={gap:t,"row-gap":r,"column-gap":a,threshold:l,limit:o};return n.jsx(z,Object.assign({},g,d,{children:c}))}const J=()=>null;J.Box=I,J.Group=F,J.Stack=M,J.Grid=V,J.Sidebar=Z,J.Switcher=U;const K=c(0,"m-progress-bar",i.ProgressBar);const Q=c(0,"m-progress-bar-countdown",i.ProgressBarCountdown);const X=c(0,"m-radio-group",i.RadioGroup,{onChange:"m-change"}),Y=c(0,"m-radio",i.Radio);const $=c(0,"m-tab",i.Tab);function nn(e){var{children:i,leading:t}=e,r=s(e,["children","leading"]);return n.jsxs($,Object.assign({},r,{children:[null!=t&&n.jsx("span",Object.assign({slot:"leading"},{children:t})),i]}))}const en=c(0,"m-tab-panel",i.TabPanel);function tn(e){var{children:i}=e,t=s(e,["children"]);return n.jsx(en,Object.assign({},t,{children:i}))}const rn=c(0,"m-tabs",i.Tabs,{onTabChange:"m-tab-change"});function sn(e){var{children:i}=e,t=s(e,["children"]);return n.jsx(rn,Object.assign({},t,{children:i}))}sn.Tab=nn,sn.Panel=tn;const an=c(0,"m-tag",i.Tag);const ln=c(0,"m-text",i.Text);const on=c(0,"m-text-field",i.TextField,{onInput:"input",onChange:"change",onClear:"m-clear"});const cn=c(0,"m-toggle",i.Toggle);function dn(e){const{children:i,leading:t}=e,r=s(e,["children","leading"]);return n.jsxs(cn,Object.assign({},r,{children:[null!=t&&n.jsx("span",Object.assign({slot:"leading"},{children:t})),i]}))}const gn=c(0,"m-toggle-group",i.ToggleGroup,{onChange:"m-change"});Object.defineProperty(exports,"DIALOG_SIZES",{enumerable:!0,get:function(){return i.DIALOG_SIZES}}),Object.defineProperty(exports,"DIALOG_VARIANTS",{enumerable:!0,get:function(){return i.DIALOG_VARIANTS}}),exports.Banner=x,exports.Box=I,exports.Button=function(e){const{leading:i,trailing:t,children:r}=e,a=s(e,["leading","trailing","children"]);return n.jsxs(O,Object.assign({},a,{children:[null!=i&&n.jsx("span",Object.assign({slot:"leading"},{children:i})),r,null!=t&&n.jsx("span",Object.assign({slot:"trailing"},{children:t}))]}))},exports.Card=v,exports.Checkbox=function(e){const{children:i,leading:t}=e,r=s(e,["children","leading"]);return n.jsxs(P,Object.assign({},r,{children:[null!=t&&n.jsx("span",Object.assign({slot:"leading"},{children:t})),i]}))},exports.Dialog=W,exports.Divider=function(e){return n.jsx(E,Object.assign({},e))},exports.Field=k,exports.Grid=V,exports.Group=F,exports.Layout=J,exports.ProgressBar=function(e){return n.jsx(K,Object.assign({},e))},exports.ProgressBarCountdown=function(e){return n.jsx(Q,Object.assign({},e))},exports.Radio=function(e){const{children:i,leading:t}=e,r=s(e,["children","leading"]);return n.jsxs(Y,Object.assign({},r,{children:[null!=t&&n.jsx("span",Object.assign({slot:"leading"},{children:t})),i]}))},exports.RadioGroup=X,exports.Sidebar=Z,exports.Stack=M,exports.Switcher=U,exports.Tab=nn,exports.TabPanel=tn,exports.Tabs=sn,exports.Tag=function(e){const{leading:i,children:t}=e,r=s(e,["leading","children"]);return n.jsxs(an,Object.assign({},r,{children:[null!=i&&n.jsx("span",Object.assign({slot:"leading"},{children:i})),t]}))},exports.Text=function(e){var{children:i}=e,t=s(e,["children"]);return n.jsx(ln,Object.assign({},t,{children:i}))},exports.TextField=function(e){var{leading:i,trailing:t}=e,r=s(e,["leading","trailing"]);return n.jsxs(on,Object.assign({},r,{children:[null!=i&&n.jsx("div",Object.assign({slot:"leading"},{children:i})),null!=t&&n.jsx("div",Object.assign({slot:"trailing"},{children:t}))]}))},exports.Toggle=dn,exports.ToggleGroup=function(e){const{value:i,options:t,children:a,disabled:l}=e,o=s(e,["value","options","children","disabled"]),c=r.useRef(null);return r.useEffect((function(){null!=c.current&&(c.current.value=i)}),[i]),n.jsx(gn,Object.assign({ref:c,disabled:l},o,{children:null!=a?a:(t||[]).map((function(e){const{label:i,value:t}=e,r=s(e,["label","value"]);return n.jsx(dn,Object.assign({},r,{disabled:Boolean(l||e.disabled),value:t},{children:i}),t)}))}))}; | ||
//# sourceMappingURL=index.js.map |
{ | ||
"name": "@loadsmart/miranda-react", | ||
"version": "1.21.2", | ||
"version": "1.22.0", | ||
"description": "React component library based on Miranda Web Components", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
Sorry, the diff of this file is not supported yet
103792
114
1129