Giter Site home page Giter Site logo

Comments (11)

bhaskarvk avatar bhaskarvk commented on June 11, 2024

Did you try passing allowfullscreen=TRUE in the frameOptions() function and pass that in the frameWidget() function?

from widgetframe.

bhaskarvk avatar bhaskarvk commented on June 11, 2024

And if you're using my leaflet.extras for adding the full screen control, try pseudoFullscreen=TRUE
https://bhaskarvk.github.io/leaflet.extras/reference/fullscreen.html

from widgetframe.

dmaupin12 avatar dmaupin12 commented on June 11, 2024

from widgetframe.

dmaupin12 avatar dmaupin12 commented on June 11, 2024

I tried the pseudoFullscreen=T option with no luck. Also, adding pseudoFullscreen=T makes the full screen button stop working for desktop as well.

from widgetframe.

bhaskarvk avatar bhaskarvk commented on June 11, 2024

Do you have a reproducible sample code I can look at ?

from widgetframe.

dmaupin12 avatar dmaupin12 commented on June 11, 2024

see code below.

library(leaflet)
library(leaflet.extras)
library(widgetframe)
library(tidyverse)

longitude<-c(-103.551700, -103.534886)
latitude<- c(31.318153, 31.149694)

ex<- data.frame(longitude,latitude)

map1<-leaflet() %>%
  addProviderTiles(providers$Esri.WorldTopoMap, group = "Esri.WorldTopoMap" )%>%
  addCircleMarkers(data=ex,~longitude,~latitude)


map1<-map1 %>% setView(map1,lng=-103.5517, lat=31.318, zoom=10)
 
map1<-map1%>% addScaleBar(position="topleft")

frameWidget(map1 %>% addFullscreenControl(),
    height= 450, width= '95%',options=frameOptions(allowfullscreen = T))

frameWidget(map1 %>% addFullscreenControl(pseudoFullscreen=T),
    height= 450, width= '95%',options=frameOptions(allowfullscreen = T))

from widgetframe.

bhaskarvk avatar bhaskarvk commented on June 11, 2024

I changed your code slightly, could you verify again if both the framed widgets don't work in iPhone.

from widgetframe.

dmaupin12 avatar dmaupin12 commented on June 11, 2024

No luck, I'm using Tranquil theme in blogdown. Could that be the issue?
To clarify, the leaflet map appears, however the fullscreen button does not work like it does without the widget.

from widgetframe.

bhaskarvk avatar bhaskarvk commented on June 11, 2024

Nah I don't think the theme matters coz the widgets are loaded inside an iframe and thus unaffected by the theme. It could be the specific case of iPhone browser in which case it might be hard to fix. I'll give you some pure HTML samples to tryout next week, just to rule out R/widgetframe part. But I am almost certain this is a browser specific issue.

from widgetframe.

dmaupin12 avatar dmaupin12 commented on June 11, 2024

I think i found a solution! All i needed to do was add in width=100%. I haven't tired it with widgetframe, but it works correctly without it. I can't believe i didn't try this sooner.

map1<-leaflet(width='100%')

from widgetframe.

bhaskarvk avatar bhaskarvk commented on June 11, 2024

Closing as this is an edge case bug probably in the iPhone browser which might not be fixable on widgetframe side.

from widgetframe.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.