@visns-studio/visns-components 6.6.4 → 6.15.0
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/README.md +1623 -18
- package/package.json +10 -4
- package/src/components/DataGrid.jsx +171 -37
- package/src/components/Fetch.jsx +80 -3
- package/src/components/Form.jsx +9 -0
- package/src/components/Navigation.jsx +109 -50
- package/src/components/Notification.jsx +279 -9
- package/src/components/TableFilter.jsx +14 -1
- package/src/components/auth/AuthBrandPanel.jsx +43 -0
- package/src/components/auth/AuthLoading.jsx +78 -0
- package/src/components/auth/AuthShell.jsx +59 -0
- package/src/components/auth/ClientAuth.jsx +161 -0
- package/src/components/auth/ClientAuthFrame.jsx +59 -0
- package/src/components/auth/ClientLogin.jsx +266 -55
- package/src/components/auth/ClientOTPVerify.jsx +587 -115
- package/src/components/auth/ImpersonateGate.jsx +254 -0
- package/src/components/auth/Login.jsx +134 -41
- package/src/components/auth/LogoutScreen.jsx +112 -0
- package/src/components/auth/Reset.jsx +134 -77
- package/src/components/auth/TwoFactorAuth.jsx +475 -297
- package/src/components/auth/Verify.jsx +237 -126
- package/src/components/auth/authEndpoints.js +105 -0
- package/src/components/auth/authFont.js +23 -0
- package/src/components/auth/authHelpers.js +465 -0
- package/src/components/auth/clientAuthProtocols.js +240 -0
- package/src/components/auth/useOptionalRouter.js +49 -0
- package/src/components/callQueue/CallQueuePop.jsx +1502 -0
- package/src/components/callQueue/CallQueueSettings.jsx +508 -0
- package/src/components/callQueue/callQueueHelpers.js +280 -0
- package/src/components/callQueue/callQueueSettingsHelpers.js +75 -0
- package/src/components/columns/ColumnRenderers.jsx +53 -7
- package/src/components/generic/GenericAuth.jsx +163 -96
- package/src/components/generic/GenericDetail.jsx +215 -90
- package/src/components/generic/GenericIndex.jsx +20 -47
- package/src/components/generic/GenericMain.jsx +5 -0
- package/src/components/generic/GroupedReportRenderer.jsx +1 -5
- package/src/components/generic/StandardModal.jsx +17 -5
- package/src/components/generic/reportSemanticSteps/SemanticEntityStep.jsx +1 -6
- package/src/components/generic/reportSemanticSteps/SemanticFieldsStep.jsx +4 -11
- package/src/components/generic/reportSemanticSteps/SemanticFiltersStep.jsx +9 -27
- package/src/components/generic/reportSemanticSteps/SemanticGroupingStep.jsx +5 -13
- package/src/components/generic/reportSemanticSteps/SemanticParameterPrompt.jsx +5 -13
- package/src/components/generic/reportSemanticSteps/SemanticPreviewStep.jsx +14 -31
- package/src/components/generic/reportSemanticSteps/SemanticRelationsStep.jsx +3 -9
- package/src/components/generic/reportSemanticSteps/SemanticValueInput.jsx +2 -15
- package/src/components/navActive.js +60 -0
- package/src/components/notify/desktopNotifications.js +256 -0
- package/src/components/sketch/SketchField.jsx +12 -2
- package/src/components/sms/SmsComposeModal.jsx +495 -0
- package/src/components/sms/SmsInbox.jsx +596 -0
- package/src/components/sms/SmsInboxBadge.jsx +468 -0
- package/src/components/sms/SmsLineSettings.jsx +854 -0
- package/src/components/sms/SmsThreadPanel.jsx +1184 -0
- package/src/components/sms/smsEndpoints.js +56 -0
- package/src/components/sms/smsHelpers.js +1075 -0
- package/src/components/sms/smsLiveState.js +132 -0
- package/src/components/sms/useSmsLive.js +307 -0
- package/src/components/styles/CallQueuePop.module.scss +646 -0
- package/src/components/styles/CallQueueSettings.module.scss +460 -0
- package/src/components/styles/ClientAuth.module.scss +229 -0
- package/src/components/styles/GenericDetail.module.scss +153 -26
- package/src/components/styles/GenericIndex.module.scss +13 -0
- package/src/components/styles/GenericMain.module.scss +19 -2
- package/src/components/styles/ImpersonateGate.module.scss +85 -0
- package/src/components/styles/Login.module.scss +13 -122
- package/src/components/styles/LogoutScreen.module.scss +89 -0
- package/src/components/styles/Navigation.module.scss +509 -223
- package/src/components/styles/Notification.module.scss +103 -0
- package/src/components/styles/Reset.module.scss +52 -186
- package/src/components/styles/Sms.module.scss +2382 -0
- package/src/components/styles/TableFilter.module.scss +118 -98
- package/src/components/styles/TwoFactorAuth.module.scss +115 -176
- package/src/components/styles/Vault.module.scss +1983 -0
- package/src/components/styles/Verify.module.scss +57 -180
- package/src/components/styles/_authBrandPanel.scss +163 -0
- package/src/components/styles/_authShell.scss +369 -0
- package/src/components/utils/buildEnv.js +67 -0
- package/src/components/utils/displayValue.js +94 -0
- package/src/components/utils/useDensity.js +345 -9
- package/src/components/vault/OtpChip.jsx +208 -0
- package/src/components/vault/PasswordGenerator.jsx +145 -0
- package/src/components/vault/QrScanner.jsx +326 -0
- package/src/components/vault/VaultAccessLog.jsx +225 -0
- package/src/components/vault/VaultConfirmPanel.jsx +113 -0
- package/src/components/vault/VaultEntryForm.jsx +740 -0
- package/src/components/vault/VaultManager.jsx +1000 -0
- package/src/components/vault/VaultQuickSearch.jsx +681 -0
- package/src/components/vault/qrDecode.js +257 -0
- package/src/components/vault/useDebouncedValue.js +22 -0
- package/src/components/vault/useVaultReveal.js +160 -0
- package/src/components/vault/vaultClipboard.js +33 -0
- package/src/components/vault/vaultEndpoints.js +40 -0
- package/src/components/vault/vaultFit.js +116 -0
- package/src/components/vault/vaultHelpers.js +547 -0
- package/src/components/vault/vaultNavigation.jsx +58 -0
- package/src/components/vault/vaultOtp.js +105 -0
- package/src/index.js +233 -1
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The URLs the messaging module talks to.
|
|
3
|
+
*
|
|
4
|
+
* Every SMS component takes an `endpoints` object rather than a base string,
|
|
5
|
+
* so a consumer can move one route without reproducing the other seventeen.
|
|
6
|
+
* The defaults are the CRM's routes under `/ajax/sms`; `makeSmsEndpoints` is
|
|
7
|
+
* there for the common case of moving all of them at once.
|
|
8
|
+
*
|
|
9
|
+
* Pure and React-free so `node --test` can import it — the same arrangement
|
|
10
|
+
* as vaultEndpoints.js, and for the same reason: these are the URLs a
|
|
11
|
+
* consumer that passes no `endpoints` prop will hit, so a change here is a
|
|
12
|
+
* change to every deployment.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
export const makeSmsEndpoints = (base = '/ajax/sms') => ({
|
|
16
|
+
// Kept so a component can build a route the contract grows later without
|
|
17
|
+
// the consumer having to re-derive the base from one of the URLs below.
|
|
18
|
+
base,
|
|
19
|
+
|
|
20
|
+
status: `${base}/status`,
|
|
21
|
+
lines: `${base}/lines`,
|
|
22
|
+
unread: `${base}/unread`,
|
|
23
|
+
|
|
24
|
+
threads: `${base}/threads`,
|
|
25
|
+
createThread: `${base}/threads`,
|
|
26
|
+
thread: (id) => `${base}/threads/${id}`,
|
|
27
|
+
updateThread: (id) => `${base}/threads/${id}`,
|
|
28
|
+
messages: (id) => `${base}/threads/${id}/messages`,
|
|
29
|
+
read: (id) => `${base}/threads/${id}/read`,
|
|
30
|
+
archive: (id) => `${base}/threads/${id}/archive`,
|
|
31
|
+
unarchive: (id) => `${base}/threads/${id}/unarchive`,
|
|
32
|
+
simulateInbound: (id) => `${base}/threads/${id}/simulate-inbound`,
|
|
33
|
+
|
|
34
|
+
clientSearch: `${base}/clients/search`,
|
|
35
|
+
|
|
36
|
+
templates: `${base}/templates`,
|
|
37
|
+
template: (id) => `${base}/templates/${id}`,
|
|
38
|
+
|
|
39
|
+
settingsLines: `${base}/settings/lines`,
|
|
40
|
+
settingsLine: (id) => `${base}/settings/lines/${id}`,
|
|
41
|
+
});
|
|
42
|
+
|
|
43
|
+
export const DEFAULT_ENDPOINTS = makeSmsEndpoints();
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* Merge a partial `endpoints` prop over the defaults.
|
|
47
|
+
*
|
|
48
|
+
* A consumer overriding one route must not lose the rest, and passing nothing
|
|
49
|
+
* at all must land exactly on DEFAULT_ENDPOINTS.
|
|
50
|
+
*/
|
|
51
|
+
export const resolveSmsEndpoints = (endpoints) => ({
|
|
52
|
+
...DEFAULT_ENDPOINTS,
|
|
53
|
+
...(endpoints || {}),
|
|
54
|
+
});
|
|
55
|
+
|
|
56
|
+
export default DEFAULT_ENDPOINTS;
|