From: Adam Dullage Date: Sat, 6 Aug 2022 18:39:04 +0000 (+0100) Subject: Implement SearchInput component X-Git-Url: http://git.99rst.org/?a=commitdiff_plain;h=936e80d09d5b6e0843775dfdea37cd324ab9e414;p=flatnotes.git Implement SearchInput component --- diff --git a/flatnotes/src/components/App.js b/flatnotes/src/components/App.js index 345a3e0..54442b9 100644 --- a/flatnotes/src/components/App.js +++ b/flatnotes/src/components/App.js @@ -5,6 +5,7 @@ import RecentlyModified from "./RecentlyModified"; import LoadingIndicator from "./LoadingIndicator"; import Login from "./Login"; import NavBar from "./NavBar"; +import SearchInput from "./SearchInput"; import api from "../api"; import * as constants from "../constants"; @@ -22,6 +23,7 @@ export default { LoadingIndicator, Login, NavBar, + SearchInput, }, data: function() { @@ -96,14 +98,6 @@ export default { this.navigate(`/${constants.basePaths.login}`); }, - search: function() { - this.navigate( - `/${constants.basePaths.search}?${ - constants.params.searchTerm - }=${encodeURI(this.searchTerm)}` - ); - }, - getSearchResults: function() { let parent = this; this.searchFailed = false; diff --git a/flatnotes/src/components/App.vue b/flatnotes/src/components/App.vue index 4539274..097dd87 100644 --- a/flatnotes/src/components/App.vue +++ b/flatnotes/src/components/App.vue @@ -68,24 +68,21 @@
-
-
- - -
-
- + +
@@ -137,20 +134,6 @@
- -
-
- -
-
-
diff --git a/flatnotes/src/constants.js b/flatnotes/src/constants.js index ffea299..329bb48 100644 --- a/flatnotes/src/constants.js +++ b/flatnotes/src/constants.js @@ -24,10 +24,10 @@ export const dataDefaults = function() { // Search Data searchFailed: false, - - // Note Data searchTerm: null, searchResults: null, + + // Note Data currentNote: null, titleInput: null, initialContent: null, diff --git a/flatnotes/src/main.scss b/flatnotes/src/main.scss index 941baba..f739830 100644 --- a/flatnotes/src/main.scss +++ b/flatnotes/src/main.scss @@ -28,10 +28,6 @@ body { font-family: "Inter", sans-serif; } -.cursor-pointer { - cursor: pointer; -} - .clickable-link { cursor: pointer; &:hover { @@ -61,8 +57,9 @@ body { padding: 0; } -.title-input:focus { - outline: none; +.form-control:focus { + box-shadow: none; + border-color: #ced4da; } .home-view {