GithubHelp home page GithubHelp logo

keppelen / clay Goto Github PK

View Code? Open in Web Editor NEW

This project forked from liferay/clay

0.0 1.0 0.0 62.72 MB

Liferay's Lexicon Design Language

Home Page: https://liferay.github.io/clay

HTML 52.29% CSS 45.81% JavaScript 1.90%

clay's Introduction

Jump to Section

About

Clay is Liferay's web implementation of the Lexicon Design Language. It is built with HTML, CSS, and Javascript with Bootstrap as a foundation Bootstrap.

You can view the various components on the Clay site.

Building

If you would like to contribute, or make changes on your system you need to do the following:

Clone the repo

Clone the repo to your computer

Install Node.js (v4.6.0 LTS) and NPM

If you don't already have it installed. You can find more info here: http://nodejs.org/ Node and NPM come bundled together, so you only need to install one package.

Install the NPM modules

Run npm install inside of the clay directory

Modify files in src/

The files are generated from the src/ directory, however, most of the files you'd be interested in changing are in src/content/. Files can be either HTML (.html) or Markdown (.md). Every file in src/content/ has a heading at the top in YAML format that looks something like:

---
title: Title of the Page
---

This section has a couple of options that can be leveraged for different purposes. Those will be covered below.

Build the static files

Run gulp build to generate the static files.

View the files

The generated files are placed into the build/ directory. Sass files in the .scss format are generated to CSS, Markdown files with the extension of .md are generated to HTML, and HTML files have one bit of processing applied, which is that HTML inside of triple ticks is escaped, like so:

```
<div>Foo</div>
```

File Heading Options

There are a couple of properties you can add to the headings of files, only one of which is required:

title:: (Required) This is used for the title of the page in the heading and in the navigation sidebar

navIndex:: The navigation is sorted alphabetically by default, but if you pass a navIndex: property, it will manually sort the item into that position. The property is any number, with 0 as the first position, but you can also pass in a keyword of last to force an item to the end.

section:: If you want to group multiple files into sections, in each of those files, pass the same title to the section: property. That title will be used for the section heading, and the files will be sorted in there. The navIndex: property works inside of sections as well.

Available Build Tasks

You can pass these options when running gulp.

build: This is the default task, so running just gulp will fire off the build task. This will generate all of the HTML/CSS/etc into the build/ directory.

watch: Because running a script after every change can get tedious, run gulp watch to rebuild the files automatically as you change files.

serve: Starts a local server on port 3000 and also runs the watch task.

release: This task will create a zip file located in the root of the repo with the version number located in the package.json. We use this to deploy into Liferay.

toc: If you add a section to the README file, running gulp toc will generate a new table of contents.

Changelog

You can view the full changelog here.

clay's People

Contributors

pat270 avatar natecavanaugh avatar marcoscv-work avatar jbalsas avatar dustinryerson avatar drewbrokke avatar deyaeddin avatar gregory-bretall avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.