From 0e2c8dadbeb1fd59584013e60353392e328766ce Mon Sep 17 00:00:00 2001 From: Safwan Samsudeen Date: Thu, 23 Jan 2025 11:44:34 +0530 Subject: [PATCH] fix: stylistic issue --- src/bar.js | 13 ++++++------- src/styles/gantt.css | 3 --- src/styles/light.css | 6 +++--- 3 files changed, 9 insertions(+), 13 deletions(-) diff --git a/src/bar.js b/src/bar.js index 490b165..3701211 100644 --- a/src/bar.js +++ b/src/bar.js @@ -109,11 +109,7 @@ export default class Bar { height: this.height, rx: this.corner_radius, ry: this.corner_radius, - class: - 'bar' + - (/^((?!chrome|android).)*safari/i.test(navigator.userAgent) - ? ' safari' - : ''), + class: 'bar', append_to: this.bar_group, }); if (this.task.color) this.$bar.style.fill = this.task.color; @@ -148,13 +144,16 @@ export default class Bar { draw_progress_bar() { if (this.invalid) return; this.progress_width = this.calculate_progress_width(); + let r = this.corner_radius; + if (!/^((?!chrome|android).)*safari/i.test(navigator.userAgent)) + r = this.corner_radius + 2; this.$bar_progress = createSVG('rect', { x: this.x, y: this.y, width: this.progress_width, height: this.height, - rx: this.corner_radius + 2, - ry: this.corner_radius + 2, + rx: r, + ry: r, class: 'bar-progress', append_to: this.bar_group, }); diff --git a/src/styles/gantt.css b/src/styles/gantt.css index 5d5da89..983aecc 100644 --- a/src/styles/gantt.css +++ b/src/styles/gantt.css @@ -142,7 +142,6 @@ transition-duration: 150ms; background-color: var(--g-actions-background); text-align: -webkit-center; - text-align: center; border-radius: 0.5rem; border: none; padding: 5px 8px; @@ -150,7 +149,6 @@ font-size: 14px; letter-spacing: 0.02em; font-weight: 420; - height: 20px; box-sizing: content-box; margin-right: 5px; @@ -167,7 +165,6 @@ & .side-header select { padding-right: 1.25rem; width: 50px; - padding-left: 4px; } & .date-range-highlight { diff --git a/src/styles/light.css b/src/styles/light.css index 1b1be11..8f0448e 100644 --- a/src/styles/light.css +++ b/src/styles/light.css @@ -2,8 +2,8 @@ --g-arrow-color: #1f2937; --g-bar-color: #fff; --g-bar-border: #fff; - --g-tick-color-thick: #e2e8f0; - --g-tick-color: #f1f5f9; + --g-tick-color-thick: #ededed; + --g-tick-color: #f3f3f3; --g-actions-background: #f3f3f3; --g-border-color: #ebeff2; --g-text-muted: #7c7c7c; @@ -15,7 +15,7 @@ --g-expected-progress: #c4c4e9; --g-header-background: #fff; --g-row-color: #fdfdfd; - --g-row-border-color: #cbd5e1; + --g-row-border-color: #c7c7c7; --g-today-highlight: #37352f; --g-popup-actions: #ebeff2; --g-weekend-highlight-color: #f7f7f7;