namirasoft-account-react 1.4.353 → 1.4.355

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.
Files changed (66) hide show
  1. package/.env.template +15 -15
  2. package/config-overrides.js +72 -72
  3. package/dist/components/NSAAccessListDialog.module.css +71 -71
  4. package/dist/components/NSAMessageListDialog.module.css +99 -99
  5. package/dist/components/NSAProductListDialog.module.css +44 -44
  6. package/dist/components/NSAUserDialog.js +2 -2
  7. package/dist/components/NSAUserDialog.js.map +1 -1
  8. package/dist/components/NSAUserDialog.module.css +66 -61
  9. package/dist/components/NSAWorkspaceListDialog.module.css +41 -41
  10. package/dist/layouts/NSASectionEditTabPage.module.css +4 -4
  11. package/dist/layouts/NSASectionList.module.css +21 -21
  12. package/dist/layouts/NSASectionViewTabPage.module.css +47 -47
  13. package/dist/pages/NSAConsentPage.module.css +26 -26
  14. package/dist/pages/NSAHomePage.module.css +23 -23
  15. package/dist/pages/NSALoginPage.module.css +26 -26
  16. package/dist/pages/NSAVerificationPage.module.css +31 -31
  17. package/package.json +78 -78
  18. package/public/index.html +21 -21
  19. package/src/App.css +31 -31
  20. package/src/App.tsx +93 -93
  21. package/src/CTFRow.ts +7 -7
  22. package/src/ConsentCacheService.ts +25 -25
  23. package/src/IEntityInfo.ts +31 -31
  24. package/src/NSARouterMaker.tsx +129 -129
  25. package/src/NSARouterMakerComponent.ts +9 -9
  26. package/src/NSARouterMakerProps.ts +22 -22
  27. package/src/Router.tsx +39 -39
  28. package/src/UseParams.tsx +18 -18
  29. package/src/components/NSAAccessListDialog.module.css +71 -71
  30. package/src/components/NSAAccessListDialog.tsx +178 -178
  31. package/src/components/NSAMessageListDialog.module.css +99 -99
  32. package/src/components/NSAMessageListDialog.tsx +141 -141
  33. package/src/components/NSAProductListDialog.module.css +44 -44
  34. package/src/components/NSAProductListDialog.tsx +106 -106
  35. package/src/components/NSAUserDialog.module.css +66 -61
  36. package/src/components/NSAUserDialog.tsx +110 -99
  37. package/src/components/NSAWorkspaceListDialog.module.css +41 -41
  38. package/src/components/NSAWorkspaceListDialog.tsx +148 -148
  39. package/src/components/NSBoxSecret.tsx +106 -106
  40. package/src/index.tsx +24 -24
  41. package/src/layouts/Actions.ts +145 -145
  42. package/src/layouts/CFTUtil.ts +18 -18
  43. package/src/layouts/NSALayout.tsx +710 -710
  44. package/src/layouts/NSASectionEdit.tsx +218 -218
  45. package/src/layouts/NSASectionEditTabPage.module.css +4 -4
  46. package/src/layouts/NSASectionEditTabPage.tsx +250 -250
  47. package/src/layouts/NSASectionList.module.css +21 -21
  48. package/src/layouts/NSASectionList.tsx +500 -500
  49. package/src/layouts/NSASectionView.tsx +94 -94
  50. package/src/layouts/NSASectionViewTabMore.tsx +77 -77
  51. package/src/layouts/NSASectionViewTabPage.module.css +47 -47
  52. package/src/layouts/NSASectionViewTabPage.tsx +344 -344
  53. package/src/main.ts +19 -19
  54. package/src/pages/NSAConsentPage.module.css +26 -26
  55. package/src/pages/NSAConsentPage.tsx +120 -120
  56. package/src/pages/NSAEmailVerificationPage.tsx +30 -30
  57. package/src/pages/NSAHomePage.module.css +23 -23
  58. package/src/pages/NSAHomePage.tsx +76 -76
  59. package/src/pages/NSALoginPage.module.css +26 -26
  60. package/src/pages/NSALoginPage.tsx +87 -87
  61. package/src/pages/NSAVerificationPage.module.css +31 -31
  62. package/src/pages/NSAVerificationPage.tsx +172 -172
  63. package/src/pages/PaymentRequired.tsx +74 -74
  64. package/tsconfig.json +43 -43
  65. package/dist/App.css +0 -32
  66. package/dist/index.css +0 -0
@@ -1,62 +1,67 @@
1
- .ns_figure {
2
- display: flex;
3
- flex-direction: column;
4
- align-items: center;
5
- gap: 1rem;
6
- margin-bottom: 0;
7
- color: #141b5c;
8
-
9
- figcaption {
10
- display: flex;
11
- flex-direction: column;
12
- align-items: center;
13
- gap: 0.5rem;
14
- }
15
- }
16
-
17
- .ns_figure_placeholder {
18
- width: 6rem;
19
- height: 6rem;
20
- display: flex;
21
- align-items: center;
22
- justify-content: center;
23
- border-radius: 50%;
24
- background-color: #141b5c;
25
- span {
26
- font-size: 1.75rem;
27
- font-weight: 500;
28
- word-spacing: -0.5rem;
29
- color: #fff;
30
- }
31
- }
32
-
33
- .ns_figure_title {
34
- font-size: 1.5rem;
35
- font-weight: 600;
36
- line-height: 1.75rem;
37
- }
38
-
39
- .ns_actions_wrapper {
40
- display: flex;
41
- flex-direction: column;
42
- }
43
-
44
- .ns_actions_wrapper .ns_link > a,
45
- .ns_actions_wrapper .ns_button {
46
- box-shadow: none;
47
- color: #141b5c !important;
48
- }
49
-
50
- .ns_actions_wrapper .ns_link > a:hover,
51
- .ns_actions_wrapper .ns_button:hover {
52
- background-color: #b2bbd9;
53
- }
54
-
55
- .ns_user_id {
56
- margin: 0;
57
- font-size: 16px;
58
- font-weight: 600;
59
- text-align: right;
60
- color: rgba(3, 119, 255);
61
- cursor: pointer;
1
+ .ns_figure {
2
+ display: flex;
3
+ flex-direction: column;
4
+ align-items: center;
5
+ gap: 1rem;
6
+ margin-bottom: 0;
7
+ color: #141b5c;
8
+ }
9
+
10
+ .ns_figure>img {
11
+ border-radius: 50%;
12
+ }
13
+
14
+ .ns_figure figcaption {
15
+ display: flex;
16
+ flex-direction: column;
17
+ align-items: center;
18
+ gap: 0.5rem;
19
+ }
20
+
21
+ .ns_figure_placeholder {
22
+ width: 6rem;
23
+ height: 6rem;
24
+ display: flex;
25
+ align-items: center;
26
+ justify-content: center;
27
+ border-radius: 50%;
28
+ background-color: #141b5c;
29
+ }
30
+
31
+ .ns_figure_placeholder span {
32
+ font-size: 1.75rem;
33
+ font-weight: 500;
34
+ word-spacing: -0.375rem;
35
+ color: #fff;
36
+ }
37
+
38
+ .ns_figure_title {
39
+ font-size: 1.5rem;
40
+ font-weight: 600;
41
+ line-height: 1.75rem;
42
+ }
43
+
44
+ .ns_actions_wrapper {
45
+ display: flex;
46
+ flex-direction: column;
47
+ }
48
+
49
+ .ns_actions_wrapper .ns_link>a,
50
+ .ns_actions_wrapper .ns_button {
51
+ box-shadow: none;
52
+ color: #141b5c !important;
53
+ }
54
+
55
+ .ns_actions_wrapper .ns_link>a:hover,
56
+ .ns_actions_wrapper .ns_button:hover {
57
+ background-color: #b2bbd9;
58
+ }
59
+
60
+ .ns_user_id {
61
+ margin: 0;
62
+ font-size: 16px;
63
+ font-weight: 600;
64
+ text-align: right;
65
+ color: rgba(3, 119, 255);
66
+ cursor: pointer;
62
67
  }
@@ -1,100 +1,111 @@
1
- import { NamirasoftAccountClient } from 'namirasoft-account-client';
2
- import { NSButton, NSCopy, NSDialog, NSDialogProps, NSLine, NSLink, NSLoading, NSSpace, NSSpaceSizeType } from 'namirasoft-site-react';
3
- import { Component } from 'react';
4
- import { NSARouterMakerProps } from '../NSARouterMakerProps';
5
- import Styles from "./NSAUserDialog.module.css";
6
-
7
- export interface NSAUserDialogProps extends NSARouterMakerProps, NSDialogProps
8
- {
9
- client: NamirasoftAccountClient
10
- }
11
-
12
- export class NSAUserDialog extends Component<NSAUserDialogProps>
13
- {
14
- override render()
15
- {
16
- let user = this.props.account?.token_manager?.getUserData((u => u), null);
17
- let content = null;
18
- if (user == null)
19
- content = <NSLoading />;
20
- else
21
- {
22
- content = (
23
- <div>
24
- <figure className={Styles.ns_figure}>
25
- {user.picture
26
- ?
27
- <img
28
- src={user.picture}
29
- width={96}
30
- height={96}
31
- alt="User Avatar"
32
- />
33
- :
34
- <div className={Styles.ns_figure_placeholder}>
35
- <span>
36
- {((user.first_name?.[0] ?? "") + " " + (user.last_name?.[0] ?? "")).trim()}
37
- </span>
38
- </div>
39
- }
40
- <figcaption>
41
- <span className={Styles.ns_figure_title}>{`Hi ${user.first_name}!`}</span>
42
- <span>{user?.email}</span>
43
- <NSCopy id={user.id}>
44
- <p className={Styles.ns_user_id}>
45
- {user.id}
46
- </p>
47
- </NSCopy>
48
- </figcaption>
49
- </figure>
50
-
51
- <NSSpace size={NSSpaceSizeType.MINI} />
52
- <NSLine />
53
- <NSSpace size={NSSpaceSizeType.MICRO} />
54
-
55
- <div className={Styles.ns_actions_wrapper}>
56
- <NSLink
57
- href="https://account.namirasoft.com/user/profile"
58
- target="_blank"
59
- title='Profile'
60
- classList={[Styles.ns_link]}
61
- />
62
- <NSLink
63
- href="https://cost.namirasoft.com/"
64
- target="_blank"
65
- title='Billing and Cost'
66
- classList={[Styles.ns_link]}
67
- />
68
- <NSLink
69
- href="https://account.namirasoft.com/setting/notification"
70
- target="_blank"
71
- title='Notificaton Setting'
72
- classList={[Styles.ns_link]}
73
- />
74
- <NSLink
75
- href="https://account.namirasoft.com/password/change"
76
- target="_blank"
77
- title='Change Password'
78
- classList={[Styles.ns_link]}
79
- />
80
- <NSButton
81
- onClick={{ action: () => this.props.client.logout() }}
82
- title='Log Out'
83
- classList={[Styles.ns_button]}
84
- icon={{
85
- src: "https://static.namirasoft.com/image/concept/logout/base.svg",
86
- alt: "Logout Icon"
87
- }}
88
- />
89
- </div>
90
- </div>
91
- );
92
- }
93
-
94
- return (
95
- <NSDialog {...this.props}>
96
- {content}
97
- </NSDialog>
98
- );
99
- }
1
+ import { NamirasoftAccountClient } from 'namirasoft-account-client';
2
+ import { NSButton, NSCopy, NSDialog, NSDialogProps, NSLine, NSLink, NSLoading, NSSpace, NSSpaceSizeType } from 'namirasoft-site-react';
3
+ import { Component } from 'react';
4
+ import { NSARouterMakerProps } from '../NSARouterMakerProps';
5
+ import Styles from "./NSAUserDialog.module.css";
6
+
7
+ export interface NSAUserDialogProps extends NSARouterMakerProps, NSDialogProps
8
+ {
9
+ client: NamirasoftAccountClient
10
+ }
11
+
12
+ export class NSAUserDialog extends Component<NSAUserDialogProps>
13
+ {
14
+ override render()
15
+ {
16
+ let user = this.props.account?.token_manager?.getUserData((u => u), null);
17
+ let content = null;
18
+ if (user == null)
19
+ content = <NSLoading />;
20
+ else
21
+ {
22
+ content = (
23
+ <div>
24
+ <figure className={Styles.ns_figure}>
25
+ {user.picture
26
+ ?
27
+ <img
28
+ src={user.picture}
29
+ width={96}
30
+ height={96}
31
+ alt="User Avatar"
32
+ />
33
+ :
34
+ <div className={Styles.ns_figure_placeholder}>
35
+ <span>
36
+ {((user.first_name?.[0] ?? "") + " " + (user.last_name?.[0] ?? "")).trim()}
37
+ </span>
38
+ </div>
39
+ }
40
+ <figcaption>
41
+ <span className={Styles.ns_figure_title}>{`Hi ${user.first_name}!`}</span>
42
+ <span>{user?.email}</span>
43
+ <NSCopy id={user.id}>
44
+ <p className={Styles.ns_user_id}>
45
+ {user.id}
46
+ </p>
47
+ </NSCopy>
48
+ </figcaption>
49
+ </figure>
50
+
51
+ <NSSpace size={NSSpaceSizeType.MINI} />
52
+ <NSLine />
53
+ <NSSpace size={NSSpaceSizeType.MICRO} />
54
+
55
+ <div className={Styles.ns_actions_wrapper}>
56
+ <NSLink
57
+ href="https://account.namirasoft.com/user/profile"
58
+ target="_blank"
59
+ classList={[Styles.ns_link]}
60
+ >
61
+ Profile
62
+ </NSLink>
63
+ <NSLink
64
+ href="https://payment.namirasoft.com/"
65
+ target="_blank"
66
+ classList={[Styles.ns_link]}
67
+ >
68
+ Payment and Billing
69
+ </NSLink>
70
+ <NSLink
71
+ href="https://cost.namirasoft.com/"
72
+ target="_blank"
73
+ classList={[Styles.ns_link]}
74
+ >
75
+ Cost and Usage
76
+ </NSLink>
77
+ <NSLink
78
+ href="https://account.namirasoft.com/setting/notification"
79
+ target="_blank"
80
+ classList={[Styles.ns_link]}
81
+ >
82
+ Notificaton Settings
83
+ </NSLink>
84
+ <NSLink
85
+ href="https://account.namirasoft.com/password/change"
86
+ target="_blank"
87
+ classList={[Styles.ns_link]}
88
+ >
89
+ Change Password
90
+ </NSLink>
91
+ <NSButton
92
+ onClick={{ action: () => this.props.client.logout() }}
93
+ title='Log Out'
94
+ classList={[Styles.ns_button]}
95
+ icon={{
96
+ src: "https://static.namirasoft.com/image/concept/logout/blue.svg",
97
+ alt: "Logout Icon"
98
+ }}
99
+ />
100
+ </div>
101
+ </div>
102
+ );
103
+ }
104
+
105
+ return (
106
+ <NSDialog {...this.props}>
107
+ {content}
108
+ </NSDialog>
109
+ );
110
+ }
100
111
  }
@@ -1,42 +1,42 @@
1
- .nsa_workspace_h2 {
2
- color: rgba(3, 119, 255, 1);
3
- text-align: center;
4
- font-weight: 600;
5
- font-size: 16px;
6
- cursor: pointer;
7
- }
8
-
9
- .nsa_workspace_h6 {
10
- color: rgba(20, 27, 92, 1);
11
- text-align: center;
12
- font-weight: 300;
13
- font-size: 16px;
14
- cursor: pointer;
15
- margin: 0;
16
- }
17
-
18
- .nsa_workspace_list {
19
- overflow-y: auto;
20
- height: 320px;
21
- width: 302px;
22
- }
23
-
24
- .nsa_workspace_border {
25
- margin-top: 16px;
26
- display: flex;
27
- flex-direction: row;
28
- justify-content: left;
29
- align-items: center;
30
- gap: 8px;
31
- border-radius: 8px;
32
- border: 1px solid gray;
33
- padding: 8px;
34
- transition: all .2s ease-in-out;
35
- flex-wrap: wrap;
36
- }
37
-
38
- .nsa_workspace_border:hover {
39
- background-color: rgba(20, 27, 92, 0.3);
40
- color: white;
41
- cursor: pointer;
1
+ .nsa_workspace_h2 {
2
+ color: rgba(3, 119, 255, 1);
3
+ text-align: center;
4
+ font-weight: 600;
5
+ font-size: 16px;
6
+ cursor: pointer;
7
+ }
8
+
9
+ .nsa_workspace_h6 {
10
+ color: rgba(20, 27, 92, 1);
11
+ text-align: center;
12
+ font-weight: 300;
13
+ font-size: 16px;
14
+ cursor: pointer;
15
+ margin: 0;
16
+ }
17
+
18
+ .nsa_workspace_list {
19
+ overflow-y: auto;
20
+ height: 320px;
21
+ width: 302px;
22
+ }
23
+
24
+ .nsa_workspace_border {
25
+ margin-top: 16px;
26
+ display: flex;
27
+ flex-direction: row;
28
+ justify-content: left;
29
+ align-items: center;
30
+ gap: 8px;
31
+ border-radius: 8px;
32
+ border: 1px solid gray;
33
+ padding: 8px;
34
+ transition: all .2s ease-in-out;
35
+ flex-wrap: wrap;
36
+ }
37
+
38
+ .nsa_workspace_border:hover {
39
+ background-color: rgba(20, 27, 92, 0.3);
40
+ color: white;
41
+ cursor: pointer;
42
42
  }