aboutsummaryrefslogtreecommitdiffstats
path: root/scss/uikit/components/article.scss
diff options
context:
space:
mode:
authorGravatar Gareth Coles <[email protected]>2018-06-05 16:07:35 +0100
committerGravatar GitHub <[email protected]>2018-06-05 16:07:35 +0100
commit13a3c1e29473aa9f563e8db4ad94cb3eee9bdfe6 (patch)
tree290c6d668ec9161a39065456a33ec634215907cc /scss/uikit/components/article.scss
parentdocumentation metadata API (#57) (diff)
Move from CSS to SCSS (#86)
* Rewrite existing style.css with sass * Add "uses-rst" class for pages that use rendered RST This replaces the previous method of just listing every page in the sass * Remove old debug print * Mixins and error pages * Newly built CSS * Add SASS cache to .gitignore * New error SASS * Slight changes to error template * Add UIKit SCSS to repo This includes the LICENSE and our customizations, which makes life way easier for contributors * Reorganize sass folder; your watchers can avoid uikit now * Sass folder should be called scss * Change variable names * [SCSS] Linting * Fix scss_lint gem name [ci skip] * [SCSS] Now you can compile with just Python! * Temporary hack to make the wiki editor taller * [SCSS] @jchristgit * [SCSS.py] Require specification of include dir to simplify the SCSS imports * [SCSS] All inline styles have been removed * [SCSS] Update UIKit theme to import from our variables * [SCSS] Remove extra newlines in errors/_common.scss
Diffstat (limited to 'scss/uikit/components/article.scss')
-rw-r--r--scss/uikit/components/article.scss110
1 files changed, 110 insertions, 0 deletions
diff --git a/scss/uikit/components/article.scss b/scss/uikit/components/article.scss
new file mode 100644
index 00000000..3d4011f9
--- /dev/null
+++ b/scss/uikit/components/article.scss
@@ -0,0 +1,110 @@
+// Name: Article
+// Description: Component to create articles
+//
+// Component: `uk-article`
+//
+// Sub-objects: `uk-article-title`
+// `uk-article-meta`
+//
+// ========================================================================
+
+
+// Variables
+// ========================================================================
+
+$article-margin-top: $global-large-margin !default;
+
+$article-title-font-size-m: $global-xxlarge-font-size !default;
+$article-title-font-size: $article-title-font-size-m * 0.85 !default;
+$article-title-line-height: 1.2 !default;
+
+$article-meta-font-size: $global-small-font-size !default;
+$article-meta-line-height: 1.4 !default;
+$article-meta-color: $global-muted-color !default;
+
+
+/* ========================================================================
+ Component: Article
+ ========================================================================== */
+
+.uk-article {
+ @if(mixin-exists(hook-article)) {@include hook-article();}
+}
+
+/*
+ * Micro clearfix
+ */
+
+.uk-article::before,
+.uk-article::after {
+ content: "";
+ display: table;
+}
+
+.uk-article::after { clear: both; }
+
+/*
+ * Remove margin from the last-child
+ */
+
+.uk-article > :last-child { margin-bottom: 0; }
+
+
+/* Adjacent sibling
+ ========================================================================== */
+
+.uk-article + .uk-article {
+ margin-top: $article-margin-top;
+ @if(mixin-exists(hook-article-adjacent)) {@include hook-article-adjacent();}
+}
+
+
+/* Title
+ ========================================================================== */
+
+.uk-article-title {
+ font-size: $article-title-font-size;
+ line-height: $article-title-line-height;
+ @if(mixin-exists(hook-article-title)) {@include hook-article-title();}
+}
+
+/* Tablet landscape and bigger */
+@media (min-width: $breakpoint-medium) {
+
+ .uk-article-title { font-size: $article-title-font-size-m; }
+
+}
+
+
+/* Meta
+ ========================================================================== */
+
+.uk-article-meta {
+ font-size: $article-meta-font-size;
+ line-height: $article-meta-line-height;
+ color: $article-meta-color;
+ @if(mixin-exists(hook-article-meta)) {@include hook-article-meta();}
+}
+
+
+// Hooks
+// ========================================================================
+
+@if(mixin-exists(hook-article-misc)) {@include hook-article-misc();}
+
+// @mixin hook-article(){}
+// @mixin hook-article-adjacent(){}
+// @mixin hook-article-title(){}
+// @mixin hook-article-meta(){}
+// @mixin hook-article-misc(){}
+
+
+// Inverse
+// ========================================================================
+
+$inverse-article-meta-color: $inverse-global-muted-color !default;
+
+
+
+// @mixin hook-inverse-article-title(){}
+// @mixin hook-inverse-article-meta(){} \ No newline at end of file