@yeeyoon/library 2.1.9 → 2.2.3

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.
@@ -1 +1 @@
1
- <?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1631872777872" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="3042" xmlns:xlink="http://www.w3.org/1999/xlink" width="32" height="32"><defs><style type="text/css"></style></defs><path d="M621.4144 214.528a351.9488 351.9488 0 0 0-288.7168-98.304h-0.256C170.752 135.7824 40.96 268.8 22.272 433.5616l49.5616 5.7856L0 628.5312l49.408-7.8848c43.0592 101.0176 130.3552 177.92 236.2368 206.1824 23.6032 8.0384 48.8448 12.288 74.6496 12.288h421.632c135.1168 0 244.5312-112.7424 242.0224-251.1872v-0.1024a240.2304 240.2304 0 0 0-45.5168-136.704 236.6976 236.6976 0 0 0-39.4752-43.52 248.6784 248.6784 0 0 0-163.4816-61.3376v49.4592l-96.8192-176.128-21.1968 36.2496a384.1024 384.1024 0 0 0-35.6864-41.0112l-0.2048-0.1536-0.1536-0.2048zM152.576 604.0064l43.9808-7.0144-124.7744-157.696 49.6128 5.8368C134.7584 327.168 228.352 231.3216 344.064 217.2416a253.2864 253.2864 0 0 1 208.0256 70.4512c19.456 19.456 35.9424 41.3696 48.5376 65.28l-23.7568 40.6016 198.6048 3.072V448c37.2736 0 72.192 13.824 98.7136 37.0688l0.256 0.256 0.3072 0.2048c8.4992 7.2704 16.1792 15.7184 22.8864 25.2416l0.2048 0.256 0.1536 0.256c6.6048 9.1136 11.776 18.1248 15.36 27.136l0.2048 0.4096 0.1536 0.4096c6.4 15.1552 10.0864 32.1024 10.4448 50.6368 1.4848 81.2544-62.72 147.5072-142.2336 147.5072H360.2944c-15.4624 0-30.464-2.6112-44.2368-7.424l-1.8432-0.6656-1.8944-0.512a258.3552 258.3552 0 0 1-159.6928-124.7232z" fill="#3ED09C" p-id="3043"></path></svg>
1
+ <?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1632654024999" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="3310" xmlns:xlink="http://www.w3.org/1999/xlink" width="32" height="32"><defs><style type="text/css"></style></defs><path d="M621.4144 214.528a351.9488 351.9488 0 0 0-288.7168-98.304h-0.256C170.752 135.7824 40.96 268.8 22.272 433.5616l49.5616 5.7856L0 628.5312l49.408-7.8848c43.0592 101.0176 130.3552 177.92 236.2368 206.1824 23.6032 8.0384 48.8448 12.288 74.6496 12.288h421.632c135.1168 0 244.5312-112.7424 242.0224-251.1872v-0.1024a240.2304 240.2304 0 0 0-45.5168-136.704 236.6976 236.6976 0 0 0-39.4752-43.52 248.6784 248.6784 0 0 0-163.4816-61.3376v49.4592l-96.8192-176.128-21.1968 36.2496a384.1024 384.1024 0 0 0-35.6864-41.0112l-0.2048-0.1536-0.1536-0.2048zM152.576 604.0064l43.9808-7.0144-124.7744-157.696 49.6128 5.8368C134.7584 327.168 228.352 231.3216 344.064 217.2416a253.2864 253.2864 0 0 1 208.0256 70.4512c19.456 19.456 35.9424 41.3696 48.5376 65.28l-23.7568 40.6016 198.6048 3.072V448c37.2736 0 72.192 13.824 98.7136 37.0688l0.256 0.256 0.3072 0.2048c8.4992 7.2704 16.1792 15.7184 22.8864 25.2416l0.2048 0.256 0.1536 0.256c6.6048 9.1136 11.776 18.1248 15.36 27.136l0.2048 0.4096 0.1536 0.4096c6.4 15.1552 10.0864 32.1024 10.4448 50.6368 1.4848 81.2544-62.72 147.5072-142.2336 147.5072H360.2944c-15.4624 0-30.464-2.6112-44.2368-7.424l-1.8432-0.6656-1.8944-0.512a258.3552 258.3552 0 0 1-159.6928-124.7232z" fill="#02B6CE" p-id="3311"></path></svg>
@@ -8,31 +8,43 @@ import ls from 'local-storage';
8
8
  const PlatformModal = (props) => {
9
9
  const { platforms, redirectUrl, tenantId } = props;
10
10
  const enterProductDetail = (plat) => {
11
+ let _link = document.createElement('a');
12
+ let link = document.body.appendChild(_link);
13
+ link.setAttribute('target', '_blank');
11
14
  if (plat.code == '20210811003') {
12
- window.open(
15
+ link.setAttribute(
16
+ 'href',
13
17
  `${plat.forwardDomainName}?token=${ls.get(
14
18
  'X-Auth-Token'
15
19
  )}&userId=${ls.get('X-Auth-Id')}&tenantId=${tenantId}`
16
20
  );
21
+ link.click();
17
22
  } else {
18
23
  getSystemToken(plat);
19
24
  }
20
25
  };
21
26
  const getSystemToken = async (plat) => {
27
+ let _link = document.createElement('a');
28
+ let link = document.body.appendChild(_link);
29
+ link.setAttribute('target', '_blank');
22
30
  const resp = await fetchSystemToken({ platformId: plat.id });
23
31
  const { success, data } = resp;
24
32
  if (success) {
25
33
  const { token, ...rest } = data;
26
34
  if (redirectUrl) {
27
- window.open(
35
+ link.setAttribute(
36
+ 'href',
28
37
  `${redirectUrl}?token=${token}&userId=${rest.userId}&tenantId=${tenantId}`
29
38
  );
39
+ link.click();
30
40
  } else if (plat.forwardDomainName) {
31
- window.open(
41
+ link.setAttribute(
42
+ 'href',
32
43
  `${plat.forwardDomainName}?token=${token}&userInfo=${JSON.stringify(
33
44
  rest
34
45
  )}&tenantId=${tenantId}`
35
46
  );
47
+ link.click();
36
48
  } else {
37
49
  message.error('该系统尚未开发,敬请期待');
38
50
  return;
@@ -16,12 +16,17 @@ const ProductListMenu = (props) => {
16
16
  const [platModal, setPlatModal] = useState(false);
17
17
  const [platforms, setPlatforms] = useState([]);
18
18
  const enterDetail = (item) => {
19
+ let _link = document.createElement('a');
20
+ let link = document.body.appendChild(_link);
21
+ link.setAttribute('target', '_blank');
19
22
  if (item.code == 200000729) {
20
- window.open(
23
+ link.setAttribute(
24
+ 'href',
21
25
  `${getCollabRedirectUrl()}?token=${ls.get(
22
26
  'X-Auth-Token'
23
27
  )}&tenantId=${tenantId}`
24
28
  );
29
+ link.click();
25
30
  } else if (item.platforms?.length > 1) {
26
31
  setPlatModal(true);
27
32
  setPlatforms(item.platforms);
@@ -32,11 +37,18 @@ const ProductListMenu = (props) => {
32
37
  const getSystemToken = async (item) => {
33
38
  const resp = await fetchSystemToken({ platformId: item.id });
34
39
  const { success, data } = resp;
40
+ let _link = document.createElement('a');
41
+ let link = document.body.appendChild(_link);
42
+ link.setAttribute('target', '_blank');
35
43
  if (success) {
36
44
  const { token, ...rest } = data;
37
- window.open(
38
- `${item.forwardDomainName}?token=${token}&userInfo=${rest}&tenantId=${tenantId}`
45
+ link.setAttribute(
46
+ 'href',
47
+ `${item.forwardDomainName}?token=${token}&userInfo=${JSON.stringify(
48
+ rest
49
+ )}&tenantId=${tenantId}`
39
50
  );
51
+ link.click();
40
52
  }
41
53
  };
42
54
  return (
@@ -224,7 +224,7 @@ const Header = (props) => {
224
224
  </span>
225
225
  </div>
226
226
  <div className={styles['comp-header__right-content']}>
227
- {/* <Tooltip title="控制台" className={styles['comp-header__icon']}> */}
227
+ {/* <Tooltip title="工作台" className={styles['comp-header__icon']}> */}
228
228
  <span className={styles['comp-header__icon']}>
229
229
  <FundProjectionScreenOutlined
230
230
  style={{ fontSize: '20px', color: 'rgba(0, 0, 0, .85)' }}
@@ -232,18 +232,9 @@ const Header = (props) => {
232
232
  window.location.href = `${HOST_PROFILE_DASH_BOARD}?token=${token}`;
233
233
  }}
234
234
  />
235
- &nbsp;控制台
235
+ &nbsp;工作台
236
236
  </span>
237
237
  {/* </Tooltip> */}
238
- {systemUserInfo && (
239
- <Notification
240
- customStyles={{
241
- icon: { height: '62px', display: 'flex' },
242
- list: { top: '44px' },
243
- }}
244
- userInfo={systemUserInfo}
245
- />
246
- )}
247
238
  {/* <Tooltip title="任务中心" className={styles['comp-header__icon']}> */}
248
239
  <span className={styles['comp-header__icon']}>
249
240
  <BarsOutlined
@@ -256,6 +247,15 @@ const Header = (props) => {
256
247
  &nbsp;任务中心
257
248
  </span>
258
249
  {/* </Tooltip> */}
250
+ {systemUserInfo && (
251
+ <Notification
252
+ customStyles={{
253
+ icon: { height: '62px', display: 'flex' },
254
+ list: { top: '44px' },
255
+ }}
256
+ userInfo={systemUserInfo}
257
+ />
258
+ )}
259
259
  <Divider type="vertical" />
260
260
  {userInfo && (
261
261
  <>
@@ -10,14 +10,16 @@ import Captcha from './Captcha';
10
10
  import styles from './universal.less';
11
11
 
12
12
  const Forget = (props) => {
13
- const { reqCb } = props;
13
+ const { reqCb, hideTitle = false } = props;
14
14
  const [step, setStep] = useState('captcha');
15
15
  const [mobile, setMobile] = useState('');
16
16
 
17
17
  return (
18
18
  <>
19
19
  <div className={styles['universal-login']}>
20
- <h1 className={styles['universal-login__title']}>重置密码</h1>
20
+ {!hideTitle && (
21
+ <h1 className={styles['universal-login__title']}>重置密码</h1>
22
+ )}
21
23
  <Card bordered={false} className={styles['universal-login__card']}>
22
24
  <ProForm
23
25
  submitter={false}
@@ -103,6 +105,7 @@ const Forget = (props) => {
103
105
 
104
106
  Forget.propTypes = {
105
107
  reqCb: PropTypes.func.required,
108
+ hideTitle: PropTypes.bool,
106
109
  };
107
110
 
108
111
  export default Forget;
@@ -3,7 +3,7 @@ import PropTypes from 'prop-types';
3
3
  import moment from 'moment';
4
4
  import qs from 'qs';
5
5
 
6
- import { Badge, Button, Tooltip, notification } from 'antd';
6
+ import { Badge, Button, notification } from 'antd';
7
7
  import { BellOutlined } from '@ant-design/icons';
8
8
  import ProList from '@ant-design/pro-list';
9
9
 
@@ -3,6 +3,21 @@
3
3
 
4
4
  body {
5
5
  // :global {
6
+ // Scrollbar
7
+ ::-webkit-scrollbar {
8
+ width: @border-radius-base;
9
+ height: @border-radius-base;
10
+ }
11
+ ::-webkit-scrollbar-thumb {
12
+ background: @primary-color;
13
+ border-radius: @border-radius-base;
14
+ }
15
+ ::-webkit-scrollbar-track {
16
+ border-radius: @border-radius-base;
17
+ }
18
+ ::-webkit-scrollbar-corner {
19
+ background: transparent;
20
+ }
6
21
  // Button
7
22
  .ant-btn {
8
23
  padding: 0 22px;
@@ -23,7 +38,7 @@ body {
23
38
  background-color: fade(@primary-color, 65%);
24
39
  }
25
40
  &.gradient {
26
- background: linear-gradient(45deg, @primary-color 0%, @primary-color-gradient 100%);
41
+ background: linear-gradient(45deg, #7367f0 0%, #9e95f5 100%);
27
42
  border: none;
28
43
  }
29
44
  }
@@ -254,6 +269,9 @@ body {
254
269
  line-height: 18px;
255
270
  border: none;
256
271
  border-radius: 4px;
272
+ &.pill {
273
+ border-radius: 17px;
274
+ }
257
275
  &.secondary {
258
276
  color: @default-color;
259
277
  }
@@ -111,7 +111,8 @@ const theme = {
111
111
  // Tab
112
112
  'tabs-horizontal-margin': '0',
113
113
  'tabs-horizontal-padding': '9px 16px',
114
- 'tabs-ink-bar-color': 'linear-gradient(90deg, #7367F0 0%, #B0A9FF 100%)',
114
+ 'tabs-ink-bar-color':
115
+ 'linear-gradient(90deg, @primary-color 0%, @primary-color-gradient 100%)',
115
116
  'tabs-hover-color': '@font-color',
116
117
  'tabs-active-color': '@primary-color',
117
118
  'tabs-card-gutter': '0',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yeeyoon/library",
3
- "version": "2.1.9",
3
+ "version": "2.2.3",
4
4
  "description": "宜云前端组件库和通用服务",
5
5
  "main": "index.js",
6
6
  "repository": {
@@ -7,7 +7,7 @@ export default function () {
7
7
  return (
8
8
  <>
9
9
  <Header
10
- productName="bpm"
10
+ productName="profile"
11
11
  tenantId="053a033a063711ecb0c00c42a1ff8370"
12
12
  token="ZmI1YzU4NzEyOTdlNDM2MTg2YjI0N2IyZGQzOGI3NDg1NDE2MzI2MjU4NjMzNzY="
13
13
  avatar="https://demo-yeeyoon-fm.oss-cn-zhangjiakou.aliyuncs.com/userCenter/userAvatar/user_avatar2.png"