Come one, come all! Welcome to the Kingdom of Goatlings!
This is a simple (well, simple to me, I do think the code is more towards
intermediate) one-page shrine I made in memorial to Goatlings shutting down, and in
the process of making it, I thought I'd make it a template as well for others to
use; many people have been wanting to save their goats and all their collections in
some form or another, so hopefully this helps people who are a little more
savvy/want to learn HTML and CSS in the process.
I will say, this template does not take into account custom goat profiles and
treasures, it is more catered to showing your goats off in a list, and your gallery
collections.
Those who are brave can try their hand at making profiles, but this template is
currently not catered towards that. Those interested may want to check out
werewolf-girlfriend's gallery
template and how image popups work, or perhaps try their hand at making a tab
just for goat profiles, and have a little dropdown to swap which goat is
showing. If I end up doing that at any point for my own, I will return to update
this code OR offer an alternative that has it as it will be more complicated.
For what features this template has, check out the news tab above.
Colour variables + system-respecting dark mode colours, plus variables to easily
change your user icon, user colour, site background, active goat, and even the
site header
Focus elements + skip to content
A mobile friendly layout
Helper classes like .hide-mobile and .hide-desktop to
easily enable/disable mobile-specific and desktop-only things
Random HA buddies on the home page which change on refresh, you can add your own
HA buddy outfits to swap around (the current ones are the ones I used for an MM
submission), you can find them in ha-image-swap.js
I will now show you how to use the most common HTML text elements:
This is bold text.This is also bold text.This is italic text.This is also italic text.This is strikethrough text.This is underlined text.This is an internal link.This is a link that will open in a new tab.This is code (displayed in a monospace font).
This is an abbreviation (Try hovering over it).
This is highlighted text.
This is a line break (The br stands for break.): It's different from a
paragraph because it does not add space inbetween the lines of text.
This is a paragraph. As you can see, there's a bit of space between it and the
previous paragraph.
And this is a divider!
This is a blockquote. Blockquotes are indented text that usually quotes something,
or someone.
Profile Your Name
You could put in custom code here, or remove. This layout isn't catered to have
custom goat profiles, or tabs, sorry. If you're curious in making tabs for your
goats, you could do what I did for the tabs here (I used
W3 School's CSS tab guide).
Come one, come all! Welcome to the Kingdom of Goatlings!
This is a simple (well, simple to me, I do think the code is more towards
intermediate) one-page shrine I made in memorial to Goatlings shutting down, and in
the process of making it, I thought I'd make it a template as well for others to
use; many people have been wanting to save their goats and all their collections in
some form or another, so hopefully this helps people who are a little more
savvy/want to learn HTML and CSS in the process.
I will say, this template does not take into account custom goat profiles and
treasures, it is more catered to showing your goats off in a list, and your gallery
collections.
Those who are brave can try their hand at making profiles, but this template is
currently not catered towards that. Those interested may want to check out
werewolf-girlfriend's gallery
template and how image popups work, or perhaps try their hand at making a tab
just for goat profiles, and have a little dropdown to swap which goat is
showing. If I end up doing that at any point for my own, I will return to update
this code OR offer an alternative that has it as it will be more complicated.
For what features this template has, check out the news tab above.
Colour variables + system-respecting dark mode colours, plus variables to easily
change your user icon, user colour, site background, active goat, and even the
site header
Focus elements + skip to content
A mobile friendly layout
Helper classes like .hide-mobile and .hide-desktop to
easily enable/disable mobile-specific and desktop-only things
Random HA buddies on the home page which change on refresh, you can add your own
HA buddy outfits to swap around (the current ones are the ones I used for an MM
submission), you can find them in ha-image-swap.js
I will now show you how to use the most common HTML text elements:
This is bold text.This is also bold text.This is italic text.This is also italic text.This is strikethrough text.This is underlined text.This is an internal link.This is a link that will open in a new tab.This is code (displayed in a monospace font).
This is an abbreviation (Try hovering over it).
This is highlighted text.
This is a line break (The br stands for break.): It's different from a
paragraph because it does not add space inbetween the lines of text.
This is a paragraph. As you can see, there's a bit of space between it and the
previous paragraph.
And this is a divider!
This is a blockquote. Blockquotes are indented text that usually quotes something,
or someone.
Profile Your Name
div {
padding: 10px;
border-radius: 4px;
border: 1px solid var(--goat-outline);
max-width: calc(25% - 10px);
text-align: center;
}
.goat-container > div img {
max-width: 160px;
}
.fave-items,
.collection {
gap: 20px;
align-items: baseline;
flex-wrap: wrap;
}
.fave-items > div {
max-width: calc(20% - 20px);
min-width: 90px;
text-align: center;
}
.collection > div {
max-width: calc(100% / 7 - 20px);
min-width: 90px;
text-align: center;
}
/* -------------------------------------------------------- */
/* FOOTER */
/* -------------------------------------------------------- */
footer {
text-align: center;
padding: 20px;
font-size: 0.7em;
}
/* Inline Lists */
footer nav ul {
font-size: 1.3em;
padding: 0;
list-style: none;
margin-bottom: 10px;
}
footer nav li a {
font-weight: bold;
}
footer nav li {
display: inline;
line-height: 1.2em;
}
footer nav li:after {
content: " |";
}
footer nav li:first-child {
padding-left: 0;
}
footer nav li:last-child {
padding-right: 0;
}
footer nav li:last-child:after {
content: "";
margin-left: 0;
}
/* -------------------------------------------------------- */
/* ACCESSIBILITY, DO NOT REMOVE */
/* -------------------------------------------------------- */
#skip a {
position: absolute;
display: inline-block;
left: 0;
top: -1000px;
overflow: hidden;
transition: top 0.5s ease;
background: var(--content-bg);
color: var(--link);
z-index: 1000;
padding: 10px;
}
#skip a:focus {
top: 0;
transition: top 0.5s ease;
}
/* -------------------------------------------------------- */
/* MOBILE RESPONSIVENESS */
/* -------------------------------------------------------- */
@media screen and (max-width: 900px) {
#contentwrapper {
width: 95%;
}
#bodycontainer {
display: flex;
flex-direction: column;
}
.home {
display: block;
}
#bodycontainer nav {
display: flex;
gap: 10px;
}
#bodycontainer nav button,
#bodycontainer nav li,
#bodycontainer nav ul {
margin: 0;
}
.hide-mobile {
display: none;
}
#bodycontainer nav {
position: static;
}
}
// define your images here
var images = [
"https://i.ibb.co/5X2QTXRw/6.png",
"https://i.ibb.co/j9vg3X88/5.png",
"https://i.ibb.co/pBF36JpF/3.png",
"https://i.ibb.co/Rk1Z0nxM/1.png",
"https://i.ibb.co/qFcVFBJB/2.png",
"https://i.ibb.co/DDfRL1WN/4.png"
];
// this chooses a random number from all available image indices
var randomImage = images[Math.floor(Math.random() * images.length)];
console.log(randomImage);
// make the URL into a proper image tag
var image = "";
// append to the div
document.getElementById("ha-shuffle").innerHTML = image;
function openGoatTab(tabName) {
var i;
var x = document.getElementsByClassName("tabbed");
for (i = 0; i < x.length; i++) {
x[i].style.display = "none";
}
document.getElementById(tabName).style.display = "block";
}
let now = new Date();
let currentTime = now.toLocaleTimeString("en-US", {
hour: "2-digit",
minute: "2-digit",
second: "2-digit"
});
document.getElementById("timer").innerHTML = `Current Time: ${currentTime}`;
console.log(`Current Time: ${currentTime}`);
Goatlings
Come one, come all! Welcome to the Kingdom of Goatlings!
This is a simple (well, simple to me, I do think the code is more towards
intermediate) one-page shrine I made in memorial to Goatlings shutting down, and in
the process of making it, I thought I'd make it a template as well for others to
use; many people have been wanting to save their goats and all their collections in
some form or another, so hopefully this helps people who are a little more
savvy/want to learn HTML and CSS in the process.
I will say, this template does not take into account custom goat profiles and
treasures, it is more catered to showing your goats off in a list, and your gallery
collections.
Those who are brave can try their hand at making profiles, but this template is
currently not catered towards that. Those interested may want to check out
werewolf-girlfriend's gallery
template and how image popups work, or perhaps try their hand at making a tab
just for goat profiles, and have a little dropdown to swap which goat is
showing. If I end up doing that at any point for my own, I will return to update
this code OR offer an alternative that has it as it will be more complicated.
For what features this template has, check out the news tab above.
Colour variables + system-respecting dark mode colours, plus variables to easily
change your user icon, user colour, site background, active goat, and even the
site header
Focus elements + skip to content
A mobile friendly layout
Helper classes like .hide-mobile and .hide-desktop to
easily enable/disable mobile-specific and desktop-only things
Random HA buddies on the home page which change on refresh, you can add your own
HA buddy outfits to swap around (the current ones are the ones I used for an MM
submission), you can find them in ha-image-swap.js
I will now show you how to use the most common HTML text elements:
This is bold text.This is also bold text.This is italic text.This is also italic text.This is strikethrough text.This is underlined text.This is an internal link.This is a link that will open in a new tab.This is code (displayed in a monospace font).
This is an abbreviation (Try hovering over it).
This is highlighted text.
This is a line break (The br stands for break.): It's different from a
paragraph because it does not add space inbetween the lines of text.
This is a paragraph. As you can see, there's a bit of space between it and the
previous paragraph.
And this is a divider!
This is a blockquote. Blockquotes are indented text that usually quotes something,
or someone.
Profile Your Name
You could put in custom code here, or remove. This layout isn't catered to have
custom goat profiles, or tabs, sorry. If you're curious in making tabs for your
goats, you could do what I did for the tabs here (I used
W3 School's CSS tab guide).