diff --git a/frappe/desk/page/activity/activity.css b/frappe/desk/page/activity/activity.css index ef4cc7341d..4ce5338175 100644 --- a/frappe/desk/page/activity/activity.css +++ b/frappe/desk/page/activity/activity.css @@ -28,6 +28,14 @@ height:8px; width:8px; border-radius:8px; + background: #d1d8dd; +} + +.date-indicator.blue { + color: #5e64ff; +} + +.date-indicator.blue::after { background: #5e64ff; } diff --git a/frappe/desk/page/activity/activity.js b/frappe/desk/page/activity/activity.js index 1397b29b8f..52d1103a99 100644 --- a/frappe/desk/page/activity/activity.js +++ b/frappe/desk/page/activity/activity.js @@ -84,7 +84,7 @@ frappe.ActivityFeed = Class.extend({ pdate = dateutil.global_date_format(date); } data.date_sep = pdate; - data.date_class = "date-indicator"; + data.date_class = pdate=='Today' ? "date-indicator blue" : "date-indicator"; } else { data.date_sep = null; data.date_class = ""; diff --git a/frappe/desk/page/activity/activity_row.html b/frappe/desk/page/activity/activity_row.html index d27a114824..6dd21169d9 100644 --- a/frappe/desk/page/activity/activity_row.html +++ b/frappe/desk/page/activity/activity_row.html @@ -2,7 +2,7 @@
{%= date_sep || "" %}
+ title="{%= by %} / {%= dateutil.str_to_user(creation) %}"> diff --git a/frappe/public/build.json b/frappe/public/build.json index b349291821..b6651dc0b1 100644 --- a/frappe/public/build.json +++ b/frappe/public/build.json @@ -3,7 +3,7 @@ "public/css/bootstrap.css", "public/css/font-awesome.css", "public/css/nprogress.css", - "website/css/website.css" + "public/css/website.css" ], "js/frappe-web.min.js": [ "public/js/lib/bootstrap.min.js", diff --git a/frappe/public/css/website.css b/frappe/public/css/website.css new file mode 100644 index 0000000000..d59f2a75db --- /dev/null +++ b/frappe/public/css/website.css @@ -0,0 +1,434 @@ +@media (min-width: 768px) { + .login-wrapper { + border-right: 1px solid #f2f2f2; + } +} +/*h1, h2, h3, h4, h5 { + font-weight: bold; +} +*/ +a { + cursor: pointer; +} +img { + max-width: 100%; +} +.content { + margin-bottom: 22px; +} +.banner { + margin-top: 20px; + padding: 0px 20px; +} +.missing-image { + background-color: #eee; + padding: 40px; + width: 112px; + font-size: 32px; + color: #888; +} +.social-icons i { + font-size: 120%; +} +.social-icons a:hover { + text-decoration: none; +} +.social-icons a i:hover { + text-decoration: none; +} +.social-icons i { + margin-left: 5px; +} +.web-footer { + padding: 20px 0px; + min-height: 140px; +} +.avatar { + display: inline-block; + vertical-align: middle; + overflow: hidden; + background-color: #ddd; + border: 1px solid #eee; + background-size: cover; + background-position: center center; + background-repeat: no-repeat; +} +.avatar-small { + margin-right: 5px; + width: 30px; + height: 30px; + border-radius: 30px; + -moz-border-radius: 30px; + -webkit-border-radius: 30px; +} +.avatar-small img { + width: 30px; +} +.avatar-medium { + margin-right: 5px; + width: 48px; + height: 48px; + border-radius: 48px; + -moz-border-radius: 48px; + -webkit-border-radius: 48px; +} +.avatar-medium img { + width: 48px; +} +.avatar-large { + margin-right: 10px; + width: 72px; + height: 72px; + border-radius: 72px; + -moz-border-radius: 72px; + -webkit-border-radius: 72px; +} +.avatar-large img { + width: 72px; +} +.avatar-x-large { + margin-right: 10px; + width: 100px; + height: 100px; + border-radius: 100px; + -moz-border-radius: 100px; + -webkit-border-radius: 100px; +} +.avatar-x-large img { + width: 100px; +} +.carousel-control .icon { + position: absolute; + top: 50%; + left: 50%; + z-index: 5; + display: inline-block; + width: 20px; + height: 20px; + margin-top: -10px; + margin-left: -10px; +} +.hidden-xs-inline, +.hidden-xs-inline-block { + display: none; +} +@media (min-width: 768px) { + .hidden-xs-inline { + display: inline; + } + .hidden-xs-inline-block { + display: inline-block; + } +} +.visible-xs-inline { + display: inline; +} +.visible-xs-inline-block { + display: inline-block; +} +@media (min-width: 768px) { + .visible-xs-inline, + .visible-xs-inline-block { + display: none; + } +} +/* the element that this class is applied to, should have a max width for this to work*/ +.ellipsis { + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + display: inline-block; +} +.navbar { + box-shadow: none; + border-radius: 0px; + margin-bottom: 0px; + padding-top: 15px; + padding-bottom: 15px; +} +.navbar-brand { + padding-right: 30px; + max-width: 80%; + min-height: 20px; + height: auto; +} +.navbar a.active { + font-weight: bold; +} +@media (min-width: 768px) { + .navbar-brand { + max-width: 300px; + } +} +.panel-container { + margin-top: 35px; +} +.panel-heading, +.panel-body { + padding-left: 15px; +} +fieldset { + margin-bottom: 20px; +} +.message-overlay { + position: fixed; + top: 0; + left: 0; + width: 100%; + height: 100%; + z-index: 1040; + background-color: #fff; + display: table; +} +.message-overlay .content { + display: table-cell; + vertical-align: middle; + text-align: center; +} +.web-page-editable { + margin: -15px; + padding: 15px; + border-radius: 4px; +} +.slide-image { + width: 100%; +} +.page-header { + margin: 0px; + margin-bottom: 20px; + padding: 25px 0px; +} +.page-header h1, +.page-header h2, +.page-header h3 { + margin: 5px auto; +} +.page-header .lead { + margin-bottom: 5px; +} +.sidebar-item { + /*background-color: #f7f7f7;*/ + border-left: 1px solid #eee; + margin-left: -30px; + padding: 5px 15px; + color: #999; + font-size: 85%; +} +.sidebar-item:first-child { + padding-top: 10px; +} +.sidebar-item:last-child { + padding-bottom: 10px; +} +.sidebar-item a { + color: #999; + text-decoration: none; +} +.sidebar-item a:hover, +.sidebar-item a:focus, +.sidebar-item a:active { + color: #333; + text-decoration: none; + /* thanks medium: https://medium.com/designing-medium/crafting-link-underlines-on-medium-7c03a9274f9 */ + background-image: linear-gradient(to bottom, transparent 50%, rgba(153, 153, 153, 0.5) 50%); + background-repeat: repeat-x; + background-size: 5% 20%; + background-position: 0 100%; +} +.sidebar-item a.active { + color: #000; + font-weight: bold; +} +html, +body { + height: 100%; + /* The html and body elements cannot have any padding or margin. */ +} +/* Wrapper for page content to push down footer */ +#wrap { + min-height: 100%; + height: auto; + /* Negative indent footer by its height */ + margin: auto; + margin: 0 auto -140px; + /* Pad bottom by footer height */ + padding: 0 0 140px; +} +/* Set the fixed height of the footer here */ +#wrap-footer { + margin-top: 30px; + min-height: 140px; + background-color: #f5f5f5; +} +.page-footer { + margin: 20px 0px 0px; + padding: 15px 0px; + border-top: 1px solid #eee; +} +/* website group */ +.view-selector { + margin-bottom: 15px; +} +/* post and post list */ +.post { + padding: 15px 0px; + word-wrap: break-word; + border-bottom: 1px solid #eee; +} +.post:first-child { + margin-top: 15px !important; +} +.post .img-responsive { + border-radius: 4px; +} +.post .media-link { + display: block; + min-width: 50px; + min-height: 50px; +} +.post .media-object { + border-radius: 4px; + max-width: 50px; +} +.post .media-heading { + margin-bottom: 12px; +} +.parent-post .post { + border: none; +} +.child-post { + border: 1px solid #eee; + padding-left: 15px; + background-color: #f8f8f8; + margin-top: 0px; +} +textarea { + resize: vertical; +} +.post-add-textarea { + height: 200px !important; +} +/* needs review */ +.btn-small, +.post-editor .btn { + padding: 5px; + font-size: 90%; +} +.btn-right, +.post-editor .btn { + margin-left: 5px; +} +.no-posts { + margin-top: 15px; +} +.full-page { + margin: 30px; +} +.user-profile { + min-height: 50px; + min-width: 70px; +} +.visible-xs { + display: none !important; +} +@media (max-width: 767px) { + .visible-xs { + display: inline-block !important; + } +} +.nav-tabs > li > a { + padding: 7px 10px; +} +.btn-more { + margin-top: 15px; +} +.post-content img { + margin: 10px 0px; +} +.assigned-label, +.event-label { + display: inline-block; + padding: .4em .6em .4em; + margin-bottom: 7px; +} +a.no-decoration { + text-decoration: none; + color: inherit; +} +a.active { + pointer-events: none; + cursor: default; +} +:target { + background-color: #ffa; +} +.page-breadcrumbs .breadcrumb { + padding: 0px; + margin-bottom: 2px; + background-color: transparent; + border-radius: 0px; + font-size: 85%; +} +.breadcrumb a { + color: inherit; +} +@media (min-width: 768px) { + .page-sidebar { + padding-left: 3em; + } +} +@media (max-width: 767px) { + .page-sidebar { + padding-bottom: 15px; + margin-bottom: 15px; + border-bottom: 1px solid #eee; + } + .page-sidebar .sidebar-item { + margin-left: 17px; + } +} +.post:last-child { + border-bottom: none; +} +/* end - needs review */ +/* docs */ +.docs-attr-name { + font-size: 120%; +} +.docs-attr-desc { + padding-left: 30px; +} +a.grey, +.sidebar-section a, +.nav-pills a, +.control-value a, +.data-row a { + color: inherit; + border-bottom: 1px solid transparent; + margin-bottom: 0.4em; +} +a.grey:hover, +.sidebar-section a:hover, +.nav-pills a:hover, +.control-value a:hover, +.data-row a:hover { + border-bottom: 1px solid #212a33; + color: #212a33; +} +.text-muted { + color: #8d99a6 !important; +} +.text-extra-muted { + color: #d1d8dd !important; +} +a.text-muted, +a.text-extra-muted { + border-bottom: 1px solid transparent; +} +a.text-muted:hover, +a.text-muted:focus, +a.text-extra-muted:hover, +a.text-extra-muted:focus { + color: inherit; + border-bottom: 1px solid #8d99a6; +} diff --git a/frappe/public/js/frappe/misc/datetime.js b/frappe/public/js/frappe/misc/datetime.js index 846f086572..855ca1ee3a 100644 --- a/frappe/public/js/frappe/misc/datetime.js +++ b/frappe/public/js/frappe/misc/datetime.js @@ -17,7 +17,7 @@ $.extend(frappe.datetime, { }, obj_to_user: function(d) { - return frappe.datetime.str_to_user(moment(d).format("YYYY-MM-DD HH:mm:ss")); + return moment(d).format(dateutil.get_user_fmt().toUpperCase()); }, get_diff: function(d1, d2) { diff --git a/frappe/website/css/website.css b/frappe/public/less/website.less similarity index 90% rename from frappe/website/css/website.css rename to frappe/public/less/website.less index bc3ca2b8cc..f5270460a8 100644 --- a/frappe/website/css/website.css +++ b/frappe/public/less/website.less @@ -1,3 +1,5 @@ +@import "variables.less"; + @media (min-width: 768px) { .login-wrapper { border-right: 1px solid #f2f2f2; @@ -480,3 +482,37 @@ a.active { .docs-attr-desc { padding-left: 30px; } + + +// links and text + +a.grey, .sidebar-section a, .nav-pills a, .control-value a, .data-row a { + color: inherit; + border-bottom: 1px solid transparent; + margin-bottom: 0.4em; +} + +a.grey:hover, .sidebar-section a:hover, .nav-pills a:hover, .control-value a:hover, .data-row a:hover { + border-bottom: 1px solid @grey-link-color; + color: @grey-link-color; +} + +.text-muted { + color: @text-muted !important; +} + +.text-extra-muted { + color: @border-color !important; +} + +a.text-muted, a.text-extra-muted { + border-bottom: 1px solid transparent; +} + +a.text-muted:hover, +a.text-muted:focus, +a.text-extra-muted:hover, +a.text-extra-muted:focus { + color: inherit; + border-bottom: 1px solid @text-muted; +} diff --git a/frappe/templates/includes/login.css b/frappe/templates/includes/login.css index 316bbe18fc..f128c29c9f 100644 --- a/frappe/templates/includes/login.css +++ b/frappe/templates/includes/login.css @@ -2,18 +2,22 @@ display: none; } -#wrap { - background-color: #f2f2f2; -} .page-content { right: 0%; width: 100%; } +#wrap { + background-color: #fafbfc; +} + .form-signin { - max-width: 330px; - padding: 15px; + max-width: 360px; + padding: 30px; margin: 0 auto; + border: 1px solid #d1d8dd; + border-radius: 5px; + background-color: #fff; } .form-signin .form-signin-heading, .form-signin .checkbox { @@ -43,4 +47,8 @@ input#login_password, input#signup_email { margin-bottom: 10px; border-top-left-radius: 0; border-top-right-radius: 0; -} \ No newline at end of file +} + +.btn-social { + margin: 10px; +} diff --git a/frappe/templates/pages/login.html b/frappe/templates/pages/login.html index c3f923d098..835b790e04 100644 --- a/frappe/templates/pages/login.html +++ b/frappe/templates/pages/login.html @@ -1,9 +1,28 @@ {% block style %}{% include "templates/includes/login.css" %}{% endblock %} {% block content %} -
+