@jsb188/app 1.1.10 → 1.1.12

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 (79) hide show
  1. package/package.json +57 -45
  2. package/src/constants/agent.ts +51 -41
  3. package/src/constants/app.ts +34 -13
  4. package/src/constants/emoji.ts +9144 -8936
  5. package/src/constants/other.ts +1 -5
  6. package/src/constants/user.ts +16 -25
  7. package/src/constants/wsActions.ts +27 -0
  8. package/src/i18n/account.ts +129 -107
  9. package/src/i18n/agent.ts +331 -73
  10. package/src/i18n/agentToolBusiness.ts +196 -0
  11. package/src/i18n/agentToolGrid.ts +137 -0
  12. package/src/i18n/agentToolWorkflow.ts +101 -0
  13. package/src/i18n/agent_note.ts +109 -0
  14. package/src/i18n/app.ts +107 -91
  15. package/src/i18n/auth.ts +117 -102
  16. package/src/i18n/billing.ts +5 -92
  17. package/src/i18n/c.ts +907 -0
  18. package/src/i18n/campaign.ts +919 -0
  19. package/src/i18n/country.ts +248 -248
  20. package/src/i18n/datetime.ts +32 -26
  21. package/src/i18n/editor.ts +58 -0
  22. package/src/i18n/error.ts +577 -192
  23. package/src/i18n/field_doc_editor.ts +21 -0
  24. package/src/i18n/field_doc_programs.ts +52 -0
  25. package/src/i18n/field_docs.ts +190 -0
  26. package/src/i18n/index.ts +42 -19
  27. package/src/i18n/log.ts +272 -238
  28. package/src/i18n/memory.ts +53 -0
  29. package/src/i18n/message.ts +3 -4
  30. package/src/i18n/note.ts +19 -0
  31. package/src/i18n/org.ts +164 -109
  32. package/src/i18n/schedule.ts +209 -0
  33. package/src/i18n/sheet.ts +333 -4
  34. package/src/i18n/sheet_formula.ts +165 -0
  35. package/src/i18n/workflow.ts +109 -23
  36. package/src/main.ts +68 -64
  37. package/src/platform.ts +90 -49
  38. package/src/types/ai.d.ts +52 -23
  39. package/src/types/app.d.ts +95 -44
  40. package/src/types/auth.d.ts +66 -40
  41. package/src/types/console.d.ts +3 -0
  42. package/src/types/other.d.ts +13 -6
  43. package/src/types.d.ts +12 -14
  44. package/src/utils/account.ts +64 -58
  45. package/src/utils/api.ts +326 -77
  46. package/src/utils/authSession.ts +24 -0
  47. package/src/utils/clientIP.ts +213 -0
  48. package/src/utils/color.ts +279 -0
  49. package/src/utils/cron.ts +49 -18
  50. package/src/utils/csv.ts +19 -0
  51. package/src/utils/datetime.ts +445 -117
  52. package/src/utils/deferredSave.ts +89 -0
  53. package/src/utils/email.ts +50 -0
  54. package/src/utils/emoji.ts +107 -84
  55. package/src/utils/expression.helpers.ts +470 -0
  56. package/src/utils/expression.test.ts +793 -0
  57. package/src/utils/expression.ts +2261 -0
  58. package/src/utils/interval.ts +80 -0
  59. package/src/utils/language.ts +9 -0
  60. package/src/utils/logic.ts +141 -121
  61. package/src/utils/managedSession.ts +34 -0
  62. package/src/utils/managedSessionBff.test.ts +60 -0
  63. package/src/utils/managedSessionBff.ts +117 -0
  64. package/src/utils/number.ts +85 -38
  65. package/src/utils/object.ts +227 -30
  66. package/src/utils/promise.ts +98 -0
  67. package/src/utils/queryReset.ts +266 -0
  68. package/src/utils/recurringTask.ts +60 -0
  69. package/src/utils/schema.ts +293 -0
  70. package/src/utils/string.test.ts +205 -208
  71. package/src/utils/string.ts +426 -463
  72. package/src/utils/timeZone.ts +309 -851
  73. package/src/utils/url_client.ts +145 -72
  74. package/tsconfig.json +10 -10
  75. package/src/constants/billing.ts +0 -146
  76. package/src/i18n/form.ts +0 -376
  77. package/src/i18n/product.ts +0 -76
  78. package/src/types/form.d.ts +0 -97
  79. package/src/utils/billing.ts +0 -134
@@ -1,4 +1,3 @@
1
-
2
1
  export const DAY_OF_WEEK = [
3
2
  'Sunday', // Order matters
4
3
  'Monday',
@@ -9,9 +8,6 @@ export const DAY_OF_WEEK = [
9
8
  'Saturday',
10
9
  ];
11
10
 
12
- export const SCHEDULE_FREQUENCY = [
13
- 'ONCE',
14
- 'WEEKLY',
15
- ];
11
+ export const SCHEDULE_FREQUENCY = ['ONCE', 'WEEKLY'];
16
12
 
17
13
  export const DATE_PICKER_MIN = '1950-01-01';
@@ -1,36 +1,27 @@
1
1
  export const USER_FRIEND_STATUS_ENUMS = [
2
- 'BLOCKED',
3
- 'DECLINED',
4
- 'PENDING',
5
- 'ACCEPTED',
2
+ 'BLOCKED',
3
+ 'DECLINED',
4
+ 'PENDING',
5
+ 'ACCEPTED',
6
6
  ];
7
7
 
8
- export const USER_PLUS_TYPE_ENUMS = [
9
- 'NORMAL',
10
- 'PERKS',
11
- 'PLUS',
12
- 'PRO',
13
- ];
8
+ export const USER_PLUS_TYPE_ENUMS = ['NORMAL', 'PERKS', 'PLUS', 'PRO'];
14
9
 
15
10
  export const SUB_TYPE_TO_ENUMS = {
16
- kajiwoto_plus: 'PLUS',
17
- kajiwoto_plus_yearly: 'PLUS',
18
- kajiwoto_pro: 'PRO',
19
- kajiwoto_pro_yearly: 'PRO',
11
+ kajiwoto_plus: 'PLUS',
12
+ kajiwoto_plus_yearly: 'PLUS',
13
+ kajiwoto_pro: 'PRO',
14
+ kajiwoto_pro_yearly: 'PRO',
20
15
  };
21
16
 
22
17
  export const SUB_TYPE_ENUMS = Object.keys(SUB_TYPE_TO_ENUMS);
23
18
 
24
- export const ONLINE_STATUS_ENUMS = [
25
- 'AWAY',
26
- 'BUSY',
27
- 'APPEAR_OFFLINE',
28
- ];
19
+ export const ONLINE_STATUS_ENUMS = ['AWAY', 'BUSY', 'APPEAR_OFFLINE'];
29
20
 
30
21
  export const STICKY_CHAT_SECTION_ENUMS = [
31
- 'LIVE',
32
- 'MY_LIVE',
33
- 'MY_AI',
34
- 'FAVORITES',
35
- 'NONE',
36
- ];
22
+ 'LIVE',
23
+ 'MY_LIVE',
24
+ 'MY_AI',
25
+ 'FAVORITES',
26
+ 'NONE',
27
+ ];
@@ -7,7 +7,10 @@ const WS_ACTIONS = {
7
7
 
8
8
  // Authentication
9
9
  auth: 'auth',
10
+ auth_ready: 'aok',
10
11
  auth_reset: 'auth_reset',
12
+ session_revoked: 'sr',
13
+ organization_access_revoked: 'oar',
11
14
 
12
15
  // App
13
16
  alert: 'alert',
@@ -16,7 +19,31 @@ const WS_ACTIONS = {
16
19
 
17
20
  // Account
18
21
  me: 'me:',
22
+ session: 'session:',
19
23
  organization: 'org:',
24
+
25
+ // Sheet collaboration
26
+ sheet: 'sheet:',
27
+ sheet_join: 'sh_j',
28
+ sheet_leave: 'sh_l',
29
+ sheet_presence: 'sh_p',
30
+ sheet_selection: 'sh_s',
31
+ sheet_draft: 'sh_d',
32
+
33
+ // Authorization-only Sheet access watcher (no workbook/collab payloads)
34
+ sheet_access: 'sheet_access:',
35
+ sheet_access_watch: 'sh_aw',
36
+ sheet_access_watch_ack: 'sh_awa',
37
+ sheet_access_unwatch: 'sh_au',
38
+
39
+ // Server-managed, signed-capability Sheet data delivery room
40
+ sheet_data: 'sheet_data:',
41
+
42
+ // Account-owned Orchestrator artifact events. A socket joins its own
43
+ // authenticated account room only while that tab's orchestrator is open.
44
+ orchestrator: 'gcp:',
45
+ orchestrator_watch: 'gcp_w',
46
+ orchestrator_unwatch: 'gcp_uw',
20
47
  };
21
48
 
22
49
  export default WS_ACTIONS;
@@ -1,117 +1,139 @@
1
1
  export default {
2
- en: {
3
- name_ph: 'e.g. Jane Doe',
4
- name_ph2: 'Jane Doe',
5
- about: 'About me',
6
- about_ph: 'This text will be displayed on your profile for others to see.',
7
- username: 'Username',
8
- username_ph: 'e.g. "@jane_doe"',
9
- username_info: 'Username, ID, and email is used to log in to your account.',
10
- email: 'Email',
11
- email_ph: 'e.g. jane_doe@email.com',
12
- email_ph2: 'jane_doe@email.com',
13
- phone_ph: 'e.g. 123-444-5555',
14
- phone_ph2: '123-444-5555',
15
- password: 'Password',
16
- password_ph: 'Enter your password',
17
- passwordRepeat: 'Password (repeat)',
18
- search_ph: 'Search @ or ID',
19
- no_one_found_: 'No one found: "%{query}"',
20
- profile_no_desc: 'This user hasn\'t written anything about themselves.',
21
- no_one_found: 'No one found with this query.',
2
+ en: {
3
+ name_ph: 'e.g. Jane Doe',
4
+ name_ph2: 'Jane Doe',
5
+ about: 'About me',
6
+ about_ph: 'This text will be displayed on your profile for others to see.',
7
+ username: 'Username',
8
+ username_ph: 'e.g. "@jane_doe"',
9
+ username_info: 'Username, ID, and email is used to log in to your account.',
10
+ email: 'Email',
11
+ email_ph: 'e.g. jane_doe@email.com',
12
+ email_ph2: 'jane_doe@email.com',
13
+ phone_ph: 'e.g. 123-444-5555',
14
+ phone_ph2: '123-444-5555',
15
+ password: 'Password',
16
+ password_ph: 'Enter your password',
17
+ passwordRepeat: 'Password (repeat)',
18
+ search_ph: 'Search @ or ID',
19
+ no_one_found_: 'No one found: "%{query}"',
20
+ profile_no_desc: "This user hasn't written anything about themselves.",
21
+ no_one_found: 'No one found with this query.',
22
22
 
23
- // App settings
24
- manage_team: 'Manage team',
25
- change_role: 'Change role',
26
- change_role_desc: (
27
- 'Choose [hl]%{name}[/hl]\'s new role in _%{orgName}_. ' +
28
- 'This will change their permissions and access to certain features.'
29
- ),
30
- edit_note_desc: 'Edit note for [hl]%{name}[/hl].',
31
- edit_note_fin_msg: 'Note for [hl]%{name}[/hl] in _%{orgName}_ has been updated.',
32
- edit_note_help: (
33
- 'It\'s useful to write information here such as their job function, ' +
34
- 'dietary preferences, disabilities or anything else to help guide the AI. ' +
35
- '_AI may update this note when it receives new information._'
36
- ),
37
- change_role_fin_msg: (
38
- '[hl]%{name}[/hl]\'s role in _%{orgName}_ has been changed to **%{role}**.'
39
- ),
40
- remove_member_confirm_msg: 'Are you sure you want to remove\n [hl]%{name}[/hl] from _%{orgName}_?',
41
- remove_member_fin_msg: '[hl]%{name}[/hl] has been removed from _%{orgName}_.',
42
- remove_member: 'Remove member',
43
- account: 'Account',
44
- fName: 'First name',
45
- lName: 'Last name',
46
- language: 'Language',
47
- ai_language: 'Preferred language for AI',
48
- timeZone: 'Time zone',
49
- your_account: 'Your account',
50
- your_preferences: 'Your preferences',
51
- profile: 'Profile',
52
- profile_desc: 'Change how your profile looks to others.',
53
- personas: 'Personas',
54
- show_password: 'Show password',
55
- hide_password: 'Hide password',
56
- change_password: 'Change password',
57
- change_password_desc: 'Change your account\'s login password.',
58
- // personas_desc: 'Manage your roleplay personas. Persona for the chat (your name and photo) can be changed by clicking your photo next to the chat textarea.',
59
- personas_desc: 'Use personas to easily change your display name and profile photo. You can change your persona by clicking your photo next to the chat textarea.',
60
- persona_label: 'Roleplay persona',
61
- badge: 'Badge',
62
- badge_desc: 'Change the badge that appear next to your name in chat.',
63
- badge_instr: 'This badge will be displayed next to your name:',
23
+ // App settings
24
+ manage_team: 'Manage team',
25
+ change_role: 'Change role',
26
+ change_role_desc:
27
+ "Choose [hl]%{name}[/hl]'s new role in _%{orgName}_. " +
28
+ 'This will change their permissions and access to certain features.',
29
+ edit_note_desc: 'Edit note for [hl]%{name}[/hl].',
30
+ edit_note_fin_msg:
31
+ 'Note for [hl]%{name}[/hl] in _%{orgName}_ has been updated.',
32
+ edit_note_help:
33
+ "It's useful to write information here such as their job function, " +
34
+ 'dietary preferences, disabilities or anything else to help guide the AI. ' +
35
+ '_AI may update this note when it receives new information._',
36
+ change_role_fin_msg:
37
+ "[hl]%{name}[/hl]'s role in _%{orgName}_ has been changed to **%{role}**.",
38
+ remove_member_confirm_msg:
39
+ 'Are you sure you want to remove\n [hl]%{name}[/hl] from _%{orgName}_?',
40
+ remove_member_fin_msg:
41
+ '[hl]%{name}[/hl] has been removed from _%{orgName}_.',
42
+ remove_member: 'Remove member',
43
+ account: 'Account',
44
+ fName: 'First name',
45
+ lName: 'Last name',
46
+ language: 'Language',
47
+ ai_language: 'Preferred language for AI',
48
+ timeZone: 'Time zone',
49
+ your_account: 'Your account',
50
+ sessions: 'Sessions',
51
+ sessions_desc: 'Review the devices currently signed in to your account.',
52
+ session_current: 'Current session',
53
+ session_last_active: 'Last active %{date}',
54
+ session_expires: 'Expires %{date}',
55
+ session_sign_out: 'Sign out',
56
+ session_sign_out_others: 'Sign out other sessions',
57
+ session_sign_out_member: 'Sign out member sessions',
58
+ session_sign_out_member_desc:
59
+ "Remove %{name}'s active access to %{orgName}.",
60
+ session_unknown_device: 'Unknown device',
61
+ session_none: 'No active sessions were found.',
62
+ your_preferences: 'Your preferences',
63
+ profile: 'Profile',
64
+ profile_desc: 'Change how your profile looks to others.',
65
+ personas: 'Personas',
66
+ show_password: 'Show password',
67
+ hide_password: 'Hide password',
68
+ change_password: 'Change password',
69
+ change_password_desc: "Change your account's login password.",
70
+ // personas_desc: 'Manage your roleplay personas. Persona for the chat (your name and photo) can be changed by clicking your photo next to the chat textarea.',
71
+ personas_desc:
72
+ 'Use personas to easily change your display name and profile photo. You can change your persona by clicking your photo next to the chat textarea.',
73
+ persona_label: 'Roleplay persona',
74
+ badge: 'Badge',
75
+ badge_desc: 'Change the badge that appear next to your name in chat.',
76
+ badge_instr: 'This badge will be displayed next to your name:',
64
77
 
65
- // Change sensitive account settings/info
66
- enter_password: 'Enter password',
78
+ // Change sensitive account settings/info
79
+ enter_password: 'Enter password',
67
80
  enter_password_msg: 'Confirm your identity before continuing.',
68
- new_email: 'New email address',
69
- email_updated: 'Email updated',
70
- email_updated_msg: 'Your email address has been updated to:\n %{emailAddress}.',
71
- change_email: 'Change email',
72
- change_email_msg: 'You will receive a confirmation email\n to your new address.',
73
- change_email_pw_confirm_msg: 'Please confirm your identity to\n change your email address.',
74
- change_email_verify_msg: 'Follow the instructions in the email we sent\n to change your email address.',
75
- change_password_msg: 'Enter your new password below.',
76
- change_password_pw_confirm_msg: 'Please confirm your identity to\n change your password.',
77
- change_phone: 'Change phone',
78
- change_phone_msg: 'Please confirm your identity to\n change your phone number.',
79
- change_phone_request_msg: 'Enter your new phone number below.\n We will send you a verification code.',
80
- change_phone_verify_msg: 'Enter the verification code\n sent to your new phone number.',
81
- currentPassword: 'Current password',
82
- newPassword: 'New password',
83
- newPasswordRepeat: 'New password (repeat)',
84
- phone_updated: 'Number updated',
85
- phone_updated_msg: 'Your phone number has been updated to:\n [hl]%{phoneNumber}[/hl].',
81
+ new_email: 'New email address',
82
+ email_updated: 'Email updated',
83
+ email_updated_msg:
84
+ 'Your email address has been updated to:\n %{emailAddress}.',
85
+ change_email: 'Change email',
86
+ change_email_msg:
87
+ 'You will receive a confirmation email\n to your new address.',
88
+ change_email_pw_confirm_msg:
89
+ 'Please confirm your identity to\n change your email address.',
90
+ change_email_verify_msg:
91
+ 'Follow the instructions in the email we sent\n to change your email address.',
92
+ change_password_msg: 'Enter your new password below.',
93
+ change_password_pw_confirm_msg:
94
+ 'Please confirm your identity to\n change your password.',
95
+ change_phone: 'Change phone',
96
+ change_phone_msg:
97
+ 'Please confirm your identity to\n change your phone number.',
98
+ change_phone_request_msg:
99
+ 'Enter your new phone number below.\n We will send you a verification code.',
100
+ change_phone_verify_msg:
101
+ 'Enter the verification code\n sent to your new phone number.',
102
+ currentPassword: 'Current password',
103
+ newPassword: 'New password',
104
+ newPasswordRepeat: 'New password (repeat)',
105
+ phone_updated: 'Number updated',
106
+ phone_updated_msg:
107
+ 'Your phone number has been updated to:\n [hl]%{phoneNumber}[/hl].',
86
108
 
87
- // Log out
88
- logout: 'Log out',
89
- logout_message: 'Do you want to log out from this account?',
90
- logout_yes: 'Yes, log me out',
109
+ // Log out
110
+ logout: 'Log out',
111
+ logout_message: 'Do you want to log out from this account?',
112
+ logout_yes: 'Yes, log me out',
91
113
 
92
- // Online status
93
- status_ONLINE: 'Online',
94
- status_AWAY: 'Away',
95
- status_BUSY: 'Busy',
96
- status_APPEAR_OFFLINE: 'Appear offline',
114
+ // Online status
115
+ status_ONLINE: 'Online',
116
+ status_AWAY: 'Away',
117
+ status_BUSY: 'Busy',
118
+ status_APPEAR_OFFLINE: 'Appear offline',
97
119
 
98
- // Mini status profile
99
- copy_id: 'Copy ID',
120
+ // Mini status profile
121
+ copy_id: 'Copy ID',
100
122
 
101
- // Profile
102
- avatar_color: 'Avatar color',
103
- open_profile: 'Open profile',
104
- cards_ct: '%{smart_count} Card||||%{smart_count} Cards',
105
- report_user: 'Report user',
106
- profile_deactivated_desc: 'This account has been deactivated.',
107
- phone_numbers: 'Phone numbers',
123
+ // Profile
124
+ avatar_color: 'Avatar color',
125
+ open_profile: 'Open profile',
126
+ cards_ct: '%{smart_count} Card||||%{smart_count} Cards',
127
+ report_user: 'Report user',
128
+ profile_deactivated_desc: 'This account has been deactivated.',
129
+ phone_numbers: 'Phone numbers',
108
130
 
109
- // Roles
110
- role: {
111
- MEMBER: 'Employee',
112
- MANAGER: 'Manager',
113
- ADMIN: 'Admin',
114
- OWNER: 'Owner',
115
- },
116
- },
131
+ // Roles
132
+ role: {
133
+ MEMBER: 'Employee',
134
+ MANAGER: 'Manager',
135
+ ADMIN: 'Admin',
136
+ OWNER: 'Owner',
137
+ },
138
+ },
117
139
  };