gmi-web/js.gmi

67 lines
2.3 KiB
Plaintext
Raw Normal View History

2020-12-11 23:22:09 +00:00
# gmi.js
## an optional extension to gmi.css
=> /css/ gmi.css
* light/dark mode
* click to copy pre blocks
* inline images, audio and video
* themeable
```
<meta name="color-scheme" content="dark light">
2020-12-11 23:50:32 +00:00
<link rel="stylesheet" href="https://talon.computer/gmi.min.css"/>
<script src="https://talon.computer/gmi.min.js"></script>
2020-12-11 23:22:09 +00:00
<script>
window.gmi = new Gemini({ modes: true })
window.onload = () => window.gmi
.clickToCopy()
.inline({ images: true, audio: true, video: true })
.themes({
book: {
icon: "📖",
colors: ["#555555", "#fffceb"]
},
rose: {
icon: "🌹",
colors: ["#555555", "#ffdfdf"]
},
plant: {
icon: "🌱",
colors: ["#555555", "#9eebcf"]
},
ocean: {
icon: "🌊",
colors: ["#555555", "#96ccff"]
},
})
</script>
```
By default gmi.js will determine your theme based on the --foreground and --background CSS variables. You can supply your own themes using the object format shown above. I recommend using readable color palettes.
=> https://tachyons.io/docs/themes/skins/ Tachyons Color Schemes
### Download gmi.js today!
=> //talon.computer/gmi.js gmi.js
=> //talon.computer/gmi.min.js gmi.min.js
# inline examples
## images
=> https://www.learningcontainer.com/wp-content/uploads/2020/09/Sample-ICO-file-Download-for-testing.ico ICO
=> https://www.learningcontainer.com/wp-content/uploads/2020/07/sample-jpg-file-for-testing.jpg JPG
=> https://www.learningcontainer.com/wp-content/uploads/2020/08/Sample-PNG-File-for-Testing.png PNG
=> https://www.learningcontainer.com/wp-content/uploads/2020/08/Sample-SVG-Image-File-Download.svg SVG
=> https://www.learningcontainer.com/wp-content/uploads/2020/08/sample-webp-file-for-testing.webp WEBP
=> https://www.learningcontainer.com/wp-content/uploads/2020/09/Sample-gif-Image-File-Download.gif GIF
## audio
=> https://learn.esperanto.com/assets/ogg/01.ogg OGG
=> https://learn.esperanto.com/assets/mp3/01.mp3 MP3
## video
=> https://www.learningcontainer.com/wp-content/uploads/2020/05/sample-mp4-file.mp4 MP4
=> https://www.learningcontainer.com/wp-content/uploads/2020/05/sample-mov-file.mov MOV
=> https://www.learningcontainer.com/wp-content/uploads/2020/05/sample-webm-file.webm WEBM
=> https://www.learningcontainer.com/wp-content/uploads/2020/05/sample-ogv-file.ogv OGV
CC0