You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
plain-ui/examples/components.html

593 lines
20 KiB

3 years ago
<!doctype html>
<html lang="en_EN">
<head>
<meta charset="utf-8">
<meta http-equiv="x-ua-compatible" content="ie=edge">
3 years ago
<title>
Plain UI 0.5 | Simple UI Framework for Apps and Websites
3 years ago
</title>
3 years ago
<meta name="viewport" content="width=device-width,initial-scale=1">
<link rel="stylesheet" href="plain-ui.css">
</head>
<body class="overflow-x-hidden">
<header class="header">
<div class="bar">
<div class="bar__start">
<div class="m-top-4 m-bottom-4 h4">
3 years ago
Plain UI 0.5
</div>
</div>
<div class="bar__main justify-center">
<div class="tabs tabs--contrast">
<a href="index.html" class="tabs__item ">
Basics
</a>
<a href="components.html" class="tabs__item tabs__item--selected">
Components
</a>
<a href="layout.html" class="tabs__item ">
Layout
</a>
<a href="helpers.html" class="tabs__item ">
Helpers
</a>
</div>
</div>
3 years ago
</div>
</header>
<div class="container">
<div class="grid">
<div class="col-12">
<h1 class="highlight m-top-5 m-bottom-5">
Components
</h1>
<!-- -->
<h2>
Badge
</h2>
<span class="badge">
Category
</span>
<span class="badge badge--round">
99+
</span>
<!-- -->
<h2 class="m-top-5">
Bar
</h2>
<div class="bar">
<div class="bar__start">
<button class="button button--transparent">
<svg class="icon fill-text-contrast fill-text-hover marginless" aria-hidden="true">
<use xlink:href="symbol-defs.svg#icon-close"></use>
3 years ago
</svg>
</button>
</div>
<div class="bar__main">
Bar
3 years ago
</div>
</div>
3 years ago
3 years ago
<!-- -->
<h2 class="m-top-5">
Buttons
</h2>
<div>
<button class="button">
Default
</button>
<button class="button">
Icon
<svg class="icon fill-success" aria-hidden="true">
<use xlink:href="symbol-defs.svg#icon-check"></use>
</svg>
</button>
<button class="button button--selected">
Selected
</button>
<button class="button" disabled>
Disabled
</button>
</div>
<div>
<button class="button button--danger">
danger
</button>
<button class="button button--success">
success
</button>
<button class="button button--warning">
warning
</button>
<button class="button button--info">
info
3 years ago
</button>
</div>
3 years ago
<div>
<button class="button button--full">
full
</button>
<button class="button button--full button--danger">
danger
</button>
<button class="button button--full button--success">
success
</button>
<button class="button button--full button--warning">
warning
</button>
<button class="button button--full button--info">
info
</button>
</div>
3 years ago
<div>
<button class="button button--outline">
outline
</button>
</div>
<button class="button button--small">
Small
</button>
<!-- -->
<h2 class="m-top-5">
Field
</h2>
<div class="field-group">
<label class="field-label">
Name
<input class="field-text" />
</label>
</div>
<div class="field-group">
<label class="field-label">
Message
<textarea class="field-text"></textarea>
</label>
</div>
3 years ago
<div class="field-group field-group--valid">
<label class="field-label">
<svg class="icon" aria-hidden="true">
<use class="test" xlink:href="symbol-defs.svg#icon-check"></use>
</svg>
Surname
<input class="field-text" />
</label>
</div>
3 years ago
<div class="field-group field-group--error">
<label class="field-label">
<svg class="icon" aria-hidden="true">
<use class="test" xlink:href="symbol-defs.svg#icon-warning"></use>
</svg>
E-Mail
<input class="field-text" />
</label>
<span class="field-error">
String is not valid
</span>
</div>
3 years ago
<div class="field-group">
<label class="field-label">
Towns
<select class="field-choice">
<option></option>
<option value="lonytown">Lonytown</option>
</select>
</label>
</div>
3 years ago
<div class="field-group">
<label class="field-label">
<input class="field-choice" type="checkbox" value="true" />
<svg class="icon field-choice__unchecked" aria-hidden="true">
<use xlink:href="symbol-defs.svg#icon-checkbox"></use>
</svg>
<svg class="icon field-choice__checked" aria-hidden="true">
<use xlink:href="symbol-defs.svg#icon-checkbox-checked"></use>
</svg>
Checkbox
</label>
</div>
3 years ago
<div class="field-group">
<label class="field-label">
<input class="field-choice" type="radio" name="radio" value="true" />
<svg class="icon field-choice__unchecked" aria-hidden="true">
<use xlink:href="symbol-defs.svg#icon-circle"></use>
</svg>
<svg class="icon field-choice__checked" aria-hidden="true">
<use xlink:href="symbol-defs.svg#icon-circle-check"></use>
</svg>
Radio A
</label>
<label class="field-label">
<input class="field-choice" type="radio" name="radio" value="true" />
<svg class="icon field-choice__unchecked" aria-hidden="true">
<use xlink:href="symbol-defs.svg#icon-circle"></use>
</svg>
<svg class="icon field-choice__checked" aria-hidden="true">
<use xlink:href="symbol-defs.svg#icon-circle-check"></use>
</svg>
Radio B
</label>
</div>
3 years ago
<div class="field-group">
<label class="field-label">
<input class="field-choice" type="checkbox" name="radio" value="true" />
<span class="field-switch"></span>
</label>
</div>
3 years ago
3 years ago
<!-- -->
<h2 class="m-top-5">
Group
</h2>
<div class="group">
<div class="group__item background-color-primary color-text-contrast p-3">
One
</div>
<div class="group__item background-color-primary color-text-contrast p-3">
Two
3 years ago
</div>
</div>
</div>
3 years ago
</div>
</div>
<div class="container">
<div class="grid">
<div class="col-12">
<h2>
Hero
</h2>
3 years ago
</div>
3 years ago
</div>
</div>
<div class="hero">
<img style="max-height: 400px;" src="/image.jpg" />
</div>
<div class="container">
<div class="grid">
<div class="col-12">
<h2 class="m-top-5">
Icon
</h2>
<svg class="icon" aria-hidden="true">
<use xlink:href="symbol-defs.svg#icon-check"></use>
</svg>
<svg class="icon fill-danger" aria-hidden="true">
<use xlink:href="symbol-defs.svg#icon-camera"></use>
</svg>
<svg class="icon fill-success" aria-hidden="true">
<use xlink:href="symbol-defs.svg#icon-clock"></use>
</svg>
<!-- Loading -->
<h2 class="m-top-5">
Loading
</h2>
<div class="loading">
<span></span>
<span></span>
<span></span>
</div>
3 years ago
<h2 class="m-top-5">
Media
</h2>
<figure class="figure">
<img class="media" src="/image.jpg" />
<figcaption class="figure__caption">
food truck yr franzen pabst
</figcaption>
</figure>
<!-- modal -->
<h2 class="m-top-5">
Modal
</h2>
<button class="button" onclick="openModal()">
Click me!
</button>
<script type="text/javascript">
function openModal() {
document.querySelector('.modal').classList.add('modal--open')
}
function closeModal() {
document.querySelector('.modal').classList.remove('modal--open')
}
</script>
<div class="modal">
<div class="modal__inner">
<div class="modal__title t-center">
<svg class="icon fill-text-contrast" aria-hidden="true">
<use xlink:href="symbol-defs.svg#icon-close"></use>
</svg>
Delete
</div>
<div class="modal__body center">
Do you really wan't to delete all files?
</div>
<div class="modal__footer">
<button class="button button--outline button--danger" onclick="closeModal()">
Confirm
</button>
<button class="button button--outline float-right" onclick="closeModal()">
Reject
</button>
</div>
3 years ago
</div>
</div>
3 years ago
<!-- panel -->
<h2 class="m-top-5">
Panel
</h2>
<div class="panel">
<div class="bar">
<div class="bar__start">
<button type="button" class="button button--transparent">
<svg class="icon fill-text-contrast" aria-hidden="true">
<use xlink:href="symbol-defs.svg#icon-expand"></use>
</svg>
</button>
</div>
<div class="bar__main">Panel</div>
<div class="bar__end">
<button type="button" class="button button--transparent">
<svg class="icon fill-text-contrast" aria-hidden="true">
<use xlink:href="symbol-defs.svg#icon-edit"></use>
</svg>
</button>
<button type="button" class="button button--transparent">
3 years ago
<svg class="icon fill-text-contrast" aria-hidden="true">
3 years ago
<use xlink:href="symbol-defs.svg#icon-close"></use>
</svg>
</button>
3 years ago
</div>
</div>
<div class="panel__body">
<div class="content m-last-child-0">
<p>
Hallo
</p>
3 years ago
</div>
</div>
</div>
3 years ago
<!-- progress -->
<h2 class="m-top-5">
Progress
</h2>
<div class="progress">
<div class="progress__inner" style="width: 20%;"></div>
</div>
3 years ago
<!-- sidebar -->
<h2 class="m-top-5">
Sidebar
</h2>
<button class="button" onclick="openSidebar()">
Click me!
</button>
<script type="text/javascript">
function openSidebar() {
document.querySelector('.sidebar').classList.add('sidebar--open')
}
function closeSidebar() {
document.querySelector('.sidebar').classList.remove('sidebar--open')
}
</script>
<div class="sidebar">
<div class="sidebar__inner">
<div class="sidebar__body">
3 years ago
</div>
<div class="sidebar__footer">
<button type="button" class="button m-bottom-0" onclick="closeSidebar()">
Close
</button>
3 years ago
</div>
</div>
</div>
3 years ago
<!-- sidebar -->
<h2 class="m-top-5">
Sidebar + Bar
</h2>
<button class="button" onclick="openSidebarBar()">
Click me!
</button>
<script type="text/javascript">
function openSidebarBar() {
document.querySelector('#sidebar-bar').classList.add('sidebar--open')
}
function closeSidebarBar() {
document.querySelector('#sidebar-bar').classList.remove('sidebar--open')
}
</script>
<div id="sidebar-bar" class="sidebar">
<div class="sidebar__inner">
3 years ago
<div class="bar">
<div class="bar__main">
Sidebar
3 years ago
</div>
<div class="bar__end">
<button class="button button--transparent" type="button" onclick="closeSidebarBar()">
<svg class="icon fill-text-contrast" aria-hidden="true">
<use xlink:href="/symbol-defs.svg#icon-close"></use>
</svg>
3 years ago
</button>
</div>
</div>
<div class="sidebar__body">
</div>
<div class="sidebar__footer">
<button type="button" class="button m-bottom-0" onclick="closeSidebarBar()">
Close
</button>
</div>
3 years ago
</div>
</div>
<!-- table -->
<h2 class="m-top-5">
Table
</h2>
<table class="table table--striped table--hover">
<thead>
<tr class="table__tr">
<th class="table__th">A</th>
<th class="table__th">B</th>
<th class="table__th">C</th>
<th class="table__th">D</th>
</tr>
</thead>
<tbody>
<tr class="table__tr">
<td class="table__td">1</td>
<td class="table__td">2</td>
<td class="table__td">3</td>
<td class="table__td">4</td>
</tr>
<tr class="table__tr">
<td class="table__td">1</td>
<td class="table__td">2</td>
<td class="table__td">3</td>
<td class="table__td">4</td>
</tr>
<tr class="table__tr">
<td class="table__td">1</td>
<td class="table__td">2</td>
<td class="table__td">3</td>
<td class="table__td">4</td>
</tr>
</tbody>
</table>
<!--- tabs -->
<h2 class="m-top-5">
Tabs
</h2>
<div class="tabs">
<a class="tabs__item tabs__item--selected">
Tab A
</a>
<a class="tabs__item">
Tab B
</a>
<a class="tabs__item">
Tab C
</a>
</div>
<h2 class="m-top-5">
Tabs + Bar
</h2>
3 years ago
<div class="bar">
<div class="tabs tabs--contrast">
3 years ago
<a class="tabs__item tabs__item--selected">
Tab A
</a>
<a class="tabs__item">
Tab B
</a>
<a class="tabs__item">
Tab C
</a>
</div>
</div>
3 years ago
<!-- toast -->
<h2 class="m-top-5">
Toast
</h2>
<script type="text/javascript">
function addToast() {
document.querySelector('#toast').style.display = 'block'
setTimeout(function() {
document.querySelector('#toast .toast').classList.add('toast--animation')
}, 100)
}
function closeToast() {
setTimeout(function() {
document.querySelector('#toast').style.display = 'none'
}, 1000)
document.querySelector('#toast .toast').classList.remove('toast--animation')
}
</script>
<button class="button" onclick="addToast()">
Click me!
</button>
<div id="toast" class="toast-wrapper" style="display: none;">
<div class="toast toast--danger">
<div class="toast__icon">
<svg class="icon fill-text-contrast" aria-hidden="true">
<use xlink:href="/symbol-defs.svg#icon-warning"></use>
</svg>
3 years ago
</div>
<div class="toast__body">
Warning! Action not Working!
3 years ago
</div>
<button class="toast__button" onclick="closeToast()">
<svg class="icon fill-text-contrast" aria-hidden="true">
<use xlink:href="/symbol-defs.svg#icon-close"></use>
</svg>
</button>
3 years ago
</div>
3 years ago
</div>
3 years ago
</div>
</div>
</div>
3 years ago
3 years ago
<footer class="site-footer m-top-5">
<div class="bar">
<div class="bar__main">
3 years ago
</div>
</div>
3 years ago
</footer>
3 years ago
</body>
</html