@dbmx/toasts 0.0.3 → 0.0.4

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.
@@ -0,0 +1,35 @@
1
+ 'use strict';
2
+
3
+ var React = require('react');
4
+ var core = require('@mantine/core');
5
+ var PropTypes = require('prop-types');
6
+
7
+ function _interopNamespaceDefault(e) {
8
+ var n = Object.create(null);
9
+ if (e) {
10
+ Object.keys(e).forEach(function (k) {
11
+ if (k !== 'default') {
12
+ var d = Object.getOwnPropertyDescriptor(e, k);
13
+ Object.defineProperty(n, k, d.get ? d : {
14
+ enumerable: true,
15
+ get: function () { return e[k]; }
16
+ });
17
+ }
18
+ });
19
+ }
20
+ n.default = e;
21
+ return Object.freeze(n);
22
+ }
23
+
24
+ var React__namespace = /*#__PURE__*/_interopNamespaceDefault(React);
25
+
26
+ var Fake = function Fake(_ref) {
27
+ var message = _ref.message;
28
+ return /*#__PURE__*/React__namespace.createElement(core.Text, null, "COUCOU ".concat(message));
29
+ };
30
+ Fake.propTypes = {
31
+ message: PropTypes.string.isRequired
32
+ };
33
+
34
+ exports.default = Fake;
35
+ //# sourceMappingURL=fake-ZW05emqw.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fake-ZW05emqw.js","sources":["../../src/components/fake.js"],"sourcesContent":["import * as React from 'react'\nimport { Text } from '@mantine/core'\nimport PropTypes from 'prop-types'\n\nconst Fake = ({ message }) => {\n return <Text>{`COUCOU ${message}`}</Text>\n}\n\nFake.propTypes = {\n message: PropTypes.string.isRequired,\n}\n\nexport default Fake\n"],"names":["Fake","_ref","message","React","createElement","Text","concat","propTypes","PropTypes","string","isRequired"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAIA,IAAMA,IAAI,GAAG,SAAPA,IAAIA,CAAAC,IAAA,EAAoB;AAAA,EAAA,IAAdC,OAAO,GAAAD,IAAA,CAAPC,OAAO,CAAA;EACrB,oBAAOC,gBAAA,CAAAC,aAAA,CAACC,SAAI,kBAAAC,MAAA,CAAYJ,OAAO,CAAS,CAAC,CAAA;AAC3C,EAAC;AAEDF,IAAI,CAACO,SAAS,GAAG;AACfL,EAAAA,OAAO,EAAEM,SAAS,CAACC,MAAM,CAACC,UAAAA;AAC5B,CAAC;;;;"}
@@ -0,0 +1,73 @@
1
+ 'use strict';
2
+
3
+ var React = require('react');
4
+
5
+ function ownKeys(e, r) {
6
+ var t = Object.keys(e);
7
+ if (Object.getOwnPropertySymbols) {
8
+ var o = Object.getOwnPropertySymbols(e);
9
+ r && (o = o.filter(function (r) {
10
+ return Object.getOwnPropertyDescriptor(e, r).enumerable;
11
+ })), t.push.apply(t, o);
12
+ }
13
+ return t;
14
+ }
15
+ function _objectSpread2(e) {
16
+ for (var r = 1; r < arguments.length; r++) {
17
+ var t = null != arguments[r] ? arguments[r] : {};
18
+ r % 2 ? ownKeys(Object(t), !0).forEach(function (r) {
19
+ _defineProperty(e, r, t[r]);
20
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) {
21
+ Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
22
+ });
23
+ }
24
+ return e;
25
+ }
26
+ function _defineProperty(obj, key, value) {
27
+ key = _toPropertyKey(key);
28
+ if (key in obj) {
29
+ Object.defineProperty(obj, key, {
30
+ value: value,
31
+ enumerable: true,
32
+ configurable: true,
33
+ writable: true
34
+ });
35
+ } else {
36
+ obj[key] = value;
37
+ }
38
+ return obj;
39
+ }
40
+ function _toPrimitive(input, hint) {
41
+ if (typeof input !== "object" || input === null) return input;
42
+ var prim = input[Symbol.toPrimitive];
43
+ if (prim !== undefined) {
44
+ var res = prim.call(input, hint || "default");
45
+ if (typeof res !== "object") return res;
46
+ throw new TypeError("@@toPrimitive must return a primitive value.");
47
+ }
48
+ return (hint === "string" ? String : Number)(input);
49
+ }
50
+ function _toPropertyKey(arg) {
51
+ var key = _toPrimitive(arg, "string");
52
+ return typeof key === "symbol" ? key : String(key);
53
+ }
54
+
55
+ var toasts = [{
56
+ id: 'fake',
57
+ component: /*#__PURE__*/React.lazy(function () {
58
+ return Promise.resolve().then(function () { return require('./fake-ZW05emqw.js'); });
59
+ }),
60
+ props: {
61
+ message: {
62
+ type: 'string',
63
+ required: false,
64
+ defaultValue: 'ici les bidibules'
65
+ }
66
+ }
67
+ }];
68
+ var index = toasts.reduce(function (acc, t) {
69
+ return _objectSpread2(_objectSpread2({}, acc), {}, _defineProperty({}, t.id, t));
70
+ }, {});
71
+
72
+ module.exports = index;
73
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sources":["../../src/index.js"],"sourcesContent":["import { lazy } from 'react'\n\nconst toasts = [\n {\n id: 'fake',\n component: lazy(() => import('./components/fake.js')),\n props: {\n message: {\n type: 'string',\n required: false,\n defaultValue: 'ici les bidibules',\n },\n },\n },\n]\n\nexport default toasts.reduce((acc, t) => ({ ...acc, [t.id]: t }), {})\n"],"names":["toasts","id","component","lazy","props","message","type","required","defaultValue","reduce","acc","t","_objectSpread","_defineProperty"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,IAAMA,MAAM,GAAG,CACb;AACEC,EAAAA,EAAE,EAAE,MAAM;EACVC,SAAS,eAAEC,UAAI,CAAC,YAAA;IAAA,OAAM,oDAAO,oBAAsB,KAAC,CAAA;GAAC,CAAA;AACrDC,EAAAA,KAAK,EAAE;AACLC,IAAAA,OAAO,EAAE;AACPC,MAAAA,IAAI,EAAE,QAAQ;AACdC,MAAAA,QAAQ,EAAE,KAAK;AACfC,MAAAA,YAAY,EAAE,mBAAA;AAChB,KAAA;AACF,GAAA;AACF,CAAC,CACF,CAAA;AAED,YAAeR,MAAM,CAACS,MAAM,CAAC,UAACC,GAAG,EAAEC,CAAC,EAAA;AAAA,EAAA,OAAAC,cAAA,CAAAA,cAAA,CAAA,EAAA,EAAWF,GAAG,CAAA,EAAA,EAAA,EAAAG,eAAA,CAAA,EAAA,EAAGF,CAAC,CAACV,EAAE,EAAGU,CAAC,CAAA,CAAA,CAAA;AAAA,CAAG,EAAE,EAAE,CAAC;;;;"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fake-JHdVf8lQ.js","sources":["../../src/components/fake.js"],"sourcesContent":["import * as React from 'react'\nimport { Text } from '@mantine/core'\nimport PropTypes from 'prop-types'\n\nconst Fake = ({ message }) => {\n return <Text>{`COUCOU ${message}`}</Text>\n}\n\nFake.propTypes = {\n message: PropTypes.string.isRequired,\n}\n\nexport default Fake\n"],"names":["Fake","_ref","message","React","createElement","Text","concat","propTypes","PropTypes","string","isRequired"],"mappings":";;;;AAIA,IAAMA,IAAI,GAAG,SAAPA,IAAIA,CAAAC,IAAA,EAAoB;AAAA,EAAA,IAAdC,OAAO,GAAAD,IAAA,CAAPC,OAAO,CAAA;EACrB,oBAAOC,KAAA,CAAAC,aAAA,CAACC,IAAI,kBAAAC,MAAA,CAAYJ,OAAO,CAAS,CAAC,CAAA;AAC3C,EAAC;AAEDF,IAAI,CAACO,SAAS,GAAG;AACfL,EAAAA,OAAO,EAAEM,SAAS,CAACC,MAAM,CAACC,UAAAA;AAC5B,CAAC;;;;"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sources":["../../src/index.js"],"sourcesContent":["import { lazy } from 'react'\n\nconst toasts = [\n {\n id: 'fake',\n component: lazy(() => import('./components/fake.js')),\n props: {\n message: {\n type: 'string',\n required: false,\n defaultValue: 'ici les bidibules',\n },\n },\n },\n]\n\nexport default toasts.reduce((acc, t) => ({ ...acc, [t.id]: t }), {})\n"],"names":["toasts","id","component","lazy","props","message","type","required","defaultValue","reduce","acc","t","_objectSpread","_defineProperty"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,IAAMA,MAAM,GAAG,CACb;AACEC,EAAAA,EAAE,EAAE,MAAM;EACVC,SAAS,eAAEC,IAAI,CAAC,YAAA;IAAA,OAAM,OAAO,oBAAsB,CAAC,CAAA;GAAC,CAAA;AACrDC,EAAAA,KAAK,EAAE;AACLC,IAAAA,OAAO,EAAE;AACPC,MAAAA,IAAI,EAAE,QAAQ;AACdC,MAAAA,QAAQ,EAAE,KAAK;AACfC,MAAAA,YAAY,EAAE,mBAAA;AAChB,KAAA;AACF,GAAA;AACF,CAAC,CACF,CAAA;AAED,YAAeR,MAAM,CAACS,MAAM,CAAC,UAACC,GAAG,EAAEC,CAAC,EAAA;AAAA,EAAA,OAAAC,cAAA,CAAAA,cAAA,CAAA,EAAA,EAAWF,GAAG,CAAA,EAAA,EAAA,EAAAG,eAAA,CAAA,EAAA,EAAGF,CAAC,CAACV,EAAE,EAAGU,CAAC,CAAA,CAAA,CAAA;AAAA,CAAG,EAAE,EAAE,CAAC;;;;"}
package/package.json CHANGED
@@ -1,9 +1,9 @@
1
1
  {
2
2
  "name": "@dbmx/toasts",
3
- "version": "0.0.3",
3
+ "version": "0.0.4",
4
4
  "type": "module",
5
- "module": "./dist/index.js",
6
- "main": "./dist/index.js",
5
+ "module": "./dist/esm/index.js",
6
+ "main": "./dist/cjs/index.js",
7
7
  "license": "MIT",
8
8
  "author": "Eric Basley <eric.basley@redpelicans.com>",
9
9
  "peerDependencies": {
@@ -79,5 +79,5 @@
79
79
  "@babel/preset-react"
80
80
  ]
81
81
  },
82
- "gitHead": "6e8ee4060fde85bb35a08acbd36f3913a2229266"
82
+ "gitHead": "9e32f1940c594280c0abe379b8ddd6b9c50dd140"
83
83
  }
@@ -1 +0,0 @@
1
- {"version":3,"file":"fake-JHdVf8lQ.js","sources":["../src/components/fake.js"],"sourcesContent":["import * as React from 'react'\nimport { Text } from '@mantine/core'\nimport PropTypes from 'prop-types'\n\nconst Fake = ({ message }) => {\n return <Text>{`COUCOU ${message}`}</Text>\n}\n\nFake.propTypes = {\n message: PropTypes.string.isRequired,\n}\n\nexport default Fake\n"],"names":["Fake","_ref","message","React","createElement","Text","concat","propTypes","PropTypes","string","isRequired"],"mappings":";;;;AAIA,IAAMA,IAAI,GAAG,SAAPA,IAAIA,CAAAC,IAAA,EAAoB;AAAA,EAAA,IAAdC,OAAO,GAAAD,IAAA,CAAPC,OAAO,CAAA;EACrB,oBAAOC,KAAA,CAAAC,aAAA,CAACC,IAAI,kBAAAC,MAAA,CAAYJ,OAAO,CAAS,CAAC,CAAA;AAC3C,EAAC;AAEDF,IAAI,CAACO,SAAS,GAAG;AACfL,EAAAA,OAAO,EAAEM,SAAS,CAACC,MAAM,CAACC,UAAAA;AAC5B,CAAC;;;;"}
package/dist/index.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sources":["../src/index.js"],"sourcesContent":["import { lazy } from 'react'\n\nconst toasts = [\n {\n id: 'fake',\n component: lazy(() => import('./components/fake.js')),\n props: {\n message: {\n type: 'string',\n required: false,\n defaultValue: 'ici les bidibules',\n },\n },\n },\n]\n\nexport default toasts.reduce((acc, t) => ({ ...acc, [t.id]: t }), {})\n"],"names":["toasts","id","component","lazy","props","message","type","required","defaultValue","reduce","acc","t","_objectSpread","_defineProperty"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,IAAMA,MAAM,GAAG,CACb;AACEC,EAAAA,EAAE,EAAE,MAAM;EACVC,SAAS,eAAEC,IAAI,CAAC,YAAA;IAAA,OAAM,OAAO,oBAAsB,CAAC,CAAA;GAAC,CAAA;AACrDC,EAAAA,KAAK,EAAE;AACLC,IAAAA,OAAO,EAAE;AACPC,MAAAA,IAAI,EAAE,QAAQ;AACdC,MAAAA,QAAQ,EAAE,KAAK;AACfC,MAAAA,YAAY,EAAE,mBAAA;AAChB,KAAA;AACF,GAAA;AACF,CAAC,CACF,CAAA;AAED,YAAeR,MAAM,CAACS,MAAM,CAAC,UAACC,GAAG,EAAEC,CAAC,EAAA;AAAA,EAAA,OAAAC,cAAA,CAAAA,cAAA,CAAA,EAAA,EAAWF,GAAG,CAAA,EAAA,EAAA,EAAAG,eAAA,CAAA,EAAA,EAAGF,CAAC,CAACV,EAAE,EAAGU,CAAC,CAAA,CAAA,CAAA;AAAA,CAAG,EAAE,EAAE,CAAC;;;;"}
File without changes
File without changes