rox-react-components 0.0.1 → 0.0.2
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/dist/es/Card/Card.js +1 -17
- package/dist/es/Card/index.js +1 -5
- package/dist/es/Card/styles.js +1 -17
- package/dist/es/index.js +1 -1
- package/dist/lib/Card/Card.js +1 -19
- package/dist/lib/Card/index.js +1 -7
- package/dist/lib/Card/styles.js +1 -19
- package/dist/lib/index.js +1 -7
- package/package.json +12 -3
- package/dist/es/Button/Button.d.ts +0 -3
- package/dist/es/Button/index.d.ts +0 -2
- package/dist/es/Button/style.d.ts +0 -4
- package/dist/es/Slide/Slide.d.ts +0 -3
- package/dist/es/Slide/index.d.ts +0 -2
- package/dist/lib/Button/Button.d.ts +0 -3
- package/dist/lib/Button/index.d.ts +0 -2
- package/dist/lib/Button/style.d.ts +0 -4
- package/dist/lib/Slide/Slide.d.ts +0 -3
- package/dist/lib/Slide/index.d.ts +0 -2
package/dist/es/Card/Card.js
CHANGED
|
@@ -1,17 +1 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import React, { useMemo } from 'react';
|
|
3
|
-
import styles from './styles.js';
|
|
4
|
-
|
|
5
|
-
var Card = function (_a) {
|
|
6
|
-
var _b = _a.expand, expand = _b === void 0 ? false : _b, children = _a.children, _c = _a.duration, duration = _c === void 0 ? 200 : _c;
|
|
7
|
-
var transitionDuration = useMemo(function () { return ({
|
|
8
|
-
transitionDuration: "".concat(duration, "ms"),
|
|
9
|
-
msTransitionDuration: "".concat(duration, "ms"),
|
|
10
|
-
MozTransitionDuration: "".concat(duration, "ms"),
|
|
11
|
-
WebkitTransitionDuration: "".concat(duration, "ms"),
|
|
12
|
-
}); }, [duration]);
|
|
13
|
-
return (React.createElement("div", { style: transitionDuration, className: "".concat(css(styles.collapse), " ").concat(expand ? css(styles.expand) : '') },
|
|
14
|
-
React.createElement("div", { className: css(styles.hide0) }, children)));
|
|
15
|
-
};
|
|
16
|
-
|
|
17
|
-
export { Card as default };
|
|
1
|
+
import{css as t}from"aphrodite";import a,{useMemo as n}from"react";import o from"./styles.js";var r=function(r){var i=r.expand,e=void 0!==i&&i,c=r.children,s=r.duration,m=void 0===s?200:s,d=n((function(){return{transitionDuration:"".concat(m,"ms"),msTransitionDuration:"".concat(m,"ms"),MozTransitionDuration:"".concat(m,"ms"),WebkitTransitionDuration:"".concat(m,"ms")}}),[m]);return a.createElement("div",{style:d,className:"".concat(t(o.collapse)," ").concat(e?t(o.expand):"")},a.createElement("div",{className:t(o.hide0)},c))};export{r as default};
|
package/dist/es/Card/index.js
CHANGED
package/dist/es/Card/styles.js
CHANGED
|
@@ -1,17 +1 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
var styles = StyleSheet.create({
|
|
4
|
-
collapse: {
|
|
5
|
-
display: 'grid',
|
|
6
|
-
gridTemplateRows: '0fr',
|
|
7
|
-
overflow: 'hidden',
|
|
8
|
-
},
|
|
9
|
-
expand: {
|
|
10
|
-
gridTemplateRows: '1fr',
|
|
11
|
-
},
|
|
12
|
-
hide0: {
|
|
13
|
-
minHeight: 0,
|
|
14
|
-
},
|
|
15
|
-
});
|
|
16
|
-
|
|
17
|
-
export { styles as default };
|
|
1
|
+
import{StyleSheet as e}from"aphrodite";var r=e.create({collapse:{display:"grid",gridTemplateRows:"0fr",overflow:"hidden"},expand:{gridTemplateRows:"1fr"},hide0:{minHeight:0}});export{r as default};
|
package/dist/es/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export
|
|
1
|
+
export{default as Card}from"./Card/Card.js";
|
package/dist/lib/Card/Card.js
CHANGED
|
@@ -1,19 +1 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
var aphrodite = require('aphrodite');
|
|
4
|
-
var React = require('react');
|
|
5
|
-
var styles = require('./styles.js');
|
|
6
|
-
|
|
7
|
-
var Card = function (_a) {
|
|
8
|
-
var _b = _a.expand, expand = _b === void 0 ? false : _b, children = _a.children, _c = _a.duration, duration = _c === void 0 ? 200 : _c;
|
|
9
|
-
var transitionDuration = React.useMemo(function () { return ({
|
|
10
|
-
transitionDuration: "".concat(duration, "ms"),
|
|
11
|
-
msTransitionDuration: "".concat(duration, "ms"),
|
|
12
|
-
MozTransitionDuration: "".concat(duration, "ms"),
|
|
13
|
-
WebkitTransitionDuration: "".concat(duration, "ms"),
|
|
14
|
-
}); }, [duration]);
|
|
15
|
-
return (React.createElement("div", { style: transitionDuration, className: "".concat(aphrodite.css(styles.collapse), " ").concat(expand ? aphrodite.css(styles.expand) : '') },
|
|
16
|
-
React.createElement("div", { className: aphrodite.css(styles.hide0) }, children)));
|
|
17
|
-
};
|
|
18
|
-
|
|
19
|
-
module.exports = Card;
|
|
1
|
+
"use strict";var e=require("aphrodite"),t=require("react"),n=require("./styles.js");module.exports=function(a){var r=a.expand,s=void 0!==r&&r,i=a.children,c=a.duration,o=void 0===c?200:c,u=t.useMemo((function(){return{transitionDuration:"".concat(o,"ms"),msTransitionDuration:"".concat(o,"ms"),MozTransitionDuration:"".concat(o,"ms"),WebkitTransitionDuration:"".concat(o,"ms")}}),[o]);return t.createElement("div",{style:u,className:"".concat(e.css(n.collapse)," ").concat(s?e.css(n.expand):"")},t.createElement("div",{className:e.css(n.hide0)},i))};
|
package/dist/lib/Card/index.js
CHANGED
package/dist/lib/Card/styles.js
CHANGED
|
@@ -1,19 +1 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
var aphrodite = require('aphrodite');
|
|
4
|
-
|
|
5
|
-
var styles = aphrodite.StyleSheet.create({
|
|
6
|
-
collapse: {
|
|
7
|
-
display: 'grid',
|
|
8
|
-
gridTemplateRows: '0fr',
|
|
9
|
-
overflow: 'hidden',
|
|
10
|
-
},
|
|
11
|
-
expand: {
|
|
12
|
-
gridTemplateRows: '1fr',
|
|
13
|
-
},
|
|
14
|
-
hide0: {
|
|
15
|
-
minHeight: 0,
|
|
16
|
-
},
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
module.exports = styles;
|
|
1
|
+
"use strict";var e=require("aphrodite").StyleSheet.create({collapse:{display:"grid",gridTemplateRows:"0fr",overflow:"hidden"},expand:{gridTemplateRows:"1fr"},hide0:{minHeight:0}});module.exports=e;
|
package/dist/lib/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,18 +1,27 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "rox-react-components",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.2",
|
|
4
4
|
"main": "dist/lib/index.js",
|
|
5
5
|
"module": "dist/es/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
7
|
+
"description": "A React UI Component Library",
|
|
8
|
+
"keywords": [
|
|
9
|
+
"React",
|
|
10
|
+
"SlideMenu",
|
|
11
|
+
"Card"
|
|
12
|
+
],
|
|
7
13
|
"files": [
|
|
8
14
|
"dist",
|
|
9
15
|
"README.md",
|
|
10
16
|
"pakcage.json"
|
|
11
17
|
],
|
|
18
|
+
"engines": {
|
|
19
|
+
"node": ">=14"
|
|
20
|
+
},
|
|
12
21
|
"author": "YangSu.Zhou",
|
|
13
22
|
"scripts": {
|
|
14
|
-
"dev": "cross-env NODE_ENV=development rollup -c",
|
|
15
|
-
"build": "cross-env NODE_ENV=production rollup -c
|
|
23
|
+
"dev": "cross-env NODE_ENV=development rollup -c -w",
|
|
24
|
+
"build": "cross-env NODE_ENV=production rollup -c"
|
|
16
25
|
},
|
|
17
26
|
"license": "MIT",
|
|
18
27
|
"devDependencies": {
|
package/dist/es/Slide/Slide.d.ts
DELETED
package/dist/es/Slide/index.d.ts
DELETED