@nearform/quantum 0.3.0 → 0.6.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 +9 -12
- package/dist/animations/index.js +42 -0
- package/dist/animations/index.js.map +1 -0
- package/dist/global.css +620 -0
- package/dist/global.css.map +1 -1
- package/dist/index.d.ts +100 -1
- package/dist/index.js +5734 -63
- package/dist/index.js.map +1 -1
- package/dist/tailwind-plugin.js +1554 -0
- package/dist/tailwind-plugin.js.map +1 -0
- package/package.json +17 -2
package/README.md
CHANGED
|
@@ -14,25 +14,22 @@ npm install --save @nearform/quantum
|
|
|
14
14
|
|
|
15
15
|
#### With Tailwind
|
|
16
16
|
|
|
17
|
-
|
|
17
|
+
Include or extend our colour configuration and add our components to Tailwind's content configuration. To ensure dark mode of the components isn't operating system dependent, add the `darkMode: "class"` entry to the config.
|
|
18
18
|
|
|
19
19
|
```js
|
|
20
20
|
// tailwind.config.js
|
|
21
|
-
import
|
|
22
|
-
|
|
21
|
+
import quantumPlugin from '@nearform/quantum/tailwind-plugin'
|
|
23
22
|
module.exports = {
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
colors,
|
|
29
|
-
}
|
|
30
|
-
};
|
|
23
|
+
//...tailwind config
|
|
24
|
+
plugins: [quantumPlugin]
|
|
25
|
+
darkMode: "class"
|
|
26
|
+
}
|
|
31
27
|
```
|
|
32
28
|
|
|
33
29
|
#### Without Tailwind
|
|
34
30
|
|
|
35
31
|
```js
|
|
36
|
-
|
|
37
|
-
import
|
|
32
|
+
//root component
|
|
33
|
+
import '@nearform/quantum/dist/global.css'
|
|
34
|
+
import { Button } from '@nearform/quantum'
|
|
38
35
|
```
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
|
|
20
|
+
// src/animations/index.ts
|
|
21
|
+
var animations_exports = {};
|
|
22
|
+
__export(animations_exports, {
|
|
23
|
+
default: () => animations_default
|
|
24
|
+
});
|
|
25
|
+
module.exports = __toCommonJS(animations_exports);
|
|
26
|
+
var animations_default = {
|
|
27
|
+
keyframes: {
|
|
28
|
+
slideDown: {
|
|
29
|
+
from: { height: "0" },
|
|
30
|
+
to: { height: "var(--radix-accordion-content-height)" }
|
|
31
|
+
},
|
|
32
|
+
slideUp: {
|
|
33
|
+
from: { height: "var(--radix-accordion-content-height)" },
|
|
34
|
+
to: { height: "0" }
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
animation: {
|
|
38
|
+
slideDown: "slideDown 300ms cubic-bezier(0.87, 0, 0.13, 1)",
|
|
39
|
+
slideUp: "slideUp 300ms cubic-bezier(0.87, 0, 0.13, 1)"
|
|
40
|
+
}
|
|
41
|
+
};
|
|
42
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/animations/index.ts"],"sourcesContent":["export default {\n keyframes: {\n slideDown: {\n from: { height: '0' },\n to: { height: 'var(--radix-accordion-content-height)' },\n },\n slideUp: {\n from: { height: 'var(--radix-accordion-content-height)' },\n to: { height: '0' }\n }\n },\n animation: {\n slideDown: 'slideDown 300ms cubic-bezier(0.87, 0, 0.13, 1)',\n slideUp: 'slideUp 300ms cubic-bezier(0.87, 0, 0.13, 1)'\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAAO,qBAAQ;AAAA,EACX,WAAW;AAAA,IACP,WAAW;AAAA,MACP,MAAM,EAAE,QAAQ,IAAI;AAAA,MACpB,IAAI,EAAE,QAAQ,wCAAwC;AAAA,IAC1D;AAAA,IACA,SAAS;AAAA,MACL,MAAM,EAAE,QAAQ,wCAAwC;AAAA,MACxD,IAAI,EAAE,QAAQ,IAAI;AAAA,IACtB;AAAA,EACJ;AAAA,EACA,WAAW;AAAA,IACP,WAAW;AAAA,IACX,SAAS;AAAA,EACb;AACJ;","names":[]}
|