@communecter/cocolight-api-client 1.0.170 → 1.0.171
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/dist/4402.cocolight-api-client.browser.js +1 -1
- package/dist/4402.cocolight-api-client.cjs +1 -1
- package/dist/601.cocolight-api-client.browser.js +1 -1
- package/dist/601.cocolight-api-client.cjs +1 -1
- package/dist/cocolight-api-client.browser.js +1 -1
- package/dist/cocolight-api-client.cjs +1 -1
- package/dist/cocolight-api-client.vite.mjs.js +1 -1
- package/dist/cocolight-api-client.vite.mjs.js.map +1 -1
- package/package.json +1 -1
- package/types/ApiClient.d.ts +7 -1
- package/types/api/EndpointApi.types.d.ts +6 -0
- package/types/costum/runtime.d.ts +4 -0
- package/types/costum/types.d.ts +5 -6
- package/types/endpoints.module.d.ts +6 -1
- package/types/index.d.ts +1 -0
package/package.json
CHANGED
package/types/ApiClient.d.ts
CHANGED
|
@@ -36,6 +36,12 @@ export interface ApiClientOptions {
|
|
|
36
36
|
*/
|
|
37
37
|
mode?: "legacy" | "clean";
|
|
38
38
|
tokenStorageStrategy?: TokenStorageStrategy | null;
|
|
39
|
+
/**
|
|
40
|
+
* Ignore les schémas costum BUNDLÉS et ne résout que par `getcostumjson` (cf. `setCostumForceLive`).
|
|
41
|
+
* À activer quand la config costum évolue en base plus vite que les artefacts publiés — sans quoi
|
|
42
|
+
* un artefact périmé masque indéfiniment les champs réels. Contrepartie : plus de démarrage à froid.
|
|
43
|
+
*/
|
|
44
|
+
costumForceLive?: boolean;
|
|
39
45
|
}
|
|
40
46
|
/**
|
|
41
47
|
* Structure des données pour les appels d'endpoint
|
|
@@ -96,7 +102,7 @@ export default class ApiClient extends EventEmitter {
|
|
|
96
102
|
private _refreshToken;
|
|
97
103
|
private _setUserId;
|
|
98
104
|
private _mode;
|
|
99
|
-
constructor({ baseURL, accessToken, refreshToken, refreshUrl, endpoints, timeout, debug, maxRetries, circuitBreakerThreshold, circuitBreakerResetTime, fromJSONValue, mode, tokenStorageStrategy }: ApiClientOptions);
|
|
105
|
+
constructor({ baseURL, accessToken, refreshToken, refreshUrl, endpoints, timeout, debug, maxRetries, circuitBreakerThreshold, circuitBreakerResetTime, fromJSONValue, mode, tokenStorageStrategy, costumForceLive }: ApiClientOptions);
|
|
100
106
|
/**
|
|
101
107
|
* Sets the access token for the API client and updates the authorization header.
|
|
102
108
|
*/
|
|
@@ -3113,6 +3113,12 @@ export interface AddProjectData {
|
|
|
3113
3113
|
* Site web
|
|
3114
3114
|
*/
|
|
3115
3115
|
url?: string | "";
|
|
3116
|
+
/**
|
|
3117
|
+
* Réseaux sociaux — objet keyé par plateforme (facebook/twitter/instagram/mastodon/telegram/…). dataBinding projet legacy `socialNetwork` (Project.php). La clé OBJET ENTIER manquait à Project là où Organization la déclare (Organization.php:82) : un client qui l'envoyait la voyait retirée à l'extraction, donc perdue en silence. Les réseaux un par un (`facebook`…) restent portés par UPDATE_BLOCK_SOCIAL.
|
|
3118
|
+
*/
|
|
3119
|
+
socialNetwork?: {
|
|
3120
|
+
[k: string]: string;
|
|
3121
|
+
};
|
|
3116
3122
|
preferences?: {
|
|
3117
3123
|
/**
|
|
3118
3124
|
* Open data (true/false)
|
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
import type { CostumExtensionModule, CostumExtensionField, KnownCostumSlug, Collection } from "./types.js";
|
|
2
2
|
import type { BaseEntity } from "../api/BaseEntity.js";
|
|
3
|
+
/** Active/désactive FORCE-LIVE (cf. `COSTUM_FORCE_LIVE`). */
|
|
4
|
+
export declare function setCostumForceLive(actif: boolean): void;
|
|
5
|
+
/** État courant de FORCE-LIVE. */
|
|
6
|
+
export declare function isCostumForceLive(): boolean;
|
|
3
7
|
/**
|
|
4
8
|
* Invalide le cache costum live — d'UN slug (ex. après avoir modifié ce costum en base), ou de TOUT
|
|
5
9
|
* (`invalidateCostumCache()`). Le prochain accès refetchera `getcostumjson` (C2e). Sans effet sur le bundle.
|
package/types/costum/types.d.ts
CHANGED
|
@@ -328,14 +328,14 @@ export interface CostumFieldMap {
|
|
|
328
328
|
};
|
|
329
329
|
equipementsSportifs974: {
|
|
330
330
|
poi: {
|
|
331
|
-
aps_name?: string
|
|
331
|
+
aps_name?: string;
|
|
332
332
|
categorie?: string;
|
|
333
333
|
equip_acc_libre?: boolean;
|
|
334
334
|
equip_douche?: boolean;
|
|
335
335
|
equip_eclair?: boolean;
|
|
336
336
|
equip_gest_type?: string;
|
|
337
337
|
equip_larg?: number;
|
|
338
|
-
equip_loc_type?: string
|
|
338
|
+
equip_loc_type?: string;
|
|
339
339
|
equip_long?: number;
|
|
340
340
|
equip_maj_date?: string;
|
|
341
341
|
equip_nature?: string;
|
|
@@ -357,14 +357,14 @@ export interface CostumFieldMap {
|
|
|
357
357
|
equip_surf?: number;
|
|
358
358
|
equip_type_famille?: string;
|
|
359
359
|
equip_type_name?: string;
|
|
360
|
-
equip_utilisateur?: string
|
|
360
|
+
equip_utilisateur?: string;
|
|
361
361
|
inst_acc_handi_bool?: boolean;
|
|
362
362
|
inst_acc_handi_type?: string;
|
|
363
363
|
inst_date_creation?: string;
|
|
364
364
|
inst_enqu_date?: string;
|
|
365
365
|
inst_nom?: string;
|
|
366
366
|
inst_part_bool?: boolean;
|
|
367
|
-
inst_part_type?: string
|
|
367
|
+
inst_part_type?: string;
|
|
368
368
|
inst_trans_bool?: boolean;
|
|
369
369
|
inst_trans_type?: string;
|
|
370
370
|
};
|
|
@@ -933,14 +933,13 @@ export interface CostumFieldMap {
|
|
|
933
933
|
personInChargeName?: string;
|
|
934
934
|
personInChargeTelephone?: number;
|
|
935
935
|
personInChargeTitle?: "Président" | "Maire.sse" | "Chef.fe d'entreprise" | "Chef.fe d'établissement" | "Autre...";
|
|
936
|
-
recepisseDeclaration?: string;
|
|
937
936
|
representativeCivility?: string;
|
|
938
937
|
representativeEmail?: string;
|
|
939
938
|
representativeFirstName?: string;
|
|
940
939
|
representativeName?: string;
|
|
941
940
|
representativeTelephone?: number;
|
|
942
941
|
representativeTitle?: "Président" | "Maire.sse" | "Chef.fe d'entreprise" | "Chef.fe d'établissement" | "Autre...";
|
|
943
|
-
responsableCivilePro?: string
|
|
942
|
+
responsableCivilePro?: Record<string, unknown>;
|
|
944
943
|
responsableSameAsRepresent?: boolean;
|
|
945
944
|
sextionInfo?: Record<string, unknown>;
|
|
946
945
|
sextionInfoRepresentant?: Record<string, unknown>;
|
|
@@ -20427,6 +20427,12 @@ declare const endpoints: {
|
|
|
20427
20427
|
shortDescription: {
|
|
20428
20428
|
type: string;
|
|
20429
20429
|
};
|
|
20430
|
+
socialNetwork: {
|
|
20431
|
+
additionalProperties: {
|
|
20432
|
+
type: string;
|
|
20433
|
+
};
|
|
20434
|
+
type: string;
|
|
20435
|
+
};
|
|
20430
20436
|
tags: {
|
|
20431
20437
|
oneOf: ({
|
|
20432
20438
|
const: string;
|
|
@@ -20551,7 +20557,6 @@ declare const endpoints: {
|
|
|
20551
20557
|
mainTag?: undefined;
|
|
20552
20558
|
openingHours?: undefined;
|
|
20553
20559
|
role?: undefined;
|
|
20554
|
-
socialNetwork?: undefined;
|
|
20555
20560
|
telephone?: undefined;
|
|
20556
20561
|
thematic?: undefined;
|
|
20557
20562
|
video?: undefined;
|
package/types/index.d.ts
CHANGED
|
@@ -87,6 +87,7 @@ export { UPDATE_PATH_MAGIC } from "./api/BaseEntity.js";
|
|
|
87
87
|
export type { CostumScope, CostumRuntimeContext, CostumFormDescriptor, CostumFieldDescriptor, CostumFieldType, } from "./costum/runtime.js";
|
|
88
88
|
export type { Collection, KnownCostumSlug } from "./costum/types.js";
|
|
89
89
|
export { describeCostumForms } from "./costum/runtime.js";
|
|
90
|
+
export { resolveCostumScope, setCostumForceLive, isCostumForceLive } from "./costum/runtime.js";
|
|
90
91
|
export { describeEntityForm } from "./forms/entityForm.js";
|
|
91
92
|
export type { EntityFormDescriptor, BaseFieldDescriptor, EntityFieldType, EntityFieldFormat } from "./forms/entityForm.js";
|
|
92
93
|
export type { AllStepsData, PendingUploadValue, PendingUpload, ProcessUploadsOptions, AnswerGetOptions, UploadAnswerFileOptions, UploadAnswerFileResult, GetFilesOptions, AnswerFileItem, } from "./api/Answer.js";
|