Windy Community
    • Unread
    • Categories
    • Groups
    • Go to windy.com
    • Register
    • Login

    Options goes transparents after Init

    Scheduled Pinned Locked Moved Bug Reports
    8 Posts 2 Posters 1.4k Views 1 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • S Offline
      sameh khemira
      last edited by

      Hello,
      I am using windy api in my angular web app ,I have followed tha basic hello world example and I have used the package "ngx-script-loader to load the libBoot.js script.
      Every thing is working but the zoom and the others options on the left side of the map are not visible as well as the logo of windy on the top?
      3036b236-e619-4352-a130-722a5450cd6d-image.png

      However I noticed that when the map is charging and it has the grey color on the backgroud, I can see them but once the map colors changed, they are not visible anymore.
      29896b4a-8f7b-4a7b-8352-a78b4976bed1-image.png

      SutyS 1 Reply Last reply Reply Quote 0
      • SutyS Offline
        Suty Windy Staff @sameh khemira
        last edited by

        @sameh-khemira Hi there, can you share the code of implementation, so I can forward it to colleagues?

        S 1 Reply Last reply Reply Quote 0
        • S Offline
          sameh khemira @Suty
          last edited by

          @Suty Hello I
          Here is the function where I load the libBoot using the script loader package

            initializeWindyMap(windyApiKey: string, lat: number, lon: number, zoom: number): Observable {
              const options = {
                key: windyApiKey, verbose: true, lat, lon, zoom,
              };
              return this.windyScriptLoaderService.loadScript('https://api.windy.com/assets/map-forecast/libBoot.js').pipe(switchMap(() => {
                return new Observable(observer => {
                  windyInit(options, windyAPI => {
                    this.map = windyAPI.map;
                    observer.next();
                    observer.complete();
                  });
                });
              }));
            }
          

          I do use this function in my angular compenent like this :

          this.mapService
                  .initializeWindyMap(
                    this.windyApiKey,
                    selectedRegion.center.lat,
                    selectedRegion.center.lon,
                    selectedRegion.zoom,
                  )
                  .subscribe(() => {
                  // treatment to process
                  });
          

          The map is displayed and initialized correctly each time. However, the map options are always not visible.
          Thank you

          SutyS 1 Reply Last reply Reply Quote 0
          • SutyS Offline
            Suty Windy Staff @sameh khemira
            last edited by

            @sameh-khemira Hi, you said that they are not visible. Did you check if they are not only visible, or they aren't there at all?

            It is possible that there is a certain collision with some of your elements and they are only hidden somewhere behind.

            S 1 Reply Last reply Reply Quote 0
            • S Offline
              sameh khemira @Suty
              last edited by

              @Suty the options are only visible at the beginning when the map is loading, as shown in this capture. I can see them when the background is grey. However, once the map finishes loading, the options become invisible
              33e95448-d409-47ef-9a43-14a9d19eace9-image.png
              I dont think there is other elements causing this issue in my html code .

              SutyS 1 Reply Last reply Reply Quote 0
              • SutyS Offline
                Suty Windy Staff @sameh khemira
                last edited by

                @sameh-khemira Okay and can you check that in the devtools?

                S 1 Reply Last reply Reply Quote 0
                • S Offline
                  sameh khemira @Suty
                  last edited by

                  @Suty
                  Yes I checked and I tried to only let the map in all the html component like this
                  < div id="windy" style="width: 95%; height: 85%; ">
                  And it is always the same problem

                  SutyS 1 Reply Last reply Reply Quote 0
                  • SutyS Offline
                    Suty Windy Staff @sameh khemira
                    last edited by

                    @sameh-khemira And z-index is not a problem, did you check that?

                    1 Reply Last reply Reply Quote 0
                    • First post
                      Last post
                    Windy Community  |  Powered by excellent NodeBB
                    Terms of Use     Privacy Policy     Windy.com