@bigbinary/neeto-molecules 1.14.1 → 1.15.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -46,6 +46,7 @@ https://neeto-molecules.neeto.com/
46
46
  - [IpRestriction](./docs/components/IpRestriction.md)
47
47
  - [KeyboardShortcuts](./docs/components/KeyboardShortcuts.md)
48
48
  - [LoginPage](./docs/components/LoginPage.md)
49
+ - [MadeWith](./docs/components/MadeWith.md)
49
50
  - [MenuBar](./docs/components/MenuBar.md)
50
51
  - [Metadata](./docs/components/Metadata.md)
51
52
  - [MoreDropdown](./docs/components/MoreDropdown.md)
@@ -0,0 +1,32 @@
1
+ import { _ as _extends } from './extends-093996c9.js';
2
+ import { _ as _objectWithoutProperties } from './objectWithoutProperties-a0edb288.js';
3
+ import React__default from 'react';
4
+ import { Trans } from 'react-i18next';
5
+ import { n } from './inject-css-c86de496.js';
6
+
7
+ var css = ".neeto-molecules-made-with__wrapper{background:#fff;border-radius:4px;color:#000;font-size:14px;font-weight:400;padding:4px 6px;-webkit-user-select:none;-moz-user-select:none;user-select:none}.neeto-molecules-made-with__wrapper strong{font-weight:700}";
8
+ n(css,{});
9
+
10
+ var _excluded = ["productName"];
11
+ var MadeWith = function MadeWith(_ref) {
12
+ var productName = _ref.productName,
13
+ otherProps = _objectWithoutProperties(_ref, _excluded);
14
+ var name = productName || globalProps.appName;
15
+ return /*#__PURE__*/React__default.createElement("a", _extends({
16
+ className: "neeto-molecules-made-with__wrapper",
17
+ "data-cy": "made-with-".concat(name),
18
+ "data-testid": "made-with-".concat(name),
19
+ href: "https://www.neeto.com/".concat(name.toLowerCase()),
20
+ rel: "noreferrer",
21
+ target: "_blank"
22
+ }, otherProps), /*#__PURE__*/React__default.createElement(Trans, {
23
+ i18nKey: "neetoMolecules.common.madeWith",
24
+ values: {
25
+ productName: name
26
+ }
27
+ }));
28
+ };
29
+ var index = /*#__PURE__*/React__default.memo(MadeWith);
30
+
31
+ export { index as default };
32
+ //# sourceMappingURL=MadeWith.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"MadeWith.js","sources":["../src/components/MadeWith/index.jsx"],"sourcesContent":["import React from \"react\";\n\nimport PropTypes from \"prop-types\";\nimport { Trans } from \"react-i18next\";\n\nimport \"./made-with.scss\";\n\nconst MadeWith = ({ productName, ...otherProps }) => {\n const name = productName || globalProps.appName;\n\n return (\n <a\n className=\"neeto-molecules-made-with__wrapper\"\n data-cy={`made-with-${name}`}\n data-testid={`made-with-${name}`}\n href={`https://www.neeto.com/${name.toLowerCase()}`}\n rel=\"noreferrer\"\n target=\"_blank\"\n {...otherProps}\n >\n <Trans\n i18nKey=\"neetoMolecules.common.madeWith\"\n values={{ productName: name }}\n />\n </a>\n );\n};\n\nMadeWith.propTypes = {\n /**\n * Product name to be displayed on the component (optional).\n */\n productName: PropTypes.string,\n};\n\nexport default React.memo(MadeWith);\n"],"names":["MadeWith","_ref","productName","otherProps","_objectWithoutProperties","_excluded","name","globalProps","appName","React","createElement","_extends","className","concat","href","toLowerCase","rel","target","Trans","i18nKey","values","memo"],"mappings":";;;;;;;;;;AAOA,IAAMA,QAAQ,GAAG,SAAXA,QAAQA,CAAAC,IAAA,EAAuC;AAAA,EAAA,IAAjCC,WAAW,GAAAD,IAAA,CAAXC,WAAW;AAAKC,IAAAA,UAAU,GAAAC,wBAAA,CAAAH,IAAA,EAAAI,SAAA,CAAA,CAAA;AAC5C,EAAA,IAAMC,IAAI,GAAGJ,WAAW,IAAIK,WAAW,CAACC,OAAO,CAAA;AAE/C,EAAA,oBACEC,cAAA,CAAAC,aAAA,CAAA,GAAA,EAAAC,QAAA,CAAA;AACEC,IAAAA,SAAS,EAAC,oCAAoC;IAC9C,SAAAC,EAAAA,YAAAA,CAAAA,MAAA,CAAsBP,IAAI,CAAG;IAC7B,aAAAO,EAAAA,YAAAA,CAAAA,MAAA,CAA0BP,IAAI,CAAG;IACjCQ,IAAI,EAAA,wBAAA,CAAAD,MAAA,CAA2BP,IAAI,CAACS,WAAW,EAAE,CAAG;AACpDC,IAAAA,GAAG,EAAC,YAAY;AAChBC,IAAAA,MAAM,EAAC,QAAA;AAAQ,GAAA,EACXd,UAAU,CAEdM,eAAAA,cAAA,CAAAC,aAAA,CAACQ,KAAK,EAAA;AACJC,IAAAA,OAAO,EAAC,gCAAgC;AACxCC,IAAAA,MAAM,EAAE;AAAElB,MAAAA,WAAW,EAAEI,IAAAA;AAAK,KAAA;AAAE,GAC/B,CACA,CAAC,CAAA;AAER,CAAC,CAAA;AASD,YAAA,aAAeG,cAAK,CAACY,IAAI,CAACrB,QAAQ,CAAC;;;;"}
@@ -0,0 +1,38 @@
1
+ 'use strict';
2
+
3
+ var _extends = require('./extends-1b35a664.js');
4
+ var objectWithoutProperties = require('./objectWithoutProperties-2fed2d7d.js');
5
+ var React = require('react');
6
+ var reactI18next = require('react-i18next');
7
+ var injectCss = require('./inject-css-80a5faa3.js');
8
+
9
+ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
10
+
11
+ var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
12
+
13
+ var css = ".neeto-molecules-made-with__wrapper{background:#fff;border-radius:4px;color:#000;font-size:14px;font-weight:400;padding:4px 6px;-webkit-user-select:none;-moz-user-select:none;user-select:none}.neeto-molecules-made-with__wrapper strong{font-weight:700}";
14
+ injectCss.n(css,{});
15
+
16
+ var _excluded = ["productName"];
17
+ var MadeWith = function MadeWith(_ref) {
18
+ var productName = _ref.productName,
19
+ otherProps = objectWithoutProperties._objectWithoutProperties(_ref, _excluded);
20
+ var name = productName || globalProps.appName;
21
+ return /*#__PURE__*/React__default["default"].createElement("a", _extends._extends({
22
+ className: "neeto-molecules-made-with__wrapper",
23
+ "data-cy": "made-with-".concat(name),
24
+ "data-testid": "made-with-".concat(name),
25
+ href: "https://www.neeto.com/".concat(name.toLowerCase()),
26
+ rel: "noreferrer",
27
+ target: "_blank"
28
+ }, otherProps), /*#__PURE__*/React__default["default"].createElement(reactI18next.Trans, {
29
+ i18nKey: "neetoMolecules.common.madeWith",
30
+ values: {
31
+ productName: name
32
+ }
33
+ }));
34
+ };
35
+ var index = /*#__PURE__*/React__default["default"].memo(MadeWith);
36
+
37
+ module.exports = index;
38
+ //# sourceMappingURL=MadeWith.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"MadeWith.js","sources":["../../src/components/MadeWith/index.jsx"],"sourcesContent":["import React from \"react\";\n\nimport PropTypes from \"prop-types\";\nimport { Trans } from \"react-i18next\";\n\nimport \"./made-with.scss\";\n\nconst MadeWith = ({ productName, ...otherProps }) => {\n const name = productName || globalProps.appName;\n\n return (\n <a\n className=\"neeto-molecules-made-with__wrapper\"\n data-cy={`made-with-${name}`}\n data-testid={`made-with-${name}`}\n href={`https://www.neeto.com/${name.toLowerCase()}`}\n rel=\"noreferrer\"\n target=\"_blank\"\n {...otherProps}\n >\n <Trans\n i18nKey=\"neetoMolecules.common.madeWith\"\n values={{ productName: name }}\n />\n </a>\n );\n};\n\nMadeWith.propTypes = {\n /**\n * Product name to be displayed on the component (optional).\n */\n productName: PropTypes.string,\n};\n\nexport default React.memo(MadeWith);\n"],"names":["MadeWith","_ref","productName","otherProps","_objectWithoutProperties","_excluded","name","globalProps","appName","React","createElement","_extends","className","concat","href","toLowerCase","rel","target","Trans","i18nKey","values","memo"],"mappings":";;;;;;;;;;;;;;;;AAOA,IAAMA,QAAQ,GAAG,SAAXA,QAAQA,CAAAC,IAAA,EAAuC;AAAA,EAAA,IAAjCC,WAAW,GAAAD,IAAA,CAAXC,WAAW;AAAKC,IAAAA,UAAU,GAAAC,gDAAA,CAAAH,IAAA,EAAAI,SAAA,CAAA,CAAA;AAC5C,EAAA,IAAMC,IAAI,GAAGJ,WAAW,IAAIK,WAAW,CAACC,OAAO,CAAA;AAE/C,EAAA,oBACEC,yBAAA,CAAAC,aAAA,CAAA,GAAA,EAAAC,iBAAA,CAAA;AACEC,IAAAA,SAAS,EAAC,oCAAoC;IAC9C,SAAAC,EAAAA,YAAAA,CAAAA,MAAA,CAAsBP,IAAI,CAAG;IAC7B,aAAAO,EAAAA,YAAAA,CAAAA,MAAA,CAA0BP,IAAI,CAAG;IACjCQ,IAAI,EAAA,wBAAA,CAAAD,MAAA,CAA2BP,IAAI,CAACS,WAAW,EAAE,CAAG;AACpDC,IAAAA,GAAG,EAAC,YAAY;AAChBC,IAAAA,MAAM,EAAC,QAAA;AAAQ,GAAA,EACXd,UAAU,CAEdM,eAAAA,yBAAA,CAAAC,aAAA,CAACQ,kBAAK,EAAA;AACJC,IAAAA,OAAO,EAAC,gCAAgC;AACxCC,IAAAA,MAAM,EAAE;AAAElB,MAAAA,WAAW,EAAEI,IAAAA;AAAK,KAAA;AAAE,GAC/B,CACA,CAAC,CAAA;AAER,CAAC,CAAA;AASD,YAAA,aAAeG,yBAAK,CAACY,IAAI,CAACrB,QAAQ,CAAC;;;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bigbinary/neeto-molecules",
3
- "version": "1.14.1",
3
+ "version": "1.15.0",
4
4
  "description": "A package of reusable molecular components for neeto products.",
5
5
  "repository": "git@github.com:bigbinary/neeto-molecules.git",
6
6
  "author": "Amaljith K <amaljith.k@bigbinary.com>",
@@ -41,7 +41,8 @@
41
41
  "emojiPicker": "Emoji picker",
42
42
  "validations": {
43
43
  "requiredField": "{{entity}} is a required field"
44
- }
44
+ },
45
+ "madeWith": "Made with <strong>{{productName, anyCase}}<strong>"
45
46
  },
46
47
  "columns": {
47
48
  "columns": "Show/hide columns",
@@ -0,0 +1,16 @@
1
+ import React from "react";
2
+ /**
3
+ *
4
+ * A component used for rendering made with block.
5
+ *
6
+ * @example
7
+ *
8
+ * import MadeWith from "@bigbinary/neeto-molecules/MadeWith";
9
+ *
10
+ * <MadeWith />;
11
+ * @endexample
12
+ */
13
+ const MadeWith: React.FC<{
14
+ productName?: string;
15
+ }>;
16
+ export default MadeWith;