@magicx-eng/ai-autocomplete-angular 0.32.0 → 0.32.2
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 +3 -2
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -741,7 +741,8 @@ apiConfig: AccessTokenConfig = {
|
|
|
741
741
|
getAccessToken: async () => {
|
|
742
742
|
const res = await fetch("/api/ac-token");
|
|
743
743
|
const { access_token, expires_at } = await res.json();
|
|
744
|
-
|
|
744
|
+
// expires_at is Unix seconds; the SDK's expiresAt is Unix milliseconds.
|
|
745
|
+
return { accessToken: access_token, expiresAt: expires_at * 1000 };
|
|
745
746
|
},
|
|
746
747
|
};
|
|
747
748
|
```
|
|
@@ -755,7 +756,7 @@ apiConfig: AccessTokenConfig = {
|
|
|
755
756
|
| `appIdentifier?` | `string` | Value for the `X-App-Identifier` header. |
|
|
756
757
|
| `headers?` | `Record<string, string>` | Additional headers merged into every request. |
|
|
757
758
|
|
|
758
|
-
The SDK handles token refresh transparently: 401 → `getAccessToken` → retry (once). Concurrent 401s share a single refresh. Tokens refresh proactively 30s before `expiresAt
|
|
759
|
+
The SDK handles token refresh transparently: 401 → `getAccessToken` → retry (once). Concurrent 401s share a single refresh. Tokens refresh proactively 30s before `expiresAt` (Unix milliseconds).
|
|
759
760
|
|
|
760
761
|
### `AIAutocompleteController` (Tier 2)
|
|
761
762
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@magicx-eng/ai-autocomplete-angular",
|
|
3
|
-
"version": "0.32.
|
|
3
|
+
"version": "0.32.2",
|
|
4
4
|
"description": "AI Autocomplete Angular SDK — guided autocomplete with pill-based input and dropdown suggestions",
|
|
5
5
|
"module": "fesm2015/magicx-eng-ai-autocomplete-angular.mjs",
|
|
6
6
|
"es2020": "fesm2020/magicx-eng-ai-autocomplete-angular.mjs",
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
23
|
"tslib": "^2.3.0",
|
|
24
|
-
"@magicx-eng/ai-autocomplete-vanilla": "0.
|
|
24
|
+
"@magicx-eng/ai-autocomplete-vanilla": "0.41.0"
|
|
25
25
|
},
|
|
26
26
|
"keywords": [
|
|
27
27
|
"angular",
|