summaryrefslogtreecommitdiff
path: root/assets/sass/components
diff options
context:
space:
mode:
authoraouvrard <antoine.ouvrard@nereide.fr>2018-02-04 19:13:13 +0100
committeraouvrard <antoine.ouvrard@nereide.fr>2018-02-04 19:13:13 +0100
commit9eee010f8fa93b1738be7b74e30174b170078e08 (patch)
treeb2e726953945a30632c0a654ae5e2e394ae80cfe /assets/sass/components
ajout su site en construction
Diffstat (limited to 'assets/sass/components')
-rw-r--r--assets/sass/components/_button.scss69
-rw-r--r--assets/sass/components/_form.scss181
-rw-r--r--assets/sass/components/_icon.scss21
-rw-r--r--assets/sass/components/_list.scss129
4 files changed, 400 insertions, 0 deletions
diff --git a/assets/sass/components/_button.scss b/assets/sass/components/_button.scss
new file mode 100644
index 0000000..c7499c9
--- /dev/null
+++ b/assets/sass/components/_button.scss
@@ -0,0 +1,69 @@
+@import '../libs/vars';
+@import '../libs/functions';
+@import '../libs/mixins';
+
+///
+/// Identity by HTML5 UP
+/// html5up.net | @ajlkn
+/// Free for personal and commercial use under the CCA 3.0 license (html5up.net/license)
+///
+
+/* Button */
+
+ input[type="submit"],
+ input[type="reset"],
+ input[type="button"],
+ button,
+ .button {
+ @include vendor('appearance', 'none');
+ @include vendor('transition', (
+ 'background-color #{_duration(transition)} ease-in-out',
+ 'border-color #{_duration(transition)} ease-in-out',
+ 'color #{_duration(transition)} ease-in-out'
+ ));
+ display: inline-block;
+ height: _size(element-height);
+ line-height: _size(element-height);
+ padding: 0 1.5em;
+ background-color: transparent;
+ border-radius: _size(border-radius);
+ border: solid 1px _palette(border);
+ color: _palette(fg) !important;
+ cursor: pointer;
+ text-align: center;
+ text-decoration: none;
+ white-space: nowrap;
+
+ &:hover {
+ border-color: _palette(highlight);
+ color: _palette(highlight) !important;
+ }
+
+ &.icon {
+ padding-left: 1.35em;
+
+ &:before {
+ margin-right: 0.5em;
+ }
+ }
+
+ &.fit {
+ display: block;
+ width: 100%;
+ margin: 0 0 (_size(element-margin) * 0.5) 0;
+ }
+
+ &.small {
+ font-size: 0.8em;
+ }
+
+ &.big {
+ font-size: 1.35em;
+ }
+
+ &.disabled,
+ &:disabled {
+ @include vendor('pointer-events', 'none');
+ opacity: 0.5;
+ }
+ } \ No newline at end of file
diff --git a/assets/sass/components/_form.scss b/assets/sass/components/_form.scss
new file mode 100644
index 0000000..5b1238e
--- /dev/null
+++ b/assets/sass/components/_form.scss
@@ -0,0 +1,181 @@
+@import '../libs/vars';
+@import '../libs/functions';
+@import '../libs/mixins';
+
+///
+/// Identity by HTML5 UP
+/// html5up.net | @ajlkn
+/// Free for personal and commercial use under the CCA 3.0 license (html5up.net/license)
+///
+
+/* Form */
+
+ form {
+ margin: 0 0 _size(element-margin) 0;
+
+ > .field {
+ margin: 0 0 _size(element-margin) 0;
+
+ > :last-child {
+ margin-bottom: 0;
+ }
+ }
+ }
+
+ label {
+ color: _palette(fg-bold);
+ display: block;
+ font-size: 0.9em;
+ margin: 0 0 (_size(element-margin) * 0.5) 0;
+ }
+
+ input[type="text"],
+ input[type="password"],
+ input[type="email"],
+ input[type="tel"],
+ select,
+ textarea {
+ @include vendor('appearance', 'none');
+ border-radius: _size(border-radius);
+ border: solid 1px _palette(border);
+ color: inherit;
+ display: block;
+ outline: 0;
+ padding: 0 1em;
+ text-decoration: none;
+ width: 100%;
+
+ &:invalid {
+ box-shadow: none;
+ }
+
+ &:focus {
+ border-color: _palette(highlight);
+ }
+ }
+
+ .select-wrapper {
+ @include icon('\f078');
+ display: block;
+ position: relative;
+
+ &:before {
+ color: _palette(border);
+ display: block;
+ height: _size(element-height);
+ line-height: _size(element-height);
+ pointer-events: none;
+ position: absolute;
+ right: 0;
+ text-align: center;
+ top: 0;
+ width: _size(element-height);
+ }
+
+ select::-ms-expand {
+ display: none;
+ }
+ }
+
+ input[type="text"],
+ input[type="password"],
+ input[type="email"],
+ select {
+ height: _size(element-height);
+ }
+
+ textarea {
+ padding: 0.75em 1em;
+ }
+
+ input[type="checkbox"],
+ input[type="radio"], {
+ @include vendor('appearance', 'none');
+ display: block;
+ float: left;
+ margin-right: -2em;
+ opacity: 0;
+ width: 1em;
+ z-index: -1;
+
+ & + label {
+ @include icon;
+ color: _palette(fg);
+ cursor: pointer;
+ display: inline-block;
+ font-size: 1em;
+ font-weight: _font(weight);
+ padding-left: (_size(element-height) * 0.6) + 0.75em;
+ padding-right: 0.75em;
+ position: relative;
+
+ &:before {
+ background: _palette(border-bg);
+ border-radius: _size(border-radius);
+ border: solid 1px _palette(border);
+ content: '';
+ display: inline-block;
+ height: (_size(element-height) * 0.6);
+ left: 0;
+ line-height: (_size(element-height) * 0.575);
+ position: absolute;
+ text-align: center;
+ top: 0.15em;
+ width: (_size(element-height) * 0.6);
+ }
+ }
+
+ &:checked + label {
+ &:before {
+ color: _palette(highlight);
+ content: '\f00c';
+ }
+ }
+
+ &:focus + label {
+ &:before {
+ border-color: _palette(highlight);
+ }
+ }
+ }
+
+ input[type="checkbox"] {
+ & + label {
+ &:before {
+ border-radius: _size(border-radius);
+ }
+ }
+ }
+
+ input[type="radio"] {
+ & + label {
+ &:before {
+ border-radius: 100%;
+ }
+ }
+ }
+
+ ::-webkit-input-placeholder {
+ color: _palette(fg-light) !important;
+ opacity: 1.0;
+ }
+
+ :-moz-placeholder {
+ color: _palette(fg-light) !important;
+ opacity: 1.0;
+ }
+
+ ::-moz-placeholder {
+ color: _palette(fg-light) !important;
+ opacity: 1.0;
+ }
+
+ :-ms-input-placeholder {
+ color: _palette(fg-light) !important;
+ opacity: 1.0;
+ }
+
+ .formerize-placeholder {
+ color: _palette(fg-light) !important;
+ opacity: 1.0;
+ } \ No newline at end of file
diff --git a/assets/sass/components/_icon.scss b/assets/sass/components/_icon.scss
new file mode 100644
index 0000000..13d22d2
--- /dev/null
+++ b/assets/sass/components/_icon.scss
@@ -0,0 +1,21 @@
+@import '../libs/vars';
+@import '../libs/functions';
+@import '../libs/mixins';
+
+///
+/// Identity by HTML5 UP
+/// html5up.net | @ajlkn
+/// Free for personal and commercial use under the CCA 3.0 license (html5up.net/license)
+///
+
+/* Icon */
+
+ .icon {
+ @include icon;
+ position: relative;
+ border-bottom: none;
+
+ > .label {
+ display: none;
+ }
+ } \ No newline at end of file
diff --git a/assets/sass/components/_list.scss b/assets/sass/components/_list.scss
new file mode 100644
index 0000000..d4aead9
--- /dev/null
+++ b/assets/sass/components/_list.scss
@@ -0,0 +1,129 @@
+@import '../libs/vars';
+@import '../libs/functions';
+@import '../libs/mixins';
+
+///
+/// Identity by HTML5 UP
+/// html5up.net | @ajlkn
+/// Free for personal and commercial use under the CCA 3.0 license (html5up.net/license)
+///
+
+/* List */
+
+ ol {
+ list-style: decimal;
+ margin: 0 0 _size(element-margin) 0;
+ padding-left: 1.25em;
+
+ li {
+ padding-left: 0.25em;
+ }
+ }
+
+ ul {
+ list-style: disc;
+ margin: 0 0 _size(element-margin) 0;
+ padding-left: 1em;
+
+ li {
+ padding-left: 0.5em;
+ }
+
+ &.alt {
+ list-style: none;
+ padding-left: 0;
+
+ li {
+ border-top: solid 1px _palette(border);
+ padding: 0.5em 0;
+
+ &:first-child {
+ border-top: 0;
+ padding-top: 0;
+ }
+ }
+ }
+
+ &.icons {
+ cursor: default;
+ list-style: none;
+ padding-left: 0;
+ margin-top: -0.675em;
+
+ li {
+ display: inline-block;
+ padding: 0.675em 0.5em;
+
+ a {
+ @include icon-alt(false, true);
+ position: relative;
+ display: block;
+ width: 3.75em;
+ height: 3.75em;
+ border-radius: 100%;
+ border: solid _size(border-width) _palette(border);
+ line-height: 3.75em;
+ overflow: hidden;
+ text-align: center;
+ text-indent: 3.75em;
+ white-space: nowrap;
+
+ &:before {
+ position: absolute;
+ top: 0;
+ left: 0;
+ width: inherit;
+ height: inherit;
+ font-size: 1.85rem;
+ line-height: inherit;
+ text-align: center;
+ text-indent: 0;
+ }
+
+ &:hover {
+ border-color: _palette(highlight);
+ }
+ }
+ }
+
+ @include breakpoint(xsmall) {
+ li {
+ a {
+ &:before {
+ font-size: 1.5rem;
+ }
+ }
+ }
+ }
+ }
+
+ &.actions {
+ cursor: default;
+ list-style: none;
+ padding-left: 0;
+
+ li {
+ display: inline-block;
+ padding: 0 (_size(element-margin) * 0.5) 0 0;
+ vertical-align: middle;
+
+ &:last-child {
+ padding-right: 0;
+ }
+ }
+ }
+ }
+
+ dl {
+ margin: 0 0 _size(element-margin) 0;
+
+ dt {
+ display: block;
+ font-weight: _font(weight-bold);
+ margin: 0 0 (_size(element-margin) * 0.5) 0;
+ }
+
+ dd {
+ margin-left: _size(element-margin);
+ }
+ } \ No newline at end of file