@ray-js/components 0.9.2 → 0.9.4-beta-1
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/lib/RichText/RichText.d.ts +3 -2
- package/lib/RichText/RichText.js +5 -7
- package/lib/RichText/RichText.thing.d.ts +4 -0
- package/lib/RichText/RichText.thing.js +8 -0
- package/lib/RichText/RichText.wechat.d.ts +4 -0
- package/lib/RichText/RichText.wechat.js +8 -0
- package/lib/RichText/index.d.ts +1 -1
- package/lib/RichText/index.js +0 -1
- package/lib/index.d.ts +0 -3
- package/lib/index.js +0 -3
- package/package.json +5 -5
- package/lib/Icon/iconfont-rn/iconfont.json +0 -189
- package/lib/LinearGradient/LinearGradient.d.ts +0 -4
- package/lib/LinearGradient/LinearGradient.js +0 -8
- package/lib/LinearGradient/LinearGradient.thing.d.ts +0 -4
- package/lib/LinearGradient/LinearGradient.thing.js +0 -56
- package/lib/LinearGradient/LinearGradient.wechat.d.ts +0 -4
- package/lib/LinearGradient/LinearGradient.wechat.js +0 -53
- package/lib/LinearGradient/index.d.ts +0 -3
- package/lib/LinearGradient/index.js +0 -3
- package/lib/LinearGradient/index.module.less +0 -7
- package/lib/LinearGradient/props.d.ts +0 -58
- package/lib/LinearGradient/props.js +0 -11
- package/lib/Modal/Modal.d.ts +0 -4
- package/lib/Modal/Modal.js +0 -10
- package/lib/Modal/Modal.thing.d.ts +0 -4
- package/lib/Modal/Modal.thing.js +0 -75
- package/lib/Modal/Modal.wechat.d.ts +0 -4
- package/lib/Modal/Modal.wechat.js +0 -75
- package/lib/Modal/index.d.ts +0 -3
- package/lib/Modal/index.js +0 -3
- package/lib/Modal/index.module.less +0 -46
- package/lib/Modal/props.d.ts +0 -51
- package/lib/Modal/props.js +0 -1
- package/lib/RadialGradient/RadialGradient.d.ts +0 -4
- package/lib/RadialGradient/RadialGradient.js +0 -8
- package/lib/RadialGradient/RadialGradient.thing.d.ts +0 -4
- package/lib/RadialGradient/RadialGradient.thing.js +0 -36
- package/lib/RadialGradient/RadialGradient.wechat.d.ts +0 -4
- package/lib/RadialGradient/RadialGradient.wechat.js +0 -36
- package/lib/RadialGradient/index.d.ts +0 -3
- package/lib/RadialGradient/index.js +0 -3
- package/lib/RadialGradient/index.module.less +0 -7
- package/lib/RadialGradient/props.d.ts +0 -64
- package/lib/RadialGradient/props.js +0 -16
- package/lib/RichText/RichText.web.d.ts +0 -4
- package/lib/RichText/RichText.web.js +0 -7
- package/lib/RichText/props.d.ts +0 -29
- package/lib/RichText/props.js +0 -1
@@ -1,8 +0,0 @@
|
|
1
|
-
import * as React from 'react';
|
2
|
-
import { View } from '@ray-js/components';
|
3
|
-
|
4
|
-
var LinearGradient = function () {
|
5
|
-
return /*#__PURE__*/React.createElement(View, null, "web \u7EBF\u6027\u6E10\u53D8 \u6682\u672A\u5B9E\u73B0");
|
6
|
-
};
|
7
|
-
|
8
|
-
export default LinearGradient;
|
@@ -1,56 +0,0 @@
|
|
1
|
-
import "core-js/modules/es.regexp.exec.js";
|
2
|
-
import "core-js/modules/es.string.replace.js";
|
3
|
-
import "core-js/modules/es.array.concat.js";
|
4
|
-
import "core-js/modules/es.object.to-string.js";
|
5
|
-
import * as React from 'react'; // import clsx from 'clsx';
|
6
|
-
// import { inlineStyle } from '@ray-js/framework-shared';
|
7
|
-
|
8
|
-
import { View } from '@ray-js/components';
|
9
|
-
|
10
|
-
// import styles from './index.module.less';
|
11
|
-
function toPoint(percent) {
|
12
|
-
var str = percent.replace('%', '');
|
13
|
-
str = str / 100;
|
14
|
-
return str;
|
15
|
-
}
|
16
|
-
|
17
|
-
var LinearGradient = function (props) {
|
18
|
-
var x1 = props.x1,
|
19
|
-
x2 = props.x2,
|
20
|
-
y1 = props.y1,
|
21
|
-
y2 = props.y2,
|
22
|
-
stops = props.stops,
|
23
|
-
width = props.width,
|
24
|
-
height = props.height,
|
25
|
-
children = props.children;
|
26
|
-
var linearGradientArr = [];
|
27
|
-
var linearGradientAngle = 0;
|
28
|
-
|
29
|
-
for (var prop in stops) {
|
30
|
-
linearGradientArr.push(stops[prop] + ' ' + prop);
|
31
|
-
}
|
32
|
-
|
33
|
-
var radian = Math.atan2((toPoint(y1) - toPoint(y2)) * height, (toPoint(x1) - toPoint(x2)) * width);
|
34
|
-
linearGradientAngle = 180 / Math.PI * radian;
|
35
|
-
console.log('linearGradientAngle', linearGradientAngle);
|
36
|
-
|
37
|
-
if (linearGradientAngle < 0 && linearGradientAngle > -90) {
|
38
|
-
linearGradientAngle = 180 - linearGradientAngle;
|
39
|
-
} else if (linearGradientAngle === -90) {
|
40
|
-
linearGradientAngle = 90 - linearGradientAngle;
|
41
|
-
} else {
|
42
|
-
linearGradientAngle = -linearGradientAngle;
|
43
|
-
}
|
44
|
-
|
45
|
-
var mixStyle = {
|
46
|
-
width: typeof width === 'number' ? "".concat(width, "px") : width,
|
47
|
-
height: typeof height === 'number' ? "".concat(height, "px") : height,
|
48
|
-
backgroundColor: 'pink',
|
49
|
-
backgroundImage: "linear-gradient(".concat(linearGradientAngle, "deg,").concat(linearGradientArr.toString(), " )")
|
50
|
-
};
|
51
|
-
return /*#__PURE__*/React.createElement(View, {
|
52
|
-
style: mixStyle
|
53
|
-
}, children);
|
54
|
-
};
|
55
|
-
|
56
|
-
export default LinearGradient;
|
@@ -1,53 +0,0 @@
|
|
1
|
-
import "core-js/modules/es.regexp.exec.js";
|
2
|
-
import "core-js/modules/es.string.replace.js";
|
3
|
-
import "core-js/modules/es.array.concat.js";
|
4
|
-
import "core-js/modules/es.object.to-string.js";
|
5
|
-
import * as React from 'react';
|
6
|
-
import { View } from '@ray-js/components';
|
7
|
-
|
8
|
-
function toPoint(percent) {
|
9
|
-
var str = percent.replace('%', '');
|
10
|
-
str = str / 100;
|
11
|
-
return str;
|
12
|
-
}
|
13
|
-
|
14
|
-
var LinearGradient = function (props) {
|
15
|
-
var x1 = props.x1,
|
16
|
-
x2 = props.x2,
|
17
|
-
y1 = props.y1,
|
18
|
-
y2 = props.y2,
|
19
|
-
stops = props.stops,
|
20
|
-
width = props.width,
|
21
|
-
height = props.height,
|
22
|
-
children = props.children;
|
23
|
-
var linearGradientArr = [];
|
24
|
-
var linearGradientAngle = 0;
|
25
|
-
|
26
|
-
for (var prop in stops) {
|
27
|
-
linearGradientArr.push(stops[prop] + ' ' + prop);
|
28
|
-
}
|
29
|
-
|
30
|
-
var radian = Math.atan2((toPoint(y1) - toPoint(y2)) * height, (toPoint(x1) - toPoint(x2)) * width);
|
31
|
-
linearGradientAngle = 180 / Math.PI * radian;
|
32
|
-
console.log('linearGradientAngle', linearGradientAngle);
|
33
|
-
|
34
|
-
if (linearGradientAngle < 0 && linearGradientAngle > -90) {
|
35
|
-
linearGradientAngle = 180 - linearGradientAngle;
|
36
|
-
} else if (linearGradientAngle === -90) {
|
37
|
-
linearGradientAngle = 90 - linearGradientAngle;
|
38
|
-
} else {
|
39
|
-
linearGradientAngle = -linearGradientAngle;
|
40
|
-
}
|
41
|
-
|
42
|
-
var mixStyle = {
|
43
|
-
width: typeof width === 'number' ? "".concat(width, "px") : width,
|
44
|
-
height: typeof height === 'number' ? "".concat(height, "px") : height,
|
45
|
-
backgroundColor: 'pink',
|
46
|
-
backgroundImage: "linear-gradient(".concat(linearGradientAngle, "deg,").concat(linearGradientArr.toString(), " )")
|
47
|
-
};
|
48
|
-
return /*#__PURE__*/React.createElement(View, {
|
49
|
-
style: mixStyle
|
50
|
-
}, children);
|
51
|
-
};
|
52
|
-
|
53
|
-
export default LinearGradient;
|
@@ -1,58 +0,0 @@
|
|
1
|
-
/// <reference types="react" />
|
2
|
-
import { BaseProps } from '../types';
|
3
|
-
export interface LinearGradientProps extends BaseProps {
|
4
|
-
/**
|
5
|
-
* @description.en width
|
6
|
-
* @description.zh 宽度
|
7
|
-
* @default 300
|
8
|
-
*/
|
9
|
-
width: number;
|
10
|
-
/**
|
11
|
-
* @description.en height
|
12
|
-
* @description.zh 高度
|
13
|
-
* @default 300
|
14
|
-
*/
|
15
|
-
height: number;
|
16
|
-
/**
|
17
|
-
* @description.zh 起始点的x轴坐标
|
18
|
-
* @description.en The x-axis coordinate of the starting point
|
19
|
-
* @default '0%'
|
20
|
-
*/
|
21
|
-
x1?: string;
|
22
|
-
/**
|
23
|
-
* @description.zh 终点的x轴坐标
|
24
|
-
* @description.en The x-axis coordinate of the ending point
|
25
|
-
* @default '0%'
|
26
|
-
*/
|
27
|
-
x2?: string;
|
28
|
-
/**
|
29
|
-
* @description.zh 起始点的y轴坐标
|
30
|
-
* @description.en The y-axis coordinate of the starting point
|
31
|
-
* @default '0%'
|
32
|
-
*/
|
33
|
-
y1?: string;
|
34
|
-
/**
|
35
|
-
* @description.zh 终点的y轴坐标
|
36
|
-
* @description.en The y-axis coordinate of the ending point
|
37
|
-
* @default '0%'
|
38
|
-
*/
|
39
|
-
y2?: string;
|
40
|
-
/**
|
41
|
-
* @description.zh 渐变梯度停点
|
42
|
-
* @description.en The stop point of gradient
|
43
|
-
* @default { '0%': 'rgb(255, 255, 255)', '100%': 'rgb(0, 0, 0)' }
|
44
|
-
*/
|
45
|
-
stops?: Record<string, string>;
|
46
|
-
children?: React.ReactElement;
|
47
|
-
}
|
48
|
-
export declare const defaultLinearGradient: {
|
49
|
-
style: null;
|
50
|
-
stops: {
|
51
|
-
'0%': string;
|
52
|
-
'100%': string;
|
53
|
-
};
|
54
|
-
x1: string;
|
55
|
-
y1: string;
|
56
|
-
x2: string;
|
57
|
-
y2: string;
|
58
|
-
};
|
package/lib/Modal/Modal.d.ts
DELETED
package/lib/Modal/Modal.js
DELETED
@@ -1,10 +0,0 @@
|
|
1
|
-
import * as React from 'react';
|
2
|
-
|
3
|
-
// import styles from './index.module.less';
|
4
|
-
var Modal = function () {
|
5
|
-
// const { disabled, className, style } = props;
|
6
|
-
return /*#__PURE__*/React.createElement("div", null, "\u6682\u672A\u5B9E\u73B0");
|
7
|
-
};
|
8
|
-
|
9
|
-
Modal.displayName = 'Modal';
|
10
|
-
export default Modal;
|
package/lib/Modal/Modal.thing.js
DELETED
@@ -1,75 +0,0 @@
|
|
1
|
-
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
2
|
-
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
3
|
-
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
4
|
-
import * as React from 'react';
|
5
|
-
import clsx from 'clsx';
|
6
|
-
import { inlineStyle } from '@ray-js/framework-shared';
|
7
|
-
import View from '../View';
|
8
|
-
import styles from './index.module.less';
|
9
|
-
var DURATION = 300; // Modal动画时长,不可props更改
|
10
|
-
|
11
|
-
var Modal = function (props) {
|
12
|
-
var _clsx;
|
13
|
-
|
14
|
-
var isPreShow = React.useRef(false);
|
15
|
-
var id = props.id,
|
16
|
-
_props$show = props.show,
|
17
|
-
show = _props$show === void 0 ? false : _props$show,
|
18
|
-
_props$overlay = props.overlay,
|
19
|
-
overlay = _props$overlay === void 0 ? false : _props$overlay,
|
20
|
-
_props$onClickOverlay = props.onClickOverlay,
|
21
|
-
onClickOverlay = _props$onClickOverlay === void 0 ? function () {} : _props$onClickOverlay,
|
22
|
-
overlayStyle = props.overlayStyle,
|
23
|
-
customStyle = props.customStyle,
|
24
|
-
_props$position = props.position,
|
25
|
-
position = _props$position === void 0 ? 'top' : _props$position;
|
26
|
-
|
27
|
-
var _React$useState = React.useState(show),
|
28
|
-
_React$useState2 = _slicedToArray(_React$useState, 2),
|
29
|
-
isShowModalOpacity = _React$useState2[0],
|
30
|
-
setIsShowOpacity = _React$useState2[1];
|
31
|
-
|
32
|
-
var _React$useState3 = React.useState(show),
|
33
|
-
_React$useState4 = _slicedToArray(_React$useState3, 2),
|
34
|
-
isShowModalDisplay = _React$useState4[0],
|
35
|
-
setIsShowDisplay = _React$useState4[1];
|
36
|
-
|
37
|
-
React.useEffect(function () {
|
38
|
-
if (show) {
|
39
|
-
isPreShow.current = true;
|
40
|
-
setIsShowDisplay(true);
|
41
|
-
setTimeout(function () {
|
42
|
-
setIsShowOpacity(true);
|
43
|
-
}, 10);
|
44
|
-
} else if (isPreShow.current) {
|
45
|
-
isPreShow.current = false;
|
46
|
-
setTimeout(function () {
|
47
|
-
setIsShowDisplay(false);
|
48
|
-
}, DURATION);
|
49
|
-
setIsShowOpacity(false);
|
50
|
-
}
|
51
|
-
}, [show]);
|
52
|
-
|
53
|
-
var stopPropagation = function (e) {
|
54
|
-
e.origin.stopPropagation();
|
55
|
-
};
|
56
|
-
|
57
|
-
return /*#__PURE__*/React.createElement(View, {
|
58
|
-
id: id,
|
59
|
-
className: clsx(styles.modalWrp, styles[position], (_clsx = {}, _defineProperty(_clsx, styles.showModalOpacity, isShowModalOpacity), _defineProperty(_clsx, styles.hideModalOpacity, !isShowModalOpacity), _defineProperty(_clsx, styles.showModalDisplay, isShowModalDisplay), _defineProperty(_clsx, styles.hideModalDisplay, !isShowModalDisplay), _defineProperty(_clsx, styles.opacityOverlay, !overlay), _clsx)),
|
60
|
-
style: inlineStyle(_objectSpread({}, overlayStyle)),
|
61
|
-
onClick: function handleMaskClick(e) {
|
62
|
-
e.origin.stopPropagation();
|
63
|
-
onClickOverlay({
|
64
|
-
type: 'clickoverlay'
|
65
|
-
});
|
66
|
-
},
|
67
|
-
onTouchMove: stopPropagation
|
68
|
-
}, isShowModalOpacity && /*#__PURE__*/React.createElement(View, {
|
69
|
-
className: clsx(styles.container),
|
70
|
-
onClick: stopPropagation
|
71
|
-
}, props.children));
|
72
|
-
};
|
73
|
-
|
74
|
-
Modal.displayName = 'Modal';
|
75
|
-
export default Modal;
|
@@ -1,75 +0,0 @@
|
|
1
|
-
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
2
|
-
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
3
|
-
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
4
|
-
import * as React from 'react';
|
5
|
-
import clsx from 'clsx';
|
6
|
-
import { inlineStyle } from '@ray-js/framework-shared';
|
7
|
-
import View from '../View';
|
8
|
-
import styles from './index.module.less';
|
9
|
-
var DURATION = 300; // Modal动画时长,不可props更改
|
10
|
-
|
11
|
-
var Modal = function (props) {
|
12
|
-
var _clsx;
|
13
|
-
|
14
|
-
var isPreShow = React.useRef(false);
|
15
|
-
var id = props.id,
|
16
|
-
_props$show = props.show,
|
17
|
-
show = _props$show === void 0 ? false : _props$show,
|
18
|
-
_props$overlay = props.overlay,
|
19
|
-
overlay = _props$overlay === void 0 ? false : _props$overlay,
|
20
|
-
_props$onClickOverlay = props.onClickOverlay,
|
21
|
-
onClickOverlay = _props$onClickOverlay === void 0 ? function () {} : _props$onClickOverlay,
|
22
|
-
overlayStyle = props.overlayStyle,
|
23
|
-
customStyle = props.customStyle,
|
24
|
-
_props$position = props.position,
|
25
|
-
position = _props$position === void 0 ? 'top' : _props$position;
|
26
|
-
|
27
|
-
var _React$useState = React.useState(show),
|
28
|
-
_React$useState2 = _slicedToArray(_React$useState, 2),
|
29
|
-
isShowModalOpacity = _React$useState2[0],
|
30
|
-
setIsShowOpacity = _React$useState2[1];
|
31
|
-
|
32
|
-
var _React$useState3 = React.useState(show),
|
33
|
-
_React$useState4 = _slicedToArray(_React$useState3, 2),
|
34
|
-
isShowModalDisplay = _React$useState4[0],
|
35
|
-
setIsShowDisplay = _React$useState4[1];
|
36
|
-
|
37
|
-
React.useEffect(function () {
|
38
|
-
if (show) {
|
39
|
-
isPreShow.current = true;
|
40
|
-
setIsShowDisplay(true);
|
41
|
-
setTimeout(function () {
|
42
|
-
setIsShowOpacity(true);
|
43
|
-
}, 10);
|
44
|
-
} else if (isPreShow.current) {
|
45
|
-
isPreShow.current = false;
|
46
|
-
setTimeout(function () {
|
47
|
-
setIsShowDisplay(false);
|
48
|
-
}, DURATION);
|
49
|
-
setIsShowOpacity(false);
|
50
|
-
}
|
51
|
-
}, [show]);
|
52
|
-
|
53
|
-
var stopPropagation = function (e) {
|
54
|
-
e.origin.stopPropagation();
|
55
|
-
};
|
56
|
-
|
57
|
-
return /*#__PURE__*/React.createElement(View, {
|
58
|
-
id: id,
|
59
|
-
className: clsx(styles.modalWrp, styles[position], (_clsx = {}, _defineProperty(_clsx, styles.showModalOpacity, isShowModalOpacity), _defineProperty(_clsx, styles.hideModalOpacity, !isShowModalOpacity), _defineProperty(_clsx, styles.showModalDisplay, isShowModalDisplay), _defineProperty(_clsx, styles.hideModalDisplay, !isShowModalDisplay), _defineProperty(_clsx, styles.opacityOverlay, !overlay), _clsx)),
|
60
|
-
style: inlineStyle(_objectSpread({}, overlayStyle)),
|
61
|
-
onTouchMove: stopPropagation,
|
62
|
-
onClick: function handleMaskClick(e) {
|
63
|
-
e.origin.stopPropagation();
|
64
|
-
onClickOverlay({
|
65
|
-
type: 'clickoverlay'
|
66
|
-
});
|
67
|
-
}
|
68
|
-
}, isShowModalOpacity && /*#__PURE__*/React.createElement(View, {
|
69
|
-
className: clsx(styles.container),
|
70
|
-
onClick: stopPropagation
|
71
|
-
}, props.children));
|
72
|
-
};
|
73
|
-
|
74
|
-
Modal.displayName = 'Modal';
|
75
|
-
export default Modal;
|
package/lib/Modal/index.d.ts
DELETED
package/lib/Modal/index.js
DELETED
@@ -1,46 +0,0 @@
|
|
1
|
-
.modalWrp {
|
2
|
-
position: fixed;
|
3
|
-
display: flex;
|
4
|
-
z-index: 500;
|
5
|
-
top: 0;
|
6
|
-
left: 0;
|
7
|
-
width: 100vh;
|
8
|
-
height: 100vh;
|
9
|
-
background-color: rgba(0, 0, 0, 0.5);
|
10
|
-
pointer-events: auto;
|
11
|
-
flex-direction: column;
|
12
|
-
transition: opacity 0.3s;
|
13
|
-
&.opacityOverlay {
|
14
|
-
background: transparent;
|
15
|
-
pointer-events: none;
|
16
|
-
}
|
17
|
-
&.top {
|
18
|
-
justify-content: flex-start;
|
19
|
-
}
|
20
|
-
&.center {
|
21
|
-
justify-content: center;
|
22
|
-
}
|
23
|
-
&.bottom {
|
24
|
-
justify-content: flex-end;
|
25
|
-
}
|
26
|
-
&.showModalDisplay {
|
27
|
-
display: flex;
|
28
|
-
}
|
29
|
-
&.hideModalDisplay {
|
30
|
-
display: none;
|
31
|
-
}
|
32
|
-
&.showModalOpacity {
|
33
|
-
opacity: 1;
|
34
|
-
}
|
35
|
-
&.hideModalOpacity {
|
36
|
-
opacity: 0;
|
37
|
-
}
|
38
|
-
}
|
39
|
-
.container {
|
40
|
-
position: fixed;
|
41
|
-
z-index: 200;
|
42
|
-
width: 100vw;
|
43
|
-
display: flex;
|
44
|
-
justify-content: center;
|
45
|
-
align-items: center;
|
46
|
-
}
|
package/lib/Modal/props.d.ts
DELETED
@@ -1,51 +0,0 @@
|
|
1
|
-
/// <reference types="react" />
|
2
|
-
import { BaseProps } from '../types';
|
3
|
-
export interface ITYModalProps extends IModalProps {
|
4
|
-
activeIdx: number;
|
5
|
-
children: JSX.Element[];
|
6
|
-
}
|
7
|
-
export interface IModalProps extends BaseProps {
|
8
|
-
/**
|
9
|
-
* @description.en Whether to display the dialog box
|
10
|
-
* @description.zh 是否显示弹框
|
11
|
-
* @default false
|
12
|
-
*/
|
13
|
-
show: boolean;
|
14
|
-
/**
|
15
|
-
* @description.en Whether a mask is displayed
|
16
|
-
* @description.zh 是否显示遮罩
|
17
|
-
* @default true
|
18
|
-
*/
|
19
|
-
overlay?: boolean;
|
20
|
-
/**
|
21
|
-
* @description.en Click on the mask to trigger the event
|
22
|
-
* @description.zh 点击蒙层触发事件
|
23
|
-
* @default undefined
|
24
|
-
*/
|
25
|
-
onClickOverlay?: (event: {
|
26
|
-
/**
|
27
|
-
* @description.en type
|
28
|
-
* @description.zh 类型
|
29
|
-
* @default undefined
|
30
|
-
*/
|
31
|
-
type: 'clickoverlay';
|
32
|
-
}) => void;
|
33
|
-
/**
|
34
|
-
* @description.en Custom mask layer styles
|
35
|
-
* @description.zh 自定义遮罩层样式
|
36
|
-
* @default undefined
|
37
|
-
*/
|
38
|
-
overlayStyle?: React.CSSProperties;
|
39
|
-
/**
|
40
|
-
* @description.en Custom pop-up layer styles
|
41
|
-
* @description.zh 自定义弹出层样式
|
42
|
-
* @default undefined
|
43
|
-
*/
|
44
|
-
customStyle?: React.CSSProperties;
|
45
|
-
/**
|
46
|
-
* @description.en Pop-up layer pop-up position
|
47
|
-
* @description.zh 弹出层弹出位置
|
48
|
-
* @default center
|
49
|
-
*/
|
50
|
-
position?: 'top' | 'center' | 'bottom';
|
51
|
-
}
|
package/lib/Modal/props.js
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
export {};
|
@@ -1,8 +0,0 @@
|
|
1
|
-
import * as React from 'react';
|
2
|
-
import { View } from '@ray-js/components';
|
3
|
-
|
4
|
-
var RadialGradient = function () {
|
5
|
-
return /*#__PURE__*/React.createElement(View, null, "web \u5F84\u5411\u6E10\u53D8 \u6682\u672A\u5B9E\u73B0");
|
6
|
-
};
|
7
|
-
|
8
|
-
export default RadialGradient;
|
@@ -1,36 +0,0 @@
|
|
1
|
-
import "core-js/modules/es.array.map.js";
|
2
|
-
import "core-js/modules/es.array.concat.js";
|
3
|
-
import "core-js/modules/es.object.to-string.js";
|
4
|
-
import "core-js/modules/es.regexp.to-string.js";
|
5
|
-
import * as React from 'react'; // import clsx from 'clsx';
|
6
|
-
// import { inlineStyle } from '@ray-js/framework-shared';
|
7
|
-
|
8
|
-
import { View } from '@ray-js/components';
|
9
|
-
|
10
|
-
// import styles from './index.module.less';
|
11
|
-
var RadialGradient = function (props) {
|
12
|
-
var fx = props.fx,
|
13
|
-
fy = props.fy,
|
14
|
-
rx = props.rx,
|
15
|
-
ry = props.ry,
|
16
|
-
stops = props.stops,
|
17
|
-
width = props.width,
|
18
|
-
height = props.height,
|
19
|
-
children = props.children,
|
20
|
-
className = props.className;
|
21
|
-
var RadialGradientArr = stops.map(function (item) {
|
22
|
-
return item.stopColor + ' ' + item.offset;
|
23
|
-
});
|
24
|
-
var mixStyle = {
|
25
|
-
width: typeof width === 'number' ? "".concat(width, "px") : width,
|
26
|
-
height: typeof height === 'number' ? "".concat(height, "px") : height,
|
27
|
-
backgroundColor: 'pink',
|
28
|
-
backgroundImage: "radial-gradient(".concat(rx, " ").concat(ry, " ellipse at ").concat(fx, " ").concat(fy, ", ").concat(RadialGradientArr.toString(), ")")
|
29
|
-
};
|
30
|
-
return /*#__PURE__*/React.createElement(View, {
|
31
|
-
className: className,
|
32
|
-
style: mixStyle
|
33
|
-
}, children);
|
34
|
-
};
|
35
|
-
|
36
|
-
export default RadialGradient;
|
@@ -1,36 +0,0 @@
|
|
1
|
-
import "core-js/modules/es.array.map.js";
|
2
|
-
import "core-js/modules/es.array.concat.js";
|
3
|
-
import "core-js/modules/es.object.to-string.js";
|
4
|
-
import "core-js/modules/es.regexp.to-string.js";
|
5
|
-
import * as React from 'react'; // import clsx from 'clsx';
|
6
|
-
// import { inlineStyle } from '@ray-js/framework-shared';
|
7
|
-
|
8
|
-
import { View } from '@ray-js/components';
|
9
|
-
|
10
|
-
// import styles from './index.module.less';
|
11
|
-
var RadialGradient = function (props) {
|
12
|
-
var fx = props.fx,
|
13
|
-
fy = props.fy,
|
14
|
-
rx = props.rx,
|
15
|
-
ry = props.ry,
|
16
|
-
stops = props.stops,
|
17
|
-
width = props.width,
|
18
|
-
height = props.height,
|
19
|
-
children = props.children,
|
20
|
-
className = props.className;
|
21
|
-
var RadialGradientArr = stops.map(function (item) {
|
22
|
-
return item.stopColor + ' ' + item.offset;
|
23
|
-
});
|
24
|
-
var mixStyle = {
|
25
|
-
width: typeof width === 'number' ? "".concat(width, "px") : width,
|
26
|
-
height: typeof height === 'number' ? "".concat(height, "px") : height,
|
27
|
-
backgroundColor: 'pink',
|
28
|
-
backgroundImage: "radial-gradient(".concat(rx, " ").concat(ry, " ellipse at ").concat(fx, " ").concat(fy, ", ").concat(RadialGradientArr.toString(), ")")
|
29
|
-
};
|
30
|
-
return /*#__PURE__*/React.createElement(View, {
|
31
|
-
className: className,
|
32
|
-
style: mixStyle
|
33
|
-
}, children);
|
34
|
-
};
|
35
|
-
|
36
|
-
export default RadialGradient;
|