ParaGRIDma uses a very standard method to display grid (very similar to popular frameworks like bootstrap or foundation). It has some basic rules
container
row
column g-12
column g-11
1
column g-10
column g-2
column g-9
column g-3
column g-8
column g-4
column g-7
column g-5
column g-6
column g-6
column g-5
column g-7
column g-4
column g-8
column g-3
column g-9
column g-2
column g-10
10
column g-11
If you want to center a column you must add the class centered
to the column. You can also add class ac
to center text inside the column.
column g-8
centered
column g-6
centered
column g-4
centered
column g-2
centered
If we add the class np
to the columns we can remove its padding.
np
The grid allows for nesting down. You can create complex layouts using nesting columns
column g-4
column g-8
column g-4
column g-8
If you want to add a lot of columns, but you don't want to create a row element for each line you can simply add a class first
to the column in which you want to start a new row.
Sometimes we want to reduce the amount of columns in small screens, but don't want to show them 100% width. In those cases we can add the class split-on-mobile
on the row element.
@screen-smal
and @screen-medium
Sometimes we want to reduce the amount of columns in small screens, but don't want to show them 100% width. In those cases we can add the class split-on-mobile
on the row element.
@screen-smal
and @screen-medium
Those panels have two columns. One of them has a fixed width, and the other one is fluid.
Frameworks defualt values: 50px, 100px, 150px, 200px and 250px. You can create new sizes editing the css file. Look for the classes .pf
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed pulvinar fringilla risus, ac egestas augue laoreet a. Quisque varius ligula non est porta sit amet dictum orci consequat. Morbi pellentesque luctus ligula, sit amet vehicula sapien imperdiet a. Suspendisse sed lacus at eros tristique vehicula eget sit amet sem.
This is another option to use when you need one fixed column and one fluid column.
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed pulvinar fringilla risus, ac egestas augue laoreet a. Quisque varius ligula non est porta sit amet dictum orci consequat. Morbi pellentesque luctus ligula, sit amet vehicula sapien imperdiet a. Suspendisse sed lacus at eros tristique vehicula eget sit amet sem.
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed pulvinar fringilla risus, ac egestas augue laoreet a. Quisque varius ligula non est porta sit amet dictum orci consequat. Morbi pellentesque luctus ligula, sit amet vehicula sapien imperdiet a. Suspendisse sed lacus at eros tristique vehicula eget sit amet sem.
Some elements can be visible in some screen sizes and invisible in other. You can choose:
hide-on-phones
hide-on-tablets
hide-on-desktops
Typography is built with rems
, so it easier to adapt the font sizes in different breakpoints.
rem: It is the size relative to the root element (or the HTML element). So we can define a single font size on the html element and it affects to all elements with rem units to be a percentage of that.
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed imperdiet blandit nunc ut cursus. Integer viverra blandit erat, a feugiat dolor auctor ac. Proin tincidunt pulvinar velit, a tincidunt nisi semper eu.
Italic Text
<small>: Small text
<em>: Emphasys text
<strong>: Emphasys text
<pre>: text
link without underline class="nu"
Force uppercase text class="upper"
Force lowercase text class="lower"
<code>: text
Headings exists from h1
to h6
. Font sizes are defined in em
In addition to heading you can use add extra text. You can use the tag <small>
inside the heading
or add an adjacent heading with class subheader
Align text on left side. class="al"
Align text on center. class="ac"
Align text on right side. class="ar"
For headings and other big size text we need to adapt font-size in relation to display width. We can do this width media queries and width a javascript function call adjustTextSize
.
This function accept 3 parameters:
strings
: Elements to be resizedset_max_size
: boolean to limit maximum font size to its defined size in CSSmin_size
: Integer number to limit minimum font size.All elements with class js-adjust-text
will be adjusted
$('.js-adjust-text').adjustTextSize(false, 12);
$('.js-adjust-text-limit').adjustTextSize(true, 30);
You can choose between different types of lists: empty list (default), unordered lists, ordered lists, and definition lists. In default ul
lists we remove list styles, because in our apps most of times we don't want that our lists look like lists
<ul>
<ul class="discList">
<dl><dt>
<ol>
<ul class="squareList">
<ul class="horizontalList">
<ul class="circleList">
<ul class="horizontalList ac">
Other possible input types are: number
, color
, range
, datetime
, datetime-local
, date
, time
, week
, month
. more info here
<div class="fg checkboxGroup"> <label>Checkbox Group</label> <div class="options"> <div class="option"> <input type="checkbox" id="name" class="checkbox"> <label for="name">option 1</label> </div> <div class="option"> <input type="checkbox" id="name" class="checkbox"> <label for="name">option 2</label> </div> </div> </div>
<div class="fg radioGroup"> <label>Radio Group</label> <div class="options"> <div class="option"> <input type="radio" id="name" class="radio"> <label for="name">option 1</label> </div> <div class="option"> <input type="radio" id="name" class="radio"> <label for="name">option 2</label> </div> </div> </div>
It is possible to display field groups inline. To do it you only need to wrap your fields in a panel with class fh
Adding the class bt
to a link, submit button or button element make them look like buttons.
<a class="bt" href="#">Button</a>Small button:
bt_small
bt_large
db
Secundary button: bt_sub
Secundary Link Button
Main Action Link Button
Secundary button: disabled
Disable Main Action Link Button
Disable Secundary Link Button
States of buttons: bt_sub
bt_success
bt_danger
Default
Subordinate
Success
Danger
Button small with icon Button small with right icon
Button medium with icon Button medium with right icon
Button large with icon Button large with right icon
With this component it is possible to put a button next to a text field. The button has a fixed with, and the text field is responsive to fill its parent width. In the example we used a button with a width of 150 pixels, but you can expand the css to adapt it to you button desired width
msg_warning
:
msg_info
:
msg_success
:
msg_error
:
Lorem ipsum dolor sit amet
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed pulvinar fringilla risus.
Lorem ipsum dolor sit amet
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed pulvinar fringilla risus.
Lorem ipsum dolor sit amet
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed pulvinar fringilla risus.
Lorem ipsum dolor sit amet
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed pulvinar fringilla risus.
It is possible to show messages with a javascript function showMsg()
Click on the left side buttons to show the selected message panel
$(wrapper Selector).showMsg( size: big|small, type: warning|error|success|info, scroll to panel: 0|1, title: "Lorem ipsum", description: "Lorem ipsum dolor sit amet, consectetur..." );
TODO: Dialogs
This component give you the core styles and javascript functions to let you use tabs.
This component give you the core styles and javascript functions to let you use tables.
# | Lorem ipsum | dolor sit | Aliquam |
---|---|---|---|
1 | Vestibulum | auctor | dapibus |
2 | faucibus | tortor | eros |
3 | Morbi in sem quis dui placerat ornare. Pellentesque odio nisi, euismod in, pharetra a, ultricies in, diam. Sed arcu. Cras consequat. | Pellentesque | eleifend |
# | Lorem ipsum | dolor sit | Aliquam |
---|---|---|---|
1 | Vestibulum | auctor | dapibus |
2 | faucibus | tortor | eros |
3 | Morbi in sem quis dui placerat ornare. Pellentesque odio nisi, euismod in, pharetra a, ultricies in, diam. Sed arcu. Cras consequat. | Pellentesque | eleifend |
You can make your tables responsive just wrapping the table with a panel with the class table-responsive
.
In small widths the table will scroll horizontally
# | Lorem ipsum | dolor sit | Aliquam |
---|---|---|---|
1 | Vestibulum | auctor | dapibus |
2 | faucibus | tortor | eros |
3 | Morbi in sem quis dui placerat ornare. Pellentesque odio nisi, euismod in, pharetra a, ultricies in, diam. Sed arcu. Cras consequat. | Pellentesque | eleifend |
This is the default way to include an image.
Work in progress.
You can see it in this post.
We know several libraries that offer this feature, but none of them fix our needs completly. We need a solution that:
To resize the image we use the PHP script timthumb.php. To make it work you need:
make timthumb work with relative paths
This is the structure that Google recommens for a breadcrumbs
TODO: Tooltips
If your page needs to load an iframe from Youtube or Vimeo you'll notice that you have 2 problems: Page load time became much more slower and the iframe doesn't fix it's responsive parent size.
To make you iframe fits the desire width and height you hace to use this HTML structure and remove every iframe tag related to dimensions.
The problem with the page load time is that this kinds of iframe needs lots of resources to work fine. If we just embed one of those iframes the page will require al those Javascript and CSS, and our cool page'll became slower.
The solution that we use is to load the iframe only when the user want to see it (on user click).
At the moment it is only available to load video iframes from youTube and Vimeo.
To get more info abouit visit Font Awesome web site.
To increase icon sizes relative to their container, use the fa-lg
(33% increase), fa-2x
, fa-3x
, fa-4x
, or fa-5x
classes.
fa-camera-retro
fa-camera-retro
fa-camera-retro
fa-camera-retro
fa-camera-retro
fa-camera-retro
Use fa-fw
to set icons at a fixed width. Great to use when variable icon widths throw off alignment. Especially useful in things like nav lists.
To arbitrarily rotate and flip icons, use the fa-rotate-*
and fa-flip-*
classes.
Use fa-border
and pull-right
or pull-left
for easy pull quotes or article graphics.
Use a few styles together and you'll have easy pull quotes or a great introductory article icon.
Use a few styles together and you'll have easy pull quotes or a great introductory article icon.