diff --git a/frappe/core/doctype/user/user.json b/frappe/core/doctype/user/user.json index 4db3895644..af7241fa38 100644 --- a/frappe/core/doctype/user/user.json +++ b/frappe/core/doctype/user/user.json @@ -664,7 +664,7 @@ } ], "max_attachments": 5, - "modified": "2020-08-26 19:48:49.677800", + "modified": "2020-10-07 19:48:49.677800", "modified_by": "Administrator", "module": "Core", "name": "User", diff --git a/frappe/hooks.py b/frappe/hooks.py index 4a93c7a2a6..dd267657fd 100644 --- a/frappe/hooks.py +++ b/frappe/hooks.py @@ -38,7 +38,6 @@ app_include_js = [ ] app_include_css = [ "assets/css/desk.min.css", - "assets/css/list.min.css", "assets/css/report.min.css", ] diff --git a/frappe/public/js/frappe/views/gantt/gantt_view.js b/frappe/public/js/frappe/views/gantt/gantt_view.js index 6fb4688a48..c8ed8a55d4 100644 --- a/frappe/public/js/frappe/views/gantt/gantt_view.js +++ b/frappe/public/js/frappe/views/gantt/gantt_view.js @@ -90,8 +90,15 @@ frappe.views.GanttView = class GanttView extends frappe.views.ListView { const date_format = 'YYYY-MM-DD'; this.$result.empty(); + this.$result.addClass('gantt-modern'); this.gantt = new Gantt(this.$result[0], this.tasks, { + bar_height: 35, + bar_corner_radius: 4, + resize_handle_width: 8, + resize_handle_height: 28, + resize_handle_corner_radius: 3, + resize_handle_offset: 4, view_mode: gantt_view_mode, date_format: "YYYY-MM-DD", on_click: task => { diff --git a/frappe/public/scss/desk/frappe-gantt.scss b/frappe/public/scss/desk/frappe-gantt.scss new file mode 100644 index 0000000000..da19e76ec6 --- /dev/null +++ b/frappe/public/scss/desk/frappe-gantt.scss @@ -0,0 +1,82 @@ +.gantt-modern .gantt { + .bar { + fill: white; + } + + .arrow { + stroke: var(--gray-600); + } + + .bar-wrapper { + .bar { + stroke: var(--gray-300); + stroke-width: 1; + } + + &:hover { + .bar { + fill: white; + stroke: var(--gray-400); + } + + .bar-progress { + fill: var(--gray-200); + } + + .handle { + visibility: hidden; + opacity: 0; + } + } + + &.active { + .handle { + visibility: visible; + opacity: 1; + fill: var(--blue-200); + } + + .bar { + fill: var(--blue-300); + stroke: var(--blue-300); + } + + .bar-progress { + fill: var(--blue-500); + } + + .bar-label { + fill: white; + } + } + } + + .bar-progress { + fill: var(--gray-200); + } + + .bar-label { + fill: var(--text-color); + font-weight: normal; + } +} + +.gantt-container .popup-wrapper { + min-width: 9rem; + border-radius: var(--border-radius); + font-size: var(--text-sm); + + .title { + color: white; + border-bottom: none; + padding-bottom: 0; + } + + .subtitle { + color: var(--gray-500); + } + + .pointer { + height: 15px; + } +} diff --git a/frappe/public/scss/desk/index.scss b/frappe/public/scss/desk/index.scss index 58370e05a2..b78e59f5d7 100644 --- a/frappe/public/scss/desk/index.scss +++ b/frappe/public/scss/desk/index.scss @@ -24,6 +24,7 @@ @import "list"; @import "report"; @import "frappe-datatable"; +@import "frappe-gantt"; @import "image-view"; @import "kanban"; @import "calendar"; @@ -32,4 +33,4 @@ @import "controls"; @import "role_editor"; @import "user-profile"; -@import "quill"; \ No newline at end of file +@import "quill"; diff --git a/frappe/www/desk.html b/frappe/www/desk.html index 5c65797e89..c39933eb57 100644 --- a/frappe/www/desk.html +++ b/frappe/www/desk.html @@ -24,7 +24,7 @@ {%- endfor -%} - + {% include "public/icons/timeless/symbol-defs.svg" %}
diff --git a/frappe/www/desk.py b/frappe/www/desk.py index 5bb2f24fc1..eb9b940090 100644 --- a/frappe/www/desk.py +++ b/frappe/www/desk.py @@ -43,7 +43,7 @@ def get_context(context): "include_css": hooks["app_include_css"], "sounds": hooks["sounds"], "boot": boot if context.get("for_mobile") else boot_json, - "theme": desk_theme or "Light", + "desk_theme": desk_theme or "Light", "csrf_token": csrf_token, "google_analytics_id": frappe.conf.get("google_analytics_id"), "mixpanel_id": frappe.conf.get("mixpanel_id") diff --git a/yarn.lock b/yarn.lock index e688adab71..0a9ee5f48c 100644 --- a/yarn.lock +++ b/yarn.lock @@ -4304,7 +4304,7 @@ lodash@4.17.15, lodash@^4.0.0, lodash@^4.17.10, lodash@^4.17.15, lodash@^4.17.4, resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.15.tgz#b447f6670a0455bbfeedd11392eff330ea097548" integrity sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A== -lodash@^4.17.11, lodash@^4.17.14, lodash@^4.17.19, lodash@^4.17.20, lodash@~4.17.12: +lodash@^4.17.11, lodash@^4.17.14, lodash@^4.17.19, lodash@^4.17.20, lodash@~4.17.10: version "4.17.20" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.20.tgz#b44a9b6297bcb698f1c51a3545a2b3b368d59c52" integrity sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==