@micheeeeel/yinyangapp 2.6.0 → 3.0.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.
@@ -25,27 +25,3 @@ export declare function getYasuniCause(id?: string): Cause;
25
25
  * bornes (`validateContactProfile`).
26
26
  */
27
27
  export declare function contactProfileToCause(profile: ContactProfileData, id?: string): Cause;
28
- /**
29
- * La `Cause` d'un contact EMBARQUÉ dans la lib, fraîchement construite à
30
- * chaque appel. `id` par défaut : l'id du contact. Lève une erreur si le
31
- * contact est inconnu (voir `listContacts`).
32
- *
33
- * @deprecated Les profils embarqués sont des fixtures gelées de la page
34
- * standalone ; une app hôte fournit ses profils à `contactProfileToCause`.
35
- * Retrait prévu en 3.0.0.
36
- */
37
- export declare function getContactCause(contactId: string, id?: string): Cause;
38
- export interface ContactSummary {
39
- id: string;
40
- name: string;
41
- role: string;
42
- organisation: string;
43
- provisional: boolean;
44
- }
45
- /**
46
- * Les contacts EMBARQUÉS, dans l'ordre de la calibration Notion.
47
- *
48
- * @deprecated Fixtures gelées de la page standalone ; la liste des contacts
49
- * d'une app hôte vient de sa propre source. Retrait prévu en 3.0.0.
50
- */
51
- export declare function listContacts(): ContactSummary[];
@@ -58,8 +58,7 @@ export { createYinYangFilmSvg, createYinYangFilmSvgAsync } from "./api-film";
58
58
  export type { YinYangFilmConfig, YinYangFilmAsyncOptions } from "./api-film";
59
59
  export { createRandomCause } from "./api-random";
60
60
  export type { RandomCauseOptions, RandomRange } from "./api-random";
61
- export { getYasuniCause, getContactCause, listContacts, contactProfileToCause, } from "./adapters/yasuniCauseAdapter";
62
- export type { ContactSummary } from "./adapters/yasuniCauseAdapter";
61
+ export { getYasuniCause, contactProfileToCause } from "./adapters/yasuniCauseAdapter";
63
62
  export { validateContactProfile } from "./data/contacts/buildContactSphere";
64
63
  export type { ContactProfileData, ContactSatelliteValue, } from "./data/contacts/buildContactSphere";
65
64
  export { UNIVERSAL_FACETS, CONTACT_CATEGORIES } from "./data/contacts/universalFacets";
@@ -26,7 +26,7 @@ export interface DiagramOption {
26
26
  label: string;
27
27
  }
28
28
  export interface DiagramEnvironment {
29
- /** `location.search` de la page (ex. "?diagram=etawane"). */
29
+ /** `location.search` de la page (ex. "?diagram=demo_contact"). */
30
30
  search: string | null | undefined;
31
31
  /** Page standalone de la lib (seule à honorer le paramètre d'URL). */
32
32
  standalone: boolean;
@@ -42,7 +42,8 @@ export declare function detectDiagramEnvironment(): DiagramEnvironment;
42
42
  /** Données d'un diagramme : les catalogues Yasuní tels quels, ou une sphère
43
43
  * de contact (pas d'actions, d'événements, de graphe ni de propagation). */
44
44
  export declare function buildDiagramData(id: string): DiagramData;
45
- /** Options du sélecteur de diagramme : le Yasuní puis les contacts. */
45
+ /** Options du sélecteur de diagramme : le Yasuní puis le contact de
46
+ * démonstration. */
46
47
  export declare function listDiagramOptions(): DiagramOption[];
47
48
  /** URL de la page courante pointant sur `diagramId` (les autres paramètres
48
49
  * sont conservés ; le Yasuní, diagramme par défaut, retire le paramètre). */
@@ -23,12 +23,6 @@ export interface ContactProfileData {
23
23
  /** Une valeur par satellite de la grille universelle, ni plus ni moins. */
24
24
  values: Record<SatelliteKey, ContactSatelliteValue>;
25
25
  }
26
- /** Profil EMBARQUÉ (fixtures `profiles/<id>.ts`, page standalone et
27
- * `getContactCause` dépréciée) : identité complète de la calibration. */
28
- export interface ContactProfile extends ContactProfileData {
29
- role: string;
30
- organisation: string;
31
- }
32
26
  /**
33
27
  * Vérifie un profil reçu de l'hôte AVANT de construire sa sphère : une clé
34
28
  * de satellite manquante ou inconnue, un score ou un poids non fini ou hors
@@ -42,5 +36,3 @@ export declare function validateContactProfile(profile: ContactProfileData): voi
42
36
  */
43
37
  export declare function qualityPercentToTension(percent: number): number;
44
38
  export declare function buildContactSphere(profile: ContactProfileData): Sphere;
45
- /** Valeurs identiques pour les 38 satellites — gabarit de profil non calibré. */
46
- export declare function uniformContactValues(score: number, weight: number): Record<SatelliteKey, ContactSatelliteValue>;
@@ -0,0 +1,3 @@
1
+ import type { ContactProfileData } from "./buildContactSphere";
2
+ export declare const DEMO_CONTACT_ID = "demo_contact";
3
+ export declare const demoContactProfile: ContactProfileData;
@@ -1,14 +1,5 @@
1
- import type { Sphere } from "../yasuni_cause";
2
- import { type ContactProfile, type ContactProfileData } from "./buildContactSphere";
3
- export declare const contactProfiles: readonly ContactProfile[];
4
- export declare const CONTACT_IDS: readonly string[];
5
- export declare function getContactProfile(contactId: string): ContactProfile | undefined;
6
- /** Le profil embarqué `contactId` au format injectable, présenté comme
7
- * avant 2.6.0 (« rôle — organisme ») ; lève une erreur si l'id est inconnu. */
8
- export declare function getEmbeddedContactProfileData(contactId: string): ContactProfileData;
9
- /** Sphere fraîchement construite du contact ; lève une erreur si l'id est inconnu. */
10
- export declare function getContactSphere(contactId: string): Sphere;
11
1
  export { buildContactSphere, qualityPercentToTension, validateContactProfile, } from "./buildContactSphere";
12
- export type { ContactProfile, ContactProfileData, ContactSatelliteValue, } from "./buildContactSphere";
2
+ export type { ContactProfileData, ContactSatelliteValue } from "./buildContactSphere";
3
+ export { DEMO_CONTACT_ID, demoContactProfile } from "./demoContact";
13
4
  export { UNIVERSAL_FACETS, CONTACT_CATEGORIES } from "./universalFacets";
14
5
  export type { SatelliteKey, ContactFacetId, ContactCategoryId } from "./universalFacets";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@micheeeeel/yinyangapp",
3
- "version": "2.6.0",
3
+ "version": "3.0.0",
4
4
  "description": "A program to visualize human activity balance to reach Sustainable Development Objectives",
5
5
  "main": "dist/bundle.js",
6
6
  "types": "dist/types/main.d.ts",
@@ -1,2 +0,0 @@
1
- import { type ContactProfile } from "../buildContactSphere";
2
- export declare const andresCevallosProfile: ContactProfile;
@@ -1,2 +0,0 @@
1
- import type { ContactProfile } from "../buildContactSphere";
2
- export declare const camilaSerranoProfile: ContactProfile;
@@ -1,2 +0,0 @@
1
- import type { ContactProfile } from "../buildContactSphere";
2
- export declare const dikaProfile: ContactProfile;
@@ -1,2 +0,0 @@
1
- import { type ContactProfile } from "../buildContactSphere";
2
- export declare const elenaViteriProfile: ContactProfile;
@@ -1,2 +0,0 @@
1
- import type { ContactProfile } from "../buildContactSphere";
2
- export declare const etawaneProfile: ContactProfile;
@@ -1,2 +0,0 @@
1
- import type { ContactProfile } from "../buildContactSphere";
2
- export declare const gabrielMenaProfile: ContactProfile;
@@ -1,2 +0,0 @@
1
- import { type ContactProfile } from "../buildContactSphere";
2
- export declare const kuriTapuyProfile: ContactProfile;
@@ -1,2 +0,0 @@
1
- import type { ContactProfile } from "../buildContactSphere";
2
- export declare const luciaCardenasProfile: ContactProfile;
@@ -1,2 +0,0 @@
1
- import type { ContactProfile } from "../buildContactSphere";
2
- export declare const marianaParedesProfile: ContactProfile;
@@ -1,2 +0,0 @@
1
- import type { ContactProfile } from "../buildContactSphere";
2
- export declare const martinAguirreProfile: ContactProfile;
@@ -1,2 +0,0 @@
1
- import type { ContactProfile } from "../buildContactSphere";
2
- export declare const mateoSalazarProfile: ContactProfile;
@@ -1,2 +0,0 @@
1
- import type { ContactProfile } from "../buildContactSphere";
2
- export declare const sofiaAlmeidaProfile: ContactProfile;
@@ -1,2 +0,0 @@
1
- import { type ContactProfile } from "../buildContactSphere";
2
- export declare const tomasValverdeProfile: ContactProfile;