Commit Graph

119 Commits

Author SHA1 Message Date
Paul van Tilburg 3251d098bd Add tests for the static file handler 2018-01-01 21:16:55 +01:00
Paul van Tilburg 8863b87c4e Add tests for the home handler 2018-01-01 21:16:47 +01:00
Paul van Tilburg e98324e3fe Move the tests for the list handlers to the right module
Also improve and expand the tests abit.  Use serde_json to parse the
results an interpret them instead on depending on response body string
matching (which fails for changing mtimes of the test files).
2018-01-01 21:15:30 +01:00
Paul van Tilburg d167c50918 Move the convert_to_html code back into to_html of the list again
The module function was never used outside of the context of a list
anymore.
2018-01-01 21:13:51 +01:00
Paul van Tilburg 810d087508 Add some tests for the list handlers 2018-01-01 18:37:26 +01:00
Paul van Tilburg 4b33969427 Add support for specifying a custom lists dir at startup-time 2018-01-01 18:36:58 +01:00
Paul van Tilburg 2ff634a01b Fix bold text example in Markdown help 2018-01-01 15:06:07 +01:00
Paul van Tilburg 05b2f88cbc Remove unnecessary use 2018-01-01 14:22:33 +01:00
Paul van Tilburg f65fde7378 Move the List struct to a modules submodule
Move the state type ListStore back to main.rs, it is used for
a global state object (like a DB connection, etc.)
2017-12-30 22:23:16 +01:00
Paul van Tilburg 38801c5625 Split the handlers off into a handler submodules
Also move the list handlers to a separate mount point.
2017-12-30 22:06:48 +01:00
Paul van Tilburg 783a71488e No longer use small buttons
They are hard to use in the mobile setting.  Also, now that the text labels
are gone, it is not much of an issue anymore.
2017-12-30 17:20:04 +01:00
Paul van Tilburg ec1e384552 Tweak and add animations
* Add animations when hiding/showing the button toolbars
* Tweak the list select animations
2017-12-30 17:16:45 +01:00
Paul van Tilburg 673b58bdec Use a button toolbar and button group for easy hiding/showing 2017-12-30 17:14:20 +01:00
Paul van Tilburg 995bd82036 Fix typo 2017-12-30 16:49:45 +01:00
Paul van Tilburg 1f4beab939 Use icons instead of text labels for the buttons 2017-12-30 16:47:21 +01:00
Paul van Tilburg 99619d9e44 Add static assets of FontAwesome 5.0.2 2017-12-30 16:47:00 +01:00
Paul van Tilburg 6259b9b320 Move Bootstrap SCSS to static/
As a result the CSS maps an be used to trace the original line in the SCSS
in the browser inspector.  Also, move bootstrap to a subdir to distinguish
it from the SCSS of the app itself.
2017-12-30 16:23:25 +01:00
Paul van Tilburg c39a065550 Immediately collapse the navbar after selecting a list 2017-12-30 16:18:13 +01:00
Paul van Tilburg 95e217a84d Add a Markdown edit help popover for the textarea
Also add an edit help button during editing to toggle the popover.
The popover is placed next to the textarea and is removed when
exiting edit mode.
2017-12-30 16:16:59 +01:00
Paul van Tilburg dc9a9efe59 Reuse the updateList() function after saving 2017-12-30 16:16:26 +01:00
Paul van Tilburg af3a6183a5 Add different styling for all unordered lists that have checkboxes
These checkboxes are generated through the GFM tasklist extension.
In this case there should be not list item and the padding-left
should be removed.
2017-12-30 16:14:52 +01:00
Paul van Tilburg e795544dc3 Don't use card-link classes
The card-link class does also other things with padding and spacing.
Instead, apply the style override to all links in the list HTML.
2017-12-30 16:13:51 +01:00
Paul van Tilburg 8b798e1d30 Add some documentation to the custom SCSS 2017-12-30 14:07:42 +01:00
Paul van Tilburg a7a90ce84b Fix link support in list HTML
* Add the card-link class to all anchors in the HTML
* Override the default Bootstrap styling for links in card text
2017-12-30 14:06:46 +01:00
Paul van Tilburg c2baff37f3 Rename the lists index handler for consistency 2017-12-30 13:48:07 +01:00
Paul van Tilburg 51d3e876d6 Enable some extentions for the Markdown syntax
Enable the strikethrough, tagfilter, tasklist and autolink extensions
from the GFM spec.
2017-12-30 13:46:58 +01:00
Paul van Tilburg fe9a5f1f52 make the itemization padding relative 2017-12-30 13:46:43 +01:00
Paul van Tilburg e2c40756ab Fix itemization padding not being applied 2017-12-30 13:23:08 +01:00
Paul van Tilburg 09db743a9e Rework the entire UI to support multiple lists in one view
* The root location now shows all lists
* The specific list locations show only the specified list
* Each list can be individually edited
* Use the card columns (masonry) layout when showing all lists
* No longer support HTML previewing, just switch between editing
  and viewing (ala Github comments)
2017-12-29 23:56:24 +01:00
Paul van Tilburg 7f36f116a6 Switch to Sass based custom CSS
* Include the Bootstrap v4.0.0-beta3 SCSS sources
* Use the old custom.css as a basis for wishlist.scss
* Set the correct column count based on the media sizes
2017-12-29 23:55:12 +01:00
Paul van Tilburg cf045a0f79 Upgrade to Bootstrap 4.0.0-beta3 2017-12-29 23:52:02 +01:00
Paul van Tilburg 4f738891f2 Switch to using Bootstrap 4 cards 2017-12-29 20:20:10 +01:00
Paul van Tilburg 5ffd7bcd62 Fix list data not being replaced when switching lists 2017-12-29 19:55:28 +01:00
Paul van Tilburg b63019bfac Add a bit of documentation 2017-12-27 22:02:55 +01:00
Paul van Tilburg 15b8dbe614 Remove an old debug statement 2017-12-27 21:50:46 +01:00
Paul van Tilburg f9ee63c765 Apply the changed list data when saving is successful 2017-12-27 21:48:28 +01:00
Paul van Tilburg 370c260a94 Revert the updating when cancelling the edit 2017-12-27 21:47:54 +01:00
Paul van Tilburg 787839e36f Implement updating the list while editing it 2017-12-27 21:47:23 +01:00
Paul van Tilburg 85e25a9b5c Add the handler for converting temp list data to HTML 2017-12-27 21:32:16 +01:00
Paul van Tilburg b01d331742 Move the data to HTML conversion to a separate function
Sometimes data needs to be converted to HTML without it being list data
(yet).
2017-12-27 21:31:17 +01:00
Paul van Tilburg e709985ba2 Show the modification date/time using the "nl" locale 2017-12-27 21:20:17 +01:00
Paul van Tilburg 1f1e4ed079 Add the modification time to the List struct 2017-12-27 21:19:34 +01:00
Paul van Tilburg a952765328 Rework the styling of a list box 2017-12-27 20:57:20 +01:00
Paul van Tilburg 9be9808463 Save the data to the list file when updated 2017-12-27 20:56:54 +01:00
Paul van Tilburg c72b3d1669 Style the list name the same as the list box/body 2017-12-27 20:29:30 +01:00
Paul van Tilburg bc12c285a0 Fix lists not changing color when another one is selected 2017-12-27 20:28:34 +01:00
Paul van Tilburg 8f55d55388 Add favicons 2017-12-27 17:37:00 +01:00
Paul van Tilburg 7e17a33df6 Make the edit buttons smaller 2017-12-27 17:37:00 +01:00
Paul van Tilburg 3fbf6884ff Fix some edit mode switch weirdness 2017-12-27 17:37:00 +01:00
Paul van Tilburg 167eda78e9 Implement saving a list; make the lists mutable using an RW lock
It currently only saves to memory.  So, if the application restart,
the lists are back to what is in the list files.
2017-12-27 17:36:26 +01:00