Commit graph

97 commits

Author SHA1 Message Date
Baptiste Gelez
bdfad844d7
Edit blogs, and add blog icons and banners (#460)
Also adds a parameter to `md_to_html` to only render inline elements (so that we don't have titles or images in blog descriptions). And moves the delete button for the blog on the edition page.

I still have to update the SQLite migration once others PRs with migrations will be merged.

Also, there will be a problem when you edit a blog while not owning its banner or icon: when validating they will be reset to their default values… I don't see a good solution to this until we have a better way to handle uploads with Rocket (the same is probably happening for articles btw).

And the icon/banner are not federated yet, I don't know if I should add it to this PR or if it can come after?

![image](https://user-images.githubusercontent.com/16254623/53894510-7d853300-4030-11e9-8a2c-f5c0b0c7f512.png)
![image](https://user-images.githubusercontent.com/16254623/53894539-8b3ab880-4030-11e9-8113-685a27be8d7c.png)

Fixes #453
Fixes #454
2019-03-22 19:51:36 +01:00
fdb-hiroshima
a2b2e37aa0
Caching (#480)
* add basic caching support

* Use hash of static dir instead of rand

* Add support for ETag
2019-03-16 15:33:28 +01:00
Baptiste Gelez
9076dbaadc
New editor (#458)
With this PR, when JS is activated and WASM supported, the article editor will be dynamically replaced with `contenteditable`s elements. This makes the editing interface simpler and less like a regular form. It will also allow us to easily add visual formatting with native browser APIs (and to insert images or videos directly). Here is a little demo:

![peek 05-03-2019 16-12](https://user-images.githubusercontent.com/16254623/53815536-1dc05680-3f62-11e9-94d3-b363ed84eb97.gif)

There is still a lot to do, but it is a good first step.

Fixes #255
2019-03-15 16:06:10 +01:00
Kenneth Steimel
4ff56c6407 Added coloration for selections and contrasting (#476)
color for anchor elements when selected
2019-03-13 21:54:48 +01:00
Baptiste Gelez
eff2698664
Slightly improve the media experience (#452)
* Slightly improve the media experience

- Use a grid to display the list of media
- Add icons for non-image media preview
- Paginate the gallery
- Add links to the gallery in the editor and in the profile settings to make it more discoverable when you need it

Fixes #432

* Allow video and audio tags in SafeString

Otherwise we can't display their preview, nor show them in articles

Also show controls by default for these two elements

* Show fallback images for audio and unknown files, to make them more visible

* Add a new constructor to SafeString when the input is trusted and doesn't need to be escaped.

And use it to generate media previews.

* Make it possible to insert video/audio in articles
2019-03-06 14:11:36 +01:00
Dominique Feyer
09a26b4602 Better contrast for input fields (#417)
* Better contrat for input fields

This change set a white background for input field (text, select and textarea)
to have a better contrast with the page background and improve accessibility for
people with vision problem, and just crappy screen.

This change also remove the round corner for the input to have a clear difference
between editing field and buttons.

This max-width of the form element are a bit bigger too.

* Less space between label and input
2019-01-09 18:57:48 +01:00
Dominique Feyer
671c340aa8 Better header line height (#418)
This change also remote all units for line-height to have more consistent styles and better cascading support. This solve the too small line height for multi line header in article and also add styling for h1 to h6 (previously h3 to h6 was not styled at all)
2019-01-09 17:46:03 +01:00
Baptiste Gelez
3fce5d6a14
Use Rust for the front-end too (#374)
Rust can compile to WASM, so let's use it for front-end code as well.

To compile the front-end:

```
cargo install cargo-web
cargo web deploy -p plume-front
```
2018-12-25 11:51:40 +01:00
Marek Ľach
2621549f5e An attempt to fix disorted submit button on mobile devices like iPhone - please review (#370)
* Update _forms.scss

* Update _forms.scss

* Update _forms.scss
2018-12-23 17:30:57 +01:00
Baptiste Gelez
04625b3fea
Use Route159 for comment deletion button (#372)
For some reason it was not what was used.
2018-12-23 15:58:25 +01:00
fdb-hiroshima
5c5cf36b0d
Allow for comment deletion (#363)
* Allow for comment deletion

Receive and emit deletion activity
Add button to delete comment

* Remove debug print and fix copy-past typo

* Improve style of comment deletion button
2018-12-23 11:13:36 +01:00
Baptiste Gelez
9e799f2cf2
Use SCSS (#355)
- Use variables
- Split everything in various files

The SCSS is compiled with `cargo build`/`run`

I also fixed a few visual issues.
2018-12-15 22:06:27 +01:00
Baptiste Gelez
e139008d35 Fix reshare button style 2018-12-13 21:56:26 +01:00
fdb-hiroshima
e9f2f769be Add microformat tags (#341)
Close #229 
Adding `<div>` might have broken the layout in some places. I've tried to fix it, tell me if I missed it somewhere
2018-12-08 21:52:46 +01:00
Trinity Pointard
b4e4b497ee Works on template
Use uri! to generate links instead of hardcoded urls
Fix #110
Fix invalid links needing to be POST forms
Translate login message for boost and like directly from template
Put js for search in its own file
2018-12-07 12:10:03 +01:00
Baptiste Gelez
70af57c6e1
Use Ructe (#327)
All the template are now compiled at compile-time with the `ructe` crate.

I preferred to use it instead of askama because it allows more complex Rust expressions, where askama only supports a small subset of expressions and doesn't allow them everywhere (for instance, `{{ macro!() | filter }}` would result in a parsing error).

The diff is quite huge, but there is normally no changes in functionality.

Fixes #161 and unblocks #110 and #273
2018-12-06 18:54:16 +01:00
Baptiste Gelez
a64c4912cf
Add support for CW in comments (#308)
All the backend/federation code was already, I just added the UI 🤷‍♀️ 

Fixes #253
2018-11-07 15:57:31 +01:00
Baptiste Gelez
68a30cc80e Fix spacing for the delete article button 2018-10-31 15:22:49 +01:00
Baptiste Gelez
185cb5142a Better style for subtitles 2018-10-31 15:19:42 +01:00
Baptiste Gelez
1a49569bf2 Better style for <select> 2018-10-31 15:07:40 +01:00
Baptiste Gelez
4a2f5aeeeb Display article covers 2018-10-31 15:07:40 +01:00
Baptiste Gelez
f6227e7a42 Nicer default avatar 2018-10-31 15:03:21 +01:00
Baptiste Gelez
2e072affb5
Fix editor auto-expansion (#293) 2018-10-30 18:16:24 +01:00
Bat
14969d489c Save medias in static/media
Fixes #272
2018-10-12 20:32:34 +01:00
Bat
45c31b1c8a Add the new logo the header 2018-10-09 15:37:40 +01:00
Bat
d5ba8864c3 Import @trwnh's logos
I would have liked to merge their commits in Plume's repository, but I have no idea how it could be done.

For reference, here is the repository they come from: https://github.com/trwnh/plumeLogos
2018-10-09 15:22:07 +01:00
Dominik Pataky
31a3e6c825 Revert icon injection 2018-09-29 21:42:51 +02:00
Dominik Pataky
83c4387e94 Add link underline for main body; add link icon
Links in the main body part are now underlined on mouse hover.
<a> tags in the article content are expanded by an icon from
FontAwesome.

Fixes #140
2018-09-29 21:41:02 +02:00
Bat
d8ca1d70b7 Fix CSRF issues
GET routes are not protected against CSRF. This commit changes the needed URLs to
POST and replace simple links with forms.

Thanks @fdb-hiroshima for noticing it!
2018-09-19 18:13:07 +01:00
Bat
fcdd3d4c1a Don't compress avatars
Fixes #210
2018-09-09 21:41:55 +01:00
Bat
de3707983a Account deletion
Fixes #182
2018-09-09 20:49:24 +01:00
Bat
663627c375 Add a default avatar
Really ugly, but is all my skills are permitting
2018-09-09 17:02:16 +01:00
Bat
6c80002e43 Add some JavaScript to open an close the mobile menu
Fixes #75 but still works in Firefox mobile without JS (and it will in Chrome/Safari too
once :focus-within will be implemented there)
2018-09-08 14:05:38 +01:00
Bat
775162559e Improve user page on small screens
Center avatar's alt text, since the only fix to display them on a single line would
break valid avatars
2018-09-08 09:55:59 +01:00
Sorin Davidoi
df3bf1a488
fix(css): Add back outline
Removing outline without adding other indicators for focused content is an accessibility violation (try using Tab to navigate on the page - you can't tell where the focus is).

http://www.outlinenone.com/
2018-09-06 23:10:01 +02:00
Bat
b99e34f624 Better style for tags 2018-09-06 13:11:48 +01:00
Bat
5b3eca63e0 Make it possible to tag articles and display them 2018-09-05 21:18:27 +01:00
Bat
e16acf8436 Mobile style improvement
Stack items when possible
2018-09-05 18:35:23 +01:00
Bat
13a04198f0 Improve tabs on small screens 2018-09-05 18:07:39 +01:00
Bat
b66d4f73ce Reorganize the homepage 2018-09-05 18:03:02 +01:00
Bat
e3d31d2a0f Merge branch 'master' of github.com:Plume-org/Plume 2018-09-05 16:53:50 +01:00
Bat
99f04893bb Add tabs to the user profile 2018-09-05 16:41:31 +01:00
Bat
30cfd96e24 Add tabs to the different feeds 2018-09-05 16:19:57 +01:00
Madeorsk
a30b99f93e Merge branch 'master' of https://github.com/Plume-org/Plume into icons 2018-09-04 21:55:44 +02:00
Madeorsk
4330600980 Show and animate .mobile-label on normal screens. 2018-09-04 21:17:30 +02:00
Madeorsk
a3a25eec6c Icons update: removed FontAwesome, added Feather icons.
- FontAwesome icons.
+ Feather font.
+ Feather svg sprites.
+ Icons for Login / Register.
* Improved mobile menu.
2018-09-04 18:09:31 +02:00
Bat
bba9a56329 Add author biography at the bottom of the post 2018-09-04 14:55:15 +01:00
Bat
dd0663348e Better image styling 2018-09-04 14:39:46 +01:00
Bat
3b2d69893d Better style for code blocks 2018-09-04 14:32:20 +01:00
Bat
dbdc9f317e Show like/boost counters even when not logged in 2018-09-04 13:46:08 +01:00