diff --git a/licenses.yaml b/licenses.yaml index 4410ecc4d645..a6d85500ae2b 100644 --- a/licenses.yaml +++ b/licenses.yaml @@ -4495,7 +4495,7 @@ license_category: binary module: web-console license_name: Apache License version 2.0 copyright: Palantir Technologies -version: 3.19.1 +version: 3.33.0 --- @@ -4504,7 +4504,7 @@ license_category: binary module: web-console license_name: Apache License version 2.0 copyright: Palantir Technologies -version: 3.14.0 +version: 3.19.2 --- @@ -4513,7 +4513,7 @@ license_category: binary module: web-console license_name: Apache License version 2.0 copyright: Palantir Technologies -version: 3.11.0 +version: 3.22.0 --- @@ -4687,6 +4687,26 @@ license_file_path: licenses/bin/debug.MIT --- +name: "deep-equal" +license_category: binary +module: web-console +license_name: MIT License +copyright: James Halliday +version: 1.1.1 +license_file_path: licenses/bin/deep-equal.MIT + +--- + +name: "define-properties" +license_category: binary +module: web-console +license_name: MIT License +copyright: Jordan Harband +version: 1.1.3 +license_file_path: licenses/bin/define-properties.MIT + +--- + name: "diff-match-patch" license_category: binary module: web-console @@ -4745,6 +4765,26 @@ license_file_path: licenses/bin/follow-redirects.MIT --- +name: "fontsource-open-sans" +license_category: binary +module: web-console +license_name: MIT License +copyright: Lotus +version: 3.0.9 +license_file_path: licenses/bin/fontsource-open-sans.MIT + +--- + +name: "function-bind" +license_category: binary +module: web-console +license_name: MIT License +copyright: Raynos +version: 1.1.1 +license_file_path: licenses/bin/function-bind.MIT + +--- + name: "gud" license_category: binary module: web-console @@ -4765,6 +4805,16 @@ license_file_path: licenses/bin/has-own-prop.MIT --- +name: "has" +license_category: binary +module: web-console +license_name: MIT License +copyright: Thiago de Arruda +version: 1.0.3 +license_file_path: licenses/bin/has.MIT + +--- + name: "history" license_category: binary module: web-console @@ -4795,6 +4845,16 @@ license_file_path: licenses/bin/hoist-non-react-statics.BSD3 --- +name: "is-arguments" +license_category: binary +module: web-console +license_name: MIT License +copyright: Jordan Harband +version: 1.0.4 +license_file_path: licenses/bin/is-arguments.MIT + +--- + name: "is-buffer" license_category: binary module: web-console @@ -4805,6 +4865,26 @@ license_file_path: licenses/bin/is-buffer.MIT --- +name: "is-date-object" +license_category: binary +module: web-console +license_name: MIT License +copyright: Jordan Harband +version: 1.0.1 +license_file_path: licenses/bin/is-date-object.MIT + +--- + +name: "is-regex" +license_category: binary +module: web-console +license_name: MIT License +copyright: Jordan Harband +version: 1.0.4 +license_file_path: licenses/bin/is-regex.MIT + +--- + name: "isarray" license_category: binary module: web-console @@ -4935,6 +5015,35 @@ license_file_path: licenses/bin/object-assign.MIT --- +name: "object-is" +license_category: binary +module: web-console +license_name: MIT License +copyright: Jordan Harband +version: 1.0.1 +license_file_path: licenses/bin/object-is.MIT + +--- + +name: "object-keys" +license_category: binary +module: web-console +license_name: MIT License +copyright: Jordan Harband +version: 1.1.1 +license_file_path: licenses/bin/object-keys.MIT + +--- + +name: "opensans" +license_category: binary +module: web-console +license_name: Apache License version 2.0 +copyright: Google +version: 1.101.0 + +--- + name: "path-to-regexp" license_category: binary module: web-console @@ -4950,7 +5059,7 @@ license_category: binary module: web-console license_name: MIT License copyright: Federico Zivolo -version: 1.15.0 +version: 1.16.1 license_file_path: licenses/bin/popper.js.MIT --- @@ -4980,7 +5089,7 @@ license_category: binary module: web-console license_name: MIT License copyright: Giampaolo Bellavite -version: 7.4.0 +version: 7.4.8 license_file_path: licenses/bin/react-day-picker.MIT --- @@ -5020,7 +5129,7 @@ license_category: binary module: web-console license_name: MIT License copyright: Travis Arnold -version: 1.3.4 +version: 1.3.7 license_file_path: licenses/bin/react-popper.MIT --- @@ -5095,6 +5204,16 @@ license_file_path: licenses/bin/regenerator-runtime.MIT --- +name: "regexp.prototype.flags" +license_category: binary +module: web-console +license_name: MIT License +copyright: Jordan Harband +version: 1.2.0 +license_file_path: licenses/bin/regexp.prototype.flags.MIT + +--- + name: "resize-observer-polyfill" license_category: binary module: web-console diff --git a/licenses/bin/deep-equal.MIT b/licenses/bin/deep-equal.MIT new file mode 100644 index 000000000000..9b0ea42eeec3 --- /dev/null +++ b/licenses/bin/deep-equal.MIT @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2012, 2013, 2014 James Halliday , 2009 Thomas Robinson <280north.com> + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/licenses/bin/define-properties.MIT b/licenses/bin/define-properties.MIT new file mode 100644 index 000000000000..8c271c14b62f --- /dev/null +++ b/licenses/bin/define-properties.MIT @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (C) 2015 Jordan Harband + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. \ No newline at end of file diff --git a/licenses/bin/fontsource-open-sans.MIT b/licenses/bin/fontsource-open-sans.MIT new file mode 100644 index 000000000000..4770db605ba0 --- /dev/null +++ b/licenses/bin/fontsource-open-sans.MIT @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2020 Lotus + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. \ No newline at end of file diff --git a/licenses/bin/function-bind.MIT b/licenses/bin/function-bind.MIT new file mode 100644 index 000000000000..62d6d237ff17 --- /dev/null +++ b/licenses/bin/function-bind.MIT @@ -0,0 +1,20 @@ +Copyright (c) 2013 Raynos. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + diff --git a/licenses/bin/has.MIT b/licenses/bin/has.MIT new file mode 100644 index 000000000000..ae7014d385df --- /dev/null +++ b/licenses/bin/has.MIT @@ -0,0 +1,22 @@ +Copyright (c) 2013 Thiago de Arruda + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. diff --git a/licenses/bin/is-arguments.MIT b/licenses/bin/is-arguments.MIT new file mode 100644 index 000000000000..47b7b5078fce --- /dev/null +++ b/licenses/bin/is-arguments.MIT @@ -0,0 +1,20 @@ +The MIT License (MIT) + +Copyright (c) 2014 Jordan Harband + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/licenses/bin/is-date-object.MIT b/licenses/bin/is-date-object.MIT new file mode 100644 index 000000000000..b43df444e518 --- /dev/null +++ b/licenses/bin/is-date-object.MIT @@ -0,0 +1,22 @@ +The MIT License (MIT) + +Copyright (c) 2015 Jordan Harband + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + diff --git a/licenses/bin/is-regex.MIT b/licenses/bin/is-regex.MIT new file mode 100644 index 000000000000..47b7b5078fce --- /dev/null +++ b/licenses/bin/is-regex.MIT @@ -0,0 +1,20 @@ +The MIT License (MIT) + +Copyright (c) 2014 Jordan Harband + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/licenses/bin/object-is.MIT b/licenses/bin/object-is.MIT new file mode 100644 index 000000000000..47b7b5078fce --- /dev/null +++ b/licenses/bin/object-is.MIT @@ -0,0 +1,20 @@ +The MIT License (MIT) + +Copyright (c) 2014 Jordan Harband + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/licenses/bin/object-keys.MIT b/licenses/bin/object-keys.MIT new file mode 100644 index 000000000000..28553fdd0684 --- /dev/null +++ b/licenses/bin/object-keys.MIT @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (C) 2013 Jordan Harband + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. \ No newline at end of file diff --git a/licenses/bin/regexp.prototype.flags.MIT b/licenses/bin/regexp.prototype.flags.MIT new file mode 100644 index 000000000000..9a8e1e0e62e4 --- /dev/null +++ b/licenses/bin/regexp.prototype.flags.MIT @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (C) 2014 Jordan Harband + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. \ No newline at end of file diff --git a/web-console/favicon.png b/web-console/favicon.png index ffe7cb4a3cb9..96b9aff6791e 100644 Binary files a/web-console/favicon.png and b/web-console/favicon.png differ diff --git a/web-console/lib/react-table.styl b/web-console/lib/react-table.styl index 372dc03405ce..709bd142044c 100644 --- a/web-console/lib/react-table.styl +++ b/web-console/lib/react-table.styl @@ -23,6 +23,7 @@ $easeOutQuad = cubic-bezier(0.250, 0.460, 0.450, 0.940) $easeOutBack = cubic-bezier(0.175, 0.885, 0.320, 1.275) $expandSize = 7px +$border-color = alpha(black, 0.15) input-select-style() border: 1px solid rgba(0,0,0,0.1) @@ -37,7 +38,6 @@ input-select-style() position:relative display: flex flex-direction: column - border: 1px solid alpha(black, .1) * box-sizing: border-box .rt-table @@ -60,20 +60,20 @@ input-select-style() &.-headerGroups background: alpha(black, .03) - border-bottom: 1px solid alpha(black, .05) + border-bottom: 1px solid $border-color &.-filters - border-bottom: 1px solid alpha(black, 0.05) + border-bottom: 1px solid $border-color //input //select // input-select-style(); .rt-th - border-right: 1px solid alpha(black, 0.02) + border-right: 1px solid $border-color &.-header - box-shadow: 0 2px 15px 0px alpha(black, .15) + box-shadow: 0 1px 0 0 $border-color .rt-tr text-align: left @@ -83,13 +83,13 @@ input-select-style() padding: 5px 5px line-height: normal position: relative - border-right: 1px solid alpha(black, .05) + border-right: 1px solid $border-color transition box-shadow .3s $easeOutBack box-shadow:inset 0 0 0 0 transparent &.-sort-asc - box-shadow:inset 0 3px 0 0 alpha(white, .6) + box-shadow:inset 0 3px 0 0 #8489A1 &.-sort-desc - box-shadow:inset 0 -3px 0 0 alpha(white, .6) + box-shadow:inset 0 -3px 0 0 #8489A1 &.-cursor-pointer cursor: pointer &:last-child @@ -105,7 +105,7 @@ input-select-style() text-overflow: ellipsis .rt-header-pivot - border-right-color: #f7f7f7 + border-right-color: $border-color .rt-header-pivot:after, .rt-header-pivot:before left: 100% @@ -136,11 +136,11 @@ input-select-style() overflow: auto // z-index:0 .rt-tr-group - border-bottom: solid 1px alpha(black, .05) + border-bottom: 1px solid $border-color &:last-child border-bottom: 0 .rt-td - border-right:1px solid alpha(black, .02) + border-right:1px solid $border-color &:last-child border-right:0 .rt-expandable @@ -207,16 +207,16 @@ input-select-style() flex: 1 0 auto display: flex flex-direction: column - box-shadow: 0 0px 15px 0px alpha(black, .15) + box-shadow: 0 0px 15px 0px alpha(black, 0) .rt-td - border-right:1px solid alpha(black, .05) + border-right:1px solid $border-color &:last-child border-right:0 &.-striped .rt-tr.-odd - background: alpha(white, .03) + background: alpha(white, .025) &.-highlight .rt-tbody .rt-tr:not(.-padRow):hover @@ -229,8 +229,7 @@ input-select-style() align-items: stretch flex-wrap: wrap padding: 3px - box-shadow: 0 0px 15px 0px alpha(black, .1) - border-top: 2px solid alpha(black, .1) + border-top: 1px solid $border-color input select diff --git a/web-console/package-lock.json b/web-console/package-lock.json index f791492e1900..cd7673d0a2bd 100644 --- a/web-console/package-lock.json +++ b/web-console/package-lock.json @@ -967,61 +967,62 @@ } }, "@blueprintjs/core": { - "version": "3.19.1", - "resolved": "https://registry.npmjs.org/@blueprintjs/core/-/core-3.19.1.tgz", - "integrity": "sha512-O+p/Jbu9kyrTE4Yy5phd7Xp9NJoiHCQ9ycO+QSR2fiuhwnVMO1xjY269QXxylzEswgPyjhST1euqHpyQQ7qnUw==", + "version": "3.33.0", + "resolved": "https://registry.npmjs.org/@blueprintjs/core/-/core-3.33.0.tgz", + "integrity": "sha512-9gccauo44DsrW8IP75Qy7rKrRv3sgOTvs2Lv2DIEH9f+WZQjj37x+3bfiGKrzeWWRS5P1vP1uSgn89P/JZrD8w==", "requires": { - "@blueprintjs/icons": "^3.11.0", + "@blueprintjs/icons": "^3.22.0", "@types/dom4": "^2.0.1", "classnames": "^2.2", "dom4": "^2.1.5", "normalize.css": "^8.0.1", - "popper.js": "^1.15.0", + "popper.js": "^1.16.1", "react-lifecycles-compat": "^3.0.4", - "react-popper": "^1.3.3", + "react-popper": "^1.3.7", "react-transition-group": "^2.9.0", "resize-observer-polyfill": "^1.5.1", - "tslib": "~1.9.0" + "tslib": "~1.13.0" }, "dependencies": { "tslib": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.9.3.tgz", - "integrity": "sha512-4krF8scpejhaOgqzBEcGM7yDIEfi0/8+8zDRZhNZZ2kjmHJ4hv3zCbQWxoJGz1iw5U0Jl0nma13xzHXcncMavQ==" + "version": "1.13.0", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.13.0.tgz", + "integrity": "sha512-i/6DQjL8Xf3be4K/E6Wgpekn5Qasl1usyw++dAA35Ue5orEn65VIxOA+YvNNl9HV3qv70T7CNwjODHZrLwvd1Q==" } } }, "@blueprintjs/datetime": { - "version": "3.14.0", - "resolved": "https://registry.npmjs.org/@blueprintjs/datetime/-/datetime-3.14.0.tgz", - "integrity": "sha512-NfCiV19zMPWZ7kcx1A2OympSLy7vp8wFrhMaMAKK6R+ndTUuEDZi3Z5NxoyX2jBJ71F9nhWYFjH1nQVOn/eDaw==", + "version": "3.19.2", + "resolved": "https://registry.npmjs.org/@blueprintjs/datetime/-/datetime-3.19.2.tgz", + "integrity": "sha512-jqPTrmoe5yPPW9r8R0q5XTxue+w1ue3cDViHWO6l5Cu9UvqNnzB9pRX7G1K8llshbMx4vaiUEK77bgo75TF+RA==", "requires": { - "@blueprintjs/core": "^3.19.0", + "@blueprintjs/core": "^3.33.0", "classnames": "^2.2", - "react-day-picker": "^7.3.2", - "tslib": "~1.9.0" + "react-day-picker": "7.4.8", + "react-lifecycles-compat": "^3.0.4", + "tslib": "~1.13.0" }, "dependencies": { "tslib": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.9.3.tgz", - "integrity": "sha512-4krF8scpejhaOgqzBEcGM7yDIEfi0/8+8zDRZhNZZ2kjmHJ4hv3zCbQWxoJGz1iw5U0Jl0nma13xzHXcncMavQ==" + "version": "1.13.0", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.13.0.tgz", + "integrity": "sha512-i/6DQjL8Xf3be4K/E6Wgpekn5Qasl1usyw++dAA35Ue5orEn65VIxOA+YvNNl9HV3qv70T7CNwjODHZrLwvd1Q==" } } }, "@blueprintjs/icons": { - "version": "3.11.0", - "resolved": "https://registry.npmjs.org/@blueprintjs/icons/-/icons-3.11.0.tgz", - "integrity": "sha512-HGS652gFc057t9cr8NyuWFyZ1gcSqG3uuexpzhZm81W35hGfh9vdC9GR+mbHJNawAuKXtu+xw4VWWkv1UGQ0Vg==", + "version": "3.22.0", + "resolved": "https://registry.npmjs.org/@blueprintjs/icons/-/icons-3.22.0.tgz", + "integrity": "sha512-clfdwRQlzqs2sDxjwQr4p10Z3bGNTnqpsLgN+4TN1ECf7plEEukhvQh6YK/Lfd5xDhEBEEZ/YQCawZbyAYjfXg==", "requires": { "classnames": "^2.2", - "tslib": "~1.9.0" + "tslib": "~1.13.0" }, "dependencies": { "tslib": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.9.3.tgz", - "integrity": "sha512-4krF8scpejhaOgqzBEcGM7yDIEfi0/8+8zDRZhNZZ2kjmHJ4hv3zCbQWxoJGz1iw5U0Jl0nma13xzHXcncMavQ==" + "version": "1.13.0", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.13.0.tgz", + "integrity": "sha512-i/6DQjL8Xf3be4K/E6Wgpekn5Qasl1usyw++dAA35Ue5orEn65VIxOA+YvNNl9HV3qv70T7CNwjODHZrLwvd1Q==" } } }, @@ -1469,6 +1470,12 @@ "integrity": "sha512-yALhelO3i0hqZwhjtcr6dYyaLoCHbAMshwtj6cGxTvHZAKXHsYGdff6E8EPw3xLKY0ELUTQ69Q1rQiJENnccMA==", "dev": true }, + "@types/json-schema": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.6.tgz", + "integrity": "sha512-3c+yGKvVP5Y9TYBEibGNR+kLtijnj7mYrXRg+WpFb2X9xm04g/DXYkfg4hmzJQosc9snFNUPkbYIhu+KAm6jJw==", + "dev": true + }, "@types/lodash": { "version": "4.14.136", "resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.14.136.tgz", @@ -3966,7 +3973,6 @@ "version": "1.1.3", "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", - "dev": true, "requires": { "object-keys": "^1.0.12" } @@ -5052,6 +5058,85 @@ "flat-cache": "^2.0.1" } }, + "file-loader": { + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/file-loader/-/file-loader-6.1.1.tgz", + "integrity": "sha512-Klt8C4BjWSXYQAfhpYYkG4qHNTna4toMHEbWrI5IuVoxbU6uiDKeKAP99R8mmbJi3lvewn/jQBOgU4+NS3tDQw==", + "dev": true, + "requires": { + "loader-utils": "^2.0.0", + "schema-utils": "^3.0.0" + }, + "dependencies": { + "ajv": { + "version": "6.12.6", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", + "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==", + "dev": true, + "requires": { + "fast-deep-equal": "^3.1.1", + "fast-json-stable-stringify": "^2.0.0", + "json-schema-traverse": "^0.4.1", + "uri-js": "^4.2.2" + } + }, + "ajv-keywords": { + "version": "3.5.2", + "resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-3.5.2.tgz", + "integrity": "sha512-5p6WTN0DdTGVQk6VjcEju19IgaHudalcfabD7yhDGeA6bcQnmL+CpveLJq/3hvfwd1aof6L386Ougkx6RfyMIQ==", + "dev": true + }, + "emojis-list": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/emojis-list/-/emojis-list-3.0.0.tgz", + "integrity": "sha512-/kyM18EfinwXZbno9FyUGeFh87KC8HRQBQGildHZbEuRyWFOmv1U10o9BBp8XVZDVNNuQKyIGIu5ZYAAXJ0V2Q==", + "dev": true + }, + "fast-deep-equal": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", + "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", + "dev": true + }, + "json5": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/json5/-/json5-2.1.3.tgz", + "integrity": "sha512-KXPvOm8K9IJKFM0bmdn8QXh7udDh1g/giieX0NLCaMnb4hEiVFqnop2ImTXCc5e0/oHz3LTqmHGtExn5hfMkOA==", + "dev": true, + "requires": { + "minimist": "^1.2.5" + } + }, + "loader-utils": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-2.0.0.tgz", + "integrity": "sha512-rP4F0h2RaWSvPEkD7BLDFQnvSf+nK+wr3ESUjNTyAGobqrijmW92zc+SO6d4p4B1wh7+B/Jg1mkQe5NYUEHtHQ==", + "dev": true, + "requires": { + "big.js": "^5.2.2", + "emojis-list": "^3.0.0", + "json5": "^2.1.2" + } + }, + "minimist": { + "version": "1.2.5", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", + "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==", + "dev": true + }, + "schema-utils": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.0.0.tgz", + "integrity": "sha512-6D82/xSzO094ajanoOSbe4YvXWMfn2A//8Y1+MUqFAJul5Bs+yn36xbK9OtNDcRVSBJ9jjeoXftM6CfztsjOAA==", + "dev": true, + "requires": { + "@types/json-schema": "^7.0.6", + "ajv": "^6.12.5", + "ajv-keywords": "^3.5.2" + } + } + } + }, "file-saver": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/file-saver/-/file-saver-2.0.2.tgz", @@ -5217,6 +5302,11 @@ "debug": "=3.1.0" } }, + "fontsource-open-sans": { + "version": "3.0.9", + "resolved": "https://registry.npmjs.org/fontsource-open-sans/-/fontsource-open-sans-3.0.9.tgz", + "integrity": "sha512-NEgZAgtpvz7iYZ/IlojOOy6hRLaLmxnxzEKYXnq0KU/X8lb9cD7d0XImykhfksK1/JZ6xyKQKjYq4PycHQZK9w==" + }, "for-in": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/for-in/-/for-in-1.0.2.tgz", @@ -5927,8 +6017,7 @@ "function-bind": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", - "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==", - "dev": true + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" }, "function.prototype.name": { "version": "1.1.1", @@ -6242,7 +6331,6 @@ "version": "1.0.3", "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", - "dev": true, "requires": { "function-bind": "^1.1.1" } @@ -6842,8 +6930,7 @@ "is-arguments": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.0.4.tgz", - "integrity": "sha512-xPh0Rmt8NE65sNzvyUmWgI1tz3mKq74lGA0mL8LYZcoIzKOzDh6HmrYm3d18k60nHerC8A9Km8kYu87zfSFnLA==", - "dev": true + "integrity": "sha512-xPh0Rmt8NE65sNzvyUmWgI1tz3mKq74lGA0mL8LYZcoIzKOzDh6HmrYm3d18k60nHerC8A9Km8kYu87zfSFnLA==" }, "is-arrayish": { "version": "0.2.1", @@ -6915,8 +7002,7 @@ "is-date-object": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.1.tgz", - "integrity": "sha1-mqIOtq7rv/d/vTPnTKAbM1gdOhY=", - "dev": true + "integrity": "sha1-mqIOtq7rv/d/vTPnTKAbM1gdOhY=" }, "is-decimal": { "version": "1.0.3", @@ -7075,7 +7161,6 @@ "version": "1.0.4", "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.0.4.tgz", "integrity": "sha1-VRdIm1RwkbCTDglWVM7SXul+lJE=", - "dev": true, "requires": { "has": "^1.0.1" } @@ -9236,14 +9321,12 @@ "object-is": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/object-is/-/object-is-1.0.1.tgz", - "integrity": "sha1-CqYOyZiaCz7Xlc9NBvYs8a1lObY=", - "dev": true + "integrity": "sha1-CqYOyZiaCz7Xlc9NBvYs8a1lObY=" }, "object-keys": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", - "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", - "dev": true + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==" }, "object-visit": { "version": "1.0.1", @@ -9885,9 +9968,9 @@ "dev": true }, "popper.js": { - "version": "1.15.0", - "resolved": "https://registry.npmjs.org/popper.js/-/popper.js-1.15.0.tgz", - "integrity": "sha512-w010cY1oCUmI+9KwwlWki+r5jxKfTFDVoadl7MSrIujHU5MJ5OR6HTDj6Xo8aoR/QsA56x8jKjA59qGH4ELtrA==" + "version": "1.16.1", + "resolved": "https://registry.npmjs.org/popper.js/-/popper.js-1.16.1.tgz", + "integrity": "sha512-Wb4p1J4zyFTbM+u6WuO4XstYx4Ky9Cewe4DWrel7B0w6VVICvPwdOpotjzcf6eD8TsckVnIMNONQyPIUFOUbCQ==" }, "portfinder": { "version": "1.0.25", @@ -10894,9 +10977,9 @@ } }, "react-day-picker": { - "version": "7.4.0", - "resolved": "https://registry.npmjs.org/react-day-picker/-/react-day-picker-7.4.0.tgz", - "integrity": "sha512-dqfr96EY7mHSpbW23hJI6of2JvxClDfHLNQ7VqctxBvNsJIzEiwh3zS8hEhqNza7xuR0vC4KN517zxndgb3/fw==", + "version": "7.4.8", + "resolved": "https://registry.npmjs.org/react-day-picker/-/react-day-picker-7.4.8.tgz", + "integrity": "sha512-pp0hnxFVoRuBQcRdR1Hofw4CQtOCGVmzCNrscyvS0Q8NEc+UiYLEDqE5dk37bf0leSnBW4lheIt0CKKhuKzDVw==", "requires": { "prop-types": "^15.6.2" } @@ -10934,16 +11017,32 @@ "integrity": "sha512-fBASbA6LnOU9dOU2eW7aQ8xmYBSXUIWr+UmF9b1efZBazGNO+rcXT/icdKnYm2pTwcRylVUYwW7H1PHfLekVzA==" }, "react-popper": { - "version": "1.3.4", - "resolved": "https://registry.npmjs.org/react-popper/-/react-popper-1.3.4.tgz", - "integrity": "sha512-9AcQB29V+WrBKk6X7p0eojd1f25/oJajVdMZkywIoAV6Ag7hzE1Mhyeup2Q1QnvFRtGQFQvtqfhlEoDAPfKAVA==", + "version": "1.3.7", + "resolved": "https://registry.npmjs.org/react-popper/-/react-popper-1.3.7.tgz", + "integrity": "sha512-nmqYTx7QVjCm3WUZLeuOomna138R1luC4EqkW3hxJUrAe+3eNz3oFCLYdnPwILfn0mX1Ew2c3wctrjlUMYYUww==", "requires": { "@babel/runtime": "^7.1.2", "create-react-context": "^0.3.0", + "deep-equal": "^1.1.1", "popper.js": "^1.14.4", "prop-types": "^15.6.1", "typed-styles": "^0.0.7", "warning": "^4.0.2" + }, + "dependencies": { + "deep-equal": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/deep-equal/-/deep-equal-1.1.1.tgz", + "integrity": "sha512-yd9c5AdiqVcR+JjcwUQb9DkhJc8ngNr0MahEBGvDiJw8puWab2yZlh+nkasOnZP+EGTAP6rRp2JzJhJZzvNF8g==", + "requires": { + "is-arguments": "^1.0.4", + "is-date-object": "^1.0.1", + "is-regex": "^1.0.4", + "object-is": "^1.0.1", + "object-keys": "^1.1.1", + "regexp.prototype.flags": "^1.2.0" + } + } } }, "react-router": { @@ -11221,7 +11320,6 @@ "version": "1.2.0", "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.2.0.tgz", "integrity": "sha512-ztaw4M1VqgMwl9HlPpOuiYgItcHlunW0He2fE6eNfT6E/CF2FtYi9ofOYe4mKntstYk0Fyh/rDRBdS3AnxjlrA==", - "dev": true, "requires": { "define-properties": "^1.1.2" } diff --git a/web-console/package.json b/web-console/package.json index f8266e548c6a..f7cc8368063f 100644 --- a/web-console/package.json +++ b/web-console/package.json @@ -52,13 +52,13 @@ "sasslint-changed-only": "git diff --diff-filter=ACMR --name-only | grep -E \\.scss$ | xargs ./node_modules/.bin/stylelint --config sasslint.json", "sasslint-fix-changed-only": "npm run sasslint-changed-only -- --fix", "generate-licenses-file": "license-checker --production --json --out licenses.json", - "check-licenses": "license-checker --production --onlyAllow 'Apache-1.1;Apache-2.0;BSD-2-Clause;BSD-3-Clause;MIT;CC0-1.0' --summary", + "check-licenses": "license-checker --production --onlyAllow 'Apache-1.1;Apache-2.0;BSD-2-Clause;BSD-3-Clause;0BSD;MIT;CC0-1.0' --summary", "start": "webpack-dev-server --hot --open" }, "dependencies": { - "@blueprintjs/core": "^3.19.1", - "@blueprintjs/datetime": "^3.11.0", - "@blueprintjs/icons": "^3.11.0", + "@blueprintjs/core": "^3.33.0", + "@blueprintjs/datetime": "^3.19.2", + "@blueprintjs/icons": "^3.22.0", "axios": "^0.19.0", "brace": "^0.11.1", "classnames": "^2.2.6", @@ -70,6 +70,7 @@ "d3-selection": "^1.4.0", "druid-query-toolkit": "^0.9.15", "file-saver": "^2.0.2", + "fontsource-open-sans": "^3.0.9", "has-own-prop": "^2.0.0", "hjson": "^3.2.1", "lodash.debounce": "^4.0.8", @@ -119,6 +120,7 @@ "enzyme": "^3.10.0", "enzyme-adapter-react-16": "^1.15.1", "enzyme-to-json": "^3.4.3", + "file-loader": "^6.1.1", "fs-extra": "^8.1.0", "identity-obj-proxy": "^3.0.0", "ignore-styles": "^5.0.1", diff --git a/web-console/script/licenses b/web-console/script/licenses index 0ca2834d8dc8..82522f9980c1 100755 --- a/web-console/script/licenses +++ b/web-console/script/licenses @@ -41,6 +41,17 @@ const extraLinesForLib = { ***************************************************************************** */` } +const extraPackages = { + // This is a OSS font so it is not listed by the npm scraper but we still want to attribute it so pretend to inject it + // as a phantom package + 'opensans@1.101.0': { + licenses: 'Apache-2.0', + repository: 'https://github.com/google/fonts/tree/master/apache/opensans', + publisher: 'Google', + url: 'https://fonts.google.com/specimen/Open+Sans', + } +} + function injectConsoleLicenses(consoleLicenses) { const text = fs.readFileSync(LICENSES_FILE, 'utf-8'); const textLines = text.split('\n'); @@ -91,6 +102,8 @@ checker.init( return; } + Object.assign(packages, extraPackages); + const seen = {}; const mapped = Object.keys(packages) .sort() diff --git a/web-console/src/blueprint-overrides/_index.scss b/web-console/src/blueprint-overrides/_index.scss index 0c058ce016f4..821d8a395d6f 100644 --- a/web-console/src/blueprint-overrides/_index.scss +++ b/web-console/src/blueprint-overrides/_index.scss @@ -17,3 +17,9 @@ */ @import 'common/colors'; +@import 'common/color-aliases'; +@import 'common/variables'; +@import 'components/button/common'; +@import 'components/forms/common'; +@import 'components/navbar/navbar'; +@import 'components/card/card'; diff --git a/web-console/src/blueprint-overrides/common/_color-aliases.scss b/web-console/src/blueprint-overrides/common/_color-aliases.scss new file mode 100644 index 000000000000..12efa49356e1 --- /dev/null +++ b/web-console/src/blueprint-overrides/common/_color-aliases.scss @@ -0,0 +1,58 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +$pt-intent-primary: $blue3; +$pt-intent-success: $green3; +$pt-intent-warning: $orange3; +$pt-intent-danger: $red3; + +$pt-app-background-color: $light-gray5; +$pt-dark-app-background-color: $dark-gray3; + +$pt-outline-color: rgba($blue3, 0.6); + +$pt-text-color: $dark-gray1; +$pt-text-color-muted: $gray1; +$pt-text-color-disabled: rgba($pt-text-color-muted, 0.6); +$pt-heading-color: $pt-text-color; +$pt-link-color: $blue2; +$pt-dark-text-color: $light-gray5; +$pt-dark-text-color-muted: $gray4; +$pt-dark-text-color-disabled: rgba($pt-dark-text-color-muted, 1); +$pt-dark-heading-color: $pt-dark-text-color; +$pt-dark-link-color: $blue5; +// Default text selection color using #7dbcff +$pt-text-selection-color: rgba(125, 188, 255, 0.6); + +$pt-icon-color: $pt-text-color-muted; +$pt-icon-color-hover: $pt-text-color; +$pt-icon-color-disabled: $pt-text-color-disabled; +$pt-icon-color-selected: $pt-intent-primary; +$pt-dark-icon-color: $pt-dark-text-color-muted; +$pt-dark-icon-color-hover: $pt-dark-text-color; +$pt-dark-icon-color-disabled: $pt-dark-text-color-disabled; +$pt-dark-icon-color-selected: $pt-intent-primary; + +$pt-divider-black: rgba($black, 0.15); +$pt-dark-divider-black: rgba($black, 0.4); +$pt-dark-divider-white: rgba($white, 0.15); + +$pt-code-text-color: $pt-text-color-muted; +$pt-dark-code-text-color: $pt-dark-text-color-muted; +$pt-code-background-color: rgba($white, 0.7); +$pt-dark-code-background-color: rgba($black, 0.3); diff --git a/web-console/src/blueprint-overrides/common/_colors.scss b/web-console/src/blueprint-overrides/common/_colors.scss index 92e532c385f1..ca10be55628d 100644 --- a/web-console/src/blueprint-overrides/common/_colors.scss +++ b/web-console/src/blueprint-overrides/common/_colors.scss @@ -16,8 +16,114 @@ * limitations under the License. */ -$blue1: #0e5a8a; -$blue2: #106ba3; -$blue3: #137cbe; // Changed as a proof of concept -$blue4: #2b95d6; -$blue5: #48aff0; +// Gray scale + +$black: #0f1320; // Changed + +$dark-gray1: #181c2d; // Changed +$dark-gray2: #24283b; +$dark-gray3: #2f344e; +$dark-gray4: #383d57; +$dark-gray5: #414765; + +$gray1: #606580; // Changed +$gray2: #787d96; +$gray3: #8489a1; +$gray4: #a1a6ba; +$gray5: #bdc1d1; + +$light-gray1: #cdd4e0; // Changed +$light-gray2: #dce0e9; +$light-gray3: #e2e6ed; +$light-gray4: #edeff3; +$light-gray5: #f4f5f8; + +$white: #ffffff; + +// Core colors + +$blue1: #115794; // Changed +$blue2: #1367af; +$blue3: #0083dc; +$blue4: #1f95e5; +$blue5: #3eadf9; + +$green1: #0a6640; +$green2: #0d8050; +$green3: #0f9960; +$green4: #15b371; +$green5: #3dcc91; + +$orange1: #a66321; +$orange2: #bf7326; +$orange3: #d9822b; +$orange4: #f29d49; +$orange5: #ffb366; + +$red1: #a82a2a; +$red2: #c23030; +$red3: #db3737; +$red4: #f55656; +$red5: #ff7373; + +// Extended colors + +$vermilion1: #9e2b0e; +$vermilion2: #b83211; +$vermilion3: #d13913; +$vermilion4: #eb532d; +$vermilion5: #ff6e4a; + +$rose1: #a82255; +$rose2: #c22762; +$rose3: #db2c6f; +$rose4: #f5498b; +$rose5: #ff66a1; + +$violet1: #5c255c; +$violet2: #752f75; +$violet3: #8f398f; +$violet4: #a854a8; +$violet5: #c274c2; + +$indigo1: #5642a6; +$indigo2: #634dbf; +$indigo3: #7157d9; +$indigo4: #9179f2; +$indigo5: #ad99ff; + +$cobalt1: #1f4b99; +$cobalt2: #2458b3; +$cobalt3: #2965cc; +$cobalt4: #4580e6; +$cobalt5: #669eff; + +$turquoise1: #008075; +$turquoise2: #00998c; +$turquoise3: #00b3a4; +$turquoise4: #14ccbd; +$turquoise5: #2ee6d6; + +$forest1: #1d7324; +$forest2: #238c2c; +$forest3: #29a634; +$forest4: #43bf4d; +$forest5: #62d96b; + +$lime1: #728c23; +$lime2: #87a629; +$lime3: #9bbf30; +$lime4: #b6d94c; +$lime5: #d1f26d; + +$gold1: #a67908; +$gold2: #bf8c0a; +$gold3: #d99e0b; +$gold4: #f2b824; +$gold5: #ffc940; + +$sepia1: #63411e; +$sepia2: #7d5125; +$sepia3: #96622d; +$sepia4: #b07b46; +$sepia5: #c99765; diff --git a/web-console/src/blueprint-overrides/common/_variables.scss b/web-console/src/blueprint-overrides/common/_variables.scss new file mode 100644 index 000000000000..bc82f53cd6d1 --- /dev/null +++ b/web-console/src/blueprint-overrides/common/_variables.scss @@ -0,0 +1,112 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// Namespace appended to the beginning of each CSS class: `.#{$ns}-button`. +// Do not quote this value, for Less consumers. +$ns: bp3; + +// easily the most important variable, so it comes up top +// (so other variables can use it to define themselves) +$pt-grid-size: 10px; + +// see https://bitsofco.de/the-new-system-font-stack/ +$pt-font-family: 'Open Sans', -apple-system, 'BlinkMacSystemFont', 'Segoe UI', 'Roboto', 'Oxygen', + 'Ubuntu', 'Cantarell', 'Helvetica Neue', 'Icons16', + // support inline Palantir icons + sans-serif; + +$pt-font-family-monospace: monospace; + +$pt-font-size: $pt-grid-size * 1.3; +$pt-font-size-large: $pt-grid-size * 1.6; +$pt-font-size-small: $pt-grid-size * 1.2; + +// a little bit extra to ensure the height comes out to just over 18px (and browser rounds to 18px) +$pt-line-height: ($pt-grid-size * 1.8) / $pt-font-size + 0.0001; + +// Icon variables + +$icons16-family: 'Icons16'; +$icons20-family: 'Icons20'; + +$pt-icon-size-standard: 16px; +$pt-icon-size-large: 20px; + +// Grids & dimensions + +$pt-border-radius: 3px; + +// Buttons +$pt-button-height: $pt-grid-size * 3; +$pt-button-height-small: $pt-grid-size * 2.4; +$pt-button-height-smaller: $pt-grid-size * 2; +$pt-button-height-large: $pt-grid-size * 4; + +// Inputs +$pt-input-height: $pt-grid-size * 3; +$pt-input-height-large: $pt-grid-size * 4; +$pt-input-height-small: $pt-grid-size * 2.4; + +// Others +$pt-navbar-height: $pt-grid-size * 5; + +// Z-indices +$pt-z-index-base: 0; +$pt-z-index-content: $pt-z-index-base + 10; +$pt-z-index-overlay: $pt-z-index-content + 10; + +// Shadow opacities +$pt-border-shadow-opacity: 0.1; +$pt-drop-shadow-opacity: 0.16; +$pt-dark-border-shadow-opacity: $pt-border-shadow-opacity * 2.8; +$pt-dark-drop-shadow-opacity: $pt-drop-shadow-opacity * 2.8; + +// Elevations +// all shadow lists must be the same length to avoid flicker in transitions. +$pt-elevation-shadow-0: 0 0 0 transparent; +$pt-elevation-shadow-1: 0 1px 3px rgba($black, $pt-drop-shadow-opacity); +$pt-elevation-shadow-2: 0 3px 9px rgba($black, $pt-drop-shadow-opacity); +$pt-elevation-shadow-3: 0 5px 15px rgba($black, $pt-drop-shadow-opacity); +$pt-elevation-shadow-4: 0 8px 24px rgba($black, $pt-drop-shadow-opacity); + +$pt-dark-elevation-shadow-0: 0 0 0 transparent; +$pt-dark-elevation-shadow-1: 0 1px 3px rgba($black, $pt-dark-drop-shadow-opacity); +$pt-dark-elevation-shadow-2: 0 3px 9px rgba($black, $pt-dark-drop-shadow-opacity); +$pt-dark-elevation-shadow-3: 0 5px 15px rgba($black, $pt-dark-drop-shadow-opacity); +$pt-dark-elevation-shadow-4: 0 8px 24px rgba($black, $pt-dark-drop-shadow-opacity); + +// Transitions +$pt-transition-ease: cubic-bezier(0.4, 1, 0.75, 0.9); +$pt-transition-ease-bounce: cubic-bezier(0.4, 1, 0.75, 0.9); +$pt-transition-duration: 30ms; + +// Light theme styles + +$pt-input-box-shadow: 0 0 0 1px rgba($black, 0.12), inset 0 1px 3px 0 rgba($black, 0.12); + +$pt-dialog-box-shadow: $pt-elevation-shadow-4; +$pt-popover-box-shadow: $pt-elevation-shadow-3; +$pt-tooltip-box-shadow: $pt-popover-box-shadow; + +// Dark theme styles + +$pt-dark-input-box-shadow: 0 0 0 1px rgba($black, 0.4), inset 0 1px 3px 0 rgba($black, 0.5); + +$pt-dark-dialog-box-shadow: $pt-dark-elevation-shadow-4; +$pt-dark-popover-box-shadow: $pt-dark-elevation-shadow-3; +$pt-dark-tooltip-box-shadow: $pt-dark-popover-box-shadow; diff --git a/web-console/src/blueprint-overrides/components/button/_common.scss b/web-console/src/blueprint-overrides/components/button/_common.scss new file mode 100644 index 000000000000..0b1c2185abb3 --- /dev/null +++ b/web-console/src/blueprint-overrides/components/button/_common.scss @@ -0,0 +1,112 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +$button-border-width: 1px; +$button-padding: ($pt-grid-size / 2) ($pt-grid-size * 1.3); +$button-padding-small: 0 ($pt-grid-size * 0.7); +$button-padding-large: ($pt-grid-size / 2) ($pt-grid-size * 1.5); +$button-icon-spacing: ($pt-button-height - $pt-icon-size-standard) / 1.6; +$button-icon-spacing-large: ($pt-button-height-large - $pt-icon-size-large) / 1.8; + +/* +CSS `border` property issues: +- An element can only have one border. +- Borders can't stack with shadows. +- Borders modify the size of the element they're applied to. +- Border positioning requires the extra `box-sizing` property. + +`box-shadow` doesn't have these issues, we're using it instead of `border`. +*/ +$button-box-shadow: inset 0 0 0 $button-border-width rgba($black, 0.2), + inset 0 (-$button-border-width) 0 rgba($black, 0.1); +$button-box-shadow-active: inset 0 0 0 $button-border-width rgba($black, 0.2), + inset 0 1px 2px rgba($black, 0.2); +$button-intent-box-shadow: none; +$button-intent-box-shadow-active: none; + +/* +Overlay shadows are used for default buttons +floating on top of other elements. This way, the +shadows blend with the colors beneath it. +Switches and slider handles both use these variables. +*/ +$button-box-shadow-overlay: 0 0 0 $button-border-width rgba($black, 0.2), + 0 1px 1px rgba($black, 0.2); +$button-box-shadow-overlay-active: 0 0 0 $button-border-width rgba($black, 0.2), + inset 0 1px 1px rgba($black, 0.1); + +$dark-button-box-shadow: 0 0 0 $button-border-width rgba($black, 0.4); +$dark-button-box-shadow-active: 0 0 0 $button-border-width rgba($black, 0.6), + inset 0 1px 2px rgba($black, 0.2); +$dark-button-intent-box-shadow: none; +$dark-button-intent-box-shadow-active: none; + +$button-gradient: none; +$button-intent-gradient: none; +$dark-button-gradient: none; + +$button-color-disabled: $pt-text-color-disabled; +$button-background-color: white; +$button-background-color-hover: $light-gray4; +$button-background-color-active: $light-gray2; +$button-background-color-disabled: rgba($light-gray1, 0.5); +$button-background-color-active-disabled: rgba($light-gray1, 0.7); +$button-intent-color-disabled: rgba($white, 0.6); +$dark-button-color-disabled: $pt-dark-text-color-disabled; +$dark-button-background-color: $dark-gray4; +$dark-button-background-color-hover: $dark-gray5; +$dark-button-background-color-active: $dark-gray2; +$dark-button-background-color-disabled: rgba($dark-gray5, 0.5); +$dark-button-background-color-active-disabled: rgba($dark-gray5, 0.7); +$dark-button-intent-color-disabled: rgba($white, 0.3); + +$minimal-button-divider-width: 1px; +$minimal-button-background-color: none; +$minimal-button-background-color-hover: rgba($gray4, 0.3); +$minimal-button-background-color-active: rgba($gray2, 0.3); +$dark-minimal-button-background-color: none; +$dark-minimal-button-background-color-hover: rgba($gray3, 0.15); +$dark-minimal-button-background-color-active: rgba($gray3, 0.3); + +$button-outlined-width: 1px; +$button-outlined-border-intent-opacity: 0.6; +$button-outlined-border-disabled-intent-opacity: 0.2; + +// "intent": (default, hover, active colors) +$button-intents: ( + 'primary': ( + $pt-intent-primary, + $blue2, + $blue1, + ), + 'success': ( + $pt-intent-success, + $green2, + $green1, + ), + 'warning': ( + $pt-intent-warning, + $orange2, + $orange1, + ), + 'danger': ( + $pt-intent-danger, + $red2, + $red1, + ), +); diff --git a/web-console/src/blueprint-overrides/components/card/_card.scss b/web-console/src/blueprint-overrides/components/card/_card.scss new file mode 100644 index 000000000000..02d67890a728 --- /dev/null +++ b/web-console/src/blueprint-overrides/components/card/_card.scss @@ -0,0 +1,22 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +$card-padding: $pt-grid-size * 2; + +$card-background-color: $white; +$dark-card-background-color: $dark-gray3; diff --git a/web-console/src/blueprint-overrides/components/forms/_common.scss b/web-console/src/blueprint-overrides/components/forms/_common.scss new file mode 100644 index 000000000000..7d788fb5d34e --- /dev/null +++ b/web-console/src/blueprint-overrides/components/forms/_common.scss @@ -0,0 +1,43 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +$input-padding-horizontal: $pt-grid-size; +$input-small-padding: $pt-input-height-small - $pt-icon-size-standard; +$input-font-weight: 400; +$input-transition: box-shadow $pt-transition-duration $pt-transition-ease; + +$input-color: $pt-text-color; +$input-color-disabled: $button-color-disabled; +$input-placeholder-color: $pt-text-color-disabled; +$input-background-color: $white; +$input-background-color-disabled: rgba($light-gray1, 0.5); +$input-shadow-color-focus: $pt-intent-primary; + +$dark-input-color: $pt-dark-text-color; +$dark-input-color-disabled: $dark-button-color-disabled; +$dark-input-placeholder-color: $pt-dark-text-color-disabled; +$dark-input-background-color: $dark-gray4; +$dark-input-background-color-disabled: rgba($dark-gray5, 0.5); +$dark-input-shadow-color-focus: $pt-intent-primary; + +$control-indicator-size: $pt-icon-size-standard; +$control-indicator-size-large: $pt-icon-size-large; + +// avoids edge blurriness for light theme focused default input +// second box-shadow of $pt-input-box-shadow +$input-box-shadow-focus: inset 0 0 0 1px transparent; diff --git a/web-console/src/blueprint-overrides/components/navbar/_navbar.scss b/web-console/src/blueprint-overrides/components/navbar/_navbar.scss new file mode 100644 index 000000000000..95f608533064 --- /dev/null +++ b/web-console/src/blueprint-overrides/components/navbar/_navbar.scss @@ -0,0 +1,22 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +$navbar-padding: $pt-grid-size * 1.5; + +$navbar-background-color: $white; +$dark-navbar-background-color: $dark-gray3; diff --git a/web-console/src/bootstrap/react-table-custom-pagination.scss b/web-console/src/bootstrap/react-table-custom-pagination.scss index 3d6a18b0f756..1acacfe6633c 100644 --- a/web-console/src/bootstrap/react-table-custom-pagination.scss +++ b/web-console/src/bootstrap/react-table-custom-pagination.scss @@ -16,21 +16,32 @@ * limitations under the License. */ +@import '../blueprint-overrides/common/colors'; +@import '../blueprint-overrides/common/variables'; + .ReactTable { .-pageJump { .bp3-input { - background-color: #374653; position: relative; top: -2px; + border: none; + + .bp3-dark & { + background-color: $dark-gray4; + } } } .-pageSizeOptions { .bp3-html-select select { - background-color: #394b59; width: 90px; position: relative; top: -2px; + border: none; + + .bp3-dark & { + background-color: $dark-gray4; + } } } } diff --git a/web-console/src/components/auto-form/__snapshots__/auto-form.spec.tsx.snap b/web-console/src/components/auto-form/__snapshots__/auto-form.spec.tsx.snap index 544177ae1bdc..1a4000ef00fb 100644 --- a/web-console/src/components/auto-form/__snapshots__/auto-form.spec.tsx.snap +++ b/web-console/src/components/auto-form/__snapshots__/auto-form.spec.tsx.snap @@ -12,6 +12,7 @@ exports[`auto-form snapshot matches snapshot 1`] = ` allowNumericCharactersOnly={true} buttonPosition="right" clampValueOnBlur={false} + defaultValue="" disabled={false} fill={true} large={false} @@ -24,7 +25,6 @@ exports[`auto-form snapshot matches snapshot 1`] = ` selectAllOnFocus={false} selectAllOnIncrement={false} stepSize={1} - value="" /> `; + +exports[`BracedText matches snapshot with padFractionalPart 1`] = ` + + + 00,000.000 + + + 23.3 + + 00 + + + +`; diff --git a/web-console/src/components/braced-text/braced-text.scss b/web-console/src/components/braced-text/braced-text.scss index 76ccb0a9c11d..872cfd70493d 100644 --- a/web-console/src/components/braced-text/braced-text.scss +++ b/web-console/src/components/braced-text/braced-text.scss @@ -34,5 +34,9 @@ right: 0; top: 0; bottom: 0; + + .zero-pad { + visibility: hidden; + } } } diff --git a/web-console/src/components/braced-text/braced-text.spec.tsx b/web-console/src/components/braced-text/braced-text.spec.tsx index 3beb7948e55a..2df4be704f86 100644 --- a/web-console/src/components/braced-text/braced-text.spec.tsx +++ b/web-console/src/components/braced-text/braced-text.spec.tsx @@ -27,4 +27,12 @@ describe('BracedText', () => { expect(bracedText).toMatchSnapshot(); }); + + it('matches snapshot with padFractionalPart', () => { + const bracedText = shallow( + , + ); + + expect(bracedText).toMatchSnapshot(); + }); }); diff --git a/web-console/src/components/braced-text/braced-text.tsx b/web-console/src/components/braced-text/braced-text.tsx index ff517eaa2cd0..71d4491d7086 100644 --- a/web-console/src/components/braced-text/braced-text.tsx +++ b/web-console/src/components/braced-text/braced-text.tsx @@ -16,6 +16,7 @@ * limitations under the License. */ +import { max } from 'd3-array'; import React from 'react'; import './braced-text.scss'; @@ -23,6 +24,7 @@ import './braced-text.scss'; export interface BracedTextProps { text: string; braces: string[]; + padFractionalPart?: boolean; } export function findMostNumbers(strings: string[]): string { @@ -43,13 +45,54 @@ export function findMostNumbers(strings: string[]): string { return longest; } +function lengthAfterLastDot(str: string): number | undefined { + const parts = str.split('.'); + const n = parts.length; + if (n < 2) return; + return parts[n - 1].length; +} + +function zerosOfLength(n: number): string { + return new Array(n + 1).join('0'); +} + export const BracedText = React.memo(function BracedText(props: BracedTextProps) { - const { text, braces } = props; + const { text, braces, padFractionalPart } = props; + + let effectiveBraces = braces.concat(text); + + let zeroPad: JSX.Element | undefined; + if (padFractionalPart) { + const lengthsAfterDot = effectiveBraces.map(lengthAfterLastDot); + const maxLengthAfterLastDot = max(lengthsAfterDot, x => x); + if (maxLengthAfterLastDot) { + const textLengthAfterLastDot = lengthAfterLastDot(text); + if (typeof textLengthAfterLastDot !== 'undefined') { + const padLength = Math.max(maxLengthAfterLastDot - textLengthAfterLastDot, 0); + zeroPad = {zerosOfLength(padLength)}; + } else { + zeroPad = {`.${zerosOfLength(maxLengthAfterLastDot)}`}; + } + + effectiveBraces = effectiveBraces.map((brace, i) => { + const braceLengthAfterLastDot = lengthsAfterDot[i]; + if (typeof braceLengthAfterLastDot !== 'undefined') { + const padLength = Math.max(maxLengthAfterLastDot - braceLengthAfterLastDot, 0); + return `${brace}${zerosOfLength(padLength)}`; + } else { + return `${brace}.${zerosOfLength(maxLengthAfterLastDot)}`; + } + }); + } + } return ( - {findMostNumbers(braces.concat(text))} - {text} + {findMostNumbers(effectiveBraces)} + + {text} + {zeroPad} + ); }); diff --git a/web-console/src/components/header-bar/header-bar.scss b/web-console/src/components/header-bar/header-bar.scss index d21c922ca45d..30365db3be04 100644 --- a/web-console/src/components/header-bar/header-bar.scss +++ b/web-console/src/components/header-bar/header-bar.scss @@ -17,6 +17,7 @@ */ @import '../../variables'; +@import '../../blueprint-overrides/common/colors'; .header-bar { overflow: hidden; @@ -32,11 +33,57 @@ top: 50%; left: 50%; transform: translate(-50%, -50%); - height: 75px; + height: 48px; + + .letter { + fill: $dark-gray2; + } + + .swirl { + fill: $druid-brand2; + } + + .bp3-dark & { + .letter { + fill: $white; + } + + .swirl { + fill: $druid-brand; + } + } } } * { white-space: nowrap; } + + .bp3-navbar-divider { + margin: 0 11px; + } + + .bp3-button.bp3-minimal { + border-radius: 20px; + margin: 0 1px; + + .bp3-icon { + svg { + fill: $blue3; + + .bp3-dark & { + fill: $druid-brand; + } + } + } + .bp3-dark & { + &:hover { + background: rgba($dark-gray5, 0.5); + } + + &.bp3-active { + background: rgba($dark-gray5, 0.9); + } + } + } } diff --git a/web-console/src/components/header-bar/header-bar.tsx b/web-console/src/components/header-bar/header-bar.tsx index 31cd0fdbf5c4..01e48a881620 100644 --- a/web-console/src/components/header-bar/header-bar.tsx +++ b/web-console/src/components/header-bar/header-bar.tsx @@ -58,54 +58,16 @@ export type HeaderActiveTab = const DruidLogo = React.memo(function DruidLogo() { return (
- + - - - -
diff --git a/web-console/src/components/interval-input/interval-input.tsx b/web-console/src/components/interval-input/interval-input.tsx index b56780e6662a..2360b3609305 100644 --- a/web-console/src/components/interval-input/interval-input.tsx +++ b/web-console/src/components/interval-input/interval-input.tsx @@ -33,14 +33,14 @@ function removeLocalTimezone(localDate: Date): Date { function parseInterval(interval: string): DateRange { const dates = interval.split('/'); if (dates.length !== 2) { - return [undefined, undefined]; + return [null, null]; } - const startDate = Date.parse(dates[0]) ? new Date(dates[0]) : undefined; - const endDate = Date.parse(dates[1]) ? new Date(dates[1]) : undefined; + const startDate = Date.parse(dates[0]) ? new Date(dates[0]) : null; + const endDate = Date.parse(dates[1]) ? new Date(dates[1]) : null; // Must check if the start and end dates are within range return [ - startDate && startDate.getFullYear() < CURRENT_YEAR - 20 ? undefined : startDate, - endDate && endDate.getFullYear() > CURRENT_YEAR ? undefined : endDate, + startDate && startDate.getFullYear() < CURRENT_YEAR - 20 ? null : startDate, + endDate && endDate.getFullYear() > CURRENT_YEAR ? null : endDate, ]; } function stringifyDateRange(localRange: DateRange): string { diff --git a/web-console/src/components/json-collapse/__snapshots__/json-collapse.spec.tsx.snap b/web-console/src/components/json-collapse/__snapshots__/json-collapse.spec.tsx.snap index fb28b32c5f57..904346cff79f 100644 --- a/web-console/src/components/json-collapse/__snapshots__/json-collapse.spec.tsx.snap +++ b/web-console/src/components/json-collapse/__snapshots__/json-collapse.spec.tsx.snap @@ -1,29 +1,31 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP -exports[`json collapse matches snapshot 1`] = ` +exports[`JsonCollapse matches snapshot 1`] = `
- -
-
-
-
+
+ + +
`; diff --git a/web-console/src/components/json-collapse/json-collapse.scss b/web-console/src/components/json-collapse/json-collapse.scss new file mode 100644 index 000000000000..1f6a3d256521 --- /dev/null +++ b/web-console/src/components/json-collapse/json-collapse.scss @@ -0,0 +1,34 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +.json-collapse { + .collapse-buttons { + height: 30px; + margin-bottom: 5px; + text-align: right; + + & > * { + display: inline-block; + } + } + + textarea { + width: 100%; + height: 100px; + } +} diff --git a/web-console/src/components/json-collapse/json-collapse.spec.tsx b/web-console/src/components/json-collapse/json-collapse.spec.tsx index 2b3293593f63..33dbd8b89073 100644 --- a/web-console/src/components/json-collapse/json-collapse.spec.tsx +++ b/web-console/src/components/json-collapse/json-collapse.spec.tsx @@ -16,17 +16,16 @@ * limitations under the License. */ -import { render } from '@testing-library/react'; +import { shallow } from 'enzyme'; import React from 'react'; import { JsonCollapse } from './json-collapse'; -describe('json collapse', () => { +describe('JsonCollapse', () => { it('matches snapshot', () => { - const jsonCollapse = ( - + const jsonCollapse = shallow( + , ); - const { container } = render(jsonCollapse); - expect(container.firstChild).toMatchSnapshot(); + expect(jsonCollapse).toMatchSnapshot(); }); }); diff --git a/web-console/src/components/json-collapse/json-collapse.tsx b/web-console/src/components/json-collapse/json-collapse.tsx index 6be4324c889b..09b4ee27c980 100644 --- a/web-console/src/components/json-collapse/json-collapse.tsx +++ b/web-console/src/components/json-collapse/json-collapse.tsx @@ -19,6 +19,8 @@ import { Button, Collapse, TextArea } from '@blueprintjs/core'; import React, { useState } from 'react'; +import './json-collapse.scss'; + interface JsonCollapseProps { stringValue: string; buttonText: string; @@ -31,12 +33,12 @@ export const JsonCollapse = React.memo(function JsonCollapse(props: JsonCollapse const prettyValue = JSON.stringify(JSON.parse(stringValue), undefined, 2); return (
-