From e559707f89af47bd2e6c6b03c6af434c467ac5f5 Mon Sep 17 00:00:00 2001 From: jlukic Date: Tue, 23 Sep 2014 11:29:31 -0400 Subject: [PATCH] Rework card to be more neutral base theme, add GitHub theme. Fix list selection spacing --- .../packages/default/elements/list.variables | 2 +- .../packages/default/views/card.variables | 8 +- .../packages/github/views/card.overrides | 98 +++++++++++++++++++ .../packages/github/views/card.variables | 22 +++++ 4 files changed, 125 insertions(+), 5 deletions(-) create mode 100755 src/themes/packages/github/views/card.overrides create mode 100755 src/themes/packages/github/views/card.variables diff --git a/src/themes/packages/default/elements/list.variables b/src/themes/packages/default/elements/list.variables index e3dc5eb0b..8b1b31889 100755 --- a/src/themes/packages/default/elements/list.variables +++ b/src/themes/packages/default/elements/list.variables @@ -100,7 +100,7 @@ @invertedLinkListItemActiveColor: @invertedSelectedTextColor; /* Selection List */ -@selectionListItemMargin: 0em 0em 0.3em 0em; +@selectionListItemMargin: 0em; @selectionListItemBorderRadius: 0.5em; @selectionListItemVerticalPadding: 0.5em; @selectionListItemHorizontalPadding: 0.5em; diff --git a/src/themes/packages/default/views/card.variables b/src/themes/packages/default/views/card.variables index 16200a581..715baba6e 100755 --- a/src/themes/packages/default/views/card.variables +++ b/src/themes/packages/default/views/card.variables @@ -7,7 +7,7 @@ --------------------*/ /* Shadow */ -@shadowDistance: 0em; +@shadowDistance: 0.2em; @shadowBoxShadow: 0px @shadowDistance 0px 0px @solidBorderColor; /* Item */ @@ -16,7 +16,7 @@ @display: block; @margin: 1em 0em; @minHeight: 0px; -@padding: 0em; +@padding: 0.5em; @width: 290px; @borderWidth: 1px; @borderShadow: 0px 0px 0px @borderWidth @solidBorderColor; @@ -103,13 +103,13 @@ /* Additional Content */ @extraDivider: 1px solid rgba(0, 0, 0, 0.05); -@extraBackground: #FAFAFA @subtleGradient; +@extraBackground: none; @extraPosition: static; @extraTop: 0em; @extraLeft: 0em; @extraWidth: 100%; @extraPadding: 0.75em 1em; -@extraBoxShadow: 0 1px 1px rgba(0, 0, 0, 0.15); +@extraBoxShadow: none; @extraColor: @lightTextColor; @extraTransition: color @transitionDuration @transitionEasing; diff --git a/src/themes/packages/github/views/card.overrides b/src/themes/packages/github/views/card.overrides new file mode 100755 index 000000000..8132fa045 --- /dev/null +++ b/src/themes/packages/github/views/card.overrides @@ -0,0 +1,98 @@ +/******************************* + Item +*******************************/ +/*------------------- + View +--------------------*/ + +/* Item */ +@background: #FFFFFF; +@borderRadius: 0.325rem; +@display: block; +@float: left; +@margin: 0em @horizontalSpacing @rowSpacing; +@minHeight: 0px; +@padding: 0em; +@width: 300px; +@boxShadow: + 0px 0px 0px 1px @borderColor, + 0px 3px 0px 0px @borderColor +; +@border: none; +@zIndex: ''; + +/* Item Group */ +@horizontalSpacing: 0.5em; +@rowSpacing: 2.5em; +@groupMargin: 1em -@horizontalSpacing; + +/*------------------- + Content +--------------------*/ + +/* Image */ +@imageBackground: @transparentBlack; +@imagePadding: 0em; +@imageBorderRadius: @borderRadius @borderRadius 0em 0em; +@imageBoxShadow: none; +@imageBorder: none; + +/* Content */ +@contentMargin: 0em; +@contentPadding: 0.75em 1em; +@contentFontSize: 1em; +@contentBorder: none; +@contentBorderRadius: 0em; +@contentBoxShadow: none; + +/* Title */ +@titleMargin: 0em; +@titleFont: @headerFont; +@titleFontWeight: bold; +@titleFontSize: 1.25em; +@titleColor: @darkTextColor; + +/* Metadata */ +@metaColor: @lightTextColor; + +/* Description */ +@descriptionDistance: 0.75em; +@descriptionColor: @lightTextColor; + +/* Image */ +@imageSpacing: 0.25em; +@contentImageWidth: 2em; +@contentImageVerticalAlign: middle; + +/* Paragraph */ +@paragraphDistance: 0.1em; + +/* Additional Content */ +@extraDisplay: absolute; +@extraTop: 100%; +@extraLeft: 0em; +@extraWidth: 100%; + +@extraPadding: 0.5em 0.75em; +@extraColor: @lightTextColor; +@extraTransition: color @transitionDuration @transitionEasing; + +/*------------------- + States +--------------------*/ + +@hoverCursor: pointer; +@hoverZIndex: 5; +@hoverBorder: none; +@hoverBoxShadow: + 0px 0px 0px 1px @selectedBorderColor, + 0px 3px 0px 0px @selectedBorderColor +; + + +/*------------------- + Variations +--------------------*/ + +/* Sizes */ +@medium: 1em; \ No newline at end of file diff --git a/src/themes/packages/github/views/card.variables b/src/themes/packages/github/views/card.variables new file mode 100755 index 000000000..629fd4f36 --- /dev/null +++ b/src/themes/packages/github/views/card.variables @@ -0,0 +1,22 @@ +/******************************* + Card +*******************************/ + +/*------------------- + View +--------------------*/ + +/* Shadow */ +@shadowDistance: 0em; +@padding: 0em; + +/*------------------- + Content +--------------------*/ + +/* Additional Content */ +@extraDivider: 1px solid rgba(0, 0, 0, 0.05); +@extraBackground: #FAFAFA @subtleGradient; +@extraPadding: 0.75em 1em; +@extraBoxShadow: 0 1px 1px rgba(0, 0, 0, 0.15); +@extraColor: @lightTextColor;