Skip to content

Commit

Permalink
Updated
Browse files Browse the repository at this point in the history
- Changed minty-quarto-website to folium
- Changed fonts to Nunito and Fira Mono
- Removed R from demo and github actions
- Customized callouts with fontawesome icons
- Added badge, removed highlight
- Added back custom crossref text formatting
  • Loading branch information
royfrancis committed Dec 28, 2023
1 parent 3a77a31 commit b491c3b
Show file tree
Hide file tree
Showing 15 changed files with 682 additions and 739 deletions.
51 changes: 16 additions & 35 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,44 +3,25 @@ on:
push:
branches:
- main

jobs:
rmd-render-job:
strategy:
fail-fast: false
matrix:
config:
- {os: ubuntu-22.04, r: '4.1.0'}
runs-on: ${{ matrix.config.os }}
deploy:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v3
- name: Install linux dependencies
run: |
sudo apt-get update
sudo apt-get install libxml2-dev libssl-dev libcurl4-openssl-dev libudunits2-dev libopenblas-base libgdal-dev
- name: Setup R
uses: r-lib/actions/setup-r@v2
with:
r-version: ${{ matrix.config.r }}
- name: Cache R packages
id: cache-r-packages
uses: actions/cache@v3
with:
path: "/home/runner/work/_temp/Library"
key: ${{runner.os}}-${{matrix.r}}-$(ls /home/runner/work/_temp/Library/ | sha256sum)
- name: Install R packages
if: steps.cache-r-packages.outputs.cache-hit != 'true'
run: |
Rscript -e 'install.packages(c("dplyr", "tidyr", "stringr", "htmlTable", "kableExtra", "formattable", "DT", "reactable", "ggplot2", "rbokeh", "highcharter", "plotly", "ggiraph", "dygraphs", "networkD3", "leaflet", "crosstalk", "fontawesome", "knitr"), repos="https://cloud.r-project.org/")'
- name: Check out repo
uses: actions/checkout@v3
- name: Setup quarto
uses: quarto-dev/quarto-actions/setup@v2
with:
version: 1.3.433
- name: Render quarto
uses: quarto-dev/quarto-actions/render@v2
- name: Deploy
uses: JamesIves/github-pages-deploy-action@v4
tinytex: true
- run: |
quarto --version
- name: Render and publish
uses: quarto-dev/quarto-actions/publish@v2
with:
folder: docs
branch: gh-pages
token: ${{ secrets.TOKEN }}

target: gh-pages
render: true
env:
GITHUB_TOKEN: ${{ secrets.TOKEN }}
2 changes: 1 addition & 1 deletion .quartoignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ docs
**/*_files
reports/demo.qmd
reports/assets/featured.jpg
minty.png
folium.png
22 changes: 12 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
# minty <span><a href="https://github.com/royfrancis/minty-quarto-website"><img src="minty.png" style="height:40px;vertical-align:middle;"></a></span>
# folium <span><a href="https://github.com/royfrancis/folium"><img src="minty.png" style="height:40px;vertical-align:middle;"></a></span>

[![ci_badge](https://github.com/royfrancis/minty-quarto-website/workflows/deploy/badge.svg)](https://github.com/royfrancis/minty-quarto-website/actions?workflow=deploy) [![lifecycle_badge](https://lifecycle.r-lib.org/articles/figures/lifecycle-experimental.svg)](https://lifecycle.r-lib.org/articles/stages.html#experimental)
[![ci_badge](https://github.com/royfrancis/folium/workflows/deploy/badge.svg)](https://github.com/royfrancis/folium/actions?workflow=deploy) [![lifecycle_badge](https://lifecycle.r-lib.org/articles/figures/lifecycle-experimental.svg)](https://lifecycle.r-lib.org/articles/stages.html#experimental)

A quarto website template for project reports. For a single page template, see [minty-quarto-webpage](https://github.com/royfrancis/minty-quarto-webpage).
A quarto website template for project reports. For a single page template, see [folium-webpage](https://github.com/royfrancis/folium-webpage).

![](preview-a.png)
![](preview-a.jpg)

![](preview-b.png)
![](preview-b.jpg)

For a demo site, see [here](https://royfrancis.github.io/minty-quarto-website).
For a demo site, see [here](https://royfrancis.github.io/folium).

## Usage

- Required quarto 1.2.2 or higher
- Run in the terminal
- Required quarto 1.3.4 or higher
- To download a starter template, run in the terminal

```
quarto use template royfrancis/minty-quarto-website
quarto use template royfrancis/folium
```

- Launch preview in the browser
Expand All @@ -25,6 +25,8 @@ quarto use template royfrancis/minty-quarto-website
quarto preview
```

Note that preview will attempt to build all documents.

- Render all html files into `docs` directory

```
Expand Down Expand Up @@ -77,4 +79,4 @@ quarto render

---

2023 • Roy Francis
2024 • Roy Francis
14 changes: 10 additions & 4 deletions _quarto.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ nbis:

format:
html:
quarto-required: ">=1.2.2"
quarto-required: ">=1.3.4"
theme: "assets/css/custom.scss"
include-in-header: "assets/head.html"
smooth-scroll: true
Expand All @@ -58,7 +58,14 @@ format:
date-format: "DD-MMM-YYYY"
lightbox:
match: auto


crossref:
fig-title: "**Fig**"
fig-labels: arabic
tbl-title: "**Tab**"
tbl-labels: arabic
title-delim: "**:**"

knitr:
opts_chunk:
results: hold
Expand All @@ -73,5 +80,4 @@ execute:
filters:
- assets/custom.lua
- lightbox


- fontawesome
60 changes: 56 additions & 4 deletions assets/css/custom.scss
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,16 @@

/* colours, fonts, size ---------------------------------------------------------------------- */

@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono&family=Source+Sans+Pro:ital,wght@0,300;0,400;0,600;1,300;1,400;1,600&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Fira+Mono&family=Nunito:ital,wght@0,400;0,500;0,600;1,400;1,500;1,600&display=swap');

$primary: #95b540;
$secondary: #E9F2D1;
$link-color: #96b43f;
$body-color: #202020;
$code-color: #496985;
$code-block-bg: WhiteSmoke;
$font-family-sans-serif: 'Source Sans Pro', 'Helvetica', 'sans-serif' ;
$font-family-monospace: 'JetBrains Mono', 'Ubuntu Mono', 'Lucida Console', 'Courier', 'monospace';
$font-family-sans-serif: 'Nunito', 'Helvetica', 'sans-serif' ;
$font-family-monospace: 'Fira Mono', 'Ubuntu Mono', 'Liberation Mono', 'Lucida Console', 'Courier', 'monospace';
$font-size-root: 18px;
$code-font-size: 14px;
/* major second scale */
Expand Down Expand Up @@ -52,7 +53,17 @@ $presentation-h6-font-size: 1em;
.smaller { font-size: 0.64em;}
.smallest { font-size: 0.512em;}

.highlight {
.badge,
.badge-primary {
background-color: $primary;
color: white;
font-size: 0.85em;
padding: 0.2em 0.3em;
border-radius: 4px;
vertical-align: baseline;
}

.badge-secondary {
background-color: $secondary;
color: white;
font-size: 0.85em;
Expand Down Expand Up @@ -82,3 +93,44 @@ $presentation-h6-font-size: 1em;
object-fit: cover;
}

/* code */
pre {
background-color: $code-block-bg;
border-radius: 0.25rem;
}

code {
color: $code-color;
}
/* call-out */
.callout-style-default,
.callout-style-simple {
border: solid silver 1px !important;
}
div.callout-note.callout-style-default .callout-title {
background-color: $secondary;
}

div.callout-note .callout-icon::before {
background-image: url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGhlaWdodD0iMTYiIHdpZHRoPSIxNiIgZmlsbD0iIzFjMjgzMyIgdmlld0JveD0iMCAwIDUxMiA1MTIiPjwhLS0hRm9udCBBd2Vzb21lIEZyZWUgNi41LjEgYnkgQGZvbnRhd2Vzb21lIC0gaHR0cHM6Ly9mb250YXdlc29tZS5jb20gTGljZW5zZSAtIGh0dHBzOi8vZm9udGF3ZXNvbWUuY29tL2xpY2Vuc2UvZnJlZSBDb3B5cmlnaHQgMjAyMyBGb250aWNvbnMsIEluYy4tLT48cGF0aCBkPSJNMjU2IDUxMkEyNTYgMjU2IDAgMSAwIDI1NiAwYTI1NiAyNTYgMCAxIDAgMCA1MTJ6TTIxNiAzMzZoMjRWMjcySDIxNmMtMTMuMyAwLTI0LTEwLjctMjQtMjRzMTAuNy0yNCAyNC0yNGg0OGMxMy4zIDAgMjQgMTAuNyAyNCAyNHY4OGg4YzEzLjMgMCAyNCAxMC43IDI0IDI0cy0xMC43IDI0LTI0IDI0SDIxNmMtMTMuMyAwLTI0LTEwLjctMjQtMjRzMTAuNy0yNCAyNC0yNHptNDAtMjA4YTMyIDMyIDAgMSAxIDAgNjQgMzIgMzIgMCAxIDEgMC02NHoiLz48L3N2Zz4=') !important;
}

div.callout-tip .callout-icon::before {
background-image: url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGhlaWdodD0iMTYiIHdpZHRoPSIxMiIgZmlsbD0iIzFjMjgzMyIgdmlld0JveD0iMCAwIDM4NCA1MTIiPjwhLS0hRm9udCBBd2Vzb21lIEZyZWUgNi41LjEgYnkgQGZvbnRhd2Vzb21lIC0gaHR0cHM6Ly9mb250YXdlc29tZS5jb20gTGljZW5zZSAtIGh0dHBzOi8vZm9udGF3ZXNvbWUuY29tL2xpY2Vuc2UvZnJlZSBDb3B5cmlnaHQgMjAyMyBGb250aWNvbnMsIEluYy4tLT48cGF0aCBkPSJNMjcyIDM4NGM5LjYtMzEuOSAyOS41LTU5LjEgNDkuMi04Ni4ybDAgMGM1LjItNy4xIDEwLjQtMTQuMiAxNS40LTIxLjRjMTkuOC0yOC41IDMxLjQtNjMgMzEuNC0xMDAuM0MzNjggNzguOCAyODkuMiAwIDE5MiAwUzE2IDc4LjggMTYgMTc2YzAgMzcuMyAxMS42IDcxLjkgMzEuNCAxMDAuM2M1IDcuMiAxMC4yIDE0LjMgMTUuNCAyMS40bDAgMGMxOS44IDI3LjEgMzkuNyA1NC40IDQ5LjIgODYuMkgyNzJ6TTE5MiA1MTJjNDQuMiAwIDgwLTM1LjggODAtODBWNDE2SDExMnYxNmMwIDQ0LjIgMzUuOCA4MCA4MCA4MHpNMTEyIDE3NmMwIDguOC03LjIgMTYtMTYgMTZzLTE2LTcuMi0xNi0xNmMwLTYxLjkgNTAuMS0xMTIgMTEyLTExMmM4LjggMCAxNiA3LjIgMTYgMTZzLTcuMiAxNi0xNiAxNmMtNDQuMiAwLTgwIDM1LjgtODAgODB6Ii8+PC9zdmc+') !important;
}

div.callout-warning .callout-icon::before {
background-image: url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGhlaWdodD0iMTYiIHdpZHRoPSIxNiIgZmlsbD0iIzFjMjgzMyIgdml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LjItNDAuMWwyMTYtMzY4QzIyOC43IDM5LjUgMjQxLjggMzIgMjU2IDMyem0wIDEyOGMtMTMuMyAwLTI0IDEwLjctMjQgMjRWMjk2YzAgMTMuMyAxMC43IDI0IDI0IDI0czI0LTEwLjcgMjQtMjRWMTg0YzAtMTMuMy0xMC43LTI0LTI0LTI0em0zMiAyMjRhMzIgMzIgMCAxIDAgLTY0IDAgMzIgMzIgMCAxIDAgNjQgMHoiLz48L3N2Zz4=') !important;
}

.callout-caution .callout-icon-container {
padding-top: 0 !important;
}

div.callout-important .callout-icon::before {
background-image: url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGhlaWdodD0iMTYiIHdpZHRoPSIxNiIgZmlsbD0iIzFjMjgzMyIgdmlld0JveD0iMCAwIDUxMiA1MTIiPjwhLS0hRm9udCBBd2Vzb21lIEZyZWUgNi41LjEgYnkgQGZvbnRhd2Vzb21lIC0gaHR0cHM6Ly9mb250YXdlc29tZS5jb20gTGljZW5zZSAtIGh0dHBzOi8vZm9udGF3ZXNvbWUuY29tL2xpY2Vuc2UvZnJlZSBDb3B5cmlnaHQgMjAyMyBGb250aWNvbnMsIEluYy4tLT48cGF0aCBkPSJNNDE2IDM5OC45YzU4LjUtNDEuMSA5Ni0xMDQuMSA5Ni0xNzQuOUM1MTIgMTAwLjMgMzk3LjQgMCAyNTYgMFMwIDEwMC4zIDAgMjI0YzAgNzAuNyAzNy41IDEzMy44IDk2IDE3NC45YzAgLjQgMCAuNyAwIDEuMXY2NGMwIDI2LjUgMjEuNSA0OCA0OCA0OGg0OFY0NjRjMC04LjggNy4yLTE2IDE2LTE2czE2IDcuMiAxNiAxNnY0OGg2NFY0NjRjMC04LjggNy4yLTE2IDE2LTE2czE2IDcuMiAxNiAxNnY0OGg0OGMyNi41IDAgNDgtMjEuNSA0OC00OFY0MDBjMC0uNCAwLS43IDAtMS4xek05NiAyNTZhNjQgNjQgMCAxIDEgMTI4IDBBNjQgNjQgMCAxIDEgOTYgMjU2em0yNTYtNjRhNjQgNjQgMCAxIDEgMCAxMjggNjQgNjQgMCAxIDEgMC0xMjh6Ii8+PC9zdmc+') !important;
}
3 changes: 1 addition & 2 deletions assets/head.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
<meta name="robots" content="noindex">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=JetBrains+Mono&family=Source+Sans+Pro:ital,wght@0,300;0,400;0,600;1,300;1,400;1,600&display=swap" rel="stylesheet">

<link href="https://fonts.googleapis.com/css2?family=Fira+Mono&family=Nunito:ital,wght@0,400;0,500;0,600;1,400;1,500;1,600&display=swap" rel="stylesheet">
Binary file added folium.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed minty.png
Binary file not shown.
Binary file added preview-a.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed preview-a.png
Binary file not shown.
Binary file added preview-b.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed preview-b.png
Binary file not shown.
Binary file removed reports/assets/featured.jpg
Binary file not shown.
Binary file added reports/assets/image.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit b491c3b

Please sign in to comment.