Skip to content

Commit

Permalink
trying parallel testing
Browse files Browse the repository at this point in the history
  • Loading branch information
DivadNojnarg committed May 5, 2024
1 parent d1c8426 commit 3cd206a
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 8 deletions.
2 changes: 2 additions & 0 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -42,3 +42,5 @@ Suggests:
thematic
VignetteBuilder: knitr
Roxygen: list(markdown = TRUE)
Config/testthat/parallel: true
Config/testthat/edition: 3
8 changes: 4 additions & 4 deletions vignettes/shinyMobile-tools.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ library(bslib)

`{shinyMobile}` provides a set of tools specifically designed to help you develop user-friendly mobile applications and leverage certain actions on mobile phones. The tools we discuss here are:

- `preview_mobile`: a function to preview your app in a large range of mobile devices
- `preview_mobile()`: a function to preview your app in a large range of mobile devices
- `pullToRefresh`: a feature to refresh the page content by pulling from top to bottom
- Predefined input values to get information about the device and Shiny inputs

Expand All @@ -44,16 +44,16 @@ preview_mobile(url = "https://dgranjon.shinyapps.io/miniUI2DemoMd", device = "ip

The local preview is a 4 steps process:

- run `preview_mobile` with `appPath`
- run `preview_mobile()` with `appPath`
- Copy the returned code `R -e "shiny::runApp('appPath', port = 3838)"` in a terminal to launch the app
- Press enter to run the wrapper app
- Have fun!

`preview_mobile` has other options such as color and landscape (to preview in landscape mode).
`preview_mobile()` has other options such as color and landscape (to preview in landscape mode).

## Pull to Refresh

`{shinyMobile}` introduces the pull to refresh feature. It may be used to refresh the page content by pulling from top to bottom. This feature is disabled by default but passing `pullToRefresh = TRUE` in `f7Page` options will activate it. On the server side, an input, namely `input$ptr` is `TRUE` when ptr is refreshed and becomes `NULL` at the end of the animation (you may run the app below in full screen mode and hold a left click with your mouse from top to bottom):
`{shinyMobile}` introduces the pull to refresh feature. It may be used to refresh the page content by pulling from top to bottom. This feature is disabled by default but passing `pullToRefresh = TRUE` in `f7Page()` options will activate it. On the server side, an input, namely `input$ptr` is `TRUE` when ptr is refreshed and becomes `NULL` at the end of the animation (you may run the app below in full screen mode and hold a left click with your mouse from top to bottom):

```{r, eval=TRUE, echo=FALSE}
card(
Expand Down
8 changes: 4 additions & 4 deletions vignettes/shinyMobile.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ f7Page(
)
```

`f7Page()` accepts any of the following `{shinyMobile}` layouts: `f7SingleLayout`, `f7TabLayout`, `f7SplitLayout` or the experimental `f7MultiLayout`, which we will discuss further in the Layouts section.
`f7Page()` accepts any of the following `{shinyMobile}` layouts: `f7SingleLayout()`, `f7TabLayout()`, `f7SplitLayout()` or the experimental `f7MultiLayout()`, which we will discuss further in the Layouts section.

<br>

Expand Down Expand Up @@ -601,7 +601,7 @@ The main content goes in the __...__ parameter. Navigation items are gathered in

<br>

The `sidebar` is composed of `f7Panel()` with and `f7PanelMenu` and one or more `f7PanelItem()`:
The `sidebar` is composed of `f7Panel()` with and `f7PanelMenu()` and one or more `f7PanelItem()`:


```{r, eval=FALSE}
Expand Down Expand Up @@ -632,11 +632,11 @@ f7Panel(
Two important notes:

- Do not forget to allow the `leftPanel` in the navbar with `f7Navbar(leftPanel = TRUE)`!
- `f7Panel` has `side` set to `left`.
- `f7Panel()` has `side` set to `left`.

<br>

The __id__ argument in `f7PanelMenu` is important if you want to get the currently selected item or update the select tab. Each `f7PanelItem()` has a mandatory __tabName__. The associated input will be `input$menu` in that example, with `tab1` for value since the first tab was set to an active state. To adequately link the body and the sidebar, you must wrap the body content in `f7Items()` containing as many `f7Item()` as sidebar items. The __tabName__ must correspond.
The __id__ argument in `f7PanelMenu()` is important if you want to get the currently selected item or update the select tab. Each `f7PanelItem()` has a mandatory __tabName__. The associated input will be `input$menu` in that example, with `tab1` for value since the first tab was set to an active state. To adequately link the body and the sidebar, you must wrap the body content in `f7Items()` containing as many `f7Item()` as sidebar items. The __tabName__ must correspond.

```{r, eval=TRUE, echo=FALSE}
card(
Expand Down

0 comments on commit 3cd206a

Please sign in to comment.