Initial commit

This commit is contained in:
Vicky 2017-03-13 17:14:02 +08:00
parent 1f3201fa43
commit 6598cf34b0
31 changed files with 880 additions and 0 deletions

61
README.md Normal file
View file

@ -0,0 +1,61 @@
# Introduction theme for Hugo
A minimal, single page, smooth scrolling theme for Hugo.
Features:
* Single scrolling home page
* About and Contact sections
* Optional Projects and Blog sections
* Browser friendly CSS fade-in effect for some pizzaz
* Smooth scroll-to nav feature
* Responsive and fast
## Quick start
### Get the theme
From the root of your Hugo site:
```sh
$ cd themes
$ git clone https://github.com/vickylaixy/hugo-theme-introduction.git introduction
```
### Configure your site
From the exampleSite, copy `config.toml` to the root folder of your Hugo site and change the fields as you like.
Start with:
1. Set your baseurl
2. Set your full name and first name
3. Set your avatar image
4. Input your social site usernames
5. Choose whether or not to show the Blog and Projects sections, and configure them to your liking
### Create About and Contact pages
Run:
```
$ hugo new about.md
$ hugo new contact.md
```
Then edit the markdown files with the content you'd like shown in your main page's About and Contact sections.
## Preview your site locally
Use Hugo's built-in server to see your site in action as you make changes.
```
$ hugo -t introduction --watch serve
```
Visit `localhost:1313` in your browser to see a live preview of your site.
## Blog posts
To create a new blog post, run:
```
$ hugo new blog/your-post.md
```
## License
This theme is released under the [Creative Commons Attribution 3.0 license.](https://github.com/vickylaixy/hugo-theme-introduction/blob/master/LICENSE.md)

2
archetypes/default.md Normal file
View file

@ -0,0 +1,2 @@
+++
+++

60
exampleSite/config.toml Normal file
View file

@ -0,0 +1,60 @@
baseurl = "/"
languageCode = "en-us"
title = "My New Hugo Site"
theme = "introduction"
enforce_ssl = "your-url.com"
builddrafts = false
canonifyurls = true
contentdir = "content"
layoutdir = "layouts"
publishdir = "public"
# disqusshortname = "xxx" # Enable Disqus for comments
# googleAnalytics = "xxx"
[permalinks]
fixed = ":title/"
blog = "blog/:slug/"
[params]
author = "Author Name" # Full name shows on blog post pages
firstname = "Author" # First name shows in introduction on main page
tagline = "Welcome to my lovingly hand-coded portfolio page template." # Appears after the introduction
avatar = "img/profile.png" # Path to image in static folder eg. img/avatar.png
email = "youremail@email.com" # Shows in contact section, or leave blank to omit
dateform = "Jan 2, 2006"
dateformfull = "Mon Jan 2 2006 15:04:05 EST"
cachebuster = true # Add the current unix timestamp in query string for cache busting css assets
description = "Website Description"
faviconfile = "img/fav.ico"
highlightjs = true # Syntax highlighting
lang = "en"
footertext = "" # Text to show in footer (overrides default text)
# Social icons appear in introduction and contact section. Input your username only, eg "you" as it appears in "twitter.com/you"
linkedin = "you"
twitter = "you"
github = "you"
codepen = "you"
pinterest = ""
facebook = ""
googleplus = ""
showblog = true # Show Blog section on home page
showallposts = false # Set 'true' to list all posts on home page, or set 'false' to link to separate blog list page
showlatest = true # Show latest blog post summary
sharebuttons = true # On post pages, show share this social buttons
showprojects = true # Show Projects section on home page
# This is your projects section. Three images of the same dimensions will look the nicest. If images are omitted, text links will be shown.
project1link = "#"
project1img = "img/project1.jpg"
project1title = "Project 1"
project2link = "#"
project2img = "img/project2.jpg"
project2title = "Project 2"
project3link = "#"
project3img = "img/project3.jpg"
project3title = "Project 3"

View file

@ -0,0 +1,14 @@
+++
date = "2017-03-09T13:19:25+08:00"
draft = false
title = "about"
+++
This is your about me page. Use it to write up a witty and engaging description of yourself.
You can include your hobbies, favorite foods, photos of your ex-lovers, anything you like.
You can even include some ipsums:
Cat ipsum dolor sit amet, i cry and cry and cry unless you pet me, and then maybe i cry just for fun Gate keepers of hell for flop over sniff other cat's butt and hang jaw half open thereafter. Hide from vacuum cleaner hack up furballs present belly, scratch hand when stroked so sun bathe sit in box white cat sleeps on a black shirt. Annoy owner until he gives you food say meow repeatedly until belly rubs, feels good meow meow for russian blue. Lick the other cats chase laser lies down i like big cats and i can not lie. Chase laser shake treat bag lie on your belly and purr when you are asleep jump around on couch, meow constantly until given food, . Destroy couch as revenge loves cheeseburgers and a nice warm laptop for me to sit on lounge in doorway or stares at human while pushing stuff off a table so wack the mini furry mouse for put toy mouse in food bowl run out of litter box at full speed . Meow to be let in.

View file

@ -0,0 +1,13 @@
+++
date = "2017-03-12T11:55:32+08:00"
title = "Hipster Ipsum"
+++
Occupy mlkshk kale chips woke, listicle locavore next level fingerstache glossier aesthetic man braid before they sold out kitsch prism. Cred copper mug freegan, flannel YOLO single-origin coffee skateboard artisan four loko church-key man bun. Synth literally gastropub, kombucha chillwave helvetica offal truffaut church-key freegan pop-up gentrify narwhal. Kombucha viral vexillologist green juice. Slow-carb hoodie mumblecore tumeric tattooed meditation, lo-fi fap cred affogato forage whatever austin. Shabby chic direct trade migas, brunch gochujang sriracha chambray fanny pack 8-bit mustache letterpress. Street art umami tattooed, glossier selfies 90's kale chips cred cardigan taxidermy seitan distillery migas.
Chicharrones ethical activated charcoal cardigan vegan copper mug. Ennui messenger bag 90's street art art party etsy. Four loko freegan flannel flexitarian, slow-carb hot chicken vexillologist tote bag church-key tilde pinterest. Ethical hell of retro, mlkshk twee yr selfies asymmetrical venmo. Photo booth mixtape tattooed pop-up, synth flexitarian paleo. DIY cornhole sustainable, gochujang whatever slow-carb hexagon tilde. Bitters XOXO kombucha af.
Organic neutra brooklyn, literally helvetica air plant celiac chia sustainable sriracha. Jean shorts typewriter chambray 90's farm-to-table, man bun tofu VHS. Messenger bag paleo plaid meditation intelligentsia forage, lomo jianbing hell of. Waistcoat synth tacos direct trade truffaut kogi. Gentrify street art woke, everyday carry whatever gastropub PBR&B fixie chambray kale chips af photo booth shoreditch. Thundercats hella cold-pressed, ethical vape irony pitchfork mixtape kombucha heirloom viral hell of deep v banh mi hoodie. Craft beer slow-carb raw denim, ugh asymmetrical artisan banh mi fingerstache trust fund poke bespoke green juice man bun mustache 3 wolf moon.
Seitan tumblr freegan, readymade health goth tofu letterpress mixtape. Viral microdosing roof party, narwhal paleo photo booth cronut fingerstache. Bitters ramps snackwave listicle, taxidermy skateboard williamsburg. Vexillologist irony ennui, vegan fap 8-bit street art hashtag bicycle rights thundercats woke fashion axe aesthetic. Before they sold out umami forage disrupt, fashion axe cardigan ugh kitsch small batch. Kitsch try-hard vexillologist, semiotics disrupt shabby chic schlitz. Cardigan deep v hammock yuccie craft beer wayfarers, bespoke shabby chic keytar vape venmo semiotics iPhone cray.

View file

@ -0,0 +1,14 @@
+++
date = "2017-03-12T11:55:50+08:00"
title = "Coffee Ipsum"
author = "Best Author Ever"
+++
Aromatic aroma con panna, crema so coffee robust coffee barista, café au lait trifecta that strong blue mountain cortado aftertaste. Aroma extraction french press, skinny sweet, blue mountain cup roast barista, beans, extra cappuccino mug crema strong. Americano caffeine white, con panna saucer sit, con panna eu, carajillo aftertaste kopi-luwak, body aftertaste cup single origin café au lait saucer. Macchiato java sweet arabica, turkish cup, eu flavour mug extraction white cortado saucer est white brewed instant, rich, barista breve cappuccino barista organic. Barista, beans extraction, barista mocha, roast steamed siphon cup sweet cortado, cinnamon froth milk ristretto cortado galão. Crema, milk extra brewed, lungo dripper, espresso flavour qui, variety, grinder caramelization sit, strong turkish espresso body, filter barista caramelization half and half strong. To go viennese cream to go, flavour, so mocha as, carajillo iced et a siphon froth. Aged, eu, cup, brewed aroma kopi-luwak, coffee, id viennese french press brewed grounds acerbic froth. Decaffeinated acerbic, spoon beans seasonal, french press café au lait mazagran roast chicory, pumpkin spice galão as fair trade, dark irish cup ristretto half and half whipped shop. Latte instant black extra aroma, instant, extra robusta variety skinny shop aged cup ristretto foam cortado. Bar galão skinny saucer est affogato sugar caffeine chicory sugar coffee, seasonal barista french press acerbic in chicory robust.
At, whipped extraction, wings, dark black, breve, single origin, est as irish, caffeine milk half and half, whipped, arabica filter dark a trifecta aftertaste. Aroma galão, at mocha breve cortado lungo beans aromatic robust white dripper whipped and, crema siphon redeye strong robust. Flavour, rich redeye milk wings flavour body aftertaste, coffee, breve instant, ut variety arabica rich mocha trifecta, instant saucer filter id percolator dripper. Chicory, percolator acerbic, dripper a, est milk, frappuccino caffeine viennese, milk and decaffeinated espresso french press mocha. Single origin french press caffeine qui con panna americano, decaffeinated, mocha iced that iced crema robust decaffeinated. Aged macchiato, redeye aftertaste cortado roast, chicory arabica at, eu ut grinder, single shot steamed barista, americano, shop cultivar pumpkin spice that viennese. Ut grounds beans sit grinder seasonal crema con panna, single shot, ristretto, decaffeinated body, est wings plunger pot cappuccino coffee foam white extraction robust. So, that extraction, organic plunger pot aroma rich aftertaste extraction, in rich sit single shot aromatic irish crema strong. Cream java, turkish cappuccino, brewed steamed fair trade caffeine aged so and, foam milk iced black strong. Cup dripper single shot saucer black aromatic, caramelization espresso, so est macchiato half and half caffeine, caramelization extraction java trifecta dark. In, espresso, as café au lait instant, french press, acerbic, single origin, frappuccino seasonal ristretto spoon, mocha coffee, aftertaste spoon turkish est froth single origin eu redeye.
Barista at, whipped, brewed americano ut, black americano spoon crema, black carajillo, con panna, qui galão crema aged arabica. Cup half and half white, sugar, viennese, mocha to go single shot americano crema single origin sweet strong, pumpkin spice, flavour, rich steamed shop grinder steamed latte extra to go brewed. Frappuccino, variety a flavour rich, bar caffeine carajillo, caffeine, half and half brewed half and half that con panna single origin redeye. Roast percolator, beans kopi-luwak aftertaste ut, cup java, sweet, single origin affogato, eu espresso barista cortado trifecta ristretto to go aged cortado caramelization sweet. So variety wings sit roast acerbic a saucer, cream galão foam seasonal, instant, cinnamon beans macchiato mug steamed caffeine cappuccino. To go, frappuccino, body dripper aftertaste brewed spoon ristretto redeye, black dark, bar crema whipped wings macchiato, flavour, ut rich mocha variety filter aromatic. Ut instant single shot shop turkish and, grounds, latte half and half aged breve mug percolator shop. Macchiato, at cup single origin crema affogato, mug cup, eu et ristretto espresso, viennese froth beans variety to go. Coffee caffeine spoon, macchiato strong dripper crema, macchiato espresso blue mountain, chicory con panna white bar caffeine skinny trifecta con panna. Robust, mazagran latte to go, carajillo cinnamon at and trifecta, cream body variety instant id cream so extra. Ut as iced wings saucer caramelization, affogato, coffee, froth so, brewed acerbic iced shop in sweet brewed.
Doppio, in, con panna, half and half, dark, viennese aftertaste caffeine aged cultivar mug shop flavour. Spoon to go, doppio caffeine, a latte carajillo whipped, viennese grinder carajillo whipped dark grinder espresso coffee, espresso, variety café au lait aged half and half grounds. Mazagran as, kopi-luwak viennese, dark, sit aged id at, milk, to go cup sweet, shop coffee, spoon mazagran filter, doppio at extra cup milk. Chicory id roast chicory aromatic strong, white sweet viennese, carajillo java strong a to go aftertaste, frappuccino at cinnamon dripper pumpkin spice arabica. Aged, brewed percolator, id, macchiato aroma, black bar aromatic ristretto lungo as mug grinder as mocha. Mug, medium et roast doppio, spoon so single origin french press skinny, caffeine blue mountain variety, mocha, percolator grinder café au lait kopi-luwak arabica. Caffeine, seasonal, french press steamed rich single origin cream galão brewed cinnamon, doppio java, chicory aftertaste ristretto, plunger pot aromatic, ut, plunger pot milk est whipped grinder coffee. Sweet macchiato cappuccino cup, decaffeinated macchiato cream, milk extra, ut, galão froth half and half sweet qui, siphon, et aged, skinny, siphon milk grounds strong to go. Chicory medium, ut viennese instant fair trade steamed medium café au lait, as fair trade, barista single origin, body acerbic decaffeinated lungo café au lait bar trifecta americano mazagran. Strong cortado caffeine wings cappuccino foam, saucer est cream white aftertaste body french press. Beans affogato, ristretto a plunger pot bar macchiato, froth filter seasonal doppio, siphon sit caffeine cortado redeye single shot.

View file

@ -0,0 +1,18 @@
+++
date = "2017-03-12T11:55:43+08:00"
title = "Cheese Ipsum"
+++
Cow dolcelatte cheese and biscuits. Pepper jack caerphilly stilton cottage cheese airedale lancashire fromage frais chalk and cheese. Bocconcini fromage frais camembert de normandie fromage frais brie squirty cheese fromage frais fromage. Boursin boursin bocconcini stilton the big cheese cheese triangles pepper jack fromage. Croque monsieur.
```sh
$ complicated techie code git bash ubuntu
>>> return value init foo
```
Squirty cheese goat brie. Cheddar cheese triangles cheese strings camembert de normandie edam cow brie jarlsberg. Cream cheese cheese and biscuits cheese strings ricotta mozzarella bavarian bergkase boursin blue castello. Bocconcini smelly cheese cheesecake red leicester cheese triangles say cheese queso manchego. Bocconcini ricotta red leicester parmesan.
Dolcelatte smelly cheese stinking bishop. Manchego mascarpone fromage frais cheesy grin cheese slices camembert de normandie cauliflower cheese hard cheese. Roquefort cheese triangles melted cheese fondue roquefort feta pepper jack blue castello. Goat melted cheese blue castello hard cheese dolcelatte caerphilly cheddar pepper jack. Cheesy feet edam.
Cauliflower cheese cauliflower cheese ricotta. Bavarian bergkase stilton lancashire paneer goat manchego brie edam. Smelly cheese cheese slices emmental cheese triangles danish fontina the big cheese ricotta pecorino. Croque monsieur ricotta melted cheese.

View file

@ -0,0 +1,10 @@
+++
date = "2017-03-09T13:23:28+08:00"
draft = false
title = "contact"
+++
This is where you overcome your social anxiety and let people know how to reach you.
You could try linking to your [email](/), for instance. Just check it, okay?

View file

View file

View file

@ -0,0 +1,12 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
<title>My New Hugo Site</title>
<link>http://replace-this-with-your-hugo-site.com/</link>
<description>Recent content on My New Hugo Site</description>
<generator>Hugo -- gohugo.io</generator>
<language>en-us</language>
<atom:link href="http://replace-this-with-your-hugo-site.com/index.xml" rel="self" type="application/rss+xml" />
</channel>
</rss>

View file

@ -0,0 +1 @@
User-agent: *

View file

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<url>
<loc>http://replace-this-with-your-hugo-site.com/</loc>
<priority>0</priority>
</url>
</urlset>

BIN
exampleSite/static/img/fav.ico Executable file

Binary file not shown.

After

Width:  |  Height:  |  Size: 361 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 106 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 31 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 19 KiB

0
layouts/404.html Normal file
View file

View file

@ -0,0 +1,42 @@
{{ partial "header.html" . }}
<div class="container-fluid">
<div class="main">
<div class="list-head">
<h1 class="list-title fade-in one">Blog</h1>
<div class="fade-in two">
{{ if .Site.Params.showlatest }}
<h2 class="blog-header">Latest Post</h2>
{{ range first 1 .Data.Pages.ByPublishDate }}
<div class="summary">{{ .Date.Format .Site.Params.dateform }}
<h4><span style="font-weight: bold"><a href="{{ .RelPermalink }}">{{ .Title }}</a></span></h4>
{{ .Summary }}
{{ if .Truncated }}
<div class="read-more-link"><a href="{{ .RelPermalink }}">...Read More</a></div>
{{ end }}
{{ end }}
{{ end }}
<h2 class="blog-header">All Posts</div>
<ul>
{{ range .Data.Pages.ByPublishDate }}
{{ if eq .Section "blog" }}
{{ partial "li.html" . }}
{{ end }}
{{ end }}
</ul>
</div>
</div>
<div class="nav">
<hr>
<a href="/">Back to Main</a>
<hr>
</div>
{{ partial "footer.html" . }}
</div>
</div>

View file

@ -0,0 +1,12 @@
{{ partial "header.html" . }}
<section class="main">
<div class="container-fluid">
<div class="content">
{{ partial "page-heading.html" . }}
<div class="markdown">
{{ .Content }}
</div>
</div>
</div>
</section>
{{ partial "footer.html" . }}

58
layouts/blog/single.html Normal file
View file

@ -0,0 +1,58 @@
{{ partial "header.html" . }}
<div class="container-fluid">
<div class="main fade-in one">
<div class="blog-header">
<a href="{{ .Permalink }}">{{ .Title }}</a>
<div class="post-data">
{{ .Site.Params.author }} |
{{ .Date.Format .Site.Params.dateform }} |
{{ if eq 1 .ReadingTime }}{{ .ReadingTime }} minute read{{ else }}{{ .ReadingTime }} minutes read{{ end }}
</div>
{{ if .Site.Params.sharebuttons }}
<div class="blog-share">
Share this:
<a class="twitter-share-button" href="https://twitter.com/intent/tweet?text=Read%20{{ .Title }}%20{{ .Permalink }}"
onclick="window.open(this.href, 'twitter-share', 'width=550,height=235');return false;">
<i class="fa fa-twitter"></i>
<span class="hidden">Twitter</span>
</a>
<a class="icon-facebook" href="https://www.facebook.com/sharer/sharer.php?u={{ .Permalink }}"
onclick="window.open(this.href, 'facebook-share','width=580,height=296');return false;">
<i class="fa fa-facebook"></i>
<span class="hidden">Facebook</span>
</a>
<a class="icon-pinterest" href="http://pinterest.com/pin/create/button/?url={{ .Permalink }}{{ if .Params.pinterestmedia }}&amp;media={{ .Site.BaseURL }}{{ .Params.pinterestmedia }}{{ end }}&amp;description={{ .Title | safeHTML}}"
onclick="window.open(this.href, 'pinterest-share','width=580,height=296');return false;">
<i class="fa fa-pinterest"></i>
<span class="hidden">Pinterest</span>
</a>
<a class="icon-google-plus" href="https://plus.google.com/share?url={{ .Permalink }}"
onclick="window.open(this.href, 'google-plus-share', 'width=490,height=530');return false;">
<i class="fa fa-linkedin"></i>
<span class="hidden">Google+</span>
</a>
</div>
{{ end }}
</div>
<div class="markdown">
{{ .Content }}
</div>
<div class="nav">
<hr>
{{ if .Site.Params.showallposts }}
<a href="/#blog">Back to blog</a> | <a href="/">Main</a>
{{ else }}
<a href="/blog">Back to blog</a> | <a href="/">Main</a>
{{ end }}
<hr>
</div>
<div class="disqus">
{{ template "_internal/disqus.html" . }}
</div>
{{ partial "footer.html" . }}
</div>
</div>

114
layouts/index.html Normal file
View file

@ -0,0 +1,114 @@
<!--
Hey! Thanks for looking at my code! You win a cookie. :) The nice kind with chocolate chips.
This page was originally created for the Personal Portfolio Webpage challenge on FreeCodeCamp's Front End Development Certification course. It's totally responsive, and the first web page I ever coded from scratch.
Enjoy, and I hope you find what you're looking for! If you have questions or want to get in touch, please do: hello@vickylai.com.
-->
{{ partial "header.html" . }}
<div class="container-fluid" id="top">
<!-- Awesome content begins here! -->
<!-- Super sweet intro heading -->
<div class="pagehead">
<h1 class="fade-in one intro">Hi, I'm {{ .Site.Params.firstname }}.</h1>
<p class="fade-in two blurb">{{ .Site.Params.tagline }}</p>
</div>
<!-- End of intro heading -->
<div class="fade-in three container-fluid main">
<!-- Some social icons -->
{{ partial "social.html" . }}
<!-- End top social icons -->
<!-- Clean and simple nav section -->
<div class="nav">
<hr>
<a href="#about">About</a> |
{{ if .Site.Params.showprojects }}
<a href="#projects">Projects</a> |
{{ end }}
{{ if .Site.Params.showblog }}
<a href="#blog">Blog</a> |
{{ end }}
<a href="#contact">Contact</a>
<hr>
</div>
<!-- Done with nav section -->
<!-- Tell them all about it! -->
<div class="content" id="about">
<h2 class="section-head">About</h2>
<div class="row">
<div class="profile-pic col-md-offset-1 col-md-3"><img class="img-responsive" src="/{{ .Site.Params.avatar }}" alt="My profile picture." width="200px">
</div>
<div class="col-md-7">
{{ range .Data.Pages }}
{{if eq .Title "about" }}
{{.Content}}
{{end}}
{{ end }}
</div>
</div>
<div class="nav"><a href="#top"><i class="fa fa-arrow-up"></i></a></div>
</div>
<!-- End of About section -->
<hr>
<!-- Now for some cool projects -->
{{ if .Site.Params.showprojects }}
{{ partial "projects.html" . }}
<hr>
{{ end }}
<!-- Done with projects section -->
<!-- Let's show some blog posts -->
{{ if .Site.Params.showblog }}
{{ partial "blogsection.html" . }}
<hr>
{{ end }}
<!-- End of blog section -->
<!-- Let's chat, shall we? -->
<div class="content text-center" id="contact">
<h2 class="section-head">Contact</h2>
{{ range .Data.Pages }}
{{if eq .Title "contact" }}
{{.Content}}
{{end}}
{{ end }}
{{ if .Site.Params.email }}
<p class="highlight-text text-center"><a href="mailto:{{ .Site.Params.email }}">{{ .Site.Params.email }}</a></p>
{{ end }}
{{ partial "social.html" . }}
<div class="nav"><a href="#top"><i class="fa fa-arrow-up"></i></a></div>
</div>
<!-- End of Contact section -->
<hr>
<!-- Nice clean finish -->
{{ partial "footer.html" . }}
<!-- Footer done! -->
<!-- Awesome content ends here! -->
</div>
</div>
<!-- Cool scroll effect from this guy: https://gist.github.com/flesler/ -->
<!-- Include jQuery from somewhere, must use version 1.8 or above -->
<script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
<!-- Include latest jquery.scrollTo, can download from https://github.com/flesler/jquery.scrollTo/releases -->
<script type="text/javascript" src="//cdn.jsdelivr.net/jquery.scrollto/2.1.2/jquery.scrollTo.min.js"></script>
<!-- Initialize the plugin, the contents of the script can be inlined here, of course -->
<script type="text/javascript" src="js/init.js"></script>
<script>
// Bind to the click of all links with a #hash in the href
$('a[href^="#"]').click(function(e) {
// Prevent the jump and the #hash from appearing on the address bar
e.preventDefault();
// Scroll the window, stop any previous animation, stop on user manual scroll
// Check https://github.com/flesler/jquery.scrollTo for more customizability
$(window).stop(true).scrollTo(this.hash, {duration:500, interrupt:false});
});
</script>

View file

@ -0,0 +1,31 @@
<div class="content" id="blog">
{{ if .Site.Params.showlatest }}
<h2 class="section-head">Latest Post</h2>
{{ range first 1 .Data.Pages.ByPublishDate }}
<div class="summary">{{ .Date.Format .Site.Params.dateform }}
<h4><span style="font-weight: bold"><a href="{{ .RelPermalink }}">{{ .Title }}</a></span></h4>
{{ .Summary }}
{{ if .Truncated }}
<div class="read-more-link"><a href="{{ .RelPermalink }}">...Read More</a></div>
{{ end }}
</div>
{{ end }}
{{ end }}
{{ if .Site.Params.showallposts }}
<h2 class="section-head">All Posts</h2>
<div class="bloglist">
<ul>
{{ range .Data.Pages.ByPublishDate }}
{{ if eq .Section "blog" }}
{{ partial "li.html" . }}
{{ end }}
{{ end }}
</ul>
</div>
{{ else }}
<div class="nav"><a href="/blog">All Blog Posts</a></div>
{{ end }}
<div class="nav"><a href="#top"><i class="fa fa-arrow-up"></i></a></div>
</div>

View file

@ -0,0 +1,8 @@
<div class="content" id="footer">
{{ if .Site.Params.footertext }}
{{ .Site.Params.footertext }}
{{ else }}
<a href="#" target="_blank">Introduction</a> theme for <a href="#" target="_blank">Hugo</a>
</div>
{{ end }}

View file

@ -0,0 +1,91 @@
<!DOCTYPE html>
<html lang="{{ .Site.LanguageCode }}">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="chrome=1">
<meta name="HandheldFriendly" content="True">
<meta name="MobileOptimized" content="320">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="referrer" content="no-referrer">
{{ if .Site.Params.description }}<meta name="description" content="{{ .Site.Params.description }}">{{ end }}
<base href="{{ .Site.BaseURL }}">
<title>
{{ $url := replace .Permalink ( printf "%s" .Site.BaseURL) "" }}
{{ if eq $url "/" }}
{{ .Site.Title }}
{{ else }}
{{ if .Params.heading }} {{ .Params.heading }} {{ else }} {{ .Title }} {{ end }}
{{ end }}
</title>
<link rel="canonical" href="{{ .Permalink }}">
<!-- HTTPS -->
{{ if .Site.Params.forcehttps }}
<script type="text/javascript">
var baseURL = '{{ .Site.BaseURL }}';
var host = baseURL.substring(0, baseURL.length - 1).replace(/\//g, '');
if ((host === window.location.host) && (window.location.protocol !== 'https:')) {
window.location.protocol = 'https:';
}
</script>
{{ end }}
<!-- CSS -->
{{ if .Site.Params.highlightjs }}
<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.6.0/styles/default.min.css">
<script src="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.6.0/highlight.min.js"></script>
<script>hljs.initHighlightingOnLoad();</script>
{{ end }}
<!-- Fonts and icon CSS -->
<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/jquery-scrollTo/2.1.0/jquery.scrollTo.min.js">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/font-awesome/4.5.0/css/font-awesome.min.css">
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Open+Sans:400,700|Ubuntu+Mono:400,400i,700,700i|Raleway:500|Work+Sans">
{{ if .Site.Params.cachebuster }}
{{ $t := .Now.Unix }}
<link rel="stylesheet" href="/css/main.css?t={{$t}}">
{{range .Site.Params.extracssfiles}}
<link rel="stylesheet" href="{{.}}?t={{$t}}">
{{ end }}
{{ else }}
<link rel="stylesheet" href="/css/main.css">
{{range .Site.Params.extracssfiles}}
<link rel="stylesheet" href="{{.}}">
{{end}}
{{ end }}
<!-- Icon -->
<link rel="shortcut icon"
{{ if .Site.Params.faviconfile }}
href="/{{ .Site.Params.faviconfile }}"
{{ else }}
href="/img/favicon.ico"
{{ end }}
>
<!-- Google Analytics -->
{{ template "_internal/google_analytics_async.html" . }}
<!-- RSS -->
{{ if .RSSLink }}
<link href="{{ .RSSLink }}" rel="alternate" type="application/rss+xml" title="{{ .Site.Title }}" />
{{ end }}
<!--[if lt IE 9]>
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
</head>
<body lang="{{ .Site.Params.lang }}">

10
layouts/partials/li.html Normal file
View file

@ -0,0 +1,10 @@
<!--
<li class="post-item">
<div class="col-md-6 col-xs-6" style="text-align:right">{{ .Date.Format .Site.Params.dateform }}</div>
<div class="col-md-6 col-xs-6" style="text-align:left"><a href="{{ .Permalink }}">{{ .Title }}</div></a>
</li>
-->
<li class="post-item">
<span>{{ .Date.Format .Site.Params.dateform }}</span>
<span><a href="{{ .Permalink }}">{{ .Title }}</a></span>
</li>

View file

@ -0,0 +1,37 @@
<div class="content" id="projects">
<h2 class="section-head">Projects</h2>
<div class="row project-grid">
<div class="col-md-4 col-xs-12 text-center">
<a href="{{ .Site.Params.project1link }}" class="thumbnail">
{{ if .Site.Params.project1img }}
<img class="img-responsive" src="/{{ .Site.Params.project1img }}" alt="{{ .Site.Params.project1title }}">
</a>
{{ end }}
<a href="{{ .Site.Params.project1link }}" class="thumbnail">
<span class="project-title">{{ .Site.Params.project1title }}</span>
</a>
</div>
<div class="col-md-4 col-xs-12 text-center">
<a href="{{ .Site.Params.project2link }}" class="thumbnail">
{{ if .Site.Params.project2img }}
<img class="img-responsive" src="/{{ .Site.Params.project2img }}" alt="{{ .Site.Params.project2title }}">
</a>
{{ end }}
<a href="{{ .Site.Params.project1link }}" class="thumbnail">
<span class="project-title">{{ .Site.Params.project2title }}</span>
</a>
</div>
<div class="col-md-4 col-xs-12 text-center">
<a href="{{ .Site.Params.project3link }}" class="thumbnail">
{{ if .Site.Params.project3img }}
<img class="img-responsive" src="/{{ .Site.Params.project3img }}" alt="{{ .Site.Params.project3title }}">
</a>
{{ end }}
<a href="{{ .Site.Params.project1link }}" class="thumbnail">
<span class="project-title">{{ .Site.Params.project3title }}</span>
</a>
</div>
</div>
<div class="nav"><a href="#top"><i class="fa fa-arrow-up"></i></a></div>
</div>

View file

@ -0,0 +1,25 @@
<div class="social-icons row">
<div class="col-md-4 col-md-offset-4">
{{ if .Site.Params.twitter }}
<a href="https://twitter.com/{{ .Site.Params.twitter }}" target="_blank"><i class="fa fa-twitter"></i></a>
{{ end }}
{{ if .Site.Params.linkedin }}
<a href="https://linkedin.com/in/{{ .Site.Params.linkedin }}" target="_blank"><i class="fa fa-linkedin"></i></a>
{{ end }}
{{ if .Site.Params.github }}
<a href="https://github.com/{{ .Site.Params.github }}" target="_blank"><i class="fa fa-github"></i></a>
{{ end }}
{{ if .Site.Params.codepen }}
<a href="https://codepen.io/{{ .Site.Params.codepen }}" target="_blank"><i class="fa fa-codepen"></i></a>
{{ end }}
{{ if .Site.Params.pinterest }}
<a href="https://pinterest.com/{{ .Site.Params.pinterest }}" target="_blank"><i class="fa fa-pinterest"></i></a>
{{ end }}
{{ if .Site.Params.facebook }}
<a href="https://facebook.com/{{ .Site.Params.facebook }}" target="_blank"><i class="fa fa-facebook"></i></a>
{{ end }}
{{ if .Site.Params.googleplus }}
<a href="https://plus.google.com/+{{ .Site.Params.googleplus }}" target="_blank"><i class="fa fa-google-plus"></i></a>
{{ end }}
</div>
</div>

217
static/css/main.css Normal file
View file

@ -0,0 +1,217 @@
/* make keyframes that tell the start state and the end state of our object */
@-webkit-keyframes fadeIn { from { opacity:0; } to { opacity:1; } }
@-moz-keyframes fadeIn { from { opacity:0; } to { opacity:1; } }
@keyframes fadeIn { from { opacity:0; } to { opacity:1; } }
.fade-in {
opacity:0; /* make things invisible upon start */
-webkit-animation:fadeIn ease-in 1; /* call our keyframe named fadeIn, use animation ease-in and repeat it only 1 time */
-moz-animation:fadeIn ease-in 1;
animation:fadeIn ease-in 1;
-webkit-animation-fill-mode:forwards; /* this makes sure that after animation is done we remain at the last keyframe value (opacity: 1)*/
-moz-animation-fill-mode:forwards;
animation-fill-mode:forwards;
-webkit-animation-duration:1s;
-moz-animation-duration:1s;
animation-duration:1s;
}
.fade-in.one {
-webkit-animation-delay: 0.7s;
-moz-animation-delay: 0.7s;
animation-delay: 0.7s;
}
.fade-in.two {
-webkit-animation-delay: 1.4s;
-moz-animation-delay:1.4s;
animation-delay: 1.4s;
}
.fade-in.three {
-webkit-animation-delay: 1.8s;
-moz-animation-delay: 1.8s;
animation-delay: 1.8s;
}
body {
font-size: 14px;
font-family: 'Work Sans', sans-serif;
color: #666;
}
a {
color: #00b8d4;
}
a:hover {
color: #000;
font-style: none;
}
a:active {
color: #00b8d4;
}
h1 {
color: #222;
}
h2 {
color: #222;
}
hr {
}
ul {
padding: 0;
}
li {
display: block;
list-style: none;
list-style-position: outside;
margin-left: 0;
}
.test-border {
border: 1px solid #000;
}
.main {
padding: 0px 40px 40px 40px;
width: 80%;
margin: 0 auto;
float: center;
}
@media (max-width: 600px) {
.main {
padding: 0px 20px 20px 20px;
width: 100%;
margin: 0 auto;
float: center;
}
}
.nav {
text-align: center;
text-transform: uppercase;
margin: 5% 0 5% 0;
}
.content {
margin: 0em 0em 4em 0em;
padding: 20px;
}
.markdown {
}
.pagehead {
margin: 20% 20% 5% 20%;
text-align: center;
}
.list-head {
text-align: left;
margin: 20% 0 0 0;
}
.list-title {
font-size: 8em;
font-weight: bold;
margin-left: -10px;
}
@media (max-width: 550px) {
.list-title {
font-size: 3em;
font-weight:bold;
margin-left: 0;
}
}
.section-head {
font-size: 3em;
text-align: center;
margin: 1.5em 0em 1.5em 0em;
}
@media (max-width: 550px) {
.section-head {
font-size: 2em;
text-align: center;
margin: 1em 0em 1em 0em;
}
}
.profile-pic {
display: flex;
justify-content: center;
align-items: center;
padding: 20px;
}
.img-responsive {
border-radius: 5px;
}
.intro {
font-size: 8em;
font-weight: bold;
}
@media (max-width: 550px) {
.intro {
font-size: 3em;
font-weight:bold;
}
}
.blurb {
font-size: 2em;
text-align: center;
}
@media (max-width: 550px) {
.blurb {
font-size: 1em;
text-align: center;
}
}
.social-icons {
text-align: center;
font-size: 2em;
margin: 1em;
}
.highlight-text {
font-size: 2em;
margin: 0.8em 0em 0.5em 0em;
}
.project-grid {
padding: 1.2em 0em 0em 0em;
}
.project-title {
font-size: 1.5em;
font-weight: bold;
}
.thumbnail {
border: none;
}
.summary {
margin: 0 0 1.5em 0;
}
.bloglist {
text-align: center;
}
.blog-header {
margin: 10% 0 5% 0;
text-align: left;
font-size: 3em;
font-weight: bold;
}
@media (max-width: 550px) {
.blog-header {
margin: 10% 0 5% 0;
text-align: left;
font-size: 2em;
font-weight: bold;
}
}
.post-data {
font-size: 0.5em;
font-weight: normal;
}
.blog-share {
font-size: 0.3em;
font-weight: normal;
line-height: 2em;
}
#footer {
text-align: center;
color: #888;
padding: 2em;
}
#footer a {
color: #888;
}

21
theme.toml Normal file
View file

@ -0,0 +1,21 @@
# theme.toml template for a Hugo theme
# See https://github.com/spf13/hugoThemes#themetoml for an example
name = "Introduction"
license = "Creative Commons Attribution 3.0 Unported"
licenselink = "https://github.com/vickylaixy/hugo-theme-introduction/blob/master/LICENSE.md"
description = "Minimal, single page, smooth scrolling theme for Hugo."
homepage = "https://github.com/vickylaixy/hugo-theme-introduction"
tags = ["clean", "minimal"]
features = ["responsive", "single page"]
min_version = 0.15
[author]
name = "Vicky Lai"
homepage = "https://vickylai.com"
# If porting an existing theme
[original]
name = ""
homepage = ""
repo = ""