Skip to content

Commit

Permalink
ajax-fetch, json-fetch, and fixed mistake on geomap index.json-ld
Browse files Browse the repository at this point in the history
  • Loading branch information
SebastianBurke committed Aug 1, 2024
1 parent 91947fc commit 9aca247
Show file tree
Hide file tree
Showing 8 changed files with 224 additions and 2 deletions.
36 changes: 35 additions & 1 deletion _data/wet-boew.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,40 @@
]
}
}
,{
"@context": {
"@version": 1.1,
"dct": "http://purl.org/dc/terms/",
"title": { "@id": "dct:title", "@container": "@language" },
"description": { "@id": "dct:description", "@container": "@language" },
"modified": "dct:modified"
},
"title": {
"en": "ajax-fetch",
"fr": "ajax-fetch"
},
"description": {
"en": "Handles Ajax requests and triggers events for success or failure.",
"fr": "Gère les requêtes Ajax et déclenche des événements pour le succès ou l'échec."
},
"modified": "2024-08-01",
"componentName": "ajax-fetch",
"status": "stable",
"pages": {
"examples": [
{
"title": "Ajax fetch",
"language": "en",
"path": "./ajax-fetch-en.html"
},
{
"title": "Ajax fetch",
"language": "fr",
"path": "./ajax-fetch-fr.html"
}
]
}
}
,{
"@context": {
"@version": 1.1,
Expand Down Expand Up @@ -614,7 +648,7 @@
},
{
"title": "Geomap v4.0.30",
"language": "fr",
"language": "en",
"path": "./geomap-v4.0.30-en.html"
},
{
Expand Down
32 changes: 32 additions & 0 deletions wet-boew/ajax-fetch/ajax-fetch-en.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
---
{
"title": "ajax-fetch",
"language": "en",
"description": "Handles Ajax requests and triggers events for success or failure.",
"altLangPage": "ajax-fetch-fr.html",
"dateModified": "2024-08-01"
}
---
<ul class="list-inline">
<li><a class="btn btn-primary" href="https://github.com/wet-boew/GCWeb/issues/new?title=Ajax%20Fetch">Questions or comments?</a></li>
</ul>

<p>The ajax-fetch component in WET-BOEW handles Ajax requests by triggering an event, processing the request, and triggering custom events for success or failure to facilitate response handling. The component defines the following events:</p>

<ul class="list-inline">
<li><strong>ajax-fetch.wb:</strong> Triggered to initiate an Ajax request based on the provided options.</li>
<li><strong>ajax-fetched.wb:</strong> Triggered when the Ajax request is successfully completed, containing the response data and other relevant information.</li>
<li><strong>ajax-failed.wb:</strong> Triggered when the Ajax request fails, containing the error information and the status of the failed request.</li>
</ul>

<p>It is used in the following components:</p>

<ul class="list-inline">
<li><a class="btn btn-primary" href="https://wet-boew.github.io/gcweb-compiled-demos/wetboew-demos/data-ajax/data-ajax-en.html">Data Ajax</a></li>
<li><a class="btn btn-primary" href="https://wet-boew.github.io/gcweb-compiled-demos/wetboew-demos/feeds/feeds-en.html">Feeds</a></li>
<li><a class="btn btn-primary" href="https://wet-boew.github.io/gcweb-compiled-demos/wetboew-demos/menu/menu-en.html">Menu</a></li>
<li><a class="btn btn-primary" href="https://wet-boew.github.io/gcweb-compiled-demos/wetboew-demos/multimedia/multimedia-audio-en.html">Multimedia Player - Audio-only</a></li>
<li><a class="btn btn-primary" href="https://wet-boew.github.io/gcweb-compiled-demos/wetboew-demos/multimedia/multimedia-en.html">Multimedia Player - Video</a></li>
<li><a class="btn btn-primary" href="https://wet-boew.github.io/gcweb-compiled-demos/wetboew-demos/multimedia/multimedia-youtube-en.html">Multimedia Player - YouTube</a></li>
<li><a class="btn btn-primary" href="https://wet-boew.github.io/wet-boew/demos/datalist/datalist-dynamic-en.html">Datalist polyfill (auto-complete) - Dynamic</a></li>
</ul>
32 changes: 32 additions & 0 deletions wet-boew/ajax-fetch/ajax-fetch-fr.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
---
{
"title": "ajax-fetch",
"language": "fr",
"description": "Gère les requêtes Ajax et déclenche des événements pour le succès ou l'échec.",
"altLangPage": "ajax-fetch-en.html",
"dateModified": "2024-08-01"
}
---
<ul class="list-inline">
<li><a class="btn btn-primary" href="https://github.com/wet-boew/GCWeb/issues/new?title=Ajax%20Fetch">Questions ou commentaires ?</a></li>
</ul>

<p>Le composant ajax-fetch dans WET-BOEW gère les requêtes Ajax en déclenchant un événement pour initier la requête, en traitant la requête et en déclenchant des événements personnalisés pour le succès ou l'échec afin de faciliter le traitement des réponses. Le composant définit les événements suivants :</p>

<ul class="list-inline">
<li><strong>ajax-fetch.wb :</strong> Déclenché pour initier une requête Ajax basée sur les options fournies.</li>
<li><strong>ajax-fetched.wb :</strong> Déclenché lorsque la requête Ajax est complétée avec succès, contenant les données de réponse et d'autres informations pertinentes.</li>
<li><strong>ajax-failed.wb :</strong> Déclenché lorsque la requête Ajax échoue, contenant les informations sur l'erreur et le statut de la requête échouée.</li>
</ul>

<p>Il est utilisé dans les composants suivants :</p>

<ul class="list-inline">
<li><a class="btn btn-primary" href="https://wet-boew.github.io/gcweb-compiled-demos/wetboew-demos/data-ajax/data-ajax-fr.html">Data Ajax</a></li>
<li><a class="btn btn-primary" href="https://wet-boew.github.io/gcweb-compiled-demos/wetboew-demos/feeds/feeds-fr.html">Fils de syndication</a></li>
<li><a class="btn btn-primary" href="https://wet-boew.github.io/gcweb-compiled-demos/wetboew-demos/menu/menu-fr.html">Menu</a></li>
<li><a class="btn btn-primary" href="https://wet-boew.github.io/gcweb-compiled-demos/wetboew-demos/multimedia/multimedia-audio-fr.html">Lecteur multimédia - Audio seulement</a></li>
<li><a class="btn btn-primary" href="https://wet-boew.github.io/gcweb-compiled-demos/wetboew-demos/multimedia/multimedia-fr.html">Lecteur multimédia - Vidéo</a></li>
<li><a class="btn btn-primary" href="https://wet-boew.github.io/gcweb-compiled-demos/wetboew-demos/multimedia/multimedia-youtube-fr.html">Lecteur multimédia - YouTube</a></li>
<li><a class="btn btn-primary" href="https://wet-boew.github.io/wet-boew/demos/datalist/datalist-dynamic-fr.html">Correctif « datalist » (saisie automatique) - Dynamique</a></li>
</ul>
34 changes: 34 additions & 0 deletions wet-boew/ajax-fetch/index.json-ld
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
{
"@context": {
"@version": 1.1,
"dct": "http://purl.org/dc/terms/",
"title": { "@id": "dct:title", "@container": "@language" },
"description": { "@id": "dct:description", "@container": "@language" },
"modified": "dct:modified"
},
"title": {
"en": "ajax-fetch",
"fr": "ajax-fetch"
},
"description": {
"en": "Handles Ajax requests and triggers events for success or failure.",
"fr": "Gère les requêtes Ajax et déclenche des événements pour le succès ou l'échec."
},
"modified": "2024-08-01",
"componentName": "ajax-fetch",
"status": "stable",
"pages": {
"examples": [
{
"title": "Ajax fetch",
"language": "en",
"path": "./ajax-fetch-en.html"
},
{
"title": "Ajax fetch",
"language": "fr",
"path": "./ajax-fetch-fr.html"
}
]
}
}
2 changes: 1 addition & 1 deletion wet-boew/geomap/index.json-ld
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
},
{
"title": "Geomap v4.0.30",
"language": "fr",
"language": "en",
"path": "./geomap-v4.0.30-en.html"
},
{
Expand Down
34 changes: 34 additions & 0 deletions wet-boew/json-fetch/index.json-ld
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
{
"@context": {
"@version": 1.1,
"dct": "http://purl.org/dc/terms/",
"title": { "@id": "dct:title", "@container": "@language" },
"description": { "@id": "dct:description", "@container": "@language" },
"modified": "dct:modified"
},
"title": {
"en": "json-fetch",
"fr": "json-fetch"
},
"description": {
"en": "Handles JSON data fetching and triggers events for success or failure.",
"fr": "Gère la récupération de données JSON et déclenche des événements pour le succès ou l'échec."
},
"modified": "2024-08-01",
"componentName": "json-fetch",
"status": "stable",
"pages": {
"examples": [
{
"title": "JSON fetch",
"language": "en",
"path": "./json-fetch-en.html"
},
{
"title": "JSON fetch",
"language": "fr",
"path": "./json-fetch-fr.html"
}
]
}
}
28 changes: 28 additions & 0 deletions wet-boew/json-fetch/json-fetch-en.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
{
"title": "json-fetch",
"language": "en",
"description": "Handles JSON data fetching and triggers events for success or failure.",
"altLangPage": "json-fetch-fr.html",
"dateModified": "2024-08-01"
}
---
<ul class="list-inline">
<li><a class="btn btn-primary" href="https://github.com/wet-boew/GCWeb/issues/new?title=JSON%20fetch">Questions or comments?</a></li>
</ul>

<p>The json-fetch component in WET-BOEW manages JSON data retrieval by triggering events to start the fetch operation, process the data, and handle responses. It defines custom events to signal the success or failure of the fetch operation, and can also handle dataset names via the wb-jsonpatch plugin. The component defines the following events:</p>

<ul class="list-inline">
<li><strong>json-fetch.wb:</strong> Triggered to initiate a JSON fetch operation.</li>
<li><strong>json-fetched.wb:</strong> Triggered when a JSON fetch is successful, providing the fetched response and other related data.</li>
<li><strong>json-failed.wb:</strong> Triggered when a JSON fetch fails, providing error information and status details.</li>
<li><strong>postpone.wb-jsonmanager:</strong> Triggered to postpone handling if a dataset name is encountered, allowing the wb-jsonpatch plugin to manage it.</li>
</ul>

<p>It is used in the following components:</p>

<ul class="list-inline">
<li><a class="btn btn-primary" href="https://wet-boew.github.io/gcweb-compiled-demos/wetboew-demos/wb-data-json/data-json-en.html">Data JSON</a></li>
<li><a class="btn btn-primary" href="https://wet-boew.github.io/gcweb-compiled-demos/wetboew-demos/wb-jsonmanager/jsonmanager-en.html">JSON Manager</a></li>
</ul>
28 changes: 28 additions & 0 deletions wet-boew/json-fetch/json-fetch-fr.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
{
"title": "json-fetch",
"language": "fr",
"description": "Gère la récupération de données JSON et déclenche des événements pour le succès ou l'échec.",
"altLangPage": "json-fetch-en.html",
"dateModified": "2024-08-01"
}
---
<ul class="list-inline">
<li><a class="btn btn-primary" href="https://github.com/wet-boew/GCWeb/issues/new?title=JSON%20fetch">Questions ou commentaires ?</a></li>
</ul>

<p>Le composant json-fetch dans WET-BOEW gère la récupération des données JSON en déclenchant des événements pour démarrer l'opération de récupération, traiter les données et gérer les réponses. Il définit des événements personnalisés pour signaler le succès ou l'échec de l'opération de récupération, et peut également gérer les noms de jeux de données via le plugin wb-jsonpatch. Le composant définit les événements suivants :</p>

<ul class="list-inline">
<li><strong>json-fetch.wb :</strong> Déclenché pour initier une opération de récupération JSON.</li>
<li><strong>json-fetched.wb :</strong> Déclenché lorsque la récupération JSON est réussie, fournissant la réponse récupérée et d'autres données connexes.</li>
<li><strong>json-failed.wb :</strong> Déclenché lorsque la récupération JSON échoue, fournissant des informations sur l'erreur et des détails sur le statut.</li>
<li><strong>postpone.wb-jsonmanager :</strong> Déclenché pour reporter le traitement si un nom de jeu de données est rencontré, permettant au plugin wb-jsonpatch de le gérer.</li>
</ul>

<p>Il est utilisé dans les composants suivants :</p>

<ul class="list-inline">
<li><a class="btn btn-primary" href="https://wet-boew.github.io/gcweb-compiled-demos/wetboew-demos/wb-data-json/data-json-fr.html">Data JSON</a></li>
<li><a class="btn btn-primary" href="https://wet-boew.github.io/gcweb-compiled-demos/wetboew-demos/wb-jsonmanager/jsonmanager-fr.html">Gestionnaire JSON</a></li>
</ul>

0 comments on commit 9aca247

Please sign in to comment.