@digitalc/dxp-ui 0.0.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/LICENSE +21 -0
- package/README.md +38 -0
- package/es/assets/iconFont/iconfont.css +734 -0
- package/es/assets/iconFont/iconfont.eot +0 -0
- package/es/assets/iconFont/iconfont.js +43 -0
- package/es/assets/iconFont/iconfont.json +1262 -0
- package/es/assets/iconFont/iconfont.svg +377 -0
- package/es/assets/iconFont/iconfont.ttf +0 -0
- package/es/assets/iconFont/iconfont.woff +0 -0
- package/es/assets/iconFont/iconfont.woff2 +0 -0
- package/es/assets/token.json +239 -0
- package/es/components/Button/designTokens.d.ts +66 -0
- package/es/components/Button/designTokens.js +131 -0
- package/es/components/Button/index.d.ts +44 -0
- package/es/components/Button/index.js +92 -0
- package/es/components/Button/index_backup.d.ts +72 -0
- package/es/components/Button/index_backup.js +110 -0
- package/es/components/Button/style/button.less +34 -0
- package/es/components/Button/style/variables.less +5 -0
- package/es/components/Text/index.d.ts +32 -0
- package/es/components/Text/index.js +59 -0
- package/es/components/Text/style/text.less +116 -0
- package/es/components/Text/style/variables.less +4 -0
- package/es/components/index.d.ts +4 -0
- package/es/components/index.js +4 -0
- package/es/constants/index.d.ts +15 -0
- package/es/constants/index.js +16 -0
- package/es/fonts/Poppins/Poppins-Bold.ttf +0 -0
- package/es/fonts/Poppins/Poppins-BoldItalic.ttf +0 -0
- package/es/fonts/Poppins/Poppins-ExtraBold.ttf +0 -0
- package/es/fonts/Poppins/Poppins-ExtraBoldItalic.ttf +0 -0
- package/es/fonts/Poppins/Poppins-ExtraLight.ttf +0 -0
- package/es/fonts/Poppins/Poppins-ExtraLightItalic.ttf +0 -0
- package/es/fonts/Poppins/Poppins-Italic.ttf +0 -0
- package/es/fonts/Poppins/Poppins-Light.ttf +0 -0
- package/es/fonts/Poppins/Poppins-LightItalic.ttf +0 -0
- package/es/fonts/Poppins/Poppins-Medium.ttf +0 -0
- package/es/fonts/Poppins/Poppins-MediumItalic.ttf +0 -0
- package/es/fonts/Poppins/Poppins-Regular.ttf +0 -0
- package/es/fonts/Poppins/Poppins-SemiBold.ttf +0 -0
- package/es/fonts/Poppins/Poppins-SemiBoldItalic.ttf +0 -0
- package/es/fonts/Poppins/Poppins-Thin.ttf +0 -0
- package/es/fonts/Poppins/Poppins-ThinItalic.ttf +0 -0
- package/es/fonts/Roboto/Roboto-Black.ttf +0 -0
- package/es/fonts/Roboto/Roboto-BlackItalic.ttf +0 -0
- package/es/fonts/Roboto/Roboto-Bold.ttf +0 -0
- package/es/fonts/Roboto/Roboto-BoldItalic.ttf +0 -0
- package/es/fonts/Roboto/Roboto-ExtraBold.ttf +0 -0
- package/es/fonts/Roboto/Roboto-ExtraBoldItalic.ttf +0 -0
- package/es/fonts/Roboto/Roboto-ExtraLight.ttf +0 -0
- package/es/fonts/Roboto/Roboto-ExtraLightItalic.ttf +0 -0
- package/es/fonts/Roboto/Roboto-Italic-VariableFont_wdth,wght.ttf +0 -0
- package/es/fonts/Roboto/Roboto-Italic.ttf +0 -0
- package/es/fonts/Roboto/Roboto-Light.ttf +0 -0
- package/es/fonts/Roboto/Roboto-LightItalic.ttf +0 -0
- package/es/fonts/Roboto/Roboto-Medium.ttf +0 -0
- package/es/fonts/Roboto/Roboto-MediumItalic.ttf +0 -0
- package/es/fonts/Roboto/Roboto-Regular.ttf +0 -0
- package/es/fonts/Roboto/Roboto-SemiBold.ttf +0 -0
- package/es/fonts/Roboto/Roboto-SemiBoldItalic.ttf +0 -0
- package/es/fonts/Roboto/Roboto-Thin.ttf +0 -0
- package/es/fonts/Roboto/Roboto-ThinItalic.ttf +0 -0
- package/es/fonts/Roboto/Roboto-VariableFont_wdth,wght.ttf +0 -0
- package/es/index.d.ts +3 -0
- package/es/index.js +3 -0
- package/es/style/antdDesignToken.json +503 -0
- package/es/style/themes/base-vars.css +6 -0
- package/es/style/themes/colorful.css +5 -0
- package/es/style/themes/index.css +4 -0
- package/es/style/variables.less +34 -0
- package/es/tokens/DXPGlobal.d.ts +240 -0
- package/es/tokens/DXPGlobal.js +5 -0
- package/es/utils/noop.d.ts +1 -0
- package/es/utils/noop.js +1 -0
- package/es/utils/themeContext.d.ts +11 -0
- package/es/utils/themeContext.js +39 -0
- package/es/utils/tokenHelper.d.ts +1 -0
- package/es/utils/tokenHelper.js +4 -0
- package/es/utils/tokenManager.d.ts +1464 -0
- package/es/utils/tokenManager.js +750 -0
- package/package.json +112 -0
- package/umd/dxp-ui.min.css +1 -0
- package/umd/dxp-ui.min.js +1 -0
- package/umd/static/Poppins-Bold.8001a01b.ttf +0 -0
- package/umd/static/Roboto-Bold.ff276312.ttf +0 -0
- package/umd/static/Roboto-Regular.a5023d7b.ttf +0 -0
- package/umd/static/Roboto-SemiBold.3452daa4.ttf +0 -0
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
2
|
+
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
|
3
|
+
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
4
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
5
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
6
|
+
import _inherits from "@babel/runtime/helpers/esm/inherits";
|
|
7
|
+
import _createSuper from "@babel/runtime/helpers/esm/createSuper";
|
|
8
|
+
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
9
|
+
var _excluded = ["children", "block", "htmlType", "loading", "circle", "className", "style", "disabled", "size", "theme", "type", "prefixCls", "iconPosition"];
|
|
10
|
+
/* eslint-disable @typescript-eslint/no-unused-vars */
|
|
11
|
+
import React, { PureComponent } from 'react';
|
|
12
|
+
import { default as classNames, default as cls } from 'classnames';
|
|
13
|
+
import { omit } from 'lodash';
|
|
14
|
+
import PropTypes from 'prop-types';
|
|
15
|
+
import { cssClasses, strings } from "../../constants";
|
|
16
|
+
import { noop } from "../../utils/noop";
|
|
17
|
+
import "./style/button.less";
|
|
18
|
+
var btnSizes = strings.sizes;
|
|
19
|
+
var htmlTypes = strings.htmlTypes,
|
|
20
|
+
btnTypes = strings.btnTypes;
|
|
21
|
+
var Button = /*#__PURE__*/function (_PureComponent) {
|
|
22
|
+
_inherits(Button, _PureComponent);
|
|
23
|
+
var _super = _createSuper(Button);
|
|
24
|
+
function Button() {
|
|
25
|
+
_classCallCheck(this, Button);
|
|
26
|
+
return _super.apply(this, arguments);
|
|
27
|
+
}
|
|
28
|
+
_createClass(Button, [{
|
|
29
|
+
key: "render",
|
|
30
|
+
value: function render() {
|
|
31
|
+
var _this$props = this.props,
|
|
32
|
+
children = _this$props.children,
|
|
33
|
+
block = _this$props.block,
|
|
34
|
+
htmlType = _this$props.htmlType,
|
|
35
|
+
loading = _this$props.loading,
|
|
36
|
+
circle = _this$props.circle,
|
|
37
|
+
className = _this$props.className,
|
|
38
|
+
style = _this$props.style,
|
|
39
|
+
disabled = _this$props.disabled,
|
|
40
|
+
size = _this$props.size,
|
|
41
|
+
theme = _this$props.theme,
|
|
42
|
+
type = _this$props.type,
|
|
43
|
+
prefixCls = _this$props.prefixCls,
|
|
44
|
+
iconPosition = _this$props.iconPosition,
|
|
45
|
+
attr = _objectWithoutProperties(_this$props, _excluded);
|
|
46
|
+
var baseProps = _objectSpread(_objectSpread({
|
|
47
|
+
disabled: disabled
|
|
48
|
+
}, omit(attr, ['x-gemo-children-alias'])), {}, {
|
|
49
|
+
className: classNames(prefixCls, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(prefixCls, "-").concat(type), !disabled && type), "".concat(prefixCls, "-disabled"), disabled), "".concat(prefixCls, "-size-").concat(size), size), "".concat(prefixCls, "-").concat(theme), theme), "".concat(prefixCls, "-block"), block), "".concat(prefixCls, "-circle"), circle), "".concat(prefixCls, "-").concat(type, "-disabled"), disabled && type), className),
|
|
50
|
+
type: htmlType,
|
|
51
|
+
'aria-disabled': disabled,
|
|
52
|
+
style: style
|
|
53
|
+
});
|
|
54
|
+
var xDXpProps = {};
|
|
55
|
+
if (!(className && className.includes('-with-icon'))) {
|
|
56
|
+
xDXpProps['x-dxp-prop'] = this.props['x-gemo-dxp-alias'] || 'children';
|
|
57
|
+
}
|
|
58
|
+
return (
|
|
59
|
+
/*#__PURE__*/
|
|
60
|
+
// eslint-disable-next-line react/button-has-type
|
|
61
|
+
React.createElement("button", _extends({}, baseProps, {
|
|
62
|
+
onClick: this.props.onClick,
|
|
63
|
+
onMouseDown: this.props.onMouseDown
|
|
64
|
+
}), /*#__PURE__*/React.createElement("span", _extends({
|
|
65
|
+
className: cls("".concat(prefixCls, "-content"), this.props.contentClassName),
|
|
66
|
+
onClick: function onClick(e) {
|
|
67
|
+
return disabled && e.stopPropagation();
|
|
68
|
+
}
|
|
69
|
+
}, xDXpProps), children))
|
|
70
|
+
// <AntdBtn {...this.props}>{children}</AntdBtn>
|
|
71
|
+
);
|
|
72
|
+
}
|
|
73
|
+
}]);
|
|
74
|
+
return Button;
|
|
75
|
+
}(PureComponent);
|
|
76
|
+
_defineProperty(Button, "defaultProps", {
|
|
77
|
+
disabled: false,
|
|
78
|
+
size: 'default',
|
|
79
|
+
type: 'primary',
|
|
80
|
+
theme: 'light',
|
|
81
|
+
block: false,
|
|
82
|
+
htmlType: 'button',
|
|
83
|
+
onMouseDown: noop,
|
|
84
|
+
onClick: noop,
|
|
85
|
+
onMouseEnter: noop,
|
|
86
|
+
onMouseLeave: noop,
|
|
87
|
+
prefixCls: cssClasses.PREFIX + '-button'
|
|
88
|
+
});
|
|
89
|
+
// todo 待移除,统一走 TS 类型检查
|
|
90
|
+
_defineProperty(Button, "propTypes", {
|
|
91
|
+
children: PropTypes.node,
|
|
92
|
+
disabled: PropTypes.bool,
|
|
93
|
+
prefixCls: PropTypes.string,
|
|
94
|
+
style: PropTypes.object,
|
|
95
|
+
size: PropTypes.oneOf(btnSizes),
|
|
96
|
+
type: PropTypes.oneOf(btnTypes),
|
|
97
|
+
block: PropTypes.bool,
|
|
98
|
+
onClick: PropTypes.func,
|
|
99
|
+
onMouseDown: PropTypes.func,
|
|
100
|
+
circle: PropTypes.bool,
|
|
101
|
+
loading: PropTypes.bool,
|
|
102
|
+
htmlType: PropTypes.oneOf(htmlTypes),
|
|
103
|
+
theme: PropTypes.oneOf(strings.themes),
|
|
104
|
+
className: PropTypes.string,
|
|
105
|
+
onMouseEnter: PropTypes.func,
|
|
106
|
+
onMouseLeave: PropTypes.func,
|
|
107
|
+
'aria-label': PropTypes.string,
|
|
108
|
+
contentClassName: PropTypes.string
|
|
109
|
+
});
|
|
110
|
+
export { Button as default };
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
@import './variables.less';
|
|
2
|
+
|
|
3
|
+
// 基础按钮样式
|
|
4
|
+
@components: button;
|
|
5
|
+
|
|
6
|
+
// 使用字符串拼接
|
|
7
|
+
.@{prefix}-@{components} {
|
|
8
|
+
|
|
9
|
+
// 按钮类型
|
|
10
|
+
// &-primary {
|
|
11
|
+
// background-color: @btn-primary-bg-default;
|
|
12
|
+
// }
|
|
13
|
+
&:not(:disabled):not(.ant-btn-disabled):hover {
|
|
14
|
+
opacity: 0.8;
|
|
15
|
+
transition: opacity 0.3s ease, transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
|
|
16
|
+
.@{prefix}-text {
|
|
17
|
+
transform: scale(0.9);
|
|
18
|
+
transform-origin: center;
|
|
19
|
+
transition: opacity 0.3s ease, transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
|
|
20
|
+
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
&:not(:disabled):not(.dxp-button-disabled):active {
|
|
25
|
+
opacity: 0.5;
|
|
26
|
+
transition: opacity 0.3s ease, transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
|
|
27
|
+
.@{prefix}-text {
|
|
28
|
+
transform: scale(0.9);
|
|
29
|
+
transform-origin: center;
|
|
30
|
+
transition: opacity 0.3s ease, transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
|
|
31
|
+
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import React, { PureComponent } from 'react';
|
|
2
|
+
import { noop } from '../../utils/noop';
|
|
3
|
+
import './style/text.less';
|
|
4
|
+
export type Size = 'bannerTitle' | 'pageTitle' | 'sectionTitle' | 'header' | 'bodyBold' | 'bodyRegular' | 'bodyStrikethrough' | 'smallbodyRegular' | 'smallBodyStrikethrough' | 'smallBodySemiBold' | 'smallBodyBold' | 'smallBodyLink' | 'textLink' | 'mediumBody' | 'mediumBodyBold';
|
|
5
|
+
export interface xDXpProps {
|
|
6
|
+
'x-dxp-prop'?: string;
|
|
7
|
+
}
|
|
8
|
+
export interface TextProps extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, 'type'> {
|
|
9
|
+
children?: React.ReactNode;
|
|
10
|
+
className?: string;
|
|
11
|
+
size?: Size;
|
|
12
|
+
prefixCls?: string;
|
|
13
|
+
style?: React.CSSProperties;
|
|
14
|
+
onClick?: React.MouseEventHandler<HTMLButtonElement>;
|
|
15
|
+
onMouseDown?: React.MouseEventHandler<HTMLButtonElement>;
|
|
16
|
+
onMouseEnter?: React.MouseEventHandler<HTMLButtonElement>;
|
|
17
|
+
onMouseLeave?: React.MouseEventHandler<HTMLButtonElement>;
|
|
18
|
+
'aria-label'?: React.AriaAttributes['aria-label'];
|
|
19
|
+
'x-dxp-children-alias'?: string;
|
|
20
|
+
[key: string]: any;
|
|
21
|
+
}
|
|
22
|
+
export default class Text extends PureComponent<TextProps> {
|
|
23
|
+
static defaultProps: {
|
|
24
|
+
size: string;
|
|
25
|
+
onMouseDown: typeof noop;
|
|
26
|
+
onClick: typeof noop;
|
|
27
|
+
onMouseEnter: typeof noop;
|
|
28
|
+
onMouseLeave: typeof noop;
|
|
29
|
+
prefixCls: string;
|
|
30
|
+
};
|
|
31
|
+
render(): React.JSX.Element;
|
|
32
|
+
}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
2
|
+
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
|
3
|
+
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
4
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
5
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
6
|
+
import _inherits from "@babel/runtime/helpers/esm/inherits";
|
|
7
|
+
import _createSuper from "@babel/runtime/helpers/esm/createSuper";
|
|
8
|
+
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
9
|
+
var _excluded = ["children", "className", "size", "prefixCls", "style"];
|
|
10
|
+
/* eslint-disable @typescript-eslint/no-unused-vars */
|
|
11
|
+
import React, { PureComponent } from 'react';
|
|
12
|
+
import { default as classNames } from 'classnames';
|
|
13
|
+
import { omit } from 'lodash';
|
|
14
|
+
import { cssClasses } from "../../constants";
|
|
15
|
+
import { noop } from "../../utils/noop";
|
|
16
|
+
import "./style/text.less";
|
|
17
|
+
var Text = /*#__PURE__*/function (_PureComponent) {
|
|
18
|
+
_inherits(Text, _PureComponent);
|
|
19
|
+
var _super = _createSuper(Text);
|
|
20
|
+
function Text() {
|
|
21
|
+
_classCallCheck(this, Text);
|
|
22
|
+
return _super.apply(this, arguments);
|
|
23
|
+
}
|
|
24
|
+
_createClass(Text, [{
|
|
25
|
+
key: "render",
|
|
26
|
+
value: function render() {
|
|
27
|
+
var _this$props = this.props,
|
|
28
|
+
children = _this$props.children,
|
|
29
|
+
className = _this$props.className,
|
|
30
|
+
size = _this$props.size,
|
|
31
|
+
prefixCls = _this$props.prefixCls,
|
|
32
|
+
style = _this$props.style,
|
|
33
|
+
attr = _objectWithoutProperties(_this$props, _excluded);
|
|
34
|
+
var baseProps = _objectSpread(_objectSpread({}, omit(attr, ['x-gemo-children-alias'])), {}, {
|
|
35
|
+
className: classNames(prefixCls, _defineProperty({}, "".concat(prefixCls, "-size-").concat(size), size), className),
|
|
36
|
+
style: style
|
|
37
|
+
});
|
|
38
|
+
var xDXpProps = {};
|
|
39
|
+
if (!(className && className.includes('-with-icon'))) {
|
|
40
|
+
xDXpProps['x-dxp-prop'] = 'children';
|
|
41
|
+
}
|
|
42
|
+
return /*#__PURE__*/React.createElement("span", _extends({
|
|
43
|
+
onClick: this.props.onClick
|
|
44
|
+
}, xDXpProps, baseProps, {
|
|
45
|
+
onMouseDown: this.props.onMouseDown
|
|
46
|
+
}), children);
|
|
47
|
+
}
|
|
48
|
+
}]);
|
|
49
|
+
return Text;
|
|
50
|
+
}(PureComponent);
|
|
51
|
+
_defineProperty(Text, "defaultProps", {
|
|
52
|
+
size: 'bodyBold',
|
|
53
|
+
onMouseDown: noop,
|
|
54
|
+
onClick: noop,
|
|
55
|
+
onMouseEnter: noop,
|
|
56
|
+
onMouseLeave: noop,
|
|
57
|
+
prefixCls: cssClasses.PREFIX + '-text'
|
|
58
|
+
});
|
|
59
|
+
export { Text as default };
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
|
|
2
|
+
@import './variables.less';
|
|
3
|
+
// 定义默认颜色常量
|
|
4
|
+
@DEFAULT_COLOR: inherit;
|
|
5
|
+
@STRIKETHROUGH_COLOR: #757575;
|
|
6
|
+
@LINK_COLOR: #4E28E8;
|
|
7
|
+
|
|
8
|
+
.dxp-text-size-bannerTitle {
|
|
9
|
+
color: @DEFAULT_COLOR;
|
|
10
|
+
font-size: 40px;
|
|
11
|
+
line-height: 48px;
|
|
12
|
+
font-family: Poppins-Blod;
|
|
13
|
+
font-weight: bold;
|
|
14
|
+
}
|
|
15
|
+
.dxp-text-size-pageTitle {
|
|
16
|
+
color: @DEFAULT_COLOR;
|
|
17
|
+
font-size: 32px;
|
|
18
|
+
line-height: 40px;
|
|
19
|
+
font-family: Poppins-Blod;
|
|
20
|
+
font-weight: bold;
|
|
21
|
+
}
|
|
22
|
+
.dxp-text-size-sectionTitle {
|
|
23
|
+
color: @DEFAULT_COLOR;
|
|
24
|
+
font-size: 24px;
|
|
25
|
+
line-height: 30px;
|
|
26
|
+
font-family: Poppins-Blod;
|
|
27
|
+
font-weight: bold;
|
|
28
|
+
}
|
|
29
|
+
.dxp-text-size-header {
|
|
30
|
+
color: @DEFAULT_COLOR;
|
|
31
|
+
font-size: 20px;
|
|
32
|
+
line-height: 25px;
|
|
33
|
+
font-family: Poppins-Blod;
|
|
34
|
+
font-weight: bold;
|
|
35
|
+
}
|
|
36
|
+
.dxp-text-size-bodyBold {
|
|
37
|
+
color: @DEFAULT_COLOR;
|
|
38
|
+
font-size: 16px;
|
|
39
|
+
line-height: 24px;
|
|
40
|
+
font-family: Roboto-Bold;
|
|
41
|
+
font-weight: bold;
|
|
42
|
+
}
|
|
43
|
+
.dxp-text-size-bodyRegular {
|
|
44
|
+
color: @DEFAULT_COLOR;
|
|
45
|
+
font-size: 16px;
|
|
46
|
+
line-height: 24px;
|
|
47
|
+
font-family: Roboto-Regular;
|
|
48
|
+
font-weight: normal;
|
|
49
|
+
}
|
|
50
|
+
.dxp-text-size-bodyStrikethrough {
|
|
51
|
+
color: @STRIKETHROUGH_COLOR;
|
|
52
|
+
font-size: 16px;
|
|
53
|
+
line-height: 24px;
|
|
54
|
+
font-family: Roboto-Regular;
|
|
55
|
+
font-weight: normal;
|
|
56
|
+
text-decoration: line-through;
|
|
57
|
+
}
|
|
58
|
+
.dxp-text-size-smallbodyRegular {
|
|
59
|
+
color: @DEFAULT_COLOR;
|
|
60
|
+
font-family: Roboto-Regular;
|
|
61
|
+
font-weight: normal;
|
|
62
|
+
font-size: 12px;
|
|
63
|
+
line-height: 18px;
|
|
64
|
+
}
|
|
65
|
+
.dxp-text-size-smallBodyStrikethrough {
|
|
66
|
+
color: @STRIKETHROUGH_COLOR;
|
|
67
|
+
font-family: Roboto-Regular;
|
|
68
|
+
font-weight: normal;
|
|
69
|
+
font-size: 12px;
|
|
70
|
+
line-height: 18px;
|
|
71
|
+
text-decoration: line-through;
|
|
72
|
+
}
|
|
73
|
+
.dxp-text-size-smallBodySemiBold {
|
|
74
|
+
color: @DEFAULT_COLOR;
|
|
75
|
+
font-family: Roboto-SemiBold;
|
|
76
|
+
font-weight: bold;
|
|
77
|
+
font-size: 12px;
|
|
78
|
+
line-height: 18px;
|
|
79
|
+
}
|
|
80
|
+
.dxp-text-size-smallBodyBold {
|
|
81
|
+
color: @DEFAULT_COLOR;
|
|
82
|
+
font-family: Roboto-Bold;
|
|
83
|
+
font-weight: bold;
|
|
84
|
+
font-size: 12px;
|
|
85
|
+
line-height: 18px;
|
|
86
|
+
}
|
|
87
|
+
.dxp-text-size-smallBodyLink {
|
|
88
|
+
color: @LINK_COLOR;
|
|
89
|
+
font-family: Roboto-Bold;
|
|
90
|
+
font-weight: bold;
|
|
91
|
+
font-size: 12px;
|
|
92
|
+
line-height: 18px;
|
|
93
|
+
text-decoration: underline;
|
|
94
|
+
}
|
|
95
|
+
.dxp-text-size-textLink {
|
|
96
|
+
color: @LINK_COLOR;
|
|
97
|
+
font-family: Roboto-Bold;
|
|
98
|
+
font-weight: bold;
|
|
99
|
+
font-size: 16px;
|
|
100
|
+
line-height: 24px;
|
|
101
|
+
text-decoration: underline;
|
|
102
|
+
}
|
|
103
|
+
.dxp-text-size-mediumBody {
|
|
104
|
+
color: @DEFAULT_COLOR;
|
|
105
|
+
font-family: Roboto-Regular;
|
|
106
|
+
font-weight: normal;
|
|
107
|
+
font-size: 14px;
|
|
108
|
+
line-height: 22px;
|
|
109
|
+
}
|
|
110
|
+
.dxp-text-size-mediumBodyBold {
|
|
111
|
+
color: @DEFAULT_COLOR;
|
|
112
|
+
font-family: Roboto-Bold;
|
|
113
|
+
font-weight: bold;
|
|
114
|
+
font-size: 14px;
|
|
115
|
+
line-height: 22px;
|
|
116
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
declare const BASE_CLASS_PREFIX = "dxp";
|
|
2
|
+
declare const cssClasses: {
|
|
3
|
+
PREFIX: string;
|
|
4
|
+
};
|
|
5
|
+
declare const strings: {
|
|
6
|
+
readonly sizes: readonly ["default", "small", "large"];
|
|
7
|
+
readonly iconPositions: readonly ["left", "right"];
|
|
8
|
+
readonly htmlTypes: readonly ["button", "reset", "submit"];
|
|
9
|
+
readonly btnTypes: readonly ["primary", "secondary", "tertiary", "warning", "danger"];
|
|
10
|
+
readonly themes: readonly ["solid", "borderless", "light", "outline"];
|
|
11
|
+
readonly DEFAULT_ICON_SIZE: "default";
|
|
12
|
+
readonly DEFAULT_ICON_POSITION: "left";
|
|
13
|
+
};
|
|
14
|
+
declare const numbers: {};
|
|
15
|
+
export { BASE_CLASS_PREFIX, cssClasses, numbers, strings };
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
var BASE_CLASS_PREFIX = 'dxp';
|
|
2
|
+
// 这里方一些全局的 css class 变量,方便不同组件公用,。
|
|
3
|
+
var cssClasses = {
|
|
4
|
+
PREFIX: "".concat(BASE_CLASS_PREFIX)
|
|
5
|
+
};
|
|
6
|
+
var strings = {
|
|
7
|
+
sizes: ['default', 'small', 'large'],
|
|
8
|
+
iconPositions: ['left', 'right'],
|
|
9
|
+
htmlTypes: ['button', 'reset', 'submit'],
|
|
10
|
+
btnTypes: ['primary', 'secondary', 'tertiary', 'warning', 'danger'],
|
|
11
|
+
themes: ['solid', 'borderless', 'light', 'outline'],
|
|
12
|
+
DEFAULT_ICON_SIZE: 'default',
|
|
13
|
+
DEFAULT_ICON_POSITION: 'left'
|
|
14
|
+
};
|
|
15
|
+
var numbers = {};
|
|
16
|
+
export { BASE_CLASS_PREFIX, cssClasses, numbers, strings };
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/es/index.d.ts
ADDED
package/es/index.js
ADDED