@geogirafe/lib-geoportal 1.1.0-dev.2334458755 → 1.1.0-dev.2361375621

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/LICENSE CHANGED
@@ -264,4 +264,31 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
264
264
 
265
265
  -------------------------------------------------------------------------------
266
266
 
267
+ From:
268
+ - https://github.com/n3r4zzurr0/svg-spinners/blob/main/svg-smil/3-dots-fade.svg
269
+
270
+
271
+ The MIT License (MIT)
272
+
273
+ Copyright (c) Utkarsh Verma
274
+
275
+ Permission is hereby granted, free of charge, to any person obtaining a copy of
276
+ this software and associated documentation files (the "Software"), to deal in
277
+ the Software without restriction, including without limitation the rights to
278
+ use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
279
+ the Software, and to permit persons to whom the Software is furnished to do so,
280
+ subject to the following conditions:
281
+
282
+ The above copyright notice and this permission notice shall be included in all
283
+ copies or substantial portions of the Software.
284
+
285
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
286
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
287
+ FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
288
+ COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
289
+ IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
290
+ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
291
+
292
+ -------------------------------------------------------------------------------
293
+
267
294
  ===============================================================================
@@ -53,6 +53,7 @@
53
53
  "contains": "enthält",
54
54
  "Control opacity": "Deckkraft steuern",
55
55
  "Copy ShortUrl": "Kurz-URL kopieren",
56
+ "Copy to Clipboard": "In die Zwischenablage kopieren",
56
57
  "Copy value": "Wert kopieren",
57
58
  "Create custom theme": "Thema erstellen",
58
59
  "cross-section-settings": "Querschnitt",
@@ -150,6 +151,8 @@
150
151
  "Generate and copy code": "Code generieren und kopieren",
151
152
  "Generate and copy link": "Link generieren und kopieren",
152
153
  "Generate CSV": "CSV generieren",
154
+ "Generating code": "Code wird generiert",
155
+ "Generating link": "Link wird generiert",
153
156
  "GeoJSON": "GeoJSON",
154
157
  "Geolocation browser error": "Ihr Browser unterstützt keine Geolokalisierung",
155
158
  "Geolocation error": "Geolocation-Fehler",
@@ -53,6 +53,7 @@
53
53
  "contains": "contains",
54
54
  "Control opacity": "Control opacity",
55
55
  "Copy ShortUrl": "Copy ShortUrl",
56
+ "Copy to Clipboard": "Copy to Clipboard",
56
57
  "Copy value": "Copier value",
57
58
  "Create custom theme": "Create custom theme",
58
59
  "cross-section-settings": "Cross-section",
@@ -151,6 +152,8 @@
151
152
  "Generate and copy code": "Generate and copy code",
152
153
  "Generate and copy link": "Generate and copy link",
153
154
  "Generate CSV": "Generate CSV",
155
+ "Generating code": "Generating code",
156
+ "Generating link": "Generating link",
154
157
  "GeoJSON": "GeoJSON",
155
158
  "Geolocation browser error": "Your browser does not support geolocation",
156
159
  "Geolocation error": "Geolocation error",
@@ -53,6 +53,7 @@
53
53
  "contains": "contient",
54
54
  "Control opacity": "Contrôler l'opacité",
55
55
  "Copy ShortUrl": "Copier le lien court",
56
+ "Copy to Clipboard": "Copier dans le presse-papiers",
56
57
  "Copy value": "Copier la valeur",
57
58
  "Create custom theme": "Créer un thème personnalisé",
58
59
  "cross-section-settings": "Coupe transversale",
@@ -150,6 +151,8 @@
150
151
  "Generate and copy code": "Générer et copier le code",
151
152
  "Generate and copy link": "Générer et copier le lien",
152
153
  "Generate CSV": "Générer CSV",
154
+ "Generating code": "Génération du code",
155
+ "Generating link": "Génération du lien",
153
156
  "GeoJSON": "GeoJSON",
154
157
  "Geolocation browser error": "Votre navigateur ne supporte pas la géolocalisation",
155
158
  "Geolocation error": "Erreur de géolocalisation",
@@ -53,6 +53,7 @@
53
53
  "contains": "contiene",
54
54
  "Control opacity": "Controlla opacità",
55
55
  "Copy ShortUrl": "Copia ShortUrl",
56
+ "Copy to Clipboard": "Copia negli appunti",
56
57
  "Copy value": "Copia il valore",
57
58
  "Create custom theme": "Crea un tema personalizzato",
58
59
  "cross-section-settings": "Sezione trasversale",
@@ -150,6 +151,8 @@
150
151
  "Generate and copy code": "Genera e copia il codice",
151
152
  "Generate and copy link": "Genera e copia il link",
152
153
  "Generate CSV": "Genera CSV",
154
+ "Generating code": "Generazione del codice",
155
+ "Generating link": "Generazione del link",
153
156
  "GeoJSON": "GeoJSON",
154
157
  "Geolocation browser error": "Il tuo browser non supporta la geolocalizzazione",
155
158
  "Geolocation error": "Errore di geolocalizzazione",
@@ -0,0 +1 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><circle cx="4" cy="12" r="3"><animate id="b" fill="freeze" attributeName="opacity" begin="0;a.end-0.25s" dur="0.75s" values="1;.2"/></circle><circle cx="12" cy="12" r="3" opacity=".4"><animate fill="freeze" attributeName="opacity" begin="b.begin+0.15s" dur="0.75s" values="1;.2"/></circle><circle cx="20" cy="12" r="3" opacity=".3"><animate id="a" fill="freeze" attributeName="opacity" begin="b.begin+0.3s" dur="0.75s" values="1;.2"/></circle></svg>
@@ -15,6 +15,8 @@ declare class ShareComponent extends GirafeHTMLElement implements IGirafePanel {
15
15
  mailLogo: string;
16
16
  iframeUrl?: string;
17
17
  iframeCode?: string;
18
+ awaitingShareLink: boolean;
19
+ awaitingIframeUrl: boolean;
18
20
  private urlShortener?;
19
21
  private simpleMaskManager?;
20
22
  private readonly eventsCallbacks;
@@ -12,9 +12,9 @@ class ShareComponent extends GirafeHTMLElement {
12
12
  return uHtml `<style>
13
13
  *{font-family:Arial,sans-serif}.hidden{display:none!important}.gg-rotate90{transform:rotate(90deg)}.gg-rotate180{transform:rotate(180deg)}.gg-rotate270{transform:rotate(270deg)}img{filter:var(--svg-filter)}img.legend-image{filter:var(--svg-map-filter);background:var(--svg-legend-bkg)}div{scrollbar-width:thin}a,a:visited{color:var(--link-color)}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@keyframes spin-wait{0%{transform:rotate(0)}7%{transform:rotate(360deg)}to{transform:rotate(360deg)}}.gg-spin{animation-name:spin;animation-duration:2s;animation-timing-function:linear;animation-iteration-count:infinite}.gg-spin-wait{animation-name:spin-wait;animation-duration:10s;animation-timing-function:linear;animation-iteration-count:infinite}::-webkit-scrollbar{width:5px}::-webkit-scrollbar-thumb{background:#999}.gg-button,.gg-select,.gg-input,.gg-textarea{background-color:var(--bkg-color);color:var(--text-color);border:var(--app-standard-border);box-sizing:border-box;cursor:pointer;border-radius:3px;outline:0;margin:0;padding:0 0 0 .5rem;display:inline-block}.gg-label{background-color:var(--bkg-color);color:var(--text-color);border:none;align-items:center;margin:0;padding:0;display:flex}.gg-button,.gg-select,.gg-input,.gg-label{min-height:calc(var(--app-standard-height)/1.5)}.gg-textarea{max-height:initial;resize:vertical;height:6rem;padding:.5rem;line-height:1.3rem}.gg-input{cursor:text}.gg-checkbox{accent-color:var(--text-color);width:1.2rem}.gg-range{accent-color:var(--text-color)}.gg-button{padding:0 .5rem}.gg-button.active{border:solid 1px var(--text-color-grad2);background-color:var(--text-color-grad2);color:var(--bkg-color)}.gg-button:disabled{color:gray;cursor:not-allowed;background-color:#d3d3d3;border:none}.gg-input:disabled,.gg-select:disabled,.gg-textarea:disabled{color:gray;cursor:not-allowed;background-color:#d3d3d3}.gg-button>img{vertical-align:middle}.gg-icon-button{color:var(--text-color);cursor:pointer;background-color:#0000;border:none;flex-direction:column;justify-content:center;align-items:center;padding:0;display:flex}.gg-icon{justify-content:center;align-items:center;display:flex}.gg-big,.gg-big-withtext{min-width:var(--app-standard-height);min-height:var(--app-standard-height);max-height:var(--app-standard-height)}.gg-big img,.gg-big-withtext img{width:calc(var(--app-standard-height) - 1.5rem);margin:0}.gg-big-withtext span{font-variant:small-caps;padding:0 1rem;font-size:.9rem}.gg-medium,.gg-medium-withtext{min-width:calc(var(--app-standard-height)/1.2);min-height:calc(var(--app-standard-height)/1.2);max-height:calc(var(--app-standard-height)/1.2);flex-direction:row}.gg-medium img{width:calc(var(--app-standard-height)/2.4);margin:0}.gg-medium-withtext img{width:calc(var(--app-standard-height)/2.4);margin-left:.5rem}.gg-medium-withtext span{padding:0 1rem 0 .5rem;font-size:.9rem}.gg-small,.gg-small-withtext{min-width:calc(var(--app-standard-height)/2);min-height:calc(var(--app-standard-height)/2);max-height:calc(var(--app-standard-height)/2);flex-direction:row}.gg-small img{width:calc(var(--app-standard-height)/3);margin:0}.gg-small-withtext img{width:calc(var(--app-standard-height)/3);margin-left:.5rem}.gg-small-withtext span{padding:0 .5rem 0 .3rem;font-size:.9rem}.gg-button:hover,.gg-select:hover,.gg-input:hover,.gg-textarea:hover,.gg-icon-button:hover{background-color:var(--bkg-color-grad1)}.gg-opacity{opacity:.5}.gg-opacity:hover{opacity:1;background-color:#0000}.gg-tabs{cursor:pointer;grid-auto-flow:column;padding-bottom:1rem;font-size:1rem;display:grid}.gg-tab{border:none;border-bottom:var(--app-standard-border);cursor:pointer;color:var(--text-color);background:0 0;padding:.5rem}.gg-tab.active{border-bottom:solid 1px var(--text-color)}.girafe-button-big,.girafe-button-large,.girafe-button-small,.girafe-button-tiny{color:var(--text-color);background-color:#0000;border:none;flex-direction:column;display:flex}.girafe-button-big:hover,.girafe-button-large:hover,.girafe-button-small:hover,.girafe-button-tiny:hover{background-color:var(--bkg-color-grad1);cursor:pointer}.girafe-button-big.dark,.girafe-button-large.dark,.girafe-button-small.dark,.girafe-button-tiny.dark{background-color:var(--bkg-color);filter:invert()}.girafe-button-big{width:var(--app-standard-height);height:var(--app-standard-height);align-items:center;padding:1rem}.girafe-button-big img{overflow:hidden}.girafe-button-large{flex-direction:row}.girafe-button-large img{height:2rem;margin:.3rem}.girafe-button-large span{height:2rem;margin:.3rem;line-height:2rem}.girafe-button-small{min-width:calc(var(--app-standard-height)/2);height:calc(var(--app-standard-height)/2);align-items:center;padding:.5rem}.girafe-button-small img{overflow:hidden}.girafe-button-small span{text-align:left;text-overflow:ellipsis;width:100%;overflow:hidden}.girafe-button-tiny{align-items:center;width:1rem;height:1rem;padding:0}.girafe-button-tiny img{overflow:hidden}.girafe-onboarding-theme{background-color:var(--bkg-color)!important;color:var(--text-color)!important}.girafe-onboarding-theme button{background-color:var(--bkg-color)!important;color:var(--text-color)!important;text-shadow:none!important}.girafe-onboarding-theme button.driver-popover-close-btn{z-index:10000}
14
14
  </style><style>
15
- #content{background:var(--bkg-color);color:var(--text-color);margin:0;padding:1rem}.group{padding-bottom:4em}.title{margin-top:0}.link{flex-direction:column;gap:.2rem;margin-top:.5rem;display:flex}.qrcode{opacity:.7;width:10rem;margin:2rem auto auto;display:block}.social{display:flex}.social button{cursor:pointer;background-color:#0000;border:none;margin:2rem auto auto}.social img{opacity:.7;width:3rem;filter:var(--svg-filter)}.social img:hover{opacity:1}input{flex-grow:1;font-size:.9rem}.error{color:var(--error-color);text-align:center;order:3;width:90%}.textarea-for-code{font-family:monospace,Arial,sans-serif;font-size:.75rem;line-height:1.1rem}.copy-success,.copy-success:hover{background-color:var(--success-color)}.checkbox-wrapper{flex-direction:row;justify-content:space-between;align-items:center;height:2rem;display:flex;& input[type=checkbox]{flex-grow:unset}}
15
+ #content{background:var(--bkg-color);color:var(--text-color);margin:0;padding:1rem}.group{padding-bottom:4em}.title{margin-top:0}.link{flex-direction:column;gap:.2rem;margin-top:.5rem;display:flex;& button{padding-top:.25rem;padding-bottom:.25rem}}.qrcode{opacity:.7;width:10rem;margin:2rem auto auto;display:block}.qrcode-placeholder{content:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR42mNkYAAAAAYAAjCB0C8AAAAASUVORK5CYII=);width:10rem;height:10rem;margin:2rem auto auto;display:block}.social{display:flex}.social button{cursor:pointer;background-color:#0000;border:none;margin:2rem auto auto}.social img{opacity:.7;width:3rem;filter:var(--svg-filter)}.social img:hover{opacity:1}input{flex-grow:1;font-size:.9rem}.error{color:var(--error-color);text-align:center;order:3;width:90%}.textarea-for-code{font-family:monospace,Arial,sans-serif;font-size:.75rem;line-height:1.1rem}.copy-success,.copy-success:hover{background-color:var(--success-color)}.checkbox-wrapper{flex-direction:row;justify-content:space-between;align-items:center;height:2rem;display:flex;& input[type=checkbox]{flex-grow:unset}}.disabled{opacity:.25;pointer-events:none}.enabled{opacity:1;pointer-events:unset}.icon-loading{content:url(icons/3-dots-fade.svg)}.icon-copy{content:url(icons/content_copy.svg);margin:1px}
16
16
  </style>
17
- <div id="panel"><div id="content"><div class="${!this.urlShortener ? '' : 'hidden'}"><div class="message" i18n="Error, the shortener service is not defined.">Error, the shortener service is not defined.</div></div><div id="share-map" class="${this.urlShortener ? 'group' : 'hidden'}"><h3 class="title" i18n="Share this map">Share this map</h3><div><div class="link"><input value="${this.shareLink}" class="gg-input" disabled="disabled"> <button id="btn-copy-short" class="gg-button" i18n="Generate and copy link" onclick="${() => this.generateAndCopyLink()}">Generate and copy link</button></div></div><img alt="share-qrcode" class="${(this.qrCode ? 'qrcode' : 'hidden')}" src="${this.qrCode}"><div class="${(this.success ? 'hidden' : 'qrcode error')}"><img alt="error-icon" src="icons/error.svg"> <span i18n="Error, can not fetch the shortener service. Please try again later.">Error, can not fetch the shortener service. Please try again later.</span></div><div class="social"><button onclick="${() => this.shareFacebook()}"><img alt="share-facebook" src="${this.facebookLogo}"></button> <button onclick="${() => this.shareTwitter()}"><img alt="share-twitter" src="${this.twitterLogo}"></button> <button onclick="${() => this.shareLinkedIn()}"><img alt="share-linkedin" src="${this.linkedInLogo}"></button> <button onclick="${() => this.shareMail()}"><img alt="share-mail" src="${this.mailLogo}"></button></div></div><div id="embed-map" class="${this.urlShortener ? 'group' : 'hidden'}"><h3 class="title" i18n="Embed this map">Embed this map</h3><div class="link"><select class="gg-select" id="logLevel" onchange="${(evt) => this.onSizeChanged(evt)}"><option ?selected="${this.iframeSize === ''}" i18n="Select map size..." value="">Select map size...<option ?selected="${this.iframeSize === 'small'}" i18n="Small" value="small">Small<option ?selected="${this.iframeSize === 'medium'}" i18n="Medium" value="medium">Medium<option ?selected="${this.iframeSize === 'large'}" i18n="Large" value="large">Large</select><div class="checkbox-wrapper"><label for="iframe-search-visible" i18n="Search visible">Search visible</label> <input type="checkbox" class="gg-checkbox" id="iframe-search-visible" value="${this.shareState.searchComponentVisible}" onchange="${(e) => this.shareState.searchComponentVisible = e.target.checked}"></div><div class="checkbox-wrapper"><label for="iframe-basemap-visible" i18n="Basemap visible">Basemap visible</label> <input type="checkbox" class="gg-checkbox" id="iframe-basemap-visible" value="${this.shareState.basemapComponentVisible}" onchange="${(e) => this.shareState.basemapComponentVisible = e.target.checked}"></div><textarea value="${this.iframeCode}" class="gg-input gg-textarea textarea-for-code" disabled="disabled"></textarea> <button id="btn-copy-iframe" class="gg-button" i18n="Generate and copy code" ?disabled="${this.iframeSize === ''}" onclick="${() => this.generateAndCopyIframeCode()}">Generate and copy code</button></div></div></div></div>`;
17
+ <div id="panel"><div id="content"><div class="${!this.urlShortener ? '' : 'hidden'}"><div class="message" i18n="Error, the shortener service is not defined.">Error, the shortener service is not defined.</div></div><div id="share-map" class="${this.urlShortener ? 'group' : 'hidden'}"><h3 class="title" i18n="Share this map">Share this map</h3><div class="${this.awaitingShareLink ? 'disabled' : 'enabled'}"><div class="link"><input value="${this.shareLink}" class="gg-input" disabled="disabled"> <button id="btn-copy-short" class="gg-button" onclick="${() => this.generateAndCopyLink()}"><img alt="loading/copy" src="" class="${this.awaitingShareLink ? 'icon-loading' : 'icon-copy'}" width="20" height="20"> <span i18n="${this.awaitingShareLink ? 'Generating link' : (!this.shareLink ? 'Generate and copy link' : 'Copy to Clipboard')}"></span></button></div><img alt="share-qrcode" class="${(this.qrCode ? 'qrcode' : 'qrcode-placeholder')}" src="${this.qrCode}"><div class="${(this.success ? 'hidden' : 'qrcode error')}"><img alt="error-icon" src="icons/error.svg"> <span i18n="Error, can not fetch the shortener service. Please try again later.">Error, can not fetch the shortener service. Please try again later.</span></div><div class="social"><button onclick="${() => this.shareFacebook()}"><img alt="share-facebook" src="${this.facebookLogo}"></button> <button onclick="${() => this.shareTwitter()}"><img alt="share-twitter" src="${this.twitterLogo}"></button> <button onclick="${() => this.shareLinkedIn()}"><img alt="share-linkedin" src="${this.linkedInLogo}"></button> <button onclick="${() => this.shareMail()}"><img alt="share-mail" src="${this.mailLogo}"></button></div></div></div><div id="embed-map" class="${this.urlShortener ? 'group' : 'hidden'}"><h3 class="title" i18n="Embed this map">Embed this map</h3><div class="link"><select class="gg-select" id="logLevel" onchange="${(evt) => this.onSizeChanged(evt)}"><option ?selected="${this.iframeSize === ''}" i18n="Select map size..." value="">Select map size...<option ?selected="${this.iframeSize === 'small'}" i18n="Small" value="small">Small<option ?selected="${this.iframeSize === 'medium'}" i18n="Medium" value="medium">Medium<option ?selected="${this.iframeSize === 'large'}" i18n="Large" value="large">Large</select><div class="checkbox-wrapper"><label for="iframe-search-visible" i18n="Search visible">Search visible</label> <input type="checkbox" class="gg-checkbox" id="iframe-search-visible" value="${this.shareState.searchComponentVisible}" onchange="${(e) => this.shareState.searchComponentVisible = e.target.checked}"></div><div class="checkbox-wrapper"><label for="iframe-basemap-visible" i18n="Basemap visible">Basemap visible</label> <input type="checkbox" class="gg-checkbox" id="iframe-basemap-visible" value="${this.shareState.basemapComponentVisible}" onchange="${(e) => this.shareState.basemapComponentVisible = e.target.checked}"></div><textarea value="${this.iframeCode}" class="gg-input gg-textarea textarea-for-code" disabled="disabled"></textarea> <button id="btn-copy-iframe" class="gg-button" ?disabled="${this.iframeSize === ''}" onclick="${() => this.generateAndCopyIframeCode()}"><img alt="loading/copy" src="" class="${this.awaitingIframeUrl ? 'icon-loading' : 'icon-copy'}" width="20" height="20"> <span i18n="${this.awaitingIframeUrl ? 'Generating code' : 'Generate and copy code'}"></span></button></div></div></div></div>`;
18
18
  };
19
19
  isPanelVisible = false;
20
20
  panelTitle = 'share-panel';
@@ -28,6 +28,8 @@ class ShareComponent extends GirafeHTMLElement {
28
28
  mailLogo = MailLogo;
29
29
  iframeUrl;
30
30
  iframeCode;
31
+ awaitingShareLink = false;
32
+ awaitingIframeUrl = false;
31
33
  urlShortener;
32
34
  simpleMaskManager;
33
35
  eventsCallbacks = [];
@@ -93,6 +95,8 @@ class ShareComponent extends GirafeHTMLElement {
93
95
  this.simpleMaskManager = new SimpleMaskManager(this.context.mapManager.getMap());
94
96
  // While the component is visible, listen for changes in the state to update the shared link
95
97
  this.registerEvents();
98
+ // Generate the share link when the component is rendered (but don't copy to clipboard)
99
+ this.generateShareLink().then(() => this.refreshRender());
96
100
  }
97
101
  /**
98
102
  * Renders an empty component when it's not visible.
@@ -119,8 +123,15 @@ class ShareComponent extends GirafeHTMLElement {
119
123
  this.eventsCallbacks.length = 0;
120
124
  }
121
125
  async generateAndCopyLink() {
122
- await this.generateShareLink();
123
- this.copyToClipboard('short');
126
+ // If there's already a share link, just copy it to clipboard
127
+ if (this.shareLink) {
128
+ this.copyToClipboard('short');
129
+ }
130
+ else {
131
+ // Otherwise generate a new link and copy it
132
+ await this.generateShareLink();
133
+ this.copyToClipboard('short');
134
+ }
124
135
  this.refreshRender();
125
136
  }
126
137
  async generateAndCopyIframeCode() {
@@ -132,6 +143,8 @@ class ShareComponent extends GirafeHTMLElement {
132
143
  if (!this.urlShortener) {
133
144
  return;
134
145
  }
146
+ this.awaitingShareLink = true;
147
+ this.refreshRender();
135
148
  const baseUrl = this.context.urlManager.getBaseUrlPath();
136
149
  const hash = this.context.shareManager.getStateToShare();
137
150
  // Get short URL
@@ -140,11 +153,14 @@ class ShareComponent extends GirafeHTMLElement {
140
153
  this.shareLink = response.shorturl;
141
154
  this.success = response.success;
142
155
  this.qrCode = response.qrcode;
156
+ this.awaitingShareLink = false;
143
157
  }
144
158
  async generateIframeCode() {
145
159
  if (!this.urlShortener || !this.iframeSize) {
146
160
  return;
147
161
  }
162
+ this.awaitingIframeUrl = true;
163
+ this.refreshRender();
148
164
  const baseUrl = this.context.urlManager.getRootUrl();
149
165
  const hash = this.context.shareManager.getStateToShare();
150
166
  // Get short URL for iframe
@@ -153,6 +169,7 @@ class ShareComponent extends GirafeHTMLElement {
153
169
  const response = await this.urlShortener.shortenUrl(longIframeUrl, indexDocument);
154
170
  this.iframeUrl = response.shorturl;
155
171
  this.iframeCode = `<iframe title="iframe GeoGirafe" width="${this.iframeWidth}" height="${this.iframeHeight}" src="${this.iframeUrl}"></iframe>`;
172
+ this.awaitingIframeUrl = false;
156
173
  }
157
174
  closeWindow() {
158
175
  this.state.interface.sharePanelVisible = false;
package/package.json CHANGED
@@ -5,7 +5,7 @@
5
5
  "name": "GeoGirafe PSC",
6
6
  "url": "https://doc.geomapfish.dev"
7
7
  },
8
- "version": "1.1.0-dev.2334458755",
8
+ "version": "1.1.0-dev.2361375621",
9
9
  "type": "module",
10
10
  "engines": {
11
11
  "node": ">=20.19.0"
@@ -1 +1 @@
1
- {"version":"1.1.0-dev.2334458755", "build":"2334458755", "date":"18/02/2026"}
1
+ {"version":"1.1.0-dev.2361375621", "build":"2361375621", "date":"03/03/2026"}