From 40b652449f85a07fa05156bd801414e175e33940 Mon Sep 17 00:00:00 2001 From: Faris Ansari Date: Thu, 26 Apr 2018 15:50:36 +0530 Subject: [PATCH] separate datatable styles --- client/style/datatable.scss | 34 +++++++++++++++++++++++++++++++ client/style/style.scss | 40 ++++++------------------------------- 2 files changed, 40 insertions(+), 34 deletions(-) create mode 100644 client/style/datatable.scss diff --git a/client/style/datatable.scss b/client/style/datatable.scss new file mode 100644 index 00000000..caf05132 --- /dev/null +++ b/client/style/datatable.scss @@ -0,0 +1,34 @@ +@import "./variables.scss"; +@import "node_modules/frappe-datatable/dist/frappe-datatable"; + +.dt-header { + background-color: $gray-200 !important; +} + +.dt-cell__edit { + padding: 0px; + + input, textarea { + outline: none; + border-radius: none; + border: none; + margin: none; + padding: $spacer-2; + + &:focus { + border: none; + box-shadow: none; + } + } + + .awesomplete > ul { + position: fixed; + left: auto; + width: auto; + min-width: 120px; + } +} + +.dt-cell--highlight { + background-color: $gray-200; +} diff --git a/client/style/style.scss b/client/style/style.scss index 1b0159a8..251cd829 100644 --- a/client/style/style.scss +++ b/client/style/style.scss @@ -3,7 +3,6 @@ @import "node_modules/flatpickr/dist/flatpickr"; @import "node_modules/flatpickr/dist/themes/airbnb"; @import "node_modules/codemirror/lib/codemirror"; -@import "node_modules/frappe-datatable/dist/frappe-datatable"; @import "./variables.scss"; @import "./indicators.scss"; @@ -169,39 +168,6 @@ html { margin-top: $spacer-2; } -.data-table { - .body-scrollable { - border-bottom: 0px !important; - - tr:first-child { - .data-table-col { - border-top: 0px !important; - } - } - } - - thead td { - background-color: $gray-200 !important; - } - - .data-table-cell .edit-cell { - padding: 0px !important; - - input, textarea { - border-radius: none; - margin: none; - padding: $spacer-2; - } - - .awesomplete > ul { - position: fixed; - left: auto; - width: auto; - min-width: 120px; - } - } -} - .CodeMirror { font-family: "SFMono-Regular",Consolas,"Liberation Mono",Menlo,Courier,monospace; border: 1px solid $gray-300; @@ -212,6 +178,11 @@ html { .awesomplete { display: block; + ul { + max-height: 150px; + overflow: auto; + } + > ul > li { padding: .75rem .375rem; } @@ -262,6 +233,7 @@ mark { } @import "./tree.scss"; +@import "./datatable.scss"; // just for accounting