Comparing version 1.0.6 to 1.0.7
@@ -1,1 +0,1 @@ | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var React=require("react");function _interopDefaultLegacy(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var React__default=_interopDefaultLegacy(React),__assign=function(){return(__assign=Object.assign||function(t){for(var o,e=1,n=arguments.length;e<n;e++)for(var r in o=arguments[e])Object.prototype.hasOwnProperty.call(o,r)&&(t[r]=o[r]);return t}).apply(this,arguments)};function __rest(t,o){var e={};for(r in t)Object.prototype.hasOwnProperty.call(t,r)&&o.indexOf(r)<0&&(e[r]=t[r]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols)for(var n=0,r=Object.getOwnPropertySymbols(t);n<r.length;n++)o.indexOf(r[n])<0&&Object.prototype.propertyIsEnumerable.call(t,r[n])&&(e[r[n]]=t[r[n]]);return e}var e=function(t){for(var o=t[0].toUpperCase(),e=1;e<t.length;e++)o+=t[e];return o};function styleInject(t,o){var e,n,o=(o=void 0===o?{}:o).insertAt;t&&"undefined"!=typeof document&&(e=document.head||document.getElementsByTagName("head")[0],(n=document.createElement("style")).type="text/css","top"===o&&e.firstChild?e.insertBefore(n,e.firstChild):e.appendChild(n),n.styleSheet?n.styleSheet.cssText=t:n.appendChild(document.createTextNode(t)))}Object.freeze({__proto__:null,cap:e});var css_248z='.index-module_storybookButton__1WDkY {\n font-family: "Nunito Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;\n font-weight: 700;\n border: 0;\n border-radius: 3em;\n cursor: pointer;\n display: inline-block;\n line-height: 1;\n}\n\n.index-module_storybookButtonPrimary__thpoG {\n color: white;\n background-color: #fd1e8e;\n}\n\n.index-module_storybookButtonSecondary__F-HDz {\n color: #333;\n background-color: transparent;\n box-shadow: rgba(0, 0, 0, 0.15) 0px 0px 0px 1px inset;\n}\n\n.index-module_storybookButtonSmall__4rGEM {\n font-size: 12px;\n padding: 10px 16px;\n}\n\n.index-module_storybookButtonMedium__1VD7c {\n font-size: 14px;\n padding: 11px 20px;\n}\n\n.index-module_storybookButtonLarge__CaF-c {\n font-size: 16px;\n padding: 12px 24px;\n}',style={storybookButton:"index-module_storybookButton__1WDkY",storybookButtonPrimary:"index-module_storybookButtonPrimary__thpoG",storybookButtonSecondary:"index-module_storybookButtonSecondary__F-HDz",storybookButtonSmall:"index-module_storybookButtonSmall__4rGEM",storybookButtonMedium:"index-module_storybookButtonMedium__1VD7c",storybookButtonLarge:"index-module_storybookButtonLarge__CaF-c"},Button=(styleInject(css_248z),function(t){var o=t.primary,o=void 0!==o&&o,n=t.size,n=void 0===n?"medium":n,r=t.backgroundColor,a=t.label,t=__rest(t,["primary","size","backgroundColor","label"]),o=o?style.storybookButtonPrimary:style.storybookButtonSecondary;return React__default.default.createElement("button",__assign({type:"button",className:"".concat(style.storybookButton," ").concat(style["storybookButton".concat(e(n))]," ").concat(o),style:{backgroundColor:r}},t),a)}),shira={Button:Button};exports.Button=Button,exports.default=shira; | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var React=require("react");function _interopDefaultLegacy(n){return n&&"object"==typeof n&&"default"in n?n:{default:n}}var React__default=_interopDefaultLegacy(React),__assign=function(){return(__assign=Object.assign||function(n){for(var e,t=1,o=arguments.length;t<o;t++)for(var r in e=arguments[t])Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}).apply(this,arguments)};function __rest(n,e){var t={};for(r in n)Object.prototype.hasOwnProperty.call(n,r)&&e.indexOf(r)<0&&(t[r]=n[r]);if(null!=n&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(n);o<r.length;o++)e.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(n,r[o])&&(t[r[o]]=n[r[o]]);return t}function styleInject(n,e){var t,o,e=(e=void 0===e?{}:e).insertAt;n&&"undefined"!=typeof document&&(t=document.head||document.getElementsByTagName("head")[0],(o=document.createElement("style")).type="text/css","top"===e&&t.firstChild?t.insertBefore(o,t.firstChild):t.appendChild(o),o.styleSheet?o.styleSheet.cssText=n:o.appendChild(document.createTextNode(n)))}var css_248z$3="/*! purgecss start ignore */\n/**\n * 1. Correct the line height in all browsers.\n * 2. Prevent adjustments of font size after orientation changes in iOS.\n */\nhtml {\n line-height: 1.15; /* 1 */\n -webkit-text-size-adjust: 100%; /* 2 */\n box-sizing: border-box;\n}\n\n*, *:before, *:after {\n box-sizing: inherit;\n}\n\n/* Sections\n ========================================================================== */\n/**\n * Remove the margin in all browsers.\n */\nbody {\n margin: 0 !important;\n padding: 0 !important;\n}\n\n/* Document\n ========================================================================== */\n/**\n * Render the `main` element consistently in IE.\n */\nmain {\n display: block;\n}\n\n/**\n * Correct the font size and margin on `h1` elements within `section` and\n * `article` contexts in Chrome, Firefox, and Safari.\n */\nh1 {\n font-size: 2em;\n}\n\nh1, h2, h3, h4, h5, h6 {\n margin: 0;\n}\n\n/* Grouping content\n ========================================================================== */\n/**\n * 1. Add the correct box sizing in Firefox.\n * 2. Show the overflow in Edge and IE.\n */\nhr {\n box-sizing: content-box; /* 1 */\n height: 0; /* 1 */\n overflow: visible; /* 2 */\n}\n\n/**\n * 1. Correct the inheritance and scaling of font size in all browsers.\n * 2. Correct the odd `em` font sizing in all browsers.\n */\npre {\n font-family: monospace, monospace; /* 1 */\n font-size: 1em; /* 2 */\n}\n\n/* Text-level semantics\n ========================================================================== */\n/**\n * Remove the gray background on active links in IE 10.\n */\na {\n background-color: transparent;\n}\n\n/**\n * 1. Remove the bottom border in Chrome 57-\n * 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari.\n */\nabbr[title] {\n border-bottom: none; /* 1 */\n text-decoration: underline; /* 2 */\n text-decoration: underline dotted; /* 2 */\n}\n\n/**\n * Add the correct font weight in Chrome, Edge, and Safari.\n */\nb,\nstrong {\n font-weight: bolder;\n}\n\n/**\n * 1. Correct the inheritance and scaling of font size in all browsers.\n * 2. Correct the odd `em` font sizing in all browsers.\n */\ncode,\nkbd,\nsamp {\n font-family: monospace, monospace; /* 1 */\n font-size: 1em; /* 2 */\n}\n\n/**\n * Add the correct font size in all browsers.\n */\nsmall {\n font-size: 80%;\n}\n\n/**\n * Prevent `sub` and `sup` elements from affecting the line height in\n * all browsers.\n */\nsub,\nsup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n}\n\nsub {\n bottom: -0.25em;\n}\n\nsup {\n top: -0.5em;\n}\n\n/* Embedded content\n ========================================================================== */\n/**\n * Remove the border on images inside links in IE 10.\n */\nimg {\n border-style: none;\n}\n\n/* Forms\n ========================================================================== */\n/**\n * 1. Change the font styles in all browsers.\n * 2. Remove the margin in Firefox and Safari.\n */\nbutton,\ninput,\noptgroup,\nselect,\ntextarea {\n font-family: inherit; /* 1 */\n font-size: 100%; /* 1 */\n line-height: 1.15; /* 1 */\n margin: 0; /* 2 */\n}\n\n/**\n * Show the overflow in IE.\n * 1. Show the overflow in Edge.\n */\nbutton,\ninput { /* 1 */\n overflow: visible;\n}\n\n/**\n * Remove the inheritance of text transform in Edge, Firefox, and IE.\n * 1. Remove the inheritance of text transform in Firefox.\n */\nbutton,\nselect { /* 1 */\n text-transform: none;\n}\n\n/**\n * Correct the inability to style clickable types in iOS and Safari.\n */\nbutton,\n[type=button],\n[type=reset],\n[type=submit] {\n -webkit-appearance: button;\n}\n\n/**\n * Remove the inner border and padding in Firefox.\n */\nbutton::-moz-focus-inner,\n[type=button]::-moz-focus-inner,\n[type=reset]::-moz-focus-inner,\n[type=submit]::-moz-focus-inner {\n border-style: none;\n padding: 0;\n}\n\n/**\n * Restore the focus styles unset by the previous rule.\n */\nbutton:-moz-focusring,\n[type=button]:-moz-focusring,\n[type=reset]:-moz-focusring,\n[type=submit]:-moz-focusring {\n outline: 1px dotted ButtonText;\n}\n\n/**\n * Correct the padding in Firefox.\n */\nfieldset {\n padding: 0.35em 0.75em 0.625em;\n}\n\n/**\n * 1. Correct the text wrapping in Edge and IE.\n * 2. Correct the color inheritance from `fieldset` elements in IE.\n * 3. Remove the padding so developers are not caught out when they zero out\n * `fieldset` elements in all browsers.\n */\nlegend {\n box-sizing: border-box; /* 1 */\n color: inherit; /* 2 */\n display: table; /* 1 */\n max-width: 100%; /* 1 */\n padding: 0; /* 3 */\n white-space: normal; /* 1 */\n}\n\n/**\n * Add the correct vertical alignment in Chrome, Firefox, and Opera.\n */\nprogress {\n vertical-align: baseline;\n}\n\n/**\n * Remove the default vertical scrollbar in IE 10+.\n */\ntextarea {\n overflow: auto;\n}\n\n/**\n * 1. Add the correct box sizing in IE 10.\n * 2. Remove the padding in IE 10.\n */\n[type=checkbox],\n[type=radio] {\n box-sizing: border-box; /* 1 */\n padding: 0; /* 2 */\n}\n\n/**\n * Correct the cursor style of increment and decrement buttons in Chrome.\n */\n[type=number]::-webkit-inner-spin-button,\n[type=number]::-webkit-outer-spin-button {\n height: auto;\n}\n\n/**\n * 1. Correct the odd appearance in Chrome and Safari.\n * 2. Correct the outline style in Safari.\n */\n[type=search] {\n -webkit-appearance: textfield; /* 1 */\n outline-offset: -2px; /* 2 */\n}\n\n/**\n * Remove the inner padding in Chrome and Safari on macOS.\n */\n[type=search]::-webkit-search-decoration {\n -webkit-appearance: none;\n}\n\n/**\n * 1. Correct the inability to style clickable types in iOS and Safari.\n * 2. Change font properties to `inherit` in Safari.\n */\n::-webkit-file-upload-button {\n -webkit-appearance: button; /* 1 */\n font: inherit; /* 2 */\n}\n\n/* Interactive\n ========================================================================== */\n/*\n * Add the correct display in Edge, IE 10+, and Firefox.\n */\ndetails {\n display: block;\n}\n\n/*\n * Add the correct display in all browsers.\n */\nsummary {\n display: list-item;\n}\n\n/* Misc\n ========================================================================== */\n/**\n * Add the correct display in IE 10+.\n */\ntemplate {\n display: none;\n}\n\n/**\n * Add the correct display in IE 10.\n */\n[hidden] {\n display: none;\n}\n\n/*! purgecss end ignore */",css_248z$2=(styleInject(css_248z$3),".base-module_main__xsrLc {\n font-family: Arial, sans-serif;\n font-size: 16px;\n color: #757575;\n padding: 0;\n margin: 0;\n background-color: #F3F8F2;\n}"),s$1={main:"base-module_main__xsrLc"},Base=(styleInject(css_248z$2),function(n){var e=n.children,t=n.backgroundColor,o=n.padding,r=n.margin,i=n.bodyHeight,i=void 0===i||i,a=n.style,n=__rest(n,["children","backgroundColor","padding","margin","bodyHeight","style"]);return React__default.default.createElement("div",__assign({className:"".concat(s$1.main),style:__assign({backgroundColor:t,padding:o,margin:r,height:i?"100vh":"auto"},a)},n),e)}),e=function(n){for(var e=n[0].toUpperCase(),t=1;t<n.length;t++)e+=n[t];return e},css_248z$1=(Object.freeze({__proto__:null,cap:e}),'.button-module_storybookButton__C78bP {\n font-family: "Nunito Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;\n font-weight: 700;\n border: 0;\n border-radius: 3em;\n cursor: pointer;\n display: inline-block;\n line-height: 1;\n}\n\n.button-module_storybookButtonPrimary__4sw6y {\n color: white;\n background-color: #1e91fd;\n}\n\n.button-module_storybookButtonSecondary__SMF1h {\n color: #333;\n background-color: transparent;\n box-shadow: rgba(0, 0, 0, 0.15) 0px 0px 0px 1px inset;\n}\n\n.button-module_storybookButtonSmall__53gNr {\n font-size: 12px;\n padding: 10px 16px;\n}\n\n.button-module_storybookButtonMedium__EsDxI {\n font-size: 14px;\n padding: 11px 20px;\n}\n\n.button-module_storybookButtonLarge__sItJ6 {\n font-size: 16px;\n padding: 12px 24px;\n}'),style={storybookButton:"button-module_storybookButton__C78bP",storybookButtonPrimary:"button-module_storybookButtonPrimary__4sw6y",storybookButtonSecondary:"button-module_storybookButtonSecondary__SMF1h",storybookButtonSmall:"button-module_storybookButtonSmall__53gNr",storybookButtonMedium:"button-module_storybookButtonMedium__EsDxI",storybookButtonLarge:"button-module_storybookButtonLarge__sItJ6"},Button=(styleInject(css_248z$1),function(n){var t=n.primary,t=void 0!==t&&t,o=n.size,o=void 0===o?"medium":o,r=n.backgroundColor,i=n.label,n=__rest(n,["primary","size","backgroundColor","label"]),t=t?style.storybookButtonPrimary:style.storybookButtonSecondary;return React__default.default.createElement("button",__assign({type:"button",className:"".concat(style.storybookButton," ").concat(style["storybookButton".concat(e(o))]," ").concat(t),style:{backgroundColor:r}},n),i)}),css_248z=".card-module_card__HG0v6 {\n display: block;\n padding: 16px;\n margin: 4px;\n max-width: 750px;\n}\n\n.card-module_cardTitle__2vWxB {\n font-size: 1.5em;\n padding-bottom: 8px;\n font-weight: bold;\n}\n\n.card-module_cardBody__NimxI {\n font-size: 1em;\n}\n.card-module_cardBody__NimxI a {\n text-decoration: none;\n color: #0dcaf0;\n}",s={card:"card-module_card__HG0v6",cardTitle:"card-module_cardTitle__2vWxB",cardBody:"card-module_cardBody__NimxI"},color=(styleInject(css_248z),require("color")),Card=function(n){var e=n.backgroundColor,e=void 0===e?"#F3F8F2":e,t=n.titleColor,t=void 0===t?"#6c757d":t,o=n.bodyColor,o=void 0===o?"#757575":o,r=n.borderColor,r=void 0===r?"#212529":r,i=n.allowHover,i=void 0===i||i,a=n.hoverBgColor,a=void 0===a?"":a,d=n.hoverTitleColor,d=void 0===d?"":d,l=n.hoverBodyColor,l=void 0===l?"":l,c=n.borderStyle,c=void 0===c?"none":c,u=n.borderWidth,u=void 0===u?1:u,b=n.borderRadius,b=void 0===b?10:b,m=n.boxShadow,m=void 0===m||m,p=n.horizontalShadow,p=void 0===p?2:p,h=n.verticalShadow,h=void 0===h?0:h,f=n.blur,f=void 0===f?8:f,y=n.spread,y=void 0===y?2:y,g=n.shadowDarkness,g=void 0===g?.35:g,_=n.style,x=n.titleStyle,v=n.bodyStyle,n=__rest(n,["backgroundColor","titleColor","bodyColor","borderColor","allowHover","hoverBgColor","hoverTitleColor","hoverBodyColor","borderStyle","borderWidth","borderRadius","boxShadow","horizontalShadow","verticalShadow","blur","spread","shadowDarkness","style","titleStyle","bodyStyle"]),k=React.useState(function(){return!1}),w=k[0],C=k[1],k=a||color(e).darken(.2),a=d||color(e).rotate(180),d=l||color(e).rotate(180);return React__default.default.createElement("div",__assign({className:"".concat(s.card),onMouseEnter:function(){return C(function(){return!0})},onMouseLeave:function(){return C(function(){return!1})},style:__assign({backgroundColor:i&&w?k:e,borderColor:r,borderStyle:c,borderWidth:u+"px",borderRadius:b+"px",WebkitBoxShadow:m?"".concat(p,"px ").concat(h,"px ").concat(f,"px ").concat(y,"px ").concat(color(r).darken(g)):"none",boxShadow:m?"".concat(p,"px ").concat(h,"px ").concat(f,"px ").concat(y,"px ").concat(color(r).darken(g)):"none"},_)},n),React__default.default.createElement("div",{className:"".concat(s.cardTitle),style:__assign({color:i&&w?a:t},x)},"Card Title"),React__default.default.createElement("div",{className:"".concat(s.cardBody),style:__assign({color:i&&w?d:o},v)},"Lorem, ipsum dolor sit amet consectetur adipisicing elit. Doloremque, aperiam eveniet.Eos tempora ",React__default.default.createElement("a",{href:"#"},"This is a link")," incidunt quaerat laborum eius aliquam fuga. Consectetur nemo incidunt porro explicabo ut quis voluptatibus expedita nihil officia."))},shira={Base:Base,Button:Button,Card:Card};exports.Base=Base,exports.Button=Button,exports.default=shira; |
/// <reference types="react" /> | ||
import * as react from 'react'; | ||
import { FC, ReactNode } from 'react'; | ||
interface CardProps { | ||
backgroundColor?: string; | ||
titleColor?: string; | ||
bodyColor?: string; | ||
borderColor?: string; | ||
allowHover?: boolean; | ||
hoverBgColor?: string; | ||
hoverTitleColor?: string; | ||
hoverBodyColor?: string; | ||
borderStyle?: 'none' | 'solid' | 'dotted' | 'dashed' | 'double' | 'groove' | 'ridge' | 'inset' | 'outset'; | ||
borderWidth?: number; | ||
borderRadius?: number; | ||
boxShadow?: boolean; | ||
horizontalShadow?: number; | ||
verticalShadow?: number; | ||
blur?: number; | ||
spread?: number; | ||
shadowDarkness?: 0.10 | 0.15 | 0.20 | 0.25 | 0.30 | 0.35 | 0.40 | 0.50 | 0.55 | 0.60 | 0.65 | 0.70 | 0.75 | 0.80 | 0.85 | 0.90 | 0.95 | 1; | ||
style?: {}; | ||
titleStyle?: {}; | ||
bodyStyle?: {}; | ||
} | ||
interface ButtonProps { | ||
@@ -23,2 +49,3 @@ /** | ||
onClick?: () => void; | ||
onMouseOver?: () => void; | ||
} | ||
@@ -30,6 +57,18 @@ /** | ||
interface BaseProps { | ||
children: ReactNode; | ||
backgroundColor?: string; | ||
padding?: string; | ||
margin?: string; | ||
bodyHeight?: boolean; | ||
style?: {}; | ||
} | ||
declare const Base: FC<BaseProps>; | ||
declare const _default: { | ||
Base: react.FC<BaseProps>; | ||
Button: ({ primary, size, backgroundColor, label, ...props }: ButtonProps) => JSX.Element; | ||
Card: react.FC<CardProps>; | ||
}; | ||
export { Button, _default as default }; | ||
export { Base, Button, _default as default }; |
@@ -1,1 +0,1 @@ | ||
import React from"react";var __assign=function(){return(__assign=Object.assign||function(o){for(var t,e=1,n=arguments.length;e<n;e++)for(var r in t=arguments[e])Object.prototype.hasOwnProperty.call(t,r)&&(o[r]=t[r]);return o}).apply(this,arguments)};function __rest(o,t){var e={};for(r in o)Object.prototype.hasOwnProperty.call(o,r)&&t.indexOf(r)<0&&(e[r]=o[r]);if(null!=o&&"function"==typeof Object.getOwnPropertySymbols)for(var n=0,r=Object.getOwnPropertySymbols(o);n<r.length;n++)t.indexOf(r[n])<0&&Object.prototype.propertyIsEnumerable.call(o,r[n])&&(e[r[n]]=o[r[n]]);return e}var e=function(o){for(var t=o[0].toUpperCase(),e=1;e<o.length;e++)t+=o[e];return t};function styleInject(o,t){var e,n,t=(t=void 0===t?{}:t).insertAt;o&&"undefined"!=typeof document&&(e=document.head||document.getElementsByTagName("head")[0],(n=document.createElement("style")).type="text/css","top"===t&&e.firstChild?e.insertBefore(n,e.firstChild):e.appendChild(n),n.styleSheet?n.styleSheet.cssText=o:n.appendChild(document.createTextNode(o)))}Object.freeze({__proto__:null,cap:e});var css_248z='.index-module_storybookButton__1WDkY {\n font-family: "Nunito Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;\n font-weight: 700;\n border: 0;\n border-radius: 3em;\n cursor: pointer;\n display: inline-block;\n line-height: 1;\n}\n\n.index-module_storybookButtonPrimary__thpoG {\n color: white;\n background-color: #fd1e8e;\n}\n\n.index-module_storybookButtonSecondary__F-HDz {\n color: #333;\n background-color: transparent;\n box-shadow: rgba(0, 0, 0, 0.15) 0px 0px 0px 1px inset;\n}\n\n.index-module_storybookButtonSmall__4rGEM {\n font-size: 12px;\n padding: 10px 16px;\n}\n\n.index-module_storybookButtonMedium__1VD7c {\n font-size: 14px;\n padding: 11px 20px;\n}\n\n.index-module_storybookButtonLarge__CaF-c {\n font-size: 16px;\n padding: 12px 24px;\n}',style={storybookButton:"index-module_storybookButton__1WDkY",storybookButtonPrimary:"index-module_storybookButtonPrimary__thpoG",storybookButtonSecondary:"index-module_storybookButtonSecondary__F-HDz",storybookButtonSmall:"index-module_storybookButtonSmall__4rGEM",storybookButtonMedium:"index-module_storybookButtonMedium__1VD7c",storybookButtonLarge:"index-module_storybookButtonLarge__CaF-c"},Button=(styleInject(css_248z),function(o){var t=o.primary,t=void 0!==t&&t,n=o.size,n=void 0===n?"medium":n,r=o.backgroundColor,a=o.label,o=__rest(o,["primary","size","backgroundColor","label"]),t=t?style.storybookButtonPrimary:style.storybookButtonSecondary;return React.createElement("button",__assign({type:"button",className:"".concat(style.storybookButton," ").concat(style["storybookButton".concat(e(n))]," ").concat(t),style:{backgroundColor:r}},o),a)}),shira={Button:Button};export{Button,shira as default}; | ||
import React,{useState}from"react";var __assign=function(){return(__assign=Object.assign||function(n){for(var e,o=1,t=arguments.length;o<t;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}).apply(this,arguments)};function __rest(n,e){var o={};for(r in n)Object.prototype.hasOwnProperty.call(n,r)&&e.indexOf(r)<0&&(o[r]=n[r]);if(null!=n&&"function"==typeof Object.getOwnPropertySymbols)for(var t=0,r=Object.getOwnPropertySymbols(n);t<r.length;t++)e.indexOf(r[t])<0&&Object.prototype.propertyIsEnumerable.call(n,r[t])&&(o[r[t]]=n[r[t]]);return o}function styleInject(n,e){var o,t,e=(e=void 0===e?{}:e).insertAt;n&&"undefined"!=typeof document&&(o=document.head||document.getElementsByTagName("head")[0],(t=document.createElement("style")).type="text/css","top"===e&&o.firstChild?o.insertBefore(t,o.firstChild):o.appendChild(t),t.styleSheet?t.styleSheet.cssText=n:t.appendChild(document.createTextNode(n)))}var css_248z$3="/*! purgecss start ignore */\n/**\n * 1. Correct the line height in all browsers.\n * 2. Prevent adjustments of font size after orientation changes in iOS.\n */\nhtml {\n line-height: 1.15; /* 1 */\n -webkit-text-size-adjust: 100%; /* 2 */\n box-sizing: border-box;\n}\n\n*, *:before, *:after {\n box-sizing: inherit;\n}\n\n/* Sections\n ========================================================================== */\n/**\n * Remove the margin in all browsers.\n */\nbody {\n margin: 0 !important;\n padding: 0 !important;\n}\n\n/* Document\n ========================================================================== */\n/**\n * Render the `main` element consistently in IE.\n */\nmain {\n display: block;\n}\n\n/**\n * Correct the font size and margin on `h1` elements within `section` and\n * `article` contexts in Chrome, Firefox, and Safari.\n */\nh1 {\n font-size: 2em;\n}\n\nh1, h2, h3, h4, h5, h6 {\n margin: 0;\n}\n\n/* Grouping content\n ========================================================================== */\n/**\n * 1. Add the correct box sizing in Firefox.\n * 2. Show the overflow in Edge and IE.\n */\nhr {\n box-sizing: content-box; /* 1 */\n height: 0; /* 1 */\n overflow: visible; /* 2 */\n}\n\n/**\n * 1. Correct the inheritance and scaling of font size in all browsers.\n * 2. Correct the odd `em` font sizing in all browsers.\n */\npre {\n font-family: monospace, monospace; /* 1 */\n font-size: 1em; /* 2 */\n}\n\n/* Text-level semantics\n ========================================================================== */\n/**\n * Remove the gray background on active links in IE 10.\n */\na {\n background-color: transparent;\n}\n\n/**\n * 1. Remove the bottom border in Chrome 57-\n * 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari.\n */\nabbr[title] {\n border-bottom: none; /* 1 */\n text-decoration: underline; /* 2 */\n text-decoration: underline dotted; /* 2 */\n}\n\n/**\n * Add the correct font weight in Chrome, Edge, and Safari.\n */\nb,\nstrong {\n font-weight: bolder;\n}\n\n/**\n * 1. Correct the inheritance and scaling of font size in all browsers.\n * 2. Correct the odd `em` font sizing in all browsers.\n */\ncode,\nkbd,\nsamp {\n font-family: monospace, monospace; /* 1 */\n font-size: 1em; /* 2 */\n}\n\n/**\n * Add the correct font size in all browsers.\n */\nsmall {\n font-size: 80%;\n}\n\n/**\n * Prevent `sub` and `sup` elements from affecting the line height in\n * all browsers.\n */\nsub,\nsup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n}\n\nsub {\n bottom: -0.25em;\n}\n\nsup {\n top: -0.5em;\n}\n\n/* Embedded content\n ========================================================================== */\n/**\n * Remove the border on images inside links in IE 10.\n */\nimg {\n border-style: none;\n}\n\n/* Forms\n ========================================================================== */\n/**\n * 1. Change the font styles in all browsers.\n * 2. Remove the margin in Firefox and Safari.\n */\nbutton,\ninput,\noptgroup,\nselect,\ntextarea {\n font-family: inherit; /* 1 */\n font-size: 100%; /* 1 */\n line-height: 1.15; /* 1 */\n margin: 0; /* 2 */\n}\n\n/**\n * Show the overflow in IE.\n * 1. Show the overflow in Edge.\n */\nbutton,\ninput { /* 1 */\n overflow: visible;\n}\n\n/**\n * Remove the inheritance of text transform in Edge, Firefox, and IE.\n * 1. Remove the inheritance of text transform in Firefox.\n */\nbutton,\nselect { /* 1 */\n text-transform: none;\n}\n\n/**\n * Correct the inability to style clickable types in iOS and Safari.\n */\nbutton,\n[type=button],\n[type=reset],\n[type=submit] {\n -webkit-appearance: button;\n}\n\n/**\n * Remove the inner border and padding in Firefox.\n */\nbutton::-moz-focus-inner,\n[type=button]::-moz-focus-inner,\n[type=reset]::-moz-focus-inner,\n[type=submit]::-moz-focus-inner {\n border-style: none;\n padding: 0;\n}\n\n/**\n * Restore the focus styles unset by the previous rule.\n */\nbutton:-moz-focusring,\n[type=button]:-moz-focusring,\n[type=reset]:-moz-focusring,\n[type=submit]:-moz-focusring {\n outline: 1px dotted ButtonText;\n}\n\n/**\n * Correct the padding in Firefox.\n */\nfieldset {\n padding: 0.35em 0.75em 0.625em;\n}\n\n/**\n * 1. Correct the text wrapping in Edge and IE.\n * 2. Correct the color inheritance from `fieldset` elements in IE.\n * 3. Remove the padding so developers are not caught out when they zero out\n * `fieldset` elements in all browsers.\n */\nlegend {\n box-sizing: border-box; /* 1 */\n color: inherit; /* 2 */\n display: table; /* 1 */\n max-width: 100%; /* 1 */\n padding: 0; /* 3 */\n white-space: normal; /* 1 */\n}\n\n/**\n * Add the correct vertical alignment in Chrome, Firefox, and Opera.\n */\nprogress {\n vertical-align: baseline;\n}\n\n/**\n * Remove the default vertical scrollbar in IE 10+.\n */\ntextarea {\n overflow: auto;\n}\n\n/**\n * 1. Add the correct box sizing in IE 10.\n * 2. Remove the padding in IE 10.\n */\n[type=checkbox],\n[type=radio] {\n box-sizing: border-box; /* 1 */\n padding: 0; /* 2 */\n}\n\n/**\n * Correct the cursor style of increment and decrement buttons in Chrome.\n */\n[type=number]::-webkit-inner-spin-button,\n[type=number]::-webkit-outer-spin-button {\n height: auto;\n}\n\n/**\n * 1. Correct the odd appearance in Chrome and Safari.\n * 2. Correct the outline style in Safari.\n */\n[type=search] {\n -webkit-appearance: textfield; /* 1 */\n outline-offset: -2px; /* 2 */\n}\n\n/**\n * Remove the inner padding in Chrome and Safari on macOS.\n */\n[type=search]::-webkit-search-decoration {\n -webkit-appearance: none;\n}\n\n/**\n * 1. Correct the inability to style clickable types in iOS and Safari.\n * 2. Change font properties to `inherit` in Safari.\n */\n::-webkit-file-upload-button {\n -webkit-appearance: button; /* 1 */\n font: inherit; /* 2 */\n}\n\n/* Interactive\n ========================================================================== */\n/*\n * Add the correct display in Edge, IE 10+, and Firefox.\n */\ndetails {\n display: block;\n}\n\n/*\n * Add the correct display in all browsers.\n */\nsummary {\n display: list-item;\n}\n\n/* Misc\n ========================================================================== */\n/**\n * Add the correct display in IE 10+.\n */\ntemplate {\n display: none;\n}\n\n/**\n * Add the correct display in IE 10.\n */\n[hidden] {\n display: none;\n}\n\n/*! purgecss end ignore */",css_248z$2=(styleInject(css_248z$3),".base-module_main__xsrLc {\n font-family: Arial, sans-serif;\n font-size: 16px;\n color: #757575;\n padding: 0;\n margin: 0;\n background-color: #F3F8F2;\n}"),s$1={main:"base-module_main__xsrLc"},Base=(styleInject(css_248z$2),function(n){var e=n.children,o=n.backgroundColor,t=n.padding,r=n.margin,i=n.bodyHeight,i=void 0===i||i,a=n.style,n=__rest(n,["children","backgroundColor","padding","margin","bodyHeight","style"]);return React.createElement("div",__assign({className:"".concat(s$1.main),style:__assign({backgroundColor:o,padding:t,margin:r,height:i?"100vh":"auto"},a)},n),e)}),e=function(n){for(var e=n[0].toUpperCase(),o=1;o<n.length;o++)e+=n[o];return e},css_248z$1=(Object.freeze({__proto__:null,cap:e}),'.button-module_storybookButton__C78bP {\n font-family: "Nunito Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;\n font-weight: 700;\n border: 0;\n border-radius: 3em;\n cursor: pointer;\n display: inline-block;\n line-height: 1;\n}\n\n.button-module_storybookButtonPrimary__4sw6y {\n color: white;\n background-color: #1e91fd;\n}\n\n.button-module_storybookButtonSecondary__SMF1h {\n color: #333;\n background-color: transparent;\n box-shadow: rgba(0, 0, 0, 0.15) 0px 0px 0px 1px inset;\n}\n\n.button-module_storybookButtonSmall__53gNr {\n font-size: 12px;\n padding: 10px 16px;\n}\n\n.button-module_storybookButtonMedium__EsDxI {\n font-size: 14px;\n padding: 11px 20px;\n}\n\n.button-module_storybookButtonLarge__sItJ6 {\n font-size: 16px;\n padding: 12px 24px;\n}'),style={storybookButton:"button-module_storybookButton__C78bP",storybookButtonPrimary:"button-module_storybookButtonPrimary__4sw6y",storybookButtonSecondary:"button-module_storybookButtonSecondary__SMF1h",storybookButtonSmall:"button-module_storybookButtonSmall__53gNr",storybookButtonMedium:"button-module_storybookButtonMedium__EsDxI",storybookButtonLarge:"button-module_storybookButtonLarge__sItJ6"},Button=(styleInject(css_248z$1),function(n){var o=n.primary,o=void 0!==o&&o,t=n.size,t=void 0===t?"medium":t,r=n.backgroundColor,i=n.label,n=__rest(n,["primary","size","backgroundColor","label"]),o=o?style.storybookButtonPrimary:style.storybookButtonSecondary;return React.createElement("button",__assign({type:"button",className:"".concat(style.storybookButton," ").concat(style["storybookButton".concat(e(t))]," ").concat(o),style:{backgroundColor:r}},n),i)}),css_248z=".card-module_card__HG0v6 {\n display: block;\n padding: 16px;\n margin: 4px;\n max-width: 750px;\n}\n\n.card-module_cardTitle__2vWxB {\n font-size: 1.5em;\n padding-bottom: 8px;\n font-weight: bold;\n}\n\n.card-module_cardBody__NimxI {\n font-size: 1em;\n}\n.card-module_cardBody__NimxI a {\n text-decoration: none;\n color: #0dcaf0;\n}",s={card:"card-module_card__HG0v6",cardTitle:"card-module_cardTitle__2vWxB",cardBody:"card-module_cardBody__NimxI"},color=(styleInject(css_248z),require("color")),Card=function(n){var e=n.backgroundColor,e=void 0===e?"#F3F8F2":e,o=n.titleColor,o=void 0===o?"#6c757d":o,t=n.bodyColor,t=void 0===t?"#757575":t,r=n.borderColor,r=void 0===r?"#212529":r,i=n.allowHover,i=void 0===i||i,a=n.hoverBgColor,a=void 0===a?"":a,d=n.hoverTitleColor,d=void 0===d?"":d,l=n.hoverBodyColor,l=void 0===l?"":l,c=n.borderStyle,c=void 0===c?"none":c,u=n.borderWidth,u=void 0===u?1:u,b=n.borderRadius,b=void 0===b?10:b,m=n.boxShadow,m=void 0===m||m,p=n.horizontalShadow,p=void 0===p?2:p,h=n.verticalShadow,h=void 0===h?0:h,y=n.blur,y=void 0===y?8:y,f=n.spread,f=void 0===f?2:f,g=n.shadowDarkness,g=void 0===g?.35:g,_=n.style,x=n.titleStyle,v=n.bodyStyle,n=__rest(n,["backgroundColor","titleColor","bodyColor","borderColor","allowHover","hoverBgColor","hoverTitleColor","hoverBodyColor","borderStyle","borderWidth","borderRadius","boxShadow","horizontalShadow","verticalShadow","blur","spread","shadowDarkness","style","titleStyle","bodyStyle"]),k=useState(function(){return!1}),w=k[0],C=k[1],k=a||color(e).darken(.2),a=d||color(e).rotate(180),d=l||color(e).rotate(180);return React.createElement("div",__assign({className:"".concat(s.card),onMouseEnter:function(){return C(function(){return!0})},onMouseLeave:function(){return C(function(){return!1})},style:__assign({backgroundColor:i&&w?k:e,borderColor:r,borderStyle:c,borderWidth:u+"px",borderRadius:b+"px",WebkitBoxShadow:m?"".concat(p,"px ").concat(h,"px ").concat(y,"px ").concat(f,"px ").concat(color(r).darken(g)):"none",boxShadow:m?"".concat(p,"px ").concat(h,"px ").concat(y,"px ").concat(f,"px ").concat(color(r).darken(g)):"none"},_)},n),React.createElement("div",{className:"".concat(s.cardTitle),style:__assign({color:i&&w?a:o},x)},"Card Title"),React.createElement("div",{className:"".concat(s.cardBody),style:__assign({color:i&&w?d:t},v)},"Lorem, ipsum dolor sit amet consectetur adipisicing elit. Doloremque, aperiam eveniet.Eos tempora ",React.createElement("a",{href:"#"},"This is a link")," incidunt quaerat laborum eius aliquam fuga. Consectetur nemo incidunt porro explicabo ut quis voluptatibus expedita nihil officia."))},shira={Base:Base,Button:Button,Card:Card};export{Base,Button,shira as default}; |
/// <reference types="react" /> | ||
declare const _default: { | ||
Base: import("react").FC<import("./base").BaseProps>; | ||
Button: ({ primary, size, backgroundColor, label, ...props }: import("./button").ButtonProps) => JSX.Element; | ||
Card: import("react").FC<import("./card").CardProps>; | ||
}; | ||
export default _default; |
import shira from './components'; | ||
import { Base } from './components/base'; | ||
import { Button } from './components/button'; | ||
export { Button }; | ||
export { Base, Button }; | ||
export default shira; |
{ | ||
"name": "shira", | ||
"version": "1.0.6", | ||
"version": "1.0.7", | ||
"description": "UI components", | ||
@@ -20,12 +20,21 @@ "main": "lib/index.cjs.js", | ||
"@storybook/addon-actions": "^6.5.9", | ||
"@storybook/addon-console": "^1.2.3", | ||
"@storybook/addon-docs": "^6.5.9", | ||
"@storybook/addon-essentials": "^6.5.9", | ||
"@storybook/addon-interactions": "^6.5.9", | ||
"@storybook/addon-links": "^6.5.9", | ||
"@storybook/addon-viewport": "^6.5.9", | ||
"@storybook/addons": "^6.5.9", | ||
"@storybook/builder-webpack5": "^6.5.9", | ||
"@storybook/core-events": "^6.5.9", | ||
"@storybook/manager-webpack5": "^6.5.9", | ||
"@storybook/react": "^6.5.9", | ||
"@storybook/testing-library": "^0.0.13", | ||
"@storybook/theming": "^6.5.9", | ||
"autoprefixer": "^10.4.7", | ||
"babel-loader": "^8.2.5", | ||
"color": "^4.2.3", | ||
"css-loader": "^6.7.1", | ||
"dotenv": "^16.0.1", | ||
"file-loader": "^6.2.0", | ||
"node-sass": "^7.0.1", | ||
@@ -46,4 +55,8 @@ "postcss": "^8.4.14", | ||
"style-loader": "^3.3.1", | ||
"terser-webpack-plugin": "^5.3.3", | ||
"typed-scss-modules": "^6.5.0", | ||
"typescript": "^4.7.4" | ||
"typescript": "^4.7.4", | ||
"webpack-bundle-analyzer": "^4.5.0", | ||
"webpack-merge": "^5.8.0", | ||
"webpack-node-externals": "^3.0.0" | ||
}, | ||
@@ -61,5 +74,5 @@ "peerDependencies": { | ||
"storybook": "start-storybook -p 6006", | ||
"build-storybook": "build-storybook", | ||
"typed-scss": "typed-scss-modules src/scss" | ||
"docs": "rimraf docs && NODE_ENV='production' build-storybook -o docs", | ||
"typed-scss": "typed-scss-modules --implementation 'sass' 'src/**/*.scss' -w" | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
33196
11
234
45
3
1